@arcgis/charts-components 5.1.0-next.65 → 5.1.0-next.67

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 (264) hide show
  1. package/dist/cdn/2333HQZZ.js +2 -0
  2. package/dist/cdn/25LAV2UI.js +2 -0
  3. package/dist/cdn/{SMGWUDX3.js → 2J5IWBKU.js} +1 -1
  4. package/dist/cdn/2NIOPMWE.js +2 -0
  5. package/dist/cdn/32WPXK4K.js +2 -0
  6. package/dist/cdn/35NR6IHU.js +2 -0
  7. package/dist/cdn/4BDLJPIB.js +2 -0
  8. package/dist/cdn/4HRFZU2C.js +2 -0
  9. package/dist/cdn/4NYTLY62.js +2 -0
  10. package/dist/cdn/{66CPF67N.js → 5KOFW5BO.js} +1 -1
  11. package/dist/cdn/5PSQ7OKJ.js +2 -0
  12. package/dist/cdn/6GURKNO2.js +2 -0
  13. package/dist/cdn/{GLST76GV.js → 6GVGNQYH.js} +1 -1
  14. package/dist/cdn/6RKNXP6N.js +2 -0
  15. package/dist/cdn/{X6QQ322N.js → 6TKG7ZF7.js} +1 -1
  16. package/dist/cdn/{6VW6XPBH.js → 75FO5HPY.js} +1 -1
  17. package/dist/cdn/7HGCX3PA.js +2 -0
  18. package/dist/cdn/7Y5FTMNT.js +2 -0
  19. package/dist/cdn/{4YWBOW4N.js → 7YDVVZJU.js} +1 -1
  20. package/dist/cdn/AALOFAWG.js +2 -0
  21. package/dist/cdn/AMLWVAHN.js +2 -0
  22. package/dist/cdn/BVK4ULHH.js +2 -0
  23. package/dist/cdn/BXDRHDLV.js +2 -0
  24. package/dist/cdn/BXNLQMSP.js +2 -0
  25. package/dist/cdn/{3WMOCDMO.js → CCNHG4LT.js} +1 -1
  26. package/dist/cdn/CUAIY5DK.js +37 -0
  27. package/dist/cdn/DHCFSWRJ.js +2 -0
  28. package/dist/cdn/ECRW3QJF.js +2 -0
  29. package/dist/cdn/{DHZT5P3N.js → EF4GVHB2.js} +1 -1
  30. package/dist/cdn/EGHVQUKF.js +2 -0
  31. package/dist/cdn/EP5VVTAX.js +2 -0
  32. package/dist/cdn/EWLMYFSA.js +2 -0
  33. package/dist/cdn/{QFC7M2Y2.js → FFXTYOTF.js} +1 -1
  34. package/dist/cdn/FOSGOEWY.js +2 -0
  35. package/dist/cdn/G56RB2UI.js +2 -0
  36. package/dist/cdn/{HR62GM42.js → GKYHQ5OF.js} +1 -1
  37. package/dist/cdn/GXQDCOI4.js +99 -0
  38. package/dist/cdn/HW42VNOU.js +2 -0
  39. package/dist/cdn/I54YDLFZ.js +2 -0
  40. package/dist/cdn/I6IYDKWG.js +2 -0
  41. package/dist/cdn/IN3H6ULU.js +2 -0
  42. package/dist/cdn/ISNJYFT7.js +2 -0
  43. package/dist/cdn/ITB7EYBT.js +2 -0
  44. package/dist/cdn/JDQ6BNXO.js +2 -0
  45. package/dist/cdn/JMMW4Z5P.js +2 -0
  46. package/dist/cdn/JTL73F75.js +2 -0
  47. package/dist/cdn/KOLQWSYX.js +2 -0
  48. package/dist/cdn/KYFOP4WA.js +2 -0
  49. package/dist/cdn/L2NQ6Z3Z.js +2 -0
  50. package/dist/cdn/LGAAHH35.js +2 -0
  51. package/dist/cdn/LIXBROPH.js +2 -0
  52. package/dist/cdn/LRQVALTM.js +2 -0
  53. package/dist/cdn/LT62HS4S.js +2 -0
  54. package/dist/cdn/MUCSVAGN.js +2 -0
  55. package/dist/cdn/N4IITAR7.js +2 -0
  56. package/dist/cdn/NEEKPRM4.js +2 -0
  57. package/dist/cdn/NEFPCTH3.js +2 -0
  58. package/dist/cdn/NVV2EBVI.js +2 -0
  59. package/dist/cdn/O7ZCEGVR.js +2 -0
  60. package/dist/cdn/{WIP3X44L.js → OPDQRTZL.js} +3 -3
  61. package/dist/cdn/PG36SBDU.js +2 -0
  62. package/dist/cdn/PGJD4Q7S.js +2 -0
  63. package/dist/cdn/PGVNBWSU.js +23 -0
  64. package/dist/cdn/PL24HKI7.js +2 -0
  65. package/dist/cdn/PLBPOYRN.js +2 -0
  66. package/dist/cdn/QEPCR5IP.js +2 -0
  67. package/dist/cdn/QT24FAYQ.js +2 -0
  68. package/dist/cdn/R6XIAIZH.js +2 -0
  69. package/dist/cdn/RDBNRYTF.js +2 -0
  70. package/dist/cdn/RQLVJM4J.js +2 -0
  71. package/dist/cdn/RX6QOYCR.js +2 -0
  72. package/dist/cdn/SNZF4LXV.js +2 -0
  73. package/dist/cdn/{QRNEQ6OE.js → TJA5FMLP.js} +1 -1
  74. package/dist/cdn/TZJGC4RS.js +2 -0
  75. package/dist/cdn/{IIJZ52BJ.js → VRXVXPKS.js} +1 -1
  76. package/dist/cdn/VWCFL5P6.js +2 -0
  77. package/dist/cdn/W5VC5OCC.js +2 -0
  78. package/dist/cdn/W6T7TNP5.js +2 -0
  79. package/dist/cdn/WNEW6UZS.js +2 -0
  80. package/dist/cdn/XFXE7IY2.js +2 -0
  81. package/dist/cdn/XV7GLCBP.js +2 -0
  82. package/dist/cdn/Y3DU5EIT.js +2 -0
  83. package/dist/cdn/Y3NWCVUF.js +2 -0
  84. package/dist/cdn/YHUBOYF5.js +2 -0
  85. package/dist/cdn/YNRVU2AU.js +2 -0
  86. package/dist/cdn/YPSEQYTV.js +2 -0
  87. package/dist/cdn/YQTJQ5J7.js +2 -0
  88. package/dist/cdn/Z4GL4EF6.js +2 -0
  89. package/dist/cdn/ZIXBICPN.js +2 -0
  90. package/dist/cdn/ZRDVJBTQ.js +2 -0
  91. package/dist/cdn/index.js +1 -1
  92. package/dist/chart-rendering/common/data/utils/summarize-data/interfaces.d.ts +8 -0
  93. package/dist/chart-rendering/common/interfaces.d.ts +7 -0
  94. package/dist/chunks/action-bar-utils.js +22 -28
  95. package/dist/chunks/axis-lines-symbol.js +8 -8
  96. package/dist/chunks/bar-chart-model.js +19 -25
  97. package/dist/chunks/bar-chart-series.js +12 -18
  98. package/dist/chunks/box-plot-data.js +75 -81
  99. package/dist/chunks/box-plot-model.js +19 -19
  100. package/dist/chunks/chart-model.js +40 -46
  101. package/dist/chunks/chart-ui-utils2.js +47 -53
  102. package/dist/chunks/class-breaks.js +16 -16
  103. package/dist/chunks/combo-bar-line-chart-model.js +20 -20
  104. package/dist/chunks/data-labels-symbol.js +5 -5
  105. package/dist/chunks/data.js +53 -59
  106. package/dist/chunks/gauge-model.js +22 -28
  107. package/dist/chunks/generate-x-axis-title.js +30 -36
  108. package/dist/chunks/heat-chart-model.js +10 -16
  109. package/dist/chunks/histogram-data.js +53 -59
  110. package/dist/chunks/histogram-model.js +31 -31
  111. package/dist/chunks/index.js +608 -20565
  112. package/dist/chunks/index2.js +171 -678
  113. package/dist/chunks/index3.js +46 -181
  114. package/dist/chunks/interfaces.js +16443 -103
  115. package/dist/chunks/interfaces2.js +109 -0
  116. package/dist/chunks/line-chart-model.js +2 -2
  117. package/dist/chunks/model-setter.js +15 -21
  118. package/dist/chunks/model-with-guides.js +22 -28
  119. package/dist/chunks/model-with-tooltips.js +23 -29
  120. package/dist/chunks/model-with-x-guides.js +4 -4
  121. package/dist/chunks/model-with-y-guides.js +25 -31
  122. package/dist/chunks/negative-values-stacked-to-baseline.js +41 -47
  123. package/dist/chunks/pie-chart-data.js +33 -39
  124. package/dist/chunks/pie-chart-model.js +62 -68
  125. package/dist/chunks/radar-chart-model.js +8 -15
  126. package/dist/chunks/rotated-state.js +9 -15
  127. package/dist/chunks/scatterplot-model.js +84 -90
  128. package/dist/chunks/serial-chart-data.js +8178 -4195
  129. package/dist/chunks/serial-chart-model.js +32 -39
  130. package/dist/chunks/series-length.js +14 -20
  131. package/dist/chunks/series.js +10 -16
  132. package/dist/chunks/utils.js +337 -119
  133. package/dist/chunks/utils2.js +19 -25
  134. package/dist/chunks/web-component-utils.js +42 -42
  135. package/dist/components/arcgis-chart/customElement.js +5255 -5339
  136. package/dist/components/arcgis-charts-action-bar/customElement.js +2 -2
  137. package/dist/components/arcgis-charts-config-bar-chart/customElement.js +22 -28
  138. package/dist/components/arcgis-charts-config-bar-chart-data/customElement.js +4 -10
  139. package/dist/components/arcgis-charts-config-bar-chart-popover/customElement.js +15 -20
  140. package/dist/components/arcgis-charts-config-bar-chart-series/customElement.js +9 -15
  141. package/dist/components/arcgis-charts-config-bar-chart-series-popover/customElement.js +9 -15
  142. package/dist/components/arcgis-charts-config-box-plot/customElement.js +10 -16
  143. package/dist/components/arcgis-charts-config-box-plot-data/customElement.js +5 -11
  144. package/dist/components/arcgis-charts-config-box-plot-popover/customElement.js +33 -38
  145. package/dist/components/arcgis-charts-config-box-plot-series/customElement.js +4 -10
  146. package/dist/components/arcgis-charts-config-box-plot-series-popover/customElement.js +4 -10
  147. package/dist/components/arcgis-charts-config-chart-rename-popover/customElement.js +7 -13
  148. package/dist/components/arcgis-charts-config-create-flow/customElement.js +14 -20
  149. package/dist/components/arcgis-charts-config-font-style/customElement.js +14 -20
  150. package/dist/components/arcgis-charts-config-format/customElement.js +4 -10
  151. package/dist/components/arcgis-charts-config-format-popover/customElement.js +10 -16
  152. package/dist/components/arcgis-charts-config-general/customElement.js +8 -14
  153. package/dist/components/arcgis-charts-config-guide/customElement.js +14 -19
  154. package/dist/components/arcgis-charts-config-guide-popover/customElement.js +13 -19
  155. package/dist/components/arcgis-charts-config-guides-type-popover/customElement.js +4 -10
  156. package/dist/components/arcgis-charts-config-heat-chart/customElement.js +20 -26
  157. package/dist/components/arcgis-charts-config-heat-chart-data/customElement.js +17 -24
  158. package/dist/components/arcgis-charts-config-heat-chart-popover/customElement.js +15 -21
  159. package/dist/components/arcgis-charts-config-histogram/customElement.js +26 -32
  160. package/dist/components/arcgis-charts-config-histogram-data/customElement.js +26 -32
  161. package/dist/components/arcgis-charts-config-histogram-popover/customElement.js +5 -11
  162. package/dist/components/arcgis-charts-config-line-chart/customElement.js +18 -24
  163. package/dist/components/arcgis-charts-config-line-chart-data/customElement.js +12 -18
  164. package/dist/components/arcgis-charts-config-line-chart-popover/customElement.js +8 -14
  165. package/dist/components/arcgis-charts-config-line-chart-series/customElement.js +4 -10
  166. package/dist/components/arcgis-charts-config-line-chart-series-popover/customElement.js +4 -10
  167. package/dist/components/arcgis-charts-config-pie-chart/customElement.js +5 -11
  168. package/dist/components/arcgis-charts-config-pie-chart-data/customElement.js +8 -14
  169. package/dist/components/arcgis-charts-config-pie-chart-popover/customElement.js +18 -24
  170. package/dist/components/arcgis-charts-config-pie-chart-slices/customElement.js +8 -14
  171. package/dist/components/arcgis-charts-config-pie-chart-slices-popover/customElement.js +4 -10
  172. package/dist/components/arcgis-charts-config-scatter-plot/customElement.js +22 -28
  173. package/dist/components/arcgis-charts-config-scatter-plot-data/customElement.js +9 -15
  174. package/dist/components/arcgis-charts-config-scatter-plot-popover/customElement.js +5 -11
  175. package/dist/components/arcgis-charts-config-select-chart-type-popover/customElement.js +4 -10
  176. package/dist/components/arcgis-charts-config-view-charts/customElement.js +12 -19
  177. package/dist/components/arcgis-charts-info-modal/customElement.js +4 -10
  178. package/dist/docs/api.json +1 -1
  179. package/dist/docs/docs.json +1 -1
  180. package/dist/docs/vscode.html-custom-data.json +1 -1
  181. package/dist/docs/web-types.json +1 -1
  182. package/dist/index.js +421 -412
  183. package/dist/utils/chart-config/utils/index.d.ts +22 -1
  184. package/dist/utils/chart-config/validator/index.d.ts +2 -2
  185. package/dist/utils/data/index.d.ts +48 -1
  186. package/dist/utils/data/pie-chart/index.d.ts +31 -0
  187. package/package.json +3 -3
  188. package/dist/cdn/2R7GVZ2K.js +0 -2
  189. package/dist/cdn/3LT2GKQ2.js +0 -2
  190. package/dist/cdn/4D7IL776.js +0 -23
  191. package/dist/cdn/4TUXERAH.js +0 -2
  192. package/dist/cdn/53BACKKK.js +0 -2
  193. package/dist/cdn/5TNV7JHC.js +0 -2
  194. package/dist/cdn/627BGNFG.js +0 -2
  195. package/dist/cdn/6LOKVOKI.js +0 -2
  196. package/dist/cdn/6NZ5UJML.js +0 -2
  197. package/dist/cdn/6WJVFMRO.js +0 -2
  198. package/dist/cdn/7GZN67ZQ.js +0 -2
  199. package/dist/cdn/7SSD7QVG.js +0 -2
  200. package/dist/cdn/7XRXZ5B3.js +0 -2
  201. package/dist/cdn/7Y57O4FJ.js +0 -2
  202. package/dist/cdn/7Y7YFJKK.js +0 -2
  203. package/dist/cdn/7YXQ6TZT.js +0 -2
  204. package/dist/cdn/A642VLJ3.js +0 -2
  205. package/dist/cdn/AVCKTWRB.js +0 -2
  206. package/dist/cdn/BCEUGCIB.js +0 -2
  207. package/dist/cdn/BP7HN7YH.js +0 -2
  208. package/dist/cdn/BPZNMCFA.js +0 -2
  209. package/dist/cdn/DRLAYMR6.js +0 -2
  210. package/dist/cdn/DXWMRZX7.js +0 -2
  211. package/dist/cdn/E7ZG5PMT.js +0 -2
  212. package/dist/cdn/EDBE2EVF.js +0 -2
  213. package/dist/cdn/EDCUOXXS.js +0 -2
  214. package/dist/cdn/EWCL54AQ.js +0 -2
  215. package/dist/cdn/FKR2N42T.js +0 -2
  216. package/dist/cdn/GT2GE37X.js +0 -2
  217. package/dist/cdn/HHMRHLFD.js +0 -2
  218. package/dist/cdn/HMYIPN7X.js +0 -2
  219. package/dist/cdn/HQZDYYW6.js +0 -2
  220. package/dist/cdn/HZDIYXNY.js +0 -2
  221. package/dist/cdn/I34GLJPW.js +0 -2
  222. package/dist/cdn/IGRLN5QE.js +0 -2
  223. package/dist/cdn/IJD3YDOE.js +0 -2
  224. package/dist/cdn/ITF5WJUH.js +0 -2
  225. package/dist/cdn/J73HEYK6.js +0 -2
  226. package/dist/cdn/JWTEQZTD.js +0 -2
  227. package/dist/cdn/KDLX6TGN.js +0 -2
  228. package/dist/cdn/LLNUWDC5.js +0 -2
  229. package/dist/cdn/LZ7LNUEI.js +0 -2
  230. package/dist/cdn/MAZJTJ64.js +0 -2
  231. package/dist/cdn/MB7BDR7H.js +0 -2
  232. package/dist/cdn/MTTVUHUH.js +0 -2
  233. package/dist/cdn/MVLJJ7VZ.js +0 -2
  234. package/dist/cdn/N373OIOT.js +0 -2
  235. package/dist/cdn/N4GBOPIU.js +0 -2
  236. package/dist/cdn/OG3JZ3LP.js +0 -37
  237. package/dist/cdn/PSYU6XTK.js +0 -2
  238. package/dist/cdn/PVTBEXFF.js +0 -2
  239. package/dist/cdn/PYLJO324.js +0 -2
  240. package/dist/cdn/QQ6DOFHZ.js +0 -99
  241. package/dist/cdn/RAJWBR34.js +0 -2
  242. package/dist/cdn/S7COU7MH.js +0 -2
  243. package/dist/cdn/SYY7UU2N.js +0 -2
  244. package/dist/cdn/TN45YUM2.js +0 -2
  245. package/dist/cdn/TODWZ6FZ.js +0 -2
  246. package/dist/cdn/TP7767ZV.js +0 -2
  247. package/dist/cdn/UFJOL4MK.js +0 -2
  248. package/dist/cdn/ULSVHCH4.js +0 -2
  249. package/dist/cdn/UVFPEIK2.js +0 -2
  250. package/dist/cdn/V3PU5TMU.js +0 -2
  251. package/dist/cdn/V3VVN7ST.js +0 -2
  252. package/dist/cdn/V5JXE6N4.js +0 -2
  253. package/dist/cdn/VPOAGMYE.js +0 -2
  254. package/dist/cdn/VXMMIOTJ.js +0 -2
  255. package/dist/cdn/WL2XRSAH.js +0 -2
  256. package/dist/cdn/WWARKOXR.js +0 -2
  257. package/dist/cdn/WWGW24FD.js +0 -2
  258. package/dist/cdn/XUHCS2SB.js +0 -2
  259. package/dist/cdn/YBAPI2UV.js +0 -2
  260. package/dist/cdn/YJDYXU2Q.js +0 -2
  261. package/dist/cdn/YUZ26Q2B.js +0 -2
  262. package/dist/cdn/ZRDKD2U3.js +0 -2
  263. package/dist/cdn/ZVOSWG36.js +0 -2
  264. /package/dist/cdn/{FPDW4F45.js → VCUC6CMW.js} +0 -0
@@ -1,37 +0,0 @@
1
- /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{a as rr}from"./QVD6LHQ2.js";import o from"./HR62GM42.js";import n from"./WIP3X44L.js";import{a as vx,g as xx}from"./7BDNLABD.js";import m from"./3LT2GKQ2.js";import{c as ef,e as Th,f as Ih,g as Dh,h as Lh,i as So,j as To}from"./S5OM65RV.js";import l from"./VPOAGMYE.js";import{a as ux}from"./FPDW4F45.js";import{a as qu}from"./MP7HYYJR.js";import k from"./MB7BDR7H.js";import j from"./PYLJO324.js";import i from"./TODWZ6FZ.js";import h from"./4D7IL776.js";import g from"./WWGW24FD.js";import f from"./UVFPEIK2.js";import e from"./V5JXE6N4.js";import d from"./JWTEQZTD.js";import c from"./IGRLN5QE.js";import b from"./2R7GVZ2K.js";import{c as fh,d as ov,e as wu,p as lv,q as hv,r as gh,s as cv,t as vo}from"./YJXIGYX6.js";import a from"./QQ6DOFHZ.js";import{C as Jl,g as oi,h as Ao,l as ra,t as Md,u as ar,v as ql,w as Ir,x as xi,y as Ct,z as ht}from"./Y7IQV44J.js";import{a as xy,b as by,c as Wl,g as Zl}from"./3ZHL4GR5.js";import{a as yx}from"./IIJZ52BJ.js";import{d as ha,e as fx,f as gx,g as px,m as Ju,s as mx}from"./TCOJQJAP.js";import"./EZM4ZDQI.js";import{a as P,b as Ey,e as je,f as Hi,h as kd,k as ns,l as Ns,m as bn,n as Py,p as qi,q as My,t as Ed,u as Pd,y as Oe,z as Hy}from"./ETLJKITO.js";import{A as my,B as yy,G as vy,g as uy,h as fy,i as hA,l as gy,n as Mi,y as py,z as Td}from"./J66D7A5G.js";import{a as no,b as cy,c as Y1,d as dy}from"./QPIMTXPL.js";export default $arcgis.t(([us,{substitute:Ug},Sg,,,,,,,,,,,,,,,,,,,,{$a:Zy,$b:cu,$c:BA,$d:CA,Ab:Ar,Ac:F0,Ad:H0,B:pA,Bb:$e,Bd:R0,C:Kd,Cb:As,Cc:Ri,Cd:pu,D:qt,Da:zy,Db:xA,Dc:S0,Dd:O0,Eb:os,Ec:hr,Ed:N0,F:Ry,Fb:Au,Fc:go,Fd:V0,G:lo,Gb:Pa,Gc:Ma,Gd:$0,H:mA,Hb:A0,Hc:Ah,Hd:K0,Ia:Yy,Ib:or,Id:hh,Jc:Tn,Jd:G0,Kb:o0,Kc:Ji,Kd:X0,L:Oy,Ld:mu,M:Ny,Mb:ii,Md:W0,N:yA,Nc:T0,Nd:z0,Ob:ou,Od:Y0,Pa:Ht,Pb:l0,Pd:yu,Qa:$,Qb:vs,Qc:I0,Qd:j0,Ra:Yd,Rc:In,Rd:Z0,Sa:jy,Sd:ch,Ta:jd,Td:q0,U:ih,Ua:na,Ud:J0,Va:Zd,Vb:lu,Vc:D0,Vd:ev,Wa:qd,Wb:fo,Wd:tv,X:Vy,Xa:nr,Xb:h0,Y:Gd,Ya:Aa,Yb:c0,Yc:uu,Yd:dh,Z:$y,Za:Vs,Zb:rh,Zc:$s,Zd:cr,_a:Jd,_b:hu,_d:uh,ab:ho,ad:L0,ba:Xd,bb:Cn,bc:d0,bd:U0,be:mo,c:oo,ca:Ky,cb:co,ce:iv,d:Bn,da:Gy,db:eu,dc:u0,dd:Q0,de:sv,ea:Wd,ec:f0,ee:rv,fa:Xy,fb:qy,fc:g0,fe:av,g:Mt,gb:Jy,gc:p0,ge:vu,h:uA,hb:_n,hc:m0,hd:fu,he:xu,i:Hd,ib:sh,ic:y0,id:k0,j:eh,jb:uo,jc:v0,je:bu,k:fA,kb:tu,kc:x0,ke:la,l:Ea,lb:iu,m:wn,ma:zd,mb:Dr,mc:Fn,n:Rd,nb:e0,nc:ah,nd:gu,ne:Bu,o:gA,ob:su,oc:b0,oe:nv,p:Od,pb:t0,pc:Lr,q:aa,qa:Wy,qb:ru,qc:du,qd:E0,rb:vA,rc:B0,rd:oh,re:Av,s:Nt,sb:i0,sc:Sn,se:yo,tb:s0,tc:nh,td:wA,ub:r0,uc:w0,ud:lh,v:Nd,vb:a0,vc:lr,w:th,wc:C0,wd:bt,x:Vd,xb:n0,xc:_0,xd:po,y:$d,yb:au,yc:oa,yd:P0,zb:nu,zc:bA,zd:M0},,,,,,,{$:xh,$a:Xv,A:jl,Aa:Qu,Ab:ax,B:Qy,Ba:Qv,Bb:nx,C:ky,Ca:kv,Cb:Ax,D:xs,Da:ku,Db:ox,E:li,Ea:Eu,Eb:lx,F:xo,Fa:Pu,Fb:hx,G:Cu,Ga:Ha,Gb:ju,H:dv,Ha:Mu,Hb:Zu,I:uv,Ia:Hu,Ib:cx,J:_u,Ja:Ev,Jb:dx,K:Fu,Ka:Pv,L:ph,La:Mv,M:et,Ma:Hv,N:Ft,Na:Rv,O:mh,Oa:Ov,P:yh,Pa:wh,Q:bo,Qa:Nv,R:vh,Ra:_o,S:Te,Sa:Ru,T:fv,Ta:Ou,U:gv,Ua:Ch,V:Su,Va:Nu,W:pv,Wa:Vv,X:mv,Xa:$v,Y:St,Ya:Kv,Z:Wt,Za:Gv,_:yv,_a:Oi,a:Ke,aa:vv,ab:Vu,b:zl,ba:Tu,bb:$u,c:ji,ca:bh,cb:Wv,d:Zi,da:xv,db:zv,e:By,ea:Iu,eb:Ku,f:cA,fa:bv,fb:Gu,g:wy,ga:Du,gb:Yv,h:Cy,ha:Bh,hb:_h,i:Id,ia:Bv,ib:jv,j:_y,ja:Lu,jb:Zv,k:Dd,ka:wv,kb:qv,l:Is,la:Cv,lb:Xu,m:Fy,ma:_v,mb:Jv,n:Yl,na:Fv,nb:Wu,o:Sy,oa:Sv,ob:ex,p:Ty,pa:Uu,pb:zu,q:ka,qa:Bo,qb:bi,r:Iy,ra:Tv,rb:Fh,s:dA,sa:Iv,sb:Sh,t:Ld,ta:Dn,tb:Ks,u:Tr,ua:Dv,ub:tx,v:Ud,va:wo,vb:Fo,w:Dy,wa:Lv,wb:Yu,x:Qd,xa:Uv,xb:ix,y:Ly,ya:Co,yb:sx,z:Uy,za:Ln,zb:rx},,,,{b:wx,r:tf},{b:bx,c:Bx},{c:sf,d:rf,e:Cx},{f:_x}])=>{var Tx=cy((af,nf)=>{(function(a,e){typeof af=="object"&&typeof nf<"u"?nf.exports=e():typeof define=="function"&&define.amd?define(e):(a=typeof globalThis<"u"?globalThis:a||self,a.html2canvas=e())})(af,(function(){"use strict";var a=function(p,f){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,v){x.__proto__=v}||function(x,v){for(var C in v)Object.prototype.hasOwnProperty.call(v,C)&&(x[C]=v[C])},a(p,f)};function e(p,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");a(p,f);function x(){this.constructor=p}p.prototype=f===null?Object.create(f):(x.prototype=f.prototype,new x)}var t=function(){return t=Object.assign||function(f){for(var x,v=1,C=arguments.length;v<C;v++){x=arguments[v];for(var S in x)Object.prototype.hasOwnProperty.call(x,S)&&(f[S]=x[S])}return f},t.apply(this,arguments)};function i(p,f,x,v){function C(S){return S instanceof x?S:new x(function(L){L(S)})}return new(x||(x=Promise))(function(S,L){function R(Z){try{j(v.next(Z))}catch(ee){L(ee)}}function H(Z){try{j(v.throw(Z))}catch(ee){L(ee)}}function j(Z){Z.done?S(Z.value):C(Z.value).then(R,H)}j((v=v.apply(p,f||[])).next())})}function s(p,f){var x={label:0,sent:function(){if(S[0]&1)throw S[1];return S[1]},trys:[],ops:[]},v,C,S,L;return L={next:R(0),throw:R(1),return:R(2)},typeof Symbol=="function"&&(L[Symbol.iterator]=function(){return this}),L;function R(j){return function(Z){return H([j,Z])}}function H(j){if(v)throw new TypeError("Generator is already executing.");for(;x;)try{if(v=1,C&&(S=j[0]&2?C.return:j[0]?C.throw||((S=C.return)&&S.call(C),0):C.next)&&!(S=S.call(C,j[1])).done)return S;switch(C=0,S&&(j=[j[0]&2,S.value]),j[0]){case 0:case 1:S=j;break;case 4:return x.label++,{value:j[1],done:!1};case 5:x.label++,C=j[1],j=[0];continue;case 7:j=x.ops.pop(),x.trys.pop();continue;default:if(S=x.trys,!(S=S.length>0&&S[S.length-1])&&(j[0]===6||j[0]===2)){x=0;continue}if(j[0]===3&&(!S||j[1]>S[0]&&j[1]<S[3])){x.label=j[1];break}if(j[0]===6&&x.label<S[1]){x.label=S[1],S=j;break}if(S&&x.label<S[2]){x.label=S[2],x.ops.push(j);break}S[2]&&x.ops.pop(),x.trys.pop();continue}j=f.call(p,x)}catch(Z){j=[6,Z],C=0}finally{v=S=0}if(j[0]&5)throw j[1];return{value:j[0]?j[1]:void 0,done:!0}}}function r(p,f,x){if(x||arguments.length===2)for(var v=0,C=f.length,S;v<C;v++)(S||!(v in f))&&(S||(S=Array.prototype.slice.call(f,0,v)),S[v]=f[v]);return p.concat(S||f)}for(var n=(function(){function p(f,x,v,C){this.left=f,this.top=x,this.width=v,this.height=C}return p.prototype.add=function(f,x,v,C){return new p(this.left+f,this.top+x,this.width+v,this.height+C)},p.fromClientRect=function(f,x){return new p(x.left+f.windowBounds.left,x.top+f.windowBounds.top,x.width,x.height)},p.fromDOMRectList=function(f,x){var v=Array.from(x).find(function(C){return C.width!==0});return v?new p(v.left+f.windowBounds.left,v.top+f.windowBounds.top,v.width,v.height):p.EMPTY},p.EMPTY=new p(0,0,0,0),p})(),A=function(p,f){return n.fromClientRect(p,f.getBoundingClientRect())},o=function(p){var f=p.body,x=p.documentElement;if(!f||!x)throw new Error("Unable to get document size");var v=Math.max(Math.max(f.scrollWidth,x.scrollWidth),Math.max(f.offsetWidth,x.offsetWidth),Math.max(f.clientWidth,x.clientWidth)),C=Math.max(Math.max(f.scrollHeight,x.scrollHeight),Math.max(f.offsetHeight,x.offsetHeight),Math.max(f.clientHeight,x.clientHeight));return new n(0,0,v,C)},l=function(p){for(var f=[],x=0,v=p.length;x<v;){var C=p.charCodeAt(x++);if(C>=55296&&C<=56319&&x<v){var S=p.charCodeAt(x++);(S&64512)===56320?f.push(((C&1023)<<10)+(S&1023)+65536):(f.push(C),x--)}else f.push(C)}return f},c=function(){for(var p=[],f=0;f<arguments.length;f++)p[f]=arguments[f];if(String.fromCodePoint)return String.fromCodePoint.apply(String,p);var x=p.length;if(!x)return"";for(var v=[],C=-1,S="";++C<x;){var L=p[C];L<=65535?v.push(L):(L-=65536,v.push((L>>10)+55296,L%1024+56320)),(C+1===x||v.length>16384)&&(S+=String.fromCharCode.apply(String,v),v.length=0)}return S},h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",d=typeof Uint8Array>"u"?[]:new Uint8Array(256),u=0;u<h.length;u++)d[h.charCodeAt(u)]=u;for(var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y=typeof Uint8Array>"u"?[]:new Uint8Array(256),m=0;m<g.length;m++)y[g.charCodeAt(m)]=m;for(var b=function(p){var f=p.length*.75,x=p.length,v,C=0,S,L,R,H;p[p.length-1]==="="&&(f--,p[p.length-2]==="="&&f--);var j=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u"&&typeof Uint8Array.prototype.slice<"u"?new ArrayBuffer(f):new Array(f),Z=Array.isArray(j)?j:new Uint8Array(j);for(v=0;v<x;v+=4)S=y[p.charCodeAt(v)],L=y[p.charCodeAt(v+1)],R=y[p.charCodeAt(v+2)],H=y[p.charCodeAt(v+3)],Z[C++]=S<<2|L>>4,Z[C++]=(L&15)<<4|R>>2,Z[C++]=(R&3)<<6|H&63;return j},B=function(p){for(var f=p.length,x=[],v=0;v<f;v+=2)x.push(p[v+1]<<8|p[v]);return x},w=function(p){for(var f=p.length,x=[],v=0;v<f;v+=4)x.push(p[v+3]<<24|p[v+2]<<16|p[v+1]<<8|p[v]);return x},_=5,T=11,Q=2,U=T-_,E=65536>>_,O=1<<_,D=O-1,k=1024>>_,F=E+k,M=F,Y=32,z=M+Y,re=65536>>T,q=1<<U,Ae=q-1,X=function(p,f,x){return p.slice?p.slice(f,x):new Uint16Array(Array.prototype.slice.call(p,f,x))},G=function(p,f,x){return p.slice?p.slice(f,x):new Uint32Array(Array.prototype.slice.call(p,f,x))},ue=function(p,f){var x=b(p),v=Array.isArray(x)?w(x):new Uint32Array(x),C=Array.isArray(x)?B(x):new Uint16Array(x),S=24,L=X(C,S/2,v[4]/2),R=v[5]===2?X(C,(S+v[4])/2):G(v,Math.ceil((S+v[4])/4));return new he(v[0],v[1],v[2],v[3],L,R)},he=(function(){function p(f,x,v,C,S,L){this.initialValue=f,this.errorValue=x,this.highStart=v,this.highValueIndex=C,this.index=S,this.data=L}return p.prototype.get=function(f){var x;if(f>=0){if(f<55296||f>56319&&f<=65535)return x=this.index[f>>_],x=(x<<Q)+(f&D),this.data[x];if(f<=65535)return x=this.index[E+(f-55296>>_)],x=(x<<Q)+(f&D),this.data[x];if(f<this.highStart)return x=z-re+(f>>T),x=this.index[x],x+=f>>_&Ae,x=this.index[x],x=(x<<Q)+(f&D),this.data[x];if(f<=1114111)return this.data[this.highValueIndex]}return this.errorValue},p})(),ae="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Ie=typeof Uint8Array>"u"?[]:new Uint8Array(256),Pe=0;Pe<ae.length;Pe++)Ie[ae.charCodeAt(Pe)]=Pe;var De="KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF8AZwBgAGgAcQB5AHUAfQCFAI0AlQCdAKIAqgCyALoAYABoAGAAaABgAGgAwgDKAGAAaADGAM4A0wDbAOEA6QDxAPkAAQEJAQ8BFwF1AH0AHAEkASwBNAE6AUIBQQFJAVEBWQFhAWgBcAF4ATAAgAGGAY4BlQGXAZ8BpwGvAbUBvQHFAc0B0wHbAeMB6wHxAfkBAQIJAvEBEQIZAiECKQIxAjgCQAJGAk4CVgJeAmQCbAJ0AnwCgQKJApECmQKgAqgCsAK4ArwCxAIwAMwC0wLbAjAA4wLrAvMC+AIAAwcDDwMwABcDHQMlAy0DNQN1AD0DQQNJA0kDSQNRA1EDVwNZA1kDdQB1AGEDdQBpA20DdQN1AHsDdQCBA4kDkQN1AHUAmQOhA3UAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AKYDrgN1AHUAtgO+A8YDzgPWAxcD3gPjA+sD8wN1AHUA+wMDBAkEdQANBBUEHQQlBCoEFwMyBDgEYABABBcDSARQBFgEYARoBDAAcAQzAXgEgASIBJAEdQCXBHUAnwSnBK4EtgS6BMIEyAR1AHUAdQB1AHUAdQCVANAEYABgAGAAYABgAGAAYABgANgEYADcBOQEYADsBPQE/AQEBQwFFAUcBSQFLAU0BWQEPAVEBUsFUwVbBWAAYgVgAGoFcgV6BYIFigWRBWAAmQWfBaYFYABgAGAAYABgAKoFYACxBbAFuQW6BcEFwQXHBcEFwQXPBdMF2wXjBeoF8gX6BQIGCgYSBhoGIgYqBjIGOgZgAD4GRgZMBmAAUwZaBmAAYABgAGAAYABgAGAAYABgAGAAYABgAGIGYABpBnAGYABgAGAAYABgAGAAYABgAGAAYAB4Bn8GhQZgAGAAYAB1AHcDFQSLBmAAYABgAJMGdQA9A3UAmwajBqsGqwaVALMGuwbDBjAAywbSBtIG1QbSBtIG0gbSBtIG0gbdBuMG6wbzBvsGAwcLBxMHAwcbByMHJwcsBywHMQcsB9IGOAdAB0gHTgfSBkgHVgfSBtIG0gbSBtIG0gbSBtIG0gbSBiwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdgAGAALAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdbB2MHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB2kH0gZwB64EdQB1AHUAdQB1AHUAdQB1AHUHfQdgAIUHjQd1AHUAlQedB2AAYAClB6sHYACzB7YHvgfGB3UAzgfWBzMB3gfmB1EB7gf1B/0HlQENAQUIDQh1ABUIHQglCBcDLQg1CD0IRQhNCEEDUwh1AHUAdQBbCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIcAh3CHoIMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIgggwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAALAcsBywHLAcsBywHLAcsBywHLAcsB4oILAcsB44I0gaWCJ4Ipgh1AHUAqgiyCHUAdQB1AHUAdQB1AHUAdQB1AHUAtwh8AXUAvwh1AMUIyQjRCNkI4AjoCHUAdQB1AO4I9gj+CAYJDgkTCS0HGwkjCYIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiAAIAAAAFAAYABgAGIAXwBgAHEAdQBFAJUAogCyAKAAYABgAEIA4ABGANMA4QDxAMEBDwE1AFwBLAE6AQEBUQF4QkhCmEKoQrhCgAHIQsAB0MLAAcABwAHAAeDC6ABoAHDCwMMAAcABwAHAAdDDGMMAAcAB6MM4wwjDWMNow3jDaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAEjDqABWw6bDqABpg6gAaABoAHcDvwOPA+gAaABfA/8DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DpcPAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcAB9cPKwkyCToJMAB1AHUAdQBCCUoJTQl1AFUJXAljCWcJawkwADAAMAAwAHMJdQB2CX4JdQCECYoJjgmWCXUAngkwAGAAYABxAHUApgn3A64JtAl1ALkJdQDACTAAMAAwADAAdQB1AHUAdQB1AHUAdQB1AHUAowYNBMUIMAAwADAAMADICcsJ0wnZCRUE4QkwAOkJ8An4CTAAMAB1AAAKvwh1AAgKDwoXCh8KdQAwACcKLgp1ADYKqAmICT4KRgowADAAdQB1AE4KMAB1AFYKdQBeCnUAZQowADAAMAAwADAAMAAwADAAMAAVBHUAbQowADAAdQC5CXUKMAAwAHwBxAijBogEMgF9CoQKiASMCpQKmgqIBKIKqgquCogEDQG2Cr4KxgrLCjAAMADTCtsKCgHjCusK8Qr5CgELMAAwADAAMAB1AIsECQsRC3UANAEZCzAAMAAwADAAMAB1ACELKQswAHUANAExCzkLdQBBC0kLMABRC1kLMAAwADAAMAAwADAAdQBhCzAAMAAwAGAAYABpC3ELdwt/CzAAMACHC4sLkwubC58Lpwt1AK4Ltgt1APsDMAAwADAAMAAwADAAMAAwAL4LwwvLC9IL1wvdCzAAMADlC+kL8Qv5C/8LSQswADAAMAAwADAAMAAwADAAMAAHDDAAMAAwADAAMAAODBYMHgx1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1ACYMMAAwADAAdQB1AHUALgx1AHUAdQB1AHUAdQA2DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AD4MdQBGDHUAdQB1AHUAdQB1AEkMdQB1AHUAdQB1AFAMMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQBYDHUAdQB1AF8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUA+wMVBGcMMAAwAHwBbwx1AHcMfwyHDI8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAYABgAJcMMAAwADAAdQB1AJ8MlQClDDAAMACtDCwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB7UMLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AA0EMAC9DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAsBywHLAcsBywHLAcsBywHLQcwAMEMyAwsBywHLAcsBywHLAcsBywHLAcsBywHzAwwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1ANQM2QzhDDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMABgAGAAYABgAGAAYABgAOkMYADxDGAA+AwADQYNYABhCWAAYAAODTAAMAAwADAAFg1gAGAAHg37AzAAMAAwADAAYABgACYNYAAsDTQNPA1gAEMNPg1LDWAAYABgAGAAYABgAGAAYABgAGAAUg1aDYsGVglhDV0NcQBnDW0NdQ15DWAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAlQCBDZUAiA2PDZcNMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAnw2nDTAAMAAwADAAMAAwAHUArw23DTAAMAAwADAAMAAwADAAMAAwADAAMAB1AL8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQDHDTAAYABgAM8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA1w11ANwNMAAwAD0B5A0wADAAMAAwADAAMADsDfQN/A0EDgwOFA4wABsOMAAwADAAMAAwADAAMAAwANIG0gbSBtIG0gbSBtIG0gYjDigOwQUuDsEFMw7SBjoO0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGQg5KDlIOVg7SBtIGXg5lDm0OdQ7SBtIGfQ6EDooOjQ6UDtIGmg6hDtIG0gaoDqwO0ga0DrwO0gZgAGAAYADEDmAAYAAkBtIGzA5gANIOYADaDokO0gbSBt8O5w7SBu8O0gb1DvwO0gZgAGAAxA7SBtIG0gbSBtIGYABgAGAAYAAED2AAsAUMD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHJA8sBywHLAcsBywHLAccDywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywPLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAc0D9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHPA/SBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gYUD0QPlQCVAJUAMAAwADAAMACVAJUAlQCVAJUAlQCVAEwPMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA//8EAAQABAAEAAQABAAEAAQABAANAAMAAQABAAIABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQACgATABcAHgAbABoAHgAXABYAEgAeABsAGAAPABgAHABLAEsASwBLAEsASwBLAEsASwBLABgAGAAeAB4AHgATAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABYAGwASAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWAA0AEQAeAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAFAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJABYAGgAbABsAGwAeAB0AHQAeAE8AFwAeAA0AHgAeABoAGwBPAE8ADgBQAB0AHQAdAE8ATwAXAE8ATwBPABYAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAFAATwBAAE8ATwBPAEAATwBQAFAATwBQAB4AHgAeAB4AHgAeAB0AHQAdAB0AHgAdAB4ADgBQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgBQAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAkACQAJAAkACQAJAAkABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAFAAHgAeAB4AKwArAFAAUABQAFAAGABQACsAKwArACsAHgAeAFAAHgBQAFAAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUAAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAYAA0AKwArAB4AHgAbACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAB4ABAAEAB4ABAAEABMABAArACsAKwArACsAKwArACsAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAKwArACsAKwBWAFYAVgBWAB4AHgArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AGgAaABoAGAAYAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQAEwAEACsAEwATAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABLAEsASwBLAEsASwBLAEsASwBLABoAGQAZAB4AUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABMAUAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABABQAFAABAAEAB4ABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUAAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAFAABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQAUABQAB4AHgAYABMAUAArACsABAAbABsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAFAABAAEAAQABAAEAFAABAAEAAQAUAAEAAQABAAEAAQAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArACsAHgArAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAUAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEAA0ADQBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUAArACsAKwBQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABABQACsAKwArACsAKwArACsAKwAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUAAaABoAUABQAFAAUABQAEwAHgAbAFAAHgAEACsAKwAEAAQABAArAFAAUABQAFAAUABQACsAKwArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQACsAUABQACsAKwAEACsABAAEAAQABAAEACsAKwArACsABAAEACsAKwAEAAQABAArACsAKwAEACsAKwArACsAKwArACsAUABQAFAAUAArAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLAAQABABQAFAAUAAEAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAArACsAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AGwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAKwArACsAKwArAAQABAAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAAQAUAArAFAAUABQAFAAUABQACsAKwArAFAAUABQACsAUABQAFAAUAArACsAKwBQAFAAKwBQACsAUABQACsAKwArAFAAUAArACsAKwBQAFAAUAArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArAAQABAAEAAQABAArACsAKwAEAAQABAArAAQABAAEAAQAKwArAFAAKwArACsAKwArACsABAArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAHgAeAB4AHgAeAB4AGwAeACsAKwArACsAKwAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAUABQAFAAKwArACsAKwArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwAOAFAAUABQAFAAUABQAFAAHgBQAAQABAAEAA4AUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAKwArAAQAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAKwArACsAKwArACsAUAArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAFAABAAEAAQABAAEAAQABAArAAQABAAEACsABAAEAAQABABQAB4AKwArACsAKwBQAFAAUAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQABoAUABQAFAAUABQAFAAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQACsAUAArACsAUABQAFAAUABQAFAAUAArACsAKwAEACsAKwArACsABAAEAAQABAAEAAQAKwAEACsABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArAAQABAAeACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAXAAqACoAKgAqACoAKgAqACsAKwArACsAGwBcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAeAEsASwBLAEsASwBLAEsASwBLAEsADQANACsAKwArACsAKwBcAFwAKwBcACsAXABcAFwAXABcACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAXAArAFwAXABcAFwAXABcAFwAXABcAFwAKgBcAFwAKgAqACoAKgAqACoAKgAqACoAXAArACsAXABcAFwAXABcACsAXAArACoAKgAqACoAKgAqACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwBcAFwAXABcAFAADgAOAA4ADgAeAA4ADgAJAA4ADgANAAkAEwATABMAEwATAAkAHgATAB4AHgAeAAQABAAeAB4AHgAeAB4AHgBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQAFAADQAEAB4ABAAeAAQAFgARABYAEQAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAAQABAAEAAQADQAEAAQAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAA0ADQAeAB4AHgAeAB4AHgAEAB4AHgAeAB4AHgAeACsAHgAeAA4ADgANAA4AHgAeAB4AHgAeAAkACQArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgBcAEsASwBLAEsASwBLAEsASwBLAEsADQANAB4AHgAeAB4AXABcAFwAXABcAFwAKgAqACoAKgBcAFwAXABcACoAKgAqAFwAKgAqACoAXABcACoAKgAqACoAKgAqACoAXABcAFwAKgAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqAFwAKgBLAEsASwBLAEsASwBLAEsASwBLACoAKgAqACoAKgAqAFAAUABQAFAAUABQACsAUAArACsAKwArACsAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAKwBQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsABAAEAAQAHgANAB4AHgAeAB4AHgAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUAArACsADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWABEAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQANAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAANAA0AKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUAArAAQABAArACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqAA0ADQAVAFwADQAeAA0AGwBcACoAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwAeAB4AEwATAA0ADQAOAB4AEwATAB4ABAAEAAQACQArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAHgArACsAKwATABMASwBLAEsASwBLAEsASwBLAEsASwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAXABcAFwAXABcACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAXAArACsAKwAqACoAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsAHgAeAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKwAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKwArAAQASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACoAKgAqACoAKgAqACoAXAAqACoAKgAqACoAKgArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABABQAFAAUABQAFAAUABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwANAA0AHgANAA0ADQANAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwAeAB4AHgAeAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArAA0ADQANAA0ADQBLAEsASwBLAEsASwBLAEsASwBLACsAKwArAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUAAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAAQAUABQAFAAUABQAFAABABQAFAABAAEAAQAUAArACsAKwArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQACsAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAFAAUABQACsAHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQACsAKwAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQACsAHgAeAB4AHgAeAB4AHgAOAB4AKwANAA0ADQANAA0ADQANAAkADQANAA0ACAAEAAsABAAEAA0ACQANAA0ADAAdAB0AHgAXABcAFgAXABcAFwAWABcAHQAdAB4AHgAUABQAFAANAAEAAQAEAAQABAAEAAQACQAaABoAGgAaABoAGgAaABoAHgAXABcAHQAVABUAHgAeAB4AHgAeAB4AGAAWABEAFQAVABUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ADQAeAA0ADQANAA0AHgANAA0ADQAHAB4AHgAeAB4AKwAEAAQABAAEAAQABAAEAAQABAAEAFAAUAArACsATwBQAFAAUABQAFAAHgAeAB4AFgARAE8AUABPAE8ATwBPAFAAUABQAFAAUAAeAB4AHgAWABEAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArABsAGwAbABsAGwAbABsAGgAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGgAbABsAGwAbABoAGwAbABoAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAHgAeAFAAGgAeAB0AHgBQAB4AGgAeAB4AHgAeAB4AHgAeAB4AHgBPAB4AUAAbAB4AHgBQAFAAUABQAFAAHgAeAB4AHQAdAB4AUAAeAFAAHgBQAB4AUABPAFAAUAAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgBQAFAAUABQAE8ATwBQAFAAUABQAFAATwBQAFAATwBQAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAUABQAFAATwBPAE8ATwBPAE8ATwBPAE8ATwBQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABPAB4AHgArACsAKwArAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHQAdAB4AHgAeAB0AHQAeAB4AHQAeAB4AHgAdAB4AHQAbABsAHgAdAB4AHgAeAB4AHQAeAB4AHQAdAB0AHQAeAB4AHQAeAB0AHgAdAB0AHQAdAB0AHQAeAB0AHgAeAB4AHgAeAB0AHQAdAB0AHgAeAB4AHgAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHgAeAB0AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAeAB0AHQAdAB0AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAdAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAWABEAHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAWABEAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AHQAdAB0AHgAeAB0AHgAeAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlAB4AHQAdAB4AHgAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AJQAlAB0AHQAlAB4AJQAlACUAIAAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAdAB0AHQAeAB0AJQAdAB0AHgAdAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAdAB0AHQAdACUAHgAlACUAJQAdACUAJQAdAB0AHQAlACUAHQAdACUAHQAdACUAJQAlAB4AHQAeAB4AHgAeAB0AHQAlAB0AHQAdAB0AHQAdACUAJQAlACUAJQAdACUAJQAgACUAHQAdACUAJQAlACUAJQAlACUAJQAeAB4AHgAlACUAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AFwAXABcAFwAXABcAHgATABMAJQAeAB4AHgAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARABYAEQAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAEAAQABAAeAB4AKwArACsAKwArABMADQANAA0AUAATAA0AUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUAANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAA0ADQANAA0ADQANAA0ADQAeAA0AFgANAB4AHgAXABcAHgAeABcAFwAWABEAFgARABYAEQAWABEADQANAA0ADQATAFAADQANAB4ADQANAB4AHgAeAB4AHgAMAAwADQANAA0AHgANAA0AFgANAA0ADQANAA0ADQANAA0AHgANAB4ADQANAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArAA0AEQARACUAJQBHAFcAVwAWABEAFgARABYAEQAWABEAFgARACUAJQAWABEAFgARABYAEQAWABEAFQAWABEAEQAlAFcAVwBXAFcAVwBXAFcAVwBXAAQABAAEAAQABAAEACUAVwBXAFcAVwA2ACUAJQBXAFcAVwBHAEcAJQAlACUAKwBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBRAFcAUQBXAFEAVwBXAFcAVwBXAFcAUQBXAFcAVwBXAFcAVwBRAFEAKwArAAQABAAVABUARwBHAFcAFQBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBRAFcAVwBXAFcAVwBXAFEAUQBXAFcAVwBXABUAUQBHAEcAVwArACsAKwArACsAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwAlACUAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACsAKwArACsAKwArACsAKwArACsAKwArAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBPAE8ATwBPAE8ATwBPAE8AJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADQATAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABLAEsASwBLAEsASwBLAEsASwBLAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAABAAEAAQABAAeAAQABAAEAAQABAAEAAQABAAEAAQAHgBQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAeAA0ADQANAA0ADQArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAAQAUABQAFAABABQAFAAUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAeAB4AHgAeAAQAKwArACsAUABQAFAAUABQAFAAHgAeABoAHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADgAOABMAEwArACsAKwArACsAKwArACsABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwANAA0ASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUAAeAB4AHgBQAA4AUABQAAQAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArAB4AWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYACsAKwArAAQAHgAeAB4AHgAeAB4ADQANAA0AHgAeAB4AHgArAFAASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArAB4AHgBcAFwAXABcAFwAKgBcAFwAXABcAFwAXABcAFwAXABcAEsASwBLAEsASwBLAEsASwBLAEsAXABcAFwAXABcACsAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAFAAUABQAAQAUABQAFAAUABQAFAAUABQAAQABAArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAHgANAA0ADQBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAXAAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAKgAqACoAXABcACoAKgBcAFwAXABcAFwAKgAqAFwAKgBcACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcACoAKgBQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAA0ADQBQAFAAUAAEAAQAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQADQAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAVABVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBUAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVACsAKwArACsAKwArACsAKwArACsAKwArAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAKwArACsAKwBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAKwArACsAKwAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAKwArACsAKwArAFYABABWAFYAVgBWAFYAVgBWAFYAVgBWAB4AVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgArAFYAVgBWAFYAVgArAFYAKwBWAFYAKwBWAFYAKwBWAFYAVgBWAFYAVgBWAFYAVgBWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAEQAWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAaAB4AKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAGAARABEAGAAYABMAEwAWABEAFAArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACUAJQAlACUAJQAWABEAFgARABYAEQAWABEAFgARABYAEQAlACUAFgARACUAJQAlACUAJQAlACUAEQAlABEAKwAVABUAEwATACUAFgARABYAEQAWABEAJQAlACUAJQAlACUAJQAlACsAJQAbABoAJQArACsAKwArAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAcAKwATACUAJQAbABoAJQAlABYAEQAlACUAEQAlABEAJQBXAFcAVwBXAFcAVwBXAFcAVwBXABUAFQAlACUAJQATACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXABYAJQARACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAWACUAEQAlABYAEQARABYAEQARABUAVwBRAFEAUQBRAFEAUQBRAFEAUQBRAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcARwArACsAVwBXAFcAVwBXAFcAKwArAFcAVwBXAFcAVwBXACsAKwBXAFcAVwBXAFcAVwArACsAVwBXAFcAKwArACsAGgAbACUAJQAlABsAGwArAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAAQAB0AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsADQANAA0AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAA0AUABQAFAAUAArACsAKwArAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwArAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwBQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAUABQAFAAUABQAAQABAAEACsABAAEACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAKwBQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAA0ADQANAA0ADQANAA0ADQAeACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAArACsAKwArAFAAUABQAFAAUAANAA0ADQANAA0ADQAUACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsADQANAA0ADQANAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArAAQABAANACsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAB4AHgAeAB4AHgArACsAKwArACsAKwAEAAQABAAEAAQABAAEAA0ADQAeAB4AHgAeAB4AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsASwBLAEsASwBLAEsASwBLAEsASwANAA0ADQANAFAABAAEAFAAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAeAA4AUAArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAADQANAB4ADQAEAAQABAAEAB4ABAAEAEsASwBLAEsASwBLAEsASwBLAEsAUAAOAFAADQANAA0AKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAANAA0AHgANAA0AHgAEACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAA0AKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsABAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsABAAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAUAArACsAKwArACsAKwAEACsAKwArACsAKwBQAFAAUABQAFAABAAEACsAKwAEAAQABAAEAAQABAAEACsAKwArAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAAQABABQAFAAUABQAA0ADQANAA0AHgBLAEsASwBLAEsASwBLAEsASwBLAA0ADQArAB4ABABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUAAeAFAAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABAAEAAQADgANAA0AEwATAB4AHgAeAA0ADQANAA0ADQANAA0ADQANAA0ADQANAA0ADQANAFAAUABQAFAABAAEACsAKwAEAA0ADQAeAFAAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKwArACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBcAFwADQANAA0AKgBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAKwArAFAAKwArAFAAUABQAFAAUABQAFAAUAArAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQAKwAEAAQAKwArAAQABAAEAAQAUAAEAFAABAAEAA0ADQANACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABABQAA4AUAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAFAABAAEAAQABAAOAB4ADQANAA0ADQAOAB4ABAArACsAKwArACsAKwArACsAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAA0ADQANAFAADgAOAA4ADQANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAAQABAAEAFAADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAOABMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAArACsAKwAEACsABAAEACsABAAEAAQABAAEAAQABABQAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAaABoAGgAaAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABIAEgAQwBDAEMAUABQAFAAUABDAFAAUABQAEgAQwBIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABDAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAJAAkACQAJAAkACQAJABYAEQArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwANAA0AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAANACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAA0ADQANAB4AHgAeAB4AHgAeAFAAUABQAFAADQAeACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAA0AHgAeACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAARwBHABUARwAJACsAKwArACsAKwArACsAKwArACsAKwAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUQBRAFEAKwArACsAKwArACsAKwArACsAKwArACsAKwBRAFEAUQBRACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAHgAEAAQADQAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQABAAEAAQABAAeAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQAHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAKwArAFAAKwArAFAAUAArACsAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUAArAFAAUABQAFAAUABQAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAHgAeAFAAUABQAFAAUAArAFAAKwArACsAUABQAFAAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeACsAKwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4ABAAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAHgAeAA0ADQANAA0AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArAAQABAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwBQAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArABsAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAB4AHgAeAB4ABAAEAAQABAAEAAQABABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArABYAFgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAGgBQAFAAUAAaAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUAArACsAKwArACsAKwBQACsAKwArACsAUAArAFAAKwBQACsAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUAArAFAAKwBQACsAUAArAFAAUAArAFAAKwArAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAKwBQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8AJQAlACUAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB4AHgAeACUAJQAlAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAlACUAJQAlACUAHgAlACUAJQAlACUAIAAgACAAJQAlACAAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACEAIQAhACEAIQAlACUAIAAgACUAJQAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAIAAlACUAJQAlACAAIAAgACUAIAAgACAAJQAlACUAJQAlACUAJQAgACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAlAB4AJQAeACUAJQAlACUAJQAgACUAJQAlACUAHgAlAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACAAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABcAFwAXABUAFQAVAB4AHgAeAB4AJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAgACUAJQAgACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAIAAgACUAJQAgACAAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACAAIAAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACAAIAAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAA==",Qe=50,dt=1,Me=2,mi=3,$t=4,I=5,le=7,ne=8,V=9,N=10,J=11,ce=12,de=13,ie=14,fe=15,Ce=16,ge=17,He=18,Dt=19,lt=20,Wi=21,ir=22,fs=23,Ps=24,gt=25,wr=26,jr=27,zi=28,ol=29,Zr=30,Vc=31,qn=32,un=33,qr=34,wa=35,$c=36,KA=37,Kc=38,ll=39,hl=40,Gc=41,Bp=42,Zw=43,qw=[9001,65288],wp="!",ut="\xD7",cl="\xF7",Xc=ue(De),Jr=[Zr,$c],Wc=[dt,Me,mi,I],Cp=[N,ne],_p=[jr,wr],Jw=Wc.concat(Cp),Fp=[Kc,ll,hl,qr,wa],eC=[fe,de],tC=function(p,f){f===void 0&&(f="strict");var x=[],v=[],C=[];return p.forEach(function(S,L){var R=Xc.get(S);if(R>Qe?(C.push(!0),R-=Qe):C.push(!1),["normal","auto","loose"].indexOf(f)!==-1&&[8208,8211,12316,12448].indexOf(S)!==-1)return v.push(L),x.push(Ce);if(R===$t||R===J){if(L===0)return v.push(L),x.push(Zr);var H=x[L-1];return Jw.indexOf(H)===-1?(v.push(v[L-1]),x.push(H)):(v.push(L),x.push(Zr))}if(v.push(L),R===Vc)return x.push(f==="strict"?Wi:KA);if(R===Bp||R===ol)return x.push(Zr);if(R===Zw)return S>=131072&&S<=196605||S>=196608&&S<=262141?x.push(KA):x.push(Zr);x.push(R)}),[v,x,C]},zc=function(p,f,x,v){var C=v[x];if(Array.isArray(p)?p.indexOf(C)!==-1:p===C)for(var S=x;S<=v.length;){S++;var L=v[S];if(L===f)return!0;if(L!==N)break}if(C===N)for(var S=x;S>0;){S--;var R=v[S];if(Array.isArray(p)?p.indexOf(R)!==-1:p===R)for(var H=x;H<=v.length;){H++;var L=v[H];if(L===f)return!0;if(L!==N)break}if(R!==N)break}return!1},Sp=function(p,f){for(var x=p;x>=0;){var v=f[x];if(v===N)x--;else return v}return 0},iC=function(p,f,x,v,C){if(x[v]===0)return ut;var S=v-1;if(Array.isArray(C)&&C[S]===!0)return ut;var L=S-1,R=S+1,H=f[S],j=L>=0?f[L]:0,Z=f[R];if(H===Me&&Z===mi)return ut;if(Wc.indexOf(H)!==-1)return wp;if(Wc.indexOf(Z)!==-1||Cp.indexOf(Z)!==-1)return ut;if(Sp(S,f)===ne)return cl;if(Xc.get(p[S])===J||(H===qn||H===un)&&Xc.get(p[R])===J||H===le||Z===le||H===V||[N,de,fe].indexOf(H)===-1&&Z===V||[ge,He,Dt,Ps,zi].indexOf(Z)!==-1||Sp(S,f)===ir||zc(fs,ir,S,f)||zc([ge,He],Wi,S,f)||zc(ce,ce,S,f))return ut;if(H===N)return cl;if(H===fs||Z===fs)return ut;if(Z===Ce||H===Ce)return cl;if([de,fe,Wi].indexOf(Z)!==-1||H===ie||j===$c&&eC.indexOf(H)!==-1||H===zi&&Z===$c||Z===lt||Jr.indexOf(Z)!==-1&&H===gt||Jr.indexOf(H)!==-1&&Z===gt||H===jr&&[KA,qn,un].indexOf(Z)!==-1||[KA,qn,un].indexOf(H)!==-1&&Z===wr||Jr.indexOf(H)!==-1&&_p.indexOf(Z)!==-1||_p.indexOf(H)!==-1&&Jr.indexOf(Z)!==-1||[jr,wr].indexOf(H)!==-1&&(Z===gt||[ir,fe].indexOf(Z)!==-1&&f[R+1]===gt)||[ir,fe].indexOf(H)!==-1&&Z===gt||H===gt&&[gt,zi,Ps].indexOf(Z)!==-1)return ut;if([gt,zi,Ps,ge,He].indexOf(Z)!==-1)for(var ee=S;ee>=0;){var oe=f[ee];if(oe===gt)return ut;if([zi,Ps].indexOf(oe)!==-1)ee--;else break}if([jr,wr].indexOf(Z)!==-1)for(var ee=[ge,He].indexOf(H)!==-1?L:S;ee>=0;){var oe=f[ee];if(oe===gt)return ut;if([zi,Ps].indexOf(oe)!==-1)ee--;else break}if(Kc===H&&[Kc,ll,qr,wa].indexOf(Z)!==-1||[ll,qr].indexOf(H)!==-1&&[ll,hl].indexOf(Z)!==-1||[hl,wa].indexOf(H)!==-1&&Z===hl||Fp.indexOf(H)!==-1&&[lt,wr].indexOf(Z)!==-1||Fp.indexOf(Z)!==-1&&H===jr||Jr.indexOf(H)!==-1&&Jr.indexOf(Z)!==-1||H===Ps&&Jr.indexOf(Z)!==-1||Jr.concat(gt).indexOf(H)!==-1&&Z===ir&&qw.indexOf(p[R])===-1||Jr.concat(gt).indexOf(Z)!==-1&&H===He)return ut;if(H===Gc&&Z===Gc){for(var _e=x[S],me=1;_e>0&&(_e--,f[_e]===Gc);)me++;if(me%2!==0)return ut}return H===qn&&Z===un?ut:cl},sC=function(p,f){f||(f={lineBreak:"normal",wordBreak:"normal"});var x=tC(p,f.lineBreak),v=x[0],C=x[1],S=x[2];(f.wordBreak==="break-all"||f.wordBreak==="break-word")&&(C=C.map(function(R){return[gt,Zr,Bp].indexOf(R)!==-1?KA:R}));var L=f.wordBreak==="keep-all"?S.map(function(R,H){return R&&p[H]>=19968&&p[H]<=40959}):void 0;return[v,C,L]},rC=(function(){function p(f,x,v,C){this.codePoints=f,this.required=x===wp,this.start=v,this.end=C}return p.prototype.slice=function(){return c.apply(void 0,this.codePoints.slice(this.start,this.end))},p})(),aC=function(p,f){var x=l(p),v=sC(x,f),C=v[0],S=v[1],L=v[2],R=x.length,H=0,j=0;return{next:function(){if(j>=R)return{done:!0,value:null};for(var Z=ut;j<R&&(Z=iC(x,S,C,++j,L))===ut;);if(Z!==ut||j===R){var ee=new rC(x,Z,H,j);return H=j,{value:ee,done:!1}}return{done:!0,value:null}}}},nC=1,AC=2,GA=4,Tp=8,dl=10,Ip=47,XA=92,oC=9,lC=32,ul=34,WA=61,hC=35,cC=36,dC=37,fl=39,gl=40,zA=41,uC=95,gs=45,fC=33,gC=60,pC=62,mC=64,yC=91,vC=93,xC=61,bC=123,pl=63,BC=125,Dp=124,wC=126,CC=128,Lp=65533,Yc=42,fn=43,_C=44,FC=58,SC=59,YA=46,TC=0,IC=8,DC=11,LC=14,UC=31,QC=127,Cr=-1,Up=48,Qp=97,kp=101,kC=102,EC=117,PC=122,Ep=65,Pp=69,Mp=70,MC=85,HC=90,Yi=function(p){return p>=Up&&p<=57},RC=function(p){return p>=55296&&p<=57343},Jn=function(p){return Yi(p)||p>=Ep&&p<=Mp||p>=Qp&&p<=kC},OC=function(p){return p>=Qp&&p<=PC},NC=function(p){return p>=Ep&&p<=HC},VC=function(p){return OC(p)||NC(p)},$C=function(p){return p>=CC},ml=function(p){return p===dl||p===oC||p===lC},yl=function(p){return VC(p)||$C(p)||p===uC},Hp=function(p){return yl(p)||Yi(p)||p===gs},KC=function(p){return p>=TC&&p<=IC||p===DC||p>=LC&&p<=UC||p===QC},Ca=function(p,f){return p!==XA?!1:f!==dl},vl=function(p,f,x){return p===gs?yl(f)||Ca(f,x):yl(p)?!0:!!(p===XA&&Ca(p,f))},jc=function(p,f,x){return p===fn||p===gs?Yi(f)?!0:f===YA&&Yi(x):Yi(p===YA?f:p)},GC=function(p){var f=0,x=1;(p[f]===fn||p[f]===gs)&&(p[f]===gs&&(x=-1),f++);for(var v=[];Yi(p[f]);)v.push(p[f++]);var C=v.length?parseInt(c.apply(void 0,v),10):0;p[f]===YA&&f++;for(var S=[];Yi(p[f]);)S.push(p[f++]);var L=S.length,R=L?parseInt(c.apply(void 0,S),10):0;(p[f]===Pp||p[f]===kp)&&f++;var H=1;(p[f]===fn||p[f]===gs)&&(p[f]===gs&&(H=-1),f++);for(var j=[];Yi(p[f]);)j.push(p[f++]);var Z=j.length?parseInt(c.apply(void 0,j),10):0;return x*(C+R*Math.pow(10,-L))*Math.pow(10,H*Z)},XC={type:2},WC={type:3},zC={type:4},YC={type:13},jC={type:8},ZC={type:21},qC={type:9},JC={type:10},e_={type:11},t_={type:12},i_={type:14},xl={type:23},s_={type:1},r_={type:25},a_={type:24},n_={type:26},A_={type:27},o_={type:28},l_={type:29},h_={type:31},Zc={type:32},Rp=(function(){function p(){this._value=[]}return p.prototype.write=function(f){this._value=this._value.concat(l(f))},p.prototype.read=function(){for(var f=[],x=this.consumeToken();x!==Zc;)f.push(x),x=this.consumeToken();return f},p.prototype.consumeToken=function(){var f=this.consumeCodePoint();switch(f){case ul:return this.consumeStringToken(ul);case hC:var x=this.peekCodePoint(0),v=this.peekCodePoint(1),C=this.peekCodePoint(2);if(Hp(x)||Ca(v,C)){var S=vl(x,v,C)?AC:nC,L=this.consumeName();return{type:5,value:L,flags:S}}break;case cC:if(this.peekCodePoint(0)===WA)return this.consumeCodePoint(),YC;break;case fl:return this.consumeStringToken(fl);case gl:return XC;case zA:return WC;case Yc:if(this.peekCodePoint(0)===WA)return this.consumeCodePoint(),i_;break;case fn:if(jc(f,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(f),this.consumeNumericToken();break;case _C:return zC;case gs:var R=f,H=this.peekCodePoint(0),j=this.peekCodePoint(1);if(jc(R,H,j))return this.reconsumeCodePoint(f),this.consumeNumericToken();if(vl(R,H,j))return this.reconsumeCodePoint(f),this.consumeIdentLikeToken();if(H===gs&&j===pC)return this.consumeCodePoint(),this.consumeCodePoint(),a_;break;case YA:if(jc(f,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(f),this.consumeNumericToken();break;case Ip:if(this.peekCodePoint(0)===Yc)for(this.consumeCodePoint();;){var Z=this.consumeCodePoint();if(Z===Yc&&(Z=this.consumeCodePoint(),Z===Ip))return this.consumeToken();if(Z===Cr)return this.consumeToken()}break;case FC:return n_;case SC:return A_;case gC:if(this.peekCodePoint(0)===fC&&this.peekCodePoint(1)===gs&&this.peekCodePoint(2)===gs)return this.consumeCodePoint(),this.consumeCodePoint(),r_;break;case mC:var ee=this.peekCodePoint(0),oe=this.peekCodePoint(1),_e=this.peekCodePoint(2);if(vl(ee,oe,_e)){var L=this.consumeName();return{type:7,value:L}}break;case yC:return o_;case XA:if(Ca(f,this.peekCodePoint(0)))return this.reconsumeCodePoint(f),this.consumeIdentLikeToken();break;case vC:return l_;case xC:if(this.peekCodePoint(0)===WA)return this.consumeCodePoint(),jC;break;case bC:return e_;case BC:return t_;case EC:case MC:var me=this.peekCodePoint(0),xe=this.peekCodePoint(1);return me===fn&&(Jn(xe)||xe===pl)&&(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(f),this.consumeIdentLikeToken();case Dp:if(this.peekCodePoint(0)===WA)return this.consumeCodePoint(),qC;if(this.peekCodePoint(0)===Dp)return this.consumeCodePoint(),ZC;break;case wC:if(this.peekCodePoint(0)===WA)return this.consumeCodePoint(),JC;break;case Cr:return Zc}return ml(f)?(this.consumeWhiteSpace(),h_):Yi(f)?(this.reconsumeCodePoint(f),this.consumeNumericToken()):yl(f)?(this.reconsumeCodePoint(f),this.consumeIdentLikeToken()):{type:6,value:c(f)}},p.prototype.consumeCodePoint=function(){var f=this._value.shift();return typeof f>"u"?-1:f},p.prototype.reconsumeCodePoint=function(f){this._value.unshift(f)},p.prototype.peekCodePoint=function(f){return f>=this._value.length?-1:this._value[f]},p.prototype.consumeUnicodeRangeToken=function(){for(var f=[],x=this.consumeCodePoint();Jn(x)&&f.length<6;)f.push(x),x=this.consumeCodePoint();for(var v=!1;x===pl&&f.length<6;)f.push(x),x=this.consumeCodePoint(),v=!0;if(v){var C=parseInt(c.apply(void 0,f.map(function(H){return H===pl?Up:H})),16),S=parseInt(c.apply(void 0,f.map(function(H){return H===pl?Mp:H})),16);return{type:30,start:C,end:S}}var L=parseInt(c.apply(void 0,f),16);if(this.peekCodePoint(0)===gs&&Jn(this.peekCodePoint(1))){this.consumeCodePoint(),x=this.consumeCodePoint();for(var R=[];Jn(x)&&R.length<6;)R.push(x),x=this.consumeCodePoint();var S=parseInt(c.apply(void 0,R),16);return{type:30,start:L,end:S}}else return{type:30,start:L,end:L}},p.prototype.consumeIdentLikeToken=function(){var f=this.consumeName();return f.toLowerCase()==="url"&&this.peekCodePoint(0)===gl?(this.consumeCodePoint(),this.consumeUrlToken()):this.peekCodePoint(0)===gl?(this.consumeCodePoint(),{type:19,value:f}):{type:20,value:f}},p.prototype.consumeUrlToken=function(){var f=[];if(this.consumeWhiteSpace(),this.peekCodePoint(0)===Cr)return{type:22,value:""};var x=this.peekCodePoint(0);if(x===fl||x===ul){var v=this.consumeStringToken(this.consumeCodePoint());return v.type===0&&(this.consumeWhiteSpace(),this.peekCodePoint(0)===Cr||this.peekCodePoint(0)===zA)?(this.consumeCodePoint(),{type:22,value:v.value}):(this.consumeBadUrlRemnants(),xl)}for(;;){var C=this.consumeCodePoint();if(C===Cr||C===zA)return{type:22,value:c.apply(void 0,f)};if(ml(C))return this.consumeWhiteSpace(),this.peekCodePoint(0)===Cr||this.peekCodePoint(0)===zA?(this.consumeCodePoint(),{type:22,value:c.apply(void 0,f)}):(this.consumeBadUrlRemnants(),xl);if(C===ul||C===fl||C===gl||KC(C))return this.consumeBadUrlRemnants(),xl;if(C===XA)if(Ca(C,this.peekCodePoint(0)))f.push(this.consumeEscapedCodePoint());else return this.consumeBadUrlRemnants(),xl;else f.push(C)}},p.prototype.consumeWhiteSpace=function(){for(;ml(this.peekCodePoint(0));)this.consumeCodePoint()},p.prototype.consumeBadUrlRemnants=function(){for(;;){var f=this.consumeCodePoint();if(f===zA||f===Cr)return;Ca(f,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},p.prototype.consumeStringSlice=function(f){for(var x=5e4,v="";f>0;){var C=Math.min(x,f);v+=c.apply(void 0,this._value.splice(0,C)),f-=C}return this._value.shift(),v},p.prototype.consumeStringToken=function(f){var x="",v=0;do{var C=this._value[v];if(C===Cr||C===void 0||C===f)return x+=this.consumeStringSlice(v),{type:0,value:x};if(C===dl)return this._value.splice(0,v),s_;if(C===XA){var S=this._value[v+1];S!==Cr&&S!==void 0&&(S===dl?(x+=this.consumeStringSlice(v),v=-1,this._value.shift()):Ca(C,S)&&(x+=this.consumeStringSlice(v),x+=c(this.consumeEscapedCodePoint()),v=-1))}v++}while(!0)},p.prototype.consumeNumber=function(){var f=[],x=GA,v=this.peekCodePoint(0);for((v===fn||v===gs)&&f.push(this.consumeCodePoint());Yi(this.peekCodePoint(0));)f.push(this.consumeCodePoint());v=this.peekCodePoint(0);var C=this.peekCodePoint(1);if(v===YA&&Yi(C))for(f.push(this.consumeCodePoint(),this.consumeCodePoint()),x=Tp;Yi(this.peekCodePoint(0));)f.push(this.consumeCodePoint());v=this.peekCodePoint(0),C=this.peekCodePoint(1);var S=this.peekCodePoint(2);if((v===Pp||v===kp)&&((C===fn||C===gs)&&Yi(S)||Yi(C)))for(f.push(this.consumeCodePoint(),this.consumeCodePoint()),x=Tp;Yi(this.peekCodePoint(0));)f.push(this.consumeCodePoint());return[GC(f),x]},p.prototype.consumeNumericToken=function(){var f=this.consumeNumber(),x=f[0],v=f[1],C=this.peekCodePoint(0),S=this.peekCodePoint(1),L=this.peekCodePoint(2);if(vl(C,S,L)){var R=this.consumeName();return{type:15,number:x,flags:v,unit:R}}return C===dC?(this.consumeCodePoint(),{type:16,number:x,flags:v}):{type:17,number:x,flags:v}},p.prototype.consumeEscapedCodePoint=function(){var f=this.consumeCodePoint();if(Jn(f)){for(var x=c(f);Jn(this.peekCodePoint(0))&&x.length<6;)x+=c(this.consumeCodePoint());ml(this.peekCodePoint(0))&&this.consumeCodePoint();var v=parseInt(x,16);return v===0||RC(v)||v>1114111?Lp:v}return f===Cr?Lp:f},p.prototype.consumeName=function(){for(var f="";;){var x=this.consumeCodePoint();if(Hp(x))f+=c(x);else if(Ca(x,this.peekCodePoint(0)))f+=c(this.consumeEscapedCodePoint());else return this.reconsumeCodePoint(x),f}},p})(),Op=(function(){function p(f){this._tokens=f}return p.create=function(f){var x=new Rp;return x.write(f),new p(x.read())},p.parseValue=function(f){return p.create(f).parseComponentValue()},p.parseValues=function(f){return p.create(f).parseComponentValues()},p.prototype.parseComponentValue=function(){for(var f=this.consumeToken();f.type===31;)f=this.consumeToken();if(f.type===32)throw new SyntaxError("Error parsing CSS component value, unexpected EOF");this.reconsumeToken(f);var x=this.consumeComponentValue();do f=this.consumeToken();while(f.type===31);if(f.type===32)return x;throw new SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},p.prototype.parseComponentValues=function(){for(var f=[];;){var x=this.consumeComponentValue();if(x.type===32)return f;f.push(x),f.push()}},p.prototype.consumeComponentValue=function(){var f=this.consumeToken();switch(f.type){case 11:case 28:case 2:return this.consumeSimpleBlock(f.type);case 19:return this.consumeFunction(f)}return f},p.prototype.consumeSimpleBlock=function(f){for(var x={type:f,values:[]},v=this.consumeToken();;){if(v.type===32||d_(v,f))return x;this.reconsumeToken(v),x.values.push(this.consumeComponentValue()),v=this.consumeToken()}},p.prototype.consumeFunction=function(f){for(var x={name:f.value,values:[],type:18};;){var v=this.consumeToken();if(v.type===32||v.type===3)return x;this.reconsumeToken(v),x.values.push(this.consumeComponentValue())}},p.prototype.consumeToken=function(){var f=this._tokens.shift();return typeof f>"u"?Zc:f},p.prototype.reconsumeToken=function(f){this._tokens.unshift(f)},p})(),jA=function(p){return p.type===15},eA=function(p){return p.type===17},Lt=function(p){return p.type===20},c_=function(p){return p.type===0},qc=function(p,f){return Lt(p)&&p.value===f},Np=function(p){return p.type!==31},tA=function(p){return p.type!==31&&p.type!==4},_r=function(p){var f=[],x=[];return p.forEach(function(v){if(v.type===4){if(x.length===0)throw new Error("Error parsing function args, zero tokens for arg");f.push(x),x=[];return}v.type!==31&&x.push(v)}),x.length&&f.push(x),f},d_=function(p,f){return f===11&&p.type===12||f===28&&p.type===29?!0:f===2&&p.type===3},_a=function(p){return p.type===17||p.type===15},yi=function(p){return p.type===16||_a(p)},Vp=function(p){return p.length>1?[p[0],p[1]]:[p[0]]},ki={type:17,number:0,flags:GA},Jc={type:16,number:50,flags:GA},Fa={type:16,number:100,flags:GA},ZA=function(p,f,x){var v=p[0],C=p[1];return[Ot(v,f),Ot(typeof C<"u"?C:v,x)]},Ot=function(p,f){if(p.type===16)return p.number/100*f;if(jA(p))switch(p.unit){case"rem":case"em":return 16*p.number;case"px":default:return p.number}return p.number},$p="deg",Kp="grad",Gp="rad",Xp="turn",bl={name:"angle",parse:function(p,f){if(f.type===15)switch(f.unit){case $p:return Math.PI*f.number/180;case Kp:return Math.PI/200*f.number;case Gp:return f.number;case Xp:return Math.PI*2*f.number}throw new Error("Unsupported angle type")}},Wp=function(p){return p.type===15&&(p.unit===$p||p.unit===Kp||p.unit===Gp||p.unit===Xp)},zp=function(p){var f=p.filter(Lt).map(function(x){return x.value}).join(" ");switch(f){case"to bottom right":case"to right bottom":case"left top":case"top left":return[ki,ki];case"to top":case"bottom":return Ms(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[ki,Fa];case"to right":case"left":return Ms(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[Fa,Fa];case"to bottom":case"top":return Ms(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[Fa,ki];case"to left":case"right":return Ms(270)}return 0},Ms=function(p){return Math.PI*p/180},Sa={name:"color",parse:function(p,f){if(f.type===18){var x=u_[f.name];if(typeof x>"u")throw new Error('Attempting to parse an unsupported color function "'+f.name+'"');return x(p,f.values)}if(f.type===5){if(f.value.length===3){var v=f.value.substring(0,1),C=f.value.substring(1,2),S=f.value.substring(2,3);return Ia(parseInt(v+v,16),parseInt(C+C,16),parseInt(S+S,16),1)}if(f.value.length===4){var v=f.value.substring(0,1),C=f.value.substring(1,2),S=f.value.substring(2,3),L=f.value.substring(3,4);return Ia(parseInt(v+v,16),parseInt(C+C,16),parseInt(S+S,16),parseInt(L+L,16)/255)}if(f.value.length===6){var v=f.value.substring(0,2),C=f.value.substring(2,4),S=f.value.substring(4,6);return Ia(parseInt(v,16),parseInt(C,16),parseInt(S,16),1)}if(f.value.length===8){var v=f.value.substring(0,2),C=f.value.substring(2,4),S=f.value.substring(4,6),L=f.value.substring(6,8);return Ia(parseInt(v,16),parseInt(C,16),parseInt(S,16),parseInt(L,16)/255)}}if(f.type===20){var R=ea[f.value.toUpperCase()];if(typeof R<"u")return R}return ea.TRANSPARENT}},Ta=function(p){return(255&p)===0},Ii=function(p){var f=255&p,x=255&p>>8,v=255&p>>16,C=255&p>>24;return f<255?"rgba("+C+","+v+","+x+","+f/255+")":"rgb("+C+","+v+","+x+")"},Ia=function(p,f,x,v){return(p<<24|f<<16|x<<8|Math.round(v*255)<<0)>>>0},Yp=function(p,f){if(p.type===17)return p.number;if(p.type===16){var x=f===3?1:255;return f===3?p.number/100*x:Math.round(p.number/100*x)}return 0},jp=function(p,f){var x=f.filter(tA);if(x.length===3){var v=x.map(Yp),C=v[0],S=v[1],L=v[2];return Ia(C,S,L,1)}if(x.length===4){var R=x.map(Yp),C=R[0],S=R[1],L=R[2],H=R[3];return Ia(C,S,L,H)}return 0};function ed(p,f,x){return x<0&&(x+=1),x>=1&&(x-=1),x<1/6?(f-p)*x*6+p:x<1/2?f:x<2/3?(f-p)*6*(2/3-x)+p:p}var Zp=function(p,f){var x=f.filter(tA),v=x[0],C=x[1],S=x[2],L=x[3],R=(v.type===17?Ms(v.number):bl.parse(p,v))/(Math.PI*2),H=yi(C)?C.number/100:0,j=yi(S)?S.number/100:0,Z=typeof L<"u"&&yi(L)?Ot(L,1):1;if(H===0)return Ia(j*255,j*255,j*255,1);var ee=j<=.5?j*(H+1):j+H-j*H,oe=j*2-ee,_e=ed(oe,ee,R+1/3),me=ed(oe,ee,R),xe=ed(oe,ee,R-1/3);return Ia(_e*255,me*255,xe*255,Z)},u_={hsl:Zp,hsla:Zp,rgb:jp,rgba:jp},qA=function(p,f){return Sa.parse(p,Op.create(f).parseComponentValue())},ea={ALICEBLUE:4042850303,ANTIQUEWHITE:4209760255,AQUA:16777215,AQUAMARINE:2147472639,AZURE:4043309055,BEIGE:4126530815,BISQUE:4293182719,BLACK:255,BLANCHEDALMOND:4293643775,BLUE:65535,BLUEVIOLET:2318131967,BROWN:2771004159,BURLYWOOD:3736635391,CADETBLUE:1604231423,CHARTREUSE:2147418367,CHOCOLATE:3530104575,CORAL:4286533887,CORNFLOWERBLUE:1687547391,CORNSILK:4294499583,CRIMSON:3692313855,CYAN:16777215,DARKBLUE:35839,DARKCYAN:9145343,DARKGOLDENROD:3095837695,DARKGRAY:2846468607,DARKGREEN:6553855,DARKGREY:2846468607,DARKKHAKI:3182914559,DARKMAGENTA:2332068863,DARKOLIVEGREEN:1433087999,DARKORANGE:4287365375,DARKORCHID:2570243327,DARKRED:2332033279,DARKSALMON:3918953215,DARKSEAGREEN:2411499519,DARKSLATEBLUE:1211993087,DARKSLATEGRAY:793726975,DARKSLATEGREY:793726975,DARKTURQUOISE:13554175,DARKVIOLET:2483082239,DEEPPINK:4279538687,DEEPSKYBLUE:12582911,DIMGRAY:1768516095,DIMGREY:1768516095,DODGERBLUE:512819199,FIREBRICK:2988581631,FLORALWHITE:4294635775,FORESTGREEN:579543807,FUCHSIA:4278255615,GAINSBORO:3705462015,GHOSTWHITE:4177068031,GOLD:4292280575,GOLDENROD:3668254975,GRAY:2155905279,GREEN:8388863,GREENYELLOW:2919182335,GREY:2155905279,HONEYDEW:4043305215,HOTPINK:4285117695,INDIANRED:3445382399,INDIGO:1258324735,IVORY:4294963455,KHAKI:4041641215,LAVENDER:3873897215,LAVENDERBLUSH:4293981695,LAWNGREEN:2096890111,LEMONCHIFFON:4294626815,LIGHTBLUE:2916673279,LIGHTCORAL:4034953471,LIGHTCYAN:3774873599,LIGHTGOLDENRODYELLOW:4210742015,LIGHTGRAY:3553874943,LIGHTGREEN:2431553791,LIGHTGREY:3553874943,LIGHTPINK:4290167295,LIGHTSALMON:4288707327,LIGHTSEAGREEN:548580095,LIGHTSKYBLUE:2278488831,LIGHTSLATEGRAY:2005441023,LIGHTSLATEGREY:2005441023,LIGHTSTEELBLUE:2965692159,LIGHTYELLOW:4294959359,LIME:16711935,LIMEGREEN:852308735,LINEN:4210091775,MAGENTA:4278255615,MAROON:2147483903,MEDIUMAQUAMARINE:1724754687,MEDIUMBLUE:52735,MEDIUMORCHID:3126187007,MEDIUMPURPLE:2473647103,MEDIUMSEAGREEN:1018393087,MEDIUMSLATEBLUE:2070474495,MEDIUMSPRINGGREEN:16423679,MEDIUMTURQUOISE:1221709055,MEDIUMVIOLETRED:3340076543,MIDNIGHTBLUE:421097727,MINTCREAM:4127193855,MISTYROSE:4293190143,MOCCASIN:4293178879,NAVAJOWHITE:4292783615,NAVY:33023,OLDLACE:4260751103,OLIVE:2155872511,OLIVEDRAB:1804477439,ORANGE:4289003775,ORANGERED:4282712319,ORCHID:3664828159,PALEGOLDENROD:4008225535,PALEGREEN:2566625535,PALETURQUOISE:2951671551,PALEVIOLETRED:3681588223,PAPAYAWHIP:4293907967,PEACHPUFF:4292524543,PERU:3448061951,PINK:4290825215,PLUM:3718307327,POWDERBLUE:2967529215,PURPLE:2147516671,REBECCAPURPLE:1714657791,RED:4278190335,ROSYBROWN:3163525119,ROYALBLUE:1097458175,SADDLEBROWN:2336560127,SALMON:4202722047,SANDYBROWN:4104413439,SEAGREEN:780883967,SEASHELL:4294307583,SIENNA:2689740287,SILVER:3233857791,SKYBLUE:2278484991,SLATEBLUE:1784335871,SLATEGRAY:1887473919,SLATEGREY:1887473919,SNOW:4294638335,SPRINGGREEN:16744447,STEELBLUE:1182971135,TAN:3535047935,TEAL:8421631,THISTLE:3636451583,TOMATO:4284696575,TRANSPARENT:0,TURQUOISE:1088475391,VIOLET:4001558271,WHEAT:4125012991,WHITE:4294967295,WHITESMOKE:4126537215,YELLOW:4294902015,YELLOWGREEN:2597139199},f_={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(p,f){return f.map(function(x){if(Lt(x))switch(x.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},g_={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Bl=function(p,f){var x=Sa.parse(p,f[0]),v=f[1];return v&&yi(v)?{color:x,stop:v}:{color:x,stop:null}},qp=function(p,f){var x=p[0],v=p[p.length-1];x.stop===null&&(x.stop=ki),v.stop===null&&(v.stop=Fa);for(var C=[],S=0,L=0;L<p.length;L++){var R=p[L].stop;if(R!==null){var H=Ot(R,f);H>S?C.push(H):C.push(S),S=H}else C.push(null)}for(var j=null,L=0;L<C.length;L++){var Z=C[L];if(Z===null)j===null&&(j=L);else if(j!==null){for(var ee=L-j,oe=C[j-1],_e=(Z-oe)/(ee+1),me=1;me<=ee;me++)C[j+me-1]=_e*me;j=null}}return p.map(function(xe,Je){var Ee=xe.color;return{color:Ee,stop:Math.max(Math.min(1,C[Je]/f),0)}})},p_=function(p,f,x){var v=f/2,C=x/2,S=Ot(p[0],f)-v,L=C-Ot(p[1],x);return(Math.atan2(L,S)+Math.PI*2)%(Math.PI*2)},m_=function(p,f,x){var v=typeof p=="number"?p:p_(p,f,x),C=Math.abs(f*Math.sin(v))+Math.abs(x*Math.cos(v)),S=f/2,L=x/2,R=C/2,H=Math.sin(v-Math.PI/2)*R,j=Math.cos(v-Math.PI/2)*R;return[C,S-j,S+j,L-H,L+H]},sr=function(p,f){return Math.sqrt(p*p+f*f)},Jp=function(p,f,x,v,C){var S=[[0,0],[0,f],[p,0],[p,f]];return S.reduce(function(L,R){var H=R[0],j=R[1],Z=sr(x-H,v-j);return(C?Z<L.optimumDistance:Z>L.optimumDistance)?{optimumCorner:R,optimumDistance:Z}:L},{optimumDistance:C?1/0:-1/0,optimumCorner:null}).optimumCorner},y_=function(p,f,x,v,C){var S=0,L=0;switch(p.size){case 0:p.shape===0?S=L=Math.min(Math.abs(f),Math.abs(f-v),Math.abs(x),Math.abs(x-C)):p.shape===1&&(S=Math.min(Math.abs(f),Math.abs(f-v)),L=Math.min(Math.abs(x),Math.abs(x-C)));break;case 2:if(p.shape===0)S=L=Math.min(sr(f,x),sr(f,x-C),sr(f-v,x),sr(f-v,x-C));else if(p.shape===1){var R=Math.min(Math.abs(x),Math.abs(x-C))/Math.min(Math.abs(f),Math.abs(f-v)),H=Jp(v,C,f,x,!0),j=H[0],Z=H[1];S=sr(j-f,(Z-x)/R),L=R*S}break;case 1:p.shape===0?S=L=Math.max(Math.abs(f),Math.abs(f-v),Math.abs(x),Math.abs(x-C)):p.shape===1&&(S=Math.max(Math.abs(f),Math.abs(f-v)),L=Math.max(Math.abs(x),Math.abs(x-C)));break;case 3:if(p.shape===0)S=L=Math.max(sr(f,x),sr(f,x-C),sr(f-v,x),sr(f-v,x-C));else if(p.shape===1){var R=Math.max(Math.abs(x),Math.abs(x-C))/Math.max(Math.abs(f),Math.abs(f-v)),ee=Jp(v,C,f,x,!1),j=ee[0],Z=ee[1];S=sr(j-f,(Z-x)/R),L=R*S}break}return Array.isArray(p.size)&&(S=Ot(p.size[0],v),L=p.size.length===2?Ot(p.size[1],C):S),[S,L]},v_=function(p,f){var x=Ms(180),v=[];return _r(f).forEach(function(C,S){if(S===0){var L=C[0];if(L.type===20&&L.value==="to"){x=zp(C);return}else if(Wp(L)){x=bl.parse(p,L);return}}var R=Bl(p,C);v.push(R)}),{angle:x,stops:v,type:1}},wl=function(p,f){var x=Ms(180),v=[];return _r(f).forEach(function(C,S){if(S===0){var L=C[0];if(L.type===20&&["top","left","right","bottom"].indexOf(L.value)!==-1){x=zp(C);return}else if(Wp(L)){x=(bl.parse(p,L)+Ms(270))%Ms(360);return}}var R=Bl(p,C);v.push(R)}),{angle:x,stops:v,type:1}},x_=function(p,f){var x=Ms(180),v=[],C=1,S=0,L=3,R=[];return _r(f).forEach(function(H,j){var Z=H[0];if(j===0){if(Lt(Z)&&Z.value==="linear"){C=1;return}else if(Lt(Z)&&Z.value==="radial"){C=2;return}}if(Z.type===18){if(Z.name==="from"){var ee=Sa.parse(p,Z.values[0]);v.push({stop:ki,color:ee})}else if(Z.name==="to"){var ee=Sa.parse(p,Z.values[0]);v.push({stop:Fa,color:ee})}else if(Z.name==="color-stop"){var oe=Z.values.filter(tA);if(oe.length===2){var ee=Sa.parse(p,oe[1]),_e=oe[0];eA(_e)&&v.push({stop:{type:16,number:_e.number*100,flags:_e.flags},color:ee})}}}}),C===1?{angle:(x+Ms(180))%Ms(360),stops:v,type:C}:{size:L,shape:S,stops:v,position:R,type:C}},em="closest-side",tm="farthest-side",im="closest-corner",sm="farthest-corner",rm="circle",am="ellipse",nm="cover",Am="contain",b_=function(p,f){var x=0,v=3,C=[],S=[];return _r(f).forEach(function(L,R){var H=!0;if(R===0){var j=!1;H=L.reduce(function(ee,oe){if(j)if(Lt(oe))switch(oe.value){case"center":return S.push(Jc),ee;case"top":case"left":return S.push(ki),ee;case"right":case"bottom":return S.push(Fa),ee}else(yi(oe)||_a(oe))&&S.push(oe);else if(Lt(oe))switch(oe.value){case rm:return x=0,!1;case am:return x=1,!1;case"at":return j=!0,!1;case em:return v=0,!1;case nm:case tm:return v=1,!1;case Am:case im:return v=2,!1;case sm:return v=3,!1}else if(_a(oe)||yi(oe))return Array.isArray(v)||(v=[]),v.push(oe),!1;return ee},H)}if(H){var Z=Bl(p,L);C.push(Z)}}),{size:v,shape:x,stops:C,position:S,type:2}},Cl=function(p,f){var x=0,v=3,C=[],S=[];return _r(f).forEach(function(L,R){var H=!0;if(R===0?H=L.reduce(function(Z,ee){if(Lt(ee))switch(ee.value){case"center":return S.push(Jc),!1;case"top":case"left":return S.push(ki),!1;case"right":case"bottom":return S.push(Fa),!1}else if(yi(ee)||_a(ee))return S.push(ee),!1;return Z},H):R===1&&(H=L.reduce(function(Z,ee){if(Lt(ee))switch(ee.value){case rm:return x=0,!1;case am:return x=1,!1;case Am:case em:return v=0,!1;case tm:return v=1,!1;case im:return v=2,!1;case nm:case sm:return v=3,!1}else if(_a(ee)||yi(ee))return Array.isArray(v)||(v=[]),v.push(ee),!1;return Z},H)),H){var j=Bl(p,L);C.push(j)}}),{size:v,shape:x,stops:C,position:S,type:2}},B_=function(p){return p.type===1},w_=function(p){return p.type===2},td={name:"image",parse:function(p,f){if(f.type===22){var x={url:f.value,type:0};return p.cache.addImage(f.value),x}if(f.type===18){var v=om[f.name];if(typeof v>"u")throw new Error('Attempting to parse an unsupported image function "'+f.name+'"');return v(p,f.values)}throw new Error("Unsupported image type "+f.type)}};function C_(p){return!(p.type===20&&p.value==="none")&&(p.type!==18||!!om[p.name])}var om={"linear-gradient":v_,"-moz-linear-gradient":wl,"-ms-linear-gradient":wl,"-o-linear-gradient":wl,"-webkit-linear-gradient":wl,"radial-gradient":b_,"-moz-radial-gradient":Cl,"-ms-radial-gradient":Cl,"-o-radial-gradient":Cl,"-webkit-radial-gradient":Cl,"-webkit-gradient":x_},__={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(p,f){if(f.length===0)return[];var x=f[0];return x.type===20&&x.value==="none"?[]:f.filter(function(v){return tA(v)&&C_(v)}).map(function(v){return td.parse(p,v)})}},F_={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(p,f){return f.map(function(x){if(Lt(x))switch(x.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},S_={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(p,f){return _r(f).map(function(x){return x.filter(yi)}).map(Vp)}},T_={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(p,f){return _r(f).map(function(x){return x.filter(Lt).map(function(v){return v.value}).join(" ")}).map(I_)}},I_=function(p){switch(p){case"no-repeat":return 1;case"repeat-x":case"repeat no-repeat":return 2;case"repeat-y":case"no-repeat repeat":return 3;case"repeat":default:return 0}},iA;(function(p){p.AUTO="auto",p.CONTAIN="contain",p.COVER="cover"})(iA||(iA={}));var D_={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(p,f){return _r(f).map(function(x){return x.filter(L_)})}},L_=function(p){return Lt(p)||yi(p)},_l=function(p){return{name:"border-"+p+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},U_=_l("top"),Q_=_l("right"),k_=_l("bottom"),E_=_l("left"),Fl=function(p){return{name:"border-radius-"+p,initialValue:"0 0",prefix:!1,type:1,parse:function(f,x){return Vp(x.filter(yi))}}},P_=Fl("top-left"),M_=Fl("top-right"),H_=Fl("bottom-right"),R_=Fl("bottom-left"),Sl=function(p){return{name:"border-"+p+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(f,x){switch(x){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},O_=Sl("top"),N_=Sl("right"),V_=Sl("bottom"),$_=Sl("left"),Tl=function(p){return{name:"border-"+p+"-width",initialValue:"0",type:0,prefix:!1,parse:function(f,x){return jA(x)?x.number:0}}},K_=Tl("top"),G_=Tl("right"),X_=Tl("bottom"),W_=Tl("left"),z_={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},Y_={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(p,f){switch(f){case"rtl":return 1;case"ltr":default:return 0}}},j_={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(p,f){return f.filter(Lt).reduce(function(x,v){return x|Z_(v.value)},0)}},Z_=function(p){switch(p){case"block":case"-webkit-box":return 2;case"inline":return 4;case"run-in":return 8;case"flow":return 16;case"flow-root":return 32;case"table":return 64;case"flex":case"-webkit-flex":return 128;case"grid":case"-ms-grid":return 256;case"ruby":return 512;case"subgrid":return 1024;case"list-item":return 2048;case"table-row-group":return 4096;case"table-header-group":return 8192;case"table-footer-group":return 16384;case"table-row":return 32768;case"table-cell":return 65536;case"table-column-group":return 131072;case"table-column":return 262144;case"table-caption":return 524288;case"ruby-base":return 1048576;case"ruby-text":return 2097152;case"ruby-base-container":return 4194304;case"ruby-text-container":return 8388608;case"contents":return 16777216;case"inline-block":return 33554432;case"inline-list-item":return 67108864;case"inline-table":return 134217728;case"inline-flex":return 268435456;case"inline-grid":return 536870912}return 0},q_={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(p,f){switch(f){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},J_={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(p,f){return f.type===20&&f.value==="normal"?0:f.type===17||f.type===15?f.number:0}},Il;(function(p){p.NORMAL="normal",p.STRICT="strict"})(Il||(Il={}));var eF={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(p,f){switch(f){case"strict":return Il.STRICT;case"normal":default:return Il.NORMAL}}},tF={name:"line-height",initialValue:"normal",prefix:!1,type:4},lm=function(p,f){return Lt(p)&&p.value==="normal"?1.2*f:p.type===17?f*p.number:yi(p)?Ot(p,f):f},iF={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(p,f){return f.type===20&&f.value==="none"?null:td.parse(p,f)}},sF={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(p,f){switch(f){case"inside":return 0;case"outside":default:return 1}}},id={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(p,f){switch(f){case"disc":return 0;case"circle":return 1;case"square":return 2;case"decimal":return 3;case"cjk-decimal":return 4;case"decimal-leading-zero":return 5;case"lower-roman":return 6;case"upper-roman":return 7;case"lower-greek":return 8;case"lower-alpha":return 9;case"upper-alpha":return 10;case"arabic-indic":return 11;case"armenian":return 12;case"bengali":return 13;case"cambodian":return 14;case"cjk-earthly-branch":return 15;case"cjk-heavenly-stem":return 16;case"cjk-ideographic":return 17;case"devanagari":return 18;case"ethiopic-numeric":return 19;case"georgian":return 20;case"gujarati":return 21;case"gurmukhi":return 22;case"hebrew":return 22;case"hiragana":return 23;case"hiragana-iroha":return 24;case"japanese-formal":return 25;case"japanese-informal":return 26;case"kannada":return 27;case"katakana":return 28;case"katakana-iroha":return 29;case"khmer":return 30;case"korean-hangul-formal":return 31;case"korean-hanja-formal":return 32;case"korean-hanja-informal":return 33;case"lao":return 34;case"lower-armenian":return 35;case"malayalam":return 36;case"mongolian":return 37;case"myanmar":return 38;case"oriya":return 39;case"persian":return 40;case"simp-chinese-formal":return 41;case"simp-chinese-informal":return 42;case"tamil":return 43;case"telugu":return 44;case"thai":return 45;case"tibetan":return 46;case"trad-chinese-formal":return 47;case"trad-chinese-informal":return 48;case"upper-armenian":return 49;case"disclosure-open":return 50;case"disclosure-closed":return 51;case"none":default:return-1}}},Dl=function(p){return{name:"margin-"+p,initialValue:"0",prefix:!1,type:4}},rF=Dl("top"),aF=Dl("right"),nF=Dl("bottom"),AF=Dl("left"),oF={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(p,f){return f.filter(Lt).map(function(x){switch(x.value){case"hidden":return 1;case"scroll":return 2;case"clip":return 3;case"auto":return 4;case"visible":default:return 0}})}},lF={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(p,f){switch(f){case"break-word":return"break-word";case"normal":default:return"normal"}}},Ll=function(p){return{name:"padding-"+p,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},hF=Ll("top"),cF=Ll("right"),dF=Ll("bottom"),uF=Ll("left"),fF={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(p,f){switch(f){case"right":return 2;case"center":case"justify":return 1;case"left":default:return 0}}},gF={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(p,f){switch(f){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},pF={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(p,f){return f.length===1&&qc(f[0],"none")?[]:_r(f).map(function(x){for(var v={color:ea.TRANSPARENT,offsetX:ki,offsetY:ki,blur:ki},C=0,S=0;S<x.length;S++){var L=x[S];_a(L)?(C===0?v.offsetX=L:C===1?v.offsetY=L:v.blur=L,C++):v.color=Sa.parse(p,L)}return v})}},mF={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(p,f){switch(f){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},yF={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(p,f){if(f.type===20&&f.value==="none")return null;if(f.type===18){var x=bF[f.name];if(typeof x>"u")throw new Error('Attempting to parse an unsupported transform function "'+f.name+'"');return x(f.values)}return null}},vF=function(p){var f=p.filter(function(x){return x.type===17}).map(function(x){return x.number});return f.length===6?f:null},xF=function(p){var f=p.filter(function(H){return H.type===17}).map(function(H){return H.number}),x=f[0],v=f[1];f[2],f[3];var C=f[4],S=f[5];f[6],f[7],f[8],f[9],f[10],f[11];var L=f[12],R=f[13];return f[14],f[15],f.length===16?[x,v,C,S,L,R]:null},bF={matrix:vF,matrix3d:xF},hm={type:16,number:50,flags:GA},BF=[hm,hm],wF={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(p,f){var x=f.filter(yi);return x.length!==2?BF:[x[0],x[1]]}},CF={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(p,f){switch(f){case"hidden":return 1;case"collapse":return 2;case"visible":default:return 0}}},JA;(function(p){p.NORMAL="normal",p.BREAK_ALL="break-all",p.KEEP_ALL="keep-all"})(JA||(JA={}));for(var _F={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(p,f){switch(f){case"break-all":return JA.BREAK_ALL;case"keep-all":return JA.KEEP_ALL;case"normal":default:return JA.NORMAL}}},FF={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(p,f){if(f.type===20)return{auto:!0,order:0};if(eA(f))return{auto:!1,order:f.number};throw new Error("Invalid z-index number parsed")}},cm={name:"time",parse:function(p,f){if(f.type===15)switch(f.unit.toLowerCase()){case"s":return 1e3*f.number;case"ms":return f.number}throw new Error("Unsupported time type")}},SF={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(p,f){return eA(f)?f.number:1}},TF={name:"text-decoration-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},IF={name:"text-decoration-line",initialValue:"none",prefix:!1,type:1,parse:function(p,f){return f.filter(Lt).map(function(x){switch(x.value){case"underline":return 1;case"overline":return 2;case"line-through":return 3;case"none":return 4}return 0}).filter(function(x){return x!==0})}},DF={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(p,f){var x=[],v=[];return f.forEach(function(C){switch(C.type){case 20:case 0:x.push(C.value);break;case 17:x.push(C.number.toString());break;case 4:v.push(x.join(" ")),x.length=0;break}}),x.length&&v.push(x.join(" ")),v.map(function(C){return C.indexOf(" ")===-1?C:"'"+C+"'"})}},LF={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},UF={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(p,f){if(eA(f))return f.number;if(Lt(f))switch(f.value){case"bold":return 700;case"normal":default:return 400}return 400}},QF={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(p,f){return f.filter(Lt).map(function(x){return x.value})}},kF={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(p,f){switch(f){case"oblique":return"oblique";case"italic":return"italic";case"normal":default:return"normal"}}},wi=function(p,f){return(p&f)!==0},EF={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(p,f){if(f.length===0)return[];var x=f[0];return x.type===20&&x.value==="none"?[]:f}},PF={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(p,f){if(f.length===0)return null;var x=f[0];if(x.type===20&&x.value==="none")return null;for(var v=[],C=f.filter(Np),S=0;S<C.length;S++){var L=C[S],R=C[S+1];if(L.type===20){var H=R&&eA(R)?R.number:1;v.push({counter:L.value,increment:H})}}return v}},MF={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(p,f){if(f.length===0)return[];for(var x=[],v=f.filter(Np),C=0;C<v.length;C++){var S=v[C],L=v[C+1];if(Lt(S)&&S.value!=="none"){var R=L&&eA(L)?L.number:0;x.push({counter:S.value,reset:R})}}return x}},HF={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(p,f){return f.filter(jA).map(function(x){return cm.parse(p,x)})}},RF={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(p,f){if(f.length===0)return null;var x=f[0];if(x.type===20&&x.value==="none")return null;var v=[],C=f.filter(c_);if(C.length%2!==0)return null;for(var S=0;S<C.length;S+=2){var L=C[S].value,R=C[S+1].value;v.push({open:L,close:R})}return v}},dm=function(p,f,x){if(!p)return"";var v=p[Math.min(f,p.length-1)];return v?x?v.open:v.close:""},OF={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(p,f){return f.length===1&&qc(f[0],"none")?[]:_r(f).map(function(x){for(var v={color:255,offsetX:ki,offsetY:ki,blur:ki,spread:ki,inset:!1},C=0,S=0;S<x.length;S++){var L=x[S];qc(L,"inset")?v.inset=!0:_a(L)?(C===0?v.offsetX=L:C===1?v.offsetY=L:C===2?v.blur=L:v.spread=L,C++):v.color=Sa.parse(p,L)}return v})}},NF={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(p,f){var x=[0,1,2],v=[];return f.filter(Lt).forEach(function(C){switch(C.value){case"stroke":v.push(1);break;case"fill":v.push(0);break;case"markers":v.push(2);break}}),x.forEach(function(C){v.indexOf(C)===-1&&v.push(C)}),v}},VF={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},$F={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(p,f){return jA(f)?f.number:0}},KF=(function(){function p(f,x){var v,C;this.animationDuration=Se(f,HF,x.animationDuration),this.backgroundClip=Se(f,f_,x.backgroundClip),this.backgroundColor=Se(f,g_,x.backgroundColor),this.backgroundImage=Se(f,__,x.backgroundImage),this.backgroundOrigin=Se(f,F_,x.backgroundOrigin),this.backgroundPosition=Se(f,S_,x.backgroundPosition),this.backgroundRepeat=Se(f,T_,x.backgroundRepeat),this.backgroundSize=Se(f,D_,x.backgroundSize),this.borderTopColor=Se(f,U_,x.borderTopColor),this.borderRightColor=Se(f,Q_,x.borderRightColor),this.borderBottomColor=Se(f,k_,x.borderBottomColor),this.borderLeftColor=Se(f,E_,x.borderLeftColor),this.borderTopLeftRadius=Se(f,P_,x.borderTopLeftRadius),this.borderTopRightRadius=Se(f,M_,x.borderTopRightRadius),this.borderBottomRightRadius=Se(f,H_,x.borderBottomRightRadius),this.borderBottomLeftRadius=Se(f,R_,x.borderBottomLeftRadius),this.borderTopStyle=Se(f,O_,x.borderTopStyle),this.borderRightStyle=Se(f,N_,x.borderRightStyle),this.borderBottomStyle=Se(f,V_,x.borderBottomStyle),this.borderLeftStyle=Se(f,$_,x.borderLeftStyle),this.borderTopWidth=Se(f,K_,x.borderTopWidth),this.borderRightWidth=Se(f,G_,x.borderRightWidth),this.borderBottomWidth=Se(f,X_,x.borderBottomWidth),this.borderLeftWidth=Se(f,W_,x.borderLeftWidth),this.boxShadow=Se(f,OF,x.boxShadow),this.color=Se(f,z_,x.color),this.direction=Se(f,Y_,x.direction),this.display=Se(f,j_,x.display),this.float=Se(f,q_,x.cssFloat),this.fontFamily=Se(f,DF,x.fontFamily),this.fontSize=Se(f,LF,x.fontSize),this.fontStyle=Se(f,kF,x.fontStyle),this.fontVariant=Se(f,QF,x.fontVariant),this.fontWeight=Se(f,UF,x.fontWeight),this.letterSpacing=Se(f,J_,x.letterSpacing),this.lineBreak=Se(f,eF,x.lineBreak),this.lineHeight=Se(f,tF,x.lineHeight),this.listStyleImage=Se(f,iF,x.listStyleImage),this.listStylePosition=Se(f,sF,x.listStylePosition),this.listStyleType=Se(f,id,x.listStyleType),this.marginTop=Se(f,rF,x.marginTop),this.marginRight=Se(f,aF,x.marginRight),this.marginBottom=Se(f,nF,x.marginBottom),this.marginLeft=Se(f,AF,x.marginLeft),this.opacity=Se(f,SF,x.opacity);var S=Se(f,oF,x.overflow);this.overflowX=S[0],this.overflowY=S[S.length>1?1:0],this.overflowWrap=Se(f,lF,x.overflowWrap),this.paddingTop=Se(f,hF,x.paddingTop),this.paddingRight=Se(f,cF,x.paddingRight),this.paddingBottom=Se(f,dF,x.paddingBottom),this.paddingLeft=Se(f,uF,x.paddingLeft),this.paintOrder=Se(f,NF,x.paintOrder),this.position=Se(f,gF,x.position),this.textAlign=Se(f,fF,x.textAlign),this.textDecorationColor=Se(f,TF,(v=x.textDecorationColor)!==null&&v!==void 0?v:x.color),this.textDecorationLine=Se(f,IF,(C=x.textDecorationLine)!==null&&C!==void 0?C:x.textDecoration),this.textShadow=Se(f,pF,x.textShadow),this.textTransform=Se(f,mF,x.textTransform),this.transform=Se(f,yF,x.transform),this.transformOrigin=Se(f,wF,x.transformOrigin),this.visibility=Se(f,CF,x.visibility),this.webkitTextStrokeColor=Se(f,VF,x.webkitTextStrokeColor),this.webkitTextStrokeWidth=Se(f,$F,x.webkitTextStrokeWidth),this.wordBreak=Se(f,_F,x.wordBreak),this.zIndex=Se(f,FF,x.zIndex)}return p.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&this.visibility===0},p.prototype.isTransparent=function(){return Ta(this.backgroundColor)},p.prototype.isTransformed=function(){return this.transform!==null},p.prototype.isPositioned=function(){return this.position!==0},p.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},p.prototype.isFloating=function(){return this.float!==0},p.prototype.isInlineLevel=function(){return wi(this.display,4)||wi(this.display,33554432)||wi(this.display,268435456)||wi(this.display,536870912)||wi(this.display,67108864)||wi(this.display,134217728)},p})(),GF=(function(){function p(f,x){this.content=Se(f,EF,x.content),this.quotes=Se(f,RF,x.quotes)}return p})(),um=(function(){function p(f,x){this.counterIncrement=Se(f,PF,x.counterIncrement),this.counterReset=Se(f,MF,x.counterReset)}return p})(),Se=function(p,f,x){var v=new Rp,C=x!==null&&typeof x<"u"?x.toString():f.initialValue;v.write(C);var S=new Op(v.read());switch(f.type){case 2:var L=S.parseComponentValue();return f.parse(p,Lt(L)?L.value:f.initialValue);case 0:return f.parse(p,S.parseComponentValue());case 1:return f.parse(p,S.parseComponentValues());case 4:return S.parseComponentValue();case 3:switch(f.format){case"angle":return bl.parse(p,S.parseComponentValue());case"color":return Sa.parse(p,S.parseComponentValue());case"image":return td.parse(p,S.parseComponentValue());case"length":var R=S.parseComponentValue();return _a(R)?R:ki;case"length-percentage":var H=S.parseComponentValue();return yi(H)?H:ki;case"time":return cm.parse(p,S.parseComponentValue())}break}},XF="data-html2canvas-debug",WF=function(p){var f=p.getAttribute(XF);switch(f){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}},sd=function(p,f){var x=WF(p);return x===1||f===x},Fr=(function(){function p(f,x){if(this.context=f,this.textNodes=[],this.elements=[],this.flags=0,sd(x,3))debugger;this.styles=new KF(f,window.getComputedStyle(x,null)),md(x)&&(this.styles.animationDuration.some(function(v){return v>0})&&(x.style.animationDuration="0s"),this.styles.transform!==null&&(x.style.transform="none")),this.bounds=A(this.context,x),sd(x,4)&&(this.flags|=16)}return p})(),zF="AAAAAAAAAAAAEA4AGBkAAFAaAAACAAAAAAAIABAAGAAwADgACAAQAAgAEAAIABAACAAQAAgAEAAIABAACAAQAAgAEAAIABAAQABIAEQATAAIABAACAAQAAgAEAAIABAAVABcAAgAEAAIABAACAAQAGAAaABwAHgAgACIAI4AlgAIABAAmwCjAKgAsAC2AL4AvQDFAMoA0gBPAVYBWgEIAAgACACMANoAYgFkAWwBdAF8AX0BhQGNAZUBlgGeAaMBlQGWAasBswF8AbsBwwF0AcsBYwHTAQgA2wG/AOMBdAF8AekB8QF0AfkB+wHiAHQBfAEIAAMC5gQIAAsCEgIIAAgAFgIeAggAIgIpAggAMQI5AkACygEIAAgASAJQAlgCYAIIAAgACAAKBQoFCgUTBRMFGQUrBSsFCAAIAAgACAAIAAgACAAIAAgACABdAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABoAmgCrwGvAQgAbgJ2AggAHgEIAAgACADnAXsCCAAIAAgAgwIIAAgACAAIAAgACACKAggAkQKZAggAPADJAAgAoQKkAqwCsgK6AsICCADJAggA0AIIAAgACAAIANYC3gIIAAgACAAIAAgACABAAOYCCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAkASoB+QIEAAgACAA8AEMCCABCBQgACABJBVAFCAAIAAgACAAIAAgACAAIAAgACABTBVoFCAAIAFoFCABfBWUFCAAIAAgACAAIAAgAbQUIAAgACAAIAAgACABzBXsFfQWFBYoFigWKBZEFigWKBYoFmAWfBaYFrgWxBbkFCAAIAAgACAAIAAgACAAIAAgACAAIAMEFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAMgFCADQBQgACAAIAAgACAAIAAgACAAIAAgACAAIAO4CCAAIAAgAiQAIAAgACABAAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAD0AggACAD8AggACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIANYFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAMDvwAIAAgAJAIIAAgACAAIAAgACAAIAAgACwMTAwgACAB9BOsEGwMjAwgAKwMyAwsFYgE3A/MEPwMIAEUDTQNRAwgAWQOsAGEDCAAIAAgACAAIAAgACABpAzQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFIQUoBSwFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABtAwgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABMAEwACAAIAAgACAAIABgACAAIAAgACAC/AAgACAAyAQgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACAAIAAwAAgACAAIAAgACAAIAAgACAAIAAAARABIAAgACAAIABQASAAIAAgAIABwAEAAjgCIABsAqAC2AL0AigDQAtwC+IJIQqVAZUBWQqVAZUBlQGVAZUBlQGrC5UBlQGVAZUBlQGVAZUBlQGVAXsKlQGVAbAK6wsrDGUMpQzlDJUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAfAKAAuZA64AtwCJALoC6ADwAAgAuACgA/oEpgO6AqsD+AAIAAgAswMIAAgACAAIAIkAuwP5AfsBwwPLAwgACAAIAAgACADRA9kDCAAIAOED6QMIAAgACAAIAAgACADuA/YDCAAIAP4DyQAIAAgABgQIAAgAXQAOBAgACAAIAAgACAAIABMECAAIAAgACAAIAAgACAD8AAQBCAAIAAgAGgQiBCoECAExBAgAEAEIAAgACAAIAAgACAAIAAgACAAIAAgACAA4BAgACABABEYECAAIAAgATAQYAQgAVAQIAAgACAAIAAgACAAIAAgACAAIAFoECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAOQEIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAB+BAcACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAEABhgSMBAgACAAIAAgAlAQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAwAEAAQABAADAAMAAwADAAQABAAEAAQABAAEAAQABHATAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAdQMIAAgACAAIAAgACAAIAMkACAAIAAgAfQMIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACFA4kDCAAIAAgACAAIAOcBCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAIcDCAAIAAgACAAIAAgACAAIAAgACAAIAJEDCAAIAAgACADFAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABgBAgAZgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAbAQCBXIECAAIAHkECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABAAJwEQACjBKoEsgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAC6BMIECAAIAAgACAAIAAgACABmBAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAxwQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAGYECAAIAAgAzgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBd0FXwUIAOIF6gXxBYoF3gT5BQAGCAaKBYoFigWKBYoFigWKBYoFigWKBYoFigXWBIoFigWKBYoFigWKBYoFigWKBYsFEAaKBYoFigWKBYoFigWKBRQGCACKBYoFigWKBQgACAAIANEECAAIABgGigUgBggAJgYIAC4GMwaKBYoF0wQ3Bj4GigWKBYoFigWKBYoFigWKBYoFigWKBYoFigUIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWLBf///////wQABAAEAAQABAAEAAQABAAEAAQAAwAEAAQAAgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAQADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUAAAAFAAUAAAAFAAUAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAQAAAAUABQAFAAUABQAFAAAAAAAFAAUAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAFAAUAAQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAAABwAHAAcAAAAHAAcABwAFAAEAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAcABwAFAAUAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAAAAQABAAAAAAAAAAAAAAAFAAUABQAFAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAHAAcAAAAHAAcAAAAAAAUABQAHAAUAAQAHAAEABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwABAAUABQAFAAUAAAAAAAAAAAAAAAEAAQABAAEAAQABAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABQANAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAABQAHAAUABQAFAAAAAAAAAAcABQAFAAUABQAFAAQABAAEAAQABAAEAAQABAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUAAAAFAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAUAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAcABwAFAAcABwAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUABwAHAAUABQAFAAUAAAAAAAcABwAAAAAABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAAAAAAAAAAABQAFAAAAAAAFAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAFAAUABQAFAAUAAAAFAAUABwAAAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABwAFAAUABQAFAAAAAAAHAAcAAAAAAAcABwAFAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAAAAAAAAAHAAcABwAAAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAUABQAFAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAHAAcABQAHAAcAAAAFAAcABwAAAAcABwAFAAUAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAFAAcABwAFAAUABQAAAAUAAAAHAAcABwAHAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAHAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUAAAAFAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAUAAAAFAAUAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABwAFAAUABQAFAAUABQAAAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABQAFAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAFAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAHAAUABQAFAAUABQAFAAUABwAHAAcABwAHAAcABwAHAAUABwAHAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABwAHAAcABwAFAAUABwAHAAcAAAAAAAAAAAAHAAcABQAHAAcABwAHAAcABwAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAUABQAFAAUABQAFAAUAAAAFAAAABQAAAAAABQAFAAUABQAFAAUABQAFAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAUABQAFAAUABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABwAFAAcABwAHAAcABwAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAUABQAFAAUABwAHAAUABQAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABQAFAAcABwAHAAUABwAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAcABQAFAAUABQAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAAAAAABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAAAAAAAAAFAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAUABQAHAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAFAAUABQAFAAcABwAFAAUABwAHAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAcABwAFAAUABwAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABQAAAAAABQAFAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAcABwAAAAAAAAAAAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAcABwAFAAcABwAAAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAFAAUABQAAAAUABQAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABwAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAHAAcABQAHAAUABQAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAAABwAHAAAAAAAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAFAAUABwAFAAcABwAFAAcABQAFAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAAAAAABwAHAAcABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAFAAcABwAFAAUABQAFAAUABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAUABQAFAAcABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABQAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAAAAAAFAAUABwAHAAcABwAFAAAAAAAAAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAHAAUABQAFAAUABQAFAAUABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAABQAAAAUABQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAHAAcAAAAFAAUAAAAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABQAFAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAABQAFAAUABQAFAAUABQAAAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAFAAUABQAFAAUADgAOAA4ADgAOAA4ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAMAAwADAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkAAAAAAAAAAAAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAAAAAAAAAAAAsADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwACwAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAADgAOAA4AAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAAAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4AAAAOAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAAAAAAAAAAAA4AAAAOAAAAAAAAAAAADgAOAA4AAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAA=",fm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",eo=typeof Uint8Array>"u"?[]:new Uint8Array(256),Ul=0;Ul<fm.length;Ul++)eo[fm.charCodeAt(Ul)]=Ul;for(var YF=function(p){var f=p.length*.75,x=p.length,v,C=0,S,L,R,H;p[p.length-1]==="="&&(f--,p[p.length-2]==="="&&f--);var j=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u"&&typeof Uint8Array.prototype.slice<"u"?new ArrayBuffer(f):new Array(f),Z=Array.isArray(j)?j:new Uint8Array(j);for(v=0;v<x;v+=4)S=eo[p.charCodeAt(v)],L=eo[p.charCodeAt(v+1)],R=eo[p.charCodeAt(v+2)],H=eo[p.charCodeAt(v+3)],Z[C++]=S<<2|L>>4,Z[C++]=(L&15)<<4|R>>2,Z[C++]=(R&3)<<6|H&63;return j},jF=function(p){for(var f=p.length,x=[],v=0;v<f;v+=2)x.push(p[v+1]<<8|p[v]);return x},ZF=function(p){for(var f=p.length,x=[],v=0;v<f;v+=4)x.push(p[v+3]<<24|p[v+2]<<16|p[v+1]<<8|p[v]);return x},gn=5,rd=11,ad=2,qF=rd-gn,gm=65536>>gn,JF=1<<gn,nd=JF-1,eS=1024>>gn,tS=gm+eS,iS=tS,sS=32,rS=iS+sS,aS=65536>>rd,nS=1<<qF,AS=nS-1,pm=function(p,f,x){return p.slice?p.slice(f,x):new Uint16Array(Array.prototype.slice.call(p,f,x))},oS=function(p,f,x){return p.slice?p.slice(f,x):new Uint32Array(Array.prototype.slice.call(p,f,x))},lS=function(p,f){var x=YF(p),v=Array.isArray(x)?ZF(x):new Uint32Array(x),C=Array.isArray(x)?jF(x):new Uint16Array(x),S=24,L=pm(C,S/2,v[4]/2),R=v[5]===2?pm(C,(S+v[4])/2):oS(v,Math.ceil((S+v[4])/4));return new hS(v[0],v[1],v[2],v[3],L,R)},hS=(function(){function p(f,x,v,C,S,L){this.initialValue=f,this.errorValue=x,this.highStart=v,this.highValueIndex=C,this.index=S,this.data=L}return p.prototype.get=function(f){var x;if(f>=0){if(f<55296||f>56319&&f<=65535)return x=this.index[f>>gn],x=(x<<ad)+(f&nd),this.data[x];if(f<=65535)return x=this.index[gm+(f-55296>>gn)],x=(x<<ad)+(f&nd),this.data[x];if(f<this.highStart)return x=rS-aS+(f>>rd),x=this.index[x],x+=f>>gn&AS,x=this.index[x],x=(x<<ad)+(f&nd),this.data[x];if(f<=1114111)return this.data[this.highValueIndex]}return this.errorValue},p})(),mm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",cS=typeof Uint8Array>"u"?[]:new Uint8Array(256),Ql=0;Ql<mm.length;Ql++)cS[mm.charCodeAt(Ql)]=Ql;var dS=1,Ad=2,od=3,ym=4,vm=5,uS=7,xm=8,ld=9,hd=10,bm=11,Bm=12,wm=13,Cm=14,cd=15,fS=function(p){for(var f=[],x=0,v=p.length;x<v;){var C=p.charCodeAt(x++);if(C>=55296&&C<=56319&&x<v){var S=p.charCodeAt(x++);(S&64512)===56320?f.push(((C&1023)<<10)+(S&1023)+65536):(f.push(C),x--)}else f.push(C)}return f},gS=function(){for(var p=[],f=0;f<arguments.length;f++)p[f]=arguments[f];if(String.fromCodePoint)return String.fromCodePoint.apply(String,p);var x=p.length;if(!x)return"";for(var v=[],C=-1,S="";++C<x;){var L=p[C];L<=65535?v.push(L):(L-=65536,v.push((L>>10)+55296,L%1024+56320)),(C+1===x||v.length>16384)&&(S+=String.fromCharCode.apply(String,v),v.length=0)}return S},pS=lS(zF),Hs="\xD7",dd="\xF7",mS=function(p){return pS.get(p)},yS=function(p,f,x){var v=x-2,C=f[v],S=f[x-1],L=f[x];if(S===Ad&&L===od)return Hs;if(S===Ad||S===od||S===ym||L===Ad||L===od||L===ym)return dd;if(S===xm&&[xm,ld,bm,Bm].indexOf(L)!==-1||(S===bm||S===ld)&&(L===ld||L===hd)||(S===Bm||S===hd)&&L===hd||L===wm||L===vm||L===uS||S===dS)return Hs;if(S===wm&&L===Cm){for(;C===vm;)C=f[--v];if(C===Cm)return Hs}if(S===cd&&L===cd){for(var R=0;C===cd;)R++,C=f[--v];if(R%2===0)return Hs}return dd},vS=function(p){var f=fS(p),x=f.length,v=0,C=0,S=f.map(mS);return{next:function(){if(v>=x)return{done:!0,value:null};for(var L=Hs;v<x&&(L=yS(f,S,++v))===Hs;);if(L!==Hs||v===x){var R=gS.apply(null,f.slice(C,v));return C=v,{value:R,done:!1}}return{done:!0,value:null}}}},xS=function(p){for(var f=vS(p),x=[],v;!(v=f.next()).done;)v.value&&x.push(v.value.slice());return x},bS=function(p){var f=123;if(p.createRange){var x=p.createRange();if(x.getBoundingClientRect){var v=p.createElement("boundtest");v.style.height=f+"px",v.style.display="block",p.body.appendChild(v),x.selectNode(v);var C=x.getBoundingClientRect(),S=Math.round(C.height);if(p.body.removeChild(v),S===f)return!0}}return!1},BS=function(p){var f=p.createElement("boundtest");f.style.width="50px",f.style.display="block",f.style.fontSize="12px",f.style.letterSpacing="0px",f.style.wordSpacing="0px",p.body.appendChild(f);var x=p.createRange();f.innerHTML=typeof"".repeat=="function"?"&#128104;".repeat(10):"";var v=f.firstChild,C=l(v.data).map(function(H){return c(H)}),S=0,L={},R=C.every(function(H,j){x.setStart(v,S),x.setEnd(v,S+H.length);var Z=x.getBoundingClientRect();S+=H.length;var ee=Z.x>L.x||Z.y>L.y;return L=Z,j===0?!0:ee});return p.body.removeChild(f),R},wS=function(){return typeof new Image().crossOrigin<"u"},CS=function(){return typeof new XMLHttpRequest().responseType=="string"},_S=function(p){var f=new Image,x=p.createElement("canvas"),v=x.getContext("2d");if(!v)return!1;f.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{v.drawImage(f,0,0),x.toDataURL()}catch{return!1}return!0},_m=function(p){return p[0]===0&&p[1]===255&&p[2]===0&&p[3]===255},FS=function(p){var f=p.createElement("canvas"),x=100;f.width=x,f.height=x;var v=f.getContext("2d");if(!v)return Promise.reject(!1);v.fillStyle="rgb(0, 255, 0)",v.fillRect(0,0,x,x);var C=new Image,S=f.toDataURL();C.src=S;var L=ud(x,x,0,0,C);return v.fillStyle="red",v.fillRect(0,0,x,x),Fm(L).then(function(R){v.drawImage(R,0,0);var H=v.getImageData(0,0,x,x).data;v.fillStyle="red",v.fillRect(0,0,x,x);var j=p.createElement("div");return j.style.backgroundImage="url("+S+")",j.style.height=x+"px",_m(H)?Fm(ud(x,x,0,0,j)):Promise.reject(!1)}).then(function(R){return v.drawImage(R,0,0),_m(v.getImageData(0,0,x,x).data)}).catch(function(){return!1})},ud=function(p,f,x,v,C){var S="http://www.w3.org/2000/svg",L=document.createElementNS(S,"svg"),R=document.createElementNS(S,"foreignObject");return L.setAttributeNS(null,"width",p.toString()),L.setAttributeNS(null,"height",f.toString()),R.setAttributeNS(null,"width","100%"),R.setAttributeNS(null,"height","100%"),R.setAttributeNS(null,"x",x.toString()),R.setAttributeNS(null,"y",v.toString()),R.setAttributeNS(null,"externalResourcesRequired","true"),L.appendChild(R),R.appendChild(C),L},Fm=function(p){return new Promise(function(f,x){var v=new Image;v.onload=function(){return f(v)},v.onerror=x,v.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(p))})},Ei={get SUPPORT_RANGE_BOUNDS(){var p=bS(document);return Object.defineProperty(Ei,"SUPPORT_RANGE_BOUNDS",{value:p}),p},get SUPPORT_WORD_BREAKING(){var p=Ei.SUPPORT_RANGE_BOUNDS&&BS(document);return Object.defineProperty(Ei,"SUPPORT_WORD_BREAKING",{value:p}),p},get SUPPORT_SVG_DRAWING(){var p=_S(document);return Object.defineProperty(Ei,"SUPPORT_SVG_DRAWING",{value:p}),p},get SUPPORT_FOREIGNOBJECT_DRAWING(){var p=typeof Array.from=="function"&&typeof window.fetch=="function"?FS(document):Promise.resolve(!1);return Object.defineProperty(Ei,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:p}),p},get SUPPORT_CORS_IMAGES(){var p=wS();return Object.defineProperty(Ei,"SUPPORT_CORS_IMAGES",{value:p}),p},get SUPPORT_RESPONSE_TYPE(){var p=CS();return Object.defineProperty(Ei,"SUPPORT_RESPONSE_TYPE",{value:p}),p},get SUPPORT_CORS_XHR(){var p="withCredentials"in new XMLHttpRequest;return Object.defineProperty(Ei,"SUPPORT_CORS_XHR",{value:p}),p},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var p=!!(typeof Intl<"u"&&Intl.Segmenter);return Object.defineProperty(Ei,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:p}),p}},to=(function(){function p(f,x){this.text=f,this.bounds=x}return p})(),SS=function(p,f,x,v){var C=DS(f,x),S=[],L=0;return C.forEach(function(R){if(x.textDecorationLine.length||R.trim().length>0)if(Ei.SUPPORT_RANGE_BOUNDS){var H=Sm(v,L,R.length).getClientRects();if(H.length>1){var j=fd(R),Z=0;j.forEach(function(oe){S.push(new to(oe,n.fromDOMRectList(p,Sm(v,Z+L,oe.length).getClientRects()))),Z+=oe.length})}else S.push(new to(R,n.fromDOMRectList(p,H)))}else{var ee=v.splitText(R.length);S.push(new to(R,TS(p,v))),v=ee}else Ei.SUPPORT_RANGE_BOUNDS||(v=v.splitText(R.length));L+=R.length}),S},TS=function(p,f){var x=f.ownerDocument;if(x){var v=x.createElement("html2canvaswrapper");v.appendChild(f.cloneNode(!0));var C=f.parentNode;if(C){C.replaceChild(v,f);var S=A(p,v);return v.firstChild&&C.replaceChild(v.firstChild,v),S}}return n.EMPTY},Sm=function(p,f,x){var v=p.ownerDocument;if(!v)throw new Error("Node has no owner document");var C=v.createRange();return C.setStart(p,f),C.setEnd(p,f+x),C},fd=function(p){if(Ei.SUPPORT_NATIVE_TEXT_SEGMENTATION){var f=new Intl.Segmenter(void 0,{granularity:"grapheme"});return Array.from(f.segment(p)).map(function(x){return x.segment})}return xS(p)},IS=function(p,f){if(Ei.SUPPORT_NATIVE_TEXT_SEGMENTATION){var x=new Intl.Segmenter(void 0,{granularity:"word"});return Array.from(x.segment(p)).map(function(v){return v.segment})}return US(p,f)},DS=function(p,f){return f.letterSpacing!==0?fd(p):IS(p,f)},LS=[32,160,4961,65792,65793,4153,4241],US=function(p,f){for(var x=aC(p,{lineBreak:f.lineBreak,wordBreak:f.overflowWrap==="break-word"?"break-word":f.wordBreak}),v=[],C,S=function(){if(C.value){var L=C.value.slice(),R=l(L),H="";R.forEach(function(j){LS.indexOf(j)===-1?H+=c(j):(H.length&&v.push(H),v.push(c(j)),H="")}),H.length&&v.push(H)}};!(C=x.next()).done;)S();return v},QS=(function(){function p(f,x,v){this.text=kS(x.data,v.textTransform),this.textBounds=SS(f,this.text,v,x)}return p})(),kS=function(p,f){switch(f){case 1:return p.toLowerCase();case 3:return p.replace(ES,PS);case 2:return p.toUpperCase();default:return p}},ES=/(^|\s|:|-|\(|\))([a-z])/g,PS=function(p,f,x){return p.length>0?f+x.toUpperCase():p},Tm=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.src=v.currentSrc||v.src,C.intrinsicWidth=v.naturalWidth,C.intrinsicHeight=v.naturalHeight,C.context.cache.addImage(C.src),C}return f})(Fr),Im=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.canvas=v,C.intrinsicWidth=v.width,C.intrinsicHeight=v.height,C}return f})(Fr),Dm=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this,S=new XMLSerializer,L=A(x,v);return v.setAttribute("width",L.width+"px"),v.setAttribute("height",L.height+"px"),C.svg="data:image/svg+xml,"+encodeURIComponent(S.serializeToString(v)),C.intrinsicWidth=v.width.baseVal.value,C.intrinsicHeight=v.height.baseVal.value,C.context.cache.addImage(C.svg),C}return f})(Fr),Lm=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.value=v.value,C}return f})(Fr),gd=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.start=v.start,C.reversed=typeof v.reversed=="boolean"&&v.reversed===!0,C}return f})(Fr),MS=[{type:15,flags:0,unit:"px",number:3}],HS=[{type:16,flags:0,number:50}],RS=function(p){return p.width>p.height?new n(p.left+(p.width-p.height)/2,p.top,p.height,p.height):p.width<p.height?new n(p.left,p.top+(p.height-p.width)/2,p.width,p.width):p},OS=function(p){var f=p.type===NS?new Array(p.value.length+1).join("\u2022"):p.value;return f.length===0?p.placeholder||"":f},kl="checkbox",El="radio",NS="password",Um=707406591,pd=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;switch(C.type=v.type.toLowerCase(),C.checked=v.checked,C.value=OS(v),(C.type===kl||C.type===El)&&(C.styles.backgroundColor=3739148031,C.styles.borderTopColor=C.styles.borderRightColor=C.styles.borderBottomColor=C.styles.borderLeftColor=2779096575,C.styles.borderTopWidth=C.styles.borderRightWidth=C.styles.borderBottomWidth=C.styles.borderLeftWidth=1,C.styles.borderTopStyle=C.styles.borderRightStyle=C.styles.borderBottomStyle=C.styles.borderLeftStyle=1,C.styles.backgroundClip=[0],C.styles.backgroundOrigin=[0],C.bounds=RS(C.bounds)),C.type){case kl:C.styles.borderTopRightRadius=C.styles.borderTopLeftRadius=C.styles.borderBottomRightRadius=C.styles.borderBottomLeftRadius=MS;break;case El:C.styles.borderTopRightRadius=C.styles.borderTopLeftRadius=C.styles.borderBottomRightRadius=C.styles.borderBottomLeftRadius=HS;break}return C}return f})(Fr),Qm=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this,S=v.options[v.selectedIndex||0];return C.value=S&&S.text||"",C}return f})(Fr),km=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.value=v.value,C}return f})(Fr),Em=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;C.src=v.src,C.width=parseInt(v.width,10)||0,C.height=parseInt(v.height,10)||0,C.backgroundColor=C.styles.backgroundColor;try{if(v.contentWindow&&v.contentWindow.document&&v.contentWindow.document.documentElement){C.tree=Mm(x,v.contentWindow.document.documentElement);var S=v.contentWindow.document.documentElement?qA(x,getComputedStyle(v.contentWindow.document.documentElement).backgroundColor):ea.TRANSPARENT,L=v.contentWindow.document.body?qA(x,getComputedStyle(v.contentWindow.document.body).backgroundColor):ea.TRANSPARENT;C.backgroundColor=Ta(S)?Ta(L)?C.styles.backgroundColor:L:S}}catch{}return C}return f})(Fr),VS=["OL","UL","MENU"],Pl=function(p,f,x,v){for(var C=f.firstChild,S=void 0;C;C=S)if(S=C.nextSibling,Hm(C)&&C.data.trim().length>0)x.textNodes.push(new QS(p,C,x.styles));else if(sA(C))if(Km(C)&&C.assignedNodes)C.assignedNodes().forEach(function(R){return Pl(p,R,x,v)});else{var L=Pm(p,C);L.styles.isVisible()&&($S(C,L,v)?L.flags|=4:KS(L.styles)&&(L.flags|=2),VS.indexOf(C.tagName)!==-1&&(L.flags|=8),x.elements.push(L),C.slot,C.shadowRoot?Pl(p,C.shadowRoot,L,v):!Hl(C)&&!Rm(C)&&!Rl(C)&&Pl(p,C,L,v))}},Pm=function(p,f){return vd(f)?new Tm(p,f):Om(f)?new Im(p,f):Rm(f)?new Dm(p,f):GS(f)?new Lm(p,f):XS(f)?new gd(p,f):WS(f)?new pd(p,f):Rl(f)?new Qm(p,f):Hl(f)?new km(p,f):Vm(f)?new Em(p,f):new Fr(p,f)},Mm=function(p,f){var x=Pm(p,f);return x.flags|=4,Pl(p,f,x,x),x},$S=function(p,f,x){return f.styles.isPositionedWithZIndex()||f.styles.opacity<1||f.styles.isTransformed()||yd(p)&&x.styles.isTransparent()},KS=function(p){return p.isPositioned()||p.isFloating()},Hm=function(p){return p.nodeType===Node.TEXT_NODE},sA=function(p){return p.nodeType===Node.ELEMENT_NODE},md=function(p){return sA(p)&&typeof p.style<"u"&&!Ml(p)},Ml=function(p){return typeof p.className=="object"},GS=function(p){return p.tagName==="LI"},XS=function(p){return p.tagName==="OL"},WS=function(p){return p.tagName==="INPUT"},zS=function(p){return p.tagName==="HTML"},Rm=function(p){return p.tagName==="svg"},yd=function(p){return p.tagName==="BODY"},Om=function(p){return p.tagName==="CANVAS"},Nm=function(p){return p.tagName==="VIDEO"},vd=function(p){return p.tagName==="IMG"},Vm=function(p){return p.tagName==="IFRAME"},$m=function(p){return p.tagName==="STYLE"},YS=function(p){return p.tagName==="SCRIPT"},Hl=function(p){return p.tagName==="TEXTAREA"},Rl=function(p){return p.tagName==="SELECT"},Km=function(p){return p.tagName==="SLOT"},Gm=function(p){return p.tagName.indexOf("-")>0},jS=(function(){function p(){this.counters={}}return p.prototype.getCounterValue=function(f){var x=this.counters[f];return x&&x.length?x[x.length-1]:1},p.prototype.getCounterValues=function(f){var x=this.counters[f];return x||[]},p.prototype.pop=function(f){var x=this;f.forEach(function(v){return x.counters[v].pop()})},p.prototype.parse=function(f){var x=this,v=f.counterIncrement,C=f.counterReset,S=!0;v!==null&&v.forEach(function(R){var H=x.counters[R.counter];H&&R.increment!==0&&(S=!1,H.length||H.push(1),H[Math.max(0,H.length-1)]+=R.increment)});var L=[];return S&&C.forEach(function(R){var H=x.counters[R.counter];L.push(R.counter),H||(H=x.counters[R.counter]=[]),H.push(R.reset)}),L},p})(),Xm={integers:[1e3,900,500,400,100,90,50,40,10,9,5,4,1],values:["M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"]},Wm={integers:[9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["\u0554","\u0553","\u0552","\u0551","\u0550","\u054F","\u054E","\u054D","\u054C","\u054B","\u054A","\u0549","\u0548","\u0547","\u0546","\u0545","\u0544","\u0543","\u0542","\u0541","\u0540","\u053F","\u053E","\u053D","\u053C","\u053B","\u053A","\u0539","\u0538","\u0537","\u0536","\u0535","\u0534","\u0533","\u0532","\u0531"]},ZS={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,400,300,200,100,90,80,70,60,50,40,30,20,19,18,17,16,15,10,9,8,7,6,5,4,3,2,1],values:["\u05D9\u05F3","\u05D8\u05F3","\u05D7\u05F3","\u05D6\u05F3","\u05D5\u05F3","\u05D4\u05F3","\u05D3\u05F3","\u05D2\u05F3","\u05D1\u05F3","\u05D0\u05F3","\u05EA","\u05E9","\u05E8","\u05E7","\u05E6","\u05E4","\u05E2","\u05E1","\u05E0","\u05DE","\u05DC","\u05DB","\u05D9\u05D8","\u05D9\u05D7","\u05D9\u05D6","\u05D8\u05D6","\u05D8\u05D5","\u05D9","\u05D8","\u05D7","\u05D6","\u05D5","\u05D4","\u05D3","\u05D2","\u05D1","\u05D0"]},qS={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["\u10F5","\u10F0","\u10EF","\u10F4","\u10EE","\u10ED","\u10EC","\u10EB","\u10EA","\u10E9","\u10E8","\u10E7","\u10E6","\u10E5","\u10E4","\u10F3","\u10E2","\u10E1","\u10E0","\u10DF","\u10DE","\u10DD","\u10F2","\u10DC","\u10DB","\u10DA","\u10D9","\u10D8","\u10D7","\u10F1","\u10D6","\u10D5","\u10D4","\u10D3","\u10D2","\u10D1","\u10D0"]},rA=function(p,f,x,v,C,S){return p<f||p>x?so(p,C,S.length>0):v.integers.reduce(function(L,R,H){for(;p>=R;)p-=R,L+=v.values[H];return L},"")+S},zm=function(p,f,x,v){var C="";do x||p--,C=v(p)+C,p/=f;while(p*f>=f);return C},Ai=function(p,f,x,v,C){var S=x-f+1;return(p<0?"-":"")+(zm(Math.abs(p),S,v,function(L){return c(Math.floor(L%S)+f)})+C)},pn=function(p,f,x){x===void 0&&(x=". ");var v=f.length;return zm(Math.abs(p),v,!1,function(C){return f[Math.floor(C%v)]})+x},aA=1,Da=2,La=4,io=8,ta=function(p,f,x,v,C,S){if(p<-9999||p>9999)return so(p,4,C.length>0);var L=Math.abs(p),R=C;if(L===0)return f[0]+R;for(var H=0;L>0&&H<=4;H++){var j=L%10;j===0&&wi(S,aA)&&R!==""?R=f[j]+R:j>1||j===1&&H===0||j===1&&H===1&&wi(S,Da)||j===1&&H===1&&wi(S,La)&&p>100||j===1&&H>1&&wi(S,io)?R=f[j]+(H>0?x[H-1]:"")+R:j===1&&H>0&&(R=x[H-1]+R),L=Math.floor(L/10)}return(p<0?v:"")+R},Ym="\u5341\u767E\u5343\u842C",jm="\u62FE\u4F70\u4EDF\u842C",Zm="\u30DE\u30A4\u30CA\u30B9",xd="\uB9C8\uC774\uB108\uC2A4",so=function(p,f,x){var v=x?". ":"",C=x?"\u3001":"",S=x?", ":"",L=x?" ":"";switch(f){case 0:return"\u2022"+L;case 1:return"\u25E6"+L;case 2:return"\u25FE"+L;case 5:var R=Ai(p,48,57,!0,v);return R.length<4?"0"+R:R;case 4:return pn(p,"\u3007\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D",C);case 6:return rA(p,1,3999,Xm,3,v).toLowerCase();case 7:return rA(p,1,3999,Xm,3,v);case 8:return Ai(p,945,969,!1,v);case 9:return Ai(p,97,122,!1,v);case 10:return Ai(p,65,90,!1,v);case 11:return Ai(p,1632,1641,!0,v);case 12:case 49:return rA(p,1,9999,Wm,3,v);case 35:return rA(p,1,9999,Wm,3,v).toLowerCase();case 13:return Ai(p,2534,2543,!0,v);case 14:case 30:return Ai(p,6112,6121,!0,v);case 15:return pn(p,"\u5B50\u4E11\u5BC5\u536F\u8FB0\u5DF3\u5348\u672A\u7533\u9149\u620C\u4EA5",C);case 16:return pn(p,"\u7532\u4E59\u4E19\u4E01\u620A\u5DF1\u5E9A\u8F9B\u58EC\u7678",C);case 17:case 48:return ta(p,"\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D",Ym,"\u8CA0",C,Da|La|io);case 47:return ta(p,"\u96F6\u58F9\u8CB3\u53C3\u8086\u4F0D\u9678\u67D2\u634C\u7396",jm,"\u8CA0",C,aA|Da|La|io);case 42:return ta(p,"\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D",Ym,"\u8D1F",C,Da|La|io);case 41:return ta(p,"\u96F6\u58F9\u8D30\u53C1\u8086\u4F0D\u9646\u67D2\u634C\u7396",jm,"\u8D1F",C,aA|Da|La|io);case 26:return ta(p,"\u3007\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D","\u5341\u767E\u5343\u4E07",Zm,C,0);case 25:return ta(p,"\u96F6\u58F1\u5F10\u53C2\u56DB\u4F0D\u516D\u4E03\u516B\u4E5D","\u62FE\u767E\u5343\u4E07",Zm,C,aA|Da|La);case 31:return ta(p,"\uC601\uC77C\uC774\uC0BC\uC0AC\uC624\uC721\uCE60\uD314\uAD6C","\uC2ED\uBC31\uCC9C\uB9CC",xd,S,aA|Da|La);case 33:return ta(p,"\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D","\u5341\u767E\u5343\u842C",xd,S,0);case 32:return ta(p,"\u96F6\u58F9\u8CB3\u53C3\u56DB\u4E94\u516D\u4E03\u516B\u4E5D","\u62FE\u767E\u5343",xd,S,aA|Da|La);case 18:return Ai(p,2406,2415,!0,v);case 20:return rA(p,1,19999,qS,3,v);case 21:return Ai(p,2790,2799,!0,v);case 22:return Ai(p,2662,2671,!0,v);case 22:return rA(p,1,10999,ZS,3,v);case 23:return pn(p,"\u3042\u3044\u3046\u3048\u304A\u304B\u304D\u304F\u3051\u3053\u3055\u3057\u3059\u305B\u305D\u305F\u3061\u3064\u3066\u3068\u306A\u306B\u306C\u306D\u306E\u306F\u3072\u3075\u3078\u307B\u307E\u307F\u3080\u3081\u3082\u3084\u3086\u3088\u3089\u308A\u308B\u308C\u308D\u308F\u3090\u3091\u3092\u3093");case 24:return pn(p,"\u3044\u308D\u306F\u306B\u307B\u3078\u3068\u3061\u308A\u306C\u308B\u3092\u308F\u304B\u3088\u305F\u308C\u305D\u3064\u306D\u306A\u3089\u3080\u3046\u3090\u306E\u304A\u304F\u3084\u307E\u3051\u3075\u3053\u3048\u3066\u3042\u3055\u304D\u3086\u3081\u307F\u3057\u3091\u3072\u3082\u305B\u3059");case 27:return Ai(p,3302,3311,!0,v);case 28:return pn(p,"\u30A2\u30A4\u30A6\u30A8\u30AA\u30AB\u30AD\u30AF\u30B1\u30B3\u30B5\u30B7\u30B9\u30BB\u30BD\u30BF\u30C1\u30C4\u30C6\u30C8\u30CA\u30CB\u30CC\u30CD\u30CE\u30CF\u30D2\u30D5\u30D8\u30DB\u30DE\u30DF\u30E0\u30E1\u30E2\u30E4\u30E6\u30E8\u30E9\u30EA\u30EB\u30EC\u30ED\u30EF\u30F0\u30F1\u30F2\u30F3",C);case 29:return pn(p,"\u30A4\u30ED\u30CF\u30CB\u30DB\u30D8\u30C8\u30C1\u30EA\u30CC\u30EB\u30F2\u30EF\u30AB\u30E8\u30BF\u30EC\u30BD\u30C4\u30CD\u30CA\u30E9\u30E0\u30A6\u30F0\u30CE\u30AA\u30AF\u30E4\u30DE\u30B1\u30D5\u30B3\u30A8\u30C6\u30A2\u30B5\u30AD\u30E6\u30E1\u30DF\u30B7\u30F1\u30D2\u30E2\u30BB\u30B9",C);case 34:return Ai(p,3792,3801,!0,v);case 37:return Ai(p,6160,6169,!0,v);case 38:return Ai(p,4160,4169,!0,v);case 39:return Ai(p,2918,2927,!0,v);case 40:return Ai(p,1776,1785,!0,v);case 43:return Ai(p,3046,3055,!0,v);case 44:return Ai(p,3174,3183,!0,v);case 45:return Ai(p,3664,3673,!0,v);case 46:return Ai(p,3872,3881,!0,v);case 3:default:return Ai(p,48,57,!0,v)}},qm="data-html2canvas-ignore",Jm=(function(){function p(f,x,v){if(this.context=f,this.options=v,this.scrolledElements=[],this.referenceElement=x,this.counters=new jS,this.quoteDepth=0,!x.ownerDocument)throw new Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(x.ownerDocument.documentElement,!1)}return p.prototype.toIFrame=function(f,x){var v=this,C=JS(f,x);if(!C.contentWindow)return Promise.reject("Unable to find iframe window");var S=f.defaultView.pageXOffset,L=f.defaultView.pageYOffset,R=C.contentWindow,H=R.document,j=i1(C).then(function(){return i(v,void 0,void 0,function(){var Z,ee;return s(this,function(oe){switch(oe.label){case 0:return this.scrolledElements.forEach(n1),R&&(R.scrollTo(x.left,x.top),/(iPad|iPhone|iPod)/g.test(navigator.userAgent)&&(R.scrollY!==x.top||R.scrollX!==x.left)&&(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(R.scrollX-x.left,R.scrollY-x.top,0,0))),Z=this.options.onclone,ee=this.clonedReferenceElement,typeof ee>"u"?[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")]:H.fonts&&H.fonts.ready?[4,H.fonts.ready]:[3,2];case 1:oe.sent(),oe.label=2;case 2:return/(AppleWebKit)/g.test(navigator.userAgent)?[4,t1(H)]:[3,4];case 3:oe.sent(),oe.label=4;case 4:return typeof Z=="function"?[2,Promise.resolve().then(function(){return Z(H,ee)}).then(function(){return C})]:[2,C]}})})});return H.open(),H.write(r1(document.doctype)+"<html></html>"),a1(this.referenceElement.ownerDocument,S,L),H.replaceChild(H.adoptNode(this.documentElement),H.documentElement),H.close(),j},p.prototype.createElementClone=function(f){if(sd(f,2))debugger;if(Om(f))return this.createCanvasClone(f);if(Nm(f))return this.createVideoClone(f);if($m(f))return this.createStyleClone(f);var x=f.cloneNode(!1);return vd(x)&&(vd(f)&&f.currentSrc&&f.currentSrc!==f.src&&(x.src=f.currentSrc,x.srcset=""),x.loading==="lazy"&&(x.loading="eager")),Gm(x)?this.createCustomElementClone(x):x},p.prototype.createCustomElementClone=function(f){var x=document.createElement("html2canvascustomelement");return bd(f.style,x),x},p.prototype.createStyleClone=function(f){try{var x=f.sheet;if(x&&x.cssRules){var v=[].slice.call(x.cssRules,0).reduce(function(S,L){return L&&typeof L.cssText=="string"?S+L.cssText:S},""),C=f.cloneNode(!1);return C.textContent=v,C}}catch(S){if(this.context.logger.error("Unable to access cssRules property",S),S.name!=="SecurityError")throw S}return f.cloneNode(!1)},p.prototype.createCanvasClone=function(f){var x;if(this.options.inlineImages&&f.ownerDocument){var v=f.ownerDocument.createElement("img");try{return v.src=f.toDataURL(),v}catch{this.context.logger.info("Unable to inline canvas contents, canvas is tainted",f)}}var C=f.cloneNode(!1);try{C.width=f.width,C.height=f.height;var S=f.getContext("2d"),L=C.getContext("2d");if(L)if(!this.options.allowTaint&&S)L.putImageData(S.getImageData(0,0,f.width,f.height),0,0);else{var R=(x=f.getContext("webgl2"))!==null&&x!==void 0?x:f.getContext("webgl");if(R){var H=R.getContextAttributes();H?.preserveDrawingBuffer===!1&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",f)}L.drawImage(f,0,0)}return C}catch{this.context.logger.info("Unable to clone canvas as it is tainted",f)}return C},p.prototype.createVideoClone=function(f){var x=f.ownerDocument.createElement("canvas");x.width=f.offsetWidth,x.height=f.offsetHeight;var v=x.getContext("2d");try{return v&&(v.drawImage(f,0,0,x.width,x.height),this.options.allowTaint||v.getImageData(0,0,x.width,x.height)),x}catch{this.context.logger.info("Unable to clone video as it is tainted",f)}var C=f.ownerDocument.createElement("canvas");return C.width=f.offsetWidth,C.height=f.offsetHeight,C},p.prototype.appendChildNode=function(f,x,v){(!sA(x)||!YS(x)&&!x.hasAttribute(qm)&&(typeof this.options.ignoreElements!="function"||!this.options.ignoreElements(x)))&&(!this.options.copyStyles||!sA(x)||!$m(x))&&f.appendChild(this.cloneNode(x,v))},p.prototype.cloneChildNodes=function(f,x,v){for(var C=this,S=f.shadowRoot?f.shadowRoot.firstChild:f.firstChild;S;S=S.nextSibling)if(sA(S)&&Km(S)&&typeof S.assignedNodes=="function"){var L=S.assignedNodes();L.length&&L.forEach(function(R){return C.appendChildNode(x,R,v)})}else this.appendChildNode(x,S,v)},p.prototype.cloneNode=function(f,x){if(Hm(f))return document.createTextNode(f.data);if(!f.ownerDocument)return f.cloneNode(!1);var v=f.ownerDocument.defaultView;if(v&&sA(f)&&(md(f)||Ml(f))){var C=this.createElementClone(f);C.style.transitionProperty="none";var S=v.getComputedStyle(f),L=v.getComputedStyle(f,":before"),R=v.getComputedStyle(f,":after");this.referenceElement===f&&md(C)&&(this.clonedReferenceElement=C),yd(C)&&l1(C);var H=this.counters.parse(new um(this.context,S)),j=this.resolvePseudoContent(f,C,L,ro.BEFORE);Gm(f)&&(x=!0),Nm(f)||this.cloneChildNodes(f,C,x),j&&C.insertBefore(j,C.firstChild);var Z=this.resolvePseudoContent(f,C,R,ro.AFTER);return Z&&C.appendChild(Z),this.counters.pop(H),(S&&(this.options.copyStyles||Ml(f))&&!Vm(f)||x)&&bd(S,C),(f.scrollTop!==0||f.scrollLeft!==0)&&this.scrolledElements.push([C,f.scrollLeft,f.scrollTop]),(Hl(f)||Rl(f))&&(Hl(C)||Rl(C))&&(C.value=f.value),C}return f.cloneNode(!1)},p.prototype.resolvePseudoContent=function(f,x,v,C){var S=this;if(v){var L=v.content,R=x.ownerDocument;if(!(!R||!L||L==="none"||L==="-moz-alt-content"||v.display==="none")){this.counters.parse(new um(this.context,v));var H=new GF(this.context,v),j=R.createElement("html2canvaspseudoelement");bd(v,j),H.content.forEach(function(ee){if(ee.type===0)j.appendChild(R.createTextNode(ee.value));else if(ee.type===22){var oe=R.createElement("img");oe.src=ee.value,oe.style.opacity="1",j.appendChild(oe)}else if(ee.type===18){if(ee.name==="attr"){var _e=ee.values.filter(Lt);_e.length&&j.appendChild(R.createTextNode(f.getAttribute(_e[0].value)||""))}else if(ee.name==="counter"){var me=ee.values.filter(tA),xe=me[0],Je=me[1];if(xe&&Lt(xe)){var Ee=S.counters.getCounterValue(xe.value),Ue=Je&&Lt(Je)?id.parse(S.context,Je.value):3;j.appendChild(R.createTextNode(so(Ee,Ue,!1)))}}else if(ee.name==="counters"){var wt=ee.values.filter(tA),xe=wt[0],tt=wt[1],Je=wt[2];if(xe&&Lt(xe)){var Xe=S.counters.getCounterValues(xe.value),Be=Je&&Lt(Je)?id.parse(S.context,Je.value):3,vt=tt&&tt.type===0?tt.value:"",xt=Xe.map(function(ps){return so(ps,Be,!1)}).join(vt);j.appendChild(R.createTextNode(xt))}}}else if(ee.type===20)switch(ee.value){case"open-quote":j.appendChild(R.createTextNode(dm(H.quotes,S.quoteDepth++,!0)));break;case"close-quote":j.appendChild(R.createTextNode(dm(H.quotes,--S.quoteDepth,!1)));break;default:j.appendChild(R.createTextNode(ee.value))}}),j.className=Bd+" "+wd;var Z=C===ro.BEFORE?" "+Bd:" "+wd;return Ml(x)?x.className.baseValue+=Z:x.className+=Z,j}}},p.destroy=function(f){return f.parentNode?(f.parentNode.removeChild(f),!0):!1},p})(),ro;(function(p){p[p.BEFORE=0]="BEFORE",p[p.AFTER=1]="AFTER"})(ro||(ro={}));var JS=function(p,f){var x=p.createElement("iframe");return x.className="html2canvas-container",x.style.visibility="hidden",x.style.position="fixed",x.style.left="-10000px",x.style.top="0px",x.style.border="0",x.width=f.width.toString(),x.height=f.height.toString(),x.scrolling="no",x.setAttribute(qm,"true"),p.body.appendChild(x),x},e1=function(p){return new Promise(function(f){if(p.complete){f();return}if(!p.src){f();return}p.onload=f,p.onerror=f})},t1=function(p){return Promise.all([].slice.call(p.images,0).map(e1))},i1=function(p){return new Promise(function(f,x){var v=p.contentWindow;if(!v)return x("No window assigned for iframe");var C=v.document;v.onload=p.onload=function(){v.onload=p.onload=null;var S=setInterval(function(){C.body.childNodes.length>0&&C.readyState==="complete"&&(clearInterval(S),f(p))},50)}})},s1=["all","d","content"],bd=function(p,f){for(var x=p.length-1;x>=0;x--){var v=p.item(x);s1.indexOf(v)===-1&&f.style.setProperty(v,p.getPropertyValue(v))}return f},r1=function(p){var f="";return p&&(f+="<!DOCTYPE ",p.name&&(f+=p.name),p.internalSubset&&(f+=p.internalSubset),p.publicId&&(f+='"'+p.publicId+'"'),p.systemId&&(f+='"'+p.systemId+'"'),f+=">"),f},a1=function(p,f,x){p&&p.defaultView&&(f!==p.defaultView.pageXOffset||x!==p.defaultView.pageYOffset)&&p.defaultView.scrollTo(f,x)},n1=function(p){var f=p[0],x=p[1],v=p[2];f.scrollLeft=x,f.scrollTop=v},A1=":before",o1=":after",Bd="___html2canvas___pseudoelement_before",wd="___html2canvas___pseudoelement_after",ey=`{
3
- content: "" !important;
4
- display: none !important;
5
- }`,l1=function(p){h1(p,"."+Bd+A1+ey+`
6
- .`+wd+o1+ey)},h1=function(p,f){var x=p.ownerDocument;if(x){var v=x.createElement("style");v.textContent=f,p.appendChild(v)}},ty=(function(){function p(){}return p.getOrigin=function(f){var x=p._link;return x?(x.href=f,x.href=x.href,x.protocol+x.hostname+x.port):"about:blank"},p.isSameOrigin=function(f){return p.getOrigin(f)===p._origin},p.setContext=function(f){p._link=f.document.createElement("a"),p._origin=p.getOrigin(f.location.href)},p._origin="about:blank",p})(),c1=(function(){function p(f,x){this.context=f,this._options=x,this._cache={}}return p.prototype.addImage=function(f){var x=Promise.resolve();return this.has(f)||(_d(f)||g1(f))&&(this._cache[f]=this.loadImage(f)).catch(function(){}),x},p.prototype.match=function(f){return this._cache[f]},p.prototype.loadImage=function(f){return i(this,void 0,void 0,function(){var x,v,C,S,L=this;return s(this,function(R){switch(R.label){case 0:return x=ty.isSameOrigin(f),v=!Cd(f)&&this._options.useCORS===!0&&Ei.SUPPORT_CORS_IMAGES&&!x,C=!Cd(f)&&!x&&!_d(f)&&typeof this._options.proxy=="string"&&Ei.SUPPORT_CORS_XHR&&!v,!x&&this._options.allowTaint===!1&&!Cd(f)&&!_d(f)&&!C&&!v?[2]:(S=f,C?[4,this.proxy(S)]:[3,2]);case 1:S=R.sent(),R.label=2;case 2:return this.context.logger.debug("Added image "+f.substring(0,256)),[4,new Promise(function(H,j){var Z=new Image;Z.onload=function(){return H(Z)},Z.onerror=j,(p1(S)||v)&&(Z.crossOrigin="anonymous"),Z.src=S,Z.complete===!0&&setTimeout(function(){return H(Z)},500),L._options.imageTimeout>0&&setTimeout(function(){return j("Timed out ("+L._options.imageTimeout+"ms) loading image")},L._options.imageTimeout)})];case 3:return[2,R.sent()]}})})},p.prototype.has=function(f){return typeof this._cache[f]<"u"},p.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},p.prototype.proxy=function(f){var x=this,v=this._options.proxy;if(!v)throw new Error("No proxy defined");var C=f.substring(0,256);return new Promise(function(S,L){var R=Ei.SUPPORT_RESPONSE_TYPE?"blob":"text",H=new XMLHttpRequest;H.onload=function(){if(H.status===200)if(R==="text")S(H.response);else{var ee=new FileReader;ee.addEventListener("load",function(){return S(ee.result)},!1),ee.addEventListener("error",function(oe){return L(oe)},!1),ee.readAsDataURL(H.response)}else L("Failed to proxy resource "+C+" with status code "+H.status)},H.onerror=L;var j=v.indexOf("?")>-1?"&":"?";if(H.open("GET",""+v+j+"url="+encodeURIComponent(f)+"&responseType="+R),R!=="text"&&H instanceof XMLHttpRequest&&(H.responseType=R),x._options.imageTimeout){var Z=x._options.imageTimeout;H.timeout=Z,H.ontimeout=function(){return L("Timed out ("+Z+"ms) proxying "+C)}}H.send()})},p})(),d1=/^data:image\/svg\+xml/i,u1=/^data:image\/.*;base64,/i,f1=/^data:image\/.*/i,g1=function(p){return Ei.SUPPORT_SVG_DRAWING||!m1(p)},Cd=function(p){return f1.test(p)},p1=function(p){return u1.test(p)},_d=function(p){return p.substr(0,4)==="blob"},m1=function(p){return p.substr(-3).toLowerCase()==="svg"||d1.test(p)},be=(function(){function p(f,x){this.type=0,this.x=f,this.y=x}return p.prototype.add=function(f,x){return new p(this.x+f,this.y+x)},p})(),nA=function(p,f,x){return new be(p.x+(f.x-p.x)*x,p.y+(f.y-p.y)*x)},Ol=(function(){function p(f,x,v,C){this.type=1,this.start=f,this.startControl=x,this.endControl=v,this.end=C}return p.prototype.subdivide=function(f,x){var v=nA(this.start,this.startControl,f),C=nA(this.startControl,this.endControl,f),S=nA(this.endControl,this.end,f),L=nA(v,C,f),R=nA(C,S,f),H=nA(L,R,f);return x?new p(this.start,v,L,H):new p(H,R,S,this.end)},p.prototype.add=function(f,x){return new p(this.start.add(f,x),this.startControl.add(f,x),this.endControl.add(f,x),this.end.add(f,x))},p.prototype.reverse=function(){return new p(this.end,this.endControl,this.startControl,this.start)},p})(),Rs=function(p){return p.type===1},y1=(function(){function p(f){var x=f.styles,v=f.bounds,C=ZA(x.borderTopLeftRadius,v.width,v.height),S=C[0],L=C[1],R=ZA(x.borderTopRightRadius,v.width,v.height),H=R[0],j=R[1],Z=ZA(x.borderBottomRightRadius,v.width,v.height),ee=Z[0],oe=Z[1],_e=ZA(x.borderBottomLeftRadius,v.width,v.height),me=_e[0],xe=_e[1],Je=[];Je.push((S+H)/v.width),Je.push((me+ee)/v.width),Je.push((L+xe)/v.height),Je.push((j+oe)/v.height);var Ee=Math.max.apply(Math,Je);Ee>1&&(S/=Ee,L/=Ee,H/=Ee,j/=Ee,ee/=Ee,oe/=Ee,me/=Ee,xe/=Ee);var Ue=v.width-H,wt=v.height-oe,tt=v.width-ee,Xe=v.height-xe,Be=x.borderTopWidth,vt=x.borderRightWidth,xt=x.borderBottomWidth,ze=x.borderLeftWidth,vi=Ot(x.paddingTop,f.bounds.width),ps=Ot(x.paddingRight,f.bounds.width),Ts=Ot(x.paddingBottom,f.bounds.width),Ut=Ot(x.paddingLeft,f.bounds.width);this.topLeftBorderDoubleOuterBox=S>0||L>0?Xt(v.left+ze/3,v.top+Be/3,S-ze/3,L-Be/3,_t.TOP_LEFT):new be(v.left+ze/3,v.top+Be/3),this.topRightBorderDoubleOuterBox=S>0||L>0?Xt(v.left+Ue,v.top+Be/3,H-vt/3,j-Be/3,_t.TOP_RIGHT):new be(v.left+v.width-vt/3,v.top+Be/3),this.bottomRightBorderDoubleOuterBox=ee>0||oe>0?Xt(v.left+tt,v.top+wt,ee-vt/3,oe-xt/3,_t.BOTTOM_RIGHT):new be(v.left+v.width-vt/3,v.top+v.height-xt/3),this.bottomLeftBorderDoubleOuterBox=me>0||xe>0?Xt(v.left+ze/3,v.top+Xe,me-ze/3,xe-xt/3,_t.BOTTOM_LEFT):new be(v.left+ze/3,v.top+v.height-xt/3),this.topLeftBorderDoubleInnerBox=S>0||L>0?Xt(v.left+ze*2/3,v.top+Be*2/3,S-ze*2/3,L-Be*2/3,_t.TOP_LEFT):new be(v.left+ze*2/3,v.top+Be*2/3),this.topRightBorderDoubleInnerBox=S>0||L>0?Xt(v.left+Ue,v.top+Be*2/3,H-vt*2/3,j-Be*2/3,_t.TOP_RIGHT):new be(v.left+v.width-vt*2/3,v.top+Be*2/3),this.bottomRightBorderDoubleInnerBox=ee>0||oe>0?Xt(v.left+tt,v.top+wt,ee-vt*2/3,oe-xt*2/3,_t.BOTTOM_RIGHT):new be(v.left+v.width-vt*2/3,v.top+v.height-xt*2/3),this.bottomLeftBorderDoubleInnerBox=me>0||xe>0?Xt(v.left+ze*2/3,v.top+Xe,me-ze*2/3,xe-xt*2/3,_t.BOTTOM_LEFT):new be(v.left+ze*2/3,v.top+v.height-xt*2/3),this.topLeftBorderStroke=S>0||L>0?Xt(v.left+ze/2,v.top+Be/2,S-ze/2,L-Be/2,_t.TOP_LEFT):new be(v.left+ze/2,v.top+Be/2),this.topRightBorderStroke=S>0||L>0?Xt(v.left+Ue,v.top+Be/2,H-vt/2,j-Be/2,_t.TOP_RIGHT):new be(v.left+v.width-vt/2,v.top+Be/2),this.bottomRightBorderStroke=ee>0||oe>0?Xt(v.left+tt,v.top+wt,ee-vt/2,oe-xt/2,_t.BOTTOM_RIGHT):new be(v.left+v.width-vt/2,v.top+v.height-xt/2),this.bottomLeftBorderStroke=me>0||xe>0?Xt(v.left+ze/2,v.top+Xe,me-ze/2,xe-xt/2,_t.BOTTOM_LEFT):new be(v.left+ze/2,v.top+v.height-xt/2),this.topLeftBorderBox=S>0||L>0?Xt(v.left,v.top,S,L,_t.TOP_LEFT):new be(v.left,v.top),this.topRightBorderBox=H>0||j>0?Xt(v.left+Ue,v.top,H,j,_t.TOP_RIGHT):new be(v.left+v.width,v.top),this.bottomRightBorderBox=ee>0||oe>0?Xt(v.left+tt,v.top+wt,ee,oe,_t.BOTTOM_RIGHT):new be(v.left+v.width,v.top+v.height),this.bottomLeftBorderBox=me>0||xe>0?Xt(v.left,v.top+Xe,me,xe,_t.BOTTOM_LEFT):new be(v.left,v.top+v.height),this.topLeftPaddingBox=S>0||L>0?Xt(v.left+ze,v.top+Be,Math.max(0,S-ze),Math.max(0,L-Be),_t.TOP_LEFT):new be(v.left+ze,v.top+Be),this.topRightPaddingBox=H>0||j>0?Xt(v.left+Math.min(Ue,v.width-vt),v.top+Be,Ue>v.width+vt?0:Math.max(0,H-vt),Math.max(0,j-Be),_t.TOP_RIGHT):new be(v.left+v.width-vt,v.top+Be),this.bottomRightPaddingBox=ee>0||oe>0?Xt(v.left+Math.min(tt,v.width-ze),v.top+Math.min(wt,v.height-xt),Math.max(0,ee-vt),Math.max(0,oe-xt),_t.BOTTOM_RIGHT):new be(v.left+v.width-vt,v.top+v.height-xt),this.bottomLeftPaddingBox=me>0||xe>0?Xt(v.left+ze,v.top+Math.min(Xe,v.height-xt),Math.max(0,me-ze),Math.max(0,xe-xt),_t.BOTTOM_LEFT):new be(v.left+ze,v.top+v.height-xt),this.topLeftContentBox=S>0||L>0?Xt(v.left+ze+Ut,v.top+Be+vi,Math.max(0,S-(ze+Ut)),Math.max(0,L-(Be+vi)),_t.TOP_LEFT):new be(v.left+ze+Ut,v.top+Be+vi),this.topRightContentBox=H>0||j>0?Xt(v.left+Math.min(Ue,v.width+ze+Ut),v.top+Be+vi,Ue>v.width+ze+Ut?0:H-ze+Ut,j-(Be+vi),_t.TOP_RIGHT):new be(v.left+v.width-(vt+ps),v.top+Be+vi),this.bottomRightContentBox=ee>0||oe>0?Xt(v.left+Math.min(tt,v.width-(ze+Ut)),v.top+Math.min(wt,v.height+Be+vi),Math.max(0,ee-(vt+ps)),oe-(xt+Ts),_t.BOTTOM_RIGHT):new be(v.left+v.width-(vt+ps),v.top+v.height-(xt+Ts)),this.bottomLeftContentBox=me>0||xe>0?Xt(v.left+ze+Ut,v.top+Xe,Math.max(0,me-(ze+Ut)),xe-(xt+Ts),_t.BOTTOM_LEFT):new be(v.left+ze+Ut,v.top+v.height-(xt+Ts))}return p})(),_t;(function(p){p[p.TOP_LEFT=0]="TOP_LEFT",p[p.TOP_RIGHT=1]="TOP_RIGHT",p[p.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",p[p.BOTTOM_LEFT=3]="BOTTOM_LEFT"})(_t||(_t={}));var Xt=function(p,f,x,v,C){var S=4*((Math.sqrt(2)-1)/3),L=x*S,R=v*S,H=p+x,j=f+v;switch(C){case _t.TOP_LEFT:return new Ol(new be(p,j),new be(p,j-R),new be(H-L,f),new be(H,f));case _t.TOP_RIGHT:return new Ol(new be(p,f),new be(p+L,f),new be(H,j-R),new be(H,j));case _t.BOTTOM_RIGHT:return new Ol(new be(H,f),new be(H,f+R),new be(p+L,j),new be(p,j));case _t.BOTTOM_LEFT:default:return new Ol(new be(H,j),new be(H-L,j),new be(p,f+R),new be(p,f))}},Nl=function(p){return[p.topLeftBorderBox,p.topRightBorderBox,p.bottomRightBorderBox,p.bottomLeftBorderBox]},v1=function(p){return[p.topLeftContentBox,p.topRightContentBox,p.bottomRightContentBox,p.bottomLeftContentBox]},Vl=function(p){return[p.topLeftPaddingBox,p.topRightPaddingBox,p.bottomRightPaddingBox,p.bottomLeftPaddingBox]},x1=(function(){function p(f,x,v){this.offsetX=f,this.offsetY=x,this.matrix=v,this.type=0,this.target=6}return p})(),$l=(function(){function p(f,x){this.path=f,this.target=x,this.type=1}return p})(),b1=(function(){function p(f){this.opacity=f,this.type=2,this.target=6}return p})(),B1=function(p){return p.type===0},iy=function(p){return p.type===1},w1=function(p){return p.type===2},sy=function(p,f){return p.length===f.length?p.some(function(x,v){return x===f[v]}):!1},C1=function(p,f,x,v,C){return p.map(function(S,L){switch(L){case 0:return S.add(f,x);case 1:return S.add(f+v,x);case 2:return S.add(f+v,x+C);case 3:return S.add(f,x+C)}return S})},ry=(function(){function p(f){this.element=f,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]}return p})(),ay=(function(){function p(f,x){if(this.container=f,this.parent=x,this.effects=[],this.curves=new y1(this.container),this.container.styles.opacity<1&&this.effects.push(new b1(this.container.styles.opacity)),this.container.styles.transform!==null){var v=this.container.bounds.left+this.container.styles.transformOrigin[0].number,C=this.container.bounds.top+this.container.styles.transformOrigin[1].number,S=this.container.styles.transform;this.effects.push(new x1(v,C,S))}if(this.container.styles.overflowX!==0){var L=Nl(this.curves),R=Vl(this.curves);sy(L,R)?this.effects.push(new $l(L,6)):(this.effects.push(new $l(L,2)),this.effects.push(new $l(R,4)))}}return p.prototype.getEffects=function(f){for(var x=[2,3].indexOf(this.container.styles.position)===-1,v=this.parent,C=this.effects.slice(0);v;){var S=v.effects.filter(function(H){return!iy(H)});if(x||v.container.styles.position!==0||!v.parent){if(C.unshift.apply(C,S),x=[2,3].indexOf(v.container.styles.position)===-1,v.container.styles.overflowX!==0){var L=Nl(v.curves),R=Vl(v.curves);sy(L,R)||C.unshift(new $l(R,6))}}else C.unshift.apply(C,S);v=v.parent}return C.filter(function(H){return wi(H.target,f)})},p})(),Fd=function(p,f,x,v){p.container.elements.forEach(function(C){var S=wi(C.flags,4),L=wi(C.flags,2),R=new ay(C,p);wi(C.styles.display,2048)&&v.push(R);var H=wi(C.flags,8)?[]:v;if(S||L){var j=S||C.styles.isPositioned()?x:f,Z=new ry(R);if(C.styles.isPositioned()||C.styles.opacity<1||C.styles.isTransformed()){var ee=C.styles.zIndex.order;if(ee<0){var oe=0;j.negativeZIndex.some(function(me,xe){return ee>me.element.container.styles.zIndex.order?(oe=xe,!1):oe>0}),j.negativeZIndex.splice(oe,0,Z)}else if(ee>0){var _e=0;j.positiveZIndex.some(function(me,xe){return ee>=me.element.container.styles.zIndex.order?(_e=xe+1,!1):_e>0}),j.positiveZIndex.splice(_e,0,Z)}else j.zeroOrAutoZIndexOrTransformedOrOpacity.push(Z)}else C.styles.isFloating()?j.nonPositionedFloats.push(Z):j.nonPositionedInlineLevel.push(Z);Fd(R,Z,S?Z:x,H)}else C.styles.isInlineLevel()?f.inlineLevel.push(R):f.nonInlineLevel.push(R),Fd(R,f,x,H);wi(C.flags,8)&&ny(C,H)})},ny=function(p,f){for(var x=p instanceof gd?p.start:1,v=p instanceof gd?p.reversed:!1,C=0;C<f.length;C++){var S=f[C];S.container instanceof Lm&&typeof S.container.value=="number"&&S.container.value!==0&&(x=S.container.value),S.listValue=so(x,S.container.styles.listStyleType,!0),x+=v?-1:1}},_1=function(p){var f=new ay(p,null),x=new ry(f),v=[];return Fd(f,x,x,v),ny(f.container,v),x},Ay=function(p,f){switch(f){case 0:return Os(p.topLeftBorderBox,p.topLeftPaddingBox,p.topRightBorderBox,p.topRightPaddingBox);case 1:return Os(p.topRightBorderBox,p.topRightPaddingBox,p.bottomRightBorderBox,p.bottomRightPaddingBox);case 2:return Os(p.bottomRightBorderBox,p.bottomRightPaddingBox,p.bottomLeftBorderBox,p.bottomLeftPaddingBox);case 3:default:return Os(p.bottomLeftBorderBox,p.bottomLeftPaddingBox,p.topLeftBorderBox,p.topLeftPaddingBox)}},F1=function(p,f){switch(f){case 0:return Os(p.topLeftBorderBox,p.topLeftBorderDoubleOuterBox,p.topRightBorderBox,p.topRightBorderDoubleOuterBox);case 1:return Os(p.topRightBorderBox,p.topRightBorderDoubleOuterBox,p.bottomRightBorderBox,p.bottomRightBorderDoubleOuterBox);case 2:return Os(p.bottomRightBorderBox,p.bottomRightBorderDoubleOuterBox,p.bottomLeftBorderBox,p.bottomLeftBorderDoubleOuterBox);case 3:default:return Os(p.bottomLeftBorderBox,p.bottomLeftBorderDoubleOuterBox,p.topLeftBorderBox,p.topLeftBorderDoubleOuterBox)}},S1=function(p,f){switch(f){case 0:return Os(p.topLeftBorderDoubleInnerBox,p.topLeftPaddingBox,p.topRightBorderDoubleInnerBox,p.topRightPaddingBox);case 1:return Os(p.topRightBorderDoubleInnerBox,p.topRightPaddingBox,p.bottomRightBorderDoubleInnerBox,p.bottomRightPaddingBox);case 2:return Os(p.bottomRightBorderDoubleInnerBox,p.bottomRightPaddingBox,p.bottomLeftBorderDoubleInnerBox,p.bottomLeftPaddingBox);case 3:default:return Os(p.bottomLeftBorderDoubleInnerBox,p.bottomLeftPaddingBox,p.topLeftBorderDoubleInnerBox,p.topLeftPaddingBox)}},T1=function(p,f){switch(f){case 0:return Kl(p.topLeftBorderStroke,p.topRightBorderStroke);case 1:return Kl(p.topRightBorderStroke,p.bottomRightBorderStroke);case 2:return Kl(p.bottomRightBorderStroke,p.bottomLeftBorderStroke);case 3:default:return Kl(p.bottomLeftBorderStroke,p.topLeftBorderStroke)}},Kl=function(p,f){var x=[];return Rs(p)?x.push(p.subdivide(.5,!1)):x.push(p),Rs(f)?x.push(f.subdivide(.5,!0)):x.push(f),x},Os=function(p,f,x,v){var C=[];return Rs(p)?C.push(p.subdivide(.5,!1)):C.push(p),Rs(x)?C.push(x.subdivide(.5,!0)):C.push(x),Rs(v)?C.push(v.subdivide(.5,!0).reverse()):C.push(v),Rs(f)?C.push(f.subdivide(.5,!1).reverse()):C.push(f),C},oy=function(p){var f=p.bounds,x=p.styles;return f.add(x.borderLeftWidth,x.borderTopWidth,-(x.borderRightWidth+x.borderLeftWidth),-(x.borderTopWidth+x.borderBottomWidth))},Gl=function(p){var f=p.styles,x=p.bounds,v=Ot(f.paddingLeft,x.width),C=Ot(f.paddingRight,x.width),S=Ot(f.paddingTop,x.width),L=Ot(f.paddingBottom,x.width);return x.add(v+f.borderLeftWidth,S+f.borderTopWidth,-(f.borderRightWidth+f.borderLeftWidth+v+C),-(f.borderTopWidth+f.borderBottomWidth+S+L))},I1=function(p,f){return p===0?f.bounds:p===2?Gl(f):oy(f)},D1=function(p,f){return p===0?f.bounds:p===2?Gl(f):oy(f)},Sd=function(p,f,x){var v=I1(oA(p.styles.backgroundOrigin,f),p),C=D1(oA(p.styles.backgroundClip,f),p),S=L1(oA(p.styles.backgroundSize,f),x,v),L=S[0],R=S[1],H=ZA(oA(p.styles.backgroundPosition,f),v.width-L,v.height-R),j=U1(oA(p.styles.backgroundRepeat,f),H,S,v,C),Z=Math.round(v.left+H[0]),ee=Math.round(v.top+H[1]);return[j,Z,ee,L,R]},AA=function(p){return Lt(p)&&p.value===iA.AUTO},Xl=function(p){return typeof p=="number"},L1=function(p,f,x){var v=f[0],C=f[1],S=f[2],L=p[0],R=p[1];if(!L)return[0,0];if(yi(L)&&R&&yi(R))return[Ot(L,x.width),Ot(R,x.height)];var H=Xl(S);if(Lt(L)&&(L.value===iA.CONTAIN||L.value===iA.COVER)){if(Xl(S)){var j=x.width/x.height;return j<S!=(L.value===iA.COVER)?[x.width,x.width/S]:[x.height*S,x.height]}return[x.width,x.height]}var Z=Xl(v),ee=Xl(C),oe=Z||ee;if(AA(L)&&(!R||AA(R))){if(Z&&ee)return[v,C];if(!H&&!oe)return[x.width,x.height];if(oe&&H){var _e=Z?v:C*S,me=ee?C:v/S;return[_e,me]}var xe=Z?v:x.width,Je=ee?C:x.height;return[xe,Je]}if(H){var Ee=0,Ue=0;return yi(L)?Ee=Ot(L,x.width):yi(R)&&(Ue=Ot(R,x.height)),AA(L)?Ee=Ue*S:(!R||AA(R))&&(Ue=Ee/S),[Ee,Ue]}var wt=null,tt=null;if(yi(L)?wt=Ot(L,x.width):R&&yi(R)&&(tt=Ot(R,x.height)),wt!==null&&(!R||AA(R))&&(tt=Z&&ee?wt/v*C:x.height),tt!==null&&AA(L)&&(wt=Z&&ee?tt/C*v:x.width),wt!==null&&tt!==null)return[wt,tt];throw new Error("Unable to calculate background-size for element")},oA=function(p,f){var x=p[f];return typeof x>"u"?p[0]:x},U1=function(p,f,x,v,C){var S=f[0],L=f[1],R=x[0],H=x[1];switch(p){case 2:return[new be(Math.round(v.left),Math.round(v.top+L)),new be(Math.round(v.left+v.width),Math.round(v.top+L)),new be(Math.round(v.left+v.width),Math.round(H+v.top+L)),new be(Math.round(v.left),Math.round(H+v.top+L))];case 3:return[new be(Math.round(v.left+S),Math.round(v.top)),new be(Math.round(v.left+S+R),Math.round(v.top)),new be(Math.round(v.left+S+R),Math.round(v.height+v.top)),new be(Math.round(v.left+S),Math.round(v.height+v.top))];case 1:return[new be(Math.round(v.left+S),Math.round(v.top+L)),new be(Math.round(v.left+S+R),Math.round(v.top+L)),new be(Math.round(v.left+S+R),Math.round(v.top+L+H)),new be(Math.round(v.left+S),Math.round(v.top+L+H))];default:return[new be(Math.round(C.left),Math.round(C.top)),new be(Math.round(C.left+C.width),Math.round(C.top)),new be(Math.round(C.left+C.width),Math.round(C.height+C.top)),new be(Math.round(C.left),Math.round(C.height+C.top))]}},Q1="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",ly="Hidden Text",k1=(function(){function p(f){this._data={},this._document=f}return p.prototype.parseMetrics=function(f,x){var v=this._document.createElement("div"),C=this._document.createElement("img"),S=this._document.createElement("span"),L=this._document.body;v.style.visibility="hidden",v.style.fontFamily=f,v.style.fontSize=x,v.style.margin="0",v.style.padding="0",v.style.whiteSpace="nowrap",L.appendChild(v),C.src=Q1,C.width=1,C.height=1,C.style.margin="0",C.style.padding="0",C.style.verticalAlign="baseline",S.style.fontFamily=f,S.style.fontSize=x,S.style.margin="0",S.style.padding="0",S.appendChild(this._document.createTextNode(ly)),v.appendChild(S),v.appendChild(C);var R=C.offsetTop-S.offsetTop+2;v.removeChild(S),v.appendChild(this._document.createTextNode(ly)),v.style.lineHeight="normal",C.style.verticalAlign="super";var H=C.offsetTop-v.offsetTop+2;return L.removeChild(v),{baseline:R,middle:H}},p.prototype.getMetrics=function(f,x){var v=f+" "+x;return typeof this._data[v]>"u"&&(this._data[v]=this.parseMetrics(f,x)),this._data[v]},p})(),hy=(function(){function p(f,x){this.context=f,this.options=x}return p})(),E1=1e4,P1=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C._activeEffects=[],C.canvas=v.canvas?v.canvas:document.createElement("canvas"),C.ctx=C.canvas.getContext("2d"),v.canvas||(C.canvas.width=Math.floor(v.width*v.scale),C.canvas.height=Math.floor(v.height*v.scale),C.canvas.style.width=v.width+"px",C.canvas.style.height=v.height+"px"),C.fontMetrics=new k1(document),C.ctx.scale(C.options.scale,C.options.scale),C.ctx.translate(-v.x,-v.y),C.ctx.textBaseline="bottom",C._activeEffects=[],C.context.logger.debug("Canvas renderer initialized ("+v.width+"x"+v.height+") with scale "+v.scale),C}return f.prototype.applyEffects=function(x){for(var v=this;this._activeEffects.length;)this.popEffect();x.forEach(function(C){return v.applyEffect(C)})},f.prototype.applyEffect=function(x){this.ctx.save(),w1(x)&&(this.ctx.globalAlpha=x.opacity),B1(x)&&(this.ctx.translate(x.offsetX,x.offsetY),this.ctx.transform(x.matrix[0],x.matrix[1],x.matrix[2],x.matrix[3],x.matrix[4],x.matrix[5]),this.ctx.translate(-x.offsetX,-x.offsetY)),iy(x)&&(this.path(x.path),this.ctx.clip()),this._activeEffects.push(x)},f.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},f.prototype.renderStack=function(x){return i(this,void 0,void 0,function(){var v;return s(this,function(C){switch(C.label){case 0:return v=x.element.container.styles,v.isVisible()?[4,this.renderStackContent(x)]:[3,2];case 1:C.sent(),C.label=2;case 2:return[2]}})})},f.prototype.renderNode=function(x){return i(this,void 0,void 0,function(){return s(this,function(v){switch(v.label){case 0:if(wi(x.container.flags,16))debugger;return x.container.styles.isVisible()?[4,this.renderNodeBackgroundAndBorders(x)]:[3,3];case 1:return v.sent(),[4,this.renderNodeContent(x)];case 2:v.sent(),v.label=3;case 3:return[2]}})})},f.prototype.renderTextWithLetterSpacing=function(x,v,C){var S=this;if(v===0)this.ctx.fillText(x.text,x.bounds.left,x.bounds.top+C);else{var L=fd(x.text);L.reduce(function(R,H){return S.ctx.fillText(H,R,x.bounds.top+C),R+S.ctx.measureText(H).width},x.bounds.left)}},f.prototype.createFontStyle=function(x){var v=x.fontVariant.filter(function(L){return L==="normal"||L==="small-caps"}).join(""),C=N1(x.fontFamily).join(", "),S=jA(x.fontSize)?""+x.fontSize.number+x.fontSize.unit:x.fontSize.number+"px";return[[x.fontStyle,v,x.fontWeight,S,C].join(" "),C,S]},f.prototype.renderTextNode=function(x,v){return i(this,void 0,void 0,function(){var C,S,L,R,H,j,Z,ee,oe=this;return s(this,function(_e){return C=this.createFontStyle(v),S=C[0],L=C[1],R=C[2],this.ctx.font=S,this.ctx.direction=v.direction===1?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",H=this.fontMetrics.getMetrics(L,R),j=H.baseline,Z=H.middle,ee=v.paintOrder,x.textBounds.forEach(function(me){ee.forEach(function(xe){switch(xe){case 0:oe.ctx.fillStyle=Ii(v.color),oe.renderTextWithLetterSpacing(me,v.letterSpacing,j);var Je=v.textShadow;Je.length&&me.text.trim().length&&(Je.slice(0).reverse().forEach(function(Ee){oe.ctx.shadowColor=Ii(Ee.color),oe.ctx.shadowOffsetX=Ee.offsetX.number*oe.options.scale,oe.ctx.shadowOffsetY=Ee.offsetY.number*oe.options.scale,oe.ctx.shadowBlur=Ee.blur.number,oe.renderTextWithLetterSpacing(me,v.letterSpacing,j)}),oe.ctx.shadowColor="",oe.ctx.shadowOffsetX=0,oe.ctx.shadowOffsetY=0,oe.ctx.shadowBlur=0),v.textDecorationLine.length&&(oe.ctx.fillStyle=Ii(v.textDecorationColor||v.color),v.textDecorationLine.forEach(function(Ee){switch(Ee){case 1:oe.ctx.fillRect(me.bounds.left,Math.round(me.bounds.top+j),me.bounds.width,1);break;case 2:oe.ctx.fillRect(me.bounds.left,Math.round(me.bounds.top),me.bounds.width,1);break;case 3:oe.ctx.fillRect(me.bounds.left,Math.ceil(me.bounds.top+Z),me.bounds.width,1);break}}));break;case 1:v.webkitTextStrokeWidth&&me.text.trim().length&&(oe.ctx.strokeStyle=Ii(v.webkitTextStrokeColor),oe.ctx.lineWidth=v.webkitTextStrokeWidth,oe.ctx.lineJoin=window.chrome?"miter":"round",oe.ctx.strokeText(me.text,me.bounds.left,me.bounds.top+j)),oe.ctx.strokeStyle="",oe.ctx.lineWidth=0,oe.ctx.lineJoin="miter";break}})}),[2]})})},f.prototype.renderReplacedElement=function(x,v,C){if(C&&x.intrinsicWidth>0&&x.intrinsicHeight>0){var S=Gl(x),L=Vl(v);this.path(L),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(C,0,0,x.intrinsicWidth,x.intrinsicHeight,S.left,S.top,S.width,S.height),this.ctx.restore()}},f.prototype.renderNodeContent=function(x){return i(this,void 0,void 0,function(){var v,C,S,L,R,H,Ue,Ue,j,Z,ee,oe,tt,_e,me,Xe,xe,Je,Ee,Ue,wt,tt,Xe;return s(this,function(Be){switch(Be.label){case 0:this.applyEffects(x.getEffects(4)),v=x.container,C=x.curves,S=v.styles,L=0,R=v.textNodes,Be.label=1;case 1:return L<R.length?(H=R[L],[4,this.renderTextNode(H,S)]):[3,4];case 2:Be.sent(),Be.label=3;case 3:return L++,[3,1];case 4:if(!(v instanceof Tm))return[3,8];Be.label=5;case 5:return Be.trys.push([5,7,,8]),[4,this.context.cache.match(v.src)];case 6:return Ue=Be.sent(),this.renderReplacedElement(v,C,Ue),[3,8];case 7:return Be.sent(),this.context.logger.error("Error loading image "+v.src),[3,8];case 8:if(v instanceof Im&&this.renderReplacedElement(v,C,v.canvas),!(v instanceof Dm))return[3,12];Be.label=9;case 9:return Be.trys.push([9,11,,12]),[4,this.context.cache.match(v.svg)];case 10:return Ue=Be.sent(),this.renderReplacedElement(v,C,Ue),[3,12];case 11:return Be.sent(),this.context.logger.error("Error loading svg "+v.svg.substring(0,255)),[3,12];case 12:return v instanceof Em&&v.tree?(j=new f(this.context,{scale:this.options.scale,backgroundColor:v.backgroundColor,x:0,y:0,width:v.width,height:v.height}),[4,j.render(v.tree)]):[3,14];case 13:Z=Be.sent(),v.width&&v.height&&this.ctx.drawImage(Z,0,0,v.width,v.height,v.bounds.left,v.bounds.top,v.bounds.width,v.bounds.height),Be.label=14;case 14:if(v instanceof pd&&(ee=Math.min(v.bounds.width,v.bounds.height),v.type===kl?v.checked&&(this.ctx.save(),this.path([new be(v.bounds.left+ee*.39363,v.bounds.top+ee*.79),new be(v.bounds.left+ee*.16,v.bounds.top+ee*.5549),new be(v.bounds.left+ee*.27347,v.bounds.top+ee*.44071),new be(v.bounds.left+ee*.39694,v.bounds.top+ee*.5649),new be(v.bounds.left+ee*.72983,v.bounds.top+ee*.23),new be(v.bounds.left+ee*.84,v.bounds.top+ee*.34085),new be(v.bounds.left+ee*.39363,v.bounds.top+ee*.79)]),this.ctx.fillStyle=Ii(Um),this.ctx.fill(),this.ctx.restore()):v.type===El&&v.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(v.bounds.left+ee/2,v.bounds.top+ee/2,ee/4,0,Math.PI*2,!0),this.ctx.fillStyle=Ii(Um),this.ctx.fill(),this.ctx.restore())),M1(v)&&v.value.length){switch(oe=this.createFontStyle(S),tt=oe[0],_e=oe[1],me=this.fontMetrics.getMetrics(tt,_e).baseline,this.ctx.font=tt,this.ctx.fillStyle=Ii(S.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=R1(v.styles.textAlign),Xe=Gl(v),xe=0,v.styles.textAlign){case 1:xe+=Xe.width/2;break;case 2:xe+=Xe.width;break}Je=Xe.add(xe,0,0,-Xe.height/2+1),this.ctx.save(),this.path([new be(Xe.left,Xe.top),new be(Xe.left+Xe.width,Xe.top),new be(Xe.left+Xe.width,Xe.top+Xe.height),new be(Xe.left,Xe.top+Xe.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new to(v.value,Je),S.letterSpacing,me),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!wi(v.styles.display,2048))return[3,20];if(v.styles.listStyleImage===null)return[3,19];if(Ee=v.styles.listStyleImage,Ee.type!==0)return[3,18];Ue=void 0,wt=Ee.url,Be.label=15;case 15:return Be.trys.push([15,17,,18]),[4,this.context.cache.match(wt)];case 16:return Ue=Be.sent(),this.ctx.drawImage(Ue,v.bounds.left-(Ue.width+10),v.bounds.top),[3,18];case 17:return Be.sent(),this.context.logger.error("Error loading list-style-image "+wt),[3,18];case 18:return[3,20];case 19:x.listValue&&v.styles.listStyleType!==-1&&(tt=this.createFontStyle(S)[0],this.ctx.font=tt,this.ctx.fillStyle=Ii(S.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",Xe=new n(v.bounds.left,v.bounds.top+Ot(v.styles.paddingTop,v.bounds.width),v.bounds.width,lm(S.lineHeight,S.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new to(x.listValue,Xe),S.letterSpacing,lm(S.lineHeight,S.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),Be.label=20;case 20:return[2]}})})},f.prototype.renderStackContent=function(x){return i(this,void 0,void 0,function(){var v,C,Ee,S,L,Ee,R,H,Ee,j,Z,Ee,ee,oe,Ee,_e,me,Ee,xe,Je,Ee;return s(this,function(Ue){switch(Ue.label){case 0:if(wi(x.element.container.flags,16))debugger;return[4,this.renderNodeBackgroundAndBorders(x.element)];case 1:Ue.sent(),v=0,C=x.negativeZIndex,Ue.label=2;case 2:return v<C.length?(Ee=C[v],[4,this.renderStack(Ee)]):[3,5];case 3:Ue.sent(),Ue.label=4;case 4:return v++,[3,2];case 5:return[4,this.renderNodeContent(x.element)];case 6:Ue.sent(),S=0,L=x.nonInlineLevel,Ue.label=7;case 7:return S<L.length?(Ee=L[S],[4,this.renderNode(Ee)]):[3,10];case 8:Ue.sent(),Ue.label=9;case 9:return S++,[3,7];case 10:R=0,H=x.nonPositionedFloats,Ue.label=11;case 11:return R<H.length?(Ee=H[R],[4,this.renderStack(Ee)]):[3,14];case 12:Ue.sent(),Ue.label=13;case 13:return R++,[3,11];case 14:j=0,Z=x.nonPositionedInlineLevel,Ue.label=15;case 15:return j<Z.length?(Ee=Z[j],[4,this.renderStack(Ee)]):[3,18];case 16:Ue.sent(),Ue.label=17;case 17:return j++,[3,15];case 18:ee=0,oe=x.inlineLevel,Ue.label=19;case 19:return ee<oe.length?(Ee=oe[ee],[4,this.renderNode(Ee)]):[3,22];case 20:Ue.sent(),Ue.label=21;case 21:return ee++,[3,19];case 22:_e=0,me=x.zeroOrAutoZIndexOrTransformedOrOpacity,Ue.label=23;case 23:return _e<me.length?(Ee=me[_e],[4,this.renderStack(Ee)]):[3,26];case 24:Ue.sent(),Ue.label=25;case 25:return _e++,[3,23];case 26:xe=0,Je=x.positiveZIndex,Ue.label=27;case 27:return xe<Je.length?(Ee=Je[xe],[4,this.renderStack(Ee)]):[3,30];case 28:Ue.sent(),Ue.label=29;case 29:return xe++,[3,27];case 30:return[2]}})})},f.prototype.mask=function(x){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(x.slice(0).reverse()),this.ctx.closePath()},f.prototype.path=function(x){this.ctx.beginPath(),this.formatPath(x),this.ctx.closePath()},f.prototype.formatPath=function(x){var v=this;x.forEach(function(C,S){var L=Rs(C)?C.start:C;S===0?v.ctx.moveTo(L.x,L.y):v.ctx.lineTo(L.x,L.y),Rs(C)&&v.ctx.bezierCurveTo(C.startControl.x,C.startControl.y,C.endControl.x,C.endControl.y,C.end.x,C.end.y)})},f.prototype.renderRepeat=function(x,v,C,S){this.path(x),this.ctx.fillStyle=v,this.ctx.translate(C,S),this.ctx.fill(),this.ctx.translate(-C,-S)},f.prototype.resizeImage=function(x,v,C){var S;if(x.width===v&&x.height===C)return x;var L=(S=this.canvas.ownerDocument)!==null&&S!==void 0?S:document,R=L.createElement("canvas");R.width=Math.max(1,v),R.height=Math.max(1,C);var H=R.getContext("2d");return H.drawImage(x,0,0,x.width,x.height,0,0,v,C),R},f.prototype.renderBackgroundImage=function(x){return i(this,void 0,void 0,function(){var v,C,S,L,R,H;return s(this,function(j){switch(j.label){case 0:v=x.styles.backgroundImage.length-1,C=function(Z){var ee,oe,_e,vi,ms,ys,Ut,Pi,xt,me,vi,ms,ys,Ut,Pi,xe,Je,Ee,Ue,wt,tt,Xe,Be,vt,xt,ze,vi,ps,Ts,Ut,Pi,Ua,ms,ys,mn,Sr,Qa,yn,vn,ia,xn,sa;return s(this,function(lA){switch(lA.label){case 0:if(Z.type!==0)return[3,5];ee=void 0,oe=Z.url,lA.label=1;case 1:return lA.trys.push([1,3,,4]),[4,S.context.cache.match(oe)];case 2:return ee=lA.sent(),[3,4];case 3:return lA.sent(),S.context.logger.error("Error loading background-image "+oe),[3,4];case 4:return ee&&(_e=Sd(x,v,[ee.width,ee.height,ee.width/ee.height]),vi=_e[0],ms=_e[1],ys=_e[2],Ut=_e[3],Pi=_e[4],xt=S.ctx.createPattern(S.resizeImage(ee,Ut,Pi),"repeat"),S.renderRepeat(vi,xt,ms,ys)),[3,6];case 5:B_(Z)?(me=Sd(x,v,[null,null,null]),vi=me[0],ms=me[1],ys=me[2],Ut=me[3],Pi=me[4],xe=m_(Z.angle,Ut,Pi),Je=xe[0],Ee=xe[1],Ue=xe[2],wt=xe[3],tt=xe[4],Xe=document.createElement("canvas"),Xe.width=Ut,Xe.height=Pi,Be=Xe.getContext("2d"),vt=Be.createLinearGradient(Ee,wt,Ue,tt),qp(Z.stops,Je).forEach(function(ao){return vt.addColorStop(ao.stop,Ii(ao.color))}),Be.fillStyle=vt,Be.fillRect(0,0,Ut,Pi),Ut>0&&Pi>0&&(xt=S.ctx.createPattern(Xe,"repeat"),S.renderRepeat(vi,xt,ms,ys))):w_(Z)&&(ze=Sd(x,v,[null,null,null]),vi=ze[0],ps=ze[1],Ts=ze[2],Ut=ze[3],Pi=ze[4],Ua=Z.position.length===0?[Jc]:Z.position,ms=Ot(Ua[0],Ut),ys=Ot(Ua[Ua.length-1],Pi),mn=y_(Z,ms,ys,Ut,Pi),Sr=mn[0],Qa=mn[1],Sr>0&&Qa>0&&(yn=S.ctx.createRadialGradient(ps+ms,Ts+ys,0,ps+ms,Ts+ys,Sr),qp(Z.stops,Sr*2).forEach(function(ao){return yn.addColorStop(ao.stop,Ii(ao.color))}),S.path(vi),S.ctx.fillStyle=yn,Sr!==Qa?(vn=x.bounds.left+.5*x.bounds.width,ia=x.bounds.top+.5*x.bounds.height,xn=Qa/Sr,sa=1/xn,S.ctx.save(),S.ctx.translate(vn,ia),S.ctx.transform(1,0,0,xn,0,0),S.ctx.translate(-vn,-ia),S.ctx.fillRect(ps,sa*(Ts-ia)+ia,Ut,Pi*sa),S.ctx.restore()):S.ctx.fill())),lA.label=6;case 6:return v--,[2]}})},S=this,L=0,R=x.styles.backgroundImage.slice(0).reverse(),j.label=1;case 1:return L<R.length?(H=R[L],[5,C(H)]):[3,4];case 2:j.sent(),j.label=3;case 3:return L++,[3,1];case 4:return[2]}})})},f.prototype.renderSolidBorder=function(x,v,C){return i(this,void 0,void 0,function(){return s(this,function(S){return this.path(Ay(C,v)),this.ctx.fillStyle=Ii(x),this.ctx.fill(),[2]})})},f.prototype.renderDoubleBorder=function(x,v,C,S){return i(this,void 0,void 0,function(){var L,R;return s(this,function(H){switch(H.label){case 0:return v<3?[4,this.renderSolidBorder(x,C,S)]:[3,2];case 1:return H.sent(),[2];case 2:return L=F1(S,C),this.path(L),this.ctx.fillStyle=Ii(x),this.ctx.fill(),R=S1(S,C),this.path(R),this.ctx.fill(),[2]}})})},f.prototype.renderNodeBackgroundAndBorders=function(x){return i(this,void 0,void 0,function(){var v,C,S,L,R,H,j,Z,ee=this;return s(this,function(oe){switch(oe.label){case 0:return this.applyEffects(x.getEffects(2)),v=x.container.styles,C=!Ta(v.backgroundColor)||v.backgroundImage.length,S=[{style:v.borderTopStyle,color:v.borderTopColor,width:v.borderTopWidth},{style:v.borderRightStyle,color:v.borderRightColor,width:v.borderRightWidth},{style:v.borderBottomStyle,color:v.borderBottomColor,width:v.borderBottomWidth},{style:v.borderLeftStyle,color:v.borderLeftColor,width:v.borderLeftWidth}],L=H1(oA(v.backgroundClip,0),x.curves),C||v.boxShadow.length?(this.ctx.save(),this.path(L),this.ctx.clip(),Ta(v.backgroundColor)||(this.ctx.fillStyle=Ii(v.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(x.container)]):[3,2];case 1:oe.sent(),this.ctx.restore(),v.boxShadow.slice(0).reverse().forEach(function(_e){ee.ctx.save();var me=Nl(x.curves),xe=_e.inset?0:E1,Je=C1(me,-xe+(_e.inset?1:-1)*_e.spread.number,(_e.inset?1:-1)*_e.spread.number,_e.spread.number*(_e.inset?-2:2),_e.spread.number*(_e.inset?-2:2));_e.inset?(ee.path(me),ee.ctx.clip(),ee.mask(Je)):(ee.mask(me),ee.ctx.clip(),ee.path(Je)),ee.ctx.shadowOffsetX=_e.offsetX.number+xe,ee.ctx.shadowOffsetY=_e.offsetY.number,ee.ctx.shadowColor=Ii(_e.color),ee.ctx.shadowBlur=_e.blur.number,ee.ctx.fillStyle=_e.inset?Ii(_e.color):"rgba(0,0,0,1)",ee.ctx.fill(),ee.ctx.restore()}),oe.label=2;case 2:R=0,H=0,j=S,oe.label=3;case 3:return H<j.length?(Z=j[H],Z.style!==0&&!Ta(Z.color)&&Z.width>0?Z.style!==2?[3,5]:[4,this.renderDashedDottedBorder(Z.color,Z.width,R,x.curves,2)]:[3,11]):[3,13];case 4:return oe.sent(),[3,11];case 5:return Z.style!==3?[3,7]:[4,this.renderDashedDottedBorder(Z.color,Z.width,R,x.curves,3)];case 6:return oe.sent(),[3,11];case 7:return Z.style!==4?[3,9]:[4,this.renderDoubleBorder(Z.color,Z.width,R,x.curves)];case 8:return oe.sent(),[3,11];case 9:return[4,this.renderSolidBorder(Z.color,R,x.curves)];case 10:oe.sent(),oe.label=11;case 11:R++,oe.label=12;case 12:return H++,[3,3];case 13:return[2]}})})},f.prototype.renderDashedDottedBorder=function(x,v,C,S,L){return i(this,void 0,void 0,function(){var R,H,j,Z,ee,oe,_e,me,xe,Je,Ee,Ue,wt,tt,Xe,Be,Xe,Be;return s(this,function(vt){return this.ctx.save(),R=T1(S,C),H=Ay(S,C),L===2&&(this.path(H),this.ctx.clip()),Rs(H[0])?(j=H[0].start.x,Z=H[0].start.y):(j=H[0].x,Z=H[0].y),Rs(H[1])?(ee=H[1].end.x,oe=H[1].end.y):(ee=H[1].x,oe=H[1].y),C===0||C===2?_e=Math.abs(j-ee):_e=Math.abs(Z-oe),this.ctx.beginPath(),L===3?this.formatPath(R):this.formatPath(H.slice(0,2)),me=v<3?v*3:v*2,xe=v<3?v*2:v,L===3&&(me=v,xe=v),Je=!0,_e<=me*2?Je=!1:_e<=me*2+xe?(Ee=_e/(2*me+xe),me*=Ee,xe*=Ee):(Ue=Math.floor((_e+xe)/(me+xe)),wt=(_e-Ue*me)/(Ue-1),tt=(_e-(Ue+1)*me)/Ue,xe=tt<=0||Math.abs(xe-wt)<Math.abs(xe-tt)?wt:tt),Je&&(L===3?this.ctx.setLineDash([0,me+xe]):this.ctx.setLineDash([me,xe])),L===3?(this.ctx.lineCap="round",this.ctx.lineWidth=v):this.ctx.lineWidth=v*2+1.1,this.ctx.strokeStyle=Ii(x),this.ctx.stroke(),this.ctx.setLineDash([]),L===2&&(Rs(H[0])&&(Xe=H[3],Be=H[0],this.ctx.beginPath(),this.formatPath([new be(Xe.end.x,Xe.end.y),new be(Be.start.x,Be.start.y)]),this.ctx.stroke()),Rs(H[1])&&(Xe=H[1],Be=H[2],this.ctx.beginPath(),this.formatPath([new be(Xe.end.x,Xe.end.y),new be(Be.start.x,Be.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},f.prototype.render=function(x){return i(this,void 0,void 0,function(){var v;return s(this,function(C){switch(C.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=Ii(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),v=_1(x),[4,this.renderStack(v)];case 1:return C.sent(),this.applyEffects([]),[2,this.canvas]}})})},f})(hy),M1=function(p){return p instanceof km||p instanceof Qm?!0:p instanceof pd&&p.type!==El&&p.type!==kl},H1=function(p,f){switch(p){case 0:return Nl(f);case 2:return v1(f);case 1:default:return Vl(f)}},R1=function(p){switch(p){case 1:return"center";case 2:return"right";case 0:default:return"left"}},O1=["-apple-system","system-ui"],N1=function(p){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?p.filter(function(f){return O1.indexOf(f)===-1}):p},V1=(function(p){e(f,p);function f(x,v){var C=p.call(this,x,v)||this;return C.canvas=v.canvas?v.canvas:document.createElement("canvas"),C.ctx=C.canvas.getContext("2d"),C.options=v,C.canvas.width=Math.floor(v.width*v.scale),C.canvas.height=Math.floor(v.height*v.scale),C.canvas.style.width=v.width+"px",C.canvas.style.height=v.height+"px",C.ctx.scale(C.options.scale,C.options.scale),C.ctx.translate(-v.x,-v.y),C.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+v.width+"x"+v.height+" at "+v.x+","+v.y+") with scale "+v.scale),C}return f.prototype.render=function(x){return i(this,void 0,void 0,function(){var v,C;return s(this,function(S){switch(S.label){case 0:return v=ud(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,x),[4,$1(v)];case 1:return C=S.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=Ii(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(C,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},f})(hy),$1=function(p){return new Promise(function(f,x){var v=new Image;v.onload=function(){f(v)},v.onerror=x,v.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(p))})},K1=(function(){function p(f){var x=f.id,v=f.enabled;this.id=x,this.enabled=v,this.start=Date.now()}return p.prototype.debug=function(){for(var f=[],x=0;x<arguments.length;x++)f[x]=arguments[x];this.enabled&&(typeof window<"u"&&window.console&&typeof console.debug=="function"?console.debug.apply(console,r([this.id,this.getTime()+"ms"],f)):this.info.apply(this,f))},p.prototype.getTime=function(){return Date.now()-this.start},p.prototype.info=function(){for(var f=[],x=0;x<arguments.length;x++)f[x]=arguments[x];this.enabled&&typeof window<"u"&&window.console&&typeof console.info=="function"&&console.info.apply(console,r([this.id,this.getTime()+"ms"],f))},p.prototype.warn=function(){for(var f=[],x=0;x<arguments.length;x++)f[x]=arguments[x];this.enabled&&(typeof window<"u"&&window.console&&typeof console.warn=="function"?console.warn.apply(console,r([this.id,this.getTime()+"ms"],f)):this.info.apply(this,f))},p.prototype.error=function(){for(var f=[],x=0;x<arguments.length;x++)f[x]=arguments[x];this.enabled&&(typeof window<"u"&&window.console&&typeof console.error=="function"?console.error.apply(console,r([this.id,this.getTime()+"ms"],f)):this.info.apply(this,f))},p.instances={},p})(),G1=(function(){function p(f,x){var v;this.windowBounds=x,this.instanceName="#"+p.instanceCount++,this.logger=new K1({id:this.instanceName,enabled:f.logging}),this.cache=(v=f.cache)!==null&&v!==void 0?v:new c1(this,f)}return p.instanceCount=1,p})(),X1=function(p,f){return f===void 0&&(f={}),W1(p,f)};typeof window<"u"&&ty.setContext(window);var W1=function(p,f){return i(void 0,void 0,void 0,function(){var x,v,C,S,L,R,H,j,Z,ee,oe,_e,me,xe,Je,Ee,Ue,wt,tt,Xe,vt,Be,vt,xt,ze,vi,ps,Ts,Ut,Pi,Ua,ms,ys,mn,Sr,Qa,yn,vn,ia,xn;return s(this,function(sa){switch(sa.label){case 0:if(!p||typeof p!="object")return[2,Promise.reject("Invalid element provided as first argument")];if(x=p.ownerDocument,!x)throw new Error("Element is not attached to a Document");if(v=x.defaultView,!v)throw new Error("Document is not attached to a Window");return C={allowTaint:(xt=f.allowTaint)!==null&&xt!==void 0?xt:!1,imageTimeout:(ze=f.imageTimeout)!==null&&ze!==void 0?ze:15e3,proxy:f.proxy,useCORS:(vi=f.useCORS)!==null&&vi!==void 0?vi:!1},S=t({logging:(ps=f.logging)!==null&&ps!==void 0?ps:!0,cache:f.cache},C),L={windowWidth:(Ts=f.windowWidth)!==null&&Ts!==void 0?Ts:v.innerWidth,windowHeight:(Ut=f.windowHeight)!==null&&Ut!==void 0?Ut:v.innerHeight,scrollX:(Pi=f.scrollX)!==null&&Pi!==void 0?Pi:v.pageXOffset,scrollY:(Ua=f.scrollY)!==null&&Ua!==void 0?Ua:v.pageYOffset},R=new n(L.scrollX,L.scrollY,L.windowWidth,L.windowHeight),H=new G1(S,R),j=(ms=f.foreignObjectRendering)!==null&&ms!==void 0?ms:!1,Z={allowTaint:(ys=f.allowTaint)!==null&&ys!==void 0?ys:!1,onclone:f.onclone,ignoreElements:f.ignoreElements,inlineImages:j,copyStyles:j},H.logger.debug("Starting document clone with size "+R.width+"x"+R.height+" scrolled to "+-R.left+","+-R.top),ee=new Jm(H,p,Z),oe=ee.clonedReferenceElement,oe?[4,ee.toIFrame(x,R)]:[2,Promise.reject("Unable to find element in cloned iframe")];case 1:return _e=sa.sent(),me=yd(oe)||zS(oe)?o(oe.ownerDocument):A(H,oe),xe=me.width,Je=me.height,Ee=me.left,Ue=me.top,wt=z1(H,oe,f.backgroundColor),tt={canvas:f.canvas,backgroundColor:wt,scale:(Sr=(mn=f.scale)!==null&&mn!==void 0?mn:v.devicePixelRatio)!==null&&Sr!==void 0?Sr:1,x:((Qa=f.x)!==null&&Qa!==void 0?Qa:0)+Ee,y:((yn=f.y)!==null&&yn!==void 0?yn:0)+Ue,width:(vn=f.width)!==null&&vn!==void 0?vn:Math.ceil(xe),height:(ia=f.height)!==null&&ia!==void 0?ia:Math.ceil(Je)},j?(H.logger.debug("Document cloned, using foreign object rendering"),vt=new V1(H,tt),[4,vt.render(oe)]):[3,3];case 2:return Xe=sa.sent(),[3,5];case 3:return H.logger.debug("Document cloned, element located at "+Ee+","+Ue+" with size "+xe+"x"+Je+" using computed rendering"),H.logger.debug("Starting DOM parsing"),Be=Mm(H,oe),wt===Be.styles.backgroundColor&&(Be.styles.backgroundColor=ea.TRANSPARENT),H.logger.debug("Starting renderer for element at "+tt.x+","+tt.y+" with size "+tt.width+"x"+tt.height),vt=new P1(H,tt),[4,vt.render(Be)];case 4:Xe=sa.sent(),sa.label=5;case 5:return(!((xn=f.removeContainer)!==null&&xn!==void 0)||xn)&&(Jm.destroy(_e)||H.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")),H.logger.debug("Finished rendering"),[2,Xe]}})})},z1=function(p,f,x){var v=f.ownerDocument,C=v.documentElement?qA(p,getComputedStyle(v.documentElement).backgroundColor):ea.TRANSPARENT,S=v.body?qA(p,getComputedStyle(v.body).backgroundColor):ea.TRANSPARENT,L=typeof x=="string"?qA(p,x):x===null?ea.TRANSPARENT:4294967295;return f===v.documentElement?Ta(C)?Ta(S)?L:S:C:L};return X1}))});var Dx=cy((Ix,Af)=>{(function(a){typeof Ix=="object"&&typeof Af<"u"?Af.exports=a():typeof define=="function"&&define.amd?define([],a):(typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:this).JSZip=a()})(function(){return(function a(e,t,i){function s(A,o){if(!t[A]){if(!e[A]){var l=typeof no=="function"&&no;if(!o&&l)return l(A,!0);if(r)return r(A,!0);var c=new Error("Cannot find module '"+A+"'");throw c.code="MODULE_NOT_FOUND",c}var h=t[A]={exports:{}};e[A][0].call(h.exports,function(d){var u=e[A][1][d];return s(u||d)},h,h.exports,a,e,t,i)}return t[A].exports}for(var r=typeof no=="function"&&no,n=0;n<i.length;n++)s(i[n]);return s})({1:[function(a,e,t){"use strict";var i=a("./utils"),s=a("./support"),r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";t.encode=function(n){for(var A,o,l,c,h,d,u,g=[],y=0,m=n.length,b=m,B=i.getTypeOf(n)!=="string";y<n.length;)b=m-y,l=B?(A=n[y++],o=y<m?n[y++]:0,y<m?n[y++]:0):(A=n.charCodeAt(y++),o=y<m?n.charCodeAt(y++):0,y<m?n.charCodeAt(y++):0),c=A>>2,h=(3&A)<<4|o>>4,d=1<b?(15&o)<<2|l>>6:64,u=2<b?63&l:64,g.push(r.charAt(c)+r.charAt(h)+r.charAt(d)+r.charAt(u));return g.join("")},t.decode=function(n){var A,o,l,c,h,d,u=0,g=0,y="data:";if(n.substr(0,y.length)===y)throw new Error("Invalid base64 input, it looks like a data url.");var m,b=3*(n=n.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(n.charAt(n.length-1)===r.charAt(64)&&b--,n.charAt(n.length-2)===r.charAt(64)&&b--,b%1!=0)throw new Error("Invalid base64 input, bad content length.");for(m=s.uint8array?new Uint8Array(0|b):new Array(0|b);u<n.length;)A=r.indexOf(n.charAt(u++))<<2|(c=r.indexOf(n.charAt(u++)))>>4,o=(15&c)<<4|(h=r.indexOf(n.charAt(u++)))>>2,l=(3&h)<<6|(d=r.indexOf(n.charAt(u++))),m[g++]=A,h!==64&&(m[g++]=o),d!==64&&(m[g++]=l);return m}},{"./support":30,"./utils":32}],2:[function(a,e,t){"use strict";var i=a("./external"),s=a("./stream/DataWorker"),r=a("./stream/Crc32Probe"),n=a("./stream/DataLengthProbe");function A(o,l,c,h,d){this.compressedSize=o,this.uncompressedSize=l,this.crc32=c,this.compression=h,this.compressedContent=d}A.prototype={getContentWorker:function(){var o=new s(i.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new n("data_length")),l=this;return o.on("end",function(){if(this.streamInfo.data_length!==l.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),o},getCompressedWorker:function(){return new s(i.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},A.createWorkerFrom=function(o,l,c){return o.pipe(new r).pipe(new n("uncompressedSize")).pipe(l.compressWorker(c)).pipe(new n("compressedSize")).withStreamInfo("compression",l)},e.exports=A},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(a,e,t){"use strict";var i=a("./stream/GenericWorker");t.STORE={magic:"\0\0",compressWorker:function(){return new i("STORE compression")},uncompressWorker:function(){return new i("STORE decompression")}},t.DEFLATE=a("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(a,e,t){"use strict";var i=a("./utils"),s=(function(){for(var r,n=[],A=0;A<256;A++){r=A;for(var o=0;o<8;o++)r=1&r?3988292384^r>>>1:r>>>1;n[A]=r}return n})();e.exports=function(r,n){return r!==void 0&&r.length?i.getTypeOf(r)!=="string"?(function(A,o,l,c){var h=s,d=c+l;A^=-1;for(var u=c;u<d;u++)A=A>>>8^h[255&(A^o[u])];return-1^A})(0|n,r,r.length,0):(function(A,o,l,c){var h=s,d=c+l;A^=-1;for(var u=c;u<d;u++)A=A>>>8^h[255&(A^o.charCodeAt(u))];return-1^A})(0|n,r,r.length,0):0}},{"./utils":32}],5:[function(a,e,t){"use strict";t.base64=!1,t.binary=!1,t.dir=!1,t.createFolders=!0,t.date=null,t.compression=null,t.compressionOptions=null,t.comment=null,t.unixPermissions=null,t.dosPermissions=null},{}],6:[function(a,e,t){"use strict";var i=null;i=typeof Promise<"u"?Promise:a("lie"),e.exports={Promise:i}},{lie:37}],7:[function(a,e,t){"use strict";var i=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",s=a("pako"),r=a("./utils"),n=a("./stream/GenericWorker"),A=i?"uint8array":"array";function o(l,c){n.call(this,"FlateWorker/"+l),this._pako=null,this._pakoAction=l,this._pakoOptions=c,this.meta={}}t.magic="\b\0",r.inherits(o,n),o.prototype.processChunk=function(l){this.meta=l.meta,this._pako===null&&this._createPako(),this._pako.push(r.transformTo(A,l.data),!1)},o.prototype.flush=function(){n.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},o.prototype.cleanUp=function(){n.prototype.cleanUp.call(this),this._pako=null},o.prototype._createPako=function(){this._pako=new s[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var l=this;this._pako.onData=function(c){l.push({data:c,meta:l.meta})}},t.compressWorker=function(l){return new o("Deflate",l)},t.uncompressWorker=function(){return new o("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(a,e,t){"use strict";function i(h,d){var u,g="";for(u=0;u<d;u++)g+=String.fromCharCode(255&h),h>>>=8;return g}function s(h,d,u,g,y,m){var b,B,w=h.file,_=h.compression,T=m!==A.utf8encode,Q=r.transformTo("string",m(w.name)),U=r.transformTo("string",A.utf8encode(w.name)),E=w.comment,O=r.transformTo("string",m(E)),D=r.transformTo("string",A.utf8encode(E)),k=U.length!==w.name.length,F=D.length!==E.length,M="",Y="",z="",re=w.dir,q=w.date,Ae={crc32:0,compressedSize:0,uncompressedSize:0};d&&!u||(Ae.crc32=h.crc32,Ae.compressedSize=h.compressedSize,Ae.uncompressedSize=h.uncompressedSize);var X=0;d&&(X|=8),T||!k&&!F||(X|=2048);var G=0,ue=0;re&&(G|=16),y==="UNIX"?(ue=798,G|=(function(ae,Ie){var Pe=ae;return ae||(Pe=Ie?16893:33204),(65535&Pe)<<16})(w.unixPermissions,re)):(ue=20,G|=(function(ae){return 63&(ae||0)})(w.dosPermissions)),b=q.getUTCHours(),b<<=6,b|=q.getUTCMinutes(),b<<=5,b|=q.getUTCSeconds()/2,B=q.getUTCFullYear()-1980,B<<=4,B|=q.getUTCMonth()+1,B<<=5,B|=q.getUTCDate(),k&&(Y=i(1,1)+i(o(Q),4)+U,M+="up"+i(Y.length,2)+Y),F&&(z=i(1,1)+i(o(O),4)+D,M+="uc"+i(z.length,2)+z);var he="";return he+=`
7
- \0`,he+=i(X,2),he+=_.magic,he+=i(b,2),he+=i(B,2),he+=i(Ae.crc32,4),he+=i(Ae.compressedSize,4),he+=i(Ae.uncompressedSize,4),he+=i(Q.length,2),he+=i(M.length,2),{fileRecord:l.LOCAL_FILE_HEADER+he+Q+M,dirRecord:l.CENTRAL_FILE_HEADER+i(ue,2)+he+i(O.length,2)+"\0\0\0\0"+i(G,4)+i(g,4)+Q+M+O}}var r=a("../utils"),n=a("../stream/GenericWorker"),A=a("../utf8"),o=a("../crc32"),l=a("../signature");function c(h,d,u,g){n.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=d,this.zipPlatform=u,this.encodeFileName=g,this.streamFiles=h,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}r.inherits(c,n),c.prototype.push=function(h){var d=h.meta.percent||0,u=this.entriesCount,g=this._sources.length;this.accumulate?this.contentBuffer.push(h):(this.bytesWritten+=h.data.length,n.prototype.push.call(this,{data:h.data,meta:{currentFile:this.currentFile,percent:u?(d+100*(u-g-1))/u:100}}))},c.prototype.openedSource=function(h){this.currentSourceOffset=this.bytesWritten,this.currentFile=h.file.name;var d=this.streamFiles&&!h.file.dir;if(d){var u=s(h,d,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:u.fileRecord,meta:{percent:0}})}else this.accumulate=!0},c.prototype.closedSource=function(h){this.accumulate=!1;var d=this.streamFiles&&!h.file.dir,u=s(h,d,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(u.dirRecord),d)this.push({data:(function(g){return l.DATA_DESCRIPTOR+i(g.crc32,4)+i(g.compressedSize,4)+i(g.uncompressedSize,4)})(h),meta:{percent:100}});else for(this.push({data:u.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},c.prototype.flush=function(){for(var h=this.bytesWritten,d=0;d<this.dirRecords.length;d++)this.push({data:this.dirRecords[d],meta:{percent:100}});var u=this.bytesWritten-h,g=(function(y,m,b,B,w){var _=r.transformTo("string",w(B));return l.CENTRAL_DIRECTORY_END+"\0\0\0\0"+i(y,2)+i(y,2)+i(m,4)+i(b,4)+i(_.length,2)+_})(this.dirRecords.length,u,h,this.zipComment,this.encodeFileName);this.push({data:g,meta:{percent:100}})},c.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},c.prototype.registerPrevious=function(h){this._sources.push(h);var d=this;return h.on("data",function(u){d.processChunk(u)}),h.on("end",function(){d.closedSource(d.previous.streamInfo),d._sources.length?d.prepareNextSource():d.end()}),h.on("error",function(u){d.error(u)}),this},c.prototype.resume=function(){return!!n.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},c.prototype.error=function(h){var d=this._sources;if(!n.prototype.error.call(this,h))return!1;for(var u=0;u<d.length;u++)try{d[u].error(h)}catch{}return!0},c.prototype.lock=function(){n.prototype.lock.call(this);for(var h=this._sources,d=0;d<h.length;d++)h[d].lock()},e.exports=c},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(a,e,t){"use strict";var i=a("../compressions"),s=a("./ZipFileWorker");t.generateWorker=function(r,n,A){var o=new s(n.streamFiles,A,n.platform,n.encodeFileName),l=0;try{r.forEach(function(c,h){l++;var d=(function(m,b){var B=m||b,w=i[B];if(!w)throw new Error(B+" is not a valid compression method !");return w})(h.options.compression,n.compression),u=h.options.compressionOptions||n.compressionOptions||{},g=h.dir,y=h.date;h._compressWorker(d,u).withStreamInfo("file",{name:c,dir:g,date:y,comment:h.comment||"",unixPermissions:h.unixPermissions,dosPermissions:h.dosPermissions}).pipe(o)}),o.entriesCount=l}catch(c){o.error(c)}return o}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(a,e,t){"use strict";function i(){if(!(this instanceof i))return new i;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var s=new i;for(var r in this)typeof this[r]!="function"&&(s[r]=this[r]);return s}}(i.prototype=a("./object")).loadAsync=a("./load"),i.support=a("./support"),i.defaults=a("./defaults"),i.version="3.10.1",i.loadAsync=function(s,r){return new i().loadAsync(s,r)},i.external=a("./external"),e.exports=i},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(a,e,t){"use strict";var i=a("./utils"),s=a("./external"),r=a("./utf8"),n=a("./zipEntries"),A=a("./stream/Crc32Probe"),o=a("./nodejsUtils");function l(c){return new s.Promise(function(h,d){var u=c.decompressed.getContentWorker().pipe(new A);u.on("error",function(g){d(g)}).on("end",function(){u.streamInfo.crc32!==c.decompressed.crc32?d(new Error("Corrupted zip : CRC32 mismatch")):h()}).resume()})}e.exports=function(c,h){var d=this;return h=i.extend(h||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:r.utf8decode}),o.isNode&&o.isStream(c)?s.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):i.prepareContent("the loaded zip file",c,!0,h.optimizedBinaryString,h.base64).then(function(u){var g=new n(h);return g.load(u),g}).then(function(u){var g=[s.Promise.resolve(u)],y=u.files;if(h.checkCRC32)for(var m=0;m<y.length;m++)g.push(l(y[m]));return s.Promise.all(g)}).then(function(u){for(var g=u.shift(),y=g.files,m=0;m<y.length;m++){var b=y[m],B=b.fileNameStr,w=i.resolve(b.fileNameStr);d.file(w,b.decompressed,{binary:!0,optimizedBinaryString:!0,date:b.date,dir:b.dir,comment:b.fileCommentStr.length?b.fileCommentStr:null,unixPermissions:b.unixPermissions,dosPermissions:b.dosPermissions,createFolders:h.createFolders}),b.dir||(d.file(w).unsafeOriginalName=B)}return g.zipComment.length&&(d.comment=g.zipComment),d})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(a,e,t){"use strict";var i=a("../utils"),s=a("../stream/GenericWorker");function r(n,A){s.call(this,"Nodejs stream input adapter for "+n),this._upstreamEnded=!1,this._bindStream(A)}i.inherits(r,s),r.prototype._bindStream=function(n){var A=this;(this._stream=n).pause(),n.on("data",function(o){A.push({data:o,meta:{percent:0}})}).on("error",function(o){A.isPaused?this.generatedError=o:A.error(o)}).on("end",function(){A.isPaused?A._upstreamEnded=!0:A.end()})},r.prototype.pause=function(){return!!s.prototype.pause.call(this)&&(this._stream.pause(),!0)},r.prototype.resume=function(){return!!s.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},e.exports=r},{"../stream/GenericWorker":28,"../utils":32}],13:[function(a,e,t){"use strict";var i=a("readable-stream").Readable;function s(r,n,A){i.call(this,n),this._helper=r;var o=this;r.on("data",function(l,c){o.push(l)||o._helper.pause(),A&&A(c)}).on("error",function(l){o.emit("error",l)}).on("end",function(){o.push(null)})}a("../utils").inherits(s,i),s.prototype._read=function(){this._helper.resume()},e.exports=s},{"../utils":32,"readable-stream":16}],14:[function(a,e,t){"use strict";e.exports={isNode:typeof Buffer<"u",newBufferFrom:function(i,s){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from(i,s);if(typeof i=="number")throw new Error('The "data" argument must not be a number');return new Buffer(i,s)},allocBuffer:function(i){if(Buffer.alloc)return Buffer.alloc(i);var s=new Buffer(i);return s.fill(0),s},isBuffer:function(i){return Buffer.isBuffer(i)},isStream:function(i){return i&&typeof i.on=="function"&&typeof i.pause=="function"&&typeof i.resume=="function"}}},{}],15:[function(a,e,t){"use strict";function i(w,_,T){var Q,U=r.getTypeOf(_),E=r.extend(T||{},o);E.date=E.date||new Date,E.compression!==null&&(E.compression=E.compression.toUpperCase()),typeof E.unixPermissions=="string"&&(E.unixPermissions=parseInt(E.unixPermissions,8)),E.unixPermissions&&16384&E.unixPermissions&&(E.dir=!0),E.dosPermissions&&16&E.dosPermissions&&(E.dir=!0),E.dir&&(w=y(w)),E.createFolders&&(Q=g(w))&&m.call(this,Q,!0);var O=U==="string"&&E.binary===!1&&E.base64===!1;T&&T.binary!==void 0||(E.binary=!O),(_ instanceof l&&_.uncompressedSize===0||E.dir||!_||_.length===0)&&(E.base64=!1,E.binary=!0,_="",E.compression="STORE",U="string");var D=null;D=_ instanceof l||_ instanceof n?_:d.isNode&&d.isStream(_)?new u(w,_):r.prepareContent(w,_,E.binary,E.optimizedBinaryString,E.base64);var k=new c(w,D,E);this.files[w]=k}var s=a("./utf8"),r=a("./utils"),n=a("./stream/GenericWorker"),A=a("./stream/StreamHelper"),o=a("./defaults"),l=a("./compressedObject"),c=a("./zipObject"),h=a("./generate"),d=a("./nodejsUtils"),u=a("./nodejs/NodejsStreamInputAdapter"),g=function(w){w.slice(-1)==="/"&&(w=w.substring(0,w.length-1));var _=w.lastIndexOf("/");return 0<_?w.substring(0,_):""},y=function(w){return w.slice(-1)!=="/"&&(w+="/"),w},m=function(w,_){return _=_!==void 0?_:o.createFolders,w=y(w),this.files[w]||i.call(this,w,null,{dir:!0,createFolders:_}),this.files[w]};function b(w){return Object.prototype.toString.call(w)==="[object RegExp]"}var B={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(w){var _,T,Q;for(_ in this.files)Q=this.files[_],(T=_.slice(this.root.length,_.length))&&_.slice(0,this.root.length)===this.root&&w(T,Q)},filter:function(w){var _=[];return this.forEach(function(T,Q){w(T,Q)&&_.push(Q)}),_},file:function(w,_,T){if(arguments.length!==1)return w=this.root+w,i.call(this,w,_,T),this;if(b(w)){var Q=w;return this.filter(function(E,O){return!O.dir&&Q.test(E)})}var U=this.files[this.root+w];return U&&!U.dir?U:null},folder:function(w){if(!w)return this;if(b(w))return this.filter(function(U,E){return E.dir&&w.test(U)});var _=this.root+w,T=m.call(this,_),Q=this.clone();return Q.root=T.name,Q},remove:function(w){w=this.root+w;var _=this.files[w];if(_||(w.slice(-1)!=="/"&&(w+="/"),_=this.files[w]),_&&!_.dir)delete this.files[w];else for(var T=this.filter(function(U,E){return E.name.slice(0,w.length)===w}),Q=0;Q<T.length;Q++)delete this.files[T[Q].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(w){var _,T={};try{if((T=r.extend(w||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:s.utf8encode})).type=T.type.toLowerCase(),T.compression=T.compression.toUpperCase(),T.type==="binarystring"&&(T.type="string"),!T.type)throw new Error("No output type specified.");r.checkSupport(T.type),T.platform!=="darwin"&&T.platform!=="freebsd"&&T.platform!=="linux"&&T.platform!=="sunos"||(T.platform="UNIX"),T.platform==="win32"&&(T.platform="DOS");var Q=T.comment||this.comment||"";_=h.generateWorker(this,T,Q)}catch(U){(_=new n("error")).error(U)}return new A(_,T.type||"string",T.mimeType)},generateAsync:function(w,_){return this.generateInternalStream(w).accumulate(_)},generateNodeStream:function(w,_){return(w=w||{}).type||(w.type="nodebuffer"),this.generateInternalStream(w).toNodejsStream(_)}};e.exports=B},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(a,e,t){"use strict";e.exports=a("stream")},{stream:void 0}],17:[function(a,e,t){"use strict";var i=a("./DataReader");function s(r){i.call(this,r);for(var n=0;n<this.data.length;n++)r[n]=255&r[n]}a("../utils").inherits(s,i),s.prototype.byteAt=function(r){return this.data[this.zero+r]},s.prototype.lastIndexOfSignature=function(r){for(var n=r.charCodeAt(0),A=r.charCodeAt(1),o=r.charCodeAt(2),l=r.charCodeAt(3),c=this.length-4;0<=c;--c)if(this.data[c]===n&&this.data[c+1]===A&&this.data[c+2]===o&&this.data[c+3]===l)return c-this.zero;return-1},s.prototype.readAndCheckSignature=function(r){var n=r.charCodeAt(0),A=r.charCodeAt(1),o=r.charCodeAt(2),l=r.charCodeAt(3),c=this.readData(4);return n===c[0]&&A===c[1]&&o===c[2]&&l===c[3]},s.prototype.readData=function(r){if(this.checkOffset(r),r===0)return[];var n=this.data.slice(this.zero+this.index,this.zero+this.index+r);return this.index+=r,n},e.exports=s},{"../utils":32,"./DataReader":18}],18:[function(a,e,t){"use strict";var i=a("../utils");function s(r){this.data=r,this.length=r.length,this.index=0,this.zero=0}s.prototype={checkOffset:function(r){this.checkIndex(this.index+r)},checkIndex:function(r){if(this.length<this.zero+r||r<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+r+"). Corrupted zip ?")},setIndex:function(r){this.checkIndex(r),this.index=r},skip:function(r){this.setIndex(this.index+r)},byteAt:function(){},readInt:function(r){var n,A=0;for(this.checkOffset(r),n=this.index+r-1;n>=this.index;n--)A=(A<<8)+this.byteAt(n);return this.index+=r,A},readString:function(r){return i.transformTo("string",this.readData(r))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var r=this.readInt(4);return new Date(Date.UTC(1980+(r>>25&127),(r>>21&15)-1,r>>16&31,r>>11&31,r>>5&63,(31&r)<<1))}},e.exports=s},{"../utils":32}],19:[function(a,e,t){"use strict";var i=a("./Uint8ArrayReader");function s(r){i.call(this,r)}a("../utils").inherits(s,i),s.prototype.readData=function(r){this.checkOffset(r);var n=this.data.slice(this.zero+this.index,this.zero+this.index+r);return this.index+=r,n},e.exports=s},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(a,e,t){"use strict";var i=a("./DataReader");function s(r){i.call(this,r)}a("../utils").inherits(s,i),s.prototype.byteAt=function(r){return this.data.charCodeAt(this.zero+r)},s.prototype.lastIndexOfSignature=function(r){return this.data.lastIndexOf(r)-this.zero},s.prototype.readAndCheckSignature=function(r){return r===this.readData(4)},s.prototype.readData=function(r){this.checkOffset(r);var n=this.data.slice(this.zero+this.index,this.zero+this.index+r);return this.index+=r,n},e.exports=s},{"../utils":32,"./DataReader":18}],21:[function(a,e,t){"use strict";var i=a("./ArrayReader");function s(r){i.call(this,r)}a("../utils").inherits(s,i),s.prototype.readData=function(r){if(this.checkOffset(r),r===0)return new Uint8Array(0);var n=this.data.subarray(this.zero+this.index,this.zero+this.index+r);return this.index+=r,n},e.exports=s},{"../utils":32,"./ArrayReader":17}],22:[function(a,e,t){"use strict";var i=a("../utils"),s=a("../support"),r=a("./ArrayReader"),n=a("./StringReader"),A=a("./NodeBufferReader"),o=a("./Uint8ArrayReader");e.exports=function(l){var c=i.getTypeOf(l);return i.checkSupport(c),c!=="string"||s.uint8array?c==="nodebuffer"?new A(l):s.uint8array?new o(i.transformTo("uint8array",l)):new r(i.transformTo("array",l)):new n(l)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(a,e,t){"use strict";t.LOCAL_FILE_HEADER="PK",t.CENTRAL_FILE_HEADER="PK",t.CENTRAL_DIRECTORY_END="PK",t.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",t.ZIP64_CENTRAL_DIRECTORY_END="PK",t.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(a,e,t){"use strict";var i=a("./GenericWorker"),s=a("../utils");function r(n){i.call(this,"ConvertWorker to "+n),this.destType=n}s.inherits(r,i),r.prototype.processChunk=function(n){this.push({data:s.transformTo(this.destType,n.data),meta:n.meta})},e.exports=r},{"../utils":32,"./GenericWorker":28}],25:[function(a,e,t){"use strict";var i=a("./GenericWorker"),s=a("../crc32");function r(){i.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}a("../utils").inherits(r,i),r.prototype.processChunk=function(n){this.streamInfo.crc32=s(n.data,this.streamInfo.crc32||0),this.push(n)},e.exports=r},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(a,e,t){"use strict";var i=a("../utils"),s=a("./GenericWorker");function r(n){s.call(this,"DataLengthProbe for "+n),this.propName=n,this.withStreamInfo(n,0)}i.inherits(r,s),r.prototype.processChunk=function(n){if(n){var A=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=A+n.data.length}s.prototype.processChunk.call(this,n)},e.exports=r},{"../utils":32,"./GenericWorker":28}],27:[function(a,e,t){"use strict";var i=a("../utils"),s=a("./GenericWorker");function r(n){s.call(this,"DataWorker");var A=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,n.then(function(o){A.dataIsReady=!0,A.data=o,A.max=o&&o.length||0,A.type=i.getTypeOf(o),A.isPaused||A._tickAndRepeat()},function(o){A.error(o)})}i.inherits(r,s),r.prototype.cleanUp=function(){s.prototype.cleanUp.call(this),this.data=null},r.prototype.resume=function(){return!!s.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,i.delay(this._tickAndRepeat,[],this)),!0)},r.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(i.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},r.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var n=null,A=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":n=this.data.substring(this.index,A);break;case"uint8array":n=this.data.subarray(this.index,A);break;case"array":case"nodebuffer":n=this.data.slice(this.index,A)}return this.index=A,this.push({data:n,meta:{percent:this.max?this.index/this.max*100:0}})},e.exports=r},{"../utils":32,"./GenericWorker":28}],28:[function(a,e,t){"use strict";function i(s){this.name=s||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}i.prototype={push:function(s){this.emit("data",s)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(s){this.emit("error",s)}return!0},error:function(s){return!this.isFinished&&(this.isPaused?this.generatedError=s:(this.isFinished=!0,this.emit("error",s),this.previous&&this.previous.error(s),this.cleanUp()),!0)},on:function(s,r){return this._listeners[s].push(r),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(s,r){if(this._listeners[s])for(var n=0;n<this._listeners[s].length;n++)this._listeners[s][n].call(this,r)},pipe:function(s){return s.registerPrevious(this)},registerPrevious:function(s){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=s.streamInfo,this.mergeStreamInfo(),this.previous=s;var r=this;return s.on("data",function(n){r.processChunk(n)}),s.on("end",function(){r.end()}),s.on("error",function(n){r.error(n)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var s=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),s=!0),this.previous&&this.previous.resume(),!s},flush:function(){},processChunk:function(s){this.push(s)},withStreamInfo:function(s,r){return this.extraStreamInfo[s]=r,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var s in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,s)&&(this.streamInfo[s]=this.extraStreamInfo[s])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var s="Worker "+this.name;return this.previous?this.previous+" -> "+s:s}},e.exports=i},{}],29:[function(a,e,t){"use strict";var i=a("../utils"),s=a("./ConvertWorker"),r=a("./GenericWorker"),n=a("../base64"),A=a("../support"),o=a("../external"),l=null;if(A.nodestream)try{l=a("../nodejs/NodejsStreamOutputAdapter")}catch{}function c(d,u){return new o.Promise(function(g,y){var m=[],b=d._internalType,B=d._outputType,w=d._mimeType;d.on("data",function(_,T){m.push(_),u&&u(T)}).on("error",function(_){m=[],y(_)}).on("end",function(){try{var _=(function(T,Q,U){switch(T){case"blob":return i.newBlob(i.transformTo("arraybuffer",Q),U);case"base64":return n.encode(Q);default:return i.transformTo(T,Q)}})(B,(function(T,Q){var U,E=0,O=null,D=0;for(U=0;U<Q.length;U++)D+=Q[U].length;switch(T){case"string":return Q.join("");case"array":return Array.prototype.concat.apply([],Q);case"uint8array":for(O=new Uint8Array(D),U=0;U<Q.length;U++)O.set(Q[U],E),E+=Q[U].length;return O;case"nodebuffer":return Buffer.concat(Q);default:throw new Error("concat : unsupported type '"+T+"'")}})(b,m),w);g(_)}catch(T){y(T)}m=[]}).resume()})}function h(d,u,g){var y=u;switch(u){case"blob":case"arraybuffer":y="uint8array";break;case"base64":y="string"}try{this._internalType=y,this._outputType=u,this._mimeType=g,i.checkSupport(y),this._worker=d.pipe(new s(y)),d.lock()}catch(m){this._worker=new r("error"),this._worker.error(m)}}h.prototype={accumulate:function(d){return c(this,d)},on:function(d,u){var g=this;return d==="data"?this._worker.on(d,function(y){u.call(g,y.data,y.meta)}):this._worker.on(d,function(){i.delay(u,arguments,g)}),this},resume:function(){return i.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(d){if(i.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new l(this,{objectMode:this._outputType!=="nodebuffer"},d)}},e.exports=h},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(a,e,t){"use strict";if(t.base64=!0,t.array=!0,t.string=!0,t.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",t.nodebuffer=typeof Buffer<"u",t.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")t.blob=!1;else{var i=new ArrayBuffer(0);try{t.blob=new Blob([i],{type:"application/zip"}).size===0}catch{try{var s=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);s.append(i),t.blob=s.getBlob("application/zip").size===0}catch{t.blob=!1}}}try{t.nodestream=!!a("readable-stream").Readable}catch{t.nodestream=!1}},{"readable-stream":16}],31:[function(a,e,t){"use strict";for(var i=a("./utils"),s=a("./support"),r=a("./nodejsUtils"),n=a("./stream/GenericWorker"),A=new Array(256),o=0;o<256;o++)A[o]=252<=o?6:248<=o?5:240<=o?4:224<=o?3:192<=o?2:1;A[254]=A[254]=1;function l(){n.call(this,"utf-8 decode"),this.leftOver=null}function c(){n.call(this,"utf-8 encode")}t.utf8encode=function(h){return s.nodebuffer?r.newBufferFrom(h,"utf-8"):(function(d){var u,g,y,m,b,B=d.length,w=0;for(m=0;m<B;m++)(64512&(g=d.charCodeAt(m)))==55296&&m+1<B&&(64512&(y=d.charCodeAt(m+1)))==56320&&(g=65536+(g-55296<<10)+(y-56320),m++),w+=g<128?1:g<2048?2:g<65536?3:4;for(u=s.uint8array?new Uint8Array(w):new Array(w),m=b=0;b<w;m++)(64512&(g=d.charCodeAt(m)))==55296&&m+1<B&&(64512&(y=d.charCodeAt(m+1)))==56320&&(g=65536+(g-55296<<10)+(y-56320),m++),g<128?u[b++]=g:(g<2048?u[b++]=192|g>>>6:(g<65536?u[b++]=224|g>>>12:(u[b++]=240|g>>>18,u[b++]=128|g>>>12&63),u[b++]=128|g>>>6&63),u[b++]=128|63&g);return u})(h)},t.utf8decode=function(h){return s.nodebuffer?i.transformTo("nodebuffer",h).toString("utf-8"):(function(d){var u,g,y,m,b=d.length,B=new Array(2*b);for(u=g=0;u<b;)if((y=d[u++])<128)B[g++]=y;else if(4<(m=A[y]))B[g++]=65533,u+=m-1;else{for(y&=m===2?31:m===3?15:7;1<m&&u<b;)y=y<<6|63&d[u++],m--;1<m?B[g++]=65533:y<65536?B[g++]=y:(y-=65536,B[g++]=55296|y>>10&1023,B[g++]=56320|1023&y)}return B.length!==g&&(B.subarray?B=B.subarray(0,g):B.length=g),i.applyFromCharCode(B)})(h=i.transformTo(s.uint8array?"uint8array":"array",h))},i.inherits(l,n),l.prototype.processChunk=function(h){var d=i.transformTo(s.uint8array?"uint8array":"array",h.data);if(this.leftOver&&this.leftOver.length){if(s.uint8array){var u=d;(d=new Uint8Array(u.length+this.leftOver.length)).set(this.leftOver,0),d.set(u,this.leftOver.length)}else d=this.leftOver.concat(d);this.leftOver=null}var g=(function(m,b){var B;for((b=b||m.length)>m.length&&(b=m.length),B=b-1;0<=B&&(192&m[B])==128;)B--;return B<0||B===0?b:B+A[m[B]]>b?B:b})(d),y=d;g!==d.length&&(s.uint8array?(y=d.subarray(0,g),this.leftOver=d.subarray(g,d.length)):(y=d.slice(0,g),this.leftOver=d.slice(g,d.length))),this.push({data:t.utf8decode(y),meta:h.meta})},l.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:t.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},t.Utf8DecodeWorker=l,i.inherits(c,n),c.prototype.processChunk=function(h){this.push({data:t.utf8encode(h.data),meta:h.meta})},t.Utf8EncodeWorker=c},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(a,e,t){"use strict";var i=a("./support"),s=a("./base64"),r=a("./nodejsUtils"),n=a("./external");function A(u){return u}function o(u,g){for(var y=0;y<u.length;++y)g[y]=255&u.charCodeAt(y);return g}a("setimmediate"),t.newBlob=function(u,g){t.checkSupport("blob");try{return new Blob([u],{type:g})}catch{try{var y=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return y.append(u),y.getBlob(g)}catch{throw new Error("Bug : can't construct the Blob.")}}};var l={stringifyByChunk:function(u,g,y){var m=[],b=0,B=u.length;if(B<=y)return String.fromCharCode.apply(null,u);for(;b<B;)g==="array"||g==="nodebuffer"?m.push(String.fromCharCode.apply(null,u.slice(b,Math.min(b+y,B)))):m.push(String.fromCharCode.apply(null,u.subarray(b,Math.min(b+y,B)))),b+=y;return m.join("")},stringifyByChar:function(u){for(var g="",y=0;y<u.length;y++)g+=String.fromCharCode(u[y]);return g},applyCanBeUsed:{uint8array:(function(){try{return i.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}})(),nodebuffer:(function(){try{return i.nodebuffer&&String.fromCharCode.apply(null,r.allocBuffer(1)).length===1}catch{return!1}})()}};function c(u){var g=65536,y=t.getTypeOf(u),m=!0;if(y==="uint8array"?m=l.applyCanBeUsed.uint8array:y==="nodebuffer"&&(m=l.applyCanBeUsed.nodebuffer),m)for(;1<g;)try{return l.stringifyByChunk(u,y,g)}catch{g=Math.floor(g/2)}return l.stringifyByChar(u)}function h(u,g){for(var y=0;y<u.length;y++)g[y]=u[y];return g}t.applyFromCharCode=c;var d={};d.string={string:A,array:function(u){return o(u,new Array(u.length))},arraybuffer:function(u){return d.string.uint8array(u).buffer},uint8array:function(u){return o(u,new Uint8Array(u.length))},nodebuffer:function(u){return o(u,r.allocBuffer(u.length))}},d.array={string:c,array:A,arraybuffer:function(u){return new Uint8Array(u).buffer},uint8array:function(u){return new Uint8Array(u)},nodebuffer:function(u){return r.newBufferFrom(u)}},d.arraybuffer={string:function(u){return c(new Uint8Array(u))},array:function(u){return h(new Uint8Array(u),new Array(u.byteLength))},arraybuffer:A,uint8array:function(u){return new Uint8Array(u)},nodebuffer:function(u){return r.newBufferFrom(new Uint8Array(u))}},d.uint8array={string:c,array:function(u){return h(u,new Array(u.length))},arraybuffer:function(u){return u.buffer},uint8array:A,nodebuffer:function(u){return r.newBufferFrom(u)}},d.nodebuffer={string:c,array:function(u){return h(u,new Array(u.length))},arraybuffer:function(u){return d.nodebuffer.uint8array(u).buffer},uint8array:function(u){return h(u,new Uint8Array(u.length))},nodebuffer:A},t.transformTo=function(u,g){if(g=g||"",!u)return g;t.checkSupport(u);var y=t.getTypeOf(g);return d[y][u](g)},t.resolve=function(u){for(var g=u.split("/"),y=[],m=0;m<g.length;m++){var b=g[m];b==="."||b===""&&m!==0&&m!==g.length-1||(b===".."?y.pop():y.push(b))}return y.join("/")},t.getTypeOf=function(u){return typeof u=="string"?"string":Object.prototype.toString.call(u)==="[object Array]"?"array":i.nodebuffer&&r.isBuffer(u)?"nodebuffer":i.uint8array&&u instanceof Uint8Array?"uint8array":i.arraybuffer&&u instanceof ArrayBuffer?"arraybuffer":void 0},t.checkSupport=function(u){if(!i[u.toLowerCase()])throw new Error(u+" is not supported by this platform")},t.MAX_VALUE_16BITS=65535,t.MAX_VALUE_32BITS=-1,t.pretty=function(u){var g,y,m="";for(y=0;y<(u||"").length;y++)m+="\\x"+((g=u.charCodeAt(y))<16?"0":"")+g.toString(16).toUpperCase();return m},t.delay=function(u,g,y){setImmediate(function(){u.apply(y||null,g||[])})},t.inherits=function(u,g){function y(){}y.prototype=g.prototype,u.prototype=new y},t.extend=function(){var u,g,y={};for(u=0;u<arguments.length;u++)for(g in arguments[u])Object.prototype.hasOwnProperty.call(arguments[u],g)&&y[g]===void 0&&(y[g]=arguments[u][g]);return y},t.prepareContent=function(u,g,y,m,b){return n.Promise.resolve(g).then(function(B){return i.blob&&(B instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(B))!==-1)&&typeof FileReader<"u"?new n.Promise(function(w,_){var T=new FileReader;T.onload=function(Q){w(Q.target.result)},T.onerror=function(Q){_(Q.target.error)},T.readAsArrayBuffer(B)}):B}).then(function(B){var w=t.getTypeOf(B);return w?(w==="arraybuffer"?B=t.transformTo("uint8array",B):w==="string"&&(b?B=s.decode(B):y&&m!==!0&&(B=(function(_){return o(_,i.uint8array?new Uint8Array(_.length):new Array(_.length))})(B))),B):n.Promise.reject(new Error("Can't read the data of '"+u+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(a,e,t){"use strict";var i=a("./reader/readerFor"),s=a("./utils"),r=a("./signature"),n=a("./zipEntry"),A=a("./support");function o(l){this.files=[],this.loadOptions=l}o.prototype={checkSignature:function(l){if(!this.reader.readAndCheckSignature(l)){this.reader.index-=4;var c=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+s.pretty(c)+", expected "+s.pretty(l)+")")}},isSignature:function(l,c){var h=this.reader.index;this.reader.setIndex(l);var d=this.reader.readString(4)===c;return this.reader.setIndex(h),d},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var l=this.reader.readData(this.zipCommentLength),c=A.uint8array?"uint8array":"array",h=s.transformTo(c,l);this.zipComment=this.loadOptions.decodeFileName(h)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var l,c,h,d=this.zip64EndOfCentralSize-44;0<d;)l=this.reader.readInt(2),c=this.reader.readInt(4),h=this.reader.readData(c),this.zip64ExtensibleData[l]={id:l,length:c,value:h}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var l,c;for(l=0;l<this.files.length;l++)c=this.files[l],this.reader.setIndex(c.localHeaderOffset),this.checkSignature(r.LOCAL_FILE_HEADER),c.readLocalPart(this.reader),c.handleUTF8(),c.processAttributes()},readCentralDir:function(){var l;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(r.CENTRAL_FILE_HEADER);)(l=new n({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(l);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var l=this.reader.lastIndexOfSignature(r.CENTRAL_DIRECTORY_END);if(l<0)throw this.isSignature(0,r.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(l);var c=l;if(this.checkSignature(r.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===s.MAX_VALUE_16BITS||this.diskWithCentralDirStart===s.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===s.MAX_VALUE_16BITS||this.centralDirRecords===s.MAX_VALUE_16BITS||this.centralDirSize===s.MAX_VALUE_32BITS||this.centralDirOffset===s.MAX_VALUE_32BITS){if(this.zip64=!0,(l=this.reader.lastIndexOfSignature(r.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(l),this.checkSignature(r.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,r.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(r.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(r.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var h=this.centralDirOffset+this.centralDirSize;this.zip64&&(h+=20,h+=12+this.zip64EndOfCentralSize);var d=c-h;if(0<d)this.isSignature(c,r.CENTRAL_FILE_HEADER)||(this.reader.zero=d);else if(d<0)throw new Error("Corrupted zip: missing "+Math.abs(d)+" bytes.")},prepareReader:function(l){this.reader=i(l)},load:function(l){this.prepareReader(l),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},e.exports=o},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(a,e,t){"use strict";var i=a("./reader/readerFor"),s=a("./utils"),r=a("./compressedObject"),n=a("./crc32"),A=a("./utf8"),o=a("./compressions"),l=a("./support");function c(h,d){this.options=h,this.loadOptions=d}c.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(h){var d,u;if(h.skip(22),this.fileNameLength=h.readInt(2),u=h.readInt(2),this.fileName=h.readData(this.fileNameLength),h.skip(u),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((d=(function(g){for(var y in o)if(Object.prototype.hasOwnProperty.call(o,y)&&o[y].magic===g)return o[y];return null})(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+s.pretty(this.compressionMethod)+" unknown (inner file : "+s.transformTo("string",this.fileName)+")");this.decompressed=new r(this.compressedSize,this.uncompressedSize,this.crc32,d,h.readData(this.compressedSize))},readCentralPart:function(h){this.versionMadeBy=h.readInt(2),h.skip(2),this.bitFlag=h.readInt(2),this.compressionMethod=h.readString(2),this.date=h.readDate(),this.crc32=h.readInt(4),this.compressedSize=h.readInt(4),this.uncompressedSize=h.readInt(4);var d=h.readInt(2);if(this.extraFieldsLength=h.readInt(2),this.fileCommentLength=h.readInt(2),this.diskNumberStart=h.readInt(2),this.internalFileAttributes=h.readInt(2),this.externalFileAttributes=h.readInt(4),this.localHeaderOffset=h.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");h.skip(d),this.readExtraFields(h),this.parseZIP64ExtraField(h),this.fileComment=h.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var h=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),h==0&&(this.dosPermissions=63&this.externalFileAttributes),h==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var h=i(this.extraFields[1].value);this.uncompressedSize===s.MAX_VALUE_32BITS&&(this.uncompressedSize=h.readInt(8)),this.compressedSize===s.MAX_VALUE_32BITS&&(this.compressedSize=h.readInt(8)),this.localHeaderOffset===s.MAX_VALUE_32BITS&&(this.localHeaderOffset=h.readInt(8)),this.diskNumberStart===s.MAX_VALUE_32BITS&&(this.diskNumberStart=h.readInt(4))}},readExtraFields:function(h){var d,u,g,y=h.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});h.index+4<y;)d=h.readInt(2),u=h.readInt(2),g=h.readData(u),this.extraFields[d]={id:d,length:u,value:g};h.setIndex(y)},handleUTF8:function(){var h=l.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=A.utf8decode(this.fileName),this.fileCommentStr=A.utf8decode(this.fileComment);else{var d=this.findExtraFieldUnicodePath();if(d!==null)this.fileNameStr=d;else{var u=s.transformTo(h,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(u)}var g=this.findExtraFieldUnicodeComment();if(g!==null)this.fileCommentStr=g;else{var y=s.transformTo(h,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(y)}}},findExtraFieldUnicodePath:function(){var h=this.extraFields[28789];if(h){var d=i(h.value);return d.readInt(1)!==1||n(this.fileName)!==d.readInt(4)?null:A.utf8decode(d.readData(h.length-5))}return null},findExtraFieldUnicodeComment:function(){var h=this.extraFields[25461];if(h){var d=i(h.value);return d.readInt(1)!==1||n(this.fileComment)!==d.readInt(4)?null:A.utf8decode(d.readData(h.length-5))}return null}},e.exports=c},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(a,e,t){"use strict";function i(d,u,g){this.name=d,this.dir=g.dir,this.date=g.date,this.comment=g.comment,this.unixPermissions=g.unixPermissions,this.dosPermissions=g.dosPermissions,this._data=u,this._dataBinary=g.binary,this.options={compression:g.compression,compressionOptions:g.compressionOptions}}var s=a("./stream/StreamHelper"),r=a("./stream/DataWorker"),n=a("./utf8"),A=a("./compressedObject"),o=a("./stream/GenericWorker");i.prototype={internalStream:function(d){var u=null,g="string";try{if(!d)throw new Error("No output type specified.");var y=(g=d.toLowerCase())==="string"||g==="text";g!=="binarystring"&&g!=="text"||(g="string"),u=this._decompressWorker();var m=!this._dataBinary;m&&!y&&(u=u.pipe(new n.Utf8EncodeWorker)),!m&&y&&(u=u.pipe(new n.Utf8DecodeWorker))}catch(b){(u=new o("error")).error(b)}return new s(u,g,"")},async:function(d,u){return this.internalStream(d).accumulate(u)},nodeStream:function(d,u){return this.internalStream(d||"nodebuffer").toNodejsStream(u)},_compressWorker:function(d,u){if(this._data instanceof A&&this._data.compression.magic===d.magic)return this._data.getCompressedWorker();var g=this._decompressWorker();return this._dataBinary||(g=g.pipe(new n.Utf8EncodeWorker)),A.createWorkerFrom(g,d,u)},_decompressWorker:function(){return this._data instanceof A?this._data.getContentWorker():this._data instanceof o?this._data:new r(this._data)}};for(var l=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],c=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},h=0;h<l.length;h++)i.prototype[l[h]]=c;e.exports=i},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(a,e,t){(function(i){"use strict";var s,r,n=i.MutationObserver||i.WebKitMutationObserver;if(n){var A=0,o=new n(d),l=i.document.createTextNode("");o.observe(l,{characterData:!0}),s=function(){l.data=A=++A%2}}else if(i.setImmediate||i.MessageChannel===void 0)s="document"in i&&"onreadystatechange"in i.document.createElement("script")?function(){var u=i.document.createElement("script");u.onreadystatechange=function(){d(),u.onreadystatechange=null,u.parentNode.removeChild(u),u=null},i.document.documentElement.appendChild(u)}:function(){setTimeout(d,0)};else{var c=new i.MessageChannel;c.port1.onmessage=d,s=function(){c.port2.postMessage(0)}}var h=[];function d(){var u,g;r=!0;for(var y=h.length;y;){for(g=h,h=[],u=-1;++u<y;)g[u]();y=h.length}r=!1}e.exports=function(u){h.push(u)!==1||r||s()}}).call(this,typeof global<"u"?global:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(a,e,t){"use strict";var i=a("immediate");function s(){}var r={},n=["REJECTED"],A=["FULFILLED"],o=["PENDING"];function l(y){if(typeof y!="function")throw new TypeError("resolver must be a function");this.state=o,this.queue=[],this.outcome=void 0,y!==s&&u(this,y)}function c(y,m,b){this.promise=y,typeof m=="function"&&(this.onFulfilled=m,this.callFulfilled=this.otherCallFulfilled),typeof b=="function"&&(this.onRejected=b,this.callRejected=this.otherCallRejected)}function h(y,m,b){i(function(){var B;try{B=m(b)}catch(w){return r.reject(y,w)}B===y?r.reject(y,new TypeError("Cannot resolve promise with itself")):r.resolve(y,B)})}function d(y){var m=y&&y.then;if(y&&(typeof y=="object"||typeof y=="function")&&typeof m=="function")return function(){m.apply(y,arguments)}}function u(y,m){var b=!1;function B(T){b||(b=!0,r.reject(y,T))}function w(T){b||(b=!0,r.resolve(y,T))}var _=g(function(){m(w,B)});_.status==="error"&&B(_.value)}function g(y,m){var b={};try{b.value=y(m),b.status="success"}catch(B){b.status="error",b.value=B}return b}(e.exports=l).prototype.finally=function(y){if(typeof y!="function")return this;var m=this.constructor;return this.then(function(b){return m.resolve(y()).then(function(){return b})},function(b){return m.resolve(y()).then(function(){throw b})})},l.prototype.catch=function(y){return this.then(null,y)},l.prototype.then=function(y,m){if(typeof y!="function"&&this.state===A||typeof m!="function"&&this.state===n)return this;var b=new this.constructor(s);return this.state!==o?h(b,this.state===A?y:m,this.outcome):this.queue.push(new c(b,y,m)),b},c.prototype.callFulfilled=function(y){r.resolve(this.promise,y)},c.prototype.otherCallFulfilled=function(y){h(this.promise,this.onFulfilled,y)},c.prototype.callRejected=function(y){r.reject(this.promise,y)},c.prototype.otherCallRejected=function(y){h(this.promise,this.onRejected,y)},r.resolve=function(y,m){var b=g(d,m);if(b.status==="error")return r.reject(y,b.value);var B=b.value;if(B)u(y,B);else{y.state=A,y.outcome=m;for(var w=-1,_=y.queue.length;++w<_;)y.queue[w].callFulfilled(m)}return y},r.reject=function(y,m){y.state=n,y.outcome=m;for(var b=-1,B=y.queue.length;++b<B;)y.queue[b].callRejected(m);return y},l.resolve=function(y){return y instanceof this?y:r.resolve(new this(s),y)},l.reject=function(y){var m=new this(s);return r.reject(m,y)},l.all=function(y){var m=this;if(Object.prototype.toString.call(y)!=="[object Array]")return this.reject(new TypeError("must be an array"));var b=y.length,B=!1;if(!b)return this.resolve([]);for(var w=new Array(b),_=0,T=-1,Q=new this(s);++T<b;)U(y[T],T);return Q;function U(E,O){m.resolve(E).then(function(D){w[O]=D,++_!==b||B||(B=!0,r.resolve(Q,w))},function(D){B||(B=!0,r.reject(Q,D))})}},l.race=function(y){var m=this;if(Object.prototype.toString.call(y)!=="[object Array]")return this.reject(new TypeError("must be an array"));var b=y.length,B=!1;if(!b)return this.resolve([]);for(var w=-1,_=new this(s);++w<b;)T=y[w],m.resolve(T).then(function(Q){B||(B=!0,r.resolve(_,Q))},function(Q){B||(B=!0,r.reject(_,Q))});var T;return _}},{immediate:36}],38:[function(a,e,t){"use strict";var i={};(0,a("./lib/utils/common").assign)(i,a("./lib/deflate"),a("./lib/inflate"),a("./lib/zlib/constants")),e.exports=i},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(a,e,t){"use strict";var i=a("./zlib/deflate"),s=a("./utils/common"),r=a("./utils/strings"),n=a("./zlib/messages"),A=a("./zlib/zstream"),o=Object.prototype.toString,l=0,c=-1,h=0,d=8;function u(y){if(!(this instanceof u))return new u(y);this.options=s.assign({level:c,method:d,chunkSize:16384,windowBits:15,memLevel:8,strategy:h,to:""},y||{});var m=this.options;m.raw&&0<m.windowBits?m.windowBits=-m.windowBits:m.gzip&&0<m.windowBits&&m.windowBits<16&&(m.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new A,this.strm.avail_out=0;var b=i.deflateInit2(this.strm,m.level,m.method,m.windowBits,m.memLevel,m.strategy);if(b!==l)throw new Error(n[b]);if(m.header&&i.deflateSetHeader(this.strm,m.header),m.dictionary){var B;if(B=typeof m.dictionary=="string"?r.string2buf(m.dictionary):o.call(m.dictionary)==="[object ArrayBuffer]"?new Uint8Array(m.dictionary):m.dictionary,(b=i.deflateSetDictionary(this.strm,B))!==l)throw new Error(n[b]);this._dict_set=!0}}function g(y,m){var b=new u(m);if(b.push(y,!0),b.err)throw b.msg||n[b.err];return b.result}u.prototype.push=function(y,m){var b,B,w=this.strm,_=this.options.chunkSize;if(this.ended)return!1;B=m===~~m?m:m===!0?4:0,typeof y=="string"?w.input=r.string2buf(y):o.call(y)==="[object ArrayBuffer]"?w.input=new Uint8Array(y):w.input=y,w.next_in=0,w.avail_in=w.input.length;do{if(w.avail_out===0&&(w.output=new s.Buf8(_),w.next_out=0,w.avail_out=_),(b=i.deflate(w,B))!==1&&b!==l)return this.onEnd(b),!(this.ended=!0);w.avail_out!==0&&(w.avail_in!==0||B!==4&&B!==2)||(this.options.to==="string"?this.onData(r.buf2binstring(s.shrinkBuf(w.output,w.next_out))):this.onData(s.shrinkBuf(w.output,w.next_out)))}while((0<w.avail_in||w.avail_out===0)&&b!==1);return B===4?(b=i.deflateEnd(this.strm),this.onEnd(b),this.ended=!0,b===l):B!==2||(this.onEnd(l),!(w.avail_out=0))},u.prototype.onData=function(y){this.chunks.push(y)},u.prototype.onEnd=function(y){y===l&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=s.flattenChunks(this.chunks)),this.chunks=[],this.err=y,this.msg=this.strm.msg},t.Deflate=u,t.deflate=g,t.deflateRaw=function(y,m){return(m=m||{}).raw=!0,g(y,m)},t.gzip=function(y,m){return(m=m||{}).gzip=!0,g(y,m)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(a,e,t){"use strict";var i=a("./zlib/inflate"),s=a("./utils/common"),r=a("./utils/strings"),n=a("./zlib/constants"),A=a("./zlib/messages"),o=a("./zlib/zstream"),l=a("./zlib/gzheader"),c=Object.prototype.toString;function h(u){if(!(this instanceof h))return new h(u);this.options=s.assign({chunkSize:16384,windowBits:0,to:""},u||{});var g=this.options;g.raw&&0<=g.windowBits&&g.windowBits<16&&(g.windowBits=-g.windowBits,g.windowBits===0&&(g.windowBits=-15)),!(0<=g.windowBits&&g.windowBits<16)||u&&u.windowBits||(g.windowBits+=32),15<g.windowBits&&g.windowBits<48&&(15&g.windowBits)==0&&(g.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new o,this.strm.avail_out=0;var y=i.inflateInit2(this.strm,g.windowBits);if(y!==n.Z_OK)throw new Error(A[y]);this.header=new l,i.inflateGetHeader(this.strm,this.header)}function d(u,g){var y=new h(g);if(y.push(u,!0),y.err)throw y.msg||A[y.err];return y.result}h.prototype.push=function(u,g){var y,m,b,B,w,_,T=this.strm,Q=this.options.chunkSize,U=this.options.dictionary,E=!1;if(this.ended)return!1;m=g===~~g?g:g===!0?n.Z_FINISH:n.Z_NO_FLUSH,typeof u=="string"?T.input=r.binstring2buf(u):c.call(u)==="[object ArrayBuffer]"?T.input=new Uint8Array(u):T.input=u,T.next_in=0,T.avail_in=T.input.length;do{if(T.avail_out===0&&(T.output=new s.Buf8(Q),T.next_out=0,T.avail_out=Q),(y=i.inflate(T,n.Z_NO_FLUSH))===n.Z_NEED_DICT&&U&&(_=typeof U=="string"?r.string2buf(U):c.call(U)==="[object ArrayBuffer]"?new Uint8Array(U):U,y=i.inflateSetDictionary(this.strm,_)),y===n.Z_BUF_ERROR&&E===!0&&(y=n.Z_OK,E=!1),y!==n.Z_STREAM_END&&y!==n.Z_OK)return this.onEnd(y),!(this.ended=!0);T.next_out&&(T.avail_out!==0&&y!==n.Z_STREAM_END&&(T.avail_in!==0||m!==n.Z_FINISH&&m!==n.Z_SYNC_FLUSH)||(this.options.to==="string"?(b=r.utf8border(T.output,T.next_out),B=T.next_out-b,w=r.buf2string(T.output,b),T.next_out=B,T.avail_out=Q-B,B&&s.arraySet(T.output,T.output,b,B,0),this.onData(w)):this.onData(s.shrinkBuf(T.output,T.next_out)))),T.avail_in===0&&T.avail_out===0&&(E=!0)}while((0<T.avail_in||T.avail_out===0)&&y!==n.Z_STREAM_END);return y===n.Z_STREAM_END&&(m=n.Z_FINISH),m===n.Z_FINISH?(y=i.inflateEnd(this.strm),this.onEnd(y),this.ended=!0,y===n.Z_OK):m!==n.Z_SYNC_FLUSH||(this.onEnd(n.Z_OK),!(T.avail_out=0))},h.prototype.onData=function(u){this.chunks.push(u)},h.prototype.onEnd=function(u){u===n.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=s.flattenChunks(this.chunks)),this.chunks=[],this.err=u,this.msg=this.strm.msg},t.Inflate=h,t.inflate=d,t.inflateRaw=function(u,g){return(g=g||{}).raw=!0,d(u,g)},t.ungzip=d},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(a,e,t){"use strict";var i=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";t.assign=function(n){for(var A=Array.prototype.slice.call(arguments,1);A.length;){var o=A.shift();if(o){if(typeof o!="object")throw new TypeError(o+"must be non-object");for(var l in o)o.hasOwnProperty(l)&&(n[l]=o[l])}}return n},t.shrinkBuf=function(n,A){return n.length===A?n:n.subarray?n.subarray(0,A):(n.length=A,n)};var s={arraySet:function(n,A,o,l,c){if(A.subarray&&n.subarray)n.set(A.subarray(o,o+l),c);else for(var h=0;h<l;h++)n[c+h]=A[o+h]},flattenChunks:function(n){var A,o,l,c,h,d;for(A=l=0,o=n.length;A<o;A++)l+=n[A].length;for(d=new Uint8Array(l),A=c=0,o=n.length;A<o;A++)h=n[A],d.set(h,c),c+=h.length;return d}},r={arraySet:function(n,A,o,l,c){for(var h=0;h<l;h++)n[c+h]=A[o+h]},flattenChunks:function(n){return[].concat.apply([],n)}};t.setTyped=function(n){n?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,s)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,r))},t.setTyped(i)},{}],42:[function(a,e,t){"use strict";var i=a("./common"),s=!0,r=!0;try{String.fromCharCode.apply(null,[0])}catch{s=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{r=!1}for(var n=new i.Buf8(256),A=0;A<256;A++)n[A]=252<=A?6:248<=A?5:240<=A?4:224<=A?3:192<=A?2:1;function o(l,c){if(c<65537&&(l.subarray&&r||!l.subarray&&s))return String.fromCharCode.apply(null,i.shrinkBuf(l,c));for(var h="",d=0;d<c;d++)h+=String.fromCharCode(l[d]);return h}n[254]=n[254]=1,t.string2buf=function(l){var c,h,d,u,g,y=l.length,m=0;for(u=0;u<y;u++)(64512&(h=l.charCodeAt(u)))==55296&&u+1<y&&(64512&(d=l.charCodeAt(u+1)))==56320&&(h=65536+(h-55296<<10)+(d-56320),u++),m+=h<128?1:h<2048?2:h<65536?3:4;for(c=new i.Buf8(m),u=g=0;g<m;u++)(64512&(h=l.charCodeAt(u)))==55296&&u+1<y&&(64512&(d=l.charCodeAt(u+1)))==56320&&(h=65536+(h-55296<<10)+(d-56320),u++),h<128?c[g++]=h:(h<2048?c[g++]=192|h>>>6:(h<65536?c[g++]=224|h>>>12:(c[g++]=240|h>>>18,c[g++]=128|h>>>12&63),c[g++]=128|h>>>6&63),c[g++]=128|63&h);return c},t.buf2binstring=function(l){return o(l,l.length)},t.binstring2buf=function(l){for(var c=new i.Buf8(l.length),h=0,d=c.length;h<d;h++)c[h]=l.charCodeAt(h);return c},t.buf2string=function(l,c){var h,d,u,g,y=c||l.length,m=new Array(2*y);for(h=d=0;h<y;)if((u=l[h++])<128)m[d++]=u;else if(4<(g=n[u]))m[d++]=65533,h+=g-1;else{for(u&=g===2?31:g===3?15:7;1<g&&h<y;)u=u<<6|63&l[h++],g--;1<g?m[d++]=65533:u<65536?m[d++]=u:(u-=65536,m[d++]=55296|u>>10&1023,m[d++]=56320|1023&u)}return o(m,d)},t.utf8border=function(l,c){var h;for((c=c||l.length)>l.length&&(c=l.length),h=c-1;0<=h&&(192&l[h])==128;)h--;return h<0||h===0?c:h+n[l[h]]>c?h:c}},{"./common":41}],43:[function(a,e,t){"use strict";e.exports=function(i,s,r,n){for(var A=65535&i|0,o=i>>>16&65535|0,l=0;r!==0;){for(r-=l=2e3<r?2e3:r;o=o+(A=A+s[n++]|0)|0,--l;);A%=65521,o%=65521}return A|o<<16|0}},{}],44:[function(a,e,t){"use strict";e.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(a,e,t){"use strict";var i=(function(){for(var s,r=[],n=0;n<256;n++){s=n;for(var A=0;A<8;A++)s=1&s?3988292384^s>>>1:s>>>1;r[n]=s}return r})();e.exports=function(s,r,n,A){var o=i,l=A+n;s^=-1;for(var c=A;c<l;c++)s=s>>>8^o[255&(s^r[c])];return-1^s}},{}],46:[function(a,e,t){"use strict";var i,s=a("../utils/common"),r=a("./trees"),n=a("./adler32"),A=a("./crc32"),o=a("./messages"),l=0,c=4,h=0,d=-2,u=-1,g=4,y=2,m=8,b=9,B=286,w=30,_=19,T=2*B+1,Q=15,U=3,E=258,O=E+U+1,D=42,k=113,F=1,M=2,Y=3,z=4;function re(I,le){return I.msg=o[le],le}function q(I){return(I<<1)-(4<I?9:0)}function Ae(I){for(var le=I.length;0<=--le;)I[le]=0}function X(I){var le=I.state,ne=le.pending;ne>I.avail_out&&(ne=I.avail_out),ne!==0&&(s.arraySet(I.output,le.pending_buf,le.pending_out,ne,I.next_out),I.next_out+=ne,le.pending_out+=ne,I.total_out+=ne,I.avail_out-=ne,le.pending-=ne,le.pending===0&&(le.pending_out=0))}function G(I,le){r._tr_flush_block(I,0<=I.block_start?I.block_start:-1,I.strstart-I.block_start,le),I.block_start=I.strstart,X(I.strm)}function ue(I,le){I.pending_buf[I.pending++]=le}function he(I,le){I.pending_buf[I.pending++]=le>>>8&255,I.pending_buf[I.pending++]=255&le}function ae(I,le){var ne,V,N=I.max_chain_length,J=I.strstart,ce=I.prev_length,de=I.nice_match,ie=I.strstart>I.w_size-O?I.strstart-(I.w_size-O):0,fe=I.window,Ce=I.w_mask,ge=I.prev,He=I.strstart+E,Dt=fe[J+ce-1],lt=fe[J+ce];I.prev_length>=I.good_match&&(N>>=2),de>I.lookahead&&(de=I.lookahead);do if(fe[(ne=le)+ce]===lt&&fe[ne+ce-1]===Dt&&fe[ne]===fe[J]&&fe[++ne]===fe[J+1]){J+=2,ne++;do;while(fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&fe[++J]===fe[++ne]&&J<He);if(V=E-(He-J),J=He-E,ce<V){if(I.match_start=le,de<=(ce=V))break;Dt=fe[J+ce-1],lt=fe[J+ce]}}while((le=ge[le&Ce])>ie&&--N!=0);return ce<=I.lookahead?ce:I.lookahead}function Ie(I){var le,ne,V,N,J,ce,de,ie,fe,Ce,ge=I.w_size;do{if(N=I.window_size-I.lookahead-I.strstart,I.strstart>=ge+(ge-O)){for(s.arraySet(I.window,I.window,ge,ge,0),I.match_start-=ge,I.strstart-=ge,I.block_start-=ge,le=ne=I.hash_size;V=I.head[--le],I.head[le]=ge<=V?V-ge:0,--ne;);for(le=ne=ge;V=I.prev[--le],I.prev[le]=ge<=V?V-ge:0,--ne;);N+=ge}if(I.strm.avail_in===0)break;if(ce=I.strm,de=I.window,ie=I.strstart+I.lookahead,fe=N,Ce=void 0,Ce=ce.avail_in,fe<Ce&&(Ce=fe),ne=Ce===0?0:(ce.avail_in-=Ce,s.arraySet(de,ce.input,ce.next_in,Ce,ie),ce.state.wrap===1?ce.adler=n(ce.adler,de,Ce,ie):ce.state.wrap===2&&(ce.adler=A(ce.adler,de,Ce,ie)),ce.next_in+=Ce,ce.total_in+=Ce,Ce),I.lookahead+=ne,I.lookahead+I.insert>=U)for(J=I.strstart-I.insert,I.ins_h=I.window[J],I.ins_h=(I.ins_h<<I.hash_shift^I.window[J+1])&I.hash_mask;I.insert&&(I.ins_h=(I.ins_h<<I.hash_shift^I.window[J+U-1])&I.hash_mask,I.prev[J&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=J,J++,I.insert--,!(I.lookahead+I.insert<U)););}while(I.lookahead<O&&I.strm.avail_in!==0)}function Pe(I,le){for(var ne,V;;){if(I.lookahead<O){if(Ie(I),I.lookahead<O&&le===l)return F;if(I.lookahead===0)break}if(ne=0,I.lookahead>=U&&(I.ins_h=(I.ins_h<<I.hash_shift^I.window[I.strstart+U-1])&I.hash_mask,ne=I.prev[I.strstart&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=I.strstart),ne!==0&&I.strstart-ne<=I.w_size-O&&(I.match_length=ae(I,ne)),I.match_length>=U)if(V=r._tr_tally(I,I.strstart-I.match_start,I.match_length-U),I.lookahead-=I.match_length,I.match_length<=I.max_lazy_match&&I.lookahead>=U){for(I.match_length--;I.strstart++,I.ins_h=(I.ins_h<<I.hash_shift^I.window[I.strstart+U-1])&I.hash_mask,ne=I.prev[I.strstart&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=I.strstart,--I.match_length!=0;);I.strstart++}else I.strstart+=I.match_length,I.match_length=0,I.ins_h=I.window[I.strstart],I.ins_h=(I.ins_h<<I.hash_shift^I.window[I.strstart+1])&I.hash_mask;else V=r._tr_tally(I,0,I.window[I.strstart]),I.lookahead--,I.strstart++;if(V&&(G(I,!1),I.strm.avail_out===0))return F}return I.insert=I.strstart<U-1?I.strstart:U-1,le===c?(G(I,!0),I.strm.avail_out===0?Y:z):I.last_lit&&(G(I,!1),I.strm.avail_out===0)?F:M}function De(I,le){for(var ne,V,N;;){if(I.lookahead<O){if(Ie(I),I.lookahead<O&&le===l)return F;if(I.lookahead===0)break}if(ne=0,I.lookahead>=U&&(I.ins_h=(I.ins_h<<I.hash_shift^I.window[I.strstart+U-1])&I.hash_mask,ne=I.prev[I.strstart&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=I.strstart),I.prev_length=I.match_length,I.prev_match=I.match_start,I.match_length=U-1,ne!==0&&I.prev_length<I.max_lazy_match&&I.strstart-ne<=I.w_size-O&&(I.match_length=ae(I,ne),I.match_length<=5&&(I.strategy===1||I.match_length===U&&4096<I.strstart-I.match_start)&&(I.match_length=U-1)),I.prev_length>=U&&I.match_length<=I.prev_length){for(N=I.strstart+I.lookahead-U,V=r._tr_tally(I,I.strstart-1-I.prev_match,I.prev_length-U),I.lookahead-=I.prev_length-1,I.prev_length-=2;++I.strstart<=N&&(I.ins_h=(I.ins_h<<I.hash_shift^I.window[I.strstart+U-1])&I.hash_mask,ne=I.prev[I.strstart&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=I.strstart),--I.prev_length!=0;);if(I.match_available=0,I.match_length=U-1,I.strstart++,V&&(G(I,!1),I.strm.avail_out===0))return F}else if(I.match_available){if((V=r._tr_tally(I,0,I.window[I.strstart-1]))&&G(I,!1),I.strstart++,I.lookahead--,I.strm.avail_out===0)return F}else I.match_available=1,I.strstart++,I.lookahead--}return I.match_available&&(V=r._tr_tally(I,0,I.window[I.strstart-1]),I.match_available=0),I.insert=I.strstart<U-1?I.strstart:U-1,le===c?(G(I,!0),I.strm.avail_out===0?Y:z):I.last_lit&&(G(I,!1),I.strm.avail_out===0)?F:M}function Qe(I,le,ne,V,N){this.good_length=I,this.max_lazy=le,this.nice_length=ne,this.max_chain=V,this.func=N}function dt(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=m,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new s.Buf16(2*T),this.dyn_dtree=new s.Buf16(2*(2*w+1)),this.bl_tree=new s.Buf16(2*(2*_+1)),Ae(this.dyn_ltree),Ae(this.dyn_dtree),Ae(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new s.Buf16(Q+1),this.heap=new s.Buf16(2*B+1),Ae(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new s.Buf16(2*B+1),Ae(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function Me(I){var le;return I&&I.state?(I.total_in=I.total_out=0,I.data_type=y,(le=I.state).pending=0,le.pending_out=0,le.wrap<0&&(le.wrap=-le.wrap),le.status=le.wrap?D:k,I.adler=le.wrap===2?0:1,le.last_flush=l,r._tr_init(le),h):re(I,d)}function mi(I){var le=Me(I);return le===h&&(function(ne){ne.window_size=2*ne.w_size,Ae(ne.head),ne.max_lazy_match=i[ne.level].max_lazy,ne.good_match=i[ne.level].good_length,ne.nice_match=i[ne.level].nice_length,ne.max_chain_length=i[ne.level].max_chain,ne.strstart=0,ne.block_start=0,ne.lookahead=0,ne.insert=0,ne.match_length=ne.prev_length=U-1,ne.match_available=0,ne.ins_h=0})(I.state),le}function $t(I,le,ne,V,N,J){if(!I)return d;var ce=1;if(le===u&&(le=6),V<0?(ce=0,V=-V):15<V&&(ce=2,V-=16),N<1||b<N||ne!==m||V<8||15<V||le<0||9<le||J<0||g<J)return re(I,d);V===8&&(V=9);var de=new dt;return(I.state=de).strm=I,de.wrap=ce,de.gzhead=null,de.w_bits=V,de.w_size=1<<de.w_bits,de.w_mask=de.w_size-1,de.hash_bits=N+7,de.hash_size=1<<de.hash_bits,de.hash_mask=de.hash_size-1,de.hash_shift=~~((de.hash_bits+U-1)/U),de.window=new s.Buf8(2*de.w_size),de.head=new s.Buf16(de.hash_size),de.prev=new s.Buf16(de.w_size),de.lit_bufsize=1<<N+6,de.pending_buf_size=4*de.lit_bufsize,de.pending_buf=new s.Buf8(de.pending_buf_size),de.d_buf=1*de.lit_bufsize,de.l_buf=3*de.lit_bufsize,de.level=le,de.strategy=J,de.method=ne,mi(I)}i=[new Qe(0,0,0,0,function(I,le){var ne=65535;for(ne>I.pending_buf_size-5&&(ne=I.pending_buf_size-5);;){if(I.lookahead<=1){if(Ie(I),I.lookahead===0&&le===l)return F;if(I.lookahead===0)break}I.strstart+=I.lookahead,I.lookahead=0;var V=I.block_start+ne;if((I.strstart===0||I.strstart>=V)&&(I.lookahead=I.strstart-V,I.strstart=V,G(I,!1),I.strm.avail_out===0)||I.strstart-I.block_start>=I.w_size-O&&(G(I,!1),I.strm.avail_out===0))return F}return I.insert=0,le===c?(G(I,!0),I.strm.avail_out===0?Y:z):(I.strstart>I.block_start&&(G(I,!1),I.strm.avail_out),F)}),new Qe(4,4,8,4,Pe),new Qe(4,5,16,8,Pe),new Qe(4,6,32,32,Pe),new Qe(4,4,16,16,De),new Qe(8,16,32,32,De),new Qe(8,16,128,128,De),new Qe(8,32,128,256,De),new Qe(32,128,258,1024,De),new Qe(32,258,258,4096,De)],t.deflateInit=function(I,le){return $t(I,le,m,15,8,0)},t.deflateInit2=$t,t.deflateReset=mi,t.deflateResetKeep=Me,t.deflateSetHeader=function(I,le){return I&&I.state?I.state.wrap!==2?d:(I.state.gzhead=le,h):d},t.deflate=function(I,le){var ne,V,N,J;if(!I||!I.state||5<le||le<0)return I?re(I,d):d;if(V=I.state,!I.output||!I.input&&I.avail_in!==0||V.status===666&&le!==c)return re(I,I.avail_out===0?-5:d);if(V.strm=I,ne=V.last_flush,V.last_flush=le,V.status===D)if(V.wrap===2)I.adler=0,ue(V,31),ue(V,139),ue(V,8),V.gzhead?(ue(V,(V.gzhead.text?1:0)+(V.gzhead.hcrc?2:0)+(V.gzhead.extra?4:0)+(V.gzhead.name?8:0)+(V.gzhead.comment?16:0)),ue(V,255&V.gzhead.time),ue(V,V.gzhead.time>>8&255),ue(V,V.gzhead.time>>16&255),ue(V,V.gzhead.time>>24&255),ue(V,V.level===9?2:2<=V.strategy||V.level<2?4:0),ue(V,255&V.gzhead.os),V.gzhead.extra&&V.gzhead.extra.length&&(ue(V,255&V.gzhead.extra.length),ue(V,V.gzhead.extra.length>>8&255)),V.gzhead.hcrc&&(I.adler=A(I.adler,V.pending_buf,V.pending,0)),V.gzindex=0,V.status=69):(ue(V,0),ue(V,0),ue(V,0),ue(V,0),ue(V,0),ue(V,V.level===9?2:2<=V.strategy||V.level<2?4:0),ue(V,3),V.status=k);else{var ce=m+(V.w_bits-8<<4)<<8;ce|=(2<=V.strategy||V.level<2?0:V.level<6?1:V.level===6?2:3)<<6,V.strstart!==0&&(ce|=32),ce+=31-ce%31,V.status=k,he(V,ce),V.strstart!==0&&(he(V,I.adler>>>16),he(V,65535&I.adler)),I.adler=1}if(V.status===69)if(V.gzhead.extra){for(N=V.pending;V.gzindex<(65535&V.gzhead.extra.length)&&(V.pending!==V.pending_buf_size||(V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),X(I),N=V.pending,V.pending!==V.pending_buf_size));)ue(V,255&V.gzhead.extra[V.gzindex]),V.gzindex++;V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),V.gzindex===V.gzhead.extra.length&&(V.gzindex=0,V.status=73)}else V.status=73;if(V.status===73)if(V.gzhead.name){N=V.pending;do{if(V.pending===V.pending_buf_size&&(V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),X(I),N=V.pending,V.pending===V.pending_buf_size)){J=1;break}J=V.gzindex<V.gzhead.name.length?255&V.gzhead.name.charCodeAt(V.gzindex++):0,ue(V,J)}while(J!==0);V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),J===0&&(V.gzindex=0,V.status=91)}else V.status=91;if(V.status===91)if(V.gzhead.comment){N=V.pending;do{if(V.pending===V.pending_buf_size&&(V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),X(I),N=V.pending,V.pending===V.pending_buf_size)){J=1;break}J=V.gzindex<V.gzhead.comment.length?255&V.gzhead.comment.charCodeAt(V.gzindex++):0,ue(V,J)}while(J!==0);V.gzhead.hcrc&&V.pending>N&&(I.adler=A(I.adler,V.pending_buf,V.pending-N,N)),J===0&&(V.status=103)}else V.status=103;if(V.status===103&&(V.gzhead.hcrc?(V.pending+2>V.pending_buf_size&&X(I),V.pending+2<=V.pending_buf_size&&(ue(V,255&I.adler),ue(V,I.adler>>8&255),I.adler=0,V.status=k)):V.status=k),V.pending!==0){if(X(I),I.avail_out===0)return V.last_flush=-1,h}else if(I.avail_in===0&&q(le)<=q(ne)&&le!==c)return re(I,-5);if(V.status===666&&I.avail_in!==0)return re(I,-5);if(I.avail_in!==0||V.lookahead!==0||le!==l&&V.status!==666){var de=V.strategy===2?(function(ie,fe){for(var Ce;;){if(ie.lookahead===0&&(Ie(ie),ie.lookahead===0)){if(fe===l)return F;break}if(ie.match_length=0,Ce=r._tr_tally(ie,0,ie.window[ie.strstart]),ie.lookahead--,ie.strstart++,Ce&&(G(ie,!1),ie.strm.avail_out===0))return F}return ie.insert=0,fe===c?(G(ie,!0),ie.strm.avail_out===0?Y:z):ie.last_lit&&(G(ie,!1),ie.strm.avail_out===0)?F:M})(V,le):V.strategy===3?(function(ie,fe){for(var Ce,ge,He,Dt,lt=ie.window;;){if(ie.lookahead<=E){if(Ie(ie),ie.lookahead<=E&&fe===l)return F;if(ie.lookahead===0)break}if(ie.match_length=0,ie.lookahead>=U&&0<ie.strstart&&(ge=lt[He=ie.strstart-1])===lt[++He]&&ge===lt[++He]&&ge===lt[++He]){Dt=ie.strstart+E;do;while(ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&ge===lt[++He]&&He<Dt);ie.match_length=E-(Dt-He),ie.match_length>ie.lookahead&&(ie.match_length=ie.lookahead)}if(ie.match_length>=U?(Ce=r._tr_tally(ie,1,ie.match_length-U),ie.lookahead-=ie.match_length,ie.strstart+=ie.match_length,ie.match_length=0):(Ce=r._tr_tally(ie,0,ie.window[ie.strstart]),ie.lookahead--,ie.strstart++),Ce&&(G(ie,!1),ie.strm.avail_out===0))return F}return ie.insert=0,fe===c?(G(ie,!0),ie.strm.avail_out===0?Y:z):ie.last_lit&&(G(ie,!1),ie.strm.avail_out===0)?F:M})(V,le):i[V.level].func(V,le);if(de!==Y&&de!==z||(V.status=666),de===F||de===Y)return I.avail_out===0&&(V.last_flush=-1),h;if(de===M&&(le===1?r._tr_align(V):le!==5&&(r._tr_stored_block(V,0,0,!1),le===3&&(Ae(V.head),V.lookahead===0&&(V.strstart=0,V.block_start=0,V.insert=0))),X(I),I.avail_out===0))return V.last_flush=-1,h}return le!==c?h:V.wrap<=0?1:(V.wrap===2?(ue(V,255&I.adler),ue(V,I.adler>>8&255),ue(V,I.adler>>16&255),ue(V,I.adler>>24&255),ue(V,255&I.total_in),ue(V,I.total_in>>8&255),ue(V,I.total_in>>16&255),ue(V,I.total_in>>24&255)):(he(V,I.adler>>>16),he(V,65535&I.adler)),X(I),0<V.wrap&&(V.wrap=-V.wrap),V.pending!==0?h:1)},t.deflateEnd=function(I){var le;return I&&I.state?(le=I.state.status)!==D&&le!==69&&le!==73&&le!==91&&le!==103&&le!==k&&le!==666?re(I,d):(I.state=null,le===k?re(I,-3):h):d},t.deflateSetDictionary=function(I,le){var ne,V,N,J,ce,de,ie,fe,Ce=le.length;if(!I||!I.state||(J=(ne=I.state).wrap)===2||J===1&&ne.status!==D||ne.lookahead)return d;for(J===1&&(I.adler=n(I.adler,le,Ce,0)),ne.wrap=0,Ce>=ne.w_size&&(J===0&&(Ae(ne.head),ne.strstart=0,ne.block_start=0,ne.insert=0),fe=new s.Buf8(ne.w_size),s.arraySet(fe,le,Ce-ne.w_size,ne.w_size,0),le=fe,Ce=ne.w_size),ce=I.avail_in,de=I.next_in,ie=I.input,I.avail_in=Ce,I.next_in=0,I.input=le,Ie(ne);ne.lookahead>=U;){for(V=ne.strstart,N=ne.lookahead-(U-1);ne.ins_h=(ne.ins_h<<ne.hash_shift^ne.window[V+U-1])&ne.hash_mask,ne.prev[V&ne.w_mask]=ne.head[ne.ins_h],ne.head[ne.ins_h]=V,V++,--N;);ne.strstart=V,ne.lookahead=U-1,Ie(ne)}return ne.strstart+=ne.lookahead,ne.block_start=ne.strstart,ne.insert=ne.lookahead,ne.lookahead=0,ne.match_length=ne.prev_length=U-1,ne.match_available=0,I.next_in=de,I.input=ie,I.avail_in=ce,ne.wrap=J,h},t.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(a,e,t){"use strict";e.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(a,e,t){"use strict";e.exports=function(i,s){var r,n,A,o,l,c,h,d,u,g,y,m,b,B,w,_,T,Q,U,E,O,D,k,F,M;r=i.state,n=i.next_in,F=i.input,A=n+(i.avail_in-5),o=i.next_out,M=i.output,l=o-(s-i.avail_out),c=o+(i.avail_out-257),h=r.dmax,d=r.wsize,u=r.whave,g=r.wnext,y=r.window,m=r.hold,b=r.bits,B=r.lencode,w=r.distcode,_=(1<<r.lenbits)-1,T=(1<<r.distbits)-1;e:do{b<15&&(m+=F[n++]<<b,b+=8,m+=F[n++]<<b,b+=8),Q=B[m&_];t:for(;;){if(m>>>=U=Q>>>24,b-=U,(U=Q>>>16&255)===0)M[o++]=65535&Q;else{if(!(16&U)){if((64&U)==0){Q=B[(65535&Q)+(m&(1<<U)-1)];continue t}if(32&U){r.mode=12;break e}i.msg="invalid literal/length code",r.mode=30;break e}E=65535&Q,(U&=15)&&(b<U&&(m+=F[n++]<<b,b+=8),E+=m&(1<<U)-1,m>>>=U,b-=U),b<15&&(m+=F[n++]<<b,b+=8,m+=F[n++]<<b,b+=8),Q=w[m&T];i:for(;;){if(m>>>=U=Q>>>24,b-=U,!(16&(U=Q>>>16&255))){if((64&U)==0){Q=w[(65535&Q)+(m&(1<<U)-1)];continue i}i.msg="invalid distance code",r.mode=30;break e}if(O=65535&Q,b<(U&=15)&&(m+=F[n++]<<b,(b+=8)<U&&(m+=F[n++]<<b,b+=8)),h<(O+=m&(1<<U)-1)){i.msg="invalid distance too far back",r.mode=30;break e}if(m>>>=U,b-=U,(U=o-l)<O){if(u<(U=O-U)&&r.sane){i.msg="invalid distance too far back",r.mode=30;break e}if(k=y,(D=0)===g){if(D+=d-U,U<E){for(E-=U;M[o++]=y[D++],--U;);D=o-O,k=M}}else if(g<U){if(D+=d+g-U,(U-=g)<E){for(E-=U;M[o++]=y[D++],--U;);if(D=0,g<E){for(E-=U=g;M[o++]=y[D++],--U;);D=o-O,k=M}}}else if(D+=g-U,U<E){for(E-=U;M[o++]=y[D++],--U;);D=o-O,k=M}for(;2<E;)M[o++]=k[D++],M[o++]=k[D++],M[o++]=k[D++],E-=3;E&&(M[o++]=k[D++],1<E&&(M[o++]=k[D++]))}else{for(D=o-O;M[o++]=M[D++],M[o++]=M[D++],M[o++]=M[D++],2<(E-=3););E&&(M[o++]=M[D++],1<E&&(M[o++]=M[D++]))}break}}break}}while(n<A&&o<c);n-=E=b>>3,m&=(1<<(b-=E<<3))-1,i.next_in=n,i.next_out=o,i.avail_in=n<A?A-n+5:5-(n-A),i.avail_out=o<c?c-o+257:257-(o-c),r.hold=m,r.bits=b}},{}],49:[function(a,e,t){"use strict";var i=a("../utils/common"),s=a("./adler32"),r=a("./crc32"),n=a("./inffast"),A=a("./inftrees"),o=1,l=2,c=0,h=-2,d=1,u=852,g=592;function y(D){return(D>>>24&255)+(D>>>8&65280)+((65280&D)<<8)+((255&D)<<24)}function m(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new i.Buf16(320),this.work=new i.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function b(D){var k;return D&&D.state?(k=D.state,D.total_in=D.total_out=k.total=0,D.msg="",k.wrap&&(D.adler=1&k.wrap),k.mode=d,k.last=0,k.havedict=0,k.dmax=32768,k.head=null,k.hold=0,k.bits=0,k.lencode=k.lendyn=new i.Buf32(u),k.distcode=k.distdyn=new i.Buf32(g),k.sane=1,k.back=-1,c):h}function B(D){var k;return D&&D.state?((k=D.state).wsize=0,k.whave=0,k.wnext=0,b(D)):h}function w(D,k){var F,M;return D&&D.state?(M=D.state,k<0?(F=0,k=-k):(F=1+(k>>4),k<48&&(k&=15)),k&&(k<8||15<k)?h:(M.window!==null&&M.wbits!==k&&(M.window=null),M.wrap=F,M.wbits=k,B(D))):h}function _(D,k){var F,M;return D?(M=new m,(D.state=M).window=null,(F=w(D,k))!==c&&(D.state=null),F):h}var T,Q,U=!0;function E(D){if(U){var k;for(T=new i.Buf32(512),Q=new i.Buf32(32),k=0;k<144;)D.lens[k++]=8;for(;k<256;)D.lens[k++]=9;for(;k<280;)D.lens[k++]=7;for(;k<288;)D.lens[k++]=8;for(A(o,D.lens,0,288,T,0,D.work,{bits:9}),k=0;k<32;)D.lens[k++]=5;A(l,D.lens,0,32,Q,0,D.work,{bits:5}),U=!1}D.lencode=T,D.lenbits=9,D.distcode=Q,D.distbits=5}function O(D,k,F,M){var Y,z=D.state;return z.window===null&&(z.wsize=1<<z.wbits,z.wnext=0,z.whave=0,z.window=new i.Buf8(z.wsize)),M>=z.wsize?(i.arraySet(z.window,k,F-z.wsize,z.wsize,0),z.wnext=0,z.whave=z.wsize):(M<(Y=z.wsize-z.wnext)&&(Y=M),i.arraySet(z.window,k,F-M,Y,z.wnext),(M-=Y)?(i.arraySet(z.window,k,F-M,M,0),z.wnext=M,z.whave=z.wsize):(z.wnext+=Y,z.wnext===z.wsize&&(z.wnext=0),z.whave<z.wsize&&(z.whave+=Y))),0}t.inflateReset=B,t.inflateReset2=w,t.inflateResetKeep=b,t.inflateInit=function(D){return _(D,15)},t.inflateInit2=_,t.inflate=function(D,k){var F,M,Y,z,re,q,Ae,X,G,ue,he,ae,Ie,Pe,De,Qe,dt,Me,mi,$t,I,le,ne,V,N=0,J=new i.Buf8(4),ce=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!D||!D.state||!D.output||!D.input&&D.avail_in!==0)return h;(F=D.state).mode===12&&(F.mode=13),re=D.next_out,Y=D.output,Ae=D.avail_out,z=D.next_in,M=D.input,q=D.avail_in,X=F.hold,G=F.bits,ue=q,he=Ae,le=c;e:for(;;)switch(F.mode){case d:if(F.wrap===0){F.mode=13;break}for(;G<16;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(2&F.wrap&&X===35615){J[F.check=0]=255&X,J[1]=X>>>8&255,F.check=r(F.check,J,2,0),G=X=0,F.mode=2;break}if(F.flags=0,F.head&&(F.head.done=!1),!(1&F.wrap)||(((255&X)<<8)+(X>>8))%31){D.msg="incorrect header check",F.mode=30;break}if((15&X)!=8){D.msg="unknown compression method",F.mode=30;break}if(G-=4,I=8+(15&(X>>>=4)),F.wbits===0)F.wbits=I;else if(I>F.wbits){D.msg="invalid window size",F.mode=30;break}F.dmax=1<<I,D.adler=F.check=1,F.mode=512&X?10:12,G=X=0;break;case 2:for(;G<16;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(F.flags=X,(255&F.flags)!=8){D.msg="unknown compression method",F.mode=30;break}if(57344&F.flags){D.msg="unknown header flags set",F.mode=30;break}F.head&&(F.head.text=X>>8&1),512&F.flags&&(J[0]=255&X,J[1]=X>>>8&255,F.check=r(F.check,J,2,0)),G=X=0,F.mode=3;case 3:for(;G<32;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.head&&(F.head.time=X),512&F.flags&&(J[0]=255&X,J[1]=X>>>8&255,J[2]=X>>>16&255,J[3]=X>>>24&255,F.check=r(F.check,J,4,0)),G=X=0,F.mode=4;case 4:for(;G<16;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.head&&(F.head.xflags=255&X,F.head.os=X>>8),512&F.flags&&(J[0]=255&X,J[1]=X>>>8&255,F.check=r(F.check,J,2,0)),G=X=0,F.mode=5;case 5:if(1024&F.flags){for(;G<16;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.length=X,F.head&&(F.head.extra_len=X),512&F.flags&&(J[0]=255&X,J[1]=X>>>8&255,F.check=r(F.check,J,2,0)),G=X=0}else F.head&&(F.head.extra=null);F.mode=6;case 6:if(1024&F.flags&&(q<(ae=F.length)&&(ae=q),ae&&(F.head&&(I=F.head.extra_len-F.length,F.head.extra||(F.head.extra=new Array(F.head.extra_len)),i.arraySet(F.head.extra,M,z,ae,I)),512&F.flags&&(F.check=r(F.check,M,ae,z)),q-=ae,z+=ae,F.length-=ae),F.length))break e;F.length=0,F.mode=7;case 7:if(2048&F.flags){if(q===0)break e;for(ae=0;I=M[z+ae++],F.head&&I&&F.length<65536&&(F.head.name+=String.fromCharCode(I)),I&&ae<q;);if(512&F.flags&&(F.check=r(F.check,M,ae,z)),q-=ae,z+=ae,I)break e}else F.head&&(F.head.name=null);F.length=0,F.mode=8;case 8:if(4096&F.flags){if(q===0)break e;for(ae=0;I=M[z+ae++],F.head&&I&&F.length<65536&&(F.head.comment+=String.fromCharCode(I)),I&&ae<q;);if(512&F.flags&&(F.check=r(F.check,M,ae,z)),q-=ae,z+=ae,I)break e}else F.head&&(F.head.comment=null);F.mode=9;case 9:if(512&F.flags){for(;G<16;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(X!==(65535&F.check)){D.msg="header crc mismatch",F.mode=30;break}G=X=0}F.head&&(F.head.hcrc=F.flags>>9&1,F.head.done=!0),D.adler=F.check=0,F.mode=12;break;case 10:for(;G<32;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}D.adler=F.check=y(X),G=X=0,F.mode=11;case 11:if(F.havedict===0)return D.next_out=re,D.avail_out=Ae,D.next_in=z,D.avail_in=q,F.hold=X,F.bits=G,2;D.adler=F.check=1,F.mode=12;case 12:if(k===5||k===6)break e;case 13:if(F.last){X>>>=7&G,G-=7&G,F.mode=27;break}for(;G<3;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}switch(F.last=1&X,G-=1,3&(X>>>=1)){case 0:F.mode=14;break;case 1:if(E(F),F.mode=20,k!==6)break;X>>>=2,G-=2;break e;case 2:F.mode=17;break;case 3:D.msg="invalid block type",F.mode=30}X>>>=2,G-=2;break;case 14:for(X>>>=7&G,G-=7&G;G<32;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if((65535&X)!=(X>>>16^65535)){D.msg="invalid stored block lengths",F.mode=30;break}if(F.length=65535&X,G=X=0,F.mode=15,k===6)break e;case 15:F.mode=16;case 16:if(ae=F.length){if(q<ae&&(ae=q),Ae<ae&&(ae=Ae),ae===0)break e;i.arraySet(Y,M,z,ae,re),q-=ae,z+=ae,Ae-=ae,re+=ae,F.length-=ae;break}F.mode=12;break;case 17:for(;G<14;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(F.nlen=257+(31&X),X>>>=5,G-=5,F.ndist=1+(31&X),X>>>=5,G-=5,F.ncode=4+(15&X),X>>>=4,G-=4,286<F.nlen||30<F.ndist){D.msg="too many length or distance symbols",F.mode=30;break}F.have=0,F.mode=18;case 18:for(;F.have<F.ncode;){for(;G<3;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.lens[ce[F.have++]]=7&X,X>>>=3,G-=3}for(;F.have<19;)F.lens[ce[F.have++]]=0;if(F.lencode=F.lendyn,F.lenbits=7,ne={bits:F.lenbits},le=A(0,F.lens,0,19,F.lencode,0,F.work,ne),F.lenbits=ne.bits,le){D.msg="invalid code lengths set",F.mode=30;break}F.have=0,F.mode=19;case 19:for(;F.have<F.nlen+F.ndist;){for(;Qe=(N=F.lencode[X&(1<<F.lenbits)-1])>>>16&255,dt=65535&N,!((De=N>>>24)<=G);){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(dt<16)X>>>=De,G-=De,F.lens[F.have++]=dt;else{if(dt===16){for(V=De+2;G<V;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(X>>>=De,G-=De,F.have===0){D.msg="invalid bit length repeat",F.mode=30;break}I=F.lens[F.have-1],ae=3+(3&X),X>>>=2,G-=2}else if(dt===17){for(V=De+3;G<V;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}G-=De,I=0,ae=3+(7&(X>>>=De)),X>>>=3,G-=3}else{for(V=De+7;G<V;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}G-=De,I=0,ae=11+(127&(X>>>=De)),X>>>=7,G-=7}if(F.have+ae>F.nlen+F.ndist){D.msg="invalid bit length repeat",F.mode=30;break}for(;ae--;)F.lens[F.have++]=I}}if(F.mode===30)break;if(F.lens[256]===0){D.msg="invalid code -- missing end-of-block",F.mode=30;break}if(F.lenbits=9,ne={bits:F.lenbits},le=A(o,F.lens,0,F.nlen,F.lencode,0,F.work,ne),F.lenbits=ne.bits,le){D.msg="invalid literal/lengths set",F.mode=30;break}if(F.distbits=6,F.distcode=F.distdyn,ne={bits:F.distbits},le=A(l,F.lens,F.nlen,F.ndist,F.distcode,0,F.work,ne),F.distbits=ne.bits,le){D.msg="invalid distances set",F.mode=30;break}if(F.mode=20,k===6)break e;case 20:F.mode=21;case 21:if(6<=q&&258<=Ae){D.next_out=re,D.avail_out=Ae,D.next_in=z,D.avail_in=q,F.hold=X,F.bits=G,n(D,he),re=D.next_out,Y=D.output,Ae=D.avail_out,z=D.next_in,M=D.input,q=D.avail_in,X=F.hold,G=F.bits,F.mode===12&&(F.back=-1);break}for(F.back=0;Qe=(N=F.lencode[X&(1<<F.lenbits)-1])>>>16&255,dt=65535&N,!((De=N>>>24)<=G);){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(Qe&&(240&Qe)==0){for(Me=De,mi=Qe,$t=dt;Qe=(N=F.lencode[$t+((X&(1<<Me+mi)-1)>>Me)])>>>16&255,dt=65535&N,!(Me+(De=N>>>24)<=G);){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}X>>>=Me,G-=Me,F.back+=Me}if(X>>>=De,G-=De,F.back+=De,F.length=dt,Qe===0){F.mode=26;break}if(32&Qe){F.back=-1,F.mode=12;break}if(64&Qe){D.msg="invalid literal/length code",F.mode=30;break}F.extra=15&Qe,F.mode=22;case 22:if(F.extra){for(V=F.extra;G<V;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.length+=X&(1<<F.extra)-1,X>>>=F.extra,G-=F.extra,F.back+=F.extra}F.was=F.length,F.mode=23;case 23:for(;Qe=(N=F.distcode[X&(1<<F.distbits)-1])>>>16&255,dt=65535&N,!((De=N>>>24)<=G);){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if((240&Qe)==0){for(Me=De,mi=Qe,$t=dt;Qe=(N=F.distcode[$t+((X&(1<<Me+mi)-1)>>Me)])>>>16&255,dt=65535&N,!(Me+(De=N>>>24)<=G);){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}X>>>=Me,G-=Me,F.back+=Me}if(X>>>=De,G-=De,F.back+=De,64&Qe){D.msg="invalid distance code",F.mode=30;break}F.offset=dt,F.extra=15&Qe,F.mode=24;case 24:if(F.extra){for(V=F.extra;G<V;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}F.offset+=X&(1<<F.extra)-1,X>>>=F.extra,G-=F.extra,F.back+=F.extra}if(F.offset>F.dmax){D.msg="invalid distance too far back",F.mode=30;break}F.mode=25;case 25:if(Ae===0)break e;if(ae=he-Ae,F.offset>ae){if((ae=F.offset-ae)>F.whave&&F.sane){D.msg="invalid distance too far back",F.mode=30;break}Ie=ae>F.wnext?(ae-=F.wnext,F.wsize-ae):F.wnext-ae,ae>F.length&&(ae=F.length),Pe=F.window}else Pe=Y,Ie=re-F.offset,ae=F.length;for(Ae<ae&&(ae=Ae),Ae-=ae,F.length-=ae;Y[re++]=Pe[Ie++],--ae;);F.length===0&&(F.mode=21);break;case 26:if(Ae===0)break e;Y[re++]=F.length,Ae--,F.mode=21;break;case 27:if(F.wrap){for(;G<32;){if(q===0)break e;q--,X|=M[z++]<<G,G+=8}if(he-=Ae,D.total_out+=he,F.total+=he,he&&(D.adler=F.check=F.flags?r(F.check,Y,he,re-he):s(F.check,Y,he,re-he)),he=Ae,(F.flags?X:y(X))!==F.check){D.msg="incorrect data check",F.mode=30;break}G=X=0}F.mode=28;case 28:if(F.wrap&&F.flags){for(;G<32;){if(q===0)break e;q--,X+=M[z++]<<G,G+=8}if(X!==(4294967295&F.total)){D.msg="incorrect length check",F.mode=30;break}G=X=0}F.mode=29;case 29:le=1;break e;case 30:le=-3;break e;case 31:return-4;case 32:default:return h}return D.next_out=re,D.avail_out=Ae,D.next_in=z,D.avail_in=q,F.hold=X,F.bits=G,(F.wsize||he!==D.avail_out&&F.mode<30&&(F.mode<27||k!==4))&&O(D,D.output,D.next_out,he-D.avail_out)?(F.mode=31,-4):(ue-=D.avail_in,he-=D.avail_out,D.total_in+=ue,D.total_out+=he,F.total+=he,F.wrap&&he&&(D.adler=F.check=F.flags?r(F.check,Y,he,D.next_out-he):s(F.check,Y,he,D.next_out-he)),D.data_type=F.bits+(F.last?64:0)+(F.mode===12?128:0)+(F.mode===20||F.mode===15?256:0),(ue==0&&he===0||k===4)&&le===c&&(le=-5),le)},t.inflateEnd=function(D){if(!D||!D.state)return h;var k=D.state;return k.window&&(k.window=null),D.state=null,c},t.inflateGetHeader=function(D,k){var F;return D&&D.state?(2&(F=D.state).wrap)==0?h:((F.head=k).done=!1,c):h},t.inflateSetDictionary=function(D,k){var F,M=k.length;return D&&D.state?(F=D.state).wrap!==0&&F.mode!==11?h:F.mode===11&&s(1,k,M,0)!==F.check?-3:O(D,k,M,M)?(F.mode=31,-4):(F.havedict=1,c):h},t.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(a,e,t){"use strict";var i=a("../utils/common"),s=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],r=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],n=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],A=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];e.exports=function(o,l,c,h,d,u,g,y){var m,b,B,w,_,T,Q,U,E,O=y.bits,D=0,k=0,F=0,M=0,Y=0,z=0,re=0,q=0,Ae=0,X=0,G=null,ue=0,he=new i.Buf16(16),ae=new i.Buf16(16),Ie=null,Pe=0;for(D=0;D<=15;D++)he[D]=0;for(k=0;k<h;k++)he[l[c+k]]++;for(Y=O,M=15;1<=M&&he[M]===0;M--);if(M<Y&&(Y=M),M===0)return d[u++]=20971520,d[u++]=20971520,y.bits=1,0;for(F=1;F<M&&he[F]===0;F++);for(Y<F&&(Y=F),D=q=1;D<=15;D++)if(q<<=1,(q-=he[D])<0)return-1;if(0<q&&(o===0||M!==1))return-1;for(ae[1]=0,D=1;D<15;D++)ae[D+1]=ae[D]+he[D];for(k=0;k<h;k++)l[c+k]!==0&&(g[ae[l[c+k]]++]=k);if(T=o===0?(G=Ie=g,19):o===1?(G=s,ue-=257,Ie=r,Pe-=257,256):(G=n,Ie=A,-1),D=F,_=u,re=k=X=0,B=-1,w=(Ae=1<<(z=Y))-1,o===1&&852<Ae||o===2&&592<Ae)return 1;for(;;){for(Q=D-re,E=g[k]<T?(U=0,g[k]):g[k]>T?(U=Ie[Pe+g[k]],G[ue+g[k]]):(U=96,0),m=1<<D-re,F=b=1<<z;d[_+(X>>re)+(b-=m)]=Q<<24|U<<16|E|0,b!==0;);for(m=1<<D-1;X&m;)m>>=1;if(m!==0?(X&=m-1,X+=m):X=0,k++,--he[D]==0){if(D===M)break;D=l[c+g[k]]}if(Y<D&&(X&w)!==B){for(re===0&&(re=Y),_+=F,q=1<<(z=D-re);z+re<M&&!((q-=he[z+re])<=0);)z++,q<<=1;if(Ae+=1<<z,o===1&&852<Ae||o===2&&592<Ae)return 1;d[B=X&w]=Y<<24|z<<16|_-u|0}}return X!==0&&(d[_+X]=D-re<<24|64<<16|0),y.bits=Y,0}},{"../utils/common":41}],51:[function(a,e,t){"use strict";e.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(a,e,t){"use strict";var i=a("../utils/common"),s=0,r=1;function n(N){for(var J=N.length;0<=--J;)N[J]=0}var A=0,o=29,l=256,c=l+1+o,h=30,d=19,u=2*c+1,g=15,y=16,m=7,b=256,B=16,w=17,_=18,T=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],Q=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],U=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],E=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],O=new Array(2*(c+2));n(O);var D=new Array(2*h);n(D);var k=new Array(512);n(k);var F=new Array(256);n(F);var M=new Array(o);n(M);var Y,z,re,q=new Array(h);function Ae(N,J,ce,de,ie){this.static_tree=N,this.extra_bits=J,this.extra_base=ce,this.elems=de,this.max_length=ie,this.has_stree=N&&N.length}function X(N,J){this.dyn_tree=N,this.max_code=0,this.stat_desc=J}function G(N){return N<256?k[N]:k[256+(N>>>7)]}function ue(N,J){N.pending_buf[N.pending++]=255&J,N.pending_buf[N.pending++]=J>>>8&255}function he(N,J,ce){N.bi_valid>y-ce?(N.bi_buf|=J<<N.bi_valid&65535,ue(N,N.bi_buf),N.bi_buf=J>>y-N.bi_valid,N.bi_valid+=ce-y):(N.bi_buf|=J<<N.bi_valid&65535,N.bi_valid+=ce)}function ae(N,J,ce){he(N,ce[2*J],ce[2*J+1])}function Ie(N,J){for(var ce=0;ce|=1&N,N>>>=1,ce<<=1,0<--J;);return ce>>>1}function Pe(N,J,ce){var de,ie,fe=new Array(g+1),Ce=0;for(de=1;de<=g;de++)fe[de]=Ce=Ce+ce[de-1]<<1;for(ie=0;ie<=J;ie++){var ge=N[2*ie+1];ge!==0&&(N[2*ie]=Ie(fe[ge]++,ge))}}function De(N){var J;for(J=0;J<c;J++)N.dyn_ltree[2*J]=0;for(J=0;J<h;J++)N.dyn_dtree[2*J]=0;for(J=0;J<d;J++)N.bl_tree[2*J]=0;N.dyn_ltree[2*b]=1,N.opt_len=N.static_len=0,N.last_lit=N.matches=0}function Qe(N){8<N.bi_valid?ue(N,N.bi_buf):0<N.bi_valid&&(N.pending_buf[N.pending++]=N.bi_buf),N.bi_buf=0,N.bi_valid=0}function dt(N,J,ce,de){var ie=2*J,fe=2*ce;return N[ie]<N[fe]||N[ie]===N[fe]&&de[J]<=de[ce]}function Me(N,J,ce){for(var de=N.heap[ce],ie=ce<<1;ie<=N.heap_len&&(ie<N.heap_len&&dt(J,N.heap[ie+1],N.heap[ie],N.depth)&&ie++,!dt(J,de,N.heap[ie],N.depth));)N.heap[ce]=N.heap[ie],ce=ie,ie<<=1;N.heap[ce]=de}function mi(N,J,ce){var de,ie,fe,Ce,ge=0;if(N.last_lit!==0)for(;de=N.pending_buf[N.d_buf+2*ge]<<8|N.pending_buf[N.d_buf+2*ge+1],ie=N.pending_buf[N.l_buf+ge],ge++,de===0?ae(N,ie,J):(ae(N,(fe=F[ie])+l+1,J),(Ce=T[fe])!==0&&he(N,ie-=M[fe],Ce),ae(N,fe=G(--de),ce),(Ce=Q[fe])!==0&&he(N,de-=q[fe],Ce)),ge<N.last_lit;);ae(N,b,J)}function $t(N,J){var ce,de,ie,fe=J.dyn_tree,Ce=J.stat_desc.static_tree,ge=J.stat_desc.has_stree,He=J.stat_desc.elems,Dt=-1;for(N.heap_len=0,N.heap_max=u,ce=0;ce<He;ce++)fe[2*ce]!==0?(N.heap[++N.heap_len]=Dt=ce,N.depth[ce]=0):fe[2*ce+1]=0;for(;N.heap_len<2;)fe[2*(ie=N.heap[++N.heap_len]=Dt<2?++Dt:0)]=1,N.depth[ie]=0,N.opt_len--,ge&&(N.static_len-=Ce[2*ie+1]);for(J.max_code=Dt,ce=N.heap_len>>1;1<=ce;ce--)Me(N,fe,ce);for(ie=He;ce=N.heap[1],N.heap[1]=N.heap[N.heap_len--],Me(N,fe,1),de=N.heap[1],N.heap[--N.heap_max]=ce,N.heap[--N.heap_max]=de,fe[2*ie]=fe[2*ce]+fe[2*de],N.depth[ie]=(N.depth[ce]>=N.depth[de]?N.depth[ce]:N.depth[de])+1,fe[2*ce+1]=fe[2*de+1]=ie,N.heap[1]=ie++,Me(N,fe,1),2<=N.heap_len;);N.heap[--N.heap_max]=N.heap[1],(function(lt,Wi){var ir,fs,Ps,gt,wr,jr,zi=Wi.dyn_tree,ol=Wi.max_code,Zr=Wi.stat_desc.static_tree,Vc=Wi.stat_desc.has_stree,qn=Wi.stat_desc.extra_bits,un=Wi.stat_desc.extra_base,qr=Wi.stat_desc.max_length,wa=0;for(gt=0;gt<=g;gt++)lt.bl_count[gt]=0;for(zi[2*lt.heap[lt.heap_max]+1]=0,ir=lt.heap_max+1;ir<u;ir++)qr<(gt=zi[2*zi[2*(fs=lt.heap[ir])+1]+1]+1)&&(gt=qr,wa++),zi[2*fs+1]=gt,ol<fs||(lt.bl_count[gt]++,wr=0,un<=fs&&(wr=qn[fs-un]),jr=zi[2*fs],lt.opt_len+=jr*(gt+wr),Vc&&(lt.static_len+=jr*(Zr[2*fs+1]+wr)));if(wa!==0){do{for(gt=qr-1;lt.bl_count[gt]===0;)gt--;lt.bl_count[gt]--,lt.bl_count[gt+1]+=2,lt.bl_count[qr]--,wa-=2}while(0<wa);for(gt=qr;gt!==0;gt--)for(fs=lt.bl_count[gt];fs!==0;)ol<(Ps=lt.heap[--ir])||(zi[2*Ps+1]!==gt&&(lt.opt_len+=(gt-zi[2*Ps+1])*zi[2*Ps],zi[2*Ps+1]=gt),fs--)}})(N,J),Pe(fe,Dt,N.bl_count)}function I(N,J,ce){var de,ie,fe=-1,Ce=J[1],ge=0,He=7,Dt=4;for(Ce===0&&(He=138,Dt=3),J[2*(ce+1)+1]=65535,de=0;de<=ce;de++)ie=Ce,Ce=J[2*(de+1)+1],++ge<He&&ie===Ce||(ge<Dt?N.bl_tree[2*ie]+=ge:ie!==0?(ie!==fe&&N.bl_tree[2*ie]++,N.bl_tree[2*B]++):ge<=10?N.bl_tree[2*w]++:N.bl_tree[2*_]++,fe=ie,Dt=(ge=0)===Ce?(He=138,3):ie===Ce?(He=6,3):(He=7,4))}function le(N,J,ce){var de,ie,fe=-1,Ce=J[1],ge=0,He=7,Dt=4;for(Ce===0&&(He=138,Dt=3),de=0;de<=ce;de++)if(ie=Ce,Ce=J[2*(de+1)+1],!(++ge<He&&ie===Ce)){if(ge<Dt)for(;ae(N,ie,N.bl_tree),--ge!=0;);else ie!==0?(ie!==fe&&(ae(N,ie,N.bl_tree),ge--),ae(N,B,N.bl_tree),he(N,ge-3,2)):ge<=10?(ae(N,w,N.bl_tree),he(N,ge-3,3)):(ae(N,_,N.bl_tree),he(N,ge-11,7));fe=ie,Dt=(ge=0)===Ce?(He=138,3):ie===Ce?(He=6,3):(He=7,4)}}n(q);var ne=!1;function V(N,J,ce,de){he(N,(A<<1)+(de?1:0),3),(function(ie,fe,Ce,ge){Qe(ie),ge&&(ue(ie,Ce),ue(ie,~Ce)),i.arraySet(ie.pending_buf,ie.window,fe,Ce,ie.pending),ie.pending+=Ce})(N,J,ce,!0)}t._tr_init=function(N){ne||((function(){var J,ce,de,ie,fe,Ce=new Array(g+1);for(ie=de=0;ie<o-1;ie++)for(M[ie]=de,J=0;J<1<<T[ie];J++)F[de++]=ie;for(F[de-1]=ie,ie=fe=0;ie<16;ie++)for(q[ie]=fe,J=0;J<1<<Q[ie];J++)k[fe++]=ie;for(fe>>=7;ie<h;ie++)for(q[ie]=fe<<7,J=0;J<1<<Q[ie]-7;J++)k[256+fe++]=ie;for(ce=0;ce<=g;ce++)Ce[ce]=0;for(J=0;J<=143;)O[2*J+1]=8,J++,Ce[8]++;for(;J<=255;)O[2*J+1]=9,J++,Ce[9]++;for(;J<=279;)O[2*J+1]=7,J++,Ce[7]++;for(;J<=287;)O[2*J+1]=8,J++,Ce[8]++;for(Pe(O,c+1,Ce),J=0;J<h;J++)D[2*J+1]=5,D[2*J]=Ie(J,5);Y=new Ae(O,T,l+1,c,g),z=new Ae(D,Q,0,h,g),re=new Ae(new Array(0),U,0,d,m)})(),ne=!0),N.l_desc=new X(N.dyn_ltree,Y),N.d_desc=new X(N.dyn_dtree,z),N.bl_desc=new X(N.bl_tree,re),N.bi_buf=0,N.bi_valid=0,De(N)},t._tr_stored_block=V,t._tr_flush_block=function(N,J,ce,de){var ie,fe,Ce=0;0<N.level?(N.strm.data_type===2&&(N.strm.data_type=(function(ge){var He,Dt=4093624447;for(He=0;He<=31;He++,Dt>>>=1)if(1&Dt&&ge.dyn_ltree[2*He]!==0)return s;if(ge.dyn_ltree[18]!==0||ge.dyn_ltree[20]!==0||ge.dyn_ltree[26]!==0)return r;for(He=32;He<l;He++)if(ge.dyn_ltree[2*He]!==0)return r;return s})(N)),$t(N,N.l_desc),$t(N,N.d_desc),Ce=(function(ge){var He;for(I(ge,ge.dyn_ltree,ge.l_desc.max_code),I(ge,ge.dyn_dtree,ge.d_desc.max_code),$t(ge,ge.bl_desc),He=d-1;3<=He&&ge.bl_tree[2*E[He]+1]===0;He--);return ge.opt_len+=3*(He+1)+5+5+4,He})(N),ie=N.opt_len+3+7>>>3,(fe=N.static_len+3+7>>>3)<=ie&&(ie=fe)):ie=fe=ce+5,ce+4<=ie&&J!==-1?V(N,J,ce,de):N.strategy===4||fe===ie?(he(N,2+(de?1:0),3),mi(N,O,D)):(he(N,4+(de?1:0),3),(function(ge,He,Dt,lt){var Wi;for(he(ge,He-257,5),he(ge,Dt-1,5),he(ge,lt-4,4),Wi=0;Wi<lt;Wi++)he(ge,ge.bl_tree[2*E[Wi]+1],3);le(ge,ge.dyn_ltree,He-1),le(ge,ge.dyn_dtree,Dt-1)})(N,N.l_desc.max_code+1,N.d_desc.max_code+1,Ce+1),mi(N,N.dyn_ltree,N.dyn_dtree)),De(N),de&&Qe(N)},t._tr_tally=function(N,J,ce){return N.pending_buf[N.d_buf+2*N.last_lit]=J>>>8&255,N.pending_buf[N.d_buf+2*N.last_lit+1]=255&J,N.pending_buf[N.l_buf+N.last_lit]=255&ce,N.last_lit++,J===0?N.dyn_ltree[2*ce]++:(N.matches++,J--,N.dyn_ltree[2*(F[ce]+l+1)]++,N.dyn_dtree[2*G(J)]++),N.last_lit===N.lit_bufsize-1},t._tr_align=function(N){he(N,2,3),ae(N,b,O),(function(J){J.bi_valid===16?(ue(J,J.bi_buf),J.bi_buf=0,J.bi_valid=0):8<=J.bi_valid&&(J.pending_buf[J.pending++]=255&J.bi_buf,J.bi_buf>>=8,J.bi_valid-=8)})(N)}},{"../utils/common":41}],53:[function(a,e,t){"use strict";e.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(a,e,t){(function(i){(function(s,r){"use strict";if(!s.setImmediate){var n,A,o,l,c=1,h={},d=!1,u=s.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(s);g=g&&g.setTimeout?g:s,n={}.toString.call(s.process)==="[object process]"?function(B){process.nextTick(function(){m(B)})}:(function(){if(s.postMessage&&!s.importScripts){var B=!0,w=s.onmessage;return s.onmessage=function(){B=!1},s.postMessage("","*"),s.onmessage=w,B}})()?(l="setImmediate$"+Math.random()+"$",s.addEventListener?s.addEventListener("message",b,!1):s.attachEvent("onmessage",b),function(B){s.postMessage(l+B,"*")}):s.MessageChannel?((o=new MessageChannel).port1.onmessage=function(B){m(B.data)},function(B){o.port2.postMessage(B)}):u&&"onreadystatechange"in u.createElement("script")?(A=u.documentElement,function(B){var w=u.createElement("script");w.onreadystatechange=function(){m(B),w.onreadystatechange=null,A.removeChild(w),w=null},A.appendChild(w)}):function(B){setTimeout(m,0,B)},g.setImmediate=function(B){typeof B!="function"&&(B=new Function(""+B));for(var w=new Array(arguments.length-1),_=0;_<w.length;_++)w[_]=arguments[_+1];var T={callback:B,args:w};return h[c]=T,n(c),c++},g.clearImmediate=y}function y(B){delete h[B]}function m(B){if(d)setTimeout(m,0,B);else{var w=h[B];if(w){d=!0;try{(function(_){var T=_.callback,Q=_.args;switch(Q.length){case 0:T();break;case 1:T(Q[0]);break;case 2:T(Q[0],Q[1]);break;case 3:T(Q[0],Q[1],Q[2]);break;default:T.apply(r,Q)}})(w)}finally{y(B),d=!1}}}}function b(B){B.source===s&&typeof B.data=="string"&&B.data.indexOf(l)===0&&m(+B.data.slice(l.length))}})(typeof self>"u"?i===void 0?this:i:self)}).call(this,typeof global<"u"?global:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})});var Fx=Symbol(),Io=class{get taskComplete(){return this.t||(this.i===1?this.t=new Promise(((e,t)=>{this.o=e,this.h=t})):this.i===3?this.t=Promise.reject(this.l):this.t=Promise.resolve(this.u)),this.t}constructor(e,t,i){this.p=0,this.i=0,(this._=e).addController(this);let s=typeof t=="object"?t:{task:t,args:i};this.v=s.task,this.j=s.args,this.m=s.argsEqual??Sx,this.k=s.onComplete,this.A=s.onError,this.autoRun=s.autoRun??!0,"initialValue"in s&&(this.u=s.initialValue,this.i=2,this.O=this.T?.())}hostUpdate(){this.autoRun===!0&&this.S()}hostUpdated(){this.autoRun==="afterUpdate"&&this.S()}T(){if(this.j===void 0)return;let e=this.j();if(!Array.isArray(e))throw Error("The args function must return an array");return e}async S(){let e=this.T(),t=this.O;this.O=e,e===t||e===void 0||t!==void 0&&this.m(t,e)||await this.run(e)}async run(e){let t,i;e??=this.T(),this.O=e,this.i===1?this.q?.abort():(this.t=void 0,this.o=void 0,this.h=void 0),this.i=1,this.autoRun==="afterUpdate"?queueMicrotask((()=>this._.requestUpdate())):this._.requestUpdate();let s=++this.p;this.q=new AbortController;let r=!1;try{t=await this.v(e,{signal:this.q.signal})}catch(n){r=!0,i=n}if(this.p===s){if(t===Fx)this.i=0;else{if(r===!1){try{this.k?.(t)}catch{}this.i=2,this.o?.(t)}else{try{this.A?.(i)}catch{}this.i=3,this.h?.(i)}this.u=t,this.l=i}this._.requestUpdate()}}abort(e){this.i===1&&this.q?.abort(e)}get value(){return this.u}get error(){return this.l}get status(){return this.i}render(e){switch(this.i){case 0:return e.initial?.();case 1:return e.pending?.();case 2:return e.complete?.(this.value);case 3:return e.error?.(this.error);default:throw Error("Unexpected status: "+this.i)}}},Sx=(a,e)=>a===e||a.length===e.length&&a.every(((t,i)=>!fy(t,e[i])));var oB=dy(Tx(),1),lB=dy(Dx(),1);var j1=function(a){Zi(a,"SpriteState")&&(a.transitionDuration=400),Zi(a,"Component")&&(a.rangeChangeDuration=500,a.interpolationDuration=500,a.sequencedInterpolation=!1,Zi(a,"SankeyDiagram")&&(a.sequencedInterpolation=!0),Zi(a,"FunnelSeries")&&(a.sequencedInterpolation=!0)),Zi(a,"Chart")&&(a.defaultState.transitionDuration=2e3,a.hiddenState.transitionDuration=1e3),Zi(a,"Tooltip")&&(a.animationDuration=400,a.defaultState.transitionDuration=400,a.hiddenState.transitionDuration=400),Zi(a,"Scrollbar")&&(a.animationDuration=500),Zi(a,"Series")&&(a.defaultState.transitionDuration=1e3,a.hiddenState.transitionDuration=700,a.hiddenState.properties.opacity=1,a.showOnInit=!0),Zi(a,"MapSeries")&&(a.hiddenState.properties.opacity=0),Zi(a,"PercentSeries")&&(a.hiddenState.properties.opacity=0),Zi(a,"FunnelSlice")&&(a.defaultState.transitionDuration=800,a.hiddenState.transitionDuration=1e3,a.hiddenState.properties.opacity=1),Zi(a,"Slice")&&(a.defaultState.transitionDuration=700,a.hiddenState.transitionDuration=1e3,a.hiddenState.properties.opacity=1),Zi(a,"Preloader")&&(a.hiddenState.transitionDuration=2e3),Zi(a,"Column")&&(a.defaultState.transitionDuration=700,a.hiddenState.transitionDuration=1e3,a.hiddenState.properties.opacity=1),Zi(a,"Column3D")&&(a.hiddenState.properties.opacity=0)},Uh=j1;var ke=class a{constructor(e){this._value=e}get value(){return this._value/100}get percent(){return this._value}toString(){return""+this._value+"%"}interpolate(e,t){return e+this.value*(t-e)}static normalize(e,t,i){return e instanceof a?e:t===i?new a(0):new a(Math.min(Math.max((e-t)*(1/(i-t)),0),1)*100)}};function Re(a){return new ke(a)}var si=Re(0),se=Re(100),ye=Re(50);function of(a){return a instanceof ke}function Ni(a){return Number(a)!==a}function Z1(a){return{}.toString.call(a)}function Vi(a){if(a!=null&&!W(a)){let e=Number(a);if(Ni(e)&&Ur(a)&&a!=""&&a.match(/[0-9]+/)){let t=a.replace(/[^0-9.\-]+/g,"");return a===t?e:Vi(t)}return e}return a}function Ux(a){if(Qh(a))return new Date(a);if(W(a))return new Date(a);{let e=Number(a);return W(e)?new Date(e):new Date(a)}}function Qx(a){if(Ni(a))return"NaN";if(a===1/0)return"Infinity";if(a===-1/0)return"-Infinity";if(a===0&&1/a===-1/0)return"-0";let e=a<0;a=Math.abs(a);let t=/^([0-9]+)(?:\.([0-9]+))?(?:e[\+\-]([0-9]+))?$/.exec(""+a),i=t[1],s=t[2]||"",r;if(t[3]===void 0)r=s===""?i:i+"."+s;else{let n=+t[3];if(a<1){let A=n-1;r="0."+Lx("0",A)+i+s}else{let A=n-s.length;A===0?r=i+s:A<0?r=i+s.slice(0,A)+"."+s.slice(A):r=i+s+Lx("0",A)}}return e?"-"+r:r}function Lx(a,e){return new Array(e+1).join(a)}function Qh(a){return Z1(a)==="[object Date]"}function Ur(a){return typeof a=="string"}function W(a){return typeof a=="number"&&Number(a)==a}function Gs(a){return typeof a=="object"&&a!==null}function kh(a){return Array.isArray(a)}var Xs="__\xA7\xA7\xA7__",Ra="__\xA7\xA7\xA7\xA7__";function Qr(a,e){let t=a.length;for(let i=0;i<t;++i)if(a[i]===e)return i;return-1}function kx(a,e){let t=a.length;for(let i=0;i<t;++i)if(e(a[i]))return!0;return!1}function Do(a,e){let t=a.length,i=new Array(t);for(let s=0;s<t;++s)i[s]=e(a[s],s);return i}function K(a,e){let t=a.length;for(let i=0;i<t;++i)e(a[i],i)}function Oa(a,e){let t=a.length;for(;t>0;)--t,e(a[t],t)}function Lo(a,e){let t=a.length;for(let i=0;i<t&&e(a[i],i);++i);}function ri(a,e){let t=!1,i=0;for(;;){if(i=a.indexOf(e,i),i===-1)return t;t=!0,a.splice(i,1)}}function Jt(a,e){let t=a.indexOf(e);return t!==-1?(a.splice(t,1),!0):!1}function Uo(a,e,t){let i=Qr(a,e);i!==-1&&Eh(a,i),t==null?a.push(e):ko(a,t,e)}function Na(a,e){a.indexOf(e)===-1&&a.push(e)}function Qo(a){let e=a.length,t=new Array(e);for(let i=0;i<e;++i)t[i]=a[i];return t}function ko(a,e,t){a.splice(e,0,t)}function Eh(a,e){a.splice(e,1)}function lf(a,e){let t=a.length;for(let i=0;i<t;++i)if(e(a[i],i))return i;return-1}function q1(a,e){let t=a.length;for(;t>0;)if(--t,e(a[t],t))return t;return-1}function Ph(a,e){let t=lf(a,e);if(t!==-1)return a[t]}function Ex(a,e){let t=q1(a,e);if(t!==-1)return a[t]}function Eo(a,e){let t=0,i=a.length,s=!1;for(;t<i;){let r=t+i>>1,n=e(a[r]);if(n<0)t=r+1;else if(n===0){for(s=!0,t=r+1;t<i&&e(a[t])===0;t++);t--;break}else i=r}return{found:s,index:t}}function Mh(a,e){let t=0,i=a.length,s=!1;for(;t<i;){let r=t+i>>1,n=e(a[r]);n<0?t=r+1:(n===0&&(s=!0),i=r)}return{found:s,index:t}}function Un(a,e){let t=a.length;for(;t>0;)--t,e(a[t])||a.splice(t,1)}function Bi(a){return Object.keys(a)}function Ds(a){return Object.entries(a)}function hf(a,e){return Bi(a).sort(e)}function Ws(a){return Object.assign({},a)}function Ve(a,e){Bi(a).forEach(t=>{e(t,a[t])})}function Px(a,e){for(let t in a)if(J1(a,t)&&!e(t,a[t]))break}function ca(a,e,t){K(hf(a,t),i=>{e(i,a[i])})}function J1(a,e){return{}.hasOwnProperty.call(a,e)}var Va=class{constructor(){this._disposed=!1}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}},Qt=class{constructor(e){this._disposed=!1,this._dispose=e}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}},Hh=class extends Va{constructor(){super(...arguments),this._disposers=[]}_dispose(){K(this._disposers,e=>{e.dispose()})}},zt=class extends Va{constructor(e){super(),this._disposers=e}_dispose(){K(this._disposers,e=>{e.dispose()})}get disposers(){return this._disposers}};var _A=class extends Qt{constructor(){super(...arguments),this._counter=0}increment(){return++this._counter,new Qt(()=>{--this._counter,this._counter===0&&this.dispose()})}};function Rx(a){a.parentNode&&a.parentNode.removeChild(a)}function kt(a,e,t,i){return a.addEventListener(e,t,i||!1),new Qt(()=>{a.removeEventListener(e,t,i||!1)})}function Oh(a){return kt(window,"resize",e=>{a()})}function zs(a){switch(a){case"touchevents":return window.hasOwnProperty("TouchEvent");case"pointerevents":return window.hasOwnProperty("PointerEvent");case"mouseevents":return window.hasOwnProperty("MouseEvent");case"wheelevents":return window.hasOwnProperty("WheelEvent");case"keyboardevents":return window.hasOwnProperty("KeyboardEvent")}return!1}function Nh(a){return a.pointerId||0}function Ox(){if(document.activeElement&&document.activeElement!=document.body)if(document.activeElement.blur)document.activeElement.blur();else{let a=document.createElement("button");a.style.position="fixed",a.style.top="0px",a.style.left="-10000px",document.body.appendChild(a),a.focus(),a.blur(),document.body.removeChild(a)}}function Nx(a){a&&a.focus()}function Vh(a){if(zs("pointerevents"))return a;if(zs("touchevents"))switch(a){case"pointerover":return"touchstart";case"pointerout":return"touchend";case"pointerleave":return"touchend";case"pointerdown":return"touchstart";case"pointermove":return"touchmove";case"pointerup":return"touchend";case"click":return"click";case"dblclick":return"dblclick"}else if(zs("mouseevents"))switch(a){case"pointerover":return"mouseover";case"pointerout":return"mouseout";case"pointerleave":return"mouseleave";case"pointerdown":return"mousedown";case"pointermove":return"mousemove";case"pointerup":return"mouseup";case"click":return"click";case"dblclick":return"dblclick"}return a}function Mo(a){if(typeof Touch<"u"&&a instanceof Touch)return!0;if(typeof PointerEvent<"u"&&a instanceof PointerEvent&&a.pointerType!=null)switch(a.pointerType){case"touch":case"pen":case 2:return!0;case"mouse":case 4:return!1;default:return!(a instanceof MouseEvent)}else if(a.type!=null&&a.type.match(/^mouse/))return!1;return!0}function Ho(a,e,t){a.style[e]=t}function Vx(a,e){return a.style[e]}function df(a){if(a.composedPath){let e=a.composedPath();return e.length===0?null:e[0]}else return a.target}function eT(a,e){let t=e;for(;;){if(a===t)return!0;if(t.parentNode===null){if(t.host==null)return!1;t=t.host}else t=t.parentNode}}function FA(a,e){return a.target&&eT(e.root.dom,a.target)}function Ka(a,e){e?a.style.pointerEvents="auto":a.style.pointerEvents="none"}function kn(a){if(a.key!==void 0)return a.key;switch(a.keyCode){case 9:return"Tab";case 13:return"Enter";case 16:return"Shift";case 17:return"Control";case 27:return"Escape";case 32:return" ";case 37:return"ArrowLeft";case 38:return"ArrowUp";case 39:return"ArrowRight";case 40:return"ArrowDown";case 46:return"Delete"}return""+a.keyCode}function uf(a){let e=a;for(;;){if(e.parentNode===null)return e.host!=null?e:null;e=e.parentNode}}var cf;function tT(a,e=""){if(a===null){if(cf==null){let t=document.createElement("style");t.type="text/css",e!=""&&t.setAttribute("nonce",e),document.head.appendChild(t),cf=t.sheet}return cf}else{let t=document.createElement("style");return t.type="text/css",e!=""&&t.setAttribute("nonce",e),a.appendChild(t),t.sheet}}function Mx(a,e){let t=a.cssRules.length;return a.insertRule(e+"{}",t),a.cssRules[t]}var Po=class extends Va{constructor(e,t,i,s=""){super(),this._root=tT(e,s);try{this._rule=Mx(this._root,t)}catch{this._rule=Mx(this._root,":not(*)")}Ve(i,(r,n)=>{this.setStyle(r,n)})}set selector(e){this._rule.selectorText=e}get selector(){return this._rule.selectorText}_dispose(){let e=Qr(this._root.cssRules,this._rule);if(e===-1)throw new Error("Could not dispose StyleRule");this._root.deleteRule(e)}_setVendorPrefixName(e,t){let i=this._rule.style;i.setProperty("-webkit-"+e,t,""),i.setProperty("-moz-"+e,t,""),i.setProperty("-ms-"+e,t,""),i.setProperty("-o-"+e,t,""),i.setProperty(e,t,"")}setStyle(e,t){e==="transition"?this._setVendorPrefixName(e,t):this._rule.style.setProperty(e,t,"")}};function iT(){return/apple/i.test(navigator.vendor)&&"ontouchend"in document}function $x(){return iT()?1:void 0}function We(a,e){return W(a)?a:a!=null&&W(a.value)&&W(e)?e*a.value:0}function $h(a){let e=(""+a).match(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/);return e?Math.max(0,(e[1]?e[1].length:0)-(e[2]?+e[2]:0)):0}function Yt(a,e=0,t="0"){return typeof a!="string"&&(a=a.toString()),e>a.length?Array(e-a.length+1).join(t)+a:a}function sT(a){return a.replace(/^[\s]*/,"")}function rT(a){return a.replace(/[\s]*$/,"")}function $a(a){return sT(rT(a))}function Kx(a,e,t=!1,i="..."){if(a.length>e){let s=e-1;for(;s>=0&&a.charAt(s).match(/\w/);)s--;return s>=0&&t==!1?a.substring(0,s+1)+"...":a.substring(0,e)+i}else return a}function Gx(a){if(typeof a>"u")return"string";a=a.toLowerCase().replace(/^\[[^\]]*\]/,""),a=a.replace(/\[[^\]]+\]/,""),a=a.trim();let e=a.match(/\/(date|number|duration)$/);return e?e[1]:a==="number"?"number":a==="date"?"date":a==="duration"?"duration":a.match(/[#0]/)?"number":a.match(/[ymwdhnsqaxkzgtei]/)?"date":"string"}function SA(a){return a.replace(/\/(date|number|duration)$/i,"")}function ff(a){return a&&a.replace(/<[^>]*>/g,"")}function gf(a){return a.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}function Xx(a){let e=/[\u0590-\u05FF\u0600-\u06FF\u0750-\u077F\u08A0-\u08FF\uFB50-\uFDFF\uFE70-\uFEFF]/,t=/([^اأدذرزو]*[اأدذرزو])/gi,i=a.split(/(\s+)/),s=[];return i.forEach(r=>{if(r.match(/^\s+$/))(r=" ")&&(r=" "),s.push(r);else if(e.test(r)){let n=r.split(t).filter(A=>A!=="");s=s.concat(n)}else s=s.concat([...r])}),s}function pf(a,e=!1){let t=new Date(a.getFullYear(),0,0),i=a.getTime()-t.getTime()+(t.getTimezoneOffset()-a.getTimezoneOffset())*60*1e3,s=1e3*60*60*24;return Math.floor(i/s)}function Qn(a,e=!1){let t=new Date(Date.UTC(a.getFullYear(),a.getMonth(),a.getDate())),i=t.getUTCDay()||7;t.setUTCDate(t.getUTCDate()+4-i);let s=new Date(Date.UTC(t.getUTCFullYear(),0,1));return Math.ceil(((t.getTime()-s.getTime())/864e5+1)/7)}function Wx(a,e=!1){let t=new Date(Date.UTC(a.getFullYear(),a.getMonth(),a.getDate())),i=t.getUTCDay()||7;return t.setUTCDate(t.getUTCDate()+4-i),new Date(Date.UTC(t.getUTCFullYear(),0,1)).getFullYear()}function zx(a,e=!1){let t=Qn(new Date(a.getFullYear(),a.getMonth(),1),e),i=Qn(a,e);return i==1&&(i=53),i-t+1}function Yx(a,e,t=1,i=!1){let s=new Date(e,0,4,0,0,0,0);return i&&s.setUTCFullYear(e),a*7+t-((s.getDay()||7)+3)}function Ro(a,e){return a>12?a-=12:a===0&&(a=12),e!=null?a+(e-1):a}function Oo(a,e=!1,t=!1,i=!1,s){if(i)return e?"Coordinated Universal Time":"UTC";if(s){let A=a.toLocaleString("en-US",{timeZone:s}),o=a.toLocaleString("en-US",{timeZone:s,timeZoneName:e?"long":"short"});return $a(o.substr(A.length))}let r=a.toLocaleString("UTC"),n=a.toLocaleString("UTC",{timeZoneName:e?"long":"short"}).substr(r.length);return t===!1&&(n=n.replace(/ (standard|daylight|summer|winter) /i," ")),$a(n)}function jx(a,e){let t=e||new Date(Date.UTC(2012,0,1,0,0,0,0)),i=new Date(t.toLocaleString("en-US",{timeZone:"UTC"}));return(new Date(t.toLocaleString("en-US",{timeZone:a})).getTime()-i.getTime())/6e4*-1}function mf(a){return a.charAt(0).toUpperCase()+a.slice(1)}function yf(a){let e,t,i,s=a.h,r=a.s,n=a.l;if(r==0)e=t=i=n;else{let A=function(h,d,u){return u<0&&(u+=1),u>1&&(u-=1),u<.16666666666666666?h+(d-h)*6*u:u<.5?d:u<.6666666666666666?h+(d-h)*(.6666666666666666-u)*6:h},o=n<.5?n*(1+r):n+r-n*r,l=2*n-o;e=A(l,o,s+1/3),t=A(l,o,s),i=A(l,o,s-1/3)}return{r:Math.round(e*255),g:Math.round(t*255),b:Math.round(i*255)}}function vf(a){let e=a.r/255,t=a.g/255,i=a.b/255,s=Math.max(e,t,i),r=Math.min(e,t,i),n=0,A=0,o=(s+r)/2;if(s===r)n=A=0;else{let l=s-r;switch(A=o>.5?l/(2-s-r):l/(s+r),s){case e:n=(t-i)/l+(t<i?6:0);break;case t:n=(i-e)/l+2;break;case i:n=(e-t)/l+4;break}n/=6}return{h:n,s:A,l:o}}function Zx(a,e){return a&&{r:Math.max(0,Math.min(255,a.r+Rh(a.r,e))),g:Math.max(0,Math.min(255,a.g+Rh(a.g,e))),b:Math.max(0,Math.min(255,a.b+Rh(a.b,e))),a:a.a}}function Rh(a,e){let t=e>0?255-a:a;return Math.round(t*e)}function qx(a,e){if(a){let t=Math.min(Math.max(a.r,a.g,a.b),230),i=Rh(t,e);return{r:Math.max(0,Math.min(255,Math.round(a.r+i))),g:Math.max(0,Math.min(255,Math.round(a.g+i))),b:Math.max(0,Math.min(255,Math.round(a.b+i))),a:a.a}}else return a}function Hx(a){return(a.r*299+a.g*587+a.b*114)/1e3>=128}function Jx(a,e){if(a===void 0||e==1)return a;let t=vf(a);return t.s=e,yf(t)}function eb(a,e={r:255,g:255,b:255},t={r:255,g:255,b:255}){let i=e,s=t;return Hx(t)&&(i=t,s=e),Hx(a)?s:i}function Fe(a,e){return a||(a=[]),[...a,...e].filter((t,i,s)=>s.indexOf(t)===i)}function Kh(a,e){return!(!e||a.left!=e.left||a.right!=e.right||a.top!=e.top||a.bottom!=e.bottom)}function tb(a){return a[0]==="#"&&(a=a.substr(1)),a.length==3&&(a=a[0].repeat(2)+a[1].repeat(2)+a[2].repeat(2)),parseInt(a,16)}function aT(a){a=a.replace(/[ ]/g,"");let e=a.match(/^rgb\(([0-9]*),([0-9]*),([0-9]*)\)/i);if(e)e.push("1");else if(e=a.match(/^rgba\(([0-9]*),([0-9]*),([0-9]*),([.0-9]*)\)/i),!e)return 0;let t="";for(let i=1;i<=3;i++){let s=parseInt(e[i]).toString(16);s.length==1&&(s="0"+s),t+=s}return tb(t)}function $i(a){return we.fromAny(a)}var we=class a{constructor(e){this._hex=e|0}get hex(){return this._hex}get r(){return this._hex>>>16}get g(){return this._hex>>8&255}get b(){return this._hex&255}toCSS(e=1){return"rgba("+this.r+", "+this.g+", "+this.b+", "+e+")"}toCSSHex(){return"#"+Yt(this.r.toString(16),2)+Yt(this.g.toString(16),2)+Yt(this.b.toString(16),2)}toHSL(e=1){return vf({r:this.r,g:this.g,b:this.b,a:e})}static fromHSL(e,t,i){let s=yf({h:e,s:t,l:i});return this.fromRGB(s.r,s.g,s.b)}toString(){return this.toCSSHex()}static fromHex(e){return new a(e)}static fromRGB(e,t,i){return new a((i|0)+(t<<8)+(e<<16))}static fromString(e){return new a(tb(e))}static fromCSS(e){return new a(aT(e))}static fromAny(e){if(Ur(e)){if(e[0]=="#")return a.fromString(e);if(e.substr(0,3)=="rgb")return a.fromCSS(e)}else{if(W(e))return a.fromHex(e);if(e instanceof a)return a.fromHex(e.hex)}throw new Error("Unknown color syntax: "+e)}static alternative(e,t,i){let s=eb({r:e.r,g:e.g,b:e.b},t?{r:t.r,g:t.g,b:t.b}:void 0,i?{r:i.r,g:i.g,b:i.b}:void 0);return this.fromRGB(s.r,s.g,s.b)}static interpolate(e,t,i,s="rgb"){if(s=="hsl"){let r=t.toHSL(),n=i.toHSL();return a.fromHSL(da(e,r.h,n.h),da(e,r.s,n.s),da(e,r.l,n.l))}else return a.fromRGB(da(e,t.r,i.r),da(e,t.g,i.g),da(e,t.b,i.b))}static lighten(e,t){let i=Zx({r:e.r,g:e.g,b:e.b},t);return a.fromRGB(i.r,i.g,i.b)}static brighten(e,t){let i=qx({r:e.r,g:e.g,b:e.b},t);return a.fromRGB(i.r,i.g,i.b)}static saturate(e,t){let i=Jx({r:e.r,g:e.g,b:e.b},t);return a.fromRGB(i.r,i.g,i.b)}};var Ls=class{constructor(){this._listeners=[],this._killed=[],this._disabled={},this._iterating=0,this._enabled=!0,this._disposed=!1}isDisposed(){return this._disposed}dispose(){if(!this._disposed){this._disposed=!0;let e=this._listeners;this._iterating=1,this._listeners=null,this._disabled=null;try{K(e,t=>{t.disposer.dispose()})}finally{this._killed=null,this._iterating=null}}}hasListeners(){return this._listeners.length!==0}hasListenersByType(e){return kx(this._listeners,t=>(t.type===null||t.type===e)&&!t.killed)}enable(){this._enabled=!0}disable(){this._enabled=!1}enableType(e){delete this._disabled[e]}disableType(e,t=1/0){this._disabled[e]=t}_removeListener(e){if(this._iterating===0){let t=this._listeners.indexOf(e);if(t===-1)throw new Error("Invalid state: could not remove listener");this._listeners.splice(t,1)}else this._killed.push(e)}_removeExistingListener(e,t,i,s){if(this._disposed)throw new Error("EventDispatcher is disposed");this._eachListener(r=>{r.once===e&&r.type===t&&(i===void 0||r.callback===i)&&r.context===s&&r.disposer.dispose()})}isEnabled(e){if(this._disposed)throw new Error("EventDispatcher is disposed");return this._enabled&&this._listeners.length>0&&this.hasListenersByType(e)&&this._disabled[e]===void 0}removeType(e){if(this._disposed)throw new Error("EventDispatcher is disposed");this._eachListener(t=>{t.type===e&&t.disposer.dispose()})}has(e,t,i){return lf(this._listeners,r=>r.once!==!0&&r.type===e&&(t===void 0||r.callback===t)&&r.context===i)!==-1}_shouldDispatch(e){if(this._disposed)throw new Error("EventDispatcher is disposed");let t=this._disabled[e];return W(t)?(t<=1?delete this._disabled[e]:--this._disabled[e],!1):this._enabled}_eachListener(e){++this._iterating;try{K(this._listeners,e)}finally{--this._iterating,this._iterating===0&&this._killed.length!==0&&(K(this._killed,t=>{this._removeListener(t)}),this._killed.length=0)}}dispatch(e,t){this._shouldDispatch(e)&&this._eachListener(i=>{!i.killed&&(i.type===null||i.type===e)&&(i._debounceDelay?(i._debounceTimeout&&window.clearTimeout(i._debounceTimeout),i._debounceTimeout=window.setTimeout(()=>{i._debounceTimeout=void 0,i.killed||i.dispatch(e,t)},i._debounceDelay)):i.dispatch(e,t))})}_on(e,t,i,s,r,n,A){if(this._disposed)throw new Error("EventDispatcher is disposed");this._removeExistingListener(e,t,i,s);let o={type:t,callback:i,context:s,shouldClone:r,dispatch:n,killed:!1,once:e,disposer:new Qt(()=>{o.killed=!0,o._debounceTimeout&&window.clearTimeout(o._debounceTimeout),this._removeListener(o)}),_debounceDelay:A};return this._listeners.push(o),o}onAll(e,t,i=!0){return this._on(!1,null,e,t,i,(s,r)=>e.call(t,r)).disposer}on(e,t,i,s=!0){return this._on(!1,e,t,i,s,(r,n)=>t.call(i,n)).disposer}onDebounced(e,t,i,s,r=!0){return this._on(!1,e,t,s,r,(n,A)=>t.call(s,A),i).disposer}once(e,t,i,s=!0){let r=this._on(!0,e,t,i,s,(n,A)=>{r.disposer.dispose(),t.call(i,A)});return r.disposer}off(e,t,i){this._removeExistingListener(!1,e,t,i)}copyFrom(e){if(this._disposed)throw new Error("EventDispatcher is disposed");if(e===this)throw new Error("Cannot copyFrom the same TargetedEventDispatcher");let t=[];return K(e._listeners,i=>{!i.killed&&i.shouldClone&&(i.type===null?t.push(this.onAll(i.callback,i.context)):i.once?t.push(this.once(i.type,i.callback,i.context)):t.push(this.on(i.type,i.callback,i.context)))}),new zt(t)}};function xf(a){return Ke(this,void 0,void 0,function*(){if(a!==void 0){let e=[];Ve(a,(t,i)=>{e.push(i.waitForStop())}),yield Promise.all(e)}})}function da(a,e,t){return e+a*(t-e)}function nT(a,e,t){return a>=1?t:e}function bf(a,e,t){return new ke(da(a,e.percent,t.percent))}function AT(a,e,t){return we.interpolate(a,e,t)}function ib(a,e){return typeof a=="number"&&typeof e=="number"?da:a instanceof ke&&e instanceof ke?bf:a instanceof we&&e instanceof we?AT:nT}var ua;(function(a){a[a.Stopped=0]="Stopped",a[a.Playing=1]="Playing",a[a.Paused=2]="Paused"})(ua||(ua={}));function No(a,e){if(!(a>=0&&a<e))throw new Error("Index out of bounds: "+a)}var Us=class{constructor(e=[]){this.events=new Ls,this._values=e}get values(){return this._values}contains(e){return this._values.indexOf(e)!==-1}removeValue(e){let t=0,i=this._values.length;for(;t<i;)this._values[t]===e?(this.removeIndex(t),--i):++t}indexOf(e){return Qr(this._values,e)}get length(){return this._values.length}hasIndex(e){return e>=0&&e<this._values.length}getIndex(e){return this._values[e]}_onPush(e){this.events.isEnabled("push")&&this.events.dispatch("push",{type:"push",target:this,newValue:e})}_onInsertIndex(e,t){this.events.isEnabled("insertIndex")&&this.events.dispatch("insertIndex",{type:"insertIndex",target:this,index:e,newValue:t})}_onSetIndex(e,t,i){this.events.isEnabled("setIndex")&&this.events.dispatch("setIndex",{type:"setIndex",target:this,index:e,oldValue:t,newValue:i})}_onSwap(e,t){this.events.isEnabled("swap")&&this.events.dispatch("swap",{type:"swap",target:this,a:e,b:t})}_onRemoveIndex(e,t){this.events.isEnabled("removeIndex")&&this.events.dispatch("removeIndex",{type:"removeIndex",target:this,index:e,oldValue:t})}_onMoveIndex(e,t,i){this.events.isEnabled("moveIndex")&&this.events.dispatch("moveIndex",{type:"moveIndex",target:this,oldIndex:e,newIndex:t,value:i})}_onClear(e){this.events.isEnabled("clear")&&this.events.dispatch("clear",{type:"clear",target:this,oldValues:e})}setIndex(e,t){No(e,this._values.length);let i=this._values[e];return i!==t&&(this._values[e]=t,this._onSetIndex(e,i,t)),i}insertIndex(e,t){return No(e,this._values.length+1),ko(this._values,e,t),this._onInsertIndex(e,t),t}swap(e,t){let i=this._values.length;if(No(e,i),No(t,i),e!==t){let s=this._values[e],r=this._values[t];this._values[e]=r,this._values[t]=s,this._onSwap(s,r)}}removeIndex(e){No(e,this._values.length);let t=this._values[e];return Eh(this._values,e),this._onRemoveIndex(e,t),t}moveValue(e,t){let i=this.indexOf(e);if(i!==-1)if(Eh(this._values,i),t==null){let s=this._values.length;this._values.push(e),this._onMoveIndex(i,s,e)}else ko(this._values,t,e),this._onMoveIndex(i,t,e);else t==null?(this._values.push(e),this._onPush(e)):(ko(this._values,t,e),this._onInsertIndex(t,e));return e}push(e){return this._values.push(e),this._onPush(e),e}unshift(e){return this.insertIndex(0,e),e}pushAll(e){K(e,t=>{this.push(t)})}copyFrom(e){this.pushAll(e._values)}pop(){return this._values.length-1<0?void 0:this.removeIndex(this._values.length-1)}shift(){return this._values.length?this.removeIndex(0):void 0}setAll(e){let t=this._values;this._values=[],this._onClear(t),K(e,i=>{this._values.push(i),this._onPush(i)})}clear(){this.setAll([])}*[Symbol.iterator](){let e=this._values.length;for(let t=0;t<e;++t)yield this._values[t]}each(e){K(this._values,e)}eachReverse(e){Oa(this._values,e)}},Ga=class extends Us{constructor(){super(...arguments),this.autoDispose=!0,this._disposed=!1}swap(e,t){let i=this.autoDispose;this.autoDispose=!1,super.swap(e,t),this.autoDispose=i}_onSetIndex(e,t,i){this.autoDispose&&t.dispose(),super._onSetIndex(e,t,i)}_onRemoveIndex(e,t){this.autoDispose&&t.dispose(),super._onRemoveIndex(e,t)}_onClear(e){this.autoDispose&&K(e,t=>{t.dispose()}),super._onClear(e)}_dispose(){this.autoDispose&&K(this._values,e=>{e.dispose()})}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}},pt=class extends Ga{constructor(e,t){super(),this.template=e,this.make=t}_dispose(){super._dispose(),this.autoDispose&&this.template.dispose()}};var Gh=class extends Us{constructor(e){super(),this._disposed=!1,this._container=e,this._events=this.events.onAll(t=>{if(t.type==="clear")K(t.oldValues,i=>{this._onRemoved(i)});else if(t.type==="push")this._onInserted(t.newValue);else if(t.type==="setIndex")this._onRemoved(t.oldValue),this._onInserted(t.newValue,t.index);else if(t.type==="insertIndex")this._onInserted(t.newValue,t.index);else if(t.type==="removeIndex")this._onRemoved(t.oldValue);else if(t.type==="moveIndex")this._onRemoved(t.value),this._onInserted(t.value,t.newIndex);else throw new Error("Unknown IListEvent type")})}_onInserted(e,t){e._setParent(this._container,!0);let i=this._container._childrenDisplay;t===void 0?i.addChild(e._display):i.addChildAt(e._display,t)}_onRemoved(e){this._container._childrenDisplay.removeChild(e._display),this._container.markDirtyBounds(),this._container.markDirty()}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._events.dispose(),K(this.values,e=>{e.dispose()}))}};var wf=Math.PI,pP=wf/2,Kt=wf/180,bs=180/wf;function jt(a,e,t){if(!W(e)||e<=0){let i=Math.round(a);return t&&i-a==.5&&i--,i}else{let i=Math.pow(10,e);return Math.round(a*i)/i}}function Cf(a,e){if(!W(e)||e<=0)return Math.ceil(a);{let t=Math.pow(10,e);return Math.ceil(a*t)/t}}function Bt(a,e,t){return Math.min(Math.max(a,e),t)}function At(a){return Math.sin(Kt*a)}function ft(a){return Math.cos(Kt*a)}function es(a){return a=a%360,a<0&&(a+=360),a}function Xa(a,e,t,i,s){let r=Number.MAX_VALUE,n=Number.MAX_VALUE,A=-Number.MAX_VALUE,o=-Number.MAX_VALUE,l=[];l.push(Bf(s,t)),l.push(Bf(s,i));let c=Math.min(Math.floor(t/90)*90,Math.floor(i/90)*90),h=Math.max(Math.ceil(t/90)*90,Math.ceil(i/90)*90);for(let d=c;d<=h;d+=90)d>=t&&d<=i&&l.push(Bf(s,d));for(let d=0;d<l.length;d++){let u=l[d];u.x<r&&(r=u.x),u.y<n&&(n=u.y),u.x>A&&(A=u.x),u.y>o&&(o=u.y)}return{left:a+r,top:e+n,right:a+A,bottom:e+o}}function Bf(a,e){return{x:a*ft(e),y:a*At(e)}}function Xh(a){let e=a.length;if(e>0){let t=a[0],i=t.left,s=t.top,r=t.right,n=t.bottom;if(e>1)for(let A=1;A<e;A++)t=a[A],i=Math.min(t.left,i),r=Math.max(t.right,r),s=Math.min(t.top,s),n=Math.max(t.bottom,n);return{left:i,right:r,top:s,bottom:n}}return{left:0,right:0,top:0,bottom:0}}function _f(a,e,t){if(e>t){let n=e;e=t,t=n}a=es(a);let i=(e-es(e))/360;a<e&&(a+=360*(i+1));let s=e+(t-e)/2+180,r=e+(t-e)/2-180;return a>t&&(a-360>e?a-=360:a<s?a=t:a=e),a<e&&(a>r?a=e:a=t),a}function sb(a,e){return a.x>=e.left&&a.y>=e.top&&a.x<=e.right&&a.y<=e.bottom}function Ff(a){return a}function dr(a){return a*a*a}function fa(a){return function(e){return 1-a(1-e)}}var rb=4/11,mP=6/11,yP=8/11,vP=3/4,xP=9/11,bP=10/11,BP=15/16,wP=21/22,CP=63/64,_P=1/rb/rb;var oT=2*Math.PI,lT=1,hT=.3/oT,FP=Math.asin(1/lT)*hT;var Sf=class{constructor(e,t){this._userSettings={},this._entity=e,this._settings=t,Ve(t,i=>{this._userSettings[i]=!0})}get(e,t){let i=this._settings[e];return i!==void 0?i:t}setRaw(e,t){this._settings[e]=t}set(e,t){this._userSettings[e]=!0,this.setRaw(e,t)}remove(e){delete this._userSettings[e],delete this._settings[e]}setAll(e){Ds(e).forEach(([t,i])=>{this.set(t,i)})}_eachSetting(e){Ve(this._settings,e)}apply(){let e={};e.stateAnimationEasing=!0,e.stateAnimationDuration=!0;let t=this._entity.states.lookup("default");this._eachSetting((i,s)=>{e[i]||(e[i]=!0,this!==t&&(i in t._settings||(t._settings[i]=this._entity.get(i))),this._entity.set(i,s))})}applyAnimate(e){e==null&&(e=this._settings.stateAnimationDuration),e==null&&(e=this.get("stateAnimationDuration",this._entity.get("stateAnimationDuration",0)));let t=this._settings.stateAnimationEasing;t==null&&(t=this.get("stateAnimationEasing",this._entity.get("stateAnimationEasing",dr)));let i=this._entity.states.lookup("default"),s={};s.stateAnimationEasing=!0,s.stateAnimationDuration=!0;let r={};return this._eachSetting((n,A)=>{if(!s[n]){s[n]=!0,this!=i&&(n in i._settings||(i._settings[n]=this._entity.get(n)));let o=this._entity.animate({key:n,to:A,duration:e,easing:t});o&&(r[n]=o)}}),r}},zh=class{constructor(e){this._states={},this._entity=e}lookup(e){return this._states[e]}create(e,t){let i=this._states[e];if(i)return i.setAll(t),i;{let s=new Sf(this._entity,t);return this._states[e]=s,s}}remove(e){delete this._states[e]}apply(e){let t=this._states[e];t&&t.apply(),this._entity._applyState(e)}applyAnimate(e,t){let i,s=this._states[e];return s&&(i=s.applyAnimate(t)),this._entity._applyStateAnimated(e,t),i}};var Tf=class{constructor(){this.version="5.16.2",this.licenses=[],this.entitiesById={},this.rootElements=[],this.autoDispose=!1}},ls=new Tf;function If(a){ls.licenses.push(a)}function Bs(a,e){return a===e?0:a<e?-1:1}function Yh(a,e,t){let i=a.length,s=e.length,r=Math.min(i,s);for(let n=0;n<r;++n){let A=t(a[n],e[n]);if(A!==0)return A}return Bs(i,s)}function Df(a,e){return a===e?0:a<e?-1:1}var Lf=class{constructor(e){this._callbacks={},this._disabled={},this._entity=e}add(e,t){let i=this._callbacks[e];return i===void 0&&(i=this._callbacks[e]=[]),i.push(t),this._entity._markDirtyKey(e),new Qt(()=>{Jt(i,t)&&this._entity._markDirtyKey(e)})}remove(e){let t=this._callbacks[e];t!==void 0&&(delete this._callbacks[e],t.length!==0&&this._entity._markDirtyKey(e))}enable(e){this._disabled[e]&&(delete this._disabled[e],this._entity._markDirtyKey(e))}disable(e){this._disabled[e]||(this._disabled[e]=!0,this._entity._markDirtyKey(e))}fold(e,t){if(!this._disabled[e]){let i=this._callbacks[e];if(i!==void 0)for(let s=0,r=i.length;s<r;++s)t=i[s](t,this._entity,e)}return t}},TA=class{constructor(e,t,i,s,r,n,A){this._time=0,this._stopped=!1,this._playing=!0,this.events=new Ls,this._animation=e,this._from=t,this._to=i,this._duration=s,this._easing=r,this._loops=n,this._interpolate=ib(t,i),this._oldTime=A}get to(){return this._to}get from(){return this._from}get playing(){return this._playing}get stopped(){return this._stopped}stop(){this._stopped||(this._stopped=!0,this._playing=!1,this.events.isEnabled("stopped")&&this.events.dispatch("stopped",{type:"stopped",target:this}))}pause(){this._playing=!1,this._oldTime=null}play(){!this._stopped&&!this._playing&&(this._playing=!0,this._animation._startAnimation())}get percentage(){return this._time/this._duration}waitForStop(){return new Promise((e,t)=>{if(this._stopped)e();else{let i=()=>{s.dispose(),e()},s=this.events.on("stopped",i)}})}_checkEnded(){return this._loops>1?(--this._loops,!1):!0}_run(e){this._oldTime!==null&&(this._time+=e-this._oldTime,this._time>this._duration&&(this._time=this._duration)),this._oldTime=e}_reset(e){this._oldTime=e,this._time=0}_value(e){return this._interpolate(this._easing(e),this._from,this._to)}},cT=0,$o=class{constructor(e){this.uid=++cT,this._privateSettings={},this._settingEvents={},this._privateSettingEvents={},this._prevSettings={},this._prevPrivateSettings={},this._animatingSettings={},this._animatingPrivateSettings={},this._disposed=!1,this._userProperties={},this.enableDispose=!0,this._settings=e}_checkDirty(){Bi(this._settings).forEach(e=>{this._userProperties[e]=!0,this._markDirtyKey(e)})}resetUserSettings(){this._userProperties={}}_runAnimation(e){let t=ua.Stopped;if(!this.isDisposed()){let i=!1,s=!1;Ve(this._animatingSettings,(r,n)=>{if(n.stopped)this._stopAnimation(r);else if(n.playing){n._run(e);let A=n.percentage;A>=1?n._checkEnded()?this.set(r,n._value(1)):(i=!0,n._reset(e),this._set(r,n._value(1))):(i=!0,this._set(r,n._value(A)))}else s=!0}),Ve(this._animatingPrivateSettings,(r,n)=>{if(n.stopped)this._stopAnimationPrivate(r);else if(n.playing){n._run(e);let A=n.percentage;A>=1?n._checkEnded()?this.setPrivate(r,n._value(1)):(i=!0,n._reset(e),this._setPrivate(r,n._value(1))):(i=!0,this._setPrivate(r,n._value(A)))}else s=!0}),i?t=ua.Playing:s&&(t=ua.Paused)}return t}_markDirtyKey(e){this.markDirty()}_markDirtyPrivateKey(e){this.markDirty()}on(e,t){let i=this._settingEvents[e];return i===void 0&&(i=this._settingEvents[e]=[]),i.push(t),new Qt(()=>{Jt(i,t),i.length===0&&delete this._settingEvents[e]})}off(e,t){let i=this._settingEvents[e];i!==void 0&&t!==void 0?Jt(i,t):delete this._settingEvents[e]}onPrivate(e,t){let i=this._privateSettingEvents[e];return i===void 0&&(i=this._privateSettingEvents[e]=[]),i.push(t),new Qt(()=>{Jt(i,t),i.length===0&&delete this._privateSettingEvents[e]})}offPrivate(e,t){let i=this._privateSettingEvents[e];i!==void 0&&t!==void 0?Jt(i,t):delete this._privateSettingEvents[e]}getRaw(e,t){let i=this._settings[e];return i!==void 0?i:t}has(e){return e in this._settings}get(e,t){return this.getRaw(e,t)}_sendKeyEvent(e,t){let i=this._settingEvents[e];i!==void 0&&K(i,s=>{s(t,this,e)})}_sendPrivateKeyEvent(e,t){let i=this._privateSettingEvents[e];i!==void 0&&K(i,s=>{s(t,this,e)})}_setRaw(e,t,i){this._prevSettings[e]=t,this._sendKeyEvent(e,i)}setRaw(e,t){let i=this._settings[e];this._settings[e]=t,i!==t&&this._setRaw(e,i,t)}_set(e,t){let i=this._settings[e];this._settings[e]=t,i!==t&&(this._setRaw(e,i,t),this._markDirtyKey(e))}_stopAnimation(e){let t=this._animatingSettings[e];t&&(delete this._animatingSettings[e],t.stop())}set(e,t){return this._set(e,t),this._stopAnimation(e),t}remove(e){e in this._settings&&(this._prevSettings[e]=this._settings[e],delete this._settings[e],this._sendKeyEvent(e,void 0),this._markDirtyKey(e)),this._stopAnimation(e)}removeAll(){K(Bi(this._settings),e=>{this.remove(e)})}getPrivate(e,t){let i=this._privateSettings[e];return i!==void 0?i:t}_setPrivateRaw(e,t,i){this._prevPrivateSettings[e]=t,this._sendPrivateKeyEvent(e,i)}setPrivateRaw(e,t){let i=this._privateSettings[e];this._privateSettings[e]=t,i!==t&&this._setPrivateRaw(e,i,t)}_setPrivate(e,t){let i=this._privateSettings[e];this._privateSettings[e]=t,i!==t&&(this._setPrivateRaw(e,i,t),this._markDirtyPrivateKey(e))}_stopAnimationPrivate(e){let t=this._animatingPrivateSettings[e];t&&(t.stop(),delete this._animatingPrivateSettings[e])}setPrivate(e,t){return this._setPrivate(e,t),this._stopAnimationPrivate(e),t}removePrivate(e){e in this._privateSettings&&(this._prevPrivateSettings[e]=this._privateSettings[e],delete this._privateSettings[e],this._markDirtyPrivateKey(e)),this._stopAnimationPrivate(e)}setAll(e){Ve(e,(t,i)=>{this.set(t,i)})}animate(e){let t=e.key,i=e.to,s=e.duration||0,r=e.loops||1,n=e.from===void 0?this.get(t):e.from,A=e.easing===void 0?Ff:e.easing;if(s===0)this.set(t,i);else if(n===void 0||n===i)this.set(t,i);else{this.set(t,n);let l=this._animatingSettings[t]=new TA(this,n,i,s,A,r,this._animationTime());return this._startAnimation(),l}let o=new TA(this,n,i,s,A,r,null);return o.stop(),o}animatePrivate(e){let t=e.key,i=e.to,s=e.duration||0,r=e.loops||1,n=e.from===void 0?this.getPrivate(t):e.from,A=e.easing===void 0?Ff:e.easing;if(s===0)this.setPrivate(t,i);else if(n===void 0||n===i)this.setPrivate(t,i);else{this.setPrivate(t,n);let l=this._animatingPrivateSettings[t]=new TA(this,n,i,s,A,r,this._animationTime());return this._startAnimation(),l}let o=new TA(this,n,i,s,A,r,null);return o.stop(),o}_dispose(){}isDisposed(){return this._disposed}dispose(){this.enableDispose&&!this._disposed&&(this._disposed=!0,this._dispose())}},nt=class extends $o{constructor(e,t,i,s=[]){if(super(t),this.states=new zh(this),this.adapters=new Lf(this),this.events=this._createEvents(),this._userPrivateProperties={},this._dirty={},this._dirtyPrivate={},this._templates=[],this._defaultThemes=[],this._templateDisposers=[],this._disposers=[],this._runSetup=!0,this._disposerProperties={},!i)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this._root=e,this._internalTemplates=s,t.id&&this._registerId(t.id)}static new(e,t,i){let s=new this(e,t,!0);return s._template=i,s._afterNew(),s}static _new(e,t,i=[]){let s=new this(e,t,!0,i);return s._afterNew(),s}_afterNew(){this._checkDirty();let e=!1,t=this._template;t&&(e=!0,t._setObjectTemplate(this)),K(this._internalTemplates,i=>{e=!0,i._setObjectTemplate(this)}),e&&this._applyTemplates(!1),this.states.create("default",{}),this._setDefaults()}_afterNewApplyThemes(){this._checkDirty();let e=this._template;e&&e._setObjectTemplate(this),K(this._internalTemplates,t=>{t._setObjectTemplate(this)}),this.states.create("default",{}),this._setDefaults(),this._applyThemes()}_createEvents(){return new Ls}get classNames(){return this.constructor.classNames}get className(){return this.constructor.className}_setDefaults(){}_setDefaultFn(e,t){let i=this.get(e);if(i)return i;{let s=t();return this.set(e,s),s}}_setDefault(e,t){this.has(e)||super.set(e,t)}_setRawDefault(e,t){this.has(e)||super.setRaw(e,t)}_clearDirty(){Bi(this._dirty).forEach(e=>{this._dirty[e]=!1}),Bi(this._dirtyPrivate).forEach(e=>{this._dirtyPrivate[e]=!1})}isDirty(e){return!!this._dirty[e]}isPrivateDirty(e){return!!this._dirtyPrivate[e]}_markDirtyKey(e){this._dirty[e]=!0,super._markDirtyKey(e)}_markDirtyPrivateKey(e){this._dirtyPrivate[e]=!0,super._markDirtyKey(e)}isType(e){return this.classNames.indexOf(e)!==-1}_pushPropertyDisposer(e,t){let i=this._disposerProperties[e];return i===void 0&&(i=this._disposerProperties[e]=[]),i.push(t),t}_disposeProperty(e){let t=this._disposerProperties[e];t!==void 0&&(K(t,i=>{i.dispose()}),delete this._disposerProperties[e])}set template(e){let t=this._template;t!==e&&(this._template=e,t&&t._removeObjectTemplate(this),e&&e._setObjectTemplate(this),this._applyTemplates())}get template(){return this._template}markDirty(){this._root._addDirtyEntity(this)}_startAnimation(){this._root._addAnimation(this)}_animationTime(){return this._root.animationTime}_applyState(e){}_applyStateAnimated(e,t){}get(e,t){let i=this.adapters.fold(e,this._settings[e]);return i!==void 0?i:t}isUserSetting(e){return this._userProperties[e]||!1}set(e,t){return this._userProperties[e]=!0,super.set(e,t)}setRaw(e,t){this._userProperties[e]=!0,super.setRaw(e,t)}_setSoft(e,t){return this._userProperties[e]?t:super.set(e,t)}remove(e){delete this._userProperties[e],this._removeTemplateProperty(e)}setPrivate(e,t){return this._userPrivateProperties[e]=!0,super.setPrivate(e,t)}setPrivateRaw(e,t){this._userPrivateProperties[e]=!0,super.setPrivateRaw(e,t)}removePrivate(e){delete this._userPrivateProperties[e],this._removeTemplatePrivateProperty(e)}_setTemplateProperty(e,t,i){if(!this._userProperties[t]){let s=this._findTemplateByKey(t);e===s&&super.set(t,i)}}_setTemplatePrivateProperty(e,t,i){if(!this._userPrivateProperties[t]){let s=this._findTemplateByPrivateKey(t);e===s&&super.setPrivate(t,i)}}_removeTemplateProperty(e){if(!this._userProperties[e]){let t=this._findTemplateByKey(e);t?super.set(e,t._settings[e]):super.remove(e)}}_removeTemplatePrivateProperty(e){if(!this._userPrivateProperties[e]){let t=this._findTemplateByPrivateKey(e);t?super.setPrivate(e,t._privateSettings[e]):super.removePrivate(e)}}_walkParents(e){e(this._root._rootContainer),e(this)}_applyStateByKey(e){let t=this.states.create(e,{}),i={};this._eachTemplate(s=>{let r=s.states.lookup(e);r&&r._apply(t,i)}),Ve(t._settings,s=>{!i[s]&&!t._userSettings[s]&&t.remove(s)})}_applyTemplate(e,t){this._templateDisposers.push(e._apply(this,t)),Ve(e._settings,(i,s)=>{!t.settings[i]&&!this._userProperties[i]&&(t.settings[i]=!0,super.set(i,s))}),Ve(e._privateSettings,(i,s)=>{!t.privateSettings[i]&&!this._userPrivateProperties[i]&&(t.privateSettings[i]=!0,super.setPrivate(i,s))}),this._runSetup&&e.setup&&(this._runSetup=!1,e.setup(this))}_findStaticTemplate(e){if(this._template&&e(this._template))return this._template}_eachTemplate(e){this._findStaticTemplate(t=>(e(t),!1)),Oa(this._internalTemplates,e),K(this._templates,e)}_applyTemplates(e=!0){e&&this._disposeTemplates();let t={settings:{},privateSettings:{},states:{}};this._eachTemplate(i=>{this._applyTemplate(i,t)}),e&&(Ve(this._settings,i=>{!this._userProperties[i]&&!t.settings[i]&&super.remove(i)}),Ve(this._privateSettings,i=>{!this._userPrivateProperties[i]&&!t.privateSettings[i]&&super.removePrivate(i)}))}_findTemplate(e){let t=this._findStaticTemplate(e);if(t===void 0){let i=Ex(this._internalTemplates,e);return i===void 0?Ph(this._templates,e):i}else return t}_findTemplateByKey(e){return this._findTemplate(t=>e in t._settings)}_findTemplateByPrivateKey(e){return this._findTemplate(t=>e in t._privateSettings)}_disposeTemplates(){K(this._templateDisposers,e=>{e.dispose()}),this._templateDisposers.length=0}_removeTemplates(){K(this._templates,e=>{e._removeObjectTemplate(this)}),this._templates.length=0}_applyThemes(e=!1){if(this.get("ignoreThemes"))return!1;let t=!1,i=[],s=[],r=new Set,n=this.get("themeTagsSelf");return n&&K(n,A=>{r.add(A)}),this._walkParents(A=>{A===this._root._rootContainer&&(t=!0),A._defaultThemes.length>0&&i.push(A._defaultThemes);let o=A.get("themes");o&&s.push(o);let l=A.get("themeTags");l&&K(l,c=>{r.add(c)})}),s=i.concat(s),this._removeTemplates(),(t||e)&&Oa(this.classNames,A=>{let o=[];K(s,l=>{K(l,c=>{let h=c._lookupRules(A);h&&Oa(h,d=>{if(d.tags.every(g=>r.has(g))){let g=Mh(o,y=>{let m=Bs(d.tags.length,y.tags.length);return m===0?Yh(d.tags,y.tags,Bs):m});o.splice(g.index,0,d)}})})}),K(o,l=>{this._templates.push(l.template),l.template._setObjectTemplate(this)})}),this._applyTemplates(),(t||e)&&(this._runSetup=!1),t||e}_changed(){}_beforeChanged(){if(this.isDirty("id")){let e=this.get("id");e&&this._registerId(e);let t=this._prevSettings.id;t&&(delete this._root.entitiesById[t],delete ls.entitiesById[t])}}_registerId(e){if(this._root.entitiesById[e]&&this._root.entitiesById[e]!==this)throw new Error('An entity with id "'+e+'" already exists.');this._root.entitiesById[e]=this,ls.entitiesById[e]=this}_afterChanged(){}addDisposer(e){return this._disposers.push(e),e}_dispose(){super._dispose();let e=this._template;e&&e._removeObjectTemplate(this),K(this._internalTemplates,i=>{i._removeObjectTemplate(this)}),this._removeTemplates(),this._disposeTemplates(),this.events.dispose(),this._disposers.forEach(i=>{i.dispose()}),Ve(this._disposerProperties,(i,s)=>{K(s,r=>{r.dispose()})});let t=this.get("id");t&&(delete this._root.entitiesById[t],delete ls.entitiesById[t])}setTimeout(e,t){let i=setTimeout(()=>{this.removeDispose(s),e()},t),s=new Qt(()=>{clearTimeout(i)});return this._disposers.push(s),s}removeDispose(e){if(!this.isDisposed()){let t=Qr(this._disposers,e);t>-1&&this._disposers.splice(t,1)}e.dispose()}hasTag(e){return Qr(this.get("themeTags",[]),e)!==-1}addTag(e){if(!this.hasTag(e)){let t=this.get("themeTags",[]);t.push(e),this.set("themeTags",t)}}removeTag(e){if(this.hasTag(e)){let t=this.get("themeTags",[]);ri(t,e),this.set("themeTags",t)}}_t(e,t,...i){return this._root.language.translate(e,t,...i)}get root(){return this._root}};nt.className="Entity";nt.classNames=["Entity"];function Uf(a){Ve(a,(e,t)=>{Gs(t)&&typeof t.dispose=="function"&&(t.enableDispose=!0,t.dispose())})}var Qf=class{constructor(e,t,i){this._name=e,this._template=t,this._settings=i}_dispose(){Uf(this._settings)}get(e,t){let i=this._settings[e];return i!==void 0?i:t}set(e,t){this._settings[e]=t,this._template._stateChanged(this._name)}remove(e){delete this._settings[e],this._template._stateChanged(this._name)}setAll(e){Bi(e).forEach(t=>{this._settings[t]=e[t]}),this._template._stateChanged(this._name)}_apply(e,t){Ve(this._settings,(i,s)=>{!t[i]&&!e._userSettings[i]&&(t[i]=!0,e.setRaw(i,s))})}},kf=class{constructor(e){this._states={},this._template=e}_dispose(){Ve(this._states,(e,t)=>{t._dispose()})}lookup(e){return this._states[e]}create(e,t){let i=this._states[e];if(i)return i.setAll(t),i;{let s=new Qf(e,this._template,t);return this._states[e]=s,this._template._stateChanged(e),s}}remove(e){delete this._states[e],this._template._stateChanged(e)}_apply(e,t){Ve(this._states,(i,s)=>{let r=t.states[i];r==null&&(r=t.states[i]={});let n=e.states.create(i,{});s._apply(n,r)})}},Ef=class{constructor(){this._callbacks={}}add(e,t){let i=this._callbacks[e];return i===void 0&&(i=this._callbacks[e]=[]),i.push(t),new Qt(()=>{Jt(i,t),i.length===0&&delete this._callbacks[e]})}remove(e){this._callbacks[e]!==void 0&&delete this._callbacks[e]}_apply(e){let t=[];return Ve(this._callbacks,(i,s)=>{K(s,r=>{t.push(e.adapters.add(i,r))})}),new zt(t)}},Ne=class a{constructor(e,t){if(this._disposed=!1,this._privateSettings={},this._settingEvents={},this._privateSettingEvents={},this._entities=[],this.states=new kf(this),this.adapters=new Ef,this.events=new Ls,!t)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this._settings=e}static new(e){return new a(e,!0)}_dispose(){Uf(this._settings),Uf(this._privateSettings)}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._dispose())}_checkDisposed(){if(this._disposed)throw new Error("Template is disposed")}get entities(){return this._entities}get(e,t){this._checkDisposed();let i=this._settings[e];return i!==void 0?i:t}setRaw(e,t){this._checkDisposed(),this._settings[e]=t}set(e,t){this._checkDisposed(),this._settings[e]!==t&&(this.setRaw(e,t),this._entities.forEach(i=>{i._setTemplateProperty(this,e,t)}))}remove(e){this._checkDisposed(),e in this._settings&&(delete this._settings[e],this._entities.forEach(t=>{t._removeTemplateProperty(e)}))}removeAll(){this._checkDisposed(),Ve(this._settings,(e,t)=>{this.remove(e)})}getPrivate(e,t){this._checkDisposed();let i=this._privateSettings[e];return i!==void 0?i:t}setPrivateRaw(e,t){return this._checkDisposed(),this._privateSettings[e]=t,t}setPrivate(e,t){return this._checkDisposed(),this._privateSettings[e]!==t&&(this.setPrivateRaw(e,t),this._entities.forEach(i=>{i._setTemplatePrivateProperty(this,e,t)})),t}removePrivate(e){this._checkDisposed(),e in this._privateSettings&&(delete this._privateSettings[e],this._entities.forEach(t=>{t._removeTemplatePrivateProperty(e)}))}setAll(e){this._checkDisposed(),Ve(e,(t,i)=>{this.set(t,i)})}on(e,t){this._checkDisposed();let i=this._settingEvents[e];return i===void 0&&(i=this._settingEvents[e]=[]),i.push(t),new Qt(()=>{Jt(i,t),i.length===0&&delete this._settingEvents[e]})}onPrivate(e,t){this._checkDisposed();let i=this._privateSettingEvents[e];return i===void 0&&(i=this._privateSettingEvents[e]=[]),i.push(t),new Qt(()=>{Jt(i,t),i.length===0&&delete this._privateSettingEvents[e]})}_apply(e,t){this._checkDisposed();let i=[];return Ve(this._settingEvents,(s,r)=>{K(r,n=>{i.push(e.on(s,n))})}),Ve(this._privateSettingEvents,(s,r)=>{K(r,n=>{i.push(e.onPrivate(s,n))})}),this.states._apply(e,t),i.push(this.adapters._apply(e)),i.push(e.events.copyFrom(this.events)),new zt(i)}_setObjectTemplate(e){this._checkDisposed(),this._entities.push(e)}_removeObjectTemplate(e){ri(this._entities,e)}_stateChanged(e){this._checkDisposed(),this._entities.forEach(t=>{t._applyStateByKey(e)})}};var jh=class a extends Ls{constructor(e){super(),this._rendererDisposers={},this._dispatchParents=!0,this._sprite=e}_makePointerEvent(e,t){return{type:e,originalEvent:t.event,point:t.point,simulated:t.simulated,native:t.native,target:this._sprite}}_onRenderer(e,t){this._sprite.set("interactive",!0),this._sprite._display.interactive=!0;let i=this._rendererDisposers[e];if(i===void 0){let s=this._sprite._display.on(e,r=>{t.call(this,r)});i=this._rendererDisposers[e]=new _A(()=>{delete this._rendererDisposers[e],s.dispose()})}return i.increment()}_on(e,t,i,s,r,n,A){let o=super._on(e,t,i,s,r,n,A),l=a.RENDERER_EVENTS[t];return l!==void 0&&(o.disposer=new zt([o.disposer,this._onRenderer(t,l)])),o}stopParentDispatch(){this._dispatchParents=!1}dispatchParents(e,t){let i=this._dispatchParents;this._dispatchParents=!0;try{this.dispatch(e,t),this._dispatchParents&&this._sprite.parent&&this._sprite.parent.events.dispatchParents(e,t)}finally{this._dispatchParents=i}}};jh.RENDERER_EVENTS={click:function(a){this.isEnabled("click")&&!this._sprite.isDragging()&&this._sprite._hasDown()&&!this._sprite._hasMoved(this._makePointerEvent("click",a))&&this.dispatch("click",this._makePointerEvent("click",a))},rightclick:function(a){this.isEnabled("rightclick")&&this.dispatch("rightclick",this._makePointerEvent("rightclick",a))},middleclick:function(a){this.isEnabled("middleclick")&&this.dispatch("middleclick",this._makePointerEvent("middleclick",a))},dblclick:function(a){this.dispatchParents("dblclick",this._makePointerEvent("dblclick",a))},pointerover:function(a){let e=this._sprite,t=!0;if(e.getPrivate("trustBounds")){e._getBounds();let i=e.globalBounds();if(e.isType("Graphics")){let s=e.get("strokeWidth",1)/2;s>=1&&(i.left-=s,i.right+=s,i.top-=s,i.bottom+=s)}sb(a.point,i)||(t=!1,e._root._renderer.removeHovering(e._display))}t&&this.isEnabled("pointerover")&&this.dispatch("pointerover",this._makePointerEvent("pointerover",a))},pointerout:function(a){this.isEnabled("pointerout")&&this.dispatch("pointerout",this._makePointerEvent("pointerout",a))},pointerdown:function(a){this.dispatchParents("pointerdown",this._makePointerEvent("pointerdown",a))},pointerup:function(a){this.isEnabled("pointerup")&&this.dispatch("pointerup",this._makePointerEvent("pointerup",a))},globalpointerup:function(a){this.isEnabled("globalpointerup")&&this.dispatch("globalpointerup",this._makePointerEvent("globalpointerup",a))},globalpointermove:function(a){this.isEnabled("globalpointermove")&&this.dispatch("globalpointermove",this._makePointerEvent("globalpointermove",a))},wheel:function(a){this.dispatchParents("wheel",{type:"wheel",target:this._sprite,originalEvent:a.event,point:a.point})}};var hi=class extends nt{constructor(){super(...arguments),this._adjustedLocalBounds={left:0,right:0,top:0,bottom:0},this._localBounds={left:0,right:0,top:0,bottom:0},this._sizeDirty=!1,this._isDragging=!1,this._isHidden=!1,this._isShowing=!1,this._isHiding=!1,this._isDown=!1,this._downPoints={}}_afterNew(){this.setPrivateRaw("visible",!0),super._afterNew()}markDirtyKey(e){this._markDirtyKey(e)}_markDirtyKey(e){super._markDirtyKey(e),(e=="x"||e=="y"||e=="dx"||e=="dy")&&(this.markDirtyBounds(),this._addPercentagePositionChildren(),this.markDirtyPosition())}_markDirtyPrivateKey(e){super._markDirtyPrivateKey(e),(e=="x"||e=="y")&&this.markDirtyPosition()}_removeTemplateField(){this._templateField&&this._templateField._removeObjectTemplate(this)}_createEvents(){return new jh(this)}_processTemplateField(){let e,t=this.get("templateField");if(t){let i=this.dataItem;if(i){let s=i.dataContext;s&&(e=s[t],!(e instanceof Ne)&&e&&(e=Ne.new(e)))}}this._templateField!==e&&(this._removeTemplateField(),this._templateField=e,e&&e._setObjectTemplate(this),this._applyTemplates())}_setDataItem(e){let t=this._dataItem;this._dataItem=e,this._processTemplateField();let i="dataitemchanged";e!=t&&this.events.isEnabled(i)&&this.events.dispatch(i,{type:i,target:this,oldDataItem:t,newDataItem:e})}set dataItem(e){this._setDataItem(e)}get dataItem(){if(this._dataItem)return this._dataItem;{let e=this._parent;for(;e;){if(e._dataItem)return e._dataItem;e=e._parent}}}_addPercentageSizeChildren(){let e=this.parent;e&&(this.get("width")instanceof ke||this.get("height")instanceof ke?Na(e._percentageSizeChildren,this):Jt(e._percentageSizeChildren,this))}_addPercentagePositionChildren(){let e=this.parent;e&&(this.get("x")instanceof ke||this.get("y")instanceof ke?Na(e._percentagePositionChildren,this):Jt(e._percentagePositionChildren,this))}markDirtyPosition(){this._root._addDirtyPosition(this)}updatePivotPoint(){let e=this._localBounds;if(e){let t=this.get("centerX");t!=null&&(this._display.pivot.x=e.left+We(t,e.right-e.left));let i=this.get("centerY");i!=null&&(this._display.pivot.y=e.top+We(i,e.bottom-e.top))}}_beforeChanged(){if(super._beforeChanged(),this._handleStates(),this.isDirty("tooltip")){let e=this._prevSettings.tooltip;e&&e.dispose()}if((this.isDirty("layer")||this.isDirty("layerMargin"))&&(this._display.setLayer(this.get("layer"),this.get("layerMargin")),this.markDirtyLayer()),this.isDirty("tooltipPosition")){let e=this._tooltipMoveDp;e&&(e.dispose(),this._tooltipMoveDp=void 0);let t=this._tooltipPointerDp;t&&(t.dispose(),this._tooltipPointerDp=void 0),this.get("tooltipPosition")=="pointer"&&(this.isHover()&&(this._tooltipMoveDp=this.events.on("globalpointermove",i=>{this.showTooltip(i.point)})),this._tooltipPointerDp=new zt([this.events.on("pointerover",()=>{this._tooltipMoveDp=this.events.on("globalpointermove",i=>{this.showTooltip(i.point)})}),this.events.on("pointerout",()=>{let i=this._tooltipMoveDp;i&&(i.dispose(),this._tooltipMoveDp=void 0)})]))}}_handleStates(){this.isDirty("active")&&(this.get("active")?(this.states.applyAnimate("active"),this.set("ariaChecked",!0)):(this.isHidden()||this.states.applyAnimate("default"),this.set("ariaChecked",!1)),this.markDirtyAccessibility()),this.isDirty("disabled")&&(this.get("disabled")?(this.states.applyAnimate("disabled"),this.set("ariaChecked",!1)):(this.isHidden()||this.states.applyAnimate("default"),this.set("ariaChecked",!0)),this.markDirtyAccessibility())}_changed(){super._changed();let e=this._display,t=this.events;if(this.isDirty("draggable")){let s=this.get("draggable");s?(this.set("interactive",!0),this._dragDp=new zt([t.on("pointerdown",r=>{this.dragStart(r)}),t.on("globalpointermove",r=>{this.dragMove(r)}),t.on("globalpointerup",r=>{this.dragStop(r)})])):this._dragDp&&(this._dragDp.dispose(),this._dragDp=void 0),e.cancelTouch=!!s}if(this.isDirty("tooltipText")||this.isDirty("tooltipHTML")||this.isDirty("showTooltipOn")){let s=this.get("tooltipText"),r=this.get("tooltipHTML"),n=this.get("showTooltipOn","hover");this._tooltipDp&&(this._tooltipDp.dispose(),this._tooltipDp=void 0),(s||r)&&(n=="click"?(this._tooltipDp=new zt([t.on("click",()=>{this.setTimeout(()=>{let A=this.getTooltip();A&&!A.isHidden()&&A.get("tooltipTarget")===this?this.hideTooltip():this.showTooltip()},10)}),kt(document,"click",A=>{this.hideTooltip()})]),this._disposers.push(this._tooltipDp)):n=="always"||(this._tooltipDp=new zt([t.on("pointerover",()=>{this.showTooltip()}),t.on("pointerout",()=>{this.hideTooltip()})]),this._disposers.push(this._tooltipDp)))}if(this.isDirty("toggleKey")){let s=this.get("toggleKey");s&&s!="none"?this._toggleDp=t.on("click",()=>{this._isDragging||this.set(s,!this.get(s))}):this._toggleDp&&(this._toggleDp.dispose(),this._toggleDp=void 0)}if(this.isDirty("opacity")&&(e.alpha=Math.max(0,this.get("opacity",1)),this.get("focusable")&&this.markDirtyAccessibility()),this.isDirty("rotation")&&(this.markDirtyBounds(),e.angle=this.get("rotation",0)),this.isDirty("scale")&&(this.markDirtyBounds(),e.scale=this.get("scale",0)),(this.isDirty("centerX")||this.isDirty("centerY"))&&(this.markDirtyBounds(),this.updatePivotPoint()),(this.isDirty("visible")||this.isPrivateDirty("visible")||this.isDirty("forceHidden"))&&(!this.get("visible")||!this.getPrivate("visible")||this.get("forceHidden")?(e.visible=!1,this.hideTooltip()):e.visible=!0,this.markDirtyBounds(),this.get("focusable")&&this.markDirtyAccessibility()),this.isDirty("width")||this.isDirty("height")){this.markDirtyBounds(),this._addPercentageSizeChildren();let s=this.parent;s&&(this.isDirty("width")&&this.get("width")instanceof ke||this.isDirty("height")&&this.get("height")instanceof ke)&&(s.markDirty(),s._prevWidth=0),this._sizeDirty=!0}if((this.isDirty("maxWidth")||this.isDirty("maxHeight")||this.isPrivateDirty("width")||this.isPrivateDirty("height")||this.isDirty("minWidth")||this.isDirty("minHeight")||this.isPrivateDirty("maxWidth")||this.isPrivateDirty("maxHeight")||this.isPrivateDirty("minWidth")||this.isPrivateDirty("minHeight")||this.isDirty("marginLeft")||this.isDirty("marginTop")||this.isDirty("marginRight")||this.isDirty("marginBottom"))&&(this.markDirtyBounds(),this._sizeDirty=!0),this._sizeDirty&&this._updateSize(),this.isDirty("wheelable")){let s=this.get("wheelable");s&&this.set("interactive",!0),e.wheelable=!!s}(this.isDirty("tabindexOrder")||this.isDirty("focusableGroup"))&&(this.get("focusable")?this._root._registerTabindexOrder(this):this._root._unregisterTabindexOrder(this)),this.isDirty("filter")&&(e.filter=this.get("filter"));let i=this.get("filter","");if(this.isDirty("blur")){let s=this.get("blur",0);s!=0&&(i+=" blur("+s+"px)")}if(this.isDirty("saturate")){let s=this.get("saturate",1);s!=1&&(i+=" saturate("+s+")")}if(this.isDirty("brightness")){let s=this.get("brightness",1);s!=1&&(i+=" brightness("+s+")")}if(this.isDirty("contrast")){let s=this.get("contrast",1);s!=1&&(i+=" contrast("+s+")")}if(this.isDirty("sepia")){let s=this.get("sepia",0);s!=0&&(i+=" sepia("+s+")")}if(this.isDirty("hue")){let s=this.get("hue",0);s!=0&&(i+=" hue-rotate("+s+"deg)")}if(this.isDirty("invert")){let s=this.get("invert",0);s!=0&&(i+=" invert("+s+")")}if(i&&(e.filter=i),this.isDirty("cursorOverStyle")&&(e.cursorOverStyle=this.get("cursorOverStyle")),this.isDirty("hoverOnFocus")&&(this.get("hoverOnFocus")?this._focusDp=new zt([t.on("focus",()=>{this.showTooltip()}),t.on("blur",()=>{this.hideTooltip()})]):this._focusDp&&(this._focusDp.dispose(),this._focusDp=void 0)),this.isDirty("focusable")&&(this.get("focusable")?this._root._registerTabindexOrder(this):this._root._unregisterTabindexOrder(this),this.markDirtyAccessibility(),this._disposers.push(t.on("blur",()=>{this.setPrivateRaw("touchHovering",!1)})),this._disposers.push(t.once("boundschanged",()=>{this.markDirtyAccessibility()}))),this.isPrivateDirty("focusable")&&this.markDirtyAccessibility(),(this.isDirty("role")||this.isDirty("ariaLive")||this.isDirty("ariaChecked")||this.isDirty("ariaHidden")||this.isDirty("ariaOrientation")||this.isDirty("ariaValueNow")||this.isDirty("ariaValueMin")||this.isDirty("ariaValueMax")||this.isDirty("ariaValueText")||this.isDirty("ariaLabel")||this.isDirty("ariaControls"))&&this.markDirtyAccessibility(),this.isDirty("exportable")&&(e.exportable=this.get("exportable")),this.isDirty("interactive")){let s=this.events;this.get("interactive")&&!s.isDisposed()?this._hoverDp=new zt([s.on("click",r=>{Mo(r.originalEvent)&&(this.getPrivate("touchHovering")||this.setTimeout(()=>{this._handleOver(),(this.get("tooltipText")||this.get("tooltipHTML"))&&this.showTooltip(),this.setPrivateRaw("touchHovering",!0),this.events.dispatch("pointerover",{type:"pointerover",target:r.target,originalEvent:r.originalEvent,point:r.point,simulated:r.simulated})},10))}),s.on("globalpointerup",r=>{Mo(r.originalEvent)&&this.getPrivate("touchHovering")&&(this._handleOut(),(this.get("tooltipText")||this.get("tooltipHTML"))&&this.hideTooltip(),this.setPrivateRaw("touchHovering",!1),this.events.dispatch("pointerout",{type:"pointerout",target:r.target,originalEvent:r.originalEvent,point:r.point,simulated:r.simulated})),this._isDown&&this._handleUp(r)}),s.on("pointerover",()=>{this._handleOver()}),s.on("pointerout",()=>{this._handleOut()}),s.on("pointerdown",r=>{this._handleDown(r)})]):(this._display.interactive=!1,this._hoverDp&&(this._hoverDp.dispose(),this._hoverDp=void 0))}this.isDirty("forceInactive")&&(this._display.inactive=this.get("forceInactive",null)),this.get("showTooltipOn")=="always"&&this._display.visible&&this.showTooltip()}dragStart(e){this._dragEvent=e,this.events.stopParentDispatch()}dragStop(e){if(this._dragEvent=void 0,this._dragPoint=void 0,this.events.stopParentDispatch(),this._isDragging){this._isDragging=!1;let t="dragstop";this.events.isEnabled(t)&&this.events.dispatch(t,{type:t,target:this,originalEvent:e.originalEvent,point:e.point,simulated:e.simulated})}}_handleOver(){this.isHidden()||(this.get("active")&&this.states.lookup("hoverActive")?this.states.applyAnimate("hoverActive"):this.get("disabled")&&this.states.lookup("hoverDisabled")?this.states.applyAnimate("hoverDisabled"):this.states.applyAnimate("hover"),this.get("draggable")&&this._isDown&&this.states.lookup("down")&&this.states.applyAnimate("down"))}_handleOut(){this.isHidden()||(this.get("active")&&this.states.lookup("active")?this.states.applyAnimate("active"):this.get("disabled")&&this.states.lookup("disabled")?this.states.applyAnimate("disabled"):(this.states.lookup("hover")||this.states.lookup("hoverActive"))&&this.states.applyAnimate("default"),this.get("draggable")&&this._isDown&&this.states.lookup("down")&&this.states.applyAnimate("down"))}_handleUp(e){if(!this.isHidden()){this.get("active")&&this.states.lookup("active")?this.states.applyAnimate("active"):this.get("disabled")&&this.states.lookup("disabled")?this.states.applyAnimate("disabled"):this.states.lookup("down")&&(this.isHover()?this.states.applyAnimate("hover"):this.states.applyAnimate("default")),this._downPoint=void 0;let t=Nh(e.originalEvent);delete this._downPoints[t],Bi(this._downPoints).length==0&&(this._isDown=!1)}}_hasMoved(e){let t=Nh(e.originalEvent),i=this._downPoints[t];if(i){let s=Math.abs(i.x-e.point.x),r=Math.abs(i.y-e.point.y);return s>5||r>5}return!1}_hasDown(){return Bi(this._downPoints).length>0}_handleDown(e){let t=this.parent;if(t&&!this.get("draggable")&&t._handleDown(e),this.get("interactive")&&!this.isHidden()){this.states.lookup("down")&&this.states.applyAnimate("down"),this._downPoint={x:e.point.x,y:e.point.y},this._isDown=!0;let i=Nh(e.originalEvent);this._downPoints[i]={x:e.point.x,y:e.point.y}}}dragMove(e){let t=this._dragEvent;if(t){if(t.simulated&&!e.simulated)return!0;let i=0,s=this.parent,r=1;for(;s!=null;)i+=s.get("rotation",0),s=s.parent,s&&(r*=s.get("scale",1));let n=(e.point.x-t.point.x)/r,A=(e.point.y-t.point.y)/r,o=this.events;if(t.simulated&&!this._isDragging){this._isDragging=!0,this._dragEvent=e,this._dragPoint={x:this.x(),y:this.y()};let l="dragstart";o.isEnabled(l)&&o.dispatch(l,{type:l,target:this,originalEvent:e.originalEvent,point:e.point,simulated:e.simulated})}if(this._isDragging){let l=this._dragPoint;this.set("x",l.x+n*ft(i)+A*At(i)),this.set("y",l.y+A*ft(i)-n*At(i));let c="dragged";o.isEnabled(c)&&o.dispatch(c,{type:c,target:this,originalEvent:e.originalEvent,point:e.point,simulated:e.simulated})}else if(Math.hypot(n,A)>5){this._isDragging=!0,this._dragEvent=e,this._dragPoint={x:this.x(),y:this.y()};let l="dragstart";o.isEnabled(l)&&o.dispatch(l,{type:l,target:this,originalEvent:e.originalEvent,point:e.point,simulated:e.simulated})}}}_updateSize(){}_getBounds(){this._localBounds=this._display.getLocalBounds()}depth(){let e=this.parent,t=0;for(;;)if(e)++t,e=e.parent;else return t}markDirtySize(){this._sizeDirty=!0,this.markDirty()}markDirtyBounds(){let e=this._display;if(this.get("isMeasured")){this._root._addDirtyBounds(this),e.isMeasured=!0,e.invalidateBounds();let t=this.parent;t&&this.get("position")!="absolute"&&(t.get("width")==null||t.get("height")==null||t.get("layout"))&&t.markDirtyBounds(),this.get("focusable")&&this.markDirtyAccessibility()}}markDirtyAccessibility(){this._root._invalidateAccessibility(this)}markDirtyLayer(){this._display.markDirtyLayer(!0)}markDirty(){super.markDirty(),this.markDirtyLayer()}_updateBounds(){let e=this._adjustedLocalBounds,t;if(!this.get("visible")||!this.getPrivate("visible")||this.get("forceHidden")?(t={left:0,right:0,top:0,bottom:0},this._localBounds=t,this._adjustedLocalBounds=t):(this._getBounds(),this._fixMinBounds(this._localBounds),this.updatePivotPoint(),this._adjustedLocalBounds=this._display.getAdjustedBounds(this._localBounds),t=this._adjustedLocalBounds),!e||e.left!==t.left||e.top!==t.top||e.right!==t.right||e.bottom!==t.bottom){let i="boundschanged";this.events.isEnabled(i)&&this.events.dispatch(i,{type:i,target:this}),this.parent&&(this.parent.markDirty(),this.parent.markDirtyBounds()),this.getPrivate("showingTooltip")&&this.showTooltip()}}_fixMinBounds(e){let t=this.get("minWidth",this.getPrivate("minWidth")),i=this.get("minHeight",this.getPrivate("minHeight"));W(t)&&e.right-e.left<t&&(e.right=e.left+t),W(i)&&e.bottom-e.top<i&&(e.bottom=e.top+i);let s=this.getPrivate("width"),r=this.getPrivate("height");W(s)&&(s>0?e.right=e.left+s:e.left=e.right+s),W(r)&&(r>0?e.bottom=e.top+r:e.top=e.bottom+r)}_removeParent(e){e&&(e.children.removeValue(this),Jt(e._percentageSizeChildren,this),Jt(e._percentagePositionChildren,this))}_clearDirty(){super._clearDirty(),this._sizeDirty=!1}hover(){this.isDisposed()||(this.showTooltip(),this._handleOver())}unhover(){this.isDisposed()||(this.hideTooltip(),this._handleOut())}showTooltip(e){if(!this.isDisposed()){let t=this.getTooltip(),i=this.get("tooltipText"),s=this.get("tooltipHTML");if((i||s)&&t){let r=this.get("tooltipPosition"),n=this.getPrivate("tooltipTarget",this);if((r=="fixed"||!e)&&(this._display._setMatrix(),e=this.toGlobal(n._getTooltipPoint())),r=="pointer"){let l=this.getPrivate("lastTooltipCoords");if(l&&l.x==e.x&&l.y==e.y)return;this.setPrivate("lastTooltipCoords",e)}t.set("pointTo",e),t.set("tooltipTarget",n),t.get("x")||t.set("x",e.x),t.get("y")||t.set("y",e.y),i&&t.label.set("text",i),s&&t.label.set("html",s);let A=this.dataItem;if(A&&t.label._setDataItem(A),this.get("showTooltipOn")=="always"&&(e.x<0||e.x>this._root.width()||e.y<0||e.y>this._root.height())){this.hideTooltip();return}t.label.text.markDirtyText();let o=t.show();return this.setPrivateRaw("showingTooltip",!0),o}}}hideTooltip(){let e=this.getTooltip();if(e&&(this.removePrivate("lastTooltipCoords"),e.get("tooltipTarget")==this.getPrivate("tooltipTarget",this)||this.get("tooltip")==e)){let t=e.get("keepTargetHover")&&e.get("stateAnimationDuration",0)==0?400:void 0,i=e.hide(t);return this.setPrivateRaw("showingTooltip",!1),i}}_getTooltipPoint(){let e=this._localBounds;if(e){let t=0,i=0;return this.get("isMeasured")?(t=e.left+We(this.get("tooltipX",0),e.right-e.left),i=e.top+We(this.get("tooltipY",0),e.bottom-e.top)):(t=We(this.get("tooltipX",0),this.width()),i=We(this.get("tooltipY",0),this.height())),{x:t,y:i}}return{x:0,y:0}}getTooltip(){let e=this.get("tooltip");if(e)return e;{let t=this.parent;if(t)return t.getTooltip()}}_updatePosition(){let e=this.parent,t=this.get("dx",0),i=this.get("dy",0),s=this.get("x"),r=this.getPrivate("x"),n=0,A=0,o=this.get("position");s instanceof ke&&(e?s=e.innerWidth()*s.value+e.get("paddingLeft",0):s=0),W(s)?n=s+t:r!=null?n=r:e&&o=="relative"&&(n=e.get("paddingLeft",0)+t);let l=this.get("y"),c=this.getPrivate("y");l instanceof ke&&(e?l=e.innerHeight()*l.value+e.get("paddingTop",0):l=0),W(l)?A=l+i:c!=null?A=c:e&&o=="relative"&&(A=e.get("paddingTop",0)+i);let h=this._display;if(h.x!=n||h.y!=A){h.invalidateBounds(),h.x=n,h.y=A;let d="positionchanged";this.events.isEnabled(d)&&this.events.dispatch(d,{type:d,target:this})}this.getPrivate("showingTooltip")&&this.showTooltip()}x(){let e=this.get("x"),t=this.getPrivate("x"),i=this.parent;return i?e instanceof ke?We(e,i.innerWidth())+i.get("paddingLeft",0):W(e)?e:t??i.get("paddingLeft",this._display.x):this._display.x}y(){let e=this.getPrivate("y");if(e!=null)return e;let t=this.get("y"),i=this.parent;return i?t instanceof ke?We(t,i.innerHeight())+i.get("paddingTop",0):W(t)?t:e??i.get("paddingTop",this._display.y):this._display.y}_dispose(){super._dispose(),this._display.dispose(),this._removeTemplateField(),this._removeParent(this.parent),this._root._removeFocusElement(this);let e=this.get("tooltip");e&&e.dispose(),this.markDirty()}adjustedLocalBounds(){return this._fixMinBounds(this._adjustedLocalBounds),this._adjustedLocalBounds}localBounds(){return this._localBounds}bounds(){let e=this._adjustedLocalBounds,t=this.x(),i=this.y();return{left:e.left+t,right:e.right+t,top:e.top+i,bottom:e.bottom+i}}globalBounds(){let e=this.localBounds(),t=this.toGlobal({x:e.left,y:e.top}),i=this.toGlobal({x:e.right,y:e.top}),s=this.toGlobal({x:e.right,y:e.bottom}),r=this.toGlobal({x:e.left,y:e.bottom});return{left:Math.min(t.x,i.x,s.x,r.x),top:Math.min(t.y,i.y,s.y,r.y),right:Math.max(t.x,i.x,s.x,r.x),bottom:Math.max(t.y,i.y,s.y,r.y)}}_onShow(e){}_onHide(e){}appear(e,t){return Ke(this,void 0,void 0,function*(){return yield this.hide(0),t?new Promise((i,s)=>{this.setTimeout(()=>{i(this.show(e))},t)}):this.show(e)})}show(e){return Ke(this,void 0,void 0,function*(){if(!this._isShowing){this._isHidden=!1,this._isShowing=!0,this._isHiding=!1,this.states.lookup("default").get("visible")&&this.set("visible",!0),this._onShow(e);let t=this.states.applyAnimate("default",e);yield xf(t),this._isShowing=!1}})}hide(e){return Ke(this,void 0,void 0,function*(){if(!this._isHiding&&!this._isHidden){this._isHiding=!0,this._isShowing=!1;let t=this.states.lookup("hidden");t||(t=this.states.create("hidden",{opacity:0,visible:!1})),this._isHidden=!0,this._onHide(e);let i=this.states.applyAnimate("hidden",e);yield xf(i),this._isHiding=!1}})}isHidden(){return this._isHidden}isShowing(){return this._isShowing}isHiding(){return this._isHiding}isHover(){return this._display.hovering()}isFocus(){return this._root.focused(this)}isDragging(){return this._isDragging}isVisible(){return!!(this.get("visible")&&this.getPrivate("visible")&&!this.get("forceHidden"))}isVisibleDeep(){return this._parent?this._parent.isVisibleDeep()&&this.isVisible():this.isVisible()}compositeOpacity(){let e=this.get("opacity",1);return this._parent?this._parent.compositeOpacity()*e:e}compositeScale(){let e=this.get("scale",1);return this._parent?this._parent.compositeScale()*e:e}compositeRotation(){let e=this.get("rotation",0);return this._parent?this._parent.compositeRotation()+e:e}width(){let e=this.get("width"),t=this.get("maxWidth",this.getPrivate("maxWidth")),i=this.get("minWidth",this.getPrivate("minWidth")),s=this.getPrivate("width"),r=0;if(W(s))r=s;else if(e==null)this._adjustedLocalBounds&&(r=this._adjustedLocalBounds.right-this._adjustedLocalBounds.left);else if(e instanceof ke){let n=this.parent;n?r=n.innerWidth()*e.value:r=this._root.width()*e.value}else W(e)&&(r=e);return W(i)&&(r=Math.max(i,r)),W(t)&&(r=Math.min(t,r)),r}maxWidth(){let e=this.get("maxWidth",this.getPrivate("maxWidth"));if(W(e))return e;{let i=this.get("width");if(W(i))return i}let t=this.parent;return t?t.innerWidth():this._root.width()}maxHeight(){let e=this.get("maxHeight",this.getPrivate("maxHeight"));if(W(e))return e;{let i=this.get("height");if(W(i))return i}let t=this.parent;return t?t.innerHeight():this._root.height()}height(){let e=this.get("height"),t=this.get("maxHeight",this.getPrivate("maxHeight")),i=this.get("minHeight",this.getPrivate("minHeight")),s=this.getPrivate("height"),r=0;if(W(s))r=s;else if(e==null)this._adjustedLocalBounds&&(r=this._adjustedLocalBounds.bottom-this._adjustedLocalBounds.top);else if(e instanceof ke){let n=this.parent;n?r=n.innerHeight()*e.value:r=this._root.height()*e.value}else W(e)&&(r=e);return W(i)&&(r=Math.max(i,r)),W(t)&&(r=Math.min(t,r)),r}_findStaticTemplate(e){return this._templateField&&e(this._templateField)?this._templateField:super._findStaticTemplate(e)}_walkParents(e){(this._parent||this._virtualParent)&&this._walkParent(e)}_walkParent(e){this._parent?this._parent._walkParent(e):this._virtualParent&&this._virtualParent._walkParent(e),e(this)}set virtualParent(e){this._virtualParent!==e&&(this._virtualParent=e,this._applyThemes())}get parent(){return this._parent}_setParent(e,t=!1){let i=this._parent;e!==i&&(this.markDirtyBounds(),e.markDirty(),this._parent=e,t&&(this._removeParent(i),e&&(this._addPercentageSizeChildren(),this._addPercentagePositionChildren())),this.markDirtyPosition(),this._applyThemes())}getNumberFormatter(){return this.get("numberFormatter",this._root.numberFormatter)}getDateFormatter(){return this.get("dateFormatter",this._root.dateFormatter)}getDurationFormatter(){return this.get("durationFormatter",this._root.durationFormatter)}toGlobal(e){return this._display.toGlobal(e)}toLocal(e){return this._display.toLocal(e)}_getDownPoint(){let e=this._getDownPointId();if(e)return this._downPoints[e]}_getDownPointId(){if(this._downPoints)return hf(this._downPoints,(e,t)=>e>t?1:e<t?-1:0)[0]}toFront(){let e=this.parent;e&&e.children.moveValue(this,e.children.length-1)}toBack(){let e=this.parent;e&&e.children.moveValue(this,0)}};hi.className="Sprite";hi.classNames=nt.classNames.concat([hi.className]);var ws=class extends nt{constructor(){super(...arguments),this._display=this._root._renderer.makeGraphics(),this._backgroundDisplay=this._root._renderer.makeGraphics(),this._clear=!1}_afterNew(){super._afterNewApplyThemes()}get pattern(){return this._pattern}_draw(){}_beforeChanged(){super._beforeChanged(),(this.isDirty("repetition")||this.isDirty("width")||this.isDirty("height")||this.isDirty("rotation")||this.isDirty("strokeWidth")||this.isDirty("strokeDasharray")||this.isDirty("strokeDashoffset")||this.isDirty("colorOpacity")||this.isDirty("fillOpacity"))&&(this._clear=!0),this._checkDirtyFill()}_checkDirtyFill(){(this.isDirty("color")||this.isDirty("fill"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){let e=this.get("repetition",""),t=this.get("width",100),i=this.get("height",100),s=this.get("fill"),r=this.get("fillOpacity",1),n=this._backgroundDisplay,A=this._display;A.clear(),n.clear(),s&&r>0&&(n.beginFill(s,r),n.drawRect(0,0,t,i),n.endFill()),A.angle=this.get("rotation",0),this._draw(),this._pattern=this._root._renderer.createPattern(A,n,e,t,i)}this._clear=!1}};ws.className="Pattern";ws.classNames=nt.classNames.concat([ws.className]);var Wa=class extends ws{_beforeChanged(){super._beforeChanged(),this._clear=!0,this.isDirty("src")&&this._load();let e=this.get("canvas");e&&(this.set("width",e.width),this.set("height",e.height))}_draw(){super._draw();let e=this.get("colorOpacity");e!==void 0&&(this._display.alpha=Math.max(0,e));let t=this._image;if(t){let s=this.get("width",100),r=this.get("height",100),n=this.get("fit","image"),A=0,o=0;n=="pattern"?(A=s,o=r,this.markDirty()):(A=t.width,o=t.height,n=="image"&&(this.set("width",A),this.set("height",o)));let l=this.get("centered",!0),c=0,h=0;l&&(c=s/2-A/2,h=r/2-o/2),this._display.image(t,A,o,c,h)}let i=this.get("canvas");i&&this._display.image(i,i.width,i.height,0,0)}_load(){let e=this.get("src");if(e){let t=new Image;t.src=e,t.decode().then(()=>{this._image=t,this._draw(),this.events.isEnabled("loaded")&&this.events.dispatch("loaded",{type:"loaded",target:this})}).catch(i=>{})}}};Wa.className="PicturePattern";Wa.classNames=ws.classNames.concat([Wa.className]);var IA;(function(a){a.ADD="lighter",a.COLOR="color",a.COLOR_BURN="color-burn",a.COLOR_DODGE="color-dodge",a.DARKEN="darken",a.DIFFERENCE="difference",a.DST_OVER="destination-over",a.EXCLUSION="exclusion",a.HARD_LIGHT="hard-light",a.HUE="hue",a.LIGHTEN="lighten",a.LUMINOSITY="luminosity",a.MULTIPLY="multiply",a.NORMAL="source-over",a.OVERLAY="overlay",a.SATURATION="saturation",a.SCREEN="screen",a.SOFT_LIGHT="soft-light",a.SRC_ATOP="source-atop",a.XOR="xor"})(IA||(IA={}));var Ko=["fill","fillOpacity","stroke","strokeWidth","strokeOpacity","fillPattern","strokePattern","fillGradient","strokeGradient","strokeDasharray","strokeDashoffset","shadowBlur","shadowColor","shadowOpacity","shadowOffsetX","shadowOffsetY","blur","sepia","invert","brightness","hue","contrast","saturate"],Le=class extends hi{constructor(){super(...arguments),this._display=this._root._renderer.makeGraphics(),this._clear=!1}_beforeChanged(){if(super._beforeChanged(),(this.isDirty("draw")||this.isDirty("svgPath"))&&this.markDirtyBounds(),(this.isDirty("fill")||this.isDirty("stroke")||this.isDirty("visible")||this.isDirty("forceHidden")||this.isDirty("scale")||this.isDirty("fillGradient")||this.isDirty("strokeGradient")||this.isDirty("fillPattern")||this.isDirty("strokePattern")||this.isDirty("fillOpacity")||this.isDirty("strokeOpacity")||this.isDirty("strokeWidth")||this.isDirty("draw")||this.isDirty("blendMode")||this.isDirty("strokeDasharray")||this.isDirty("strokeDashoffset")||this.isDirty("svgPath")||this.isDirty("lineJoin")||this.isDirty("lineCap")||this.isDirty("shadowColor")||this.isDirty("shadowBlur")||this.isDirty("shadowOffsetX")||this.isDirty("shadowOffsetY"))&&(this._clear=!0),this._display.crisp=this.get("crisp",!1),this.isDirty("fillGradient")){let e=this.get("fillGradient");if(e){this._display.isMeasured=!0;let t=e.get("target");t&&(this._disposers.push(t.events.on("boundschanged",()=>{this._markDirtyKey("fill")})),this._disposers.push(t.events.on("positionchanged",()=>{this._markDirtyKey("fill")})))}}if(this.isDirty("strokeGradient")){let e=this.get("strokeGradient");if(e){this._display.isMeasured=!0;let t=e.get("target");t&&(this._disposers.push(t.events.on("boundschanged",()=>{this._markDirtyKey("stroke")})),this._disposers.push(t.events.on("positionchanged",()=>{this._markDirtyKey("stroke")})))}}}_changed(){if(super._changed(),this._clear){this.markDirtyBounds(),this.markDirtyLayer(),this._display.clear();let e=this.get("strokeDasharray");W(e)&&(e<.5?e=[0]:e=[e]),this._display.setLineDash(e);let t=this.get("strokeDashoffset");t&&this._display.setLineDashOffset(t);let i=this.get("blendMode",IA.NORMAL);this._display.blendMode=i;let s=this.get("draw");s&&typeof s=="function"&&s(this._display,this);let r=this.get("svgPath");r!=null&&this._display.svgPath(r)}}_afterChanged(){if(super._afterChanged(),this._clear){let e=this.get("fill"),t=this.get("fillGradient"),i=this.get("fillPattern"),s=this.get("fillOpacity"),r=this.get("stroke"),n=this.get("strokeGradient"),A=this.get("strokePattern"),o=this.get("shadowColor"),l=this.get("shadowBlur"),c=this.get("shadowOffsetX"),h=this.get("shadowOffsetY"),d=this.get("shadowOpacity");if(o&&(l||c||h)&&this._display.shadow(o,l,c,h,d),e&&!t&&(this._display.beginFill(e,s),this._display.endFill()),t){if(e){let g=t.get("stops",[]);g.length&&K(g,y=>{(!y.color||y.colorInherited)&&e&&(y.color=e,y.colorInherited=!0),(y.opacity==null||y.opacityInherited)&&(y.opacity=s,y.opacityInherited=!0)})}let u=t.getFill(this);u&&(this._display.beginFill(u,s),this._display.endFill())}if(i){let u=i.pattern;u&&(this._display.beginFill(u,s),this._display.endFill(),i instanceof Wa&&i.events.once("loaded",()=>{this._clear=!0,this.markDirty()}))}if(r||n||A){let u=this.get("strokeOpacity"),g=this.get("strokeWidth",1);this.get("nonScalingStroke")&&(g=g/this.get("scale",1)),this.get("crisp")&&(g/=this._root._renderer.resolution);let y=this.get("lineJoin"),m=this.get("lineCap");if(r&&!n&&(this._display.lineStyle(g,r,u,y,m),this._display.endStroke()),n){let b=n.get("stops",[]);b.length&&K(b,w=>{(!w.color||w.colorInherited)&&r&&(w.color=r,w.colorInherited=!0),(w.opacity==null||w.opacityInherited)&&(w.opacity=u,w.opacityInherited=!0)});let B=n.getFill(this);B&&(this._display.lineStyle(g,B,u,y,m),this._display.endStroke())}if(A){let b=A.pattern;b&&(this._display.lineStyle(g,b,u,y,m),this._display.endStroke(),A instanceof Wa&&A.events.once("loaded",()=>{this._clear=!0,this.markDirty()}))}}this.getPrivate("showingTooltip")&&this.showTooltip()}this._clear=!1}};Le.className="Graphics";Le.classNames=hi.classNames.concat([Le.className]);var Tt=class extends Le{_afterNew(){super._afterNew(),this._display.isMeasured=!0,this.setPrivateRaw("trustBounds",!0)}_beforeChanged(){super._beforeChanged(),(this.isDirty("width")||this.isDirty("height")||this.isPrivateDirty("width")||this.isPrivateDirty("height"))&&(this._clear=!0)}_changed(){super._changed(),this._clear&&!this.get("draw")&&this._draw()}_draw(){let e=this.width(),t=this.height(),i=0,s=0,r=e/Math.abs(e),n=t/Math.abs(t);if(this.get("containStroke",!1)){let A=this.get("strokeWidth",0);e-=A*r,t-=A*n,i+=A/2*r,s+=A/2*n}this._display.drawRect(i,s,e,t)}_updateSize(){this.markDirty(),this._clear=!0}};Tt.className="Rectangle";Tt.classNames=Le.classNames.concat([Tt.className]);function Ys(a,e){a.get("reverseChildren",!1)?a.children.eachReverse(e):a.children.each(e)}var Cs=class extends nt{};Cs.className="Layout";Cs.classNames=nt.classNames.concat([Cs.className]);var kr=class extends Cs{updateContainer(e){let t=e.get("paddingLeft",0),i=e.innerWidth(),s=0;Ys(e,n=>{if(n.isVisible()&&n.get("position")=="relative"){let A=n.get("width");if(A instanceof ke){s+=A.value;let o=i*A.value,l=n.get("minWidth",n.getPrivate("minWidth",-1/0));l>o&&(i-=l,s-=A.value);let c=n.get("maxWidth",n.getPrivate("maxWidth",1/0));o>c&&(i-=c,s-=A.value)}else W(A)||(A=n.width()),i-=A+n.get("marginLeft",0)+n.get("marginRight",0)}}),(i<=0||i==1/0)&&(i=.1),Ys(e,n=>{if(n.isVisible()&&n.get("position")=="relative"){let A=n.get("width");if(A instanceof ke){let o=i*A.value/s-n.get("marginLeft",0)-n.get("marginRight",0),l=n.get("minWidth",n.getPrivate("minWidth",-1/0)),c=n.get("maxWidth",n.getPrivate("maxWidth",1/0));o=Math.min(Math.max(l,o),c),n.setPrivate("width",o)}else n._prevSettings.width instanceof ke&&n.setPrivate("width",void 0)}});let r=t;Ys(e,n=>{if(n.get("position")=="relative")if(n.isVisible()){let A=n.adjustedLocalBounds(),o=n.get("marginLeft",0),l=n.get("marginRight",0),c=n.get("maxWidth"),h=A.left,d=A.right;c&&d-h>c&&(d=h+c);let u=r+o-h;n.setPrivate("x",u),r=u+d+l}else n.setPrivate("x",void 0)})}};kr.className="HorizontalLayout";kr.classNames=Cs.classNames.concat([kr.className]);var Er=class extends Cs{updateContainer(e){let t=e.get("paddingTop",0),i=e.innerHeight(),s=0;Ys(e,n=>{if(n.isVisible()&&n.get("position")=="relative"){let A=n.get("height");if(A instanceof ke){s+=A.value;let o=i*A.value,l=n.get("minHeight",n.getPrivate("minHeight",-1/0));l>o&&(i-=l,s-=A.value);let c=n.get("maxHeight",n.getPrivate("maxHeight",1/0));o>c&&(i-=c,s-=A.value)}else W(A)||(A=n.height()),i-=A+n.get("marginTop",0)+n.get("marginBottom",0)}}),(i<=0||i==1/0)&&(i=.1),Ys(e,n=>{if(n.isVisible()&&n.get("position")=="relative"){let A=n.get("height");if(A instanceof ke){let o=i*A.value/s-n.get("marginTop",0)-n.get("marginBottom",0),l=n.get("minHeight",n.getPrivate("minHeight",-1/0)),c=n.get("maxHeight",n.getPrivate("maxHeight",1/0));o=Math.min(Math.max(l,o),c),n.setPrivate("height",o)}else n._prevSettings.height instanceof ke&&n.setPrivate("height",void 0)}});let r=t;Ys(e,n=>{if(n.get("position")=="relative")if(n.isVisible()){let A=n.adjustedLocalBounds(),o=n.get("marginTop",0),l=A.top,c=A.bottom,h=n.get("maxHeight");h&&c-l>h&&(c=l+h);let d=n.get("marginBottom",0),u=r+o-l;n.setPrivate("y",u),r=u+c+d}else n.setPrivate("y",void 0)})}};Er.className="VerticalLayout";Er.classNames=Cs.classNames.concat([Er.className]);var js=class extends Cs{_afterNew(){this._setRawDefault("maxColumns",Number.MAX_VALUE),super._afterNew()}updateContainer(e){let t=e.get("paddingLeft",0),i=e.get("paddingRight",0),s=e.get("paddingTop",0),r=e.maxWidth()-t-i,n=r,A=1;Ys(e,g=>{if(g.get("visible")&&g.getPrivate("visible")&&!g.get("forceHidden")&&g.get("position")!="absolute"){let y=g.width();y<n&&(n=y),y>A&&(A=y)}}),n=Bt(n,1,r),A=Bt(A,1,r);let o=1;this.get("fixedWidthGrid")?o=r/A:o=r/n,o=Math.max(1,Math.floor(o)),o=Math.min(this.get("maxColumns",Number.MAX_VALUE),o);let l=this.getColumnWidths(e,o,A,r),c=s,h=0,d=0;o=l.length;let u=t;Ys(e,g=>{if(g.get("position")=="relative"&&g.isVisible()){let y=g.get("marginTop",0),m=g.get("marginBottom",0),b=g.adjustedLocalBounds(),B=g.get("marginLeft",0),w=g.get("marginRight",0),_=u+B-b.left,T=c+y-b.top;g.setPrivate("x",_),g.setPrivate("y",T),u+=l[h]+w,d=Math.max(d,g.height()+y+m),h++,h>=o&&(h=0,u=t,c+=d,d=0)}})}getColumnWidths(e,t,i,s){let r=0,n=[],A=0;return Ys(e,o=>{let l=o.adjustedLocalBounds();o.get("position")!="absolute"&&o.isVisible()&&(this.get("fixedWidthGrid")?n[A]=i:n[A]=Math.max(n[A]|0,l.right-l.left+o.get("marginLeft",0)+o.get("marginRight",0)),A<e.children.length-1&&(A++,A==t&&(A=0)))}),K(n,o=>{r+=o}),r>s?t>2?(t-=1,this.getColumnWidths(e,t,i,s)):[s]:n}};js.className="GridLayout";js.classNames=Cs.classNames.concat([js.className]);var Di=class{static escape(e){return e.replace(/\[\[/g,this.prefix+"1").replace(/([^\/\]]{1})\]\]/g,"$1"+this.prefix+"2").replace(/\]\]/g,this.prefix+"2").replace(/\{\{/g,this.prefix+"3").replace(/\}\}/g,this.prefix+"4").replace(/\'\'/g,this.prefix+"5")}static unescape(e){return e.replace(new RegExp(this.prefix+"1","g"),"[[").replace(new RegExp(this.prefix+"2","g"),"]]").replace(new RegExp(this.prefix+"3","g"),"{{").replace(new RegExp(this.prefix+"4","g"),"}}").replace(new RegExp(this.prefix+"5","g"),"''")}static cleanUp(e){return e.replace(/\[\[/g,"[").replace(/\]\]/g,"]").replace(/\{\{/g,"{").replace(/\}\}/g,"}").replace(/\'\'/g,"'")}static chunk(e,t=!1,i=!1){let s=[];e=this.escape(e);let r=t?e.split("'"):[e];for(let n=0;n<r.length;n++){let A=r[n];if(A!=="")if(n%2===0){A=A.replace(/\]\[/g,"]"+Xs+"["),A=A.replace(/\[\]/g,"[ ]");let o=A.split(/[\[\]]+/);for(let l=0;l<o.length;l++){let c=this.cleanUp(this.unescape(o[l]));c!==Xs&&c!==""&&(l%2===0?s.push({type:"value",text:c}):s.push({type:i?"value":"format",text:"["+c+"]"}))}}else{let o=A.split(/[\[\]]+/);for(let l=0;l<o.length;l++){let c=this.cleanUp(this.unescape(o[l]));c!==""&&(l%2===0?s.push({type:"text",text:c}):this.isImage(c)?s.push({type:"image",text:"["+c+"]"}):s.push({type:"format",text:"["+c+"]"}))}}}return s}static isImage(e){return!!e.match(/img[ ]?:/)}static getTextStyle(e){let t={};if(e==""||e=="[ ]")return{};let i=e.match(/('[^']*')|("[^"]*")/gi);if(i)for(let r=0;r<i.length;r++)e=e.replace(i[r],i[r].replace(/['"]*/g,"").replace(/[ ]+/g,"+"));let s=e.match(/([\w\-]*:[\s]?[^;\s\]]*)|(\#[\w]{1,6})|([\w\-]+)|(\/)/gi);if(!s)return{};for(let r=0;r<s.length;r++)if(s[r].match(/^(normal|bold|bolder|lighter|100|200|300|400|500|600|700|800|900)$/i))t.fontWeight=s[r];else if(s[r].match(/^(underline|line-through)$/i))t.textDecoration=s[r];else if(s[r]!="/")if(!s[r].match(/:/))t.fill=we.fromString(s[r]);else{let n=s[r].replace("+"," ").split(/:[ ]*/);t[n[0]]=n[1]}return t}};Di.prefix="__amcharts__";function Pr(a,e){if(e!=null){e=""+e,e=Di.escape(e);let t=e.match(/\{([^}]+)\}/g),i;if(t)for(i=0;i<t.length;i++){let s=t[i].replace(/\{([^}]+)\}/,"$1"),r=Pf(a,s,"");r==null&&(r=""),e=e.split(t[i]).join(r)}e=Di.unescape(e)}else e="";return e}function Pf(a,e,t){let i,s=a.dataItem,r=[],n=/(format[a-zA-Z]*)\((.*)\)|([^.]+)/g,A;for(;A=n.exec(e),A!==null;)if(A[3]){r.push({prop:A[3]});let o=a.getDateFormatter().get("dateFields",[]),l=a.getNumberFormatter().get("numericFields",[]),c=a.getDurationFormatter().get("durationFields",[]);o.indexOf(A[3])!==-1?r.push({method:"formatDate",params:[]}):l.indexOf(A[3])!==-1?r.push({method:"formatNumber",params:[]}):c.indexOf(A[3])!==-1&&r.push({method:"formatDuration",params:[]})}else{let o=[];if($a(A[2])!=""){let l=/'([^']*)'|"([^"]*)"|([0-9\-]+)/g,c;for(;c=l.exec(A[2]),c!==null;)o.push(c[1]||c[2]||c[3])}r.push({method:A[1],params:o})}if(s){i=En(a,r,s._settings),(i==null||Gs(i))&&(i=En(a,r,s));let o=s.dataContext;i==null&&o&&(i=En(a,r,o),i==null&&(i=En(a,[{prop:e}],o)),i==null&&o.dataContext&&(i=En(a,r,o.dataContext))),i==null&&s.component&&s.component.dataItem!==s&&(i=Pf(s.component,e,t))}return i==null&&(i=En(a,r,a)),i==null&&a.parent&&(i=Pf(a.parent,e,t)),i}function dT(a,e){let t=a.getPrivate("customData");if(Gs(t))return t[e]}function En(a,e,t,i){let s=t,r=!1;for(let n=0,A=e.length;n<A;n++){let o=e[n];if(o.prop){if(s instanceof hi){let l=s.get(o.prop);l==null&&(l=s.getPrivate(o.prop)),l==null&&(l=dT(s,o.prop)),l==null&&(l=s[o.prop]),s=l}else if(s.get){let l=s.get(o.prop);l==null&&(l=s[o.prop]),s=l}else s=s[o.prop];if(s==null)return}else switch(o.method){case"formatNumber":let l=Vi(s);l!=null&&(s=a.getNumberFormatter().format(l,i||o.params[0]||void 0),r=!0);break;case"formatDate":let c=Ux(s);if(!Qh(c)||Ni(c.getTime()))return;c!=null&&(s=a.getDateFormatter().format(c,i||o.params[0]||void 0),r=!0);break;case"formatDuration":let h=Vi(s);h!=null&&(s=a.getDurationFormatter().format(h,i||o.params[0]||void 0,o.params[1]||void 0),r=!0);break;case"urlEncode":case"encodeURIComponent":s=encodeURIComponent(s);break;default:s[o.method]&&s[o.method].apply(t,o.params);break}}if(!r){let n=[{method:"",params:i}];if(i==null)W(s)?(n[0].method="formatNumber",n[0].params=""):Qh(s)&&(n[0].method="formatDate",n[0].params="");else{let A=Gx(i);A==="number"?n[0].method="formatNumber":A==="date"?n[0].method="formatDate":A==="duration"&&(n[0].method="formatDuration")}n[0].method&&(s=En(a,n,s))}return s}var pe=class a extends hi{constructor(){super(...arguments),this._display=this._root._renderer.makeContainer(),this._childrenDisplay=this._root._renderer.makeContainer(),this.children=new Gh(this),this._percentageSizeChildren=[],this._percentagePositionChildren=[],this._prevWidth=0,this._prevHeight=0,this._contentWidth=0,this._contentHeight=0,this._childrenPrep=!1,this._childrenUpdt=!1}_afterNew(){super._afterNew(),this._display.addChild(this._childrenDisplay)}_afterChanged(){super._afterChanged(),this._childrenPrep=!1,this._childrenUpdt=!1}_dispose(){Oa(this.allChildren(),e=>{e.dispose()}),this.getPrivate("htmlElement")&&this._root._removeHTMLContent(this),super._dispose()}_beforeChanged(){this._childrenPrep||this._prepareChildren(),this._childrenUpdt||this._updateChildren(),super._beforeChanged()}_changed(){if(super._changed(),this.isDirty("interactiveChildren")&&(this._display.interactiveChildren=this.get("interactiveChildren",!1)),this.isDirty("layout")&&(this._prevWidth=0,this._prevHeight=0,this.markDirtyBounds(),this._prevSettings.layout&&this.children.each(e=>{e.removePrivate("x"),e.removePrivate("y")})),(this.isDirty("paddingTop")||this.isDirty("paddingBottom")||this.isDirty("paddingLeft")||this.isDirty("paddingRight"))&&this.children.each(e=>{e.markDirtyPosition()}),this.isDirty("maskContent")){let e=this._childrenDisplay,t=this._contentMask;this.get("maskContent")?t||(t=Tt.new(this._root,{x:-.5,y:-.5,width:this.width()+1,height:this.height()+1}),this._contentMask=t,e.addChildAt(t._display,0),e.mask=t._display):t&&(e.removeChild(t._display),e.mask=null,t.dispose(),this._contentMask=void 0)}}_updateSize(){super._updateSize(),K(this._percentageSizeChildren,e=>{e._updateSize()}),K(this._percentagePositionChildren,e=>{e.markDirtyPosition(),e._updateSize()}),this.updateBackground()}updateBackground(){let e=this.get("background"),t=this._localBounds;if(t&&!this.isHidden()){let i=t.left,s=t.top,r=t.right-i,n=t.bottom-s,A=this.get("maxWidth"),o=this.get("maxHeight");o&&n>o&&(n=o),A&&r>A&&(r=A);let l=this.width(),c=this.height();e&&(e.setAll({width:r,height:n,x:i,y:s}),this._display.interactive&&(e._display.interactive=!0));let h=this._contentMask;h&&h.setAll({width:l+1,height:c+1});let d=this.get("verticalScrollbar");if(d){d.set("height",c),d.set("x",l-d.width()-d.get("marginRight",0)),d.set("end",d.get("start",0)+c/this._contentHeight);let u=d.get("background");u&&u.setAll({width:d.width(),height:c});let g=!0;this._contentHeight<=c&&(g=!1),d.setPrivate("visible",g)}}}_applyThemes(e=!1){return super._applyThemes(e)?(this.eachChildren(t=>{t._applyThemes(e)}),!0):!1}_applyState(e){super._applyState(e),this.get("setStateOnChildren")&&this.eachChildren(t=>{t.states.apply(e)})}_applyStateAnimated(e,t){super._applyStateAnimated(e,t),this.get("setStateOnChildren")&&this.eachChildren(i=>{i.states.applyAnimate(e,t)})}innerWidth(){return this.width()-this.get("paddingRight",0)-this.get("paddingLeft",0)}innerHeight(){return this.height()-this.get("paddingTop",0)-this.get("paddingBottom",0)}_getBounds(){if(this.get("html")){let e=this._localBounds;e&&(this._contentWidth=e.right-e.left,this._contentHeight=e.bottom-e.top)}else{let e=this.get("width"),t=this.get("height"),i=this.getPrivate("width"),s=this.getPrivate("height"),r={left:0,top:0,right:this.width(),bottom:this.height()},n=this.get("layout"),A=!1,o=!1;if((n instanceof kr||n instanceof js)&&(A=!0),n instanceof Er&&(o=!0),!((e!=null||i!=null)&&(t!=null||s!=null)&&!this.get("verticalScrollbar"))){let l=Number.MAX_VALUE,c=l,h=-l,d=l,u=-l,g=this.get("paddingLeft",0),y=this.get("paddingTop",0),m=this.get("paddingRight",0),b=this.get("paddingBottom",0);this.children.each(_=>{if(_.get("position")!="absolute"&&_.get("isMeasured")){let T=_.adjustedLocalBounds(),Q=_.x(),U=_.y(),E=Q+T.left,O=Q+T.right,D=U+T.top,k=U+T.bottom;A&&(E-=_.get("marginLeft",0),O+=_.get("marginRight",0)),o&&(D-=_.get("marginTop",0),k+=_.get("marginBottom",0)),E<c&&(c=E),O>h&&(h=O),D<d&&(d=D),k>u&&(u=k)}}),c==l&&(c=0),h==-l&&(h=0),d==l&&(d=0),u==-l&&(u=0),r.left=c-g,r.top=d-y,r.right=h+m,r.bottom=u+b;let B=this.get("minWidth");W(B)&&B>0&&r.right-r.left<B&&(r.right>=B?r.left=r.right-B:r.right=r.left+B);let w=this.get("minHeight");W(w)&&w>0&&r.bottom-r.top<w&&(r.bottom>=w?r.top=r.bottom-w:r.bottom=r.top+w)}this._contentWidth=r.right-r.left,this._contentHeight=r.bottom-r.top,W(e)&&(r.left=0,r.right=e),W(i)&&(r.left=0,r.right=i),W(t)&&(r.top=0,r.bottom=t),W(s)&&(r.top=0,r.bottom=s),this._localBounds=r}}_updateBounds(){let e=this.get("layout");e&&e.updateContainer(this),super._updateBounds(),this.updateBackground()}markDirty(){super.markDirty(),this._root._addDirtyParent(this)}_prepareChildren(){this._childrenPrep=!0;let e=this.innerWidth(),t=this.innerHeight();if(e!=this._prevWidth||t!=this._prevHeight){let i=this.get("layout"),s=!1,r=!1;i&&((i instanceof kr||i instanceof js)&&(s=!0),i instanceof Er&&(r=!0)),K(this._percentageSizeChildren,n=>{if(!s){let A=n.get("width");A instanceof ke&&n.setPrivate("width",A.value*e)}if(!r){let A=n.get("height");A instanceof ke&&n.setPrivate("height",A.value*t)}}),K(this._percentagePositionChildren,n=>{n.markDirtyPosition(),n.markDirtyBounds()}),this._prevWidth=e,this._prevHeight=t,this._sizeDirty=!0,this.updateBackground()}}_updateHTMLContent(){let e=this.get("html","");e&&e!==""?this._root._setHTMLContent(this,Pr(this,e)):this._root._removeHTMLContent(this),this._root._positionHTMLElement(this)}scrollToChild(e){let t=this.get("verticalScrollbar");if(t){let i=e.y(),s=this.innerHeight(),r=e.height(),n=this._contentHeight,A=1-(s-r/2)/n;if(i+r*.7+this._childrenDisplay.y>s||i-r*.3+this._childrenDisplay.y<0){let o=Math.max(0,Math.min(A,(i-r/2)/n));t.animate({key:"start",to:o,duration:t.get("animationDuration",0),easing:t.get("animationEasing")})}}}_updateChildren(){if(this._childrenUpdt=!0,this.isDirty("html")&&this._updateHTMLContent(),this.isDirty("verticalScrollbar")){let e=this.get("verticalScrollbar");if(e){e._setParent(this),e.startGrip.setPrivate("visible",!1),e.endGrip.setPrivate("visible",!1),this.set("maskContent",!0),this.set("paddingRight",e.width()+e.get("marginRight",0)+e.get("marginLeft",0));let t=this.get("background");t||(t=this.set("background",Tt.new(this._root,{themeTags:["background"],fillOpacity:0,fill:this._root.interfaceColors.get("alternativeBackground")}))),this._vsbd0=this.events.on("wheel",i=>{let s=i.originalEvent;if(FA(s,this))s.preventDefault();else return;let r=s.deltaY/5e3,n=e.get("start",0),A=e.get("end",1);n+r<=0&&(r=-n),A+r>=1&&(r=1-A),n+r>=0&&A+r<=1&&(e.set("start",n+r),e.set("end",A+r))}),this._disposers.push(this._vsbd0),this._vsbd1=e.events.on("rangechanged",()=>{let i=this._contentHeight,s=this._childrenDisplay,r=this._contentMask;s.y=-e.get("start",0)*i,s.markDirtyLayer(),r&&(r._display.y=-s.y,s.mask=r._display)}),this._disposers.push(this._vsbd1),this._display.addChild(e._display)}else{let t=this._prevSettings.verticalScrollbar;if(t){this._display.removeChild(t._display),this._vsbd0&&this._vsbd0.dispose(),this._vsbd1&&this._vsbd1.dispose();let i=this._childrenDisplay;i.y=0,this.setPrivate("height",void 0),this.set("maskContent",!1),this.set("paddingRight",void 0)}}}if(this.isDirty("background")){let e=this._prevSettings.background;e&&this._display.removeChild(e._display);let t=this.get("background");t instanceof hi&&(t.set("isMeasured",!1),t._setParent(this),this._display.addChildAt(t._display,0))}if(this.isDirty("mask")){let e=this.get("mask"),t=this._prevSettings.mask;if(t&&(this._display.removeChild(t._display),t!=e&&t.dispose()),e){let i=e.parent;i&&i.children.removeValue(e),e._setParent(this),this._display.addChildAt(e._display,0),this._childrenDisplay.mask=e._display}}}_processTemplateField(){super._processTemplateField(),this.children.each(e=>{e._processTemplateField()})}walkChildren(e){this.children.each((t,i)=>{t instanceof a&&t.walkChildren(e),e(t,i)})}eachChildren(e){let t=this.get("background");t&&e(t);let i=this.get("verticalScrollbar");i&&e(i);let s=this.get("mask");s&&e(s),this.children.values.forEach(r=>{e(r)})}allChildren(){let e=[];return this.eachChildren(t=>{e.push(t)}),e}_setDataItem(e){let t=e!==this._dataItem;super._setDataItem(e);let i=this.get("html","");i&&i!==""&&t&&this._root._setHTMLContent(this,Pr(this,i))}contentWidth(){return this._contentWidth}contentHeight(){return this._contentHeight}};pe.className="Container";pe.classNames=hi.classNames.concat([pe.className]);var Zs=class extends hi{constructor(){super(...arguments),this.textStyle=this._root._renderer.makeTextStyle(),this._display=this._root._renderer.makeText("",this.textStyle),this._textStyles=["textAlign","fontFamily","fontSize","fontStyle","fontWeight","fontStyle","fontVariant","textDecoration","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","shadowOpacity","lineHeight","baselineRatio","direction","textBaseline","oversizedBehavior","breakWords","ellipsis","minScale","maxChars"]}_updateBounds(){if(this.get("text")){super._updateBounds();let e=this.get("fillGradient");e&&(this._display.style.fill=e.getFill(this))}else{let e={left:0,right:0,top:0,bottom:0};this._adjustedLocalBounds=e}}_changed(){super._changed(),this._display.clear();let e=this.textStyle;if(this.isDirty("opacity")){let t=this.get("opacity",1);this._display.alpha=t}if((this.isDirty("text")||this.isDirty("populateText"))&&(this._display.text=this._getText(),this.markDirtyBounds(),this.get("role")=="tooltip"&&this._root.updateTooltip(this)),this.isPrivateDirty("tooltipElement")&&this.getPrivate("tooltipElement")&&this._disposers.push(new Qt(()=>{this._root._removeTooltipElement(this)})),this.isDirty("width")&&(e.wordWrapWidth=this.width(),this.markDirtyBounds()),this.isDirty("oversizedBehavior")&&(e.oversizedBehavior=this.get("oversizedBehavior","none"),this._display.invalidateVisibility(),this.markDirtyBounds()),this.isDirty("breakWords")&&(e.breakWords=this.get("breakWords",!1),this.markDirtyBounds()),this.isDirty("ellipsis")&&(e.ellipsis=this.get("ellipsis"),this.markDirtyBounds()),this.isDirty("ignoreFormatting")&&(e.ignoreFormatting=this.get("ignoreFormatting",!1),this.markDirtyBounds()),this.isDirty("minScale")&&(e.minScale=this.get("minScale",0),this.markDirtyBounds()),this.isDirty("fill")||this.isDirty("fillGradient")){let t=this.get("fill"),i=this.get("fillGradient"),s=this.get("fillOpacity");if(i){if(t){let r=i.get("stops",[]);r.length&&K(r,n=>{(!n.color||n.colorInherited)&&t&&(n.color=t,n.colorInherited=!0),(n.opacity==null||n.opacityInherited)&&(n.opacity=s,n.opacityInherited=!0)})}e.fill=i.getFill(this)}else t&&(e.fill=t)}if(this.isDirty("fillOpacity")){let t=this.get("fillOpacity",1);t&&(e.fillOpacity=t)}(this.isDirty("maxWidth")||this.isPrivateDirty("maxWidth"))&&(e.maxWidth=this.get("maxWidth",this.getPrivate("maxWidth")),this.markDirtyBounds()),(this.isDirty("maxHeight")||this.isPrivateDirty("maxHeight"))&&(e.maxHeight=this.get("maxHeight",this.getPrivate("maxHeight")),this.markDirtyBounds()),K(this._textStyles,t=>{this._dirty[t]&&(e[t]=this.get(t),this.markDirtyBounds())}),e.fontSize=this.get("fontSize"),e.fontFamily=this.get("fontFamily"),this._display.style=e,this.isDirty("role")&&this.get("role")=="tooltip"&&this._root.updateTooltip(this)}_getText(){let e=this.get("text","");return this.get("maxChars")&&(e=Kx(e,this.get("maxChars",1e8),this.get("breakWords"),this.get("ellipsis"))),this.get("populateText")?Pr(this,e):e}_getAccessibleText(){let e=this.get("ariaLabel");return e!==void 0?this.get("populateText")?Pr(this,e):e:this._getText()}markDirtyText(){this._display.text=this._getText(),this.get("role")=="tooltip"&&this._root.updateTooltip(this),this.markDirtyBounds(),this.markDirty()}_setDataItem(e){super._setDataItem(e),this.get("populateText")&&this.markDirtyText()}getNumberFormatter(){return this.parent?this.parent.getNumberFormatter():super.getNumberFormatter()}getDateFormatter(){return this.parent?this.parent.getDateFormatter():super.getDateFormatter()}getDurationFormatter(){return this.parent?this.parent.getDurationFormatter():super.getDurationFormatter()}};Zs.className="Text";Zs.classNames=hi.classNames.concat([Zs.className]);var Mf=class{constructor(){this._targets=[],this._observer=new ResizeObserver(e=>{K(e,t=>{K(this._targets,i=>{i.target===t.target&&i.callback()})})})}addTarget(e,t){this._observer.observe(e,{box:"border-box"}),this._targets.push({target:e,callback:t})}removeTarget(e){this._observer.unobserve(e),Un(this._targets,t=>t.target!==e)}},qh=class a{constructor(){this._timer=null,this._targets=[]}addTarget(e,t){if(this._timer===null){let s=null,r=()=>{let n=Date.now();(s===null||n>s+a.delay)&&(s=n,K(this._targets,A=>{let o=A.target.getBoundingClientRect();(o.width!==A.size.width||o.height!==A.size.height)&&(A.size=o,A.callback())})),this._targets.length===0?this._timer=null:this._timer=requestAnimationFrame(r)};this._timer=requestAnimationFrame(r)}let i={width:0,height:0,left:0,right:0,top:0,bottom:0,x:0,y:0};this._targets.push({target:e,callback:t,size:i})}removeTarget(e){Un(this._targets,t=>t.target!==e),this._targets.length===0&&this._timer!==null&&(cancelAnimationFrame(this._timer),this._timer=null)}};qh.delay=200;var Zh=null;function uT(){return Zh===null&&(typeof ResizeObserver<"u"?Zh=new Mf:Zh=new qh),Zh}var Jh=class{constructor(e,t){this._disposed=!1,this._sensor=uT(),this._element=e,this._listener=Oh(t),this._sensor.addTarget(e,t)}isDisposed(){return this._disposed}dispose(){this._disposed||(this._disposed=!0,this._sensor.removeTarget(this._element),this._listener.dispose())}get sensor(){return this._sensor}};var Pn=class extends nt{};Pn.className="InterfaceColors";Pn.classNames=nt.classNames.concat([Pn.className]);var Ze=class extends pe{constructor(){super(...arguments),this._textKeys=["text","fill","fillGradient","fillOpacity","textAlign","fontFamily","fontSize","fontStyle","fontWeight","fontStyle","fontVariant","textDecoration","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","shadowOpacity","lineHeight","baselineRatio","direction","textBaseline","oversizedBehavior","breakWords","ellipsis","minScale","populateText","role","ignoreFormatting","maxChars","ariaLabel"]}get text(){return this._text}_afterNew(){super._afterNew(),this._makeText(),K(this._textKeys,e=>{let t=this.get(e);t!=null&&this._text.set(e,t)}),this.get("html","")!==""&&this._text.set("text",""),this.onPrivate("maxWidth",()=>{this._setMaxDimentions()}),this.onPrivate("maxHeight",()=>{this._setMaxDimentions()})}_makeText(){this._text=this.children.push(Zs.new(this._root,{}))}_updateChildren(){super._updateChildren();let e=this._text;if(K(this._textKeys,i=>{this._text.set(i,this.get(i))}),(this.isDirty("maxWidth")||this.isDirty("maxHeight")||this.isDirty("rotation"))&&this._setMaxDimentions(),this.get("html","")!==""?e.set("text",""):(e.set("text",this.get("text")),this._maybeUpdateHTMLColor()),(this.isDirty("fill")||this.isDirty("fillGradient"))&&this._maybeUpdateHTMLColor(),this.isDirty("textAlign")||this.isDirty("width")){let i=this.get("textAlign"),s;this.get("width")!=null?i=="right"?s=se:i=="center"?s=ye:s=0:i=="left"||i=="start"?s=this.get("paddingLeft",0):(i=="right"||i=="end")&&(s=-this.get("paddingRight",0)),e.set("x",s)}let t=this.get("background");t&&t.setPrivate("visible",e._display.textVisible)}_maybeUpdateHTMLColor(){let e=this.getPrivate("htmlElement");e&&this.get("fill")&&(e.style.color=this.get("fill").toCSSHex())}_setMaxDimentions(){let e=this.get("rotation"),t=e==90||e==270||e==-90,i=this._text,s=this.get("maxWidth",this.getPrivate("maxWidth",1/0));W(s)?i.set(t?"maxHeight":"maxWidth",s-this.get("paddingTop",0)-this.get("paddingBottom",0)):i.set(t?"maxHeight":"maxWidth",void 0);let r=this.get("maxHeight",this.getPrivate("maxHeight",1/0));W(r)?i.set(t?"maxWidth":"maxHeight",r-this.get("paddingLeft",0)-this.get("paddingRight",0)):i.set(t?"maxWidth":"maxHeight",void 0),this.root.events.once("frameended",()=>{i.markDirtyBounds()})}_setDataItem(e){super._setDataItem(e),this._markDirtyKey("text"),this._markDirtyKey("html");let t=this._text;t.get("populateText")&&t.markDirtyText();let i=this.get("html");i&&i!==""&&this._updateHTMLContent()}getText(){return this._text._getText()}getAccessibleText(){return this._text._getAccessibleText()}};Ze.className="Label";Ze.classNames=pe.classNames.concat([Ze.className]);var ga=class extends Le{_beforeChanged(){super._beforeChanged(),(this.isDirty("pointerBaseWidth")||this.isDirty("cornerRadius")||this.isDirty("pointerLength")||this.isDirty("pointerX")||this.isDirty("pointerY")||this.isDirty("width")||this.isDirty("height"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){this.markDirtyBounds();let e=this.width(),t=this.height();if(e>0&&t>0){let i=this.get("cornerRadius",8);i=Bt(i,0,Math.min(e/2,t/2));let s=this.get("pointerX",0),r=this.get("pointerY",0),n=this.get("pointerBaseWidth",15)/2,A=0,o=0,l=e,c=0,h=e,d=t,u=0,g=t,y=(s-A)*(d-o)-(r-o)*(h-A),m=(s-u)*(c-g)-(r-g)*(l-u),b=this._display;if(b.moveTo(i,0),y>0&&m>0){let B=Math.round(Bt(s,i+n,e-n-i));r=Bt(r,-1/0,0),b.lineTo(B-n,0),b.lineTo(s,r),b.lineTo(B+n,0)}if(b.lineTo(e-i,0),b.arcTo(e,0,e,i,i),y>0&&m<0){let B=Math.round(Bt(r,i+n,t-n-i));s=Bt(s,e,1/0),b.lineTo(e,i),b.lineTo(e,Math.max(B-n,i)),b.lineTo(s,r),b.lineTo(e,B+n)}if(b.lineTo(e,t-i),b.arcTo(e,t,e-i,t,i),y<0&&m<0){let B=Math.round(Bt(s,i+n,e-n-i));r=Bt(r,t,1/0),b.lineTo(e-i,t),b.lineTo(B+n,t),b.lineTo(s,r),b.lineTo(B-n,t)}if(b.lineTo(i,t),b.arcTo(0,t,0,t-i,i),y<0&&m>0){let B=Math.round(Bt(r,i+n,t-i-n));s=Bt(s,-1/0,0),b.lineTo(0,t-i),b.lineTo(0,B+n),b.lineTo(s,r),b.lineTo(0,Math.max(B-n,i))}b.lineTo(0,i),b.arcTo(0,0,i,0,i),b.closePath()}}}};ga.className="PointedRectangle";ga.classNames=Le.classNames.concat([ga.className]);var ai=class extends pe{constructor(e,t,i,s=[]){super(e,t,i,s),this._fx=0,this._fy=0,this._w=0,this._h=0,this._htmlContentHovered=!1}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["tooltip"]),super._afterNew(),this._setDefaultFn("background",()=>ga.new(this._root,{})).set("themeTags",["tooltip","background"]),this._label=this.children.push(Ze.new(this._root,{})),this._disposers.push(this._label.events.on("boundschanged",()=>{this._updateBackground()})),this._disposers.push(this.on("bounds",()=>{this._updateBackground()})),this._updateTextColor(),this._root.tooltipContainer.children.push(this),this.hide(0),this._disposers.push(this.label.onPrivate("htmlElement",t=>{t&&(this._disposers.push(kt(t,"pointerover",i=>{this._htmlContentHovered=!0})),this._disposers.push(kt(t,"pointerout",i=>{this._htmlContentHovered=!1})))})),this.on("visible",t=>{this._handleReaderAnnouncement()}),this.label.events.on("dataitemchanged",t=>{this._handleReaderAnnouncement()}),this._root._tooltips.push(this)}_handleReaderAnnouncement(){this.get("readerAnnounce")&&this.isVisibleDeep()&&this._root.readerAlert(this.label.getAccessibleText())}get label(){return this._label}_dispose(){super._dispose(),ri(this._root._tooltips,this)}_updateChildren(){super._updateChildren(),(this.isDirty("pointerOrientation")||this.isPrivateDirty("minWidth")||this.isPrivateDirty("minHeight"))&&this.get("background")._markDirtyKey("width"),this.get("labelText")!=null&&this.label.set("text",this.get("labelText")),this.get("labelHTML")!=null&&this.label.set("html",this.get("labelHTML")),this.get("labelAriaLabel")!=null&&this.label.set("ariaLabel",this.get("labelAriaLabel"))}_changed(){if(super._changed(),(this.isDirty("pointTo")||this.isDirty("pointerOrientation"))&&this._updateBackground(),this.isDirty("tooltipTarget")&&this.updateBackgroundColor(),this.isDirty("keepTargetHover"))if(this.get("keepTargetHover")){let t=this.get("background");this._keepHoverDp=new zt([t.events.on("pointerover",i=>{let s=this.get("tooltipTarget");s&&(s.parent&&s.parent.getPrivate("tooltipTarget")==s&&(s=s.parent),s.hover())}),t.events.on("pointerout",i=>{let s=this.get("tooltipTarget");s&&(s.parent&&s.parent.getPrivate("tooltipTarget")==s&&(s=s.parent),this._htmlContentHovered||s.unhover())})]),this.label.onPrivate("htmlElement",i=>{this._keepHoverDp&&i&&this._keepHoverDp.disposers.push(kt(i,"pointerleave",s=>{let r=this.root._renderer.getEvent(s);t.events.dispatch("pointerout",{type:"pointerout",originalEvent:r.event,point:r.point,simulated:!1,target:t})}))})}else this._keepHoverDp&&(this._keepHoverDp.dispose(),this._keepHoverDp=void 0)}_onShow(){super._onShow(),this.updateBackgroundColor()}updateBackgroundColor(){let e=this.get("tooltipTarget"),t=this.get("background"),i,s;if(e&&t){if(i=e.get("fill"),s=e.get("stroke"),i==null&&(i=s),this.get("getFillFromSprite")&&(this._fillDp&&this._fillDp.dispose(),i!=null&&t.set("fill",i),this._fillDp=e.on("fill",r=>{r!=null&&(t.set("fill",r),this._updateTextColor(r))}),this._disposers.push(this._fillDp)),this.get("getFillGradientFromSprite")){this._fillGrDp&&this._fillGrDp.dispose();let r=e.get("fillGradient");r!=null&&t.set("fillGradient",r),this._fillGrDp=e.on("fillGradient",n=>{n!=null&&t.set("fillGradient",n)}),this._disposers.push(this._fillGrDp)}this.get("getStrokeFromSprite")&&(this._strokeDp&&this._strokeDp.dispose(),i!=null&&t.set("stroke",i),this._strokeDp=e.on("fill",r=>{r!=null&&t.set("stroke",r)}),this._disposers.push(this._strokeDp)),this.get("getLabelFillFromSprite")&&(this._labelDp&&this._labelDp.dispose(),i!=null&&this.label.set("fill",i),this._labelDp=e.on("fill",r=>{r!=null&&this.label.set("fill",r)}),this._disposers.push(this._labelDp))}this._updateTextColor(i)}_updateTextColor(e){this.get("autoTextColor")&&(e==null&&(e=this.get("background").get("fill")),e==null&&(e=this._root.interfaceColors.get("background")),e instanceof we&&this.label.set("fill",we.alternative(e,this._root.interfaceColors.get("alternativeText"),this._root.interfaceColors.get("text"))))}_setDataItem(e){super._setDataItem(e),this.label._setDataItem(e)}_updateBackground(){super.updateBackground();let e=this._root.container;if(e){let t=.5,i=.5,s=this.get("centerX");s instanceof ke&&(t=s.value);let r=this.get("centerY");r instanceof ke&&(i=r.value);let n=e.width(),A=e.height(),o=this.parent,l=0,c=0;if(o){l=o.x(),c=o.y();let k=o.get("layerMargin");k&&(l+=k.left||0,c+=k.top||0,n+=(k.left||0)+(k.right||0),A+=(k.top||0)+(k.bottom||0))}let h=this.get("bounds",{left:-l,top:-c,right:n-l,bottom:A-c});this._updateBounds();let d=this.width(),u=this.height();d===0&&(d=this._w),u===0&&(u=this._h);let g=this.get("pointTo",{x:n/2,y:A/2}),y=g.x,m=g.y,b=this.get("pointerOrientation"),B=this.get("background"),w=0,_=0,T=0;B instanceof ga&&(w=B.get("pointerLength",0),_=B.get("strokeWidth",0)/2,T=_,B.set("width",d),B.set("height",u));let Q=0,U=0,E=h.right-h.left,O=h.bottom-h.top;b=="horizontal"||b=="left"||b=="right"?(_=0,b=="horizontal"?y>h.left+E/2?(y-=d*(1-t)+w,T*=-1):y+=d*t+w:b=="left"?y+=d*(1-t)+w:(y-=d*t+w,T*=-1)):(T=0,b=="vertical"?m>h.top+u/2+w?m-=u*(1-i)+w:(m+=u*i+w,_*=-1):b=="down"?m-=u*(1-i)+w:(m+=u*i+w,_*=-1)),y=Bt(y,h.left+d*t,h.left+E-d*(1-t))+T,m=Bt(m,h.top+u*i,h.top+O-u*(1-i))-_,Q=g.x-y+d*t+T,U=g.y-m+u*i-_,this._fx=y,this._fy=m;let D=this.get("animationDuration",0);if(D>0&&this.get("visible")&&this.get("opacity")>.1){let k=this.get("animationEasing");this.animate({key:"x",to:y,duration:D,easing:k}),this.animate({key:"y",to:m,duration:D,easing:k})}else this.set("x",y),this.set("y",m);B instanceof ga&&(B.set("pointerX",Q),B.set("pointerY",U)),d>0&&(this._w=d),u>0&&(this._h=u)}}};ai.className="Tooltip";ai.classNames=pe.classNames.concat([ai.className]);var za=class extends nt{_setDefaults(){this._setDefault("negativeBase",0),this._setDefault("numberFormat","#,###.#####"),this._setDefault("smallNumberThreshold",1);let e="_big_number_suffix_",t="_small_number_suffix_",i="_byte_suffix_";this._setDefault("bigNumberPrefixes",[{number:1e3,suffix:this._t(e+"3")},{number:1e6,suffix:this._t(e+"6")},{number:1e9,suffix:this._t(e+"9")},{number:1e12,suffix:this._t(e+"12")},{number:1e15,suffix:this._t(e+"15")},{number:1e18,suffix:this._t(e+"18")},{number:1e21,suffix:this._t(e+"21")},{number:1e24,suffix:this._t(e+"24")}]),this._setDefault("smallNumberPrefixes",[{number:1e-24,suffix:this._t(t+"24")},{number:1e-21,suffix:this._t(t+"21")},{number:1e-18,suffix:this._t(t+"18")},{number:1e-15,suffix:this._t(t+"15")},{number:1e-12,suffix:this._t(t+"12")},{number:1e-9,suffix:this._t(t+"9")},{number:1e-6,suffix:this._t(t+"6")},{number:.001,suffix:this._t(t+"3")}]),this._setDefault("bytePrefixes",[{number:1,suffix:this._t(i+"B")},{number:1024,suffix:this._t(i+"KB")},{number:1048576,suffix:this._t(i+"MB")},{number:1073741824,suffix:this._t(i+"GB")},{number:1099511627776,suffix:this._t(i+"TB")},{number:0x4000000000000,suffix:this._t(i+"PB")}]),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(e,t,i){(t==null||Ur(t)&&t.toLowerCase()==="number")&&(t=this.get("numberFormat",""));let s,r=Number(e);if(Gs(t))try{return this.get("intlLocales")?new Intl.NumberFormat(this.get("intlLocales"),t).format(r):new Intl.NumberFormat(void 0,t).format(r)}catch{return"Invalid"}else{t=SA(t);let n=this.parseFormat(t,this._root.language),A;r>this.get("negativeBase")?A=n.positive:r<this.get("negativeBase")?A=n.negative:A=n.zero,i!=null&&!A.mod&&(A=Ws(A),A.decimals.active=r==0?0:i),s=A.template.split(Xs).join(this.applyFormat(r,A))}return this.get("forceLTR")===!0&&(s="\u200E"+s),s}parseFormat(e,t){let i=t.translateEmpty("_thousandSeparator"),s=t.translateEmpty("_decimalSeparator"),r={positive:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1},negative:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1},zero:{thousands:{active:-1,passive:-1,interval:-1,separator:i},decimals:{active:-1,passive:-1,separator:s},template:"",source:"",parsed:!1}};e=e.replace("||",Ra);let n=e.split("|");return r.positive.source=n[0],typeof n[2]>"u"?r.zero=r.positive:r.zero.source=n[2],typeof n[1]>"u"?r.negative=r.positive:r.negative.source=n[1],Ve(r,(A,o)=>{if(o.parsed)return;let l=o.source;l.toLowerCase()==="number"&&(l=this.get("numberFormat","#,###.#####"));let c=Di.chunk(l,!0);for(let h=0;h<c.length;h++){let d=c[h];if(d.text=d.text.replace(Ra,"|"),d.type==="value"){let u=d.text.match(/[#0.,]+[ ]?[abespABESP%!]?[abespABESP‰!]?/);if(u)if(u===null||u[0]==="")o.template+=d.text;else{let g=u[0].match(/[abespABESP%‰!]{2}|[abespABESP%‰]{1}$/);g&&(o.mod=g[0].toLowerCase(),o.modSpacing=!!u[0].match(/[ ]{1}[abespABESP%‰!]{1}$/));let y=u[0].split(".");if(y[0]!==""){o.thousands.active=(y[0].match(/0/g)||[]).length,o.thousands.passive=(y[0].match(/\#/g)||[]).length+o.thousands.active;let m=y[0].split(",");m.length===1||(o.thousands.interval=(m.pop()||"").length,o.thousands.interval===0&&(o.thousands.interval=-1))}typeof y[1]>"u"||(o.decimals.active=(y[1].match(/0/g)||[]).length,o.decimals.passive=(y[1].match(/\#/g)||[]).length+o.decimals.active),o.template+=d.text.split(u[0]).join(Xs)}}else o.template+=d.text}o.parsed=!0}),r}applyFormat(e,t){let i=e<0;e=Math.abs(e);let s="",r="",n=t.mod?t.mod.split(""):[];if(n.indexOf("b")!==-1){let h=this.applyPrefix(e,this.get("bytePrefixes"),n.indexOf("!")!==-1);e=h[0],s=h[1],r=h[2],t.modSpacing&&(r=" "+r)}else if(n.indexOf("a")!==-1){let h=this.applyPrefix(e,e<this.get("smallNumberThreshold")?this.get("smallNumberPrefixes"):this.get("bigNumberPrefixes"),n.indexOf("!")!==-1);e=h[0],s=h[1],r=h[2],t.modSpacing&&(r=" "+r)}else if(n.indexOf("p")!==-1){let h=Math.min(e.toString().length+2,21);e=parseFloat(e.toPrecision(h)),s=this._root.language.translate("_percentPrefix"),r=this._root.language.translate("_percentSuffix"),s==""&&r==""&&(r="%")}else if(n.indexOf("%")!==-1){let h=Math.min(e.toString().length+2,21);e*=100,e=parseFloat(e.toPrecision(h)),r="%"}else if(n.indexOf("\u2030")!==-1){let h=Math.min(e.toString().length+3,21);e*=1e3,e=parseFloat(e.toPrecision(h)),r="\u2030"}if(n.indexOf("e")!==-1){let h;t.decimals.passive>=0?h=e.toExponential(t.decimals.passive).split("e"):h=e.toExponential().split("e"),e=Number(h[0]),r="e"+h[1],t.modSpacing&&(r=" "+r)}else if(t.decimals.passive===0)e=Math.round(e);else if(t.decimals.passive>0){let h=$h(e);if(h>0){let d=Math.pow(10,t.decimals.passive);e=Math.round(parseFloat((e*d).toFixed(h)))/d}}let A="",o=Qx(e).split("."),l=o[0];if(l.length<t.thousands.active&&(l=Array(t.thousands.active-l.length+1).join("0")+l),t.thousands.interval>0){let h=[],d=l.split("").reverse().join("");for(let u=0,g=l.length;u<=g;u+=t.thousands.interval){let y=d.substr(u,t.thousands.interval).split("").reverse().join("");y!==""&&h.unshift(y)}l=h.join(t.thousands.separator)}A+=l,o.length===1&&o.push("");let c=o[1];return c.length<t.decimals.active&&(c+=Array(t.decimals.active-c.length+1).join("0")),c!==""&&(A+=t.decimals.separator+c),A===""&&(A="0"),e!==0&&i&&n.indexOf("s")===-1&&(A="-"+A),s&&(A=s+A),r&&(A+=r),A}applyPrefix(e,t,i=!1){let s=e,r="",n="",A=!1,o=1;for(let l=0,c=t.length;l<c;l++)t[l].number<=e&&(t[l].number===0?s=0:(s=e/t[l].number,o=t[l].number),r=t[l].prefix,n=t[l].suffix,A=!0);return!A&&i&&t.length&&e!=0&&(s=e/t[0].number,r=t[0].prefix,n=t[0].suffix,A=!0),A&&(s=parseFloat(s.toPrecision(Math.min(o.toString().length+Math.floor(s).toString().replace(/[^0-9]*/g,"").length,21)))),[s,r,n]}escape(e){return e.replace("||",Ra)}unescape(e){return e.replace(Ra,"|")}};function nb(a,e){let t=0,i=0,s=1,r=0,n=0,A=0,o=0,l=0;return a.formatToParts(e).forEach(c=>{switch(c.type){case"year":t=+c.value;break;case"month":i=+c.value-1;break;case"day":s=+c.value;break;case"hour":r=+c.value;break;case"minute":n=+c.value;break;case"second":A=+c.value;break;case"fractionalSecond":o=+c.value;break;case"weekday":switch(c.value){case"Sun":l=0;break;case"Mon":l=1;break;case"Tue":l=2;break;case"Wed":l=3;break;case"Thu":l=4;break;case"Fri":l=5;break;case"Sat":l=6;break}}}),r===24&&(r=0),{year:t,month:i,day:s,hour:r,minute:n,second:A,millisecond:o,weekday:l}}function ab(a,e){let{year:t,month:i,day:s,hour:r,minute:n,second:A,millisecond:o}=nb(a,e);return Date.UTC(t,i,s,r,n,A,o)}var Mn=class{constructor(e,t){if(!t)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this.name=e,this._utc=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"UTC",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",weekday:"short",fractionalSecondDigits:3}),this._dtf=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",weekday:"short",fractionalSecondDigits:3})}static new(e){return new this(e,!0)}convertLocal(e){let t=this.offsetUTC(e),i=e.getTimezoneOffset(),s=new Date(e);s.setUTCMinutes(s.getUTCMinutes()-(t-i));let r=s.getTimezoneOffset();return i!=r&&s.setUTCMinutes(s.getUTCMinutes()+r-i),s}offsetUTC(e){let t=ab(this._utc,e),i=ab(this._dtf,e);return(t-i)/6e4}parseDate(e){return nb(this._dtf,e)}};var Hn=class extends nt{_setDefaults(){this._setDefault("capitalize",!0),this._setDefault("dateFormat","yyyy-MM-dd"),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(e,t,i=!1){(typeof t>"u"||t==="")&&(t=this.get("dateFormat","yyyy-MM-dd"));let s,r=e;if(Gs(t))try{let l=this.get("intlLocales");return l?new Intl.DateTimeFormat(l,t).format(r):new Intl.DateTimeFormat(void 0,t).format(r)}catch{return"Invalid"}let n=this.parseFormat(t),A=this._root.timezone,o=r;return A&&!this._root.utc&&!i&&(r=A.convertLocal(r)),W(r.getTime())?(s=this.applyFormat(r,n,i,o),this.get("capitalize")&&(s=s.replace(/^.{1}/,s.substr(0,1).toUpperCase())),s):"Invalid date"}applyFormat(e,t,i=!1,s){let r=t.template,n,A,o,l,c,h,d,u,g=e.getTime();this._root.utc&&!i?(n=e.getUTCFullYear(),A=e.getUTCMonth(),o=e.getUTCDay(),l=e.getUTCDate(),c=e.getUTCHours(),h=e.getUTCMinutes(),d=e.getUTCSeconds(),u=e.getUTCMilliseconds()):(n=e.getFullYear(),A=e.getMonth(),o=e.getDay(),l=e.getDate(),c=e.getHours(),h=e.getMinutes(),d=e.getSeconds(),u=e.getMilliseconds());for(let y=0,m=t.parts.length;y<m;y++){let b="";switch(t.parts[y]){case"G":b=this._t(n<0?"_era_bc":"_era_ad");break;case"yyyy":b=Math.abs(n).toString(),n<0&&(b+=this._t("_era_bc"));break;case"yyy":case"yy":case"y":b=Math.abs(n).toString().substr(-t.parts[y].length),n<0&&(b+=this._t("_era_bc"));break;case"YYYY":case"YYY":case"YY":case"Y":let B=Wx(e,this._root.utc);t.parts[y]=="YYYY"?b=Math.abs(B).toString():b=Math.abs(B).toString().substr(-t.parts[y].length),B<0&&(b+=this._t("_era_bc"));break;case"u":break;case"q":b=""+Math.ceil((e.getMonth()+1)/3);break;case"MMMMM":b=this._t(this._getMonth(A)).substr(0,1);break;case"MMMM":b=this._t(this._getMonth(A));break;case"MMM":b=this._t(this._getShortMonth(A));break;case"MM":b=Yt(A+1,2,"0");break;case"M":b=(A+1).toString();break;case"ww":b=Yt(Qn(e,this._root.utc),2,"0");break;case"w":b=Qn(e,this._root.utc).toString();break;case"W":b=zx(e,this._root.utc).toString();break;case"dd":b=Yt(l,2,"0");break;case"d":b=l.toString();break;case"DD":case"DDD":b=Yt(pf(e,this._root.utc).toString(),t.parts[y].length,"0");break;case"D":b=pf(e,this._root.utc).toString();break;case"F":break;case"g":break;case"t":b=this._root.language.translateFunc("_dateOrd").call(this,l);break;case"E":b=(o||7).toString();break;case"EE":b=Yt((o||7).toString(),2,"0");break;case"EEE":case"eee":b=this._t(this._getShortWeekday(o));break;case"EEEE":case"eeee":b=this._t(this._getWeekday(o));break;case"EEEEE":case"eeeee":b=this._t(this._getShortWeekday(o)).substr(0,1);break;case"e":case"ee":b=(o-(this._root.locale.firstDayOfWeek||1)+1).toString(),t.parts[y]=="ee"&&(b=Yt(b,2,"0"));break;case"a":c>=12?b=this._t("PM"):b=this._t("AM");break;case"aa":c>=12?b=this._t("P.M."):b=this._t("A.M.");break;case"aaa":c>=12?b=this._t("P"):b=this._t("A");break;case"h":b=Ro(c).toString();break;case"hh":b=Yt(Ro(c),2,"0");break;case"H":b=c.toString();break;case"HH":b=Yt(c,2,"0");break;case"K":b=Ro(c,0).toString();break;case"KK":b=Yt(Ro(c,0),2,"0");break;case"k":b=(c+1).toString();break;case"kk":b=Yt(c+1,2,"0");break;case"m":b=h.toString();break;case"mm":b=Yt(h,2,"0");break;case"s":b=d.toString();break;case"ss":b=Yt(d,2,"0");break;case"S":case"SS":case"SSS":b=Math.round(u/1e3*Math.pow(10,t.parts[y].length)).toString();break;case"x":b=g.toString();break;case"n":case"nn":case"nnn":b=Yt(u,t.parts[y].length,"0");break;case"z":b=Oo(s||e,!1,!1,this._root.utc,this._root.timezone?this._root.timezone.name:void 0).replace(/[+-]+[0-9]+$/,"");break;case"zz":b=Oo(s||e,!0,!1,this._root.utc,this._root.timezone?this._root.timezone.name:void 0);break;case"zzz":b=Oo(s||e,!1,!0,this._root.utc,this._root.timezone?this._root.timezone.name:void 0).replace(/[+-]+[0-9]+$/,"");break;case"zzzz":b=Oo(s||e,!0,!0,this._root.utc,this._root.timezone?this._root.timezone.name:void 0);break;case"Z":case"ZZ":let w=this._root.utc?"UTC":this._root.timezone;w instanceof Mn&&(w=w.name);let _=w?jx(w,s||e):e.getTimezoneOffset(),T=Math.abs(_)/60,Q=Math.floor(T),U=T*60-Q*60;this._root.utc&&(Q=0,U=0),t.parts[y]=="Z"?(b="GMT",b+=_>0?"-":"+",b+=Yt(Q,2)+":"+Yt(U,2)):(b=_>0?"-":"+",b+=Yt(Q,2)+Yt(U,2));break;case"i":b=e.toISOString();break;case"I":b=e.toUTCString();break}r=r.replace(Xs,b)}return r}parseFormat(e){let t={template:"",parts:[]},i=Di.chunk(e,!0);for(let s=0;s<i.length;s++){let r=i[s];if(r.type==="value"){if(r.text.match(/^date$/i)){let A=this.get("dateFormat","yyyy-MM-dd");Ur(A)||(A="yyyy-MM-dd"),r.text=A}let n=r.text.match(/G|yyyy|yyy|yy|y|YYYY|YYY|YY|Y|u|q|MMMMM|MMMM|MMM|MM|M|ww|w|W|dd|d|DDD|DD|D|F|g|EEEEE|EEEE|EEE|EE|E|eeeee|eeee|eee|ee|e|aaa|aa|a|hh|h|HH|H|KK|K|kk|k|mm|m|ss|s|SSS|SS|S|A|zzzz|zzz|zz|z|ZZ|Z|t|x|nnn|nn|n|i|I/g);if(n)for(let A=0;A<n.length;A++)t.parts.push(n[A]),r.text=r.text.replace(n[A],Xs)}t.template+=r.text}return t}_months(){return["January","February","March","April","May","June","July","August","September","October","November","December"]}_getMonth(e){return this._months()[e]}_shortMonths(){return["Jan","Feb","Mar","Apr","May(short)","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}_getShortMonth(e){return this._shortMonths()[e]}_weekdays(){return["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]}_getWeekday(e){return this._weekdays()[e]}_shortWeekdays(){return["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]}_getShortWeekday(e){return this._shortWeekdays()[e]}parse(e,t,i){if(typeof i>"u"&&(i=this._root.utc),e instanceof Date)return e;if(W(e))return new Date(e);if(t=="x")return new Date(parseInt(e));Ur(e)||(e=e.toString());let s,r="";t=SA(t),t=t.substr(0,e.length);let n=this.parseFormat(t),A={year:-1,year3:-1,year2:-1,year1:-1,month:-1,monthShort:-1,monthLong:-1,weekdayShort:-1,weekdayLong:-1,day:-1,yearDay:-1,week:-1,hourBase0:-1,hour12Base0:-1,hourBase1:-1,hour12Base1:-1,minute:-1,second:-1,millisecond:-1,millisecondDigits:-1,am:-1,zone:-1,timestamp:-1,iso:-1},o={year:1970,month:0,day:1,hour:0,minute:0,second:0,millisecond:0,timestamp:null,offset:0,utc:i},l=0,c=0;for(let u=0;u<n.parts.length;u++){switch(c=u+l+1,n.parts[u]){case"yyyy":case"YYYY":r+="([0-9]{4})",A.year=c;break;case"yyy":case"YYY":r+="([0-9]{3})",A.year3=c;break;case"yy":case"YY":r+="([0-9]{2})",A.year2=c;break;case"y":case"Y":r+="([0-9]{1})",A.year1=c;break;case"MMMM":r+="("+this.getStringList(this._months()).join("|")+")",A.monthLong=c;break;case"MMM":r+="("+this.getStringList(this._shortMonths()).join("|")+")",A.monthShort=c;break;case"MM":case"M":r+="([0-9]{2}|[0-9]{1})",A.month=c;break;case"ww":case"w":r+="([0-9]{2}|[0-9]{1})",A.week=c;break;case"dd":case"d":r+="([0-9]{2}|[0-9]{1})",A.day=c;break;case"DDD":case"DD":case"D":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",A.yearDay=c;break;case"dddd":r+="("+this.getStringList(this._weekdays()).join("|")+")",A.weekdayLong=c;break;case"ddd":r+="("+this.getStringList(this._shortWeekdays()).join("|")+")",A.weekdayShort=c;break;case"aaa":case"aa":case"a":r+="("+this.getStringList(["AM","PM","A.M.","P.M.","A","P"]).join("|")+")",A.am=c;break;case"hh":case"h":r+="([0-9]{2}|[0-9]{1})",A.hour12Base1=c;break;case"HH":case"H":r+="([0-9]{2}|[0-9]{1})",A.hourBase0=c;break;case"KK":case"K":r+="([0-9]{2}|[0-9]{1})",A.hour12Base0=c;break;case"kk":case"k":r+="([0-9]{2}|[0-9]{1})",A.hourBase1=c;break;case"mm":case"m":r+="([0-9]{2}|[0-9]{1})",A.minute=c;break;case"ss":case"s":r+="([0-9]{2}|[0-9]{1})",A.second=c;break;case"SSS":case"SS":case"S":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",A.millisecond=c,A.millisecondDigits=n.parts[u].length;break;case"nnn":case"nn":case"n":r+="([0-9]{3}|[0-9]{2}|[0-9]{1})",A.millisecond=c;break;case"x":r+="([0-9]{1,})",A.timestamp=c;break;case"Z":r+="GMT([-+]+[0-9]{2}:[0-9]{2})",A.zone=c;break;case"ZZ":r+="([\\-+]+[0-9]{2}[0-9]{2})",A.zone=c;break;case"i":r+="([0-9]{4})-?([0-9]{2})-?([0-9]{2})T?([0-9]{2}):?([0-9]{2}):?([0-9]{2})\\.?([0-9]{0,3})([zZ]|[+\\-][0-9]{2}:?[0-9]{2}|$)",A.iso=c,l+=7;break;case"G":case"YYYY":case"YYY":case"YY":case"Y":case"MMMMM":case"W":case"EEEEE":case"EEEE":case"EEE":case"EE":case"E":case"eeeee":case"eeee":case"eee":case"ee":case"e":case"zzzz":case"zzz":case"zz":case"z":case"t":l--;break}r+="[^0-9]*"}let h=new RegExp(r),d=e.match(h);if(d){if(A.year>-1&&(o.year=parseInt(d[A.year])),A.year3>-1){let u=parseInt(d[A.year3]);u+=1e3,o.year=u}if(A.year2>-1){let u=parseInt(d[A.year2]);u>50?u+=1e3:u+=2e3,o.year=u}if(A.year1>-1){let u=parseInt(d[A.year1]);u=Math.floor(new Date().getFullYear()/10)*10+u,o.year=u}if(A.monthLong>-1&&(o.month=this.resolveMonth(d[A.monthLong])),A.monthShort>-1&&(o.month=this.resolveShortMonth(d[A.monthShort])),A.month>-1&&(o.month=parseInt(d[A.month])-1),A.week>-1&&A.day===-1&&(o.month=0,o.day=Yx(parseInt(d[A.week]),o.year,1,i)),A.day>-1&&(o.day=parseInt(d[A.day])),A.yearDay>-1&&(o.month=0,o.day=parseInt(d[A.yearDay])),A.hourBase0>-1&&(o.hour=parseInt(d[A.hourBase0])),A.hourBase1>-1&&(o.hour=parseInt(d[A.hourBase1])-1),A.hour12Base0>-1){let u=parseInt(d[A.hour12Base0]);u==11&&(u=0),A.am>-1&&!this.isAm(d[A.am])&&(u+=12),o.hour=u}if(A.hour12Base1>-1){let u=parseInt(d[A.hour12Base1]);u==12&&(u=0),A.am>-1&&!this.isAm(d[A.am])&&(u+=12),o.hour=u}if(A.minute>-1&&(o.minute=parseInt(d[A.minute])),A.second>-1&&(o.second=parseInt(d[A.second])),A.millisecond>-1){let u=parseInt(d[A.millisecond]);A.millisecondDigits==2?u*=10:A.millisecondDigits==1&&(u*=100),o.millisecond=u}if(A.timestamp>-1){o.timestamp=parseInt(d[A.timestamp]);let u=new Date(o.timestamp);o.year=u.getUTCFullYear(),o.month=u.getUTCMonth(),o.day=u.getUTCDate(),o.hour=u.getUTCHours(),o.minute=u.getUTCMinutes(),o.second=u.getUTCSeconds(),o.millisecond=u.getUTCMilliseconds()}A.zone>-1&&(o.offset=this.resolveTimezoneOffset(new Date(o.year,o.month,o.day),d[A.zone])),A.iso>-1&&(o.year=Vi(d[A.iso+0]),o.month=Vi(d[A.iso+1])-1,o.day=Vi(d[A.iso+2]),o.hour=Vi(d[A.iso+3]),o.minute=Vi(d[A.iso+4]),o.second=Vi(d[A.iso+5]),o.millisecond=Vi(d[A.iso+6]),d[A.iso+7]=="Z"||d[A.iso+7]=="z"?o.utc=!0:d[A.iso+7]!=""&&(o.offset=this.resolveTimezoneOffset(new Date(o.year,o.month,o.day),d[A.iso+7]))),o.utc?s=new Date(Date.UTC(o.year,o.month,o.day,o.hour,o.minute,o.second,o.millisecond)):s=new Date(o.year,o.month,o.day,o.hour,o.minute+o.offset,o.second,o.millisecond)}else s=new Date(e);return s}resolveTimezoneOffset(e,t){if(t.match(/([+\-]?)([0-9]{2}):?([0-9]{2})/)){let s=t.match(/([+\-]?)([0-9]{2}):?([0-9]{2})/),r=s[1],n=s[2],A=s[3],o=parseInt(n)*60+parseInt(A);r=="+"&&(o*=-1);let l=(e||new Date).getTimezoneOffset();return o-l}return 0}resolveMonth(e){let t=this._months().indexOf(e);return t>-1||!this._root.language.isDefault()&&(t=this._root.language.translateAll(this._months()).indexOf(e),t>-1)?t:0}resolveShortMonth(e){let t=this._shortMonths().indexOf(e);return t>-1||(t=this._months().indexOf(e),t>-1)||this._root.language&&!this._root.language.isDefault()&&(t=this._root.language.translateAll(this._shortMonths()).indexOf(e),t>-1)?t:0}isAm(e){return this.getStringList(["AM","A.M.","A"]).indexOf(e.toUpperCase())>-1}getStringList(e){let t=[];for(let i=0;i<e.length;i++)this._root.language?t.push(gf(this._t(e[i]))):t.push(gf(e[i]));return t}};var ec=class extends nt{constructor(){super(...arguments),this._unitAliases={Y:"y",D:"d",H:"h",K:"h",k:"h",n:"S"}}_setDefaults(){let e="_duration_millisecond",t="_duration_second",i="_duration_minute",s="_duration_hour",r="_duration_day",n="_duration_week",A="_duration_month",o="_duration_year",l="_second",c="_minute",h="_hour",d="_day",u="_week",g="_week",y="_year";this._setDefault("negativeBase",0),this._setDefault("baseUnit","second"),this._setDefault("durationFormats",{millisecond:{millisecond:this._t(e),second:this._t(e+l),minute:this._t(e+c),hour:this._t(e+h),day:this._t(e+d),week:this._t(e+u),month:this._t(e+g),year:this._t(e+y)},second:{second:this._t(t),minute:this._t(t+c),hour:this._t(t+h),day:this._t(t+d),week:this._t(t+u),month:this._t(t+g),year:this._t(t+y)},minute:{minute:this._t(i),hour:this._t(i+h),day:this._t(i+d),week:this._t(i+u),month:this._t(i+g),year:this._t(i+y)},hour:{hour:this._t(s),day:this._t(s+d),week:this._t(s+u),month:this._t(s+g),year:this._t(s+y)},day:{day:this._t(r),week:this._t(r+u),month:this._t(r+g),year:this._t(r+y)},week:{week:this._t(n),month:this._t(n+g),year:this._t(n+y)},month:{month:this._t(A),year:this._t(A+y)},year:{year:this._t(o)}}),super._setDefaults()}_beforeChanged(){super._beforeChanged()}format(e,t,i){let s=i||this.get("baseUnit");(typeof t>"u"||t==="")&&(this.get("durationFormat")!=null?t=this.get("durationFormat"):t=this.getFormat(Vi(e),void 0,s)),t=SA(t);let r=this.parseFormat(t,s),n=Number(e),A;n>this.get("negativeBase")?A=r.positive:n<this.get("negativeBase")?A=r.negative:A=r.zero;let o=this.applyFormat(n,A);return A.color!==""&&(o="["+A.color+"]"+o+"[/]"),o}parseFormat(e,t){let i=t||this.get("baseUnit"),s={positive:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1},negative:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1},zero:{color:"",template:"",parts:[],source:"",baseUnit:i,parsed:!1,absolute:!1}};e=e.replace("||",Ra);let r=e.split("|");return s.positive.source=r[0],typeof r[2]>"u"?s.zero=s.positive:s.zero.source=r[2],typeof r[1]>"u"?s.negative=s.positive:s.negative.source=r[1],Ve(s,(n,A)=>{if(A.parsed)return;let o=A.source,l=[];l=A.source.match(/^\[([^\]]*)\]/),l&&l.length&&l[0]!==""&&(o=A.source.substr(l[0].length),A.color=l[1]);let c=Di.chunk(o,!0);for(let h=0;h<c.length;h++){let d=c[h];if(d.text=d.text.replace(Ra,"|"),d.type==="value"){d.text.match(/[yYMdDwhHKkmsSn]+a/)&&(A.absolute=!0,d.text=d.text.replace(/([yYMdDwhHKkmsSn]+)a/,"$1"));let u=d.text.match(/y+|Y+|M+|d+|D+|w+|h+|H+|K+|k+|m+|s+|S+|n+/g);if(u)for(let g=0;g<u.length;g++)u[g]==null&&(u[g]=this._unitAliases[u[g]]),A.parts.push(u[g]),d.text=d.text.replace(u[g],Xs)}A.template+=d.text}A.parsed=!0}),s}applyFormat(e,t){let i=!t.absolute&&e<this.get("negativeBase");e=Math.abs(e);let s=this.toTimeStamp(e,t.baseUnit),r=t.template,n={millisecond:0,second:0,minute:0,hour:0,day:0,week:0,month:0,year:0};for(let A=0,o=t.parts.length;A<o;A++){let l=t.parts[A],c=this._toTimeUnit(l.substr(0,1)),h,d=this._getUnitValue(c);A<o-1?h=Math.floor(s/d):h=Math.round(s/d),n[c]+=h,s-=h*d}Ve(n,(A,o)=>{A=="millisecond"&&o==1e3?(n.second++,n.millisecond=0):A=="second"&&o==60?(n.minute++,n.second=0):A=="minute"&&o==60?(n.hour++,n.minute=0):A=="hour"&&o==24?(n.day++,n.hour=0):A=="day"&&o==7&&t.parts.indexOf("w")!==-1?(n.week++,n.day=0):A=="day"&&o==30?(n.month++,n.day=0):A=="month"&&o==12&&(n.year++,n.month=0)});for(let A=0,o=t.parts.length;A<o;A++){let l=t.parts[A],c=this._toTimeUnit(l.substr(0,1)),h=l.length;r=r.replace(Xs,Yt(n[c],h,"0"))}return i&&(r="-"+r),r}toTimeStamp(e,t){return e*this._getUnitValue(t)}_toTimeUnit(e){switch(e){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year"}}getFormat(e,t,i){if(this.get("durationFormat")!=null)return this.get("durationFormat");if(i||(i=this.get("baseUnit")),t!=null&&e!=t){e=Math.abs(e),t=Math.abs(t);let s=this.getValueUnit(Math.max(e,t),i);return this.get("durationFormats")[i][s]}else{let s=this.getValueUnit(e,i);return this.get("durationFormats")[i][s]}}getValueUnit(e,t){t||(t=this.get("baseUnit"));let i,s=this.getMilliseconds(e,t);return Px(this._getUnitValues(),(r,n)=>{if(r==t||i){if(s/n<=1)return i||(i=r),!1;i=r}return!0}),i}getMilliseconds(e,t){return t||(t=this.get("baseUnit")),e*this._getUnitValue(t)}_getUnitValue(e){return this._getUnitValues()[e]}_getUnitValues(){return{millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5,week:6048e5,month:2592e6,year:31536e6}}};var tc={firstDayOfWeek:1,_decimalSeparator:".",_thousandSeparator:",",_percentPrefix:null,_percentSuffix:"%",_big_number_suffix_3:"k",_big_number_suffix_6:"M",_big_number_suffix_9:"G",_big_number_suffix_12:"T",_big_number_suffix_15:"P",_big_number_suffix_18:"E",_big_number_suffix_21:"Z",_big_number_suffix_24:"Y",_small_number_suffix_3:"m",_small_number_suffix_6:"\u03BC",_small_number_suffix_9:"n",_small_number_suffix_12:"p",_small_number_suffix_15:"f",_small_number_suffix_18:"a",_small_number_suffix_21:"z",_small_number_suffix_24:"y",_byte_suffix_B:"B",_byte_suffix_KB:"KB",_byte_suffix_MB:"MB",_byte_suffix_GB:"GB",_byte_suffix_TB:"TB",_byte_suffix_PB:"PB",_date:"yyyy-MM-dd",_date_millisecond:"mm:ss SSS",_date_millisecond_full:"HH:mm:ss SSS",_date_second:"HH:mm:ss",_date_second_full:"HH:mm:ss",_date_minute:"HH:mm",_date_minute_full:"HH:mm - MMM dd, yyyy",_date_hour:"HH:mm",_date_hour_short:"HH",_date_hour_full:"HH:mm - MMM dd, yyyy",_date_day:"MMM dd",_date_day_full:"MMM dd, yyyy",_date_week:"ww",_date_week_full:"MMM dd, yyyy",_date_month:"MMM",_date_month_full:"MMM, yyyy",_date_year:"yyyy",_duration_millisecond:"SSS",_duration_millisecond_second:"ss.SSS",_duration_millisecond_minute:"mm:ss SSS",_duration_millisecond_hour:"hh:mm:ss SSS",_duration_millisecond_day:"d'd' mm:ss SSS",_duration_millisecond_week:"d'd' mm:ss SSS",_duration_millisecond_month:"M'm' dd'd' mm:ss SSS",_duration_millisecond_year:"y'y' MM'm' dd'd' mm:ss SSS",_duration_second:"ss",_duration_second_minute:"mm:ss",_duration_second_hour:"hh:mm:ss",_duration_second_day:"d'd' hh:mm:ss",_duration_second_week:"d'd' hh:mm:ss",_duration_second_month:"M'm' dd'd' hh:mm:ss",_duration_second_year:"y'y' MM'm' dd'd' hh:mm:ss",_duration_minute:"mm",_duration_minute_hour:"hh:mm",_duration_minute_day:"d'd' hh:mm",_duration_minute_week:"d'd' hh:mm",_duration_minute_month:"M'm' dd'd' hh:mm",_duration_minute_year:"y'y' MM'm' dd'd' hh:mm",_duration_hour:"hh'h'",_duration_hour_day:"d'd' hh'h'",_duration_hour_week:"d'd' hh'h'",_duration_hour_month:"M'm' dd'd' hh'h'",_duration_hour_year:"y'y' MM'm' dd'd' hh'h'",_duration_day:"d'd'",_duration_day_week:"d'd'",_duration_day_month:"M'm' dd'd'",_duration_day_year:"y'y' MM'm' dd'd'",_duration_week:"w'w'",_duration_week_month:"w'w'",_duration_week_year:"w'w'",_duration_month:"M'm'",_duration_month_year:"y'y' MM'm'",_duration_year:"y'y'",_era_ad:"AD",_era_bc:"BC",A:"",P:"",AM:"",PM:"","A.M.":"","P.M.":"",January:"",February:"",March:"",April:"",May:"",June:"",July:"",August:"",September:"",October:"",November:"",December:"",Jan:"",Feb:"",Mar:"",Apr:"","May(short)":"May",Jun:"",Jul:"",Aug:"",Sep:"",Oct:"",Nov:"",Dec:"",Sunday:"",Monday:"",Tuesday:"",Wednesday:"",Thursday:"",Friday:"",Saturday:"",Sun:"",Mon:"",Tue:"",Wed:"",Thu:"",Fri:"",Sat:"",_dateOrd:function(a){let e="th";if(a<11||a>13)switch(a%10){case 1:e="st";break;case 2:e="nd";break;case 3:e="rd";break}return e},"Zoom Out":"",Play:"",Stop:"",Legend:"","Press ENTER to toggle":"",Loading:"",Home:"",Chart:"","Serial chart":"","X/Y chart":"","Pie chart":"","Gauge chart":"","Radar chart":"","Sankey diagram":"","Flow diagram":"","Chord diagram":"","TreeMap chart":"","Force directed tree":"","Sliced chart":"",Series:"","Candlestick Series":"","OHLC Series":"","Column Series":"","Line Series":"","Pie Slice Series":"","Funnel Series":"","Pyramid Series":"","X/Y Series":"",Map:"","Press ENTER to zoom in":"","Press ENTER to zoom out":"","Use arrow keys to zoom in and out":"","Use plus and minus keys on your keyboard to zoom in and out":"",Export:"",Image:"",Data:"",Print:"","Press ENTER or use arrow keys to navigate":"","Press ENTER to open":"","Press ENTER to print.":"","Press ENTER to export as %1.":"","(Press ESC to close this message)":"","Image Export Complete":"","Export operation took longer than expected. Something might have gone wrong.":"","Saved from":"",PNG:"",JPG:"",GIF:"",SVG:"",PDF:"",JSON:"",CSV:"",XLSX:"",HTML:"","Use TAB to select grip buttons or left and right arrows to change selection":"","Use left and right arrows to move selection":"","Use left and right arrows to move left selection":"","Use left and right arrows to move right selection":"","Use TAB select grip buttons or up and down arrows to change selection":"","Use up and down arrows to move selection":"","Use up and down arrows to move lower selection":"","Use up and down arrows to move upper selection":"","From %1 to %2":"","From %1":"","To %1":"","No parser available for file: %1":"","Error parsing file: %1":"","Unable to load file: %1":"","Invalid date":"",Close:"",Minimize:"",Confirm:""};var ic=class extends nt{_setDefaults(){this.setPrivate("defaultLocale",tc),super._setDefaults()}translate(e,t,...i){t||(t=this._root.locale||this.getPrivate("defaultLocale"));let s=e,r=t[e];if(r===null)s="";else if(r!=null)r&&(s=r);else if(t!==this.getPrivate("defaultLocale"))return this.translate(e,this.getPrivate("defaultLocale"),...i);if(i.length)for(let n=i.length,A=0;A<n;++A)s=s.split("%"+(A+1)).join(i[A]);return s}translateAny(e,t,...i){return this.translate(e,t,...i)}setTranslationAny(e,t,i){let s=i||this._root.locale;s[e]=t}setTranslationsAny(e,t){Ve(e,(i,s)=>{this.setTranslationAny(i,s,t)})}translateEmpty(e,t,...i){let s=this.translate(e,t,...i);return s==e?"":s}translateFunc(e,t){return this._root.locale[e]?this._root.locale[e]:t!==this.getPrivate("defaultLocale")?this.translateFunc(e,this.getPrivate("defaultLocale")):()=>""}translateAll(e,t){return this.isDefault()?e:Do(e,i=>this.translate(i,t))}isDefault(){return this.getPrivate("defaultLocale")===this._root.locale}};var _s=class{constructor(e,t){if(this._rules={},this._root=e,!t)throw new Error("You cannot use `new Class()`, instead use `Class.new()`")}static new(e){let t=new this(e,!0);return t.setupDefaultRules(),t}setupDefaultRules(){}_lookupRules(e){return this._rules[e]}ruleRaw(e,t=[]){let i=this._rules[e];i||(i=this._rules[e]=[]),t.sort(Bs);let{index:s,found:r}=Eo(i,n=>{let A=Bs(n.tags.length,t.length);return A===0?Yh(n.tags,t,Bs):A});if(r)return i[s].template;{let n=Ne.new({});return i.splice(s,0,{tags:t,template:n}),n}}rule(e,t=[]){return this.ruleRaw(e,t)}};function ve(a,e,t,i){a.set(e,t.get(i)),t.on(i,s=>{a.set(e,s)})}var sc=class extends _s{setupDefaultRules(){super.setupDefaultRules();let e=this._root.language,t=this._root.interfaceColors,i=this._root.horizontalLayout,s=this._root.verticalLayout,r=this.rule.bind(this);r("InterfaceColors").setAll({stroke:we.fromHex(15066597),fill:we.fromHex(15987699),primaryButton:we.fromHex(6788316),primaryButtonHover:we.fromHex(6779356),primaryButtonDown:we.fromHex(6872182),primaryButtonActive:we.fromHex(6872182),primaryButtonDisabled:we.fromHex(14342874),primaryButtonTextDisabled:we.fromHex(16777215),primaryButtonText:we.fromHex(16777215),primaryButtonStroke:we.fromHex(16777215),secondaryButton:we.fromHex(14277081),secondaryButtonHover:we.fromHex(10724259),secondaryButtonDown:we.fromHex(9276813),secondaryButtonActive:we.fromHex(15132390),secondaryButtonText:we.fromHex(0),secondaryButtonStroke:we.fromHex(16777215),grid:we.fromHex(0),background:we.fromHex(16777215),alternativeBackground:we.fromHex(0),text:we.fromHex(0),alternativeText:we.fromHex(16777215),disabled:we.fromHex(11382189),positive:we.fromHex(5288704),negative:we.fromHex(11730944)});{let n=r("ColorSet");n.setAll({passOptions:{hue:.05,saturation:0,lightness:0},colors:[we.fromHex(6797276)],step:1,reuse:!1,startIndex:0}),n.setPrivate("currentStep",0),n.setPrivate("currentPass",0)}r("Entity").setAll({stateAnimationDuration:0,stateAnimationEasing:fa(dr)}),r("Component").setAll({interpolationDuration:0,interpolationEasing:fa(dr)}),r("Sprite").setAll({visible:!0,scale:1,opacity:1,rotation:0,position:"relative",tooltipX:ye,tooltipY:ye,tooltipPosition:"fixed",isMeasured:!0}),r("Sprite").states.create("default",{visible:!0,opacity:1}),r("Container").setAll({interactiveChildren:!0,setStateOnChildren:!1}),r("Graphics").setAll({strokeWidth:1}),r("Chart").setAll({width:se,height:se,interactiveChildren:!1}),r("ZoomableContainer").setAll({width:se,height:se,wheelable:!0,pinchZoom:!0,maxZoomLevel:32,minZoomLevel:1,zoomStep:2,animationEasing:fa(dr),animationDuration:600,maxPanOut:.4}),r("Sprite",["horizontal","center"]).setAll({centerX:ye,x:ye}),r("Sprite",["vertical","center"]).setAll({centerY:ye,y:ye}),r("Container",["horizontal","layout"]).setAll({layout:i}),r("Container",["vertical","layout"]).setAll({layout:s}),r("Pattern").setAll({repetition:"repeat",width:50,height:50,rotation:0,fillOpacity:1}),r("LinePattern").setAll({gap:6,colorOpacity:1,width:49,height:49}),r("RectanglePattern").setAll({gap:6,checkered:!1,centered:!0,maxWidth:5,maxHeight:5,width:48,height:48,strokeWidth:0}),r("CirclePattern").setAll({gap:5,checkered:!1,centered:!1,radius:3,strokeWidth:0,width:45,height:45}),r("GrainPattern").setAll({width:200,height:200,colors:[we.fromHex(0)],size:1,horizontalGap:0,verticalGap:0,density:1,minOpacity:0,maxOpacity:.2});{let n=r("PatternSet");n.setAll({step:1}),ve(n,"color",t,"stroke")}r("LinearGradient").setAll({rotation:90}),r("Legend").setAll({fillField:"fill",strokeField:"stroke",nameField:"name",layout:js.new(this._root,{}),layer:30,clickTarget:"itemContainer"}),r("Container",["legend","item","itemcontainer"]).setAll({paddingLeft:5,paddingRight:5,paddingBottom:5,paddingTop:5,layout:i,setStateOnChildren:!0,interactiveChildren:!1,ariaChecked:!0,focusable:!0,ariaLabel:e.translate("Press ENTER to toggle"),role:"checkbox"});{let n=r("Rectangle",["legend","item","background"]);n.setAll({fillOpacity:0}),ve(n,"fill",t,"background")}r("Container",["legend","marker"]).setAll({setStateOnChildren:!0,centerY:ye,paddingLeft:0,paddingRight:0,paddingBottom:0,paddingTop:0,width:18,height:18}),r("RoundedRectangle",["legend","marker","rectangle"]).setAll({width:se,height:se,cornerRadiusBL:3,cornerRadiusTL:3,cornerRadiusBR:3,cornerRadiusTR:3});{let n=r("RoundedRectangle",["legend","marker","rectangle"]).states.create("disabled",{});ve(n,"fill",t,"disabled"),ve(n,"stroke",t,"disabled")}r("Label",["legend","label"]).setAll({centerY:ye,marginLeft:5,paddingRight:0,paddingLeft:0,paddingTop:0,paddingBottom:0,populateText:!0});{let n=r("Label",["legend","label"]).states.create("disabled",{});ve(n,"fill",t,"disabled")}r("Label",["legend","value","label"]).setAll({centerY:ye,marginLeft:5,paddingRight:0,paddingLeft:0,paddingTop:0,paddingBottom:0,width:50,centerX:se,populateText:!0});{let n=r("Label",["legend","value","label"]).states.create("disabled",{});ve(n,"fill",t,"disabled")}r("HeatLegend").setAll({stepCount:1}),r("RoundedRectangle",["heatlegend","marker"]).setAll({cornerRadiusTR:0,cornerRadiusBR:0,cornerRadiusTL:0,cornerRadiusBL:0}),r("RoundedRectangle",["vertical","heatlegend","marker"]).setAll({height:se,width:15}),r("RoundedRectangle",["horizontal","heatlegend","marker"]).setAll({width:se,height:15}),r("HeatLegend",["vertical"]).setAll({height:se}),r("HeatLegend",["horizontal"]).setAll({width:se}),r("Label",["heatlegend","start"]).setAll({paddingLeft:5,paddingRight:5,paddingTop:5,paddingBottom:5}),r("Label",["heatlegend","end"]).setAll({paddingLeft:5,paddingRight:5,paddingTop:5,paddingBottom:5});{let n=r("Label");n.setAll({paddingTop:8,paddingBottom:8,paddingLeft:10,paddingRight:10,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',fontSize:"1em",populateText:!1}),ve(n,"fill",t,"text")}r("RadialLabel").setAll({textType:"regular",centerY:ye,centerX:ye,inside:!1,radius:0,baseRadius:se,orientation:"auto",textAlign:"center"}),r("EditableLabel").setAll({editOn:"click",themeTags:["editablelabel"],multiLine:!0}),r("RoundedRectangle",["editablelabel","background"]).setAll({fillOpacity:0,fill:we.fromHex(0),cornerRadiusBL:3,cornerRadiusBR:3,cornerRadiusTL:3,cornerRadiusTR:3,strokeOpacity:0,stroke:we.fromHex(0)}),r("RoundedRectangle",["editablelabel","background"]).states.create("active",{strokeOpacity:.2}),r("RoundedRectangle").setAll({cornerRadiusTL:8,cornerRadiusBL:8,cornerRadiusTR:8,cornerRadiusBR:8}),r("PointedRectangle").setAll({pointerBaseWidth:15,pointerLength:10,cornerRadius:8}),r("Slice").setAll({shiftRadius:0,dRadius:0,dInnerRadius:0});{let n=r("Tick");n.setAll({strokeOpacity:.15,isMeasured:!1,length:4.5,position:"absolute",crisp:!0}),ve(n,"stroke",t,"grid")}r("Bullet").setAll({locationX:.5,locationY:.5}),r("Tooltip").setAll({position:"absolute",getFillFromSprite:!0,getStrokeFromSprite:!1,autoTextColor:!0,paddingTop:9,paddingBottom:8,paddingLeft:10,paddingRight:10,marginBottom:5,pointerOrientation:"vertical",centerX:ye,centerY:ye,animationEasing:fa(dr),exportable:!1}),r("Tooltip",["system"]).setAll({pointerOrientation:"horizontal",paddingTop:4,paddingRight:7,paddingBottom:4,paddingLeft:7});{let n=r("PointedRectangle",["tooltip","system","background"]);n.setAll({strokeOpacity:.3}),ve(n,"fill",t,"background"),ve(n,"stroke",t,"grid")}r("Label",["tooltip","system"]).setAll({fontSize:12,fill:t.get("background")}),r("Polygon").setAll({animationEasing:fa(dr)}),r("Link").setAll({cornerRadius:8,setStateOnChildren:!0});{let n=r("OrthogonalLine",["link","line"]);n.setAll({isMeasured:!1,crisp:!0});let A=n.states.create("active",{strokeWidth:2});ve(A,"stroke",t,"negative")}r("OrthogonalLine",["link","hit"]).setAll({strokeWidth:10,opacity:0,strokeOpacity:0});{let n=r("OrthogonalLine");n.setAll({strokeWidth:1,strokeOpacity:1,cornerRadius:10}),ve(n,"stroke",t,"grid")}{let n=r("Triangle",["link"]);n.setAll({width:14,height:10,centerY:0}),ve(n,"fill",t,"grid"),ve(n,"stroke",t,"grid"),n.states.create("default",{stateAnimationDuration:0});let A=n.states.create("active",{stateAnimationDuration:0,stroke:$i(16777215),strokeWidth:2});A.set("draw",o=>{o.arc(0,0,11,0,Math.PI*2),o.moveTo(-4,-4),o.lineTo(4,4),o.moveTo(4,-4),o.lineTo(-4,4)}),ve(A,"fill",t,"negative")}r("PointedRectangle",["tooltip","background"]).setAll({strokeOpacity:.9,cornerRadius:4,pointerLength:4,pointerBaseWidth:8,fillOpacity:.9,stroke:we.fromHex(16777215)});{let n=r("Label",["tooltip"]);n.setAll({role:"tooltip",populateText:!0,paddingRight:0,paddingTop:0,paddingLeft:0,paddingBottom:0}),ve(n,"fill",t,"alternativeText")}r("Button").setAll({paddingTop:8,paddingBottom:8,paddingLeft:10,paddingRight:10,interactive:!0,layout:i,interactiveChildren:!1,setStateOnChildren:!0,focusable:!0}),r("Button").states.create("hover",{}),r("Button").states.create("down",{stateAnimationDuration:0}),r("Button").states.create("active",{}),r("Button").states.create("disabled",{forceInactive:!0});{let n=r("RoundedRectangle",["button","background"]);ve(n,"fill",t,"primaryButton"),ve(n,"stroke",t,"primaryButtonStroke")}{let n=r("RoundedRectangle",["button","background"]).states.create("hover",{});ve(n,"fill",t,"primaryButtonHover")}{let n=r("RoundedRectangle",["button","background"]).states.create("down",{stateAnimationDuration:0});ve(n,"fill",t,"primaryButtonDown")}{let n=r("RoundedRectangle",["button","background"]).states.create("active",{});ve(n,"fill",t,"primaryButtonActive")}{let n=r("RoundedRectangle",["button","background"]).states.create("disabled",{});ve(n,"fill",t,"primaryButtonDisabled")}{let n=r("Graphics",["button","icon"]).states.create("disabled",{});ve(n,"fill",t,"primaryButtonTextDisabled")}{let n=r("Label",["button"]).states.create("disabled",{});ve(n,"fill",t,"primaryButtonTextDisabled")}{let n=r("Graphics",["button","icon"]);n.setAll({forceInactive:!0}),ve(n,"stroke",t,"primaryButtonText")}{let n=r("Label",["button"]);ve(n,"fill",t,"primaryButtonText")}r("ConfirmButton").setAll({toggleKey:"active",setStateOnChildren:!0,label:Ze.new(this._root,{text:e.translate("Confirm"),forceHidden:!0})});{let n=r("RoundedRectangle",["button","background","confirm"]).states.create("active",{});ve(n,"fill",t,"negative")}r("Label",["button","confirm"]).setAll({paddingTop:0,paddingBottom:0,paddingRight:3,paddingLeft:5}),r("Label",["button","confirm"]).states.create("default",{stateAnimationDuration:0}),r("Label",["button","confirm"]).states.create("active",{forceHidden:!1,stateAnimationDuration:0});{let n=r("Graphics",["icon","confirm","button"]);n.setAll({stateAnimationDuration:0}),n.states.create("default",{stateAnimationDuration:0}),ve(n,"stroke",t,"primaryButtonText")}{let n=r("Graphics",["icon","confirm","button"]).states.create("active",{svgPath:"M -5 1 L 0 6 L 8 -5",strokeWidth:2});ve(n,"stroke",t,"primaryButtonText")}{let n=r("Graphics",["icon","confirm","button","secondary"]).states.create("active",{});ve(n,"stroke",t,"primaryButtonText")}{let n=r("RoundedRectangle",["button","background","confirm","secondary"]).states.create("active",{fillOpacity:1});ve(n,"fill",t,"negative")}{let n=r("RoundedRectangle",["button","background","confirm","secondary"]).states.create("hoverActive",{fillOpacity:1});ve(n,"fill",t,"negative")}r("Button",["button","confirm"]).states.create("hoverActive",{}),r("Button",["zoom"]).setAll({paddingTop:18,paddingBottom:18,paddingLeft:12,paddingRight:12,centerX:46,centerY:-10,y:0,x:se,role:"button",ariaLabel:e.translate("Zoom Out"),layer:30});{let n=r("RoundedRectangle",["background","button","zoom"]);n.setAll({cornerRadiusBL:40,cornerRadiusBR:40,cornerRadiusTL:40,cornerRadiusTR:40}),ve(n,"fill",t,"primaryButton")}{let n=r("RoundedRectangle",["background","button","zoom"]).states.create("hover",{});ve(n,"fill",t,"primaryButtonHover")}{let n=r("RoundedRectangle",["background","button","zoom"]).states.create("down",{stateAnimationDuration:0});ve(n,"fill",t,"primaryButtonDown")}{let n=r("Graphics",["icon","button","zoom"]);n.setAll({crisp:!0,strokeOpacity:.7,draw:A=>{A.moveTo(0,0),A.lineTo(12,0)}}),ve(n,"stroke",t,"primaryButtonText")}r("Button",["resize"]).setAll({paddingTop:9,paddingBottom:9,paddingLeft:13,paddingRight:13,draggable:!0,centerX:ye,centerY:ye,position:"absolute",role:"slider",ariaValueMin:"0",ariaValueMax:"100",ariaLabel:e.translate("Use up and down arrows to move selection")});{let n=r("RoundedRectangle",["background","resize","button"]);n.setAll({cornerRadiusBL:40,cornerRadiusBR:40,cornerRadiusTL:40,cornerRadiusTR:40}),ve(n,"fill",t,"secondaryButton"),ve(n,"stroke",t,"secondaryButtonStroke")}{let n=r("RoundedRectangle",["background","resize","button"]).states.create("hover",{});ve(n,"fill",t,"secondaryButtonHover")}{let n=r("RoundedRectangle",["background","resize","button"]).states.create("down",{stateAnimationDuration:0});ve(n,"fill",t,"secondaryButtonDown")}{let n=r("Graphics",["resize","button","icon"]);n.setAll({interactive:!1,crisp:!0,strokeOpacity:.5,draw:A=>{A.moveTo(0,.5),A.lineTo(0,12.5),A.moveTo(4,.5),A.lineTo(4,12.5)}}),ve(n,"stroke",t,"secondaryButtonText")}r("Button",["resize","vertical"]).setAll({rotation:90,cursorOverStyle:"ns-resize"}),r("Button",["resize","horizontal"]).setAll({cursorOverStyle:"ew-resize"}),r("Button",["play"]).setAll({paddingTop:13,paddingBottom:13,paddingLeft:14,paddingRight:14,ariaLabel:e.translate("Play"),toggleKey:"active"});{let n=r("RoundedRectangle",["play","background"]);n.setAll({strokeOpacity:.5,cornerRadiusBL:100,cornerRadiusBR:100,cornerRadiusTL:100,cornerRadiusTR:100}),ve(n,"fill",t,"primaryButton")}{let n=r("Graphics",["play","icon"]);n.setAll({stateAnimationDuration:0,dx:1,draw:A=>{A.moveTo(0,-5),A.lineTo(8,0),A.lineTo(0,5),A.lineTo(0,-5)}}),ve(n,"fill",t,"primaryButtonText")}r("Graphics",["play","icon"]).states.create("default",{stateAnimationDuration:0}),r("Graphics",["play","icon"]).states.create("active",{stateAnimationDuration:0,draw:n=>{n.moveTo(-4,-5),n.lineTo(-1,-5),n.lineTo(-1,5),n.lineTo(-4,5),n.lineTo(-4,-5),n.moveTo(4,-5),n.lineTo(1,-5),n.lineTo(1,5),n.lineTo(4,5),n.lineTo(4,-5)}}),r("Button",["switch"]).setAll({paddingTop:4,paddingBottom:4,paddingLeft:4,paddingRight:4,ariaLabel:e.translate("Press ENTER to toggle"),toggleKey:"active",width:40,height:24,layout:null});{let n=r("RoundedRectangle",["switch","background"]);n.setAll({strokeOpacity:.5,cornerRadiusBL:100,cornerRadiusBR:100,cornerRadiusTL:100,cornerRadiusTR:100}),ve(n,"fill",t,"primaryButton")}{let n=r("Circle",["switch","icon"]);n.setAll({radius:8,centerY:0,centerX:0,dx:0}),ve(n,"fill",t,"primaryButtonText")}r("Graphics",["switch","icon"]).states.create("active",{dx:16}),r("Scrollbar").setAll({start:0,end:1,layer:30,animationEasing:fa(dr)}),r("Scrollbar",["vertical"]).setAll({marginRight:13,marginLeft:13,minWidth:12,height:se}),r("Scrollbar",["horizontal"]).setAll({marginTop:13,marginBottom:13,minHeight:12,width:se}),this.rule("Button",["scrollbar"]).setAll({exportable:!1});{let n=r("RoundedRectangle",["scrollbar","main","background"]);n.setAll({cornerRadiusTL:8,cornerRadiusBL:8,cornerRadiusTR:8,cornerRadiusBR:8,fillOpacity:.8}),ve(n,"fill",t,"fill")}{let n=r("RoundedRectangle",["scrollbar","thumb"]);n.setAll({role:"slider",ariaLive:"polite",position:"absolute",draggable:!0}),ve(n,"fill",t,"secondaryButton")}{let n=r("RoundedRectangle",["scrollbar","thumb"]).states.create("hover",{});ve(n,"fill",t,"secondaryButtonHover")}{let n=r("RoundedRectangle",["scrollbar","thumb"]).states.create("down",{stateAnimationDuration:0});ve(n,"fill",t,"secondaryButtonDown")}r("RoundedRectangle",["scrollbar","thumb","vertical"]).setAll({x:ye,width:se,centerX:ye,ariaLabel:e.translate("Use up and down arrows to move selection")}),r("RoundedRectangle",["scrollbar","thumb","horizontal"]).setAll({y:ye,centerY:ye,height:se,ariaLabel:e.translate("Use left and right arrows to move selection")});{let n=r("PointedRectangle",["axis","tooltip","background"]);n.setAll({cornerRadius:0}),ve(n,"fill",t,"alternativeBackground")}r("Label",["axis","tooltip"]).setAll({role:void 0}),r("Label",["axis","tooltip","y"]).setAll({textAlign:"right"}),r("Label",["axis","tooltip","y","opposite"]).setAll({textAlign:"left"}),r("Label",["axis","tooltip","x"]).setAll({textAlign:"center"}),r("Tooltip",["categoryaxis"]).setAll({labelText:"{category}"}),r("Star").setAll({spikes:5,innerRadius:5,radius:10}),r("Tooltip",["stock"]).setAll({paddingTop:6,paddingBottom:5,paddingLeft:7,paddingRight:7}),r("Tooltip",["indicator"]).setAll({forceHidden:!0}),r("PointedRectangle",["tooltip","stock","axis"]).setAll({pointerLength:0,pointerBaseWidth:0,cornerRadius:3}),r("Label",["tooltip","stock"]).setAll({fontSize:"0.8em"}),r("SpriteResizer").setAll({rotationStep:10,isMeasured:!1}),r("Container",["resizer","grip"]).states.create("hover",{});{let n=r("RoundedRectangle",["resizer","grip"]);n.setAll({strokeOpacity:.7,strokeWidth:1,fillOpacity:1,width:12,height:12}),ve(n,"fill",t,"background"),ve(n,"stroke",t,"alternativeBackground")}{let n=r("RoundedRectangle",["resizer","grip","outline"]);n.setAll({strokeOpacity:0,fillOpacity:0,width:20,height:20}),n.states.create("hover",{fillOpacity:.3}),ve(n,"fill",t,"alternativeBackground")}r("RoundedRectangle",["resizer","grip","left"]).setAll({cornerRadiusBL:0,cornerRadiusBR:0,cornerRadiusTL:0,cornerRadiusTR:0}),r("RoundedRectangle",["resizer","grip","right"]).setAll({cornerRadiusBL:0,cornerRadiusBR:0,cornerRadiusTL:0,cornerRadiusTR:0});{let n=r("Rectangle",["resizer","rectangle"]);n.setAll({strokeDasharray:[2,2],strokeOpacity:.5,strokeWidth:1}),ve(n,"stroke",t,"alternativeBackground")}r("Graphics",["button","plus","icon"]).setAll({x:ye,y:ye,draw:n=>{n.moveTo(-4,0),n.lineTo(4,0),n.moveTo(0,-4),n.lineTo(0,4)}}),r("Graphics",["button","minus","icon"]).setAll({x:ye,y:ye,draw:n=>{n.moveTo(-4,0),n.lineTo(4,0)}}),r("Graphics",["button","home","icon"]).setAll({x:ye,y:ye,svgPath:"M 8 -1 L 6 -1 L 6 7 L 2 7 L 2 1 L -2 1 L -2 7 L -6 7 L -6 -1 L -8 -1 L 0 -9 L 8 -1 Z M 8 -1"}),r("Button",["zoomtools"]).setAll({marginTop:1,marginBottom:2}),r("ZoomTools").setAll({x:se,centerX:se,y:se,centerY:se,paddingRight:10,paddingBottom:10}),r("ProgressPie").setAll({radius:se,width:50,height:50,centerX:Re(-50),centerY:Re(-50),innerRadius:Re(85),numberFormat:"#."});{let n=r("Label",["progresspie"]);n.setAll({centerX:ye,centerY:ye,fontSize:"0.75em"}),ve(n,"fill",t,"primaryButton")}{let n=r("Circle",["progresspie"]);n.setAll({fillOpacity:.5}),ve(n,"fill",t,"background")}{let n=r("Slice",["progresspie"]);n.setAll({startAngle:-90}),ve(n,"fill",t,"primaryButton")}{let n=r("Slice",["progresspie","background"]);n.setAll({fillOpacity:.2,arc:360}),ve(n,"fill",t,"primaryButton")}r("EditableLabel",["numericstepper"]).setAll({y:ye,centerY:ye,multiLine:!1,marginRight:2});{let n=r("Container",["numericstepper","buttons"]);n.setAll({layout:this._root.verticalLayout,centerY:ye,y:ye,marginRight:10,opacity:0}),n.states.create("active",{opacity:1}),n.states.create("default",{opacity:0})}{let n=r("Triangle",["numericstepper"]);n.setAll({width:17,height:11,marginTop:3,marginBottom:3,strokeWidth:5,strokeOpacity:0,cursorOverStyle:"pointer"}),ve(n,"fill",t,"secondaryButton")}r("Triangle",["downbutton"]).setAll({rotation:180})}};var DA=class{constructor(e=1,t=0,i=0,s=1,r=0,n=0){this.a=e,this.b=t,this.c=i,this.d=s,this.tx=r,this.ty=n}setTransform(e,t,i,s,r,n=1){this.a=Math.cos(r)*n,this.b=Math.sin(r)*n,this.c=-Math.sin(r)*n,this.d=Math.cos(r)*n,this.tx=e-(i*this.a+s*this.c),this.ty=t-(i*this.b+s*this.d)}apply(e){return{x:this.a*e.x+this.c*e.y+this.tx,y:this.b*e.x+this.d*e.y+this.ty}}applyInverse(e){let t=1/(this.a*this.d+this.c*-this.b);return{x:this.d*t*e.x+-this.c*t*e.y+(this.ty*this.c-this.tx*this.d)*t,y:this.a*t*e.y+-this.b*t*e.x+(-this.ty*this.a+this.tx*this.b)*t}}append(e){let t=this.a,i=this.b,s=this.c,r=this.d;this.a=e.a*t+e.b*s,this.b=e.a*i+e.b*r,this.c=e.c*t+e.d*s,this.d=e.c*i+e.d*r,this.tx=e.tx*t+e.ty*s+this.tx,this.ty=e.tx*i+e.ty*r+this.ty}prepend(e){let t=this.tx;if(e.a!==1||e.b!==0||e.c!==0||e.d!==1){let i=this.a,s=this.c;this.a=i*e.a+this.b*e.c,this.b=i*e.b+this.b*e.d,this.c=s*e.a+this.d*e.c,this.d=s*e.b+this.d*e.d}this.tx=t*e.a+this.ty*e.c+e.tx,this.ty=t*e.b+this.ty*e.d+e.ty}copyFrom(e){this.a=e.a,this.b=e.b,this.c=e.c,this.d=e.d,this.tx=e.tx,this.ty=e.ty}};var fT=(function(){function a(e,t){var i=[],s=!0,r=!1,n=void 0;try{for(var A=e[Symbol.iterator](),o;!(s=(o=A.next()).done)&&(i.push(o.value),!(t&&i.length===t));s=!0);}catch(l){r=!0,n=l}finally{try{!s&&A.return&&A.return()}finally{if(r)throw n}}return i}return function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return a(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),Go=Math.PI*2,Hf=function(e,t,i,s,r,n,A){var o=e.x,l=e.y;o*=t,l*=i;var c=s*o-r*l,h=r*o+s*l;return{x:c+n,y:h+A}},gT=function(e,t){var i=t===1.5707963267948966?.551915024494:t===-1.5707963267948966?-.551915024494:1.3333333333333333*Math.tan(t/4),s=Math.cos(e),r=Math.sin(e),n=Math.cos(e+t),A=Math.sin(e+t);return[{x:s-r*i,y:r+s*i},{x:n+A*i,y:A-n*i},{x:n,y:A}]},Ab=function(e,t,i,s){var r=e*s-t*i<0?-1:1,n=e*i+t*s;return n>1&&(n=1),n<-1&&(n=-1),r*Math.acos(n)},pT=function(e,t,i,s,r,n,A,o,l,c,h,d){var u=Math.pow(r,2),g=Math.pow(n,2),y=Math.pow(h,2),m=Math.pow(d,2),b=u*g-u*m-g*y;b<0&&(b=0),b/=u*m+g*y,b=Math.sqrt(b)*(A===o?-1:1);var B=b*r/n*d,w=b*-n/r*h,_=c*B-l*w+(e+i)/2,T=l*B+c*w+(t+s)/2,Q=(h-B)/r,U=(d-w)/n,E=(-h-B)/r,O=(-d-w)/n,D=Ab(1,0,Q,U),k=Ab(Q,U,E,O);return o===0&&k>0&&(k-=Go),o===1&&k<0&&(k+=Go),[_,T,D,k]},mT=function(e){var t=e.px,i=e.py,s=e.cx,r=e.cy,n=e.rx,A=e.ry,o=e.xAxisRotation,l=o===void 0?0:o,c=e.largeArcFlag,h=c===void 0?0:c,d=e.sweepFlag,u=d===void 0?0:d,g=[];if(n===0||A===0)return[];var y=Math.sin(l*Go/360),m=Math.cos(l*Go/360),b=m*(t-s)/2+y*(i-r)/2,B=-y*(t-s)/2+m*(i-r)/2;if(b===0&&B===0)return[];n=Math.abs(n),A=Math.abs(A);var w=Math.pow(b,2)/Math.pow(n,2)+Math.pow(B,2)/Math.pow(A,2);w>1&&(n*=Math.sqrt(w),A*=Math.sqrt(w));var _=pT(t,i,s,r,n,A,h,u,y,m,b,B),T=fT(_,4),Q=T[0],U=T[1],E=T[2],O=T[3],D=Math.abs(O)/(Go/4);Math.abs(1-D)<1e-7&&(D=1);var k=Math.max(Math.ceil(D),1);O/=k;for(var F=0;F<k;F++)g.push(gT(E,O)),E+=O;return g.map(function(M){var Y=Hf(M[0],n,A,m,y,Q,U),z=Y.x,re=Y.y,q=Hf(M[1],n,A,m,y,Q,U),Ae=q.x,X=q.y,G=Hf(M[2],n,A,m,y,Q,U),ue=G.x,he=G.y;return{x1:z,y1:re,x2:Ae,y2:X,x:ue,y:he}})},ob=mT;function yT(a,e,t){if(e!==t)throw new Error("Required "+t+" arguments for "+a+" but got "+e)}function Xo(a,e,t){if(e<t)throw new Error("Required at least "+t+" arguments for "+a+" but got "+e)}function Qs(a,e,t){if(Xo(a,e,t),e%t!==0)throw new Error("Arguments for "+a+" must be in pairs of "+t)}function vT(a){for(let e=0;e<a.length;e+=7){let t=e+3,i=a[t];if(i.length>1){let s=/^([01])([01])(.*)$/.exec(i);s!==null&&(a.splice(t,0,s[1]),++t,a.splice(t,0,s[2]),++t,s[3].length>0?a[t]=s[3]:a.splice(t,1))}if(++t,i=a[t],i.length>1){let s=/^([01])(.+)$/.exec(i);s!==null&&(a.splice(t,0,s[1]),++t,a[t]=s[2])}}}function lb(a){if(a===0||a===1)return a;throw new Error("Flag must be 0 or 1")}function xT(a){let e=[0,0,0];for(let t=0;t<24;t++)e[t%3]<<=1,e[t%3]|=a&1,a>>=1;return(e[0]|0)+(e[1]<<8)+(e[2]<<16)}function rc(a,e){for(;!(a.interactive&&!e(a));)if(a._parent)a=a._parent;else break}function bT(a,e,t){return kt(a,Vh(e),i=>{let s=df(i),r=i.touches;r?(r.length==0&&(r=i.changedTouches),t(Qo(r),s)):t([i],s)})}function hb(a){let e=document.createElement("canvas");e.width=1,e.height=1;let t=e.getContext("2d",{willReadFrequently:!0});t.drawImage(a,0,0,1,1);try{return t.getImageData(0,0,1,1),!1}catch{return console.warn('Image "'+a.src+'" is loaded from different host and is not covered by CORS policy. For more information about the implications read here: https://www.amcharts.com/docs/v5/concepts/cors'),!0}}function Wo(a){a.width=0,a.height=0,a.style.width="0px",a.style.height="0px"}function cb(a){return Math.floor(a)+.5}var Rf=class{constructor(){this._x=0,this._y=0}get x(){return this._x}get y(){return this._y}set x(e){this._x=e}set y(e){this._y=e}},LA=class extends Va{constructor(e){super(),this.mask=null,this.visible=!0,this.exportable=!0,this.interactive=!1,this.inactive=null,this.wheelable=!1,this.cancelTouch=!1,this.isMeasured=!1,this.buttonMode=!1,this.alpha=1,this.compoundAlpha=1,this.angle=0,this.scale=1,this.x=0,this.y=0,this.crisp=!1,this.pivot=new Rf,this._localMatrix=new DA,this._matrix=new DA,this._uMatrix=new DA,this._renderer=e}subStatus(e){return{inactive:this.inactive==null?e.inactive:this.inactive,layer:this._layer||e.layer}}_dispose(){this._renderer._removeObject(this),this.getLayer().dirty=!0}getCanvas(){return this.getLayer().view}getLayer(){let e=this;for(;;){if(e._layer)return e._layer;if(e._parent)e=e._parent;else return this._renderer.defaultLayer}}setLayer(e,t){e==null?this._layer=void 0:(this._layer=this._renderer.getLayer(e,!0),this._layer.visible=!0,this._layer.margin=t,t&&Ka(this._layer.view,!1),this._renderer._ghostLayer.setMargin(this._renderer.layers),this._parent&&this._parent.registerChildLayer(this._layer),this._layer.dirty=!0,this._renderer.resizeLayer(this._layer),this._renderer.resizeGhost())}markDirtyLayer(){this.getLayer().dirty=!0}clear(){this.invalidateBounds()}invalidateBounds(){this._localBounds=void 0}_addBounds(e){}_getColorId(){return this._colorId===void 0&&(this._colorId=this._renderer.paintId(this)),this._colorId}_isInteractive(e){return!e.inactive&&(this.interactive||this._renderer._forceInteractive>0)}_isInteractiveMask(e){return this._isInteractive(e)}contains(e){for(;;){if(e===this)return!0;if(e._parent)e=e._parent;else return!1}}toGlobal(e){return this._matrix.apply(e)}toLocal(e){return this._matrix.applyInverse(e)}getLocalMatrix(){return this._uMatrix.setTransform(0,0,this.pivot.x,this.pivot.y,this.angle*Math.PI/180,this.scale),this._uMatrix}getLocalBounds(){return this._localBounds||(this._localBounds={left:1e7,top:1e7,right:-1e7,bottom:-1e7},this._addBounds(this._localBounds)),this._localBounds}getAdjustedBounds(e){this._setMatrix();let t=this.getLocalMatrix(),i=t.apply({x:e.left,y:e.top}),s=t.apply({x:e.right,y:e.top}),r=t.apply({x:e.right,y:e.bottom}),n=t.apply({x:e.left,y:e.bottom});return{left:Math.min(i.x,s.x,r.x,n.x),top:Math.min(i.y,s.y,r.y,n.y),right:Math.max(i.x,s.x,r.x,n.x),bottom:Math.max(i.y,s.y,r.y,n.y)}}on(e,t,i){return this.interactive?this._renderer._addEvent(this,e,t,i):new Qt(()=>{})}_setMatrix(){this._localMatrix.setTransform(this.x,this.y,this.pivot.x,this.pivot.y,this.angle*Math.PI/180,this.scale),this._matrix.copyFrom(this._localMatrix),this._parent&&this._matrix.prepend(this._parent._matrix)}_transform(e,t){let i=this._matrix,s=i.tx*t,r=i.ty*t;this.crisp&&(s=cb(s),r=cb(r)),e.setTransform(i.a*t,i.b*t,i.c*t,i.d*t,s,r)}_transformMargin(e,t,i){let s=this._matrix;e.setTransform(s.a*t,s.b*t,s.c*t,s.d*t,(s.tx+i.left)*t,(s.ty+i.top)*t)}_transformLayer(e,t,i){i.margin?this._transformMargin(e,i.scale||t,i.margin):this._transform(e,i.scale||t)}render(e,t=0){if(this.visible&&(this.exportable!==!1||!this._renderer._omitTainted)){this._setMatrix();let i=this.subStatus(e),s=this._renderer.resolution,r=this._renderer.layers,n=this._renderer._ghostLayer,A=n.context,o=this.mask;o&&o._setMatrix(),K(r,l=>{if(l){let c=l.context;c.save(),o&&(o._transformLayer(c,s,l),o._runPath(c),c.clip()),c.globalAlpha=this.compoundAlpha*this.alpha,this._transformLayer(c,s,l),this.filter&&(c.filter=this.filter)}}),A.save(),o&&this._isInteractiveMask(i)&&(o._transformMargin(A,s,n.margin),o._runPath(A),A.clip()),this._transformMargin(A,s,n.margin),i.layer.order>0&&!t&&Uo(this._renderer._deferredGhostLayers,i.layer.order),this._render(i,t),A.restore(),K(r,l=>{l&&l.context.restore()})}}_render(e,t=0){this.exportable===!1&&(e.layer.tainted=!0)}_ghostOnly(e=0){return e>0}_drawGhost(e,t=0){let i=this._isInteractive(e),s=e.layer.order||0;return!!(i&&(s==0&&!this._ghostOnly(t)||s==t))}hovering(){return this._renderer._hovering.has(this)}dragging(){return this._renderer._dragging.some(e=>e.value===this)}shouldCancelTouch(){let e=this._renderer;return e.tapToActivate&&!e._touchActive?!1:this.cancelTouch?!0:this._parent?this._parent.shouldCancelTouch():!1}},Of=class extends LA{constructor(){super(...arguments),this.interactiveChildren=!0,this._children=[]}_isInteractiveMask(e){return this.interactiveChildren||super._isInteractiveMask(e)}addChild(e){e._parent=this,this._children.push(e),e._layer&&this.registerChildLayer(e._layer)}addChildAt(e,t){e._parent=this,this._children.splice(t,0,e),e._layer&&this.registerChildLayer(e._layer)}removeChild(e){e._parent=void 0,Jt(this._children,e)}_render(e,t){super._render(e);let i=this._renderer;this.interactive&&this.interactiveChildren&&++i._forceInteractive,K(this._children,s=>{s.compoundAlpha=this.compoundAlpha*this.alpha,s.render(e,t)}),this.interactive&&this.interactiveChildren&&--i._forceInteractive}registerChildLayer(e){this._childLayers||(this._childLayers=[]),Na(this._childLayers,e),this._parent&&this._parent.registerChildLayer(e)}markDirtyLayer(e=!1){super.markDirtyLayer(),e&&this._childLayers&&K(this._childLayers,t=>t.dirty=!0)}_dispose(){super._dispose(),this._childLayers&&K(this._childLayers,e=>{e.dirty=!0})}};function ci(a,e){a.left=Math.min(a.left,e.x),a.top=Math.min(a.top,e.y),a.right=Math.max(a.right,e.x),a.bottom=Math.max(a.bottom,e.y)}var di=class{colorize(e,t){}colorizeGhost(e,t){this.colorize(e,t)}path(e){}pathGhost(e){this.path(e)}addBounds(e){}},Nf=class extends di{colorize(e,t){e.beginPath()}},zo=class extends di{constructor(e){super(),this.color=e}colorize(e,t){t!==void 0?e.fillStyle=t:e.fillStyle=this.color}},Vf=class extends di{constructor(e){super(),this.clearShadow=e}colorize(e,t){e.fill(),this.clearShadow&&(e.shadowColor="",e.shadowBlur=0,e.shadowOffsetX=0,e.shadowOffsetY=0)}},$f=class extends di{colorize(e,t){e.stroke()}},Yo=class extends di{constructor(e,t,i,s){super(),this.width=e,this.color=t,this.lineJoin=i,this.lineCap=s}colorize(e,t){t!==void 0?e.strokeStyle=t:e.strokeStyle=this.color,e.lineWidth=this.width,this.lineJoin&&(e.lineJoin=this.lineJoin),this.lineCap&&(e.lineCap=this.lineCap)}},Kf=class extends di{constructor(e){super(),this.dash=e}colorize(e,t){e.setLineDash(this.dash)}},Gf=class extends di{constructor(e){super(),this.dashOffset=e}colorize(e,t){e.lineDashOffset=this.dashOffset}},Xf=class extends di{constructor(e,t,i,s){super(),this.x=e,this.y=t,this.width=i,this.height=s}path(e){e.rect(this.x,this.y,this.width,this.height)}addBounds(e){let t=this.x,i=this.y,s=t+this.width,r=i+this.height;ci(e,{x:t,y:i}),ci(e,{x:s,y:i}),ci(e,{x:t,y:r}),ci(e,{x:s,y:r})}},Wf=class extends di{constructor(e,t,i){super(),this.x=e,this.y=t,this.radius=i}path(e){e.moveTo(this.x+this.radius,this.y),e.arc(this.x,this.y,this.radius,0,2*Math.PI)}addBounds(e){ci(e,{x:this.x-this.radius,y:this.y-this.radius}),ci(e,{x:this.x+this.radius,y:this.y+this.radius})}},zf=class extends di{constructor(e,t,i,s){super(),this.x=e,this.y=t,this.radiusX=i,this.radiusY=s}path(e){e.ellipse(0,0,this.radiusX,this.radiusY,0,0,Math.PI*2)}addBounds(e){ci(e,{x:this.x-this.radiusX,y:this.y-this.radiusY}),ci(e,{x:this.x+this.radiusX,y:this.y+this.radiusY})}},Yf=class extends di{constructor(e,t,i,s,r,n){super(),this.cx=e,this.cy=t,this.radius=i,this.startAngle=s,this.endAngle=r,this.anticlockwise=n}path(e){this.radius>0&&e.arc(this.cx,this.cy,this.radius,this.startAngle,this.endAngle,this.anticlockwise)}addBounds(e){let t=Xa(this.cx,this.cy,this.startAngle*bs,this.endAngle*bs,this.radius);ci(e,{x:t.left,y:t.top}),ci(e,{x:t.right,y:t.bottom})}},jf=class extends di{constructor(e,t,i,s,r){super(),this.x1=e,this.y1=t,this.x2=i,this.y2=s,this.radius=r}path(e){this.radius>0&&e.arcTo(this.x1,this.y1,this.x2,this.y2,this.radius)}addBounds(e){}},Zf=class extends di{constructor(e,t){super(),this.x=e,this.y=t}path(e){e.lineTo(this.x,this.y)}addBounds(e){ci(e,{x:this.x,y:this.y})}},qf=class extends di{constructor(e,t){super(),this.x=e,this.y=t}path(e){e.moveTo(this.x,this.y)}addBounds(e){ci(e,{x:this.x,y:this.y})}},Jf=class extends di{path(e){e.closePath()}},eg=class extends di{constructor(e,t,i,s,r,n){super(),this.cpX=e,this.cpY=t,this.cpX2=i,this.cpY2=s,this.toX=r,this.toY=n}path(e){e.bezierCurveTo(this.cpX,this.cpY,this.cpX2,this.cpY2,this.toX,this.toY)}addBounds(e){ci(e,{x:this.cpX,y:this.cpY}),ci(e,{x:this.cpX2,y:this.cpY2}),ci(e,{x:this.toX,y:this.toY})}},tg=class extends di{constructor(e,t,i,s){super(),this.cpX=e,this.cpY=t,this.toX=i,this.toY=s}path(e){e.quadraticCurveTo(this.cpX,this.cpY,this.toX,this.toY)}addBounds(e){ci(e,{x:this.cpX,y:this.cpY}),ci(e,{x:this.toX,y:this.toY})}},ig=class extends di{constructor(e,t,i,s,r){super(),this.color=e,this.blur=t,this.offsetX=i,this.offsetY=s,this.opacity=r}colorize(e,t){this.opacity&&(e.fillStyle=this.color),e.shadowColor=this.color,e.shadowBlur=this.blur,e.shadowOffsetX=this.offsetX,e.shadowOffsetY=this.offsetY}colorizeGhost(e,t){}},sg=class extends di{constructor(e,t,i,s,r){super(),this.image=e,this.width=t,this.height=i,this.x=s,this.y=r}path(e){e.drawImage(this.image,this.x,this.y,this.width,this.height)}addBounds(e){ci(e,{x:this.x,y:this.y}),ci(e,{x:this.width,y:this.height})}},rg=class extends LA{constructor(){super(...arguments),this._operations=[],this.blendMode=IA.NORMAL,this._hasShadows=!1}clear(){super.clear(),this._operations.length=0}_pushOp(e){this._operations.push(e)}beginFill(e,t=1){this._fillAlpha=t,e?e instanceof we?this._pushOp(new zo(e.toCSS(t))):(this.isMeasured=!0,this._pushOp(new zo(e))):this._pushOp(new zo("rgba(0, 0, 0, "+t+")"))}endFill(){this._pushOp(new Vf(this._hasShadows))}endStroke(){this._pushOp(new $f)}beginPath(){this._pushOp(new Nf)}lineStyle(e=0,t,i=1,s,r){this._strokeAlpha=i,t?t instanceof we?this._pushOp(new Yo(e,t.toCSS(i),s,r)):this._pushOp(new Yo(e,t,s,r)):this._pushOp(new Yo(e,"rgba(0, 0, 0, "+i+")",s,r))}setLineDash(e){this._pushOp(new Kf(e||[]))}setLineDashOffset(e=0){this._pushOp(new Gf(e))}drawRect(e,t,i,s){this._pushOp(new Xf(e,t,i,s))}drawCircle(e,t,i){this._pushOp(new Wf(e,t,i))}drawEllipse(e,t,i,s){this._pushOp(new zf(e,t,i,s))}arc(e,t,i,s,r,n=!1){this._pushOp(new Yf(e,t,i,s,r,n))}arcTo(e,t,i,s,r){this._pushOp(new jf(e,t,i,s,r))}lineTo(e,t){this._pushOp(new Zf(e,t))}moveTo(e,t){this._pushOp(new qf(e,t))}bezierCurveTo(e,t,i,s,r,n){this._pushOp(new eg(e,t,i,s,r,n))}quadraticCurveTo(e,t,i,s){this._pushOp(new tg(e,t,i,s))}closePath(){this._pushOp(new Jf)}shadow(e,t=0,i=0,s=0,r){this._hasShadows=!0,this._pushOp(new ig(r?e.toCSS(r):e.toCSS(this._fillAlpha||this._strokeAlpha),t,i,s))}image(e,t,i,s,r){this._pushOp(new sg(e,t,i,s,r))}svgPath(e){let t=0,i=0,s=null,r=null,n=null,A=null,o=/([MmZzLlHhVvCcSsQqTtAa])([^MmZzLlHhVvCcSsQqTtAa]*)/g,l=/[\u0009\u0020\u000A\u000C\u000D]*([\+\-]?[0-9]*\.?[0-9]+(?:[eE][\+\-]?[0-9]+)?)[\u0009\u0020\u000A\u000C\u000D]*,?/g,c=this._operations.length;try{let h;for(;(h=o.exec(e))!==null;){let d=h[1],u=h[2],g=[];for(;(h=l.exec(u))!==null;)g.push(h[1]);switch(d!=="S"&&d!=="s"&&d!=="C"&&d!=="c"&&(s=null,r=null),d!=="Q"&&d!=="q"&&d!=="T"&&d!=="t"&&(n=null,A=null),d){case"M":Qs(d,g.length,2),t=+g[0],i=+g[1],this.moveTo(t,i);for(let m=2;m<g.length;m+=2)t=+g[m],i=+g[m+1],this.lineTo(t,i);break;case"m":Qs(d,g.length,2),t+=+g[0],i+=+g[1],this.moveTo(t,i);for(let m=2;m<g.length;m+=2)t+=+g[m],i+=+g[m+1],this.lineTo(t,i);break;case"L":Qs(d,g.length,2);for(let m=0;m<g.length;m+=2)t=+g[m],i=+g[m+1],this.lineTo(t,i);break;case"l":Qs(d,g.length,2);for(let m=0;m<g.length;m+=2)t+=+g[m],i+=+g[m+1],this.lineTo(t,i);break;case"H":Xo(d,g.length,1);for(let m=0;m<g.length;++m)t=+g[m],this.lineTo(t,i);break;case"h":Xo(d,g.length,1);for(let m=0;m<g.length;++m)t+=+g[m],this.lineTo(t,i);break;case"V":Xo(d,g.length,1);for(let m=0;m<g.length;++m)i=+g[m],this.lineTo(t,i);break;case"v":Xo(d,g.length,1);for(let m=0;m<g.length;++m)i+=+g[m],this.lineTo(t,i);break;case"C":Qs(d,g.length,6);for(let m=0;m<g.length;m+=6){let b=+g[m],B=+g[m+1];s=+g[m+2],r=+g[m+3],t=+g[m+4],i=+g[m+5],this.bezierCurveTo(b,B,s,r,t,i)}break;case"c":Qs(d,g.length,6);for(let m=0;m<g.length;m+=6){let b=+g[m]+t,B=+g[m+1]+i;s=+g[m+2]+t,r=+g[m+3]+i,t+=+g[m+4],i+=+g[m+5],this.bezierCurveTo(b,B,s,r,t,i)}break;case"S":Qs(d,g.length,4),(s===null||r===null)&&(s=t,r=i);for(let m=0;m<g.length;m+=4){let b=2*t-s,B=2*i-r;s=+g[m],r=+g[m+1],t=+g[m+2],i=+g[m+3],this.bezierCurveTo(b,B,s,r,t,i)}break;case"s":Qs(d,g.length,4),(s===null||r===null)&&(s=t,r=i);for(let m=0;m<g.length;m+=4){let b=2*t-s,B=2*i-r;s=+g[m]+t,r=+g[m+1]+i,t+=+g[m+2],i+=+g[m+3],this.bezierCurveTo(b,B,s,r,t,i)}break;case"Q":Qs(d,g.length,4);for(let m=0;m<g.length;m+=4)n=+g[m],A=+g[m+1],t=+g[m+2],i=+g[m+3],this.quadraticCurveTo(n,A,t,i);break;case"q":Qs(d,g.length,4);for(let m=0;m<g.length;m+=4)n=+g[m]+t,A=+g[m+1]+i,t+=+g[m+2],i+=+g[m+3],this.quadraticCurveTo(n,A,t,i);break;case"T":Qs(d,g.length,2),(n===null||A===null)&&(n=t,A=i);for(let m=0;m<g.length;m+=2)n=2*t-n,A=2*i-A,t=+g[m],i=+g[m+1],this.quadraticCurveTo(n,A,t,i);break;case"t":Qs(d,g.length,2),(n===null||A===null)&&(n=t,A=i);for(let m=0;m<g.length;m+=2)n=2*t-n,A=2*i-A,t+=+g[m],i+=+g[m+1],this.quadraticCurveTo(n,A,t,i);break;case"A":case"a":let y=d==="a";vT(g),Qs(d,g.length,7);for(let m=0;m<g.length;m+=7){let b=+g[m+5],B=+g[m+6];y&&(b+=t,B+=i);let w=ob({px:t,py:i,rx:+g[m],ry:+g[m+1],xAxisRotation:+g[m+2],largeArcFlag:lb(+g[m+3]),sweepFlag:lb(+g[m+4]),cx:b,cy:B});K(w,_=>{this.bezierCurveTo(_.x1,_.y1,_.x2,_.y2,_.x,_.y),t=_.x,i=_.y})}break;case"Z":case"z":yT(d,g.length,0),this.closePath();break}}}catch(h){this._operations.length=c,console.warn(`Error when parsing svgPath:
8
- `+h.message+`
9
- `+e)}}_runPath(e){e.beginPath(),K(this._operations,t=>{t.path(e)})}_render(e,t=0){super._render(e);let i=e.layer.dirty,s=this._isInteractive(e),r=this._ghostOnly(t),n=this._drawGhost(e,t);if(i||s||r){let A=e.layer.context,o=this._renderer._ghostLayer.context;i&&!r&&(A.globalCompositeOperation=this.blendMode,A.beginPath());let l;n&&(o.beginPath(),l=this._getColorId()),K(this._operations,c=>{i&&!r&&(c.path(A),c.colorize(A,void 0)),n&&(c.pathGhost(o),c.colorizeGhost(o,l))})}}renderDetached(e){if(this.visible){this._setMatrix(),e.save();let t=this.mask;t&&(t._setMatrix(),t._transform(e,1),t._runPath(e),e.clip()),e.globalAlpha=this.compoundAlpha*this.alpha,this._transform(e,1),this.filter&&(e.filter=this.filter),e.globalCompositeOperation=this.blendMode,e.beginPath(),K(this._operations,i=>{i.path(e),i.colorize(e,void 0)}),e.restore()}}_addBounds(e){this.visible&&this.isMeasured&&K(this._operations,t=>{t.addBounds(e)})}},ac=class extends LA{constructor(e,t,i){super(e),this.resolution=1,this.textVisible=!0,this._originalScale=1,this.text=t,this.style=i}invalidateBounds(){super.invalidateBounds(),this._textInfo=void 0}invalidateVisibility(){this.textVisible=!0,this.scale=this._originalScale||1}_shared(e){this.style.textAlign&&(e.textAlign=this.style.textAlign),this.style.direction&&(e.direction=this.style.direction),this.style.textBaseline&&(e.textBaseline=this.style.textBaseline)}_prerender(e,t=!1,i=!1){super._render(e);let s=e.layer.context,r=this._renderer._ghostLayer.context,n=this.style,A=this._getFontStyle(void 0,i);s.font=A,this._isInteractive(e)&&!t&&(r.font=A),n.fill&&(n.fill instanceof we?s.fillStyle=n.fill.toCSS(n.fillOpacity!=null?n.fillOpacity:1):s.fillStyle=n.fill),n.shadowColor&&(e.layer.context.shadowColor=n.shadowColor.toCSS(n.shadowOpacity||1)),n.shadowBlur&&(e.layer.context.shadowBlur=n.shadowBlur),n.shadowOffsetX&&(e.layer.context.shadowOffsetX=n.shadowOffsetX),n.shadowOffsetY&&(e.layer.context.shadowOffsetY=n.shadowOffsetY),this._shared(s),this._isInteractive(e)&&!t&&(r.fillStyle=this._getColorId(),this._shared(r))}_getFontStyle(e,t=!1){let i=this.style,s=[];return e&&e.fontVariant?s.push(e.fontVariant):i.fontVariant&&s.push(i.fontVariant),t||(e&&e.fontWeight?s.push(e.fontWeight):i.fontWeight&&s.push(i.fontWeight)),e&&e.fontStyle?s.push(e.fontStyle):i.fontStyle&&s.push(i.fontStyle),e&&e.fontSize?(W(e.fontSize)&&(e.fontSize=e.fontSize+"px"),s.push(e.fontSize)):i.fontSize&&(W(i.fontSize)&&(i.fontSize=i.fontSize+"px"),s.push(i.fontSize)),e&&e.fontFamily?s.push(e.fontFamily):i.fontFamily?s.push(i.fontFamily):s.length&&s.push("Arial"),s.join(" ")}_render(e,t=0){if(this._textInfo||this._measure(e),this.textVisible){let i=this._isInteractive(e),s=e.layer.context,r=e.layer.dirty,n=this._renderer._ghostLayer.context,A=this._ghostOnly(t),o=this._drawGhost(e,t);s.save(),n.save(),this._prerender(e),K(this._textInfo,(l,c)=>{K(l.textChunks,(h,d)=>{if(h.style&&(s.save(),n.save(),A||(s.font=h.style),this._isInteractive(e)&&(n.font=h.style)),h.fill&&(s.save(),A||(s.fillStyle=h.fill.toCSS())),r&&!A&&s.fillText(h.text,h.offsetX,l.offsetY+h.offsetY),h.textDecoration=="underline"||h.textDecoration=="line-through"){let u=1,g=1,y=h.height,m=this.style.oversizedBehavior||"";if(["truncate","wrap","wrap-no-break"].indexOf(m)>-1){let w=this._measureText(h.text,s);h.width=w.actualBoundingBoxLeft+w.actualBoundingBoxRight}let b=h.offsetX;switch(this.style.textAlign){case"right":case"end":b-=h.width;break;case"center":b-=h.width/2;break}if(h.style)switch(Di.getTextStyle(h.style).fontWeight){case"bolder":case"bold":case"700":case"800":case"900":u=2;break}y&&(g=y/20);let B;h.textDecoration=="line-through"?B=u+l.offsetY+h.offsetY-h.height/2:B=u+g*1.5+l.offsetY+h.offsetY,A||(s.save(),s.beginPath(),h.fill?s.strokeStyle=h.fill.toCSS():this.style.fill&&this.style.fill instanceof we&&(s.strokeStyle=this.style.fill.toCSS()),s.lineWidth=u*g,s.moveTo(b,B),s.lineTo(b+h.width,B),s.stroke(),s.restore())}i&&this.interactive&&o&&n.fillText(h.text,h.offsetX,l.offsetY+h.offsetY),h.fill&&s.restore(),h.style&&(s.restore(),n.restore())})}),s.restore(),n.restore()}}_addBounds(e){if(this.visible&&this.isMeasured){let t=this._measure({inactive:this.inactive,layer:this.getLayer()});ci(e,{x:t.left,y:t.top}),ci(e,{x:t.right,y:t.bottom})}}_ignoreFontWeight(){return/apple/i.test(navigator.vendor)}_measure(e){let t=e.layer.context,i=this._renderer._ghostLayer.context,s=this.style.direction=="rtl";this._textInfo=[];let r=this.style.oversizedBehavior,n=this.style.maxWidth,A=W(n)&&r=="truncate",o=W(n)&&(r=="wrap"||r=="wrap-no-break");t.save(),i.save(),this._prerender(e,!0,this._ignoreFontWeight());let l="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ",c=this.text.toString().replace(/\r/g,"").split(/\n/),h=!0,d=0,u=0,g=0,y;K(c,(b,B)=>{let w;for(b==""?w=[{type:"value",text:""}]:w=Di.chunk(b,!1,this.style.ignoreFormatting);w.length>0;){let _={offsetY:g,ascent:0,width:0,height:0,left:0,right:0,textChunks:[]},T=this._measureText(l,t),Q=T.actualBoundingBoxAscent+T.actualBoundingBoxDescent;_.height=Q,_.ascent=T.actualBoundingBoxAscent;let U,E=this.style.textDecoration,O,D,k=!1,F=!0,M=[],Y;Lo(w,(z,re)=>{if(z.type=="format")if(z.text=="[/]")h||(t.restore(),i.restore(),h=!0),O=void 0,y=void 0,D=void 0,E=this.style.textDecoration,Y=void 0,U=z.text;else{h||(t.restore(),i.restore());let q=Di.getTextStyle(z.text),Ae=this._getFontStyle(q);t.save(),i.save(),t.font=Ae,y=Ae,U=z.text,q.textDecoration&&(E=q.textDecoration),q.fill&&(O=q.fill),q.width&&(D=Vi(q.width)),q.verticalAlign&&(Y=q.verticalAlign),h=!1;let X=this._measureText(l,t),G=X.actualBoundingBoxAscent+X.actualBoundingBoxDescent;G>_.height&&(_.height=G),X.actualBoundingBoxAscent>_.ascent&&(_.ascent=X.actualBoundingBoxAscent)}else if(z.type=="value"&&!k){let q=this._measureText(z.text,t),Ae=q.actualBoundingBoxLeft+q.actualBoundingBoxRight;if(A){this.truncated=void 0;let he=F||this.style.breakWords||!1,ae=this.style.ellipsis||"",Ie=this._measureText(ae,t),Pe=Ie.actualBoundingBoxLeft+Ie.actualBoundingBoxRight;if(_.width+Ae>n){let De=n-_.width-Pe;z.text=this._truncateText(t,z.text,De,he),z.text+=ae,k=!0,this.truncated=!0}}else if(o&&_.width+Ae>n){let he=n-_.width,ae=this._truncateText(t,z.text,he,!1,F&&this.style.oversizedBehavior!="wrap-no-break");if(ae=="")return this.textVisible=!0,!1;M=w.slice(re+1),$a(ae)!=$a(z.text)&&(M.unshift({type:"value",text:z.text.substr(ae.length)}),U&&M.unshift({type:"format",text:U})),z.text=$a(ae),w=[],k=!0}let X=1,G=1;if(y&&D&&D>Ae){let he=Ae/D;switch(this.style.textAlign){case"right":case"end":X=he;break;case"center":X=he,G=he;break;default:G=he}Ae=D}let ue=q.actualBoundingBoxAscent+q.actualBoundingBoxDescent;ue>_.height&&(_.height=ue),q.actualBoundingBoxAscent>_.ascent&&(_.ascent=q.actualBoundingBoxAscent),_.width+=Ae,_.left+=q.actualBoundingBoxLeft/X,_.right+=q.actualBoundingBoxRight/G,_.textChunks.push({style:y,fill:O,text:z.text,width:Ae,height:ue,left:q.actualBoundingBoxLeft,right:q.actualBoundingBoxRight,ascent:q.actualBoundingBoxAscent,offsetX:0,offsetY:0,textDecoration:E,verticalAlign:Y}),F=!1}return!0}),this.style.lineHeight instanceof ke?(_.height*=this.style.lineHeight.value,_.ascent*=this.style.lineHeight.value):(_.height*=this.style.lineHeight||1.2,_.ascent*=this.style.lineHeight||1.2),d<_.left&&(d=_.left),u<_.right&&(u=_.right),this._textInfo.push(_),g+=_.height,w=M||[]}}),h||(t.restore(),i.restore()),K(this._textInfo,(b,B)=>{let w=0;K(b.textChunks,_=>{if(_.offsetX=w+_.left-b.left,_.offsetY+=b.height-b.height*(this.style.baselineRatio||.19),w+=_.width*(s?-1:1),_.verticalAlign)switch(_.verticalAlign){case"super":_.offsetY-=b.height/2-_.height/2;break;case"sub":_.offsetY+=_.height/2;break}})});let m={left:s?-u:-d,top:0,right:s?d:u,bottom:g};if(r!=="none"){let b=this._fitRatio(m);if(b<1)if(r=="fit")W(this.style.minScale)&&b<this.style.minScale?(this.textVisible=!1,m.left=0,m.top=0,m.right=0,m.bottom=0):(this._originalScale||(this._originalScale=this.scale),this.scale=b,this.textVisible=!0);else if(r=="hide")this.textVisible=!1,m.left=0,m.top=0,m.right=0,m.bottom=0;else{switch(this.style.textAlign){case"right":case"end":m.left=s?n:-n,m.right=0;break;case"center":m.left=-n/2,m.right=n/2;break;default:m.left=0,m.right=s?-n:n}this.scale=this._originalScale||1,this._originalScale=void 0,this.textVisible=!0}else this.scale=this._originalScale||1,this._originalScale=void 0,this.textVisible=!0}return t.restore(),i.restore(),m}_fitRatio(e){let t=this.style.maxWidth,i=this.style.maxHeight;if(!W(t)&&!W(i))return 1;let s=e.right-e.left,r=e.bottom-e.top;return Math.min(t/s||1,i/r||1)}_truncateText(e,t,i,s=!1,r=!0){let n;do{if(s)t=t.slice(0,-1);else{let o=t.replace(/[^,;:!?\\\/\s​]+[,;:!?\\\/\s​]*$/g,"");if((o==""||o===t)&&r)s=!0;else{if(o=="")return t;t=o}}let A=this._measureText(t,e);n=A.actualBoundingBoxLeft+A.actualBoundingBoxRight}while(n>i&&t!="");return t}_measureText(e,t){let i=t.measureText(e),s={};if(i.actualBoundingBoxAscent==null){let n=document.createElement("div");n.innerText=e,n.style.visibility="hidden",n.style.position="absolute",n.style.top="-1000000px;",n.style.fontFamily=this.style.fontFamily||"",n.style.fontSize=this.style.fontSize+"",document.body.appendChild(n);let A=n.getBoundingClientRect();document.body.removeChild(n);let o=A.height,l=i.width;s={actualBoundingBoxAscent:o,actualBoundingBoxDescent:0,actualBoundingBoxLeft:0,actualBoundingBoxRight:l,fontBoundingBoxAscent:o,fontBoundingBoxDescent:0,width:l}}else s={actualBoundingBoxAscent:i.actualBoundingBoxAscent,actualBoundingBoxDescent:i.actualBoundingBoxDescent,actualBoundingBoxLeft:i.actualBoundingBoxLeft,actualBoundingBoxRight:i.actualBoundingBoxRight,fontBoundingBoxAscent:i.actualBoundingBoxAscent,fontBoundingBoxDescent:i.actualBoundingBoxDescent,width:i.width};let r=i.width;switch(this.style.textAlign){case"right":case"end":s.actualBoundingBoxLeft=r,s.actualBoundingBoxRight=0;break;case"center":s.actualBoundingBoxLeft=r/2,s.actualBoundingBoxRight=r/2;break;default:s.actualBoundingBoxLeft=0,s.actualBoundingBoxRight=r}return s}},ag=class{constructor(){this.lineHeight=Re(120),this.baselineRatio=.19,this.oversizedBehavior="none",this.breakWords=!1,this.ellipsis="\u2026",this.ignoreFormatting=!1}},ng=class extends ac{constructor(){super(...arguments),this.textType="circular",this.inside=!1,this.orientation="auto",this.kerning=0,this._textReversed=!1}_render(e,t=0){switch(this.textType){case"circular":this._renderCircular(e,t);break;default:super._render(e,t);break}}_renderCircular(e,t=0){if(this.textVisible){this._prerender(e);let i=this._isInteractive(e),s=e.layer.context,r=e.layer.dirty,n=this._renderer._ghostLayer.context;s.save(),i&&n.save(),this._textInfo||this._measure(e);let A=this.radius||0,o=this.startAngle||0,l=0,c=this.orientation,h=c=="auto"?"auto":c=="inward",d=this.inside,u=this.style.textAlign||"left",g=this.kerning||0,y=u=="left"?1:-1,m=!this._textReversed,b=this._ghostOnly(t),B=this._drawGhost(e,t);if(h=="auto"){let w=0,_=0;K(this._textInfo,(T,Q)=>{let U=o+T.width/(A-T.height)/2*-y;U>w&&(w=U)}),u=="left"?_=(w+l/2)*bs:u=="right"?_=(w-l/2)*bs:_=o*bs,_=es(_),h=_>=270||_<=90}h==!0&&m&&(this._textInfo.reverse(),this._textReversed=!0),K(this._textInfo,(w,_)=>{let T=w.height;d||(A+=T),(y==-1&&h||y==1&&!h)&&m&&w.textChunks.reverse();let Q=o;l=0,u=="center"&&(Q+=w.width/(A-T)/2*-y,l=Q-o),Q+=Math.PI*(h?0:1),s.save(),i&&n.save(),b||s.rotate(Q),i&&n.rotate(Q);let U=0;K(w.textChunks,(E,O)=>{let D=E.text,k=E.width;U=k/2/(A-T)*y,b||s.rotate(U),i&&n.rotate(U),E.style&&(s.save(),n.save(),b||(s.font=E.style),i&&(n.font=E.style)),E.fill&&(s.save(),b||(s.fillStyle=E.fill.toCSS())),b||(s.textBaseline="middle",s.textAlign="center"),i&&(n.textBaseline="middle",n.textAlign="center"),r&&!b&&s.fillText(D,0,(h?1:-1)*(0-A+T/2)),i&&B&&n.fillText(D,0,(h?1:-1)*(0-A+T/2)),E.fill&&s.restore(),E.style&&(s.restore(),n.restore()),U=(k/2+g)/(A-T)*y,b||s.rotate(U),i&&n.rotate(U)}),s.restore(),i&&n.restore(),d&&(A-=T)}),s.restore(),i&&n.restore()}}_measure(e){switch(this.textType){case"circular":return this._measureCircular(e);default:return super._measure(e)}}_measureCircular(e){let t=e.layer.context,i=this._renderer._ghostLayer.context,s=this.style.direction=="rtl",r=this.style.oversizedBehavior,n=this.style.maxWidth,A=W(n)&&r=="truncate",o=this.style.ellipsis||"",l;this.textVisible=!0,this._textInfo=[],this._textReversed=!1,t.save(),i.save(),this._prerender(e,!0);let c=this.text.toString().replace(/\r/g,"").split(/\n/),h=!0,d=0,u=0;return K(c,(g,y)=>{let m=Di.chunk(g,!1,this.style.ignoreFormatting),b={offsetY:u,ascent:0,width:0,height:0,left:0,right:0,textChunks:[]},B,w,_;K(m,(T,Q)=>{if(T.type=="format"){if(T.text=="[/]")h||(t.restore(),i.restore(),h=!0),w=void 0,B=void 0,_=void 0;else{let U=Di.getTextStyle(T.text),E=this._getFontStyle(U);t.save(),i.save(),t.font=E,B=E,U.fill&&(w=U.fill),U.width&&(_=Vi(U.width)),h=!1}A&&(l=this._measureText(o,t))}else if(T.type=="value"){let U=T.text.match(/./ug)||[];s&&(U=Xx(T.text),U.reverse());for(let E=0;E<U.length;E++){let O=U[E],D=this._measureText(O,t),k=D.width;B&&_&&_>k&&(k=_);let F=D.actualBoundingBoxAscent+D.actualBoundingBoxDescent;if(F>b.height&&(b.height=F),D.actualBoundingBoxAscent>b.ascent&&(b.ascent=D.actualBoundingBoxAscent),d+=k,A){l||(l=this._measureText(o,t));let M=l.actualBoundingBoxLeft+l.actualBoundingBoxRight;if(d+M>n){b.textChunks.length==1?this.textVisible=!1:(b.width+=M,b.left+=l.actualBoundingBoxLeft,b.right+=l.actualBoundingBoxRight,b.textChunks.push({style:B,fill:w,text:o,width:M,height:F+l.actualBoundingBoxDescent,left:l.actualBoundingBoxLeft,right:l.actualBoundingBoxRight,ascent:l.actualBoundingBoxAscent,offsetX:0,offsetY:F,textDecoration:void 0}));break}}b.width+=k,b.left+=D.actualBoundingBoxLeft,b.right+=D.actualBoundingBoxRight,b.textChunks.push({style:B,fill:w,text:O,width:k,height:F+D.actualBoundingBoxDescent,left:D.actualBoundingBoxLeft,right:D.actualBoundingBoxRight,ascent:D.actualBoundingBoxAscent,offsetX:0,offsetY:F,textDecoration:void 0})}}}),this.style.lineHeight instanceof ke?b.height*=this.style.lineHeight.value:b.height*=this.style.lineHeight||1.2,this._textInfo.push(b),u+=b.height}),h||(t.restore(),i.restore()),r=="hide"&&d>n&&(this.textVisible=!1),K(this._textInfo,g=>{K(g.textChunks,y=>{y.offsetY+=Math.round((g.height-y.height+(g.ascent-y.ascent))/2)})}),t.restore(),i.restore(),{left:0,top:0,right:0,bottom:0}}},Ag=class extends LA{constructor(e,t){super(e),this.image=t}_dispose(){super._dispose(),this._imageMask&&Wo(this._imageMask)}getLocalBounds(){if(!this._localBounds){let e=0,t=0;this.width&&(e=this.width),this.height&&(t=this.height),this._localBounds={left:0,top:0,right:e,bottom:t},this._addBounds(this._localBounds)}return this._localBounds}_render(e,t=0){if(super._render(e),this.image){if(this.tainted===void 0&&(this.tainted=hb(this.image),e.layer.tainted=!0),this.tainted&&this._renderer._omitTainted)return;let i=this._ghostOnly(t),s=this._drawGhost(e,t);if(e.layer.dirty&&!i){this.shadowColor&&(e.layer.context.shadowColor=this.shadowColor.toCSS(this.shadowOpacity||1)),this.shadowBlur&&(e.layer.context.shadowBlur=this.shadowBlur),this.shadowOffsetX&&(e.layer.context.shadowOffsetX=this.shadowOffsetX),this.shadowOffsetY&&(e.layer.context.shadowOffsetY=this.shadowOffsetY);let r=this.width||this.image.naturalWidth,n=this.height||this.image.naturalHeight;e.layer.context.drawImage(this.image,0,0,r,n)}if(this.interactive&&this._isInteractive(e)&&s){let r=this._getMask(this.image);this._renderer._ghostLayer.context.drawImage(r,0,0)}}}clear(){super.clear(),this.image=void 0,this._imageMask=void 0}_getMask(e){if(this._imageMask===void 0){let t=this.width||e.naturalWidth,i=this.height||e.naturalHeight,s=document.createElement("canvas");s.width=t,s.height=i;let r=s.getContext("2d");r.imageSmoothingEnabled=!1,r.fillStyle=this._getColorId(),r.fillRect(0,0,t,i),hb(e)||(r.globalCompositeOperation="destination-in",r.drawImage(e,0,0,t,i)),this._imageMask=s}return this._imageMask}},og=class{constructor(e,t,i,s){this.event=e,this.originalPoint=t,this.point=i,this.bbox=s,this.simulated=!1,this.native=!0,zs("touchevents")&&e instanceof Touch?this.id=e.identifier:this.id=null}},nc=class extends Hh{constructor(e){if(super(),this.view=document.createElement("div"),this._layerDom=document.createElement("div"),this.layers=[],this._dirtyLayers=[],this.defaultLayer=this.getLayer(0),this._ghostLayer=new lg,this._deferredGhostLayers=[],this._patternCanvas=document.createElement("canvas"),this._patternContext=this._patternCanvas.getContext("2d"),this._realWidth=0,this._realHeight=0,this._calculatedWidth=0,this._calculatedHeight=0,this.interactionsEnabled=!0,this._listeners={},this._events={},this._colorId=0,this._colorMap={},this._forceInteractive=0,this._omitTainted=!1,this._hovering=new Set,this._dragging=[],this._mousedown=[],this.tapToActivate=!1,this.tapToActivateTimeout=3e3,this._touchActive=!1,e==null?this.resolution=window.devicePixelRatio:this.resolution=e,this.view.style.position="absolute",this.view.setAttribute("aria-hidden","true"),this.view.appendChild(this._layerDom),this._disposers.push(new Qt(()=>{Ve(this._events,(t,i)=>{i.disposer.dispose()}),K(this.layers,t=>{Wo(t.view),t.exportableView&&Wo(t.exportableView)}),Wo(this._ghostLayer.view),Wo(this._patternCanvas)})),this._disposers.push(Oh(()=>{e==null&&(this.resolution=window.devicePixelRatio)})),zs("touchevents")){let t=i=>{this._dragging.length!==0&&Lo(this._dragging,s=>s.value.shouldCancelTouch()?(i.preventDefault(),!1):!0),this._touchActiveTimeout&&this._delayTouchDeactivate()};this._disposers.push(kt(window,"touchstart",t,{passive:!1})),this._disposers.push(kt(this.view,"touchstart",t,{passive:!1})),this._disposers.push(kt(this.view,"touchmove",()=>{this._touchActiveTimeout&&this._delayTouchDeactivate()},{passive:!0})),this._disposers.push(kt(window,"click",i=>{this._touchActive=!1},{passive:!0})),this._disposers.push(kt(this.view,"click",i=>{window.setTimeout(()=>{this._touchActive=!0,this._delayTouchDeactivate()},100)},{passive:!0}))}zs("wheelevents")&&this._disposers.push(kt(this.view,"wheel",t=>{let i=!1;this._hovering.forEach(s=>{if(s.wheelable)return i=!0,!1}),i&&t.preventDefault()},{passive:!1}))}resetImageArray(){this._ghostLayer.imageArray=void 0}_delayTouchDeactivate(){this._touchActiveTimeout&&clearTimeout(this._touchActiveTimeout),this.tapToActivateTimeout>0&&(this._touchActiveTimeout=window.setTimeout(()=>{this._touchActive=!1},this.tapToActivateTimeout))}get debugGhostView(){return!!this._ghostLayer.view.parentNode}set debugGhostView(e){e?this._ghostLayer.view.parentNode||this.view.appendChild(this._ghostLayer.view):this._ghostLayer.view.parentNode&&this._ghostLayer.view.parentNode.removeChild(this._ghostLayer.view)}createLinearGradient(e,t,i,s){return this.defaultLayer.context.createLinearGradient(e,t,i,s)}createRadialGradient(e,t,i,s,r,n){return this.defaultLayer.context.createRadialGradient(e,t,i,s,r,n)}createPattern(e,t,i,s,r){return this._patternCanvas.width=s,this._patternCanvas.height=r,this._patternContext.clearRect(0,0,s,r),t.renderDetached(this._patternContext),e.renderDetached(this._patternContext),this._patternContext.createPattern(this._patternCanvas,i)}makeContainer(){return new Of(this)}makeGraphics(){return new rg(this)}makeText(e,t){return new ac(this,e,t)}makeTextStyle(){return new ag}makeRadialText(e,t){return new ng(this,e,t)}makePicture(e){return new Ag(this,e)}resizeLayer(e){e.resize(this._calculatedWidth,this._calculatedHeight,this._calculatedWidth,this._calculatedHeight,this.resolution)}resizeGhost(){this._ghostLayer.resize(this._calculatedWidth,this._calculatedHeight,this._calculatedWidth,this._calculatedHeight,this.resolution)}resize(e,t,i,s){this._realWidth=e,this._realHeight=t,this._calculatedWidth=i,this._calculatedHeight=s,K(this.layers,r=>{r&&(r.dirty=!0,this.resizeLayer(r))}),this.resizeGhost(),this.view.style.width=i+"px",this.view.style.height=s+"px"}createDetachedLayer(e=!1){let t=document.createElement("canvas"),i=t.getContext("2d",{willReadFrequently:e}),s=new hg(t,i);return t.style.position="absolute",t.style.top="0px",t.style.left="0px",s}getLayerByOrder(e){let t=this.layers,i=t.length;for(let s=0;s<i;s++){let r=t[s];if(r.order==e)return r}}getLayer(e,t=!0){let i=this.getLayerByOrder(e);if(i)return i;let s=this.createDetachedLayer(e==99);s.order=e,s.visible=t,s.view.className="am5-layer-"+e,s.visible&&this.resizeLayer(s);let r=this.layers;r.push(s),r.sort((l,c)=>l.order>c.order?1:l.order<c.order?-1:0);let n=r.length,A=Qr(r,s),o;for(let l=A+1;l<n;l++)if(r[l].visible){o=r[l];break}return s.visible&&(o===void 0?this._layerDom.appendChild(s.view):this._layerDom.insertBefore(s.view,o.view)),s}render(e){this._dirtyLayers.length=0,this._deferredGhostLayers=[],K(this.layers,i=>{i&&i.dirty&&i.visible&&(this._dirtyLayers.push(i),i.clear())}),this._ghostLayer.clear(),e.render({inactive:null,layer:this.defaultLayer});let t=this._deferredGhostLayers;if(t.length&&(t.sort((i,s)=>i-s),K(t,i=>{e.render({inactive:null,layer:this.defaultLayer},i)})),this._ghostLayer.context.restore(),K(this.layers,i=>{if(i){let s=i.context;s.beginPath(),s.moveTo(0,0),s.stroke()}}),K(this._dirtyLayers,i=>{i.context.restore(),i.dirty=!1}),this._hovering.size&&this._lastPointerMoveEvent){let{events:i,target:s,native:r}=this._lastPointerMoveEvent;K(i,n=>{this._dispatchGlobalMousemove(n,s,r)})}}paintId(e){let t=xT(++this._colorId),i=we.fromHex(t).toCSS();return this._colorMap[i]=e,i}_removeObject(e){e._colorId!==void 0&&delete this._colorMap[e._colorId]}_adjustBoundingBox(e){let t=this._ghostLayer.margin;return new DOMRect(-t.left,-t.top,e.width+t.left+t.right,e.height+t.top+t.bottom)}getEvent(e,t=!0){let i=this.view.getBoundingClientRect(),s=e.clientX||0,r=e.clientY||0,n=this._calculatedWidth/this._realWidth,A=this._calculatedHeight/this._realHeight,o={x:s-i.left,y:r-i.top},l={x:(s-(t?i.left:0))*n,y:(r-(t?i.top:0))*A};return new og(e,o,l,this._adjustBoundingBox(i))}_getHitTarget(e,t,i){if(t.width===0||t.height===0||e.x<t.left||e.x>t.right||e.y<t.top||e.y>t.bottom||!i||!this._layerDom.contains(i))return;let s=this._ghostLayer.getImageData(e,t);if(s.data[0]===0&&s.data[1]===0&&s.data[2]===0)return!1;let r=we.fromRGB(s.data[0],s.data[1],s.data[2]).toCSS();return this._colorMap[r]}getObjectAtPoint(e){let t=this._ghostLayer.getImageArray(e);if(t[0]===0&&t[1]===0&&t[2]===0)return;let i=we.fromRGB(t[0],t[1],t[2]).toCSS();return this._colorMap[i]}_withEvents(e,t){let i=this._events[e];if(i!==void 0){i.dispatching=!0;try{t(i)}finally{i.dispatching=!1,i.cleanup&&(i.cleanup=!1,Un(i.callbacks,s=>!s.disposed),i.callbacks.length===0&&(i.disposer.dispose(),delete this._events[e]))}}}_dispatchEventAll(e,t){this.interactionsEnabled&&this._withEvents(e,i=>{K(i.callbacks,s=>{s.disposed||s.callback.call(s.context,t)})})}_dispatchEvent(e,t,i){if(!this.interactionsEnabled)return!1;let s=!1;return this._withEvents(e,r=>{K(r.callbacks,n=>{!n.disposed&&n.object===t&&(n.callback.call(n.context,i),s=!0)})}),s}_dispatchMousedown(e,t){let i=e.button;if(i!=0&&i!=2&&i!=1&&i!==void 0)return;let s=this.getEvent(e),r=this._getHitTarget(s.originalPoint,s.bbox,t);if(r){let n=s.id,A=!1;rc(r,o=>{let l={id:n,value:o};return this._mousedown.push(l),!A&&this._dispatchEvent("pointerdown",o,s)&&(A=!0,this._dragging.some(h=>h.value===o&&h.id===n)||this._dragging.push(l)),!0})}}_dispatchGlobalMousemove(e,t,i){let s=this.getEvent(e),r=this._getHitTarget(s.originalPoint,s.bbox,t);s.native=i,r?(this._hovering.forEach(n=>{n.contains(r)||(this._hovering.delete(n),n.cursorOverStyle&&Ho(document.body,"cursor",n._replacedCursorStyle),this._dispatchEvent("pointerout",n,s))}),s.native&&rc(r,n=>(this._hovering.has(n)||(this._hovering.add(n),n.cursorOverStyle&&(n._replacedCursorStyle=Vx(document.body,"cursor"),Ho(document.body,"cursor",n.cursorOverStyle)),this._dispatchEvent("pointerover",n,s)),!0))):(this._hovering.forEach(n=>{n.cursorOverStyle&&Ho(document.body,"cursor",n._replacedCursorStyle),this._dispatchEvent("pointerout",n,s)}),this._hovering.clear()),this._dispatchEventAll("globalpointermove",s)}removeHovering(e){this._hovering.delete(e),e.cursorOverStyle&&Ho(document.body,"cursor",e._replacedCursorStyle)}_dispatchGlobalMouseup(e,t){let i=this.getEvent(e);i.native=t,this._dispatchEventAll("globalpointerup",i)}_dispatchDragMove(e){if(this._dragging.length!==0){let t=this.getEvent(e),i=t.id;this._dragging.forEach(s=>{s.id===i&&this._dispatchEvent("pointermove",s.value,t)})}}_dispatchDragEnd(e,t){let i=e.button,s;if(i==0||i===void 0)s="click";else if(i==2)s="rightclick";else if(i==1)s="middleclick";else return;let r=this.getEvent(e),n=r.id;if(this._mousedown.length!==0){let A=this._getHitTarget(r.originalPoint,r.bbox,t);A&&this._mousedown.forEach(o=>{o.id===n&&o.value.contains(A)&&this._dispatchEvent(s,o.value,r)}),this._mousedown.length=0}this._dragging.length!==0&&(this._dragging.forEach(A=>{A.id===n&&this._dispatchEvent("pointerup",A.value,r)}),this._dragging.length=0)}_dispatchDoubleClick(e,t){let i=this.getEvent(e),s=this._getHitTarget(i.originalPoint,i.bbox,t);s&&rc(s,r=>!this._dispatchEvent("dblclick",r,i))}_dispatchWheel(e,t){let i=this.getEvent(e),s=this._getHitTarget(i.originalPoint,i.bbox,t);s&&rc(s,r=>!this._dispatchEvent("wheel",r,i))}_makeSharedEvent(e,t){if(this._listeners[e]===void 0){let i=t();this._listeners[e]=new _A(()=>{delete this._listeners[e],i.dispose()})}return this._listeners[e].increment()}_onPointerEvent(e,t){let i=!1,s=null;function r(){s=null,i=!1}return new zt([new Qt(()=>{s!==null&&clearTimeout(s),r()}),kt(this.view,Vh(e),n=>{i=!0,s!==null&&clearTimeout(s),s=window.setTimeout(r,0)}),bT(window,e,(n,A)=>{s!==null&&(clearTimeout(s),s=null),t(n,A,i),i=!1})])}_initEvent(e){switch(e){case"globalpointermove":case"pointerover":case"pointerout":return this._makeSharedEvent("pointermove",()=>{let t=(i,s,r)=>{this._lastPointerMoveEvent={events:i,target:s,native:r},K(i,n=>{this._dispatchGlobalMousemove(n,s,r)})};return new zt([this._onPointerEvent("pointerdown",t),this._onPointerEvent("pointermove",t)])});case"globalpointerup":return this._makeSharedEvent("pointerup",()=>{let t=this._onPointerEvent("pointerup",(s,r,n)=>{K(s,A=>{this._dispatchGlobalMouseup(A,n)}),this._lastPointerMoveEvent={events:s,target:r,native:n}}),i=this._onPointerEvent("pointercancel",(s,r,n)=>{K(s,A=>{this._dispatchGlobalMouseup(A,n)}),this._lastPointerMoveEvent={events:s,target:r,native:n}});return new Qt(()=>{t.dispose(),i.dispose()})});case"click":case"rightclick":case"middleclick":case"pointerdown":case"pointermove":case"pointerup":return this._makeSharedEvent("pointerdown",()=>{let t=this._onPointerEvent("pointerdown",(n,A)=>{K(n,o=>{this._dispatchMousedown(o,A)})}),i=this._onPointerEvent("pointermove",n=>{K(n,A=>{this._dispatchDragMove(A)})}),s=this._onPointerEvent("pointerup",(n,A)=>{K(n,o=>{this._dispatchDragEnd(o,A)})}),r=this._onPointerEvent("pointercancel",(n,A)=>{K(n,o=>{this._dispatchDragEnd(o,A)})});return new Qt(()=>{t.dispose(),i.dispose(),s.dispose(),r.dispose()})});case"dblclick":return this._makeSharedEvent("dblclick",()=>this._onPointerEvent("dblclick",(t,i)=>{K(t,s=>{this._dispatchDoubleClick(s,i)})}));case"wheel":return this._makeSharedEvent("wheel",()=>kt(this.view,Vh("wheel"),t=>{this._dispatchWheel(t,df(t))},{passive:!1}))}}_addEvent(e,t,i,s){let r=this._events[t];r===void 0&&(r=this._events[t]={disposer:this._initEvent(t),callbacks:[],dispatching:!1,cleanup:!1});let n={object:e,context:s,callback:i,disposed:!1};return r.callbacks.push(n),new Qt(()=>{n.disposed=!0,r.dispatching?r.cleanup=!0:(Jt(r.callbacks,n),r.callbacks.length===0&&(r.disposer.dispose(),delete this._events[t]))})}getCanvas(e,t){this.render(e),t||(t={});let i=this.resolution,s=Math.floor(this._calculatedWidth*this.resolution),r=Math.floor(this._calculatedHeight*this.resolution);if(t.minWidth&&t.minWidth>s){let u=t.minWidth/s;u>i&&(i=u*this.resolution)}if(t.minHeight&&t.minHeight>r){let u=t.minHeight/r;u>i&&(i=u*this.resolution)}if(t.maxWidth&&t.maxWidth<s){let u=t.maxWidth/s;u<i&&(i=u*this.resolution)}if(t.maxHeight&&t.maxHeight>r){let u=t.maxHeight/r;u<i&&(i=u*this.resolution)}t.maintainPixelRatio&&(i/=this.resolution);let n=[],A=!1,o=document.createElement("canvas");i!=this.resolution&&(A=!0,s=s*i/this.resolution,r=r*i/this.resolution),o.width=s,o.height=r,o.style.position="fixed",o.style.top="-10000px",this.view.appendChild(o),n.push(o);let l=o.getContext("2d"),c=0,h=0,d=!1;return K(this.layers,u=>{if(u&&u.visible&&(u.tainted||A)){d=!0,u.exportableView=u.view,u.exportableContext=u.context,u.view=document.createElement("canvas"),u.view.style.position="fixed",u.view.style.top="-10000px",this.view.appendChild(u.view),n.push(u.view);let g=0,y=0;u.margin&&(g+=u.margin.left||0+u.margin.right||0,y+=u.margin.top||0+u.margin.bottom||0),u.view.width=s+g,u.view.height=r+y,u.context=u.view.getContext("2d"),u.dirty=!0,u.scale=i}}),d&&(this._omitTainted=!0,this.render(e),this._omitTainted=!1),K(this.layers,u=>{if(u&&u.visible){let g=0,y=0;u.margin&&(g=-(u.margin.left||0)*this.resolution,y=-(u.margin.top||0)*this.resolution),l.drawImage(u.view,g,y),u.exportableView&&(u.view=u.exportableView,u.exportableView=void 0),u.exportableContext&&(u.context=u.exportableContext,u.exportableContext=void 0),c<u.view.clientWidth&&(c=u.view.clientWidth),h<u.view.clientHeight&&(h=u.view.clientHeight),u.scale=void 0}}),o.style.width=c+"px",o.style.height=h+"px",K(n,u=>{u.style.position="",u.style.top="",this.view.removeChild(u)}),o}},lg=class{constructor(){this.margin={left:0,right:0,top:0,bottom:0},this._resolution=1,this._width=0,this._height=0,this.view=document.createElement("canvas"),this.context=this.view.getContext("2d",{alpha:!1,willReadFrequently:!0}),this.context.imageSmoothingEnabled=!1,this.view.style.position="absolute",this.view.style.top="0px",this.view.style.left="0px"}resize(e,t,i,s,r){this._resolution=r,e+=this.margin.left+this.margin.right,t+=this.margin.top+this.margin.bottom,i+=this.margin.left+this.margin.right,s+=this.margin.top+this.margin.bottom,this.view.style.left=-this.margin.left+"px",this.view.style.top=-this.margin.top+"px",this._width=Math.floor(e*r),this._height=Math.floor(t*r),this.view.width=this._width,this.view.style.width=i+"px",this.view.height=this._height,this.view.style.height=s+"px"}getImageData(e,t){return this.context.getImageData(Math.round((e.x-t.left)/t.width*this._width),Math.round((e.y-t.top)/t.height*this._height),1,1)}getImageArray(e){this.imageArray||(this.imageArray=this.context.getImageData(0,0,this._width,this._height).data);let t=this.imageArray,i=Math.round(e.x*this._resolution),r=(Math.round(e.y*this._resolution)*this._width+i)*4;return[t[r],t[r+1],t[r+2],t[r+3]]}setMargin(e){this.margin.left=0,this.margin.right=0,this.margin.top=0,this.margin.bottom=0,K(e,t=>{t.margin&&(this.margin.left=Math.max(this.margin.left,t.margin.left),this.margin.right=Math.max(this.margin.right,t.margin.right),this.margin.top=Math.max(this.margin.top,t.margin.top),this.margin.bottom=Math.max(this.margin.bottom,t.margin.bottom))})}clear(){this.context.save(),this.context.fillStyle="#000",this.context.fillRect(0,0,this._width,this._height)}},hg=class{constructor(e,t){this.tainted=!0,this.order=0,this.visible=!0,this.dirty=!0,this._width=0,this._height=0,this.view=e,this.context=t}resize(e,t,i,s,r){this.width!=null&&(e=this.width,i=this.width),this.height!=null&&(t=this.height,s=this.height),this.margin?(e+=this.margin.left+this.margin.right,t+=this.margin.top+this.margin.bottom,i+=this.margin.left+this.margin.right,s+=this.margin.top+this.margin.bottom,this.view.style.left=-this.margin.left+"px",this.view.style.top=-this.margin.top+"px"):(this.view.style.left="0px",this.view.style.top="0px"),this._width=Math.floor(e*r),this._height=Math.floor(t*r),this.view.width=this._width,this.view.style.width=i+"px",this.view.height=this._height,this.view.style.height=s+"px"}clear(){this.context.save(),this.context.clearRect(0,0,this._width,this._height)}};function db(a,e){a==null?requestAnimationFrame(e):setTimeout(()=>{requestAnimationFrame(e)},1e3/a)}var Rn=class a{constructor(e,t={},i){if(this._isDirty=!1,this._isDirtyParents=!1,this._isDirtyAnimation=!1,this._dirty={},this._dirtyParents={},this._dirtyBounds={},this._dirtyPositions={},this._ticker=null,this._tickers=[],this._updateTick=!0,this.skipRenderFrame=!1,this.events=new Ls,this.animationTime=null,this._animations=[],this.language=ic.new(this,{}),this.locale=tc,this.utc=!1,this.numberFormatter=za.new(this,{}),this.dateFormatter=Hn.new(this,{}),this.durationFormatter=ec.new(this,{}),this.tabindex=0,this._tabindexes=[],this._a11yD=!1,this._focusElementDirty=!1,this._skipNextGroupJump=!0,this.verticalLayout=Er.new(this,{}),this.horizontalLayout=kr.new(this,{}),this.gridLayout=js.new(this,{}),this._paused=!1,this.autoResize=!0,this._fontHash=[],this._isDisposed=!1,this._disposers=[],this._tooltips=[],this._htmlEnabledContainers=[],this.entitiesById={},!i)throw new Error("You cannot use `new Class()`, instead use `Class.new()`");this._settings=t,t.accessible==!1&&(this._a11yD=!0),t.useSafeResolution==null&&(t.useSafeResolution=!0);let s;t.useSafeResolution&&(s=$x()),this._renderer=new nc(s);let r;if(e instanceof HTMLElement?r=e:r=document.getElementById(e),K(ls.rootElements,o=>{if(o.dom===r)if(ls.autoDispose)o.dispose();else throw new Error("You cannot have multiple Roots on the same DOM node")}),this.interfaceColors=Pn.new(this,{}),r===null)throw new Error("Could not find HTML element with id `"+e+"`");this.dom=r;let n=document.createElement("div");n.style.position="relative",n.style.width="100%",n.style.height="100%",r.appendChild(n);let A=t.tooltipContainerBounds;A&&(this._tooltipContainerSettings=A),this._inner=n,this._updateComputedStyles(),ls.rootElements.push(this)}static new(e,t){let i=new a(e,t,!0);return i._init(),i}moveDOM(e){let t;if(e instanceof HTMLElement?t=e:t=document.getElementById(e),t){for(;this.dom.childNodes.length>0;)t.appendChild(this.dom.childNodes[0]);this.dom=t,this._initResizeSensor(),this.resize()}}_handleLogo(){if(this._logo){let e=this.dom.offsetWidth,t=this.dom.offsetHeight;e<=150||t<=60?this._logo.hide():this._logo.show()}}_showBranding(){if(!this._logo){let e=this.tooltipContainer.children.push(pe.new(this,{interactive:!0,interactiveChildren:!1,position:"absolute",setStateOnChildren:!0,paddingTop:9,paddingRight:9,paddingBottom:9,paddingLeft:9,scale:.6,y:Re(100),centerY:se,tooltipY:10,tooltipText:"Created using amCharts 5",tooltipX:se,cursorOverStyle:"pointer",background:Tt.new(this,{fill:$i(4671320),fillOpacity:0,tooltipY:5})}));e.set("tooltip",this.systemTooltip),e.events.on("click",()=>{window.open("https://www.amcharts.com/","_blank")}),e.states.create("hover",{});let t=e.children.push(Le.new(this,{stroke:$i(13421772),strokeWidth:3,svgPath:"M5 25 L13 25h13.6c3.4 0 6 0 10.3-4.3s5.2-12 8.6-12c3.4 0 4.3 8.6 7.7 8.6M83.4 25H79.8c-3.4 0-6 0-10.3-4.3s-5.2-12-8.6-12-4.3 8.6-7.7 8.6",dx:-50,strokeOpacity:0}));t.states.create("hover",{stroke:$i(3976191)});let i=e.children.push(Le.new(this,{stroke:$i(8947848),strokeWidth:3,svgPath:"M83.4 25h-31C37 25 39.5 4.4 28.4 4.4S18.9 24.2 4.3 25H0",dx:50,strokeOpacity:0})),s=fa(dr),r=1500;e.setTimeout(()=>{i.animate({key:"strokeOpacity",to:1,duration:r,easing:s}),i.animate({key:"dx",to:0,duration:r,easing:s}),t.animate({key:"dx",to:0,duration:r,easing:s}),t.animate({key:"strokeOpacity",to:1,duration:r,easing:s})},3e3),i.states.create("hover",{stroke:$i(4671320)}),this._logo=e,this._handleLogo()}}_getRealSize(){return this.dom.getBoundingClientRect()}_getCalculatedSize(e){return this._settings.calculateSize?this._settings.calculateSize(e):{width:e.width,height:e.height}}_init(){let e=this._settings;e.accessible!==!1&&(e.focusable&&(this._inner.setAttribute("focusable","true"),this._inner.setAttribute("tabindex",this.tabindex+"")),e.ariaLabel&&this._inner.setAttribute("aria-label",e.ariaLabel),e.role&&this._inner.setAttribute("role",e.role));let t=this._renderer,i=this._getRealSize(),s=this._getCalculatedSize(i),r=Math.floor(s.width),n=Math.floor(s.height),A=Math.floor(i.width),o=Math.floor(i.height),l=pe.new(this,{visible:!0,width:r,height:n});this._rootContainer=l,this._rootContainer._defaultThemes.push(sc.new(this));let c=l.children.push(pe.new(this,{visible:!0,width:se,height:se}));this.container=c,t.resize(A,o,r,n),this._inner.appendChild(t.view),this._initResizeSensor();let h=document.createElement("div");if(this._htmlElementContainer=h,h.className="am5-html-container",h.style.position="absolute",h.style.pointerEvents="none",this._tooltipContainerSettings||(h.style.overflow="hidden"),this._inner.appendChild(h),this._a11yD!==!0){let d=document.createElement("div");d.className="am5-reader-container",d.setAttribute("role","alert"),d.style.position="absolute",d.style.width="1px",d.style.height="1px",d.style.overflow="hidden",d.style.clip="rect(1px, 1px, 1px, 1px)",this._readerAlertElement=d,this._inner.appendChild(this._readerAlertElement);let u=document.createElement("div");u.className="am5-focus-container",u.style.position="absolute",u.style.pointerEvents="none",u.style.top="0px",u.style.left="0px",u.style.overflow="hidden",u.style.width=r+"px",u.style.height=n+"px",u.setAttribute("role","graphics-document"),Ka(u,!1),this._focusElementContainer=u,this._inner.appendChild(this._focusElementContainer);let g=document.createElement("div");this._tooltipElementContainer=g,g.className="am5-tooltip-container",this._inner.appendChild(g),zs("keyboardevents")&&(this._disposers.push(kt(window,"keydown",y=>{let m=kn(y);m=="Shift"?this._isShift=!0:m=="Tab"&&(this._isShift=y.shiftKey)})),this._disposers.push(kt(window,"keyup",y=>{kn(y)=="Shift"&&(this._isShift=!1)})),this._disposers.push(kt(u,"click",()=>{let y=this._focusedSprite;if(y){let m=y.get("clickAnnounceText","");m!==""&&this.readerAlert(m);let b=t.getEvent(new MouseEvent("click"));y.events.dispatch("click",{type:"click",originalEvent:b.event,point:b.point,simulated:!0,target:y})}})),this._disposers.push(kt(u,"keydown",y=>{let m=this._focusedSprite;if(m){y.key=="Escape"&&(Ox(),this._focusedSprite=void 0);let b=0,B=0,w=kn(y);switch(w){case"Enter":case" ":let _=m.get("clickAnnounceText","");if(_!==""&&this.readerAlert(_),w==" "&&m.get("role")!="checkbox")return;y.preventDefault();let T=t.getEvent(new MouseEvent("mouse"));m.events.dispatch("click",{type:"click",originalEvent:T.event,point:T.point,simulated:!0,target:m});return;case"ArrowLeft":b=-6;break;case"ArrowRight":b=6;break;case"ArrowUp":B=-6;break;case"ArrowDown":B=6;break;default:return}if(b!=0||B!=0){if(y.preventDefault(),!m.isDragging()){this._keyboardDragPoint={x:0,y:0};let Q=t.getEvent(new MouseEvent("mousedown",{clientX:0,clientY:0}));Q.point={x:0,y:0},m.events.isEnabled("pointerdown")&&m.events.dispatch("pointerdown",{type:"pointerdown",originalEvent:Q.event,point:Q.point,simulated:!0,target:m})}let _=this._keyboardDragPoint;_.x+=b,_.y+=B;let T=t.getEvent(new MouseEvent("mousemove",{clientX:_.x,clientY:_.y}),!1);m.events.isEnabled("globalpointermove")&&m.events.dispatch("globalpointermove",{type:"globalpointermove",originalEvent:T.event,point:T.point,simulated:!0,target:m})}}})),this._disposers.push(kt(u,"keyup",y=>{if(this._focusedSprite){let m=this._focusedSprite,b=kn(y);switch(b){case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"ArrowDown":if(m.isDragging()){let w=this._keyboardDragPoint,_=t.getEvent(new MouseEvent("mouseup",{clientX:w.x,clientY:w.y}));m.events.isEnabled("globalpointerup")&&m.events.dispatch("globalpointerup",{type:"globalpointerup",originalEvent:_.event,point:_.point,simulated:!0,target:m}),this._keyboardDragPoint=void 0;return}else if(m.get("focusableGroup")){let w=m.get("focusableGroup"),_=this._tabindexes.filter(U=>!!(U.get("focusableGroup")==w&&U.getPrivate("focusable")!==!1&&U.isVisibleDeep())),T=_.indexOf(m),Q=_.length-1;T+=b=="ArrowRight"||b=="ArrowDown"?1:-1,T<0?T=Q:T>Q&&(T=0),Nx(_[T].getPrivate("focusElement").dom)}break;case"Tab":let B=m.get("focusableGroup");if(B&&this._isShift){this._skipNextGroupJump||(this._focusNext(m.getPrivate("focusElement").dom,-1,B),this._skipNextGroupJump=!0);return}break}}})))}this._startTicker(),this.setThemes([]),this._addTooltip(),this._hasLicense()||this._showBranding()}get systemTooltip(){if(!this._systemTooltip){let e=ai.new(this,{themeTags:["system"]});this._systemTooltip=e}return this._systemTooltip}_initResizeSensor(){this._resizeSensorDisposer&&this._resizeSensorDisposer.dispose(),this._resizeSensorDisposer=new Jh(this.dom,()=>{this.autoResize&&this.resize()}),this._disposers.push(this._resizeSensorDisposer)}resize(){let e=this._getRealSize(),t=this._getCalculatedSize(e),i=Math.floor(t.width),s=Math.floor(t.height);if(i>0&&s>0){let r=Math.floor(e.width),n=Math.floor(e.height),A=this._htmlElementContainer;if(A.style.width=i+"px",A.style.height=s+"px",this._a11yD!==!0){let l=this._focusElementContainer;l.style.width=i+"px",l.style.height=s+"px"}this._renderer.resize(r,n,i,s);let o=this._rootContainer;o.setPrivate("width",i),o.setPrivate("height",s),this._render(),this._handleLogo()}}_render(){if(this.skipRenderFrame){this.skipRenderFrame=!1;return}this._renderer.render(this._rootContainer._display),this._focusElementDirty&&(this._updateCurrentFocus(),this._focusElementDirty=!1)}_runTickers(e){K(this._tickers,t=>{t(e)})}_runAnimations(e){let t=0;return Un(this._animations,i=>{let s=i._runAnimation(e);return s===ua.Stopped?!1:(s===ua.Playing&&++t,!0)}),this._isDirtyAnimation=!1,t===0}_runDirties(){let e={};for(;this._isDirtyParents;)this._isDirtyParents=!1,Ds(this._dirtyParents).forEach(([n,A])=>{delete this._dirtyParents[n],A.isDisposed()||(e[A.uid]=A,A._prepareChildren())});Ds(e).forEach(([n,A])=>{A._updateChildren()});let t=[];Ds(this._dirty).forEach(([n,A])=>{A.isDisposed()?delete this._dirty[n]:(t.push(A),A._beforeChanged())}),t.forEach(n=>{n._changed(),delete this._dirty[n.uid],n._clearDirty()}),this._isDirty=!1;let i={},s=[];Ds(this._dirtyBounds).forEach(([n,A])=>{delete this._dirtyBounds[n],A.isDisposed()||(i[A.uid]=A.depth(),s.push(A))}),this._positionHTMLElements(),s.sort((n,A)=>Bs(i[A.uid],i[n.uid])),s.forEach(n=>{n._updateBounds()});let r=this._dirtyPositions;Ds(r).forEach(([n,A])=>{delete r[n],A.isDisposed()||A._updatePosition()}),t.forEach(n=>{n._afterChanged()}),Ds(e).forEach(([n,A])=>{A._childrenPrep=!1,A._childrenUpdt=!1})}_renderFrame(e){if(this._updateTick){this.events.isEnabled("framestarted")&&this.events.dispatch("framestarted",{type:"framestarted",target:this,timestamp:e}),this._checkComputedStyles(),this._runTickers(e);let t=this._runAnimations(e);return this._runDirties(),this._render(),this._renderer.resetImageArray(),this._positionHTMLElements(),this.events.isEnabled("frameended")&&this.events.dispatch("frameended",{type:"frameended",target:this,timestamp:e}),this._tickers.length===0&&t&&!this._isDirtyAnimation&&!this._isDirty}else return!0}_runTicker(e,t){this.isDisposed()||(this.animationTime=e,this._renderFrame(e)?(this._ticker=null,this.animationTime=null):this._paused||(t?this._ticker:db(this.fps,this._ticker)))}_runTickerNow(e=1e4){if(!this.isDisposed()){let t=performance.now()+e;for(;;){let i=performance.now();if(i>=t){this.animationTime=null;break}if(this.animationTime=i,this._renderFrame(i)){this.animationTime=null;break}}}}_startTicker(){this._ticker===null&&(this.animationTime=null,this._ticker=e=>{this._runTicker(e)},db(this.fps,this._ticker))}get updateTick(){return this._updateTick}set updateTick(e){this._updateTick=e,e&&this._startTicker()}_addDirtyEntity(e){this._isDirty=!0,this._dirty[e.uid]===void 0&&(this._dirty[e.uid]=e),this._startTicker()}_addDirtyParent(e){this._isDirty=!0,this._isDirtyParents=!0,this._dirtyParents[e.uid]===void 0&&(this._dirtyParents[e.uid]=e),this._startTicker()}_addDirtyBounds(e){this._isDirty=!0,this._dirtyBounds[e.uid]===void 0&&(this._dirtyBounds[e.uid]=e),this._startTicker()}_addDirtyPosition(e){this._isDirty=!0,this._dirtyPositions[e.uid]===void 0&&(this._dirtyPositions[e.uid]=e),this._startTicker()}_addAnimation(e){this._isDirtyAnimation=!0,this._animations.indexOf(e)===-1&&this._animations.push(e),this._startTicker()}_markDirty(){this._isDirty=!0}_markDirtyRedraw(){this.events.once("frameended",()=>{this._isDirty=!0,this._startTicker()})}eachFrame(e){return this._tickers.push(e),this._startTicker(),new Qt(()=>{Jt(this._tickers,e)})}markDirtyGlobal(e){e||(e=this.container),e.walkChildren(t=>{t instanceof pe&&this.markDirtyGlobal(t),t.markDirty(),t.markDirtyBounds()})}width(){return Math.floor(this._getCalculatedSize(this._getRealSize()).width)}height(){return Math.floor(this._getCalculatedSize(this._getRealSize()).height)}dispose(){this._isDisposed||(this._isDisposed=!0,this._rootContainer.dispose(),this._renderer.dispose(),this.horizontalLayout.dispose(),this.verticalLayout.dispose(),this.interfaceColors.dispose(),K(this._disposers,e=>{e.dispose()}),this._inner&&Rx(this._inner),ri(ls.rootElements,this))}isDisposed(){return this._isDisposed}readerAlert(e){if(this._a11yD!==!0){let t=this._readerAlertElement;e=ff(e),t.innerHTML==e&&(t.innerHTML=""),t.innerHTML=e}}setThemes(e){this._rootContainer.set("themes",e);let t=this.tooltipContainer;t&&t._applyThemes();let i=this.interfaceColors;i&&i._applyThemes()}_addTooltip(){if(!this.tooltipContainer){let e=this._tooltipContainerSettings,t=this._rootContainer.children.push(pe.new(this,{position:"absolute",isMeasured:!1,width:se,height:se,layer:e?35:30,layerMargin:e||void 0}));this.tooltipContainer=t;let i=ai.new(this,{});this.container.set("tooltip",i),i.hide(0),this._tooltip=i}}_registerTabindexOrder(e){this._a11yD!=!0&&(e.get("focusable")?Na(this._tabindexes,e):ri(this._tabindexes,e),this._invalidateTabindexes())}_unregisterTabindexOrder(e){this._a11yD!=!0&&(ri(this._tabindexes,e),this._invalidateTabindexes())}_invalidateTabindexes(){if(this._a11yD==!0)return;this._tabindexes.sort((t,i)=>{let s=t.get("tabindexOrder",0),r=i.get("tabindexOrder",0);return s==r?0:s>r?1:-1});let e=[];K(this._tabindexes,(t,i)=>{t.getPrivate("focusElement")?this._moveFocusElement(i,t):this._makeFocusElement(i,t);let s=t.get("focusableGroup");s&&t.getPrivate("focusable")!==!1&&(e.indexOf(s)!==-1?t.getPrivate("focusElement").dom.setAttribute("tabindex","-1"):e.push(s))})}_updateCurrentFocus(){this._a11yD!=!0&&this._focusedSprite&&(this._decorateFocusElement(this._focusedSprite),this._positionFocusElement(this._focusedSprite))}_decorateFocusElement(e,t){if(this._a11yD==!0||(t||(t=e.getPrivate("focusElement").dom),!t))return;let i=e.get("role");i?t.setAttribute("role",i):t.removeAttribute("role");let s=e.get("ariaLabel");if(s){let y=Pr(e,s);t.setAttribute("aria-label",y)}else t.removeAttribute("aria-label");let r=e.get("ariaLive");r?t.setAttribute("aria-live",r):t.removeAttribute("aria-live");let n=e.get("ariaChecked");n!=null&&i&&["checkbox","option","radio","menuitemcheckbox","menuitemradio","treeitem"].indexOf(i)!==-1?t.setAttribute("aria-checked",n?"true":"false"):t.removeAttribute("aria-checked");let A=e.get("ariaCurrent");A!=null?t.setAttribute("aria-current",A):t.removeAttribute("aria-current");let o=e.get("ariaSelected");o!=null&&i&&["gridcell","option","row","tab","columnheader","rowheader","treeitem"].indexOf(i)!==-1?t.setAttribute("aria-selected",o?"true":"false"):t.removeAttribute("aria-selected"),e.get("ariaHidden")?t.setAttribute("aria-hidden","true"):t.removeAttribute("aria-hidden");let l=e.get("ariaOrientation");l?t.setAttribute("aria-orientation",l):t.removeAttribute("aria-orientation");let c=e.get("ariaValueNow");c?t.setAttribute("aria-valuenow",c):t.removeAttribute("aria-valuenow");let h=e.get("ariaValueMin");h?t.setAttribute("aria-valuemin",h):t.removeAttribute("aria-valuemin");let d=e.get("ariaValueMax");d?t.setAttribute("aria-valuemax",d):t.removeAttribute("aria-valuemax");let u=e.get("ariaValueText");u?t.setAttribute("aria-valuetext",u):t.removeAttribute("aria-valuetext");let g=e.get("ariaControls");g?t.setAttribute("aria-controls",g):t.removeAttribute("aria-controls"),e.get("visible")&&e.get("opacity")!==0&&e.get("role")!="tooltip"&&!e.isHidden()&&e.getPrivate("focusable")!==!1&&(e.height()||e.width())?(t.getAttribute("tabindex")!="-1"&&t.setAttribute("tabindex",""+this.tabindex),t.removeAttribute("aria-hidden")):(t.removeAttribute("tabindex"),t.setAttribute("aria-hidden","true"))}_makeFocusElement(e,t){if(t.getPrivate("focusElement")||this._a11yD==!0)return;let i=document.createElement("div");t.get("role")!="tooltip"&&(i.tabIndex=this.tabindex),i.style.position="absolute",Ka(i,!1);let s=[];t.setPrivate("focusElement",{dom:i,disposers:s}),this._decorateFocusElement(t),s.push(kt(i,"focus",r=>{this._handleFocus(r)})),s.push(kt(i,"blur",r=>{this._handleBlur(r)})),this._moveFocusElement(e,t)}_removeFocusElement(e){if(this._a11yD==!0)return;ri(this._tabindexes,e);let t=e.getPrivate("focusElement");t&&(this._focusElementContainer.removeChild(t.dom),K(t.disposers,s=>{s.dispose()}))}_hideFocusElement(e){if(this._a11yD==!0)return;let t=e.getPrivate("focusElement");t.dom.style.display="none"}_moveFocusElement(e,t){if(this._a11yD==!0)return;let i=this._focusElementContainer,s=t.getPrivate("focusElement").dom;if(s===this._focusElementContainer.children[e])return;let r=this._focusElementContainer.children[e+1];r?i.insertBefore(s,r):i.append(s)}_positionFocusElement(e){if(this._a11yD==!0||e==null)return;this._focusElementContainer.scrollTop=0;let t=e.globalBounds(),i=t.right==t.left?e.width():t.right-t.left,s=t.top==t.bottom?e.height():t.bottom-t.top,r=this._settings.focusPadding!==void 0?this._settings.focusPadding:2,n=t.left-r,A=t.top-r;i<0&&(n+=i,i=Math.abs(i)),s<0&&(A+=s,s=Math.abs(s));let o=e.getPrivate("focusElement").dom;o.style.top=A+"px",o.style.left=n+"px",o.style.width=i+r*2+"px",o.style.height=s+r*2+"px"}_getSpriteByFocusElement(e){let t;return Lo(this._tabindexes,(i,s)=>i.getPrivate("focusElement").dom===e?(t=i,!1):!0),t}_handleFocus(e){if(this._a11yD==!0)return;let t=this._getSpriteByFocusElement(e.target);if(t){if(!t.isVisibleDeep()){this._focusNext(e.target,this._isShift?-1:1);return}this._positionFocusElement(t),this._focusedSprite=t,t.events.isEnabled("focus")&&t.events.dispatch("focus",{type:"focus",originalEvent:e,target:t}),t.getPrivate("focusElement").dom.tabIndex==-1&&(this._skipNextGroupJump=!1)}}_focusNext(e,t,i){if(this._a11yD==!0)return;let s=Array.from(document.querySelectorAll(["a[href]","area[href]","button:not([disabled])","details","input:not([disabled])","iframe:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[contentEditable=""]','[contentEditable="true"]','[contentEditable="TRUE"]','[tabindex]:not([tabindex^="-"])'].join(","))),r=s.indexOf(e)+t;r<0?r=s.length-1:r>=s.length&&(r=0);let n=s[r];if(i&&t==-1){let A=this._getSpriteByFocusElement(n);if(A&&A.get("focusableGroup")==i){this._focusNext(n,t);return}}n.focus()}_handleBlur(e){if(this._a11yD==!0)return;let t=this._focusedSprite;t&&!t.isDisposed()&&t.events.isEnabled("blur")&&t.events.dispatch("blur",{type:"blur",originalEvent:e,target:t}),this._focusedSprite=void 0}updateTooltip(e){if(this._a11yD==!0)return;let t=ff(e._getText()),i=e.getPrivate("tooltipElement");e.get("role")=="tooltip"&&t!=""?(i||(i=this._makeTooltipElement(e)),i.innerHTML!=t&&(i.innerHTML=t),i.setAttribute("aria-hidden",e.isVisibleDeep()?"false":"true")):i&&(i.remove(),e.removePrivate("tooltipElement"))}_makeTooltipElement(e){let t=this._tooltipElementContainer,i=document.createElement("div");return i.style.position="absolute",i.style.width="1px",i.style.height="1px",i.style.overflow="hidden",i.style.clip="rect(1px, 1px, 1px, 1px)",Ka(i,!1),this._decorateFocusElement(e,i),t.append(i),e.setPrivate("tooltipElement",i),i}_removeTooltipElement(e){if(this._a11yD==!0)return;let t=e.getPrivate("tooltipElement");if(t){let i=t.parentElement;i&&i.removeChild(t)}}_invalidateAccessibility(e){if(this._a11yD==!0)return;this._focusElementDirty=!0;let t=e.getPrivate("focusElement");e.get("focusable")?t&&(this._decorateFocusElement(e),this._positionFocusElement(e)):t&&this._removeFocusElement(e)}focused(e){return this._focusedSprite===e}documentPointToRoot(e){let t=this._getRealSize(),i=this._getCalculatedSize(t),s=i.width/t.width,r=i.height/t.height;return{x:(e.x-t.left)*s,y:(e.y-t.top)*r}}rootPointToDocument(e){let t=this._getRealSize(),i=this._getCalculatedSize(t),s=i.width/t.width,r=i.height/t.height;return{x:e.x/s+t.left,y:e.y/r+t.top}}addDisposer(e){return this._disposers.push(e),e}_updateComputedStyles(){let e=window.getComputedStyle(this.dom),t=this._fontHash,i=Bi(e).flatMap(s=>{var r;return typeof s=="string"&&s.startsWith("font")?[(r=e[s])===null||r===void 0?void 0:r.toString()]:[]});if(t.length!==i.length)return this._fontHash=i,!0;for(let s=0;s<t.length;s++)if(t[s]!==i[s])return this._fontHash=i,!0;return!1}_checkComputedStyles(){this._updateComputedStyles()&&this._invalidateLabelBounds(this.container)}_invalidateLabelBounds(e){e instanceof pe?e.children.each(t=>{this._invalidateLabelBounds(t)}):e instanceof Zs&&e.markDirtyBounds()}_hasLicense(){for(let e=0;e<ls.licenses.length;e++)if(ls.licenses[e].match(/^AM5C.{5,}/i))return!0;return!1}_licenseApplied(){this._logo&&this._logo.set("forceHidden",!0)}get debugGhostView(){return this._renderer.debugGhostView}set debugGhostView(e){this._renderer.debugGhostView=e}set tapToActivate(e){this._renderer.tapToActivate=e}get tapToActivate(){return this._renderer.tapToActivate}set tapToActivateTimeout(e){this._renderer.tapToActivateTimeout=e}get tapToActivateTimeout(){return this._renderer.tapToActivateTimeout}_makeHTMLElement(e){let t=this._htmlElementContainer,i=document.createElement("div");e.setPrivate("htmlElement",i);let s=!1,r;e._walkParents(A=>{if(A.get("verticalScrollbar"))return s=!0,r=A,!1});let n;return s&&(n=document.createElement("div"),e.setPrivate("htmlElementWrapper",n),e.setPrivate("wrapperContainer",r),n.style.position="absolute",n.style.overflow="hidden",n.style.boxSizing="border-box",n.style.top="0px",n.style.left="0px",n.style.width="100%",n.style.height="100%",r.events.on("boundschanged",()=>{this._positionHTMLElement(e)})),i.style.position="absolute",i.style.overflow="auto",i.style.boxSizing="border-box",Ka(i,e.get("interactive",!1)),e.events.isEnabled("click")&&(Ka(i,!0),this._disposers.push(kt(i,"click",A=>{let o=this._renderer.getEvent(A);e.events.dispatch("click",{type:"click",originalEvent:o.event,point:o.point,simulated:!1,target:e})}))),this._positionHTMLElement(e),s?(n.append(i),t.append(n)):t.append(i),Na(this._htmlEnabledContainers,e),i}_positionHTMLElements(){K(this._htmlEnabledContainers,e=>{this._positionHTMLElement(e)})}_positionHTMLElement(e){let t=e.getPrivate("htmlElementWrapper");if(t){let s=e.getPrivate("wrapperContainer");if(s){let r=s.globalBounds();t.style.clipPath="rect("+r.top+"px "+r.right+"px "+r.bottom+"px "+r.left+"px)"}}let i=e.getPrivate("htmlElement");if(i){K(["paddingTop","paddingRight","paddingBottom","paddingLeft","minWidth","minHeight","maxWidth","maxHeight"],w=>{let _=e.get(w);_?i.style[w]=_+"px":i.style[w]=""}),K(["fontFamily","fontSize","fontStyle","fontWeight","fontStyle","fontVariant","textDecoration"],w=>{let _=e.get(w);_?w=="fontSize"&&!Ur(_)?i.style[w]=_+"px":i.style[w]=_+"":i.style[w]=""});let n=e.compositeScale()||1,A=e.compositeRotation()||0;i.style.transform="",i.style.transformOrigin="";let o=e.compositeOpacity();setTimeout(()=>{i.style.opacity=o+""},10);let l=e.isVisibleDeep();l&&(i.style.display="block");let c={x:e.x()+e.get("dx",0),y:e.y()+e.get("dy",0)};e.parent&&(c=e.parent.toGlobal(c)),i.style.top=c.y+"px",i.style.left=c.x+"px";let h=e.get("width"),d=e.get("height"),u=0,g=0;if(h&&(u=e.width()),d&&(g=e.height()),!h||!d){i.style.position="fixed",i.style.width="",i.style.height="";let w=i.getBoundingClientRect();i.style.position="absolute",h||(u=w.width),d||(g=w.height);let _=u/n,T=g/n,Q=e.get("centerX",0),U=e.get("centerY",0),E=0,O=0,D=0,k=0;Q instanceof ke?(E=-Q.value*_,O=(1-Q.value)*_):(E=-Q,O=_-Q),U instanceof ke?(D=-U.value*T,k=(1-U.value)*T):(D=-U,k=T-U),e._localBounds={left:E,right:O,top:D,bottom:k};let F=e._adjustedLocalBounds,M=e._display.getAdjustedBounds(e._localBounds);e._adjustedLocalBounds=M,(F.left!==M.left||F.right!==M.right||F.top!==M.top||F.bottom!==M.bottom)&&e.markDirtyBounds()}u>0&&(i.style.minWidth=u+"px"),g>0&&(i.style.minHeight=g+"px"),(!l||o==0)&&(i.style.display="none");let y=e.get("centerX",0),m=of(y)?y.percent+"%":y+"px",b=e.get("centerY",0),B=of(b)?b.percent+"%":b+"px";(y||b)&&(i.style.transform="translate(-"+m+", -"+B+")"+i.style.transform),n!=1&&(i.style.transform+="scale("+n+")"),A!=0&&(i.style.transform+=" rotate("+A+"deg)"),i.style.transform!=""&&(i.style.transformOrigin=m+" "+B)}}_setHTMLContent(e,t){let i=e.getPrivate("htmlElement");i||(i=this._makeHTMLElement(e),this.autoResize||this.resize()),i.innerHTML!=t&&(i.innerHTML=t)}_removeHTMLContent(e){let t=e.getPrivate("htmlElementWrapper"),i=e.getPrivate("htmlElement");t?(this._htmlElementContainer.removeChild(t),e.removePrivate("htmlElement"),e.removePrivate("htmlElementWrapper"),e.removePrivate("wrapperContainer")):i&&(this._htmlElementContainer.removeChild(i),e.removePrivate("htmlElement"),e.removePrivate("wrapperContainer")),ri(this._htmlEnabledContainers,e)}};var ts=class extends nt{_afterNew(){super._afterNewApplyThemes()}_beforeChanged(){if(super._beforeChanged(),this.isDirty("sprite")){let e=this.get("sprite");e&&(e.setAll({position:"absolute",role:"figure"}),this._disposers.push(e))}(this.isDirty("locationX")||this.isDirty("locationY"))&&this.series&&this.series._positionBullet(this)}};ts.className="Bullet";ts.classNames=nt.classNames.concat([ts.className]);var Et=class extends Tt{_beforeChanged(){super._beforeChanged(),(this.isDirty("cornerRadiusTL")||this.isDirty("cornerRadiusTR")||this.isDirty("cornerRadiusBR")||this.isDirty("cornerRadiusBL"))&&(this._clear=!0)}_draw(){let e=this.width(),t=this.height(),i=e/Math.abs(e),s=t/Math.abs(t),r=0,n=0,A=this.get("strokeWidth",0);this.get("containStroke",!1)&&(e-=i*A,t-=s*A,r+=i*A/2,n+=s*A/2);let o=e,l=t;if(W(o)&&W(l)){let c=Math.min(o,l)/2,h=We(this.get("cornerRadiusTL",8),c),d=We(this.get("cornerRadiusTR",8),c),u=We(this.get("cornerRadiusBR",8),c),g=We(this.get("cornerRadiusBL",8),c),y=Math.min(Math.abs(o/2),Math.abs(l/2));h=Bt(h,0,y),d=Bt(d,0,y),u=Bt(u,0,y),g=Bt(g,0,y);let m=this._display;m.moveTo(r+h*i,n),m.lineTo(r+o-d*i,n),d>0&&m.arcTo(r+o,n,r+o,n+d*s,d),m.lineTo(r+o,n+l-u*s),u>0&&m.arcTo(r+o,n+l,r+o-u*i,n+l,u),m.lineTo(r+g*i,n+l),g>0&&m.arcTo(r,n+l,r,n+l-g*s,g),m.lineTo(r,n+h*s),h>0&&m.arcTo(r,n,r+h*i,n,h),m.closePath()}}};Et.className="RoundedRectangle";Et.classNames=Tt.classNames.concat([Et.className]);var pa=class extends pe{_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["button"]),super._afterNew(),this._settings.background||this.set("background",Et.new(this._root,{themeTags:Fe(this._settings.themeTags,["background"])})),this.setPrivate("trustBounds",!0)}_prepareChildren(){if(super._prepareChildren(),this.isDirty("icon")){let e=this._prevSettings.icon,t=this.get("icon");t!==e&&(this._disposeProperty("icon"),e&&e.dispose(),t&&this.children.push(t),this._prevSettings.icon=t)}if(this.isDirty("label")){let e=this._prevSettings.label,t=this.get("label");t!==e&&(this._disposeProperty("label"),e&&e.dispose(),t&&this.children.push(t),this._prevSettings.label=t)}}};pa.className="Button";pa.classNames=pe.classNames.concat([pa.className]);var Ac=class extends Us{incrementRef(){}decrementRef(){}_onPush(e){this.processor&&this.processor.processRow(e),super._onPush(e)}_onInsertIndex(e,t){this.processor&&this.processor.processRow(t),super._onInsertIndex(e,t)}_onSetIndex(e,t,i){this.processor&&this.processor.processRow(i),super._onSetIndex(e,t,i)}};var ui=class extends $o{constructor(e,t,i){super(i),this.dataContext=t,this.component=e,this._settings.visible=!0,this._checkDirty()}markDirty(){this.component.markDirtyValues(this)}_startAnimation(){this.component._root._addAnimation(this)}_animationTime(){return this.component._root.animationTime}_dispose(){this.component&&this.component.disposeDataItem(this),super._dispose()}show(e){this.setRaw("visible",!0),this.component&&this.component.showDataItem(this,e)}hide(e){this.setRaw("visible",!1),this.component&&this.component.hideDataItem(this,e)}isHidden(){return!this.get("visible")}},qs=class extends pe{constructor(){super(...arguments),this._data=new Ac,this._dataItems=[],this._mainDataItems=this._dataItems,this.valueFields=[],this.fields=["id"],this._valuesDirty=!1,this._dataChanged=!1,this._dataGrouped=!1,this.inited=!1}set data(e){e.incrementRef(),this._data.decrementRef(),this._data=e}get data(){return this._data}_dispose(){super._dispose(),this._data.decrementRef()}_onDataClear(){}_afterNew(){super._afterNew(),this._data.incrementRef(),this._updateFields(),this._disposers.push(this.data.events.onAll(e=>{let t=this._mainDataItems;if(this.markDirtyValues(),this._markDirtyGroup(),this._dataChanged=!0,e.type==="clear")K(t,i=>{i.dispose()}),t.length=0,this._onDataClear();else if(e.type==="push"){let i=new ui(this,e.newValue,this._makeDataItem(e.newValue));t.push(i),this.processDataItem(i)}else if(e.type==="setIndex"){let i=t[e.index],s=this._makeDataItem(e.newValue);i.bullets&&i.bullets.length==0&&(i.bullets=void 0),Ds(s).forEach(([r,n])=>{i.get(r)!=n&&i.animate({key:r,to:n,duration:this.get("interpolationDuration",0),easing:this.get("interpolationEasing")})}),i.dataContext=e.newValue}else if(e.type==="insertIndex"){let i=new ui(this,e.newValue,this._makeDataItem(e.newValue));t.splice(e.index,0,i),this.processDataItem(i)}else if(e.type==="removeIndex")t[e.index].dispose(),t.splice(e.index,1);else if(e.type==="moveIndex"){let i=t[e.oldIndex];t.splice(e.oldIndex,1),t.splice(e.newIndex,0,i)}else throw new Error("Unknown IStreamEvent type");this._afterDataChange()}))}_postUpdateData(){}updateData(e){let t=0;K(e,(i,s)=>{let r=this.dataItems[s];if(!r)this.data.push(i);else{let n=r.dataContext;n&&Ds(i).forEach(([o,l])=>{n[o]=l});let A=this._makeDataItem(n);Ds(A).forEach(([o,l])=>{var c;if(r.get(o)!=l){r.set(o,l);let h=(c=this._valueFieldsF[o])===null||c===void 0?void 0:c.workingKey;h&&r.set(h,l)}})}t=s});for(let i=this.dataItems.length-1;i>t;i--){let s=this.dataItems[i];ri(this.dataItems,s),s.dispose()}this._postUpdateData()}_updateFields(){this.valueFields&&(this._valueFields=[],this._valueFieldsF={},K(this.valueFields,e=>{this.get(e+"Field")&&(this._valueFields.push(e),this._valueFieldsF[e]={fieldKey:e+"Field",workingKey:e+"Working"})})),this.fields&&(this._fields=[],this._fieldsF={},K(this.fields,e=>{this.get(e+"Field")&&(this._fields.push(e),this._fieldsF[e]=e+"Field")}))}get dataItems(){return this._dataItems}processDataItem(e){}_makeDataItem(e){let t={};return this._valueFields&&K(this._valueFields,i=>{let s=this.get(this._valueFieldsF[i].fieldKey);t[i]=e[s],t[this._valueFieldsF[i].workingKey]=t[i]}),this._fields&&K(this._fields,i=>{let s=this.get(this._fieldsF[i]);t[i]=e[s]}),t}makeDataItem(e,t){let i=new ui(this,t,e);return this.processDataItem(i),i}pushDataItem(e,t){let i=this.makeDataItem(e,t);return this._mainDataItems.push(i),i}disposeDataItem(e){}showDataItem(e,t){return Ke(this,void 0,void 0,function*(){e.set("visible",!0)})}hideDataItem(e,t){return Ke(this,void 0,void 0,function*(){e.set("visible",!1)})}_clearDirty(){super._clearDirty(),this._valuesDirty=!1}_afterDataChange(){}_afterChanged(){if(super._afterChanged(),this._dataChanged){let e="datavalidated";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this}),this._dataChanged=!1}if(this._valuesDirty){let e="valueschanged";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this})}this.inited=!0}markDirtyValues(e){this.markDirty(),this._valuesDirty=!0}_markDirtyGroup(){this._dataGrouped=!1}markDirtySize(){this._sizeDirty=!0,this.markDirty()}getDataItemById(e){return Ph(this.dataItems,t=>t.get("id")==e)}};qs.className="Component";qs.classNames=pe.classNames.concat([qs.className]);var Ya=class extends nt{_afterNew(){super._afterNewApplyThemes()}getFill(e){return{addColorStop:(t,i)=>{}}}_changed(){super._changed()}getBounds(e){let t=this.get("target");if(t){let i=t.globalBounds(),s=e.toLocal({x:i.left,y:i.top}),r=e.toLocal({x:i.right,y:i.top}),n=e.toLocal({x:i.right,y:i.bottom}),A=e.toLocal({x:i.left,y:i.bottom});return{left:Math.min(s.x,r.x,n.x,A.x),top:Math.min(s.y,r.y,n.y,A.y),right:Math.max(s.x,r.x,n.x,A.x),bottom:Math.max(s.y,r.y,n.y,A.y)}}return e._display.getLocalBounds()}};Ya.className="Gradient";Ya.classNames=nt.classNames.concat([Ya.className]);var Mr=class extends Ya{getFill(e){let t=this.get("rotation",0),i=this.getBounds(e),s=i.left||0,r=i.right||0,n=i.top||0,A=i.bottom||0,o=ft(t),l=At(t),c=o*(r-s),h=l*(A-n);c==0&&(c=1),h==0&&(h=1);let d=Math.max(c,h),u=this._root._renderer.createLinearGradient(s,n,s+d*o,n+d*l),g=this.get("stops");if(g){let y=0;K(g,m=>{let b=m.offset;W(b)||(b=y/(g.length-1));let B=m.opacity;W(B)||(B=1);let w=m.color;if(w){let _=m.lighten;_&&(w=we.lighten(w,_));let T=m.brighten;T&&(w=we.brighten(w,T)),u.addColorStop(b,"rgba("+w.r+","+w.g+","+w.b+","+B+")")}y++})}return u}};Mr.className="LinearGradient";Mr.classNames=Ya.classNames.concat([Mr.className]);var ur=class extends pe{constructor(){super(...arguments),this.labelContainer=this.children.push(pe.new(this._root,{})),this.markerContainer=this.children.push(pe.new(this._root,{})),this.startLabel=this.labelContainer.children.push(Ze.new(this._root,{themeTags:["start"]})),this.endLabel=this.labelContainer.children.push(Ze.new(this._root,{themeTags:["end"]})),this.markers=this.addDisposer(new pt(Ne.new({}),()=>Et._new(this._root,{themeTags:Fe(this.markers.template.get("themeTags",[]),[this.get("orientation"),"heatlegend","marker"])},[this.markers.template])))}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["heatlegend",this._settings.orientation]),super._afterNew(),this.set("tooltip",ai.new(this._root,{themeTags:["heatlegend"]}))}makeMarker(){let e=this.markers.make();return e.states.create("disabled",{}),e}showValue(e,t,i){let s=this.getTooltip();if(s&&W(e)){let r=this.get("startValue",0),n=this.get("endValue",1),A=(e-r)/(n-r);(A==1/0||A==-1/0||isNaN(A))&&(A=.5);let o=this.get("startColor"),l=this.get("endColor");t||(t=this.getNumberFormatter().format(e)),i||(i=we.interpolate(A,o,l)),s.label.set("text",t);let c;this.get("orientation")=="vertical"?c=this.markerContainer.toGlobal({x:0,y:this.innerHeight()*(1-A)}):c=this.markerContainer.toGlobal({x:this.innerWidth()*A,y:0});let h=s.get("background");h&&h.set("fill",i),s.set("pointTo",c),s.show()}}_prepareChildren(){super._prepareChildren();let e=this.labelContainer,t=this.get("orientation"),i=this.startLabel,s=this.endLabel,r=this.getTooltip();if(this.isDirty("orientation")&&(t=="vertical"?(this.markerContainer.setAll({layout:this._root.verticalLayout,height:se}),this.set("layout",this._root.horizontalLayout),i.setAll({y:se,x:void 0,centerY:se,centerX:se}),s.setAll({y:0,x:void 0,centerY:0,centerX:se}),e.setAll({height:se,width:void 0}),r&&r.set("pointerOrientation","horizontal")):(this.markerContainer.setAll({layout:this._root.horizontalLayout,width:se}),this.set("layout",this._root.verticalLayout),i.setAll({x:0,y:void 0,centerX:0,centerY:0}),s.setAll({x:se,y:void 0,centerX:se,centerY:0}),e.setAll({width:se,height:void 0}),r&&r.set("pointerOrientation","vertical"))),this.isDirty("stepCount")){let n=this.get("stepCount",1),A=this.get("startColor"),o=this.get("endColor"),l=this.get("startOpacity",1),c=this.get("endOpacity",1);if(this.markerContainer.children.clear(),n>1)for(let h=0;h<n;h++){let d=this.makeMarker();t=="vertical"?this.markerContainer.children.moveValue(d,0):this.markerContainer.children.push(d),A&&o&&d.setAll({fill:we.interpolate(h/n,A,o),fillOpacity:Re(h/n*100).interpolate(l,c)})}else if(n==1){let h=this.makeMarker();this.markerContainer.children.push(h);let d=Mr.new(this._root,{stops:[{color:A,opacity:l},{color:o,opacity:c}]});if(t=="vertical"){d.set("rotation",90);let u=d.get("stops");u&&u.reverse()}else d.set("rotation",0);A&&o&&h.set("fillGradient",d)}}(this.isDirty("startText")||this.isDirty("startValue"))&&i.set("text",this.get("startText",this.getNumberFormatter().format(this.get("startValue",0)))),(this.isDirty("endText")||this.isDirty("endValue"))&&s.set("text",this.get("endText",this.getNumberFormatter().format(this.get("endValue",1))))}};ur.className="HeatLegend";ur.classNames=pe.classNames.concat([ur.className]);var On={};Y1(On,{add:()=>CT,checkChange:()=>hc,chooseInterval:()=>Zo,copy:()=>wT,getDateIntervalDuration:()=>jo,getDuration:()=>_i,getIntervalDuration:()=>ks,getNextUnit:()=>lc,getTime:()=>BT,getUnitValue:()=>_T,now:()=>ub,roun:()=>ei,round:()=>ma,sleep:()=>cg,timeUnitDurations:()=>oc});function cg(a){return new Promise((e,t)=>{setTimeout(e,a)})}var oc={millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5,week:6048e5,month:365.242/12*864e5,year:31536e6};function lc(a){switch(a){case"year":return;case"month":return"year";case"week":return"month";case"day":return"month";case"hour":return"day";case"minute":return"hour";case"second":return"minute";case"millisecond":return"second"}}function _i(a,e){return e==null&&(e=1),oc[a]*e}function ks(a){return a?oc[a.timeUnit]*a.count:0}function jo(a,e,t,i,s){let r=a.timeUnit,n=a.count;if(r=="hour"||r=="minute"||r=="second"||r=="millisecond")return oc[a.timeUnit]*a.count;{let A=ma(new Date(e.getTime()),r,n,t,i,void 0,s).getTime(),o=A+n*_i(r)*1.05;return o=ma(new Date(o),r,1,t,i,void 0,s).getTime(),o-A}}function ub(){return new Date}function BT(){return ub().getTime()}function wT(a){return new Date(a.getTime())}function hc(a,e,t,i,s){if(e-a>_i(t,1.2))return!0;let r=new Date(a),n=new Date(e);s&&(r=s.convertLocal(r),n=s.convertLocal(n));let A=0,o=0;!i&&t!="millisecond"&&(A=r.getTimezoneOffset(),r.setUTCMinutes(r.getUTCMinutes()-A),o=n.getTimezoneOffset(),n.setUTCMinutes(n.getUTCMinutes()-o));let l=!1;switch(t){case"year":r.getUTCFullYear()!=n.getUTCFullYear()&&(l=!0);break;case"month":(r.getUTCFullYear()!=n.getUTCFullYear()||r.getUTCMonth()!=n.getUTCMonth())&&(l=!0);break;case"day":(r.getUTCMonth()!=n.getUTCMonth()||r.getUTCDate()!=n.getUTCDate())&&(l=!0);break;case"hour":r.getUTCHours()!=n.getUTCHours()&&(l=!0);break;case"minute":r.getUTCMinutes()!=n.getUTCMinutes()&&(l=!0);break;case"second":r.getUTCSeconds()!=n.getUTCSeconds()&&(l=!0);break;case"millisecond":r.getTime()!=n.getTime()&&(l=!0);break}if(l)return l;let c=lc(t);return c?hc(a,e,c,i,s):!1}function CT(a,e,t,i,s){let r=0;switch(!i&&e!="millisecond"&&(r=a.getTimezoneOffset(),s&&(r-=s.offsetUTC(a)),a.setUTCMinutes(a.getUTCMinutes()-r)),e){case"day":let n=a.getUTCDate();a.setUTCDate(n+t);break;case"second":let A=a.getUTCSeconds();a.setUTCSeconds(A+t);break;case"millisecond":let o=a.getUTCMilliseconds();a.setUTCMilliseconds(o+t);break;case"hour":let l=a.getUTCHours();a.setUTCHours(l+t);break;case"minute":let c=a.getUTCMinutes();a.setUTCMinutes(c+t);break;case"year":let h=a.getUTCFullYear();a.setUTCFullYear(h+t);break;case"month":let d=a.getUTCDate(),u=new Date(a.getUTCFullYear(),a.getUTCMonth(),0).getUTCDate(),g=a.getUTCMonth();d>u?a.setUTCMonth(g+t,u):a.setUTCMonth(g+t);break;case"week":let y=a.getUTCDate();a.setUTCDate(y+t*7);break}if(!i&&e!="millisecond"&&(a.setUTCMinutes(a.getUTCMinutes()+r),e=="day"||e=="week"||e=="month"||e=="year")){let n=a.getTimezoneOffset();if(s&&(n+=s.offsetUTC(a)),n!=r){let A=n-r;a.setUTCMinutes(a.getUTCMinutes()+A),a.getTimezoneOffset()!=n&&a.setUTCMinutes(a.getUTCMinutes()-A)}}return a}function ei(a,e,t,i,s){let r;return s!=null&&(r=new Date(s)),ma(new Date(a),e,t,i.locale.firstDayOfWeek,i.utc,r,i.timezone).getTime()}function ma(a,e,t,i,s,r,n){if(!n||s){let A=0;switch(!s&&e!="millisecond"&&(A=a.getTimezoneOffset(),a.setUTCMinutes(a.getUTCMinutes()-A)),e){case"day":let o=a.getUTCDate();if(t>1){if(r){r=ma(r,"day",1);let b=a.getTime()-r.getTime(),B=Math.floor(b/_i("day")/t),w=_i("day",B*t);a.setTime(r.getTime()+w-A*_i("minute"))}}else a.setUTCDate(o);a.setUTCHours(0,0,0,0);break;case"second":let l=a.getUTCSeconds();t>1&&(l=Math.floor(l/t)*t),a.setUTCSeconds(l,0);break;case"millisecond":if(t==1)return a;let c=a.getUTCMilliseconds();c=Math.floor(c/t)*t,a.setUTCMilliseconds(c);break;case"hour":let h=a.getUTCHours();t>1&&(h=Math.floor(h/t)*t),a.setUTCHours(h,0,0,0);break;case"minute":let d=a.getUTCMinutes();t>1&&(d=Math.floor(d/t)*t),a.setUTCMinutes(d,0,0);break;case"month":let u=a.getUTCMonth();t>1&&(t==2||t==3||t==4||t==6)&&(u=Math.floor(u/t)*t),a.setUTCMonth(u,1),a.setUTCHours(0,0,0,0);break;case"year":let g=a.getUTCFullYear();t>1&&(g=Math.floor(g/t)*t),a.setUTCFullYear(g,0,1),a.setUTCHours(0,0,0,0);break;case"week":if(t>1&&r){r=ma(r,"week",1);let b=a.getTime()-r.getTime(),B=Math.floor(b/_i("week")/t),w=_i("week",B*t);a.setTime(r.getTime()+w-A*_i("minute"))}let y=a.getUTCDate(),m=a.getUTCDay();W(i)||(i=1),m>=i?y=y-m+i:y=y-(7+m)+i,a.setUTCDate(y),a.setUTCHours(0,0,0,0);break}if(!s&&e!="millisecond"&&(a.setUTCMinutes(a.getUTCMinutes()+A),e=="day"||e=="week"||e=="month"||e=="year")){let o=a.getTimezoneOffset();if(o!=A){let l=o-A;a.setUTCMinutes(a.getUTCMinutes()+l)}}return a}else{if(isNaN(a.getTime()))return a;let A=a.getTime(),o=n.offsetUTC(a),l=a.getTimezoneOffset(),c=n.parseDate(a),h=c.year,d=c.month,u=c.day,g=c.hour,y=c.minute,m=c.second,b=c.millisecond,B=c.weekday,w=o-l;switch(e){case"day":if(t>1&&r){r=ma(r,"day",1,i,s,void 0,n);let O=a.getTime()-r.getTime(),D=Math.floor(O/_i("day")/t),k=_i("day",D*t);a.setTime(r.getTime()+k),c=n.parseDate(a),h=c.year,d=c.month,u=c.day}g=0,y=w,m=0,b=0;break;case"second":y+=w,t>1&&(m=Math.floor(m/t)*t),b=0;break;case"millisecond":y+=w,t>1&&(b=Math.floor(b/t)*t);break;case"hour":t>1&&(g=Math.floor(g/t)*t),y=w,m=0,b=0;break;case"minute":t>1&&(y=Math.floor(y/t)*t),y+=w,m=0,b=0;break;case"month":t>1&&(d=Math.floor(d/t)*t),u=1,g=0,y=w,m=0,b=0;break;case"year":t>1&&(h=Math.floor(h/t)*t),d=0,u=1,g=0,y=w,m=0,b=0;break;case"week":W(i)||(i=1),B>=i?u=u-B+i:u=u-(7+B)+i,g=0,y=w,m=0,b=0;break}a=new Date(h,d,u,g,y,m,b);let _=a.getTime(),T=36e5;e=="hour"&&(T=36e5*t),_+T<=A&&(e=="hour"||e=="minute"||e=="second"||e=="millisecond")&&(a=new Date(_+T));let Q=a.getTimezoneOffset(),E=n.offsetUTC(a)-Q;return E!=w&&a.setTime(a.getTime()+(E-w)*6e4),a}}function Zo(a,e,t,i){let s=i[a],r=ks(s),n=i.length-1;if(a>=n)return Object.assign({},i[n]);let A=Math.ceil(e/r);return e<r&&a>0?Object.assign({},i[a-1]):A<=t?Object.assign({},i[a]):a+1<i.length?Zo(a+1,e,t,i):Object.assign({},i[a])}function _T(a,e){switch(e){case"day":return a.getDate();case"second":return a.getSeconds();case"millisecond":return a.getMilliseconds();case"hour":return a.getHours();case"minute":return a.getMinutes();case"month":return a.getMonth();case"year":return a.getFullYear();case"week":return Qn(a)}}var ti=class extends qs{constructor(){super(...arguments),this._aggregatesCalculated=!1,this._selectionAggregatesCalculated=!1,this._dataProcessed=!1,this._baseSeriesDirty=!1,this.bullets=new Us,this.bulletsContainer=pe.new(this._root,{width:se,height:se,position:"absolute"})}_afterNew(){this.valueFields.push("value","customValue"),super._afterNew(),this.setPrivate("customData",{}),this._disposers.push(this.bullets.events.onAll(()=>{this._handleBullets(this.dataItems)}))}_dispose(){this.bulletsContainer.dispose(),super._dispose()}startIndex(){let e=this.dataItems.length;return Math.min(this.getPrivate("startIndex",0),e)}endIndex(){let e=this.dataItems.length;return Math.max(0,Math.min(this.getPrivate("endIndex",e),e))}_handleBullets(e){K(e,t=>{let i=t.bullets;i&&(K(i,s=>{s.dispose()}),t.bullets=void 0)}),this.markDirtyValues()}_makeBullets(e){this._shouldMakeBullet(e)&&(e.bullets=[],this.bullets.each(t=>{this._makeBullet(e,t)}))}_shouldMakeBullet(e){return!0}_makeBullet(e,t,i){let s=t(this._root,this,e);return s&&(s._index=i,this._makeBulletReal(e,s)),s}_makeBulletReal(e,t){let i=t.get("sprite");i&&(i._setDataItem(e),i.setRaw("position","absolute"),this.bulletsContainer.children.push(i)),t.series=this,e.bullets.push(t)}addBullet(e,t){e.bullets||(e.bullets=[]),t&&this._makeBulletReal(e,t)}_clearDirty(){super._clearDirty(),this._aggregatesCalculated=!1,this._baseSeriesDirty=!1,this._selectionAggregatesCalculated=!1}_prepareChildren(){super._prepareChildren();let e=this.dataItems,t=e.length,i=this.startIndex(),s=this.endIndex();if(this.isDirty("name")&&this.updateLegendValue(),this.isDirty("heatRules")&&(this._valuesDirty=!0),this.isPrivateDirty("baseValueSeries")){let n=this.getPrivate("baseValueSeries");n&&this._disposers.push(n.onPrivate("startIndex",()=>{this._baseSeriesDirty=!0,this.markDirtyValues()}))}if(this.get("calculateAggregates")&&(this._valuesDirty&&!this._dataProcessed&&(this._aggregatesCalculated||(this._calculateAggregates(0,t),this._aggregatesCalculated=!0,i!=0&&(this._psi=void 0))),(this._psi!=i||this._pei!=s||this.isPrivateDirty("adjustedStartIndex"))&&!this._selectionAggregatesCalculated&&(i===0&&s===t&&this._aggregatesCalculated||this._calculateAggregates(i,s),this._selectionAggregatesCalculated=!0)),this.isDirty("tooltip")){let n=this.get("tooltip");n&&(n.hide(0),n.set("tooltipTarget",this))}if(this.isDirty("fill")||this.isDirty("stroke")){let n,A=this.get("legendDataItem");if(A&&(n=A.get("markerRectangle"),n&&this.isVisible())){if(this.isDirty("stroke")){let o=this.get("stroke");n.set("stroke",o)}if(this.isDirty("fill")){let o=this.get("fill");n.set("fill",o)}}this.updateLegendMarker(void 0)}if(this.bullets.length>0){let n=this.startIndex(),A=this.endIndex();A<t&&A++;for(let o=n;o<A;o++){let l=e[o];l.bullets||this._makeBullets(l)}}}_handleRemoved(){}_adjustStartIndex(e){return e}_calculateAggregates(e,t){let i=this._valueFields;if(!i)throw new Error("No value fields are set for the series.");let s=this.get("excludeFromAggregate");s&&(i=i.filter(m=>s.indexOf(m)==-1));let r={},n={},A={},o={},l={},c={},h={},d={},u={};for(let m=0,b=i.length;m<b;m++){let B=i[m];r[B]=0,n[B]=0,A[B]=0}let g=this.dataItems,y=g.length;for(let m=0,b=i.length;m<b;m++){let B=i[m],w=B+"Change",_=B+"ChangePercent",T=B+"ChangePrevious",Q=B+"ChangePreviousPercent",U=B+"ChangeSelection",E=B+"ChangeSelectionPercent",O="valueY";(B==="valueX"||B.endsWith("ValueX"))&&(O="valueX");let D=this.getPrivate("baseValueSeries"),k=this.getPrivate("adjustedStartIndex",e),F=(M,Y,z)=>{if(e===0){let Ae=c[O],X=Y-Ae;M.setRaw(w,X),M.setRaw(_,X/Ae*100)}let re=Y-u[O],q=Y-c[O];M.setRaw(T,re),M.setRaw(Q,re/u[O]*100),M.setRaw(U,q),M.setRaw(E,q/c[O]*100),u[z]=Y};for(let M=k;M<t;M++){let Y=g[M];if(Y){let z=Y.get(B);if(z!=null){o[B]==null&&(o[B]=z),l[B]==null&&(l[B]=z),c[B]==null&&(c[B]=z,u[B]=z,D&&(c[O]=D._getBase(O)));break}}}for(let M=k;M<t;M++){let Y=g[M];if(Y){let z=Y._settings[B];z!=null&&(A[B]++,r[B]+=z,n[B]+=Math.abs(z),o[B]>z&&(o[B]=z),l[B]<z&&(l[B]=z),h[B]=z,F(Y,z,B))}}if(d[B]=r[B]/A[B],t<y){let M=g[t];if(M){let Y=M.get(B);Y!=null&&F(M,Y,B)}}if(t+1<y){let M=g[t+1];if(M){let Y=M.get(B);Y!=null&&F(M,Y,B)}}e>0&&e--,delete u[B];for(let M=e;M<k;M++){let Y=g[M];if(Y){let z=Y.get(B);u[B]==null&&(u[B]=z),z!=null&&F(Y,z,B)}}}for(let m=0,b=i.length;m<b;m++){let B=i[m];this.setPrivate(B+"AverageSelection",d[B]),this.setPrivate(B+"CountSelection",A[B]),this.setPrivate(B+"SumSelection",r[B]),this.setPrivate(B+"AbsoluteSumSelection",n[B]),this.setPrivate(B+"LowSelection",o[B]),this.setPrivate(B+"HighSelection",l[B]),this.setPrivate(B+"OpenSelection",c[B]),this.setPrivate(B+"CloseSelection",h[B])}if(e===0&&t===y)for(let m=0,b=i.length;m<b;m++){let B=i[m];this.setPrivate(B+"Average",d[B]),this.setPrivate(B+"Count",A[B]),this.setPrivate(B+"Sum",r[B]),this.setPrivate(B+"AbsoluteSum",n[B]),this.setPrivate(B+"Low",o[B]),this.setPrivate(B+"High",l[B]),this.setPrivate(B+"Open",c[B]),this.setPrivate(B+"Close",h[B])}}_updateChildren(){super._updateChildren(),this._psi=this.startIndex(),this._pei=this.endIndex(),this.isDirty("visible")&&this.bulletsContainer.set("visible",this.get("visible"));let e=this.get("heatRules");if(this._valuesDirty&&e&&e.length>0&&K(e,t=>{let i=t.minValue||this.getPrivate(t.dataField+"Low")||0,s=t.maxValue||this.getPrivate(t.dataField+"High")||0;K(t.target._entities,r=>{let n=r.dataItem.get(t.dataField);if(!W(n)){t.neutral&&r.set(t.key,t.neutral);let A=r.states;if(A){let o=A.lookup("default");o&&t.neutral&&o.set(t.key,t.neutral)}if(!t.customFunction)return}if(t.customFunction)t.customFunction.call(this,r,i,s,n);else{let A;t.logarithmic?A=(Math.log(n)*Math.LOG10E-Math.log(i)*Math.LOG10E)/(Math.log(s)*Math.LOG10E-Math.log(i)*Math.LOG10E):A=(n-i)/(s-i),W(n)&&(!W(A)||Math.abs(A)==1/0)&&(A=.5);let o;W(t.min)?o=t.min+(t.max-t.min)*A:t.min instanceof we?o=we.interpolate(A,t.min,t.max):t.min instanceof ke&&(o=bf(A,t.min,t.max)),r.set(t.key,o);let l=r.states;if(l){let c=l.lookup("default");c&&c.set(t.key,o)}}})}),this.get("visible")){let t=this.dataItems,i=t.length,s=this.startIndex(),r=this.endIndex();r<i&&r++,s>0&&s--;for(let n=0;n<s;n++)this._hideBullets(t[n]);for(let n=s;n<r;n++)this._positionBullets(t[n]);for(let n=r;n<i;n++)this._hideBullets(t[n])}}_positionBullets(e){e.bullets&&K(e.bullets,t=>{this._positionBullet(t);let i=t.get("sprite");t.get("dynamic")&&(i&&(i._markDirtyKey("fill"),i.markDirtySize()),i instanceof pe&&i.walkChildren(s=>{s._markDirtyKey("fill"),s.markDirtySize(),s instanceof Ze&&s.text.markDirtyText()})),i instanceof Ze&&i.get("populateText")&&i.text.markDirtyText()})}_hideBullets(e){e.bullets&&K(e.bullets,t=>{let i=t.get("sprite");i&&i.setPrivate("visible",!1)})}_positionBullet(e){}_placeBulletsContainer(e){e.bulletsContainer.children.moveValue(this.bulletsContainer)}_removeBulletsContainer(){let e=this.bulletsContainer;e.parent&&e.parent.children.removeValue(e)}disposeDataItem(e){let t=e.bullets;t&&(K(t,i=>{i.dispose()}),e.bullets=void 0)}_getItemReaderLabel(){return""}showDataItem(e,t){let i=Object.create(null,{showDataItem:{get:()=>super.showDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.showDataItem.call(this,e,t)],r=e.bullets;r&&K(r,n=>{let A=n.get("sprite");A&&s.push(A.show(t))}),yield Promise.all(s)})}hideDataItem(e,t){let i=Object.create(null,{hideDataItem:{get:()=>super.hideDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.hideDataItem.call(this,e,t)],r=e.bullets;r&&K(r,n=>{let A=n.get("sprite");A&&s.push(A.hide(t))}),yield Promise.all(s)})}_sequencedShowHide(e,t){return Ke(this,void 0,void 0,function*(){if(this.get("sequencedInterpolation"))if(W(t)||(t=this.get("interpolationDuration",0)),t>0){let i=this.startIndex(),s=this.endIndex();yield Promise.all(Do(this.dataItems,(r,n)=>Ke(this,void 0,void 0,function*(){let A=t||0;(n<i-10||n>s+10)&&(A=0);let o=this.get("sequencedDelay",0)+A/(s-i);yield cg(o*(n-i)),e?yield this.showDataItem(r,A):yield this.hideDataItem(r,A)})))}else yield Promise.all(Do(this.dataItems,i=>e?this.showDataItem(i,0):this.hideDataItem(i,0)))})}updateLegendValue(e){if(e){let t=e.get("legendDataItem");if(t){let i=t.get("valueLabel");if(i){let r=i.text,n="";i._setDataItem(e),n=this.get("legendValueText",r.get("text","")),i.set("text",n),r.markDirtyText()}let s=t.get("label");if(s){let r=s.text,n="";s._setDataItem(e),n=this.get("legendLabelText",r.get("text","")),s.set("text",n),r.markDirtyText()}}}}updateLegendMarker(e){}_onHide(){super._onHide();let e=this.getTooltip();e&&e.hide()}hoverDataItem(e){}unhoverDataItem(e){}_getBase(e){let t=this.dataItems[this.startIndex()];return t?t.get(e):0}};ti.className="Series";ti.classNames=qs.classNames.concat([ti.className]);var Hr=class extends ti{constructor(){super(...arguments),this.itemContainers=this.addDisposer(new pt(Ne.new({}),()=>pe._new(this._root,{themeTags:Fe(this.itemContainers.template.get("themeTags",[]),["legend","item"]),themeTagsSelf:Fe(this.itemContainers.template.get("themeTagsSelf",[]),["itemcontainer"]),background:Et.new(this._root,{themeTags:Fe(this.itemContainers.template.get("themeTags",[]),["legend","item","background"]),themeTagsSelf:Fe(this.itemContainers.template.get("themeTagsSelf",[]),["itemcontainer"])})},[this.itemContainers.template]))),this.markers=this.addDisposer(new pt(Ne.new({}),()=>pe._new(this._root,{themeTags:Fe(this.markers.template.get("themeTags",[]),["legend","marker"])},[this.markers.template]))),this.labels=this.addDisposer(new pt(Ne.new({}),()=>Ze._new(this._root,{themeTags:Fe(this.labels.template.get("themeTags",[]),["legend","label"])},[this.labels.template]))),this.valueLabels=this.addDisposer(new pt(Ne.new({}),()=>Ze._new(this._root,{themeTags:Fe(this.valueLabels.template.get("themeTags",[]),["legend","label","value"])},[this.valueLabels.template]))),this.markerRectangles=this.addDisposer(new pt(Ne.new({}),()=>Et._new(this._root,{themeTags:Fe(this.markerRectangles.template.get("themeTags",[]),["legend","marker","rectangle"])},[this.markerRectangles.template])))}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["legend"]),this.fields.push("name","stroke","fill"),super._afterNew()}makeItemContainer(e){let t=this.children.push(this.itemContainers.make());return t._setDataItem(e),this.itemContainers.push(t),t.states.create("disabled",{}),t}makeMarker(){let e=this.markers.make();return this.markers.push(e),e.states.create("disabled",{}),e}makeLabel(){let e=this.labels.make();return e.states.create("disabled",{}),e}makeValueLabel(){let e=this.valueLabels.make();return e.states.create("disabled",{}),e}makeMarkerRectangle(){let e=this.markerRectangles.make();return e.states.create("disabled",{}),e}processDataItem(e){super.processDataItem(e);let t=this.makeItemContainer(e),i=this.get("nameField"),s=this.get("fillField"),r=this.get("strokeField");if(t){let n=this.get("clickTarget","itemContainer"),A=e.dataContext;A&&A.set&&A.set("legendDataItem",e),t._setDataItem(e),e.set("itemContainer",t);let o=this.makeMarker();if(o){t.children.push(o),o._setDataItem(e),e.set("marker",o);let h=this.get("useDefaultMarker"),d=o.children.push(this.makeMarkerRectangle()),u=e.get("fill"),g=e.get("stroke");e.set("markerRectangle",d),A&&A.get&&(u=A.get(s,u),g=A.get(r,g)),g||(g=u),h?A.on&&(A.on(s,()=>{d.set("fill",A.get(s))}),A.on(r,()=>{d.set("stroke",A.get(r))})):A&&A.createLegendMarker&&A.createLegendMarker(),d.setAll({fill:u,stroke:g});let y=A.component;y&&y.updateLegendMarker&&y.updateLegendMarker(A)}let l=this.makeLabel();if(l){t.children.push(l),l._setDataItem(e),e.set("label",l),l.text.on("text",()=>{t.setRaw("ariaLabel",l.text._getText()+(this.get("clickTarget")!=="none"?"; "+this._t("Press ENTER to toggle"):"")),t.markDirtyAccessibility()}),A&&A.get&&e.set("name",A.get(i));let h=e.get("name");h&&l.set("text",h)}let c=this.makeValueLabel();if(c&&(t.children.push(c),c._setDataItem(e),e.set("valueLabel",c)),A&&A.show&&(A.on("visible",h=>{t.set("disabled",!h)}),A.get("visible")||t.set("disabled",!0),n!="none")){let h=t;n=="marker"&&(h=o),this._addClickEvents(h,A,e)}this.children.values.sort((h,d)=>{let u=h.dataItem.dataContext,g=d.dataItem.dataContext;if(u&&g){let y=this.data.indexOf(u),m=this.data.indexOf(g);if(y>m)return 1;if(y<m)return-1}return 0}),A&&A.updateLegendValue&&A.updateLegendValue()}}_addClickEvents(e,t,i){e.set("cursorOverStyle","pointer"),e.events.on("pointerover",()=>{let s=t.component;s&&s.hoverDataItem&&s.hoverDataItem(t)}),e.events.on("pointerout",()=>{let s=t.component;s&&s.hoverDataItem&&s.unhoverDataItem(t)}),e.events.on("click",()=>{let s=i.get("label").text._getText();t.show&&t.isHidden&&(t.isHidden()||t.get("visible")===!1)?(t.show(),e.set("disabled",!1),this._root.readerAlert(this._t("%1 shown",this._root.locale,s))):t.hide&&(t.hide(),e.set("disabled",!0),this._root.readerAlert(this._t("%1 hidden",this._root.locale,s)))})}disposeDataItem(e){super.disposeDataItem(e);let t=e.dataContext;t&&t.get&&t.get("legendDataItem")==e&&t.set("legendDataItem",void 0);let i=e.get("itemContainer");i&&(this.itemContainers.removeValue(i),i.dispose());let s=e.get("marker");s&&(this.markers.removeValue(s),s.dispose());let r=e.get("markerRectangle");r&&(this.markerRectangles.removeValue(r),r.dispose());let n=e.get("label");n&&(this.labels.removeValue(n),n.dispose());let A=e.get("valueLabel");A&&(this.valueLabels.removeValue(A),A.dispose())}};Hr.className="Legend";Hr.classNames=ti.classNames.concat([Hr.className]);function dg(a,e){for(let t=0,i=e.length;t<i;t++){let s=e[t];if(s.length>0){let r=s[0];if(r.length>0){let n=r[0];a.moveTo(n.x,n.y);for(let A=0,o=s.length;A<o;A++)FT(a,s[A])}}}}function FT(a,e){for(let t=0,i=e.length;t<i;t++){let s=e[t];a.lineTo(s.x,s.y)}}var ja=class extends Le{_beforeChanged(){super._beforeChanged(),(this.isDirty("points")||this.isDirty("segments")||this._sizeDirty||this.isPrivateDirty("width")||this.isPrivateDirty("height"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){let e=this.get("points"),t=this.get("segments");if(e&&e.length>0){let i=e[0];this._display.moveTo(i.x,i.y),dg(this._display,[[e]])}else if(t)dg(this._display,t);else if(!this.get("draw")){let i=this.width(),s=this.height();this._display.moveTo(0,0),this._display.lineTo(i,s)}}}};ja.className="Line";ja.classNames=Le.classNames.concat([ja.className]);var Nn=class extends Zs{constructor(){super(...arguments),this._display=this._root._renderer.makeRadialText("",this.textStyle)}_afterNew(){super._afterNew()}_beforeChanged(){super._beforeChanged(),this._display.clear(),this.isDirty("textType")&&(this._display.textType=this.get("textType"),this.markDirtyBounds()),this.isDirty("radius")&&(this._display.radius=this.get("radius"),this.markDirtyBounds()),this.isDirty("startAngle")&&(this._display.startAngle=(this.get("startAngle",0)+90)*Kt,this.markDirtyBounds()),this.isDirty("inside")&&(this._display.inside=this.get("inside"),this.markDirtyBounds()),this.isDirty("orientation")&&(this._display.orientation=this.get("orientation"),this.markDirtyBounds()),this.isDirty("kerning")&&(this._display.kerning=this.get("kerning"),this.markDirtyBounds())}};Nn.className="RadialText";Nn.classNames=Zs.classNames.concat([Nn.className]);var Rr=class extends Ze{constructor(){super(...arguments),this._flipped=!1}_afterNew(){this._textKeys.push("textType","kerning"),super._afterNew()}_makeText(){this._text=this.children.push(Nn.new(this._root,{}))}baseRadius(){let e=this.getPrivate("radius",0),t=this.getPrivate("innerRadius",0),i=this.get("baseRadius",0);return t+We(i,e-t)}radius(){let e=this.get("inside",!1);return this.baseRadius()+this.get("radius",0)*(e?-1:1)}_updateChildren(){if(super._updateChildren(),this.isDirty("baseRadius")||this.isPrivateDirty("radius")||this.isPrivateDirty("innerRadius")||this.isDirty("labelAngle")||this.isDirty("radius")||this.isDirty("inside")||this.isDirty("orientation")||this.isDirty("textType")){let e=this.get("textType","adjusted"),t=this.get("inside",!1),i=this.get("orientation"),s=es(this.get("labelAngle",0));this._text.set("startAngle",this.get("labelAngle",0)),this._text.set("inside",t);let r=At(s),n=ft(s),A=this.baseRadius(),o=this.radius();if(this._display.angle=0,e=="circular")this.setAll({paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}),this.setRaw("x",void 0),this.setRaw("y",void 0),this._text.set("orientation",i),this._text.set("radius",o);else{A==0&&(s=0,o=0);let l=o*n,c=o*r;e=="radial"?(this.setRaw("x",l),this.setRaw("y",c),s<90||s>270||i!="auto"?(this._display.angle=s,this._flipped=!1):(this._display.angle=s+180,this._flipped=!0),this._dirty.rotation=!1):e=="adjusted"?(this.setRaw("centerX",ye),this.setRaw("centerY",ye),this.setRaw("x",l),this.setRaw("y",c)):e=="regular"&&(this.setRaw("x",l),this.setRaw("y",c))}this.markDirtyPosition(),this.markDirtyBounds()}}_updatePosition(){let e=this.get("textType","regular"),t=this.get("inside",!1),i=0,s=0,r=this.get("labelAngle",0),n=this.localBounds(),A=n.right-n.left,o=n.bottom-n.top;if(e=="radial"){if(this._flipped){let l=this.get("centerX");l instanceof ke&&(A=A*(1-l.value*2)),i=A*ft(r),s=A*At(r)}}else!t&&e=="adjusted"&&(i=A/2*ft(r),s=o/2*At(r));this.setRaw("dx",i),this.setRaw("dy",s),super._updatePosition()}get text(){return this._text}};Rr.className="RadialLabel";Rr.classNames=Ze.classNames.concat([Rr.className]);var Or=class extends pe{constructor(){super(...arguments),this.thumb=this._makeThumb(),this.startGrip=this._makeButton(),this.endGrip=this._makeButton(),this._thumbBusy=!1,this._startDown=!1,this._endDown=!1,this._thumbDown=!1}_addOrientationClass(){this._settings.themeTags=Fe(this._settings.themeTags,["scrollbar",this._settings.orientation]),this._settings.background||(this._settings.background=Et.new(this._root,{themeTags:Fe(this._settings.themeTags,["main","background"])}))}_makeButton(){return this.children.push(pa.new(this._root,{themeTags:["resize","button",this.get("orientation")],icon:Le.new(this._root,{themeTags:["icon"]})}))}_makeThumb(){return this.children.push(Et.new(this._root,{themeTags:["thumb",this.get("orientation")]}))}_handleAnimation(e){e&&this._disposers.push(e.events.on("stopped",()=>{this.setPrivateRaw("isBusy",!1),this._thumbBusy=!1}))}_afterNew(){this._addOrientationClass(),super._afterNew();let e=this.startGrip,t=this.endGrip,i=this.thumb,s=this.get("background");s&&this._disposers.push(s.events.on("click",r=>{this.setPrivateRaw("isBusy",!0);let n=this._display.toLocal(r.point),A=this.width(),o=this.height(),l=this.get("orientation"),c;l=="vertical"?c=(n.y-i.height()/2)/o:c=(n.x-i.width()/2)/A;let h,d;l=="vertical"?(h=c*o,d="y"):(h=c*A,d="x");let u=this.get("animationDuration",0);u>0?(this._thumbBusy=!0,this._handleAnimation(this.thumb.animate({key:d,to:h,duration:u,easing:this.get("animationEasing")}))):(this.thumb.set(d,h),this._root.events.once("frameended",()=>{this.setPrivateRaw("isBusy",!1)}))})),this._disposers.push(i.events.on("dblclick",r=>{if(!FA(r.originalEvent,this))return;let n=this.get("animationDuration",0),A=this.get("animationEasing");this.animate({key:"start",to:0,duration:n,easing:A}),this.animate({key:"end",to:1,duration:n,easing:A})})),this._disposers.push(e.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._startDown=!0,this._gripDown="start"})),this._disposers.push(t.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._endDown=!0,this._gripDown="end"})),this._disposers.push(i.events.on("pointerdown",()=>{this.setPrivateRaw("isBusy",!0),this._thumbDown=!0,this._gripDown=void 0})),this._disposers.push(e.events.on("globalpointerup",()=>{this._startDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._startDown=!1})),this._disposers.push(t.events.on("globalpointerup",()=>{this._endDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._endDown=!1})),this._disposers.push(i.events.on("globalpointerup",()=>{this._thumbDown&&(this.setPrivateRaw("isBusy",!1),this._released()),this._thumbDown=!1})),this._disposers.push(e.on("x",()=>{this._updateThumb()})),this._disposers.push(t.on("x",()=>{this._updateThumb()})),this._disposers.push(e.on("y",()=>{this._updateThumb()})),this._disposers.push(t.on("y",()=>{this._updateThumb()})),this._disposers.push(i.events.on("positionchanged",()=>{this._updateGripsByThumb()})),this.get("orientation")=="vertical"?(e.set("x",0),t.set("x",0),this._disposers.push(i.adapters.add("y",r=>Math.max(Math.min(Number(r),this.height()-i.height()),0))),this._disposers.push(i.adapters.add("x",r=>this.width()/2)),this._disposers.push(e.adapters.add("x",r=>this.width()/2)),this._disposers.push(t.adapters.add("x",r=>this.width()/2)),this._disposers.push(e.adapters.add("y",r=>Math.max(Math.min(Number(r),this.height()),0))),this._disposers.push(t.adapters.add("y",r=>Math.max(Math.min(Number(r),this.height()),0)))):(e.set("y",0),t.set("y",0),this._disposers.push(i.adapters.add("x",r=>Math.max(Math.min(Number(r),this.width()-i.width()),0))),this._disposers.push(i.adapters.add("y",r=>this.height()/2)),this._disposers.push(e.adapters.add("y",r=>this.height()/2)),this._disposers.push(t.adapters.add("y",r=>this.height()/2)),this._disposers.push(e.adapters.add("x",r=>Math.max(Math.min(Number(r),this.width()),0))),this._disposers.push(t.adapters.add("x",r=>Math.max(Math.min(Number(r),this.width()),0))))}_updateChildren(){super._updateChildren(),(this.isDirty("end")||this.isDirty("start")||this._sizeDirty)&&this.updateGrips()}_changed(){if(super._changed(),this.isDirty("start")||this.isDirty("end")){let e="rangechanged";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this,start:this.get("start",0),end:this.get("end",1),grip:this._gripDown})}}_released(){let e="released";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this})}updateGrips(){let e=this.startGrip,t=this.endGrip,i=this.get("orientation"),s=this.height(),r=this.width();i=="vertical"?(e.set("y",s*this.get("start",0)),t.set("y",s*this.get("end",1))):(e.set("x",r*this.get("start",0)),t.set("x",r*this.get("end",1)));let n=this.getPrivate("positionTextFunction"),A=Math.round(this.get("start",0)*100),o=Math.round(this.get("end",0)*100),l,c;n?(l=n.call(this,this.get("start",0)),c=n.call(this,this.get("end",0))):(l=A+"%",c=o+"%"),e.set("ariaLabel",this._t("From %1",void 0,l)),e.set("ariaValueNow",""+A),e.set("ariaValueText",A+"%"),e.set("ariaValueMin","0"),e.set("ariaValueMax","100"),t.set("ariaLabel",this._t("To %1",void 0,c)),t.set("ariaValueNow",""+o),t.set("ariaValueText",o+"%"),t.set("ariaValueMin","0"),t.set("ariaValueMax","100")}_updateThumb(){let e=this.thumb,t=this.startGrip,i=this.endGrip,s=this.height(),r=this.width(),n=t.x(),A=i.x(),o=t.y(),l=i.y(),c=0,h=1;this.get("orientation")=="vertical"?W(o)&&W(l)&&(!this._thumbBusy&&!e.isDragging()&&(e.set("height",l-o),e.set("y",o)),c=o/s,h=l/s):W(n)&&W(A)&&(!this._thumbBusy&&!e.isDragging()&&(e.set("width",A-n),e.set("x",n)),c=n/r,h=A/r),this.getPrivate("isBusy")&&(this.get("start")!=c||this.get("end")!=h)&&(this.set("start",c),this.set("end",h));let d=this.getPrivate("positionTextFunction"),u=Math.round(this.get("start",0)*100),g=Math.round(this.get("end",0)*100),y,m;d?(y=d.call(this,this.get("start",0)),m=d.call(this,this.get("end",0))):(y=u+"%",m=g+"%"),e.set("ariaLabel",this._t("From %1 to %2",void 0,y,m)),e.set("ariaValueNow",""+u),e.set("ariaValueText",u+"%")}_updateGripsByThumb(){let e=this.thumb,t=this.startGrip,i=this.endGrip;if(this.get("orientation")=="vertical"){let s=e.height();t.set("y",e.y()),i.set("y",e.y()+s)}else{let s=e.width();t.set("x",e.x()),i.set("x",e.x()+s)}}};Or.className="Scrollbar";Or.classNames=pe.classNames.concat([Or.className]);function It(a){return function(){return a}}var ug=Math.abs,Ki=Math.atan2,Za=Math.cos,fb=Math.max,cc=Math.min,fr=Math.sin,Vn=Math.sqrt,hs=1e-12,UA=Math.PI,qo=UA/2,gb=2*UA;function pb(a){return a>1?0:a<-1?UA:Math.acos(a)}function fg(a){return a>=1?qo:a<=-1?-qo:Math.asin(a)}var gg=Math.PI,pg=2*gg,$n=1e-6,TT=pg-$n;function mb(a){this._+=a[0];for(let e=1,t=a.length;e<t;++e)this._+=arguments[e]+a[e]}function IT(a){let e=Math.floor(a);if(!(e>=0))throw new Error(`invalid digits: ${a}`);if(e>15)return mb;let t=10**e;return function(i){this._+=i[0];for(let s=1,r=i.length;s<r;++s)this._+=Math.round(arguments[s]*t)/t+i[s]}}var Kn=class{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?mb:IT(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,i,s){this._append`Q${+e},${+t},${this._x1=+i},${this._y1=+s}`}bezierCurveTo(e,t,i,s,r,n){this._append`C${+e},${+t},${+i},${+s},${this._x1=+r},${this._y1=+n}`}arcTo(e,t,i,s,r){if(e=+e,t=+t,i=+i,s=+s,r=+r,r<0)throw new Error(`negative radius: ${r}`);let n=this._x1,A=this._y1,o=i-e,l=s-t,c=n-e,h=A-t,d=c*c+h*h;if(this._x1===null)this._append`M${this._x1=e},${this._y1=t}`;else if(d>$n)if(!(Math.abs(h*o-l*c)>$n)||!r)this._append`L${this._x1=e},${this._y1=t}`;else{let u=i-n,g=s-A,y=o*o+l*l,m=u*u+g*g,b=Math.sqrt(y),B=Math.sqrt(d),w=r*Math.tan((gg-Math.acos((y+d-m)/(2*b*B)))/2),_=w/B,T=w/b;Math.abs(_-1)>$n&&this._append`L${e+_*c},${t+_*h}`,this._append`A${r},${r},0,0,${+(h*u>c*g)},${this._x1=e+T*o},${this._y1=t+T*l}`}}arc(e,t,i,s,r,n){if(e=+e,t=+t,i=+i,n=!!n,i<0)throw new Error(`negative radius: ${i}`);let A=i*Math.cos(s),o=i*Math.sin(s),l=e+A,c=t+o,h=1^n,d=n?s-r:r-s;this._x1===null?this._append`M${l},${c}`:(Math.abs(this._x1-l)>$n||Math.abs(this._y1-c)>$n)&&this._append`L${l},${c}`,i&&(d<0&&(d=d%pg+pg),d>TT?this._append`A${i},${i},0,1,${h},${e-A},${t-o}A${i},${i},0,1,${h},${this._x1=l},${this._y1=c}`:d>$n&&this._append`A${i},${i},0,${+(d>=gg)},${h},${this._x1=e+i*Math.cos(r)},${this._y1=t+i*Math.sin(r)}`)}rect(e,t,i,s){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${i=+i}v${+s}h${-i}Z`}toString(){return this._}};function yb(){return new Kn}yb.prototype=Kn.prototype;function QA(a){let e=3;return a.digits=function(t){if(!arguments.length)return e;if(t==null)e=null;else{let i=Math.floor(t);if(!(i>=0))throw new RangeError(`invalid digits: ${t}`);e=i}return a},()=>new Kn(e)}function DT(a){return a.innerRadius}function LT(a){return a.outerRadius}function UT(a){return a.startAngle}function QT(a){return a.endAngle}function kT(a){return a&&a.padAngle}function ET(a,e,t,i,s,r,n,A){var o=t-a,l=i-e,c=n-s,h=A-r,d=h*o-c*l;if(!(d*d<hs))return d=(c*(e-r)-h*(a-s))/d,[a+d*o,e+d*l]}function dc(a,e,t,i,s,r,n){var A=a-t,o=e-i,l=(n?r:-r)/Vn(A*A+o*o),c=l*o,h=-l*A,d=a+c,u=e+h,g=t+c,y=i+h,m=(d+g)/2,b=(u+y)/2,B=g-d,w=y-u,_=B*B+w*w,T=s-r,Q=d*y-g*u,U=(w<0?-1:1)*Vn(fb(0,T*T*_-Q*Q)),E=(Q*w-B*U)/_,O=(-Q*B-w*U)/_,D=(Q*w+B*U)/_,k=(-Q*B+w*U)/_,F=E-m,M=O-b,Y=D-m,z=k-b;return F*F+M*M>Y*Y+z*z&&(E=D,O=k),{cx:E,cy:O,x01:-c,y01:-h,x11:E*(s/T-1),y11:O*(s/T-1)}}function gr(){var a=DT,e=LT,t=It(0),i=null,s=UT,r=QT,n=kT,A=null,o=QA(l);function l(){var c,h,d=+a.apply(this,arguments),u=+e.apply(this,arguments),g=s.apply(this,arguments)-qo,y=r.apply(this,arguments)-qo,m=ug(y-g),b=y>g;if(A||(A=c=o()),u<d&&(h=u,u=d,d=h),!(u>hs))A.moveTo(0,0);else if(m>gb-hs)A.moveTo(u*Za(g),u*fr(g)),A.arc(0,0,u,g,y,!b),d>hs&&(A.moveTo(d*Za(y),d*fr(y)),A.arc(0,0,d,y,g,b));else{var B=g,w=y,_=g,T=y,Q=m,U=m,E=n.apply(this,arguments)/2,O=E>hs&&(i?+i.apply(this,arguments):Vn(d*d+u*u)),D=cc(ug(u-d)/2,+t.apply(this,arguments)),k=D,F=D,M,Y;if(O>hs){var z=fg(O/d*fr(E)),re=fg(O/u*fr(E));(Q-=z*2)>hs?(z*=b?1:-1,_+=z,T-=z):(Q=0,_=T=(g+y)/2),(U-=re*2)>hs?(re*=b?1:-1,B+=re,w-=re):(U=0,B=w=(g+y)/2)}var q=u*Za(B),Ae=u*fr(B),X=d*Za(T),G=d*fr(T);if(D>hs){var ue=u*Za(w),he=u*fr(w),ae=d*Za(_),Ie=d*fr(_),Pe;if(m<UA)if(Pe=ET(q,Ae,ae,Ie,ue,he,X,G)){var De=q-Pe[0],Qe=Ae-Pe[1],dt=ue-Pe[0],Me=he-Pe[1],mi=1/fr(pb((De*dt+Qe*Me)/(Vn(De*De+Qe*Qe)*Vn(dt*dt+Me*Me)))/2),$t=Vn(Pe[0]*Pe[0]+Pe[1]*Pe[1]);k=cc(D,(d-$t)/(mi-1)),F=cc(D,(u-$t)/(mi+1))}else k=F=0}U>hs?F>hs?(M=dc(ae,Ie,q,Ae,u,F,b),Y=dc(ue,he,X,G,u,F,b),A.moveTo(M.cx+M.x01,M.cy+M.y01),F<D?A.arc(M.cx,M.cy,F,Ki(M.y01,M.x01),Ki(Y.y01,Y.x01),!b):(A.arc(M.cx,M.cy,F,Ki(M.y01,M.x01),Ki(M.y11,M.x11),!b),A.arc(0,0,u,Ki(M.cy+M.y11,M.cx+M.x11),Ki(Y.cy+Y.y11,Y.cx+Y.x11),!b),A.arc(Y.cx,Y.cy,F,Ki(Y.y11,Y.x11),Ki(Y.y01,Y.x01),!b))):(A.moveTo(q,Ae),A.arc(0,0,u,B,w,!b)):A.moveTo(q,Ae),!(d>hs)||!(Q>hs)?A.lineTo(X,G):k>hs?(M=dc(X,G,ue,he,d,-k,b),Y=dc(q,Ae,ae,Ie,d,-k,b),A.lineTo(M.cx+M.x01,M.cy+M.y01),k<D?A.arc(M.cx,M.cy,k,Ki(M.y01,M.x01),Ki(Y.y01,Y.x01),!b):(A.arc(M.cx,M.cy,k,Ki(M.y01,M.x01),Ki(M.y11,M.x11),!b),A.arc(0,0,d,Ki(M.cy+M.y11,M.cx+M.x11),Ki(Y.cy+Y.y11,Y.cx+Y.x11),b),A.arc(Y.cx,Y.cy,k,Ki(Y.y11,Y.x11),Ki(Y.y01,Y.x01),!b))):A.arc(0,0,d,T,_,b)}if(A.closePath(),c)return A=null,c+""||null}return l.centroid=function(){var c=(+a.apply(this,arguments)+ +e.apply(this,arguments))/2,h=(+s.apply(this,arguments)+ +r.apply(this,arguments))/2-UA/2;return[Za(h)*c,fr(h)*c]},l.innerRadius=function(c){return arguments.length?(a=typeof c=="function"?c:It(+c),l):a},l.outerRadius=function(c){return arguments.length?(e=typeof c=="function"?c:It(+c),l):e},l.cornerRadius=function(c){return arguments.length?(t=typeof c=="function"?c:It(+c),l):t},l.padRadius=function(c){return arguments.length?(i=c==null?null:typeof c=="function"?c:It(+c),l):i},l.startAngle=function(c){return arguments.length?(s=typeof c=="function"?c:It(+c),l):s},l.endAngle=function(c){return arguments.length?(r=typeof c=="function"?c:It(+c),l):r},l.padAngle=function(c){return arguments.length?(n=typeof c=="function"?c:It(+c),l):n},l.context=function(c){return arguments.length?(A=c??null,l):A},l}var fO=Array.prototype.slice;function uc(a){return typeof a=="object"&&"length"in a?a:Array.from(a)}function vb(a){this._context=a}vb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(a,e){switch(a=+a,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(a,e):this._context.moveTo(a,e);break;case 1:this._point=2;default:this._context.lineTo(a,e);break}}};function Gn(a){return new vb(a)}function fc(a){return a[0]}function gc(a){return a[1]}function Jo(a,e){var t=It(!0),i=null,s=Gn,r=null,n=QA(A);a=typeof a=="function"?a:a===void 0?fc:It(a),e=typeof e=="function"?e:e===void 0?gc:It(e);function A(o){var l,c=(o=uc(o)).length,h,d=!1,u;for(i==null&&(r=s(u=n())),l=0;l<=c;++l)!(l<c&&t(h=o[l],l,o))===d&&((d=!d)?r.lineStart():r.lineEnd()),d&&r.point(+a(h,l,o),+e(h,l,o));if(u)return r=null,u+""||null}return A.x=function(o){return arguments.length?(a=typeof o=="function"?o:It(+o),A):a},A.y=function(o){return arguments.length?(e=typeof o=="function"?o:It(+o),A):e},A.defined=function(o){return arguments.length?(t=typeof o=="function"?o:It(!!o),A):t},A.curve=function(o){return arguments.length?(s=o,i!=null&&(r=s(i)),A):s},A.context=function(o){return arguments.length?(o==null?i=r=null:r=s(i=o),A):i},A}function mg(a,e,t){var i=null,s=It(!0),r=null,n=Gn,A=null,o=QA(l);a=typeof a=="function"?a:a===void 0?fc:It(+a),e=typeof e=="function"?e:e===void 0?It(0):It(+e),t=typeof t=="function"?t:t===void 0?gc:It(+t);function l(h){var d,u,g,y=(h=uc(h)).length,m,b=!1,B,w=new Array(y),_=new Array(y);for(r==null&&(A=n(B=o())),d=0;d<=y;++d){if(!(d<y&&s(m=h[d],d,h))===b)if(b=!b)u=d,A.areaStart(),A.lineStart();else{for(A.lineEnd(),A.lineStart(),g=d-1;g>=u;--g)A.point(w[g],_[g]);A.lineEnd(),A.areaEnd()}b&&(w[d]=+a(m,d,h),_[d]=+e(m,d,h),A.point(i?+i(m,d,h):w[d],t?+t(m,d,h):_[d]))}if(B)return A=null,B+""||null}function c(){return Jo().defined(s).curve(n).context(r)}return l.x=function(h){return arguments.length?(a=typeof h=="function"?h:It(+h),i=null,l):a},l.x0=function(h){return arguments.length?(a=typeof h=="function"?h:It(+h),l):a},l.x1=function(h){return arguments.length?(i=h==null?null:typeof h=="function"?h:It(+h),l):i},l.y=function(h){return arguments.length?(e=typeof h=="function"?h:It(+h),t=null,l):e},l.y0=function(h){return arguments.length?(e=typeof h=="function"?h:It(+h),l):e},l.y1=function(h){return arguments.length?(t=h==null?null:typeof h=="function"?h:It(+h),l):t},l.lineX0=l.lineY0=function(){return c().x(a).y(e)},l.lineY1=function(){return c().x(a).y(t)},l.lineX1=function(){return c().x(i).y(e)},l.defined=function(h){return arguments.length?(s=typeof h=="function"?h:It(!!h),l):s},l.curve=function(h){return arguments.length?(n=h,r!=null&&(A=n(r)),l):n},l.context=function(h){return arguments.length?(h==null?r=A=null:A=n(r=h),l):r},l}var pc=class{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t);break}}this._x0=e,this._y0=t}};function yg(a){return new pc(a,!0)}function vg(a){return new pc(a,!1)}function xg(){}function xb(a,e,t){a._context.bezierCurveTo(a._x1+a._k*(a._x2-a._x0),a._y1+a._k*(a._y2-a._y0),a._x2+a._k*(a._x1-e),a._y2+a._k*(a._y1-t),a._x2,a._y2)}function bb(a,e){this._context=a,this._k=(1-e)/6}bb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:xb(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(a,e){switch(a=+a,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(a,e):this._context.moveTo(a,e);break;case 1:this._point=2,this._x1=a,this._y1=e;break;case 2:this._point=3;default:xb(this,a,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=a,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var bg=(function a(e){function t(i){return new bb(i,e)}return t.tension=function(i){return a(+i)},t})(0);function Bb(a){this._context=a}Bb.prototype={areaStart:xg,areaEnd:xg,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(a,e){a=+a,e=+e,this._point?this._context.lineTo(a,e):(this._point=1,this._context.moveTo(a,e))}};function Bg(a){return new Bb(a)}function wb(a,e){this._context=a,this._t=e}wb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(a,e){switch(a=+a,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(a,e):this._context.moveTo(a,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(a,e);else{var t=this._x*(1-this._t)+a*this._t;this._context.lineTo(t,this._y),this._context.lineTo(t,e)}break}}this._x=a,this._y=e}};function wg(a){return new wb(a,1)}var is=class extends Le{constructor(){super(...arguments),this.ix=0,this.iy=0,this._generator=gr()}_getTooltipPoint(){let e=this.get("tooltipX"),t=this.get("tooltipY"),i=0,s=0;W(e)&&(i=e),W(t)&&(s=t);let r=this.get("radius",0),n=this.get("innerRadius",0),A=this.get("dRadius",0),o=this.get("dInnerRadius",0);return r+=A,n+=o,n<0&&(n=r+n),e instanceof ke&&(i=this.ix*(n+(r-n)*e.value)),t instanceof ke&&(s=this.iy*(n+(r-n)*t.value)),this.get("arc")>=360&&n==0&&(i=0,s=0),{x:i,y:s}}_beforeChanged(){super._beforeChanged(),(this.isDirty("radius")||this.isDirty("arc")||this.isDirty("innerRadius")||this.isDirty("startAngle")||this.isDirty("dRadius")||this.isDirty("dInnerRadius")||this.isDirty("cornerRadius")||this.isDirty("shiftRadius"))&&(this._clear=!0)}_changed(){if(super._changed(),this._clear){let e=this.get("startAngle",0),t=this.get("arc",0),i=this._generator;t<0&&(e=e+t,t=t*-1),t>.1&&i.cornerRadius(this.get("cornerRadius",0)),i.context(this._display);let s=this.get("radius",0),r=this.get("innerRadius",0),n=this.get("dRadius",0),A=this.get("dInnerRadius",0);s+=n,r+=A,r<0&&(r=s+r),i({innerRadius:r,outerRadius:s,startAngle:(e+90)*Kt,endAngle:(e+t+90)*Kt});let o=e+t/2;this.ix=ft(o),this.iy=At(o);let l=this.get("shiftRadius",0);this.setRaw("dx",this.ix*l),this.setRaw("dy",this.iy*l),this.markDirtyPosition()}}};is.className="Slice";is.classNames=Le.classNames.concat([is.className]);var qa=class extends pe{constructor(){super(...arguments),this.chartContainer=this.children.push(pe.new(this._root,{width:se,height:se,interactiveChildren:!1})),this.bulletsContainer=pe.new(this._root,{interactiveChildren:!1,isMeasured:!1,position:"absolute",width:se,height:se})}};qa.className="Chart";qa.classNames=pe.classNames.concat([qa.className]);var Fi=class extends qa{constructor(){super(...arguments),this.seriesContainer=pe.new(this._root,{width:se,height:se,isMeasured:!1}),this.series=new Ga}_afterNew(){super._afterNew(),this._disposers.push(this.series);let e=this.seriesContainer.children;this._disposers.push(this.series.events.onAll(t=>{if(t.type==="clear"){K(t.oldValues,r=>{this._removeSeries(r)});let i=this.get("colors");i&&i.reset();let s=this.get("patterns");s&&s.reset()}else if(t.type==="push")e.moveValue(t.newValue),this._processSeries(t.newValue);else if(t.type==="setIndex")e.setIndex(t.index,t.newValue),this._processSeries(t.newValue);else if(t.type==="insertIndex")e.insertIndex(t.index,t.newValue),this._processSeries(t.newValue);else if(t.type==="removeIndex")this._removeSeries(t.oldValue);else if(t.type==="moveIndex")e.moveValue(t.value,t.newIndex),this._processSeries(t.value);else if(t.type==="swap"){let i=t.a,s=t.b,r=this.series.indexOf(i),n=this.series.indexOf(s);e.moveValue(i,n),e.moveValue(s,r),this.series.each(A=>{this._processSeries(A),A.markDirtyValues()})}else throw new Error("Unknown IListEvent type")}))}_processSeries(e){e.chart=this,e._placeBulletsContainer(this)}_removeSeries(e){e._handleRemoved(),e.isDisposed()||(this.seriesContainer.children.removeValue(e),e._removeBulletsContainer())}};Fi.className="SerialChart";Fi.classNames=qa.classNames.concat([Fi.className]);var Nr=class extends ja{};Nr.className="Tick";Nr.classNames=ja.classNames.concat([Nr.className]);var ya=class extends ws{_beforeChanged(){super._beforeChanged(),this.isDirty("gap")&&(this._clear=!0)}_draw(){super._draw();let e=this.get("width",100),t=this.get("height",100),i=this.get("gap",0),s=this.get("strokeWidth",1);if(!i)this._display.moveTo(0,0),this._display.lineTo(e,0);else{let A=i+s,o=t/A,l=this.get("angle",0)*Math.PI/180;if(l===0)for(let c=-o;c<o*2;c++){let h=Math.round(c*A-A/2)+.5;this._display.moveTo(-e,h),this._display.lineTo(e*2,h)}else{let c=Math.cos(l),h=Math.sin(l),d=Math.sqrt(e*e+t*t)*2,u=A/Math.max(Math.abs(c),Math.abs(h)),g=Math.ceil(d/u)*2;for(let y=-g;y<g;y++){let m=y*A,b=m*h-d*c,B=m*c+d*h,w=m*h+d*c,_=m*c-d*h;this._display.moveTo(b,B),this._display.lineTo(w,_)}}}this._display.lineStyle(s,this.get("color"),this.get("colorOpacity"));let r=this.get("strokeDasharray");W(r)&&(r<.5?r=[0]:r=[r]),this._display.setLineDash(r);let n=this.get("strokeDashoffset");n&&this._display.setLineDashOffset(n),this._display.endStroke()}};ya.className="LinePattern";ya.classNames=ws.classNames.concat([ya.className]);var Ja=class extends ws{_beforeChanged(){super._beforeChanged(),this.isDirty("gap")&&(this._clear=!0)}_draw(){super._draw();let e=this.get("checkered",!1),t=this.get("centered",!0),i=this.get("gap",0),s=this.get("rotation",0),r=this.get("width",100),n=this.get("height",100),A=this.get("maxWidth",5),o=this.get("maxHeight",5),l=this._display,c=A+i,h=o+i,d=Math.round(r/c),u=Math.round(n/h);c=r/d,h=n/u,s!=0&&(l.x=c/2*ft(s),l.y=-h/2*At(s));for(let m=s==0?0:-u*2;m<u*2;m++)for(let b=s==0?0:-d*2;b<d*2;b++)if(!e||(m&1)!=1&&(b&1)!=1||(m&1)==1&&(b&1)==1){let B=b*c,w=m*h;t&&(B+=(c-A)/2,w+=(h-o)/2),l.drawRect(B,w,A,o)}e?(r=r/2-i*2,n=n/2-i*2):(r-=i,n-=i);let g=this.get("color"),y=this.get("colorOpacity");(g||y)&&(l.beginFill(g,y),l.endFill())}};Ja.className="RectanglePattern";Ja.classNames=ws.classNames.concat([Ja.className]);var Vr=class extends nt{_afterNew(){super._afterNewApplyThemes(),this._dirty.colors=!1}_beforeChanged(){this.isDirty("colors")&&this.reset()}generateColors(){this.setPrivate("currentPass",this.getPrivate("currentPass",0)+1);let e=this.getPrivate("currentPass"),t=this.get("colors",[this.get("baseColor",we.fromHex(16711680))]);this.getPrivate("numColors")||this.setPrivate("numColors",t.length);let i=this.getPrivate("numColors"),s=0,r=this.get("passOptions"),n=this.get("reuse");for(let A=s;A<i;A++)if(n)t.push(t[A]);else{let o=t[A].toHSL(),l=o.h+(r.hue||0)*e;for(;l>1;)l-=1;let c=o.s+(r.saturation||0)*e;c>1&&(c=1),c<0&&(c=0);let h=o.l+(r.lightness||0)*e;for(;h>1;)h-=1;t.push(we.fromHSL(l,c,h))}}getIndex(e){let t=this.get("colors",[]),i=this.get("saturation");return e>=t.length?(this.generateColors(),this.getIndex(e)):i!=null?we.saturate(t[e],i):t[e]}next(){let e=this.getPrivate("currentStep",this.get("startIndex",0));return this.setPrivate("currentStep",e+this.get("step",1)),this.getIndex(e)}reset(){this.setPrivate("currentStep",this.get("startIndex",0)),this.setPrivate("currentPass",0)}};Vr.className="ColorSet";Vr.classNames=nt.classNames.concat([Vr.className]);var mc=class extends _s{setupDefaultRules(){super.setupDefaultRules();let e=this._root.interfaceColors,t=this.rule.bind(this);t("PercentSeries").setAll({legendLabelText:"{category}",legendValueText:"{valuePercentTotal.formatNumber('0.00p')}",colors:Vr.new(this._root,{}),width:se,height:se}),t("PieChart").setAll({radius:Re(80),startAngle:-90,endAngle:270}),t("PieSeries").setAll({alignLabels:!0,startAngle:-90,endAngle:270}),t("PieSeries").states.create("hidden",{endAngle:-90,opacity:0}),t("Slice",["pie"]).setAll({position:"absolute",isMeasured:!1,x:0,y:0,toggleKey:"active",tooltipText:"{category}: {valuePercentTotal.formatNumber('0.00p')}",strokeWidth:1,strokeOpacity:1,role:"figure",lineJoin:"round"}),t("Slice",["pie"]).states.create("active",{shiftRadius:20,scale:1}),t("Slice",["pie"]).states.create("hoverActive",{scale:1.04}),t("Slice",["pie"]).states.create("hover",{scale:1.04}),t("RadialLabel",["pie"]).setAll({textType:"aligned",radius:10,text:"{category}: {valuePercentTotal.formatNumber('0.00p')}",paddingTop:5,paddingBottom:5,populateText:!0}),t("Tick",["pie"]).setAll({location:1}),t("SlicedChart").setAll({paddingLeft:10,paddingRight:10,paddingTop:10,paddingBottom:10}),t("FunnelSeries").setAll({startLocation:0,endLocation:1,orientation:"vertical",alignLabels:!0,sequencedInterpolation:!0}),t("FunnelSlice").setAll({interactive:!0,expandDistance:0}),t("FunnelSlice").states.create("hover",{expandDistance:.15}),t("Label",["funnel"]).setAll({populateText:!0,text:"{category}: {valuePercentTotal.formatNumber('0.00p')}",centerY:ye}),t("Label",["funnel","horizontal"]).setAll({centerX:0,centerY:ye,rotation:-90}),t("Label",["funnel","vertical"]).setAll({centerY:ye,centerX:0}),t("Tick",["funnel"]).setAll({location:1}),t("FunnelSlice",["funnel","link"]).setAll({fillOpacity:.5,strokeOpacity:0,expandDistance:-.1}),t("FunnelSlice",["funnel","link","vertical"]).setAll({height:10}),t("FunnelSlice",["funnel","link","horizontal"]).setAll({width:10}),t("PyramidSeries").setAll({valueIs:"area"}),t("FunnelSlice",["pyramid","link"]).setAll({fillOpacity:.5}),t("FunnelSlice",["pyramid","link","vertical"]).setAll({height:0}),t("FunnelSlice",["pyramid","link","horizontal"]).setAll({width:0}),t("FunnelSlice",["pyramid"]).setAll({interactive:!0,expandDistance:0}),t("FunnelSlice",["pyramid"]).states.create("hover",{expandDistance:.15}),t("Label",["pyramid"]).setAll({populateText:!0,text:"{category}: {valuePercentTotal.formatNumber('0.00p')}",centerY:ye}),t("Label",["pyramid","horizontal"]).setAll({centerX:0,centerY:ye,rotation:-90}),t("Label",["pyramid","vertical"]).setAll({centerY:ye,centerX:0}),t("Tick",["pyramid"]).setAll({location:1}),t("FunnelSlice",["pictorial"]).setAll({interactive:!0,tooltipText:"{category}: {valuePercentTotal.formatNumber('0.00p')}"}),t("Label",["pictorial"]).setAll({populateText:!0,text:"{category}: {valuePercentTotal.formatNumber('0.00p')}",centerY:ye}),t("Label",["pictorial","horizontal"]).setAll({centerX:0,centerY:ye,rotation:-90}),t("Label",["pictorial","vertical"]).setAll({centerY:ye,centerX:0}),t("FunnelSlice",["pictorial","link"]).setAll({fillOpacity:.5,width:0,height:0}),t("Tick",["pictorial"]).setAll({location:.5});{let i=t("Graphics",["pictorial","background"]);i.setAll({fillOpacity:.2}),ve(i,"fill",e,"alternativeBackground")}}};var en=class extends Fi{_afterNew(){this._defaultThemes.push(mc.new(this._root)),super._afterNew(),this.chartContainer.children.push(this.seriesContainer),this.seriesContainer.children.push(this.bulletsContainer)}_processSeries(e){super._processSeries(e),this.seriesContainer.children.moveValue(this.bulletsContainer,this.seriesContainer.children.length-1)}};en.className="PercentChart";en.classNames=Fi.classNames.concat([en.className]);var tn=class extends ti{constructor(){super(...arguments),this.slicesContainer=this.children.push(pe.new(this._root,{position:"absolute",isMeasured:!1})),this.labelsContainer=this.children.push(pe.new(this._root,{position:"absolute",isMeasured:!1})),this.ticksContainer=this.children.push(pe.new(this._root,{position:"absolute",isMeasured:!1})),this._lLabels=[],this._rLabels=[],this._hLabels=[],this.slices=this.addDisposer(this._makeSlices()),this.labels=this.addDisposer(this._makeLabels()),this.ticks=this.addDisposer(this._makeTicks())}_applyThemes(e=!1){let t=this.get("colors");return t&&t.reset(),super._applyThemes(e)}makeSlice(e){let t=this.slicesContainer.children.push(this.slices.make());return t.on("fill",()=>{this.updateLegendMarker(e)}),t.on("fillPattern",()=>{this.updateLegendMarker(e)}),t.on("stroke",()=>{this.updateLegendMarker(e)}),t._setDataItem(e),e.set("slice",t),this.slices.push(t),t}makeLabel(e){let t=this.labelsContainer.children.push(this.labels.make());return t._setDataItem(e),e.set("label",t),this.labels.push(t),t}_shouldMakeBullet(e){return e.get("value")!=null}makeTick(e){let t=this.ticksContainer.children.push(this.ticks.make());return t._setDataItem(e),e.set("tick",t),this.ticks.push(t),t}_afterNew(){this.fields.push("category","fill"),super._afterNew()}_onDataClear(){let e=this.get("colors");e&&e.reset();let t=this.get("patterns");t&&t.reset()}_prepareChildren(){if(super._prepareChildren(),this._lLabels=[],this._rLabels=[],this._hLabels=[],this._valuesDirty){let e=0,t=0,i=0,s=1/0,r=0;K(this._dataItems,n=>{let A=n.get("valueWorking",0);e+=A,t+=Math.abs(A)}),K(this._dataItems,n=>{let A=n.get("valueWorking",0);A>i&&(i=A),A<s&&(s=A),r++;let o=A/t;t==0&&(o=0),n.setRaw("valuePercentTotal",o*100)}),this.setPrivateRaw("valueLow",s),this.setPrivateRaw("valueHigh",i),this.setPrivateRaw("valueSum",e),this.setPrivateRaw("valueAverage",e/r),this.setPrivateRaw("valueAbsoluteSum",t)}}show(e){let t=Object.create(null,{show:{get:()=>super.show}});return Ke(this,void 0,void 0,function*(){let i=[];i.push(t.show.call(this,e)),i.push(this._sequencedShowHide(!0,e)),yield Promise.all(i)})}hide(e){let t=Object.create(null,{hide:{get:()=>super.hide}});return Ke(this,void 0,void 0,function*(){let i=[];i.push(t.hide.call(this,e)),i.push(this._sequencedShowHide(!1,e)),yield Promise.all(i)})}_updateChildren(){super._updateChildren(),this._valuesDirty&&K(this._dataItems,e=>{e.get("label").text.markDirtyText()}),(this.isDirty("legendLabelText")||this.isDirty("legendValueText"))&&K(this._dataItems,e=>{this.updateLegendValue(e)}),this._arrange()}_arrange(){this._arrangeDown(this._lLabels),this._arrangeUp(this._lLabels),this._arrangeDown(this._rLabels),this._arrangeUp(this._rLabels),this._arrangeLeft(this._hLabels),this._arrangeRight(this._hLabels),K(this.dataItems,e=>{this._updateTick(e)})}_afterChanged(){super._afterChanged(),this._arrange()}processDataItem(e){if(super.processDataItem(e),e.get("fill")==null){let t=this.get("colors");t&&e.setRaw("fill",t.next())}if(e.get("fillPattern")==null){let t=this.get("patterns");t&&e.setRaw("fillPattern",t.next())}}showDataItem(e,t){let i=Object.create(null,{showDataItem:{get:()=>super.showDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.showDataItem.call(this,e,t)];W(t)||(t=this.get("stateAnimationDuration",0));let r=this.get("stateAnimationEasing"),n=e.get("value"),A=e.animate({key:"valueWorking",to:n,duration:t,easing:r});A&&s.push(A.waitForStop());let o=e.get("tick");o&&s.push(o.show(t));let l=e.get("label");l&&s.push(l.show(t));let c=e.get("slice");c&&s.push(c.show(t)),c.get("active")&&c.states.applyAnimate("active"),yield Promise.all(s)})}hideDataItem(e,t){let i=Object.create(null,{hideDataItem:{get:()=>super.hideDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.hideDataItem.call(this,e,t)],r=this.states.create("hidden",{});W(t)||(t=r.get("stateAnimationDuration",this.get("stateAnimationDuration",0)));let n=r.get("stateAnimationEasing",this.get("stateAnimationEasing")),A=e.animate({key:"valueWorking",to:0,duration:t,easing:n});A&&s.push(A.waitForStop());let o=e.get("tick");o&&s.push(o.hide(t));let l=e.get("label");l&&s.push(l.hide(t));let c=e.get("slice");c.hideTooltip(),c&&s.push(c.hide(t)),yield Promise.all(s)})}disposeDataItem(e){super.disposeDataItem(e);let t=e.get("label");t&&(this.labels.removeValue(t),t.dispose());let i=e.get("tick");i&&(this.ticks.removeValue(i),i.dispose());let s=e.get("slice");s&&(this.slices.removeValue(s),s.dispose())}hoverDataItem(e){let t=e.get("slice");t&&!t.isHidden()&&t.hover()}unhoverDataItem(e){let t=e.get("slice");t&&t.unhover()}updateLegendMarker(e){if(e){let t=e.get("slice");if(t){let i=e.get("legendDataItem");if(i){let s=i.get("markerRectangle");K(Ko,r=>{t.get(r)!=null&&s.set(r,t.get(r))})}}}}_arrangeDown(e){if(e){let t=this._getNextDown();e.sort((i,s)=>i.y>s.y?1:i.y<s.y?-1:0),K(e,i=>{let s=i.label.adjustedLocalBounds(),r=s.top;i.y+r<t&&(i.y=t-r),i.label.set("y",i.y),t=i.y+s.bottom})}}_getNextUp(){return this.labelsContainer.maxHeight()}_getNextDown(){return 0}_arrangeUp(e){if(e){let t=this._getNextUp();e.sort((i,s)=>i.y<s.y?1:i.y>s.y?-1:0),K(e,i=>{let s=i.label.adjustedLocalBounds(),r=s.bottom;i.y+r>t&&(i.y=t-r),i.label.set("y",i.y),t=i.y+s.top})}}_arrangeRight(e){if(e){let t=0;e.sort((i,s)=>i.y>s.y?1:i.y<s.y?-1:0),K(e,i=>{let s=i.label.adjustedLocalBounds(),r=s.left;i.y+r<t&&(i.y=t-r),i.label.set("x",i.y),t=i.y+s.right})}}_arrangeLeft(e){if(e){let t=this.labelsContainer.maxWidth();e.sort((i,s)=>i.y<s.y?1:i.y>s.y?-1:0),K(e,i=>{let s=i.label.adjustedLocalBounds(),r=s.right;i.y+r>t&&(i.y=t-r),i.label.set("x",i.y),t=i.y+s.left})}}_updateSize(){super._updateSize(),this.markDirty()}_updateTick(e){}_dispose(){super._dispose();let e=this.chart;e&&e.series.removeValue(this)}};tn.className="PercentSeries";tn.classNames=ti.classNames.concat([tn.className]);var Li=class extends en{constructor(){super(...arguments),this._maxRadius=1}_afterNew(){super._afterNew(),this.seriesContainer.setAll({x:ye,y:ye})}_prepareChildren(){super._prepareChildren();let e=this.chartContainer,t=e.innerWidth(),i=e.innerHeight(),s=this.get("startAngle",0),r=this.get("endAngle",0),n=this.get("innerRadius"),A=Xa(0,0,s,r,1),o=t/(A.right-A.left),l=i/(A.bottom-A.top),c={left:0,right:0,top:0,bottom:0};if(n instanceof ke){let u=n.value,g=Math.min(o,l);u=Math.max(g*u,g-Math.min(i,t))/g,c=Xa(0,0,s,r,u),this.setPrivateRaw("irModifyer",u/n.value)}A=Xh([A,c]);let h=this._maxRadius;this._maxRadius=Math.min(o,l);let d=We(this.get("radius",0),this._maxRadius);this.seriesContainer.setAll({dy:-d*(A.bottom+A.top)/2,dx:-d*(A.right+A.left)/2}),(this.isDirty("startAngle")||this.isDirty("endAngle")||h!=this._maxRadius)&&this.series.each(u=>{u._markDirtyKey("startAngle")}),(this.isDirty("innerRadius")||this.isDirty("radius"))&&this.series.each(u=>{u._markDirtyKey("innerRadius")})}radius(e){let t=We(this.get("radius",0),this._maxRadius),i=We(this.get("innerRadius",0),t);if(e){let s=this.series.indexOf(e),r=this.series.length,n=e.get("radius");return n!=null?i+We(n,t-i):i+(t-i)/r*(s+1)}return t}innerRadius(e){let t=this.radius(),i=We(this.get("innerRadius",0),t);if(i<0&&(i=t+i),e){let s=this.series.indexOf(e),r=this.series.length,n=e.get("innerRadius");return n!=null?i+We(n,t-i):i+(t-i)/r*s}return i}_updateSize(){super._updateSize(),this.markDirtyKey("radius")}};Li.className="PieChart";Li.classNames=en.classNames.concat([Li.className]);var ni=class extends tn{_makeSlices(){return new pt(Ne.new({}),()=>is._new(this._root,{themeTags:Fe(this.slices.template.get("themeTags",[]),["pie","series"])},[this.slices.template]))}_makeLabels(){return new pt(Ne.new({}),()=>Rr._new(this._root,{themeTags:Fe(this.labels.template.get("themeTags",[]),["pie","series"])},[this.labels.template]))}_makeTicks(){return new pt(Ne.new({}),()=>Nr._new(this._root,{themeTags:Fe(this.ticks.template.get("themeTags",[]),["pie","series"])},[this.ticks.template]))}processDataItem(e){super.processDataItem(e);let t=this.makeSlice(e);t.on("scale",()=>{this._updateTick(e)}),t.on("shiftRadius",()=>{this._updateTick(e)}),t.events.on("positionchanged",()=>{this._updateTick(e)});let i=this.makeLabel(e);i.events.on("positionchanged",()=>{this._updateTick(e)}),this.makeTick(e),t.events.on("positionchanged",()=>{i.markDirty()})}_getNextUp(){let e=this.chart;return e?e._maxRadius:this.labelsContainer.maxHeight()/2}_getNextDown(){let e=this.chart;return e?-e._maxRadius:-this.labelsContainer.maxHeight()/2}_prepareChildren(){super._prepareChildren();let e=this.chart;if(e){if(this.isDirty("alignLabels")){let t=this.labels.template;if(this.get("alignLabels"))t.set("textType","aligned");else{let i=t.get("textType");(i==null||i=="aligned")&&t.set("textType","adjusted")}}if(this._valuesDirty||this.isDirty("radius")||this.isDirty("innerRadius")||this.isDirty("startAngle")||this.isDirty("endAngle")||this.isDirty("alignLabels")){this.markDirtyBounds();let t=this.get("startAngle",e.get("startAngle",-90)),s=this.get("endAngle",e.get("endAngle",270))-t,r=t,n=e.radius(this);this.setPrivateRaw("radius",n);let A=e.innerRadius(this)*e.getPrivate("irModifyer",1);A<0&&(A=n+A),K(this._dataItems,o=>{this.updateLegendValue(o);let l=s*o.get("valuePercentTotal")/100,c=o.get("slice");if(c){c.set("radius",n),c.set("innerRadius",A),c.set("startAngle",r),c.set("arc",l);let u=o.get("fill");c._setDefault("fill",u),c._setDefault("stroke",u);let g=o.get("fillPattern");c._setDefault("fillPattern",g)}let h=es(r+l/2),d=o.get("label");if(d&&(d.setPrivate("radius",n),d.setPrivate("innerRadius",A),d.set("labelAngle",h),d.get("textType")=="aligned")){let u=n+d.get("radius",0),g=n*At(h);h>90&&h<=270?(!d.isHidden()&&!d.isHiding()&&this._lLabels.push({label:d,y:g}),u*=-1,u-=this.labelsContainer.get("paddingLeft",0),d.set("centerX",se),d.setPrivateRaw("left",!0)):(!d.isHidden()&&!d.isHiding()&&this._rLabels.push({label:d,y:g}),u+=this.labelsContainer.get("paddingRight",0),d.set("centerX",0),d.setPrivateRaw("left",!1)),d.set("x",u),d.set("y",n*At(h))}r+=l,this._updateTick(o)})}}}_updateTick(e){let t=e.get("tick"),i=e.get("label"),s=e.get("slice"),r=t.get("location",1);if(t&&i&&s){let n=(s.get("shiftRadius",0)+s.get("radius",0))*s.get("scale",1)*r,A=i.get("labelAngle",0),o=ft(A),l=At(A),c=this.labelsContainer,h=c.get("paddingLeft",0),d=c.get("paddingRight",0),u=0,g=0;u=i.x(),g=i.y();let y=[];if(u!=0||g!=0){if(i.get("textType")=="circular"){let b=i.radius()-i.get("paddingBottom",0),B=i.get("labelAngle",0);u=b*ft(B),g=b*At(B)}let m=-d;i.getPrivate("left")&&(m=h),y=[{x:s.x()+n*o,y:s.y()+n*l},{x:u+m,y:g},{x:u,y:g}]}t.set("points",y)}}_positionBullet(e){let t=e.get("sprite");if(t){let s=t.dataItem.get("slice");if(s){let r=s.get("innerRadius",0),n=s.get("radius",0),A=s.get("startAngle",0),o=s.get("arc",0),l=e.get("locationX",.5),c=e.get("locationY",.5),h=A+o*l,d=r+(n-r)*c;t.setAll({x:ft(h)*d,y:At(h)*d})}}}};ni.className="PieSeries";ni.classNames=tn.classNames.concat([ni.className]);var Xn=class extends Nr{constructor(){super(...arguments),this._tickPoints=[]}};Xn.className="AxisTick";Xn.classNames=Nr.classNames.concat([Xn.className]);var $r=class extends Le{_beforeChanged(){super._beforeChanged(),(this.isPrivateDirty("width")||this.isPrivateDirty("height"))&&(this._clear=!0)}};$r.className="Grid";$r.classNames=Le.classNames.concat([$r.className]);var Wn=class extends Ze{constructor(){super(...arguments),this._tickPoints=[]}};Wn.className="AxisLabel";Wn.classNames=Ze.classNames.concat([Wn.className]);var Gi=class extends Le{constructor(){super(...arguments),this._axisLength=100,this._start=0,this._end=1,this._inversed=!1,this._minSize=0,this._lc=1,this._ls=0,this.ticks=this.addDisposer(new pt(Ne.new({}),()=>Xn._new(this._root,{themeTags:Fe(this.ticks.template.get("themeTags",[]),this.get("themeTags",[]))},[this.ticks.template]))),this.grid=this.addDisposer(new pt(Ne.new({}),()=>$r._new(this._root,{themeTags:Fe(this.grid.template.get("themeTags",[]),this.get("themeTags",[]))},[this.grid.template]))),this.axisFills=this.addDisposer(new pt(Ne.new({}),()=>Le._new(this._root,{themeTags:Fe(this.axisFills.template.get("themeTags",["axis","fill"]),this.get("themeTags",[]))},[this.axisFills.template]))),this.labels=this.addDisposer(new pt(Ne.new({}),()=>Wn._new(this._root,{themeTags:Fe(this.labels.template.get("themeTags",[]),this.get("themeTags",[]))},[this.labels.template])))}makeTick(e,t){let i=this.ticks.make();return i._setDataItem(e),e.setRaw("tick",i),i.set("themeTags",Fe(i.get("themeTags"),t)),this.axis.labelsContainer.children.push(i),this.ticks.push(i),i}makeGrid(e,t){let i=this.grid.make();return i._setDataItem(e),e.setRaw("grid",i),i.set("themeTags",Fe(i.get("themeTags"),t)),this.axis.gridContainer.children.push(i),this.grid.push(i),i}makeAxisFill(e,t){let i=this.axisFills.make();return i._setDataItem(e),i.set("themeTags",Fe(i.get("themeTags"),t)),this.axis.gridContainer.children.push(i),e.setRaw("axisFill",i),this.axisFills.push(i),i}makeLabel(e,t){let i=this.labels.make();return i.set("themeTags",Fe(i.get("themeTags"),t)),e.get("isRange")?this.axis.labelsContainer.children.push(i):this.axis.labelsContainer.children.moveValue(i,0),i._setDataItem(e),e.setRaw("label",i),this.labels.push(i),i}axisLength(){return 0}gridCount(){return this.axisLength()/this.get("minGridDistance",50)}_updatePositions(){}_afterNew(){super._afterNew(),this.set("isMeasured",!1);let e=this.thumb;e&&(this._disposers.push(e.events.on("pointerdown",t=>{this._handleThumbDown(t)})),this._disposers.push(e.events.on("globalpointerup",t=>{this._handleThumbUp(t)})),this._disposers.push(e.events.on("globalpointermove",t=>{this._handleThumbMove(t)})))}_beforeChanged(){super._beforeChanged(),this.isDirty("minGridDistance")&&this.root.events.once("frameended",()=>{this.axis.markDirtySize()})}_changed(){if(super._changed(),this.isDirty("pan")){let e=this.thumb;if(e){let t=this.axis.labelsContainer,i=this.get("pan");i=="zoom"?t.children.push(e):i=="none"&&t.children.removeValue(e)}}}_handleThumbDown(e){this._thumbDownPoint=this.toLocal(e.point);let t=this.axis;this._downStart=t.get("start"),this._downEnd=t.get("end")}_handleThumbUp(e){this._thumbDownPoint=void 0}_handleThumbMove(e){let t=this._thumbDownPoint;if(t){let i=this.toLocal(e.point),s=this._downStart,r=this._downEnd,n=this._getPan(i,t)*Math.min(1,r-s)/2*this.get("panSensitivity",1);this.axis.zoom(s-n,r+n,0)}}_getPan(e,t){return 0}positionToCoordinate(e){return this._inversed?(this._end-e)*this._axisLength:(e-this._start)*this._axisLength}updateTooltipBounds(e){}_updateSize(){this.markDirty(),this._clear=!0}toAxisPosition(e){let t=this._start||0,i=this._end||1;return e=e*(i-t),this.get("inversed")?e=i-e:e=t+e,e}toGlobalPosition(e){let t=this._start||0,i=this._end||1;return this.get("inversed")?e=i-e:e=e-t,e=e/(i-t),e}fixPosition(e){return this.get("inversed")?1-e:e}_updateLC(){}toggleVisibility(e,t,i,s){let r=this.axis,n=r.get("start",0),A=r.get("end",1),o=n+(A-n)*(i-1e-4),l=n+(A-n)*(s+1e-4);t<o||t>l?e.setPrivate("visible",!1):e.setPrivate("visible",!0)}_positionTooltip(e,t){let i=this.chart;i&&(e.set("pointTo",this._display.toGlobal(t)),i.inPlot(t)||e.hide())}processAxis(){}};Gi.className="AxisRenderer";Gi.classNames=Le.classNames.concat([Gi.className]);var va=class extends Rr{constructor(){super(...arguments),this._tickPoints=[]}};va.className="AxisLabelRadial";va.classNames=Rr.classNames.concat([va.className]);var Ui=class extends Gi{constructor(){super(...arguments),this.labels=this.addDisposer(new pt(Ne.new({}),()=>va._new(this._root,{themeTags:Fe(this.labels.template.get("themeTags",[]),this.get("themeTags",[]))},[this.labels.template]))),this.axisFills=this.addDisposer(new pt(Ne.new({}),()=>is._new(this._root,{themeTags:Fe(this.axisFills.template.get("themeTags",["fill"]),this.get("themeTags",[]))},[this.axisFills.template]))),this._fillGenerator=gr()}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["renderer","circular"]),super._afterNew(),this.setPrivateRaw("letter","X"),this.setRaw("position","absolute")}_changed(){super._changed(),(this.isDirty("radius")||this.isDirty("innerRadius")||this.isDirty("startAngle")||this.isDirty("endAngle"))&&this.updateLayout()}processAxis(){super.processAxis(),this.axis.labelsContainer.set("isMeasured",!1)}updateLayout(){let e=this.chart;if(e){let t=e.getPrivate("radius",0),i=We(this.get("radius",se),t);i<0&&(i=t+i),this.setPrivate("radius",i);let s=We(this.get("innerRadius",e.getPrivate("innerRadius",0)),t)*e.getPrivate("irModifyer",1);s<0&&(s=i+s),this.setPrivate("innerRadius",s);let r=this.get("startAngle",e.get("startAngle",-90)),n=this.get("endAngle",e.get("endAngle",270));this.setPrivate("startAngle",r),this.setPrivate("endAngle",n),this.set("draw",A=>{let o=this.positionToPoint(0);A.moveTo(o.x,o.y),r>n&&([r,n]=[n,r]),A.arc(0,0,i,r*Kt,n*Kt)}),this.axis.markDirtySize()}}updateGrid(e,t,i){if(e){t==null&&(t=0);let s=e.get("location",.5);i!=null&&i!=t&&(t=t+(i-t)*s);let r=this.getPrivate("radius",0),n=this.getPrivate("innerRadius",0),A=this.positionToAngle(t);this.toggleVisibility(e,t,0,1),r!=null&&e.set("draw",o=>{o.moveTo(n*ft(A),n*At(A)),o.lineTo(r*ft(A),r*At(A))})}}positionToAngle(e){let t=this.axis,i=this.getPrivate("startAngle",0),s=this.getPrivate("endAngle",360),r=t.get("start",0),n=t.get("end",1),A=(s-i)/(n-r),o;return this.get("inversed")?o=i+(n-e)*A:o=i+(e-r)*A,o}_handleOpposite(){}positionToPoint(e){let t=this.getPrivate("radius",0),i=this.positionToAngle(e);return{x:t*ft(i),y:t*At(i)}}updateLabel(e,t,i,s){if(e){t==null&&(t=0);let r=.5;s!=null&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),i!=null&&i!=t&&(t=t+(i-t)*r);let n=this.getPrivate("radius",0),A=this.getPrivate("innerRadius",0),o=this.positionToAngle(t);e.setPrivate("radius",n),e.setPrivate("innerRadius",A),e.set("labelAngle",o),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}fillDrawMethod(e,t,i){e.set("draw",s=>{t==null&&(t=this.getPrivate("startAngle",0)),i==null&&(i=this.getPrivate("endAngle",0));let r=this.getPrivate("innerRadius",0),n=this.getPrivate("radius",0);this._fillGenerator.context(s),this._fillGenerator({innerRadius:r,outerRadius:n,startAngle:(t+90)*Kt,endAngle:(i+90)*Kt})})}updateTick(e,t,i,s){if(e){t==null&&(t=0);let r=.5;s!=null&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),i!=null&&i!=t&&(t=t+(i-t)*r);let n=e.get("length",0);e.get("inside")&&(n*=-1);let o=this.getPrivate("radius",0),l=this.positionToAngle(t);this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1)),o!=null&&e.set("draw",c=>{c.moveTo(o*ft(l),o*At(l)),o+=n,c.lineTo(o*ft(l),o*At(l))})}}updateBullet(e,t,i){if(e){let s=e.get("sprite");if(s){t==null&&(t=0);let r=e.get("location",.5);i!=null&&i!=t&&(t=t+(i-t)*r);let n=this.getPrivate("radius",0),A=this.positionToAngle(t);this.toggleVisibility(s,t,0,1),s.setAll({rotation:A,x:n*ft(A),y:n*At(A)})}}}updateFill(e,t,i){if(e){t==null&&(t=0),i==null&&(i=1);let s=this.fitAngle(this.positionToAngle(t)),r=this.fitAngle(this.positionToAngle(i));e.setAll({startAngle:s,arc:r-s}),e._setSoft("innerRadius",this.getPrivate("innerRadius")),e._setSoft("radius",this.getPrivate("radius"))}}fitAngle(e){let t=this.getPrivate("startAngle",0),i=this.getPrivate("endAngle",0),s=Math.min(t,i),r=Math.max(t,i);return e<s&&(e=s),e>r&&(e=r),e}axisLength(){return Math.abs(this.getPrivate("radius",0)*Math.PI*2*(this.getPrivate("endAngle",360)-this.getPrivate("startAngle",0))/360)}positionTooltip(e,t){let i=this.getPrivate("radius",0),s=this.positionToAngle(t);this._positionTooltip(e,{x:i*ft(s),y:i*At(s)})}updateTooltipBounds(e){}};Ui.className="AxisRendererCircular";Ui.classNames=Gi.classNames.concat([Ui.className]);var sn=class extends Gi{constructor(){super(...arguments),this._fillGenerator=gr(),this.labels=this.addDisposer(new pt(Ne.new({}),()=>va._new(this._root,{themeTags:Fe(this.labels.template.get("themeTags",[]),this.get("themeTags",[]))},[this.labels.template])))}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["renderer","radial"]),super._afterNew(),this.setPrivate("letter","Y"),this.setRaw("position","absolute")}_changed(){super._changed(),(this.isDirty("radius")||this.isDirty("innerRadius")||this.isDirty("startAngle")||this.isDirty("endAngle"))&&this.updateLayout()}processAxis(){super.processAxis()}updateLayout(){let e=this.chart;if(e){let t=e.getPrivate("radius",0),i=We(this.get("radius",se),t),s=We(this.get("innerRadius",e.getPrivate("innerRadius",0)),t)*e.getPrivate("irModifyer",1);s<0&&(s=i+s),this.setPrivate("radius",i),this.setPrivate("innerRadius",s);let r=this.get("startAngle",e.get("startAngle",-90)),n=this.get("endAngle",e.get("endAngle",270));this.setPrivate("startAngle",r),this.setPrivate("endAngle",n);let A=this.get("axisAngle",0);this.set("draw",o=>{o.moveTo(s*ft(A),s*At(A)),o.lineTo(i*ft(A),i*At(A))}),this.axis.markDirtySize()}}updateGrid(e,t,i){if(e){W(t)||(t=0);let s=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*s);let r=this.positionToCoordinate(t)+this.getPrivate("innerRadius",0);this.toggleVisibility(e,t,0,1),W(r)&&e.set("draw",n=>{let A=this.getPrivate("startAngle",0)*Kt,o=this.getPrivate("endAngle",0)*Kt;n.arc(0,0,Math.max(0,r),Math.min(A,o),Math.max(A,o))})}}_handleOpposite(){}positionToPoint(e){let t=this.getPrivate("innerRadius",0),i=this.positionToCoordinate(e)+t,s=this.get("axisAngle",0);return{x:i*ft(s),y:i*At(s)}}updateLabel(e,t,i,s){if(e){W(t)||(t=0);let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),W(i)&&i!=t&&(t=t+(i-t)*r);let n=this.positionToPoint(t),A=Math.hypot(n.x,n.y);e.setPrivate("radius",A),e.setPrivate("innerRadius",A),e.set("labelAngle",this.get("axisAngle")),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}fillDrawMethod(e,t,i){e.set("draw",s=>{t=Math.max(0,t),i=Math.max(0,i),this._fillGenerator.context(s);let r=(this.getPrivate("startAngle",0)+90)*Kt,n=(this.getPrivate("endAngle",0)+90)*Kt;n<r&&([r,n]=[n,r]),this._fillGenerator({innerRadius:t,outerRadius:i,startAngle:r,endAngle:n})})}updateTick(e,t,i,s){if(e){W(t)||(t=0);let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),W(i)&&i!=t&&(t=t+(i-t)*r);let n=this.positionToPoint(t);e.set("x",n.x),e.set("y",n.y);let A=e.get("length",0);e.get("inside")&&(A*=-1);let l=this.get("axisAngle",0)+90;e.set("draw",c=>{c.moveTo(0,0),c.lineTo(A*ft(l),A*At(l))}),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}updateBullet(e,t,i){if(e){let s=e.get("sprite");if(s){W(t)||(t=0);let r=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*r);let n=this.positionToPoint(t);s.setAll({x:n.x,y:n.y}),this.toggleVisibility(s,t,0,1)}}}updateFill(e,t,i){if(e){W(t)||(t=0),W(i)||(i=1);let s=this.getPrivate("innerRadius",0),r=this.positionToCoordinate(t)+s,n=this.positionToCoordinate(i)+s;this.fillDrawMethod(e,r,n)}}axisLength(){return this.getPrivate("radius",0)-this.getPrivate("innerRadius",0)}updateTooltipBounds(e){}positionToCoordinate(e){return this._inversed?(e=Math.min(this._end,e),(this._end-e)*this._axisLength):(e=Math.max(this._start,e),(e-this._start)*this._axisLength)}positionTooltip(e,t){let i=this.getPrivate("innerRadius",0)+this.positionToCoordinate(t),s=this.get("axisAngle",0);this._positionTooltip(e,{x:i*ft(s),y:i*At(s)})}};sn.className="AxisRendererRadial";sn.classNames=Gi.classNames.concat([sn.className]);var Kr=class extends pe{constructor(){super(...arguments),this.hand=this.children.push(Le.new(this._root,{themeTags:["hand"]})),this.pin=this.children.push(Le.new(this._root,{themeTags:["pin"]}))}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["clock"]),super._afterNew(),this.set("width",Re(1)),this.adapters.add("x",()=>0),this.adapters.add("y",()=>0),this.pin.set("draw",(e,t)=>{let i=t.parent;if(i){let s=i.dataItem;if(s){let r=s.component;if(r){let n=r.chart;if(n){let A=n.getPrivate("radius",0),o=We(i.get("pinRadius",0),A);o<0&&(o=A+o),e.moveTo(o,0),e.arc(0,0,o,0,360)}}}}}),this.hand.set("draw",(e,t)=>{let i=t.parent;if(i){let s=i.parent;s&&s.set("width",Re(1));let r=i.dataItem;if(r){let n=r.component;if(n){let A=n.chart;if(A){let o=i.get("bottomWidth",10)/2,l=i.get("topWidth",0)/2,c=A.getPrivate("radius",0),h=We(i.get("radius",0),c);h<0&&(h=c+h);let d=i.get("innerRadius",0);d instanceof ke?d=We(d,c):d<0&&d<0&&(d=h+d),e.moveTo(d,-o),e.lineTo(h,-l),e.lineTo(h,l),e.lineTo(d,o),e.lineTo(d,-o)}}}}})}_prepareChildren(){super._prepareChildren(),this.hand._markDirtyKey("fill"),this.pin._markDirtyKey("fill")}};Kr.className="ClockHand";Kr.classNames=pe.classNames.concat([Kr.className]);var yc=class extends _s{setupDefaultRules(){super.setupDefaultRules();let e=this.rule.bind(this),t=this._root.interfaceColors;e("RadarChart").setAll({radius:Re(80),innerRadius:0,startAngle:-90,endAngle:270}),e("RadarColumnSeries").setAll({clustered:!0}),e("Slice",["radar","column","series"]).setAll({width:Re(80),height:Re(80)}),e("RadarLineSeries").setAll({connectEnds:!0}),e("SmoothedRadarLineSeries").setAll({tension:.5}),e("AxisRendererRadial").setAll({minGridDistance:40,axisAngle:-90,inversed:!1,cellStartLocation:0,cellEndLocation:1}),e("AxisRendererCircular").setAll({minGridDistance:100,inversed:!1,cellStartLocation:0,cellEndLocation:1}),e("RadialLabel",["circular"]).setAll({textType:"circular",paddingTop:1,paddingRight:0,paddingBottom:1,paddingLeft:0,centerX:0,centerY:0,radius:8}),e("AxisLabelRadial",["category"]).setAll({text:"{category}",populateText:!0}),e("RadialLabel",["radial"]).setAll({textType:"regular",centerX:0,textAlign:"right"}),e("RadarChart",["gauge"]).setAll({startAngle:180,endAngle:360,innerRadius:Re(90)}),e("ClockHand").setAll({topWidth:1,bottomWidth:10,radius:Re(90),pinRadius:10});{let i=e("Graphics",["clock","hand"]);i.setAll({fillOpacity:1}),ve(i,"fill",t,"alternativeBackground")}{let i=e("Graphics",["clock","pin"]);i.setAll({fillOpacity:1}),ve(i,"fill",t,"alternativeBackground")}}};var vc=class extends _s{setupDefaultRules(){super.setupDefaultRules();let e=this._root.interfaceColors,t=this._root.language,i=this.rule.bind(this);i("XYChart").setAll({colors:Vr.new(this._root,{}),paddingLeft:20,paddingRight:20,paddingTop:16,paddingBottom:16,panX:!1,panY:!1,wheelStep:.25,arrangeTooltips:!0,pinchZoomX:!1,pinchZoomY:!1}),i("XYSeries").setAll({legendLabelText:"{name}"}),i("Rectangle",["plotbackground","xy","background"]).setAll({fill:we.fromHex(0),fillOpacity:0}),i("XYChart",["scrollbar","chart"]).setAll({paddingBottom:0,paddingLeft:0,paddingTop:0,paddingRight:0,colors:Vr.new(this._root,{saturation:0})});{let o=i("Graphics",["scrollbar","overlay"]);o.setAll({fillOpacity:.5}),ve(o,"fill",e,"background")}i("RoundedRectangle",["xy","scrollbar","thumb"]).setAll({cornerRadiusTR:0,cornerRadiusTL:0,cornerRadiusBR:0,cornerRadiusBL:0,fillOpacity:0,focusable:!0}),i("RoundedRectangle",["xy","scrollbar","thumb"]).states.create("hover",{fillOpacity:.4}),i("RoundedRectangle",["xy","scrollbar","chart","background"]).setAll({cornerRadiusTL:0,cornerRadiusBL:0,cornerRadiusTR:0,cornerRadiusBR:0}),i("RoundedRectangle",["xy","scrollbar","chart","background","resize","button"]).setAll({cornerRadiusBL:40,cornerRadiusBR:40,cornerRadiusTL:40,cornerRadiusTR:40}),i("AxisRendererX",["xy","chart","scrollbar"]).setAll({strokeOpacity:0,inside:!0}),i("AxisRendererY",["xy","chart","scrollbar"]).setAll({strokeOpacity:0,inside:!0,minGridDistance:5}),i("AxisLabel",["xy","scrollbar","x"]).setAll({opacity:.5,centerY:se,minPosition:.01,maxPosition:.99,fontSize:"0.8em"}),i("AxisLabel",["category"]).setAll({text:"{category}",populateText:!0}),i("AxisLabel",["x"]).setAll({centerY:0}),i("AxisLabel",["x","inside"]).setAll({centerY:se}),i("AxisLabel",["x","inside","opposite"]).setAll({centerY:0}),i("AxisLabel",["x","opposite"]).setAll({centerY:se}),i("AxisLabel",["y"]).setAll({centerX:se}),i("AxisLabel",["y","inside"]).setAll({centerX:0}),i("AxisLabel",["y","inside","opposite"]).setAll({centerX:se}),i("AxisLabel",["y","opposite"]).setAll({centerX:0}),i("AxisLabel",["minor"]).setAll({fontSize:"0.6em"}),i("AxisLabel",["xy","scrollbar","y"]).setAll({visible:!1}),i("Grid",["xy","scrollbar","y"]).setAll({visible:!1}),i("Grid",["xy","scrollbar","x"]).setAll({opacity:.5}),i("XYCursor").setAll({behavior:"none",layer:30,exportable:!1,snapToSeriesBy:"xy",moveThreshold:1});{let o=i("Grid",["cursor","x"]);o.setAll({forceInactive:!0,strokeOpacity:.8,strokeDasharray:[2,2],role:"slider",ariaLabel:t.translate("Use left and right arrows to move selection")}),ve(o,"stroke",e,"alternativeBackground")}{let o=i("Grid",["cursor","y"]);o.setAll({forceInactive:!0,strokeOpacity:.8,strokeDasharray:[2,2],role:"slider",ariaLabel:t.translate("Use up and down arrows to move selection")}),ve(o,"stroke",e,"alternativeBackground")}{let o=i("Graphics",["cursor","selection"]);o.setAll({fillOpacity:.15}),ve(o,"fill",e,"alternativeBackground")}i("Axis").setAll({zoomOut:!0,start:0,end:1,minZoomCount:1,maxZoomCount:1/0,maxZoomFactor:1e3,maxDeviation:.1,snapTooltip:!0,tooltipLocation:.5,panX:!0,panY:!0,zoomX:!0,zoomY:!0,fixAxisSize:!0}),i("AxisLabel").setAll({location:.5,multiLocation:0,centerX:ye,centerY:ye,paddingTop:3,paddingBottom:3,paddingLeft:5,paddingRight:5}),i("Container",["axis","header"]).setAll({layer:30}),i("Rectangle",["axis","header","background"]).setAll({crisp:!0});{let o=i("AxisRenderer");o.setAll({crisp:!0,strokeOpacity:0}),ve(o,"stroke",e,"grid")}i("AxisRendererX").setAll({minGridDistance:120,opposite:!1,inversed:!1,cellStartLocation:0,cellEndLocation:1,width:se}),i("AxisRendererY").setAll({minGridDistance:40,opposite:!1,inversed:!1,cellStartLocation:0,cellEndLocation:1,height:se});{let o=i("Rectangle",["axis","thumb","zoomgrip"]);o.setAll({fillOpacity:0}),ve(o,"fill",e,"alternativeBackground"),o.states.create("hover",{fillOpacity:.1})}i("Rectangle",["axis","thumb","x","zoomgrip"]).setAll({cursorOverStyle:"ew-resize"}),i("Rectangle",["axis","thumb","y","zoomgrip"]).setAll({cursorOverStyle:"ns-resize"});{let o=i("Grid");o.setAll({location:0,strokeOpacity:.15,crisp:!0}),ve(o,"stroke",e,"grid")}{let o=i("Grid",["minor"]);o.setAll({location:0,strokeOpacity:.07,crisp:!0}),ve(o,"stroke",e,"grid")}i("Grid",["base"]).setAll({strokeOpacity:.3});{let o=i("Graphics",["axis","fill"]);o.setAll({visible:!1,isMeasured:!1,position:"absolute",fillOpacity:.05}),ve(o,"fill",e,"alternativeBackground")}i("Graphics",["axis","fill","range"]).setAll({isMeasured:!0}),i("Graphics",["series","fill","range"]).setAll({visible:!1,isMeasured:!0}),i("Grid",["series","range"]).setAll({visible:!1}),i("AxisTick",["series","range"]).setAll({visible:!1}),i("AxisLabel",["series","range"]).setAll({visible:!1});{let o=i("AxisTick");o.setAll({location:.5,multiLocation:0,strokeOpacity:1,isMeasured:!1,position:"absolute",visible:!1}),ve(o,"stroke",e,"grid")}i("CategoryAxis").setAll({startLocation:0,endLocation:1,fillRule:(o,l)=>{let c=o.get("axisFill");c&&(!W(l)||l%2==0?c.setPrivate("visible",!0):c.setPrivate("visible",!1))}});let s=[{timeUnit:"millisecond",count:1},{timeUnit:"millisecond",count:5},{timeUnit:"millisecond",count:10},{timeUnit:"millisecond",count:50},{timeUnit:"millisecond",count:100},{timeUnit:"millisecond",count:500},{timeUnit:"second",count:1},{timeUnit:"second",count:5},{timeUnit:"second",count:10},{timeUnit:"second",count:30},{timeUnit:"minute",count:1},{timeUnit:"minute",count:5},{timeUnit:"minute",count:10},{timeUnit:"minute",count:15},{timeUnit:"minute",count:30},{timeUnit:"hour",count:1},{timeUnit:"hour",count:3},{timeUnit:"hour",count:6},{timeUnit:"hour",count:12},{timeUnit:"day",count:1},{timeUnit:"day",count:2},{timeUnit:"day",count:3},{timeUnit:"day",count:4},{timeUnit:"day",count:5},{timeUnit:"week",count:1},{timeUnit:"month",count:1},{timeUnit:"month",count:2},{timeUnit:"month",count:3},{timeUnit:"month",count:6},{timeUnit:"year",count:1},{timeUnit:"year",count:2},{timeUnit:"year",count:5},{timeUnit:"year",count:10},{timeUnit:"year",count:50},{timeUnit:"year",count:100},{timeUnit:"year",count:200},{timeUnit:"year",count:500},{timeUnit:"year",count:1e3},{timeUnit:"year",count:2e3},{timeUnit:"year",count:5e3},{timeUnit:"year",count:1e4},{timeUnit:"year",count:1e5}],r={millisecond:t.translate("_date_millisecond"),second:t.translate("_date_second"),minute:t.translate("_date_minute"),hour:t.translate("_date_hour"),day:t.translate("_date_day"),week:t.translate("_date_day"),month:t.translate("_date_month"),year:t.translate("_date_year")},n={millisecond:t.translate("_date_millisecond"),second:t.translate("_date_second"),minute:t.translate("_date_minute"),hour:t.translate("_date_day"),day:t.translate("_date_day"),week:t.translate("_date_day"),month:t.translate("_date_month")+" "+t.translate("_date_year"),year:t.translate("_date_year")},A={millisecond:t.translate("_date_millisecond_full"),second:t.translate("_date_second_full"),minute:t.translate("_date_minute_full"),hour:t.translate("_date_hour_full"),day:t.translate("_date_day_full"),week:t.translate("_date_week_full"),month:t.translate("_date_month_full"),year:t.translate("_date_year")};i("CategoryDateAxis").setAll({markUnitChange:!0,gridIntervals:Qo(s),dateFormats:Ws(r),periodChangeDateFormats:Ws(n)}),i("DateAxis").setAll({maxZoomFactor:null,strictMinMax:!0,startLocation:0,endLocation:1,markUnitChange:!0,groupData:!1,groupCount:500,skipFirstMinor:!0,weekLabelLocation:0,gridIntervals:Qo(s),dateFormats:Ws(r),periodChangeDateFormats:Ws(n),tooltipDateFormats:A,groupIntervals:[{timeUnit:"millisecond",count:1},{timeUnit:"millisecond",count:10},{timeUnit:"millisecond",count:100},{timeUnit:"second",count:1},{timeUnit:"second",count:10},{timeUnit:"minute",count:1},{timeUnit:"minute",count:10},{timeUnit:"hour",count:1},{timeUnit:"day",count:1},{timeUnit:"week",count:1},{timeUnit:"month",count:1},{timeUnit:"year",count:1}],fillRule:o=>{let l=o.get("axisFill");if(l){let c=o.component,h=o.get("value"),d=o.get("endValue"),u=c.intervalDuration(),g=c.getPrivate("baseInterval"),y=c.getPrivate("gridInterval",g),m=c.getPrivate("min",0);if(m=ma(new Date(m),y.timeUnit,y.count,this._root.locale.firstDayOfWeek,this._root.utc,void 0,this._root.timezone).getTime(),h!=null&&d!=null){let b=Math.round(Math.round((h-m)/u))/2;b==Math.round(b)?l.setPrivate("visible",!0):l.setPrivate("visible",!1)}}}}),i("GaplessDateAxis").setAll({fillRule:o=>{let l=o.get("axisFill");if(l){let c=o.get("index"),h=!1;(!W(c)||c%2==0)&&(h=!0),l.setPrivate("visible",h)}}}),i("ValueAxis").setAll({baseValue:0,logarithmic:!1,strictMinMax:!1,autoZoom:!0,fillRule:o=>{let l=o.get("axisFill");if(l){let c=o.component,h=o.get("value"),d=c.getPrivate("step");W(h)&&W(d)&&(jt(h/d/2,5)==Math.round(h/d/2)?l.setPrivate("visible",!1):l.setPrivate("visible",!0))}}}),i("DurationAxis").setAll({baseUnit:"second"}),i("XYSeries").setAll({maskBullets:!0,stackToNegative:!0,locationX:.5,locationY:.5,snapTooltip:!1,openValueXGrouped:"open",openValueYGrouped:"open",valueXGrouped:"close",valueYGrouped:"close",seriesTooltipTarget:"series"}),i("BaseColumnSeries").setAll({adjustBulletPosition:!0}),i("ColumnSeries").setAll({clustered:!0}),i("RoundedRectangle",["series","column"]).setAll({position:"absolute",isMeasured:!1,width:Re(70),height:Re(70),strokeWidth:1,strokeOpacity:1,cornerRadiusBL:0,cornerRadiusTL:0,cornerRadiusBR:0,cornerRadiusTR:0,fillOpacity:1,role:"figure"}),i("LineSeries").setAll({connect:!0,autoGapCount:1.1,stackToNegative:!1}),i("Graphics",["series","stroke"]).setAll({position:"absolute",strokeWidth:1,strokeOpacity:1,isMeasured:!1}),i("Graphics",["series","fill"]).setAll({visible:!1,fillOpacity:0,position:"absolute",strokeWidth:0,strokeOpacity:0,isMeasured:!1}),i("Graphics",["line","series","legend","marker","stroke"]).setAll({draw:(o,l)=>{let c=l.parent;if(c){let h=c.height(),d=c.width();o.moveTo(0,h/2),o.lineTo(d,h/2)}}});{let o=i("Graphics",["line","series","legend","marker","stroke"]).states.create("disabled",{});ve(o,"stroke",e,"disabled")}i("Graphics",["line","series","legend","marker","fill"]).setAll({draw:(o,l)=>{let c=l.parent;if(c){let h=c.height(),d=c.width();o.moveTo(0,0),o.lineTo(d,0),o.lineTo(d,h),o.lineTo(0,h),o.lineTo(0,0)}}});{let o=i("Graphics",["line","series","legend","marker","fill"]).states.create("disabled",{});ve(o,"stroke",e,"disabled")}i("SmoothedXYLineSeries").setAll({tension:.5}),i("SmoothedXLineSeries").setAll({tension:.5}),i("SmoothedYLineSeries").setAll({tension:.5}),i("Candlestick").setAll({position:"absolute",isMeasured:!1,width:Re(50),height:Re(50),strokeWidth:1,strokeOpacity:1,cornerRadiusBL:0,cornerRadiusTL:0,cornerRadiusBR:0,cornerRadiusTR:0,fillOpacity:1,role:"figure"}),i("OHLC").setAll({width:Re(80),height:Re(80)}),i("CandlestickSeries").setAll({lowValueXGrouped:"low",lowValueYGrouped:"low",highValueXGrouped:"high",highValueYGrouped:"high",openValueXGrouped:"open",openValueYGrouped:"open",valueXGrouped:"close",valueYGrouped:"close"});{let o=i("Rectangle",["column","autocolor"]).states.create("riseFromOpen",{});ve(o,"fill",e,"positive"),ve(o,"stroke",e,"positive")}{let o=i("Rectangle",["column","autocolor"]).states.create("dropFromOpen",{});ve(o,"fill",e,"negative"),ve(o,"stroke",e,"negative")}i("Rectangle",["column","autocolor","pro"]).states.create("riseFromOpen",{fillOpacity:0}),i("Rectangle",["column","autocolor","pro"]).states.create("dropFromOpen",{fillOpacity:1});{let o=i("Rectangle",["column","autocolor","pro"]).states.create("riseFromPrevious",{});ve(o,"fill",e,"positive"),ve(o,"stroke",e,"positive")}{let o=i("Rectangle",["column","autocolor","pro"]).states.create("dropFromPrevious",{});ve(o,"fill",e,"negative"),ve(o,"stroke",e,"negative")}i("RoundedRectangle",["rangegrip"]).setAll({strokeOpacity:0,fillOpacity:0,strokeWidth:1,width:12,height:12});{let o=i("Graphics",["rangegrip","button","icon"]);o.setAll({interactive:!1,crisp:!0,strokeOpacity:.5,draw:l=>{l.moveTo(0,.5),l.lineTo(0,12.5),l.moveTo(2,.5),l.lineTo(2,12.5),l.moveTo(4,.5),l.lineTo(4,12.5)}}),ve(o,"stroke",e,"secondaryButtonText")}i("Button",["rangegrip"]).setAll({draggable:!0,paddingTop:0,paddingBottom:0}),i("Button",["rangegrip","vertical"]).setAll({rotation:90,cursorOverStyle:"ns-resize",centerX:ye}),i("Button",["rangegrip","horizontal"]).setAll({cursorOverStyle:"ew-resize",centerX:ye}),i("Button",["rangegrip","vertical","left"]).setAll({centerY:se}),i("Button",["rangegrip","vertical","right"]).setAll({centerY:0}),i("Button",["rangegrip","horizontal","top"]).setAll({centerY:0}),i("Button",["rangegrip","horizontal","bottom"]).setAll({centerY:se})}};var ct=class extends Fi{constructor(){super(...arguments),this.xAxes=new Ga,this.yAxes=new Ga,this.topAxesContainer=this.chartContainer.children.push(pe.new(this._root,{width:se,layout:this._root.verticalLayout})),this.yAxesAndPlotContainer=this.chartContainer.children.push(pe.new(this._root,{width:se,height:se,layout:this._root.horizontalLayout})),this.bottomAxesContainer=this.chartContainer.children.push(pe.new(this._root,{width:se,layout:this._root.verticalLayout})),this.leftAxesContainer=this.yAxesAndPlotContainer.children.push(pe.new(this._root,{height:se,layout:this._root.horizontalLayout})),this.plotsContainer=this.yAxesAndPlotContainer.children.push(pe.new(this._root,{width:se,height:se,maskContent:!1})),this.plotContainer=this.plotsContainer.children.push(pe.new(this._root,{width:se,height:se})),this.topPlotContainer=this.plotsContainer.children.push(pe.new(this._root,{width:se,height:se})),this.gridContainer=this.plotContainer.children.push(pe.new(this._root,{width:se,height:se,isMeasured:!1})),this.topGridContainer=pe.new(this._root,{width:se,height:se,isMeasured:!1}),this.rightAxesContainer=this.yAxesAndPlotContainer.children.push(pe.new(this._root,{height:se,layout:this._root.horizontalLayout})),this.axisHeadersContainer=this.plotContainer.children.push(pe.new(this._root,{})),this.zoomOutButton=this.topPlotContainer.children.push(pa.new(this._root,{themeTags:["zoom"],icon:Le.new(this._root,{themeTags:["button","icon"]})})),this._movePoint={x:0,y:0},this._movePoints={}}_afterNew(){this._defaultThemes.push(vc.new(this._root)),super._afterNew(),this._disposers.push(this.xAxes),this._disposers.push(this.yAxes);let e=this._root,t=this._root.verticalLayout,i=this.zoomOutButton;i.events.on("click",()=>{this.zoomOut()}),i.hide(0),i.states.lookup("default").set("opacity",1),this.chartContainer.set("layout",t);let s=this.plotContainer;s.children.push(this.seriesContainer),this._disposers.push(this._processAxis(this.xAxes,this.bottomAxesContainer)),this._disposers.push(this._processAxis(this.yAxes,this.leftAxesContainer)),s.children.push(this.topGridContainer),s.children.push(this.bulletsContainer),s.set("interactive",!0),s.set("interactiveChildren",!1),s.set("background",Tt.new(e,{themeTags:["plotbackground","xy","background"]})),this._disposers.push(s.events.on("pointerdown",r=>{this._handlePlotDown(r)})),this._disposers.push(s.events.on("globalpointerup",r=>{this._handlePlotUp(r)})),this._disposers.push(s.events.on("globalpointermove",r=>{this._handlePlotMove(r)})),this._maskGrid(),this._setUpTouch()}_beforeChanged(){super._beforeChanged(),(this.isDirty("pinchZoomX")||this.isDirty("pinchZoomY")||this.get("panX")||this.get("panY"))&&this._setUpTouch()}_setUpTouch(){this.plotContainer._display.cancelTouch||(this.plotContainer._display.cancelTouch=!!(this.get("pinchZoomX")||this.get("pinchZoomY")||this.get("panX")||this.get("panY")))}_maskGrid(){this.gridContainer.set("maskContent",!0),this.topGridContainer.set("maskContent",!0)}_removeSeries(e){e._unstack(),e._posXDp&&e._posXDp.dispose(),e._posYDp&&e._posYDp.dispose(),e.set("baseAxis",void 0);let t=e.get("xAxis");t&&(ri(t.series,e),t.markDirtyExtremes());let i=e.get("yAxis");i&&(ri(i.series,e),i.markDirtyExtremes());let s=this.get("cursor");if(s){let r=s.get("snapToSeries");r&&ri(r,e)}super._removeSeries(e)}_applyThemes(e=!1){let t=this.get("colors");return t&&t.reset(),super._applyThemes(e)}handleWheel(e){let t=this.get("wheelX"),i=this.get("wheelY"),s=this.plotContainer,r=e.originalEvent,n=!1;if(FA(r,this))n=!0;else return;let A=s.toLocal(e.point),o=this.get("wheelStep",.2),l=r.deltaY/100,c=r.deltaX/100,h=this.get("wheelZoomPositionX"),d=this.get("wheelZoomPositionY");(t==="zoomX"||t==="zoomXY")&&c!=0&&this.xAxes.each(u=>{if(u.get("zoomX")){let g=u.get("start"),y=u.get("end"),m=u.fixPosition(A.x/s.width());h!=null&&(m=h);let b=u.get("maxDeviation",0),B=Math.min(1+b,Math.max(-b,g-o*(y-g)*c*m)),w=Math.max(-b,Math.min(1+b,y+o*(y-g)*c*(1-m)));B==g&&w==y&&(n=!1),1/(w-B)<u.getPrivate("maxZoomFactor",1/0)/u.get("minZoomCount",1)?this._handleWheelAnimation(u.zoom(B,w)):n=!1}}),(i==="zoomX"||i==="zoomXY")&&l!=0&&this.xAxes.each(u=>{if(u.get("zoomX")){let g=u.get("start"),y=u.get("end"),m=u.fixPosition(A.x/s.width());h!=null&&(m=h);let b=u.get("maxDeviation",0),B=Math.min(1+b,Math.max(-b,g-o*(y-g)*l*m)),w=Math.max(-b,Math.min(1+b,y+o*(y-g)*l*(1-m)));B==g&&w==y&&(n=!1),1/(w-B)<u.getPrivate("maxZoomFactor",1/0)/u.get("minZoomCount",1)?this._handleWheelAnimation(u.zoom(B,w)):n=!1}}),(t==="zoomY"||t==="zoomXY")&&c!=0&&this.yAxes.each(u=>{if(u.get("zoomY")){let g=u.get("start"),y=u.get("end"),m=u.fixPosition(A.y/s.height());d!=null&&(m=d);let b=u.get("maxDeviation",0),B=Math.min(1+b,Math.max(-b,g-o*(y-g)*c*m)),w=Math.max(-b,Math.min(1+b,y+o*(y-g)*c*(1-m)));B==g&&w==y&&(n=!1),1/(w-B)<u.getPrivate("maxZoomFactor",1/0)/u.get("minZoomCount",1)?this._handleWheelAnimation(u.zoom(B,w)):n=!1}}),(i==="zoomY"||i==="zoomXY")&&l!=0&&this.yAxes.each(u=>{if(u.get("zoomY")){let g=u.get("start"),y=u.get("end"),m=u.fixPosition(A.y/s.height());d!=null&&(m=d);let b=u.get("maxDeviation",0),B=Math.min(1+b,Math.max(-b,g-o*(y-g)*l*m)),w=Math.max(-b,Math.min(1+b,y+o*(y-g)*l*(1-m)));B==g&&w==y&&(n=!1),1/(w-B)<u.getPrivate("maxZoomFactor",1/0)/u.get("minZoomCount",1)?this._handleWheelAnimation(u.zoom(B,w)):n=!1}}),(t==="panX"||t==="panXY")&&c!=0&&this.xAxes.each(u=>{if(u.get("panX")){let g=u.get("start"),y=u.get("end"),m=this._getWheelSign(u)*o*(y-g)*c,b=g+m,B=y+m,w=this._fixWheel(b,B);b=w[0],B=w[1],b==g&&B==y&&(n=!1),this._handleWheelAnimation(u.zoom(b,B))}}),(i==="panX"||i==="panXY")&&l!=0&&this.xAxes.each(u=>{if(u.get("panX")){let g=u.get("start"),y=u.get("end"),m=this._getWheelSign(u)*o*(y-g)*l,b=g+m,B=y+m,w=this._fixWheel(b,B);b=w[0],B=w[1],b==g&&B==y&&(n=!1),this._handleWheelAnimation(u.zoom(b,B))}}),(t==="panY"||t==="panXY")&&c!=0&&this.yAxes.each(u=>{if(u.get("panY")){let g=u.get("start"),y=u.get("end"),m=this._getWheelSign(u)*o*(y-g)*c,b=g+m,B=y+m,w=this._fixWheel(b,B);b=w[0],B=w[1],b==g&&B==y&&(n=!1),this._handleWheelAnimation(u.zoom(b,B))}}),(i==="panY"||i==="panXY")&&l!=0&&this.yAxes.each(u=>{if(u.get("panY")){let g=u.get("start"),y=u.get("end"),m=this._getWheelSign(u)*o*(y-g)*l,b=g-m,B=y-m,w=this._fixWheel(b,B);b=w[0],B=w[1],b==g&&B==y&&(n=!1),this._handleWheelAnimation(u.zoom(b,B))}}),n&&r.preventDefault()}_handleSetWheel(){let e=this.get("wheelX"),t=this.get("wheelY"),i=this.plotContainer;e!=="none"||t!=="none"?(this._wheelDp=i.events.on("wheel",s=>{let r=s.originalEvent;(e!=="none"&&Math.abs(r.deltaX)!=0||t!=="none"&&Math.abs(r.deltaY)!=0)&&this.handleWheel(s)}),this._disposers.push(this._wheelDp)):this._wheelDp&&this._wheelDp.dispose()}_getWheelSign(e){let t=1;return e.get("renderer").get("inversed")&&(t=-1),t}_fixWheel(e,t){let i=t-e;return e<0&&(e=0,t=e+i),t>1&&(t=1,e=t-i),[e,t]}_handlePlotDown(e){let t=e.originalEvent;if(t.button==2)return;let i=this.plotContainer,s=i.toLocal(e.point);if((this.get("pinchZoomX")||this.get("pinchZoomY"))&&t.pointerId&&Bi(i._downPoints).length>0){let n=this.xAxes.getIndex(0),A=this.yAxes.getIndex(0);n&&(this._downStartX=n.get("start",0),this._downEndX=n.get("end",1)),A&&(this._downStartY=A.get("start",0),this._downEndY=A.get("end",1))}if((this.get("panX")||this.get("panY"))&&s.x>=0&&s.y>=0&&s.x<=i.width()&&s.y<=this.height()){this._downPoint={x:t.clientX,y:t.clientY};let r=this.get("panX"),n=this.get("panY");r&&this.xAxes.each(o=>{o._panStart=o.get("start"),o._panEnd=o.get("end")}),n&&this.yAxes.each(o=>{o._panStart=o.get("start"),o._panEnd=o.get("end")});let A="panstarted";this.events.isEnabled(A)&&this.events.dispatch(A,{type:A,target:this,originalEvent:e.originalEvent})}}_handleWheelAnimation(e){e?e.events.on("stopped",()=>{this._dispatchWheelAnimation()}):this._dispatchWheelAnimation()}_dispatchWheelAnimation(){let e="wheelended";this.events.isEnabled(e)&&this.events.dispatch(e,{type:e,target:this})}_handlePlotUp(e){let t=this._downPoint;if(t&&(this.get("panX")||this.get("panY"))){if(e.originalEvent.clientX==t.x&&e.originalEvent.clientY==t.y){let s="pancancelled";this.events.isEnabled(s)&&this.events.dispatch(s,{type:s,target:this,originalEvent:e.originalEvent})}let i="panended";this.events.isEnabled(i)&&this.events.dispatch(i,{type:i,target:this,originalEvent:e.originalEvent})}this._downPoint=void 0,this.xAxes.each(i=>{i._isPanning=!1}),this.yAxes.each(i=>{i._isPanning=!1})}_handlePlotMove(e){let t=this.plotContainer;if(this.get("pinchZoomX")||this.get("pinchZoomY")){let r=e.originalEvent.pointerId;if(r&&(this._movePoints[r]=e.point,Bi(t._downPoints).length>1)){this._handlePinch();return}}let i=this._downPoint;if(i){i=t.toLocal(this._root.documentPointToRoot(i));let s=t.toLocal(e.point),r=this.get("panX"),n=this.get("panY");if(r){let A=this.get("scrollbarX");A&&A.events.disableType("rangechanged"),this.xAxes.each(o=>{if(o.get("panX")){o._isPanning=!0;let l=o._panStart,c=o._panEnd,d=(c-l)*(i.x-s.x)/t.width();o.get("renderer").get("inversed")&&(d*=-1);let u=l+d,g=c+d;g-u<1+o.get("maxDeviation",1)*2&&(o.set("start",u),o.set("end",g))}}),A&&A.events.enableType("rangechanged")}if(n){let A=this.get("scrollbarY");A&&A.events.disableType("rangechanged"),this.yAxes.each(o=>{if(o.get("panY")){o._isPanning=!0;let l=o._panStart,c=o._panEnd,d=(c-l)*(i.y-s.y)/t.height();o.get("renderer").get("inversed")&&(d*=-1);let u=l-d,g=c-d;g-u<1+o.get("maxDeviation",1)*2&&(o.set("start",u),o.set("end",g))}}),A&&A.events.enableType("rangechanged")}}}_handlePinch(){let e=this.plotContainer,t=0,i=[],s=[];if(Ve(e._downPoints,(r,n)=>{i[t]=n;let A=this._movePoints[r];A&&(s[t]=A),t++}),i.length>1&&s.length>1){let r=e.width(),n=e.height(),A=i[0],o=i[1],l=s[0],c=s[1];if(A&&o&&l&&c){if(l=e.toLocal(l),c=e.toLocal(c),A=e.toLocal(A),o=e.toLocal(o),this.get("pinchZoomX")){let h=this._downStartX,d=this._downEndX;if(h!=null&&d!=null){A.x>o.x&&([A,o]=[o,A],[l,c]=[c,l]);let u=h+A.x/r*(d-h),g=h+o.x/r*(d-h),y=h+l.x/r*(d-h),m=h+c.x/r*(d-h),b=Math.max(.001,g-u),B=Math.max(.001,m-y),w=b/B,_=h*w+u-y*w,T=d*w+g-m*w;this.xAxes.each(Q=>{let U=Q.fixPosition(_),E=Q.fixPosition(T);Q.zoom(U,E,0)})}}if(this.get("pinchZoomY")){let h=this._downStartY,d=this._downEndY;if(h!=null&&d!=null){A.y<o.y&&([A,o]=[o,A],[l,c]=[c,l]);let u=h+(1-A.y/n)*(d-h),g=h+(1-o.y/n)*(d-h),y=h+(1-l.y/n)*(d-h),m=h+(1-c.y/n)*(d-h),b=Math.max(.001,g-u),B=Math.max(.001,m-y),w=b/B,_=h*w+u-y*w,T=d*w+g-m*w;this.yAxes.each(Q=>{let U=Q.fixPosition(_),E=Q.fixPosition(T);Q.zoom(U,E,0)})}}}}}_handleCursorPosition(){let e=this.get("cursor");if(e){let t=e.getPrivate("point"),i=e.get("snapToSeries");if(e._downPoint&&(i=void 0),i&&t){let s=e.get("snapToSeriesBy"),r=[];K(i,o=>{if(!o.isHidden()&&!o.isHiding())if(s!="x!"&&s!="y!"){let l=o.startIndex(),c=o.endIndex();for(let h=l;h<c;h++){let d=o.dataItems[h];d&&!d.isHidden()&&r.push(d)}}else{let l=o.get("tooltipDataItem");l&&r.push(l)}});let n=1/0,A;if(K(r,o=>{let l=o.get("point");if(l){let c=0;s=="x"||s=="x!"?c=Math.abs(t.x-l.x):s=="y"||s=="y!"?c=Math.abs(t.y-l.y):c=Math.hypot(t.x-l.x,t.y-l.y),c<n&&(n=c,A=o)}}),K(i,o=>{let l=o.get("tooltip");l&&l._setDataItem(void 0)}),A){let o=A.component;o.showDataItemTooltip(A),o.setRaw("tooltipDataItem",A);let l=A.get("point");l&&e.handleMove(o.toGlobal({x:l.x-o.x(),y:l.y-o.y()}),!0)}}}}_updateCursor(){let e=this.get("cursor");e&&e.updateCursor()}_addCursor(e){this.plotContainer.children.push(e)}_prepareChildren(){if(super._prepareChildren(),this.series.each(e=>{this._colorize(e)}),(this.isDirty("wheelX")||this.isDirty("wheelY"))&&this._handleSetWheel(),this.isDirty("cursor")){let e=this._prevSettings.cursor,t=this.get("cursor");t!==e&&(this._disposeProperty("cursor"),e&&e.dispose(),t&&(t._setChart(this),this._addCursor(t),this._pushPropertyDisposer("cursor",t.events.on("selectended",()=>{this._handleCursorSelectEnd()}))),this._prevSettings.cursor=t)}if(this.isDirty("scrollbarX")){let e=this._prevSettings.scrollbarX,t=this.get("scrollbarX");t!==e&&(this._disposeProperty("scrollbarX"),e&&e.dispose(),t&&(t.parent||this.topAxesContainer.children.push(t),this._pushPropertyDisposer("scrollbarX",t.events.on("rangechanged",i=>{this._handleScrollbar(this.xAxes,i.start,i.end,i.grip)})),this._pushPropertyDisposer("scrollbarX",t.events.on("released",()=>{this.xAxes.each(i=>{i.get("zoomable")&&this._handleAxisSelection(i)})})),t.setPrivate("positionTextFunction",i=>{let s=this.xAxes.getIndex(0);return s&&s.getTooltipText(i,!1)||""})),this._prevSettings.scrollbarX=t)}if(this.isDirty("scrollbarY")){let e=this._prevSettings.scrollbarY,t=this.get("scrollbarY");t!==e&&(this._disposeProperty("scrollbarY"),e&&e.dispose(),t&&(t.parent||this.rightAxesContainer.children.push(t),this._pushPropertyDisposer("scrollbarY",t.events.on("rangechanged",i=>{this._handleScrollbar(this.yAxes,i.start,i.end,i.grip)})),this._pushPropertyDisposer("scrollbarY",t.events.on("released",()=>{this.yAxes.each(i=>{i.get("zoomable")&&this._handleAxisSelection(i)})})),t.setPrivate("positionTextFunction",i=>{let s=this.yAxes.getIndex(0);return s&&s.getTooltipText(i,!1)||""})),this._prevSettings.scrollbarY=t)}this._handleZoomOut()}_processSeries(e){super._processSeries(e);let t=e.get("xAxis"),i=e.get("yAxis");Uo(t.series,e),Uo(i.series,e),e._posXDp=e.addDisposer(t.events.on("positionchanged",()=>{e._fixPosition()})),e._posXDp=e.addDisposer(i.events.on("positionchanged",()=>{e._fixPosition()})),e.get("baseAxis")||(i.isType("CategoryAxis")||i.isType("DateAxis")?e.set("baseAxis",i):e.set("baseAxis",t)),e.get("stacked")&&(e._markDirtyKey("stacked"),K(e.dataItems,s=>{s.set("stackToItemY",void 0),s.set("stackToItemX",void 0)})),e._markDirtyAxes(),i.markDirtyExtremes(),t.markDirtyExtremes(),t._seriesAdded=!0,i._seriesAdded=!0,this._colorize(e)}_colorize(e){let t=this.get("colors");if(t&&e.get("fill")==null){let s=t.next();e._setSoft("stroke",s),e._setSoft("fill",s)}let i=this.get("patterns");if(i&&e.get("fillPattern")==null){let s=i.next();e._setSoft("fillPattern",s)}}_handleCursorSelectEnd(){let e=this.get("cursor"),t=e.get("behavior"),i=e.getPrivate("downPositionX",0),s=e.getPrivate("downPositionY",0),r=Math.min(1,Math.max(0,e.getPrivate("positionX",.5))),n=Math.min(1,Math.max(0,e.getPrivate("positionY",.5)));this.xAxes.each(A=>{if(t==="zoomX"||t==="zoomXY"){let o=A.toAxisPosition(i),l=A.toAxisPosition(r);A.zoom(o,l)}A.setPrivate("updateScrollbar",!0)}),this.yAxes.each(A=>{if(t==="zoomY"||t==="zoomXY"){let o=A.toAxisPosition(s),l=A.toAxisPosition(n);A.zoom(o,l)}A.setPrivate("updateScrollbar",!0)})}_handleScrollbar(e,t,i,s){e.each(r=>{let n=r.fixPosition(t),A=r.fixPosition(i),o=r.zoom(n,A,void 0,s),l="updateScrollbar";r.setPrivateRaw(l,!1),o?o.events.on("stopped",()=>{r.setPrivateRaw(l,!0)}):r.setPrivateRaw(l,!0)})}_processAxis(e,t){return e.events.onAll(i=>{if(i.type==="clear")K(i.oldValues,s=>{this._removeAxis(s)});else if(i.type==="push")t.children.push(i.newValue),i.newValue.processChart(this);else if(i.type==="setIndex")t.children.setIndex(i.index,i.newValue),i.newValue.processChart(this);else if(i.type==="insertIndex")t.children.insertIndex(i.index,i.newValue),i.newValue.processChart(this);else if(i.type==="removeIndex")this._removeAxis(i.oldValue);else if(i.type==="moveIndex")t.children.moveValue(i.value,i.newIndex),i.value.processChart(this);else throw new Error("Unknown IListEvent type")})}_removeAxis(e){if(!e.isDisposed()){let t=e.parent;t&&t.children.removeValue(e);let i=e.gridContainer,s=i.parent;s&&s.children.removeValue(i);let r=e.topGridContainer,n=r.parent;n&&n.children.removeValue(r)}}_updateChartLayout(){let e=this.leftAxesContainer.width(),t=this.rightAxesContainer.width(),i=this.bottomAxesContainer;i.set("paddingLeft",e),i.set("paddingRight",t);let s=this.topAxesContainer;s.set("paddingLeft",e),s.set("paddingRight",t)}processAxis(e){var t=this.get("cursor");t&&(this.addDisposer(e.on("start",()=>{this._updateCursor()})),this.addDisposer(e.on("end",()=>{this._updateCursor()})))}_handleAxisSelection(e,t){let i=e.fixPosition(e.get("start",0)),s=e.fixPosition(e.get("end",1));if(i>s&&([i,s]=[s,i]),this.xAxes.indexOf(e)!=-1){if(t||e.getPrivate("updateScrollbar")){let r=this.get("scrollbarX");r&&(!r.getPrivate("isBusy")||t)&&(r.setRaw("start",i),r.setRaw("end",s),r.updateGrips())}}else if(this.yAxes.indexOf(e)!=-1&&(t||e.getPrivate("updateScrollbar"))){let r=this.get("scrollbarY");r&&(!r.getPrivate("isBusy")||t)&&(r.setRaw("start",i),r.setRaw("end",s),r.updateGrips())}this._handleZoomOut()}_handleZoomOut(){let e=this.zoomOutButton;if(e&&e.parent){let t=!1;this.xAxes.each(i=>{i.get("zoomOut",!0)&&(jt(i.get("start",0),5)!=0||jt(i.get("end",1),5)!=1)&&(t=!0)}),this.yAxes.each(i=>{i.get("zoomOut",!0)&&(jt(i.get("start",0),5)!=0||jt(i.get("end",1),5)!=1)&&(t=!0)}),t?e.isHidden()&&e.show():e.hide()}}inPlot(e){let t=this.plotContainer,i=this.getPrivate("otherCharts",this._otherCharts),s=t.toGlobal(e);if(e.x>=-.5&&e.y>=-.5&&e.x<=t.width()+.5&&e.y<=t.height()+.5)return!0;if(i)for(let r=i.length-1;r>=0;r--){let n=i[r];if(n!=this){let A=n.plotContainer,o=this._root.rootPointToDocument(s),l=n._root.documentPointToRoot(o),c=A.toLocal(l);if(c.x>=-.1&&c.y>=-.1&&c.x<=A.width()+.1&&c.y<=A.height()+.1)return!0}}return!1}arrangeTooltips(){let e=this.plotContainer,t=e.width(),i=e.height(),s=this.height(),r=this._root.tooltipContainer.get("layerMargin");r&&r.bottom>s&&(s=r.bottom);let n=e._display.toGlobal({x:0,y:0}),A=e._display.toGlobal({x:t,y:i}),o=[],l=0,c=1/0,h=this._movePoint,d=this.get("maxTooltipDistance"),u=this.get("maxTooltipDistanceBy","xy"),g,y;W(d)&&this.series.each(b=>{if(!b.isHidden()){let B=b.get("tooltip");if(B){let w=B.get("pointTo");if(w){let _=Math.hypot(h.x-w.x,h.y-w.y);u=="x"?_=Math.abs(h.x-w.x):u=="y"&&(_=Math.abs(h.y-w.y)),_<c&&(c=_,g=b,y=w)}}}});let m=[];if(this.series.each(b=>{let B=b.get("tooltip");if(B&&!B.get("forceHidden")){let w=!1,_=B.get("pointTo");if(_){if(d>=0){let T=B.get("pointTo");if(T&&y&&b!=g){let Q=Math.hypot(y.x-T.x,y.y-T.y);u=="x"?Q=Math.abs(y.x-T.x):u=="y"&&(Q=Math.abs(y.y-T.y)),Q>d&&(w=!0)}}else d==-1&&b!=g&&(w=!0);!this.inPlot(this._tooltipToLocal(_))||!B.dataItem?w=!0:w||(l+=_.y),w||b.isHidden()||b.isHiding()?B.hide(0):(B.show(),o.push(B),m.push(b))}}}),this.setPrivate("tooltipSeries",m),this.get("arrangeTooltips")){let b=0,B=0,w=this._root.tooltipContainer,_=o.length;if(l/_>i/2+n.y){o.sort((U,E)=>Df(E.get("pointTo").y,U.get("pointTo").y));let Q=A.y;if(K(o,U=>{let E=U.height();B++,b+=E;let O=U.get("centerY");O instanceof ke&&(E*=O.value),E+=U.get("marginBottom",0),U.set("bounds",{left:n.x,top:n.y,right:A.x,bottom:Q}),U.setPrivate("customData",{left:n.x,top:n.y,right:A.x,bottom:Q}),Q=Math.min(Q-E,U._fy-E),U.parent==w&&w.children.moveValue(U,0)}),Q<0){o.reverse();let U=Q;K(o,E=>{B++;let O=E.get("bounds");if(O){let D=O.top-Q,k=O.bottom-Q;D<U&&(D=U,k=D+E.height()),E.set("bounds",{left:O.left,top:D,right:O.right,bottom:k}),U=O.bottom-Q+E.get("marginBottom",0)}})}}else{o.reverse(),o.sort((U,E)=>Df(U.get("pointTo").y,E.get("pointTo").y));let Q=0;if(K(o,U=>{B++;let E=U.height();b+=E;let O=U.get("centerY");O instanceof ke&&(E*=O.value),E+=U.get("marginBottom",0),U.set("bounds",{left:n.x,top:Q,right:A.x,bottom:Math.max(n.y+s,Q+E)}),U.parent==w&&w.children.moveValue(U,0),Q=Math.max(Q+E,U._fy+E)}),Q>s){o.reverse();let U=s;K(o,E=>{B++;let O=E.get("bounds");if(O){let D=O.top-(s-Q),k=O.bottom-(s-Q);k>U&&(k=U,D=k-E.height()),E.set("bounds",{left:O.left,top:D,right:O.right,bottom:k}),U=k-E.height()-E.get("marginBottom",0)}})}}b==0&&B>0&&this._disposers.push(this.root.events.once("frameended",()=>{this.arrangeTooltips()}))}}_tooltipToLocal(e){return this.plotContainer.toLocal(e)}zoomOut(){this.xAxes.each(e=>{e.get("zoomOut",!0)&&(e.setPrivate("updateScrollbar",!0),e.zoom(0,1))}),this.yAxes.each(e=>{e.get("zoomOut",!0)&&(e.setPrivate("updateScrollbar",!0),e.zoom(0,1))})}_dispose(){super._dispose();let e=this.get("cursor");e&&e.dispose()}};ct.className="XYChart";ct.classNames=Fi.classNames.concat([ct.className]);var cs=class extends ct{constructor(){super(...arguments),this.radarContainer=this.plotContainer.children.push(pe.new(this._root,{x:ye,y:ye})),this._arcGenerator=gr(),this._maxRadius=1}_afterNew(){this._defaultThemes.push(yc.new(this._root)),super._afterNew();let e=this.radarContainer,t=this.gridContainer,i=this.topGridContainer,s=this.seriesContainer,r=this.bulletsContainer;e.children.pushAll([t,s,i,r]),s.set("mask",Le.new(this._root,{})),t.set("mask",Le.new(this._root,{})),this._disposers.push(this.plotContainer.events.on("boundschanged",()=>{this._updateRadius()}))}_maskGrid(){}_prepareChildren(){if(super._prepareChildren(),this._sizeDirty||this.isDirty("radius")||this.isDirty("innerRadius")||this.isDirty("startAngle")||this.isDirty("endAngle")){let e=this.chartContainer,t=e.innerWidth(),i=e.innerHeight(),s=this.get("startAngle",0),r=this.get("endAngle",0),n=this.get("innerRadius"),A=Xa(0,0,s,r,1),o=t/(A.right-A.left),l=i/(A.bottom-A.top),c={left:0,right:0,top:0,bottom:0};if(n instanceof ke){let d=n.value,u=Math.min(o,l);d=Math.max(u*d,u-Math.min(i,t))/u,c=Xa(0,0,s,r,d),this.setPrivateRaw("irModifyer",d/n.value)}A=Xh([A,c]),this._maxRadius=Math.max(0,Math.min(o,l));let h=We(this.get("radius",0),this._maxRadius);this.radarContainer.setAll({dy:-h*(A.bottom+A.top)/2,dx:-h*(A.right+A.left)/2}),this._updateRadius()}}_addCursor(e){this.radarContainer.children.push(e)}_updateRadius(){let e=We(this.get("radius",Re(80)),this._maxRadius);this.setPrivateRaw("radius",e);let t=We(this.get("innerRadius",0),e);t<0&&(t=e+t),this.setPrivateRaw("innerRadius",t),this.xAxes.each(s=>{s.get("renderer").updateLayout()}),this.yAxes.each(s=>{s.get("renderer").updateLayout()}),this._updateMask(this.seriesContainer,t,e),this._updateMask(this.gridContainer,t,e),this.series.each(s=>{s.get("maskBullets")?this._updateMask(s.bulletsContainer,t,e):s.bulletsContainer.remove("mask")});let i=this.get("cursor");i&&i.updateLayout()}_updateMask(e,t,i){let s=e.get("mask");s&&s.set("draw",r=>{this._arcGenerator.context(r),this._arcGenerator({innerRadius:t,outerRadius:i+.5,startAngle:(this.get("startAngle",0)+90)*Kt,endAngle:(this.get("endAngle",0)+90)*Kt})})}processAxis(e){this.radarContainer.children.push(e)}_processSeries(e){super._processSeries(e),this._updateRadius()}inPlot(e,t,i){let s=Math.hypot(e.x,e.y),r=es(Math.atan2(e.y,e.x)*bs),n=es(this.get("startAngle",0)),A=es(this.get("endAngle",0)),o=!1;return n<A&&n<r&&r<A&&(o=!0),n>A&&(r>n&&(o=!0),r<A&&(o=!0)),n==A&&(o=!0),o?(t==null&&(t=this.getPrivate("radius",0)),i==null&&(i=this.getPrivate("innerRadius",0)),i>t&&([i,t]=[t,i]),s<=t+.5&&s>=i-.5):!1}_tooltipToLocal(e){return this.radarContainer._display.toLocal(e)}_handlePinch(){}};cs.className="RadarChart";cs.classNames=ct.classNames.concat([cs.className]);function Cg(a,e){return a==null?e:e==null?a:e<a?e:a}function _g(a,e){return a==null?e:e==null||a>e?a:e}var ss=class extends ti{constructor(){super(...arguments),this._axesDirty=!1,this._stackDirty=!1,this._selectionProcessed=!1,this._dataSets={},this._x=0,this._y=0,this._bullets={},this.mainContainer=this.children.push(pe.new(this._root,{})),this.axisRanges=new Us,this._skipped=!1,this._couldStackTo=[],this._reallyStackedTo={},this._stackedSeries={},this._aLocationX0=0,this._aLocationX1=1,this._aLocationY0=0,this._aLocationY1=1,this._showBullets=!0,this.valueXFields=["valueX","openValueX","lowValueX","highValueX"],this.valueYFields=["valueY","openValueY","lowValueY","highValueY"],this._emptyDataItem=new ui(this,void 0,{})}_afterNew(){this.fields.push("categoryX","categoryY","openCategoryX","openCategoryY"),this.valueFields.push("valueX","valueY","openValueX","openValueY","lowValueX","lowValueY","highValueX","highValueY"),this._setRawDefault("vcx",1),this._setRawDefault("vcy",1),this._setRawDefault("valueXShow","valueXWorking"),this._setRawDefault("valueYShow","valueYWorking"),this._setRawDefault("openValueXShow","openValueXWorking"),this._setRawDefault("openValueYShow","openValueYWorking"),this._setRawDefault("lowValueXShow","lowValueXWorking"),this._setRawDefault("lowValueYShow","lowValueYWorking"),this._setRawDefault("highValueXShow","highValueXWorking"),this._setRawDefault("highValueYShow","highValueYWorking"),this._setRawDefault("lowValueXGrouped","low"),this._setRawDefault("lowValueYGrouped","low"),this._setRawDefault("highValueXGrouped","high"),this._setRawDefault("highValueYGrouped","high");let e=this.get("xAxis");e&&(this._xRenderer=e.get("renderer"));let t=this.get("yAxis");t&&(this._yRenderer=t.get("renderer")),super._afterNew(),this.set("maskContent",!0),this._disposers.push(this.axisRanges.events.onAll(i=>{if(i.type==="clear")K(i.oldValues,s=>{this._removeAxisRange(s)});else if(i.type==="push")this._processAxisRange(i.newValue);else if(i.type==="setIndex")this._processAxisRange(i.newValue);else if(i.type==="insertIndex")this._processAxisRange(i.newValue);else if(i.type==="removeIndex")this._removeAxisRange(i.oldValue);else if(i.type==="moveIndex")this._processAxisRange(i.value);else throw new Error("Unknown IStreamEvent type")})),this.states.create("hidden",{opacity:1,visible:!1}),this.onPrivate("startIndex",()=>{this.root.events.once("frameended",()=>{this.updateLegendValue()})}),this.onPrivate("endIndex",()=>{this.root.events.once("frameended",()=>{this.updateLegendValue()})}),this._makeFieldNames()}_processAxisRange(e){let t=pe.new(this._root,{});e.container=t,this.children.push(t),e.series=this;let i=e.axisDataItem;i.setRaw("isRange",!0);let s=i.component;if(s){s._processAxisRange(i,["range","series"]);let r=i.get("bullet");if(r){let A=r.get("sprite");A&&A.setPrivate("visible",!1)}let n=i.get("axisFill");n&&t.set("mask",n),s._seriesAxisRanges.push(i)}}_onDataClear(){super._onDataClear(),Ve(this._dataSets,(e,t)=>{K(t,i=>{i.dispose()}),t.length=0})}_removeAxisRange(e){let t=e.axisDataItem,i=t.component;t.dispose(),ri(i._seriesAxisRanges,t);let s=e.container;s&&s.dispose()}_updateFields(){super._updateFields(),this._valueXFields=[],this._valueYFields=[],this._valueXShowFields=[],this._valueYShowFields=[],this.__valueXShowFields=[],this.__valueYShowFields=[],this.valueXFields&&K(this.valueXFields,e=>{if(this.get(e+"Field")){this._valueXFields.push(e);let i=this.get(e+"Show");this.__valueXShowFields.push(i),i.indexOf("Working")!=-1?this._valueXShowFields.push(i.split("Working")[0]):this._valueXShowFields.push(i)}}),this.valueYFields&&K(this.valueYFields,e=>{if(this.get(e+"Field")){this._valueYFields.push(e);let i=this.get(e+"Show");this.__valueYShowFields.push(i),i.indexOf("Working")!=-1?this._valueYShowFields.push(i.split("Working")[0]):this._valueYShowFields.push(i)}})}_dispose(){super._dispose(),this._bullets={};let e=this.chart;e&&e.series.removeValue(this),Jt(this.get("xAxis").series,this),Jt(this.get("yAxis").series,this)}_min(e,t){let i=Cg(this.getPrivate(e),t);this.setPrivate(e,i)}_max(e,t){let i=_g(this.getPrivate(e),t);this.setPrivate(e,i)}_shouldMakeBullet(e){let t=this.get("xAxis"),i=this.get("yAxis"),s=this.get("baseAxis");if(!t.inited||!i.inited)return!1;let r=this.get("minBulletDistance",0);if(r>0){let n=this.startIndex(),o=this.endIndex()-n;if(t==s){if(this._xRenderer.axisLength()/o<r/5)return!1}else if(i==s&&this._yRenderer.axisLength()/o<r/5)return!1}return e.get(this._xField)!=null&&e.get(this._yField)!=null}_makeFieldNames(){let e=this.get("xAxis"),t=this.get("yAxis"),i=e.getPrivate("name"),s=mf(i),r=t.getPrivate("name"),n=mf(r),A=e.get("renderer").getPrivate("letter"),o=t.get("renderer").getPrivate("letter"),l="open",c="low",h="high",d="Show";e.className==="ValueAxis"?(this._xField=this.get(i+A+d),this._xOpenField=this.get(l+s+A+d),this._xLowField=this.get(c+s+A+d),this._xHighField=this.get(h+s+A+d)):(this._xField=i+A,this._xOpenField=l+s+A,this._xLowField=c+s+A,this._xHighField=h+s+A),t.className==="ValueAxis"?(this._yField=this.get(r+o+d),this._yOpenField=this.get(l+n+o+d),this._yLowField=this.get(c+n+o+d),this._yHighField=this.get(h+n+o+d)):(this._yField=r+o,this._yOpenField=l+n+o,this._yLowField=c+n+o,this._yHighField=h+n+o)}_fixVC(){let e=this.get("xAxis"),t=this.get("yAxis"),i=this.get("baseAxis"),s=this.states.lookup("hidden"),r=this.get("sequencedInterpolation");if(s){let n=0;r&&(n=.999999999999),e===i?s.set("vcy",n):(t===i||s.set("vcy",n),s.set("vcx",n))}}_handleMaskBullets(){this.isDirty("maskBullets")&&this.bulletsContainer.set("maskContent",this.get("maskBullets"))}_fixPosition(){let e=this.get("xAxis"),t=this.get("yAxis");this.set("x",e.x()-We(e.get("centerX",0),e.width())-e.parent.get("paddingLeft",0)),this.set("y",t.y()-We(t.get("centerY",0),t.height())-t.parent.get("paddingTop",0)),this.bulletsContainer.set("y",this.y()),this.bulletsContainer.set("x",this.x())}_prepareChildren(){super._prepareChildren(),this._xRenderer=this.get("xAxis").get("renderer"),this._yRenderer=this.get("yAxis").get("renderer"),this._bullets={},(this.isDirty("valueYShow")||this.isDirty("valueXShow")||this.isDirty("openValueYShow")||this.isDirty("openValueXShow")||this.isDirty("lowValueYShow")||this.isDirty("lowValueXShow")||this.isDirty("highValueYShow")||this.isDirty("highValueXShow"))&&(this._updateFields(),this._makeFieldNames(),this._valuesDirty=!0),(this.isDirty("xAxis")||this.isDirty("yAxis"))&&(this._valuesDirty=!0),this.set("width",this.get("xAxis").width()),this.set("height",this.get("yAxis").height()),this._handleMaskBullets();let e=this.get("xAxis"),t=this.get("yAxis"),i=this.get("baseAxis"),s=this.get("tooltipPositionX"),r;switch(s){case"open":r=this._xOpenField;break;case"low":r=this._xLowField;break;case"high":r=this._xHighField;break;default:r=this._xField}this._tooltipFieldX=r;let n=this.get("tooltipPositionY"),A;switch(n){case"open":A=this._yOpenField;break;case"low":A=this._yLowField;break;case"high":A=this._yHighField;break;default:A=this._yField}this._tooltipFieldY=A,this.isDirty("baseAxis")&&this._fixVC(),this._fixPosition();let o=this.get("stacked");if(this.isDirty("stacked")&&(o?this._valuesDirty&&!this._dataProcessed||this._stack():this._unstack()),this._valuesDirty&&!this._dataProcessed){this._dataProcessed=!0,o&&this._stack();let l,c,h,d;K(this.dataItems,u=>{K(this._valueXShowFields,g=>{let y=u.get(g);y!=null&&(o&&(y+=this.getStackedXValue(u,g)),l=Cg(l,y),c=_g(c,y))}),K(this._valueYShowFields,g=>{let y=u.get(g);y!=null&&(o&&(y+=this.getStackedYValue(u,g)),h=Cg(h,y),d=_g(d,y))}),e.processSeriesDataItem(u,this._valueXFields),t.processSeriesDataItem(u,this._valueYFields)}),this._min("minX",l),this._max("maxX",c),this._min("minY",h),this._max("maxY",d),e._seriesValuesDirty=!0,t._seriesValuesDirty=!0,this.get("ignoreMinMax")||((this.isPrivateDirty("minX")||this.isPrivateDirty("maxX"))&&e.markDirtyExtremes(),(this.isPrivateDirty("minY")||this.isPrivateDirty("maxY"))&&t.markDirtyExtremes()),this._markStakedDirtyStack(),this.get("tooltipDataItem")||this.updateLegendValue(void 0)}if((this.isDirty("vcx")||this.isDirty("vcy"))&&this._markStakedDirtyStack(),this._dataGrouped||(e._groupSeriesData(this),t._groupSeriesData(this),this._dataGrouped=!0),this._valuesDirty||this.isPrivateDirty("startIndex")||this.isPrivateDirty("adjustedStartIndex")||this.isPrivateDirty("endIndex")||this.isDirty("vcx")||this.isDirty("vcy")||this._stackDirty||this._sizeDirty||this.isDirty("minBulletDistance")){let l=this.startIndex(),c=this.endIndex(),h=this.get("minBulletDistance",0);if(h>0&&i&&(i.get("renderer").axisLength()/(c-l)>h?this._showBullets=!0:this._showBullets=!1),(this._psi!=l||this._pei!=c||this.isDirty("vcx")||this.isDirty("vcy")||this.isPrivateDirty("adjustedStartIndex")||this._stackDirty||this._valuesDirty)&&!this._selectionProcessed){this._selectionProcessed=!0;let d=this.get("vcx",1),u=this.get("vcy",1),g=this.get("stacked",!1),y=this.getPrivate("outOfSelection");if(i===e||!i)if(t._calculateTotals(),this.setPrivateRaw("selectionMinY",void 0),this.setPrivateRaw("selectionMaxY",void 0),y)t.markDirtySelectionExtremes();else for(let m=l;m<c;m++)this.processYSelectionDataItem(this.dataItems[m],u,g);if(i===t||!i)if(e._calculateTotals(),this.setPrivateRaw("selectionMinX",void 0),this.setPrivateRaw("selectionMaxX",void 0),y)t.markDirtySelectionExtremes();else for(let m=l;m<c;m++)this.processXSelectionDataItem(this.dataItems[m],d,g);if((i===e||!i)&&(this.get("valueYShow")!=="valueYWorking"||this.get("useSelectionExtremes"))){let m=this.getPrivate("selectionMinY");m!=null&&(this.setPrivateRaw("minY",m),t.markDirtyExtremes());let b=this.getPrivate("selectionMaxY");b!=null&&(this.setPrivateRaw("maxY",b),t.markDirtyExtremes())}if((i===t||!i)&&(this.get("valueXShow")!=="valueXWorking"||this.get("useSelectionExtremes"))){let m=this.getPrivate("selectionMinX");m!=null&&(this.setPrivateRaw("minX",m),t.markDirtyExtremes());let b=this.getPrivate("selectionMaxX");b!=null&&(this.setPrivateRaw("maxX",b),e.markDirtyExtremes())}(this.isPrivateDirty("selectionMinX")||this.isPrivateDirty("selectionMaxX"))&&e.markDirtySelectionExtremes(),(this.isPrivateDirty("selectionMinY")||this.isPrivateDirty("selectionMaxY"))&&t.markDirtySelectionExtremes()}}}_postUpdateData(){let e=this.get("xAxis"),t=this.get("yAxis");e._seriesValuesDirty=!0,t._seriesValuesDirty=!0,K(this.dataItems,i=>{i.open=void 0,i.close=void 0,e.processSeriesDataItem(i,this._valueXFields),t.processSeriesDataItem(i,this._valueYFields)})}_makeRangeMask(){if(this.axisRanges.length>0){let e=this._mainContainerMask;e==null&&(e=this.children.push(Le.new(this._root,{})),this._mainContainerMask=e,e.set("draw",(t,i)=>{let s=this.parent;if(s){let r=this._root.container.width(),n=this._root.container.height();t.moveTo(-r,-n),t.lineTo(-r,n*2),t.lineTo(r*2,n*2),t.lineTo(r*2,-n),t.lineTo(-r,-n),this.axisRanges.each(A=>{let o=A.axisDataItem.get("axisFill");if(s&&o){let l=o.get("draw");l&&l(t,i)}})}this.mainContainer._display.mask=e._display})),e.markDirty(),e._markDirtyKey("fill")}else this.mainContainer._display.mask=null}_updateChildren(){super._updateChildren(),this._x=this.x(),this._y=this.y(),this._makeRangeMask()}_stack(){let e=this.chart;if(e){let t=e.series.indexOf(this);if(this._couldStackTo=[],t>0){let i;for(let s=t-1;s>=0&&(i=e.series.getIndex(s),!(i.get("xAxis")===this.get("xAxis")&&i.get("yAxis")===this.get("yAxis")&&i.className===this.className&&(this._couldStackTo.push(i),!i.get("stacked"))));s--);}this._stackDataItems()}}_unstack(){Ve(this._reallyStackedTo,(e,t)=>{delete t._stackedSeries[this.uid]}),this._reallyStackedTo={},K(this.dataItems,e=>{e.setRaw("stackToItemY",void 0),e.setRaw("stackToItemX",void 0)})}_handleRemoved(){let e=this.get("xAxis");e&&e._handleSeriesRemoved();let t=this.get("yAxis");t&&t._handleSeriesRemoved()}_stackDataItems(){let e=this.get("baseAxis"),t=this.get("xAxis"),i=this.get("yAxis"),s,r;e===t?(s="valueY",r="stackToItemY"):e===i&&(s="valueX",r="stackToItemX");let n=this._couldStackTo.length,A=0,o=this.get("stackToNegative");this._reallyStackedTo={},K(this.dataItems,l=>{for(let c=0;c<n;c++){let h=this._couldStackTo[c],d=h.dataItems[A],u=l.get(s);if(d){let g=d.get(s);if(o)if(W(u)){if(W(g)){if(c==n-1&&l.setRaw(r,void 0),u>=0&&g>=0){l.setRaw(r,d),this._reallyStackedTo[h.uid]=h,h._stackedSeries[this.uid]=this;break}if(u<0&&g<0){l.setRaw(r,d),this._reallyStackedTo[h.uid]=h,h._stackedSeries[this.uid]=this;break}}}else break;else if(W(u)&&W(g)){l.setRaw(r,d),this._reallyStackedTo[h.uid]=h,h._stackedSeries[this.uid]=this;break}}}A++})}processXSelectionDataItem(e,t,i){K(this.__valueXShowFields,s=>{let r=e.get(s);r!=null&&(i&&(r+=this.getStackedXValueWorking(e,s)),this._min("selectionMinX",r),this._max("selectionMaxX",r*t))})}processYSelectionDataItem(e,t,i){K(this.__valueYShowFields,s=>{let r=e.get(s);r!=null&&(i&&(r+=this.getStackedYValueWorking(e,s)),this._min("selectionMinY",r),this._max("selectionMaxY",r*t))})}getStackedYValueWorking(e,t){let i=e.get("stackToItemY");if(i){let s=i.component;return i.get(t,0)*s.get("vcy",1)+this.getStackedYValueWorking(i,t)}return 0}getStackedXValueWorking(e,t){let i=e.get("stackToItemX");if(i){let s=i.component;return i.get(t,0)*s.get("vcx",1)+this.getStackedXValueWorking(i,t)}return 0}getStackedYValue(e,t){let i=e.get("stackToItemY");return i?i.get(t,0)+this.getStackedYValue(i,t):0}getStackedXValue(e,t){let i=e.get("stackToItemX");return i?i.get(t,0)+this.getStackedXValue(i,t):0}createLegendMarker(e){this.updateLegendMarker()}_markDirtyAxes(){this._axesDirty=!0,this.markDirty()}_markDataSetDirty(){this._afterDataChange(),this._valuesDirty=!0,this._dataProcessed=!1,this._aggregatesCalculated=!1,this.markDirty()}_clearDirty(){super._clearDirty(),this._axesDirty=!1,this._selectionProcessed=!1,this._stackDirty=!1,this._dataProcessed=!1}_positionBullet(e){let t=e.get("sprite");if(t){let i=t.dataItem,s=e.get("locationX",i.get("locationX",.5)),r=e.get("locationY",i.get("locationY",.5)),n=this.get("xAxis"),A=this.get("yAxis"),o=this.get("exactLocationX",!1),l=this.get("exactLocationY",!1),c=n.getDataItemPositionX(i,this._xField,s,this.get("vcx",1),o),h=A.getDataItemPositionY(i,this._yField,r,this.get("vcy",1),l),d=this.getPoint(c,h),u=i.get("left",d.x),g=i.get("right",d.x),y=i.get("top",d.y),m=i.get("bottom",d.y),b=0,B=0,w=g-u,_=m-y;if(this._shouldShowBullet(c,h)){t.setPrivate("visible",!e.getPrivate("hidden"));let T=e.get("field"),Q=this.get("baseAxis"),U=this.get("xAxis"),E=this.get("yAxis");if(T!=null){let D;Q==U?(T=="value"?D=this._yField:T=="open"?D=this._yOpenField:T=="high"?D=this._yHighField:T=="low"&&(D=this._yLowField),D&&(h=E.getDataItemPositionY(i,D,0,this.get("vcy",1),l),d=this._yRenderer.positionToPoint(h),B=d.y,b=u+w*s)):(T=="value"?D=this._xField:T=="open"?D=this._xOpenField:T=="high"?D=this._xHighField:T=="low"&&(D=this._xLowField),D&&(c=U.getDataItemPositionX(i,D,0,this.get("vcx",1),o),d=this._xRenderer.positionToPoint(c),b=d.x,B=m-_*r))}else b=u+w*s,B=m-_*r;let O=e.get("stacked");if(O){let D=this.chart;if(Q==U){let k=this._bullets[c+"_"+h];if(k){let F=k.bounds(),M=t.localBounds(),Y=B;B=F.top,O=="down"?B=F.bottom-M.top:O=="auto"?D&&(Y<D.plotContainer.height()/2?B=F.bottom-M.top:B+=M.bottom):B+=M.bottom}this._bullets[c+"_"+h]=t}else{let k=this._bullets[c+"_"+h];if(k){let F=k.bounds(),M=t.localBounds(),Y=b;b=F.right,O=="down"?b=F.left-M.right:O=="auto"?D&&(Y<D.plotContainer.width()/2?b=F.left-M.right:b-=M.left):b-=M.left}this._bullets[c+"_"+h]=t}}t.isType("Label")&&(t.setPrivate("maxWidth",Math.abs(w)),t.setPrivate("maxHeight",Math.abs(_))),t.setAll({x:b,y:B})}else t.setPrivate("visible",!1)}}_shouldShowBullet(e,t){return this._showBullets}setDataSet(e){if(this._dataSets[e]){this._handleDataSetChange(),this._dataItems=this._dataSets[e],this._markDataSetDirty(),this._dataSetId=e;let t="datasetchanged";this.events.isEnabled(t)&&this.events.dispatch(t,{type:t,target:this,id:e})}}resetGrouping(){Ve(this._dataSets,(e,t)=>{t!=this._mainDataItems&&K(t,i=>{i.dispose()})}),this._dataSets={},this._dataItems=this.mainDataItems}_handleDataSetChange(){K(this._dataItems,e=>{let t=e.bullets;t&&K(t,i=>{if(i){let s=i.get("sprite");s&&s.setPrivate("visible",!1)}})}),this._selectionProcessed=!1}show(e){let t=Object.create(null,{show:{get:()=>super.show}});return Ke(this,void 0,void 0,function*(){this._fixVC();let i=[];i.push(t.show.call(this,e).then(()=>{this._isShowing=!1;let s=this.get("xAxis"),r=this.get("yAxis"),n=this.get("baseAxis");r!==n&&r.markDirtySelectionExtremes(),s!==n&&s.markDirtySelectionExtremes()})),i.push(this.bulletsContainer.show(e)),i.push(this._sequencedShowHide(!0,e)),yield Promise.all(i)})}hide(e){let t=Object.create(null,{hide:{get:()=>super.hide}});return Ke(this,void 0,void 0,function*(){this._fixVC();let i=[];i.push(t.hide.call(this,e).then(()=>{this._isHiding=!1})),i.push(this.bulletsContainer.hide(e)),i.push(this._sequencedShowHide(!1,e)),yield Promise.all(i)})}showDataItem(e,t){let i=Object.create(null,{showDataItem:{get:()=>super.showDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.showDataItem.call(this,e,t)];W(t)||(t=this.get("stateAnimationDuration",0));let r=this.get("stateAnimationEasing");K(this._valueFields,n=>{s.push(e.animate({key:n+"Working",to:e.get(n),duration:t,easing:r}).waitForStop())}),yield Promise.all(s)})}hideDataItem(e,t){let i=Object.create(null,{hideDataItem:{get:()=>super.hideDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.hideDataItem.call(this,e,t)],r=this.states.lookup("hidden");r||(r=this.states.create("hidden",{})),W(t)||(t=r.get("stateAnimationDuration",this.get("stateAnimationDuration",0)));let n=r.get("stateAnimationEasing",this.get("stateAnimationEasing")),A=this.get("xAxis"),o=this.get("yAxis"),l=this.get("baseAxis"),c=this.get("stacked");if((l===A||!l)&&K(this._valueYFields,h=>{let d=o.getPrivate("min"),u=o.baseValue();W(d)&&d>u&&(u=d),c&&(u=0),e.get(h)!=null&&s.push(e.animate({key:h+"Working",to:u,duration:t,easing:n}).waitForStop())}),l===o||!l){let h=A.getPrivate("min"),d=A.baseValue();W(h)&&h>d&&(d=h),c&&(d=0),K(this._valueXFields,u=>{e.get(u)!=null&&s.push(e.animate({key:u+"Working",to:d,duration:t,easing:n}).waitForStop())})}yield Promise.all(s)})}_markDirtyStack(){this._stackDirty=!0,this.markDirty(),this._markStakedDirtyStack()}_markStakedDirtyStack(){let e=this._stackedSeries;e&&Ve(e,(t,i)=>{i._stackDirty||i._markDirtyStack()})}_afterChanged(){super._afterChanged(),this._skipped&&(this._markDirtyAxes(),this._skipped=!1)}showDataItemTooltip(e){this.getPrivate("doNotUpdateLegend")||(this.updateLegendMarker(e),this.updateLegendValue(e));let t=this.get("tooltip"),i=this.get("exactLocationX",!1),s=this.get("exactLocationY",!1);if(t)if(!this.isHidden()&&this.get("visible")){if(t._setDataItem(e),e){let r=this.get("locationX",0),n=this.get("locationY",1),A=e.get("locationX",r),o=e.get("locationY",n),l=this.get("xAxis"),c=this.get("yAxis"),h=this.get("vcx",1),d=this.get("vcy",1),u=l.getDataItemPositionX(e,this._tooltipFieldX,this._aLocationX0+(this._aLocationX1-this._aLocationX0)*A,h,i),g=c.getDataItemPositionY(e,this._tooltipFieldY,this._aLocationY0+(this._aLocationY1-this._aLocationY0)*o,d,s),y=this.getPoint(u,g),m=!0;if(K(this._valueFields,b=>{e.get(b)==null&&(m=!1)}),m){let b=this.chart;b&&b.inPlot(y)?(t.label.text.markDirtyText(),t.set("tooltipTarget",this._getTooltipTarget(e)),t.set("pointTo",this._display.toGlobal({x:y.x,y:y.y}))):t._setDataItem(void 0)}else t._setDataItem(void 0)}}else this.hideTooltip()}hideTooltip(){let e=this.get("tooltip");return e&&e.set("tooltipTarget",this),super.hideTooltip()}_getTooltipTarget(e){if(this.get("seriesTooltipTarget")=="bullet"){let t=e.bullets;if(t&&t.length>0){let s=t[0].get("sprite");if(s)return s}}return this}updateLegendValue(e){let t=this.get("legendDataItem");if(t){let i=t.get("label");if(i){let r="";e?(i._setDataItem(e),r=this.get("legendLabelText",i.get("text",this.get("name","")))):(i._setDataItem(this._emptyDataItem),r=this.get("legendRangeLabelText",this.get("legendLabelText",i.get("text",this.get("name",""))))),i.set("text",r)}let s=t.get("valueLabel");if(s){let r="";e?(s._setDataItem(e),r=this.get("legendValueText",s.get("text",""))):(s._setDataItem(this._emptyDataItem),r=this.get("legendRangeValueText",s.get("text",""))),s.set("text",r)}}}_getItemReaderLabel(){let e="X: {"+this._xField;return this.get("xAxis").isType("DateAxis")&&(e+=".formatDate()"),e+="}; Y: {"+this._yField,this.get("yAxis").isType("DateAxis")&&(e+=".formatDate()"),e+="}",e}getPoint(e,t){let i=this._xRenderer.positionToCoordinate(e),s=this._yRenderer.positionToCoordinate(t),r=999999999;return s<-r?s=-r:s>r&&(s=r),i<-r?i=-r:i>r&&(i=r),{x:i,y:s}}_shouldInclude(e){return!0}handleCursorHide(){this.hideTooltip(),this.updateLegendValue(void 0),this.updateLegendMarker(void 0)}_afterDataChange(){super._afterDataChange(),this.get("xAxis")._markDirtyKey("start"),this.get("yAxis")._markDirtyKey("start"),this.resetExtremes()}resetExtremes(){this.setPrivate("selectionMinX",void 0),this.setPrivate("selectionMaxX",void 0),this.setPrivate("selectionMinY",void 0),this.setPrivate("selectionMaxY",void 0),this.setPrivate("minX",void 0),this.setPrivate("minY",void 0),this.setPrivate("maxX",void 0),this.setPrivate("maxY",void 0)}createAxisRange(e){return this.axisRanges.push({axisDataItem:e})}get mainDataItems(){return this._mainDataItems}_adjustStartIndex(e){let t=this.get("xAxis");if(this.get("baseAxis")==t&&t.isType("DateAxis")){let s=t.baseDuration(),r=t.getPrivate("selectionMin",t.getPrivate("min",0)),n=s*this.get("locationX",.5),A=-1/0;for(;A<r;){let o=this.dataItems[e];if(o){let l=o.open;if(l?A=l.valueX:A=o.get("valueX",0),A+=n,A<r)e++;else break}else break}}return e}};ss.className="XYSeries";ss.classNames=ti.classNames.concat([ss.className]);var rn=class a extends ss{constructor(){super(...arguments),this._ph=0,this._pw=0,this._columnsUpdated=!1}_makeGraphics(e,t){return this.makeColumn(t,e)}_makeFieldNames(){super._makeFieldNames();let e=this.get("xAxis"),t=this.get("yAxis"),i="CategoryAxis",s="ValueAxis";e.isType(i)&&(this.get("openCategoryXField")||(this._xOpenField=this._xField)),e.isType(s)&&(this.get("openValueXField")||(this._xOpenField=this._xField)),t.isType(i)&&(this.get("openCategoryYField")||(this._yOpenField=this._yField)),t.isType(s)&&(this.get("openValueYField")||(this._yOpenField=this._yField))}_prepareChildren(){super._prepareChildren();let e=this.get("xAxis"),t=this.get("yAxis"),i=this.dataItems.length,s=Math.max(0,this.startIndex()-2),r=Math.min(this.endIndex()+2,i-1);if(e.inited&&t.inited)for(let n=s;n<=r;n++){let A=this.dataItems[n];this._createGraphics(A)}}_updateChildren(){let e=this.chart;e&&(this._ph=e.plotContainer.height(),this._pw=e.plotContainer.width());let t=this.get("xAxis"),i=this.get("yAxis"),s=this.get("baseAxis"),r=this.columns.template;this.isDirty("fill")&&r.get("fill")==null&&r.set("fill",this.get("fill")),this.isDirty("fillPattern")&&r.get("fillPattern")==null&&r.set("fillPattern",this.get("fillPattern")),this.isDirty("stroke")&&r.get("stroke")==null&&r.set("stroke",this.get("stroke"));let n=0,A=0,o=0;s&&K(s.series,y=>{if(y instanceof a){let m=y.get("stacked");m&&o==0&&A++,!m&&y.get("clustered")&&A++}y===this&&(n=A-1),o++}),this.get("clustered")||(n=0,A=1),A===0&&(A=1,n=0);let l="cellStartLocation",c="cellEndLocation",h=this._xRenderer.get(l,0),d=this._xRenderer.get(c,1),u=this._yRenderer.get(l,0),g=this._yRenderer.get(c,1);if(this._aLocationX0=h+n/A*(d-h),this._aLocationX1=h+(n+1)/A*(d-h),this._aLocationY0=u+n/A*(g-u),this._aLocationY1=u+(n+1)/A*(g-u),t.inited&&i.inited){if(this._axesDirty||this._valuesDirty||this._stackDirty||this.isDirty("vcx")||this.isDirty("vcy")||this._sizeDirty){let y=this.dataItems.length,m=Math.max(0,this.startIndex()-2),b=Math.min(this.endIndex()+2,y-1);for(let _=0;_<m;_++)this._toggleColumn(this.dataItems[_],!1);let B=this.dataItems[m];for(let _=m;_<=b;_++){let T=this.dataItems[_];if(T.get("valueX")!=null&&T.get("valueY")!=null){if(B=T,_>0&&m>0)for(let Q=_-1;Q>=0;Q--){let U=this.dataItems[Q];if(U.get("valueX")!=null&&U.get("valueY")!=null){B=U;break}}break}else this._toggleColumn(T,!1)}this._beforeColumnsDraw();let w=0;i.isType("CategoryAxis")&&t.isType("CategoryAxis")?w=2:t===s?w=0:i===s&&(w=1);for(let _=m;_<=b;_++){let T=this.dataItems[_];this._updateGraphics(T,B,w),T.get("valueX")!=null&&T.get("valueY")!=null&&(B=T)}this._afterColumnsDraw();for(let _=b+1;_<y;_++)this._toggleColumn(this.dataItems[_],!1);this._columnsUpdated=!0}}else this._skipped=!0;this.getPrivate("doNotUpdateLegend")||this.updateLegendMarker(this.get("tooltipDataItem")),super._updateChildren()}_afterChanged(){super._afterChanged(),this._columnsUpdated=!1}_beforeColumnsDraw(){}_afterColumnsDraw(){}_createGraphics(e){let t=e.get("graphics");if(!t){t=this._makeGraphics(this.columns,e),e.set("graphics",t),t._setDataItem(e);let i=e.get("legendDataItem");if(i){let r=i.get("markerRectangle");if(r){let n=r.states.lookup("default");K(Ko,A=>{let o=t.get(A,this.get(A));r.set(A,o),n.set(A,o)})}}let s=e.get("rangeGraphics");s&&K(s,r=>{r.dispose()}),s=[],e.setRaw("rangeGraphics",s),this.axisRanges.each(r=>{let n=r.container,A=this._makeGraphics(r.columns,e);s&&s.push(A),A.setPrivate("list",r.columns),n.children.push(A)})}}createAxisRange(e){return K(this.dataItems,t=>{let i=t.get("graphics");i&&(i.dispose(),t.set("graphics",void 0))}),super.createAxisRange(e)}_updateGraphics(e,t,i){let s=e.get("graphics"),r=this._xField,n=this._yField,A=e.get(r),o=e.get(n),l=this.get("exactLocationX",!1);if(A!=null&&o!=null){let c=this._xOpenField,h=this._yOpenField,d=this.get("locationX",e.get("locationX",.5)),u=this.get("locationY",e.get("locationY",.5)),g=this.get("openLocationX",e.get("openLocationX",d)),y=this.get("openLocationY",e.get("openLocationY",u)),m=s.get("width"),b=s.get("height"),B=this.get("stacked"),w=this.get("xAxis"),_=this.get("yAxis"),T=w.get("start"),Q=w.get("end"),U=_.get("start"),E=_.get("end"),O,D,k,F,M=this.get("vcy",1),Y=this.get("vcx",1),z=!1,re=!1;if(i==0){let Ae=this._aLocationX0+g-.5,X=this._aLocationX1+d-.5;if(m instanceof ke){let G=(X-Ae)*(1-m.value)/2;Ae+=G,X-=G}if(O=w.getDataItemPositionX(e,c,Ae,Y,l),D=w.getDataItemPositionX(e,r,X,Y,l),k=_.getDataItemPositionY(e,n,u,M),this._yOpenField!==this._yField)F=_.getDataItemPositionY(e,h,y,M);else if(B){let G=e.get("stackToItemY");G?F=_.getDataItemPositionY(G,n,y,G.component.get("vcy")):F=_.basePosition()}else F=_.basePosition();e.setRaw("point",{x:O+(D-O)/2,y:k}),re=!0}else if(i==1){let Ae=this._aLocationY0+y-.5,X=this._aLocationY1+u-.5;if(b instanceof ke){let G=(X-Ae)*(1-b.value)/2;Ae+=G,X-=G}if(k=_.getDataItemPositionY(e,h,Ae,M),F=_.getDataItemPositionY(e,n,X,M),D=w.getDataItemPositionX(e,r,d,Y,l),this._xOpenField!==this._xField)O=w.getDataItemPositionX(e,c,g,Y,l);else if(B){let G=e.get("stackToItemX");G?O=w.getDataItemPositionX(G,r,g,G.component.get("vcx"),l):O=w.basePosition()}else O=w.basePosition();z=!0,e.setRaw("point",{x:D,y:k+(F-k)/2})}else if(i==2){let Ae=this._aLocationX0+g-.5,X=this._aLocationX1+d-.5;if(m instanceof ke){let G=(X-Ae)*(1-m.value)/2;Ae+=G,X-=G}if(O=w.getDataItemPositionX(e,c,Ae,Y),D=w.getDataItemPositionX(e,r,X,Y),Ae=this._aLocationY0+y-.5,X=this._aLocationY1+u-.5,b instanceof ke){let G=(X-Ae)*(1-b.value)/2;Ae+=G,X-=G}k=_.getDataItemPositionY(e,h,Ae,M),F=_.getDataItemPositionY(e,n,X,M),e.setRaw("point",{x:O+(D-O)/2,y:k+(F-k)/2})}this._applyGraphicsStates(e,t),this._updateSeriesGraphics(e,s,O,D,k,F,z,re),O<T&&D<T||O>Q&&D>Q||k<U&&F<=U||k>=E&&F>E||Ni(O)||Ni(k)?this._toggleColumn(e,!1):this._toggleColumn(e,!0);let q=e.get("rangeGraphics");q&&K(q,Ae=>{this._updateSeriesGraphics(e,Ae,O,D,k,F,z,re)})}else this._toggleColumn(e,!1)}_updateSeriesGraphics(e,t,i,s,r,n,A,o){let l=t.get("width"),c=t.get("height"),h=t.get("maxWidth"),d=t.get("maxHeight"),u=this.getPoint(i,r),g=this.getPoint(s,n),y=e.get("point");if(y){let m=this.getPoint(y.x,y.y);y.x=m.x+this._x,y.y=m.y+this._y}if(i=u.x,s=g.x,r=u.y,n=g.y,W(l)){let m=(s-i-l)/2;i+=m,s-=m}if(W(h)&&h<Math.abs(s-i)){let m=(s-i-h)/2;i+=m,s-=m}if(W(c)){let m=(n-r-c)/2;r+=m,n-=m}if(W(d)&&d<Math.abs(n-r)){let m=(n-r-d)/2;r+=m,n-=m}this.get("adjustBulletPosition")&&(A&&(s=Math.min(Math.max(0,s),this._pw),i=Math.min(Math.max(0,i),this._pw)),o&&(r=Math.min(Math.max(0,r),this._ph),n=Math.min(Math.max(0,n),this._ph))),e.setRaw("left",i),e.setRaw("right",s),e.setRaw("top",r),e.setRaw("bottom",n),t.setPrivate("width",s-i),t.setPrivate("height",n-r),t.set("x",i),t.set("y",n-(n-r))}_handleDataSetChange(){super._handleDataSetChange(),K(this._dataItems,e=>{this._toggleColumn(e,!1)})}_applyGraphicsStates(e,t){let i=e.get("graphics"),s=i.states.lookup("dropFromOpen"),r=i.states.lookup("riseFromOpen"),n=i.states.lookup("dropFromPrevious"),A=i.states.lookup("riseFromPrevious");if(s||n||r||A){let o=this.get("xAxis"),l=this.get("yAxis"),c=this.get("baseAxis"),h,d,u;c===o&&l.isType("ValueAxis")?(h=e.get(this._yOpenField),d=e.get(this._yField),u=t.get(this._yField)):c===l&&o.isType("ValueAxis")&&(h=e.get(this._xOpenField),d=e.get(this._xField),u=t.get(this._xField)),W(h)&&W(d)&&(d<h?s&&s.apply():r&&r.apply(),W(u)&&(d<u?n&&n.apply():A&&A.apply()))}}disposeDataItem(e){super.disposeDataItem(e);let t=e.get("graphics");t&&(this.columns.removeValue(t),t.dispose());let i=e.get("rangeGraphics");i&&K(i,s=>{let r=s.getPrivate("list");r&&r.removeValue(s),s.dispose()})}hideDataItem(e,t){let i=Object.create(null,{hideDataItem:{get:()=>super.hideDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.hideDataItem.call(this,e,t)],r=e.get("graphics");r&&s.push(r.hide(t));let n=e.get("rangeGraphics");n&&K(n,A=>{s.push(A.hide(t))}),yield Promise.all(s)})}_toggleColumn(e,t){let i=e.get("graphics");i&&i.setPrivate("visible",t);let s=e.get("rangeGraphics");s&&K(s,n=>{n.setPrivate("visible",t)});let r=e.bullets;r&&K(r,n=>{n.setPrivate("hidden",!t)})}showDataItem(e,t){let i=Object.create(null,{showDataItem:{get:()=>super.showDataItem}});return Ke(this,void 0,void 0,function*(){let s=[i.showDataItem.call(this,e,t)],r=e.get("graphics");r&&s.push(r.show(t));let n=e.get("rangeGraphics");n&&K(n,A=>{s.push(A.show(t))}),yield Promise.all(s)})}updateLegendMarker(e){let t=this.get("legendDataItem");if(this.get("useLastColorForLegendMarker")&&!e){let i=this.dataItems[this.endIndex()-1];i&&(e=i)}if(t){let i=this.columns.template;if(e){let r=e.get("graphics");r&&(i=r)}let s=t.get("markerRectangle");if(s&&!t.get("itemContainer").get("disabled")){let r=s.states.lookup("default");K(Ko,n=>{let A=i.get(n,this.get(n));s.set(n,A),r.set(n,A)})}}}_getTooltipTarget(e){if(this.get("seriesTooltipTarget")=="bullet")return super._getTooltipTarget(e);let t=e.get("graphics");return t||this}};rn.className="BaseColumnSeries";rn.classNames=ss.classNames.concat([rn.className]);var Js=class extends pe{constructor(){super(...arguments),this._alwaysShow=!1,this.lineX=this.children.push($r.new(this._root,{themeTags:["x"]})),this.lineY=this.children.push($r.new(this._root,{themeTags:["y"]})),this.selection=this.children.push(Le.new(this._root,{themeTags:["selection","cursor"],layer:30})),this._lastPoint={x:0,y:0},this._lastPoint2={x:0,y:0},this._tooltipX=!1,this._tooltipY=!1}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["xy","cursor"]),super._afterNew(),this.setAll({width:se,height:se,isMeasured:!0,position:"absolute"}),this.states.create("hidden",{visible:!0,opacity:0}),this._drawLines(),this.setPrivateRaw("visible",!1),this._disposers.push(this.setTimeout(()=>{this.setPrivate("visible",!0)},500)),this._disposers.push(this.lineX.events.on("positionchanged",()=>{this._handleXLine()})),this._disposers.push(this.lineY.events.on("positionchanged",()=>{this._handleYLine()})),this._disposers.push(this.lineX.events.on("focus",()=>this._handleLineFocus())),this._disposers.push(this.lineX.events.on("blur",()=>this._handleLineBlur())),this._disposers.push(this.lineY.events.on("focus",()=>this._handleLineFocus())),this._disposers.push(this.lineY.events.on("blur",()=>this._handleLineBlur())),zs("keyboardevents")&&this._disposers.push(kt(document,"keydown",e=>{this._handleLineMove(kn(e),e.ctrlKey)}))}_setUpTouch(){let e=this.chart;e&&(e.plotContainer._display.cancelTouch=this.get("behavior")!="none")}_handleXLine(){let e=this.lineX.x(),t=!0;(e<0||e>this.width())&&(t=!1),this.lineX.setPrivate("visible",t)}_handleYLine(){let e=this.lineY.y(),t=!0;(e<0||e>this.height())&&(t=!1),this.lineY.setPrivate("visible",t)}_handleLineMove(e,t){let i="",s=this.chart,r;if(s&&s.xAxes.length){this._root.focused(this.lineX)?(i="positionX",r=s.xAxes.getIndex(0)):this._root.focused(this.lineY)&&(r=s.yAxes.getIndex(0),i="positionY");let n=1;if(t&&(n=5),r){let A=r.get("renderer").get("inversed",!1),o;e=="ArrowRight"||e=="ArrowDown"?o=1:e=="ArrowLeft"||e=="ArrowUp"?o=-1:e=="Tab"&&(o=0),o!=null&&(A&&(o*=-1),this.set(i,r.nextPosition(o*n)))}}}_handleLineFocus(){this._alwaysShow=this.get("alwaysShow",!1),this.setAll({positionX:this.getPrivate("positionX",0),positionY:this.getPrivate("positionY",0),alwaysShow:!0}),this._handleLineMove("Tab")}_handleLineBlur(){(this.lineX.isFocus()||this.lineY.isFocus())&&this.setAll({positionX:void 0,positionY:void 0,alwaysShow:this._alwaysShow})}_prepareChildren(){if(super._prepareChildren(),this.isDirty("xAxis")){this._tooltipX=!1;let e=this.get("xAxis");if(e){let t=e.get("tooltip");t&&(this._tooltipX=!0,this._disposers.push(t.on("pointTo",()=>{this._updateXLine(t)})))}}if(this.isDirty("yAxis")){this._tooltipY=!1;let e=this.get("yAxis");if(e){let t=e.get("tooltip");t&&(this._tooltipY=!0,this._disposers.push(t.on("pointTo",()=>{this._updateYLine(t)})))}}}_handleSyncWith(){let e=this.chart;if(e){let t=this.get("syncWith"),i=[];t&&K(t,s=>{let r=s.chart;r&&i.push(r)}),e._otherCharts=i}}_updateChildren(){if(super._updateChildren(),this._handleSyncWith(),this.isDirty("positionX")||this.isDirty("positionY")){let e=this.get("positionX"),t=this.get("positionY");e==null&&t==null?this.hide(0):(this._movePoint=this.toGlobal(this._getPoint(this.get("positionX",0),this.get("positionY",0))),this.handleMove())}}_updateXLine(e){let t=jt(this._display.toLocal(e.get("pointTo",{x:0,y:0})).x,3);this._toX!=t&&(this.lineX.animate({key:"x",to:t,duration:e.get("animationDuration",0),easing:e.get("animationEasing")}),this._toX=t)}_updateYLine(e){let t=jt(this._display.toLocal(e.get("pointTo",{x:0,y:0})).y,3);this._toY!=t&&(this.lineY.animate({key:"y",to:t,duration:e.get("animationDuration",0),easing:e.get("animationEasing")}),this._toY=t)}_drawLines(){this.lineX.set("draw",e=>{e.moveTo(0,0),e.lineTo(0,this.height())}),this.lineY.set("draw",e=>{e.moveTo(0,0),e.lineTo(this.width(),0)})}updateCursor(){this.get("alwaysShow")&&(this._movePoint=this.toGlobal(this._getPoint(this.get("positionX",0),this.get("positionY",0)))),this.handleMove()}_setChart(e){this.chart=e,this._handleSyncWith();let t=e.plotContainer;this.events.on("boundschanged",()=>{this._disposers.push(this.setTimeout(()=>{this.updateCursor()},50))}),zs("touchevents")&&(this._disposers.push(t.events.on("click",s=>{Mo(s.originalEvent)&&this._handleMove(s)})),this._setUpTouch()),this._disposers.push(t.events.on("pointerdown",s=>{this._handleCursorDown(s)})),this._disposers.push(t.events.on("globalpointerup",s=>{this._handleCursorUp(s),!s.native&&!this.isHidden()&&this._handleMove(s)})),this._disposers.push(t.events.on("globalpointermove",s=>{!this.get("syncWith")&&Bi(t._downPoints).length==0&&!s.native&&this.isHidden()||(this._handleMove(s),Math.hypot(this._lastPoint2.x-s.point.x,this._lastPoint2.y-s.point.y)>1&&(this._handleLineBlur(),this._lastPoint2=s.point))}));let i=this.parent;i&&i.children.moveValue(this.selection)}_inPlot(e){let t=this.chart;return t?t.inPlot(e):!1}_handleCursorDown(e){if(e.originalEvent.button==2)return;let t=e.point,i=this._display.toLocal(t),s=this.chart;if(this.selection.set("draw",()=>{}),s&&this._inPlot(i)){if(this._downPoint=i,this.get("behavior")!="none"){this.selection.show();let A="selectstarted";this.events.isEnabled(A)&&this.events.dispatch(A,{type:A,target:this,originalEvent:e.originalEvent})}let r=this._getPosition(i).x,n=this._getPosition(i).y;this.setPrivate("downPositionX",r),this.setPrivate("downPositionY",n)}}_handleCursorUp(e){if(this._downPoint){let t=this.get("behavior","none");if(t!="none"){t.charAt(0)==="z"&&this.selection.hide();let i=e.point,s=this._display.toLocal(i),r=this._downPoint,n=this.get("moveThreshold",1);if(s&&r){let A=!1;if((t==="zoomX"||t==="zoomXY"||t==="selectX"||t==="selectXY")&&Math.abs(s.x-r.x)>n&&(A=!0),(t==="zoomY"||t==="zoomXY"||t==="selectY"||t==="selectXY")&&Math.abs(s.y-r.y)>n&&(A=!0),A){let o="selectended";this.events.isEnabled(o)&&this.events.dispatch(o,{type:o,target:this,originalEvent:e.originalEvent})}else{let o="selectcancelled";this.events.isEnabled(o)&&this.events.dispatch(o,{type:o,target:this,originalEvent:e.originalEvent})}}}}this._downPoint=void 0}_handleMove(e){if(this.getPrivate("visible")){let t=this.chart;if(t&&Bi(t.plotContainer._downPoints).length>1){this.set("forceHidden",!0);return}else this.set("forceHidden",!1);let i=e.point,s=this._lastPoint;if(Math.round(s.x)===Math.round(i.x)&&Math.round(s.y)===Math.round(i.y))return;this._lastPoint=i,this.setPrivate("lastPoint",i),this.handleMove({x:i.x,y:i.y},!1,e.originalEvent)}}_getPosition(e){return{x:e.x/this.width(),y:e.y/this.height()}}handleMove(e,t,i){e||(e=this._movePoint);let s=this.get("alwaysShow");if(!e){this.hide(0);return}this._movePoint=e;let r=this._display.toLocal(e),n=this.chart;if(n&&(this._inPlot(r)||this._downPoint)){n._movePoint=e,this.isHidden()&&(this.show(),this.get("behavior","").charAt(0)=="z"&&this.selection.set("draw",()=>{}));let A=r.x,o=r.y,l=this._getPosition(r);this.setPrivate("point",r);let c=this.get("snapToSeries");this._downPoint&&(c=void 0);let h=this.get("positionX"),d=l.x;W(h)&&(d=h);let u=this.get("positionY"),g=l.y;W(u)&&(g=u),this.setPrivate("positionX",d),this.setPrivate("positionY",g);let y=this._getPoint(d,g);if(A=y.x,o=y.y,n.xAxes.each(m=>{m._handleCursorPosition(d,c),s&&m.handleCursorShow()}),n.yAxes.each(m=>{m._handleCursorPosition(g,c),s&&m.handleCursorShow()}),!t){n._handleCursorPosition();let m="cursormoved";this.events.isEnabled(m)&&this.events.dispatch(m,{type:m,target:this,point:e,originalEvent:i})}this._updateLines(A,o),n.arrangeTooltips()}else if(!this._downPoint&&!s){this.hide(0);let A="cursorhidden";this.events.isEnabled(A)&&this.events.dispatch(A,{type:A,target:this})}this._downPoint&&this.get("behavior")!="none"&&this._updateSelection(r)}_getPoint(e,t){return{x:this.width()*e,y:this.height()*t}}_updateLines(e,t){this._tooltipX||this.lineX.set("x",e),this._tooltipY||this.lineY.set("y",t),this._drawLines()}_updateSelection(e){let t=this.selection,i=this.get("behavior"),s=this.width(),r=this.height();e.x<0&&(e.x=0),e.x>s&&(e.x=s),e.y<0&&(e.y=0),e.y>r&&(e.y=r),t.set("draw",n=>{let A=this._downPoint;A&&(i==="zoomXY"||i==="selectXY"?(n.moveTo(A.x,A.y),n.lineTo(A.x,e.y),n.lineTo(e.x,e.y),n.lineTo(e.x,A.y),n.lineTo(A.x,A.y)):i==="zoomX"||i==="selectX"?(n.moveTo(A.x,0),n.lineTo(A.x,r),n.lineTo(e.x,r),n.lineTo(e.x,0),n.lineTo(A.x,0)):(i==="zoomY"||i==="selectY")&&(n.moveTo(0,A.y),n.lineTo(s,A.y),n.lineTo(s,e.y),n.lineTo(0,e.y),n.lineTo(0,A.y)))})}_onHide(){if(this.isHidden()){let e=this.chart;e&&(e.xAxes.each(t=>{t.handleCursorHide()}),e.yAxes.each(t=>{t.handleCursorHide()}),e.series.each(t=>{t.handleCursorHide()}))}super._onHide()}_onShow(){if(!this.isHidden()){let e=this.chart;e&&(e.xAxes.each(t=>{t.handleCursorShow()}),e.yAxes.each(t=>{t.handleCursorShow()}))}super._onShow()}_dispose(){super._dispose(),this.selection.dispose()}};Js.className="XYCursor";Js.classNames=pe.classNames.concat([Js.className]);var Gr=class extends Js{constructor(){super(...arguments),this._fillGenerator=gr()}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["radar","cursor"]),super._afterNew()}_handleXLine(){}_handleYLine(){}_getPosition(e){let t=Math.hypot(e.x,e.y),i=es(Math.atan2(e.y,e.x)*bs),s=this.getPrivate("innerRadius"),r=es(this.getPrivate("startAngle")),n=es(this.getPrivate("endAngle"));(n<r||n==r)&&(i<r&&(i+=360),n=n+360);let A=(i-r)/(n-r);return A<0&&(A=1+A),A<.003&&(A=0),A>.997&&(A=1),{x:A,y:(t-s)/(this.getPrivate("radius")-s)}}_getPoint(e,t){let i=this.getPrivate("innerRadius"),s=this.getPrivate("startAngle"),r=this.getPrivate("endAngle"),n=this.getPrivate("radius"),A=s+e*(r-s),o=i+(n-i)*t;return{x:o*ft(A),y:o*At(A)}}updateLayout(){let e=this.chart;if(e){let t=e.getPrivate("radius",0);this.setPrivate("radius",We(this.get("radius",se),t));let i=We(this.get("innerRadius",e.getPrivate("innerRadius",0)),t);i<0&&(i=t+i),this.setPrivate("innerRadius",i);let s=this.get("startAngle",e.get("startAngle",-90)),r=this.get("endAngle",e.get("endAngle",270));this.setPrivate("startAngle",s),this.setPrivate("endAngle",r)}}_updateLines(e,t){this._tooltipX||this._drawXLine(e,t),this._tooltipY||this._drawYLine(e,t)}_drawXLine(e,t){let i=this.getPrivate("innerRadius"),s=this.getPrivate("radius"),r=Math.atan2(t,e);this.lineX.set("draw",n=>{n.moveTo(i*Math.cos(r),i*Math.sin(r)),n.lineTo(s*Math.cos(r),s*Math.sin(r))})}_drawYLine(e,t){let i=Math.hypot(e,t);this.lineY.set("draw",s=>{s.arc(0,0,i,this.getPrivate("startAngle",0)*Kt,this.getPrivate("endAngle",0)*Kt)})}_updateXLine(e){let t=e.get("pointTo");t&&(t=this._display.toLocal(t),this._drawXLine(t.x,t.y))}_updateYLine(e){let t=e.get("pointTo");t&&(t=this._display.toLocal(t),this._drawYLine(t.x,t.y))}_inPlot(e){let t=this.chart;return t?t.inPlot(e,this.getPrivate("radius"),this.getPrivate("innerRadius")):!1}_updateSelection(e){this.selection.set("draw",t=>{let i=this.get("behavior"),s=this._downPoint,r=this.getPrivate("startAngle"),n=this.getPrivate("endAngle"),A=this.getPrivate("radius"),o=this.getPrivate("innerRadius");A<o&&([A,o]=[o,A]);let l=r,c=n,h=A,d=o;s&&(i=="zoomXY"||i=="selectXY"?(l=Math.atan2(s.y,s.x)*bs,c=Math.atan2(e.y,e.x)*bs,d=Math.hypot(s.x,s.y),h=Math.hypot(e.x,e.y)):i=="zoomX"||i=="selectX"?(l=Math.atan2(s.y,s.x)*bs,c=Math.atan2(e.y,e.x)*bs):(i=="zoomY"||i=="selectY")&&(d=Math.hypot(s.x,s.y),h=Math.hypot(e.x,e.y))),d=Bt(d,o,A),h=Bt(h,o,A),l=_f(l,r,n),c=_f(c,r,n),l==c&&(c=l+360),l*=Kt,c*=Kt,this._fillGenerator.context(t),this._fillGenerator({innerRadius:d,outerRadius:h,startAngle:l+Math.PI/2,endAngle:c+Math.PI/2})})}};Gr.className="RadarCursor";Gr.classNames=Js.classNames.concat([Gr.className]);var qe=class extends ss{constructor(){super(...arguments),this._strokeGenerator=Jo(),this._fillGenerator=mg(),this.strokes=this.addDisposer(new pt(Ne.new({}),()=>Le._new(this._root,{themeTags:Fe(this.strokes.template.get("themeTags",[]),["line","series","stroke"])},[this.strokes.template]))),this.fills=this.addDisposer(new pt(Ne.new({}),()=>Le._new(this._root,{themeTags:Fe(this.strokes.template.get("themeTags",[]),["line","series","fill"])},[this.fills.template]))),this._previousPoint=[0,0,0,0],this._dindex=0,this._sindex=0}_afterNew(){this._fillGenerator.y0(function(e){return e[3]}),this._fillGenerator.x0(function(e){return e[2]}),this._fillGenerator.y1(function(e){return e[1]}),this._fillGenerator.x1(function(e){return e[0]}),super._afterNew()}makeStroke(e){let t=this.mainContainer.children.push(e.make());return e.push(t),t}makeFill(e){let t=this.mainContainer.children.push(e.make());return e.push(t),t}_updateChildren(){this._strokeTemplate=void 0,this._fillTemplate=void 0;let e=this.get("xAxis"),t=this.get("yAxis");if(this.isDirty("stroke")){let i=this.get("stroke");this.strokes.template.set("stroke",i);let s=this._legendStroke;s&&s.states.lookup("default").set("stroke",i)}if(this.isDirty("fill")){let i=this.get("fill");this.fills.template.set("fill",i);let s=this._legendFill;s&&s.states.lookup("default").set("fill",i)}if(this.isDirty("fillPattern")){let i=this.get("fillPattern");this.fills.template.set("fillPattern",i);let s=this._legendFill;s&&s.states.lookup("default").set("fillPattern",i)}if(this.isDirty("curveFactory")){let i=this.get("curveFactory");i&&(this._strokeGenerator.curve(i),this._fillGenerator.curve(i))}if(e.inited&&t.inited){if(this._axesDirty||this._valuesDirty||this._stackDirty||this.isDirty("vcx")||this.isDirty("vcy")||this._sizeDirty||this.isDirty("connect")||this.isDirty("curveFactory")){let i=this.dataItems;this.fills.each(h=>{h.setPrivate("visible",!1)}),this.strokes.each(h=>{h.setPrivate("visible",!1)}),this.axisRanges.each(h=>{let d=h.fills;d&&d.each(g=>{g.setPrivate("visible",!1)});let u=h.strokes;u&&u.each(g=>{g.setPrivate("visible",!1)})});let s=this.startIndex(),r=this.strokes.template.get("templateField"),n=this.fills.template.get("templateField"),A=!0,o=!0;r&&(A=!1),n&&(o=!1);for(let h=s-1;h>=0;h--){let d=i[h],u=!0,g=d.dataContext;r&&g[r]&&(A=!0),n&&g[n]&&(o=!0);for(let y=0,m=this._valueFields.length;y<m;y++)if(!W(d.get(this._valueFields[y]))){u=!1;break}if(u&&A&&o){s=h;break}}let l=i.length,c=this.endIndex();if(c<l){c++;for(let h=c;h<l;h++){let d=i[h],u=!0;for(let g=0,y=this._valueFields.length;g<y;g++)if(!W(d.get(this._valueFields[g]))){u=!1;break}if(u){c=h+1;break}}}if(s>0&&s--,this._endIndex=c,this._clearGraphics(),this._sindex=0,this._dindex=s,l==1)this._startSegment(0);else for(;this._dindex<c-1;)this._startSegment(this._dindex),this._sindex++}}else this._skipped=!0;super._updateChildren()}_clearGraphics(){this.strokes.clear(),this.fills.clear(),this.axisRanges.each(e=>{e.fills.clear(),e.strokes.clear()})}_startSegment(e){let t=this.dataItems,i=this._endIndex,s=i,r=this.get("autoGapCount"),n=this.get("connect"),A=this.makeFill(this.fills),o=this._fillTemplate,l=this.fills.template;o&&o!=l&&(A.template=o),A.setPrivate("visible",!0);let c=this.makeStroke(this.strokes),h=this._strokeTemplate;h&&h!=this.strokes.template&&(c.template=h),c.setPrivate("visible",!0);let d=this.get("xAxis"),u=this.get("yAxis"),g=this.get("baseAxis"),y=this.get("vcx",1),m=this.get("vcy",1),b=this._xField,B=this._yField,w=this._xOpenField,_=this._yOpenField,T=this.get("openValueXField"),Q=this.get("openValueYField");T||(w=this._xField),Q||(_=this._yField);let U=this.get("stacked"),E=d.basePosition(),O=u.basePosition(),D;g===u?D=this._yField:D=this._xField;let k=[],F=[];k.push(F);let M=this.strokes.template.get("templateField"),Y=this.fills.template.get("templateField"),z=this.get("locationX",.5),re=this.get("locationY",.5),q=this.get("openLocationX",z),Ae=this.get("openLocationY",re),X=this.get("minDistance",0),G,ue=this.fills.template.get("visible");this.axisRanges.length>0&&(ue=!0);let he=!1;(U||T||Q)&&(he=!0);let ae={points:F,segments:k,stacked:U,getOpen:he,basePosX:E,basePosY:O,fillVisible:ue,xField:b,yField:B,xOpenField:w,yOpenField:_,vcx:y,vcy:m,baseAxis:g,xAxis:d,yAxis:u,locationX:z,locationY:re,openLocationX:q,openLocationY:Ae,minDistance:X},Ie=this._strokeTemplate,Pe=this._fillTemplate;for(G=e;G<s;G++){this._dindex=G;let De=t[G],Qe=De.get(b),dt=De.get(B);if(Qe==null||dt==null?n||(F=[],k.push(F),ae.points=F):this._getPoints(De,ae),M){let Me=De.dataContext[M];if(Me)if(Me instanceof Ne||(Me=Ne.new(Me)),this._strokeTemplate=Me,G>e){s=G;break}else Ie=Me,c.template=Me}if(Y){let Me=De.dataContext[Y];if(Me)if(Me instanceof Ne||(Me=Ne.new(Me)),this._fillTemplate=Me,G>e){s=G;break}else Pe=Me,A.template=Me}if(!n){let Me=t[G+1];Me&&g.shouldGap(De,Me,r,D)&&(F=[],k.push(F),ae.points=F)}}A.setRaw("userData",[e,G]),c.setRaw("userData",[e,G]),G===i&&this._endLine(F,k[0][0]),c&&this._drawStroke(c,k),A&&this._drawFill(A,k),this.axisRanges.each(De=>{let Qe=De.container,dt=De.fills,Me=this.makeFill(dt);Qe&&Qe.children.push(Me),Me.setPrivate("visible",!0),this._drawFill(Me,k);let mi=De.strokes,$t=this.makeStroke(mi);Qe&&Qe.children.push($t),Ie&&Ie!=this.strokes.template&&($t.template=Ie),Pe&&Pe!=this.fills.template&&(Me.template=Pe),$t.setPrivate("visible",!0),this._drawStroke($t,k),Me.setRaw("userData",[e,G]),$t.setRaw("userData",[e,G])})}_getPoints(e,t){let i=t.points,s=e.get("locationX",t.locationX),r=e.get("locationY",t.locationY),n=this.get("exactLocationX",!1),A=this.get("exactLocationY",!1),o=t.xAxis.getDataItemPositionX(e,t.xField,s,t.vcx,n),l=t.yAxis.getDataItemPositionY(e,t.yField,r,t.vcy,A);if(this._shouldInclude(o)){let c=this.getPoint(o,l),h=[c.x,c.y];if(c.x+=this._x,c.y+=this._y,e.set("point",c),t.fillVisible){let d=o,u=l;if(t.baseAxis===t.xAxis?u=t.basePosY:t.baseAxis===t.yAxis&&(d=t.basePosX),t.getOpen){let y=e.get(t.xOpenField),m=e.get(t.yOpenField);if(y!=null&&m!=null){let b=e.get("openLocationX",t.openLocationX),B=e.get("openLocationY",t.openLocationY);if(t.stacked){let w=e.get("stackToItemX"),_=e.get("stackToItemY");w?(d=t.xAxis.getDataItemPositionX(w,t.xField,b,w.component.get("vcx"),n),Ni(d)&&(d=t.basePosX)):t.yAxis===t.baseAxis?d=t.basePosX:d=t.xAxis.getDataItemPositionX(e,t.xOpenField,b,t.vcx,n),_?(u=t.yAxis.getDataItemPositionY(_,t.yField,B,_.component.get("vcy"),A),Ni(u)&&(u=t.basePosY)):t.xAxis===t.baseAxis?u=t.basePosY:u=t.yAxis.getDataItemPositionY(e,t.yOpenField,B,t.vcy,A)}else d=t.xAxis.getDataItemPositionX(e,t.xOpenField,b,t.vcx,n),u=t.yAxis.getDataItemPositionY(e,t.yOpenField,B,t.vcy,A)}}let g=this.getPoint(d,u);h[2]=g.x,h[3]=g.y}if(t.minDistance>0){let d=h[0],u=h[1],g=h[2],y=h[3],m=this._previousPoint,b=m[0],B=m[1],w=m[2],_=m[3];(Math.hypot(d-b,u-B)>t.minDistance||g&&y&&Math.hypot(g-w,y-_)>t.minDistance)&&(i.push(h),this._previousPoint=h)}else i.push(h)}}_endLine(e,t){}_drawStroke(e,t){e.get("visible")&&!e.get("forceHidden")&&e.set("draw",i=>{K(t,s=>{this._strokeGenerator.context(i),this._strokeGenerator(s)})})}_drawFill(e,t){e.get("visible")&&!e.get("forceHidden")&&e.set("draw",i=>{K(t,s=>{this._fillGenerator.context(i),this._fillGenerator(s)})})}_processAxisRange(e){super._processAxisRange(e),e.fills=new pt(Ne.new({}),()=>Le._new(this._root,{themeTags:Fe(e.fills.template.get("themeTags",[]),["line","series","fill"])},[this.fills.template,e.fills.template])),e.strokes=new pt(Ne.new({}),()=>Le._new(this._root,{themeTags:Fe(e.strokes.template.get("themeTags",[]),["line","series","stroke"])},[this.strokes.template,e.strokes.template]))}createLegendMarker(e){let t=this.get("legendDataItem");if(t){let i=t.get("marker"),s=t.get("markerRectangle");s&&s.setPrivate("visible",!1),i.set("background",Tt.new(i._root,{fillOpacity:0,fill:$i(0)}));let r=i.children.push(Le._new(i._root,{themeTags:["line","series","legend","marker","stroke"],interactive:!1},[this.strokes.template]));this._legendStroke=r;let n=i.children.push(Le._new(i._root,{themeTags:["line","series","legend","marker","fill"]},[this.fills.template]));this._legendFill=n;let A=this._root.interfaceColors.get("disabled");if(r.states.create("disabled",{fill:A,stroke:A}),n.states.create("disabled",{fill:A,stroke:A}),this.bullets.length>0){let o=this.bullets.getIndex(0);if(o){let l=o(i._root,this,new ui(this,{legend:!0},{}));if(l){let c=l.get("sprite");c instanceof Le&&c.states.create("disabled",{fill:A,stroke:A}),c&&(c.setAll({tooltipText:void 0,tooltipHTML:void 0,focusable:void 0,focusableGroup:void 0,ariaLabel:void 0}),i.children.push(c),c.setAll({x:i.width()/2,y:i.height()/2}),i.events.on("boundschanged",()=>{c.setAll({x:i.width()/2,y:i.height()/2})}))}}}}}};qe.className="LineSeries";qe.classNames=ss.classNames.concat([qe.className]);var Xr=class extends qe{_afterNew(){super._afterNew(),this.set("maskContent",!1),this.bulletsContainer.set("maskContent",!1),this.bulletsContainer.set("mask",Le.new(this._root,{}))}_handleMaskBullets(){}getPoint(e,t){let i=this.get("yAxis"),s=this.get("xAxis"),r=i.get("renderer"),n=r.positionToCoordinate(t)+r.getPrivate("innerRadius",0),o=s.get("renderer").positionToAngle(e);return{x:n*ft(o),y:n*At(o)}}_endLine(e,t){this.get("connectEnds")&&t&&e.push(t)}_shouldInclude(e){let t=this.get("xAxis");return!(e<t.get("start")||e>t.get("end"))}_shouldShowBullet(e,t){let i=this.get("xAxis");return e<i.get("start")||e>i.get("end")?!1:this._showBullets}_positionBullet(e){let t=e.get("sprite");if(t){let i=t.dataItem,s=e.get("locationX",i.get("locationX",.5)),r=e.get("locationY",i.get("locationY",.5)),n=this.get("xAxis"),A=this.get("yAxis"),o=n.getDataItemPositionX(i,this._xField,s,this.get("vcx",1)),l=A.getDataItemPositionY(i,this._yField,r,this.get("vcy",1)),c=this.getPoint(o,l);this._shouldShowBullet(o,l)?(t.setPrivate("visible",!0),t.set("x",c.x),t.set("y",c.y)):t.setPrivate("visible",!1)}}};Xr.className="RadarLineSeries";Xr.classNames=qe.classNames.concat([Xr.className]);var pr=class extends qs{constructor(){super(...arguments),this._series=[],this._isPanning=!1,this.minorDataItems=[],this.labelsContainer=this.children.push(pe.new(this._root,{})),this.gridContainer=pe.new(this._root,{width:se,height:se}),this.topGridContainer=pe.new(this._root,{width:se,height:se}),this.bulletsContainer=this.children.push(pe.new(this._root,{isMeasured:!1,width:se,height:se,position:"absolute"})),this._rangesDirty=!1,this._panStart=0,this._panEnd=1,this._skipSync=!1,this.axisRanges=new Us,this._seriesAxisRanges=[],this._cursorPosition=-1,this._seriesValuesDirty=!1,this._seriesAdded=!1,this.axisHeader=this.children.push(pe.new(this._root,{themeTags:["axis","header"],position:"absolute",background:Tt.new(this._root,{themeTags:["header","background"],fill:this._root.interfaceColors.get("background")})})),this._bullets={}}_dispose(){this.gridContainer.dispose(),this.topGridContainer.dispose(),this.bulletsContainer.dispose(),this.labelsContainer.dispose(),this.axisHeader.dispose(),super._dispose()}_afterNew(){super._afterNew(),this.setPrivate("updateScrollbar",!0),this._disposers.push(this.axisRanges.events.onAll(t=>{if(t.type==="clear")K(t.oldValues,i=>{i.dispose()});else if(t.type==="push")this._processAxisRange(t.newValue,["range"]);else if(t.type==="setIndex")this._processAxisRange(t.newValue,["range"]);else if(t.type==="insertIndex")this._processAxisRange(t.newValue,["range"]);else if(t.type==="removeIndex")this.disposeDataItem(t.oldValue);else if(t.type==="moveIndex")this._processAxisRange(t.value,["range"]);else throw new Error("Unknown IStreamEvent type")}));let e=this.get("renderer");e&&(e.axis=this,e.processAxis()),this.children.push(e),this._createGhostLabel()}_createGhostLabel(){let t=this.get("renderer").makeLabel(new ui(this,void 0,{}),[]);t.adapters.disable("text"),t.setAll({opacity:0,tooltipText:void 0,tooltipHTML:void 0,interactive:!1}),t.events.disable(),this.ghostLabel=t}_updateFinals(e,t){}zoom(e,t,i,s){if(this.get("zoomable",!0))if(this._updateFinals(e,t),this.get("start")!==e||this.get("end")!=t){let r=this._sAnimation,n=this._eAnimation;e>t&&([e,t]=[t,e]);let A=this.get("maxDeviation",.5)*Math.min(1,t-e);e<-A&&(e=-A),t>1+A&&(t=1+A);let o=this.getPrivate("maxZoomFactor",this.get("maxZoomFactor",100)),l=o;W(i)||(i=this.get("interpolationDuration",0)),s||(s="end"),t===1&&e!==0&&(e<this.get("start",0)?s="start":s="end"),e===0&&t!==1&&(t>this.get("end",1)?s="end":s="start");let c=this.get("minZoomCount",0),h=this.dataItems;h&&h.length<c&&(c=h.length);let d=this.get("maxZoomCount",1/0);W(c)&&(o=l/c);let u=1;if(W(d)&&(u=l/d),e>t&&([e,t]=[t,e]),s==="start"?(d>0&&1/(t-e)<u&&(t=e+1/u),1/(t-e)>o&&(t=e+1/o),t>1&&t-e<1/o&&(e=t-1/o)):(d>0&&1/(t-e)<u&&(e=t-1/u),1/(t-e)>o&&(e=t-1/o),e<0&&t-e<1/o&&(t=e+1/o)),1/(t-e)>o&&(t=e+1/o),1/(t-e)>o&&(e=t-1/o),d!=null&&c!=null&&e==this.get("start")&&t==this.get("end")){let g=this.chart;g&&g._handleAxisSelection(this,!0)}if((r&&r.playing&&r.to==e||this.get("start")==e)&&(n&&n.playing&&n.to==t||this.get("end")==t))return;if(i>0){let g=this.get("interpolationEasing"),y,m;if(this.get("start")!=e&&(y=this.animate({key:"start",to:e,duration:i,easing:g})),this.get("end")!=t&&(m=this.animate({key:"end",to:t,duration:i,easing:g})),this._sAnimation=y,this._eAnimation=m,y)return y;if(m)return m}else this.set("start",e),this.set("end",t),this.root.events.once("frameended",()=>{this.markDirtyKey("start")})}else this._sAnimation&&this._sAnimation.stop(),this._eAnimation&&this._eAnimation.stop()}get series(){return this._series}_processAxisRange(e,t){e.setRaw("isRange",!0),this._createAssets(e,t),this._rangesDirty=!0,this._prepareDataItem(e);let i=e.get("above"),s=this.topGridContainer,r=e.get("grid");i&&r&&s.children.moveValue(r);let n=e.get("axisFill");i&&n&&s.children.moveValue(n)}_prepareDataItem(e,t){}markDirtyExtremes(){}markDirtySelectionExtremes(){}_calculateTotals(){}_updateAxisRanges(){this._bullets={},this.axisRanges.each(e=>{this._prepareDataItem(e)}),K(this._seriesAxisRanges,e=>{this._prepareDataItem(e)})}_prepareChildren(){super._prepareChildren();let e=this.ghostLabel;if(e&&(this.get("fixAxisSize")?e.set("visible",!0):e.set("visible",!1)),this.isDirty("start")||this.isDirty("end")){let i=this.chart;i&&i._updateCursor();let s=this.get("start",0),r=this.get("end",1),n=this.get("maxDeviation",.5)*Math.min(1,r-s);if(s<-n){let A=s+n;s=-n,this.setRaw("start",s),this.isDirty("end")&&this.setRaw("end",r-A)}if(r>1+n){let A=r-1-n;r=1+n,this.setRaw("end",r),this.isDirty("start")&&this.setRaw("start",s-A)}}let t=this.get("renderer");if(t._start=this.get("start"),t._end=this.get("end"),t._inversed=t.get("inversed",!1),t._axisLength=t.axisLength()/(t._end-t._start),t._updateLC(),this.isDirty("tooltip")){let i=this.get("tooltip");if(i){let s=t.get("themeTags");i.addTag("axis"),i.addTag(this.className.toLowerCase()),i._applyThemes(),s&&(i.set("themeTags",Fe(i.get("themeTags"),s)),i.label._applyThemes())}}}_updateTooltipBounds(){let e=this.get("tooltip");e&&this.get("renderer").updateTooltipBounds(e)}_updateBounds(){super._updateBounds(),this._updateTooltipBounds()}processChart(e){this.chart=e;let t=this.get("renderer");t.chart=e,e.gridContainer.children.push(this.gridContainer),e.topGridContainer.children.push(this.topGridContainer),e.axisHeadersContainer.children.push(this.axisHeader),this.on("start",()=>{e._handleAxisSelection(this)}),this.on("end",()=>{e._handleAxisSelection(this)}),e.plotContainer.onPrivate("width",()=>{this.markDirtySize()}),e.plotContainer.onPrivate("height",()=>{this.markDirtySize()}),e.processAxis(this)}hideDataItem(e){return this._toggleFHDataItem(e,!0),super.hideDataItem(e)}showDataItem(e){return this._toggleFHDataItem(e,!1),super.showDataItem(e)}_toggleFHDataItem(e,t){let i="forceHidden",s=e.get("label");s&&s.set(i,t);let r=e.get("grid");r&&r.set(i,t);let n=e.get("tick");n&&n.set(i,t);let A=e.get("axisFill");A&&A.set(i,t);let o=e.get("bullet");if(o){let l=o.get("sprite");l&&l.set(i,t)}}_toggleDataItem(e,t){let i=e.get("label"),s="visible";i&&i.setPrivate(s,t);let r=e.get("grid");r&&r.setPrivate(s,t);let n=e.get("tick");n&&n.setPrivate(s,t);let A=e.get("axisFill");A&&A.setPrivate(s,t);let o=e.get("bullet");if(o){let l=o.get("sprite");l&&l.setPrivate(s,t)}}_createAssets(e,t,i){var s,r,n;let A=this.get("renderer"),o="minor",l=e.get("label");if(!l)A.makeLabel(e,t);else{let d=l.get("themeTags"),u=!1;i?d?.indexOf(o)==-1&&(u=!0):d?.indexOf(o)!=-1&&(u=!0),u&&((s=l.parent)===null||s===void 0||s.children.removeValue(l),A.makeLabel(e,t),l.dispose(),A.labels.removeValue(l))}let c=e.get("grid");if(!c)A.makeGrid(e,t);else{let d=c.get("themeTags"),u=!1;i?d?.indexOf(o)==-1&&(u=!0):d?.indexOf(o)!=-1&&(u=!0),u&&((r=c.parent)===null||r===void 0||r.children.removeValue(c),A.makeGrid(e,t),c.dispose(),A.grid.removeValue(c))}let h=e.get("tick");if(!h)A.makeTick(e,t);else{let d=!1,u=h.get("themeTags");i?u?.indexOf(o)==-1&&(d=!0):u?.indexOf(o)!=-1&&(d=!0),d&&((n=h.parent)===null||n===void 0||n.children.removeValue(h),A.makeTick(e,t),h.dispose(),A.ticks.removeValue(h))}(!i&&!e.get("axisFill")||i&&!e.get("axisFill")&&this.get("minorAxisFillsEnabled"))&&A.makeAxisFill(e,t),this._processBullet(e)}_processBullet(e){let t=e.get("bullet"),i=this.get("bullet");if(!t&&i&&!e.get("isRange")&&(t=i(this._root,this,e)),t){t.axis=this;let s=t.get("sprite");s&&(s._setDataItem(e),e.setRaw("bullet",t),s.parent||this.bulletsContainer.children.push(s))}}_afterChanged(){super._afterChanged();let e=this.chart;e&&(e._updateChartLayout(),e.axisHeadersContainer.markDirtySize()),this.get("renderer")._updatePositions(),this._seriesAdded=!1}disposeDataItem(e){super.disposeDataItem(e);let t=this.get("renderer"),i=e.get("label");i&&(t.labels.removeValue(i),i.dispose());let s=e.get("tick");s&&(t.ticks.removeValue(s),s.dispose());let r=e.get("grid");r&&(t.grid.removeValue(r),r.dispose());let n=e.get("axisFill");n&&(t.axisFills.removeValue(n),n.dispose());let A=e.get("bullet");A&&A.dispose()}_updateGhost(){this.setPrivate("cellWidth",this.getCellWidthPosition()*this.get("renderer").axisLength());let e=this.ghostLabel;if(e){if(!e.isHidden()){let s=e.localBounds(),r=Math.ceil(s.right-s.left),n=e.get("text");K(this.dataItems,A=>{let o=A.get("label");if(o&&!o.isHidden()){let l=o.localBounds();Math.ceil(l.right-l.left)>r&&(n=o.text._getText())}}),e.set("text",n)}let t=this.get("start",0),i=this.get("end",1);this.get("renderer").updateLabel(e,t+(i-t)*.5)}}_handleCursorPosition(e,t){e=this.get("renderer").toAxisPosition(e),this._cursorPosition=e,this._snapToSeries=t,this.updateTooltip()}updateTooltip(){let e=this._snapToSeries,t=this._cursorPosition,i=this.get("tooltip"),s=this.get("renderer");W(t)&&(K(this.series,r=>{if(r.get("baseAxis")===this){let n=this.getSeriesItem(r,t,this.get("tooltipLocation"));e&&e.indexOf(r)!=-1?(r.updateLegendMarker(n),r.updateLegendValue(n),r._settings.tooltipDataItem=n):(r.showDataItemTooltip(n),r.setRaw("tooltipDataItem",n))}}),this.get("snapTooltip")&&(t=this.roundAxisPosition(t,this.get("tooltipLocation",.5))),this.setPrivateRaw("tooltipPosition",t),i&&(s.updateTooltipBounds(i),Ni(t)?i.hide(0):(this._updateTooltipText(i,t),s.positionTooltip(i,t),t<this.get("start",0)||t>this.get("end",1)?i.hide(0):i.show(0))))}_updateTooltipText(e,t){e.label.set("text",this.getTooltipText(t))}roundAxisPosition(e,t){return e}_handleSeriesRemoved(){}handleCursorShow(){let e=this.get("tooltip");e&&e.show()}handleCursorHide(){let e=this.get("tooltip");e&&e.hide()}processSeriesDataItem(e,t){}_clearDirty(){super._clearDirty(),this._sizeDirty=!1,this._rangesDirty=!1}coordinateToPosition(e){let t=this.get("renderer");return t.toAxisPosition(e/t.axisLength())}toAxisPosition(e){return this.get("renderer").toAxisPosition(e)}toGlobalPosition(e){return this.get("renderer").toGlobalPosition(e)}fixPosition(e){return this.get("renderer").fixPosition(e)}shouldGap(e,t,i,s){return!1}createAxisRange(e){return this.axisRanges.push(e)}_groupSeriesData(e){}getCellWidthPosition(){return .05}};pr.className="Axis";pr.classNames=qs.classNames.concat([pr.className]);var at=class extends pr{constructor(){super(...arguments),this._dirtyExtremes=!1,this._dirtySelectionExtremes=!1,this._dseHandled=!1,this._deltaMinMax=1,this._baseValue=0,this._minLogAdjusted=1}markDirtyExtremes(){this._dirtyExtremes=!0,this.markDirty()}markDirtySelectionExtremes(){this._dirtySelectionExtremes=!0,this.markDirty()}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["axis"]),this.setPrivateRaw("name","value"),this.addTag("value"),super._afterNew()}_prepareChildren(){var e;if(super._prepareChildren(),this.isDirty("syncWithAxis")){this._prevSettings.syncWithAxis&&this._syncDp&&this._syncDp.dispose();let s=this.get("syncWithAxis");s&&(this._syncDp=new zt([s.onPrivate("selectionMinFinal",()=>{this._dirtySelectionExtremes=!0}),s.onPrivate("selectionMaxFinal",()=>{this._dirtySelectionExtremes=!0})]))}let t=!1;if((this.isDirty("min")||this.isDirty("max")||this.isDirty("maxPrecision")||this.isDirty("numberFormat"))&&(t=!0,(e=this.ghostLabel)===null||e===void 0||e.set("text","")),(this._sizeDirty||this._dirtyExtremes||this._valuesDirty||t||this.isPrivateDirty("width")||this.isPrivateDirty("height")||this.isDirty("extraMin")||this.isDirty("extraMax")||this.isDirty("logarithmic")||this.isDirty("treatZeroAs")||this.isDirty("baseValue")||this.isDirty("strictMinMax")||this.isDirty("strictMinMaxSelection"))&&(this._getMinMax(),this._dirtyExtremes=!1),this._handleSizeDirty(),this._dirtySelectionExtremes&&!this._isPanning&&this.get("autoZoom",!0)){let i=this.chart,s=!1;if(i){let r=this.get("renderer").getPrivate("letter");r=="Y"?i.xAxes.each(n=>{n.className!="ValueAxis"&&(s=!0)}):r=="X"&&i.yAxes.each(n=>{n.className!="ValueAxis"&&(s=!0)})}s&&this._getSelectionMinMax(),this._dirtySelectionExtremes=!1}this._groupData(),(this._sizeDirty||this._valuesDirty||this.isDirty("start")||this.isDirty("end")||this.isPrivateDirty("min")||this.isPrivateDirty("selectionMax")||this.isPrivateDirty("selectionMin")||this.isPrivateDirty("max")||this.isPrivateDirty("step")||this.isPrivateDirty("width")||this.isPrivateDirty("height")||this.isDirty("logarithmic"))&&(this._handleRangeChange(),this._prepareAxisItems(),this._updateAxisRanges()),this._baseValue=this.baseValue()}_handleSizeDirty(){this._sizeDirty&&!this._dseHandled&&(this._dirtySelectionExtremes=!0,this._dseHandled=!0,(this.getPrivate("selectionMinFinal")!=this.getPrivate("selectionMin")||this.getPrivate("selectionMaxFinal")!=this.getPrivate("selectionMax"))&&(this._dirtySelectionExtremes=!1))}_clearDirty(){super._clearDirty(),this._dseHandled=!1}_groupData(){}_formatText(e){let t=this.get("numberFormat"),i=this.getNumberFormatter(),s="";return t?s=i.format(e,t):s=i.format(e,void 0,this.getPrivate("stepDecimalPlaces")),s}_prepareAxisItems(){let e=this.getPrivate("min"),t=this.getPrivate("max");if(W(e)&&W(t)){let i=this.get("logarithmic"),s=this.getPrivate("step"),r=this.getPrivate("selectionMin"),n=this.getPrivate("selectionMax")+s,A=r-s,o=1,l=e;if(i){if(A=this._minLogAdjusted,A<r)for(;A<r;)A+=s;if(l=A,l<=0){let T=this._minRealLog;W(T)||(T=1),l=Math.pow(10,Math.log(T)*Math.LOG10E),s<1&&(W(this._minRealLog)?l=this._minRealLog:l=Math.pow(10,-50))}o=Math.log(n-s)*Math.LOG10E-Math.log(l)*Math.LOG10E,o>2&&(A=Math.pow(10,Math.log(l)*Math.LOG10E-50))}let c=this.get("renderer"),h=c.get("minorLabelsEnabled"),d=c.get("minorGridEnabled",h),u=Math.pow(10,Math.floor(Math.log(Math.abs(s))*Math.LOG10E)),g=Math.round(s/u),y=2;jt(g/5,10)%1==0&&(y=5),jt(g/10,10)%1==0&&(y=10);let m=s/y,b=0,B=0,w=-1/0,_=this.get("renderer").gridCount();for(;A<n;){let T;this.dataItems.length<b+1?(T=new ui(this,void 0,{}),this._dataItems.push(T),this.processDataItem(T)):T=this.dataItems[b],this._createAssets(T,[]),this._toggleDataItem(T,!0),T.setRaw("value",A);let Q=T.get("label");Q&&Q.set("text",this._formatText(A)),this._prepareDataItem(T);let U=A;if(!i)U+=s;else if(o>2){let O=Math.max(1,_),D=Math.max(1,Math.ceil(o/O)),k=Math.log(l)*Math.LOG10E+(b+1)*D-50;U=Math.pow(10,k)}else U+=s;if(d){let O=A+m;for(i&&(o>2&&(m=this._adjustMinMax(A,U,10).step),O=A+m);O<U-s*1e-11;){let D;this.minorDataItems.length<B+1?(D=new ui(this,void 0,{}),this.minorDataItems.push(D),this.processDataItem(D)):D=this.minorDataItems[B],this._createAssets(D,["minor"],!0),this._toggleDataItem(D,!0),D.setRaw("value",O);let k=D.get("label");k&&(h?k.set("text",this._formatText(O)):k.setPrivate("visible",!1)),this._prepareDataItem(D),O+=m,B++}}if(A=U,w==A)break;let E=Math.pow(10,Math.floor(Math.log(Math.abs(s))*Math.LOG10E));if(E<1&&!i){let O=Math.round(Math.abs(Math.log(Math.abs(E))*Math.LOG10E))+2;A=jt(A,O)}b++,i&&o<=2&&A-s<s&&(A=s),w=A}for(let T=b;T<this.dataItems.length;T++)this._toggleDataItem(this.dataItems[T],!1);for(let T=B;T<this.minorDataItems.length;T++)this._toggleDataItem(this.minorDataItems[T],!1);K(this.series,T=>{T.inited&&T._markDirtyAxes()}),this._updateGhost()}}_prepareDataItem(e,t){let i=this.get("renderer"),s=e.get("value"),r=e.get("endValue"),n=this.valueToPosition(s),A=n,o=this.valueToPosition(s+this.getPrivate("step"));W(r)&&(A=this.valueToPosition(r),o=A),e.get("isRange")&&r==null&&(o=n);let l=A,c=e.get("labelEndValue");c!=null&&(l=this.valueToPosition(c)),i.updateLabel(e.get("label"),n,l,t);let h=e.get("grid");if(i.updateGrid(h,n,A),h&&(s==this.get("baseValue",0)?(h.addTag("base"),h._applyThemes()):h.hasTag("base")&&(h.removeTag("base"),h._applyThemes())),i.updateTick(e.get("tick"),n,l,t),i.updateFill(e.get("axisFill"),n,o),this._processBullet(e),i.updateBullet(e.get("bullet"),n,A),!e.get("isRange")){let d=this.get("fillRule");d&&d(e)}}_handleRangeChange(){let e=this.positionToValue(this.get("start",0)),t=this.positionToValue(this.get("end",1)),i=this.get("renderer").gridCount(),s=this._adjustMinMax(e,t,i,!0),r=$h(s.step);this.setPrivateRaw("stepDecimalPlaces",r),e=jt(e,r),t=jt(t,r),s=this._adjustMinMax(e,t,i,!0);let n=s.step;e=s.min,t=s.max,(this.getPrivate("selectionMin")!==e||this.getPrivate("selectionMax")!==t||this.getPrivate("step")!==n)&&(this.setPrivateRaw("selectionMin",e),this.setPrivateRaw("selectionMax",t),this.setPrivateRaw("step",n))}positionToValue(e){let t=this.getPrivate("min"),i=this.getPrivate("max");return this.get("logarithmic")?Math.pow(Math.E,(e*(Math.log(i)*Math.LOG10E-Math.log(t)*Math.LOG10E)+Math.log(t)*Math.LOG10E)/Math.LOG10E):e*(i-t)+t}valueToPosition(e){let t=this.getPrivate("min"),i=this.getPrivate("max");if(this.get("logarithmic")){if(e<=0){let s=this.get("treatZeroAs");W(s)&&(e=s)}return(Math.log(e)*Math.LOG10E-Math.log(t)*Math.LOG10E)/(Math.log(i)*Math.LOG10E-Math.log(t)*Math.LOG10E)}else return(e-t)/(i-t)}valueToFinalPosition(e){let t=this.getPrivate("minFinal"),i=this.getPrivate("maxFinal");if(this.get("logarithmic")){if(e<=0){let s=this.get("treatZeroAs");W(s)&&(e=s)}return(Math.log(e)*Math.LOG10E-Math.log(t)*Math.LOG10E)/(Math.log(i)*Math.LOG10E-Math.log(t)*Math.LOG10E)}else return(e-t)/(i-t)}getX(e,t,i){e=i+(e-i)*t;let s=this.valueToPosition(e);return this._settings.renderer.positionToCoordinate(s)}getY(e,t,i){e=i+(e-i)*t;let s=this.valueToPosition(e);return this._settings.renderer.positionToCoordinate(s)}getDataItemCoordinateX(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionX(e,t,i,s))}getDataItemPositionX(e,t,i,s){let r=e.get(t);if(e.get("stackToItemX")){let A=e.component;r=r*s+A.getStackedXValueWorking(e,t)}else r=this._baseValue+(r-this._baseValue)*s;return this.valueToPosition(r)}getDataItemCoordinateY(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionY(e,t,i,s))}getDataItemPositionY(e,t,i,s){let r=e.get(t);if(e.get("stackToItemY")){let A=e.component;r=r*s+A.getStackedYValueWorking(e,t)}else r=this._baseValue+(r-this._baseValue)*s;return this.valueToPosition(r)}basePosition(){return this.valueToPosition(this.baseValue())}baseValue(){let e=Math.min(this.getPrivate("minFinal",-1/0),this.getPrivate("selectionMin",-1/0)),t=Math.max(this.getPrivate("maxFinal",1/0),this.getPrivate("selectionMax",1/0)),i=this.get("baseValue",0);return i<e&&(i=e),i>t&&(i=t),i}cellEndValue(e){return e}fixSmallStep(e){return 1+e===1?(e*=2,this.fixSmallStep(e)):e}_fixMin(e){return e}_fixMax(e){return e}_calculateTotals(){if(this.get("calculateTotals")){let e=this.series[0];if(e){let t=e.startIndex();if(e.dataItems.length>0){t>0&&t--;let i=e.endIndex();i<e.dataItems.length&&i++;let s,r;e.get("yAxis")==this?(s="valueY",r="vcy"):e.get("xAxis")==this&&(s="valueX",r="vcx");let n=s+"Working";if(s){let A=this.series.length,o=[],l=[];for(let g=0;g<A;g++){let y=this.series[g];y.get("excludeFromTotal")||(o.push(y),l.push(y.get(r)))}let c=o.length,h=s+"Total",d=s+"Sum",u=s+"TotalPercent";for(let g=t;g<i;g++){let y=0,m=0;for(let b=0;b<c;b++){let B=o[b].dataItems[g];if(B){let w=B.get(n)*l[b];Ni(w)||(y+=w,m+=Math.abs(w))}}for(let b=0;b<c;b++){let B=o[b].dataItems[g];if(B){let w=B.get(n)*l[b];Ni(w)||(B.set(h,m),B.set(d,y),B.set(u,m==0?0:w/m*100))}}}}}}}}_getSelectionMinMax(){let e=this.getPrivate("minFinal"),t=this.getPrivate("maxFinal"),i=this.get("min"),s=this.get("max"),r=this.get("extraMin",0),n=this.get("extraMax",0);this.get("logarithmic")&&(this.get("extraMin")==null&&(r=.1),this.get("extraMax")==null&&(n=.2));let A=this.get("renderer").gridCount(),o=this.get("strictMinMaxSelection"),l=this.get("strictMinMax");if(W(e)&&W(t)){let c=t,h=e;if(K(this.series,_=>{if(!_.get("ignoreMinMax")){let T,Q,U=_.getPrivate("outOfSelection");if(_.get("xAxis")===this){if(!U){let E=_.getPrivate("minX"),O=_.getPrivate("maxX");(_.startIndex()!=0||_.endIndex()!=_.dataItems.length)&&(E=void 0,O=void 0),T=_.getPrivate("selectionMinX",E),Q=_.getPrivate("selectionMaxX",O)}}else if(_.get("yAxis")===this&&!U){let E=_.getPrivate("minY"),O=_.getPrivate("maxY");(_.startIndex()!=0||_.endIndex()!=_.dataItems.length)&&(E=void 0,O=void 0),T=_.getPrivate("selectionMinY",E),Q=_.getPrivate("selectionMaxY",O)}!_.isHidden()&&!_.isShowing()&&(W(T)&&(c=Math.min(c,T)),W(Q)&&(h=Math.max(h,Q)))}}),this.axisRanges.each(_=>{if(_.get("affectsMinMax")){let T=_.get("value");T!=null&&(c=Math.min(c,T),h=Math.max(h,T)),T=_.get("endValue"),T!=null&&(c=Math.min(c,T),h=Math.max(h,T))}}),c>h&&([c,h]=[h,c]),W(i)?l?c=i:c=e:l&&W(this._minReal)&&(c=this._minReal),W(s)?l?h=s:h=t:l&&W(this._maxReal)&&(h=this._maxReal),c===h){let _=c;if(c-=this._deltaMinMax,h+=this._deltaMinMax,c<e){let Q=_-e;Q==0&&(Q=this._deltaMinMax),c=_-Q,h=_+Q,l=!0}let T=this._adjustMinMax(c,h,A,l);c=T.min,h=T.max}let d=c,u=h,g=h-c;c-=g*r,h+=g*n;let y=this._adjustMinMax(c,h,A);c=y.min,h=y.max,c=Bt(c,e,t),h=Bt(h,e,t),y=this._adjustMinMax(c,h,A,!0),l||(c=y.min,h=y.max);let m=this.get("syncWithAxis");if(m&&(y=this._syncAxes(c,h,y.step,m.getPrivate("selectionMinFinal",m.getPrivate("minFinal",0)),m.getPrivate("selectionMaxFinal",m.getPrivate("maxFinal",1)),m.getPrivate("selectionStepFinal",m.getPrivate("step",1))),c=y.min,h=y.max),l&&!m&&(W(i)&&(c=Math.max(c,i)),W(s)&&(h=Math.min(h,s))),o&&!m&&(c=d-(u-d)*r,h=u+(u-d)*n),l&&!m){W(i)?c=i:c=d,W(s)?h=s:h=u,h-c<=1e-8&&(c-=this._deltaMinMax,h+=this._deltaMinMax);let _=h-c;c-=_*r,h+=_*n}this.get("logarithmic")&&(c<=0&&(c=d*(1-Math.min(r,.99))),c<e&&(c=e),h>t&&(h=t));let b=Math.min(20,Math.ceil(Math.log(this.getPrivate("maxZoomFactor",100)+1)/Math.LN10)+2),B=jt(this.valueToFinalPosition(c),b),w=jt(this.valueToFinalPosition(h),b);this.setPrivateRaw("selectionMinFinal",c),this.setPrivateRaw("selectionMaxFinal",h),this.setPrivateRaw("selectionStepFinal",y.step),this.zoom(B,w)}}_getMinMax(){let e=this.get("min"),t=this.get("max"),i=1/0,s=-1/0,r=this.get("extraMin",0),n=this.get("extraMax",0);this.get("logarithmic")&&(this.get("strictMinMax")||(this.get("extraMin")==null&&(r=.1),this.get("extraMax")==null&&(n=.2)));let A=1/0;if(K(this.series,w=>{if(!w.get("ignoreMinMax")){let _,T;if(w.get("xAxis")===this?(_=w.getPrivate("minX"),T=w.getPrivate("maxX")):w.get("yAxis")===this&&(_=w.getPrivate("minY"),T=w.getPrivate("maxY")),W(_)&&W(T)){i=Math.min(i,_),s=Math.max(s,T);let Q=T-_;Q<=0&&(Q=Math.abs(T/100)),Q<A&&(A=Q)}}}),this.axisRanges.each(w=>{if(w.get("affectsMinMax")){let _=w.get("value");_!=null&&(i=Math.min(i,_),s=Math.max(s,_)),_=w.get("endValue"),_!=null&&(i=Math.min(i,_),s=Math.max(s,_))}}),this.get("logarithmic")){let w=this.get("treatZeroAs");W(w)&&i<=0&&(i=w),i<=0&&new Error("Logarithmic value axis can not have values <= 0.")}if(i===0&&s===0&&(s=.9,i=-.9),W(e)&&(i=e),W(t)&&(s=t),i===1/0||s===-1/0){this.setPrivate("minFinal",void 0),this.setPrivate("maxFinal",void 0);return}i>s&&([i,s]=[s,i]);let o=i,l=s,c=this.adapters.fold("min",i),h=this.adapters.fold("max",s);this._minRealLog=i,W(c)&&(i=c),W(h)&&(s=h),i=this._fixMin(i),s=this._fixMax(s),s-i<=1/Math.pow(10,15)&&(s-i!==0?this._deltaMinMax=(s-i)/2:this._getDelta(s),i-=this._deltaMinMax,s+=this._deltaMinMax),i-=(s-i)*r,s+=(s-i)*n,this.get("logarithmic")&&(i<0&&o>=0&&(i=0),s>0&&l<=0&&(s=0)),this._minReal=i,this._maxReal=s;let d=this.get("strictMinMax"),u=this.get("strictMinMaxSelection",!1);u&&(d=u);let g=d;W(t)&&(g=!0);let y=this.get("renderer").gridCount(),m=this._adjustMinMax(i,s,y,g);if(i=m.min,s=m.max,m=this._adjustMinMax(i,s,y,!0),i=m.min,s=m.max,d){W(e)?i=e:i=this._minReal,W(t)?s=t:s=this._maxReal,s-i<=1e-8&&(i-=this._deltaMinMax,s+=this._deltaMinMax);let w=s-i;i-=w*r,s+=w*n}c=this.adapters.fold("min",i),h=this.adapters.fold("max",s),W(c)&&(i=c),W(h)&&(s=h),A==1/0&&(A=s-i);let b=Math.round(Math.abs(Math.log(Math.abs(s-i))*Math.LOG10E))+5;i=jt(i,b),s=jt(s,b);let B=this.get("syncWithAxis");if(B&&(m=this._syncAxes(i,s,m.step,B.getPrivate("minFinal",B.getPrivate("min",0)),B.getPrivate("maxFinal",B.getPrivate("max",1)),B.getPrivate("step",1)),i=m.min,s=m.max),this.setPrivateRaw("maxZoomFactor",Math.max(1,Math.ceil((s-i)/A*this.get("maxZoomFactor",100)))),this._fixZoomFactor(),this.get("logarithmic")&&(this._minLogAdjusted=i,i=this._minReal,s=this._maxReal,i<=0&&(i=o*(1-Math.min(r,.99)))),W(i)&&W(s)&&(this.getPrivate("minFinal")!==i||this.getPrivate("maxFinal")!==s)){this.setPrivate("minFinal",i),this.setPrivate("maxFinal",s),this._saveMinMax(i,s);let w=this.get("interpolationDuration",0),_=this.get("interpolationEasing");this.animatePrivate({key:"min",to:i,duration:w,easing:_}),this.animatePrivate({key:"max",to:s,duration:w,easing:_})}}_fixZoomFactor(){}_getDelta(e){let t=Math.log(Math.abs(e))*Math.LOG10E,i=Math.pow(10,Math.floor(t));i=i/10,this._deltaMinMax=i}_saveMinMax(e,t){}_adjustMinMax(e,t,i,s){i<=1&&(i=1),i=Math.round(i);let r=e,n=t,A=t-e;A===0&&(A=Math.abs(t));let o=Math.log(Math.abs(A))*Math.LOG10E,l=Math.pow(10,Math.floor(o));l=l/10;let c=l;s&&(c=0),s?(e=Math.floor(e/l)*l,t=Math.ceil(t/l)*l):(e=Math.ceil(e/l)*l-c,t=Math.floor(t/l)*l+c),e<0&&r>=0&&(e=0),t>0&&n<=0&&(t=0),o=Math.log(Math.abs(A))*Math.LOG10E,l=Math.pow(10,Math.floor(o)),l=l/100;let h=Math.ceil(A/i/l)*l,d=Math.pow(10,Math.floor(Math.log(Math.abs(h))*Math.LOG10E)),u=Math.ceil(h/d);u>5?u=10:u<=5&&u>2&&(u=5),h=Math.ceil(h/(d*u))*d*u;let g=this.get("maxPrecision");if(W(g)){let B=Cf(h,g);g<Number.MAX_VALUE&&h!==B&&(h=B,h==0&&(h=1))}let y=0;d<1&&(y=Math.round(Math.abs(Math.log(Math.abs(d))*Math.LOG10E))+1,h=jt(h,y));let m=Math.floor(e/h);e=jt(h*m,y);let b;return s?b=Math.floor(t/h):b=Math.ceil(t/h),b===m&&b++,t=jt(h*b,y),t<n&&(t=t+h),e>r&&(e=e-h),h=this.fixSmallStep(h),{min:e,max:t,step:h}}getTooltipText(e,t){let i=this.get("tooltipNumberFormat",this.get("numberFormat")),s=this.getNumberFormatter(),r=this.get("extraTooltipPrecision",0),n=this.getPrivate("stepDecimalPlaces",0)+r,A=jt(this.positionToValue(e),n);return i?s.format(A,i):s.format(A,void 0,n)}getSeriesItem(e,t){let i=this.getPrivate("name")+this.get("renderer").getPrivate("letter"),s=this.positionToValue(t),r,n;if(K(e.dataItems,(A,o)=>{let l=Math.abs(A.get(i)-s);(r===void 0||l<n)&&(r=o,n=l)}),r!=null)return e.dataItems[r]}zoomToValues(e,t,i){let s=this.getPrivate("minFinal",this.getPrivate("min",0)),r=this.getPrivate("maxFinal",this.getPrivate("max",1));this.getPrivate("min")!=null&&this.getPrivate("max")!=null&&this.zoom((e-s)/(r-s),(t-s)/(r-s),i)}_syncAxes(e,t,i,s,r,n){if(this.get("syncWithAxis")){let o=Math.round((r-s)/n);if(o>0)if(this.get("syncZeros")&&s<=0&&r>=0){let l=Math.round((0-s)/n),c=o-l,h=0;l>0&&e<0&&(h=Math.abs(e)/l),c>0&&t>0&&(h=Math.max(h,t/c)),h==0&&(h=(t-e)/o),i=this._niceStep(h),e=-i*l,t=i*c}else{let l=(t-e)/o;i=this._niceStep(l);let c=Math.floor(e/i)*i,h=c+i*o;h<t&&(c=Math.ceil(t/i)*i-i*o,h=c+i*o),e>=0&&c<0&&(c=0,h=i*o),t<=0&&h>0&&(h=0,c=-(i*o)),e=c,t=h}}return{min:e,max:t,step:i}}_niceStep(e){let t=Math.pow(10,Math.floor(Math.log(Math.abs(e))*Math.LOG10E)),i=e/t;i<=1?i=1:i<=2?i=2:i<=5?i=5:i=10;let s=i*t,r=this.get("maxPrecision");if(W(r)){let n=Cf(s,r);r<Number.MAX_VALUE&&s!==n&&(s=n,s==0&&(s=1))}return s}getCellWidthPosition(){let e=this.getPrivate("selectionMax",this.getPrivate("max")),t=this.getPrivate("selectionMin",this.getPrivate("min"));return W(e)&&W(t)?this.getPrivate("step",1)/(e-t):.05}nextPosition(e){e==null&&(e=1),this.get("renderer").getPrivate("letter")=="Y"&&(e*=-1);let t=this.positionToValue(this.getPrivate("tooltipPosition",0));return t+=this.getPrivate("step",1)*e,t=Bt(t,this.getPrivate("selectionMin",0),this.getPrivate("selectionMax",1)),this.toGlobalPosition(this.valueToPosition(t))}};at.className="ValueAxis";at.classNames=pr.classNames.concat([at.className]);var Gt=class a extends pr{constructor(){super(...arguments),this._frequency=1,this._itemMap={}}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["axis"]),this.fields.push("category","id","cellSize"),this.setPrivateRaw("name","category"),this.addTag("category"),super._afterNew()}_afterDataChange(){super._afterDataChange();let e=this.dataItems.length;e>0&&this.setPrivateRaw("maxZoomFactor",e),this.setPrivateRaw("startIndex",Math.min(this.getPrivate("startIndex",0),e)),this.setPrivateRaw("endIndex",Math.min(this.getPrivate("endIndex",e),1))}_prepareChildren(){super._prepareChildren();let e=this.dataItems.length,t=0;this._valuesDirty&&(this._itemMap={},K(this.dataItems,n=>{n.setRaw("index",t),this._itemMap[n.get("category")]=n,t++}),this.setPrivateRaw("maxZoomFactor",e));let i=this.get("start",0),s=this.get("end",1),r=this._getIndices(i,s);this.setPrivateRaw("startIndex",r.startIndex),this.setPrivateRaw("endIndex",r.endIndex),(this._sizeDirty||this._valuesDirty||this.isDirty("start")||this.isDirty("end")||this.isPrivateDirty("endIndex")||this.isPrivateDirty("startIndex")||this.isPrivateDirty("width")||this.isPrivateDirty("height"))&&this.dataItems.length>0&&(this._handleRangeChange(),this._prepareAxisItems(),this._updateAxisRanges())}adjustZoom(){let e=this.dataItems.length;if(e>1){let t=this.get("maxZoomCount",this.dataItems.length),i=this.get("minZoomCount",1),s=0,r=this.getPrivate("startIndex",0),n=this.getPrivate("endIndex",0),A=this._sAnimation,o=this._eAnimation,l=this.get("start",0),c=!1;A&&!A.stopped&&(l=Number(A.to),c=!0);let h=this.get("end",1);if(o&&!o.stopped&&(h=Number(o.to),c=!0),c){let d=this._getIndices(l,h);r=d.startIndex,n=d.endIndex}for(let d=r;d<n;d++){let u=this.dataItems[d];s+=u.get("finalCellSize",1)}if(s<=i){let d=0;for(let u=r;u<e;u++){let g=this.dataItems[u];if(d+=g.get("finalCellSize",1),n=u+1,d>=i)break}if(d<i)for(let u=r-1;u>=0;u--){let g=this.dataItems[u];if(d+=g.get("finalCellSize",1),r=u,d>=i)break}this.zoomToIndexes(r,n)}else if(s>=t){let d=s;for(let u=n-1;u>=r;u--){let g=this.dataItems[u];if(d-=g.get("finalCellSize",1),d<=t){n=u+1;break}}this.zoomToIndexes(r,n)}}}_handleRangeChange(){K(this.series,e=>{let t=this.dataItems[this.startIndex()].get("category"),i=this.dataItems[this.endIndex()-1].get("category"),s=e.get("baseAxis"),r=e.get("xAxis"),n=e.get("yAxis");if(r instanceof a&&n instanceof a)e._markDirtyAxes();else if(s===this){let A,o,l=n;if(r===s?(e.get("categoryXField")&&(A="categoryX"),e.get("openCategoryXField")&&(o="openCategoryX")):n===s&&(e.get("categoryYField")&&(A="categoryY"),e.get("openCategoryYField")&&(o="openCategoryY"),l=r),l instanceof at&&(A||o)){let d=function(m,b,B,w,_,T){let Q,U=b.categoryToIndex(_);for(;!Q&&U>=0&&U<b.dataItems.length;){let E=b.dataItems[U].get("category");if(T=="previous")for(let O=m.dataItems.length-1;O>=0;O--){let D=m.dataItems[O];if(B&&D.get(B)===E){Q=D;break}if(w&&D.get(w)===E){Q=D;break}}else for(let O=0,D=m.dataItems.length;O<D;O++){let k=m.dataItems[O];if(B&&k.get(B)===E){Q=k;break}if(w&&k.get(w)===E){Q=k;break}}Q||(U+=T==="previous"?-1:1)}return Q},c,h;c=d(e,this,A,o,t,"next"),h=d(e,this,A,o,i,"previous");let u=0,g=e.dataItems.length;c&&(u=e.dataItems.indexOf(c)),h&&(g=e.dataItems.indexOf(h)+1),e.setPrivate("startIndex",u),e.setPrivate("endIndex",g);let y=!1;for(let m=u;m<g;m++){let b=e.dataItems[m];if(K(e.__valueXShowFields,B=>{b.get(B)!=null&&(y=!0)}),K(e.__valueYShowFields,B=>{b.get(B)!=null&&(y=!0)}),y)break}e.setPrivate("outOfSelection",!y)}e._markDirtyAxes()}})}_prepareAxisItems(){var e;let t=this.get("renderer"),i=this.dataItems.length,s=this.startIndex();s>0&&s--;let r=this.endIndex();r<i&&r++;let n=t.get("minorLabelsEnabled"),A=t.get("minorGridEnabled",n),o=t.axisLength()/Math.max(t.get("minGridDistance"),1),l=Math.max(1,Math.min(i,Math.ceil((r-s)/o)));s=Math.floor(s/l)*l,this._frequency=l;for(let h=0;h<i;h++)this._toggleDataItem(this.dataItems[h],!1);let c=this.dataItems[s].get("index",0);for(let h=s;h<r;h=h+l){let d=this.dataItems[h];this._createAssets(d,[]),this._toggleDataItem(d,!0);let u=l;A&&(u=1),this._prepareDataItem(d,c,u),c++}if(t.get("minorGridEnabled"))for(let h=s;h<r;h++){let d=this.dataItems[h];h%l!=0&&(this._createAssets(d,["minor"],!0),this._toggleDataItem(d,!0),this._prepareDataItem(d,0,1),n||(e=d.get("label"))===null||e===void 0||e.setPrivate("visible",!1))}this._updateGhost()}_prepareDataItem(e,t,i){let s=this.get("renderer"),r=e.get("categoryLocation",0),n=e.get("endCategoryLocation",1),A=e.get("index");W(A)||(A=this.categoryToIndex(e.get("category")));let o=this.indexToPosition(A,r),l=e.get("endCategory"),c;l?(c=this.categoryToIndex(l),W(c)||(c=A)):c=A;let h=this.indexToPosition(c,n),d,u;if(e.get("isRange")){if(d=c,!W(A)){this._toggleDataItem(e,!1);return}}else d=A+this._frequency-1;u=this.indexToPosition(d,n),s.updateLabel(e.get("label"),o,h,i),s.updateGrid(e.get("grid"),o,h),s.updateTick(e.get("tick"),o,h,i),s.updateFill(e.get("axisFill"),o,u),this._processBullet(e),s.updateBullet(e.get("bullet"),o,h);let g=this.get("fillRule");g&&g(e,t)}startIndex(){let e=this.dataItems.length;return Math.min(Math.max(this.getPrivate("startIndex",0),0),e-1)}endIndex(){let e=this.dataItems.length;return Math.max(1,Math.min(this.getPrivate("endIndex",e),e))}baseValue(){}basePosition(){return 0}getX(e){let t=this._itemMap[e];return t?this._settings.renderer.positionToCoordinate(this.indexToPosition(t.get("index",0))):NaN}getY(e){let t=this._itemMap[e];return t?this._settings.renderer.positionToCoordinate(this.indexToPosition(t.get("index",0))):NaN}getDataItemPositionX(e,t,i,s){let r=e.get(t),n=this._itemMap[r];return n?this.indexToPosition(n.get("index",0),i):NaN}getDataItemCoordinateX(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionX(e,t,i,s))}getDataItemPositionY(e,t,i,s){let r=e.get(t),n=this._itemMap[r];return n?this.indexToPosition(n.get("index",0),i):NaN}getDataItemCoordinateY(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionY(e,t,i,s))}indexToPosition(e,t,i){let s=this.dataItems.length,r=0;if(s==0||(e>=s&&(e=s-1,t=1),W(t)||(t=.5),!W(e)))return 0;let n=this.get("startLocation",0),A=this.get("endLocation",1);if(!this.get("cellSizeField"))s-=n,s-=1-A,r=(e+t-n)/s;else{let o=i?"finalCellSize":"cellSize",l=this.dataItems,c=0;K(this.dataItems,u=>{c+=u.get(o,1)}),c-=n*l[0].get(o,1),c-=(1-A)*l[l.length-1].get(o,1);let h=0;for(let u=0;u<e;u++)h+=l[u].get(o,1);let d=l[e].get(o,1);r=(h+t*d-n*l[0].get(o,1))/c}if(!i){let o=this.dataItems[e];o&&(r+=o.get("deltaPosition",0))}return r}categoryToPosition(e){let t=this._itemMap[e];return t?this.indexToPosition(t.get("index")):NaN}categoryToIndex(e){let t=this._itemMap[e];return t?t.get("index"):NaN}dataItemToPosition(e){return this.indexToPosition(e.get("index"))}roundAxisPosition(e,t){return e+=(.5-t)/this.dataItems.length,this.indexToPosition(this.axisPositionToIndex(e),t)}axisPositionToIndex(e){let t=this.dataItems.length;if(t===0)return 0;if(this.get("cellSizeField")){let i=0,s=[];K(this.dataItems,l=>{let c=l.get("cellSize",1);s.push(c),i+=c});let r=this.get("startLocation",0),n=this.get("endLocation",1);i-=r,i-=1-n;let A=e*i+r,o=0;for(let l=0;l<t;l++){let c=s[l];if(A<o+c)return l;o+=c}return t-1}else return Bt(Math.floor(e*t),0,t-1)}getTooltipText(e,t){let i=this.dataItems[this.axisPositionToIndex(e)];if(i){let s=i.get("label");if(s)return Pr(s,this.get("tooltipText",""))}}_updateTooltipText(e,t){e._setDataItem(this.dataItems[this.axisPositionToIndex(t)]),e.label.text.markDirtyText()}getSeriesItem(e,t){if(this.dataItems.length>0){let i=this.getPrivate("name")+this.get("renderer").getPrivate("letter"),s=this.axisPositionToIndex(t),r=e.dataItems[s],n=this.dataItems[s],A=n.get("category");if(r&&n&&r.get(i)===A)return r;for(let o=0,l=e.dataItems.length;o<l;o++){let c=e.dataItems[o];if(c.get(i)===A)return c}}}_getIndices(e,t){let i=this.dataItems.length,s=0,r=i,n="cellSize";if(this.get("cellSizeField")){let A=0,o=this.dataItems;if(o.length==0)return{startIndex:0,endIndex:0};K(o,c=>{A+=c.get(n,1)}),A-=this.get("startLocation",0)*o[0].get(n,1),A-=(1-this.get("endLocation",1))*o[o.length-1].get(n,1);let l=0;for(let c=0;c<i;c++)if(l+=this.dataItems[c].get(n,1),Math.round(l)>Math.round(e*A)){s=c;break}for(let c=s+1;c<i;c++)if(l+=this.dataItems[c].get(n,1),Math.round(l)>=Math.round(t*A)){r=c+1;break}s=Math.max(s,0),r=Math.min(r,i)}else s=Math.max(Math.round(this.get("start",0)*i),0),r=Math.min(Math.round(this.get("end",1)*i),i);return{startIndex:s,endIndex:r}}zoomToIndexes(e,t,i){let s=this.dataItems.length;this.get("cellSizeField")?(e=Math.min(Math.max(e,0),s),t=Math.max(Math.min(t,s),1),this.setPrivateRaw("startIndex",e),this.setPrivateRaw("endIndex",t),this.zoom(this.indexToPosition(e,0,!0),this.indexToPosition(t,0,!0),i)):this.zoom(e/s,t/s,i)}zoomToCategories(e,t,i){this.zoomToIndexes(this.categoryToIndex(e),this.categoryToIndex(t)+1,i)}getCellWidthPosition(){return this._frequency/this.dataItems.length/(this.get("end",1)-this.get("start",0))}nextPosition(e){e==null&&(e=1),this.get("renderer").getPrivate("letter")=="Y"&&(e*=-1);let t=this.getPrivate("tooltipPosition",0),i=Bt(this.axisPositionToIndex(t)+e,0,this.dataItems.length-1);return this.toGlobalPosition(this.indexToPosition(i))}};Gt.className="CategoryAxis";Gt.classNames=pr.classNames.concat([Gt.className]);var Rt=class extends at{constructor(){super(...arguments),this._dataGrouped=!1,this._seriesDataGrouped=!1,this._groupingCalculated=!1,this._intervalDuration=1,this._baseDuration=1,this._intervalMax={},this._intervalMin={}}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["axis"]),super._afterNew(),this.addTag("date"),this._setBaseInterval(this.get("baseInterval")),this.on("baseInterval",()=>{this._setBaseInterval(this.get("baseInterval"))})}_setBaseInterval(e){this.setPrivateRaw("baseInterval",e),this._baseDuration=ks(e)}_fixZoomFactor(){let e=this.get("maxZoomFactor");e!=null&&e!=1/0?this.setPrivateRaw("maxZoomFactor",e):this.setPrivateRaw("maxZoomFactor",Math.round((this.getPrivate("max",0)-this.getPrivate("min",0))/this.baseMainDuration()))}_groupData(){let e=this.getPrivate("min"),t=this.getPrivate("max");if(W(e)&&W(t)){this._fixZoomFactor();let i=this.getPrivate("groupInterval");if(i?this._setBaseInterval(i):this._setBaseInterval(this.get("baseInterval")),this.isDirty("groupInterval")){let s=this.get("groupInterval");s&&(this.setRaw("groupIntervals",[s]),this._handleRangeChange())}if(this.isDirty("groupData")&&!this._dataGrouped){if(this.get("groupData"))K(this.series,s=>{this._groupSeriesData(s)}),this._handleRangeChange();else{let s=this.get("baseInterval"),r=s.timeUnit+s.count;K(this.series,n=>{n.setDataSet(r),n.resetGrouping()}),this._setBaseInterval(s),this.setPrivateRaw("groupInterval",void 0),this.markDirtyExtremes()}this._dataGrouped=!0}}}_groupSeriesData(e){if(this.get("groupData")&&!e.get("groupDataDisabled")){this._dataGrouped=!0,this._seriesDataGrouped=!0;let t=[],i=this.baseMainDuration(),s=this.get("groupIntervals");K(s,u=>{ks(u)>i&&t.push(u)}),e._dataSets={};let r=this.getPrivate("name")+this.get("renderer").getPrivate("letter"),n,A=e.get("baseAxis");e.get("xAxis")===A?n=e._valueYFields:e.get("yAxis")===A&&(n=e._valueXFields);let o=e._mainDataItems,l=this.get("baseInterval"),c=l.timeUnit+l.count;e._dataSets[c]=o;let h=e.get("groupDataCallback"),d=e.get("groupDataWithOriginals",!1);h&&(d=!0),K(t,u=>{let g=-1/0,y=u.timeUnit+u.count;e._dataSets[y]=[];let m,b={},B={},w={},_={};K(n,O=>{b[O]=0,B[O]=0,w[O]=e.get(O+"Grouped"),_[O]=O+"Working"});let T=_i(u.timeUnit),Q=o[0],U;Q&&(U=o[0].get(r));let E;K(o,O=>{let D=O.get(r),k=ei(D,u.timeUnit,u.count,this._root,U),F;if(g<k-T/24)F=Ws(O.dataContext),m=new ui(e,F,e._makeDataItem(F)),m.setRaw(r,k),e._dataSets[y].push(m),K(n,M=>{let Y=O.get(M);W(Y)?(m.setRaw(M,Y),m.setRaw(_[M],Y),B[M]=1,b[M]=Y):(b[M]=0,B[M]=0)}),d&&m.set("originals",[O]),h&&E&&h(E,u),E=m;else{let M=!1;if(K(n,Y=>{let z=w[Y],re=O.get(Y);if(re!=null){M=!0;let q=m.get(Y);switch(z){case"close":m.setRaw(Y,re);break;case"sum":m.setRaw(Y,q+re);break;case"open":break;case"low":re<q&&m.setRaw(Y,re);break;case"high":re>q&&m.setRaw(Y,re);break;case"average":B[Y]++,b[Y]+=re;let Ae=b[Y]/B[Y];m.setRaw(Y,Ae);break;case"extreme":Math.abs(re)>Math.abs(q)&&m.setRaw(Y,re);break}m.setRaw(_[Y],m.get(Y))}}),M){let Y=Ws(O.dataContext);Y[r]=k,m.dataContext=Y}d&&m.get("originals").push(O)}g=k}),h&&E&&h(E,u)}),e._dataSetId&&e.setDataSet(e._dataSetId),this.markDirtySize(),this._seriesAdded&&this._root.events.once("frameended",()=>{this.markDirtySize()})}}_clearDirty(){super._clearDirty(),this._groupingCalculated=!1,this._dataGrouped=!1}getGroupInterval(e){let t=this.get("baseInterval"),i=Zo(0,e,this.get("groupCount",1/0),this.get("groupIntervals"));return ks(i)<ks(t)&&(i=Object.assign({},t)),i}getIntervalMax(e){return this._intervalMax[e.timeUnit+e.count]}getIntervalMin(e){return this._intervalMin[e.timeUnit+e.count]}_handleRangeChange(){super._handleRangeChange();let e=Math.round(this.getPrivate("selectionMin")),t=Math.round(this.getPrivate("selectionMax"));if(W(e)&&W(t)){if(this.get("endLocation")==0&&(t+=1),this.get("groupData")&&!this._groupingCalculated){this._groupingCalculated=!0;let i=this.get("groupInterval"),s=this.getPrivate("groupInterval"),r=t-e+(this.get("startLocation",0)+(1-this.get("endLocation",1))*this._baseDuration);if(s){let n=ks(s);r=Math.ceil(r/n)*n}if(i||(i=this.getGroupInterval(r)),i&&(!s||s.timeUnit!==i.timeUnit||s.count!==i.count||this._seriesDataGrouped)){this._seriesDataGrouped=!1,this.setPrivateRaw("groupInterval",i),this._setBaseInterval(i);let n=i.timeUnit+i.count;K(this.series,A=>{A.get("baseAxis")===this&&A.setDataSet(n)}),this.markDirtyExtremes(),this._root.events.once("frameended",()=>{this._root.events.once("frameended",()=>{let A="groupintervalchanged";this.events.isEnabled(A)&&this.events.dispatch(A,{type:A,target:this})})})}}K(this.series,i=>{if(i.get("baseAxis")===this){let s=this.getPrivate("name")+this.get("renderer").getPrivate("letter"),n=Mh(i.dataItems,m=>Bs(m.get(s),e)).index;n>0&&(n-=1),t+=this._baseDuration*(1-this.get("endLocation",1));let o=Eo(i.dataItems,m=>Bs(m.get(s),t)).index,l=o;l>1&&l--;let c=i.dataItems[n],h=i.dataItems[l],d,u;c&&(u=c.get(s)),h&&(d=h.get(s));let g=!1;d!=null&&u!=null&&(d<e||u>t)&&(g=!0),i.setPrivate("outOfSelection",g),i.setPrivate("startIndex",n);let y=i._adjustStartIndex(n);i.getPrivate("adjustedStartIndex")!==y&&(i.setPrivate("adjustedStartIndex",y),this.root.events.once("frameended",()=>{i._markDirtyPrivateKey("adjustedStartIndex")})),i.setPrivate("endIndex",o)}})}}_adjustMinMax(e,t,i,s){return{min:e,max:t,step:(t-e)/i}}intervalDuration(){return this._intervalDuration}_saveMinMax(e,t){let i=this.getPrivate("groupInterval");i||(i=this.get("baseInterval"));let s=i.timeUnit+i.count;this._intervalMin[s]=e,this._intervalMax[s]=t}_getM(e){return e=="day"||e=="month"||e=="year"?1.05:1.01}_getMinorInterval(e){var t;let i,s=e.count,r=e.timeUnit;return s>1&&(s==10||s==15?s=5:s==12?s=2:s==6?s=1:s==30?s=10:s<10&&(s=1),i={timeUnit:r,count:s}),r=="week"&&(((t=this.getPrivate("baseInterval"))===null||t===void 0?void 0:t.timeUnit)!="week"?i={timeUnit:"day",count:1}:i={timeUnit:"week",count:1}),r=="year"&&s==1&&this.getPrivate("selectionMax",0)-this.getPrivate("selectionMin",0)<4*366*24*60*60*1e3&&(i={timeUnit:"month",count:1}),i}_prepareAxisItems(){let e=this.getPrivate("min"),t=this.getPrivate("max");if(W(e)&&W(t)){let i=this._root,s=Math.round(this.getPrivate("selectionMin")),r=Math.round(this.getPrivate("selectionMax")),n=this.get("renderer"),A=this.getPrivate("baseInterval"),o=s,l=0,c=this.get("gridIntervals"),h=Zo(0,r-s,n.gridCount(),c);ks(h)<this._baseDuration&&(h=Object.assign({},A));let d=ks(h);this._intervalDuration=d;let u=lc(h.timeUnit),g=i.utc,y=i.timezone;o=ei(s-d,h.timeUnit,h.count,i,e);let m=o-d,b,B=this.get("dateFormats");this.setPrivateRaw("gridInterval",h);let w=n.get("minorLabelsEnabled"),_=n.get("minorGridEnabled",w),T,Q=0;_&&(T=this._getMinorInterval(h),Q=ks(T));let U=0;for(;o<r+d;){let E;this.dataItems.length<l+1?(E=new ui(this,void 0,{}),this._dataItems.push(E),this.processDataItem(E)):E=this.dataItems[l],this._createAssets(E,[]),this._toggleDataItem(E,!0),E.setRaw("value",o),E.setRaw("labelEndValue",void 0);let O=o+_i(h.timeUnit,h.count*this._getM(h.timeUnit));O=ei(O,h.timeUnit,1,i),E.setRaw("endValue",O);let D=new Date(o);b=B[h.timeUnit],u&&this.get("markUnitChange")&&W(m)&&h.timeUnit!="year"&&hc(o,m,u,g,y)&&(b=this.get("periodChangeDateFormats")[h.timeUnit]);let k=E.get("label");k&&k.set("text",i.dateFormatter.format(D,b));let F=h.count;if(h.timeUnit=="week"?k?.set("location",this.get("weekLabelLocation",0)):k?.set("location",n.labels.template.get("location")),_){F=1;let M=h.timeUnit;M=="week"&&this.get("skipFirstMinor")&&(M="day");let Y=o+_i(M,this._getM(M));Y=ei(Y,M,1,i),E.setRaw("labelEndValue",Y)}if(this._prepareDataItem(E,F),m=o,o=O,T){let M=T.timeUnit,Y=T.count,z=this._getM(M);this.get("skipFirstMinor")||(m-=Q*z);let re=ei(m+Q*z,M,Y,i,m),q,Ae=this.get("minorDateFormats",this.get("dateFormats"));for(;re<o-.01*Q;){let X;this.minorDataItems.length<U+1?(X=new ui(this,void 0,{}),this.minorDataItems.push(X),this.processDataItem(X)):X=this.minorDataItems[U],this._createAssets(X,["minor"],!0),this._toggleDataItem(X,!0),X.setRaw("value",re);let G=re+_i(M,Y*z);G=ei(G,M,1,i),X.setRaw("endValue",G);let ue=new Date(re);b=Ae[M];let he=X.get("label");if(he&&(w?he.set("text",i.dateFormatter.format(ue,b)):he.setPrivate("visible",!1)),this._prepareDataItem(X,1),re==q)break;if(!X.get("isRange")){let ae=this.get("fillRule");ae&&ae(X)}q=re,re=G,U++}}if(o==m)break;l++}for(let E=l;E<this.dataItems.length;E++)this._toggleDataItem(this.dataItems[E],!1);for(let E=U;E<this.minorDataItems.length;E++)this._toggleDataItem(this.minorDataItems[E],!1);K(this.series,E=>{E.inited&&E._markDirtyAxes()})}this._updateGhost()}_updateFinals(e,t){this.setPrivateRaw("selectionMinFinal",this.positionToValue(e)),this.setPrivateRaw("selectionMaxFinal",this.positionToValue(t))}_getDelta(){this._deltaMinMax=this._baseDuration/2}_fixMin(e){let t=this.getPrivate("baseInterval"),i=t.timeUnit,s=ei(e,i,t.count,this._root),r=s+_i(i,t.count*this._getM(i));return r=ei(r,i,1,this._root),s+(r-s)*this.get("startLocation",0)}_fixMax(e){let t=this.getPrivate("baseInterval"),i=t.timeUnit,s=ei(e,i,t.count,this._root),r=s+_i(i,t.count*this._getM(i));return r=ei(r,i,1,this._root),s+(r-s)*this.get("endLocation",1)}_updateDates(e,t){}_handleSeriesRemoved(){this.setPrivate("baseInterval",this.get("baseInterval")),this.setPrivate("min",void 0),this.setPrivate("minFinal",void 0)}baseDuration(){return this._baseDuration}baseMainDuration(){return ks(this.get("baseInterval"))}processSeriesDataItem(e,t){let i=this.getPrivate("baseInterval");e.open||(e.open={}),e.close||(e.close={}),K(t,s=>{let r=e.get(s);if(W(r)){let n=e.open[s],A=e.close[s];if(!(r>=n&&r<=A)){let o=i.timeUnit,l=i.count;n=ei(r,o,l,this._root),A=n+_i(o,l*this._getM(o)),A=ei(A,o,1,this._root),e.open[s]=n,e.close[s]=A}this._updateDates(n,e.component)}})}_handleSizeDirty(){}getDataItemPositionX(e,t,i,s,r){let n,A,o;return r?o=e.get(t):(e.open&&e.close?(n=e.open[t],A=e.close[t]):(n=e.get(t),A=n),o=n+(A-n)*i,o=this._baseValue+(o-this._baseValue)*s),this.valueToPosition(o)}getDataItemCoordinateX(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionX(e,t,i,s))}getDataItemPositionY(e,t,i,s,r){let n,A,o;return r?o=e.get(t):(e.open&&e.close?(n=e.open[t],A=e.close[t]):(n=e.get(t),A=n),o=n+(A-n)*i,o=this._baseValue+(o-this._baseValue)*s),this.valueToPosition(o)}getDataItemCoordinateY(e,t,i,s){return this._settings.renderer.positionToCoordinate(this.getDataItemPositionY(e,t,i,s))}roundAxisPosition(e,t){let i=this.positionToValue(e);i=i-(t-.5)*this._baseDuration;let s=this.getPrivate("baseInterval");if(!Ni(i)){let r=this._root.locale.firstDayOfWeek,n=s.timeUnit,A=this._root.utc,o=this._root.timezone,l=s.count;i=ei(i,n,l,this._root,this.getPrivate("min",0));let c=jo(s,new Date(i),r,A,o);return o&&(i=ei(i+this._baseDuration*.05,n,l,this._root,this.getPrivate("min",0)),c=jo(s,new Date(i+c*t),r,A,o)),this.valueToPosition(i+c*t)}return NaN}getTooltipText(e,t){if(this.getPrivate("min")!=null){let i=this.get("tooltipDateFormats")[this.getPrivate("baseInterval").timeUnit],s=this.positionToValue(e);if(W(s)){let r=new Date(s),n=this.getPrivate("baseInterval"),A=jo(n,r,this._root.locale.firstDayOfWeek,this._root.utc,this._root.timezone);return t!==!1&&(r=new Date(s+this.get("tooltipIntervalOffset",-this.get("tooltipLocation",.5))*A)),this._root.dateFormatter.format(r,this.get("tooltipDateFormat",i))}}return""}getSeriesItem(e,t,i,s){let r=this.getPrivate("name")+this.get("renderer").getPrivate("letter"),n=this.positionToValue(t);i==null&&(i=.5),n=n-(i-.5)*this._baseDuration;let A=Eo(e.dataItems,o=>{let l=0;return o.open&&(l=o.open[r]),Bs(l,n)});if(s||e.get("snapTooltip")){let o=e.dataItems[A.index-1],l=e.dataItems[A.index];if(o&&l&&o.open&&l.close){let c=o.open[r],h=l.close[r];if(Math.abs(n-c)>Math.abs(n-h))return l}if(o)return o;if(l)return l}else{let o=e.dataItems[A.index-1];if(o&&o.open&&o.close){let l=o.open[r],c=o.close[r];if(n>=l&&n<=c)return o}}}shouldGap(e,t,i,s){let r=e.get(s);return t.get(s)-r>this._baseDuration*i}zoomToDates(e,t,i){this.zoomToValues(e.getTime(),t.getTime(),i)}zoomToValues(e,t,i){let s=this.getPrivate("minFinal",this.getPrivate("min",0)),r=this.getPrivate("maxFinal",this.getPrivate("max",0));if(this.getPrivate("min")!=null&&this.getPrivate("max")!=null)if(this.get("groupData")){let n=this.getGroupInterval(t-e),A=this.get("baseInterval"),o=this.getIntervalMin(A),l=this.getIntervalMax(A)-1;l=ei(l,n.timeUnit,n.count,this.root),l+=this._getM(n.timeUnit)*ks(n),l=ei(l,n.timeUnit,n.count,this.root);let c=ei(o,n.timeUnit,n.count,this.root),h=ei(l,n.timeUnit,n.count,this.root),d=(e-c)/(h-c),u=(t-c)/(h-c);this.zoom(d,u,i)}else this.zoom((e-s)/(r-s),(t-s)/(r-s),i)}positionToDate(e){return new Date(this.positionToValue(e))}dateToPosition(e){return this.valueToPosition(e.getTime())}getCellWidthPosition(){let e=this.getPrivate("selectionMax",this.getPrivate("max")),t=this.getPrivate("selectionMin",this.getPrivate("min"));return W(e)&&W(t)?this._intervalDuration/(e-t):.05}nextPosition(e){e==null&&(e=1);let t=this.get("tooltipLocation",.5)*this._baseDuration;this.get("renderer").getPrivate("letter")=="Y"&&(e*=-1);let i=this.positionToValue(this.getPrivate("tooltipPosition",0)),s=this.getPrivate("baseInterval"),r=this._nextTime(i,e,s),n=this.getPrivate("selectionMin",0),A=this.getPrivate("selectionMax",0),o=ei(n,s.timeUnit,s.count,this._root),l=ei(A,s.timeUnit,s.count,this._root);return r+=t,r=Bt(r,o+t,l-t),this.toGlobalPosition(this.valueToPosition(r))}_nextTime(e,t,i){return ei(e+t*this._baseDuration,i.timeUnit,i.count,this._root)}};Rt.className="DateAxis";Rt.classNames=at.classNames.concat([Rt.className]);var an=class extends nt{_beforeChanged(){super._beforeChanged();let e=this.get("sprite");if(this.isDirty("sprite")&&e&&(e.setAll({position:"absolute",role:"figure"}),this._disposers.push(e)),this.isDirty("location")){let t=e.dataItem;this.axis&&e&&t&&this.axis._prepareDataItem(t)}}_dispose(){let e=this.axis;e&&Ve(e._bullets,(t,i)=>{i.uid==this.uid&&delete e._bullets[t]}),super._dispose()}};an.className="AxisBullet";an.classNames=nt.classNames.concat([an.className]);var fi=class extends Gi{constructor(){super(...arguments),this.thumb=Tt.new(this._root,{width:se,isMeasured:!1,themeTags:["axis","x","thumb","zoomgrip"]})}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["renderer","x"]),super._afterNew(),this.setPrivateRaw("letter","X");let e=this.grid.template;e.set("height",se),e.set("width",0),e.set("draw",(t,i)=>{t.moveTo(0,0),t.lineTo(0,i.height())}),this.set("draw",(t,i)=>{t.moveTo(0,0),t.lineTo(i.width(),0)})}_changed(){var e;super._changed();let t=this.axis,i=t.ghostLabel;i&&(i.setPrivate("visible",!this.get("inside")),i.set("x",-1e3));let s="opposite",r="inside";if(this.isDirty(s)||this.isDirty(r)){let n=this.chart,A=t.children;if(this.get(r)?t.addTag(r):t.removeTag(r),n){if(this.get(s)){let o=n.topAxesContainer.children;o.indexOf(t)==-1&&o.insertIndex(0,t),t.addTag(s),A.moveValue(this)}else{let o=n.bottomAxesContainer.children;o.indexOf(t)==-1&&o.moveValue(t),t.removeTag(s),A.moveValue(this,0)}(e=t.ghostLabel)===null||e===void 0||e._applyThemes(),this.labels.each(o=>{o._applyThemes()}),this.root._markDirtyRedraw()}t.markDirtySize()}this.thumb.setPrivate("height",t.labelsContainer.height())}_getPan(e,t){return(t.x-e.x)/this.width()}toAxisPosition(e){let t=this._start||0,i=this._end||1;return e-=this._ls,e=e*(i-t)/this._lc,this.get("inversed")?e=i-e:e=t+e,e}toGlobalPosition(e){let t=this._start||0,i=this._end||1;return this.get("inversed")?e=i-e:e=e-t,e=e/(i-t)*this._lc,e+=this._ls,e}_updateLC(){let e=this.axis,t=e.parent;if(t){let i=t.innerWidth();this._lc=this.axisLength()/i,this._ls=(e.x()-t.get("paddingLeft",0))/i}}_updatePositions(){let e=this.axis,t=e.x()-We(e.get("centerX",0),e.width())-e.parent.get("paddingLeft",0);e.gridContainer.set("x",t),e.topGridContainer.set("x",t),e.bulletsContainer.set("y",this.y());let i=e.chart;if(i){let s=i.plotContainer,r=e.axisHeader,n=e.get("marginLeft",0),A=e.x()-n,o=e.parent;o&&(A-=o.get("paddingLeft",0)),r.children.length>0?(n=e.axisHeader.width(),e.set("marginLeft",n+1)):r.set("width",n),r.setAll({x:A,y:-1,height:s.height()+2})}}processAxis(){super.processAxis();let e=this.axis;e.get("width")==null&&e.set("width",se);let t=this._root.verticalLayout;e.set("layout",t),e.labelsContainer.set("width",se),e.axisHeader.setAll({layout:t})}axisLength(){return this.axis.width()}positionToPoint(e){return{x:this.positionToCoordinate(e),y:0}}updateTick(e,t,i,s){if(e){W(t)||(t=0);let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),W(i)&&i!=t&&(t=t+(i-t)*r),e.set("x",this.positionToCoordinate(t));let n=e.get("length",0),A=e.get("inside",this.get("inside",!1));this.get("opposite")?(e.set("y",se),A||(n*=-1)):(e.set("y",0),A&&(n*=-1)),e.set("draw",o=>{o.moveTo(0,0),o.lineTo(0,n)}),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}updateLabel(e,t,i,s){if(e){let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),W(t)||(t=0);let n=e.get("inside",this.get("inside",!1));this.get("opposite")?n?(e.set("position","absolute"),e.set("y",0)):(e.set("position","relative"),e.set("y",se)):n?(e.set("y",0),e.set("position","absolute")):(e.set("y",void 0),e.set("position","relative")),W(i)&&i!=t&&(t=t+(i-t)*r),e.set("x",this.positionToCoordinate(t)),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}updateGrid(e,t,i){if(e){W(t)||(t=0);let s=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*s),e.set("x",this.positionToCoordinate(t)),this.toggleVisibility(e,t,0,1)}}updateBullet(e,t,i){if(e){let s=e.get("sprite");if(s){W(t)||(t=0);let r=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*r);let n=this.axis.roundAxisPosition(t,r),A=this.axis._bullets[n],o=-1;if(this.get("opposite")&&(o=1),e.get("stacked"))if(A){let l=A.get("sprite");l&&s.set("y",l.y()+l.height()*o)}else s.set("y",0);this.axis._bullets[n]=e,s.set("x",this.positionToCoordinate(t)),this.toggleVisibility(s,t,0,1)}}}updateFill(e,t,i){if(e){W(t)||(t=0),W(i)||(i=1);let s=this.positionToCoordinate(t),r=this.positionToCoordinate(i);this.fillDrawMethod(e,s,r)}}fillDrawMethod(e,t,i){e.set("draw",s=>{let r=this.axis.gridContainer.height(),n=this.width();i<t&&([i,t]=[t,i]),!(t>n||i<0)&&(s.moveTo(t,0),s.lineTo(i,0),s.lineTo(i,r),s.lineTo(t,r),s.lineTo(t,0))})}positionTooltip(e,t){this._positionTooltip(e,{x:this.positionToCoordinate(t),y:0})}updateTooltipBounds(e){let t=this.get("inside"),i=1e5,s=this._display.toGlobal({x:0,y:0}),r=s.x,n=0,A=this.axisLength(),o=i,l="up";this.get("opposite")?t?(l="up",n=s.y,o=i):(l="down",n=s.y-i,o=i):t?(l="down",n=s.y-i,o=i):(l="up",n=s.y,o=i);let c={left:r,right:r+A,top:n,bottom:n+o},h=e.get("bounds");Kh(c,h)||(e.set("bounds",c),e.set("pointerOrientation",l))}};fi.className="AxisRendererX";fi.classNames=Gi.classNames.concat([fi.className]);var rs=class extends Gi{constructor(){super(...arguments),this.thumb=Tt.new(this._root,{height:se,isMeasured:!1,themeTags:["axis","y","thumb","zoomgrip"]})}_afterNew(){this._settings.themeTags=Fe(this._settings.themeTags,["renderer","y"]),this._settings.opposite&&this._settings.themeTags.push("opposite"),super._afterNew(),this.setPrivateRaw("letter","Y");let e=this.grid.template;e.set("width",se),e.set("height",0),e.set("draw",(t,i)=>{t.moveTo(0,0),t.lineTo(i.width(),0)}),this.set("draw",(t,i)=>{t.moveTo(0,0),t.lineTo(0,i.height())})}_getPan(e,t){return(e.y-t.y)/this.height()}_changed(){var e;super._changed();let t=this.axis,i=t.ghostLabel;i&&(i.setPrivate("visible",!this.get("inside")),i.set("y",-1e3));let s=this.thumb,r="opposite",n="inside",A=this.chart;if(this.isDirty(r)||this.isDirty(n)){let l=t.children;if(this.get(n)?t.addTag(n):t.removeTag(n),A){if(this.get(r)){let c=A.rightAxesContainer.children;c.indexOf(t)==-1&&c.moveValue(t,0),t.addTag(r),l.moveValue(this,0)}else{let c=A.leftAxesContainer.children;c.indexOf(t)==-1&&c.moveValue(t),t.removeTag(r),l.moveValue(this)}(e=t.ghostLabel)===null||e===void 0||e._applyThemes(),this.labels.each(c=>{c._applyThemes()}),this.root._markDirtyRedraw()}t.markDirtySize()}let o=t.labelsContainer.width();A&&(this.get(r)?s.set("centerX",0):s.set("centerX",o)),s.setPrivate("width",o)}processAxis(){super.processAxis();let e=this.axis;e.get("height")==null&&e.set("height",se);let t=this._root.horizontalLayout;e.set("layout",t),e.labelsContainer.set("height",se),e.axisHeader.set("layout",t)}_updatePositions(){let e=this.axis,t=e.y()-We(e.get("centerY",0),e.height());e.gridContainer.set("y",t),e.topGridContainer.set("y",t),e.bulletsContainer.set("x",this.x());let i=e.chart;if(i){let s=i.plotContainer,r=e.axisHeader,n=e.get("marginTop",0);r.children.length>0?(n=e.axisHeader.height(),e.set("marginTop",n+1)):r.set("height",n),r.setAll({y:e.y()-n,x:-1,width:s.width()+2})}}axisLength(){return this.axis.innerHeight()}positionToPoint(e){return{x:0,y:this.positionToCoordinate(e)}}updateLabel(e,t,i,s){if(e){W(t)||(t=0);let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r);let n=this.get("opposite"),A=e.get("inside",this.get("inside",!1));n?(e.set("x",0),A?e.set("position","absolute"):e.set("position","relative")):A?(e.set("x",0),e.set("position","absolute")):(e.set("x",void 0),e.set("position","relative")),W(i)&&i!=t&&(t=t+(i-t)*r),e.set("y",this.positionToCoordinate(t)),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}updateGrid(e,t,i){if(e){W(t)||(t=0);let s=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*s),e.set("y",this.positionToCoordinate(t)),this.toggleVisibility(e,t,0,1)}}updateTick(e,t,i,s){if(e){W(t)||(t=0);let r=.5;W(s)&&s>1?r=e.get("multiLocation",r):r=e.get("location",r),W(i)&&i!=t&&(t=t+(i-t)*r),e.set("y",this.positionToCoordinate(t));let n=e.get("length",0),A=e.get("inside",this.get("inside",!1));this.get("opposite")?(e.set("x",0),A&&(n*=-1)):A||(n*=-1),e.set("draw",o=>{o.moveTo(0,0),o.lineTo(n,0)}),this.toggleVisibility(e,t,e.get("minPosition",0),e.get("maxPosition",1))}}updateBullet(e,t,i){if(e){let s=e.get("sprite");if(s){W(t)||(t=0);let r=e.get("location",.5);W(i)&&i!=t&&(t=t+(i-t)*r);let n=this.axis.roundAxisPosition(t,r),A=this.axis._bullets[n],o=1;if(this.get("opposite")&&(o=-1),e.get("stacked"))if(A){let l=A.get("sprite");l&&s.set("x",l.x()+l.width()*o)}else s.set("x",0);this.axis._bullets[n]=e,s.set("y",this.positionToCoordinate(t)),this.toggleVisibility(s,t,0,1)}}}updateFill(e,t,i){if(e){W(t)||(t=0),W(i)||(i=1);let s=this.positionToCoordinate(t),r=this.positionToCoordinate(i);this.fillDrawMethod(e,s,r)}}fillDrawMethod(e,t,i){e.set("draw",s=>{let r=this.axis.gridContainer.width(),n=this.height();i<t&&([i,t]=[t,i]),!(t>n||i<0)&&(s.moveTo(0,t),s.lineTo(r,t),s.lineTo(r,i),s.lineTo(0,i),s.lineTo(0,t))})}positionToCoordinate(e){return this._inversed?(e-this._start)*this._axisLength:(this._end-e)*this._axisLength}positionTooltip(e,t){this._positionTooltip(e,{x:0,y:this.positionToCoordinate(t)})}updateTooltipBounds(e){let t=this.get("inside"),i=1e5,s=this._display.toGlobal({x:0,y:0}),r=s.y,n=0,A=this.axisLength(),o=i,l="right";this.get("opposite")?t?(l="right",n=s.x-i,o=i):(l="left",n=s.x,o=i):t?(l="left",n=s.x,o=i):(l="right",n=s.x-i,o=i);let c={left:n,right:n+o,top:r,bottom:r+A},h=e.get("bounds");Kh(c,h)||(e.set("bounds",c),e.set("pointerOrientation",l))}_updateLC(){let e=this.axis,t=e.parent;if(t){let i=t.innerHeight();this._lc=this.axisLength()/i,this._ls=e.y()/i}}toAxisPosition(e){let t=this._start||0,i=this._end||1;return e-=this._ls,e=e*(i-t)/this._lc,this.get("inversed")?e=t+e:e=i-e,e}toGlobalPosition(e){let t=this._start||0,i=this._end||1;return this.get("inversed")?e=e-t:e=i-e,e=e/(i-t)*this._lc,e+=this._ls,e}fixPosition(e){return this.get("inversed")?e:1-e}};rs.className="AxisRendererY";rs.classNames=Gi.classNames.concat([rs.className]);var nn=class extends Et{_beforeChanged(){super._beforeChanged(),(this.isDirty("lowX0")||this.isDirty("lowY0")||this.isDirty("lowX1")||this.isDirty("lowY1")||this.isDirty("highX0")||this.isDirty("highX1")||this.isDirty("highY0")||this.isDirty("highY1"))&&(this._clear=!0)}_draw(){super._draw();let e=this._display;e.moveTo(this.get("lowX0",0),this.get("lowY0",0)),e.lineTo(this.get("lowX1",0),this.get("lowY1",0)),e.moveTo(this.get("highX0",0),this.get("highY0",0)),e.lineTo(this.get("highX1",0),this.get("highY1",0))}};nn.className="Candlestick";nn.classNames=Et.classNames.concat([nn.className]);var mt=class extends rn{constructor(){super(...arguments),this.allColumns=this.children.push(Le.new(this._root,{})),this.allColumnsData=[],this.columns=this.addDisposer(new pt(Ne.new({}),()=>Et._new(this._root,{position:"absolute",themeTags:Fe(this.columns.template.get("themeTags",[]),["series","column"])},[this.columns.template])))}makeColumn(e,t){let i=t.make();return this.get("turboMode")?i.virtualParent=this.chart:this.mainContainer.children.push(i),i._setDataItem(e),t.push(i),i}_processAxisRange(e){super._processAxisRange(e),e.columns=new pt(Ne.new({}),()=>Et._new(this._root,{position:"absolute",themeTags:Fe(e.columns.template.get("themeTags",[]),["series","column"])},[this.columns.template,e.columns.template]))}_beforeColumnsDraw(){this.allColumnsData=[]}_afterColumnsDraw(){this.get("turboMode")&&this.allColumns.set("draw",e=>{e.clear(),K(this.allColumnsData,t=>{let i=t.width,s=t.height,r=t.x,n=t.y,A=t.stroke,o=t.fill,l=t.strokeWidth,c=t.strokeOpacity,h=t.fillOpacity;e.beginFill(o,h),e.beginPath(),e.lineStyle(l,A,c),e.drawRect(r,n,i,s),e.endStroke(),e.endFill()})})}_updateChildren(){this.isDirty("turboMode")&&(this.markDirtyValues(),this.get("turboMode")||this.allColumns.set("draw",void 0)),super._updateChildren()}_updateSeriesGraphics(e,t,i,s,r,n,A,o){if(this.get("turboMode")){t.virtualParent=this.chart,t.parent&&(this.mainContainer.children.removeValue(t),t._parent=void 0);let l=t.get("stroke"),c=t.get("fillOpacity",1),h=t.get("strokeOpacity",1),d=t.get("strokeWidth",1),u=t.get("fill"),g=this.getPoint(i,r),y=this.getPoint(s,n),m=e.get("point");if(m){let b=this.getPoint(m.x,m.y);m.x=b.x+this._x,m.y=b.y+this._y}i=g.x,s=y.x,r=g.y,n=y.y,e.setRaw("left",i),e.setRaw("right",s),e.setRaw("top",r),e.setRaw("bottom",n),this.allColumnsData.push({width:s-i,height:n-r,x:i,y:r,stroke:l,fill:u,strokeWidth:d,strokeOpacity:h,fillOpacity:c})}else t.parent||this.mainContainer.children.push(t),super._updateSeriesGraphics(e,t,i,s,r,n,A,o)}};mt.className="ColumnSeries";mt.classNames=rn.classNames.concat([mt.className]);var ds=class extends mt{constructor(){super(...arguments),this.columns=this.addDisposer(new pt(Ne.new({themeTags:["autocolor"]}),()=>nn._new(this._root,{themeTags:Fe(this.columns.template.get("themeTags",[]),["candlestick","series","column"])},[this.columns.template])))}makeColumn(e,t){let i=t.make();return this.get("turboMode")?i.virtualParent=this.chart:this.mainContainer.children.push(i),i._setDataItem(e),t.push(i),i}_updateGraphics(e,t,i){super._updateGraphics(e,t,i);let s=this.getRaw("xAxis"),r=this.getRaw("yAxis"),n=this.get("vcy",1),A=this.get("vcx",1),o,l,c,h,d,u,g,y,m=this.get("locationX",e.get("locationX",.5)),b=this.get("locationY",e.get("locationY",.5)),B=this.get("openLocationX",e.get("openLocationX",m)),w=this.get("openLocationY",e.get("openLocationY",b)),_;if(i==0){let T=r.getDataItemPositionY(e,this._yOpenField,1,n),Q=r.getDataItemPositionY(e,this._yField,1,n);h=r.getDataItemPositionY(e,this._yLowField,1,n),y=r.getDataItemPositionY(e,this._yHighField,1,n),g=Math.max(T,Q),c=Math.min(T,Q);let U=this._aLocationX0+B-.5,E=this._aLocationX1+m-.5;o=s.getDataItemPositionX(e,this._xField,U+(E-U)/2,A),l=o,d=o,u=o,_="vertical"}else{let T=s.getDataItemPositionX(e,this._xOpenField,1,A),Q=s.getDataItemPositionX(e,this._xField,1,A);l=s.getDataItemPositionX(e,this._xLowField,1,A),u=s.getDataItemPositionX(e,this._xHighField,1,A),d=Math.max(T,Q),o=Math.min(T,Q);let U=this._aLocationY0+w-.5,E=this._aLocationY1+b-.5;c=r.getDataItemPositionY(e,this._yField,U+(E-U)/2,n),h=c,g=c,y=c,_="horizontal"}this._updateCandleGraphics(e,o,l,c,h,d,u,g,y,_)}_updateCandleGraphics(e,t,i,s,r,n,A,o,l,c){let h=e.get("graphics");if(h){let d=this.getPoint(t,s),u=this.getPoint(i,r),g=this.getPoint(n,o),y=this.getPoint(A,l);if(this.get("turboMode")){let m=this.allColumnsData[this.allColumnsData.length-1];m.lowX0=d.x,m.lowY0=d.y,m.lowX1=u.x,m.lowY1=u.y,m.highX0=g.x,m.highY0=g.y,m.highX1=y.x,m.highY1=y.y}else{let m=h.x(),b=h.y();h.set("lowX0",d.x-m),h.set("lowY0",d.y-b),h.set("lowX1",u.x-m),h.set("lowY1",u.y-b),h.set("highX0",g.x-m),h.set("highY0",g.y-b),h.set("highX1",y.x-m),h.set("highY1",y.y-b),h.set("orientation",c);let B=e.get("rangeGraphics");B&&K(B,w=>{w.set("lowX0",d.x-m),w.set("lowY0",d.y-b),w.set("lowX1",u.x-m),w.set("lowY1",u.y-b),w.set("highX0",g.x-m),w.set("highY0",g.y-b),w.set("highX1",y.x-m),w.set("highY1",y.y-b),w.set("orientation",c)})}}}_afterColumnsDraw(){this.get("turboMode")&&this.allColumns.set("draw",e=>{e.clear(),K(this.allColumnsData,t=>{let i=t.width,s=t.height,r=t.x,n=t.y,A=t.stroke,o=t.fill,l=t.strokeWidth,c=t.strokeOpacity,h=t.fillOpacity,d=t.lowX0,u=t.lowY0,g=t.lowX1,y=t.lowY1,m=t.highX0,b=t.highY0,B=t.highX1,w=t.highY1;e.beginFill(o,h),e.beginPath(),e.lineStyle(l,A,c),e.drawRect(r,n,i,s),e.moveTo(d,u),e.lineTo(g,y),e.moveTo(m,b),e.lineTo(B,w),e.endStroke(),e.endFill()})})}_processAxisRange(e){super._processAxisRange(e),e.columns=new pt(Ne.new({}),()=>nn._new(this._root,{themeTags:Fe(e.columns.template.get("themeTags",[]),["candlestick","series","column"])},[this.columns.template,e.columns.template]))}};ds.className="CandlestickSeries";ds.classNames=mt.classNames.concat([ds.className]);var mr=class extends qe{_afterNew(){this._setDefault("curveFactory",wg),super._afterNew()}_getPoints(e,t){let i=t.points,s=this.get("stepWidth",se).value/2,r=e.get("locationX",t.locationX),n=e.get("locationY",t.locationY),A=r,o=n;t.baseAxis===t.xAxis?(r-=s,A+=s):t.baseAxis===t.yAxis&&(n-=s,o+=s);let l=t.xAxis.getDataItemPositionX(e,t.xField,r,t.vcx),c=t.yAxis.getDataItemPositionY(e,t.yField,n,t.vcy),h=t.xAxis.getDataItemPositionX(e,t.xField,A,t.vcx),d=t.yAxis.getDataItemPositionY(e,t.yField,o,t.vcy);if(this._shouldInclude(l)){let u=this.getPoint(l,c),g=[u.x,u.y],y=this.getPoint(h,d),m=[y.x,y.y];if(t.fillVisible){let b=l,B=c,w=h,_=d;if(t.baseAxis===t.xAxis?(B=t.basePosY,_=t.basePosY):t.baseAxis===t.yAxis&&(b=t.basePosX,w=t.basePosX),t.getOpen){let U=e.get(t.xOpenField),E=e.get(t.yOpenField);if(U!=null&&E!=null)if(r=e.get("openLocationX",t.openLocationX),n=e.get("openLocationY",t.openLocationY),A=r,o=n,t.baseAxis===t.xAxis?(r-=s,A+=s):t.baseAxis===t.yAxis&&(n-=s,o+=s),t.stacked){let O=e.get("stackToItemX"),D=e.get("stackToItemY");O?(b=t.xAxis.getDataItemPositionX(O,t.xField,r,O.component.get("vcx")),w=t.xAxis.getDataItemPositionX(O,t.xField,A,O.component.get("vcx"))):t.yAxis===t.baseAxis?(b=t.basePosX,w=t.basePosX):t.baseAxis===t.yAxis&&(b=t.xAxis.getDataItemPositionX(e,t.xOpenField,r,t.vcx),w=t.xAxis.getDataItemPositionX(e,t.xOpenField,A,t.vcx)),D?(B=t.yAxis.getDataItemPositionY(D,t.yField,n,D.component.get("vcy")),_=t.yAxis.getDataItemPositionY(D,t.yField,o,D.component.get("vcy"))):t.xAxis===t.baseAxis?(B=t.basePosY,_=t.basePosY):t.baseAxis===t.yAxis&&(B=t.yAxis.getDataItemPositionY(e,t.yOpenField,n,t.vcy),_=t.yAxis.getDataItemPositionY(e,t.yOpenField,o,t.vcy))}else b=t.xAxis.getDataItemPositionX(e,t.xOpenField,r,t.vcx),B=t.yAxis.getDataItemPositionY(e,t.yOpenField,n,t.vcy),w=t.xAxis.getDataItemPositionX(e,t.xOpenField,A,t.vcx),_=t.yAxis.getDataItemPositionY(e,t.yOpenField,o,t.vcy)}let T=this.getPoint(b,B),Q=this.getPoint(w,_);g[2]=T.x,g[3]=T.y,m[2]=Q.x,m[3]=Q.y}i.push(g),i.push(m),e.set("point",{x:g[0]+(m[0]-g[0])/2,y:g[1]+(m[1]-g[1])/2})}this.get("noRisers")&&(t.points=[],t.segments.push(i))}};mr.className="StepLineSeries";mr.classNames=qe.classNames.concat([mr.className]);var xc=class extends _s{setupDefaultRules(){super.setupDefaultRules(),this.rule("Component").setAll({interpolationDuration:600}),this.rule("Hierarchy").set("animationDuration",600),this.rule("Scrollbar").set("animationDuration",600),this.rule("Tooltip").set("animationDuration",300),this.rule("MapChart").set("animationDuration",1e3),this.rule("MapChart").set("wheelDuration",300),this.rule("Entity").setAll({stateAnimationDuration:600}),this.rule("Sprite").states.create("default",{stateAnimationDuration:600}),this.rule("Tooltip",["axis"]).setAll({animationDuration:200}),this.rule("WordCloud").set("animationDuration",500),this.rule("Polygon").set("animationDuration",600),this.rule("ArcDiagram").set("animationDuration",600)}};var Cb=xc;var yr=class a extends _s{constructor(e,t){super(e,t),this.responsiveRules=[],this._dp=new zt([this._root._rootContainer.onPrivate("width",i=>{this._isUsed()&&this._maybeApplyRules()}),this._root._rootContainer.onPrivate("height",i=>{this._isUsed()&&this._maybeApplyRules()})])}static widthXXS(e,t){return e<=a.XXS}static widthXS(e,t){return e<=a.XS}static widthS(e,t){return e<=a.S}static widthM(e,t){return e<=a.M}static widthL(e,t){return e<=a.L}static widthXL(e,t){return e<=a.XL}static widthXXL(e,t){return e<=a.XXL}static heightXXS(e,t){return t<=a.XXS}static heightXS(e,t){return t<=a.XS}static heightS(e,t){return t<=a.S}static heightM(e,t){return t<=a.M}static heightL(e,t){return t<=a.L}static heightXL(e,t){return t<=a.XL}static heightXXL(e,t){return t<=a.XXL}static isXXS(e,t){return e<=a.XXS&&t<=a.XXS}static isXS(e,t){return e<=a.XS&&t<=a.XS}static isS(e,t){return e<=a.S&&t<=a.S}static isM(e,t){return e<=a.M&&t<=a.M}static isL(e,t){return e<=a.L&&t<=a.L}static isXL(e,t){return e<=a.XL&&t<=a.XL}static isXXL(e,t){return e<=a.XXL&&t<=a.XXL}static maybeXXS(e,t){return e<=a.XXS||t<=a.XXS}static maybeXS(e,t){return e<=a.XS||t<=a.XS}static maybeS(e,t){return e<=a.S||t<=a.S}static maybeM(e,t){return e<=a.M||t<=a.M}static maybeL(e,t){return e<=a.L||t<=a.L}static maybeXL(e,t){return e<=a.XL||t<=a.XL}static maybeXXL(e,t){return e<=a.XXL||t<=a.XXL}static newEmpty(e){return new this(e,!0)}addRule(e){return e.name&&!e.template&&(e.template=this.rule(e.name,e.tags)),this.responsiveRules.push(e),this._maybeApplyRule(e),e}removeRule(e){ri(this.responsiveRules,e)}dispose(){this._dp&&this._dp.dispose()}_isUsed(){return this._root._rootContainer.get("themes").indexOf(this)!==-1}_maybeApplyRules(){K(this.responsiveRules,e=>{this._maybeUnapplyRule(e)}),K(this.responsiveRules,e=>{this._maybeApplyRule(e)})}_maybeApplyRule(e){if(e.applied)return;let t=this._root._rootContainer.getPrivate("width"),i=this._root._rootContainer.getPrivate("height");e.relevant.call(e,t,i)&&(e.applied=!0,e.template&&e.settings&&e.template.setAll(e.settings),e.applying&&e.applying.call(e))}_maybeUnapplyRule(e){if(!e.applied)return;let t=this._root._rootContainer.getPrivate("width"),i=this._root._rootContainer.getPrivate("height");e.relevant.call(e,t,i)||(e.applied=!1,e.template&&e.template.removeAll(),e.removing&&e.removing.call(e))}setupDefaultRules(){super.setupDefaultRules();let e=t=>this.addRule(t);e({name:"Chart",relevant:a.widthXXS,settings:{paddingLeft:0,paddingRight:0}}),e({name:"Chart",relevant:a.heightXXS,settings:{paddingTop:0,paddingBottom:0}}),e({name:"Bullet",relevant:a.isXS,settings:{forceHidden:!0}}),e({name:"Legend",relevant:a.isXS,settings:{forceHidden:!0}}),e({name:"HeatLegend",tags:["vertical"],relevant:a.widthXS,settings:{forceHidden:!0}}),e({name:"HeatLegend",tags:["horizontal"],relevant:a.heightXS,settings:{forceHidden:!0}}),e({name:"Label",tags:["heatlegend","start"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"Label",tags:["heatlegend","end"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"Button",tags:["resize"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"AxisRendererX",relevant:a.heightXS,settings:{inside:!0}}),e({name:"AxisRendererY",relevant:a.widthXS,settings:{inside:!0}}),e({name:"AxisRendererXLabel",relevant:a.heightXS,settings:{minPosition:.1,maxPosition:.9}}),e({name:"AxisLabel",tags:["y"],relevant:a.widthXS,settings:{centerY:se,maxPosition:.9}}),e({name:"AxisLabel",tags:["x"],relevant:a.heightXXS,settings:{forceHidden:!0}}),e({name:"AxisLabel",tags:["x","minor"],relevant:a.widthXXL,settings:{forceHidden:!0}}),e({name:"AxisLabel",tags:["y"],relevant:a.widthXXS,settings:{forceHidden:!0}}),e({name:"AxisLabel",tags:["y","minor"],relevant:a.heightXXL,settings:{forceHidden:!0}}),e({name:"AxisTick",tags:["x"],relevant:a.heightXS,settings:{inside:!0,minPosition:.1,maxPosition:.9}}),e({name:"AxisTick",tags:["y"],relevant:a.widthXXS,settings:{inside:!0,minPosition:.1,maxPosition:.9}}),e({name:"Grid",relevant:a.maybeXXS,settings:{forceHidden:!0}}),e({name:"RadialLabel",tags:["radial"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"RadialLabel",tags:["circular"],relevant:a.maybeS,settings:{inside:!0}}),e({name:"AxisTick",relevant:a.maybeS,settings:{inside:!0}}),e({name:"RadialLabel",tags:["circular"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"AxisTick",tags:["circular"],relevant:a.maybeXS,settings:{inside:!0}}),e({name:"PieChart",relevant:a.maybeXS,settings:{radius:Re(99)}}),e({name:"PieChart",relevant:a.widthM,settings:{radius:Re(99)}}),e({name:"RadialLabel",tags:["pie"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"RadialLabel",tags:["pie"],relevant:a.widthM,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pie"],relevant:a.maybeXS,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pie"],relevant:a.widthM,settings:{forceHidden:!0}}),e({name:"FunnelSeries",relevant:a.widthM,settings:{alignLabels:!1}}),e({name:"Label",tags:["funnel","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Tick",tags:["funnel","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Label",tags:["funnel","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"Tick",tags:["funnel","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"PyramidSeries",relevant:a.widthM,settings:{alignLabels:!1}}),e({name:"Label",tags:["pyramid","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pyramid","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Label",tags:["pyramid","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pyramid","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"PictorialStackedSeries",relevant:a.widthM,settings:{alignLabels:!1}}),e({name:"Label",tags:["pictorial","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pictorial","vertical"],relevant:a.widthL,settings:{forceHidden:!0}}),e({name:"Label",tags:["pictorial","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"Tick",tags:["pictorial","horizontal"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"Label",tags:["flow","horizontal"],relevant:a.widthS,settings:{forceHidden:!0}}),e({name:"Label",tags:["flow","vertical"],relevant:a.heightS,settings:{forceHidden:!0}}),e({name:"Chord",relevant:a.maybeXS,settings:{radius:Re(99)}}),e({name:"Label",tags:["hierarchy","node"],relevant:a.maybeXS,settings:{forceHidden:!0}})}};yr.XXS=100;yr.XS=200;yr.S=300;yr.M=400;yr.L=600;yr.XL=800;yr.XXL=1e3;var _b=yr;var Fg;function PT(){return Ke(this,void 0,void 0,function*(){let a=yield Promise.all([import("./ZXIRDWJW.js"),import("./IYCUGRVF.js")]),e=a[0].default,t=a[1].default,i=window;return i.pdfMake=i.pdfMake||{},i.pdfMake.vfs=t,e.vfs=t,e})}var An=class extends nt{_afterNew(){super._afterNew(),this._setRawDefault("filePrefix","chart"),this._setRawDefault("charset","utf-8"),this._setRawDefault("numericFields",[]),this._setRawDefault("dateFields",[]),this._setRawDefault("durationFields",[]),this._setRawDefault("extraImages",[]),this._setRawDefault("pngOptions",{quality:1,maintainPixelRatio:!1}),this._setRawDefault("jpgOptions",{quality:.8,maintainPixelRatio:!1}),this._setRawDefault("printOptions",{quality:1,maintainPixelRatio:!1,delay:500,printMethod:"iframe",imageFormat:"png"}),this._setRawDefault("jsonOptions",{indent:2,renameFields:!0}),this._setRawDefault("csvOptions",{separator:",",addColumnNames:!0,emptyAs:"",addBOM:!0}),this._setRawDefault("htmlOptions",{emptyAs:"-",addColumnNames:!0}),this._setRawDefault("xlsxOptions",{emptyAs:"",addColumnNames:!0}),this._setRawDefault("pdfOptions",{fontSize:14,imageFormat:"png",align:"left",addURL:!0}),this._setRawDefault("pdfdataOptions",{emptyAs:"",addColumnNames:!0}),this._root.addDisposer(this)}_beforeChanged(){if(super._beforeChanged(),this.isDirty("menu")){let e=this.get("menu");e&&(e.set("exporting",this),this._disposers.push(e))}}_getFormatOptions(e,t){let i=Ws(this.get(e+"Options",{}));return t&&Ve(t,(s,r)=>{i[s]=r}),i}download(e,t){return Ke(this,void 0,void 0,function*(){let i=e=="pdfdata"?"pdf":e,s=this.get("filePrefix","chart")+"."+i,r=this._getFormatOptions(e,t);this.events.dispatch("downloadstarted",{type:"downloadstarted",format:e,options:r,fileName:s,target:this});let n=yield this.export(e,r);this.streamFile(n,s,r&&r.addBOM)})}print(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("print",e);this.events.dispatch("printstarted",{type:"printstarted",format:"print",options:t,target:this});let i=yield this.export(t.imageFormat||"png",t);this.initiatePrint(i,t,this.get("title"))})}export(e,t){return Ke(this,void 0,void 0,function*(){let i=this._getFormatOptions(e,t);this.events.dispatch("exportstarted",{type:"exportstarted",format:e,options:i,target:this});let s="";switch(e){case"png":case"jpg":this._root._runTickerNow(),s=this.exportImage(e,i);break;case"json":s=this.exportJSON(i);break;case"csv":s=this.exportCSV(i);break;case"html":s=this.exportHTML(i);break;case"xlsx":s=this.exportXLSX(i);break;case"pdf":this._root._runTickerNow(),s=this.exportPDF(i);break;case"pdfdata":s=this.exportPDFData(i);break}return this.events.dispatch("exportfinished",{type:"exportfinished",format:e,options:i,target:this}),s})}exportImage(e,t){return Ke(this,void 0,void 0,function*(){let i=this._getFormatOptions(e,t),s=yield this.getCanvas(i),r=s.toDataURL(this.getContentType(e),i.quality||1);return this.disposeCanvas(s),r})}exportCanvas(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("canvas",e),i=yield this.getCanvas(t),s=i.toDataURL(this.getContentType("canvas"),t.quality||1);return this.disposeCanvas(i),s})}getCanvas(e){return Ke(this,void 0,void 0,function*(){let t=this._root._renderer.getCanvas(this._root._rootContainer._display,e),i=this.get("extraImages",[]),s=0,r=0,n=t.width,A=t.height,o=0,l=0,c=[];K(i,w=>{let _;w instanceof Rn?_={source:w,position:"bottom"}:_=w,_.position=_.position||"bottom",_.marginTop=_.marginTop||0,_.marginRight=_.marginRight||0,_.marginBottom=_.marginBottom||0,_.marginLeft=_.marginLeft||0;let T=_.source._renderer.getCanvas(_.source._rootContainer._display,e),Q=T.width+_.marginLeft+_.marginRight,U=T.height+_.marginTop+_.marginBottom;_.position=="top"?(n=_.crop?A:Math.max(n,Q),r+=U):_.position=="right"?(A=_.crop?A:Math.max(A,U),o+=Q):_.position=="left"?(A=_.crop?A:Math.max(A,U),s+=Q):_.position==="bottom"&&(n=_.crop?A:Math.max(n,Q),l+=U),c.push({canvas:T,position:_.position,left:_.marginLeft,top:_.marginTop,width:Q,height:U})});let h=this.getDisposableCanvas();h.width=s+n+o,h.height=r+A+l;let d=h.getContext("2d"),u=this.get("backgroundColor",this.findBackgroundColor(this._root.dom)),g=this.get("backgroundOpacity",1);u&&(d.fillStyle=u.toCSS(g),d.fillRect(0,0,h.width,h.height));let y=s,m=r,b=y+n,B=m+A;return K(c,w=>{w.position=="top"?(m-=w.height,d.drawImage(w.canvas,s+w.left,m+w.top)):w.position=="right"?(d.drawImage(w.canvas,b+w.left,r+w.top),b+=w.width):w.position=="left"?(y-=w.width,d.drawImage(w.canvas,y+w.left,r+w.top)):w.position==="bottom"&&(d.drawImage(w.canvas,s+w.left,B+w.top),B+=w.height)}),d.drawImage(t,s,r),h})}exportJSON(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("json")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getJSON(e))})}getJSON(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("json",e);return JSON.stringify(this.getData("json",e,t.renameFields),(i,s)=>(Gs(s)&&Ve(s,(r,n)=>{s[r]=this.convertToSpecialFormat(r,n,t)}),s),t.indent)})}exportCSV(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("csv")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getCSV(e))})}getCSV(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("csv",e),i="",s="",r=this.getData("csv",t),n=this.getDataFields(r);if(t.pivot){let A=this.get("dataFieldsOrder",[]);ca(n,(o,l)=>{let c=[];t.addColumnNames&&c.push(l);for(let h=r.length,d=0;d<h;d++){let u=r[d][o];c.push(this.convertToSpecialFormat(o,u,t,!0))}i+=s+this.getCSVRow(c,t,void 0,!0),s=`
10
- `},(o,l)=>{let c=A.indexOf(o),h=A.indexOf(l);return c>h?-1:c<h?1:0})}else{for(let A=r.length,o=0;o<A;o++){let l=this.getCSVRow(r[o],t,n);t.reverse?i=l+s+i:i+=s+l,s=`
11
- `}t.addColumnNames&&(i=this.getCSVRow(n,t,void 0,!0)+s+i)}return i})}getCSVRow(e,t,i,s=!1){let r=t.separator||",",n=[];i||(i={},Ve(e,(o,l)=>{i[o]=l}));let A=this.get("dataFieldsOrder",[]);return ca(i,(o,l)=>{let c=this.convertEmptyValue(o,e[o],t),h=s?c:this.convertToSpecialFormat(o,c,t);h=""+h,h=h.replace(/"/g,'""'),(t.forceQuotes||h.search(new RegExp(`"|
12
- |`+r,"g"))>=0)&&(h='"'+h+'"'),n.push(h)},(o,l)=>{let c=A.indexOf(o),h=A.indexOf(l);return c>h?1:c<h?-1:0}),n.join(r)}exportHTML(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("html")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getHTML(e))})}getHTML(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("html",e),i="<table>";t.tableClass&&(i='<table class="'+t.tableClass+'">');let s=this.getData("html",t),r=this.getDataFields(s);if(t.pivot){let n=this.get("dataFieldsOrder",[]);i+=`
13
- <tbody>`,ca(r,(A,o)=>{let l=[];t.addColumnNames&&l.push(o);for(let c=s.length,h=0;h<c;h++){let d=s[h][A];l.push(this.convertToSpecialFormat(A,d,t,!0))}i+=`
14
- `+this.getHTMLRow(l,t,void 0,!0)},(A,o)=>{let l=n.indexOf(A),c=n.indexOf(o);return l>c?-1:l<c?1:0}),i+=`
15
- </tbody>`}else{t.addColumnNames&&(i+=`
16
- <thead>
17
- `+this.getHTMLRow(r,t,void 0,!0,!0)+`
18
- </thead>`),i+=`
19
- <tbody>`;for(let n=s.length,A=0;A<n;A++)i+=`
20
- `+this.getHTMLRow(s[A],t,r);i+=`
21
- </tbody>`}return i+=`
22
- </table>`,i})}getHTMLRow(e,t,i,s=!1,r=!1){let n=" <tr>";t.rowClass&&(n=' <tr class="'+t.rowClass+'">'),i||(i=e);let A=this.get("dataFieldsOrder",[]),o=r?"th":"td",l=!0;return ca(i,(c,h)=>{let d=this.convertEmptyValue(c,e[c],t),u=s?d:this.convertToSpecialFormat(c,d,t);u=""+u,u=u.replace(/[\u00A0-\u9999<>\&]/gim,function(y){return"&#"+y.charCodeAt(0)+";"});let g=o;t.pivot&&l&&(g="th"),t.cellClass?n+=`
23
- <`+g+' class="'+t.cellClass+'">'+u+"</"+g+">":n+=`
24
- <`+g+">"+u+"</"+g+">",l=!1},(c,h)=>{let d=A.indexOf(c),u=A.indexOf(h);return d>u?1:d<u?-1:0}),n+=`
25
- </tr>`,n}exportXLSX(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("xlsx")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getXLSX(e))})}getXLSX(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("xlsx",e),i=yield this.getXLSXLib(),s={bookType:"xlsx",bookSST:!1,type:"base64"},r=this._normalizeExcelSheetName(this.get("title",this._t("Data"))),n={SheetNames:[r],Sheets:{}},A=[],o=this.getData("html",t),l=this.getDataFields(o);if(t.pivot){let c=this.get("dataFieldsOrder",[]);ca(l,(h,d)=>{let u=[];t.addColumnNames&&u.push(d);for(let g=o.length,y=0;y<g;y++){let m=o[y][h];u.push(this.convertToSpecialFormat(h,m,t,!0))}A.push(this.getXLSXRow(u,t,void 0,!0))},(h,d)=>{let u=c.indexOf(h),g=c.indexOf(d);return u>g?1:u<g?-1:0})}else{t.addColumnNames&&A.push(this.getXLSXRow(l,t,void 0,!0));for(let c=o.length,h=0;h<c;h++)A.push(this.getXLSXRow(o[h],t,l))}return n.Sheets[r]=i.utils.aoa_to_sheet(A),this.events.dispatch("workbookready",{type:"workbookready",format:"xlsx",options:t,workbook:n,workbookOptions:s,xlsx:i,target:this}),i.write(n,s)})}_normalizeExcelSheetName(e){return e=e.replace(/([:\\\/?*\[\]]+)/g," "),e.length>30?e.substr(0,30)+"...":e}getXLSXRow(e,t,i,s=!1){let r=[];i||(i=e);let n=this.get("dataFieldsOrder",[]);return ca(i,(A,o)=>{let l=this.convertEmptyValue(A,e[A],t),c=s?l:this.convertToSpecialFormat(A,l,t,!0);r.push(c)},(A,o)=>{let l=n.indexOf(A),c=n.indexOf(o);return l>c?1:l<c?-1:0}),r}_xlsx(){return Ke(this,void 0,void 0,function*(){return yield import("./WBGGAC4P.js")})}getXLSXLib(){return this._xlsx()}exportPDF(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("pdf")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getPDF(e,!0))})}exportPDFData(e){return Ke(this,void 0,void 0,function*(){return"data:"+this.getContentType("pdf")+";"+this.get("charset","utf-8")+","+encodeURIComponent(yield this.getPDF(e,!1,!0))})}getPDF(e,t=!0,i=!1){return Ke(this,void 0,void 0,function*(){let s=this._getFormatOptions("pdf",e),r=this._getFormatOptions("pdfdata",e),n=s.pageOrientation||"portrait",A,o={width:0,height:0};if(t){let b=s.imageFormat||"png",B=this._getFormatOptions(b,s),w=yield this.getCanvas(B);o.width=w.clientWidth,o.height=w.clientHeight,A=w.toDataURL(this.getContentType(b),s.quality||1),this.disposeCanvas(w)}let l=yield this.getPdfmake(),c=[30,30,30,30],h={pageSize:s.pageSize||"A4",pageOrientation:n,pageMargins:s.pageMargins||c,defaultStyle:{font:s.font?s.font.name:void 0},content:[]},d=this.get("title"),u=0;if(d&&(h.content.push({text:d,fontSize:s.fontSize||14,bold:!0,margin:[0,0,0,15]}),u+=50),s.addURL&&(h.content.push({text:this._t("Saved from")+": "+document.location.href,fontSize:s.fontSize,margin:[0,0,0,15]}),u+=50),t&&A){let b=this.getPageSizeFit(h.pageSize,h.pageMargins,u,n);o.width>b[0]||o.height>b[1]?h.content.push({image:A,alignment:s.align||"left",fit:b}):h.content.push({image:A,alignment:s.align||"left"})}(i||s.includeData)&&this.hasData()&&h.content.push({table:yield this.getPDFData(r),fontSize:s.fontSize||14});let g=null,y=null;function m(b){let B={};B.normal=b.normal.path,y[b.normal.path]=b.normal.bytes,b.bold?(B.bold=b.bold.path,y[b.bold.path]=b.bold.bytes):B.bold=b.normal.path,b.italics?(B.italics=b.italics.path,y[b.italics.path]=b.italics.bytes):B.italics=b.normal.path,b.bolditalics?(B.bolditalics=b.bolditalics.path,y[b.bolditalics.path]=b.bolditalics.bytes):B.bolditalics=b.normal.path,g[b.name]=B}return s.font&&(g={},y={},m(s.font),s.extraFonts&&K(s.extraFonts,m)),this.events.dispatch("pdfdocready",{type:"pdfdocready",format:"pdf",options:s,doc:h,target:this}),new Promise((b,B)=>{l.createPdf(h,null,g,y).getBase64(w=>{b(w)})})})}getPDFData(e){return Ke(this,void 0,void 0,function*(){let t=this._getFormatOptions("pdfdata",e),i={body:[]},s=this.getData("html",t),r=this.getDataFields(s);if(t.pivot){let n=this.get("dataFieldsOrder",[]);ca(r,(A,o)=>{let l=[];t.addColumnNames&&l.push(o);for(let c=s.length,h=0;h<c;h++){let d=s[h][A];l.push(this.convertToSpecialFormat(A,d,t,!0))}i.body.push(this.getPDFDataRow(l,t,void 0,!0))},(A,o)=>{let l=n.indexOf(A),c=n.indexOf(o);return l>c?1:l<c?-1:0})}else{t.addColumnNames&&(i.body.push(this.getPDFDataRow(r,t,void 0,!0)),i.headerRows=1);for(let n=s.length,A=0;A<n;A++)i.body.push(this.getPDFDataRow(s[A],t,r))}return i})}getPDFDataRow(e,t,i,s=!1){let r=[];i||(i=e);let n=this.get("dataFieldsOrder",[]);return ca(i,(A,o)=>{let l=this.convertEmptyValue(A,e[A],t),c=s?l:this.convertToSpecialFormat(A,l,t);c=""+c,r.push(c)},(A,o)=>{let l=n.indexOf(A),c=n.indexOf(o);return l>c?1:l<c?-1:0}),r}getPdfmake(){return Fg===void 0&&(Fg=PT()),Fg}getPageSizeFit(e,t,i=0,s="portrait"){let r=[0,0,0,0];W(t)?r=[t,t,t,t]:t.length==2?r=[t[0],t[1],t[0],t[1]]:t.length==4&&(r=t);let A={"4A0":[4767.87,6740.79],"2A0":[3370.39,4767.87],A0:[2383.94,3370.39],A1:[1683.78,2383.94],A2:[1190.55,1683.78],A3:[841.89,1190.55],A4:[595.28,841.89],A5:[419.53,595.28],A6:[297.64,419.53],A7:[209.76,297.64],A8:[147.4,209.76],A9:[104.88,147.4],A10:[73.7,104.88],B0:[2834.65,4008.19],B1:[2004.09,2834.65],B2:[1417.32,2004.09],B3:[1000.63,1417.32],B4:[708.66,1000.63],B5:[498.9,708.66],B6:[354.33,498.9],B7:[249.45,354.33],B8:[175.75,249.45],B9:[124.72,175.75],B10:[87.87,124.72],C0:[2599.37,3676.54],C1:[1836.85,2599.37],C2:[1298.27,1836.85],C3:[918.43,1298.27],C4:[649.13,918.43],C5:[459.21,649.13],C6:[323.15,459.21],C7:[229.61,323.15],C8:[161.57,229.61],C9:[113.39,161.57],C10:[79.37,113.39],RA0:[2437.8,3458.27],RA1:[1729.13,2437.8],RA2:[1218.9,1729.13],RA3:[864.57,1218.9],RA4:[609.45,864.57],SRA0:[2551.18,3628.35],SRA1:[1814.17,2551.18],SRA2:[1275.59,1814.17],SRA3:[907.09,1275.59],SRA4:[637.8,907.09],EXECUTIVE:[521.86,756],FOLIO:[612,936],LEGAL:[612,1008],LETTER:[612,792],TABLOID:[792,1224]}[e];return s=="landscape"&&A.reverse(),A[0]-=r[0]+r[2],A[1]-=r[1]+r[3]+i,A}hasData(){let e=this.get("dataSource");return!!(kh(e)&&e.length)}getData(e,t,i=!1){let s=this._getFormatOptions(e,t),r=this.get("dataSource",[]),n=r,A=this.get("dataFields");A&&kh(r)&&(n=[],K(r,l=>{if(Gs(l)){let c={};Ve(A,(h,d)=>{A[h]!=null&&(c[i?d:h]=this.convertToSpecialFormat(h,l[h],s))}),n.push(c)}}));let o={type:"dataprocessed",format:e,options:s,data:n,target:this};return this.events.dispatch("dataprocessed",o),o.data}getDataFields(e){let t=this.get("dataFields");return t||(t={},kh(e)&&e.length&&K(e,i=>{Ve(i,(s,r)=>{t[s]==null&&(t[s]=s)})})),t}convertEmptyValue(e,t,i){return t??i.emptyAs}convertToSpecialFormat(e,t,i,s){if(typeof t=="number")if(this.isDateField(e))t=new Date(t);else{if(this.isNumericField(e)&&this.get("numberFormat"))return this._root.numberFormatter.format(t,this.get("numberFormat"));if(this.isDurationField(e))return this._root.durationFormatter.format(t,this.get("durationFormat"),this.get("durationUnit"))}return t instanceof Date&&(i.useTimestamps?t=t.getTime():i.useLocale?s||(t=t.toLocaleString()):t=this._root.dateFormatter.format(t,this.get("dateFormat"))),t}isDateField(e){return this.get("dateFields").indexOf(e)!==-1}isNumericField(e){return this.get("numericFields").indexOf(e)!==-1}isDurationField(e){return this.get("durationFields").indexOf(e)!==-1}getContentType(e){let t="";switch(e){case"png":t="image/"+e;break;case"jpg":t="image/jpeg";break;case"csv":t="text/csv";break;case"json":t="application/json";break;case"html":t="text/html";break;case"pdf":case"pdfdata":t="application/pdf";break;case"xlsx":t="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";break;default:t="application/octet-stream"}return t}getDisposableCanvas(){let e=document.createElement("canvas");return e.style.position="fixed",e.style.top="-10000px",this._root.dom.appendChild(e),e}disposeCanvas(e){this._root.dom.removeChild(e)}findBackgroundColor(e){let t=1,i=getComputedStyle(e,"background-color").getPropertyValue("background-color");if((i.match(/[^,]*,[^,]*,[^,]*,[ ]?0/)||i=="transparent")&&(t=0),t==0){let s=e.parentElement;return s?this.findBackgroundColor(s):we.fromHex(16777215)}else return we.fromCSS(i)}streamFile(e,t,i=!1){if(this.blobDownloadSupport()){let s=document.createElement("a");s.download=t,document.body.appendChild(s);let r=e.split(";"),n=r.shift().replace(/data:/,"");if(e=decodeURIComponent(r.join(";").replace(/^[^,]*,/,"")),["image/svg+xml","application/json","text/csv","text/html"].indexOf(n)==-1)try{e=atob(e)}catch{return!1}else{i&&(e="\uFEFF"+e);let c=new Blob([e],{type:n}),h=window.URL.createObjectURL(c);return s.href=h,s.download=t,s.click(),setTimeout(()=>{document.body.removeChild(s),window.URL.revokeObjectURL(h)},100),!0}let A=new Array(e.length);for(let c=0;c<e.length;++c){let h=e.charCodeAt(c);A[c]=h}i&&(A=[239,187,191].concat(A));let o=new Blob([new Uint8Array(A)],{type:n}),l=window.URL.createObjectURL(o);s.href=l,s.download=t,document.body.appendChild(s),s.click(),document.body.removeChild(s),setTimeout(()=>{window.URL.revokeObjectURL(l)},100)}else if(this.linkDownloadSupport()){let s=document.createElement("a");s.download=t,s.href=e,document.body.appendChild(s),s.click(),document.body.removeChild(s)}else window.location.href=e;return!0}downloadSupport(){return this.linkDownloadSupport()}linkDownloadSupport(){return typeof document.createElement("a").download<"u"}blobDownloadSupport(){return window.Blob!=null}initiatePrint(e,t,i){let s=this._getFormatOptions("print",t);s.printMethod=="css"?this._printViaCSS(e,s,i):this._printViaIframe(e,s,i)}_printViaCSS(e,t,i){let r=this._getFormatOptions("print",t).delay||500,n=document.documentElement.scrollTop||document.body.scrollTop,A=new Po(uf(this._root.dom),"body > *",{display:"none",position:"fixed",visibility:"hidden",opacity:"0",clipPath:"polygon(0px 0px,0px 0px,0px 0px,0px 0px);"},this._root.nonce),o=new Po(uf(this._root.dom),"body",{padding:"0",margin:"0"},this._root.nonce),l;i&&document&&document.title&&(l=document.title,document.title=i);let c=new Image;c.src=e,c.style.maxWidth="100%",c.style.display="block",c.style.position="relative",c.style.visibility="visible",c.style.opacity="1",c.style.clipPath="none",document.body.appendChild(c),this.setTimeout(()=>{window.print()},50),/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream&&r<1e3?r=1e3:r<100&&(r=100),this.setTimeout(()=>{document.body.removeChild(c),A.dispose(),o.dispose(),l&&(document.title=document.title),document.documentElement.scrollTop=document.body.scrollTop=n},r||500)}_printViaIframe(e,t,i){let r=this._getFormatOptions("print",t).delay||500,n=document.createElement("iframe");n.style.visibility="hidden",document.body.appendChild(n),n.contentWindow.document.open(),n.contentWindow.document.close();let A=new Image;A.src=e,A.style.maxWidth="100%",A.style.height="auto",i&&(n.contentWindow.document.title=i),n.contentWindow.document.body.appendChild(A),n.load=function(){n.contentWindow.document.body.appendChild(A)},this.setTimeout(()=>{try{n.contentWindow.document.execCommand("print",!1,null)||n.contentWindow.print()}catch{n.contentWindow.print()}},r||50),/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream&&r<1e3?r=1e3:r<100&&(r=100),this.setTimeout(()=>{document.body.removeChild(n)},r+50||100)}supportedFormats(){let e=[],t=this.hasData(),i=this.downloadSupport();return K(["png","jpg","canvas","pdf","xlsx","csv","json","html","pdfdata","print"],s=>{this._getFormatOptions(s).disabled!==!0&&(["xlsx","csv","json","html","pdfdata"].indexOf(s)==-1||t&&i)&&e.push(s)}),e}supportedExportTypes(){let e=["image","print"];return this.downloadSupport()&&this.hasData()&&e.push("data"),e}};An.className="Exporting";An.classNames=nt.classNames.concat([An.className]);var bc={exports:{}},Tg,Fb;function MT(){if(Fb)return Tg;Fb=1;function a(e){var t=new e,i=t;function s(){var n=t;return n.next?t=n.next:(t=new e,i=t),n.next=null,n}function r(n){i.next=n,i=n}return{get:s,release:r}}return Tg=a,Tg}var Sb;function HT(){if(Sb)return bc.exports;Sb=1;var a=MT();function e(r,n,A){if(typeof r=="function"&&(A=n,n=r,r=null),A<1)throw new Error("fastqueue concurrency must be greater than 1");var o=a(i),l=null,c=null,h=0,d=null,u={push:_,drain:t,saturated:t,pause:y,paused:!1,concurrency:A,running:g,resume:B,idle:w,length:m,getQueue:b,unshift:T,empty:t,kill:U,killAndDrain:E,error:O};return u;function g(){return h}function y(){u.paused=!0}function m(){for(var D=l,k=0;D;)D=D.next,k++;return k}function b(){for(var D=l,k=[];D;)k.push(D.value),D=D.next;return k}function B(){if(u.paused){u.paused=!1;for(var D=0;D<u.concurrency;D++)h++,Q()}}function w(){return h===0&&u.length()===0}function _(D,k){var F=o.get();F.context=r,F.release=Q,F.value=D,F.callback=k||t,F.errorHandler=d,h===u.concurrency||u.paused?c?(c.next=F,c=F):(l=F,c=F,u.saturated()):(h++,n.call(r,F.value,F.worked))}function T(D,k){var F=o.get();F.context=r,F.release=Q,F.value=D,F.callback=k||t,h===u.concurrency||u.paused?l?(F.next=l,l=F):(l=F,c=F,u.saturated()):(h++,n.call(r,F.value,F.worked))}function Q(D){D&&o.release(D);var k=l;k?u.paused?h--:(c===l&&(c=null),l=k.next,k.next=null,n.call(r,k.value,k.worked),c===null&&u.empty()):--h===0&&u.drain()}function U(){l=null,c=null,u.drain=t}function E(){l=null,c=null,u.drain(),u.drain=t}function O(D){d=D}}function t(){}function i(){this.value=null,this.callback=t,this.next=null,this.release=t,this.context=null,this.errorHandler=null;var r=this;this.worked=function(n,A){var o=r.callback,l=r.errorHandler,c=r.value;r.value=null,r.callback=t,r.errorHandler&&l(n,c),o.call(r.context,n,A),r.release(r)}}function s(r,n,A){typeof r=="function"&&(A=n,n=r,r=null);function o(y,m){n.call(this,y).then(function(b){m(null,b)},m)}var l=e(r,o,A),c=l.push,h=l.unshift;return l.push=d,l.unshift=u,l.drained=g,l;function d(y){var m=new Promise(function(b,B){c(y,function(w,_){if(w){B(w);return}b(_)})});return m.catch(t),m}function u(y){var m=new Promise(function(b,B){h(y,function(w,_){if(w){B(w);return}b(_)})});return m.catch(t),m}function g(){var y=l.drain,m=new Promise(function(b){l.drain=function(){y(),b()}});return m}}return bc.exports=e,bc.exports.promise=s,bc.exports}var RT=HT();function il(a){let{value:e,axisMin:t,axisMax:i}=a,s=Number.NaN,r=i-t;return r!==0&&(s=(e-t)/r),s}function Qg(a){return a!=null&&a!==0}function hB(a){let{minimum:e,maximum:t,labelsIncrement:i,minimumValueConversion:s,maximumValueConversion:r}=a,n=e??Ht.gauge.axisMinimum,A=t??Ht.gauge.axisMaximum;n=au(n,s),A=au(A,r);let o=Qg(i),l=Qg(i)?i:Math.abs(A-n)/Ht.gauge.numberOfLabelIntervals,c=o?Math.round(Math.abs(A-n)/l):Ht.gauge.numberOfLabelIntervals;if(o)if(c>Ht.gauge.maximumNumberOfLabelIntervals)l=Math.abs(A-n),c=1;else{let h=n+c*l;h<A?(c+=1,A=n+c*l):h>A&&(A=h)}return{min:n,max:A,labelsIncrement:l,numberOfIntervals:c}}function cB(a){let{axisConfig:e,axisMin:t,axisMax:i}=a;typeof t=="number"&&typeof i=="number"&&i-t!==0&&e.guides?.forEach(s=>{let{start:r,end:n}=s;typeof r=="number"&&(s.start=il({value:r,axisMin:t,axisMax:i})),typeof n=="number"&&(s.end=il({value:n,axisMin:t,axisMax:i}))})}function OT(a){let{featureIndex:e,chartData:t,chartConfig:i}=a,{minimumFromField:s,maximumFromField:r}=i?.axes?.[0]??{},n,A;if(e>=0&&e<t.length){let o=t[e];typeof s=="string"&&!ii(s)&&Number.isFinite(o[s])&&(n=o[s]),typeof r=="string"&&!ii(r)&&Number.isFinite(o[r])&&(A=o[r])}return{minimumFromData:n,maximumFromData:A}}function NT(a){let{featureIndex:e,chartData:t,x:i}=a,s=-1;if(e>=0&&e<t.length){let r=t[e];i!==void 0&&!ii(i)&&Number.isFinite(r[i])&&(s=r[i])}return s}async function dB(a){let{featureIndex:e=0,chartData:t,queryConfig:i,chartConfig:s,queryObject:r}=a,{axes:n,series:A}=s,o=dh(s),{minimum:l,maximum:c}=n?.[0]??{},{x:h}=A?.[0]??{},d=Ht.gauge,u,g;o?{minimumFromData:u,maximumFromData:g}=OT({featureIndex:e,chartData:t,chartConfig:s}):i!==void 0&&({minimumFromData:u,maximumFromData:g}=await u0({queryObject:r,chartConfig:s,queryConfig:i}));let y=u??l??d.axisMinimum,m=g??c??d.axisMaximum,b=NT({chartData:t,featureIndex:e,x:h});return{minimum:y,maximum:m,dataValue:b}}function VT(a){let{oldConfig:e,axisMax:t,min:i,max:s,labelsIncrement:r,numberOfIntervals:n,valueFormat:A,minimumFromField:o}=a,l=wn(A),c=!0;if(e!==void 0){let{minimum:h,minimumFromField:d,labelsIncrement:u,valueFormat:g}=e.axes[0],y=g?.intlOptions?.style!==A?.intlOptions?.style,m=Qg(u)?u!==r:n!==Ht.gauge.numberOfLabelIntervals;c=y||i!==h||o!==d||!l&&s!==t||m}return c}var Ti={InnerLabel:0,InnerLabelSecondary:1,AxisLabels:2,FirstAndLastLabels:3};function on(a,e){let t;switch(e){case Ti.InnerLabel:t="gaugeAutoResizeInnerLabelFirstDisposer";break;case Ti.InnerLabelSecondary:t="gaugeAutoResizeInnerLabelSecondDisposer";break;case Ti.AxisLabels:t="gaugeAutoResizeAxisLabelsDisposer";break;case Ti.FirstAndLastLabels:t="gaugeAutoResizeFirstAndLastLabelsDisposer";break}if(t!==void 0){let i=et(a.uid,t);i!==void 0&&(i.dispose(),i=void 0,Ft(a.uid,{[t]:void 0}))}}function $T(a){let{chart:e,labelList:t,scaleToAdjust:i,fontSize:s,type:r,axisConfig:n}=a,A=Number.NaN,o=Number.NaN,l=i;if(r===Ti.InnerLabel){let h=t[0],d=n?.innerLabel?.content?.verticalAlignment??Ct.Middle,u=h.dy??0,g=Math.round(e.chartContainer.measuredHeight-e.radarContainer.pixelY-u),y=h.bbox.height*i,m=0;switch(d){case Ct.Bottom:m=y;break;case Ct.Top:m=-y;break;case Ct.Middle:case Ct.Baseline:m=y*.5;break}m>g&&(l=i*(g/m)),A=Te.gauge.innerLabelAutoMinFontSize,o=Te.gauge.innerLabelAutoMaxFontSize}else A=Te.gauge.axisLabelAutoMinFontSize,o=Te.gauge.axisLabelAutoMaxFontSize;let c=s*l;return c<A?l*=A/c:c>o&&(l*=o/c),l}function Wg(a){let{chart:e,type:t,labelList:i,currentScale:s,currentFontSize:r,axisConfig:n}=a,A=Number.NaN,o=Number.NaN;if(t===Ti.InnerLabel){let l=typeof e.innerRadius=="number"?e.innerRadius:e.innerRadius.value;o=(e.xAxes.getIndex(0)?.measuredWidth!==0?e.xAxes.getIndex(0)?.measuredWidth??1:1)*l}else o=e.xAxes.getIndex(0)?.measuredHeight??1;if(o>1){let l=t===Ti.InnerLabel?i[0]?.measuredWidth??0:i.find(c=>c.measuredWidth>0&&c.measuredHeight>0)?.measuredHeight??0;if(l>0){let c=l/o;if(c>0){let{axisLabelToInnerChartRatio:h,innerLabelToInnerChartRatio:d}=Te.gauge,u=t===Ti.InnerLabel?d:h;A=s*(u/c),A=$T({chart:e,labelList:i,axisConfig:n,scaleToAdjust:A,fontSize:r,type:t}),A=Number(A.toFixed(2))}}}return Number.isFinite(A)||(A=s),A}function KT(a){return a?.labels.content.font?.size===void 0||a?.innerLabel?.visible!==!1&&a?.innerLabel?.content?.font?.size===void 0}function Ic(a){return a.some(e=>vo(e)&&e.value!==void 0)}function GT(a){let{chart:e,axisConfig:t,axis:i}=a;if(t.labels.content.font?.size===void 0&&t.onlyShowFirstAndLastLabels!==!0){on(e,Ti.AxisLabels),on(e,Ti.FirstAndLastLabels);let s=()=>{i.events.once(Wt.Validated,()=>{let n=Ks(i,bi.GaugeTicksWithLabels);if(Ic(n)){let A=n.map(d=>d.label),o=A[0].scale,l=A[0].fontSize,c=Wg({chart:e,type:Ti.AxisLabels,labelList:A,currentScale:o,currentFontSize:l,axisConfig:t}),h=c/o;Number.isFinite(c)&&c>0&&(h<=.98||h>1.02)&&A.forEach(d=>{d.scale=c})}}),i.validate()};e.events.once(Wt.Validated,s);let r=e.events.on(Wt.SizeChanged,s);Ft(e.uid,{gaugeAutoResizeAxisLabelsDisposer:r}),s()}else{on(e,Ti.AxisLabels);let s=Ks(i,bi.GaugeTicksWithLabels);s.length>0&&s.map(r=>r.label).forEach(r=>{r.scale=1})}}function XT(a,e){let t=et(a.uid,"config")?.axes?.[0];if(t?.innerLabel?.visible!==!1&&t?.innerLabel?.content?.font?.size===void 0){let i=a.xAxes.getIndex(0)?.measuredWidth;if(i!==void 0&&i>0){let s=Wg({chart:a,type:Ti.InnerLabel,labelList:[e],currentScale:e.scale,currentFontSize:e.fontSize,axisConfig:t});Number.isFinite(s)&&Math.abs(e.scale-s)>.25&&(e.scale=s,e.validate())}}else e.scale=1}function WT(a,e){on(a,Ti.InnerLabel),on(a,Ti.InnerLabelSecondary);let t=a.xAxes.getIndex(0),i=()=>{t?.events.once(Wt.Validated,()=>{XT(a,e)})},s=a.events.on(Wt.Validated,i),r=a.events.on(Wt.SizeChanged,i);Ft(a.uid,{gaugeAutoResizeInnerLabelFirstDisposer:r,gaugeAutoResizeInnerLabelSecondDisposer:s}),i()}function kg(a){return a?.labels.content.font?.size===void 0&&a?.onlyShowFirstAndLastLabels===!0}function zT(a){let e=a.chart,t=et(e.uid,"config")?.axes?.[0],i=Ks(a,bi.GaugeFirstAndLastGuides);if(Ic(i)){let s=i.map(o=>o.label),r=s[0].scale,n=s[0].fontSize,A=Wg({chart:e,type:Ti.FirstAndLastLabels,labelList:s,currentScale:r,currentFontSize:n,axisConfig:t});Number.isFinite(A)&&A>0&&s.forEach(o=>{vh(o.uid,{originalWidth:o.measuredWidth/o.scale,originalHeight:o.measuredHeight/o.scale}),o.scale=A,o.validate()})}}function YT(a){let{chart:e,axisConfig:t,axis:i}=a;if(kg(t)){on(e,Ti.AxisLabels),on(e,Ti.FirstAndLastLabels);let s=()=>{i.events.once(Wt.Validated,()=>{zT(i)})},r=e.events.on(Wt.SizeChanged,s);Ft(e.uid,{gaugeAutoResizeFirstAndLastLabelsDisposer:r}),s()}else on(e,Ti.FirstAndLastLabels),Ks(i,bi.GaugeFirstAndLastGuides).map(s=>s.label).forEach(s=>{s.scale=1})}function Eg(a,e){let t=a.xAxes.getIndex(0);if(t!==void 0){let i=e??et(a.uid,"config"),{onlyShowFirstAndLastLabels:s}=i?.axes?.[0]??{};if(!t.renderer.labels.template.visible||s===!0)a.radius=new zl(Te.gauge.radius);else{let r=Ks(t,bi.GaugeTicksWithLabels),{furthestLabelX:n,furthestLabelY:A}=r.reduce(({furthestLabelX:o,furthestLabelY:l,furthestPixelX:c,furthestPixelY:h},{label:d})=>{if(d?.visible&&d.bbox.width>0&&d.bbox.height>0){let u=d.pixelX,g=d.bbox.width*d.scale,y=0;u<0?y=Math.abs(u):y=u+g,y>c&&(c=y,o=d);let m=d.pixelY,b=d.bbox.height*d.scale,B=0;m<0?B=Math.abs(m):B=m+b,B>h&&(h=B,l=d)}return{furthestLabelX:o,furthestLabelY:l,furthestPixelX:c,furthestPixelY:h}},{furthestLabelX:void 0,furthestPixelX:0,furthestLabelY:void 0,furthestPixelY:0});if(n!==void 0&&A!==void 0){let o=(n.bbox.width+5)*n.scale,l=(A.bbox.height+5)*A.scale,c=typeof t.renderer.labels.template.radius=="number"?t.renderer.labels.template.radius:t.renderer.labels.template.radius.value,h=(o+c)*2+a.radarContainer.measuredWidth+wo(a.paddingLeft)+wo(a.paddingRight),d=80,u=170,g=a.htmlContainer?.clientHeight??0,y=Math.max(0,Math.min(1,(g-d)/(u-d))),m=a.radarContainer.measuredHeight+(l+c*y)*2+wo(a.paddingTop)+wo(a.paddingBottom),b=a.measuredWidth,B=a.measuredHeight,w=b/h,_=B/m,T=(typeof a.radius=="number"?a.radius:a.radius.value)*100,Q=Number((T*w).toFixed(2)),U=Number((T*_).toFixed(2)),E=Q/T,O=U/T,D=a.radarContainer.measuredWidth*E,k=a.radarContainer.measuredWidth*O,[F,M]=D<k?[Q,E]:[U,O];Number.isFinite(F)&&F>=10&&F<=Te.gauge.radius&&(M<.98||M>1.02)&&(a.radius=new zl(F))}}}}function jT(a){let e=a.xAxes.getIndex(0);e!==void 0&&(e.events.on(Wt.SizeChanged,()=>Eg(a)),e.events.on(Wt.Validated,Ao(()=>Eg(a),Te.debounceTime)))}function uB(a){let e=a.hands.push(new Ty),t=Te.gaugeNeedle,{startWidth:i,endWidth:s,innerRadius:r}=t;e.pin.disabled=!0,e.startWidth=i??Number.NaN,e.endWidth=s??Number.NaN,e.innerRadius=ji(r??Number.NaN);let n=a.xAxes.getIndex(0);return n!==void 0&&(e.axis=n),e}function ZT(a){let{x:e,data:t,chart:i,valueFormat:s,minimum:r,maximum:n}=a,A=Number.NaN;if(t!==void 0&&e!==void 0){let o=t.find(c=>e in c),l=Number.parseFloat(o[e]);Number.isFinite(l)&&(A=l,Ft(i.uid,{gaugeData:A}))}else{let o=et(i.uid,"gaugeData");Number.isFinite(o)&&(A=o)}return wn(s)&&r!==void 0&&n!==void 0&&r!==null&&n!==null&&A!==null&&n-r!==0&&(A=il({value:A,axisMin:r,axisMax:n})),A}function qT(a,e){let t=e??null;if(e!=null){let i=a.xAxes.getIndex(0),s=et(a.uid,"config"),r=i.min??s?.axes?.[0].minimum??Te.gauge.axisMinimum,n=i.max??s?.axes?.[0].maximum??Te.gauge.axisMaximum;e<r?t=r:e>n&&(t=n)}return t}function JT(a){let{chart:e,needle:t,gaugeValue:i}=a,s=e.hands.getIndex(0)??uB(e);if(s!==void 0){Du({element:s,fillSymbol:t?.symbol});let{startWidth:r,endWidth:n,innerRadius:A}=Te.gaugeNeedle;s.value=qT(e,i),s.pin.disabled=t?.displayPin!==!0,s.visible=t?.visible??!0,s.startWidth=t?.startWidth??r,s.endWidth=t?.endWidth??n,s.innerRadius=ji(t?.innerRadius??A)}}function eI(a){let e=Co(void 0,a.radarContainer);e.isMeasured=!1,vh(e.uid,{isGaugeAxisInnerLabel:!0}),WT(a,e)}function tI(a){let{chart:e,innerLabelConfig:t,valueFormat:i,gaugeValue:s,gaugeInnerLabelFormatter:r}=a,n=e.radarContainer.children.values.find(A=>bo(A.uid,"isGaugeAxisInnerLabel")===!0);if(n!==void 0){Ln({label:n,labelConfig:t,defaults:Te.gaugeInnerLabel});let A=et(e.uid,"formatLocale");n.html=dI({valueFormat:i,iLocale:e.language.locale,formatLocale:A,gaugeValue:s,innerLabelConfigContent:t?.content,gaugeInnerLabelFormatter:r}),e.radarContainer.invalidateLabels()}}function iI(a){let e=a.axisRanges.create();return e.axisFill.fillOpacity=1,e.axisFill.disabled=!0,e.grid.strokeOpacity=1,e.grid.disabled=!1,e.tick.length=Te.gaugeTicksLength,e}function sI(a){let e=new Sy;return e.disabled=!0,e.axis=a,Uv(e),e.padding(10,10,10,10),vh(e.uid,{isGaugeAxisLabel:!0}),e}function rI(a){let{axis:e,min:t,max:i,labelsIncrement:s,numberOfIntervals:r,valueFormat:n}=a,A=wn(n),o=1,l=Ks(e,bi.Ticks);l.length>0&&(o=l[0].label?.scale,l.forEach(d=>{if(vo(d)){let u=e.axisRanges.values.indexOf(d);u>=0&&e.axisRanges.removeIndex(u)}}));let c=Te.gauge.numberOfTicksBetweenTwoLabels+1,h=r*c+1;for(let d=0;d<h;d+=1){let u=d===h-1,g=iI(e),y=u?i:t+d/c*s;g.value=A?il({value:y,axisMin:t,axisMax:i}):y,d%c===0&&(g.label=sI(e),g.label.text=String(y),g.grid.disabled=!0,Number.isFinite(o)&&(g.label.scale=o))}}function aI(a){let{chart:e,axis:t,onlyShowFirstAndLastLabels:i,valueFormat:s,axisLabelConfigContent:r,axisValueFormatter:n}=a;if(!i){let A=Ks(t,bi.GaugeTicksWithLabels);if(Ic(A)){let o=et(e.uid,"formatLocale");A.forEach(l=>{Ln({label:l.label,labelConfig:r}),vo(l)&&(l.label.html=fB({valueFormat:s,iLocale:e.language.locale,formatLocale:o,gaugeLabelConfigContent:r?.content,itemLabelValue:l.value,axisValueFormatter:n}))})}}}function nI(a,e){let t=e?.ticks?.visible??!0,i=Ks(a,bi.Ticks);for(let s=0;s<i.length;s+=1){let r=i[s];xh(r.tick,t)}}function AI(a,e){if(a instanceof Dd&&a.chart instanceof ka){let t=Ks(a,bi.GaugeTicksWithLabels);if(Ic(t)){let{onlyShowFirstAndLastLabels:i,labels:s}=e,r=(s?.visible??!0)&&i!==!0;t.forEach(n=>{xh(n.label,r)})}}}function oI(a){let{labels:e,guides:t,onlyShowFirstAndLastLabels:i}=a,s=t??[];if(i===!0){let r={type:P.Guide,start:Number.NaN,style:{type:"esriSLS"},name:""};s.push({...r,start:a.minimum??Number.NaN,name:Te.gaugeFirstLabelId,label:{...e.content,text:`${a.minimum}`}},{...r,start:a.maximum??Number.NaN,name:Te.gaugeLastLabelId,label:{...e.content,text:`${a.maximum}`}})}a.guides=s}function lI(a){Ks(a,bi.GaugeFirstAndLastGuides).forEach(e=>{e.label.adapter.keys().includes("dx")||e.label.adapter.add("dx",t=>{let i=t;if(e.label.measuredWidth>0){let s=et(a.chart.uid,"config")?.axes?.[0],r=bo(e.label.uid,"originalWidth"),n=kg(s)&&r!==void 0&&r===e.label.measuredWidth&&e.label.scale!==1;i=Math.round((n?r*e.label.scale:e.label.measuredWidth)/2),e.id===Te.gaugeLastLabelId&&(i*=-1)}return i}),e.label.adapter.keys().includes("dy")||e.label.adapter.add("dy",t=>{let i=t;if(e.label.measuredHeight>0){let s=et(a.chart.uid,"config")?.axes?.[0],r=bo(e.label.uid,"originalHeight"),n=kg(s)&&r!==void 0&&r===e.label.measuredHeight&&e.label.scale!==1;i=Math.round((n?r*e.label.scale:e.label.measuredHeight)/2)}return i})})}function hI(a){let{chart:e,axis:t,onlyShowFirstAndLastLabels:i,valueFormat:s,gaugeLabelConfigContent:r,axisValueFormatter:n}=a;if(i){let A=Ks(t,bi.GaugeFirstAndLastGuides),o=et(e.uid,"formatLocale");A.forEach(l=>{l?.label!==void 0&&vo(l)&&(l.label.html=fB({valueFormat:s,iLocale:e.language.locale,formatLocale:o,gaugeLabelConfigContent:r?.content,itemLabelValue:l.value,axisValueFormatter:n}))}),lI(t)}}function cI(a){let{chart:e,valueFormat:t,queryObject:i}=a;e.xAxes.clear(),Yu({isXAxis:!0,axes:e.xAxes,valueFormat:t,queryObject:i});let s=e.xAxes.getIndex(0);s instanceof Dd&&(s.renderer.labels.template.disabled=!0,s.renderer.ticks.template.disabled=!0,uB(e),eI(e),jT(e),s.maxZoomFactor=1)}function dI(a){let{valueFormat:e,iLocale:t,formatLocale:i,innerLabelConfigContent:s,gaugeValue:r,gaugeInnerLabelFormatter:n}=a,A="";if(Number.isFinite(r))if(n!==void 0)A=n(r);else{let o=fA(e),l=Su({type:P.NumberAxisFormat,iLocale:t,formatLocale:i});l.numberFormat=o,A=l.format(`${r}`),A=nr({textSymbol:{type:ht.TS,...s,text:A},format:"html"}),A=vs(A)}return A}function fB(a){let{valueFormat:e,iLocale:t,formatLocale:i,gaugeLabelConfigContent:s,itemLabelValue:r,axisValueFormatter:n}=a,A="";if(Number.isFinite(r))if(n!==void 0)A=n(r);else{let o=fA(e),l=Su({type:P.NumberAxisFormat,iLocale:t,formatLocale:i});l.numberFormat=o,A=l.format(`${r}`),A=nr({textSymbol:{type:ht.TS,...s,text:A},format:"html"}),A=vs(A)}return A}async function uI(a){let{chart:e,chartConfig:t,data:i,queryObject:s,axisValueFormatter:r,gaugeInnerLabelFormatter:n,utilsStrings:A,errorStrings:o}=a,{axes:l,series:c}=t,h=dh(t),d=Oe(t.series),{featureIndex:u,x:g}=c[0],y=l?.[0],m=e.xAxes.getIndex(0),b={...y};if(m!==void 0&&b!==void 0){let{valueFormat:B,needle:w,innerLabel:_,onlyShowFirstAndLastLabels:T}=b;pv({axis:m,valueFormat:B,chartType:d})&&Yu({isXAxis:!0,axes:e.xAxes,valueFormat:B,queryObject:s});let Q=await dB({featureIndex:u,chartData:e.data,chartConfig:t,queryObject:s,queryConfig:et(e.uid,"queryConfig")});b.minimum=Q.minimum,b.maximum=Q.maximum;let{min:U,max:E,labelsIncrement:O,numberOfIntervals:D}=hB(b);VT({oldConfig:et(m.chart.uid,"config"),axisMax:m.max,min:U,max:E,labelsIncrement:O,numberOfIntervals:D,valueFormat:B})&&rI({axis:m,min:U,max:E,labelsIncrement:O,numberOfIntervals:D,valueFormat:B});let k={...b};wn(B)?(k.minimum=0,k.maximum=1,cB({axisConfig:k,axisMin:b.minimum,axisMax:b.maximum})):(k.minimum=U,k.maximum=E),oI(k),sx({axis:m,axisConfig:k,axisConfigIndex:0,chartType:P.GaugeSeries,axisValueFormatter:r,isTimeOnlyField:!1,utilsStrings:A,errorStrings:o}),m.renderer.labels.template.disabled||(m.renderer.labels.template.disabled=!0),m.renderer.ticks.template.disabled||(m.renderer.ticks.template.disabled=!0),GT({chart:m.chart,axis:m,axisConfig:b}),YT({chart:e,axis:m,axisConfig:b}),nI(m,b),aI({chart:e,axis:m,onlyShowFirstAndLastLabels:T??!1,valueFormat:B,axisLabelConfigContent:b.labels,axisValueFormatter:r}),hI({chart:e,axis:m,onlyShowFirstAndLastLabels:T??!1,valueFormat:B,gaugeLabelConfigContent:b.labels,axisValueFormatter:r});let F=h?Q?.dataValue:ZT({x:g,data:i,chart:e,minimum:b.minimum,maximum:b.maximum,valueFormat:B});JT({chart:e,needle:w,gaugeValue:F}),tI({chart:e,innerLabelConfig:_,valueFormat:B,gaugeValue:F,gaugeInnerLabelFormatter:n}),AI(m,b),Eg(e,t),e.validateData()}}function fI(a){a.background.fill=Iu(Te.backgroundColor)}function Dc(a,e){a.background.fill=Iu(e??Te.backgroundColor)}function gI(a){let e=Vu(Te.headerContainer,a),t=Co(Te.title,e),i=Co(Te.subtitle,e);return Sh({chart:a,label:t,labelType:St.ChartTitle}),Sh({chart:a,label:i,labelType:St.ChartSubTitle}),Wv(e),{headerContainer:e,title:t,subtitle:i}}function Lc(a,e){let{title:t,subtitle:i,headerContainer:s}=a;Ln({label:t,labelConfig:e?.title,defaults:Te.titleLabel}),Ln({label:i,labelConfig:e?.subtitle,defaults:Te.titleLabel}),$u(s,t.disabled&&i.disabled),Fh({chart:t.parent,label:t,labelType:St.ChartTitle}),Fh({chart:i.parent,label:i,labelType:St.ChartSubTitle})}function pI(a){let e=Vu(Te.footerContainer,a),t=Co(Te.footer,e);return Sh({chart:a,label:t,labelType:St.ChartFooter}),{footerContainer:e,footer:t}}function Uc(a,e){let{footer:t,footerContainer:i}=a;Ln({label:t,labelConfig:e,defaults:Te.footer}),$u(i,t.disabled||e?.content.text===""),Fh({chart:t.parent,label:t,labelType:St.ChartFooter})}function gB(a){if(a instanceof Is){let e=new Id,t=new Id;e.disabled=!0,t.disabled=!0,e.marginTop=-10,t.marginRight=0,a.scrollbarX=e,a.scrollbarY=t}}function mI(a,e){let t=e?0:-1;a.thumb.tabindex=t,a.startGrip.tabindex=t,a.endGrip.tabindex=t}function yI(a,e){if(e!==void 0){let t=Tu(e);[a.background,a.startGrip.background,a.endGrip.background,a.thumb.background,a.background.states.getKey("default")?.properties,a.startGrip.background.states.getKey("default")?.properties,a.endGrip.background.states.getKey("default")?.properties,a.thumb.background.states.getKey("default")?.properties,a.startGrip.background.states.getKey("hover")?.properties,a.endGrip.background.states.getKey("hover")?.properties,a.thumb.background.states.getKey("hover")?.properties,a.startGrip.background.states.getKey("down")?.properties,a.endGrip.background.states.getKey("down")?.properties,a.thumb.background.states.getKey("down")?.properties].forEach(i=>{i!==void 0&&(i.fill=t)})}}function vI(a,e){typeof e=="number"&&Number.isFinite(e)&&(a.orientation==="horizontal"?(a.height=e,a.minHeight=e):(a.width=e,a.minWidth=e))}function xI(a,e){if(typeof e=="number"&&Number.isFinite(e)){let t=e/30;a.startGrip.scale=t,a.endGrip.scale=t}}function bI(a,e){typeof e=="number"&&Number.isFinite(e)&&(a.orientation==="horizontal"?a.marginBottom=e:a.marginLeft=e,a.parent?.invalidateLayout())}function pB(a){let{chart:e,scrollbarXConfig:t,scrollbarYConfig:i}=a;if(e instanceof Is){let s=et(e.uid,"isRotated");(e.scrollbarX===void 0||e.scrollbarY===void 0)&&gB(e);let{scrollbarX:r,scrollbarY:n}=e;[r,n].forEach(A=>{let o=A.orientation==="horizontal"&&s!==!0||A.orientation==="vertical"&&s===!0?t:i,l=o?.visible!==!0;if(A.disabled=l,mI(A,!l),o!==void 0&&!l){let{width:c,color:h,gripSize:d,margin:u}=o;bI(A,u),yI(A,h),xI(A,d),vI(A,c)}})}}function BI(a,e){a.columns.each(t=>{(t.dataItem?.dataContext)[e]===0&&(t.strokeOpacity=0)})}function wI(a,e){let t=a.chart.legend.events.on(Wt.Validated,()=>{_o({element:a.legendDataItem?.marker.children.getIndex(0),stylingInfo:e}),a.chart.legend.isReady()&&(t.dispose(),a.chart.legend.invalidate())})}function CI(a){let{series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,chartSubType:r,colorMatch:n,rendererType:A}=a,o=e.dataFields.valueY??e.dataFields.valueX??t.y,l=!1,c=new Set,h,d=t.fillSymbol,u={seriesConfig:t,seriesIndex:i,seriesSymbol:d,colorMatch:n,isChartFillSymbol:!0},g={},y={},m=zd(i);if(e.columns.length===0?g=Bh({seriesConfig:t,seriesIndex:i,seriesSymbol:d??m,element:new wy,colorMatch:n,isChartFillSymbol:!0}):e.columns.each(b=>{let B=b.dataItem?.dataContext;if(Number.isFinite(B?.[o])){let w=Dr({dataItem:B,seriesConfig:t,chartSubType:r,colorMatch:n,rendererType:A}),_=B[Te.xAxisField]===Te.nullValue,T=(_&&t.nullCategory?.symbol!==void 0?t.nullCategory.symbol:d)??m;g=Bh({...u,seriesSymbol:T,element:b,rendererSymbol:w}),_o({element:b,stylingInfo:g.stylingInfo}),_||(c.add(JSON.stringify(g.symbolWithColorInfo)),y=g)}}),s>1){let b=e.chart.legend.markers.values;b.length!==0?b.forEach(B=>{if(B.dataItem instanceof _y){let w=B.dataItem.marker.children.getIndex(0);w!==void 0&&w.baseSprite?.parent instanceof Ud?_o({element:w,stylingInfo:y.stylingInfo}):l=!0}}):l=!0}return l&&wI(e,y.stylingInfo),c.size<=1&&(h=y.symbolWithColorInfo??d),BI(e,o),h}function _I(a){let{series:e,seriesSymbolMapForEvent:t,seriesIndexMapper:i,seriesIndex:s,colorMatch:r,rendererType:n}=a,A=a.seriesConfig,o=et(e.chart.uid,"config"),l=o?.series.length??0,c=bt(o?.series),h=CI({series:e,seriesConfig:A,seriesIndex:s,numberOfSeries:l,chartSubType:c,colorMatch:r,rendererType:n});t.set(i.get(A.id)??s,h),t.size===l&&lr({data:t,htmlContainer:e.chart.htmlContainer,chartId:e.chart.id,colorMatchApplied:Qu(e.chart)})}function mB(a){let{seriesConfig:e,series:t,seriesIndexMapper:i,rotationChanged:s,colorMatch:r,stackedType:n,rendererType:A,seriesIndex:o,seriesSymbolMapForEvent:l,queryObject:c}=a,{name:h}=e,d=et(t.chart.uid,"config"),u=Dn({config:d}),g=bt(d?.series);xh(t,e.visible);let y=h,m=t.dataFields?.customValue??"";(g===$e.BarAndLineSplitBy||g===$e.BarAndLineSplitByNoAggregation)&&(y=fu({queryObject:c,fieldName:wA(m),fieldValue:y})??y),kv(t,y),ku({series:t,seriesConfig:e,rotationChanged:s,stackedType:n,isRotated:u}),_I({series:t,seriesConfig:e,seriesIndex:o,seriesIndexMapper:i,colorMatch:r,rendererType:A,seriesSymbolMapForEvent:l}),yh(t.uid,{barSeriesLastUpdate:{numberOfColumnsUpdated:t.columns.length,updateProps:a}})}function FI(a){a.events.on(Wt.Validated,()=>{let e=mh(a.uid,"barSeriesLastUpdate");if(e!==void 0){let{numberOfColumnsUpdated:t,updateProps:i}=e;a.columns.length>t&&mB(i)}})}function SI(a){let{chart:e,chartConfig:t,seriesIndex:i,axisList:s=[],hideLoaderHandle:r,selectionTheme:n,queryObject:A}=a,{rotated:o}=t,l=t.series[i],{y:c,assignToSecondValueAxis:h}=l,d=new Ud;Ou(d,r),d.id=l.id;let u,g;o!==!0?(u=s[0],g=h===!0&&s[2]?s[2]:s[1]):(u=h===!0&&s[2]?s[2]:s[0],g=s[1]),u!==void 0&&(d.xAxis=u),g!==void 0&&(d.yAxis=g);let y=e instanceof Is?Dn({chart:e}):!1,m=bt(t.series)!==$e.BarAndLineSplitByNoAggregation?c:`${c}_${lh({where:l.query?.where,keepSurroundingQuotes:!1,escape:!1})}`;y?d.dataFields.valueX=m:d.dataFields.valueY=m;let b=y?s[1]:s[0];if(b!==void 0){let B=Qv(b,y);d.dataFields[B]=Te.xAxisField,d.baseAxis=b}return ku({series:d,seriesConfig:l,rotationChanged:!1,stackedType:t.stackedType,isRotated:y}),d.dataFields.customValue=l?.query?.where,Kv(d.columns.template,d),d.columns.template.width=ji(100),Mu({element:d.columns.template,customSelectionTheme:n}),Rv({chart:e,element:d.columns.template,queryObject:A}),Gu(d),FI(d),Pu(d),d}function TI(a){let{seriesConfig:e,series:t,seriesIndex:i,axes:s,utilsStrings:r,fieldList:n,queryObject:A,stackedType:o,options:l}=a;t.id=e.id;let c=Dn({chart:t.chart});tx({series:t,seriesType:P.BarSeries,isRotated:c,stackedType:o,hideOversizedSideBySideLabels:e.hideOversizedSideBySideLabels,hideOversizedStackedLabels:e.hideOversizedStackedLabels,dataLabelsConfig:e.dataLabels,yAxisValueFormat:s[1].valueFormat,customDataLabelFormatter:l?.dataLabelFormatter}),Eu({styleCallback:mB,callbackProps:a,series:t,seriesConfig:e,onReadyEvent:!0}),Gv({series:t,seriesConfig:e,fieldList:n,queryObject:A,utilsStrings:r,seriesIndex:i,tooltipFormatter:l?.tooltipFormatter})}function II(a){a.labels.template.adapter.add("html",(e,t)=>{let i=mh(a.uid,"pieChartDataLabelFormatter"),s=e??"",{dataItem:r}=t;if(r instanceof dA){let{slice:n}=r;if(n!==void 0&&!xv(n))s="";else if(i!==void 0){let{value:A,percent:o}=r.values?.value??{};if(A!==void 0&&A!==0){let l=`${r.properties?.category??e}`;s=i(l,A,o)}}}return ii(s)&&(s=Te.htmlEmptyContent),vs(s)})}function DI(a){let e=a.labels.template;e.maxWidth=Te.pieChart.dataLabels.maxWidth??Number.NaN,e.wrap=Te.pieChart.dataLabels.wrap??!0,e.events.on(Wt.Over,t=>{let{dataItem:i}=t.target??{};i instanceof dA&&i.slice.showTooltip()}),II(a)}function LI(a,e){let{numericValueFormat:t,percentValueFormat:i,displayCategoryOnDataLabel:s,displayNumericValueOnDataLabel:r,displayPercentageOnDataLabel:n,valuePrefix:A,valueSuffix:o,percentagePrefix:l,percentageSuffix:c,dataLabelsCharacterLimit:h}=e,d=Ku({iLocale:a.chart.language.locale,pieChart:a.chart,valueIntlOptions:t?.intlOptions,percentageIntlOptions:i?.intlOptions,displayNumericValue:r??Te.pieChart.displayNumericValueOnDataLabel,displayPercentage:n??Te.pieChart.displayPercentageOnDataLabel,valuePrefix:A,valueSuffix:o,percentagePrefix:l,percentageSuffix:c}),u=Zd(h),g=na(a.rtl," ");return(y,m,b)=>{let B=d(y,m,b),w=s??Te.pieChart.displayCategoryOnDataLabel?u(y):"",_=ii(w)?"":`${w}${g}`;return _=`${_}${B}`,e.dataLabels?.content!==void 0&&(_=nr({textSymbol:{...e.dataLabels.content,text:_},format:"html",defaults:{...Te.pieChart.dataLabels,wrap:e.optimizeDataLabelsOverlapping??Te.pieChart.dataLabels.wrap}})),_}}function UI(a){let{pieSeries:e,seriesConfig:t,dataLabelFormatter:i}=a,{dataLabels:s}=t,r=t.dataLabelsOffset??Te.pieChart.dataLabelsOffset,n=t.dataLabelsInside??Te.pieChart.dataLabelsInside;yh(e.uid,{pieChartDataLabelFormatter:i??LI(e,t)}),Ln({label:e.labels.template,labelConfig:s,defaults:{...Te.pieChart.dataLabels,wrap:t.optimizeDataLabelsOverlapping??Te.pieChart.alignDataLabels},skipSettingText:!0}),e.alignLabels=!n&&(t.alignDataLabels??Te.pieChart.alignDataLabels);let A=e.labels.template.radius;e.chart.invalidateData(),(n&&A!==ji(-40)||!n&&A===ji(-40)||r!==void 0&&Number.isFinite(r)&&A!==r)&&(e.labels.template.radius=n?ji(-40):r,e.invalidate())}function QI(a,e){let t=(g,y,m)=>Te.htmlEmptyContent,{numericValueFormat:i,percentValueFormat:s,dataTooltipValueFormat:r,dataTooltipPercentFormat:n,displayCategoryOnTooltip:A,displayNumericValueOnTooltip:o,displayPercentageOnTooltip:l,valuePrefix:c,valueSuffix:h,percentagePrefix:d,percentageSuffix:u}=e;return t=(g,y,m)=>{let b=Te.htmlEmptyContent,B=Ku({iLocale:a.chart.language.locale,pieChart:a.chart,valueIntlOptions:(r??i)?.intlOptions,percentageIntlOptions:(n??s)?.intlOptions,displayNumericValue:o??Te.pieChart.displayNumericValueOnTooltip,displayPercentage:l??Te.pieChart.displayPercentageOnTooltip,valuePrefix:c,valueSuffix:h,percentagePrefix:d,percentageSuffix:u})("",y,m),w=!ii(g)&&(A??Te.pieChart.displayCategoryOnTooltip);if(w&&(b=`<b>${g}</b>`),!ii(B)){let _=qd(B);b=w?`${b}<br />${_}`:_}return b},t}function kI(a){if(a.tooltip!==void 0){let e=a.fill;e instanceof Ly?e=e.stroke:e instanceof Uy&&(e=e.backgroundFill),a.tooltip.background.fill=e}}function EI(a){let e=a.slices.template;e.tooltipHTML=Te.htmlEmptyContent,e.adapter.add("tooltipHTML",(t,i)=>{let s=t??"",{chart:r}=a;if(r!==void 0&&i.tooltip!==void 0){let n=et(r.uid,"config"),{dataTooltipVisible:A}=n?.series[0]??{};if(A===!1)i.tooltip.disabled=!0;else{let o=mh(a.uid,"pieChartTooltipFormatter");if(o!==void 0){let{dataItem:l}=i;if(l instanceof dA){let c=l.properties.category??"",h=l.dataContext,d=vA(h);d===void 0&&(d=c);let u=l.values?.value?.value,g=l.values?.value?.percent;typeof u=="number"&&u!==0&&n?.series?.[0]?.dataTooltipVisible!==!1?(i.tooltip.disabled=!1,kI(i),s=o(`${c}`,u,g,d)):i.tooltip.disabled=!0}}}}return vs(s)})}function PI(a){let{series:e,seriesConfig:t,tooltipFormatter:i}=a;yh(e.uid,{pieChartTooltipFormatter:i??QI(e,t)})}function MI(a){a.ticks.template.adapter.add("disabled",(e,t)=>t.dataItem?.values?.value?.value===0||!Number.isFinite(t.dataItem?.values?.value?.value)||e===!0)}function HI(a){let{chartData:e,pieSeries:t,pieSlicesSymbols:i,seriesConfig:s}=a;if(t.slices.length===0){let r=[];e?.forEach(n=>{let A=ph({dataContext:n,pieSlicesSymbols:i,seriesConfig:s});r.push(Tu(A.color))}),r.length>0&&(t.colors.list=r)}}function RI(a){let{seriesConfig:e,hideLoaderHandle:t,selectionTheme:i}=a,{x:s,y:r,id:n,visible:A}=e,o=new Ld;o.id=n,Ou(o,t),o.dataFields.value=r,o.dataFields.category=s;let l=Te.pieChart;o.startAngle=l.min,o.endAngle=360+o.startAngle,MI(o),EI(o),DI(o);let c=i!==void 0&&i.selectedElementsTheme?.transformation?.opacity===void 0?{...i,selectedElementsTheme:{...i?.selectedElementsTheme,transformation:{...i?.selectedElementsTheme?.transformation,opacity:1}}}:i;return Mu({element:o.slices.template,useNativeState:!0,customSelectionTheme:c}),o.slices.template.states.removeKey("hover"),Pu(o),o.hidden=A===!1,Gu(o),o}function OI(a){let{series:e,pieSlicesSymbols:t,seriesConfig:i,selectionTheme:s}=a;e.defaultState.reset(),e.slices.each((r,n)=>{let A=r.dataItem?.dataContext,o=ph({dataContext:A,pieSlicesSymbols:t,seriesConfig:i}),l=Du({element:r,fillSymbol:o,defaultToColorFromRamp:!0,colorRampIndex:n,isChartFillSymbol:!0});s!==void 0&&s.selectedElementsTheme===void 0&&_o({element:r,stylingInfo:l,stateKey:Ha.Active})})}function NI(a,e){let{ticks:t}=e,i=t?.visible===!1||e.dataLabelsInside===!0||e.dataLabels===void 0||e.dataLabels?.visible===!1||e.dataLabelsOffset!==void 0&&e.dataLabelsOffset<=0;a.ticks.template.disabled=i,a.ticks.template.strokeOpacity=Te.pieChart.ticksOpacity;let s=t?.lineSymbol??ih({color:$d});i&&(s.width=0),bv({element:a.ticks.template,lineSymbol:s,visible:!i})}function VI(a){let{chart:e,seriesConfig:t,series:i,pieSlicesSymbols:s,options:r,utilsStrings:n,queryObject:A}=a,{tooltipFormatter:o,dataLabelFormatter:l}=r??{},{x:c,y:h,id:d,innerRadius:u,startAngle:g,endAngle:y}=t;i.id=d;let m=bt([t]),b=Te.pieChart;i.dataFields.value=m!==$e.PieFromFields?h:Bn,i.dataFields.category=m!==$e.PieFromFields?c:oo;let B=e.radius instanceof zl?e.radius.value:e.radius;e.innerRadius=ji((u??b.innerRadius)*B),i.startAngle=g??b.min,i.endAngle=y??360+i.startAngle,UI({pieSeries:i,seriesConfig:t,dataLabelFormatter:l}),HI({chartData:e.data,pieSeries:i,pieSlicesSymbols:s,seriesConfig:t}),Eu({styleCallback:OI,callbackProps:a,series:i,seriesConfig:t}),NI(i,t),PI({series:i,seriesConfig:t,tooltipFormatter:o})}function zg(a){let{data:e,seriesConfig:t,utilsStrings:i}=a,s=t[0],r=e?.reduce((d,u)=>{let g=u[Bn]??u[s.y];return Number.isFinite(g)||(g=0),g+d},0),n=s?.sliceGrouping?.percentageThreshold??0,A=[],o,l=0,c=e?.find(d=>d[pA.defaultGroupOfSlicesId]===!0)?.[Ht.pieChart.technicalFieldGroupedSlices]??[],h=[...e,...c].filter(d=>{let u=!0,g=d[Bn]??d[s.y];if(Number.isFinite(g)){let y=g/r*100;d[Ht.pieChart.technicalFieldSlicePercent]=y,y<=n&&d[pA.defaultGroupOfSlicesId]!==!0&&(l+=g,A.push(d),u=!1)}else d[pA.defaultGroupOfSlicesId]!==!0&&(A.push(d),u=n===0||n===void 0);return d[pA.defaultGroupOfSlicesId]===!0&&(o=d,u=!1),u});if(n>0&&A.length>0){let d=l/r*100,u=bt(t)===$e.PieFromFields,g={...o,[pA.defaultGroupOfSlicesId]:!0,[u?oo:s.x]:s.sliceGrouping?.label??i?.pieChart.defaultSliceGroupingLabel,[u?Bn:s.y]:l,[Ht.pieChart.technicalFieldSlicePercent]:d,[Ht.pieChart.technicalFieldGroupedSlices]:A};h.push(g)}return h}function yB(a){let{chart:e,seriesConfig:t,utilsStrings:i}=a,s=e.data,r=zg({data:s,seriesConfig:t,utilsStrings:i});e.data=r}async function Tb(a){let{chart:e,hitSlice:t,multiSelect:i=!1,queryObject:s}=a,r=[],n=et(e.uid,"config"),A=e.series.getIndex(0);if(n&&A!==void 0){let o=_v(A),l=Fv(A),c={element:{},xAxisField:o,yAxisField:l,seriesIndex:0,chartConfig:n};A.slices.each((h,d)=>{h.isActive&&(h===t||i||h.dataItem instanceof dA&&h.dataItem.label.isHover)?ah(h.dataItem?.dataContext)?(Fu({groupOfSlicesDataContext:h.dataItem?.dataContext})??[]).forEach(u=>{r.push({...c,element:void 0,elementDataContext:u,elementIndex:d})}):r.push({...c,element:h,elementDataContext:h.dataItem?.dataContext,elementIndex:d}):Hu({element:h,selected:!1,useNativeState:!0})}),r.forEach(h=>{Hu({element:h.element,selected:!0,useNativeState:!0})}),await zu({chart:e,listSelectedElements:r,selectionSource:As.SelectionByClick,queryObject:s})}e.feedLegend()}function $I(a,e){let t=async r=>{let{target:n}=r;if(Pv(a)&&a.series.getIndex(0)?.slices.template.togglable){let A=Ev(r,a);if(n instanceof Iy)await Tb({chart:a,multiSelect:A,hitSlice:n,queryObject:e});else if(n instanceof Cy){let o=n.dataItem;if(o instanceof dA){let{slice:l}=o;l.isActive=!l.isActive,await Tb({chart:a,multiSelect:A,hitSlice:l,queryObject:e})}}else n===a.background&&await zu({chart:a,listSelectedElements:[],selectionSource:As.SelectionByClick,queryObject:e})}},i=a.series.getIndex(0)?.slices.template;i!==void 0&&(i.events.on(Wt.Hit,t),i.events.on(Wt.DoubleHit,t));let s=a.series.getIndex(0)?.labels.template;s!==void 0&&s.events.on(Wt.Hit,t),a.background.events.on(Wt.Hit,t),a.background.events.on(Wt.DoubleHit,t)}function Ib(a){return a?.offsetParent!==null}function KI(a,e){a!==void 0&&e!==void 0&&window.IntersectionObserver!==void 0&&new IntersectionObserver(t=>{t[0].intersectionRatio>0&&(et(a.uid,"chartWasCreatedWhileHidden")===!0?(a.reinit(),a.events.once(Wt.Validated,()=>{a.reinit()}),a instanceof Is&&Fo(a),Ft(a.uid,{chartWasCreatedWhileHidden:!1})):et(a.uid,"chartWasUpdatedWhileHidden")===!0&&(a.reinit(),Ft(a.uid,{chartWasUpdatedWhileHidden:!1})))},{root:null}).observe(e)}function GI(a,e){let t=Te.pieChart.dataLabels.maxWidth??100;if(a!=null){let{alignDataLabels:i,dataLabelsOffset:s=Te.pieChart.dataLabelsOffset,optimizeDataLabelsOverlapping:r,dataLabels:n,dataLabelsInside:A}=a;if(n?.visible===!0&&i===!0&&A!==!0&&r===!0){let o=typeof e.radius=="number"?e.radius/100:e.radius.value,l=e.chartContainer.measuredWidth,c=e.chartContainer.measuredHeight,h=o*Math.min(l,c),d=5,u=Math.floor((l-h)/2)-d-s;t=Math.min(u,t-d);let g=30;t<g&&(t=g)}}return t}function vB(a){if(bh(a)){let e=typeof a.radius=="number"?a.radius:a.radius.percent;Ft(a.uid,{pieChartRadius:e});let t=()=>{let i=ji(et(a.uid,"pieChartRadius")??Te.pieChart.chartOptimizedRadius),s=i,r=et(a.uid,"config");if(r!==void 0){let{series:n}=r,{innerRadius:A,optimizeDataLabelsOverlapping:o,alignDataLabels:l,dataLabelsOffset:c=Te.pieChart.dataLabelsOffset,dataLabels:h,dataLabelsInside:d}=n[0];if(h?.visible===!0&&l===!0&&o===!0&&d!==!0){let g=Te.pieChart.chartOptimizedRadius/100,y=500,m=150,b=.6,B=.5,w=1,_=a.chartContainer.measuredWidth-c*2,T=Math.max(_-m,0)/(y-m),Q=T<1?Math.max(T**w*b,.4):Math.min(T**B*b,g);s=ji(Q*100)}else s=ji(Te.pieChart.chartRadius);i.value.toFixed(1)!==s.value.toFixed(1)&&(Ft(a.uid,{pieChartRadius:s.percent}),a.radius=s,a.innerRadius=ji((A??Te.pieChart.innerRadius)*s.value));let u=a.series?.values?.[0];u instanceof Ld&&(u.labels.template.maxWidth=GI(r?.series[0],a))}return s};a.events.on(Wt.SizeChanged,Ao(t,Te.debounceTime)),t(),a.validate()}}function xB(a){if(a instanceof Tr)vB(a);else if(!(a instanceof ka)){let e=()=>{let i=et(a.uid,"config"),{chartPaddingMinSize:s,chartPaddingRightWhenLegendNotOnRight:r,chartContainerPaddingTopWhenRotated:n,chartContainer:A}=Te,o=i?.series,l=Oe(o),c=Dn({config:i}),h=o?.[0]?.dataLabels?.visible??!0,d=Te.chartDefaultPaddingRight;if(c&&h&&(l===P.LineSeries||l===P.ComboLineAndBarSeries||l===P.BarSeries&&(i?.stackedType??Yy())===Hi.Side)){let g=0,y=m=>bo(m.uid,"isDataLabel")??!1;a.series.each(m=>{let b=m.bullets.values.find(y);b!==void 0&&b.clones.each(B=>{let w=B.measuredWidth;switch(B.horizontalCenter){case Ct.Middle:w/=2;break;case xi.Right:w*=-1;break;case xi.Left:}let _=B.pixelX+w;_>g&&(g=_,d=w)})})}d>=0&&(a.chartContainer.paddingRight=d),a.chartContainer.paddingTop=c?n:A.paddingTop;let u=i?.legend?.visible!==!1&&i?.legend?.position===je.Right;a.paddingRight=u?s:r},t=0;a.series.each(i=>{i.events.once(Wt.Validated,()=>{t+=1,t===a.series.length&&e()})})}}function Db(a){let e="";for(let t=0;t<a.length;t+=1){let i=a[t];e+=`<li>${i.message}</li>`}return`<ol>${e}</ol>`}function bB(a){let{chartConfig:e,createMessage:t,status:i,errorStrings:s}=a,{schemaErrors:r,customErrors:n,warnings:A}=i,o="",l="";return e===void 0?(l=t===void 0?s.modalHeaders.newChart:"",o=t??s.errors.newChartRequest):r.length>0?(l=s.modalHeaders.error,o=s.errors.simpleError):n.length>0?(l=s.modalHeaders.error,o=Db(n)):A.length>0&&(l=s.modalHeaders.warning,o=`<p>${s.errors.warningRequest}</p>${Db(A)}`),{title:l,message:o}}function XI(a){let{config:e,previousConfig:t,dataUpdateNeededProps:i,updatedProps:s,options:r,filterBySelection:n,previousSelectionOIDs:A,fieldList:o,queryObject:l}=a,c=Array.from(s.keys()).some(d=>{let u=!1;if(i.includes(d)){let{oldValue:g,newValue:y}=s.get(d)??{};u=!ra(g,y)}return u}),h;if(!c&&s.get("layer")){let{oldValue:d,newValue:u}=s.get("layer")??{};c=Ma(d)!==Ma(u)}if(s.get("layer")&&(h={common:{layerChanged:!0}}),e&&t){let d=tv({previousConfig:t,newConfig:e,options:r,previousFilterBySelection:s.has("filterBySelection")?s.get("filterBySelection")?.oldValue:n,previousSelectionOIDs:A,fieldList:o,queryObject:l});h=d.dataUpdateDetails,c=c||d.dataUpdateNeeded}return{dataUpdateNeeded:c,dataUpdateDetails:h}}function WI(a){return a?.type==="uniqueValue"&&(a.uniqueValueInfos=a.uniqueValueInfos.map(e=>{let t=e.value===null?Ht.nullValue:e.value;return{...e,value:t}})),a}async function BB(a){let{data:e,queryObject:t,chartConfig:i,allowColorMatch:s}=a,r=!1,n=[];if(s&&!Ri(t)){let{series:A,chartRenderer:o}=i,l=WI(o),c=l?_n.ChartRenderer:_n.LayerRenderer,h=t?Ji(t):void 0,d=l??h?.renderer,u;h&&c===_n.LayerRenderer?n=await k0(h):c===_n.ChartRenderer&&(n=t0(d));let g=uo(l,h?.renderer),y=tu({chartRenderer:o,queryObject:t}),m=bt(A),b=oh(i),B=wA(b.query?.where);u=new Map;for(let w=0;w<e.length;w+=1){let _=e[w],T=await iu({seriesConfig:i.series,dataItem:_,renderer:d,rendererType:g,rendererOrigin:c,chartSubType:m,splitByField:B,graphicTemplate:y,mapAttributesToSymbol:u,rendererFieldNames:n});r=r||T.colorMatchApplied}}return{dataItems:e,colorMatchApplied:r,rendererFieldNames:n}}function zI(a,e,t){let i=new Set(Array.from(e)),s=a.findIndex(r=>!i.has(Pg(r)));return s!==-1?s:t}function Pg(a){return`${a[0]},${a[1]},${a[2]}`}function YI(a){let{chartConfig:e,queryObject:t,usePopupTemplateFieldsInfo:i,labelUpdateNeeded:s,utilsStrings:r}=a,{series:n}=e,A=n[0],{x:o}=A,l=!n0({chartConfig:e}),c=bt([A]),h=c===$e.PieFromFields,d=Ji(t),u=BA(d).idField,g=$s(t,i);return{x:o,isNonAggregatedChart:l,objectIdField:u,isPieFromFields:h,seriesConfig:A,fieldList:g,labelUpdateNeeded:s,chartSubType:c,colorMatch:xA(e),utilsStrings:r}}function jI(a){let{dataContext:e,seriesConfig:t,existingSlicesColors:i,isGroupOfSlices:s,sliceFromConfig:r,dataIndex:n,colorMatch:A,chartSubType:o}=a,l=s?{...Ht.pieChart.sliceGrouping.fillSymbol,...t.sliceGrouping?.fillSymbol}:oi(r?.fillSymbol??t.fillSymbol),c=Dr({dataItem:e,seriesConfig:t,chartSubType:o,colorMatch:A}),h=n;l?.color||(h=zI(Ry,i,n));let d={dataItem:{dataContext:e}},{symbolWithColorInfo:u}=Bh({element:d,seriesConfig:t,y:t.y,seriesSymbol:l??Wy(),seriesIndex:h,rendererSymbol:c,colorMatch:A,isChartFillSymbol:!0});return u}function Lb(a,e){let{x:t,isNonAggregatedChart:i,objectIdField:s,isPieFromFields:r,seriesConfig:n,fieldList:A,labelUpdateNeeded:o,colorMatch:l,chartSubType:c,utilsStrings:h}=a,d=[],u,g,y=new Set;return e?.forEach((m,b)=>{let B=dv({dataContext:m,x:t,isNonAggregatedChart:i,dataIndex:b,objectIdField:s,isPieFromFields:r});m[Ht.pieChart.technicalFieldSliceId]=B;let w=Cu(n.slices,B);w?.fillSymbol?.color!==void 0&&y.add(Pg(w.fillSymbol.color))}),e?.forEach((m,b)=>{let B=m[Ht.pieChart.technicalFieldSliceId],w=Cu(n.slices,B),_=ah(m),T=jI({dataContext:m,seriesConfig:n,existingSlicesColors:y,isGroupOfSlices:_,sliceFromConfig:w,dataIndex:b,colorMatch:l,chartSubType:c});T.color&&y.add(Pg(T.color));let Q=uv({dataContext:m,sliceFromConfig:w,isGroupOfSlices:_,seriesConfig:n,fieldList:A,isPieFromFields:r,labelUpdateNeeded:o,colorMatch:l,utilsStrings:h}),U={sliceId:B,label:Q,fillSymbol:T};U.originalLabel=w?.originalLabel??(m?.[Ht.originalCategoryValue]!==void 0?m?.[Ht.originalCategoryValue]:U.label),_?(g=m[Ht.pieChart.technicalFieldGroupedSlices],n.sliceGrouping!==void 0&&(u={sliceId:n.sliceGrouping.sliceId,percentageThreshold:n.sliceGrouping.percentageThreshold,label:Q,originalLabel:n.sliceGrouping.originalLabel??Q,fillSymbol:T})):d.push(U)}),{slices:d,groupOfSlicesSymbols:u,groupOfSlices:g}}function rl(a){let e=YI(a),{slices:t,groupOfSlicesSymbols:i,groupOfSlices:s}=Lb(e,a.chartData),{slices:r}=Lb(e,s??[]);return{slices:t,groupedSlices:r,groupOfSlices:i}}async function Yg(a){let{chart:e,data:t,chartConfig:i,pieSlicesSymbols:s,queryObject:r,options:n,utilsStrings:A,errorStrings:o}=a,{slices:l}=s??{},{chartWillRender:c}=n??{},h=i,d=oi(s);if(c!==void 0&&(e instanceof ka||e instanceof Tr)){h=oi(i);let u=a0({data:t,seriesConfig:i.series});h=await c({chartConfig:h,data:u,slices:l});let g=await bu({input:h,queryObject:r,allowUsingObjectIdStat:n?.allowUsingObjectIdStat});if(!g.valid){let{title:y,message:m}=bB({chartConfig:h,createMessage:n?.createMessage,status:g,errorStrings:o}),b={keyword:In.InvalidConfig,header:y,message:m};_0(b,e.htmlContainer)}if(e instanceof Tr&&!Ri(r)){if(t&&"dataItems"in t){let{colorMatchApplied:y,rendererFieldNames:m}=await BB({data:t.dataItems,queryObject:r,chartConfig:h,allowColorMatch:sh({chartConfig:h,queryObject:r})});Ft(e.uid,{colorMatchApplied:y,rendererFieldNames:m})}d=rl({chartData:e.data,chartConfig:h,queryObject:r,labelUpdateNeeded:!0,usePopupTemplateFieldsInfo:n?.usePopupTemplateFieldsInfo,utilsStrings:A})}}return{alteredConfig:h,alteredPieSlicesSymbols:d}}function ZI(a,e){a.adapter.add("criticalError",t=>(t.message=e.errors.simpleError,t))}cA.classNamePrefix="arcgis-charts-";async function jg(a,e){let t=await gv(e.locale);cA.defaultLocale=t,a.language.locale=t,Ft(a.uid,{formatLocale:e.formatLocale}),a.rtl=e.rtl}function Qc(a){let{chart:e,actionMode:t,cursorRange:i}=a;if(bh(e)){let s=t??et(e.uid,"actionMode")??Te.actionMode;Ft(e.uid,{actionMode:s});let r=et(e.uid,"filterBySelection");switch(s){case Nt.MonoSelection:case Nt.MultiSelection:case Nt.MultiSelectionWithCtrlKey:r!==!0?Nv(e):wh(e);break;case Nt.Zoom:wh(e);break;case Nt.None:Wu({chart:e,selectionSource:As.ClearSelection,clearOnlyVisibleSeries:!1,disposeStyleAndSelection:!1}),wh(e);break}Cv({chart:e,actionMode:s,cursorRange:i})}}function qI(a,e){e===!0&&(a.tapToActivate=!0,a.tapTimeout=3e3,a.responsive.enabled=!0)}function JI(a){let{chart:e,axesConfig:t,chartType:i,isRotated:s,errorStrings:r,queryObject:n}=a;switch(aa({chartType:i,axesConfig:t,errorStrings:r}),i){case P.GaugeSeries:{hr(n),e instanceof ka&&t?.[0]?.valueFormat!==void 0&&cI({chart:e,valueFormat:t[0].valueFormat,queryObject:n});break}case P.BarSeries:case P.LineSeries:case P.ComboLineAndBarSeries:case P.BoxPlotSeries:{ax({chart:e,chartType:i,isRotated:s,axesConfig:t,queryObject:n});break}}}async function Zg(a){let{chart:e,chartConfig:t,chartConfig:{axes:i},rotationChanged:s,axisLabelsBehaviorChanged:r,chartType:n,isRotated:A,dualAxisChanged:o,timeIntervalInfoWasReset:l,data:c,queryObject:h,guideTooltipFormatter:d,xAxisLabelFormatter:u,yAxisLabelFormatter:g,secondaryYAxisLabelFormatter:y,gaugeInnerLabelFormatter:m,utilsStrings:b,errorStrings:B}=a;switch(aa({chartType:n,axesConfig:i,errorStrings:B}),n){case P.BarSeries:case P.LineSeries:case P.ComboLineAndBarSeries:case P.BoxPlotSeries:{e instanceof Is&&nx({chart:e,chartConfig:t,rotationChanged:s,axisLabelsBehaviorChanged:r,isRotated:A,dualAxisChanged:o,timeIntervalInfoWasReset:l,timeIntervalInfo:c?.timeIntervalInfo??et(e.uid,"timeIntervalInfo"),guideTooltipFormatter:d,xAxisLabelFormatter:u,yAxisLabelFormatter:g,secondaryYAxisLabelFormatter:y,utilsStrings:b,errorStrings:B,queryObject:h});break}case P.GaugeSeries:{e instanceof ka&&(hr(h),await uI({chart:e,chartConfig:t,data:(c??e.data).dataItems,queryObject:h,axisValueFormatter:u,gaugeInnerLabelFormatter:m,utilsStrings:b,errorStrings:B}));break}}}function wB(a){let{chart:e,chartConfig:t,hideLoaderHandle:i,options:s,utilsStrings:r,queryObject:n}=a,{selectionTheme:A,ignoreSmoothRenderingLimit:o}=s??{};e.series.clear();let l,c,h=[],d=e instanceof Is?[e.xAxes.getIndex(0),e.yAxes.getIndex(0),e.xAxes.getIndex(1)??e.yAxes.getIndex(1)]:void 0,u={hideLoaderHandle:i,selectionTheme:A,utilsStrings:r},g={...u,axisList:d};if(e instanceof Is)for(let m=0;m<t.series.length;m+=1){let b=t.series[m];if(c=Oe([b]),Vs(t))l=qv({...g,chart:e,axisList:d,chartConfig:t,seriesIndex:m,queryObject:n}),h.push(...l.flat());else switch(c){case P.BarSeries:{l=SI({...g,chart:e,chartConfig:t,seriesIndex:m,queryObject:n}),h.push(l);break}case P.LineSeries:{hr(n),l=jv({...g,chart:e,chartConfig:t,seriesIndex:m,ignoreSmoothRenderingLimit:o,queryObject:n}),h.push(l);break}}}else e instanceof Tr&&t.series[0].type===P.PieSeries&&(l=RI({...u,seriesConfig:t.series[0]}),h.push(l));let y=Zy({chartConfig:t,queryObject:n,chartData:e.data});y.length>0&&(e.colors.list=y.map(m=>{let[b,B,w,_]=m;return new By({r:b,g:B,b:w,a:_})})),h.length>0&&e.series.pushAll(h),$v(e)}async function qg(a){let{chart:e,chartConfig:t,chartConfig:{series:i,axes:s,chartRenderer:r},seriesIndexMapper:n,rotationChanged:A,seriesReordered:o,outliersVisibilityChanged:l,standardizeValuesVisibilityChanged:c,chartData:h,queryObject:d,options:u,dataWasUpdated:g,sortChanged:y,groupOfSlicesWasUpdated:m,pieSlicesSymbols:b,utilsStrings:B,errorStrings:w}=a,_=e.series.values,T=new Map,Q=t.series.length,U=xA(t),E=Pa(t),O=$s(d,u?.usePopupTemplateFieldsInfo),D=Ji(d),k=uo(r,Ri(D)?void 0:D?.renderer);for(let[F,M]of i.entries()){let Y=Oe([M]),z=_[F],re={numberOfSeries:Q,series:z,seriesConfig:M,seriesIndex:F,colorMatch:U,queryObject:d,rendererType:k,options:u,dataWasUpdated:g,fieldList:O,sortChanged:y,utilsStrings:B},q={...re,axes:s,seriesIndexMapper:n},Ae=z;if(e instanceof Is&&Vs(t))Ae=_.find(X=>X.id===M.id),z!==void 0&&(Ae instanceof Dy||Ae instanceof Yl)&&Jv({...re,chart:e,series:Ae,seriesIndexMapper:n,seriesSymbolMapForEvent:T,chartData:h,showOutliers:t.showOutliers,showMean:t.showMean,outliersVisibilityChanged:l,seriesReordered:o,standardizeValuesVisibilityChanged:c,rotationChanged:A,options:u});else switch(Y){case P.BarSeries:TI({...q,stackedType:E,seriesSymbolMapForEvent:T,rotationChanged:A});break;case P.LineSeries:Zv({...q,stackedType:E,seriesSymbolMapForEvent:T,rotationChanged:A});break;case P.PieSeries:VI({...re,chart:e,groupOfSlicesWasUpdated:m,pieSlicesSymbols:b,selectionTheme:u?.selectionTheme});break}}await ex({chart:e,options:u,dataWasUpdated:g,chartData:h,chartConfig:t,queryObject:d,rotationChanged:A,sortChanged:y,groupOfSlicesWasUpdated:m,errorStrings:w})}async function Jg(a){let{chartConfig:e}=a,{chart:t,options:i,globalOptions:s,colorMatchApplied:r,queryObject:n,utilsStrings:A,errorStrings:o,dataInfo:l,loaderHandle:c}=a,{disableTogglingLegendItems:h,cursorRange:d,actionMode:u,pieChartLegendValueLabelFormatter:g,guideTooltipFormatter:y,xAxisLabelFormatter:m,yAxisLabelFormatter:b,secondaryYAxisLabelFormatter:B,gaugeInnerLabelFormatter:w,usePopupTemplateFieldsInfo:_}=i??{},{data:T,count:Q,queryConfig:U}=l??{},E,O,D,k=Oe(e.series),F=$s(n,_);Ft(t.uid,{fieldList:F,options:i,elementCount:Q,queryConfig:U,boxPlotMeanLinesData:T?.meanLines,timeIntervalInfo:T?.timeIntervalInfo,serverLimitReached:T?.serverLimitReached});let M=new Map;e.series.forEach((dt,Me)=>{M.set(dt.id,Me)});let Y=cr(T);Y!==void 0&&(t.data=Y);let z=bt(e.series);Vs(e)&&z!==$e.BoxPlotMonoField&&z!==$e.BoxPlotMonoFieldAndSplitBy&&(Fn({arrayToSort:t.data,chartConfig:e}),Xu({chart:t,chartData:t.data,chartConfig:e}));let re;t instanceof Tr&&!Ri(n)&&(yB({chart:t,seriesConfig:e.series,utilsStrings:A}),re=rl({chartData:t.data,chartConfig:e,queryObject:n,labelUpdateNeeded:!0,usePopupTemplateFieldsInfo:i?.usePopupTemplateFieldsInfo,utilsStrings:A}));let q={dataItems:t.data,timeIntervalInfo:et(t.uid,"timeIntervalInfo"),serverLimitReached:et(t.uid,"serverLimitReached"),meanLines:et(t.uid,"boxPlotMeanLinesData"),outliers:T?.outliers};Lr({data:t instanceof Tr?{dataItems:t.data}:T,seriesConfig:e.series,htmlContainer:t.htmlContainer});let Ae=await Yg({chart:t,data:T,chartConfig:e,pieSlicesSymbols:re,queryObject:n,options:i,utilsStrings:A,errorStrings:o}),{alteredConfig:X,alteredPieSlicesSymbols:G}=Ae;re=G,t instanceof Tr&&(xo({data:t.data,newChartConfig:X,pieSlicesSymbols:re,fieldList:et(t.uid,"fieldList")}),lr({data:re,htmlContainer:t.htmlContainer,chartId:t.id,colorMatchApplied:r===!0}),du({data:{dataItems:t.data},chartConfig:X,htmlContainer:t.htmlContainer}));let{title:ue,subtitle:he,footer:ae,series:Ie,background:Pe}=X;E=gI(t),Lc(E,{title:ue,subtitle:he}),O=pI(t),Uc(O,ae),D=Yv(t,Ie),zv(t);let De=Dn({config:X});Ft(t.uid,{config:X,isRotated:De,isNonAggregatedChart:!ho(z)}),X.axes!==void 0&&(JI({chart:t,axesConfig:X.axes,chartType:k,isRotated:De,errorStrings:o,queryObject:n}),await Zg({chart:t,chartConfig:X,chartType:k,isRotated:De,data:T,queryObject:n,guideTooltipFormatter:y,xAxisLabelFormatter:m,yAxisLabelFormatter:b,secondaryYAxisLabelFormatter:B,gaugeInnerLabelFormatter:w,utilsStrings:A,errorStrings:o})),wB({chart:t,chartConfig:X,hideLoaderHandle:c.hideLoader,utilsStrings:A,options:i,queryObject:n}),await qg({chart:t,chartConfig:X,seriesIndexMapper:M,rotationChanged:!1,queryObject:n,chartData:k===P.BoxPlotSeries?q:T,groupOfSlicesWasUpdated:!0,pieSlicesSymbols:re,dataWasUpdated:!0,options:i,utilsStrings:A,errorStrings:o}),_h({legendElements:D,seriesConfig:Ie,webChartLegend:X.legend,pieChartLegendValueLabelFormatter:g}),gB(t),fI(t),Dc(t,Pe),pB({chart:t,scrollbarXConfig:X.axes?.[0]?.scrollbar,scrollbarYConfig:X.axes?.[1]?.scrollbar}),Bv(t),Lu(t,X?.cursorCrosshair),Qc({chart:t,actionMode:u,cursorRange:d});let Qe=yo(t.htmlContainer??document.documentElement);return t.dateFormatter.intlLocales=Qe,qI(t,s?.enableResponsiveFeatures),(t instanceof ka||Ru(t.series))&&Sn(t.htmlContainer),xB(t),E!==void 0&&O!==void 0&&D!==void 0?{headerElements:E,footerElements:O,legendElements:D}:void 0}function CB(a){a.series.each(e=>{e.events.on(Wt.Ready,()=>{Ru(a.series)&&Fo(a)})})}async function eD(a){let{chartContainer:e,chartConfig:t,queryObject:i,colorMatchApplied:s,dataInfo:r,t9nStrings:n,options:A,globalOptions:o,loaderHandle:l}=a,{errorStrings:c,utilsStrings:h}=n,d=jl(e,Is);d.id=t?.id??d.uid,Ft(d.uid,{queryObject:i});let{t9nLocale:u}=Zl(d.htmlContainer??document.documentElement),g=yo(d.htmlContainer??document.documentElement),y=Wl(d.htmlContainer??document.documentElement)==="rtl";await jg(d,{locale:u,formatLocale:g,rtl:y}),d.events.on(Wt.Inited,()=>d.zoomOutButton.deepInvalidate());let m=Oe(t?.series);d instanceof Is&&m!==P.BoxPlotSeries&&(d.maskBullets=!1);let b=await Jg({chartConfig:t,chart:d,queryObject:i,colorMatchApplied:s,options:A,globalOptions:o,utilsStrings:h,errorStrings:c,dataInfo:r,loaderHandle:l});return Ft(d.uid,{config:oi(t)}),CB(d),Mv(d,i),Hv(d,i),{chart:d,chartElements:b}}async function tD(a){let{chartContainer:e,chartConfig:t,queryObject:i,dataInfo:s,colorMatchApplied:r,errorStrings:n,utilsStrings:A,options:o,globalOptions:l,loaderHandle:c}=a,h=jl(e,Tr);h.id=t?.id??h.uid;let d=Bu(h.htmlContainer);await jg(h,d),h.radius=ji(Te.pieChart.chartRadius);let u=await Jg({chartConfig:t,chart:h,queryObject:i,colorMatchApplied:r,dataInfo:s,options:o,globalOptions:l,utilsStrings:A,errorStrings:n,loaderHandle:c});return Ft(h.uid,{config:oi(t),filterBySelection:o?.filterBySelection}),$I(h,i),{chart:h,chartElements:u}}async function iD(a){let{chartContainer:e,chartConfig:t,queryObject:i,dataInfo:s,errorStrings:r,utilsStrings:n,options:A,globalOptions:o,loaderHandle:l}=a,c=jl(e,ka);c.id=t?.id??c.uid;let h=Bu(c.htmlContainer);await jg(c,h),c.maskBullets=!1;let d=Te.gauge,u=Number.isFinite(t?.innerRadius)?t?.innerRadius:d.innerRadius,g=Number.isFinite(t?.startAngle)?t?.startAngle:d.startAngle,y=Number.isFinite(t?.endAngle)?t?.endAngle:d.endAngle;c.radius=ji(d.radius),typeof u=="number"&&(c.innerRadius=ji(u)),typeof g=="number"&&(c.startAngle=g),typeof y=="number"&&(c.endAngle=y);let m=await Jg({chartConfig:t,chart:c,queryObject:i,dataInfo:s,options:A,globalOptions:o,utilsStrings:n,errorStrings:r,loaderHandle:l});return Ft(c.uid,{config:oi(t)}),CB(c),e?.ownerDocument.addEventListener("visibilitychange",()=>{let b=e.ownerDocument.hidden;c&&!b&&KT(t?.axes?.[0])&&(c.svgContainer?.measure(),c.invalidateData())}),{chart:c,chartElements:m}}async function sD(a){let{newConfig:e}=a,{chart:t,chartElements:i,dataWasUpdated:s,dataUpdateDetails:r,dataInfo:n,options:A,configWithAllSeries:o,hasSeriesFilteredOut:l,queryObject:c,utilsStrings:h,errorStrings:d,loaderHandle:u}=a,{guideTooltipFormatter:g}=A??{},y=et(t.uid,"config"),m=y?.series,b=e.series,B=Oe(b),w=Dn({config:e});Ft(t.uid,{config:oi(e),isRotated:w}),Ft(t.uid,{filterBySelection:A?.filterBySelection}),Qc({chart:t,actionMode:A?.actionMode,cursorRange:A?.cursorRange});let{xOrYChanged:_,layerChanged:T}=r?.common??{},{numberOfSeriesChanged:Q}=r?.common??{},U=mu(y,e),E=yu(y,e),O=W0(y,e),D=z0(y,e),k=JSON.stringify(Au(m))!==JSON.stringify(Au(b)),F=!1,M=!1;Vs(e)&&Vs(y)&&(F=j0(y,e),M=Z0(y,e));let Y=rh({oldConfig:l?o:y,newConfig:e,dataWasUpdated:s}),z=Od({oldConfig:y,newConfig:e,rotationChanged:E}),re=rx({chart:t,dualAxisChanged:O,rotationChanged:E,timeIntervalInfoWasReset:U,axisLabelsBehaviorChanged:z}),q=!1,Ae=cr(n?.data),X=bt(b);if(Ft(t.uid,{isNonAggregatedChart:!ho(X)}),s){let{count:Ie,data:Pe,queryConfig:De}=n??{};Ft(t.uid,{elementCount:Ie,queryConfig:De,boxPlotMeanLinesData:Pe?.meanLines,timeIntervalInfo:Pe?.timeIntervalInfo,serverLimitReached:Pe?.serverLimitReached}),Sn(t.htmlContainer)}else if(B===P.BarSeries||B===P.LineSeries||B===P.RadarSeries||B===P.ComboLineAndBarSeries||B===P.BoxPlotSeries){let Ie=hu(m,b);if(Ie.length>0&&(vv(t.series,Ie),t.feedLegend(),q=!0),P0(b[0])){let{binTemporalData:Pe}=b[0],{unit:De,size:Qe}=b[0].temporalBinning??{};Pe===!1&&De!==void 0&&Qe!==void 0&&Ft(t.uid,{timeIntervalInfo:{unit:De,size:Qe}})}}Y&&(Fn({arrayToSort:s?Ae??t.data:t.data,chartConfig:e,fieldList:et(t.uid,"fieldList"),isTimeBinningSeries:po({seriesConfig:oh(e),xAxisValueFormatType:eh(e),setTimeBinningInfoWhenNotProvided:A?.setTimeBinningInfoWhenNotProvided,queryObject:c})}),Vs(e)&&Xu({chart:t,chartData:s?Ae??t.data:t.data,chartConfig:e}),s||(t.validateData(),B===P.BoxPlotSeries&&t.series.each(Ie=>{Ie instanceof Yl&&!(Ie instanceof Qd)&&Ie.id.includes(li.Outliers)&&Ie.validateData()})));let G={dataItems:s?Ae??t.data:t.data,timeIntervalInfo:et(t.uid,"timeIntervalInfo"),serverLimitReached:et(t.uid,"serverLimitReached"),meanLines:et(t.uid,"boxPlotMeanLinesData"),outliers:s?n?.data?.outliers:t.series.values.find(Ie=>!(Ie instanceof Qd)&&Ie instanceof Yl)?.data};(s||Y)&&Lr({data:G,seriesConfig:e.series,htmlContainer:t.htmlContainer});let ue=new Map;e.series.forEach((Ie,Pe)=>{ue.set(Ie.id,Pe)}),Q=Q||l,Ae&&s&&(t.data=Ae),e.axes!==void 0&&await Zg({chart:t,chartConfig:e,rotationChanged:E,timeIntervalInfoWasReset:U,axisLabelsBehaviorChanged:z,chartType:B,isRotated:w,dualAxisChanged:O,guideTooltipFormatter:g,xAxisLabelFormatter:A?.xAxisLabelFormatter,yAxisLabelFormatter:A?.yAxisLabelFormatter,secondaryYAxisLabelFormatter:A?.secondaryYAxisLabelFormatter,queryObject:c,utilsStrings:h,errorStrings:d});let he=B===P.BoxPlotSeries&&(X0(b,m)||G0(b,m));(t.series===void 0||t.series.length===0||_||T||Q||k||(B===P.BarSeries||B===P.LineSeries||B===P.RadarSeries||B===P.ComboLineAndBarSeries)&&t.series.length!==e.series.length||re||D||he||r?.boxPlot?.showMeanChanged)&&(!s&&(E||he||re)&&t.invalidateData(),wB({chart:t,chartConfig:e,hideLoaderHandle:u.hideLoader,utilsStrings:h,queryObject:c,options:A})),await qg({chart:t,chartConfig:e,seriesIndexMapper:ue,rotationChanged:E,seriesReordered:q,outliersVisibilityChanged:F,standardizeValuesVisibilityChanged:M,queryObject:c,chartData:G,options:A,dataWasUpdated:s,sortChanged:Y,utilsStrings:h,errorStrings:d}),Lc(i.headerElements,{title:e.title,subtitle:e.subtitle}),Uc(i.footerElements,e.footer),_h({legendElements:i.legendElements,seriesConfig:e.series,webChartLegend:e.legend,disableTogglingLegendItems:A?.disableTogglingLegendItems}),Dc(t,e.background),pB({chart:t,scrollbarXConfig:e.axes?.[0]?.scrollbar,scrollbarYConfig:e.axes?.[1]?.scrollbar}),Lu(t,e?.cursorCrosshair);let ae=wv(t);(ae.behavior===xs.SelectX||ae.behavior===xs.SelectXY||ae.behavior===xs.SelectY||ae.behavior===xs.None)&&t.scrollbarX.start===0&&t.scrollbarX.end===1&&t.scrollbarY.start===0&&t.scrollbarY.end===1&&Fo(t),xB(t),ix(t.series.values[0])}async function rD(a){let{chart:e,chartElements:t,dataWasUpdated:i,newConfig:s,queryObject:r,options:n,dataInfo:A,utilsStrings:o,errorStrings:l}=a,c=et(e.uid,"config"),h=c?.series,d=s?.series,u=ch(c,s),g=rh({oldConfig:c,newConfig:s,dataWasUpdated:i});Ft(e.uid,{filterBySelection:n?.filterBySelection,config:oi(s)});let y,m,b=!1;if(i){let{count:D,data:k,queryConfig:F}=A??{};y=k,Ft(e.uid,{elementCount:D,queryConfig:F}),m=cr(y),m!==void 0&&b0(e.data,m)&&(e.data=m,b=!0),Sn(e.htmlContainer)}let B=_u(h,d);(b||B)&&yB({chart:e,seriesConfig:d,utilsStrings:o}),(g||B)&&(Fn({arrayToSort:m??e.data,chartConfig:s,fieldList:et(e.uid,"fieldList")}),e.validateData());let w=hh({oldConfig:c,newConfig:s}),_=pu(c,s),T=rl({chartData:e.data,chartConfig:s,queryObject:r,labelUpdateNeeded:b||w||u||_,usePopupTemplateFieldsInfo:n?.usePopupTemplateFieldsInfo,utilsStrings:o});(b||g)&&(Lr({data:{dataItems:e.data},seriesConfig:s.series,htmlContainer:e.htmlContainer}),du({data:{dataItems:e.data},chartConfig:s,htmlContainer:e.htmlContainer}));let Q=await Yg({chart:e,data:{dataItems:e.data},chartConfig:s,pieSlicesSymbols:T,queryObject:r,options:n,utilsStrings:o,errorStrings:l}),{alteredPieSlicesSymbols:U,alteredConfig:E}=Q;T=U;let O=hh({oldConfig:s,newConfig:E});(b||w||O||u||_)&&xo({data:e.data,newChartConfig:E,pieSlicesSymbols:T,fieldList:et(e.uid,"fieldList")}),lr({data:T,htmlContainer:e.htmlContainer,chartId:e.id,colorMatchApplied:Qu(e,E)}),await qg({chart:e,queryObject:r,chartConfig:E,seriesIndexMapper:new Map,options:n,dataWasUpdated:b,sortChanged:g,chartData:y,groupOfSlicesWasUpdated:B,pieSlicesSymbols:T,utilsStrings:o,errorStrings:l}),Lc(t.headerElements,{title:E.title,subtitle:E.subtitle}),Uc(t.footerElements,E.footer),_h({legendElements:t.legendElements,seriesConfig:E.series,webChartLegend:E.legend,disableTogglingLegendItems:n?.disableTogglingLegendItems,pieChartLegendValueLabelFormatter:n?.pieChartLegendValueLabelFormatter}),Dc(e,E.background),Qc({chart:e,actionMode:n?.actionMode,cursorRange:n?.cursorRange}),vB(e)}async function aD(a){let{chart:e,chartElements:t,newConfig:i,queryObject:s,dataInfo:r,dataWasUpdated:n,options:A,utilsStrings:o,errorStrings:l}=a,{xAxisLabelFormatter:c,gaugeInnerLabelFormatter:h,guideTooltipFormatter:d}=A??{},u=i.series,g=Oe(u),y;if(n){let{count:T,data:Q,queryConfig:U}=r??{};y=Q,y?.dataItems!==void 0&&(e.data=y.dataItems),Lr({data:{dataItems:e.data},seriesConfig:i.series,htmlContainer:e.htmlContainer}),Sn(e.htmlContainer),Ft(e.uid,{elementCount:T,queryConfig:U})}let m=(await Yg({chart:e,data:{dataItems:e.data},chartConfig:i,queryObject:s,options:A,utilsStrings:o,errorStrings:l})).alteredConfig;m.axes!==void 0&&await Zg({chart:e,chartConfig:m,chartType:g,data:y,queryObject:s,xAxisLabelFormatter:c,gaugeInnerLabelFormatter:h,guideTooltipFormatter:d,utilsStrings:o,errorStrings:l});let b=Te.gauge,B=Number.isFinite(m?.innerRadius)?m.innerRadius:b.innerRadius,w=Number.isFinite(m?.startAngle)?m.startAngle:b.startAngle,_=Number.isFinite(m?.endAngle)?m.endAngle:b.endAngle;e.innerRadius=ji(B),e.startAngle=w,e.endAngle=_,Lc(t.headerElements,{title:m.title,subtitle:m.subtitle}),Uc(t.footerElements,m.footer),Dc(e,m.background),Ft(e.uid,{config:oi(m)})}async function nD(a){let{chartContainer:e,chartConfig:t,colorMatchApplied:i,queryObject:s,dataInfo:r,t9nStrings:n,options:A,globalOptions:o,loaderHandle:l}=a,{errorStrings:c,utilsStrings:h}=n;cA.commercialLicense=o?.hideLicenseWatermark!==!1,cA.queue=o?.queueChartCreation!==!1,cA.autoDispose=o?.autoDisposeChart===!0,o?.useAnimatedCharts===!0?Qy(Uh):ky(Uh);let d;switch(Oe(t?.series)){case P.PieSeries:hr(s),d=await tD({chartContainer:e,chartConfig:t,queryObject:s,dataInfo:r,colorMatchApplied:i,options:A,globalOptions:o,utilsStrings:h,errorStrings:c,loaderHandle:l});break;case P.GaugeSeries:hr(s),d=await iD({chartContainer:e,chartConfig:t,queryObject:s,dataInfo:r,options:A,globalOptions:o,utilsStrings:h,errorStrings:c,loaderHandle:l});break;default:d=await eD({chartContainer:e,chartConfig:t,dataInfo:r,colorMatchApplied:i,queryObject:s,options:A,globalOptions:o,t9nStrings:n,loaderHandle:l});break}return d}async function AD(a){let{chartContainer:e,chartConfig:t,t9nStrings:i,queryObject:s,options:r,colorMatchApplied:n,rendererFieldNames:A,globalOptions:o,dataInfo:l,uniqueInternalID:c,loaderHandle:h}=a,{errorStrings:d}=i,u=!Ib(e),g=await nD({chartContainer:e,chartConfig:t,dataInfo:l,colorMatchApplied:n,queryObject:s,t9nStrings:i,options:r,globalOptions:o,loaderHandle:h}),{chart:y,chartElements:m}=g;Ft(y.uid,{chartWasCreatedWhileHidden:u,queryObject:s,filterBySelection:r?.filterBySelection,options:r,colorMatchApplied:n,rendererFieldNames:A}),ZI(y,d),KI(y,e);function b(){c&&F0.delete(c),y.isDisposed()||(Dv(y),m!==void 0&&(g.chartElements=void 0),y.dispose())}async function B(Q){let{newChartConfig:U,dataWasUpdated:E,dataUpdateDetails:O,queryObject:D,updateOptions:k,t9nStrings:{utilsStrings:F},configWithAllSeries:M,hasSeriesFilteredOut:Y,dataInfo:z,loaderHandle:re}=Q,q=et(y.uid,"config"),Ae=U?.series,X=Ae!==void 0?Oe(Ae):void 0;if(y.isDisposed()||m===void 0||!Jd(q,U))throw new oa(bA.ChartDisposed);switch(X){case P.BoxPlotSeries:case P.BarSeries:case P.LineSeries:case P.ComboLineAndBarSeries:y instanceof Is&&await sD({chart:y,chartElements:m,queryObject:D,dataWasUpdated:E,dataUpdateDetails:O,dataInfo:z,newConfig:U,configWithAllSeries:M,hasSeriesFilteredOut:Y,options:k,utilsStrings:F,errorStrings:d,loaderHandle:re});break;case P.PieSeries:hr(D),await rD({chart:y,chartElements:m,queryObject:D,dataWasUpdated:E,dataInfo:z,newConfig:U,options:k,utilsStrings:F,errorStrings:d});break;case P.GaugeSeries:hr(D),await aD({chart:y,chartElements:m,newConfig:U,queryObject:D,dataWasUpdated:E,dataInfo:z,options:k,utilsStrings:F,errorStrings:d});break}}async function w(Q){let{newChartConfig:U,updateOptions:E,dataWasUpdated:O,dataUpdateDetails:D,configWithAllSeries:k,hasSeriesFilteredOut:F,colorMatchApplied:M,rendererFieldNames:Y,updateGlobalOptions:z,t9nStrings:re,queryObject:q,dataInfo:Ae,loaderHandle:X}=Q,G=!Ib(e),ue=$s(q,r?.usePopupTemplateFieldsInfo);Ft(y.uid,{chartWasUpdatedWhileHidden:G,options:E,fieldList:ue,queryObject:q,colorMatchApplied:M,rendererFieldNames:Y}),await B({newChartConfig:U,updateOptions:E,dataWasUpdated:O,dataUpdateDetails:D,t9nStrings:re,configWithAllSeries:k,hasSeriesFilteredOut:F,queryObject:q,dataInfo:Ae,loaderHandle:X})}async function _(Q){if(bh(y)&&(y instanceof Is||y instanceof Tr)){let U=et(y.uid,"actionMode");U!==Nt.MonoSelection&&U!==Nt.None&&await Ov(y,Q)}}function T(){Fo(y)}return{update:w,dispose:b,resetZoom:T,clearSelection:()=>Wu({chart:y}),switchSelection:async Q=>await _(Q),exportImage:async Q=>await Lv({chart:y,exportOptions:Q}),setActionMode:(Q,U)=>Qc({chart:y,actionMode:Q,cursorRange:U}),loaderHandle:h}}var oD="AM5C241025748",ot={SelectEnded:"selectended",DataValidated:"datavalidated",BoundsChanged:"boundschanged",PointerUp:"pointerup",FrameEnded:"frameended",Click:"click"},Mg=new Map;function lD(a,e){return jn(a,e)}function hD(a,e){Yn(a,e)}function Yn(a,e){let t=Mg.get(a)??{};Mg.set(a,{...t,...e})}function jn(a,e){return Mg.get(a)?.[e]}function te(a,e){return jn(a,e)}function Pt(a,e){Yn(a,e)}function Ge(a,e){return jn(a,e)}function gi(a,e){Yn(a,e)}function br(a,e){return jn(a,e)}function HA(a,e){Yn(a,e)}function Yr(a,e){return jn(a,e)}function cD(a,e){Yn(a,e)}function Ss(a,e){return jn(a,e)}function ep(a,e){Yn(a,e)}function dD(a,e){return jn(a,e)}function uD(a,e){Yn(a,e)}function tp(a){return a!=null&&!a.isDisposed()}function fD(a){let e;if(a!=null){let t=a;if(t instanceof ti)e=t.chart;else{let i=t.dataItem?.component;i instanceof ti&&(e=i.chart)}}return e}function _B(a){let e;if(a){let t=a.get("background")?.get("fill");if(t){let{r:i,g:s,b:r}=t;e=[Math.round(i),Math.round(s),Math.round(r),255]}}return e}function FB(a){let e=$i(a),{r:t,g:i,b:s}=e;return{r:t,g:i,b:s}}function gD(a,e){e===!0&&a.setThemes([_b.new(a)])}function pD(a,e){e===!0&&a.setThemes([Cb.new(a)])}function Ye(a){let e=$i("#000000"),t=th;if(a!=null){let[i,s,r,n]=a;t=n/255,e=$i(`rgba(${i}, ${s}, ${r}, ${t})`)}return{color:e,opacity:t}}function Vt(a,e){e===!1&&(!("isHiding"in a)||!a.isHiding())?(a.set("visible",!1),"hide"in a&&a.hide()):e!==!1&&(!("isShowing"in a)||!a.isShowing())&&(a.set("visible",!0),"show"in a&&a.show())}function yt(a){let{childId:e,parent:t,useChildId:i}=a,s=i?e:Qi(e,t.uid);return t.children.values.find(r=>r.get("id")===s)}function Qi(a,e){return`${a}${e}`}function hn(a,e=100){return setTimeout(()=>a(),e)}function Ub(a){let e=Number.NaN;if(typeof a=="number")e=a;else if(a.includes("%")){let t=Number.parseFloat(a.trim().replace("%","").trim());Number.isFinite(t)&&(e=Re(t))}return e}function mD(a,e){return e!==!0||a?.includes("Dot")===!0?"round":"square"}function yD(a,e){let t=a??ar.Solid,i=e??$.lineWidth,s={[ar.Solid]:[],[ar.Dot]:[1,i],[ar.DashDotDot]:[4*i,i,1,i,1,i],[ar.Dash]:[4*i,3*i],[ar.DashDot]:[4*i,3*i,1,3*i],[ar.Null]:[]};return s[t]??s[ar.Null]}function vD(a){let{root:e,fill:t,rotation:i,isLinePattern:s,chartBackgroundFill:r}=a,n;if(s!==!1){let{tileSize:A,diagonalTileSize:o}=$.patternLineProperties,l=i===45||i===135,c=l?o:A;n=ya.new(e,{width:c,height:c,strokeWidth:$.patternLineProperties.strokeWidth??1,gap:6,color:t,...l?{angle:i}:{rotation:i??Number.NaN},...r!==void 0&&{fill:r,fillOpacity:1}})}else{let A=r!==void 0?1:$.patternRectProperties.fillOpacity??Number.NaN;n=Ja.new(e,{width:$.patternRectProperties.width??Number.NaN,height:$.patternRectProperties.height??Number.NaN,strokeWidth:$.patternRectProperties.strokeWidth??Number.NaN,fillOpacity:A,color:r??t,fill:t,gap:1,maxWidth:$.patternRectProperties.rectWidth??Number.NaN,maxHeight:$.patternRectProperties.rectHeight??Number.NaN,rotation:i??Number.NaN})}return n}function xD(a){let{fill:e,root:t,style:i,chartBackgroundFill:s}=a,r,n,A=!0;switch(i){case Ir.Horizontal:{n=0;break}case Ir.Vertical:{n=90;break}case Ir.ForwardDiagonal:{n=135;break}case Ir.BackwardDiagonal:{n=45;break}case Ir.Cross:{n=0,A=!1;break}case Ir.DiagonalCross:{n=135,A=!1;break}case Ir.Solid:}return n!==void 0&&t!==void 0&&(r=vD({root:t,fill:e,rotation:n,isLinePattern:A,chartBackgroundFill:s})),r}function SB(a,e=0){return(a??e)%360}function TB(a,e){let t={stroke:Ye().color,strokeWidth:$.lineWidth,strokeDasharray:[],linecap:e!==!0?"round":"square",strokeOpacity:th};if(a!=null){let i=Ye(a.color);t.stroke=i.color,t.strokeOpacity=i.opacity,a.width!==void 0&&(t.strokeWidth=a.width,t.strokeOpacity=a.width===0?0:i.opacity),a.style!==void 0&&a.style!==ar.Null&&(t.strokeDasharray=yD(a.style,t.strokeWidth),t.linecap=mD(a.style,e))}return t}function IB(a,e){let t=a,[i,s,r,n]=a?.color??e??$.color,A=[i,s,r,n];return t==null?t={type:ht.SLS,color:A}:t.color===void 0&&(t.color=A),TB(t,!1)}function bD(a,e,t){let{color:i,outline:s,style:r}=a,n=Ye(i),A=Yd(r),o;return t!==void 0?o=Ye(t).color:A&&(o=Ye($.backgroundColor).color),{pattern:xD({root:e,fill:n.color,style:r,chartBackgroundFill:o}),fill:n.color,outline:IB(s,i),fillOpacity:n.opacity}}function BD(a){let{color:e,style:t,size:i,outline:s,xoffset:r,yoffset:n,angle:A}=a,o=SB(A),l=t!==void 0?jy(t,i):"",c=Ye(e),h=s;return t!==ql.Cross&&t!==ql.X&&i!==void 0&&i<=$.lineSeries.marker.markerSizeThresholdForTooltipDisplay&&(s?.width===void 0||s.width===0)&&(h={type:ht.SLS,style:s?.style??ar.Solid,color:[0,0,0,0],width:$.lineSeries.marker.markerSizeThresholdForTooltipDisplay-i}),{path:l,fill:c.color,outline:IB(h,e),xOffset:r??0,yOffset:n??0,angle:o,fillOpacity:c.opacity}}function wD(a){let e;switch(a){case Jl.LineThrough:case Jl.Underline:e=a;break;case Jl.None:}return e}function CD(a){return a===!0?"wrap":"none"}function DB(a,e){let t=ye;switch(a??e){case xi.Right:t=se;break;case xi.Left:t=si;break;case xi.Center:case xi.Justify:}return t}function LB(a,e){let t=ye;switch(a??e){case Ct.Top:t=si;break;case Ct.Bottom:t=se;break;case Ct.Baseline:case Ct.Middle:}return t}function _D(a){let{angle:e,mappedHAlignment:t,mappedVAlignment:i,isGuideLabel:s}=a,r=t,n=i,A=t,o=i;return(Math.abs(e)===270||Math.abs(e)===90)&&(s||(A=void 0,n=void 0),o===si?r=se:o===se?r=si:o===ye&&(r=ye)),{align:r,valign:n,horizontalCenter:A,verticalCenter:o}}function ip(a){let{root:e,symbol:t,defaultToColorFromRamp:i,colorRampIndex:s,isChartFillSymbol:r=!1,chartBackgroundColor:n}=a,A;if(i===!0){let o=r?Vd:th;if(t.color=t.color??yA({colorIndex:s,opacity:o}),fh(t)||wu(t)){let{outline:l}=t;l!==void 0&&(l.color=l?.color??yA({colorIndex:s}),t.outline={...l})}}return ov(t)?A=TB(t,!0):wu(t)?(t.style??=$.lineSeries.marker.markerStyle,t.size??=$.lineSeries.marker.markerBigSize,A=BD(t)):fh(t)&&(A=bD(t,e,n)),A}function FD(a){let{input:e,isGuideLabel:t,defaults:i}=a,s=SB(e.angle,i?.rotation),r=DB(e.horizontalAlignment,i?.horizontalCenter),n=LB(e.verticalAlignment,i?.verticalCenter),{align:A,valign:o,horizontalCenter:l,verticalCenter:c}=_D({angle:s,mappedHAlignment:r,mappedVAlignment:n,isGuideLabel:t});return{fill:Ye(e.color).color,fontFamily:e.font?.family??"Arial, Helvetica, sans-serif",fontSize:e.font?.size??$.generalFontSize,fontWeight:e.font?.weight??"400",textDecoration:wD(e.font?.decoration),align:A,valign:o,verticalCenter:c,horizontalCenter:l,text:nr({textSymbol:e,format:"amChartsV5"}),angle:s,xOffset:e.xoffset??i?.dx??0,yOffset:e.yoffset??i?.dy??0,backgroundFill:Ye(e.backgroundColor).color,borderFill:Ye(e.borderLineColor).color,borderWidth:e.borderLineSize??1,haloColor:Ye(e.haloColor).color,rtl:(e.rightToLeft??Wl(document.documentElement))==="rtl"?"rtl":"ltr",wrap:CD(i?.wrap),maxWidth:i?.maxWidth??Number.NaN}}function UB(a,e){e!==void 0&&(e.marginBottom!==void 0&&a.set("marginBottom",e.marginBottom),e.marginTop!==void 0&&a.set("marginTop",e.marginTop),e.marginRight!==void 0&&a.set("marginRight",e.marginRight),e.marginLeft!==void 0&&a.set("marginLeft",e.marginLeft),e.verticalCenter!==void 0&&a.set("y",LB(e.verticalCenter)),e.horizontalCenter!==void 0&&a.set("x",DB(e.horizontalCenter)),e.strokeWidth!==void 0&&a.get("background")?.set("strokeWidth",e.strokeWidth),e.paddingBottom!==void 0&&a.set("paddingBottom",e.paddingBottom),e.paddingTop!==void 0&&a.set("paddingTop",e.paddingTop),e.paddingLeft!==void 0&&a.set("paddingLeft",e.paddingLeft),e.paddingRight!==void 0&&a.set("paddingRight",e.paddingRight),e.maxWidth!==void 0&&a.set("maxWidth",e.maxWidth))}function EA(a){let{root:e,parent:t,defaults:i,index:s,id:r}=a,n=Ze.new(e,{text:"",textAlign:"center",background:Tt.new(e,{}),paddingBottom:0,paddingTop:0,paddingLeft:0,paddingRight:0});return r!==void 0&&n.set("id",r),UB(n,i),t!==void 0&&t.children.insertIndex(s??t.children.length,n),n}function Qb(a){let{label:e,offset:t,offsetProperty:i}=a;e.adapters.remove(i),(e instanceof Ze?[e]:e.entities).forEach(s=>{if(typeof t=="string"&&!Number.isFinite(Number(t))){let r=nu(t);typeof r=="number"&&(r/=100,s.adapters.add(i,()=>(i==="dx"?s.width():s.height())*(r??0)))}else{let r=Number(t);Number.isFinite(r)&&s.set(i,r)}})}function Es(a){let{label:e,labelConfig:t,defaults:i,skipSettingText:s,skipSettingXAndY:r}=a,n=t?.visible??!0;if(e!==void 0&&!e.isDisposed()&&t!==void 0){let A=e instanceof Ze&&Ss(e.uid,"isGuide"),o=FD({input:t.content,isGuideLabel:A,defaults:i});e.setAll({fill:o.fill,fontFamily:o.fontFamily,fontWeight:o.fontWeight,fontSize:o.fontSize,textDecoration:o.textDecoration,rotation:o.angle,direction:o.rtl,oversizedBehavior:o.wrap,maxWidth:o.maxWidth}),s||e.setAll({text:o.text}),r||(Qb({label:e,offset:o.xOffset,offsetProperty:"dx"}),Qb({label:e,offset:o.yOffset,offsetProperty:"dy"}),e.setAll({centerX:o.align,centerY:o.valign,x:o.horizontalCenter,y:o.verticalCenter})),e.get("background")?.setAll({strokeWidth:o.borderWidth,strokeOpacity:1}),e.set("visible",n),e instanceof Ze?Vt(e,n):e.entities.forEach(l=>{Vt(l,n)})}}function Wr(a){let{chart:e,label:t,labelType:i}=a,{legendTitle:s}=$.legendProperties,r=te(e.uid,"config"),n=s.maxWidth??Number.NaN,A=Number.NaN;switch(i){case St.GuideLabel:if(e instanceof ct){let o=t.get("rotation");o===90||o===270?n=e.seriesContainer.height():n=e.seriesContainer.width()}break;case St.XAxisTitle:e instanceof ct&&(n=e.seriesContainer.width());break;case St.YAxisTitle:e instanceof ct&&(A=e.seriesContainer.height());break;case St.ChartTitle:case St.ChartSubTitle:case St.ChartFooter:n=e.chartContainer.width()-20;break;case St.LegendTitle:r?.legend?.position!==void 0&&(r?.legend?.position===je.Top||r?.legend?.position===je.Bottom)&&(n=e.chartContainer.width()-20);break}n>0&&t.setAll({maxWidth:n,oversizedBehavior:"wrap"}),A>0&&i===St.YAxisTitle&&t.setAll({maxHeight:A,oversizedBehavior:"wrap"})}function PA(a){let{chart:e}=a;Wr(a),e.events.onDebounced(ot.BoundsChanged,()=>Wr(a),$.debounceTime)}function QB(a){let{hour:e,minute:t=0,format:i,locale:s="en-US"}=a,r=i&&Object.keys(i).length>0?i:{hour:"numeric",minute:"2-digit",hour12:!1},n=e.toString();if(Number.isInteger(e)&&e>=0&&e<=23&&Number.isInteger(t)&&t>=0&&t<=59){let A=new Date(2e3,0,1,e,t);n=new Intl.DateTimeFormat(s,r).format(A),n.includes(":")||n.startsWith("0")&&(n=n.slice(1))}return n}function kB(a){let{weekdayNumber:e,format:t,locale:i="en-US",firstDayOfWeek:s=7}=a,r=t&&Object.keys(t).length>0?t:{weekday:"long"},n=e.toString();if(Number.isInteger(e)&&e>0&&e<=7&&Number.isInteger(s)&&s>0&&s<=7){let A=(e+s-1)%7,o=new Date(2e3,0,2+A);n=new Intl.DateTimeFormat(i,r).format(o)}return n}function EB(a){let{monthNumber:e,format:t,locale:i="en-US"}=a,s=t&&Object.keys(t).length>0?t:{month:"long"},r=e.toString();if(Number.isInteger(e)&&e>0&&e<=12){let n=new Date(2e3,e-1);r=new Intl.DateTimeFormat(i,s).format(n)}return r}function _c(a,e){let t=e.get("axisFill"),i=e.get("label");if(t!==void 0&&i!==void 0){let s=Ss(i.uid,"guideLabelConfig"),r=a.get("renderer")instanceof fi,n=Math.round(t.width()),A=Math.round(t.height()),o=Math.round(i.height()),l=Math.round(i.width()),{horizontalAlignment:c,verticalAlignment:h}=s??{},d=0,u=0;if(r){let g=n!==0;switch(c){case xi.Left:g?d=-l/2:d=-l;break;case xi.Right:g?d=l/2:d=l;break;case xi.Center:case xi.Justify:break;default:g||(d=l/2);break}switch(h){case Ct.Bottom:g?u=-o:u=-o/2;break;case Ct.Middle:u=-A/2;break;case Ct.Top:default:u=-A+o/2;break}}else{let g=A!==0;switch(c){case xi.Center:d=n/2;break;case xi.Left:d=l/2;break;case xi.Right:default:d=n-l/2;break}switch(h){case Ct.Bottom:g?u=A/2:u=o;break;case Ct.Top:g?u=-A/2+o/2:u=-o;break;case Ct.Middle:default:g||(u=-o/2);break}}i.setAll({dx:d,dy:u})}}function SD(a){let{axis:e,guide:t,label:i}=a,{chart:s}=e;if(s){let r=e.get("renderer")instanceof fi?s.yAxes.getIndex(0):s.xAxes.getIndex(0);r&&(r.events.onDebounced(ot.BoundsChanged,()=>_c(e,t),$.debounceTime),e.events.onDebounced(ot.BoundsChanged,()=>_c(e,t),$.debounceTime))}i.setAll({paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0})}function TD(a){let{guide:e,axis:t,guideLabelConfig:i}=a,s=e.get("label");if(s!==void 0){UB(s),ep(s.uid,{isGuide:!0,guideLabelConfig:i});let{chart:r}=t;r!==void 0&&PA({chart:r,label:s,labelType:St.GuideLabel}),SD({axis:t,guide:e,label:s})}}function ID(a){let{axis:e,guide:t,guideConfig:i,guideType:s}=a,r=t?.get("label");if(r!==void 0)if(i.label!==void 0){let n=e.get("renderer")instanceof fi,A;e instanceof Ui||(n?s===ht.SFS?A=$.verticalSurfaceGuideLabels:A=$.verticalLineGuideLabels:s===ht.SFS?A=$.horizontalSurfaceGuideLabels:A=$.horizontalLineGuideLabels),ep(r.uid,{guideLabelConfig:i.label});let o={type:P.Text,visible:i.visible,content:{...i.label,verticalAlignment:Ct.Middle,horizontalAlignment:xi.Center,rightToLeft:r.get("direction")==="rtl"}};Es({label:r,labelConfig:o,defaults:A});let l=i.label?.text;typeof l=="string"&&/<\/?[a-z][\s\S]*>/iu.test(l)&&(r.set("html",vs(l)),r.set("text","")),r.events.once(ot.BoundsChanged,()=>{_c(e,t)}),_c(e,t)}else Vt(r,!1)}function PB(a){let{element:e,fill:t,fillOpacity:i,pattern:s,chartBackgroundFill:r}=a,n=e.get("tooltip"),A=!0,o=e;if(s!==void 0){n!==void 0&&(A=!1,n.get("background")?.set("fill",t)),o.set("fillPattern",s);let l=r??t;o.set("fill",l),o.set("fillOpacity",1),o.set("themeTags",[]);let c=o.dataItem?.component;c&&c instanceof ti&&((c.uid!==void 0?Ge(c.uid,"bulletTemplate"):void 0)?.adapters?.remove?.("fill"),c instanceof mt&&c.columns?.template?.adapters?.remove?.("fill"))}else o.set("fill",t),o.remove("fillPattern"),o.set("fillOpacity",i);n!==void 0&&n.set("getFillFromSprite",A)}function Fc(a,e){a.setAll({stroke:e.stroke,strokeDasharray:e.strokeDasharray,strokeOpacity:e.strokeOpacity,strokeWidth:e.strokeWidth,lineCap:e.linecap})}function MB(a){let{element:e,markerSymbol:t,visible:i,defaultToColorFromRamp:s,colorRampIndex:r}=a,n;return e!==void 0&&t!==void 0&&(n=ip({symbol:t,defaultToColorFromRamp:s,colorRampIndex:r}),n!==void 0&&(e.setAll({svgPath:n.path,rotation:n.angle,dx:n.xOffset,dy:n.yOffset}),PB({element:e,fill:n.fill,fillOpacity:n.fillOpacity}),Fc(e,n.outline)),Vt(e,i)),n}function cn(a){let{root:e,element:t,fillSymbol:i,visible:s,defaultToColorFromRamp:r,colorRampIndex:n,isChartFillSymbol:A,keepCurrentVisibility:o,chartBackgroundColor:l}=a,c=Yd(i?.style),h=fD(t),d=l??(c?_B(h)??[...$.backgroundColor]:void 0),u;if(t!==void 0&&!t.isDisposed()){if(i!==void 0&&(u=ip({root:e,symbol:i,defaultToColorFromRamp:r,colorRampIndex:n,isChartFillSymbol:A,chartBackgroundColor:d}),u!==void 0)){let g=d!==void 0?Ye(d).color:void 0;PB({element:t,fill:u.fill,fillOpacity:u.fillOpacity,pattern:u.pattern,chartBackgroundFill:g}),Fc(t,u.outline)}o||Vt(t,s)}return u}function vr(a){let{element:e,lineSymbol:t,visible:i,defaultToColorFromRamp:s,colorRampIndex:r}=a,n;return e!==void 0&&!e.isDisposed()&&(t!==void 0&&(n=ip({symbol:t,defaultToColorFromRamp:s,colorRampIndex:r}),n!==void 0&&(Fc(e,n),e instanceof qe&&Fc(e.strokes.template,n))),Vt(e,i)),n}function Fs(a){let{root:e,element:t,seriesIndex:i,seriesSymbol:s,isChartFillSymbol:r,colorMatch:n,rendererSymbol:A,keepCurrentVisibility:o}=a,l,c;n&&A!==void 0&&(l=e0({rendererSymbol:A,seriesSymbol:s,colorIndex:i}));let h={root:e,element:t,defaultToColorFromRamp:!0,colorRampIndex:i},d=l??{...s};switch(s.type){case ht.SLS:c=vr({...h,lineSymbol:d});break;case ht.SFS:c=cn({...h,fillSymbol:d,isChartFillSymbol:r,keepCurrentVisibility:o});break;case ht.SMS:c=MB({...h,markerSymbol:d});break}return{symbolWithColorInfo:d,stylingInfo:c}}function kb(a,e){if(e!==void 0){let{elementColor:t,elementOutlineColor:i,elementOutlineWidth:s,rotation:r,transformation:n}=e,{opacity:A,scale:o}=n??{};t!==void 0&&a.setAll({fill:Ye(t).color,fillOpacity:1}),i!==void 0&&a.setAll({stroke:Ye(i).color,strokeOpacity:1}),s!==void 0&&a.setAll({strokeWidth:s}),r!==void 0&&a.setAll({rotation:r}),o!==void 0&&a.setAll({scale:o}),A!==void 0&&(a.setAll({fillOpacity:(a.get("fillOpacity")??1)*A}),a.setAll({strokeOpacity:(a.get("strokeOpacity")??1)*A}))}}async function DD(a=Zl(document.documentElement).t9nLocale){let e=await import("./DOJQQMHT.js");switch(a){case"ar":e=await import("./DBZZDGFN.js");break;case"bs":e=await import("./7WFAXHLM.js");break;case"bg":e=await import("./QF7PCBW5.js");break;case"ca":e=await import("./IJV4GPC2.js");break;case"cs":e=await import("./UWTDBFUQ.js");break;case"da":break;case"de":e=await import("./FJQT5KJP.js");break;case"el":e=await import("./5BCD22Z4.js");break;case"es":e=await import("./UV5SARBS.js");break;case"et":e=await import("./QJT4EUS4.js");break;case"fi":e=await import("./YFFVERLU.js");break;case"fr":e=await import("./4F37LPEF.js");break;case"he":e=await import("./LSVE7QXZ.js");break;case"hr":e=await import("./VBEHPXA6.js");break;case"hu":e=await import("./FE6JBDVY.js");break;case"id":e=await import("./PXARJZNJ.js");break;case"it":e=await import("./4BLJCGW5.js");break;case"ja":e=await import("./63Y6JME7.js");break;case"ko":e=await import("./VSGEUWLS.js");break;case"lt":e=await import("./TCBSBBWS.js");break;case"lv":e=await import("./TQXS55IG.js");break;case"no":e=await import("./HOLFKH7Q.js");break;case"nl":e=await import("./PBJ6N3WD.js");break;case"pl":e=await import("./BZOGCJZN.js");break;case"pt-BR":e=await import("./L3GOQ5OW.js");break;case"pt-PT":e=await import("./ZG6HIUYV.js");break;case"ro":e=await import("./K2B3HXTF.js");break;case"ru":e=await import("./2NTJWJIL.js");break;case"sr":e=await import("./C2AG56ML.js");break;case"sk":e=await import("./FPBBWTJ7.js");break;case"sl":e=await import("./S4E3LX4H.js");break;case"sv":e=await import("./5GTDAUJP.js");break;case"th":e=await import("./P2QEICEQ.js");break;case"tr":break;case"uk":e=await import("./UFA45G3D.js");break;case"vi":e=await import("./T3SPP6VD.js");break;case"zh-CN":e=await import("./2XF6LPQI.js");break;case"zh-HK":e=await import("./X6O3IA2W.js");break;case"zh-TW":e=await import("./X6O3IA2W.js");break}let t=(await fv(a)).customAmchartsStrings;return{...e.default,...t}}function er(a){let{root:e,type:t,intlOptions:i,formatLocale:s}=a,r;switch(t){case P.NumberAxisFormat:{r=za.new(e,{}),r.set("intlLocales",s),r.set("numberFormat",i);break}case P.DateAxisFormat:{r=Hn.new(e,{}),r.set("intlLocales",s);break}}return r}function LD(a,e,t){let i=e-a,s=[];if(i!==0){if(t===1)s=[a];else if(t>1){let r=i/(t-1);s=[...f0(a,e,r),e]}}return s}function UD({x:a,mean:e,stddev:t,scalingFactor:i}){let s=-1/(2*t**2);return(i??1)*Math.exp(s*(a-e)**2)}function QD(a){let e=0;if(a.length>0)for(let t=0;t<a.length;t+=1)a[t].count>e&&(e=a[t].count);return e}function HB(a){let e=!1,t;if(a.target.dataItem?.component instanceof ti?{chart:t}=a.target.dataItem.component:(a.target instanceof Js||a.target instanceof Gr)&&({chart:t}=a.target),t instanceof ct||t instanceof Li){let i=te(t.uid,"actionMode");if(i!==void 0){let{originalEvent:s}=a;e=i===Nt.MultiSelection||i===Nt.MultiSelectionWithCtrlKey&&("ctrlKey"in s&&s.ctrlKey||"metaKey"in s&&s.metaKey)}}return e}function Xi(a){let{element:e,selected:t,multiSelect:i,isDateOrCategoryAxis:s,backToDefaultState:r}=a,n=!1;if(e!==void 0){let A=Yr(e.uid,"selected")??!1;n=A,i!==!0?s===!0?n=A?!1:A!==t:n=t:n=A!==t;let o=r===!0?Ha.Default:Ha.CustomInactive;e.states.apply(Ha.Default),e.states.apply(n?Ha.CustomActive:o),n!==A&&(cD(e.uid,{selected:n}),n&&(e.toFront(),e.dataItem?.component instanceof ti&&e.dataItem.component.toFront()))}return n}function kD(a,e){let t=te(e.chart?.uid??Number.NaN,"actionMode"),i=HB(a);return t===Nt.MonoSelection||t===Nt.MultiSelectionWithCtrlKey&&!i}function pi(a,e){let{selectedElementsTheme:t,nonSelectedElementsTheme:i}=e??$.selectionTheme??{},s=a.states.create(Ha.CustomActive,{}),r=a.states.create(Ha.CustomInactive,{});kb(s,t),kb(r,i)}function MA(a){let{value:e,valueFormat:t,formatLocale:i,root:s}=a,r=e?.toString(),n=er({type:t.type,intlOptions:t.intlOptions,formatLocale:i,root:s});return typeof e=="number"&&t.type===P.NumberAxisFormat?r=n.format(e,fA(t)):(typeof e=="number"||e instanceof Date)&&t.type===P.DateAxisFormat&&(r=n.format(e,fA(t))),r}async function ED(a){let{root:e,exportOptions:t}=a,{format:i,quality:s=1,...r}=t,n=s<0||s>1?1:s,A=await An.new(e,{}).exportImage(i,{quality:n,...r}),o=Iv(A),l=i==="jpg"?"image/jpeg":"image/png";return new File([o],`chart.${i}`,{type:l})}function kA(a,e){if(a!==void 0&&e!==void 0&&(a.states.lookup("default")?.setAll({fill:e.fill,fillOpacity:e.fillOpacity}),e.outline!==void 0)){let{outline:t}=e;a.states.lookup("default")?.setAll({stroke:t.stroke,strokeOpacity:t.strokeOpacity,strokeDasharray:t.strokeDasharray,lineCap:t.linecap,strokeWidth:t.strokeWidth})}}function RB(a){let{numberFormatter:e,dataLabelsConfigContent:t,stackedType:i,externalDataLabelFormatter:s}=a;return(r,n)=>{let A=i===Hi.Stacked100&&n!==void 0?n:r;return e.get("numberFormat").style==="percent"&&(A/=100),nr({textSymbol:{...t,text:e.format(A)},format:s===void 0?"amChartsV5":"html"})}}function PD(a,e){let t=a.dataItem,i;switch(e){case P.LineSeries:case P.ScatterSeries:i=t.get("point");break;case P.HistogramSeries:case P.BarSeries:case P.HeatSeries:i=t.get("graphics");break}let s=i??a,r=i?.x??s?.get("x")??0,n=i?.y??s?.get("y")??0;return{x:r,y:n}}function OB(a){let{label:e,chart:t,seriesType:i}=a,s=n=>{if(t instanceof ct){let A=PD(n,i),o=t.plotContainer,l=o.x(),c=o.y(),h=A.x<l||A.x>l+o.width()||A.y<c||A.y>c+o.height();n.setAll({visible:!h,forceHidden:h})}},r=Ao((n,A)=>{A&&s(A)},$.debounceTime);e.on("x",r),e.on("y",r)}function MD(a){let{series:e,label:t,isHeatChart:i}=a;t.adapters.add("y",(s,r)=>{let{chart:n}=e,A=n!==void 0?te(n.uid,"isRotated"):!1,o=typeof s=="number"?s:s?.value,l=r.dataItem;if(l!==void 0&&o!==void 0&&o!==null){let c=l?.get("valueY"),h=r.localBounds().bottom;if(A!==!0){let d=$.dataLabelNegative?.paddingTop??0;if(e.get("stacked")||i)if(c<0)o+=h-d;else{let u=i?$.heatChartLabelPadding.paddingTop:0;o+=h/2+u}}else{let d=$.rotatedChartPadding?.paddingTop??0;o+=h/2+d}}return o}),t.adapters.add("x",(s,r)=>{let{chart:n}=e,A=n!==void 0?te(n.uid,"isRotated"):!1,o=typeof s=="number"?s:s?.value,l=r.dataItem;if(l!==void 0&&o!==void 0&&o!==null&&A===!0){let c=l?.get("valueX"),h=r.width()/2,d=$.rotatedChartPadding?.paddingRight??0,u=h+d;e.get("stacked")||(c<0?o-=u:o+=u)}return o})}function HD(a){let{series:e,isRotated:t,externalDataLabelFormatter:i}=a;e.bullets.push(()=>{let s=te(e.chart?.uid??Number.NaN,"config")?.series?.find(o=>o.id===e.get("id"))?.dataLabels??a.dataLabelsConfig,r=e.get("stacked"),n=ts.new(e.root,{locationY:!r&&!t?1:void 0,locationX:!r&&t?1:void 0,sprite:Ze.new(e.root,{text:t?"{valueX}":"{valueY}",populateText:!0,centerY:se,centerX:si,paddingBottom:0,paddingTop:0,paddingRight:0,paddingLeft:0,fill:Ye(s?.content.color).color,fontSize:s?.content.font?.size})}),A=n.get("sprite");if(A){let o=A;VB({dataLabel:o,series:e,externalDataLabelFormatter:i}),$B({...a,dataLabelsConfig:s,dataLabel:o,dataLabelFormatter:RB})}return n})}function sp(a,e=1){a.bullets.removeIndex(e)}function NB(a){let{textBackgroundColor:e,chartBackgroundColor:t,fillOpacity:i}=a,s;return fo({r:e.r,g:e.g,b:e.b,a:i})?s=fo({r:t.r,g:t.g,b:t.b,a:i})?Ye(Ny).color:t:s=fo({r:t.r,g:t.g,b:t.b,a:i})?t:Ye(Oy).color,s}function RD(a){let{dataLabel:e,labelConfigColor:t,seriesColor:i,backgroundColor:s,autoInverseDataLabelTextColor:r,isHeatChart:n}=a,A=s??Ye($.backgroundColor).color;r===!0&&i&&e.adapters.add("fill",(o,l,c)=>{let h=t??l.text.get("fill"),d=(l.dataItem?.component).get("stacked"),u=h;if(h&&(d||n)){let g=l.dataItem.get("graphics"),y=g?.get("fillOpacity");u=NB({textBackgroundColor:g?.get("fill")??i,chartBackgroundColor:A,fillOpacity:y})}return u})}function VB(a){let{dataLabel:e,series:t,externalDataLabelFormatter:i}=a;e.adapters.remove("text"),e.adapters.remove("html");let s=i!==void 0?"html":"text";sl({label:e,labelOutputProp:s}),e.adapters.add(s,(r,n)=>{let A=r??"",o=n.dataItem,l=Ge(t.uid,t instanceof mt?"barSeriesDataLabelFormatter":"lineSeriesDataLabelFormatter");if(l!==void 0&&t.chart&&o){let c=te(t.chart.uid,"isRotated"),h=c===!0?o.get("valueX"):o.get("valueY"),d=c===!0?o.get("valueXTotalPercent"):o.get("valueYTotalPercent"),u=t.get("valueYShow")==="valueYTotalPercent"||t.get("valueXShow")==="valueXTotalPercent";A=l(u?d:h)}return s==="html"?vs(A):A})}function sl(a){let{label:e,labelOutputProp:t}=a,i=e;t==="html"?i.set("html",$.htmlEmptyContent):i.set("html",void 0)}function kc(a){let{series:e,seriesConfig:t,dataLabel:i,labelDefaults:s,dataLabelsConfig:r,yAxisValueFormat:n,stackedType:A,isRotated:o,seriesType:l,defaultDataLabelFormatter:c,externalDataLabelFormatter:h}=a,{chart:d}=e;if(i!==void 0){let u=h,g=r?.content??{type:ht.TS};if(h===void 0&&c!==void 0&&n?.type===P.NumberAxisFormat&&d){let w=te(d.uid,"formatLocale"),_=er({root:d.root,type:n.type,formatLocale:w,intlOptions:n.intlOptions});u=c({numberFormatter:_,dataLabelsConfigContent:g,stackedType:A,externalDataLabelFormatter:h})}let y;switch(l){case P.BarSeries:y="barSeriesDataLabelFormatter";break;case P.LineSeries:y="lineSeriesDataLabelFormatter";break;case P.HistogramSeries:y="histogramDataLabelFormatter";break;case P.ScatterSeries:y="scatterplotDataLabelFormatter";break;case P.HeatSeries:y="heatChartDataLabelFormatter";break}y!==void 0&&gi(e.uid,{[y]:u}),r!==void 0&&(l===P.HeatSeries?r.content.text="{value}":r.content.text=o===!0?"{valueX}":"{valueY}",r.visible=r.visible!==!1),Es({label:i,labelConfig:r,defaults:s??$.dataLabel,skipSettingText:!0});let m=e.get("stacked"),b=m&&l===P.BarSeries&&t?.hideOversizedStackedLabels!==!1,B=!m&&l===P.BarSeries&&t?.hideOversizedSideBySideLabels===!0;B||b?i.setAll({oversizedBehavior:"hide",maxWidth:void 0,maxHeight:B?100:void 0}):i.setAll({oversizedBehavior:"none"})}}function OD(a){let{series:e,labelDefaults:t,externalDataLabelFormatter:i}=a;e.dataItems.forEach(s=>{let r=s.bullets?.[1];if(r){r.set("locationY",e.get("stacked")?void 0:1);let n=r.get("sprite");n&&(VB({dataLabel:n,series:e,externalDataLabelFormatter:i}),kc({...a,dataLabel:n,labelDefaults:t,defaultDataLabelFormatter:RB,externalDataLabelFormatter:i}))}})}function $B(a){let{series:e,dataLabelsConfig:t,autoInverseDataLabelTextColor:i,externalDataLabelFormatter:s,labelDefaults:r,seriesType:n,dataLabel:A,isHeatChart:o,dataLabelFormatter:l}=a;A&&(e.chart&&t?.visible&&OB({label:A,chart:e.chart,seriesType:n}),MD({series:e,label:A,isHeatChart:o}),kc({...a,dataLabel:A,labelDefaults:r,defaultDataLabelFormatter:l,externalDataLabelFormatter:s}),RD({dataLabel:A,labelConfigColor:Ye(t?.content.color).color,seriesColor:e.get("fill"),backgroundColor:e.chart?.get("background")?.get("fill"),autoInverseDataLabelTextColor:i,isHeatChart:o}))}function KB(a){let{series:e,dataLabelsConfig:t}=a,i=t?.visible,s=e.bullets.hasIndex(1);i!==!0?s&&sp(e):(s||HD(a),OD(a))}function ND(a){let{dataLabel:e,series:t,externalDataLabelFormatter:i}=a;e.adapters.remove("text"),e.adapters.remove("html");let s=i!==void 0?"html":"text";sl({label:e,labelOutputProp:s}),e.adapters.add(s,(r,n)=>{let A=r??"",o=n.dataItem,l=Ge(t.uid,"heatChartDataLabelFormatter"),c=te(t.chart?.uid??NaN,"config");if(l!==void 0&&o){let h=o.get("value"),d=o.get("categoryX"),u=o.get("categoryY");h===null?A=c?.series[0].emptyCells?.text??$.heatChart.emptyCells?.text??"":h!==void 0&&(A=l(h,d,u))}return s==="html"?vs(A):A})}function VD(a){let{numberFormatter:e,dataLabelsConfigContent:t}=a;return i=>nr({textSymbol:{...t,text:e.format(i)},format:"amChartsV5"})}function $D(a){let{series:e,externalDataLabelFormatter:t}=a;e.bullets.push(()=>{let i=te(e.chart?.uid??Number.NaN,"config")?.series?.[0]?.dataLabels??a.dataLabelsConfig,s=ts.new(e.root,{sprite:Ze.new(e.root,{text:"{value}",populateText:!0,centerY:se,centerX:si,paddingBottom:0,paddingTop:0,paddingRight:0,paddingLeft:0,fill:Ye(i?.content.color).color,fontSize:i?.content.font?.size,oversizedBehavior:"hide"})}),r=s.get("sprite");if(r){let n=r;ND({dataLabel:n,series:e,externalDataLabelFormatter:t}),$B({...a,dataLabelsConfig:i,dataLabel:n,isHeatChart:!0,dataLabelFormatter:VD}),n.set("oversizedBehavior","hide"),n.set("maxWidth",void 0),n.set("maxHeight",void 0)}return s})}function KD(a){let{series:e,dataLabelsConfig:t}=a,i=t?.visible;e.bullets.hasIndex(0)&&sp(e,0),i===!0&&$D(a)}var Si={nameField:"name",fillField:"fill",strokeField:"stroke",fillOpacityField:"fillOpacity",strokeOpacityField:"strokeOpacity"};function rp(a,e){let t=al(a);a.columns.template.set("tooltip",t);let i=e!==void 0||Ge(a.uid,"hasExternalTooltipFormatter")===!0,s=i?"tooltipHTML":"tooltipText";zr({element:a.columns.template,labelOutputProp:s}),a.columns.template.setAll({tooltipPosition:$.columnTooltipPosition}),a.columns.template.adapters.remove("tooltipText"),a.columns.template.adapters.remove("tooltipHTML"),a.columns.template.adapters.add(s,(r,n)=>xr({element:n,series:a,isHTML:i})),a.columns.each(r=>{r.set("tooltip",t),zr({element:r,labelOutputProp:s}),r.adapters.remove("tooltipText"),r.adapters.remove("tooltipHTML"),r.adapters.add(s,(n,A)=>xr({element:A,series:a,isHTML:i}))})}function GB(a){let{axesConfig:e,currentSeries:t,tooltipValueFormat:i}=a,{root:s,chart:r}=t;if(r){let n=e?.[1]?.valueFormat,A=e?.[0].valueFormat,o=te(r.uid,"formatLocale");if(n?.type===P.NumberAxisFormat){let l=er({root:s,type:n.type,formatLocale:o,intlOptions:n.intlOptions});gi(t.uid,{tooltipValueYNumberFormatCallback:c=>l.format(c,i?.intlOptions??n.intlOptions)})}if(A?.type===P.NumberAxisFormat){let l=er({root:s,type:A.type,formatLocale:o,intlOptions:A.intlOptions});gi(t.uid,{tooltipValueXNumberFormatCallback:c=>l.format(c,i?.intlOptions??A.intlOptions)})}}}function GD(a){let{axes:e,seriesConfig:t,series:i,fieldList:s,utilsStrings:r}=a,{dataTooltipVisible:n}=t,A,o=te(i.chart?.uid??0,"rtl")??!1,l=na(o);return n===!1?A=(c,h,d)=>"":A=(c,h,d)=>{let u=or(s,t.x),g=Ch(u,e?.[0].title?.content?.text),y=Ch(r?.statistics.count??"",e?.[1]?.title?.content?.text??""),m=Ge(i.uid,"tooltipValueXNumberFormatCallback"),b=Ge(i.uid,"tooltipValueYNumberFormatCallback"),B=m?m(h):h,w=m?m(d):d,_=b?b(c):c;return`[bold]${g}${l} [/]${B} - ${w}
26
- [bold]${y}${l} [/]${_}`},A}function XD(a){let{seriesConfig:e,series:t,tooltip:i}=a,{dataTooltipVisible:s}=e;if(s!==!1){let r=Ge(t.uid,"histogramTooltipFormatter");if(r!==void 0){let n=i.dataItem;if(n!==void 0){let A=n.dataContext;return r(n.get("valueY")??0,A.minValue,A.maxValue)}}}return""}function ap(a,e){let t=al(a);a.columns.template.set("tooltip",t);let i=e!==void 0||Ge(a.uid,"hasExternalTooltipFormatter")===!0,s=i?"tooltipHTML":"tooltipText";zr({element:a.columns.template,labelOutputProp:s}),a.columns.template.setAll({tooltipPosition:$.columnTooltipPosition}),a.columns.template.adapters.remove("tooltipText"),a.columns.template.adapters.remove("tooltipHTML"),a.columns.template.adapters.add(s,(r,n)=>xr({element:n,series:a,isHTML:i})),a.columns.each(r=>{r.set("tooltip",t),r.set("tooltipPosition","pointer"),zr({element:r,labelOutputProp:s}),r.adapters.remove("tooltipText"),r.adapters.remove("tooltipHTML"),r.adapters.add(s,(n,A)=>xr({element:A,series:a,isHTML:i}))})}function WD(a){let{series:e,tooltipFormatter:t,axesConfig:i,seriesConfig:s}=a,r=Ge(e.uid,"hasExternalTooltipFormatter")===!0,n=t!==void 0;GB({axesConfig:i,currentSeries:e,tooltipValueFormat:s.dataTooltipValueFormat}),gi(e.uid,{histogramTooltipFormatter:t??GD(a),hasExternalTooltipFormatter:n}),r!==n&&ap(e,t)}function np(a){let{pieChart:e,valueIntlOptions:t,percentageIntlOptions:i,displayNumericValue:s,displayPercentage:r,valuePrefix:n,valueSuffix:A,percentagePrefix:o,percentageSuffix:l}=a,{root:c}=e,h=te(e.uid,"formatLocale"),d=er({root:c,type:P.NumberAxisFormat,intlOptions:t,formatLocale:h}),u=er({root:c,type:P.NumberAxisFormat,intlOptions:{...i,style:"percent"},formatLocale:h}),g=na(te(e.uid,"rtl")??!1," ");return(y,m,b)=>{let B="";if(m!==void 0&&b!==void 0){let w=`${n??""}${d.format(m)}${A??""}`,_=`${o??""}${u.format(Math.abs(b/100))}${l??""}`;Number.isFinite(m)?s===!0&&r===!0?B=`${_}${g}(${w})`:s===!0?B=w:r===!0&&(B=_):B=""}return B}}function zD(a,e){let t=(g,y,m)=>"",{numericValueFormat:i,percentValueFormat:s,dataTooltipValueFormat:r,dataTooltipPercentFormat:n,displayCategoryOnTooltip:A,displayNumericValueOnTooltip:o,displayPercentageOnTooltip:l,valuePrefix:c,valueSuffix:h,percentagePrefix:d,percentageSuffix:u}=e;return t=(g,y,m)=>{let b="",{chart:B}=a;if(B){let w=np({pieChart:B,valueIntlOptions:(r??i)?.intlOptions,percentageIntlOptions:(n??s)?.intlOptions,displayNumericValue:o??$.pieChart.displayNumericValueOnTooltip,displayPercentage:l??$.pieChart.displayPercentageOnTooltip,valuePrefix:c,valueSuffix:h,percentagePrefix:d,percentageSuffix:u})("",y,m),_=!ii(g)&&(A??$.pieChart.displayCategoryOnTooltip);if(_&&(b=`[bold]${g}[/]`),!ii(w)){let T=qd(w);b=_?`${b}
27
- ${T}`:T}}return b},t}function YD(a){let e=a.get("tooltip");if(e!==void 0){let t=a.get("fill");t instanceof ya&&(t=t.get("fill")),e.get("background")?.set("fill",t)}}function jD(a){let{pieSeries:e,tooltip:t}=a,i="",{chart:s}=e;if(s!==void 0&&t!==void 0){let r=te(s.uid,"config"),{dataTooltipVisible:n}=r?.series[0]??{};if(n!==!1){let A=Ge(e.uid,"pieChartTooltipFormatter");if(A){let o=t.dataItem;if(o!==void 0){let l=o,c=l.get("category")??"",h=o.dataContext,d=vA(h);d===void 0&&(d=c);let u=l.get("value"),g=l.get("valuePercentTotal");typeof u=="number"&&u!==0&&r?.series?.[0]?.dataTooltipVisible!==!1?(t.set("disabled",!1),YD(l.get("slice")),i=A(c,u,g,d)):t.set("disabled",!0)}}}else return}return i}function Ap(a,e){let t=a.slices.template,i=al(a),s=e!==void 0||Ge(a.uid,"hasExternalTooltipFormatter")===!0,r=s?"tooltipHTML":"tooltipText";zr({element:t,labelOutputProp:r}),t.setAll({tooltip:i,tooltipPosition:$.sliceTooltipPosition}),t.adapters.remove("tooltipText"),t.adapters.remove("tooltipHTML"),t.adapters.add(r,(n,A)=>{let o=" ";try{let l=A.get("tooltip");l&&(l.dataItem=A.dataItem,o=xr({element:l,series:a,isHTML:s}))}catch{}return o}),t.set(r," "),a.slices.each(n=>{n.set("tooltip",i),n.set("tooltipPosition","fixed"),zr({element:n,labelOutputProp:r}),n.adapters.remove("tooltipText"),n.adapters.remove("tooltipHTML"),n.adapters.add(r,(A,o)=>{let l=" ";try{let c=o.get("tooltip");c&&(c.dataItem=o.dataItem,l=xr({element:c,series:a,isHTML:s}))}catch{}return l})})}function ZD(a){let{series:e,seriesConfig:t,tooltipFormatter:i}=a,s=Ge(e.uid,"hasExternalTooltipFormatter")===!0,r=i!==void 0;gi(e.uid,{pieChartTooltipFormatter:i??zD(e,t),hasExternalTooltipFormatter:r}),s!==r&&Ap(e,i)}function qD(a){let{axesConfig:e,seriesConfig:t,series:i,fieldList:s}=a,{dataTooltipVisible:r}=t,n,{chart:A}=i,o=A?.uid!==void 0?te(A.uid,"rtl"):!1,l=na(o??!1);return r===!1?n=(c,h,d,u)=>"":n=(c,h,d,u)=>{let g=or(s,t.x),y=ii(e?.[0].title?.content?.text)?g:e?.[0].title?.content?.text,m=or(s,t.y),b=ii(e?.[1]?.title?.content?.text)?m:e?.[1]?.title?.content?.text,B=Ge(i.uid,"tooltipValueXNumberFormatCallback"),w=B?B(c):c,_=Ge(i.uid,"tooltipValueYNumberFormatCallback"),T=_?_(h):h,Q=`[bold]${y}${l} [/]${w}
28
- [bold]${b}${l} [/]${T}`;if(d!==void 0&&t.sizePolicy?.field!==void 0){let U=or(s,t.sizePolicy?.field),E=_?_(d):d;Q+=`
29
- [bold]${U}${l} [/]${E}`}return t.additionalTooltipFields?.forEach(U=>{let E=or(s,U),O=s?.find(F=>F.name===U),D=u?.[U],k="";if(D!=null&&D!==void 0&&O)if(L0(O)&&typeof D=="number")k=String(_?_(D):D);else if(U0(O)){let F=new Date(D),M=A?te(A.uid,"formatLocale"):void 0;k=new Intl.DateTimeFormat(M,{}).format(F)}else O.type===Md.String&&typeof D=="string"&&(k=D);Q+=o?`
30
- ${k}[bold]${E}${l} [/]`:`
31
- [bold]${E}${l} [/]${k}`}),Q},n}function JD(a){let{seriesConfig:e,markerSeries:t,tooltip:i}=a,{x:s,y:r,sizePolicy:n,dataTooltipVisible:A}=e,{field:o}=n??{};if(A!==!1){let l=Ge(t.uid,"scatterplotTooltipFormatter");if(!i.isHidden()&&l){let{dataItem:c}=i;if(c){let h=c.dataContext;if(h){let d=s in h&&typeof h[s]=="number"?Number(h[s]):Number.NaN,u=r in h&&typeof h[r]=="number"?Number(h[r]):Number.NaN,g=o&&o in h&&typeof h[o]=="number"?Number(h[o]):void 0;return l(d,u,g,h)}}}}}function eL(a){let{axesConfig:e,series:t,seriesConfig:i,tooltipFormatter:s}=a;GB({axesConfig:e,currentSeries:t,tooltipValueFormat:i.dataTooltipValueFormat}),gi(t.uid,{scatterplotTooltipFormatter:s??qD(a),hasExternalTooltipFormatter:s!==void 0});let r=Ge(t.uid,"bulletTemplate");r&&RA({series:t,element:r,tooltipFormatter:s})}function Eb(a,e){if(e!==void 0){let t=FB(e);t!==void 0&&a.label.setAll({fill:fo({r:t.r,g:t.g,b:t.b,a:1})?$i("#000000"):$i("#ffffff")})}}function XB(a){a.label.setAll({paddingTop:4,paddingBottom:4})}function WB(a,e){let{dataTooltipStyleReversed:t,dataTooltipStyle:i}=$;if(e===!0){let s=a.get("background")?.get("fill");if(s!==void 0)if(Eb(a,a.get("background")?.get("fill")?.toCSS()),t?.color!==void 0&&s.toCSSHex()!==Ye(t.color).color.toCSSHex()){a.get("background")?.setAll({fill:Ye(t.color).color,stroke:s,strokeWidth:t.outline?.width??Number.NaN});let r=a.get("background");if(r instanceof Le&&r.parent instanceof ai){let n=r.parent.get("tooltipTarget");r.set("strokeOpacity",n instanceof Le?n.get("fillOpacity"):void 0)}a.get("background")?.adapters.enable("fillOpacity")}else s.toCSSHex()===Ye(t?.color).color.toCSSHex()&&a.get("background")?.adapters.disable("fillOpacity")}else Eb(a,a.get("background")?.get("fill")?.toCSS()),a.setAll({getStrokeFromSprite:!0,getFillFromSprite:!0}),a.get("background")?.adapters.enable("fillOpacity"),a.get("background")?.setAll({strokeWidth:i?.outline?.width??Number.NaN,stroke:Ye(i?.outline?.color).color})}function tL(a){a.get("background")?.adapters.add("fillOpacity",(e,t)=>{let i=e;if(t.parent instanceof ai){let s=t.parent.get("tooltipTarget");i=s instanceof Le?s.get("fillOpacity"):i}return i})}function al(a){let{root:e,chart:t}=a,i=ai.new(e,{});return i.label.setAll({oversizedBehavior:"wrap",maxWidth:$.tooltipWidth}),i.adapters.add("visible",(s,r)=>(s&&sL(r,a),s)),tL(i),iL(i,t),i}function RA(a){let{series:e,element:t,tooltipFormatter:i}=a,s,r=al(e);t&&t.get("tooltip")===void 0?(s=t,t.setAll({tooltip:r,tooltipPosition:$.markerTooltipPosition})):s=r;let n=i!==void 0||Ge(e.uid,"hasExternalTooltipFormatter")===!0,A=n?"tooltipHTML":"tooltipText";zr({element:s,labelOutputProp:A}),s instanceof ai?(s.adapters.remove("tooltipText"),s.adapters.remove("tooltipHTML"),s.adapters.add(A,(l,c)=>xr({element:c,series:e,isHTML:n}))):s instanceof Ne&&(s.adapters.remove("tooltipText"),s.adapters.remove("tooltipHTML"),s.adapters.add(A,(l,c)=>xr({element:c,series:e,isHTML:n})));let o=l=>{l.set("tooltip",r),l.set("tooltipPosition","fixed"),zr({element:l,labelOutputProp:A}),l.adapters.remove("tooltipText"),l.adapters.remove("tooltipHTML"),l.adapters.add(A,(c,h)=>xr({element:h,series:e,isHTML:n}))};return e.bulletsContainer.children.each(l=>{l instanceof hi&&o(l)}),r}function zr(a){let{element:e,labelOutputProp:t}=a,i=t==="tooltipHTML";if(e instanceof ai)i?(e.label.set("html",$.htmlEmptyContent),e.label.set("text","")):e.label.set("html",void 0);else if(e instanceof hi){let s=e.get("tooltip");s&&(i?(s.label.set("html",$.htmlEmptyContent),s.label.set("text","")):s.label.set("html",void 0)),e.set("tooltipText",i?void 0:$.htmlEmptyContent),e.set("tooltipHTML",i?$.htmlEmptyContent:void 0)}else e instanceof Ne&&(e.set("tooltipText",i?void 0:$.htmlEmptyContent),e.set("tooltipHTML",i?$.htmlEmptyContent:void 0))}function iL(a,e){if(a){let t=te(e?.uid??0,"rtl");a.label.set("direction",t?"rtl":"ltr"),XB(a)}}function sL(a,e){let{chart:t}=e;if(t&&a){let i=te(t.uid,"config");if(i){let{seriesConfig:s}=Hc(e,i);if(s){let{dataTooltipReverseColor:r}=s;WB(a,r)}}}}function rL(a){let{seriesConfig:e,series:t,tooltip:i,isRotated:s}=a,r=Ge(t.uid,"barAndLineTooltipFormatter");if(r!==void 0){let n=i.dataItem;if(n!==void 0){let A=n.get("valueX"),o=n.get("valueY"),l=n.get("valueXTotalPercent"),c=n.get("valueYTotalPercent"),h=s?A:o,d;s&&typeof l=="number"?d=l:!s&&typeof c=="number"&&(d=c),d&&(d/=100);let u=n.dataContext??{},g=te(t.chart?.uid??0,"config"),y=te(t.chart?.uid??0,"rendererFieldNames"),m=ru({value:u[e.x],dataContext:u,useRendererLabel:su(g,y),specificField:lu(bt([e]),e)}),b=vA(u);b===void 0&&(b=m);let B=u[$.dateBinningRange];if(b!==void 0||h!==void 0||d!==void 0||B!==void 0)return r({seriesName:t.get("name")??e.name,xValue:m,originalXValue:b,dateBinningRange:B,statValue:h,percentValue:d})}}}function Pb(a,e){if(a instanceof ai)a.set("forceHidden",e);else{let t=a.get("tooltip");t&&t.set("forceHidden",e)}}function xr(a){let{element:e,series:t,isHTML:i}=a,s,{chart:r}=t;if(r!==void 0){let A=te(r.uid,"config"),{seriesConfig:o}=Hc(t,A),{dataTooltipVisible:l}=A?.series[0]??{};if(l===!1||!o)s="",Pb(e,!0);else switch(Pb(e,!1),o.type){case P.ScatterSeries:t instanceof qe&&(s=JD({seriesConfig:o,markerSeries:t,tooltip:e}));break;case P.BarSeries:case P.LineSeries:case P.RadarSeries:s=rL({seriesConfig:o,series:t,tooltip:e,isRotated:A?.rotated??!1});break;case P.HistogramSeries:s=XD({seriesConfig:o,series:t,tooltip:e});break;case P.HeatSeries:s=cL({heatSeries:t,tooltip:e});break;case P.PieSeries:t instanceof ni&&e instanceof ai&&(s=jD({pieSeries:t,tooltip:e}));break}}let n=s??"";if(i){let A=vs(n),o=e instanceof ai?e:e.get("tooltip");return o&&o.label.setAll({html:A,text:""}),A}return n}function aL(a){let{series:e,dateRange:t,xAxisValueFormat:i}=a,s,r=te(e.chart?.uid??Number.NaN,"timeIntervalInfo");if(t!==void 0&&t.length>0){let n={};switch(r?.unit){case ns.Second:n={month:"numeric",day:"numeric",year:"numeric",hour:"numeric",minute:"numeric",second:"numeric"};break;case ns.Minute:n={month:"numeric",day:"numeric",year:"numeric",hour:"numeric",minute:"numeric"};break;case ns.Hour:n={month:"numeric",day:"numeric",year:"numeric",hour:"numeric",minute:"numeric"};break;case ns.Day:case ns.Week:case ns.Month:case ns.Year:n={month:"numeric",day:"numeric",year:"numeric"};break}n.timeZone=i.intlOptions.timeZone;let A=new Date(t[0]),o=new Date(t[1]),{root:l}=e;if(!Number.isNaN(A.valueOf())&&e.chart!==void 0){let c=te(e.chart.uid,"formatLocale"),h=er({root:l,type:P.DateAxisFormat,formatLocale:c,intlOptions:n}),d=h.format(A,n);if(s=d,!Number.isNaN(o.valueOf())){let u=h.format(o,n);u!==d&&(s=`${s} - ${u}`)}}}return s?.toString()??""}function nL(a){let{seriesConfig:e,xAxisValueFormat:t,setTimeBinningInfoWhenNotProvided:i,dataTooltipValueFormat:s,dataTooltipDateFormat:r,series:n,xValue:A,dateBinningRange:o,isTimeOnlyField:l,queryObject:c}=a,{root:h}=n,d,u=te(n.chart?.uid??0,"formatLocale");return po({seriesConfig:e,xAxisValueFormatType:t?.type,setTimeBinningInfoWhenNotProvided:i,queryObject:c})&&o!==void 0&&t?.type===P.DateAxisFormat?d=aL({series:n,dateRange:o,xAxisValueFormat:t}):gA(t)?l&&typeof A=="number"?d=new Date(A).toLocaleTimeString(u):A instanceof Date&&(d=MA({root:h,value:A,valueFormat:r??t,formatLocale:u})):typeof A=="number"&&Ea(t)?d=MA({root:h,value:A,valueFormat:s??t,formatLocale:u}):d=A,d?.toString()??""}function AL(a){let{isStacked100:e,series:t,statValue:i,percentValue:s,yAxisValueFormat:r,dataTooltipValueFormat:n,dataTooltipPercentFormat:A}=a,o=t.chart?.uid??0,{root:l}=t,c=n;c===void 0&&(Ea(r)&&r?(c=r,e&&(c.intlOptions.style="decimal")):c=Vy());let h=te(o,"formatLocale"),d=i!==void 0?MA({root:l,value:i,valueFormat:c,formatLocale:h}):"",u="";if(e&&s!==void 0&&l!==void 0){let g=A;g===void 0&&(g=$y(),g.intlOptions.minimumFractionDigits=2,g.intlOptions.maximumFractionDigits=2),u=MA({root:l,value:s,valueFormat:g,formatLocale:h})}return{formattedStatValue:d,formattedPercentValue:u}}function oL(a){let{utilsStrings:e,fieldList:t,queryObject:i,series:s,seriesConfig:r,seriesIndex:n,setTimeBinningInfoWhenNotProvided:A}=a,{chart:o}=s,{dataTooltipDateFormat:l,dataTooltipPercentFormat:c,dataTooltipValueFormat:h}=r,d=()=>"";if(o!==void 0){let u=te(o.uid,"config");if(u!==void 0){let{dataTooltipVisible:g}=r,y=s instanceof qe?r.markerVisible:void 0;if(g!==!1&&y!==!1){let m=u.axes,b=m[0].valueFormat,B=m[1].valueFormat,w=t?.find(M=>M.name===r.x)?.type===Md.TimeOnly,_=bt(u.series),T=Pa(u)===Hi.Stacked100,Q=Ji(i),U=BA(Q).idField,E=or(t,r.x),O=Ch(E,m[0].title?.content.text),D=Vv({config:u,fieldList:t,objectIdField:U,seriesIndex:n,utilsStrings:e,isStacked100:T}),k=te(o.uid,"rtl"),F=na(k??!1);d=M=>{let{seriesName:Y,statValue:z,percentValue:re,xValue:q,dateBinningRange:Ae}=M,X=nL({seriesConfig:r,xAxisValueFormat:b,dataTooltipValueFormat:h,dataTooltipDateFormat:l,setTimeBinningInfoWhenNotProvided:A,series:s,xValue:q,dateBinningRange:Ae,isTimeOnlyField:w,queryObject:i}),{formattedStatValue:G,formattedPercentValue:ue}=AL({isStacked100:T,yAxisValueFormat:B,dataTooltipValueFormat:h,dataTooltipPercentFormat:c,series:s,statValue:z,percentValue:re}),he=[`[bold]${O}${F} [/]${X}`];switch(_){case $e.BarAndLineFromFields:{he.pop();let ae=Nu({config:u,fieldName:or(t,X??""),utilsStrings:e});he.push(`[bold]${ae}${F} [/]${G}`);break}case $e.BarAndLineMonoField:case $e.BarAndLineNoAggregation:case $e.BarAndLineMultiFields:he.push(`[bold]${D}${F} [/]${G}`);break;case $e.BarAndLineSplitByNoAggregation:case $e.BarAndLineSplitBy:{let ae=wA(r.query?.where,!1),Ie=A0({value:or(t,ae)});he.push(`[bold]${Ie}${F} [/]${Y}
32
- [bold]${D}${F} [/]${G}`)}break}return T&&he.push(`[bold]${e.statistics.percent}${F} [/]${ue}`),he.join(`
33
- `)}}}}return d}function op(a){let{series:e,tooltipFormatter:t,seriesConfig:i}=a,s=Ge(e.uid,"hasExternalTooltipFormatter")===!0,r=t!==void 0;if(gi(e.uid,{barAndLineTooltipFormatter:t??oL(a),hasExternalTooltipFormatter:r}),s!==r)switch(i.type){case P.BarSeries:{e instanceof mt&&rp(e,t);break}case P.LineSeries:case P.RadarSeries:{if(e instanceof qe){let n=Ge(e.uid,"bulletTemplate");n&&RA({series:e,element:n,tooltipFormatter:t})}break}}}function lL(a){let{chartType:e,series:t,tooltipFormatter:i}=a;switch(!0){case(e===P.HistogramSeries&&t instanceof mt):{ap(t,i);break}case(e===P.PieSeries&&t instanceof ni):{let s=Ge(t.uid,"tooltipCallback");s&&s.dispose();let r=t.events.on(ot.DataValidated,()=>{Ap(t,i)});gi(t.uid,{tooltipCallback:r});break}case(e===P.HeatSeries&&t instanceof mt):{lp(t,i);break}case((e===P.ComboLineAndBarSeries||e===P.BarSeries)&&t instanceof mt):{rp(t,i);break}case(t instanceof qe&&(e===P.ComboLineAndBarSeries||e===P.LineSeries||e===P.RadarSeries||e===P.ScatterSeries)):{let s=Ge(t.uid,"bulletTemplate");s&&RA({series:t,element:s,tooltipFormatter:i});break}}}function Mb(a){let{value:e,formatLocale:t,unit:i,config:s,utilsStrings:r}=a,n={label:"",value:e.toString()};switch(i){case Ns.DayOfWeek:n={label:r.heatChartCalendarDatePartsUnits.dayOfWeek,value:kB({weekdayNumber:e,firstDayOfWeek:"firstDayOfWeek"in s?s.firstDayOfWeek:$.heatChartFirstDayOfWeek,locale:t})};break;case Ns.MonthOfYear:n={label:r.heatChartCalendarDatePartsUnits.monthOfYear,value:EB({monthNumber:e,locale:t})};break;case Ns.HourOfDay:n={label:r.heatChartCalendarDatePartsUnits.hourOfDay,value:QB({hour:e,format:{hour:"numeric",hour12:!1},locale:t})};break;case Ns.DayOfMonth:n={label:r.heatChartCalendarDatePartsUnits.dayOfMonth,value:typeof e=="string"?e:e?.toString()??""};break;case Ns.DayOfYear:n={label:r.heatChartCalendarDatePartsUnits.dayOfYear,value:typeof e=="string"?e:e?.toString()??""};break;case Ns.MinuteOfDay:n={label:r.heatChartCalendarDatePartsUnits.minuteOfDay,value:typeof e=="string"?e:e?.toString()??""};break;case Ns.WeekOfYear:n={label:r.heatChartCalendarDatePartsUnits.weekOfYear,value:typeof e=="string"?e:e?.toString()??""};break;case Ns.QuarterOfYear:n={label:r.heatChartCalendarDatePartsUnits.quarterOfYear,value:typeof e=="string"?e:e?.toString()??""};break}return n}function hL(a){let{columnSeries:e,seriesConfig:t,utilsStrings:i,fieldList:s,queryObject:r}=a;return(n,A,o)=>{let l="",c=n,h=te(e.chart?.uid??0,"rtl"),d=te(e.chart?.uid??0,"config");if(Aa(d)){c!==null?e.chart&&(c=er({root:e.chart.root,type:"number",intlOptions:{}}).format(n)):c=d.series[0].emptyCells?.text??$.heatChart.emptyCells?.text??"";let u=na(h??!1),g=t.query?.outStatistics?.[0].onStatisticField,y=Ji(r),m=i.statistics.count;g!==BA(y).idField&&(m=Nu({config:d,fieldName:or(s,t.query?.outStatistics?.[0].onStatisticField??""),utilsStrings:i}));let b=te(e.chart?.uid??0,"formatLocale"),B={label:t.x,value:A},w={label:t.y,value:o};if(t.xTemporalBinning!==void 0){let{label:_,value:T}=Mb({value:Number(A),config:d,formatLocale:b,unit:t.xTemporalBinning.unit,utilsStrings:i});!ii(_)&&!ii(T)&&(B={label:_,value:T})}if(t.yTemporalBinning!==void 0){let{label:_,value:T}=Mb({value:Number(o),config:d,formatLocale:b,unit:t.yTemporalBinning.unit,utilsStrings:i});!ii(_)&&!ii(T)&&(w={label:_,value:T})}ii(l)&&(l=`[bold]${B.label}${u} [/]${B.value}
34
- [bold]${w.label}${u} [/]${w.value}
35
- [bold]${m}${u}[/] ${c} [/]]`)}return l}}function cL(a){let{heatSeries:e,tooltip:t}=a,i="",{chart:s}=e;if(s!==void 0&&t!==void 0){let r=te(s.uid,"config"),{dataTooltipVisible:n}=r?.series[0]??{};if(n!==!1){let A=Ge(e.uid,"heatChartTooltipFormatter");if(A){let o=t.dataItem;if(o!==void 0){let l=o.dataContext;if(r?.series?.[0]?.dataTooltipVisible!==!1){let c=l?.[qt.valueField]??null,h=l?.[qt.xField],d=l?.[qt.yField];i=A(c,h,d)}}}}else return}return vs(i)}function lp(a,e){let t=al(a);a.columns.template.set("tooltip",t);let i=e!==void 0||Ge(a.uid,"hasExternalTooltipFormatter")===!0,s=i?"tooltipHTML":"tooltipText";zr({element:a.columns.template,labelOutputProp:s}),a.columns.template.setAll({tooltipPosition:$.columnTooltipPosition}),a.columns.template.adapters.remove("tooltipText"),a.columns.template.adapters.remove("tooltipHTML"),a.columns.template.adapters.add(s,(r,n)=>xr({element:n,series:a,isHTML:i})),a.columns.each(r=>{r.set("tooltip",t),r.set("tooltipPosition","pointer"),zr({element:r,labelOutputProp:s}),r.adapters.remove("tooltipText"),r.adapters.remove("tooltipHTML"),r.adapters.add(s,(n,A)=>xr({element:A,series:a,isHTML:i}))})}function dL(a){let{series:e,seriesConfig:t,utilsStrings:i,fieldList:s,options:r,queryObject:n}=a,A=Ge(e.uid,"hasExternalTooltipFormatter")===!0,o=r?.tooltipFormatter!==void 0;gi(e.uid,{heatChartTooltipFormatter:r?.tooltipFormatter??hL({columnSeries:e,seriesConfig:t,utilsStrings:i,fieldList:s,queryObject:n}),hasExternalTooltipFormatter:o}),A!==o&&lp(e,r?.tooltipFormatter)}function Sc(a){let e={type:ht.SLS,color:[0,0,0,0],width:0},t=a?.color?a:e,i=a?.color?Ye(a.color).color:void 0,s=a?.color?Ye(a.color).opacity:void 0;return{outlineSymbol:t,outlineColor:i,outlineOpacity:s}}function uL(a){let{root:e,xAxis:t,yAxis:i,options:s,chartConfig:r,queryObject:n}=a,A=mt.new(e,{calculateAggregates:!0,stroke:Ye($.backgroundColor).color,clustered:!1,xAxis:t,yAxis:i,categoryXField:qt.xField,categoryYField:qt.yField,valueField:qt.valueField});return A.columns.template.setAll({tooltipText:`x: {${qt.xField}}
36
- y: {${qt.yField}}
37
- Value: {${qt.valueField}}`,width:se,height:se}),lp(A,s?.tooltipFormatter),VA(A,r),pi(A.columns.template,s?.selectionTheme),Br({element:A.columns.template,series:A,queryObject:n}),A}function fL(a){let{columnSeries:e,data:t,loaderHandle:i}=a;t?.dataItems&&(e.events.once(ot.DataValidated,()=>{i.hideLoader()}),e.data.setAll(t.dataItems))}function gL(a){let{columnSeries:e,seriesConfig:t}=a,{gradientHeatRules:i}=$.heatChart,{gradientRules:s,heatRulesType:r,gridLine:n}=t,A=t.emptyCells?.symbol??$.heatChart.emptyCells?.symbol,o=s?.colorList?.[0]??i.minColor,l=s?.colorList?.[1]??i.maxColor,c=s?.outsideRangeLowerColor??i.outsideRangeLowerColor,h=s?.outsideRangeUpperColor??i.outsideRangeUpperColor,{minValue:d,maxValue:u}=s??{},{color:g,opacity:y}=Ye(o),{color:m,opacity:b}=Ye(l),B=Ye(c),w=Ye(h);e.set("heatRules",[{target:e.columns.template,dataField:"value",key:"fill",customFunction:(_,T,Q,U)=>{let E=_.dataItem?.dataContext;if(_ instanceof Le){let O,D,k,F=!1;if(r===bn.Renderer){let M=E?.[Ht.rendererSymbolField];if(fh(M)){k=oi(M);let{outlineSymbol:Y}=Sc(n);k.outline=Y}else F=!0}if((!Number.isFinite(U)||F)&&A){k=oi(A);let{outlineSymbol:M}=Sc(n);k.outline=M}if(k){let M=cn({root:e.root,element:_,fillSymbol:k});kA(_,M)}else typeof d=="number"&&U<d?{color:O,opacity:D}=B:typeof u=="number"&&U>u?{color:O,opacity:D}=w:T===Q?(O=g,D=y):(O=we.interpolate((U-T)/(Q-T),g,m,"rgb"),D=y+(U-T)/(Q-T)*(b-y)),O&&_.set("fill",O),D!==void 0&&_.set("fillOpacity",D)}}}])}function pL(a,e){e?.color?vr({element:a.columns.template,lineSymbol:e}):a.columns.template.setAll({strokeOpacity:0,strokeWidth:0})}function mL(a){let{series:e,data:t,loaderHandle:i,dataWasUpdated:s,sortChanged:r,timeZoneChanged:n,seriesWereReinitialized:A,seriesConfig:o,autoInverseDataLabelTextColor:l,options:c,queryObject:h,chartConfig:d}=a,u=s===!0||r===!0||n||A===!0;e.set("id",o.id),pi(e.columns.template,c?.selectionTheme),dn(e.columns.template,t?.dataItems?.length),dL(a),pL(e,o.gridLine),gL({columnSeries:e,seriesConfig:o}),u&&fL({columnSeries:e,data:t,loaderHandle:i}),KD({seriesType:P.HeatSeries,series:e,seriesConfig:o,dataLabelsConfig:o.dataLabels,yAxisValueFormat:{intlOptions:{},type:"number"},autoInverseDataLabelTextColor:l,externalDataLabelFormatter:c?.dataLabelFormatter});let{chart:g}=e;g&&yL({seriesConfig:o,queryObject:h,chartConfig:d,chart:g})}function yL(a){let{seriesConfig:e,queryObject:t,chartConfig:i,chart:s}=a,r;if(e.heatRulesType===bn.Renderer)r={heatRulesType:bn.Renderer,seriesColors:YB({queryObject:t,chartConfig:i,forLegend:!1})};else{let{gradientHeatRules:n}=$.heatChart,{gradientRules:A}=e;r={heatRulesType:bn.Gradient,seriesColors:{startColor:A?.colorList?.[0]??n.minColor,endColor:A?.colorList?.[1]??n.maxColor}}}lr({chartId:s.get("id"),data:r,colorMatchApplied:!1,htmlContainer:s.root.dom})}function zB(a,e){let t="",i,s,r;return a&&typeof a=="object"&&(t="label"in a&&typeof a.label=="string"?a.label:"",i="symbol"in a&&a.symbol&&typeof a.symbol=="object"&&"color"in a.symbol&&Array.isArray(a.symbol.color)?a.symbol.color:void 0,r="symbol"in a&&a.symbol&&typeof a.symbol=="object"&&"outline"in a.symbol&&Array.isArray(a.symbol.outline)?a.symbol.outline:void 0,e&&(Array.isArray(i)&&({color:i,opacity:s}=Ye(i)),Array.isArray(r)&&(r=Ye(r).color))),{legendItemLabel:t,legendItemColor:i,legendItemColorOpacity:s,legendItemStrokeColor:r}}function vL(a){let e,{outlineColor:t,outlineOpacity:i,dataItems:s,valueField:r,classBreakInfo:n,classBreakIndex:A,numberOfClassBreaks:o,evaluateUpTo:l}=a,{legendItemLabel:c,legendItemColor:h,legendItemColorOpacity:d}=zB(n,!0);if(n&&typeof n=="object"&&h&&!Array.isArray(h)){let u=!0;if(s&&r){let g="classMinValue"in n&&typeof n.classMinValue=="number"?n.classMinValue:-1/0,y="classMaxValue"in n&&typeof n.classMaxValue=="number"?n.classMaxValue:1/0,m=A===o-1;u=s.some(b=>{let B=b[r];return m||l?typeof B=="number"&&B>=g&&B<=y:typeof B=="number"&&B>=g&&B<y})}u&&(e={[Si.nameField]:c,[Si.fillField]:h,[Si.strokeField]:t,[Si.fillOpacityField]:d,[Si.strokeOpacityField]:i})}return e}function xL(a){let e,{legendItemLabel:t,legendItemColor:i,legendItemStrokeColor:s}=zB(a,!1);return Array.isArray(i)&&(!s||Array.isArray(s))&&(e={label:t,symbol:{type:ht.SFS,style:Ir.Solid,color:i,outline:{type:ht.SLS,color:s??i}}}),e}function YB(a){let{queryObject:e,chartConfig:t,forLegend:i,series:s}=a,r,n=Ji(e),A=t.series?.[0],o=t.chartRenderer??n?.renderer?.toJSON(),{outlineColor:l,outlineOpacity:c}=Sc(A?.gridLine);if((o?.type==="classBreaks"||o?.type==="class-breaks")&&"classBreakInfos"in o){let h=s?.data.values,d=s?.get("valueField")??qt.valueField,u=o.classBreakInfos?.[0],g=u?u.classMinValue===u.classMaxValue:!1;r=o.classBreakInfos.map((y,m)=>{let b;return i?b=vL({outlineColor:l,outlineOpacity:c,dataItems:h,valueField:d,classBreakInfo:y,classBreakIndex:m,numberOfClassBreaks:o.classBreakInfos.length,evaluateUpTo:g}):b=xL(y),b}).filter(Boolean)}return r}var Ec="arcgis_charts_title_container",hp="arcgis_charts_subtitle_container",Pc="arcgis_charts_footer_container",jB="arcgis_charts_title",ZB="arcgis_charts_subtitle",qB="arcgis_charts_footer",as="arcgis_charts_legend_container",tr="arcgis_charts_legend_title",Hg="arcgis_charts_axis_title_id";function bL(a){let e=a.yAxes.getIndex(0);if(e){let t=yt({childId:`${Hg}_y_${e.uid}`,parent:e});t instanceof Ze&&t.set("dx",0)}}function BL(a,e){let t=$.axisLabelSpacing.verticalAxisLabelSidePadding,i=$.heatChart.legend.legendPadding+t;e.set("marginRight",i),a.leftAxesContainer.setAll({paddingLeft:t});let s=a.leftAxesContainer.children.values[0];s instanceof Gt&&s.set("paddingLeft",t)}function JB(a,e){let{root:t}=a,i=te(a.uid,"rtl")??!1,s=te(a.uid,"config")??e,r=s?.series[0],{start:n,end:A}=Mc(i,r),o=s?.legend?.position??$.heatChart.legend.position,l=o===je.Top||o===je.Bottom;return ur.new(t,{orientation:l?"horizontal":"vertical",startColor:n.color,endColor:A.color,visible:s?.legend?.visible,startOpacity:n.opacity,endOpacity:A.opacity})}function wL(a,e){let t=te(e.uid,"rtl")??!1,i=te(e.uid,"config");if(i?.series[0].type===P.HeatSeries){let s=i?.series[0],{start:r,end:n}=Mc(t,s);a.setAll({startColor:r.color,endColor:n.color,startOpacity:r.opacity,endOpacity:n.opacity})}}function Mc(a=!1,e){let t=$.heatChart.gradientHeatRules,i=e.gradientRules?.colorList??[...a?[t.maxColor,t.minColor]:[t.minColor,t.maxColor]],{color:s,opacity:r}=Ye(i[0]),{color:n,opacity:A}=Ye(i[1]);return{start:{color:s,opacity:r},end:{color:n,opacity:A}}}function Hb(a,e){let t=te(a.uid,"rtl")??!1,i=te(a.uid,"config")?.series[0],{start:s,end:r}=Mc(t,i);e.setAll({startColor:s.color,endColor:r.color})}function ew(a){let e=te(a.uid,"config");if(e?.series?.[0]?.type===P.HeatSeries&&e?.legend?.visible!==!1){let t=$.heatChart.legend,i=e?.legend?.position??t.position,s=Qi(as,a.uid),r,n=!1;switch(i){case je.Top:r=a.topAxesContainer,n=!0;break;case je.Bottom:r=a.bottomAxesContainer,n=!1;break;case je.Left:r=a.leftAxesContainer,n=!0;break;case je.Right:r=a.rightAxesContainer,n=!1;break;default:r=void 0}if(r!==void 0){let A=yt({childId:s,parent:r,useChildId:!0});if(A!==void 0){let{children:o}=r,l=o.indexOf(A);l!==-1&&(n&&l!==0?(o.removeValue(A),o.unshift(A),r.markDirty()):!n&&l!==o.length-1&&(o.removeValue(A),o.push(A),r.markDirty()))}}}}function tw(a){let{chart:e,legend:t,legendContainer:i}=a,{root:s}=e,r=te(e.uid,"config"),n=$.heatChart.legend,A=r?.legend?.position??n.position,o,l,c,h=A===je.Left||A===je.Top,d=yt({childId:tr,parent:i}),u=r?.legend?r.legend.visible??!0:!1,g=r?.legend?.title?r.legend.title.visible??!0:!1,y=d instanceof Ze&&u&&g?d.height()>0?d.height():n.titleHeight:0,m=A===je.Left||A===je.Right;switch(t.setAll({orientation:m?"vertical":"horizontal",width:se}),A){case je.Left:i.setAll({layout:s.verticalLayout,paddingRight:n.legendPadding,width:n.width}),BL(e,i),o=e.leftAxesContainer;break;case je.Right:i.setAll({layout:s.verticalLayout,paddingLeft:n.legendPadding,paddingRight:n.legendPadding,width:n.width}),e.rightAxesContainer.setAll({paddingRight:n.chartPadding}),o=e.rightAxesContainer;break;case je.Top:c=n.chartPadding,i.setAll({layout:s.verticalLayout,paddingBottom:n.legendPadding,paddingTop:n.legendPadding,width:se}),o=e.topAxesContainer;break;case je.Bottom:{l=n.chartPadding,i.setAll({layout:s.verticalLayout,paddingTop:n.legendPadding,width:se}),e.bottomAxesContainer.setAll({paddingBottom:n.legendPadding+y});let b=yt({childId:Pc,parent:e});b instanceof pe&&b.set("paddingBottom",n.chartPadding+y),o=e.bottomAxesContainer}break}bL(e),t.markDirty(),iw(e,{chartPaddingTop:c,chartPaddingBottom:l}),hn(()=>{o&&(h?o.children.unshift(i):o.children.push(i),e.markDirty(),t.markDirty(),o.markDirty())})}function iw(a,e){let{chartPaddingTop:t,chartPaddingLeft:i,chartPaddingRight:s,chartPaddingBottom:r}=e;a.setAll({paddingTop:t,paddingLeft:i,paddingRight:s,paddingBottom:r})}function sw(a,e){let t=a.root.events.on(ot.FrameEnded,()=>{a.markerContainer.children.length>0&&(e(),t.dispose())})}function rw(a){let{series:e,legend:t,chart:i}=a,s=te(i.uid,"config"),r=n=>{let A=n.getPrivate("valueLow"),o=n.getPrivate("valueHigh");A!==void 0&&o!==void 0&&(t.get("orientation")==="vertical"?(t.set("startValue",o),t.set("endValue",A)):(t.set("startValue",A),t.set("endValue",o))),hn(()=>{sw(t,()=>{aw({legend:t,series:n,chartConfig:s})})})};e!==void 0&&(e.events.on("datavalidated",()=>{r(e)}),r(e)),nw(t,s?.legend)}function aw(a){let{legend:e,series:t,chartConfig:i}=a,s=i?.series[0],r=s?.gradientRules;if(r&&(r.minValue!==void 0||r.maxValue!==void 0)){let n=t.getPrivate("valueLow"),A=t.getPrivate("valueHigh");if(n!==void 0&&A!==void 0&&A>n){let o=n,l=A,c=l-o,h=r.minValue??o,d=r.maxValue??l,u=(h-o)/c,g=(d-o)/c;u=Math.max(0,Math.min(1,u)),g=Math.max(0,Math.min(1,g));let{start:y,end:m}=Mc(!1,s),{color:b,opacity:B}=Ye(r.outsideRangeLowerColor??$.heatChart.gradientHeatRules.outsideRangeLowerColor),{color:w,opacity:_}=Ye(r.outsideRangeUpperColor??$.heatChart.gradientHeatRules.outsideRangeUpperColor),T=[{color:b,opacity:B,offset:0},{color:b,opacity:B,offset:u},{color:y.color,opacity:y.opacity,offset:u},{color:m.color,opacity:m.opacity,offset:g},{color:w,opacity:_,offset:g},{color:w,opacity:_,offset:1}],Q=(E,O,D)=>{let k=Qi(`heatLegendLabel${D}`,e.uid),F=e.markerContainer.children.values.find(z=>z instanceof Ze&&z.get("id")===k),M=F&&!F.isDisposed()?F:void 0,Y=e.startLabel;if(M||(M=Ze.new(e.root,{id:k,position:"absolute",isMeasured:!1,centerX:ye,centerY:ye,paddingLeft:0}),e.markerContainer.children.push(M)),M.setAll({fill:Y.get("fill"),fontSize:Y.get("fontSize"),fontFamily:Y.get("fontFamily")}),M.set("text",E.toString()),e.get("orientation")==="vertical"){let z=Y.localBounds().top,re=Y.get("fontSize")??0;if(typeof re=="number"){let q=$.heatChart.legend.minMaxLabelPadding;M.set("x",z-re*2-q)}else M.set("x",z);M.set("y",Re(O*100)),M.set("centerY",ye)}else{M.set("x",Re(O*100));let z=e.startLabel.localBounds().bottom,re=$.heatChart.legend.minMaxLabelPadding;M.set("y",-z-re),M.set("centerX",si)}};u>0&&u<1&&Q(h,u,"Min"),g>0&&g<1&&Q(d,g,"Max");let U=()=>{let E;if(e.markerContainer.children.length>0&&e.markerContainer.children.each(O=>{O instanceof Tt&&(E=O)}),E){let O=0;e.get("orientation")==="vertical"&&(O=90),E.set("fillGradient",Mr.new(e.root,{stops:T,rotation:O}))}};if(e.markerContainer.children.length>0)U();else{let E=e.markerContainer.children.events.once("push",()=>{e.markerContainer.children.length>0&&(E.dispose(),U())})}}}else{let n=()=>{if(e.get("orientation")==="vertical"){let A;e.markerContainer.children.length>0&&e.markerContainer.children.each(o=>{o instanceof Tt&&(A=o)}),A&&A.set("rotation",180)}};if(e.markerContainer.children.length>0)n();else{let A=e.markerContainer.children.events.once("push",()=>{e.markerContainer.children.length>0&&(A.dispose(),n())})}}}function nw(a,e){if(a!==void 0){let t={type:P.Text,visible:e?.visible,content:{...e?.body,type:ht.TS,text:" "}};[a.startLabel,a.endLabel].forEach(i=>{Es({label:i,labelConfig:t,skipSettingText:!0,skipSettingXAndY:!0})})}}function cp(a){let e=Qi(as,a.uid);[a.bottomAxesContainer,a.rightAxesContainer,a.leftAxesContainer,a.topAxesContainer].forEach(t=>{let i=yt({childId:e,parent:t,useChildId:!0});i&&(i.children.values.filter(s=>s instanceof ur).forEach(s=>{s.dispose()}),t.children.removeValue(i),i.dispose()),t.markDirty()}),iw(a,{}),_L(a)}function dp(a,e){let t=EA({root:e.root,parent:e,index:0,id:Qi(tr,e.uid)});return t.set("paddingTop",$.heatChart.legend.titlePadding),PA({chart:a,label:t,labelType:St.LegendTitle}),t}function Rg(a){let{chart:e,legendConfig:t,container:i}=a,s=Qi(as,e.uid),r=i;if(r||[e.bottomAxesContainer,e.rightAxesContainer,e.leftAxesContainer,e.topAxesContainer].forEach(n=>{let A=yt({childId:s,parent:n,useChildId:!0});A&&(r=A)}),r!==void 0){let n=yt({childId:tr,parent:r})??dp(e,r);if(t!==void 0){let{title:A,visible:o}=t,{legendTitle:l}=$.legendProperties;if(A!==void 0){Es({label:n,labelConfig:{...A,visible:o!==!1&&A.visible!==!1},defaults:{...l,verticalCenter:Ct.Top}});let c=te(e.uid,"config")?.legend?.position??$.heatChart.legend.position;c===je.Left||c===je.Right?(n.set("maxWidth",250),Wr({chart:e,label:n,labelType:St.LegendTitle})):n.set("maxWidth",void 0),Aw({legendContainer:r,chart:e})}else Vt(n,!1)}}}function CL(a,e){let{root:t}=a,i=te(a.uid,"config"),s=i?.legend,r=a.series.values[0];cp(a);let n=JB(a,i??e),A=pe.new(t,{id:Qi(as,a.uid),layout:t.verticalLayout});return A.children.push(n),dp(a,A),Rg({chart:a,legendConfig:s,container:A}),rw({series:r,legend:n,chart:a}),s!==void 0&&s.visible!==!1&&(tw({chart:a,legend:n,legendContainer:A}),Og({legend:n,chart:a,legendContainer:A})),n}function Og(a){let{legend:e,chart:t,legendContainer:i}=a,s=te(t.uid,"config"),r=$.heatChart.legend,n=s?.legend?.position??r.position;if(n===je.Left||n===je.Right)e.set("height",se),i.set("height",se),Aw({legendContainer:i,chart:t});else{let A=yt({childId:tr,parent:i}),o=s?.legend?s.legend.visible??!0:!1,l=s?.legend?.title?s.legend.title.visible??!0:!1,c=A instanceof Ze&&o&&l?A.height()>0?A.height():r.titleHeight+r.titlePadding:0,h=n===je.Top?r.topHeight:r.bottomHeight;e.set("height",h),i.set("height",h+c+20)}}function Aw(a){let{legendContainer:e,chart:t}=a,i=te(t.uid,"config"),s=$.heatChart.legend,r=i?.legend?.position??s.position;if(r!==je.Left&&r!==je.Right)return;let n=yt({childId:tr,parent:e}),A=i?.legend?.title?i.legend.title.visible??!0:!1;if(n instanceof Ze&&A){let o=()=>{let l=n.width(),c=s.width,h=Math.max(l+s.legendPadding*2,c);e.set("width",h)};n.width()>0?o():n.events.once("boundschanged",o)}else e.set("width",s.width)}function _L(a){let e=yt({childId:Ec,parent:a});e instanceof pe&&e.set("marginTop",0)}function FL(a){let e,t=Qi(as,a.uid);return[a.bottomAxesContainer,a.rightAxesContainer,a.leftAxesContainer,a.topAxesContainer].forEach(i=>{let s=yt({childId:t,parent:i,useChildId:!0});if(s){let n=s.children.values.find(A=>A instanceof ur);if(n){e=n;return}}let r=i.children.values.find(n=>n instanceof ur);if(r){e=r;return}}),e}function SL(a){let{chart:e,chartConfig:t,heatLegendPositionChanged:i,heatRulesTypeChanged:s}=a,{legend:r}=t,n=r!==void 0&&r.visible!==!1,A=e.series.values[0];if(i||s)cp(e),n&&A instanceof mt&&hn(()=>{let o=JB(e),l=pe.new(e.root,{id:Qi(as,e.uid),layout:e.root.verticalLayout});l.children.push(o),dp(e,l),Rg({chart:e,legendConfig:r,container:l}),Hb(e,o),tw({chart:e,legend:o,legendContainer:l}),rw({series:A,legend:o,chart:e}),Og({legend:o,chart:e,legendContainer:l})});else if(A instanceof mt){let o=FL(e);if(o){Hb(e,o),Rg({chart:e,legendConfig:r}),nw(o,r);let l=o.parent;l&&l.get("id")===Qi(as,e.uid)&&Vt(l,n),Vt(o,n),wL(o,e),l&&Og({legend:o,chart:e,legendContainer:l}),hn(()=>{sw(o,()=>{aw({legend:o,series:A,chartConfig:t})})})}}}function TL(a,e){let t=!1;if(e===je.Right||e===je.Left)t=!0;else{let i=a.dataItems[0]?.get("itemContainer").bounds().left;i!==void 0&&(t=!a.dataItems.some(s=>s.get("itemContainer").bounds().left!==i))}return t}function IL(a){let e=!1,t=a.dataItems[0]?.get("itemContainer").bounds().bottom;return t!==void 0&&(e=!a.dataItems.some(i=>i.get("itemContainer").bounds().bottom!==t)),e}function DL(a){ep(a.uid,{isLegendValueLabel:!0}),a.valueLabels.template.adapters.add("text",(e,t)=>{let i=e??"",s=lD(a.uid,"pieChartLegendValueLabelsFormatter");return s!==void 0&&(i=s(t.dataItem?.get("value")??0,t.dataItem?.get("valuePercentTotal")??0)),i}),a.valueLabels.template.set("text","")}function ow(a){let{legend:e,seriesConfig:t,webChartLegend:i,pieChartLegendValueLabelFormatter:s,chart:r}=a,{visible:n,body:A,displayNumericValue:o,displayPercentage:l}=i??{};if(Oe(t)===P.PieSeries){let{numericValueFormat:c,percentValueFormat:h,valuePrefix:d,valueSuffix:u,percentagePrefix:g,percentageSuffix:y}=t[0],m=o??$.pieChart.displayNumericValueOnLegend,b=l??$.pieChart.displayPercentageOnLegend,B=s;if(s===void 0){let O=np({pieChart:r,valueIntlOptions:c?.intlOptions,percentageIntlOptions:h?.intlOptions,displayNumericValue:m,displayPercentage:b,valuePrefix:d,valueSuffix:u,percentagePrefix:g,percentageSuffix:y});B=(D,k)=>O("",D,k)}hD(e.uid,{pieChartLegendValueLabelsFormatter:B});let w=te(r?.uid??0,"config")?.legend?.position??$.legendProperties.position,_=i?.valueLabelMaxWidth,T=TL(e,w),Q={type:P.Text,visible:n,content:{...A,type:ht.TS,text:".",verticalAlignment:Ct.Middle,horizontalAlignment:T?xi.Right:xi.Center}};Es({label:e.valueLabels.template,labelConfig:Q,defaults:$.legendProperties.valueLabels});let U=te(r?.uid??0,"rtl")??!1,E=_!==void 0&&!Number.isNaN(_);e.valueLabels.template.setAll({x:void 0,y:void 0,paddingRight:5,textAlign:U?"right":"left",disabled:m===!1&&b===!1,width:E?_:null,oversizedBehavior:E?"wrap":"none"})}}function LL(a,e){a.labels.template.adapters.add("maxWidth",t=>{let i=t,s=te(e.uid,"config"),r=s?.legend?.labelMaxWidth,n=s?.legend?.position??$.legendProperties.position;if(n===je.Right||n===je.Left)i=r??$.legendProperties.legendLabels.maxWidth;else if(r!==void 0)i=r;else{let A=0;a.valueLabels.template.get("forceHidden")||a.valueLabels.each(l=>{let c=l.get("width",0);typeof c=="number"&&(A=Math.max(A,c))});let o=a.get("width",200);typeof o=="number"&&(i=o+A)}return i}),a.valueLabels.template.adapters.add("maxWidth",t=>{let i=t,s=te(e.uid,"config"),r=s?.legend?.valueLabelMaxWidth,n=s?.legend?.position??$.legendProperties.position;return n===je.Right||n===je.Left?i=r??$.legendProperties.valueLabels.maxWidth:i=r??Number.NaN,i})}function lw(a,e){let t=0;for(let i of a.dataItems){let s=i.get("label")?._contentWidth??0;t=Math.max(t,s)}return e&&t>e?e:t}function UL(a,e){for(let t of a.dataItems)t.get("label")?.set("width",e)}function QL(a,e){let t=0;for(let i of a.dataItems){let s=i.get("marker")?._contentWidth??0,r=i.get("valueLabel")?._contentWidth??0,n=s+e+r;t=Math.max(t,n)}return Math.ceil(t)+$.legendPadding}function hw(a,e){hn(()=>{let t=IL(a),i=e===je.Right||e===je.Left||!t;UL(a,i?lw(a):void 0)})}function kL(a){let{legend:e,chart:t,seriesConfig:i,legendConfig:s}=a,{displayCategory:r}=s??{},n=r??$.pieChart.displayCategoryOnLegend,A=te(t?.uid??0,"rtl")??!1;e.labels.template.setAll({forceHidden:n===!1,direction:A?"rtl":"ltr",oversizedBehavior:s?.labelMaxWidth!==void 0&&!Number.isNaN(s.labelMaxWidth)?"wrap":"none"}),hn(()=>{let o=lw(e,s?.labelMaxWidth),l=QL(e,o);e.itemContainers.template.setAll({width:l,layout:t.root.horizontalLayout}),LL(e,t),ow({legend:e,seriesConfig:i,webChartLegend:s,chart:t});let c=s.position??$.legendProperties.position;hw(e,c),e.markDirty()})}function cw(a){return a?.[0].type===P.HeatSeries&&a[0].heatRulesType!==bn.Renderer}function dw(a){let e=a.get("id");a.on("visible",(t,i)=>{if(i){let{chart:s}=i;if(s instanceof Fi){let r=yt({childId:as,parent:s});r!==void 0&&r.dataItems?.forEach(n=>{n.get("id")===e&&r.set("opacity",t?1:$.legendProperties.legendLabelReducedOpacity)})}}})}function EL(a){let e=a.target.dataItem;if(e?.dataContext!==void 0){let{dataContext:t}=e,i=typeof t=="object"&&t!==null&&"component"in t?t.component:t;if(i instanceof ti){let s={visible:!i.get("visible")};xa(i)||nl(i)?s.overlayType=Ge(i.uid,"type"):s.seriesId=i.get("id"),B0(s,i.root.dom)}}}function PL(a){a.itemContainers.template.events.on(ot.Click,EL)}function ML(a,e){let t=te(e.uid,"rtl")??!1;a.itemContainers.template.setAll({reverseChildren:t})}function HL(a){let{chart:e,legend:t,chartConfig:i,hideEmptySeries:s,queryObject:r}=a,n=Oe(i.series);if(e.series.length>1||n===P.PieSeries||n===P.HeatSeries){let A=[],o=bt(i.series);switch(n){case P.BoxPlotSeries:{let l=Cn(i);A=e.series.values.filter(c=>{let h=!1;return l?h=c instanceof qe&&!(c instanceof mr):h=c instanceof ds,h});break}case P.HistogramSeries:{A=e.series.values.filter(l=>{let c=!1;if(Ge(l.uid,"isOverlay")){let h=i.series[0].type===P.HistogramSeries?i.series[0].overlays:void 0,d=Ge(l.uid,"type"),u;switch(d){case Mt.Mean:u=h?.mean?.created;break;case Mt.Median:u=h?.median?.created;break;case Mt.Normal:u=h?.comparisonDistribution?.created;break;case Mt.StdDev:u=h?.standardDeviation?.created;break}c=u===!0}return c});break}case P.PieSeries:{A=e.series.getIndex(0)?.dataItems??[];break}case P.ComboLineAndBarSeries:case P.LineSeries:case P.RadarSeries:case P.BarSeries:A=e.series.values.filter(l=>{let c=!0;if(s!==!1){let h=i.series.find(d=>d.id===l.get("id"));if(h!==void 0&&"y"in h&&typeof h.y=="string"){let{x:d,y:u}=h,g=o===$e.BarAndLineSplitByNoAggregation?`${u}_${lh({where:h.query?.where,keepSurroundingQuotes:!1,escape:!1})}`:u;c=l.data.values.some(y=>iv({dataItem:y,x:d,y:g}))}}return c});break;case P.ScatterSeries:{let l=pw(e);l!==void 0&&(A=[l]);break}case P.HeatSeries:{let l=e.series.getIndex(0);if(l instanceof mt&&Aa(i)&&!Ri(r)){let c=YB({queryObject:r,chartConfig:i,forLegend:!0,series:l});if(c){A=[...c];let h=ZL(e);h!==void 0&&A.push(h)}}break}}t.data.setAll(A)}}function Rb(a){let e=0;return a.dataItems.forEach(t=>{let i=t.get("itemContainer").width();e=Math.max(i,e)}),Math.ceil(e)}function tl(a,e){let{root:t}=a,i=yt({childId:as,parent:a});if(i!==void 0){let s=te(a.uid,"config"),r=te(a.uid,"rtl"),n=s?.title?s.title.visible??!0:!1,A=s?.subtitle?s.subtitle.visible??!0:!1,o=s?.footer?s.footer.visible??!0:!1,l=s?.legend?s.legend.visible??!0:!1,c=s?.legend?.title?s.legend.title.visible??!0:!1,h=yt({childId:Ec,parent:a}),d=h instanceof pe&&n?h.height():0,u=yt({childId:hp,parent:a}),g=u instanceof pe&&A?u.height():0,y=yt({childId:Pc,parent:a}),m=y instanceof pe&&o?y.height():0,b=yt({childId:tr,parent:i}),B=b instanceof Ze&&l&&c?b?.height():0,w=s?.legend?.position??$.legendProperties.position,_,T=e.get("verticalScrollbar"),Q=ye,U=ye,E=t.verticalLayout,O=ye,D=ye,k=ye,F=ye,M=0,Y,z=e.height()+B,re=0,q=0,Ae=0,X=0,G,ue;switch(w){case je.Left:E=t.verticalLayout,O=si,k=si,D=si,F=si,Y=void 0,Q=si,U=si,re=i.width(),M=d+g,z<a.seriesContainer.height()&&(M+=a.seriesContainer.height()/2-z/2),_=Rb(e),T?.width()!==void 0&&_&&T.isVisible()&&(_+=T.width()+$.scrollbarPadding),r&&(G=se,ue=_);break;case je.Right:E=t.verticalLayout,O=se,k=se,D=si,F=si,Y=void 0,Q=si,U=si,q=i.width(),M=d+g,z<a.seriesContainer.height()&&(M+=a.seriesContainer.height()/2-z/2),_=Rb(e),T?.width()!==void 0&&_&&T.isVisible()&&(_+=T.width()+$.scrollbarPadding),r&&(G=se,ue=_);break;case je.Top:E=t.gridLayout,O=ye,k=ye,D=si,F=si,Y=se,Q=ye,U=ye,Ae+=z,M+=d+g,_=void 0,r&&(G=void 0);break;case je.Bottom:E=t.gridLayout,O=ye,k=ye,D=se,F=se,Y=se,Q=ye,U=ye,X=z,M=-X-m,_=void 0,r&&(G=void 0);break}(_===void 0||_>0)&&(e.setPrivate("width",_),r&&e.itemContainers.template.setAll({centerX:G,dx:ue})),e.setAll({layout:E,x:Q,centerX:U}),i.setAll({x:O,y:D,centerX:k,centerY:F,dy:M,width:Y,height:0}),a.chartContainer.setAll({paddingBottom:X,paddingTop:Ae,paddingLeft:re,paddingRight:q}),Y===void 0&&(i.setPrivate("width",void 0),i.markDirty()),a instanceof Li&&hw(e,w)}}function RL(a){let{chart:e,legend:t,legendContainer:i}=a,s=yt({childId:tr,parent:i});s&&s.on("visible",()=>{t.root.events.once(ot.FrameEnded,()=>{tl(e,t)})}),i.events.on(ot.BoundsChanged,()=>{tl(e,t)}),t.events.on(ot.BoundsChanged,()=>{tl(e,t)}),e.seriesContainer.onPrivate("height",()=>{tl(e,t)})}function uw(a,e){let t=EA({root:e.root,parent:e,index:0,id:Qi(tr,e.uid)});return t.set("paddingTop",10),PA({chart:a,label:t,labelType:St.LegendTitle}),t}function OL(a,e){e.markers.template.setAll({width:$.legendProperties.legendMarkersSize,height:$.legendProperties.legendMarkersSize}),e.markerRectangles.template.adapters.add("fillOpacity",(t,i)=>{let s=i.parent?.dataItem?.dataContext,r=s&&Si.fillOpacityField in s?s[Si.fillOpacityField]:1;return typeof r=="number"?r:t}),e.markerRectangles.template.adapters.add("strokeOpacity",(t,i)=>{let s=i.parent?.dataItem?.dataContext,r=s&&Si.strokeOpacityField in s?s[Si.strokeOpacityField]:t;return typeof r=="number"?r:t}),e.labels.template.adapters.add("text",(t,i)=>{let s=t,r=te(a.uid,"config");if(Oe(r?.series)!==P.HeatSeries){let n=i.dataItem?.component;n instanceof ni?s=(i.dataItem?.dataContext?.[n.get("categoryField")??""]??t)?.toString():n instanceof ti&&(s=n.get("name"))}if(r!==void 0){let{legend:n}=r,A={...n?.body,type:ht.TS,text:s};s=nr({textSymbol:A,format:"amChartsV5"})}return s})}function NL(a,e){e.seriesContainer.onPrivate("height",t=>{let i=0,s=te(e.uid,"config"),r=s?.legend,n=yt({childId:as,parent:e});if(n!==void 0){let o=yt({childId:tr,parent:n});o!==void 0&&r?.visible!==!1&&r?.title?.visible!==!1&&(i=o.height())}let A=s?.legend?.maxHeight??Number.NaN;Number.isFinite(A)||(s?.legend?.position===je.Top||s?.legend?.position===je.Bottom?A=$.legendProperties.maxHeight:typeof t=="number"&&(A=t-i)),a.set("maxHeight",A)})}function VL(a,e,t){a.events.on(ot.DataValidated,()=>{a.dataItems.length>0&&fw(a,e,t)})}function $L(a){let e;if(a!==void 0){let t=te(a?.uid,"config");e=te(a.uid,"rtl")&&(t?.legend?.position===je.Top||t?.legend?.position===je.Bottom)}return e??!1}function KL(a){let e="";if(a instanceof ct){let t=te(a.uid,"config"),i=os(t),s=i?Oi.Rotated:Oi.NonRotated,r=Pa(t),n=Oi.SideBySide;r===Hi.Stacked?n=Oi.Stacked:r===Hi.Stacked100&&(n=Oi.Stacked100);let A=te(a.uid,"rtl")?Oi.RTL:Oi.LTR,o;switch(t?.legend?.position){case je.Left:o=Oi.LegendLeft;break;case je.Top:o=Oi.LegendTop;break;case je.Bottom:o=Oi.LegendBottom;break;case je.Right:default:o=Oi.LegendRight;break}let l=i?a.yAxes.getIndex(0):a.xAxes.getIndex(0),c;l instanceof Rt?c=Oi.DateAxis:l instanceof at?c=Oi.ValueAxis:c=Oi.CategoryAxis;let h=t?.orderOptions?.data&&"orderBy"in t.orderOptions.data&&t.orderOptions.data.orderBy===kd.Descending?Oi.OrderByFieldsDESC:Oi.OrderByFieldsASC;e=`${s}-${A}-${n}-${o}-${c}-${h}`}return e}function GL(a){let e=KL(a);return Xv.has(e)}function fw(a,e,t){switch(t){case P.HistogramSeries:case P.PieSeries:a.set("reverseChildren",$L(e));break;case P.BarSeries:case P.LineSeries:case P.RadarSeries:case P.ComboLineAndBarSeries:a.set("reverseChildren",GL(e));break}}function XL(a,e){let t=yt({childId:as,parent:a});if(t!==void 0){let i=yt({childId:tr,parent:t})??uw(a,t);if(e!==void 0){let{title:s,visible:r}=e,{legendTitle:n}=$.legendProperties;s!==void 0?(Es({label:i,labelConfig:{...s,visible:r!==!1&&s.visible!==!1},defaults:{...n,verticalCenter:Ct.Top}}),Wr({chart:a,label:i,labelType:St.LegendTitle})):Vt(i,!1)}}}function WL(a,e=!1){let t=e?$.legendProperties.roundedMarkerRadius:$.legendProperties.rectangleMarkerRadius;a.markerRectangles.template.setAll({cornerRadiusTL:t,cornerRadiusTR:t,cornerRadiusBL:t,cornerRadiusBR:t})}function zL(a){let{legend:e,legendConfig:t,chartType:i,seriesConfig:s,chart:r}=a;if(e!==void 0){let n={type:P.Text,visible:t?.visible,content:{...t?.body,type:ht.TS,text:" "}};if(i===P.PieSeries){let A=yt({childId:as,parent:r});A!==void 0&&yt({childId:tr,parent:A})!==void 0&&ow({legend:e,seriesConfig:s,webChartLegend:t,chart:r})}Es({label:e.labels.template,labelConfig:n}),e.labels.template.setAll({x:void 0,y:void 0,paddingRight:5})}}function YL(a,e){e===!0&&a.itemContainers.each(t=>{t.events.disableType(ot.Click)})}function jL(a){let{legend:e,chart:t,seriesConfig:i}=a;i?.[0].type!==P.HeatSeries&&e.itemContainers.template.adapters.add("cursorOverStyle",()=>te(t.uid,"options")?.disableTogglingLegendItems===!0?"default":"pointer")}function Ob(a,e){let{root:t}=a,i;if(cw(e?.series))i=CL(a,e);else{let s=pe.new(t,{id:Qi(as,a.uid),layout:t.verticalLayout}),r=e?.series?.[0].type===P.HeatSeries?{nameField:Si.nameField,fillField:Si.fillField,strokeField:Si.strokeField,fillOpacityField:Si.fillOpacityField,strokeOpacityField:Si.strokeOpacityField}:{};i=Hr.new(t,{...r,verticalScrollbar:Or.new(t,{orientation:"vertical"})}),a instanceof Li?DL(i):i.valueLabels.template.setAll({forceHidden:!0,textAlign:"left"}),OL(a,i),uw(a,s),PL(i),ML(i,a),RL({chart:a,legend:i,legendContainer:s}),NL(i,a),VL(i,a,Oe(e?.series)),jL({legend:i,chart:a,seriesConfig:e?.series}),s.children.push(i),a.children.push(s)}return i}function ZL(a){let e=te(a.uid??NaN,"config"),t=e?.series[0].heatRulesType===bn.Renderer,i=a.series.values[0].data.values.some(r=>r[qt.valueField]===null||t&&!r[Ht.rendererSymbolField]),s;if(i){let r=e?.series[0].emptyCells,n=r?.symbol?.color??$.heatChart.emptyCells?.symbol?.color,{outlineColor:A,outlineOpacity:o}=Sc(e?.series[0].gridLine);s={[Si.nameField]:r?.text??$.heatChart.emptyCells?.text??"",[Si.fillField]:Ye(n).color,[Si.fillOpacityField]:Ye(n).opacity,[Si.strokeField]:A,[Si.strokeOpacityField]:o}}return s}function Nb(a){let{chart:e,legend:t,showLegend:i}=a,s=yt({childId:as,parent:e});s&&(Vt(s,i),Vt(t,i))}function Vb(a){let{chart:e,showLegend:t,legendConfig:i}=a;if(i){let{title:s,visible:r}=i,n=s!==void 0&&r!==!1&&s.visible!==!1,A=yt({childId:as,parent:e});if(A){let o=yt({childId:tr,parent:A});o&&(s?Vt(o,n):Vt(o,t))}}}function gw(a){let{chart:e,chartConfig:t,legend:i,heatChartLegendUpdatedNeeded:s,hideEmptySeries:r,seriesConfig:n,queryObject:A,heatRulesTypeChanged:o,heatLegendPositionChanged:l}=a,{legend:c,series:h}=t;if(cw(n)&&s)o&&i&&(Nb({chart:e,legend:i,showLegend:!1}),Vb({chart:e,showLegend:!1,legendConfig:c})),SL({chart:e,chartConfig:t,heatLegendPositionChanged:l,heatRulesTypeChanged:o});else if(i instanceof Hr&&(n?.[0].type===P.HeatSeries&&cp(e),yt({childId:as,parent:e})!==void 0)){let d=o0(h)&&c!==void 0&&c.visible!==!1;if(Nb({chart:e,legend:i,showLegend:d}),Vb({chart:e,showLegend:d,legendConfig:c}),d){WL(i,c?.roundMarkers),zL({legend:i,legendConfig:c,chartType:Oe(h),seriesConfig:n,chart:e}),fw(i,e,Oe(h)),HL({chart:e,legend:i,chartConfig:t,hideEmptySeries:r,queryObject:A}),XL(e,c),tl(e,i);let u=te(e.uid,"options");YL(i,u?.disableTogglingLegendItems),e instanceof Li&&kL({legend:i,chart:e,seriesConfig:n,legendConfig:c})}}}function qL(a){let{seriesConfig:e,series:t,sizePolicyChanged:i}=a,{sizePolicy:s}=e,r=t.get("heatRules")?.[0],n=Ge(t.uid,"bulletTemplate");if(n!==void 0)if(s!==void 0){let{scaleType:A,field:o,minSize:l,maxSize:c}=s,h=Xy(),d=e.markerSymbol?.size??Wd().size??1,u=(l??h.minSize)/d,g=(c??h.maxSize)/d;r!==void 0?i&&(r.min=u,r.max=g,r.logarithmic=A===Ed.Logarithmic,t.set("valueField",o),t.markDirtySize()):t.setAll({valueField:o,calculateAggregates:!0,heatRules:[{target:n,key:"scale",min:u,max:g,dataField:"value",logarithmic:A===Ed.Logarithmic}]})}else t.get("heatRules")?.pop(),t.setAll({valueField:void 0,calculateAggregates:!1})}function xa(a){return a.get("id")===$.overlayId.scatterplotTrendLine}function JL(a){return a.series.values.find(e=>!xa(e))}function pw(a){return a.series.values.find(e=>xa(e))}function eU(a){let{root:e,xAxis:t,yAxis:i,seriesConfig:s}=a,{x:r,y:n}=s,A=qe.new(e,{xAxis:t,yAxis:i,valueXField:r,valueYField:n,layer:$.zIndexes.scatterplotTrendLine});return A.set("id",$.overlayId.scatterplotTrendLine),gi(A.uid,{type:Mt.Trendline}),A}function tU(a){let{markerSeries:e,options:t,queryObject:i}=a,s=Ne.new({});gi(e.uid,{bulletTemplate:s}),pi(s,t?.selectionTheme),e.bullets.push(r=>{let n=Le.new(r,{nonScalingStroke:!0,tooltip:RA({series:e,tooltipFormatter:t?.tooltipFormatter})},s);return Br({element:n,series:e,queryObject:i}),Cw(n,e),ts.new(r,{sprite:n})})}function iU(a){let{root:e,chartConfig:t,seriesConfig:i,xAxis:s,yAxis:r,options:n,queryObject:A}=a,{x:o,y:l,id:c}=i,h=[],d=qe.new(e,{xAxis:s,yAxis:r,valueXField:o,valueYField:l,id:c,opacity:0,valueField:"value",maskBullets:!1,layer:$.zIndexes.bulletMarkers});d.strokes.template.set("forceHidden",!0),tU({markerSeries:d,options:n,queryObject:A}),VA(d,t),h.push(d);let u=eU({root:e,xAxis:s,yAxis:r,seriesConfig:i});return dw(u),h.push(u),d.appear(),h}function sU(a){let{root:e,trendLineSeries:t,data:i,dataWasUpdated:s,seriesWereReinitialized:r,valueFormat:n,defaultR2Value:A,chartConfig:o}=a,{chart:l}=t,c=o.series[0],h=c.overlays?.trendLine,d=h?.symbol??{type:ht.SLS},u=h?.created===!0&&h.visible!==!1;if(i&&(s||r)){let g=$.scatterplotSeries,y=l!==void 0?te(l.uid,"formatLocale"):void 0,{x:m,y:b}=c;t.setAll({valueXField:m,valueYField:b}),t.data.setAll(i.trendLinePoints??$.scatterplotSeries.trendLinePoints);let B=Number.isFinite(i.r2)?MA({root:e,value:i.r2??g.r2,valueFormat:n,formatLocale:y}):void 0,w=B!==void 0?`R\xB2 = ${B}`:A;t.set("name",w)}d.color===void 0&&(d.color=yA({colorIndex:1})),vr({element:t,lineSymbol:d,visible:u})}function rU(a){let{root:e,chartConfig:t,markerSeries:i}=a,s=i.chart;if(s){let r=t.series[0],n=xA(t),A,o,l=Wd(),c=new Set;i.dataItems.forEach(d=>{let u=d.bullets?.[0]?.get("sprite");if(u!==void 0){let g=Dr({dataItem:d?.dataContext,seriesConfig:r,chartSubType:$e.NonSpecific,colorMatch:n}),y=Fs({root:e,element:u,seriesSymbol:r.markerSymbol??l,rendererSymbol:g,colorMatch:n});A=y.symbolWithColorInfo,o=y.stylingInfo,kA(u,o),c.add(JSON.stringify(o))}}),A=c.size>1?void 0:A;let h=new Map;h.set(0,A),lr({data:h,htmlContainer:e.dom,chartId:i.chart?.get("id"),colorMatchApplied:$A(s)})}}function aU(a){let{dataWasUpdated:e,seriesWereReinitialized:t,data:i,series:s,chartConfig:r,loaderHandle:n}=a;if((e||t)&&i){let{x:A,y:o}=r.series[0];if(s.setAll({valueXField:A,valueYField:o}),s.events.once(ot.DataValidated,()=>{n.hideLoader()}),r.series[0].type===P.ScatterSeries&&r.series[0].sizePolicy){let{field:l}=r.series[0].sizePolicy;i.dataItems=i.dataItems.sort((c,h)=>typeof h[l]=="number"&&typeof c[l]=="number"?h[l]-c[l]:0)}s.data.setAll(i.dataItems)}}function nU(a){let{root:e,chartConfig:t,seriesConfig:i,options:s,fieldList:r,series:n,trendLineSeries:A,data:o,dataWasUpdated:l,seriesWereReinitialized:c,sizePolicyChanged:h,loaderHandle:d,utilsStrings:u}=a,{axes:g}=t,{tooltipFormatter:y}=s??{};n.set("id",i.id);let m=Ge(n.uid,"bulletTemplate");m&&pi(m,s?.selectionTheme),Vt(n.bulletsContainer,i.visible),sU({root:e,trendLineSeries:A,chartConfig:t,data:o,dataWasUpdated:l,seriesWereReinitialized:c,valueFormat:Gd(),defaultR2Value:u.notAvailable}),qL({seriesConfig:i,series:n,sizePolicyChanged:h}),ba(a)&&Ba({styleCallback:rU,callbackProps:{root:e,chartConfig:t,markerSeries:n,dataWasUpdated:l},series:n,seriesConfig:i}),eL({axesConfig:g,seriesConfig:i,series:n,fieldList:r,tooltipFormatter:y}),aU({dataWasUpdated:l,seriesWereReinitialized:c,data:o,series:n,chartConfig:t,loaderHandle:d})}function AU(a){a.series.each(e=>{e instanceof qe?e.dataItems.forEach(t=>{let i=t.bullets?.[0];i&&Xi({element:i.get("sprite"),selected:!1,backToDefaultState:!0})}):e instanceof mt?e.columns.each(t=>{Xi({element:t,selected:!1,backToDefaultState:!0})}):e instanceof ni&&e.slices.each(t=>{Xi({element:t,selected:!1,backToDefaultState:!0})})})}function Zn(a){let{chart:e,selectionSource:t}=a,i=te(e.uid,"currentSelectionDataItems");Pt(e.uid,{currentSelectionDataItems:void 0,currentSelectionOIDs:void 0,currentSelectionIndexes:void 0,computedSelectionDataItems:void 0,computedSelectionIndexes:void 0,pendingSelectionQueries:!1}),tp(e)&&AU(e),i&&nh({data:{selectionSource:t??As.ClearSelection},htmlContainer:e.root.dom})}function mw(a){let e=a?.selection.width();return e!==void 0&&e>0&&e!==2e7}function Br(a){let{element:e,series:t,queryObject:i}=a;e.events.on(ot.PointerUp,async s=>{let{chart:r}=t;if(r){let n=r.get("cursor");if(!mw(n)){let A=te(t.chart?.uid??Number.NaN,"actionMode");if(!te(t.chart?.uid??Number.NaN,"filterBySelection")&&A!==Nt.None&&A!==Nt.Zoom){let o=s.target,l=kD(s,t);Xi({element:o,selected:Yr(o.uid,"selected")!==!0}),l&&r.series.each(c=>{c instanceof qe?c.dataItems.forEach(h=>{let d=h.bullets?.[0]?.get("sprite");d!==o&&Xi({element:d,selected:!1})}):c instanceof mt?c.columns.each(h=>{h!==o&&Xi({element:h,selected:!1})}):c instanceof ni&&c.slices.each(h=>{h!==o&&Xi({element:h,selected:!1})})}),await up({chart:r,selectionSource:As.SelectionByClick,queryObject:i})}}}})}function $b(a,e){let t=Number.NaN,i=Number.NaN;if(a instanceof Gr){let s=e.get("renderer")instanceof Ui,r=a.getPrivate(s?"downPositionX":"downPositionY"),n=a.getPrivate(s?"positionX":"positionY");if(r!==void 0&&n!==void 0)if(e instanceof Gt)t=e.axisPositionToIndex(e.toAxisPosition(r)),i=e.axisPositionToIndex(e.toAxisPosition(n));else if(e instanceof Rt){t=e.positionToDate(e.toAxisPosition(r)).getTime(),i=e.positionToDate(e.toAxisPosition(n)).getTime();let A=e.getPrivate("baseInterval"),o=On.getDuration(A.timeUnit,A.count)*(e.chart?.series.getIndex(0)?.get("locationX")??1);t-=o,i-=o}else e instanceof at&&(t=e.positionToValue(e.toAxisPosition(r)),i=e.positionToValue(e.toAxisPosition(n)))}else{let s=e.get("renderer")instanceof fi,r=a.getPrivate(s?"downPositionX":"downPositionY"),n=a.getPrivate(s?"positionX":"positionY");r!==void 0&&n!==void 0&&(t=r*(s?e.width():e.height()),i=n*(s?e.width():e.height()))}return{value1:t,value2:i}}function oU(a){let e=()=>{let t=a instanceof ct?a.get("cursor"):void 0,i=te(a.uid,"filterBySelection");(t===void 0||!mw(t))&&!i&&Zn({chart:a})};a.get("background")?.events.on(ot.Click,e),a instanceof ct&&a.plotContainer.events.on(ot.PointerUp,e)}function lU(a){let{series:e,cursorBounds:t,multiSelect:i}=a,s=te(e.chart?.uid??NaN,"config"),r=Oe(s?.series);e.columns.each(n=>{let A=n.get("x"),o=n.get("y"),l=n.height()<0&&r!==P.HeatSeries,c=l?Math.abs(n.height()):n.height();if(typeof A=="number"&&typeof o=="number"){let h=l?o-c:o,d={left:A,right:A+n.width(),top:h,bottom:h+c};if(r===P.HeatSeries){let g=d.top;d.top=d.bottom,d.bottom=g}let u=!(d.left>t.right||d.right<t.left||d.top>t.bottom||d.bottom<t.top)||i&&Yr(n.uid,"selected")===!0;Xi({element:n,selected:u})}})}function hU(a){let{series:e,cursorBounds:t,multiSelect:i}=a;e.dataItems.forEach(s=>{let r=s.bullets?.[0]?.get("sprite");if(r){let n=s.bullets?.[0]?.get("sprite").get("x"),A=s.bullets?.[0]?.get("sprite").get("y"),o=typeof n=="number"&&typeof A=="number"&&n>=t.left&&n<=t.right&&A>=t.top&&A<=t.bottom||i&&Yr(r.uid,"selected")===!0;Xi({element:r,selected:o})}})}function cU(a){let{xAxis:e,series:t,cursorBounds:i,multiSelect:s}=a;t.dataItems.forEach(r=>{let n=r.bullets?.[0]?.get("sprite");if(n){let A=r.dataContext,o=r.get("valueX"),l=r.get("valueY");if(e instanceof Gt){let u=A?.[$.xAxisField];typeof u=="string"&&(o=e.categoryToIndex(u))}let c=typeof o=="number"&&o>=i.left&&o<=i.right,h=typeof l=="number"&&l>=i.top&&l<=i.bottom,d=c&&h||s&&Yr(n.uid,"selected")===!0;Xi({element:n,selected:d})}})}function dU(a){let{cursor:e,xAxis:t,yAxis:i}=a,s=e.get("behavior"),{value1:r,value2:n}=$b(e,t),{value1:A,value2:o}=$b(e,i),l={left:r>n?n:r,right:r>n?r:n,top:A<o?A:o,bottom:A<o?o:A};return s==="selectX"?(l.top=Number.NEGATIVE_INFINITY,l.bottom=Number.POSITIVE_INFINITY):s==="selectY"&&(l.right=Number.POSITIVE_INFINITY,l.left=Number.NEGATIVE_INFINITY),l}function uU(a,e){a.get("cursor")?.events.on(ot.SelectEnded,async t=>{let i=te(a.uid,"actionMode");if(i===Nt.MultiSelection||i===Nt.MultiSelectionWithCtrlKey){let s=a.xAxes.getIndex(0),r=a.yAxes.getIndex(0);if(s&&r){let n=te(a.uid,"config"),A=Oe(n?.series),o=a.get("cursor"),l=dU({cursor:o,xAxis:s,yAxis:r}),c=HB(t);a.series.each(h=>{!xa(h)&&!nl(h)&&(h instanceof mt?lU({series:h,cursorBounds:l,multiSelect:c}):h instanceof qe&&(A===P.RadarSeries?cU({xAxis:s,series:h,cursorBounds:l,multiSelect:c}):hU({series:h,cursorBounds:l,multiSelect:c})))}),Vt(o.selection,!1),await up({chart:a,selectionSource:As.SelectionByRange,queryObject:e})}}})}function fU(a){let{series:e,labelDefaults:t,externalDataLabelFormatter:i,seriesType:s}=a;e.bullets.push(()=>{let r=te(e.chart?.uid??Number.NaN,"config")?.series?.[0]?.dataLabels??a.dataLabelsConfig,n=ts.new(e.root,{locationY:1,sprite:Ze.new(e.root,{populateText:!0,oversizedBehavior:"hide",centerY:se,centerX:ye,paddingBottom:0,paddingTop:0,paddingRight:0,paddingLeft:0,fill:Ye(r?.content.color).color,fontSize:r?.content.font?.size})}),A=n.get("sprite");return A&&(yw({dataLabel:A,series:e,externalDataLabelFormatter:i}),e.chart&&r?.visible&&OB({label:A,chart:e.chart,seriesType:s}),kc({...a,dataLabel:A,dataLabelsConfig:r,labelDefaults:t,defaultDataLabelFormatter:vw})),n})}function yw(a){let{dataLabel:e,series:t,externalDataLabelFormatter:i}=a;e.adapters.remove("text"),e.adapters.remove("html");let s=i!==void 0?"html":"text";sl({label:e,labelOutputProp:s}),e.adapters.add(s,(r,n)=>{let A=r??"",o=Ge(t.uid,"histogramDataLabelFormatter"),l=n.dataItem;if(l&&"dataContext"in l&&l.dataContext!==void 0&&o!==void 0){let{count:c,minValue:h,maxValue:d}=l.dataContext;A=o(c,h,d)}return s==="html"?vs(A):A})}function vw(a){let{numberFormatter:e,dataLabelsConfigContent:t,externalDataLabelFormatter:i}=a;return(s,r,n)=>nr({textSymbol:{...t,text:e.format(s)},format:i===void 0?"amChartsV5":"html"})}function gU(a){let{series:e,labelDefaults:t,externalDataLabelFormatter:i}=a;e.dataItems.forEach(s=>{let r=s.bullets?.[0];if(r){let n=r.get("sprite");n&&n instanceof Ze&&(yw({dataLabel:n,series:e,externalDataLabelFormatter:i}),kc({...a,dataLabel:n,labelDefaults:t,defaultDataLabelFormatter:vw,externalDataLabelFormatter:i}))}})}function xw(a){let{series:e,dataLabelsConfig:t}=a,i=t?.visible,s=e.bullets.hasIndex(0);i!==!0?s&&sp(e,0):(s||fU(a),gU(a))}function nl(a){return[$.overlayId.histogramMean,$.overlayId.histogramMedian,$.overlayId.histogramStdDev,$.overlayId.histogramNormalDistribution].includes(a.get("id")??"")}function pU(a){let e="";switch(a){case Mt.Mean:e=$.overlayId.histogramMean;break;case Mt.Median:e=$.overlayId.histogramMedian;break;case Mt.StdDev:e=$.overlayId.histogramStdDev;break;case Mt.Normal:e=$.overlayId.histogramNormalDistribution;break}return e}function mU(a){let{series:e,seriesConfig:t,colorMatch:i,rendererSymbol:s}=a,{root:r}=e,n=e.chart;if(n){let A=t.fillSymbol??zy(),o=Fs({root:e.root,element:e.columns.template,seriesSymbol:A,rendererSymbol:s,colorMatch:i,isChartFillSymbol:!0}).symbolWithColorInfo;if(o!==void 0){let l=new Map;l.set(0,o),lr({data:l,htmlContainer:r.dom,chartId:n.get("id"),colorMatchApplied:$A(n)})}}}function yU(a){let{series:e,data:t,dataWasUpdated:i,seriesWereReinitialized:s,loaderHandle:r}=a;t&&(i===!0||s===!0)&&(e.events.once(ot.DataValidated,()=>{r.hideLoader()}),e.data.setAll(t.bins))}function Bc(a){let{root:e,xAxis:t,yAxis:i,type:s,utilsStrings:r}=a,n=qe.new(e,{id:pU(s),valueXField:"x",valueYField:"y",xAxis:t,yAxis:i,visible:!1});return s===Mt.Normal&&NA(n,r.overlays.normal),gi(n.uid,{isOverlay:!0,type:s}),n.set("connect",!1),n.appear(),n}function vU(a){let{root:e,seriesConfig:t,xAxis:i,yAxis:s,options:r,chartConfig:n,queryObject:A}=a,{id:o,name:l}=t,c=mt.new(e,{id:o,name:l,xAxis:i,yAxis:s,categoryXField:uA.Start,valueYField:uA.Count,maskBullets:!1});return pi(c.columns.template,r?.selectionTheme),Br({element:c.columns.template,series:c,queryObject:A}),c.columns.template.setAll({width:se}),xw({yAxisValueFormat:n.axes?.[1]?.valueFormat,series:c,seriesConfig:t,seriesType:P.HistogramSeries,dataLabelsConfig:t.dataLabels,externalDataLabelFormatter:r?.dataLabelFormatter}),VA(c,n),c.appear(),c}function xU(a){let{root:e,seriesConfig:t,xAxis:i,xAxisForOverlaySeries:s,yAxis:r,utilsStrings:n,options:A,chartConfig:o,queryObject:l}=a,c=[],h=vU({root:e,seriesConfig:t,xAxis:i,yAxis:r,options:A,chartConfig:o,queryObject:l});return c.push(h),ap(h,A?.tooltipFormatter),s&&(c.push(Bc({root:e,xAxis:s,yAxis:r,type:Mt.Mean,utilsStrings:n})),c.push(Bc({root:e,xAxis:s,yAxis:r,type:Mt.Median,utilsStrings:n})),c.push(Bc({root:e,xAxis:s,yAxis:r,type:Mt.StdDev,utilsStrings:n})),c.push(Bc({root:e,xAxis:s,yAxis:r,type:Mt.Normal,utilsStrings:n}))),c}function bU(a){let{lineSeries:e,overlayConfig:t,data:i,utilsStrings:s}=a;if(!t)Vt(e,!1);else{let{symbol:r,created:n,visible:A}=t,o=Ge(e.uid,"type"),l=r??{type:ht.SLS};if(t.symbol?.color===void 0&&(l.color=yA({colorIndex:ou(o),histogramOverlays:!0})),vr({element:e,lineSymbol:l,visible:n===!0&&A!==!1}),i&&"bins"in i){let h=i.bins.map(w=>w.count),d=Math.max(...h),{mean:u,stddev:g,median:y}=i,m=u-g,b=u+g,B=[];switch(o){case Mt.Mean:B=[{x:u,y:0},{x:u,y:d}];break;case Mt.Median:B=[{x:y,y:0},{x:y,y:d}];break;case Mt.StdDev:B=[{x:m,y:0},{x:m,y:d},{x:null,y:null},{x:b,y:0},{x:b,y:d}];break}e.data.setAll(B)}let c=e.data.getIndex(0)?.x;if(o===Mt.StdDev&&(c=i?.stddev??Ge(e.uid,"stddev"),gi(e.uid,{stddev:c})),typeof c=="number"){let h=o;switch(o){case Mt.Mean:h=s.overlays.mean;break;case Mt.Median:h=s.overlays.median;break;case Mt.StdDev:h=s.overlays.stdDev;break}let d=te(e.chart?.uid??Number.NaN,"formatLocale"),u=MA({root:e.root,value:c,valueFormat:Gd(),formatLocale:d}),g=`${h}: ${u}`;NA(e,g)}}}function BU(a){let{lineSeries:e,overlayConfig:t,data:i,numberOfPoints:s}=a;if(!t)Vt(e,!1);else{let{symbol:r,created:n,visible:A}=t,o=r??{type:ht.SLS};if(t?.symbol?.color===void 0&&(o.color=yA({colorIndex:ou(Mt.Normal),histogramOverlays:!0})),vr({element:e,lineSymbol:o,visible:n===!0&&A!==!1}),i&&"bins"in i){let{mean:l,stddev:c,min:h,max:d}=i,u=QD(i.bins),g=LD(h,d,s??$.histogramSeries.normalDistribNumberOfPoints).map(y=>({x:y,y:UD({x:y,mean:l,stddev:c,scalingFactor:u})}));e.data.setAll(g)}}}async function wU(a){let{series:e,chartConfig:t,seriesConfig:i,seriesWereReinitialized:s,dataWasUpdated:r,queryObject:n,chartRenderer:A,data:o,loaderHandle:l,options:c}=a;e.set("id",i.id),Vt(e,i.visible),pi(e.columns.template,c?.selectionTheme),dn(e.columns.template,o?.bins?.length),NA(e,i.name);let h=Ji(n),d=tu({chartRenderer:A,queryObject:n}),u=A??h?.renderer,g=uo(A,h?.renderer),y;if(sh({chartConfig:t,queryObject:n})){let m=await iu({seriesConfig:[i],dataItem:{},renderer:u,rendererOrigin:A!==void 0?_n.ChartRenderer:_n.LayerRenderer,rendererType:g,chartSubType:$e.NonSpecific,graphicTemplate:d});y=m.rendererSymbol,Pt(e.chart?.uid??Number.NaN,{colorMatchApplied:m.colorMatchApplied})}ba(a)&&Ba({styleCallback:mU,callbackProps:{...a,rendererSymbol:y},series:e,seriesConfig:i}),yU({series:e,seriesWereReinitialized:s,dataWasUpdated:r,data:o,loaderHandle:l})}async function CU(a){let{allChartSeries:e,seriesConfig:t,data:i,utilsStrings:s,fieldList:r,axes:n,options:A,dataLabelFormatter:o,chartConfig:l}=a,{tooltipFormatter:c}=A??{};for(let h=0;h<e.length;h++){let d=e[h];if(d instanceof qe&&Ge(d.uid,"isOverlay")){let u=Ge(d.uid,"type");if(u===Mt.Normal)BU({lineSeries:d,overlayConfig:t.overlays?.comparisonDistribution,data:i});else{let g;switch(u){case Mt.Mean:g=t.overlays?.mean;break;case Mt.Median:g=t.overlays?.median;break;case Mt.StdDev:g=t.overlays?.standardDeviation;break}bU({lineSeries:d,overlayConfig:g,data:i,utilsStrings:s})}}else d instanceof mt&&(await wU({...a,series:d}),xw({series:d,yAxisValueFormat:l.axes?.[1]?.valueFormat,seriesConfig:t,seriesType:P.HistogramSeries,dataLabelsConfig:t.dataLabels,externalDataLabelFormatter:o}),WD({axes:n,series:d,seriesConfig:t,fieldList:r,tooltipFormatter:c,utilsStrings:s,axesConfig:l.axes}))}}function _U(a){let e="";return a instanceof ss?e=a.get("categoryXField")??a.get("valueXField")??"":a instanceof ni&&(e=a.get("categoryField")??""),e}function FU(a){let e="";return a instanceof ss?e=a.get("categoryYField")??a.get("valueYField")??"":a instanceof ni&&(e=a.get("categoryField")??""),e}function Al(a){let e="",{chart:t}=a;return t!==void 0&&(e=te(t.uid,"isRotated")===!0?_U(a):FU(a)),e}function SU(a){T0(),w0(a.root.dom),Zn({chart:a})}function TU(a){let{chart:e,chartType:t,showMean:i}=a;return e.series.values.filter(s=>{let r=!0;return xa(s)||nl(s)||Ge(s.uid,"isOverlay")===!0?r=!1:t===P.BoxPlotSeries&&(i?r=Ge(s.uid,"isBoxPlotMeanLineSeries")===!0:r=s instanceof ds),r}).every(s=>Ge(s.uid,"isSelectionApplied")===!0)}function IU(a){a.series.each(e=>gi(e.uid,{isSelectionApplied:void 0}))}function DU(a){let e=[];if(!xa(a)&&!nl(a))switch(!0){case a instanceof ni:e=a.slices.values;break;case a instanceof mt:let{chart:t}=a;if(t){let i=te(t.uid,"config");if(i){let s=Oe(i?.series),r=[];s===P.HistogramSeries?r=[uA.Count]:s===P.HeatSeries?r=[qt.valueField]:r=mo(i?.series,[a.get("id")??""]),e=a.columns.values.filter(n=>{let A=!1,o=n.dataItem?.dataContext;return o&&(A=s===P.HeatSeries||r.some(l=>l in o&&Number.isFinite(o[l]))),A})}}break;case a instanceof qe:e=Array.from(a.dataItems.values());break}return e}function bw(a,e){let t=te(a.uid,"actionMode");(t===Nt.MonoSelection||t===Nt.None)&&e.length>1?Zn({chart:a}):e.forEach(i=>{Xi({element:i,selected:!0})})}function LU(a){let{chart:e,selectionIndexes:t,queryObject:i}=a,s=[],r=[],n=te(e.uid,"config"),A=co(n),o=mo(n?.series??[]),l=bt(n?.series),c=Oe(n?.series);return e.series.each((h,d)=>{if(n&&h.get("visible")===!0&&h.get("id")!==$.overlayId.scatterplotTrendLine){let u=n.series[0].x,g=Al(h),y=t.get(d);if(y!==void 0){let m;if(h instanceof qe&&(m=h.dataItems.map(b=>b?.bullets?.[0]?.get("sprite")).filter(b=>b!==void 0)),m!==void 0){let{indexesToSelect:b}=y;m.forEach((B,w)=>{if(b===void 0||b.includes(w)){let _=Bo({dataContext:B.dataItem?.dataContext,yList:o,yAxisField:g,xAxisField:u,chartType:c,chartSubType:l,showOutliers:A,isFeatureCollectionLayer:go(i)});_!==void 0&&s.push(_),r.push(B)}else Xi({element:B,selected:!1})})}}}}),bw(e,r),s}function UU(a){let{chart:e,chartConfig:t,options:i,elementsToApplySelectionTo:s,selectionDataItems:r,layerOidField:n,xAxisField:A,yAxisField:o,splitBy:l,queryObject:c}=a,h=Oe(t.series),d=bt(t.series),u=co(t),g=[],y=[],m=[],b=mo(t.series);return s.forEach((B,w)=>{let _=B instanceof Et||B instanceof is?B:B.bullets?.[0]?.get("sprite");if(_!==void 0){let T=B instanceof Et||B instanceof is?_.dataItem?.dataContext:B.dataContext;if(T!==void 0&&h===P.BoxPlotSeries&&T[$.boxPlot.boxPlotOutlierId]!==!0&&(T=Bo({dataContext:T,yAxisField:o,yList:b,xAxisField:A,splitBy:l,chartType:h,chartSubType:d,showOutliers:u,isFeatureCollectionLayer:go(c)})),Uu({elementDataContext:T,options:i,selectionDataItems:r,layerOidField:n,xAxisField:A,yAxisField:o,chartType:h,splitBy:l,chartSubType:d,showOutliers:u}))if(g.push(_),y.push(w),_?.dataItem instanceof Fy&&T!==void 0)m.push(T);else{let Q=new Set;h===P.PieSeries&&ah(T)?(Fu({groupOfSlicesDataContext:T})??[]).forEach(U=>{r.forEach(E=>{Sv({layerOidField:n,sliceDataContext:U,selectionDataContext:E,xAxisField:A})&&Q.add(U)})}):Q.add(T),Array.from(Q)?.forEach(U=>{let E=Bo({dataContext:U,yAxisField:o,yList:b,xAxisField:A,splitBy:l,chartType:h,chartSubType:d,showOutliers:u,isFeatureCollectionLayer:go(c)});E!==void 0&&m.push(E)})}else Xi({element:_,selected:!1})}}),bw(e,g),{selectedIndexes:y,newSelectionDataItems:m}}function QU(a){let{series:e,seriesIndex:t,queryObject:i,dataWasUpdated:s,sortChanged:r,groupOfSlicesWasUpdated:n,xAxisField:A,yAxisField:o,splitBy:l,rotationChanged:c}=a,{chart:h}=e;if(h instanceof Fi){let d=te(h.uid,"options"),{filterBySelection:u,selectionData:g,returnSelectionIndexes:y,returnSelectionOIDs:m}=d??{},{selectionIndexes:b}=g??{},B=te(h.uid,"config"),w=Cn(B),_=Oe(B?.series),T=bt(B?.series),Q=DU(e);if(u!==!0&&B!==void 0){let U=Ji(i),E=BA(U).idField,O=te(h.uid,"currentSelectionDataItems"),D=!1,k=!1,F,M=!1;if(Q?.[0]!==void 0){if(d?.viewExtentUpdated!==!0){F=d?.selectionData?.selectionItems??O;let Y=te(h.uid,"currentSelectionIndexes");M=g0({itemsA:F,itemsB:O,isPieFromFields:T===$e.PieFromFields,x:A,y:o,outStatisticFieldName:B.series[0].query?.outStatistics?.[0]?.outStatisticFieldName});let z=b?.keys.length!==Y?.keys.length||!ra(b,Y);D=r===!0||s===!0||n===!0||c===!0||F!==void 0&&M;let re=!0;if(b!==void 0&&b.size>0){let{indexesToSelect:q}=b.get(t??0)??{};re=q!==void 0&&q[0]===void 0}k=s===!0||n===!0||c===!0||!re&&z}if(D&&F!==void 0&&F.length>0){let{selectedIndexes:Y,newSelectionDataItems:z}=UU({chart:h,chartConfig:B,options:d,elementsToApplySelectionTo:Q,selectionDataItems:F,layerOidField:E,xAxisField:A,yAxisField:o,splitBy:l,queryObject:i}),re=te(h.uid,"computedSelectionDataItems")??[];if(re.push(...z),B.series.length>1&&T!==$e.BarAndLineNoAggregation&&T!==$e.BarAndLineSplitByNoAggregation&&(re=x0({data:re,x:B.series[0].x,splitByField:wA(B.series[0].query?.where)})),Pt(h.uid,{computedSelectionDataItems:re}),y===!0){let q=Array.from(new Set(Y)),Ae=te(h.uid,"computedSelectionIndexes");Ae===void 0&&(Ae=new Map),q.length===Q.length?Ae.set(t??0,{}):Ae.set(t??0,{indexesToSelect:q}),Pt(h.uid,{computedSelectionIndexes:Ae})}}else if(b!==void 0&&k)F=LU({chart:h,selectionIndexes:b,queryObject:i});else{let Y=z=>{let re=z.dataItem?.dataContext;return Uu({elementDataContext:re,options:d,selectionDataItems:F??O??[],layerOidField:E,xAxisField:A,yAxisField:o,chartType:_,splitBy:l,chartSubType:T})};Q.forEach(z=>{let re=z instanceof Et||z instanceof is?z:z.bullets?.[0]?.get("sprite");re!==void 0&&Xi({element:re,selected:Yr(re.uid,"selected")===!0||Y(re),backToDefaultState:F===void 0||F.length===0})})}}if(gi(e.uid,{isSelectionApplied:!0}),TU({chart:h,chartType:_,showMean:w})&&(IU(h),M||k)){let Y=te(h.uid,"computedSelectionDataItems")??F;Y=Array.from(new Set(Y?.map(re=>JSON.stringify(re)))).map(re=>JSON.parse(re)),F!==void 0&&Pt(h.uid,{currentSelectionDataItems:Y}),g?.selectionOIDs!==void 0&&Pt(h.uid,{currentSelectionOIDs:g.selectionOIDs});let z;if(y===!0&&(z=te(h.uid,"computedSelectionIndexes")??b,z!==void 0&&Pt(h.uid,{currentSelectionIndexes:z})),Y===void 0||Y.length===0)Zn({chart:h,selectionSource:As.ProgrammaticSelection});else{let re={selectionItems:Y,selectionSource:As.ProgrammaticSelection};y===!0&&(re.selectionIndexes=z),m!==!1&&(re.selectionOIDs=g?.selectionOIDs??te(h.uid,"currentSelectionOIDs")),nh({data:re,htmlContainer:h.root.dom})}Pt(h.uid,{computedSelectionIndexes:void 0,computedSelectionDataItems:void 0})}}}}async function kU(a){let{chart:e,options:t,dataWasUpdated:i,data:s,chartConfig:r,queryObject:n,errorStrings:A}=a,o=te(e.uid,"currentSelectionOIDs"),l=te(e.uid,"queryConfig");if(!te(e.uid,"filterBySelection")&&!Ri(n)){let c=await m0({chartConfig:r,queryConfig:l,chartData:s,currentSelectionOIDs:o,dataWasUpdated:i,queryObject:n,options:t,errorStrings:A});c!==void 0&&t!==void 0&&(t.selectionData={...t?.selectionData,selectionItems:c}),e.series.values.filter(h=>!xa(h)&&!nl(h)).forEach(h=>{let{seriesConfig:d,seriesIndex:u}=Hc(h,r);if(d){let g=d.x,y=d.type===P.BoxPlotSeries||d.type===P.HeatSeries?d.y.toString():Al(h),m=d.query?.where??"";EU({callbackProps:{...a,series:h,seriesIndex:u,xAxisField:g,yAxisField:y,splitBy:m},series:h,seriesConfig:d})}})}}async function up(a){let{chart:e,selectionSource:t,queryObject:i}=a,s=te(e.uid,"config"),r=Ri(i);if(s){let n=te(e.uid,"options"),A=Oe(s.series),o=bt(s.series),l=co(s),c=mo(s.series),h=s.series[0].x,d=Ma(i),u=r?void 0:Ah(Ji(i))?.dateFieldsTimeZone,g=Aa(s)?s.outTimeZone:void 0,y=$s(i).find(m=>m.name===h)?.type;try{let m=new Set,b=[],B=new Map,w=[],_=[],T=0;if(e.series.each((Q,U)=>{let{seriesConfig:E}=Hc(Q,s),O=E?.query?.where??"",D=E?.type===P.BoxPlotSeries?E.y.toString():Al(Q),k;Q instanceof qe?k=Q.dataItems:Q instanceof mt?k=Q.columns.values:Q instanceof ni&&(k=Q.slices.values),k?.forEach((F,M)=>{let Y=F instanceof Et||F instanceof is?F:F.bullets?.[0]?.get("sprite");if(Y!==void 0&&Yr(Y.uid,"selected")===!0){T+=1;let z=F instanceof Et||F instanceof is?F.dataItem?.dataContext:F.dataContext;if(z!==void 0){if(z=Bo({dataContext:z,yAxisField:D,yList:c,xAxisField:h,splitBy:O,chartType:A,chartSubType:o,showOutliers:l,isFeatureCollectionLayer:go(i)}),m.has(JSON.stringify(z))||(m.add(JSON.stringify(z)),b.push(z)),M!==void 0){let q=B.get(U)?.indexesToSelect??[];q.push(M),B.set(U,{indexesToSelect:Array.from(new Set(q))})}let re=z[Nd.uniqueIdsName]!==void 0?[z[Nd.uniqueIdsName]].flat():[];if(re.length>0)_.push(...re);else if(!r&&n?.returnSelectionOIDs!==!1){let q=p0({dataContext:z,options:n,xAxisField:h,yAxisField:D??"",splitBy:O,xAxisFieldType:y,chartConfig:s,outTimeZone:g,dataTimeZone:u,runsOnClientQueryEngine:d,queryObject:i});w.push(q)}}}})}),T===0)Zn({chart:e,selectionSource:t});else{if(!r&&n?.returnSelectionOIDs!==!1&&w.length>0){let U={...te(e.uid,"queryConfig")};delete U.groupByFieldsForStatistics,delete U.orderByFields,delete U.outStatistics;let E=await y0({whereList:w,queryObject:i,queryConfig:U});if(w.length===T)_=E;else for(let O=0;O<E.length;O+=1)_.push(E[O])}_=Array.from(new Set(_)),Pt(e.uid,{currentSelectionDataItems:b,currentSelectionOIDs:_,currentSelectionIndexes:B});let Q={selectionItems:b,selectionSource:t};n?.returnSelectionIndexes===!0&&(Q.selectionIndexes=B),n?.returnSelectionOIDs!==!1&&(Q.selectionOIDs=_),r&&(Q.selectionPixelTarget=D0({chartConfig:s,layer:i,selectionDataItems:b})),nh({data:Q,htmlContainer:e.root.dom})}}catch(m){Pt(e.uid,{pendingSelectionQueries:!1});let{httpStatus:b}=m instanceof oa?m.details.details:m.details??{};if(b===429)SU(e);else throw m}Pt(e.uid,{pendingSelectionQueries:!1})}}function OA(a,e){let{y:t,query:i}=e,s=bt(a.series)===$e.BarAndLineSplitByNoAggregation?`${t.toString()}_${lh({where:i?.where,keepSurroundingQuotes:!1,escape:!1})}`:[t].flat()[0],r=$.xAxisField,n=a.rotated===!0?"categoryYField":"categoryXField",A=a.rotated===!0?"valueYField":"valueXField",o=a.axes?.[0]?.valueFormat?.type===P.CategoryAxisFormat?n:A,l=a.rotated===!0?"valueXField":"valueYField";return{xField:r,yField:s,xAxisField:o,yAxisField:l}}function ba(a){let{chartConfig:e,seriesWereReinitialized:t,dataWasUpdated:i,colorMatchChanged:s,seriesStyleChanged:r,sortChanged:n,groupOfSlicesUpdateNeeded:A,stackedTypeChanged:o}=a,l=e.series.length===1,c=Oe(e.series),h=(t||i||s||r)??!1,d=!1;switch(c){case P.BarSeries:d=(l&&(n||o))??!1;break;case P.PieSeries:d=(A||n)??!1;break}return d||h}function Bw(a){let{series:e,callbackInfo:t,seriesConfig:i}=a,s=n=>{let{type:A,callbackProps:o}=n;A==="selection"?QU(o):(Vt(e,i.visible),n.styleCallback(o))},r=te(e.chart?.uid??Number.NaN,"config");switch(!0){case e instanceof mr:e.events.once(ot.DataValidated,()=>s(t));break;case e instanceof mt:{let n=e.root.events.on(ot.FrameEnded,()=>{e.columns.length===e.dataItems.length&&(n.dispose(),s(t))})}break;case e instanceof qe:{let n=Ge(e.uid,"bulletTemplate");if(n)if(Oe(r?.series??[i])===P.ScatterSeries){let A=e.root.events.on(ot.FrameEnded,()=>{n.entities.length===e.data.length&&e.dataItems[e.dataItems.length-1]?.bullets?.[0]?.get("sprite")&&(A.dispose(),s(t))})}else{let A=e.root.events.on(ot.FrameEnded,()=>{let o=Al(e)??"",l=r?.series[0]?.x??"";e.dataItems.filter(c=>{let h=c.dataContext;return o in h&&l in h&&h[l]!==void 0}).every(c=>!Number.isFinite(c.dataContext[o])||c?.bullets?.[0]?.get("sprite"))&&(A.dispose(),s(t))});t.type==="style"&&s(t)}}break;default:s(t);break}}function EU(a){let{series:e,callbackProps:t,seriesConfig:i}=a;Bw({callbackInfo:{callbackProps:t,type:"selection"},series:e,seriesConfig:i})}function Ba(a){let{series:e,styleCallback:t,callbackProps:i,seriesConfig:s}=a;Bw({callbackInfo:{styleCallback:t,callbackProps:i,type:"style"},series:e,seriesConfig:s})}function ww(a){let e;return a&&a.series.length>0&&(e=a.series.values.map(t=>t.get("visible")!==!1?`${t.get("id")}`:"").filter(t=>t!=="")),e}function fp(a){let{series:e,chartConfig:t,isRotated:i}=a,s=Pa(t),r=t.series[0],n=e.chart?.xAxes.getIndex(0),A=e.chart?.yAxes.getIndex(0),o=i&&(s===Hi.Stacked||s===Hi.Stacked100)?A:n;switch(s){case Hi.Stacked:{e.setAll({stacked:!0,valueYShow:"valueYWorking",valueXShow:"valueXWorking",baseAxis:o}),e instanceof qe&&e.set("stackToNegative",r.stackNegativeValuesToBaseline??$.lineSeries.stackNegativeValuesToBaseline);break}case Hi.Stacked100:{e.setAll({stacked:!0,baseAxis:o}),i===!0?(e.setAll({valueXShow:"valueXTotalPercent"}),n instanceof at&&n.set("calculateTotals",!0)):(e.setAll({valueYShow:"valueYTotalPercent"}),A instanceof at&&A.set("calculateTotals",!0));break}case Hi.Side:default:{e.setAll({stacked:!1,valueYShow:"valueYWorking",valueXShow:"valueXWorking"});break}}}function NA(a,e){a.set("name",e)}function PU(a){let{chart:e,chartType:t,rotated:i,assignToSecondValueAxis:s}=a,r=e.xAxes.getIndex(0),n=e.yAxes.getIndex(0),A=[r,n,e.xAxes.getIndex(1)??e.yAxes.getIndex(1)],o,l;i!==!0?(o=A[0],l=s===!0&&A[2]?A[2]:A[1]):(o=s===!0&&A[2]?A[2]:A[0],l=A[1]);let c=t===P.HistogramSeries?e.xAxes.getIndex(1):void 0;return{xAxis:o,xAxisForHistogramOverlaySeries:c,yAxis:l}}function VA(a,e){let{series:t}=e,i=Oe(t);switch(!0){case a instanceof mt:a.columns.template.setAll({hoverOnFocus:!0}),i===P.HeatSeries?a.columns.template.set("ariaLabel",RU()):a.columns.template.set("ariaLabel",eu());break}}function dn(a,e){a&&a.set("focusable",(e??0)<$.focusableThreshold)}function MU(a){let{chartSeriesLength:e,chartConfig:t,dataUpdateDetails:i,seriesFilteredOut:s,sizePolicyChangesRequireSeriesReinit:r}=a,n=!1;switch(Oe(t.series)){case P.BarSeries:case P.LineSeries:case P.RadarSeries:case P.ComboLineAndBarSeries:case P.BoxPlotSeries:n=s||i?.common?.numberOfSeriesChanged===!0||e!==t.series.length;break;case P.ScatterSeries:n=r===!0;break}return n}function gp(a){let{chartConfig:e,series:t,seriesIndex:i,queryObject:s}=a,r=e.series[i];if(r){let n=bt(e.series),A=r.name;if(n===$e.BarAndLineSplitBy||n===$e.BarAndLineSplitByNoAggregation){let o=wA(r.query?.where);A=fu({queryObject:s,fieldName:o,fieldValue:A})??A}NA(t,A)}}function Hc(a,e){let t=Oe(e?.series),i,s;return e?.series.forEach((r,n)=>{let A=!1;t!==P.BoxPlotSeries||a instanceof ds?A=a.get("id")===r.id:a instanceof mr?A=a.get("id")?.replace(`_${li.Top}`,"")===r.id||a.get("id")?.replace(`_${li.Median}`,"")===r.id||a.get("id")?.replace(`_${li.Bottom}`,"")===r.id:a instanceof qe&&(A=a.get("id")?.replace(`_${li.Outliers}`,"")===r.id),A&&(i=r,s=n)}),{seriesConfig:i,seriesIndex:s}}function HU(a,e){let{chart:t}=e;if(t instanceof ct){let i=e.get("xAxis"),s=e.get("yAxis"),r=a.dataItem?.get("valueX"),n=a.dataItem?.get("valueY");if(typeof r=="number"&&typeof n=="number"){let A=i?.getPrivate("min",0),o=i?.getPrivate("max",0),l=s?.getPrivate("min",0),c=s?.getPrivate("max",0),h=i?.get("start",0),d=i?.get("end",1),u=s?.get("start",0),g=s?.get("end",1),y=A+h*(o-A),m=A+d*(o-A),b=l+u*(c-l),B=l+g*(c-l),w=r<y||r>m||n<b||n>B;a.set("forceHidden",w)}}}function Cw(a,e){let t=(i,s)=>{s!==void 0&&HU(s,e)};a.on("x",t),a.on("y",t)}function $A(a,e){let t=e;t===void 0&&(t=te(a.uid,"config"));let i=te(a.uid,"colorMatchApplied")??!1;return(t?.colorMatch??!1)&&i}function RU(){return`{${qt.xField}} {${qt.yField}} {${qt.valueField}}`}function _w(a){let{root:e,intlOptions:t,formatLocale:i,overridePercentMultiplication:s}=a,r=er({root:e,intlOptions:t,type:P.NumberAxisFormat,formatLocale:i});return n=>{let A=`${n}`;if(r!==void 0&&n!==null&&!(n instanceof Date)){let o=typeof n=="number"?n:Av(n,r.get("intlLocales"));s===!0&&t.style==="percent"&&(o/=100),A=r.format(o)}else n instanceof Date&&(A=n.toLocaleString(void 0,t));return A}}function OU(a){let{axis:e,intlOptions:t,overridePercentMultiplication:i,valueAxisFormatter:s}=a,{chart:r,root:n}=e,A=r!==void 0?te(r.uid,"formatLocale"):void 0,o=s??_w({root:n,intlOptions:t,formatLocale:A,overridePercentMultiplication:i});return HA(e.uid,{numberFormatter:o}),o}function NU(a){let{chart:e,formatOptions:t,isNonAggregatedChart:i}=a,{root:s}=e;return r=>{let n=r??"",A=te(e.uid,"formatLocale"),o=te(e.uid,"config");if(typeof r=="number"&&t.type===P.NumberAxisFormat)n=_w({root:s,intlOptions:t.intlOptions,formatLocale:A})(r);else if(i===!0&&t.type===P.DateAxisFormat)n=er({root:s,type:P.DateAxisFormat,intlOptions:t.intlOptions,formatLocale:A}).format(n,t.intlOptions);else if(t.type===P.CategoryAxisFormat){let l=bt(o?.series);if([$e.BoxPlotMonoField,$e.BoxPlotMultiFields,$e.BoxPlotMonoFieldAndSplitBy,$e.BoxPlotMultiFieldsAndSplitBy,$e.BarAndLineFromFields].includes(l)&&typeof r=="string"){let h=te(e.uid,"fieldList");r=or(h,r)}let{characterLimit:c}=t;n=r?.toString()??"",!ii(n)&&n!==$.htmlEmptyContent&&(n=jd({stringToTruncate:n,characterLimit:c}))}return n.toString()}}function VU(a){let{chart:e,isXAxis:t=!0,formatOptions:i}=a,{root:s}=e;return r=>{let n=r??"",A=te(e.uid,"formatLocale"),o=te(e.uid,"config");if(Aa(o)){let l=Hy(o.series[0],t);if(l&&r!==void 0&&r!==""){if(i.type===P.DateAxisFormat&&i.intlOptions)switch(l.unit){case Ns.DayOfWeek:n=kB({weekdayNumber:Number(r),format:i.intlOptions,firstDayOfWeek:o.firstDayOfWeek,locale:A});break;case Ns.MonthOfYear:n=EB({monthNumber:Number(r),format:i.intlOptions,locale:A});break;case Ns.HourOfDay:n=QB({hour:Number(r),format:i.intlOptions,locale:A});break}}else if(r!==void 0&&r!==""){if(i.type===P.DateAxisFormat)n=er({root:s,type:P.DateAxisFormat,intlOptions:i.intlOptions,formatLocale:A}).format(n,i.intlOptions);else if(i.type===P.CategoryAxisFormat&&(n=r?.toString()??"",!ii(n)&&n!==$.htmlEmptyContent)){let{characterLimit:c}=i;n=jd({stringToTruncate:n,characterLimit:c})}}}return n.toString()}}function $U(a,e){let t={...fA(e)},i=["year","month","day","hour","minute","second"],s={hour:{hour:"numeric",minute:"numeric"}},r={hour:{hour:"numeric",minute:"numeric"}},n=Mn.new(t.timeZone??Intl.DateTimeFormat().resolvedOptions().timeZone);a.root.timezone?.name!==n.name&&(a.root.timezone=n);for(let A=0;A<i.length;A+=1){let o=i[A],l=A===0?o:i[A-1],c=e?.formatPerDateTimeUnit?.[o]??t,h=e?.formatPerDateTimeUnit?.[l];c&&Object.values(c).find(d=>d!==void 0&&(typeof d!="string"||!ii(d)))&&(s[o]=c,r[o]=h??c)}Object.keys(s).length>0&&a.set("dateFormats",s),Object.keys(r).length>0&&a.set("periodChangeDateFormats",r)}function Kb(a){let{axis:e,valueFormat:t,chartType:i}=a,s=yp({isXAxis:!0,chartType:i,valueFormat:t}),r=gA(t)&&e instanceof Rt,n=Ea(t)&&e instanceof at&&!(e instanceof Rt),A=s&&e instanceof Gt;return!r&&!n&&!A}function Fw(a){let{dataContext:e,defaultValue:t,chartUID:i}=a,s=vA(e),r=te(i,"config"),n=te(i,"rendererFieldNames"),A=Oe(r?.series),o=bt(r?.series);if(A===P.BoxPlotSeries&&(o===$e.BoxPlotMonoField||o===$e.BoxPlotMultiFields||o===$e.BoxPlotMonoFieldAndSplitBy||o===$e.BoxPlotMultiFieldsAndSplitBy))s=e?.[Kd];else if(A===P.HistogramSeries)s=e?.[uA.Start];else if((A===P.BarSeries||A===P.LineSeries||A===P.RadarSeries||A===P.ComboLineAndBarSeries)&&r!==void 0){let l=r.series?.[0]?.nullCategory,c=lu(o,r.series?.[0]);s=s===null&&l?.text!==void 0?l.text:e?.[c]?.toString()??""}else s=ru({value:t??"",dataContext:e,useRendererLabel:su(r,n),specificField:Ht.xAxisField});return{labelValue:s,originalLabelValue:vA(e)}}function KU(a,e){let{chart:t}=a;if(t!==void 0){let i=a.get("renderer").labels.template;i.adapters.remove("text"),i.adapters.remove("html"),i.set("html",void 0);let s=br(a.uid,"isHtmlLabelFormatter")===!0,r=e!==void 0||s?"html":"text";i.adapters.add(r,(n,A)=>{let o=n,l=br(a.uid,"labelFormatter");if(!Ss(A.uid,"isGuide")&&l!==void 0){let c,h;switch(!0){case a instanceof Rt:case a instanceof at:c=A.dataItem?._settings?.value;break;case a instanceof Gt:{let d=n,u=A.dataItem?.dataContext,g=te(a.chart?.uid??Number.NaN,"config");if(Oe(g?.series)===P.HeatSeries){let m=zn(a.get("renderer"))?u?.[qt.xField]:u?.[qt.yField];typeof m=="string"&&(d=m)}let y=Fw({dataContext:u,defaultValue:d,chartUID:t.uid});c=y.labelValue,h=y.originalLabelValue}break}c!==void 0&&(o=l(c,h),r==="html"&&(o=vs(o)))}return o}),i.adapters.add(r,(n,A)=>{let o=n,l=te(t.uid,"config");if(!Ss(A.uid,"isGuide")&&l!==void 0&&!(r==="html"&&s)){let c=os(l),h=zn(a.get("renderer"),c),d=l.axes?.[h?0:1],u={type:ht.TS,...d?.labels.content,text:n};o=nr({textSymbol:u,format:r==="text"?"amChartsV5":"html"})}return o}),r==="html"&&(i.set("html",$.htmlEmptyContent),i.set("text","")),GU(a,r)}}function GU(a,e){a.get("renderer").labels.each(t=>{if(e==="html")t.set("html",void 0),t.set("html",$.htmlEmptyContent),t.set("text","");else{let i=t.get("text")??"";t.set("text",""),t.set("text",i),t.set("html",void 0)}})}function XU(a){let{axis:e,isRotated:t,chartConfig:i}=a;if(e instanceof Gt||e instanceof Rt){let s=i.orderOptions?.data&&"orderBy"in i.orderOptions.data?i.orderOptions.data.orderBy===kd.Descending:!1,r=t===!0;s&&e instanceof Rt&&(r=!r),e.get("renderer").set("inversed",r)}}function WU(a){let{axis:e,isXAxis:t,chartType:i,formatOptions:s,isNonAggregatedChart:r,overridePercentMultiplication:n,externalAxisLabelFormatter:A,errorStrings:o}=a,{chart:l}=e;if(l!==void 0){let c=yp({isXAxis:t,chartType:i,valueFormat:s}),h=e instanceof at&&!(e instanceof Rt)&&Ea(s),d=e instanceof Rt&&gA(s),u=e instanceof Gt&&c;if(!(h||d||u))Hd("mismatchAxisAndValueFormat",o);else{let g=br(e.uid,"labelFormatter"),y=A??g;A===void 0&&(i===P.HeatSeries?y=VU({chart:l,isXAxis:t,formatOptions:s}):u?y=NU({chart:l,formatOptions:s,isNonAggregatedChart:r}):h?y=OU({axis:e,intlOptions:s.intlOptions,overridePercentMultiplication:n,valueAxisFormatter:A}):d&&$U(e,s));let m=A!==void 0;HA(e.uid,{labelFormatter:y,isHtmlLabelFormatter:m}),KU(e,y)}}}function zU(a){let{chart:e,chartConfig:{axes:t,series:i},rotationChanged:s,axisLabelsBehaviorChanged:r,timeIntervalInfoWasReset:n}=a,A=Oe(i),o=os(a.chartConfig),l=o?1:0,c=o?0:1,h=t?.[l]?.valueFormat,d=t?.[c]?.valueFormat,u=e.xAxes.getIndex(0),g=e.yAxes.getIndex(0),y=u===void 0||s||h!==void 0&&Kb({axis:u,valueFormat:h,chartType:A}),m=g===void 0||s||d!==void 0&&Kb({axis:g,valueFormat:d,chartType:A});return n||r?.[0]||r?.[1]||y||m}function zn(a,e){return a instanceof fi&&!e||a instanceof rs&&e||a instanceof Ui}function Rc(a){return a instanceof fi}function YU(a){return a instanceof rs}function jU(a){let{axis:e,isLogarithmic:t,axisConfigIndex:i}=a,s=te(e.chart?.uid??Number.NaN,"config"),r=t===!0&&xu({chartConfig:s,axisConfigIndex:i,chartData:e.chart?.series.getIndex(0)?.data.values});(e instanceof Rt||e instanceof at)&&e.setAll({logarithmic:r,treatZeroAs:r?$.treatZeroValueAs:0,maxPrecision:r?0:void 0})}function ZU(a,e){if(a instanceof at){let{integerOnlyValues:t,valueFormat:i}=e,s=lv(i)?i.intlOptions.maximumFractionDigits:void 0;a.set("maxPrecision",t===!0||s===0?0:Number.NaN)}}function Sw(a,e){let{chart:t}=e,i=ai.new(a,{forceHidden:!0});return e.set("tooltip",i),i.adapters.add("labelText",(s,r)=>{let n=s??"",A=br(e.uid,"labelFormatter");if(!r.isHidden()&&A&&t){let{label:o}=r,l=o.get("text")??"";if(e instanceof at){let c=Number.parseFloat(l.replace(/,/gu,""));n=A(Number.isNaN(c)?l:c,s)}else if(e instanceof Gt){let c=o.dataItem?.dataContext,h=Fw({dataContext:c,defaultValue:s,chartUID:t.uid});n=A(h.labelValue??l,s??h.originalLabelValue)}}return n}),i}function qU(a){let{root:e,axis:t,displayCursorTooltip:i}=a;(t.get("tooltip")??Sw(e,t)).set("forceHidden",i!==!0)}function JU(a){let{axis:e,timeIntervalInfo:t,dateBaseInterval:i,xFieldIsTimeOnly:s}=a;if(e instanceof Rt){let r,n=1;if(s)r="second";else{let{size:A,unit:o}=t??{};if(o||({size:A,unit:o}=i??{}),A&&o!==void 0){switch(o){case ns.Second:r="second";break;case ns.Minute:r="minute";break;case ns.Hour:r="hour";break;case ns.Day:r="day";break;case ns.Week:r="week";break;case ns.Month:r="month";break;case ns.Year:r="year";break}n=A}}r!==void 0&&e.set("baseInterval",{timeUnit:r,count:n})}}function eQ(a,e){let{buffer:t}=e??{};return t??=$.buffer,a instanceof at&&!(a instanceof Rt)&&!t}function tQ(a,e){let t=!1;return a instanceof at&&!(a instanceof Rt)&&(t=eQ(a,e),a.set("strictMinMax",t)),t}function Gb(a,e){let t=a;if(a){let i=(e?Math.ceil:Math.floor)(Math.log10(a));t=Math.pow(10,i)}return t}function iQ(a){let{axis:e,xAxis:t,isSecondValueAxis:i,chartType:s,stackedType:r,isLogarithmic:n}=a,A=!1,o=[P.BarSeries,P.LineSeries,P.ComboLineAndBarSeries,P.RadarSeries];if(s!==void 0&&o.includes(s)&&r===Hi.Stacked100&&!n&&e instanceof at&&!t){let l=te(e.chart?.uid??Number.NaN,"config"),c=e.chart?.series.getIndex(0)?.data.values;if(l&&c){let h=ww(e.chart),d=vu({chartConfig:l,isSecondValueAxis:i,seriesIds:h});A=!rv({seriesConfig:l.series,filteredData:c,filteredSeriesIds:d}).dataHasNegativeValues}}return A}function sQ(a){let{dataMinMax:e,chartType:t,stackedType:i,isXAxis:s,minimumFromConfig:r,maximumFromConfig:n,isLogarithmic:A}=a,{minX:o,maxX:l,minY:c,maxY:h}=e,[d,u]=s?[o??Number.NaN,l??Number.NaN]:[c,h],g=d,y=u;return i===Hi.Stacked100?(g=Number.NaN,y=Number.NaN):((t===P.BarSeries||t===P.ComboLineAndBarSeries||t===P.HistogramSeries&&!s||(t===P.LineSeries||t===P.RadarSeries)&&i===Hi.Stacked&&!s)&&(g=Math.min(d,0),y=Math.max(u,0)),g=r??g,y=n??y),A===!0&&(g=Number.isFinite(g)?Gb(g,!1):g,y=Number.isFinite(y)?Gb(y,!0):y),{min:g??Number.NaN,max:y??Number.NaN}}function rQ(a){let{axis:e,xAxis:t,isSecondValueAxis:i,data:s,minimumFromConfig:r,maximumFromConfig:n}=a,A=r,o=n,{chart:l}=e;if(l){let c=te(l.uid,"config");if(l instanceof ct&&c){let h=Oe(c.series),d=Pa(c)??Hi.Side,u=ww(l),g=vu({chartConfig:c,isSecondValueAxis:i,seriesIds:u}),y=cr(s),m=av({chartConfig:c,chartData:y??l.series.getIndex(0)?.data.values??[],filteredSeriesIds:g}),b=sQ({dataMinMax:m,chartType:h,stackedType:d,isXAxis:t,minimumFromConfig:r,maximumFromConfig:n});A=b.min,o=b.max}}return{min:A,max:o}}function aQ(a){let{axis:e,axisConfig:t,minimumFromConfig:i,maximumFromConfig:s,isLogarithmic:r,chartType:n,stackedType:A,isRotated:o,data:l,isSecondValueAxis:c}=a,{chart:h}=e;if(h&&(e instanceof at||e instanceof Rt))if(tQ(e,t)){let d=i,u=s,g=zn(e.get("renderer"),o);if(iQ({chartType:n,stackedType:A,isLogarithmic:r,axis:e,xAxis:g}))d=d??0,u=u??100;else if(mv({minimumFromConfig:i,maximumFromConfig:s,isLogarithmic:r})){let y=rQ({axis:e,xAxis:g,data:l,minimumFromConfig:d,maximumFromConfig:u,isSecondValueAxis:c});d=y.min,u=y.max}u=u??Number.NaN,d=d??Number.NaN,r&&d!==void 0&&d!==null&&(d=Number.isNaN(d)||d===0?$.treatZeroValueAs:d),Number.isNaN(d)||Number.isNaN(u)||d<u?e.setAll({min:d,max:u}):e.setAll({min:Number.NaN,max:Number.NaN}),n===P.GaugeSeries&&e.markDirty()}else e.setAll({min:Number.NaN,max:Number.NaN})}function Tc(a,e){if(a!==void 0){let t=te(a.uid,"config");if(t!==void 0){let i=Oe(t?.series),s=Pa(t)??Hi.Side,r=os(t),n=a.xAxes.getIndex(0),A=t.axes?.[0],o=t.axes?.[1],l=t.axes?.[2],c=a.yAxes.getIndex(0),h=a.xAxes.getIndex(1)??a.yAxes.getIndex(1);[{axis:n,axisConfig:A},{axis:c,axisConfig:o},{axis:h,axisConfig:i===P.HistogramSeries?A:l,isSecondValueAxis:i!==P.HistogramSeries}].forEach(d=>{let{axis:u,axisConfig:g,isSecondValueAxis:y}=d;if(u!==void 0){let{minimum:m,maximum:b,buffer:B,isLogarithmic:w}=g??{};aQ({axis:u,axisConfig:g,data:e,chartType:i,stackedType:s,isRotated:r,minimumFromConfig:m,maximumFromConfig:b,isLogarithmic:w,isSecondValueAxis:y})}})}}}function nQ(a){a.get("renderer").grid.template.adapters.add("strokeWidth",(e,t)=>{let i=br(a.uid,"zeroGridLine"),s=i?.displayZeroLine===!0,r=i?.strokeWidth??$.lineWidth;return t.get("themeTags")?.includes("base")&&s&&(r=(r===0?1:r)*1.5),r}),a.get("renderer").grid.template.adapters.add("strokeOpacity",(e,t)=>{let i=br(a.uid,"zeroGridLine"),s=i?.displayZeroLine===!0,r=i?.visible===!0?e:0;return t.get("themeTags")?.includes("base")&&s&&(r=1),r})}function pp(a){a.on("visible",()=>{a.chart instanceof ct&&Tc(a.chart)}),a.events.on(ot.DataValidated,()=>{a.chart instanceof ct&&Tc(a.chart)})}function AQ(a){let e=0;return a.dataItems.forEach(t=>{let i=t.get("label");i!==void 0&&Ss(i.uid,"isGuide")!==!0&&i.getText()!==void 0&&i.height()>e&&i.isVisible()&&(e=i.height())}),e}function Xb(a,e){if(e){let{chart:t}=e;if(t){let i=te(t.uid,"isRotated"),s=te(t.uid,"config"),r=Oe(s?.series),n=[],A=(o,l)=>{if(o instanceof at){let c=o.get("renderer")instanceof Ui;n.push({isXAxis:zn(o.get("renderer"),i),isSecondValueAxis:l===1&&r!==P.HistogramSeries,minimum:c?o.get("min"):o.getPrivate("min"),maximum:c?o.get("max"):o.getPrivate("max")})}};t.xAxes.each(A),t.yAxes.each(A),n.length>0&&n.every(o=>!Number.isNaN(o.minimum)&&!Number.isNaN(o.maximum))&&C0(n,t.root.dom)}}}function Tw(a){a.ghostLabel?.set("forceHidden",!0)}function Wb(a){let{axis:e,start:t,end:i}=a;e.zoom(t??0,i??1)}function zb(a){a!==void 0&&a.setAll({start:0,end:1})}function oQ(a){a instanceof ct&&(a.xAxes.each(e=>Wb({axis:e})),a.yAxes.each(e=>Wb({axis:e})),zb(a.get("scrollbarX")),zb(a.get("scrollbarY")))}function lQ(a){let{axis:e,guide:t,guideIndex:i}=a,{root:s,chart:r}=e,n=t.get("axisFill");n?.set("tooltip",ai.new(s,{autoTextColor:!1}));let A=n?.get("tooltip");if(A!==void 0&&r!==void 0){A.label.setAll({oversizedBehavior:"wrap"}),A.label.adapters.add("maxWidth",()=>Math.min($.tooltipWidth,r.seriesContainer.width())),A.get("background")?.set("fillOpacity",Vd);let o=te(r.uid,"rtl");A.label.set("direction",o?"rtl":"ltr")}if(n!==void 0){n.adapters.remove("tooltipText"),n.adapters.remove("tooltipHTML"),n.setAll({tooltipText:void 0,tooltipHTML:$.htmlEmptyContent,tooltipPosition:$.guideTooltipPosition}),n.adapters.add("tooltipHTML",(l,c)=>{let h=l,{dataItem:d}=c;if(!(e.get("renderer")instanceof Ui)){let u=br(e.uid,"guideTooltipFormatter");if(u!==void 0&&d instanceof ui){let g,y;switch(!0){case e instanceof Rt:case e instanceof at:g=d.get("value"),y=d.get("endValue");break;case e instanceof Gt:g=d.get("category"),y=d.get("endCategory");break}h=u({guideName:dD(d.uid,"name")??"",start:g??"",end:y,guideIndex:i})}}return vs(h??"")});let o=n.getTooltip();o&&(XB(o),o.adapters.add("x",(l,c)=>{let{chart:h}=e;if(h&&c){let d=te(h.uid,"config"),u=te(h.uid,"isRotated");if(d){let g=zn(e.get("renderer"),u)?0:1,y=d?.axes?.[g]?.guides?.[i];if(y){let{tooltipReverseColor:m}=y;WB(c,m)}}}return l}))}}function hQ(a,e){return t=>{let{guideName:i,start:s,end:r}=t,{chart:n,root:A}=a,o="";if(n!==void 0){let l=te(n.uid,"config"),c=te(n.uid,"isRotated"),h=zn(a.get("renderer"),c)?0:1,d=l?.axes?.[h]?.guides,u=s,g=r;if(a instanceof Rt){let w;if(n!==void 0){let _=te(a.chart?.uid??Number.NaN,"formatLocale");w=er({root:a.root,type:P.DateAxisFormat,formatLocale:_});let T=l?.axes?.[0]?.valueFormat?.type===P.DateAxisFormat?l.axes[0].valueFormat.intlOptions:void 0;u=w.format(s,T),r!==void 0&&(g=w.format(r,T))}}else if(a instanceof at&&!(s instanceof Date)&&!(r instanceof Date)){let w=d?.find(U=>U.name===i),{start:_,end:T}=Iw(a,w);Number.isFinite(_)&&(u=_),Number.isFinite(T)&&(g=T);let Q=br(a.uid,"numberFormatter")??(U=>za.new(A,{}).format(U));u=Q(u),g!==void 0&&(g=Q(g))}else a instanceof Gt&&(u=s,g=r);let y=u.toString(),m=g?.toString()??"";!ii(m)&&y!==m?o=Ug(e.guideTooltipLabel,{guideStart:y,guideEnd:m}):o=y;let b=te(n.uid,"rtl"),B=na(b??!1);o=`${i}${B} ${o}`}return o}}function cQ(a){let{axis:e,guideTooltipFormatter:t,utilsStrings:i}=a;HA(e.uid,{guideTooltipFormatter:t??hQ(e,i)})}function Yb(a){let{inputValue:e,axis:t,axisMin:i,axisMax:s}=a,r=e;if(e!=null)switch(!0){case t instanceof Rt:r=e;break;case t instanceof Gt:r=e.toString();break;case t instanceof at:if(typeof e!="number"){let n=e.toString().trim(),A=nu(n);A!==void 0?i!==void 0&&s!==void 0?r=A/100*(s-i)+i:r=null:r=Number.parseFloat(n)}break}return r}function mp(a,e){return a.axisRanges?.values?.filter(t=>{let i=t.get("label"),s=Ss(i?.uid??Number.NaN,"isGuide")??!1,r=Ss(i?.uid??Number.NaN,"isGaugeAxisLabel")??!1,n=!1;switch(e){case bi.Ticks:n=!s;break;case bi.Guides:n=s;break;case bi.GaugeTicksWithLabels:n=r&&"value"in t&&t.value!==void 0;break}return n})??[]}function dQ(a){let{axis:e,guideConfig:t,above:i}=a,s=t!==void 0,r=e.axisRanges.length,n=e.axisRanges.insertIndex(r,e.makeDataItem({above:i}));s&&(i===!0&&n.get("axisFill")?.setAll({layer:$.zIndexes.guide}),TD({guide:n,axis:e,guideLabelConfig:t?.label}));let A=n.get("axisFill");A!==void 0&&A.setAll({disabled:!0,fillOpacity:1});let o=n.get("grid");return o!==void 0&&s&&o.set("strokeOpacity",0),n}function uQ(a){let{axis:e,guideIndex:t,guideConfig:i}=a,s=dQ({axis:e,guideConfig:i,above:i?.above});lQ({axis:e,guide:s,guideIndex:t});let r=s.get("tick"),n=s.get("label"),A=s.get("grid");r!==void 0&&r.set("disabled",!0),n!==void 0&&n.set("inside",!0),A!==void 0&&A.set("disabled",!0)}function fQ(a,e){let t=mp(a,bi.Guides).length,i=(e?.length??t)-t;for(let s=0;s<i;s+=1)uQ({axis:a,guideIndex:s,guideConfig:e?.[s]})}function gQ(a,e){let{start:t,end:i}=e,s=t!==null?t:void 0,r=i!==null?i:void 0,{chart:n}=a,A=te(n?.uid??Number.NaN,"config");if(A!==void 0){let o=h0(A),l=a.data.values,c=l.find(h=>h[$.originalCategoryValue]===t)?.[o];if((typeof c=="string"||typeof c=="number"||c instanceof Date)&&(s=c),r!==void 0)for(let h=l.length-1;h>=0;h-=1){let d=l[h],u=d[o];if(d[$.originalCategoryValue]===i&&(typeof u=="string"||typeof u=="number"||u instanceof Date)){r=u;break}}}return{modifiedStart:s,modifiedEnd:r}}function Iw(a,e){let{start:t,end:i}=e??{},s;if(e!==void 0&&t!==void 0&&t!==null){let r=a instanceof at?a.get("min"):void 0,n=a instanceof at?a.get("max"):void 0,A=Yb({inputValue:t,axis:a,axisMin:r,axisMax:n}),o=e.style?.type===ht.SFS&&i!==null&&i!==void 0?Yb({inputValue:i,axis:a,axisMin:r,axisMax:n}):A;s={isValidGuide:A!=null&&(i===void 0||o!=null),start:A,end:o}}else s={isValidGuide:!1,start:void 0,end:void 0};return s}function pQ(a){let{axis:e,guide:t,guideConfig:i}=a,{start:s,end:r}=i;if(s!==void 0){let{chart:n}=e,A;if(e instanceof Gt&&n instanceof ct&&te(n.uid,"isNonAggregatedChart")===!0){let{modifiedStart:o,modifiedEnd:l}=gQ(e,i);A={isValidGuide:!0,start:o??s,end:l??r}}else A=Iw(e,i);if(A.isValidGuide){let o,l;switch(!0){case e instanceof Rt:case e instanceof at:o="value",l="endValue";break;case e instanceof Gt:o="category",l="endCategory";break}o!==void 0&&A.start!==void 0&&t.setAll({[o]:A.start}),l!==void 0&&A.end!==void 0&&t.setAll({[l]:A.end})}}}function mQ(a){let{axis:e,guide:t,guideConfig:i}=a;if(t){let s=t.get("axisFill"),r=t.get("label");if(i!==void 0){uD(t.uid,{name:i.name}),Vt(t,i.visible),pQ({axis:e,guide:t,guideConfig:i}),i.style.type===ht.SLS?cn({root:e.root,element:s,fillSymbol:{type:ht.SFS,color:i.style?.color,outline:i.style},visible:i.visible}):i.style.type===ht.SFS&&cn({root:e.root,element:s,fillSymbol:i.style,visible:i.visible}),ID({axis:e,guide:t,guideConfig:i,guideType:i.style.type}),t.get("axisFill")?.setAll({layer:i.above?$.zIndexes.guide:0});let{chart:n}=e}else s!==void 0&&s.set("disabled",!0),r!==void 0&&r.set("disabled",!0)}}function yQ(a){let{axis:e,guideConfigs:t,guideTooltipFormatter:i,utilsStrings:s}=a;if(t!==void 0){let r=mp(e,bi.Guides);t.forEach((n,A)=>{mQ({axis:e,guide:r[A],guideConfig:n})}),cQ({axis:e,guideTooltipFormatter:i,utilsStrings:s})}}function vQ(a){let{axis:e,tickOrGuide:t,numberOfElementsToBeDeleted:i}=a,s=[],r=e.axisRanges.length-1,n=i;for(;n>0&&r>=0;){let A=e.axisRanges.getIndex(r);A!==void 0&&(Ss(A.get("label")?.uid??Number.NaN,"isGuide")??!1)===!0&&t===bi.Guides&&(s.push(A),n-=1),r-=1}for(let A=0;A<s.length;A+=1)e.axisRanges.removeValue(s[A])}function jb(a,e){let t=mp(a,bi.Guides).length,i=e?.length??0,s=t-i;vQ({axis:a,numberOfElementsToBeDeleted:s,tickOrGuide:bi.Guides})}function xQ(a){let{axis:e,guideConfigs:t,anyGuideAboveChanged:i}=a;i&&jb(e),fQ(e,t),yQ(a),jb(e,t)}function Dw(a){return a.getCellWidthPosition()*a.width()}function bQ(a,e){let t=a.get("renderer");if(a!==void 0){let i=Number.NaN;if(e===qi.Wrap){let s=Number.MAX_SAFE_INTEGER;t.labels.each(n=>{Ss(n.uid,"isGuide")!==!0&&n.width()>0&&(s=Math.min(s,n.innerWidth()))});let r=a instanceof Rt?a.width()/$.maxNumberOfXAxisLabelsInWrapModeForDateAxis:a.width()/$.maxNumberOfXAxisLabelsInWrapMode;i=Math.max(s,r)}else if(e===qi.Hide){let s=Number.MIN_SAFE_INTEGER;t.labels.each(r=>{Ss(r.uid,"isGuide")!==!0&&r.width()>0&&(s=Math.max(s,r.innerWidth()))}),i=s+2}Number.isFinite(i)&&i>$.shortestMinGridDistance&&t.set("minGridDistance",i)}}function BQ(a){let{axis:e,chartType:t,labelConfig:i,isSecondValueAxis:s,tickSpacing:r}=a,{horizontalAxisLabelsBehavior:n}=a;n===void 0&&(n=t!==P.HistogramSeries?qi.Rotate:qi.Hide);let A=e.get("renderer"),o=A.get("minGridDistance");if(typeof r=="number"&&Number.isFinite(r))o=r;else if(t!==P.RadarSeries)if(A instanceof Ui)o=$.gauge.gaugeMinGridDistance;else if(e instanceof at)o=A instanceof fi?$.xAxisMinGridDistance:$.yAxisMinGridDistance;else if(A instanceof fi)if(s===!0)o=$.secondRotatedValueAxisMinGridDistance;else if(n===qi.Rotate){let l=i.content.font?.size??$.generalFontSize,c=e instanceof Gt?$.categoryAxisLabelPadding:$.axisLabelPadding;o=l*c}else if(n===qi.Wrap||n===qi.Hide){n===qi.Hide&&(o=e instanceof Gt?$.xCategoryAxisMinGridDistance:$.xAxisMinGridDistance);let l=br(e.uid,"minGridDistanceCallbackDisposer");l!==void 0&&l.dispose(),l=e.events.on(ot.BoundsChanged,()=>{bQ(e,n)}),HA(e.uid,{minGridDistanceCallbackDisposer:l})}else n===qi.Stagger?o=$.staggerMinGridDistance:o=e instanceof Gt?$.xCategoryAxisMinGridDistance:$.xAxisMinGridDistance;else o=e instanceof Gt?$.yCategoryAxisMinGridDistance:$.yAxisMinGridDistance;A.set("minGridDistance",o)}function Zb(a=1,e){e.get("renderer").labels.template.set("maxWidth",Dw(e)*a)}function qb(a,e=1){a.get("renderer").labels.template.setAll({oversizedBehavior:"wrap",paddingLeft:.5,paddingRight:.5,textAlign:"center"}),a.events.on(ot.BoundsChanged,()=>Zb(e,a)),Zb(e,a)}function wQ(a){let e=a.get("renderer").labels.template;e.adapters.add("rotation",(t,i)=>{let s=Ss(i.uid,"isGuide")!==!0?br(a.uid,"rotation")??0:t??0;return e.set("centerX",s===0?ye:se),s})}function Ig(a){if(a?.chart!==void 0){let e=a.get("renderer");if(te(a.chart.uid,"config")?.axes?.[0].labels!==void 0&&e.labels.length>1){let t=e.labels.getIndex(0)?.get("rotation"),i=0;e.labels.each(r=>{if(Ss(r.uid,"isGuide")!==!0&&r.width()>0){let n=t===$.rotatedAxisLabel.rotation?Math.sqrt(r.innerHeight()**2+r.innerWidth()**2):r.innerWidth();n>i&&(i=n)}});let s=Dw(a)>=i+5;if(!s&&t===0||s&&t===$.rotatedAxisLabel.rotation){let r=s?$.axisLabel.rotation:$.rotatedAxisLabel.rotation;e.labels.template.setAll({rotation:r,centerX:s?ye:se,centerY:si,paddingTop:s?$.axisLabel.paddingTop:$.rotatedAxisLabel.paddingTop,paddingLeft:s?$.axisLabel.paddingLeft:$.rotatedAxisLabel.paddingLeft,paddingRight:s?$.axisLabel.paddingRight:$.rotatedAxisLabel.paddingRight}),HA(a.uid,{rotation:r})}}}}function Jb(a){let e=a.get("renderer");wQ(a),e.labels.template.setAll({oversizedBehavior:"hide",multiLocation:.5}),e.ticks.template.setAll({multiLocation:.5}),a.events.on(ot.BoundsChanged,()=>Ig(a)),a.events.on(ot.DataValidated,()=>Ig(a)),Ig()}function eB(a){if(a&&te(a.chart?.uid??Number.NaN,"config")?.axes?.[0].labels?.visible!==!1){let e=0;a.dataItems.forEach((t,i)=>{let s=t.get("label");s!==void 0&&Ss(s.uid,"isGuide")!==!0&&s.getText()!==void 0&&s.width()>0&&i%2===0&&s.innerHeight()>e&&(e=s.innerHeight())}),e=Math.round(e),e>0&&(a.dataItems.filter(t=>{let i=t.get("tick"),s=t.get("label");return i!==void 0&&s!==void 0&&Ss(s.uid,"isGuide")!==!0&&s.getText()!==void 0&&s.width()>0}).forEach((t,i)=>{let s=t.get("tick"),r=t.get("label"),n=i%2===1;s&&s.set("length",n?e+5:$.axisTickLength),r&&r.set("dy",n?e:0)}),e&&a.get("renderer").labels.template.get("paddingBottom")!==e+5&&a.get("renderer").labels.template.set("paddingBottom",e+5))}}function CQ(a){a.get("renderer").labels.template.set("oversizedBehavior","wrap"),a.events.on(ot.BoundsChanged,()=>eB(a)),eB(a)}function _Q(a){a.get("renderer").labels.template.setAll({oversizedBehavior:"wrap",maxWidth:$.yAxisLabelMaxWidth,textAlign:"end"})}function FQ(a){let{axis:e,horizontalAxisLabelsBehavior:t,verticalAxisLabelsBehavior:i,axisLabelsBehaviorChanged:s,labelConfig:r,chartType:n}=a,A=e.get("renderer");if(!(A instanceof Ui))if(Rc(A)&&s?.[0]===!0)switch(n===P.HistogramSeries&&t===void 0?qi.Hide:t){case qi.Hide:break;case qi.Stagger:CQ(e),qb(e,2);break;case qi.Wrap:qb(e);break;case qi.Rotate:Jb(e);break;default:r.content.angle!==null&&r.content.angle===void 0&&Jb(e);break}else YU(A)&&i!==qi.Hide&&_Q(e)}function SQ(a){let{renderer:e,axisConfig:t,labelConfig:i}=a;switch(t.labelsOrientation){case Pd.Horizontal:e.labels.template.setAll({textType:"adjusted"}),e.labels.template.remove("radius");break;case Pd.Radial:e.labels.template.setAll({textType:"radial",radius:35}),i.content.verticalAlignment=Ct.Middle;break;default:e.labels.template.setAll({textType:"circular"}),e.labels.template.remove("radius")}}function TQ(a){let{axis:e,axisConfig:{labels:t},horizontalAxisLabelsBehavior:i,verticalAxisLabelsBehavior:s,axisLabelsBehaviorChanged:r,chartType:n}=a,A={...t},o=e.get("renderer"),l=o?.get("opposite");Rc(o)?(A.content.horizontalAlignment=xi.Center,A.content.verticalAlignment=l?Ct.Bottom:Ct.Top):(A.content.horizontalAlignment=l?xi.Left:xi.Right,A.content.verticalAlignment=Ct.Middle),o instanceof Ui?SQ({renderer:o,axisConfig:a.axisConfig,labelConfig:t}):A.content.angle=A.content.angle??o.labels.template.get("rotation");let c=br(e.uid,"isHtmlLabelFormatter")===!0;Es({label:o.labels.template,labelConfig:A,skipSettingText:c}),FQ({axis:e,horizontalAxisLabelsBehavior:i,verticalAxisLabelsBehavior:s,labelConfig:t,axisLabelsBehaviorChanged:r,chartType:n})}function IQ(a){let{axis:e,isHorizontalAxis:t,label:i}=a,{chart:s}=e;if(s){let r=t?"width":"height",n=t?St.XAxisTitle:St.YAxisTitle;Wr({chart:s,label:i,labelType:n}),e.onPrivate(r,Ao(()=>Wr({chart:s,label:i,labelType:n}),$.debounceTime))}}function DQ(a){let{x:e,data:t,chart:i,valueFormat:s,minimum:r,maximum:n}=a,A=Number.NaN;if(t!==void 0&&e!==void 0){let o=t.find(c=>e in c),l=Number.parseFloat(o[e]);Number.isFinite(l)&&(A=l,Pt(i.uid,{gaugeData:A}))}else{let o=te(i.uid,"gaugeData");Number.isFinite(o)&&(A=o)}return wn(s)&&r!==void 0&&n!==void 0&&r!==null&&n!==null&&A!==null&&n-r!==0&&(A=il({value:A,axisMin:r,axisMax:n})),A}function LQ(a,e){let t=e??null;if(e!=null){let i=a.xAxes.getIndex(0),s=te(a.uid,"config"),r=i.get("min")??s?.axes?.[0].minimum??$.gauge.axisMinimum,n=i.get("max")??s?.axes?.[0].maximum??$.gauge.axisMaximum;e<r?t=r:e>n&&(t=n)}return t??void 0}function UQ(a){let{root:e}=a,t=Kr.new(e,{radius:Re(100)}),i=a.makeDataItem({value:0,bullet:an.new(e,{sprite:t})});return a.createAxisRange(i),i.get("grid")?.set("visible",!1),i.get("tick")?.set("visible",!1),t}function QQ(a){let{chart:e,axis:t,needleConfig:i,gaugeValue:s}=a,r=t.axisRanges.values.find(A=>A.get("bullet")?.get("sprite")instanceof Kr),n=r?.get("bullet")?.get("sprite");if(r&&n instanceof Kr){let{startWidth:A,endWidth:o,innerRadius:l}=$.gaugeNeedle;cn({root:t.root,element:n.hand,fillSymbol:i?.symbol}),cn({root:t.root,element:n.pin,fillSymbol:i?.symbol}),r.set("value",LQ(e,s)),n.pin.set("visible",i?.displayPin===!0),n.setAll({visible:i?.visible??!0,innerRadius:Re(i?.innerRadius??l),bottomWidth:i?.startWidth??A,topWidth:i?.endWidth??o})}}function kQ(a,e){let t=Number.isFinite(e?.innerRadius)?e?.innerRadius:$.gauge.innerRadius;typeof t=="number"&&Number.isFinite(t)&&a.set("innerRadius",Re(t))}function EQ(a,e){let t=Number.isFinite(e?.startAngle)?e?.startAngle:$.gauge.startAngle,i=Number.isFinite(e?.endAngle)?e?.endAngle:$.gauge.endAngle;typeof t=="number"&&Number.isFinite(t)&&a.set("startAngle",t),typeof i=="number"&&Number.isFinite(i)&&a.set("endAngle",i)}async function PQ(a){let{chart:e,chartConfig:t,data:i,queryObject:s,xAxisLabelFormatter:r,utilsStrings:n,errorStrings:A}=a,{axes:o,series:l}=t,c=dh(t),{featureIndex:h,x:d}=l[0],u=o?.[0],g=e.xAxes.getIndex(0),y={...u};if(g instanceof at&&g.get("renderer")instanceof Ui&&y!==void 0&&i&&"dataItems"in i){let{valueFormat:m,needle:b}=y;kQ(e,t),EQ(e,t);let B=await dB({featureIndex:h,chartData:i.dataItems,chartConfig:t,queryObject:s,queryConfig:te(e.uid,"queryConfig")});y.minimum=B.minimum,y.maximum=B.maximum;let{min:w,max:_}=hB(y),T={...y};wn(m)?(T.minimum=0,T.maximum=1,cB({axisConfig:T,axisMin:y.minimum,axisMax:y.maximum})):(T.minimum=w,T.maximum=_),vp({chartConfig:t,axis:g,axisConfig:T,axisConfigIndex:0,externalAxisLabelFormatter:r,utilsStrings:n,errorStrings:A,queryObject:s});let Q=c?B?.dataValue:DQ({x:d,data:i.dataItems,chart:e,minimum:y.minimum,maximum:y.maximum,valueFormat:m});QQ({chart:e,axis:g,needleConfig:b,gaugeValue:Q})}}function MQ(a){let{chart:e,axesConfig:t,errorStrings:i}=a,{root:s}=e;aa({chartType:P.GaugeSeries,axesConfig:t,errorStrings:i});let r=e.xAxes.push(at.new(s,{min:0,max:100,renderer:Ui.new(s,{})}));UQ(r),Tw(r)}function HQ(a){let{chart:e,chartConfig:t,axisLabelsBehaviorChanged:i,sortChanged:s,data:r,dataWasUpdated:n,axesInitializationNeeded:A,yAxisLabelFormatter:o,xAxisLabelFormatter:l,guideTooltipFormatter:c,utilsStrings:h,errorStrings:d,queryObject:u}=a,{horizontalAxisLabelsBehavior:g,verticalAxisLabelsBehavior:y,axes:m}=t,b=P.HistogramSeries,B=e.xAxes.getIndex(0),w=e.yAxes.getIndex(0);aa({chartType:b,axesConfig:m,errorStrings:d}),[{axis:B,axisConfig:m?.[0],externalAxisLabelFormatter:l},{axis:w,axisConfig:m?.[1],externalAxisLabelFormatter:o}].forEach((_,T)=>{let{axis:Q,axisConfig:U,externalAxisLabelFormatter:E}=_;Q!==void 0&&!Q.isDisposed()&&U!==void 0&&vp({axis:Q,data:r,dataWasUpdated:n,axesInitializationNeeded:A,sortChanged:s,axisConfig:U,axisConfigIndex:T,horizontalAxisLabelsBehavior:g,verticalAxisLabelsBehavior:y,axisLabelsBehaviorChanged:i,utilsStrings:h,chartConfig:t,externalAxisLabelFormatter:E,guideTooltipFormatter:c,errorStrings:d,queryObject:u})}),Tc(e,r)}function RQ(a){let{chart:e,axesConfig:t,x:i,errorStrings:s}=a,{root:r}=e,n=P.HistogramSeries;aa({chartType:n,axesConfig:t,errorStrings:s});let A={root:r,x:i,chartType:n},o=t?.[0]?.valueFormat,l=t?.[1]?.valueFormat;if(o!==void 0&&l!==void 0){let c=ln({...A,axes:e.xAxes,valueFormat:o,axisRenderer:fi.new(r,{}),isXAxis:!0,x:i}),h=ln({...A,axes:e.xAxes,valueFormat:o,axisRenderer:fi.new(r,{}),isAxisForHistogramOverlaySeries:!0,isXAxis:!0,x:i});ln({...A,axes:e.yAxes,valueFormat:l,axisRenderer:rs.new(r,{}),isXAxis:!1,x:i}),c&&(c.get("renderer").grid.template.set("location",0),c.get("renderer").ticks.template.set("location",0),c.get("renderer").labels.template.set("location",0)),h&&(h.set("visible",!1),h.get("renderer").grid.template.set("visible",!1),h.get("renderer").ticks.template.set("visible",!1),h.get("renderer").labels.template.set("visible",!1))}}function yp(a){let{isXAxis:e,chartType:t,valueFormat:i,isAxisForHistogramOverlaySeries:s}=a;return t===P.HeatSeries||e&&(Rd(i)||t===P.HistogramSeries&&!s||t===P.BarSeries&&Ea(i))}function Lw(a,e){return e?`${Hg}_x_${a.uid}`:`${Hg}_y_${a.uid}`}function Ng(a,e){let t=te(a.chart?.uid??Number.NaN,"config"),i=os(t)?1:0,s=t?.axes?.[i]?.title?.content?.verticalAlignment,r=AQ(a),n=r;switch(s){case Ct.Baseline:case Ct.Middle:n=r/2;break;case Ct.Bottom:n=Math.min(r,0);break;case Ct.Top:}e?.set("dy",n)}function OQ(a){a instanceof at&&(a.onPrivate("min",Xb),a.onPrivate("max",Xb))}function NQ(a){let{axis:e,isHorizontalAxis:t,isSecondValueAxis:i}=a,{root:s}=e,r=t?{...$.xAxisTitleLabel,verticalCenter:Ct.Top}:$.yAxisTitleLabel,n=EA({root:s,id:Lw(e,t),defaults:r});return e.get("renderer")instanceof rs&&i!==!0||e.get("renderer")instanceof fi&&i===!0?e.children.unshift(n):e.children.push(n),t&&i!==!0&&(e.events.onDebounced(ot.BoundsChanged,()=>Ng(e,n),$.debounceTime),e.events.onDebounced(ot.DataValidated,()=>Ng(e,n),$.debounceTime),IQ({axis:e,isHorizontalAxis:t,label:n})),n}function ln(a){let{root:e,axes:t,isXAxis:i,valueFormat:s,axisRenderer:r,isSecondValueAxis:n=!1,chartType:A,x:o,isAxisForHistogramOverlaySeries:l}=a,c;if(yp({isXAxis:i,chartType:A,valueFormat:s,isAxisForHistogramOverlaySeries:l})&&!n){let h;switch(A){case P.HeatSeries:h=i?qt.xField:qt.yField;break;case P.HistogramSeries:h=uA.Start;break;case P.BoxPlotSeries:h=o;break;default:h=$.xAxisField;break}h&&(c=t.push(Gt.new(e,{categoryField:h,renderer:r})))}else if(gA(s))c=t.push(Rt.new(e,{strictMinMax:!0,baseInterval:{timeUnit:"day",count:1},renderer:r}));else if(Ea(s)&&(c=t.push(at.new(e,{strictMinMax:!0,renderer:r})),n&&c instanceof at)){let h=t.getIndex(0);h instanceof at&&c.set("syncWithAxis",h)}if(c!==void 0&&!l){nQ(c),Sw(e,c);let h=A===P.HistogramSeries||A===P.HeatSeries?0:.1,d=A===P.HistogramSeries||A===P.HeatSeries?1:.9;c.get("renderer").setAll({cellStartLocation:h,cellEndLocation:d}),A===P.HeatSeries&&(r instanceof fi||r instanceof rs)&&r.setAll({layer:$.zIndexes.axisLineLayer}),Tw(c),OQ(c),Rc(c.get("renderer"))?c.get("renderer").labels.template.set(n?"paddingBottom":"paddingTop",$.axisLabelSpacing.horizontalAxisLabelPaddingTop):r instanceof rs&&c.get("renderer").labels.template.set(n?"paddingLeft":"paddingRight",$.axisLabelSpacing.verticalAxisLabelSidePadding)}return c}function VQ(a){let{axis:e,data:t,chartType:i,dataWasUpdated:s,axesInitializationNeeded:r,sortChanged:n,heatChartHideEmptyRowsAndColumnsChanged:A}=a;if(t&&(s||r||n||A)){let o=cr(t);if(i!==P.HeatSeries)e.data.setAll(o??[]);else{let l=(d,u)=>{let g=u?.map(y=>d in y?y[d]:void 0);return Array.from(new Set(g)).map(y=>({[d]:y}))},c=e.get("renderer")instanceof rs?qt.yField:qt.xField,h=l(c,o);e.data.setAll(h)}}}function $Q(a){let{axis:e,axisTitleConfig:t,isSecondValueAxis:i}=a,s=e.get("renderer"),{chart:r}=e,n=Rc(s),A=yt({childId:Lw(e,n),parent:e,useChildId:!0})??NQ({axis:e,isHorizontalAxis:n,isSecondValueAxis:i});if(A instanceof Ze){let o=n?{...$.xAxisTitleLabel,verticalCenter:Ct.Top}:$.yAxisTitleLabel;if(Es({label:A,labelConfig:t,defaults:o}),n&&i!==!0&&Ng(e,A),r){let l={chart:r,label:A,labelType:n?St.XAxisTitle:St.YAxisTitle};Wr(l)}}}function vp(a){let{axis:e,data:t,dataWasUpdated:i,axesInitializationNeeded:s,sortChanged:r,heatChartHideEmptyRowsAndColumnsChanged:n,axisConfig:A,axisConfigIndex:o,timeIntervalInfo:l,horizontalAxisLabelsBehavior:c,verticalAxisLabelsBehavior:h,axisLabelsBehaviorChanged:d,anyGuideAboveChanged:u,isNonAggregatedChart:g,isSecondValueAxis:y,chartConfig:m,externalAxisLabelFormatter:b,guideTooltipFormatter:B,utilsStrings:w,errorStrings:_,queryObject:T}=a,{visible:Q,lineSymbol:U,title:E,labels:O,isLogarithmic:D,grid:k,displayCursorTooltip:F,displayZeroLine:M,valueFormat:Y,guides:z,tickSpacing:re,dateBaseInterval:q}=A,{root:Ae}=e,X=Oe(m.series),G=Pa(m),ue=os(m),{chart:he}=e,ae=he?te(he.uid,"config"):void 0,Ie=Ji(T),Pe=$s(Ie).find(dt=>dt.name===ae?.series?.[0]?.x),De=Q0(Pe),Qe=e.get("renderer");HA(e.uid,{zeroGridLine:{displayZeroLine:M,strokeWidth:k?.width??$.lineWidth,visible:k!==void 0}}),jU({axis:e,isLogarithmic:D,axisConfigIndex:o}),WU({axis:e,isXAxis:zn(e.get("renderer"),ue),chartType:X,formatOptions:Y,isNonAggregatedChart:g,overridePercentMultiplication:G===Hi.Stacked100,externalAxisLabelFormatter:b,errorStrings:_}),XU({axis:e,isRotated:ue,chartConfig:m}),JU({axis:e,timeIntervalInfo:l,dateBaseInterval:q,xFieldIsTimeOnly:De}),vr({element:Qe,lineSymbol:{color:[...$.color],...U??ih()},visible:Q}),vr({element:Qe.ticks.template,lineSymbol:U,visible:Q}),vr({element:Qe.grid.template,lineSymbol:k,visible:Q}),k===void 0&&(e.get("renderer").grid.template.set("strokeWidth",$.lineWidth),e.markDirtyValues()),TQ({axis:e,axisConfig:A,chartType:X,horizontalAxisLabelsBehavior:c,verticalAxisLabelsBehavior:h,axisLabelsBehaviorChanged:d}),$Q({axis:e,axisTitleConfig:E,isSecondValueAxis:y}),ZU(e,A),BQ({axis:e,chartType:X,labelConfig:O,horizontalAxisLabelsBehavior:c,isSecondValueAxis:y,tickSpacing:re}),qU({root:Ae,axis:e,displayCursorTooltip:F}),xQ({axis:e,guideConfigs:z,guideTooltipFormatter:B,anyGuideAboveChanged:u,utilsStrings:w}),VQ({axis:e,data:t,chartType:X,dataWasUpdated:i,axesInitializationNeeded:s,heatChartHideEmptyRowsAndColumnsChanged:n,sortChanged:r})}function KQ(a){let{chart:e,errorStrings:t}=a,{root:i}=e,s=te(e.uid,"config");if(s){let{x:r}=s.series[0],n=os(s),{axes:A}=s,o=Oe(s.series);aa({chartType:o,axesConfig:A,errorStrings:t});let l={root:i,x:r,chartType:o},c=n?A?.[1]:A?.[0],h=n?A?.[0]:A?.[1],d=c?.valueFormat,u=h?.valueFormat;if(d!==void 0&&u!==void 0&&(ln({...l,axes:e.xAxes,valueFormat:d,axisRenderer:fi.new(i,{}),isXAxis:!n,x:r}),ln({...l,axes:e.yAxes,valueFormat:u,axisRenderer:rs.new(i,{}),isXAxis:n,x:r}),A?.[2]!==void 0)){let g=n?fi:rs;ln({...l,axes:n?e.xAxes:e.yAxes,valueFormat:A[2]?.valueFormat,axisRenderer:g.new(i,{opposite:!0}),isSecondValueAxis:!0,isXAxis:n,x:r})}}}function GQ(a){let{chart:e,chartType:t,axesConfig:i,x:s,errorStrings:r}=a,{root:n}=e,A=i?.[0],o=i?.[1];if(aa({chartType:t,axesConfig:i,errorStrings:r}),A?.valueFormat!==void 0&&o?.valueFormat!==void 0){let l={root:n,x:s,chartType:t};ln({...l,axes:e.xAxes,valueFormat:A.valueFormat,axisRenderer:Ui.new(n,{}),isXAxis:!0,x:s}),ln({...l,axes:e.yAxes,valueFormat:o.valueFormat,axisRenderer:sn.new(n,{}),isXAxis:!1,x:s})}}function Uw(a){let{chart:e,chartConfig:t,errorStrings:i}=a,{axes:s}=t,{x:r}=t.series[0],n=Oe(t.series);switch(e.xAxes.clear(),e.yAxes.clear(),n){case P.GaugeSeries:e instanceof cs&&MQ({chart:e,axesConfig:s,errorStrings:i});break;case P.HistogramSeries:RQ({chart:e,axesConfig:s,x:r,errorStrings:i});break;case P.HeatSeries:case P.BarSeries:case P.ComboLineAndBarSeries:case P.ScatterSeries:case P.LineSeries:case P.BoxPlotSeries:KQ({chart:e,errorStrings:i});break;case P.RadarSeries:e instanceof cs&&GQ({chart:e,axesConfig:s,chartType:n,x:r,errorStrings:i});break}}function XQ(a){let{chart:e,chartConfig:t,axisLabelsBehaviorChanged:i,sortChanged:s,anyGuideAboveChanged:r,data:n,dataWasUpdated:A,axesInitializationNeeded:o,heatChartHideEmptyRowsAndColumnsChanged:l,timeIntervalInfo:c,xAxisLabelFormatter:h,yAxisLabelFormatter:d,secondaryYAxisLabelFormatter:u,guideTooltipFormatter:g,utilsStrings:y,errorStrings:m,queryObject:b}=a,{horizontalAxisLabelsBehavior:B,verticalAxisLabelsBehavior:w,axes:_}=t,T=os(t),Q=Oe(t.series),U=te(e.uid,"isNonAggregatedChart"),E=e.xAxes.getIndex(0),O=e.yAxes.getIndex(0),D=e.xAxes.getIndex(1)??e.yAxes.getIndex(1);aa({chartType:Q,axesConfig:_,errorStrings:m});let k=T?1:0,F=T?0:1,M=_?.[k],Y=_?.[F];[{axis:E,axisConfig:M,externalAxisLabelFormatter:T?d:h,axisConfigIndex:k},{axis:O,axisConfig:Y,externalAxisLabelFormatter:T?h:d,axisConfigIndex:F},{axis:D,axisConfig:_?.[2],externalAxisLabelFormatter:u,isSecondValueAxis:!0,axisConfigIndex:2}].forEach(z=>{let{axis:re,axisConfig:q,axisConfigIndex:Ae,externalAxisLabelFormatter:X,isSecondValueAxis:G}=z;re!==void 0&&!re.isDisposed()&&q!==void 0&&vp({axis:re,data:n,dataWasUpdated:A,axesInitializationNeeded:o,heatChartHideEmptyRowsAndColumnsChanged:l,sortChanged:s,timeIntervalInfo:c,axisConfig:q,axisConfigIndex:Ae,horizontalAxisLabelsBehavior:B,verticalAxisLabelsBehavior:w,axisLabelsBehaviorChanged:i,anyGuideAboveChanged:r,isNonAggregatedChart:U,isSecondValueAxis:G,utilsStrings:y,chartConfig:t,externalAxisLabelFormatter:X,guideTooltipFormatter:g,errorStrings:m,queryObject:b})}),Tc(e,n)}async function Qw(a){let{chart:e,chartConfig:t}=a,i=Oe(t.series);i===P.GaugeSeries&&e instanceof cs?await PQ(a):i===P.HistogramSeries?HQ(a):XQ(a)}function WQ(a,e){let t=Ye($.backgroundColor);e.set("background",Tt.new(a,{fill:t.color,fillOpacity:t.opacity}))}function kw(a,e){let t=Ye(e??$.backgroundColor);a.get("background")?.setAll({fill:t.color,fillOpacity:t.opacity})}function Ew(a,e){let t=Oe(e.series);return a instanceof ct&&t!==P.GaugeSeries}function zQ(a,e){let t=$.cursorCrosshair.style,i={type:ht.SLS,style:e?.style??t.style,color:e?.color??t.color,width:e?.width??t.width},s=a.get("cursor")?.lineX,r=a.get("cursor")?.lineY;vr({element:s,lineSymbol:i}),vr({element:r,lineSymbol:i})}function Pw(a){let{root:e,chart:t,config:i,queryObject:s}=a,r;if(Ew(t,i)){let n=t instanceof cs?Gr:Js;r=t.set("cursor",n.new(e,{})),uU(t,s)}return r}function Mw(a){let{root:e,chart:t,cursorCrosshair:i,config:s,queryObject:r}=a;if(Ew(t,s)){let n=t.get("cursor")??Pw({root:e,chart:t,config:s,queryObject:r});n&&(zQ(t,i?.style),n.lineX.set("visible",i?.verticalLineVisible??$.cursorCrosshair.verticalLineVisible),n.lineY.set("visible",i?.horizontalLineVisible??$.cursorCrosshair.horizontalLineVisible))}}function YQ(a){let{chart:e,enabled:t}=a,i=t?"pointer":"default";e instanceof Fi&&e.series.each(s=>{switch(!0){case s instanceof mt:s.columns.template.set("cursorOverStyle",i);break;case s instanceof qe:let r=Ge(s.uid,"bulletTemplate");r!==void 0&&!xa(s)&&r.set("cursorOverStyle",i);break;case s instanceof ni:s.slices.template.setAll({cursorOverStyle:i});break}})}function jQ(a){let{chart:e,actionMode:t,cursorRange:i}=a,s=te(e.uid,"isRotated"),r=te(e.uid,"config"),n=Oe(r?.series),A=n===P.ScatterSeries,o=(n===P.LineSeries||n===P.RadarSeries)&&Ea(r?.axes?.[0]?.valueFormat),l=(n===P.LineSeries||n===P.RadarSeries)&&Rd(r?.axes?.[0]?.valueFormat),c=(n===P.LineSeries||n===P.RadarSeries)&&gA(r?.axes?.[0]?.valueFormat),h,d=!1,u=t??te(e.uid,"actionMode")??$.actionMode;if(te(e.uid,"filterBySelection")===!0)h=xs.None,d=!1;else if(i!==void 0)h=yv({actionMode:u,cursorRange:i,isRotated:s});else switch(u){case Nt.Zoom:A||o||c?h=xs.ZoomXY:h=s===!0?xs.ZoomY:xs.ZoomX,d=!1;break;case Nt.MultiSelection:case Nt.MultiSelectionWithCtrlKey:l?h=s===!0?xs.SelectY:xs.SelectX:h=xs.SelectXY,d=!0;break;case Nt.MonoSelection:h=xs.None,d=!0;break;case Nt.None:h=xs.None,d=!1;break}e instanceof ct&&e.get("cursor")!==void 0&&h!==void 0&&e.get("cursor")?.set("behavior",h),YQ({chart:e,enabled:d})}function ZQ(a,e){e!==void 0&&(e.width!==void 0&&a.set("width",Ub(e.width)),e.height!==void 0&&a.set("height",Ub(e.height)),e.paddingTop!==void 0&&a.set("paddingTop",e.paddingTop),e.paddingBottom!==void 0&&a.set("paddingBottom",e.paddingBottom))}function Vg(a){let{root:e,defaults:t,parent:i,id:s,index:r}=a,n=pe.new(e,{});return ZQ(n,t),i!==void 0&&i.children.insertIndex(r??i.children.length,n),s!==void 0&&n.set("id",s),n}function $g(a,e){e?a.hide():a.show()}function qQ(a,e){let t=Vg({root:a,defaults:$.headerContainer,parent:e,id:Qi(Ec,e.uid),index:0}),i=Vg({root:a,defaults:$.headerContainer,parent:e,id:Qi(hp,e.uid),index:1}),s=EA({root:a,parent:t,defaults:$.titleLabel,id:Qi(jB,t.uid)}),r=EA({root:a,parent:i,defaults:$.subtitleLabel,id:Qi(ZB,i.uid)});PA({chart:e,label:s,labelType:St.ChartTitle}),PA({chart:e,label:r,labelType:St.ChartSubTitle})}function Hw(a,e){let{title:t,subtitle:i}=e??{},s=yt({childId:Ec,parent:a});if(s!==void 0){let n=yt({childId:jB,parent:s});n!==void 0&&(Es({label:n,labelConfig:t,defaults:$.titleLabel}),Wr({chart:a,label:n,labelType:St.ChartTitle}),$g(s,n.get("disabled")===!0||(t?.content.text??"")===""))}let r=yt({childId:hp,parent:a});if(r!==void 0){let n=yt({childId:ZB,parent:r});n!==void 0&&(Es({label:n,labelConfig:i,defaults:$.subtitleLabel}),Wr({chart:a,label:n,labelType:St.ChartSubTitle}),$g(r,n.get("disabled")===!0||(i?.content.text??"")===""))}}function JQ(a){let{root:e}=a,t=Vg({root:e,defaults:$.footerContainer,parent:a,id:Qi(Pc,a.uid)}),i=EA({root:e,parent:t,id:Qi(qB,t.uid)});PA({chart:a,label:i,labelType:St.ChartFooter})}function Rw(a,e){let t=yt({childId:Pc,parent:a});if(t!==void 0){let i=yt({childId:qB,parent:t});i!==void 0&&(Es({label:i,labelConfig:e,defaults:$.footer}),Wr({chart:a,label:i,labelType:St.ChartFooter}),$g(t,i.get("disabled")||(e?.content.text??"")===""))}}function Ow(a){if(!(a instanceof cs)&&a instanceof ct){let{root:e}=a,t=Or.new(e,{orientation:"horizontal",visible:!1,marginTop:0}),i=Or.new(e,{orientation:"vertical",visible:!1});a.setAll({scrollbarX:t,scrollbarY:i})}}function ek(a,e){if(e!==void 0){let t=Ye(e),i=e[3]/255,s=i/2;[{element:a.get("background"),specificOpacity:s},{element:a.startGrip.get("background")},{element:a.endGrip.get("background")},{element:a.thumb}].forEach(r=>{let{element:n,specificOpacity:A}=r;n!==void 0&&n.setAll({fill:t.color,fillOpacity:A??i})}),[{element:a.get("background"),stateName:"default",specificOpacity:s},{element:a.startGrip.get("background"),stateName:"default"},{element:a.startGrip.get("background"),stateName:"hover"},{element:a.startGrip.get("background"),stateName:"down"},{element:a.endGrip.get("background"),stateName:"default"},{element:a.endGrip.get("background"),stateName:"hover"},{element:a.endGrip.get("background"),stateName:"down"},{element:a.thumb,stateName:"default"},{element:a.thumb,stateName:"hover"},{element:a.thumb,stateName:"down"}].forEach(r=>{let{element:n,stateName:A,specificOpacity:o}=r;(n?.states.lookup(A)??n?.states.create(A,{}))?.setAll({fill:t.color,fillOpacity:o??i})})}}function tk(a,e){typeof e=="number"&&Number.isFinite(e)&&(a.get("orientation")==="horizontal"?a.setAll({height:e,minHeight:e}):a.setAll({width:e,minWidth:e}))}function ik(a,e){if(typeof e=="number"&&Number.isFinite(e)){let t=e/30;a.startGrip.set("scale",t),a.endGrip.set("scale",t)}}function tB(a,e){typeof e=="number"&&Number.isFinite(e)&&(a.get("orientation")==="horizontal"?a.set("marginBottom",e):a.set("marginLeft",e),a.markDirtyBounds())}function Nw(a){let{chart:e,scrollbarXConfig:t,scrollbarYConfig:i}=a;if(!(e instanceof cs)&&e instanceof ct){let s=te(e.uid,"isRotated");(e.get("scrollbarX")===void 0||e.get("scrollbarY")===void 0)&&Ow(e);let r=e.get("scrollbarX"),n=e.get("scrollbarY");[r,n].forEach(A=>{if(A!==void 0){let o=A.get("orientation")==="horizontal"&&s!==!0||A.get("orientation")==="vertical"&&s===!0?t:i,l=o?.visible!==!0;if(Vt(A,!l),o!==void 0&&!l){let{width:c,color:h,gripSize:d,margin:u}=o;tB(A,u??c??$.scrollbarPadding),ek(A,h),ik(A,d),tk(A,c)}else tB(A,0)}})}}function sk(a){KB(a)}function iB(a){return a.get("legendDataItem")?.get("marker").children.getIndex(0)}function rk(a,e){a.columns.each(t=>{(t.dataItem?.dataContext)[e]===0&&t.set("strokeOpacity",0)})}function ak(a){let{root:e,chartConfig:t,seriesConfig:i,xAxis:s,yAxis:r,options:n,queryObject:A}=a,{id:o,name:l}=i,{xField:c,yField:h,xAxisField:d,yAxisField:u}=OA(t,i),g=c0(t),y=mt.new(e,{id:o,name:l,stacked:g,xAxis:s,yAxis:r,[d]:c,[u]:h,maskBullets:!1});pi(y.columns.template,n?.selectionTheme);let m=Ne.new({});return gi(y.uid,{bulletTemplate:m}),Br({element:y.columns.template,series:y,queryObject:A}),y.bullets.push(b=>{let B=Le.new(b,{},m);return ts.new(b,{sprite:B})}),y.columns.template.set("width",Re(100)),pp(y),rp(y,n?.tooltipFormatter),dw(y),VA(y,t),y.appear(),y}function nk(a){let{series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,chartSubType:r,colorMatch:n,rendererType:A}=a,o=e.root,l=Al(e),c=new Set,h,d,u=t.fillSymbol,g={root:o,seriesConfig:t,seriesIndex:i,seriesSymbol:u,isChartFillSymbol:!0},y={},m={},b=zd(i),B=Ge(e.uid,"bulletTemplate");if(B&&u?.style&&u.style!==Ir.Solid&&cn({root:o,element:B,fillSymbol:u,defaultToColorFromRamp:!0,colorRampIndex:i,isChartFillSymbol:!0,chartBackgroundColor:_B(e.chart)??[...$.backgroundColor]}),e.columns.length===0?y=Fs({root:o,seriesIndex:i,colorMatch:n,seriesSymbol:u??b,element:Le.new(o,{}),isChartFillSymbol:!0}):e.columns.each(w=>{let _=w.dataItem?.dataContext;if(Number.isFinite(_?.[l])){d=Dr({dataItem:_,seriesConfig:t,chartSubType:r,colorMatch:n,rendererType:A});let T=_[$.xAxisField]===$.nullValue,Q=(T&&t.nullCategory?.symbol!==void 0?t.nullCategory.symbol:u)??b;y=Fs({...g,seriesSymbol:Q,element:w,colorMatch:n,rendererSymbol:d}),kA(w,y.stylingInfo),T||(c.add(JSON.stringify(y.symbolWithColorInfo)),m=y)}}),s>1){let w=iB(e);if(w!==void 0)Fs({...g,seriesSymbol:u??b,element:w,colorMatch:n,rendererSymbol:d}),kA(w,m.stylingInfo);else if(e.chart instanceof ct){let _=e.chart.children.values.find(T=>T instanceof Hr);_!==void 0&&_.events.once(ot.BoundsChanged,()=>{kA(iB(e),m.stylingInfo)})}Fs({...g,seriesSymbol:m.symbolWithColorInfo??u??b,element:e,colorMatch:n,rendererSymbol:d,keepCurrentVisibility:!0}),Fs({...g,seriesSymbol:m.symbolWithColorInfo??u??b,element:e.columns.template,colorMatch:n,rendererSymbol:d})}return c.size<=1&&(h=m.symbolWithColorInfo??u),rk(e,l),h}function Ak(a){let{series:e,seriesSymbolMapForEvent:t,seriesIndexMapper:i,seriesIndex:s,colorMatch:r,rendererType:n}=a,A=a.seriesConfig,o=e.chart;if(o!==void 0){let l=te(o.uid,"config"),c=l?.series.length??0,h=bt(l?.series),d=nk({series:e,seriesConfig:A,seriesIndex:s,numberOfSeries:c,chartSubType:h,colorMatch:r,rendererType:n});t.set(i?.get(A.id)??s,d),t.size===c&&lr({data:t,htmlContainer:e.root.dom,chartId:o.get("id"),colorMatchApplied:$A(o)})}}function ok(a){let{columnSeries:e,data:t,seriesIndex:i,chartConfig:s,dataWasUpdated:r,seriesWereReinitialized:n,rotationChanged:A,stackedTypeChanged:o,timeZoneChanged:l,sortChanged:c,loaderHandle:h}=a,d=s.series[i];if(t&&d?.type===P.BarSeries&&(A===!0||r===!0||c===!0||o===!0||l||n===!0)){let{xField:u,yField:g,xAxisField:y,yAxisField:m}=OA(s,d);e.setAll({[y]:u,[m]:g}),e.events.once(ot.DataValidated,()=>{h.hideLoader()}),e.data.setAll(t.dataItems)}}function lk(a){let{series:e,data:t,chartConfig:i,options:s,seriesIndex:r,dataWasUpdated:n,rotationChanged:A,timeZoneChanged:o,queryObject:l,utilsStrings:c,seriesWereReinitialized:h,autoInverseDataLabelTextColor:d,fieldList:u,sortChanged:g,stackedTypeChanged:y,loaderHandle:m}=a,b=i.series[r],B=i.rotated,w=i.axes,_;w?.[1]&&(_=w[1]),e.set("id",b.id),pi(e.columns.template,s?.selectionTheme),dn(e.columns.template,t?.dataItems?.length),fp({series:e,chartConfig:i,isRotated:B}),sk({seriesType:P.BarSeries,series:e,seriesConfig:b,isRotated:B,dataLabelsConfig:b.dataLabels,autoInverseDataLabelTextColor:d,yAxisValueFormat:_?.valueFormat,externalDataLabelFormatter:s?.dataLabelFormatter}),ok({columnSeries:e,data:t,seriesIndex:r,chartConfig:i,dataWasUpdated:n,timeZoneChanged:o,seriesWereReinitialized:h,rotationChanged:A,stackedTypeChanged:y,sortChanged:g,loaderHandle:m}),op({series:e,seriesConfig:b,fieldList:u,queryObject:l,seriesIndex:r,tooltipFormatter:s?.tooltipFormatter,utilsStrings:c}),ba(a)&&Ba({styleCallback:Ak,callbackProps:a,series:e,seriesConfig:b}),gp({chartConfig:i,series:e,seriesIndex:r,queryObject:l})}function hk(a){let{chartConfig:e,seriesConfig:t}=a,i=os(e),s=e.showOutliers,r=e.standardizeValues,n=Cn(e),{y:A}=t,o=cu(e),l=bt(o.series),c=n?void 0:t?.query?.where,h={y:l===$e.BoxPlotMultiFieldsAndCategory&&typeof A=="string"?A:void 0,chartSubType:l,splitBy:c,showOutliers:s,standardizeValues:uh(l)?r:!1},d=Oc({chartConfig:e,seriesConfig:t,key:Ar.ThirdQuartile});return{properties:{...d.properties,low:CA({...h,key:Ar.Min}),open:CA({...h,key:Ar.FirstQuartile}),high:CA({...h,key:Ar.Max})},dataFields:{...d.dataFields,low:i?"lowValueXField":"lowValueYField",open:i?"openValueXField":"openValueYField",high:i?"highValueXField":"highValueYField"}}}function ck(a){let{candleStickSeries:e,data:t,rotationChanged:i,sortChanged:s,dataWasUpdated:r,seriesWereReinitialized:n,loaderHandle:A}=a;(i===!0||r===!0||s===!0||n===!0)&&(e.events.once(ot.DataValidated,()=>{A.hideLoader()}),e.data.setAll(t?.dataItems??[]))}function dk(a){let{candleStickSeries:e,seriesConfig:t,seriesIndex:i,chartSubType:s,colorMatch:r,showMean:n,rendererType:A}=a,{root:o}=e,l=t.fillSymbol??Xd(i),c={},h={root:o,seriesConfig:t,seriesIndex:i,colorMatch:r,isChartFillSymbol:!0};e.columns.length===0?c=Fs({...h,seriesSymbol:l,element:Le.new(o,{})}):e.columns.each(d=>{c=Fs({...h,seriesSymbol:l,element:d,rendererSymbol:n?void 0:Dr({dataItem:d.dataItem?.dataContext,seriesConfig:t,chartSubType:s,colorMatch:r,rendererType:A})})}),Fs({...h,seriesSymbol:c?.symbolWithColorInfo??l,element:e.columns.template,colorMatch:r})}function uk(a){let{candleStickSeries:e,seriesConfig:t,data:i,options:s}=a;pi(e.columns.template,s?.selectionTheme),dn(e.columns.template,i?.dataItems?.length),NA(e,t.name),ck(a),ba(a)&&Ba({styleCallback:dk,callbackProps:a,series:e,seriesConfig:t})}function fk(a){let{root:e,xAxis:t,yAxis:i,chartConfig:s,seriesIndex:r,options:n,queryObject:A}=a,o=s.series[r],l;if(o.type===P.BoxPlotSeries){let c=hk({chartConfig:s,seriesConfig:o});l=ds.new(e,{id:o.id,xAxis:t,yAxis:i,[c.dataFields.low]:c.properties.low,[c.dataFields.open]:c.properties.open,[c.dataFields.high]:c.properties.high,[c.dataFields.value]:c.properties.value,[c.dataFields.category]:c.properties.category}),l.columns.template.setAll({themeTags:[],width:Re(80)}),pi(l.columns.template,n?.selectionTheme),Br({element:l.columns.template,series:l,queryObject:A})}return l}function gk(a){let{chartConfig:e,seriesConfig:t}=a,i=bt(e.series),{showOutliers:s,standardizeValues:r}=e,{y:n}=t,A=t?.query?.where,o=cu(e),l=Oc({chartConfig:o,seriesConfig:t,key:Ar.Average}),c=CA({y:i===$e.BoxPlotMultiFieldsAndCategory&&typeof n=="string"?n:void 0,chartSubType:i,splitBy:A,showOutliers:s,standardizeValues:uh(i)?r:!1,key:Ar.Average});return l.properties.value=c,l}function pk(a){let{meanLineSeries:e,data:t,rotationChanged:i,sortChanged:s,dataWasUpdated:r,seriesWereReinitialized:n}=a;(i===!0||r===!0||s===!0||n===!0)&&e.data.setAll(t?.meanLines??[])}function mk(a){let{meanLineSeries:e,seriesConfig:t,data:i,dataWasUpdated:s,sortChanged:r,rotationChanged:n,seriesWereReinitialized:A,options:o}=a,l=Ge(e.uid,"bulletTemplate");l&&pi(l,o?.selectionTheme),dn(l,i?.meanLines?.length),NA(e,t?.name),pk({meanLineSeries:e,data:i,dataWasUpdated:s,sortChanged:r,rotationChanged:n,seriesWereReinitialized:A})}function yk(a){let{root:e,xAxis:t,yAxis:i,chartConfig:s,seriesIndex:r,options:n,queryObject:A}=a,o=s.series[r],l;if(o.type===P.LineSeries){let c=gk({chartConfig:s,seriesConfig:o});l=qe.new(e,{id:o.id,xAxis:t,yAxis:i,[c.dataFields.value]:c.properties.value,[c.dataFields.category]:c.properties.category}),l.appear();let h=Ne.new({});gi(l.uid,{isBoxPlotMeanLineSeries:!0,bulletTemplate:h}),pi(h,n?.selectionTheme),l.bullets.push(d=>{let u=Le.new(d,{},h),g=ts.new(d,{sprite:u});return l&&Br({element:u,series:l,queryObject:A}),g})}return l}function vk(a,e){return a.get("id")===`${e}_${li.Outliers}`}function xk(a){let{chartConfig:e,seriesConfig:t}=a;return Oc({chartConfig:e,seriesConfig:t,key:Ar.Outlier})}function bk(a){let{outlierSeries:e,data:t,rotationChanged:i,sortChanged:s,dataWasUpdated:r,seriesWereReinitialized:n}=a;(i===!0||r===!0||s===!0||n===!0)&&e.data.setAll(t?.outliers??[])}function Bk(a,e){return(a??$.boxPlot.boxPlotOutliersVisibility)&&e!==!1}function wk(a){let{outlierSeries:e,chartSubType:t,seriesConfig:i,colorMatch:s,showOutliers:r}=a;if(Ge(e.uid,"bulletTemplate")&&i.type===P.BoxPlotSeries){let A=i.fillSymbol,o={type:ht.SMS,style:ql.Circle,color:A?.color,size:$.boxPlot.boxPlotOutliersSize};e.dataItems.forEach(l=>{let c=l.bullets?.[0]?.get("sprite");if(c!==void 0){let h=Dr({dataItem:l.dataContext,seriesConfig:i,chartSubType:t,colorMatch:s});Fs({root:e.root,seriesSymbol:o,element:c,colorMatch:s,rendererSymbol:h})}})}let n=Bk(r,i.visible);Vt(e,n)}function Ck(a){let{outlierSeries:e,data:t,seriesConfig:i,sortChanged:s,dataWasUpdated:r,rotationChanged:n,seriesWereReinitialized:A,options:o}=a;if(e&&i.type===P.BoxPlotSeries){let l=Ge(e.uid,"bulletTemplate");l&&pi(l,o?.selectionTheme),dn(l,t?.outliers?.length),bk({outlierSeries:e,data:t,rotationChanged:n,sortChanged:s,dataWasUpdated:r,seriesWereReinitialized:A}),ba(a)&&Ba({styleCallback:wk,callbackProps:a,series:e,seriesConfig:i})}}function _k(a){let{root:e,xAxis:t,yAxis:i,chartConfig:s,seriesIndex:r,options:n,queryObject:A}=a,o=s.series[r],l;if(o.type===P.BoxPlotSeries){let c=xk({chartConfig:s,seriesConfig:o});l=qe.new(e,{id:`${o.id}_${li.Outliers}`,xAxis:t,yAxis:i,[c.dataFields.value]:c.properties.value,[c.dataFields.category]:c.properties.category}),l.strokes.template.set("forceHidden",!0);let h=Ne.new({});gi(l.uid,{isBoxPlotOutliersSeries:!0,bulletTemplate:h}),pi(h,n?.selectionTheme),l.bullets.push(d=>{let u=Le.new(d,{},h),g=ts.new(d,{sprite:u});return l&&Br({element:u,series:l,queryObject:A}),Lk({outlierSeries:l,bullet:g,seriesConfigId:o.id}),g}),l.appear()}return l}function Fk(a){let{chartConfig:e,seriesConfig:t,type:i}=a,s="";switch(i){case li.Top:s=Ar.Max;break;case li.Median:s=Ar.Median;break;case li.Bottom:s=Ar.Min;break}return Oc({chartConfig:e,seriesConfig:t,key:s})}function Sk(a){let{stepLineSeries:e,data:t,rotationChanged:i,sortChanged:s,dataWasUpdated:r,seriesWereReinitialized:n}=a;(i===!0||r===!0||s===!0||n===!0)&&e.data.setAll(t?.dataItems??[])}function Tk(a){let{stepLineSeries:e,data:t,seriesConfig:i,seriesIndex:s,colorMatch:r,chartSubType:n,rendererType:A}=a;if(i.type===P.BoxPlotSeries){let{root:o}=e,l=Tv({data:t.dataItems,colorMatch:r,chartSubType:n,rendererType:A}),c=(i.fillSymbol??Xd(s)).color,h={type:ht.SLS,width:$.boxPlot.boxPlotLineWidth,color:l?$.boxPlot.boxPlotWhiskersColor:c};Fs({root:o,seriesIndex:s,seriesSymbol:h,element:e,colorMatch:r})}}function Ik(a){let{stepLineSeries:e,data:t,seriesConfig:i,rotationChanged:s,sortChanged:r,dataWasUpdated:n,seriesWereReinitialized:A}=a,o=i.visible!==!1;e!==void 0&&i.type===P.BoxPlotSeries&&(Vt(e,o),ba(a)&&Ba({styleCallback:Tk,callbackProps:a,series:e,seriesConfig:i}),Sk({stepLineSeries:e,data:t,rotationChanged:s,sortChanged:r,dataWasUpdated:n,seriesWereReinitialized:A}))}function Dg(a){let{root:e,xAxis:t,yAxis:i,chartConfig:s,seriesIndex:r,type:n,options:A,queryObject:o}=a,l=s.series[r],c;if(l.type===P.BoxPlotSeries){let h=Fk({chartConfig:s,seriesConfig:l,type:n});c=mr.new(e,{id:`${l.id}_${n}`,xAxis:t,yAxis:i,noRisers:!0,[h.dataFields.value]:h.properties.value,[h.dataFields.category]:h.properties.category}),pi(c.strokes.template,A?.selectionTheme),Br({element:c.strokes.template,series:c,queryObject:o})}return c}function Oc(a){let{chartConfig:e,seriesConfig:t,key:i}=a,s=os(e),r=e.showOutliers,n=e.standardizeValues,A=Cn(e),o=bt(e.series),{x:l,y:c}=t,h=A?void 0:t?.query?.where,d={y:o===$e.BoxPlotMultiFieldsAndCategory&&typeof c=="string"?c:void 0,chartSubType:o,splitBy:h,showOutliers:r,standardizeValues:uh(o)?n:!1},u=o===$e.BoxPlotMonoField||o===$e.BoxPlotMultiFields||o===$e.BoxPlotMonoFieldAndSplitBy||o===$e.BoxPlotMultiFieldsAndSplitBy?Kd:l;return{dataFields:{value:s?"valueXField":"valueYField",category:s?"categoryYField":"categoryXField"},properties:{value:CA({key:i,...d}),category:u}}}function Dk(a,e){return a.series.values.find(t=>vk(t,e))}function Vw(a,e){let t=a.series.values.find(r=>r.get("id")===`${e}_${li.Top}`),i=a.series.values.find(r=>r.get("id")===`${e}_${li.Median}`),s=a.series.values.find(r=>r.get("id")===`${e}_${li.Bottom}`);return{topStepLineSeries:t,medianStepLineSeries:i,bottomStepLineSeries:s}}function $w(a){return a!==$e.BoxPlotMonoField&&a!==$e.BoxPlotMultiFields&&a!==$e.BoxPlotMonoFieldAndCategory}function Kw(a){let{chart:e,candleSeriesIndex:t,numberOfCandleStickSeries:i}=a,s,r,n=te(e.uid,"config");if(n){let A=os(n),o=Cn(n),l=A?e.yAxes.getIndex(0)?.get("renderer"):e.xAxes.getIndex(0)?.get("renderer"),c=l?.get("cellStartLocation"),h=l?.get("cellEndLocation");if(c&&h){let d=c/(o?1:n.series.length);s=c+t/i*(h-c)+d,r=c+(t+1)/i*(h-c)-d}}return{startLocation:s,endLocation:r}}function Lk(a){let{outlierSeries:e,bullet:t,seriesConfigId:i}=a;if(e){let{chart:s}=e;if(s){let r=te(s.uid,"config");if(r){let n=bt(r.series);if($w(n)){let A=s.series.values.filter(l=>l instanceof ds),o=A?.findIndex(l=>l.get("id")===i);if(o&&o!==-1&&A[o]){let{startLocation:l,endLocation:c}=Kw({chart:s,candleSeriesIndex:o,numberOfCandleStickSeries:A.length});l!==void 0&&c!==void 0&&t.set("locationX",(l+c)/2)}}}}}}function Uk(a){let e=te(a.uid,"config");if(e){let t=bt(e.series),i=e.series.length,s=os(e)?a.yAxes.getIndex(0)?.get("renderer"):a.xAxes.getIndex(0)?.get("renderer"),r=s?.get("cellStartLocation"),n=s?.get("cellEndLocation");if(r&&n){let A=a.series.values.filter(o=>o instanceof ds);A.forEach((o,l)=>{let{topStepLineSeries:c,medianStepLineSeries:h,bottomStepLineSeries:d}=Vw(a,o.get("id")??"");if($w(t)){let{startLocation:u,endLocation:g}=Kw({chart:a,candleSeriesIndex:l,numberOfCandleStickSeries:A.length});[c,h,d].forEach(y=>{y!==void 0&&(y.set("stepWidth",Re(60/i)),u&&g&&y.set("locationX",(u+g)/2))})}else[c,h,d].forEach(u=>{u!==void 0&&u.setAll({stepWidth:Re(60/i)})})})}}}function Qk(a){let{chartConfig:e,seriesIndex:t}=a,i=e.series[t],s=Oe([i]),r=[];if(s===P.BoxPlotSeries)[fk(a),Dg({...a,type:li.Top}),Dg({...a,type:li.Median}),Dg({...a,type:li.Bottom}),_k(a)].forEach(n=>{n&&r.push(n)});else if(s===P.LineSeries){let n=yk(a);n&&r.push(n)}return r}function kk(a){let{chart:e,chartConfig:t,series:i,seriesConfig:s}=a;if(e&&t)if(Uk(e),i instanceof ds&&s.type===P.BoxPlotSeries){i.set("id",s.id);let r=i.get("id")??"";uk({...a,series:i,seriesConfig:s,candleStickSeries:i});let{topStepLineSeries:n,medianStepLineSeries:A,bottomStepLineSeries:o}=Vw(e,r),l=[li.Top,li.Median,li.Bottom];[n,A,o].forEach((h,d)=>{h&&(h.set("id",`${s.id}_${l[d]}`),Ik({...a,stepLineSeries:h}))});let c=Dk(e,r);c&&(c.set("id",`${s.id}_${li.Outliers}`),Ck({...a,outlierSeries:c}))}else i instanceof qe&&s.type===P.LineSeries&&mk({...a,meanLineSeries:i})}function Gw(a){let{chart:e,chartData:t,chartConfig:i}=a;if(e&&t?.length>1&&i?.showMean===!0){let s=i.series[0].x??$.originalCategoryValue,r=te(e.uid,"boxPlotMeanLinesData");if(r!==void 0&&r.length>1){let n=[];for(let A of t){let o=r.find(l=>s in l&&l[s]===A[s]);o!==void 0&&n.push(o)}Pt(e.uid,{boxPlotMeanLinesData:n})}}}function Ek(a){KB(a)}function xp(a){let{isLineSmoothed:e,isRadarLineSeries:t,isRotated:i}=a,s=t?Bg:Gn;return e&&(s=t?bg:i?vg:yg),s}function Pk(a){let{series:e,seriesConfig:t,chartSubType:i,colorMatch:s,rendererType:r}=a,n;for(let A of e.dataItems){let o=A.dataContext;if(n=Dr({seriesConfig:t,dataItem:o,chartSubType:i,colorMatch:s,rendererType:r}),n!==void 0)break}return n}function Mk(a){let{series:e,seriesConfig:t,seriesIndex:i,chartSubType:s,colorMatch:r,rendererType:n}=a,A=e.root,o=Pk({series:e,seriesConfig:t,chartSubType:s,colorMatch:r,rendererType:n}),l=Fs({root:A,seriesIndex:i,seriesSymbol:t.lineSymbol??Gy(i),element:e,colorMatch:r,rendererSymbol:o});return Vt(e,t.visible),l.symbolWithColorInfo}function Hk(a){let{series:e,seriesIndex:t,chartSubType:i,seriesConfig:s,colorMatch:r,lineColor:n}=a,A=!1,o,l=Ge(e.uid,"bulletTemplate");if(l!==void 0){s.markerVisible!==!1&&s.visible!==!1?e.bulletsContainer.show():e.bulletsContainer.hide();let{markerSymbol:c}=s;c===void 0&&(c=Ky(),c.color=n),r?c.color=n:c.color??=n;let h=Dr({dataItem:e.dataItems[0]?.dataContext,seriesConfig:s,chartSubType:i,colorMatch:r});h&&h.outline&&(c.outline??=h.outline,c.outline.color=h.outline.color),MB({element:l,markerSymbol:c});let d=new Set,u;e.dataItems.forEach(g=>{let y=g.bullets?.[0]?.get("sprite");if(y!==void 0){let m=Dr({dataItem:g?.dataContext,seriesConfig:s,chartSubType:i,colorMatch:r}),b=Fs({root:e.root,seriesIndex:t,seriesSymbol:c,element:y,colorMatch:r,rendererSymbol:m});o=b.symbolWithColorInfo,u=b.stylingInfo,kA(y,u),d.add(JSON.stringify(u))}}),A=d.size>1}return A?void 0:o}function Rk(a,e){if(a.showArea===!0)if(a.areaColor!==void 0){let{color:t,opacity:i}=Ye(a.areaColor);e.set("fill",t),e.fills.template.setAll({fillOpacity:i,visible:!0})}else e.set("fill",e.get("stroke")),e.fills.template.setAll({fillOpacity:$.lineSeries.areaOpacity,visible:!0});else e.fills.template.set("visible",!1)}function Xw(a){let{series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,colorMatch:r,rendererType:n,chartSubType:A,seriesIndexMapper:o,seriesSymbolMapForEvent:l,isRotated:c}=a,h=e.root,d=e.chart;if(d){let u=e instanceof Xr;Vt(e,t.visible);let g=xp({isRadarLineSeries:u,isLineSmoothed:t.lineSmoothed,isRotated:c});e.set("curveFactory",g);let y=Mk({series:e,seriesConfig:t,seriesIndex:i,chartSubType:A,colorMatch:r,rendererType:n}),m=Hk({series:e,seriesConfig:t,seriesIndex:i,chartSubType:A,colorMatch:r,lineColor:y.color});l.set(o?.get(t.id)??i,{lineSymbol:y,markerSymbol:m}),Rk(t,e),l.size===s&&(lr({data:oi(l),htmlContainer:h.dom,chartId:e.chart?.get("id"),colorMatchApplied:$A(d)}),l.clear())}}function Ok(a){let{root:e,chartConfig:t,xAxis:i,yAxis:s,seriesConfig:r,options:n,queryObject:A}=a,{id:o,name:l}=r,{xField:c,yField:h,xAxisField:d,yAxisField:u}=OA(t,r),g=qe.new(e,{id:o,name:l,xAxis:i,yAxis:s,[d]:c,[u]:h,maskBullets:!1,curveFactory:xp({isRadarLineSeries:!1,isLineSmoothed:r.lineSmoothed,isRotated:t.rotated})});g.appear();let y=Ne.new({});return pi(y,n?.selectionTheme),gi(g.uid,{bulletTemplate:y}),g.bullets.push(m=>{let b=Le.new(m,{role:$.aria.defaultChartItemRole,ariaLabel:eu(),hoverOnFocus:!0,tooltip:RA({series:g,tooltipFormatter:n?.tooltipFormatter}),layer:$.zIndexes.bulletMarkers},y);return Br({element:b,series:g,queryObject:A}),Cw(b,g),ts.new(m,{sprite:b})}),pp(g),VA(g,t),g}function Nk(a){let{lineSeries:e,data:t,seriesIndex:i,chartConfig:s,dataWasUpdated:r,seriesWereReinitialized:n,rotationChanged:A,stackedTypeChanged:o,timeZoneChanged:l,sortChanged:c,loaderHandle:h}=a,d=s.series[i];if(t!==void 0&&i>=0&&i<s.series.length&&d.type===P.LineSeries&&(A===!0||r===!0||o===!0||l||n===!0||c===!0)){let{xField:u,yField:g,xAxisField:y,yAxisField:m}=OA(s,d);e.setAll({[y]:u,[m]:g}),e.events.once(ot.DataValidated,()=>{h.hideLoader()}),e.data.setAll(t.dataItems)}}function Vk(a){let{series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,colorMatch:r,rendererType:n,seriesIndexMapper:A,seriesSymbolMapForEvent:o}=a,{chart:l}=e;if(l!==void 0){let c=te(l.uid,"config"),h=te(l.uid,"isRotated")??!1,d=bt(c?.series);Xw({series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,colorMatch:r,chartSubType:d,rendererType:n,seriesIndexMapper:A,seriesSymbolMapForEvent:o,isRotated:h})}}function $k(a,e){let{connectLines:t,temporalBinning:i}=e,s=i?.nullPolicy;a.set("connect",t!==!1&&s!==Py.Null)}function Kk(a){let{series:e,data:t,chartConfig:i,options:s,seriesIndex:r,dataWasUpdated:n,queryObject:A,fieldList:o,utilsStrings:l,rotationChanged:c,seriesWereReinitialized:h,timeZoneChanged:d,sortChanged:u,stackedTypeChanged:g,loaderHandle:y}=a,m=i.series[r],b=i.rotated,B=i.axes,w;B?.[1]&&(w=B[1]),e.set("id",m.id);let _=Ge(e.uid,"bulletTemplate");_&&pi(_,s?.selectionTheme),dn(_,t?.dataItems?.length),fp({series:e,chartConfig:i,isRotated:b}),Ek({seriesType:P.LineSeries,series:e,seriesConfig:m,isRotated:b,dataLabelsConfig:m.dataLabels,yAxisValueFormat:w?.valueFormat,externalDataLabelFormatter:s?.dataLabelFormatter}),$k(e,m),Nk({lineSeries:e,seriesIndex:r,data:t,chartConfig:i,dataWasUpdated:n,rotationChanged:c,stackedTypeChanged:g,seriesWereReinitialized:h,timeZoneChanged:d,sortChanged:u,loaderHandle:y}),op({series:e,seriesConfig:m,fieldList:o,queryObject:A,seriesIndex:r,tooltipFormatter:s?.tooltipFormatter,utilsStrings:l}),ba(a)&&Ba({styleCallback:Vk,callbackProps:a,series:e,seriesConfig:m}),gp({chartConfig:i,series:e,seriesIndex:r,queryObject:A})}function Ww(a,e){let t=a.labels.template;t.adapters.remove("text"),t.adapters.remove("html");let i=e!==void 0?"html":"text";sl({label:t,labelOutputProp:i});let s=(r,n)=>{let A=r??"",o=Ge(a.uid,"pieChartDataLabelFormatter");if(o){let l=n.dataItem;if(l){let c=l?.get("valuePercentTotal"),h=l?.get("value"),d=l?.get("category")??r??"";A=o(d,h,c)}}return i==="html"?vs(A):A};t.adapters.add(i,(r,n)=>s(r,n)),a.labels.each(r=>{r.adapters.remove("text"),r.adapters.remove("html"),sl({label:r,labelOutputProp:i}),r.adapters.add(i,n=>s(n,r))})}function Gk(a){let e=a.dataItem?.component,t;if(e instanceof ni){let i=te(e.chart?.uid??Number.NaN,"config");if(i!==void 0&&i.series[0].type===P.PieSeries){let s=i.series[0].dataLabelsInside??$.pieChart.dataLabelsInside,r=Ye(i?.series[0].dataLabels?.content?.color).color,n=e.chart?.get("background")?.get("fill")??Ye($.backgroundColor).color,A=te(e.chart?.uid??Number.NaN,"options")?.autoInverseDataLabelTextColor??Ht.options.autoInverseDataLabelTextColor,o=a.dataItem?.dataContext?.[Ht.pieChart.technicalFieldSliceId],l=e.slices.values.find(h=>(h.dataItem?.dataContext)[Ht.pieChart.technicalFieldSliceId]===o)?.get("fill")??Ye(i.series[0].fillSymbol?.color).color,c=r??a.text.get("fill");t=c,c&&l&&A&&s&&(t=NB({textBackgroundColor:l,chartBackgroundColor:n}))}}return t}function Xk(a,e){let t=a.labels.template;t.set("cursorOverStyle","pointer"),t.setAll({cursorOverStyle:"pointer",maxWidth:$.pieChart.dataLabels.maxWidth??Number.NaN,oversizedBehavior:$.pieChart.dataLabels.wrap??!0?"wrap":"none",centerX:ye,centerY:ye}),Ww(a,e),t.adapters.add("fill",(i,s,r)=>Gk(s))}function Wk(a,e){let{numericValueFormat:t,percentValueFormat:i,displayNumericValueOnDataLabel:s,displayCategoryOnDataLabel:r,displayPercentageOnDataLabel:n,valuePrefix:A,valueSuffix:o,percentagePrefix:l,percentageSuffix:c,dataLabelsCharacterLimit:h}=e,{chart:d}=a,u;if(d){let g=np({pieChart:d,valueIntlOptions:t?.intlOptions,percentageIntlOptions:i?.intlOptions,displayNumericValue:s??$.pieChart.displayNumericValueOnDataLabel,displayPercentage:n??$.pieChart.displayPercentageOnDataLabel,valuePrefix:A,valueSuffix:o,percentagePrefix:l,percentageSuffix:c}),y=Zd(h),m=na(te(a.chart?.uid??Number.NaN,"rtl")??!1," ");u=(b,B,w)=>{let _=g(b,B,w),T=r??$.pieChart.displayCategoryOnDataLabel?y(b):"",Q=ii(T)?"":`${T}${m}`;return Q=`${Q}${_}`,e.dataLabels?.content!==void 0&&(Q=nr({textSymbol:{...e.dataLabels.content,text:Q},format:"amChartsV5",defaults:{...$.pieChart.dataLabels,wrap:e.optimizeDataLabelsOverlapping??$.pieChart.dataLabels.wrap}})),Q}}return u}function zk(a){let{pieSeries:e,seriesConfig:t,dataLabelFormatter:i}=a,{dataLabels:s}=t,r=t.dataLabelsOffset??$.pieChart.dataLabelsOffset,n=t.dataLabelsInside??$.pieChart.dataLabelsInside;Ww(e,i),gi(e.uid,{pieChartDataLabelFormatter:i??Wk(e,t)}),Es({label:e.labels.template,labelConfig:s,defaults:{...$.pieChart.dataLabels,wrap:t.optimizeDataLabelsOverlapping??$.pieChart.alignDataLabels}});let A=te(e.chart?.uid??0,"rtl"),o=!n&&(t.alignDataLabels??$.pieChart.alignDataLabels),l=t.optimizeDataLabelsOverlapping===!0;e.set("alignLabels",o),e.labels.template.setAll({forceHidden:!s?.visible,breakWords:l?!1:void 0,textAlign:A?"right":"left"});let c=e.labels.template.get("radius"),h=e.labels.template.get("baseRadius");n&&h!==Re(60)?e.labels.template.setAll({radius:void 0,baseRadius:Re(60),textType:"regular"}):!n&&!l&&!o&&(e.labels.template.setAll({baseRadius:se,textType:"adjusted"}),r!==void 0&&Number.isFinite(r)&&c!==r&&e.labels.template.set("radius",r))}var Lg;function Yk(a,e){let{ticks:t}=e,i=t?.visible===!1||e.dataLabelsInside===!0||e.dataLabels===void 0||e.dataLabels?.visible===!1||e.dataLabelsOffset!==void 0&&e.dataLabelsOffset<=0;a.ticks.template.setAll({visible:!i,crisp:!1});let s=t?.lineSymbol??ih({color:$d});i&&(s.width=0),vr({element:a.ticks.template,lineSymbol:s,visible:!i})}function jk(a){let{series:e,pieSlicesSymbols:t,seriesConfig:i}=a;e.slices.each((s,r)=>{let n=s.dataItem?.dataContext,A=ph({dataContext:n,pieSlicesSymbols:t,seriesConfig:i});cn({root:e.root,element:s,fillSymbol:A,defaultToColorFromRamp:!0,colorRampIndex:r,isChartFillSymbol:!0})})}function Zk(a,e){let t=new Map(a.map((i,s)=>[i.arcgis_charts_original_category_value,s]));return[...e].sort((i,s)=>(t.get(i.arcgis_charts_original_category_value)??1/0)-(t.get(s.arcgis_charts_original_category_value)??1/0))}function qk(a){let{series:e,data:t,seriesConfig:i,dataWasUpdated:s,sortChanged:r,seriesWereReinitialized:n,loaderHandle:A,labelUpdateNeeded:o,groupOfSlicesUpdateNeeded:l}=a,{x:c,y:h}=i,d=bt([i]),u=d===$e.PieFromFields?oo:c;if(t&&(s===!0||n===!0||r===!0||l===!0))e.setAll({categoryField:u,valueField:d===$e.PieFromFields?Bn:h}),e.events.once(ot.DataValidated,()=>{A.hideLoader()}),e.data.setAll(t.dataItems);else if(t&&o){let g=e.dataItems,y=g.map(b=>b.dataContext),m=Zk(y,t.dataItems);g.forEach((b,B)=>{let w=m[B];typeof w[u]=="string"&&b.set("category",w[u])}),e.markDirty()}}function Jk(a,e){let{innerRadius:t}=e;a.set("innerRadius",t?Re(t):0)}function eE(a,e){let{startAngle:t,endAngle:i}=e;a.setAll({startAngle:t??$.pieChart.min,endAngle:i??360+(a.get("startAngle")??0)})}function tE(a){let{root:e,seriesConfig:t,options:i,chart:s,queryObject:r}=a,{id:n,name:A,x:o,y:l}=t,c=bt([t]),h=ni.new(e,{id:n,name:A,categoryField:c===$e.PieFromFields?oo:o,valueField:c===$e.PieFromFields?Bn:l});return Xk(h,i?.dataLabelFormatter),Ap(h,i?.tooltipFormatter),h.slices.template.states.create("hover",{scale:1,stateAnimationDuration:0}),pi(h.slices.template,i?.selectionTheme),Br({element:h.slices.template,series:h,queryObject:r}),h.appear(),s instanceof Li&&zw(s,h),h}function iE(a){let{series:e,seriesConfig:t,seriesWereReinitialized:i,dataWasUpdated:s,sortChanged:r,data:n,options:A,loaderHandle:o,labelUpdateNeeded:l,utilsStrings:c,groupOfSlicesUpdateNeeded:h}=a,{dataLabelFormatter:d,tooltipFormatter:u}=A??{};e.set("id",t.id),pi(e.slices.template,A?.selectionTheme),qk({series:e,seriesConfig:t,seriesWereReinitialized:i,dataWasUpdated:s,sortChanged:r,data:n,loaderHandle:o,labelUpdateNeeded:l,groupOfSlicesUpdateNeeded:h}),ba(a)&&Ba({styleCallback:jk,callbackProps:a,series:e,seriesConfig:t}),zk({pieSeries:e,seriesConfig:t,dataLabelFormatter:d}),Jk(e,t),eE(e,t),Yk(e,t),ZD({series:e,seriesConfig:t,tooltipFormatter:u});let{chart:g}=e;g instanceof Li&&zw(g,e)}function zw(a,e){if(!a.isDisposed()){let t=a.radius();Pt(a.uid,{pieChartRadius:t});let i=()=>{let s=Re(te(a.uid,"pieChartRadius")??$.pieChart.chartOptimizedRadius),r=s,n=a.series?.values?.[0]??e,A=te(a.uid,"config");if(A!==void 0){let{series:o}=A,{innerRadius:l,optimizeDataLabelsOverlapping:c,alignDataLabels:h,dataLabelsOffset:d=$.pieChart.dataLabelsOffset,dataLabels:u,dataLabelsInside:g}=o[0];if(u?.visible===!0&&h===!0&&c===!0&&g!==!0){let y=$.pieChart.chartOptimizedRadius/100,m=500,b=150,B=.6,w=.5,_=1,T=a.seriesContainer.width()-d*2,Q=Math.max(T-b,0)/(m-b),U=Q<1?Math.max(Q**_*B,.4):Math.min(Q**w*B,y);r=Re(U*100)}else r=Re($.pieChart.chartRadius);s.value.toFixed(1)!==r.value.toFixed(1)&&(Pt(a.uid,{pieChartRadius:r.percent}),Lg&&clearTimeout(Lg),Lg=hn(()=>{let y=a.chartContainer.height();if(a.chartContainer.set("height",y+.1),a.set("radius",r),l&&!Number.isNaN(l)&&l>0){let m=(l??$.pieChart.innerRadius)*r.value;a.set("innerRadius",Re(m))}a.markDirty(),n.markDirty(),a.root.resize(),sE(a)})),n instanceof ni&&n.labels.template.setAll({maxWidth:rE({seriesConfig:A?.series[0],chart:a,newChartRadius:r})})}return r};a.events.onDebounced(ot.BoundsChanged,()=>i(),$.debounceTime),i()}}function sE(a){hn(()=>{a.chartContainer.set("height",Re(100)),a.root.resize()})}function rE(a){let{seriesConfig:e,chart:t,newChartRadius:i}=a,s=$.pieChart.dataLabels.maxWidth??100;if(e!=null){let{alignDataLabels:r,dataLabelsOffset:n=$.pieChart.dataLabelsOffset,optimizeDataLabelsOverlapping:A,dataLabels:o,dataLabelsInside:l}=e;if(o?.visible===!0&&r===!0&&l!==!0&&A===!0){let c=t.seriesContainer.width(),h=t.seriesContainer.height(),d=i.value*Math.min(c,h),u=5,g=Math.floor((c-d)/2)-u-n;s=Math.min(g,s-u);let y=$.pieChartDataLabel.minWidth;s<y&&(s=y)}}return s}function aE(a){let{root:e,chartConfig:t,xAxis:i,yAxis:s,seriesConfig:r,options:n,queryObject:A}=a,{id:o,name:l}=r,{xField:c,yField:h,xAxisField:d,yAxisField:u}=OA(t,r),g=Xr.new(e,{id:o,name:l,xAxis:i,yAxis:s,[d]:c,[u]:h,curveFactory:xp({isRadarLineSeries:!0,isLineSmoothed:r.lineSmoothed,isRotated:t.rotated}),layer:$.zIndexes.bulletMarkers});g.appear();let y=Ne.new({});return gi(g.uid,{bulletTemplate:y}),pi(y,n?.selectionTheme),g.bullets.push(m=>{let b=Le.new(m,{tooltip:RA({series:g,tooltipFormatter:n?.tooltipFormatter})},y);return Br({element:b,series:g,queryObject:A}),ts.new(m,{sprite:b})}),pp(g),VA(g,t),g}function nE(a){let{radarLineSeries:e,data:t,seriesIndex:i,chartConfig:s,dataWasUpdated:r,seriesWereReinitialized:n,stackedTypeChanged:A,timeZoneChanged:o,loaderHandle:l}=a,c=s.series[i];if(t!==void 0&&c?.type===P.RadarSeries&&(r||o||n||A)){let{xField:h,yField:d,xAxisField:u,yAxisField:g}=OA(s,c);e.setAll({[u]:h,[g]:d}),e.events.once(ot.DataValidated,()=>{l.hideLoader()}),e.data.setAll(t.dataItems)}}function AE(a){let{series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,colorMatch:r,rendererType:n,seriesIndexMapper:A,seriesSymbolMapForEvent:o}=a,{chart:l}=e;if(l!==void 0){let c=te(l.uid,"config"),h=te(l.uid,"isRotated")??!1,d=bt(c?.series);Xw({series:e,seriesConfig:t,seriesIndex:i,numberOfSeries:s,colorMatch:r,chartSubType:d,rendererType:n,seriesIndexMapper:A,seriesSymbolMapForEvent:o,isRotated:h})}}function oE(a){let{series:e,data:t,seriesWereReinitialized:i,chartConfig:s,options:r,seriesIndex:n,dataWasUpdated:A,timeZoneChanged:o,stackedTypeChanged:l,fieldList:c,queryObject:h,loaderHandle:d,utilsStrings:u}=a,g=s.series[n];e.set("id",g.id);let y=Ge(e.uid,"bulletTemplate");y&&pi(y,r?.selectionTheme),dn(y,t?.dataItems?.length),fp({series:e,chartConfig:s,isRotated:!1}),op({series:e,seriesConfig:g,fieldList:c,queryObject:h,seriesIndex:n,tooltipFormatter:r?.tooltipFormatter,utilsStrings:u}),ba(a)&&Ba({styleCallback:AE,callbackProps:a,series:e,seriesConfig:g}),gp({chartConfig:s,series:e,seriesIndex:n,queryObject:h}),nE({radarLineSeries:e,data:t,seriesIndex:n,chartConfig:s,dataWasUpdated:A,timeZoneChanged:o,stackedTypeChanged:l,seriesWereReinitialized:i,loaderHandle:d})}async function bp(a){let{chart:e,chartConfig:t,options:i,utilsStrings:s,queryObject:r}=a,{rotated:n}=t,{root:A}=e,o=Oe(t.series);e.series.clear();let l=[],c={root:A,chartConfig:t,options:i,chart:e,utilsStrings:s,queryObject:r},h=[];for(let d=0;d<t.series.length;d+=1){let u=t.series[d],{assignToSecondValueAxis:g,type:y}=u,m=e instanceof ct?PU({chart:e,chartType:o,rotated:n,assignToSecondValueAxis:g}):void 0,{xAxis:b,xAxisForHistogramOverlaySeries:B,yAxis:w}=m??{};switch(!0){case y===P.HeatSeries:{hr(r),b&&w&&h.push(uL({...c,queryObject:r,xAxis:b,yAxis:w}));break}case o===P.BoxPlotSeries:{b&&w&&Vs(t)&&h.push(...Qk({...c,xAxis:b,yAxis:w,seriesIndex:d,seriesConfig:t.series[d],chartConfig:t}));break}case y===P.HistogramSeries:{b&&w&&h.push(...xU({...c,seriesConfig:u,xAxis:b,xAxisForOverlaySeries:B,yAxis:w}));break}case y===P.PieSeries:{h.push(tE({...c,seriesConfig:u}));break}case(o===P.ComboLineAndBarSeries||o===P.BarSeries||o===P.LineSeries):{b&&w&&(y===P.BarSeries?h.push(ak({...c,seriesConfig:u,xAxis:b,yAxis:w})):y===P.LineSeries&&h.push(Ok({...c,seriesConfig:u,xAxis:b,yAxis:w})));break}case y===P.RadarSeries:{b&&w&&h.push(aE({...c,seriesConfig:u,xAxis:b,yAxis:w}));break}case y===P.ScatterSeries:{b&&w&&h.push(...iU({...c,seriesConfig:u,xAxis:b,yAxis:w}));break}}h=[...h,...await Promise.all(l)].flat()}h.forEach(d=>{d instanceof ss&&d.setPrivate("doNotUpdateLegend",!0)}),e.series.pushAll(h)}async function Nc(a){let{chart:e,chartConfig:t,options:i,data:s,seriesIndexMapper:r,dataWasUpdated:n,sortChanged:A,seriesWereReinitialized:o,rotationChanged:l,colorMatchChanged:c,stackedTypeChanged:h,seriesStyleChanged:d,timeZoneChanged:u,sizePolicyChanged:g,pieSlicesSymbols:y,queryObject:m,loaderHandle:b,utilsStrings:B,errorStrings:w,groupOfSlicesUpdateNeeded:_,labelUpdateNeeded:T}=a,{chartRenderer:Q}=t,{root:U}=e,{series:E}=t,O=Oe(t.series),D=bt(t.series),k=e.series.values,F=xA(t),M=t.series.length,Y=new Map,z=$s(m,i?.usePopupTemplateFieldsInfo),re=Ji(m),q=Ri(re)?void 0:uo(Q,re.renderer),Ae=o||n||A||l||h,X={root:U,chartConfig:t,queryObject:m,options:i,colorMatch:F,dataWasUpdated:n,sortChanged:A,seriesWereReinitialized:o,fieldList:z,rendererType:q,dataLabelFormatter:i?.dataLabelFormatter,utilsStrings:B,chartSubType:D,loaderHandle:b,autoInverseDataLabelTextColor:i?.autoInverseDataLabelTextColor??$.options.autoInverseDataLabelTextColor},G={...X,numberOfSeries:M,rotationChanged:l,colorMatchChanged:c,stackedTypeChanged:h,seriesStyleChanged:d,seriesIndexMapper:r,seriesSymbolMapForEvent:Y,timeZoneChanged:u};for(let ue=0;ue<E.length;ue++){let he=E[ue],ae=k[ue],Ie=he.type;switch(!0){case O===P.HeatSeries:{ae instanceof mt&&e instanceof ct&&Aa(t)&&mL({...G,series:ae,data:s,seriesConfig:t.series[ue],chartConfig:t});break}case O===P.BoxPlotSeries:{ae=k.find(Pe=>Pe.get("id")===he.id),e instanceof ct&&Vs(t)&&(ae instanceof ds||ae instanceof qe)&&(Ie===P.BoxPlotSeries||Ie===P.LineSeries)&&kk({...G,chart:e,series:ae,data:s,seriesIndex:ue,seriesConfig:he,chartConfig:t,showMean:Cn(t),showOutliers:co(t)});break}case Ie===P.HistogramSeries:{ae instanceof mt&&e instanceof ct&&hv(s)&&await CU({...G,series:ae,allChartSeries:k,data:s,seriesIndex:ue,seriesConfig:he,chartRenderer:Q,axes:t.axes});break}case Ie===P.PieSeries:{ae instanceof ni&&e instanceof Li&&gh(s)&&iE({...X,series:ae,seriesConfig:he,data:s,pieSlicesSymbols:y,groupOfSlicesUpdateNeeded:_,seriesStyleChanged:d,colorMatchChanged:c,labelUpdateNeeded:T});break}case(O===P.ComboLineAndBarSeries||O===P.BarSeries||O===P.LineSeries):e instanceof ct&&gh(s)&&(Ie===P.BarSeries&&ae instanceof mt?lk({...G,series:ae,data:s,seriesIndex:ue,seriesConfig:he}):Ie===P.LineSeries&&ae instanceof qe&&Kk({...G,series:ae,seriesIndex:ue,seriesConfig:he,data:s}));break;case Ie===P.ScatterSeries:{ae=JL(e);let Pe=pw(e);ae instanceof qe&&Pe instanceof qe&&cv(s)&&nU({...G,series:ae,seriesConfig:he,trendLineSeries:Pe,sizePolicyChanged:g,data:s});break}case Ie===P.RadarSeries:{ae instanceof Xr&&e instanceof cs&&gh(s)&&oE({...G,series:ae,data:s,seriesIndex:ue,seriesConfig:he,chartConfig:t});break}}Ae&&O&&ae&&lL({chartType:O,series:ae,tooltipFormatter:i?.tooltipFormatter})}await kU({chart:e,options:i,dataWasUpdated:n,data:s,chartConfig:t,queryObject:m,errorStrings:w})}function lE(a){let{chart:e,seriesConfig:t,utilsStrings:i,data:s}=a,r=e.series.getIndex(0),n;return r&&(n=zg({data:s,seriesConfig:t,utilsStrings:i}),r?.data.setAll(n)),n}function hE(a){let{chart:e,data:t,seriesConfig:i,utilsStrings:s}=a,r=e.series.getIndex(0),n;return r&&t&&"dataItems"in t&&(n=zg({data:t.dataItems,seriesConfig:i,utilsStrings:s}),r?.data.setAll(n)),n}function cE(a){xa(a)||a.dataItems.forEach(e=>{let t=e.bullets?.[0];if(t){let i=t.get("sprite"),s=Yr(i.uid,"selected")!==!0;Xi({element:i,selected:s})}})}function dE(a){a.columns.each(e=>{let t=Yr(e.uid,"selected")!==!0;Xi({element:e,selected:t})})}function uE(a){a.slices.each(e=>{let t=Yr(e.uid,"selected")!==!0;Xi({element:e,selected:t})})}async function fE(a,e){if(tp(a)){let t=te(a.uid,"actionMode");t!==Nt.MonoSelection&&t!==Nt.None&&(a.series.each(i=>{switch(!0){case i instanceof mt:dE(i);break;case i instanceof qe:cE(i);break;case i instanceof ni:uE(i);break}}),await up({chart:a,selectionSource:As.ProgrammaticSelection,queryObject:e}))}}function gE(a,e){let t=!1,i=a.series,s=e.series,r=Oe(s),n=(h,d)=>h.filter(u=>u.type===d).flatMap(u=>{let g=[];switch(d){case P.BarSeries:case P.HistogramSeries:g.push(u.fillSymbol);break;case P.LineSeries:case P.RadarSeries:g.push(u.lineSymbol,u.markerSymbol);break;case P.ScatterSeries:g.push(u.markerSymbol);break;case P.PieSeries:let y=u;y.slices?.forEach(m=>{g.push(m.fillSymbol)}),y.sliceGrouping&&g.push(y.sliceGrouping.fillSymbol);break}return(u.type===P.BarSeries||u.type===P.LineSeries||u.type===P.RadarSeries)&&u.nullCategory?.symbol!==void 0&&g.push(u.nullCategory.symbol),g}),A,o;r===P.ComboLineAndBarSeries?(A=n(i,P.BarSeries).concat(n(i,P.LineSeries)),o=n(s,P.BarSeries).concat(n(s,P.LineSeries))):(A=n(i,i[0].type),o=n(s,s[0].type));let l=!ra(A,o),c=!1;switch(r){case P.LineSeries:case P.RadarSeries:case P.ComboLineAndBarSeries:c=s.filter(h=>h.type===P.LineSeries||h.type===P.RadarSeries).some(h=>{let d=i.find(u=>u.id===h.id);return(h.showArea??$.lineSeries.showArea)!==(d?.showArea??$.lineSeries.showArea)||(h.lineSmoothed??$.lineSeries.lineSmoothed)!==(d?.lineSmoothed??$.lineSeries.lineSmoothed)||(h.markerVisible??$.lineSeries.markerVisible)!==(d?.markerVisible??$.lineSeries.markerVisible)||h.showArea&&!ra(h.areaColor,d?.areaColor)});break}return t=l||c,t}function pE(a){let{chartSeries:e,oldSeries:t,newSeries:i}=a,s=hu(t,i);for(let r=0;r<s.length;r+=1){let n=s[r][0],A=s[r][1],o=e.length;n>=0&&n<o&&A>=0&&A<o&&e.swap(s[r][0],s[r][1])}}function mE(){If(oD)}function yE(a){a.dispose()}async function vE(a,e){let{root:t}=a,{t9nLocale:i}=Zl(e??document.documentElement),s=yo(e??document.documentElement),r=await DD(i);t.locale=r,Pt(a.uid,{locale:i,formatLocale:s,rtl:Wl(e??document.documentElement)==="rtl"})}function Kg(a){let{chart:e,actionMode:t,cursorRange:i}=a;if(tp(e)){let s=t??te(e.uid,"actionMode")??$.actionMode;Pt(e.uid,{actionMode:s}),s===Nt.None&&Zn({chart:e,selectionSource:As.ClearSelection}),jQ({chart:e,actionMode:s,cursorRange:i})}}function xE(a){return ls.rootElements.find(e=>e.dom===a)?.dispose(),Rn.new(a)}function bE(a,e){a.container.children.clear();let t=Oe(e?.series),i;switch(t){case P.RadarSeries:case P.GaugeSeries:i=cs;break;case P.PieSeries:i=Li;break;default:i=ct;break}return a.container.children.push(i.new(a,{id:`${e?.id}`,layout:a.verticalLayout,paddingBottom:$.chartPadding,paddingTop:$.chartPadding,paddingRight:$.chartPadding,paddingLeft:$.chartPadding}))}async function BE(a){let{chart:e,chartConfig:t,data:i,dataWasUpdated:s,sortChanged:r,slicesConfigChangedSinceLastUpdate:n,chartRendererChanged:A,colorMatchChanged:o,options:l,queryObject:c,loaderHandle:h,utilsStrings:d,errorStrings:u,groupOfSlicesUpdateNeeded:g,seriesConfig:y,seriesStyleChanged:m}=a,b=i,B=!1;if(e&&(s||g)){let Q=hE({chart:e,data:i,seriesConfig:y,utilsStrings:d});Q!==void 0&&(Fn({arrayToSort:Q,chartConfig:t}),B=!0,b={dataItems:Q})}let w=s||n||A||o,_=rl({chartData:b&&"dataItems"in b?b.dataItems:void 0,chartConfig:t,queryObject:c,labelUpdateNeeded:w,usePopupTemplateFieldsInfo:l?.usePopupTemplateFieldsInfo,utilsStrings:d}),T=b&&"dataItems"in b?b.dataItems:[];xo({data:T,newChartConfig:t,pieSlicesSymbols:_}),await Nc({chart:e,chartConfig:t,options:l,data:b,dataWasUpdated:s,sortChanged:r,queryObject:c,pieSlicesSymbols:_,loaderHandle:h,utilsStrings:d,errorStrings:u,groupOfSlicesUpdateNeeded:g,seriesStyleChanged:m,colorMatchChanged:o,labelUpdateNeeded:w}),Lr({data:b,seriesConfig:y,htmlContainer:e.root.dom}),lr({data:_,htmlContainer:e.root.dom,chartId:e.get("id"),colorMatchApplied:$A(e)}),B&&Pt(e.uid,{data:b})}async function wE(a){let{chart:e,chartConfig:t,data:i,anyGuideAboveChanged:s,dataWasUpdated:r,dataUpdateDetails:n,seriesIndexMapper:A,seriesFilteredOut:o,sortChanged:l,options:c,queryObject:h,rotationChanged:d,colorMatchChanged:u,stackedTypeChanged:g,heatChartHideEmptyRowsAndColumnsChanged:y,seriesStyleChanged:m,timeZoneChanged:b,timeIntervalInfoWasReset:B,sizePolicyChanged:w,sizePolicyChangesRequireSeriesReinit:_,loaderHandle:T,utilsStrings:Q,errorStrings:U}=a,{axisLabelsBehaviorChanged:E}=a,O=zU({chart:e,chartConfig:t,rotationChanged:d,axisLabelsBehaviorChanged:E,timeIntervalInfoWasReset:B}),D=O||MU({chartSeriesLength:e.series.length,chartConfig:t,dataUpdateDetails:n,seriesFilteredOut:o,sizePolicyChangesRequireSeriesReinit:_});O&&(Uw({chart:e,chartConfig:t,errorStrings:U}),E=[!0,!0]),D&&(e.series.clear(),await bp({chart:e,chartConfig:t,options:c,utilsStrings:Q,queryObject:h}),e.gridContainer?.toBack?.()),await Qw({chart:e,chartConfig:t,queryObject:h,data:i,dataWasUpdated:r,axesInitializationNeeded:O,heatChartHideEmptyRowsAndColumnsChanged:y,sortChanged:l,timeIntervalInfo:i?.timeIntervalInfo??te(e.uid,"timeIntervalInfo"),axisLabelsBehaviorChanged:E,anyGuideAboveChanged:s,xAxisLabelFormatter:c?.xAxisLabelFormatter,yAxisLabelFormatter:c?.yAxisLabelFormatter,secondaryYAxisLabelFormatter:c?.secondaryYAxisLabelFormatter,guideTooltipFormatter:c?.guideTooltipFormatter,gaugeInnerLabelFormatter:c?.gaugeInnerLabelFormatter,utilsStrings:Q,errorStrings:U}),await Nc({chart:e,chartConfig:t,options:c,data:i,dataWasUpdated:r,sortChanged:l,seriesIndexMapper:A,seriesWereReinitialized:D,rotationChanged:d,colorMatchChanged:u,stackedTypeChanged:g,seriesStyleChanged:m,timeZoneChanged:b,sizePolicyChanged:w,queryObject:h,loaderHandle:T,utilsStrings:Q,errorStrings:U}),Oe(t.series)===P.HeatSeries&&ew(e),Nw({chart:e,scrollbarXConfig:t.axes?.[0]?.scrollbar,scrollbarYConfig:t.axes?.[1]?.scrollbar})}async function CE(a){let{chart:e,legend:t,loaderHandle:i,updateProps:s}=a,{newChartConfig:r,updateOptions:n,dataWasUpdated:A,dataUpdateDetails:o,hasSeriesFilteredOut:l,colorMatchApplied:c,rendererFieldNames:h,configWithAllSeries:d,t9nStrings:u,queryObject:g,dataInfo:y}=s,{utilsStrings:m,errorStrings:b}=u,{root:B}=e,{usePopupTemplateFieldsInfo:w}=n??{};if(r===void 0)throw new Error;let _=r,T=te(e.uid,"config");if(e.isDisposed()||!Jd(T,_))throw new oa(bA.ChartDisposed);T??=_,Pt(e.uid,{queryObject:g});let Q=bt(_.series),U=os(_);Pt(e.uid,{config:oi(_),options:n,isNonAggregatedChart:!ho(Q),isRotated:U,filterBySelection:n?.filterBySelection,colorMatchApplied:c,rendererFieldNames:h});let E=$s(g,w),O=Y0(T,_),D=yu(T,_),k=pu(T,_),F=O0(T,_),M=gE(T,_),Y=ch(T,_),z=q0(T,_),re=mu(T,_),q=J0(T,_),Ae=ev(T,_),X=rh({oldConfig:l?d:T,newConfig:_,dataWasUpdated:A}),G=!1,ue=!1,he=!1,ae=!1;Aa(T)&&Aa(r)&&(G=K0(T,r),ue=V0(T,r),he=N0(T,r)||$0(T,r)||G,ae=R0(T,r));let Ie=Od({oldConfig:T,newConfig:_,rotationChanged:D}),Pe=T.series,De=_.series;if(A){let{data:I,queryConfig:le,count:ne}=y??{};Pt(e.uid,{fieldList:E,queryConfig:le,elementCount:ne,boxPlotMeanLinesData:I!==void 0&&"meanLines"in I?I.meanLines:void 0,timeIntervalInfo:I!==void 0&&"timeIntervalInfo"in I?I.timeIntervalInfo:void 0}),Lr({data:I,seriesConfig:_.series,htmlContainer:B.dom}),Sn(B.dom)}e instanceof Fi&&pE({chartSeries:e.series,oldSeries:Pe,newSeries:De});let Qe=y?.data??te(e.uid,"data"),dt=cr(Qe),Me=e instanceof Li?_u(Pe,De):!1;(X||Me)&&(Fn({arrayToSort:dt,chartConfig:_,fieldList:E,isTimeBinningSeries:po({seriesConfig:oh(r),xAxisValueFormatType:eh(r),setTimeBinningInfoWhenNotProvided:n?.setTimeBinningInfoWhenNotProvided,queryObject:g})}),Vs(_)&&Gw({chart:e,chartData:A?dt:Qe,chartConfig:_}),Pt(e.uid,{fieldList:E}),Qe&&"dataItems"in Qe&&(Qe.dataItems=dt)),(A||X)&&Lr({data:Qe,seriesConfig:_.series,htmlContainer:B.dom});let mi=hh({oldConfig:T,newConfig:_}),$t=new Map;switch(_.series.forEach((I,le)=>{$t.set(I.id,le)}),Pt(e.uid,{data:Qe}),kw(e,_.background),Hw(e,{title:_.title,subtitle:_.subtitle}),Rw(e,_.footer),Mw({root:B,chart:e,cursorCrosshair:_.cursorCrosshair,config:_,queryObject:g}),Oe(_.series)){case P.PieSeries:{e instanceof Li&&(hr(g),await BE({chart:e,chartConfig:_,options:n,data:Qe,dataWasUpdated:A,slicesConfigChangedSinceLastUpdate:mi,chartRendererChanged:Y,sortChanged:X,queryObject:g,seriesConfig:_.series,loaderHandle:i,colorMatchChanged:k,utilsStrings:m,errorStrings:b,groupOfSlicesUpdateNeeded:Me,seriesStyleChanged:M}));break}case P.HeatSeries:case P.BarSeries:case P.LineSeries:case P.ComboLineAndBarSeries:case P.ScatterSeries:case P.RadarSeries:case P.GaugeSeries:case P.HistogramSeries:case P.BoxPlotSeries:e instanceof ct&&await wE({chart:e,chartConfig:_,options:n,data:Qe,dataWasUpdated:A,seriesIndexMapper:$t,dataUpdateDetails:o,seriesFilteredOut:l,heatChartHideEmptyRowsAndColumnsChanged:ae,sortChanged:X,axisLabelsBehaviorChanged:Ie,anyGuideAboveChanged:O,rotationChanged:D,colorMatchChanged:k,stackedTypeChanged:F,seriesStyleChanged:M,timeZoneChanged:z,timeIntervalInfoWasReset:re,sizePolicyChanged:q,sizePolicyChangesRequireSeriesReinit:Ae,queryObject:g,loaderHandle:i,utilsStrings:m,errorStrings:b});break}e instanceof Fi&&gw({chart:e,chartConfig:_,legend:t,hideEmptySeries:n?.hideEmptySeries,seriesConfig:_.series,heatChartLegendUpdatedNeeded:he,heatRulesTypeChanged:G,heatLegendPositionChanged:ue,queryObject:g}),Kg({chart:e,actionMode:n?.actionMode,cursorRange:n?.cursorRange})}async function _E(a){let{chart:e,data:t,chartConfig:i,options:s,queryObject:r,loaderHandle:n,utilsStrings:A,errorStrings:o}=a;await bp({chart:e,chartConfig:i,options:s,utilsStrings:A,queryObject:r});let l=t,c=!1,h=i.series;if(e){let g=t&&"dataItems"in t?t.dataItems:[],y=lE({chart:e,data:g,seriesConfig:h,utilsStrings:A});y!==void 0&&(c=!0,l={dataItems:y})}let d=rl({chartData:l?.dataItems,chartConfig:i,queryObject:r,labelUpdateNeeded:!0,usePopupTemplateFieldsInfo:s?.usePopupTemplateFieldsInfo,utilsStrings:A}),u=l&&"dataItems"in l?l.dataItems:[];xo({data:u,newChartConfig:i,pieSlicesSymbols:d}),await Nc({chart:e,chartConfig:i,options:s,data:l,dataWasUpdated:!0,pieSlicesSymbols:d,queryObject:r,loaderHandle:n,utilsStrings:A,errorStrings:o}),Lr({data:l,seriesConfig:h,htmlContainer:e.root.dom}),lr({data:d,htmlContainer:e.root.dom,chartId:e.get("id"),colorMatchApplied:$A(e)}),c&&Pt(e.uid,{data:l})}async function FE(a){let{chart:e,data:t,chartConfig:i,options:s,queryObject:r,loaderHandle:n,seriesIndexMapper:A,utilsStrings:o,errorStrings:l}=a;Ow(e),Nw({chart:e,scrollbarXConfig:i.axes?.[0]?.scrollbar,scrollbarYConfig:i.axes?.[1]?.scrollbar}),Uw({chart:e,chartConfig:i,errorStrings:l}),await Qw({chart:e,chartConfig:i,queryObject:r,axisLabelsBehaviorChanged:[!0,!0],data:t,dataWasUpdated:!0,timeIntervalInfo:t?.timeIntervalInfo,xAxisLabelFormatter:s?.xAxisLabelFormatter,yAxisLabelFormatter:s?.yAxisLabelFormatter,secondaryYAxisLabelFormatter:s?.secondaryYAxisLabelFormatter,guideTooltipFormatter:s?.guideTooltipFormatter,gaugeInnerLabelFormatter:s?.gaugeInnerLabelFormatter,utilsStrings:o,errorStrings:l}),await bp({chart:e,chartConfig:i,options:s,utilsStrings:o,queryObject:r}),e.gridContainer?.toBack?.(),await Nc({chart:e,chartConfig:i,seriesIndexMapper:A,options:s,data:t,dataWasUpdated:!0,timeZoneChanged:!0,queryObject:r,loaderHandle:n,utilsStrings:o,errorStrings:l}),Oe(i.series)===P.HeatSeries&&ew(e)}async function SE(a){let{chartContainer:e,chartConfig:t,options:i,colorMatchApplied:s,rendererFieldNames:r,globalOptions:n,t9nStrings:A,queryObject:o,dataInfo:l,loaderHandle:c}=a,{errorStrings:h,utilsStrings:d}=A,{data:u,queryConfig:g,count:y}=l??{};mE();let m=t,b=xE(e);gD(b,n?.enableResponsiveFeatures);let B=bE(b,m);await vE(B,e);let w;if(pD(b,n?.useAnimatedCharts),!B.isDisposed()){let T=bt(m.series),Q=os(m);Pt(B.uid,{options:i,filterBySelection:i?.filterBySelection,config:m,queryObject:o,isNonAggregatedChart:!ho(T),isRotated:Q,colorMatchApplied:s,rendererFieldNames:r}),Pw({root:b,chart:B,config:m,queryObject:o}),Mw({root:b,chart:B,cursorCrosshair:m.cursorCrosshair,config:m,queryObject:o});let{title:U,subtitle:E,footer:O}=m;qQ(b,B),Hw(B,{title:U,subtitle:E}),JQ(B),Rw(B,O),WQ(b,B),kw(B,m.background);let D=$s(o,i?.usePopupTemplateFieldsInfo);Pt(B.uid,{fieldList:D}),Pt(B.uid,{options:i,queryConfig:g,elementCount:y,boxPlotMeanLinesData:u!==void 0&&"meanLines"in u?u.meanLines:void 0,timeIntervalInfo:u!==void 0&&"timeIntervalInfo"in u?u.timeIntervalInfo:void 0});let k=new Map;m.series.forEach((M,Y)=>{k.set(M.id,Y)});let F=cr(u);Pt(B.uid,{queryConfig:g,elementCount:y,data:u}),Vs(m)&&T!==$e.BoxPlotMonoField&&T!==$e.BoxPlotMonoFieldAndSplitBy&&(Fn({arrayToSort:F,chartConfig:m,fieldList:D}),Gw({chart:B,chartData:F,chartConfig:m})),Lr({data:u,seriesConfig:m.series,htmlContainer:e}),B instanceof ct?await FE({chart:B,data:{...u,dataItems:F,meanLines:te(B.uid,"boxPlotMeanLinesData")},chartConfig:m,options:i,queryObject:o,loaderHandle:c,utilsStrings:d,errorStrings:h}):B instanceof Li&&u&&"dataItems"in u&&(hr(o),await _E({chart:B,data:u,chartConfig:m,options:i,queryObject:o,loaderHandle:c,utilsStrings:d,errorStrings:h})),B instanceof Fi&&(w=Ob(B,m),gw({chart:B,chartConfig:m,legend:w,hideEmptySeries:i?.hideEmptySeries,seriesConfig:m.series,queryObject:o})),Kg({chart:B,actionMode:i?.actionMode,cursorRange:i?.cursorRange}),oU(B),Sn(b.dom)}function _(){oQ(B)}return{update:async T=>{w===void 0&&(w=Ob(B,T.newChartConfig)),await CE({chart:B,legend:w,loaderHandle:c,updateProps:T})},dispose:()=>yE(b),resetZoom:_,clearSelection:()=>Zn({chart:B}),switchSelection:async()=>await fE(B,o),exportImage:async T=>await ED({root:b,exportOptions:T}),setActionMode:(T,Q)=>Kg({chart:B,actionMode:T,cursorRange:Q}),loaderHandle:c}}function TE(a,e){let t;switch(a){case P.PieSeries:t=e?.placeholders.pieChartCreateMsg;break;case P.BarSeries:t=e?.placeholders.barChartCreateMsg;break;case P.BoxPlotSeries:t=e?.placeholders.boxPlotCreateMsg;break;case P.LineSeries:t=e?.placeholders.lineChartCreateMsg;break;case P.HistogramSeries:t=e?.placeholders.histogramCreateMsg;break;case P.ScatterSeries:t=e?.placeholders.scatterplotCreateMsg;break;case P.HeatSeries:t=e?.placeholders.calendarHeatChartCreateMsg;break;case P.ComboLineAndBarSeries:t=e?.placeholders.comboBarLineChartCreateMsg;break;case P.RadarSeries:t=e?.placeholders.radarChartCreateMsg;break;case P.GaugeSeries:t=e?.placeholders.gaugeCreateMsg;break}return t}function wc(a){let e;if(a){let t=FB(a);t&&(e=[t.r,t.g,t.b,255])}return e}function Gg(a){return by(a)==="dark"}function Yw(a){let e=window.getComputedStyle(a);return{backgroundColor:wc(e.getPropertyValue("--calcite-color-foreground-1")),textColor:wc(e.getPropertyValue("--calcite-color-text-1")),lineColor:wc(e.getPropertyValue("--calcite-color-border-1")),secondLineColor:wc(e.getPropertyValue("--calcite-color-text-3"))}}function IE(a,e){a?.axes?.forEach(t=>{t?.title?.content&&e.textColor&&(t.title.content.color=e.textColor),t?.labels?.content&&e.textColor&&(t.labels.content.color=e.textColor),t?.grid&&e.lineColor&&(t.grid.color=e.lineColor),t?.lineSymbol&&e.lineColor&&(t.lineSymbol.color=e.lineColor),t?.guides?.forEach(i=>{i.label&&e.textColor&&(i.label.color=e.textColor),e.lineColor&&(i.style?.type===ht.SLS?i.style.color=e.lineColor:i.style?.type===ht.SFS&&i.style?.outline&&(i.style.outline.color=e.lineColor))})})}function DE(a,e){a&&e.backgroundColor&&(a.background=e.backgroundColor)}function LE(a,e){a?.title?.content&&e.textColor&&(a.title.content.color=e.textColor),a?.subtitle?.content&&e.textColor&&(a.subtitle.content.color=e.textColor),a?.footer?.content&&e.textColor&&(a.footer.content.color=e.textColor)}function el(a,e){e?.created&&e?.visible&&(e.symbol={type:ht.SLS,...e.symbol,color:a})}function sB(a){let{configElementWithFillSymbol:e,markerColor:t,lineColor:i}=a;e.markerSymbol={type:ht.SMS,...e.markerSymbol,color:t},e.markerSymbol.outline={type:ht.SLS,...e.markerSymbol.outline,color:i}}function Cc(a){let{configElementWithFillSymbol:e,fillColor:t,lineColor:i}=a;e.fillSymbol={type:ht.SFS,...e.fillSymbol,color:t},i&&(e.fillSymbol.outline={type:ht.SLS,...e.fillSymbol.outline,color:i})}function jw(a,e){a&&(a.colorMatch=!1,a.series.forEach((t,i)=>{t.dataLabels?.content&&e.textColor&&(t.dataLabels.content.color=e.textColor);let s=lo[i%lo.length];switch(t.type){case P.BarSeries:Cc({configElementWithFillSymbol:t,fillColor:s,lineColor:e.lineColor});break;case P.HistogramSeries:Cc({configElementWithFillSymbol:t,fillColor:s,lineColor:e.lineColor}),el(mA[0],t.overlays?.standardDeviation),el(mA[1],t.overlays?.mean),el(mA[2],t.overlays?.median),el(mA[3],t.overlays?.comparisonDistribution);break;case P.LineSeries:case P.RadarSeries:t.lineSymbol={type:ht.SLS,...t.lineSymbol,color:s},sB({configElementWithFillSymbol:t,markerColor:s,lineColor:e.lineColor}),t.areaColor=[s[0],s[1],s[2],255*Te.lineSeries.areaOpacity];break;case P.BoxPlotSeries:Cc({configElementWithFillSymbol:t,fillColor:s,lineColor:e.lineColor});break;case P.PieSeries:t.slices?.forEach((r,n)=>{Cc({configElementWithFillSymbol:r,fillColor:lo[n%lo.length],lineColor:e.lineColor})});break;case P.ScatterSeries:sB({configElementWithFillSymbol:t,markerColor:s,lineColor:e.lineColor}),el(mA[1],t.overlays?.trendLine);break;case P.HeatSeries:case P.GaugeSeries:}}))}function UE(a,e){if(a?.series[0].type===P.PieSeries){let t=a.series[0];t.ticks?.lineSymbol&&e.secondLineColor&&(t.ticks.lineSymbol.color=e.secondLineColor)}}function QE(a,e){a?.legend&&(a.legend.title?.content&&e.textColor&&(a.legend.title.content.color=e.textColor),a.legend.body&&e.textColor&&(a.legend.body.color=e.textColor))}function kE(a,e){a?.series[0].type===P.GaugeSeries&&a.axes?.forEach(t=>{t.innerLabel?.content&&e.textColor&&(t.innerLabel.content.color=e.textColor),t.needle?.symbol&&e.textColor&&(t.needle.symbol.color=e.textColor)})}function EE(a,e){a?.series[0].type===P.HeatSeries&&a.series.forEach(t=>{t.gridLine&&e.textColor&&(t.gridLine.color=e.textColor)})}function PE(a){let{chartElement:e,options:t,calciteThemeApplied:i}=a,s=t;return i==="dark"&&(s.selectionTheme={...Ht.selectionTheme,selectedElementsTheme:{...Ht.selectionTheme.selectedElementsTheme,elementOutlineColor:[55,255,255,255]}},s.chartWillRender=async r=>{let{chartConfig:n,slices:A}=r,o=oi(n);if(e.chartWillRender&&(o=await e.chartWillRender(r)),o.series[0].type===P.PieSeries&&!o.series[0].slices){let l=Yw(e);o.series[0].slices=A,jw(o,l)}return o}),s}function ME(a,e){let t=oi(e);if(t&&Gg(a)){let i=Yw(a);DE(t,i),LE(t,i),IE(t,i),jw(t,i),QE(t,i),kE(t,i),UE(t,i),EE(t,i)}return t}function HE(){return!0}function rB(a){let{layer:e}=a,t,i=Ji(e),s=Ah(i);return s!==void 0&&"definitionExpression"in s&&a.layerFilterChangePolicy===Ih.Refresh&&(t=us.watch(()=>s.definitionExpression,()=>{a.refresh({updateData:!0,resetAxesBounds:!0})})),t}function aB(a){let{layer:e,model:t}=a,i=ha(t)?t.config:t,s;if(e!==void 0&&a.layerRendererChangePolicy===Dh.Refresh){let r=Ji(e);s=us.watch(()=>r.renderer,()=>{if(xA(i)){let n=HE();a.refresh({updateData:n})}})}return s}async function RE(a){let{view:e,layer:t,model:i,filterByExtent:s}=a,r=ha(i)?i.config:i,n;if(e!==void 0&&r!==void 0){let A=await uu({chartConfig:r,view:e,layer:t,filterByExtent:s}),o;if(Ma(A)?o=A:Ri(A)&&(o=await e.whenLayerView(A)),o){await us.whenOnce(()=>!o.updating);let l=async()=>{a.filterByExtent&&e.stationary&&(o.updating&&await us.whenOnce(()=>!o.updating),await a.refresh({updateData:!0,resetAxesBounds:!0}))};n=[],Ma(o)?(n.push(us.when(()=>e.stationary,l)),n.push(us.when(()=>!o.dataUpdating,l))):n.push(us.when(()=>e.stationary,l)),await l()}}return n}function OE(a){let{view:e,model:t}=a,i=ha(t)?t.config:t,s=Oe(i?.series),r;return e!==void 0&&a.viewTimeExtentChangePolicy===So.Refresh&&s!==P.HistogramSeries&&(r=us.watch(()=>e.timeExtent,()=>{a.refresh({updateData:!0})})),r}function NE(a){let{view:e}=a,t;return e&&"timeZone"in e&&(t=us.watch(()=>e.timeZone,()=>{let{model:i}=a,s=ha(i)?i.config:i;Aa(s)&&a.refresh({updateData:!0})})),t}function nB(a){let{layer:e}=a,t,i=Ji(e),s=Ah(i);return s!==void 0&&"fields"in s&&a.layerFieldsChangePolicy===Lh.Refresh&&(t=us.watch(()=>[s.fields],()=>{a.refresh({updateData:!0})})),t}function AB(a){let{view:e}=a,t;return e!==void 0&&"selectionManager"in e&&"selections"in e.selectionManager&&(t=us.watch(()=>e.selectionManager.selections,i=>{a.syncSelectionsBetweenChartAndLayerViewPolicy===To.Enabled&&(Array.isArray(i)&&i?.length===0?a.clearSelection():a.applySelectionFromView())})),t}var VE=({message:a,heading:e,options:t})=>hA`<calcite-alert .icon=${t?.icon??"exclamationMarkTriangle"} .open=${t?.active===!0} .autoClose=${t?.autoClose??!1} .autoCloseDuration=${t?.duration??"medium"} scale=m .kind=${t?.kind??"danger"} .ariaHidden=${t?.active!==!0} dir=ltr role=alertdialog label="arcgis charts notify panel">${e!==void 0?hA`<div slot=title>${e}</div>`:null}${a!==void 0?hA`<div slot=message>${a}</div>`:null}</calcite-alert>`,$E=uy`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}.chart{flex-grow:1;overflow-y:hidden}.chart>div{justify-content:center;align-items:center}:host{width:var(--chart-width, var(--arcgis-charts-default-width));height:var(--chart-height, var(--arcgis-charts-default-height));display:flex;flex-direction:row;position:relative;overflow:hidden}.chart-wrapper{position:relative;width:100%}.chart-container{height:100%;overflow:hidden}`,Xg=class extends my{constructor(){super(),this.loaderHandle={showLoader:()=>{this.showLoader=this.hideLoaderAnimation!==!0},hideLoader:()=>{this.showLoader=!1}},this._messages=qu(),this.chartRef=py(),this.guid=Cx(),this.commonStrings=qu({name:"common",blocking:!0}),this.dataUpdateNeededProps=["forceDataUpdate","runtimeDataFilters","returnFeaturesExtent","chartLimits","updateSplitBySeries"],this.updatedProps=new Map,this.updateQueue=RT.promise(async()=>await this.renderChart(),qy),this.noRenderingUpdateProps=["_messages","showLoader","infoModalMessage","notifyMessage"],this.handleExternalSelection=e=>{if(!Ri(this.layer)){let t=e,{selectionData:i,model:s}=t.detail,r=this.layer&&s?.layer?.id===Tn(this.layer).id;this.syncSelection&&r&&e.target!==this.el&&!ra(i.selectionOIDs,this.selectionData?.selectionOIDs)&&(i.selectionOIDs?(this.selectionData={selectionOIDs:i.selectionOIDs,selectionSource:As.ProgrammaticSelection},this.arcgisSelectionComplete.emit({selectionData:this.selectionData,model:this._model})):this.clearSelection())}},this.configPanelNumberChange=e=>{let t=e,{panelNumber:i,modelList:s}=t.detail;this.actionBarElement&&this.enableConfiguration&&this.ourModelExistsIn(s)&&(this.actionBarElement.editChartToggle=i===1?ef.Active:ef.Inactive)},this.configDataChangeError=e=>{let t=e,{error:i,model:s}=t.detail;this.enableConfiguration&&s?.isSameChartAs(this._model)&&this.notify(i.message)},this.modelConfigChange=e=>{let t=e;this.lastModelSetterCalled=t.detail.setterName;let i=this._model?.config;this.enableConfiguration&&la(i)&&(this.applyPlaceholderForPartialConfig(i),this.arcgisConfigChange.emit({newConfig:i,oldConfig:this.config,functionCalled:t.detail.setterName})),i?.iLayer&&!ra(this.config?.iLayer,i?.iLayer)&&(this.layer=new Sg(i.iLayer)),JSON.stringify(this.config)!==JSON.stringify(i)&&(this.config=oi(i))},this.modelDataChange=()=>{this.setTimeBinningInfoWhenNotProvided&&mx(this._model)&&this._model?.resetTimeInterval()},this.actionBarSlotRef=e=>{this.actionBarElement=e&&"assignedElements"in e?e.assignedElements().find(t=>t.tagName.toLowerCase()==="arcgis-charts-action-bar"):void 0},this.checkForInvalidContainer=()=>{this.chartRef.value||Hd("divNode",this.commonStrings?.errorStrings)},this._loadQueryObject=new Io(this,{args:()=>[this.config,this.layer,this.view,this.filterByExtent],task:async([e,t,i,s],{signal:r})=>{let n=await uu({chartConfig:e,layer:t,view:i,filterByExtent:s,abortSignal:r});return await Ji(n)?.load({signal:r}),n}}),this.showLoader=!1,this.enableBetaFeatures=!1,this.enableConfiguration=!1,this.enableAutoTheming=!1,this.syncSelection=!1,this.allowUsingObjectIdStat=!1,this.nullAsValid=!1,this.errorPolicy=Th.Throw,this.layerFilterChangePolicy=Ih.Refresh,this.viewTimeExtentChangePolicy=So.Ignore,this.layerRendererChangePolicy=Dh.Refresh,this.layerFieldsChangePolicy=Lh.Refresh,this.syncSelectionsBetweenChartAndLayerViewPolicy=To.Disabled,this.autoDestroyDisabled=!1,this.arcgisAxesMinMaxChange=Mi(),this.arcgisBadDataWarningRaise=Mi(),this.arcgisChartNotFoundWarning=Mi(),this.arcgisConfigChange=Mi(),this.arcgisDataFetchComplete=Mi(),this.arcgisDataProcessComplete=Mi(),this.arcgisDataProcessError=Mi(),this.arcgisInvalidConfigWarningRaise=Mi(),this.arcgisLegendItemVisibilityChange=Mi(),this.arcgisNoRenderPropChange=Mi(),this.arcgisRenderingComplete=Mi(),this.arcgisRuntimeError=Mi(),this.arcgisSelectionComplete=Mi(),this.arcgisSeriesColorChange=Mi(),this.arcgisSeriesOrder=Mi(),this.arcgisUpdateComplete=Mi(),this.listen("arcgisChartsJSDataProcessComplete",this.handleDataProcessComplete),this.listen("arcgisChartsJSDataFetchComplete",this.handleDataFetchComplete),this.listen("arcgisChartsJSLegendItemVisibilityChange",this.handleLegendItemVisibilityChanged),this.listen("arcgisChartsJSInvalidConfigWarningRaise",this.handleInvalidConfigWarningRaise),this.listen("arcgisChartsJSSeriesColorChange",this.handleSeriesColorsChange),this.listen("arcgisChartsJSSelectionComplete",this.handleSelection),this.listen("arcgisChartsJSTooManySelectedElements",this.handleTooManySelectedElements),this.listen("calciteAlertClose",this.handleAlertClosed),this.listen("arcgisChartsJSAxesMinMaxChange",this.handleAxesMinMaxChange),this.listen("arcgisChartsJSSeriesOrder",this.handleSeriesOrder),this.listen("arcgisChartsJSRenderingComplete",this.handleRenderingComplete),this.addConfigListeners(),this.listenOn(document,"arcgisSelectionComplete",this.handleExternalSelection)}static{this.properties={infoModalMessage:16,notifyMessage:16,showLoader:16,config:16,enableBetaFeatures:5,model:0,enableConfiguration:5,enableAutoTheming:5,syncSelection:5,rotation:[5,{hasChanged:()=>!1}],actionMode:1,cursorRange:1,legendPosition:[1,{hasChanged:()=>!1}],legendVisibility:[5,{hasChanged:()=>!1}],allowUsingObjectIdStat:5,nullAsValid:5,showUIMessages:5,hideEmptySeries:5,autoInverseDataLabelTextColor:5,replaceNoValueCategoryWithZero:5,ignoreSmoothRenderingLimit:5,chartWillRender:0,legendValueLabelFormatter:0,timeZone:1,view:[0,{hasChanged:()=>!1}],layer:0,layerItemId:1,chartIndex:9,selectionData:0,returnSelectionOIDs:5,returnSelectionIndexes:5,returnFeaturesExtent:5,filterBySelection:5,filterByExtent:[5,{hasChanged:()=>!1}],disableInteractions:[5,{hasChanged:()=>!1}],queueChartCreation:5,useAnimatedCharts:5,hideLicenseWatermark:5,enableResponsiveFeatures:5,autoDisposeChart:5,featureIndex:[9,{hasChanged:()=>!1}],placeholder:1,selectionTheme:0,setTimeBinningInfoWhenNotProvided:5,chartLimits:0,aria:[0,{hasChanged:()=>!1}],tooltipFormatter:0,dataLabelFormatter:0,guideTooltipFormatter:0,xAxisLabelFormatter:0,yAxisLabelFormatter:0,secondaryYAxisLabelFormatter:0,gaugeInnerLabelFormatter:0,errorPolicy:1,disableTogglingLegendItems:5,hideLoaderAnimation:5,loaderColors:0,runtimeDataFilters:0,usePopupTemplateFieldsInfo:5,layerFilterChangePolicy:1,viewTimeExtentChangePolicy:1,layerRendererChangePolicy:1,layerFieldsChangePolicy:1,syncSelectionsBetweenChartAndLayerViewPolicy:1,ignoreViewExtent:5,updateSplitBySeries:0,messageOverrides:0,autoDestroyDisabled:5}}static{this.styles=$E}get config(){return this._config}set config(e){let t=this._config;this._config=e,t&&e&&M0(t,e)&&this.updatedProps.set("forceDataUpdate",{oldValue:!1,newValue:!0}),this.arcgisConfigChange.emit({newConfig:e,oldConfig:t,functionCalled:this.lastModelSetterCalled}),this.lastModelSetterCalled=void 0,this.actionBarElement&&!la(e)&&(this.actionBarElement.forceDisableActions=!1),la(e)&&this.applyPlaceholderForPartialConfig(e)}get rotation(){return this._rotation}set rotation(e){this.rotationChange(e),this.handleNoRenderPropChange("rotation",e),this._rotation=e}get legendPosition(){return this._legendPosition}set legendPosition(e){this.legendPositionChange(e),this.handleNoRenderPropChange("legendPosition",e),this._legendPosition=e}get legendVisibility(){return this._legendVisibility}set legendVisibility(e){this.legendVisibilityChange(e),this.handleNoRenderPropChange("legendVisibility",e),this._legendVisibility=e}get view(){return this._view}set view(e){let t=this._view;this._view=e,this.viewChange(e,t),this.handleNoRenderPropChange("view",e)}get filterByExtent(){return this._filterByExtent}set filterByExtent(e){this._filterByExtent=e,this.filterByExtentChanged(e),this.handleNoRenderPropChange("filterByExtent",e)}get disableInteractions(){return this._disableInteractions??!1}set disableInteractions(e){this.disableInteractionsChange(e),this.handleNoRenderPropChange("disableInteractions",e),this._disableInteractions=e}get featureIndex(){return this._featureIndex}set featureIndex(e){let t=this.featureIndex;this.featureIndexChange(e,t),this.handleNoRenderPropChange("featureIndex",e),this._featureIndex=e}get aria(){return this._aria??{}}set aria(e){this._aria=e,this.chartRef.value&&(this.chartRef.value.ariaLabel=e.label??this.chartRef.value.ariaLabel,this.chartRef.value.ariaDescription=e.description??this.chartRef.value.ariaDescription,this.chartRef.value.ariaLabelledByElements=e.labelledByElements??this.chartRef.value.ariaLabelledByElements,this.chartRef.value.ariaDescribedByElements=e.describedByElements??this.chartRef.value.ariaDescribedByElements),this.handleNoRenderPropChange("aria",e)}async clearSelection(){this.chart!==void 0&&(this.unsanitizedSelectionDataItems=void 0,this.chart.clearSelection(),this.filterBySelection===!0&&await this.refresh())}async destroy(){this.chart?.dispose()}async exportAsCSV(e){let t=S0(this.config)||Ri(this.layer),i,s;if(this.sanitizedChartData&&!t){let r=await this._loadQueryObject.taskComplete,n=r?$s(r,this.usePopupTemplateFieldsInfo):void 0,A=ha(this.model)?this.model.titleText:this.config?.title?.content?.text??this.commonStrings.utilsStrings.chartType.chart;if(Object.values(this.sanitizedChartData).filter(o=>Array.isArray(o)&&o.length>0).length>1){let o=new lB.default;Object.entries(this.sanitizedChartData).forEach(([c,h])=>{if(Array.isArray(h)&&h.length>0){let d=rf({rawData:h,config:this._model?.config??this.config,layer:r,fieldList:n}),u=sf(d,e),g=`${A}-${c}.csv`;o.file(g,u)}});let l=await o.generateAsync({type:"blob"});i=URL.createObjectURL(l),s=`${A}.zip`}else{let o;if("bins"in this.sanitizedChartData?o=this.sanitizedChartData.bins:"dataItems"in this.sanitizedChartData&&(o=this.sanitizedChartData.dataItems),o){let l=rf({rawData:o,config:this._model?.config??this.config,layer:r,fieldList:n}),c=sf(l,e);i=URL.createObjectURL(new Blob([c],{type:"text/csv;charset=utf-8;"})),s=`${A}.csv`}}i!==void 0&&s!==void 0&&tf(i,s)}}async exportAsImage(e=Jy.PNG){let t=this.chartRef.value;t?(await(0,oB.default)(t,{useCORS:!0,backgroundColor:null})).toBlob(i=>{if(i){let s=URL.createObjectURL(i),r=`${this.model.titleText??this.commonStrings.utilsStrings.chartType.chart}.${e}`;tf(s,r)}},e):this.notify(this.commonStrings?.errorStrings.errors.exportImageChartNotReady)}async loadModel(){return this._model?await this._model.asyncUpdatesPromise:await new Promise(e=>{this.resolveModelSetup=e})}async notify(e,t){this.infoModalMessage=e,this.infoModalHeading=t}async refresh(e){let{updateData:t=!0,resetAxesBounds:i=!1}=e??{};this.updatedProps.set(t?"forceDataUpdate":"forceSimpleUpdate",{oldValue:!1,newValue:!0}),i&&(delete this.config?.axes?.[0]?.minimum,delete this.config?.axes?.[0]?.maximum,delete this.config?.axes?.[1]?.minimum,delete this.config?.axes?.[1]?.maximum),this.requestUpdate("refresh")}async resetZoom(){this.chart!==void 0&&this.chart.resetZoom()}async switchSelection(){let e=await this._loadQueryObject.taskComplete;this.chart!==void 0&&this.filterBySelection!==!0&&e&&await this.chart.switchSelection(e)}load(){if(this.syncSelectionsBetweenChartAndLayerViewPolicy===To.Enabled){let e=this.getSelectionFromLayerView();e&&(this.selectionData={selectionOIDs:e,selectionSource:As.ProgrammaticSelection})}}willUpdate(e){e.has("model")&&this.modelChange(),e.has("selectionData")&&this.selectionDataChange(),e.has("layer")&&this.layerChange(),e.has("layerItemId")&&this.layerItemIdChange(),(e.has("chartIndex")||e.has("layerItemId"))&&this.createModelFromLayer(),e.has("timeZone")&&this.timeZoneChange(),e.has("filterBySelection")&&this.filterBySelectionChanged(),e.has("layerFilterChangePolicy")&&this.layerFilterChangePolicyCallBack(this.layerFilterChangePolicy),e.has("viewTimeExtentChangePolicy")&&this.viewTimeExtentChangePolicyCallback(this.viewTimeExtentChangePolicy),e.has("layerRendererChangePolicy")&&this.layerRendererChangePolicyCallBack(this.layerRendererChangePolicy),e.has("layerFieldsChangePolicy")&&this.layerFieldsChangePolicyCallBack(this.layerFieldsChangePolicy),Array.from(e.keys(),t=>{let i=t.toString();this.updatedProps.set(i,{oldValue:e.get(i),newValue:this[i]})})}updated(e){Array.from(e.keys()).filter(t=>!this.noRenderingUpdateProps.includes(t)).length>0&&this.updatedAsync(),this.actionBarElement!==void 0&&Bx({actionBar:this.actionBarElement,chartComponent:this.el,config:this.config,isInfoModalDisplayed:this.infoModalMessage!==void 0})}disconnectedCallback(){super.disconnectedCallback(),this.removeLayerWatchHandlers(),this.removeExtentChangeWatchHandlers(),this.removeViewWatchHandlers(),this.autoDestroyDisabled||this.chart?.dispose()}applySelectionFromView(){let e=this.getSelectionFromLayerView();e&&(this.selectionData={selectionOIDs:e,selectionSource:As.ProgrammaticSelection},this.arcgisSelectionComplete.emit({selectionData:this.selectionData,model:this._model}))}hideInfoModal(){this.infoModalMessage=void 0}async generateHeatChartClassBreaks(e){if(!Ri(this.layer)&&Ju(this._model)&&e?.data&&"dataItems"in e.data){let t=await _x({data:e.data,classificationMethod:this._model.classificationMethod,breaksCount:this._model.breaksCount,xAxisField:this._model.xAxisField,existingClassBreakInfos:this._model.chartRenderer?.classBreakInfos});!ra(t,this._model.chartRenderer?.classBreakInfos)&&(this._model.chartRenderer={...this._model.chartRenderer,classBreakInfos:t,type:"classBreaks",field:qt.valueField})}}async updatedAsync(){if(this.dataFetching&&(await this.dataFetching,this.dataFetching=void 0),this.chart===void 0&&this.chartCreationProcessing!==void 0&&(await this.chartCreationProcessing,this.chartCreationProcessing=void 0),this.config!==void 0&&this.chart!==void 0)try{(!this.config&&!this.layer||ju(this.config,this.layer)&&!la(this.config)&&await Zu(this.config,this.layer))&&await this.updateQueue?.push({})}catch(e){this.updatedProps.clear(),this.chartRef.value!==void 0&&(e instanceof oa&&e.name===bA.ChartDisposed?(this.chart?.dispose(),this.chart=void 0,this.chartRef.value.innerHTML="",await this.createChartInstance(!1)):(e instanceof oa&&e.name===bA.QueryFeaturesError?this.arcgisDataProcessError.emit(e.details):e instanceof oa&&this.arcgisRuntimeError.emit(e.details??e),typeof e=="object"&&e&&"message"in e&&this.notify(String(e.message),this.commonStrings?.errorStrings.errorHeading)))}else this.chart===void 0&&this.chartCreationProcessing===void 0&&await this.createChartInstance();this.placeholder!==void 0?await this.notify(this.placeholder):this.enableConfiguration&&la(this.config)&&this.applyPlaceholderForPartialConfig(this.config)}useAmCharts5(){let e=Oe(this.config?.series);return this.enableBetaFeatures||e===P.ScatterSeries||e===P.HistogramSeries||e===P.RadarSeries||e===P.HeatSeries}handleNoRenderPropChange(e,t){this.arcgisNoRenderPropChange.emit({propName:e,value:t,model:this._model})}handleRenderingComplete(e){this.arcgisRenderingComplete.emit(e.detail),this.showLoader=!1}handleDataProcessComplete(e){this.sanitizedChartData=e.detail,this.arcgisDataProcessComplete.emit({chartData:e.detail,model:this._model})}handleDataFetchComplete(e){this.arcgisDataFetchComplete.emit(e.detail)}handleLegendItemVisibilityChanged(e){l0(e,this.config),this.arcgisLegendItemVisibilityChange.emit({legendItemVisibility:e.detail,model:this._model})}handleUpdateCompleted(e){if(this.enableConfiguration){let t=this.commonStrings?.errorStrings.notifications;if(this.placeholder===void 0&&(e.schemaErrors.length>0&&!la(this.config)?la(this.config)?this.applyPlaceholderForPartialConfig(this.config):this.notify(t?.invalidConfig,void 0):e.warnings.length>0&&e.warnings.some(i=>i.keyword===I0.NonNumericAggregation)&&this.notify(t?.validateAggregationTypeMsg,t?.missingNumericFields)),(fx(this._model)||gx(this._model))&&this._model.aggregationType===Ey.NoAggregation&&this._model.numericFields.length===1&&this.layer){let i=Tn(this.layer),s=BA(i).idField;s&&this._model.numericFields.includes(s)&&this.notify(t?.noAggregationRequiresNumericFields,t?.missingNumericFields)}}this.showLoader&&this.loaderHandle.hideLoader(),this.arcgisUpdateComplete.emit(e)}handleInvalidConfigWarningRaise(e){this.arcgisInvalidConfigWarningRaise.emit(e.detail),this.notify(e.detail.message,e.detail.header)}handleSeriesColorsChange(e){this.arcgisSeriesColorChange.emit({data:e.detail.data,colorMatchApplied:e.detail.colorMatchApplied,model:this._model})}handleSelection(e){let t={...e.detail},i={...t},s=oi(t.selectionItems);s&&(s=s0(s,this.config?.series),s=s.map(r0),s=i0(s,this.config?.series),i.selectionItems=s),ra(i,this.selectionData)||(this.unsanitizedSelectionDataItems=t.selectionItems,this.selectionData=i,this.arcgisSelectionComplete.emit({selectionData:i,model:this._model}))}handleTooManySelectedElements(){this.errorPolicy===Th.Throw&&(this.infoModalHeading=this.commonStrings?.errorStrings.tooManySelectedElements?.title,this.infoModalMessage=this.commonStrings?.errorStrings.tooManySelectedElements?.message,this.notifyOptions={kind:"warning",autoClose:!0,duration:"fast",active:!0})}handleAlertClosed(e){e.target===this.el&&(this.notifyHeading=void 0,this.notifyMessage=void 0)}handleAxesMinMaxChange(e){this.arcgisAxesMinMaxChange.emit({bounds:e.detail,model:this._model})}handleSeriesOrder(e){this.arcgisSeriesOrder.emit(e.detail)}modelChange(){if(ha(this.model)){this._model=this.model,this.config=oi(this._model?.config);let e=this._model?.layer;!this.layerItemId&&e&&(this.layer=e),this.addModelListeners(),this._model.asyncUpdatesPromise.then(()=>{typeof this.resolveModelSetup=="function"&&this.resolveModelSetup()})}else this.config=this.model;if(this.enableBetaFeatures===void 0){let e=Oe(this.config?.series);this.enableBetaFeatures=e===P.ScatterSeries||e===P.HistogramSeries}}selectionDataChange(){this.layer!==void 0&&this.syncSelectionsBetweenChartAndLayerViewPolicy===To.Enabled&&this.view!==void 0&&this.setSelectionInLayerView()}async viewChange(e,t){this.layerItemId&&this.layerItemId?.trim()!==""&&(this.layer=gu({view:this.view,portalItemId:this.layerItemId})??new Sg({portalItem:{id:this.layerItemId}})),await this.setExtentChangeWatchHandler(),this.setViewTimeExtentChangeWatchHandler(),this.setViewTimeZoneWatchHandler(),t!==void 0&&e===void 0&&await this.refresh(),this.view?this.setViewSelectionsChangeWatchHandler():this.removeViewSelectionsChangeWatchHandler()}async layerChange(){this.addLayerWatchHandlers(),this.layer&&(await Tn(this.layer).load(),await this.setExtentChangeWatchHandler(),this.setViewTimeExtentChangeWatchHandler(),this.setViewTimeZoneWatchHandler())}layerItemIdChange(){this.layerItemId&&this.layerItemId?.trim()!==""?this.layer=gu({view:this.view,portalItemId:this.layerItemId})??new Sg({portalItem:{id:this.layerItemId}}):this.layer=void 0}featureIndexChange(e,t){t===void 0&&typeof e=="number"&&this.updatedProps.set("forceDataUpdate",{oldValue:t,newValue:e})}disableInteractionsChange(e){e?this.chartRef.value?.classList.add(rr.DisableInteractions):this.chartRef.value?.classList.remove(rr.DisableInteractions)}rotationChange(e){e!==void 0&&(this.config=lx(e,this.config))}legendPositionChange(e){e!==void 0&&(this.config=Ax(e,this.config))}legendVisibilityChange(e){e!==void 0&&(this.config=ox(e,this.config))}timeZoneChange(){this.updateConfigTimeZone()}filterBySelectionChanged(){this.config=hx(this.config)}layerFilterChangePolicyCallBack(e){e!==Ih.Ignore?this.setLayerFilterWatchHandler():this.removeLayerFilterWatchHandler()}viewTimeExtentChangePolicyCallback(e){e!==So.Refresh?this.removeViewTimeExtentChangeWatchHandler():this.setViewTimeExtentChangeWatchHandler()}layerRendererChangePolicyCallBack(e){e!==Dh.Ignore?this.setLayerRendererWatchHandler():this.removeLayerRendererWatchHandler()}async filterByExtentChanged(e){e||await this.refresh({updateData:!0,resetAxesBounds:!0}),e?this.setExtentChangeWatchHandler(e):this.removeExtentChangeWatchHandlers()}layerFieldsChangePolicyCallBack(e){e!==Lh.Ignore?this.setLayerFieldsWatchHandler():this.removeLayerFieldsWatchHandler()}addConfigListeners(){this.listenOn(document,"arcgisChartsConfigPanelNumberChange",this.configPanelNumberChange),this.listenOn(document,"arcgisChartsConfigDataChangeError",this.configDataChangeError)}getSelectionFromLayerView(){let e;if(this.view&&this.layer&&!Ri(this.layer)){let t=Tn(this.layer);e=this.view?.selectionManager?.getSelection(t)}return e}setSelectionInLayerView(){if(this.view&&this.layer&&!Ri(this.layer)){let e,t=this.selectionData?.selectionOIDs?.length===0||this.selectionData?.selectionOIDs===void 0||this.selectionData?.selectionSource===As.ClearSelection,i=(this.selectionData?.selectionOIDs?.length??0)>0;t?e=[]:i&&this.selectionData&&(e=this.selectionData.selectionOIDs),e&&this.view.selectionManager.replace(Tn(this.layer),e)}}addModelListeners(){this.listenOn(this._model??null,"arcgisChartsModelConfigChange",this.modelConfigChange),this.listenOn(this._model??null,"arcgisChartsModelDataChange",this.modelDataChange)}addLayerWatchHandlers(){this.removeLayerWatchHandlers(),this.layerFilterWatchHandler=rB(this),this.layerRendererWatchHandler=aB(this),this.layerFieldsWatchHandler=nB(this),this.removeViewSelectionsChangeWatchHandler(),this.viewSelectionsChangeWatchHandler=AB(this)}setLayerFilterWatchHandler(){this.removeLayerFilterWatchHandler(),this.layerFilterWatchHandler=rB(this)}setLayerRendererWatchHandler(){this.removeLayerRendererWatchHandler(),this.layerRendererWatchHandler=aB(this)}setLayerFieldsWatchHandler(){this.removeLayerFieldsWatchHandler(),this.layerFieldsWatchHandler=nB(this)}async setExtentChangeWatchHandler(e){(e??this.filterByExtent)&&(this.removeExtentChangeWatchHandlers(),this.extentChangeWatchHandlers=await RE(this))}setViewTimeZoneWatchHandler(){this.removeViewTimeZoneChangeWatchHandler(),this.viewTimeZoneChangeWatchHandler=NE(this)}setViewTimeExtentChangeWatchHandler(){this.removeViewTimeExtentChangeWatchHandler(),this.viewTimeExtentChangeWatchHandler=OE(this)}setViewSelectionsChangeWatchHandler(){this.removeViewSelectionsChangeWatchHandler(),this.viewSelectionsChangeWatchHandler=AB(this)}removeLayerWatchHandlers(){this.removeLayerFilterWatchHandler(),this.removeLayerRendererWatchHandler(),this.removeLayerFieldsWatchHandler()}removeViewWatchHandlers(){this.removeViewSelectionsChangeWatchHandler(),this.removeViewTimeZoneChangeWatchHandler(),this.removeViewTimeExtentChangeWatchHandler()}removeLayerFilterWatchHandler(){this.layerFilterWatchHandler?.remove()}removeLayerRendererWatchHandler(){this.layerRendererWatchHandler?.remove()}removeLayerFieldsWatchHandler(){this.layerFieldsWatchHandler?.remove()}removeExtentChangeWatchHandlers(){this.extentChangeWatchHandlers?.forEach(e=>e.remove()),this.extentChangeWatchHandlers=[]}removeViewSelectionsChangeWatchHandler(){this.viewSelectionsChangeWatchHandler?.remove()}removeViewTimeZoneChangeWatchHandler(){this.viewTimeZoneChangeWatchHandler?.remove()}removeViewTimeExtentChangeWatchHandler(){this.viewTimeExtentChangeWatchHandler?.remove(),this.runtimeDataFilters?.timeExtent&&delete this.runtimeDataFilters.timeExtent}async createModelFromLayer(){if(this.layer){let e=Tn(this.layer);await e.load();let t=this.chartIndex??0,i="charts"in e?e?.charts?.[t]:void 0;if(i)this.model=await yx({layer:e,config:i});else{let s=Ug(this._messages?.chartNotFoundWarning??"",{chartIndex:t.toString(),layerTitle:e.title});this.arcgisChartNotFoundWarning.emit(s),gy("warn",this,s)}}}applyPlaceholderForPartialConfig(e){let t=px(this._model)?P.ComboLineAndBarSeries:Oe(e?.series),i=TE(t,this.commonStrings?.errorStrings);this.notify(i)}checkForIncompatibleChartVersion(){let e=this.config?.version;this.errorPolicy===Th.Throw&&E0(e).versionStatus===My.Newer&&(this.notifyHeading=this.commonStrings?.errorStrings.incompatibleChartVersion?.title,this.notifyMessage=this.commonStrings?.errorStrings.incompatibleChartVersion?.message?Ug(this.commonStrings?.errorStrings.incompatibleChartVersion?.message,{chartVersion:e??""}):"",this.notifyOptions={kind:"warning",autoClose:!0,active:!0})}ourModelExistsIn(e){return e.some(t=>this._model?.isSameChartAs(t))}updateConfigTimeZone(){this.config?.axes?.[0]?.valueFormat.type===P.DateAxisFormat&&(this.config.axes[0].valueFormat.intlOptions.timeZone=nv(this.timeZone))}gatherComponentGlobalOptions(){return{queueChartCreation:this.queueChartCreation,useAnimatedCharts:this.useAnimatedCharts,hideLicenseWatermark:this.hideLicenseWatermark,enableResponsiveFeatures:this.enableResponsiveFeatures,autoDisposeChart:this.autoDisposeChart}}addMutationObserverForCalciteTheme(){xy(this.el,["class"],()=>{if(this.enableAutoTheming){let e=Gg(this.el);(this.calciteThemeApplied==="dark"&&!e||this.calciteThemeApplied!=="dark"&&e)&&(this.calciteThemeApplied=e?"dark":void 0,this.refresh({updateData:!1}))}})}gatherComponentOptions(e=!0){let t=this.runtimeDataFilters;this.view&&this.viewTimeExtentChangePolicy===So.Refresh&&this.view.timeExtent?.start!=null&&this.view.timeExtent?.end!=null&&(t={...t,timeExtent:[this.view.timeExtent.start.valueOf(),this.view.timeExtent.end.valueOf()]});let i;if(Ri(this.layer))i=this.filterByExtent?this.view:void 0;else{let s=ha(this.model)?this.model.config:this.model,r=Oe(s?.series);i=this.filterByExtent||r!==P.HistogramSeries?this.view:void 0}return{layer:this.layer,view:i,viewExtentUpdated:e&&this.filterByExtent===!0&&(this.view!==void 0||Ma(this.layer)),allowUsingObjectIdStat:this.allowUsingObjectIdStat,nullAsValid:this.nullAsValid,showUIMessages:this.showUIMessages,createMessage:this.placeholder,hideLoaderAnimation:this.hideLoaderAnimation,loaderColors:oi(this.loaderColors),runtimeDataFilters:t,usePopupTemplateFieldsInfo:this.usePopupTemplateFieldsInfo,ignoreViewExtent:this.ignoreViewExtent,chartLimits:this.chartLimits,guideTooltipFormatter:this.guideTooltipFormatter,xAxisLabelFormatter:this.xAxisLabelFormatter,yAxisLabelFormatter:this.yAxisLabelFormatter,secondaryYAxisLabelFormatter:this.secondaryYAxisLabelFormatter,tooltipFormatter:this.tooltipFormatter,dataLabelFormatter:this.dataLabelFormatter,selectionData:this.selectionData,filterBySelection:this.filterBySelection,actionMode:this.actionMode,cursorRange:this.cursorRange,selectionTheme:this.selectionTheme,setTimeBinningInfoWhenNotProvided:this.setTimeBinningInfoWhenNotProvided,returnSelectionOIDs:Ri(this.layer)?!1:this.returnSelectionOIDs,returnSelectionIndexes:this.returnSelectionIndexes,returnFeaturesExtent:this.returnFeaturesExtent,disableTogglingLegendItems:this.disableTogglingLegendItems,hideEmptySeries:this.hideEmptySeries,autoInverseDataLabelTextColor:this.autoInverseDataLabelTextColor,replaceNoValueCategoryWithZero:this.replaceNoValueCategoryWithZero,gaugeInnerLabelFormatter:this.gaugeInnerLabelFormatter,ignoreSmoothRenderingLimit:this.ignoreSmoothRenderingLimit,chartWillRender:this.chartWillRender,pieChartLegendValueLabelFormatter:this.legendValueLabelFormatter}}raiseLogScaleNotCompatibleWarning(e){let t=!0;return this.config?.axes?.forEach((i,s)=>{xu({chartConfig:this.config,axisConfigIndex:s,chartData:cr(e?.data??this.sanitizedChartData)})||(t=!1,this.raiseInvalidDataWarning(s===0?In.NegativeValueInXAxisLogScale:In.NegativeValueInYAxisLogScale))}),t}raiseNoDataWarning(e){let t=!1;if(e?.data){let i=cr(e.data);sv({chartConfig:this.config,nullAsValid:this.nullAsValid,dataSet:i})&&(t=!0,this.raiseInvalidDataWarning(In.EmptyDataSet))}return t}raiseInvalidDataWarning(e,t){let i=this.layer,s=this.gatherComponentOptions(),r=this.config!==void 0&&po({seriesConfig:this.config.series[0],xAxisValueFormatType:eh(this.config),queryObject:i}),n=d0({invalidType:e,elementCount:t,seriesCount:this.config?.series?.length,chartLimits:s?.chartLimits,filterBySelection:s?.filterBySelection,queryObject:i,formatLocale:yo(this.el),isTemporalChart:r,errorStrings:this.commonStrings?.errorStrings});(n.keyword!==In.EmptyDataSet||this.infoModalMessage===void 0)&&(this.arcgisBadDataWarningRaise.emit(n),this.notify(n.message,n.header))}processInvalidConfigStatus(e,t){if(this.enableConfiguration)this.handleUpdateCompleted(e);else if(this.loaderHandle.hideLoader(),!this.infoModalMessage){let{title:i,message:s}=bB({chartConfig:t,createMessage:this.placeholder,status:e,errorStrings:this.commonStrings?.errorStrings});this.arcgisInvalidConfigWarningRaise.emit({keyword:In.InvalidConfig,header:i,message:s}),this.notify(s,i)}}async createChartInstance(e=!0){if(this.config)try{this.addMutationObserverForCalciteTheme(),await this.renderChart(),e&&this.chart&&(this.addLayerWatchHandlers(),await this.setExtentChangeWatchHandler(),this.setViewTimeExtentChangeWatchHandler(),this.setViewTimeZoneWatchHandler())}catch(t){this.updatedProps.clear(),t instanceof oa&&t.name===bA.QueryFeaturesError?this.arcgisDataProcessError.emit(t.details):t instanceof oa&&this.arcgisRuntimeError.emit(t.details??t),typeof t=="object"&&t&&"message"in t&&this.notify(String(t.message),this.commonStrings?.errorStrings.errorHeading),this.chart?.dispose(),this.chartCreationProcessing=void 0,this.chart=void 0}}async renderChart(){if(this.config){let e=this.chart===void 0,t=new Map(this.updatedProps),i=Array.from(t.keys());if(e||i.length>0){this.checkForInvalidContainer(),e&&(this.dataFetching&&(await this.dataFetching,this.dataFetching=void 0),this.chartCreationProcessing&&(await this.chartCreationProcessing,this.chartCreationProcessing=void 0),this.updateConfigTimeZone(),this.checkForIncompatibleChartVersion(),this.updatedProps.clear());let s=await this._loadQueryObject.taskComplete;if(s){let r=this.gatherComponentOptions(),n=$s(s,this.usePopupTemplateFieldsInfo),A=e?void 0:t?.get("config")?.oldValue??this.config,o=e,l;e||({dataUpdateNeeded:o,dataUpdateDetails:l}=XI({config:this.config,previousConfig:A,dataUpdateNeededProps:this.dataUpdateNeededProps,updatedProps:t,options:r,filterBySelection:this.filterBySelection,previousSelectionOIDs:t.has("selectionData")?t.get("selectionData")?.oldValue?.selectionOIDs:this.selectionData?.selectionOIDs,fieldList:n,queryObject:s}),o&&this.hideInfoModal());let c=this.updateSplitBySeries?.addMissingSeries===!0&&(e||o||i.includes("layer")||i.includes("filterByExtent")),h,d,u=!0;for(let g=0;g<wx&&u;g++){let y=this.config;({alteredConfig:h,preFetchedQueryResponse:d}=await cx({configToAlter:this.config,updateSplitBySeries:this.updateSplitBySeries,addMissingSeries:c,chartContainer:this.el,queryObject:s,options:r,layer:this.layer})),u=this.config!==y}if(this._config=h,this.model&&h&&!ha(this.model)&&(this.model.series=h.series),l?.common&&A?.series&&h?.series&&(l.common.numberOfSeriesChanged=H0(A.series,h.series)),!h&&!this.layer||ju(h,this.layer)&&await Zu(h,this.layer)){let g=await bu({input:h,queryObject:s,allowUsingObjectIdStat:r?.allowUsingObjectIdStat});if(i.forEach(y=>this.updatedProps.delete(y)),!g.valid)this.processInvalidConfigStatus(g,h);else{let y={valid:!0,data:this.processedChartData??this.sanitizedChartData};if(h)if(Ma(s)&&await us.whenOnce(()=>!s.updating),o=o&&h!==void 0&&!la(h),o&&(this.loaderHandle.showLoader(),this.dataFetching=v0({chartConfig:h,preFetchedQueryResponse:d,queryObject:s,options:r,fieldList:n,fullDatasetBeforeFBS:this.processedChartData,currentSelectionOIDs:this.selectionData?.selectionOIDs,currentSelectionDataItems:this.unsanitizedSelectionDataItems,dataForFilterBySelectionChanged:l?.common?.dataForFilterBySelectionChanged,errorStrings:this.commonStrings?.errorStrings,abortKey:this.guid}),y=await this.dataFetching,Ju(this._model)&&xx(vx,y?.data),this.filterBySelection||(this.processedChartData=y?.data)),!y.valid)this.raiseInvalidDataWarning(y.invalidType,y.count);else{let m,b=oi(h);if({filteredConfig:h,seriesFilteredOut:m}=dx({hideEmptySeries:this.hideEmptySeries??!0,config:h,data:y?.data}),!this.raiseNoDataWarning(y)&&this.raiseLogScaleNotCompatibleWarning(y)){ch(A,h)&&(o=!0);let B=Vs(h)?h.showMean:void 0,w=y?.data??this.sanitizedChartData,_=w&&B&&"meanLines"in w?w.meanLines:cr(w);_&&(e||o)&&({colorMatchApplied:this._colorMatchApplied,rendererFieldNames:this._rendererFieldNames}=await BB({data:_,queryObject:s,chartConfig:h,allowColorMatch:sh({chartConfig:h,queryObject:s})})),this.enableAutoTheming&&(h=ME(this.el,h),this.calciteThemeApplied=Gg(this.el)?"dark":void 0,r=PE({chartElement:this.el,options:r,calciteThemeApplied:this.calciteThemeApplied}));let T={chartContainer:this.chartRef.value,queryObject:s,dataInfo:y,colorMatchApplied:this._colorMatchApplied,rendererFieldNames:this._rendererFieldNames,hasSeriesFilteredOut:m,uniqueInternalID:this.el.id,t9nStrings:{errorStrings:this.commonStrings?.errorStrings,utilsStrings:this.commonStrings?.utilsStrings},loaderHandle:this.loaderHandle};if(this.hideInfoModal(),e){let Q=this.useAmCharts5()?SE:AD;this.chartCreationProcessing=Q({...T,chartConfig:h,options:r,globalOptions:this.gatherComponentGlobalOptions()}),this.chart=await this.chartCreationProcessing,this.chartCreationProcessing=void 0}else await this.chart?.update({...T,newChartConfig:h,dataUpdateDetails:l,configWithAllSeries:b,dataWasUpdated:o,updateOptions:r,updateGlobalOptions:this.gatherComponentGlobalOptions()}),this.handleUpdateCompleted(g);await this.generateHeatChartClassBreaks(y)}}}}}}}}render(){let e=this.notifyMessage?VE({heading:this.notifyHeading,message:this.notifyMessage,options:this.notifyOptions}):null,t="";switch(!0){case(this.notifyMessage&&this.notifyOptions?.kind==="danger"):case(this.infoModalMessage&&this.showUIMessages!==!1):t=rr.Hide;break;default:t=`${rr.Chart} ${rr.Show}`;break}let i=this.notifyMessage?`${rr.Show} ${rr.NotifyPanel}`:rr.Hide;return hA`<slot name=${ux.actionBar} @slotchange=${s=>{this.actionBarElement=bx(s,this.el,this.config)}} ${Td(this.actionBarSlotRef)}></slot>${(this.infoModalMessage||this.showLoader)&&this.showUIMessages!==!1?hA`<arcgis-charts-info-modal .heading=${this.infoModalHeading??""} .message=${this.infoModalMessage??""} .showLoader=${this.showLoader} .loaderColors=${this.loaderColors} .calciteThemeApplied=${this.calciteThemeApplied} .enableAutoTheming=${this.enableAutoTheming}></arcgis-charts-info-modal>`:null}<div class=${`${rr.ChartWrapper} ${t}`}><div class=${`${rr.ChartContainer} ${t}`} ${Td(this.chartRef)}></div></div><div class=${yy(i)}>${e}</div>`}};vy("arcgis-chart",Xg);return Xg},"core/reactiveUtils","intl","layers/FeatureLayer","geometry/support/jsonUtils","rest/support/AttributeBinsQuery","rest/support/Query","rest/support/StatisticDefinition","time/TimeExtent","core/promiseUtils","request","applications/Components/imageryUtils","geometry/Extent","geometry/Point","Graphic","renderers/support/jsonUtils","symbols/support/symbolUtils","AttributeBinsGraphic","layers/support/CodedValueDomain","layers/support/FeatureFilter","smartMapping/statistics/histogram","smartMapping/statistics/summaryStatistics","core/sql",a,b,c,d,e,f,g,h,i,j,k,l,m,n,o)