@carbon/charts 0.29.1 → 0.29.2

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 (210) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/LICENSE.md +201 -0
  3. package/{src/axis-chart.d.ts → axis-chart.d.ts} +0 -0
  4. package/{src/axis-chart.js → axis-chart.js} +9 -2
  5. package/axis-chart.js.map +1 -0
  6. package/bundle.js +1 -25
  7. package/{src/chart.d.ts → chart.d.ts} +0 -0
  8. package/{src/chart.js → chart.js} +9 -2
  9. package/chart.js.map +1 -0
  10. package/{src/charts → charts}/bar-grouped.d.ts +0 -0
  11. package/{src/charts → charts}/bar-grouped.js +1 -1
  12. package/{src/charts → charts}/bar-grouped.js.map +0 -0
  13. package/{src/charts → charts}/bar-simple.d.ts +0 -0
  14. package/{src/charts → charts}/bar-simple.js +1 -1
  15. package/{src/charts → charts}/bar-simple.js.map +0 -0
  16. package/{src/charts → charts}/bar-stacked.d.ts +0 -0
  17. package/{src/charts → charts}/bar-stacked.js +1 -1
  18. package/{src/charts → charts}/bar-stacked.js.map +0 -0
  19. package/{src/charts → charts}/bubble.d.ts +0 -0
  20. package/{src/charts → charts}/bubble.js +1 -1
  21. package/{src/charts → charts}/bubble.js.map +0 -0
  22. package/{src/charts → charts}/donut.d.ts +0 -0
  23. package/{src/charts → charts}/donut.js +1 -1
  24. package/{src/charts → charts}/donut.js.map +0 -0
  25. package/{src/charts → charts}/index.d.ts +0 -0
  26. package/{src/charts → charts}/index.js +1 -1
  27. package/{src/charts → charts}/index.js.map +0 -0
  28. package/{src/charts → charts}/line.d.ts +0 -0
  29. package/{src/charts → charts}/line.js +1 -1
  30. package/{src/charts → charts}/line.js.map +0 -0
  31. package/{src/charts → charts}/pie.d.ts +0 -0
  32. package/{src/charts → charts}/pie.js +1 -1
  33. package/{src/charts → charts}/pie.js.map +0 -0
  34. package/{src/charts → charts}/scatter.d.ts +0 -0
  35. package/{src/charts → charts}/scatter.js +1 -1
  36. package/{src/charts → charts}/scatter.js.map +0 -0
  37. package/{src/components → components}/axes/axis.d.ts +0 -0
  38. package/{src/components → components}/axes/axis.js +1 -1
  39. package/{src/components → components}/axes/axis.js.map +0 -0
  40. package/{src/components → components}/axes/grid.d.ts +0 -0
  41. package/{src/components → components}/axes/grid.js +1 -1
  42. package/{src/components → components}/axes/grid.js.map +0 -0
  43. package/{src/components → components}/axes/two-dimensional-axes.d.ts +0 -0
  44. package/{src/components → components}/axes/two-dimensional-axes.js +1 -1
  45. package/{src/components → components}/axes/two-dimensional-axes.js.map +0 -0
  46. package/{src/components → components}/axes/zero-line.d.ts +0 -0
  47. package/{src/components → components}/axes/zero-line.js +1 -1
  48. package/{src/components → components}/axes/zero-line.js.map +0 -0
  49. package/{src/components → components}/component.d.ts +0 -0
  50. package/{src/components → components}/component.js +1 -1
  51. package/{src/components → components}/component.js.map +0 -0
  52. package/{src/components → components}/essentials/legend.d.ts +0 -0
  53. package/{src/components → components}/essentials/legend.js +1 -1
  54. package/{src/components → components}/essentials/legend.js.map +0 -0
  55. package/{src/components → components}/essentials/title.d.ts +0 -0
  56. package/{src/components → components}/essentials/title.js +1 -1
  57. package/{src/components → components}/essentials/title.js.map +0 -0
  58. package/{src/components → components}/essentials/tooltip-bar.d.ts +0 -0
  59. package/{src/components → components}/essentials/tooltip-bar.js +1 -1
  60. package/{src/components → components}/essentials/tooltip-bar.js.map +0 -0
  61. package/{src/components → components}/essentials/tooltip-scatter.d.ts +0 -0
  62. package/{src/components → components}/essentials/tooltip-scatter.js +1 -1
  63. package/{src/components → components}/essentials/tooltip-scatter.js.map +0 -0
  64. package/{src/components → components}/essentials/tooltip.d.ts +0 -0
  65. package/{src/components → components}/essentials/tooltip.js +1 -1
  66. package/{src/components → components}/essentials/tooltip.js.map +0 -0
  67. package/{src/components → components}/graphs/bar-grouped.d.ts +0 -0
  68. package/{src/components → components}/graphs/bar-grouped.js +1 -1
  69. package/{src/components → components}/graphs/bar-grouped.js.map +0 -0
  70. package/{src/components → components}/graphs/bar-simple.d.ts +0 -0
  71. package/{src/components → components}/graphs/bar-simple.js +1 -1
  72. package/{src/components → components}/graphs/bar-simple.js.map +0 -0
  73. package/{src/components → components}/graphs/bar-stacked.d.ts +0 -0
  74. package/{src/components → components}/graphs/bar-stacked.js +1 -1
  75. package/{src/components → components}/graphs/bar-stacked.js.map +0 -0
  76. package/{src/components → components}/graphs/bar.d.ts +0 -0
  77. package/{src/components → components}/graphs/bar.js +1 -1
  78. package/{src/components → components}/graphs/bar.js.map +0 -0
  79. package/{src/components → components}/graphs/bubble.d.ts +0 -0
  80. package/{src/components → components}/graphs/bubble.js +1 -1
  81. package/{src/components → components}/graphs/bubble.js.map +0 -0
  82. package/{src/components → components}/graphs/donut.d.ts +0 -0
  83. package/{src/components → components}/graphs/donut.js +1 -1
  84. package/{src/components → components}/graphs/donut.js.map +0 -0
  85. package/{src/components → components}/graphs/line.d.ts +0 -0
  86. package/{src/components → components}/graphs/line.js +1 -1
  87. package/{src/components → components}/graphs/line.js.map +0 -0
  88. package/{src/components → components}/graphs/pie.d.ts +0 -0
  89. package/{src/components → components}/graphs/pie.js +1 -1
  90. package/{src/components → components}/graphs/pie.js.map +0 -0
  91. package/{src/components → components}/graphs/scatter.d.ts +0 -0
  92. package/{src/components → components}/graphs/scatter.js +1 -1
  93. package/{src/components → components}/graphs/scatter.js.map +0 -0
  94. package/{src/components → components}/index.d.ts +0 -0
  95. package/{src/components → components}/index.js +1 -1
  96. package/{src/components → components}/index.js.map +0 -0
  97. package/{src/components → components}/layout/layout.d.ts +0 -0
  98. package/{src/components → components}/layout/layout.js +1 -1
  99. package/{src/components → components}/layout/layout.js.map +0 -0
  100. package/{src/components → components}/layout/spacer.d.ts +0 -0
  101. package/{src/components → components}/layout/spacer.js +1 -1
  102. package/{src/components → components}/layout/spacer.js.map +0 -0
  103. package/{src/configuration.d.ts → configuration.d.ts} +0 -0
  104. package/{src/configuration.js → configuration.js} +1 -1
  105. package/{src/configuration.js.map → configuration.js.map} +0 -0
  106. package/demo/demo-data/bundle.js +1 -0
  107. package/demo/demo-data/create-codesandbox.d.ts +2 -2
  108. package/demo/demo-data/create-codesandbox.js +1 -1
  109. package/demo/demo-data/create-codesandbox.js.map +1 -1
  110. package/demo/demo-data/step.js +1 -1
  111. package/demo/demo-data/step.js.map +1 -1
  112. package/demo/demo-options.d.ts +2 -0
  113. package/demo/demo-options.js +43 -0
  114. package/demo/demo-options.js.map +1 -0
  115. package/demo/index.d.ts +1 -0
  116. package/demo/index.js +128 -0
  117. package/demo/index.js.map +1 -0
  118. package/demo/tsconfig.tsbuildinfo +2801 -0
  119. package/{src/index.d.ts → index.d.ts} +0 -0
  120. package/index.js +9 -25
  121. package/{src/index.js.map → index.js.map} +0 -0
  122. package/{src/interfaces → interfaces}/a11y.d.ts +0 -0
  123. package/{src/interfaces → interfaces}/a11y.js +1 -1
  124. package/{src/interfaces → interfaces}/a11y.js.map +0 -0
  125. package/{src/interfaces → interfaces}/axis-scales.d.ts +0 -0
  126. package/interfaces/axis-scales.js +1 -0
  127. package/{src/interfaces → interfaces}/axis-scales.js.map +0 -0
  128. package/{src/interfaces → interfaces}/charts.d.ts +0 -0
  129. package/interfaces/charts.js +1 -0
  130. package/{src/interfaces → interfaces}/charts.js.map +0 -0
  131. package/{src/interfaces → interfaces}/components.d.ts +0 -0
  132. package/interfaces/components.js +1 -0
  133. package/{src/interfaces → interfaces}/components.js.map +0 -0
  134. package/{src/interfaces → interfaces}/enums.d.ts +0 -0
  135. package/{src/interfaces → interfaces}/enums.js +1 -1
  136. package/{src/interfaces → interfaces}/enums.js.map +0 -0
  137. package/{src/interfaces → interfaces}/events.d.ts +0 -0
  138. package/{src/interfaces → interfaces}/events.js +1 -1
  139. package/{src/interfaces → interfaces}/events.js.map +0 -0
  140. package/{src/interfaces → interfaces}/index.d.ts +0 -0
  141. package/interfaces/index.js +3 -0
  142. package/{src/interfaces → interfaces}/index.js.map +0 -0
  143. package/{src/interfaces → interfaces}/layout.d.ts +0 -0
  144. package/interfaces/layout.js +1 -0
  145. package/{src/interfaces → interfaces}/layout.js.map +0 -0
  146. package/{src/interfaces → interfaces}/model.d.ts +0 -0
  147. package/interfaces/model.js +1 -0
  148. package/{src/interfaces → interfaces}/model.js.map +0 -0
  149. package/{src/model-pie.d.ts → model-pie.d.ts} +0 -0
  150. package/{src/model-pie.js → model-pie.js} +1 -1
  151. package/{src/model-pie.js.map → model-pie.js.map} +0 -0
  152. package/{src/model-simple-bar.d.ts → model-simple-bar.d.ts} +0 -0
  153. package/{src/model-simple-bar.js → model-simple-bar.js} +1 -1
  154. package/{src/model-simple-bar.js.map → model-simple-bar.js.map} +0 -0
  155. package/{src/model.d.ts → model.d.ts} +0 -0
  156. package/{src/model.js → model.js} +1 -1
  157. package/{src/model.js.map → model.js.map} +0 -0
  158. package/package.json +12 -8
  159. package/{src/polyfills.d.ts → polyfills.d.ts} +0 -0
  160. package/{src/polyfills.js → polyfills.js} +1 -1
  161. package/{src/polyfills.js.map → polyfills.js.map} +0 -0
  162. package/{src/services → services}/colorPalettes.d.ts +0 -0
  163. package/{src/services → services}/colorPalettes.js +1 -1
  164. package/{src/services → services}/colorPalettes.js.map +0 -0
  165. package/{src/services → services}/colors.d.ts +0 -0
  166. package/{src/services → services}/colors.js +1 -1
  167. package/{src/services → services}/colors.js.map +0 -0
  168. package/{src/services → services}/curves.d.ts +0 -0
  169. package/{src/services → services}/curves.js +1 -1
  170. package/{src/services → services}/curves.js.map +0 -0
  171. package/{src/services → services}/essentials/dom-utils.d.ts +0 -0
  172. package/{src/services → services}/essentials/dom-utils.js +1 -1
  173. package/{src/services → services}/essentials/dom-utils.js.map +0 -0
  174. package/{src/services → services}/essentials/events.d.ts +0 -0
  175. package/{src/services → services}/essentials/events.js +1 -1
  176. package/{src/services → services}/essentials/events.js.map +0 -0
  177. package/{src/services → services}/essentials/transitions.d.ts +0 -0
  178. package/{src/services → services}/essentials/transitions.js +1 -1
  179. package/{src/services → services}/essentials/transitions.js.map +0 -0
  180. package/{src/services → services}/index.d.ts +0 -0
  181. package/{src/services → services}/index.js +1 -1
  182. package/{src/services → services}/index.js.map +0 -0
  183. package/{src/services → services}/scales-cartesian.d.ts +0 -0
  184. package/{src/services → services}/scales-cartesian.js +1 -1
  185. package/{src/services → services}/scales-cartesian.js.map +0 -0
  186. package/{src/services → services}/service.d.ts +0 -0
  187. package/{src/services → services}/service.js +1 -1
  188. package/{src/services → services}/service.js.map +0 -0
  189. package/{src/tools.d.ts → tools.d.ts} +16 -15
  190. package/{src/tools.js → tools.js} +1 -1
  191. package/{src/tools.js.map → tools.js.map} +0 -0
  192. package/tsconfig.tsbuildinfo +3102 -0
  193. package/src/axis-chart.js.map +0 -1
  194. package/src/chart.js.map +0 -1
  195. package/src/index.js +0 -9
  196. package/src/interfaces/axis-scales.js +0 -1
  197. package/src/interfaces/charts.js +0 -1
  198. package/src/interfaces/components.js +0 -1
  199. package/src/interfaces/index.js +0 -3
  200. package/src/interfaces/layout.js +0 -1
  201. package/src/interfaces/model.js +0 -1
  202. package/src/tests/index.d.ts +0 -1
  203. package/src/tests/index.js +0 -2
  204. package/src/tests/index.js.map +0 -1
  205. package/src/tests/test-environment.d.ts +0 -13
  206. package/src/tests/test-environment.js +0 -32
  207. package/src/tests/test-environment.js.map +0 -1
  208. package/src/tests/tools.d.ts +0 -3
  209. package/src/tests/tools.js +0 -13
  210. package/src/tests/tools.js.map +0 -1
package/bundle.js CHANGED
@@ -1,25 +1 @@
1
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).Charts={})}(this,(function(t){"use strict";
2
- /*! *****************************************************************************
3
- Copyright (c) Microsoft Corporation. All rights reserved.
4
- Licensed under the Apache License, Version 2.0 (the "License"); you may not use
5
- this file except in compliance with the License. You may obtain a copy of the
6
- License at http://www.apache.org/licenses/LICENSE-2.0
7
-
8
- THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
9
- KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
10
- WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
11
- MERCHANTABLITY OR NON-INFRINGEMENT.
12
-
13
- See the Apache Version 2.0 License for specific language governing permissions
14
- and limitations under the License.
15
- ***************************************************************************** */var e,n,r,i,o,a=function(t,e){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function s(t,e){function n(){this.constructor=t}a(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}!function(t){t.GRAPHICS_DOCUMENT="graphics-document",t.GRAPHICS_OBJECT="graphics-object",t.GRAPHICS_SYMBOL="graphics-symbol",t.GROUP="group"}(e||(e={})),function(t){t.SLICE_MOUSEOVER="pie-slice-mouseover",t.SLICE_MOUSEMOVE="pie-slice-mousemove",t.SLICE_CLICK="pie-slice-click",t.SLICE_MOUSEOUT="pie-slice-mouseout"}(n||(n={})),function(t){t.BAR_MOUSEOVER="bar-mouseover",t.BAR_MOUSEMOVE="bar-mousemove",t.BAR_CLICK="bar-click",t.BAR_MOUSEOUT="bar-mouseout"}(r||(r={})),function(t){t.SCATTER_MOUSEOVER="scatter-mouseover",t.SCATTER_MOUSEMOVE="scatter-mousemove",t.SCATTER_CLICK="scatter-click",t.SCATTER_MOUSEOUT="scatter-mouseout"}(i||(i={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(o||(o={}));var u,l,c,f,h,p,d,v,g,y,_,m,b=Object.freeze({__proto__:null,get Pie(){return n},get Bar(){return r},get Scatter(){return i},get Line(){return o}});!function(t){t.DEFAULT="default",t.G100="g100",t.G90="g90",t.G10="g10"}(u||(u={})),function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(l||(l={})),function(t){t.VERTICAL="vertical",t.HORIZONTAL="horizontal"}(c||(c={})),function(t){t.PRIMARY="primary",t.SECONDARY="secondary"}(f||(f={})),function(t){t.TIME="time",t.LINEAR="linear",t.LOG="log",t.LABELS="labels"}(h||(h={})),function(t){t.MOUSE="mouse",t.TOP="top",t.BOTTOM="bottom"}(p||(p={})),function(t){t.DATAPOINT="datapoint",t.GRIDLINE="gridline",t.TITLE="title"}(d||(d={})),function(t){t.RIGHT="right",t.LEFT="left",t.TOP="top",t.BOTTOM="bottom"}(v||(v={})),function(t){t.HORIZONTAL="horizontal",t.VERTICAL="vertical"}(g||(g={})),function(t){t.ROW="row",t.COLUMN="column",t.ROW_REVERSE="row-reverse",t.COLUMN_REVERSE="column-reverse"}(y||(y={})),function(t){t.FIXED="fixed",t.PREFERRED="preferred",t.STRETCH="stretch"}(_||(_={})),function(t){t.LEFT="left",t.RIGHT="right"}(m||(m={}));var x=Object.freeze({__proto__:null,get Roles(){return e},Events:b,get ChartTheme(){return u},get AxisPositions(){return l},get CartesianOrientations(){return c},get AxisTypes(){return f},get ScaleTypes(){return h},get TooltipPosition(){return p},get TooltipTypes(){return d},get LegendPositions(){return v},get LegendOrientations(){return g},get LayoutDirection(){return y},get LayoutGrowth(){return _},get CalloutDirections(){return m}}),w="object"==typeof global&&global&&global.Object===Object&&global,O="object"==typeof self&&self&&self.Object===Object&&self,E=w||O||Function("return this")(),T=E.Symbol,S=Object.prototype,M=S.hasOwnProperty,A=S.toString,k=T?T.toStringTag:void 0;var L=Object.prototype.toString;var C=T?T.toStringTag:void 0;function R(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":C&&C in Object(t)?function(t){var e=M.call(t,k),n=t[k];try{t[k]=void 0;var r=!0}catch(t){}var i=A.call(t);return r&&(e?t[k]=n:delete t[k]),i}(t):function(t){return L.call(t)}(t)}function P(t){return null!=t&&"object"==typeof t}function j(t){return"symbol"==typeof t||P(t)&&"[object Symbol]"==R(t)}function D(t){return"number"==typeof t?t:j(t)?NaN:+t}function I(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}var N=Array.isArray,B=T?T.prototype:void 0,F=B?B.toString:void 0;function z(t){if("string"==typeof t)return t;if(N(t))return I(t,z)+"";if(j(t))return F?F.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function V(t,e){return function(n,r){var i;if(void 0===n&&void 0===r)return e;if(void 0!==n&&(i=n),void 0!==r){if(void 0===i)return r;"string"==typeof n||"string"==typeof r?(n=z(n),r=z(r)):(n=D(n),r=D(r)),i=t(n,r)}return i}}var G=V((function(t,e){return t+e}),0);function U(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var H=/^\s+|\s+$/g,W=/^[-+]0x[0-9a-f]+$/i,q=/^0b[01]+$/i,Y=/^0o[0-7]+$/i,X=parseInt;function $(t){if("number"==typeof t)return t;if(j(t))return NaN;if(U(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=U(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(H,"");var n=q.test(t);return n||Y.test(t)?X(t.slice(2),n?2:8):W.test(t)?NaN:+t}function Z(t){return t?(t=$(t))===1/0||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function K(t){var e=Z(t),n=e%1;return e==e?n?e-n:e:0}function J(t){return t}function Q(t){if(!U(t))return!1;var e=R(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var tt,et=E["__core-js_shared__"],nt=(tt=/[^.]+$/.exec(et&&et.keys&&et.keys.IE_PROTO||""))?"Symbol(src)_1."+tt:"";var rt=Function.prototype.toString;function it(t){if(null!=t){try{return rt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var ot=/^\[object .+?Constructor\]$/,at=Function.prototype,st=Object.prototype,ut=at.toString,lt=st.hasOwnProperty,ct=RegExp("^"+ut.call(lt).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ft(t){return!(!U(t)||function(t){return!!nt&&nt in t}(t))&&(Q(t)?ct:ot).test(it(t))}function ht(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return ft(n)?n:void 0}var pt=ht(E,"WeakMap"),dt=pt&&new pt,vt=dt?function(t,e){return dt.set(t,e),t}:J,gt=Object.create,yt=function(){function t(){}return function(e){if(!U(e))return{};if(gt)return gt(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();function _t(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=yt(t.prototype),r=t.apply(n,e);return U(r)?r:n}}function mt(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}var bt=Math.max;function xt(t,e,n,r){for(var i=-1,o=t.length,a=n.length,s=-1,u=e.length,l=bt(o-a,0),c=Array(u+l),f=!r;++s<u;)c[s]=e[s];for(;++i<a;)(f||i<o)&&(c[n[i]]=t[i]);for(;l--;)c[s++]=t[i++];return c}var wt=Math.max;function Ot(t,e,n,r){for(var i=-1,o=t.length,a=-1,s=n.length,u=-1,l=e.length,c=wt(o-s,0),f=Array(c+l),h=!r;++i<c;)f[i]=t[i];for(var p=i;++u<l;)f[p+u]=e[u];for(;++a<s;)(h||i<o)&&(f[p+n[a]]=t[i++]);return f}function Et(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}function Tt(){}function St(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Mt(){}St.prototype=yt(Tt.prototype),St.prototype.constructor=St;var At=dt?function(t){return dt.get(t)}:Mt,kt={},Lt=Object.prototype.hasOwnProperty;function Ct(t){for(var e=t.name+"",n=kt[e],r=Lt.call(kt,e)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==t)return i.name}return e}function Rt(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=void 0}function Pt(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}function jt(t){if(t instanceof St)return t.clone();var e=new Rt(t.__wrapped__,t.__chain__);return e.__actions__=Pt(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}Rt.prototype=yt(Tt.prototype),Rt.prototype.constructor=Rt;var Dt=Object.prototype.hasOwnProperty;function It(t){if(P(t)&&!N(t)&&!(t instanceof St)){if(t instanceof Rt)return t;if(Dt.call(t,"__wrapped__"))return jt(t)}return new Rt(t)}function Nt(t){var e=Ct(t),n=It[e];if("function"!=typeof n||!(e in St.prototype))return!1;if(t===n)return!0;var r=At(n);return!!r&&t===r[0]}It.prototype=Tt.prototype,It.prototype.constructor=It;var Bt=Date.now;function Ft(t){var e=0,n=0;return function(){var r=Bt(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var zt=Ft(vt),Vt=/\{\n\/\* \[wrapped with (.+)\] \*/,Gt=/,? & /;var Ut=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function Ht(t){return function(){return t}}var Wt=function(){try{var t=ht(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),qt=Ft(Wt?function(t,e){return Wt(t,"toString",{configurable:!0,enumerable:!1,value:Ht(e),writable:!0})}:J);function Yt(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function Xt(t,e,n,r){for(var i=t.length,o=n+(r?1:-1);r?o--:++o<i;)if(e(t[o],o,t))return o;return-1}function $t(t){return t!=t}function Zt(t,e,n){return e==e?function(t,e,n){for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}(t,e,n):Xt(t,$t,n)}function Kt(t,e){return!!(null==t?0:t.length)&&Zt(t,e,0)>-1}var Jt=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];function Qt(t,e,n){var r=e+"";return qt(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(Ut,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return Yt(Jt,(function(n){var r="_."+n[0];e&n[1]&&!Kt(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(Vt);return e?e[1].split(Gt):[]}(r),n)))}function te(t,e,n,r,i,o,a,s,u,l){var c=8&e;e|=c?32:64,4&(e&=~(c?64:32))||(e&=-4);var f=[t,e,i,c?o:void 0,c?a:void 0,c?void 0:o,c?void 0:a,s,u,l],h=n.apply(void 0,f);return Nt(t)&&zt(h,f),h.placeholder=r,Qt(h,t,e)}function ee(t){return t.placeholder}var ne=/^(?:0|[1-9]\d*)$/;function re(t,e){var n=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==n||"symbol"!=n&&ne.test(t))&&t>-1&&t%1==0&&t<e}var ie=Math.min;function oe(t,e){for(var n=t.length,r=ie(e.length,n),i=Pt(t);r--;){var o=e[r];t[r]=re(o,n)?i[o]:void 0}return t}function ae(t,e){for(var n=-1,r=t.length,i=0,o=[];++n<r;){var a=t[n];a!==e&&"__lodash_placeholder__"!==a||(t[n]="__lodash_placeholder__",o[i++]=n)}return o}function se(t,e,n,r,i,o,a,s,u,l){var c=128&e,f=1&e,h=2&e,p=24&e,d=512&e,v=h?void 0:_t(t);return function g(){for(var y=arguments.length,_=Array(y),m=y;m--;)_[m]=arguments[m];if(p)var b=ee(g),x=Et(_,b);if(r&&(_=xt(_,r,i,p)),o&&(_=Ot(_,o,a,p)),y-=x,p&&y<l){var w=ae(_,b);return te(t,e,se,g.placeholder,n,_,w,s,u,l-y)}var O=f?n:this,T=h?O[t]:t;return y=_.length,s?_=oe(_,s):d&&y>1&&_.reverse(),c&&u<y&&(_.length=u),this&&this!==E&&this instanceof g&&(T=v||_t(T)),T.apply(O,_)}}var ue=Math.min;var le=Math.max;function ce(t,e,n,r,i,o,a,s){var u=2&e;if(!u&&"function"!=typeof t)throw new TypeError("Expected a function");var l=r?r.length:0;if(l||(e&=-97,r=i=void 0),a=void 0===a?a:le(K(a),0),s=void 0===s?s:K(s),l-=i?i.length:0,64&e){var c=r,f=i;r=i=void 0}var h=u?void 0:At(t),p=[t,e,n,r,i,c,f,o,a,s];if(h&&function(t,e){var n=t[1],r=e[1],i=n|r,o=i<131,a=128==r&&8==n||128==r&&256==n&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!o&&!a)return t;1&r&&(t[2]=e[2],i|=1&n?0:4);var s=e[3];if(s){var u=t[3];t[3]=u?xt(u,s,e[4]):s,t[4]=u?ae(t[3],"__lodash_placeholder__"):e[4]}(s=e[5])&&(u=t[5],t[5]=u?Ot(u,s,e[6]):s,t[6]=u?ae(t[5],"__lodash_placeholder__"):e[6]),(s=e[7])&&(t[7]=s),128&r&&(t[8]=null==t[8]?e[8]:ue(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i}(p,h),t=p[0],e=p[1],n=p[2],r=p[3],i=p[4],!(s=p[9]=void 0===p[9]?u?0:t.length:le(p[9]-l,0))&&24&e&&(e&=-25),e&&1!=e)d=8==e||16==e?function(t,e,n){var r=_t(t);return function i(){for(var o=arguments.length,a=Array(o),s=o,u=ee(i);s--;)a[s]=arguments[s];var l=o<3&&a[0]!==u&&a[o-1]!==u?[]:ae(a,u);if((o-=l.length)<n)return te(t,e,se,i.placeholder,void 0,a,l,void 0,void 0,n-o);var c=this&&this!==E&&this instanceof i?r:t;return mt(c,this,a)}}(t,e,s):32!=e&&33!=e||i.length?se.apply(void 0,p):function(t,e,n,r){var i=1&e,o=_t(t);return function e(){for(var a=-1,s=arguments.length,u=-1,l=r.length,c=Array(l+s),f=this&&this!==E&&this instanceof e?o:t;++u<l;)c[u]=r[u];for(;s--;)c[u++]=arguments[++a];return mt(f,i?n:this,c)}}(t,e,n,r);else var d=function(t,e,n){var r=1&e,i=_t(t);return function e(){var o=this&&this!==E&&this instanceof e?i:t;return o.apply(r?n:this,arguments)}}(t,e,n);return Qt((h?vt:zt)(d,p),t,e)}function fe(t,e,n){return e=n?void 0:e,ce(t,128,void 0,void 0,void 0,void 0,e=t&&null==e?t.length:e)}function he(t,e,n){"__proto__"==e&&Wt?Wt(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function pe(t,e){return t===e||t!=t&&e!=e}var de=Object.prototype.hasOwnProperty;function ve(t,e,n){var r=t[e];de.call(t,e)&&pe(r,n)&&(void 0!==n||e in t)||he(t,e,n)}function ge(t,e,n,r){var i=!n;n||(n={});for(var o=-1,a=e.length;++o<a;){var s=e[o],u=r?r(n[s],t[s],s,n,t):void 0;void 0===u&&(u=t[s]),i?he(n,s,u):ve(n,s,u)}return n}var ye=Math.max;function _e(t,e,n){return e=ye(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,o=ye(r.length-e,0),a=Array(o);++i<o;)a[i]=r[e+i];i=-1;for(var s=Array(e+1);++i<e;)s[i]=r[i];return s[e]=n(a),mt(t,this,s)}}function me(t,e){return qt(_e(t,e,J),t+"")}function be(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}function xe(t){return null!=t&&be(t.length)&&!Q(t)}function we(t,e,n){if(!U(n))return!1;var r=typeof e;return!!("number"==r?xe(n)&&re(e,n.length):"string"==r&&e in n)&&pe(n[e],t)}function Oe(t){return me((function(e,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;for(o=t.length>3&&"function"==typeof o?(i--,o):void 0,a&&we(n[0],n[1],a)&&(o=i<3?void 0:o,i=1),e=Object(e);++r<i;){var s=n[r];s&&t(e,s,r,o)}return e}))}var Ee=Object.prototype;function Te(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Ee)}function Se(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Me(t){return P(t)&&"[object Arguments]"==R(t)}var Ae=Object.prototype,ke=Ae.hasOwnProperty,Le=Ae.propertyIsEnumerable,Ce=Me(function(){return arguments}())?Me:function(t){return P(t)&&ke.call(t,"callee")&&!Le.call(t,"callee")};function Re(){return!1}var Pe="object"==typeof t&&t&&!t.nodeType&&t,je=Pe&&"object"==typeof module&&module&&!module.nodeType&&module,De=je&&je.exports===Pe?E.Buffer:void 0,Ie=(De?De.isBuffer:void 0)||Re,Ne={};function Be(t){return function(e){return t(e)}}Ne["[object Float32Array]"]=Ne["[object Float64Array]"]=Ne["[object Int8Array]"]=Ne["[object Int16Array]"]=Ne["[object Int32Array]"]=Ne["[object Uint8Array]"]=Ne["[object Uint8ClampedArray]"]=Ne["[object Uint16Array]"]=Ne["[object Uint32Array]"]=!0,Ne["[object Arguments]"]=Ne["[object Array]"]=Ne["[object ArrayBuffer]"]=Ne["[object Boolean]"]=Ne["[object DataView]"]=Ne["[object Date]"]=Ne["[object Error]"]=Ne["[object Function]"]=Ne["[object Map]"]=Ne["[object Number]"]=Ne["[object Object]"]=Ne["[object RegExp]"]=Ne["[object Set]"]=Ne["[object String]"]=Ne["[object WeakMap]"]=!1;var Fe="object"==typeof t&&t&&!t.nodeType&&t,ze=Fe&&"object"==typeof module&&module&&!module.nodeType&&module,Ve=ze&&ze.exports===Fe&&w.process,Ge=function(){try{var t=ze&&ze.require&&ze.require("util").types;return t||Ve&&Ve.binding&&Ve.binding("util")}catch(t){}}(),Ue=Ge&&Ge.isTypedArray,He=Ue?Be(Ue):function(t){return P(t)&&be(t.length)&&!!Ne[R(t)]},We=Object.prototype.hasOwnProperty;function qe(t,e){var n=N(t),r=!n&&Ce(t),i=!n&&!r&&Ie(t),o=!n&&!r&&!i&&He(t),a=n||r||i||o,s=a?Se(t.length,String):[],u=s.length;for(var l in t)!e&&!We.call(t,l)||a&&("length"==l||i&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||re(l,u))||s.push(l);return s}function Ye(t,e){return function(n){return t(e(n))}}var Xe=Ye(Object.keys,Object),$e=Object.prototype.hasOwnProperty;function Ze(t){if(!Te(t))return Xe(t);var e=[];for(var n in Object(t))$e.call(t,n)&&"constructor"!=n&&e.push(n);return e}function Ke(t){return xe(t)?qe(t):Ze(t)}var Je=Object.prototype.hasOwnProperty,Qe=Oe((function(t,e){if(Te(e)||xe(e))ge(e,Ke(e),t);else for(var n in e)Je.call(e,n)&&ve(t,n,e[n])}));var tn=Object.prototype.hasOwnProperty;function en(t){if(!U(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=Te(t),n=[];for(var r in t)("constructor"!=r||!e&&tn.call(t,r))&&n.push(r);return n}function nn(t){return xe(t)?qe(t,!0):en(t)}var rn=Oe((function(t,e){ge(e,nn(e),t)})),on=Oe((function(t,e,n,r){ge(e,nn(e),t,r)})),an=Oe((function(t,e,n,r){ge(e,Ke(e),t,r)})),sn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,un=/^\w*$/;function ln(t,e){if(N(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!j(t))||(un.test(t)||!sn.test(t)||null!=e&&t in Object(e))}var cn=ht(Object,"create");var fn=Object.prototype.hasOwnProperty;var hn=Object.prototype.hasOwnProperty;function pn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function dn(t,e){for(var n=t.length;n--;)if(pe(t[n][0],e))return n;return-1}pn.prototype.clear=function(){this.__data__=cn?cn(null):{},this.size=0},pn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},pn.prototype.get=function(t){var e=this.__data__;if(cn){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return fn.call(e,t)?e[t]:void 0},pn.prototype.has=function(t){var e=this.__data__;return cn?void 0!==e[t]:hn.call(e,t)},pn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=cn&&void 0===e?"__lodash_hash_undefined__":e,this};var vn=Array.prototype.splice;function gn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}gn.prototype.clear=function(){this.__data__=[],this.size=0},gn.prototype.delete=function(t){var e=this.__data__,n=dn(e,t);return!(n<0)&&(n==e.length-1?e.pop():vn.call(e,n,1),--this.size,!0)},gn.prototype.get=function(t){var e=this.__data__,n=dn(e,t);return n<0?void 0:e[n][1]},gn.prototype.has=function(t){return dn(this.__data__,t)>-1},gn.prototype.set=function(t,e){var n=this.__data__,r=dn(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var yn=ht(E,"Map");function _n(t,e){var n,r,i=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof e?"string":"hash"]:i.map}function mn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}mn.prototype.clear=function(){this.size=0,this.__data__={hash:new pn,map:new(yn||gn),string:new pn}},mn.prototype.delete=function(t){var e=_n(this,t).delete(t);return this.size-=e?1:0,e},mn.prototype.get=function(t){return _n(this,t).get(t)},mn.prototype.has=function(t){return _n(this,t).has(t)},mn.prototype.set=function(t,e){var n=_n(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};function bn(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=t.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(bn.Cache||mn),n}bn.Cache=mn;var xn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,wn=/\\(\\)?/g,On=function(t){var e=bn(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(xn,(function(t,n,r,i){e.push(r?i.replace(wn,"$1"):n||t)})),e}));function En(t){return null==t?"":z(t)}function Tn(t,e){return N(t)?t:ln(t,e)?[t]:On(En(t))}function Sn(t){if("string"==typeof t||j(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Mn(t,e){for(var n=0,r=(e=Tn(e,t)).length;null!=t&&n<r;)t=t[Sn(e[n++])];return n&&n==r?t:void 0}function An(t,e,n){var r=null==t?void 0:Mn(t,e);return void 0===r?n:r}function kn(t,e){for(var n=-1,r=e.length,i=Array(r),o=null==t;++n<r;)i[n]=o?void 0:An(t,e[n]);return i}function Ln(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}var Cn=T?T.isConcatSpreadable:void 0;function Rn(t){return N(t)||Ce(t)||!!(Cn&&t&&t[Cn])}function Pn(t,e,n,r,i){var o=-1,a=t.length;for(n||(n=Rn),i||(i=[]);++o<a;){var s=t[o];e>0&&n(s)?e>1?Pn(s,e-1,n,r,i):Ln(i,s):r||(i[i.length]=s)}return i}function jn(t){return(null==t?0:t.length)?Pn(t,1):[]}function Dn(t){return qt(_e(t,void 0,jn),t+"")}var In=Dn(kn),Nn=Ye(Object.getPrototypeOf,Object),Bn=Function.prototype,Fn=Object.prototype,zn=Bn.toString,Vn=Fn.hasOwnProperty,Gn=zn.call(Object);function Un(t){if(!P(t)||"[object Object]"!=R(t))return!1;var e=Nn(t);if(null===e)return!0;var n=Vn.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&zn.call(n)==Gn}function Hn(t){if(!P(t))return!1;var e=R(t);return"[object Error]"==e||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!Un(t)}var Wn=me((function(t,e){try{return mt(t,void 0,e)}catch(t){return Hn(t)?t:new Error(t)}}));function qn(t,e){var n;if("function"!=typeof e)throw new TypeError("Expected a function");return t=K(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=void 0),n}}var Yn=me((function(t,e,n){var r=1;if(n.length){var i=ae(n,ee(Yn));r|=32}return ce(t,r,e,n,i)}));Yn.placeholder={};var Xn=Dn((function(t,e){return Yt(e,(function(e){e=Sn(e),he(t,e,Yn(t[e],t))})),t})),$n=me((function(t,e,n){var r=3;if(n.length){var i=ae(n,ee($n));r|=32}return ce(e,r,t,n,i)}));function Zn(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=Array(i);++r<i;)o[r]=t[r+e];return o}function Kn(t,e,n){var r=t.length;return n=void 0===n?r:n,!e&&n>=r?t:Zn(t,e,n)}$n.placeholder={};var Jn=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");function Qn(t){return Jn.test(t)}var tr="[\\ud800-\\udfff]",er="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",nr="\\ud83c[\\udffb-\\udfff]",rr="[^\\ud800-\\udfff]",ir="(?:\\ud83c[\\udde6-\\uddff]){2}",or="[\\ud800-\\udbff][\\udc00-\\udfff]",ar="(?:"+er+"|"+nr+")"+"?",sr="[\\ufe0e\\ufe0f]?"+ar+("(?:\\u200d(?:"+[rr,ir,or].join("|")+")[\\ufe0e\\ufe0f]?"+ar+")*"),ur="(?:"+[rr+er+"?",er,ir,or,tr].join("|")+")",lr=RegExp(nr+"(?="+nr+")|"+ur+sr,"g");function cr(t){return Qn(t)?function(t){return t.match(lr)||[]}(t):function(t){return t.split("")}(t)}function fr(t){return function(e){var n=Qn(e=En(e))?cr(e):void 0,r=n?n[0]:e.charAt(0),i=n?Kn(n,1).join(""):e.slice(1);return r[t]()+i}}var hr=fr("toUpperCase");function pr(t){return hr(En(t).toLowerCase())}function dr(t,e,n,r){var i=-1,o=null==t?0:t.length;for(r&&o&&(n=t[++i]);++i<o;)n=e(n,t[i],i,t);return n}function vr(t){return function(e){return null==t?void 0:t[e]}}var gr=vr({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),yr=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_r=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");function mr(t){return(t=En(t))&&t.replace(yr,gr).replace(_r,"")}var br=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var xr=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var wr="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Or="["+wr+"]",Er="\\d+",Tr="[\\u2700-\\u27bf]",Sr="[a-z\\xdf-\\xf6\\xf8-\\xff]",Mr="[^\\ud800-\\udfff"+wr+Er+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",Ar="(?:\\ud83c[\\udde6-\\uddff]){2}",kr="[\\ud800-\\udbff][\\udc00-\\udfff]",Lr="[A-Z\\xc0-\\xd6\\xd8-\\xde]",Cr="(?:"+Sr+"|"+Mr+")",Rr="(?:"+Lr+"|"+Mr+")",Pr="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",jr="[\\ufe0e\\ufe0f]?"+Pr+("(?:\\u200d(?:"+["[^\\ud800-\\udfff]",Ar,kr].join("|")+")[\\ufe0e\\ufe0f]?"+Pr+")*"),Dr="(?:"+[Tr,Ar,kr].join("|")+")"+jr,Ir=RegExp([Lr+"?"+Sr+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[Or,Lr,"$"].join("|")+")",Rr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[Or,Lr+Cr,"$"].join("|")+")",Lr+"?"+Cr+"+(?:['’](?:d|ll|m|re|s|t|ve))?",Lr+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Er,Dr].join("|"),"g");function Nr(t,e,n){return t=En(t),void 0===(e=n?void 0:e)?function(t){return xr.test(t)}(t)?function(t){return t.match(Ir)||[]}(t):function(t){return t.match(br)||[]}(t):t.match(e)||[]}var Br=RegExp("['’]","g");function Fr(t){return function(e){return dr(Nr(mr(e).replace(Br,"")),t,"")}}var zr=Fr((function(t,e,n){return e=e.toLowerCase(),t+(n?pr(e):e)}));var Vr=E.isFinite,Gr=Math.min;function Ur(t){var e=Math[t];return function(t,n){if(t=$(t),(n=null==n?0:Gr(K(n),292))&&Vr(t)){var r=(En(t)+"e").split("e");return+((r=(En(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var Hr=Ur("ceil");function Wr(t){var e=It(t);return e.__chain__=!0,e}var qr=Math.ceil,Yr=Math.max;function Xr(t,e,n){return t==t&&(void 0!==n&&(t=t<=n?t:n),void 0!==e&&(t=t>=e?t:e)),t}function $r(t){var e=this.__data__=new gn(t);this.size=e.size}function Zr(t,e){return t&&ge(e,Ke(e),t)}$r.prototype.clear=function(){this.__data__=new gn,this.size=0},$r.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},$r.prototype.get=function(t){return this.__data__.get(t)},$r.prototype.has=function(t){return this.__data__.has(t)},$r.prototype.set=function(t,e){var n=this.__data__;if(n instanceof gn){var r=n.__data__;if(!yn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new mn(r)}return n.set(t,e),this.size=n.size,this};var Kr="object"==typeof t&&t&&!t.nodeType&&t,Jr=Kr&&"object"==typeof module&&module&&!module.nodeType&&module,Qr=Jr&&Jr.exports===Kr?E.Buffer:void 0,ti=Qr?Qr.allocUnsafe:void 0;function ei(t,e){if(e)return t.slice();var n=t.length,r=ti?ti(n):new t.constructor(n);return t.copy(r),r}function ni(t,e){for(var n=-1,r=null==t?0:t.length,i=0,o=[];++n<r;){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}function ri(){return[]}var ii=Object.prototype.propertyIsEnumerable,oi=Object.getOwnPropertySymbols,ai=oi?function(t){return null==t?[]:(t=Object(t),ni(oi(t),(function(e){return ii.call(t,e)})))}:ri;var si=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)Ln(e,ai(t)),t=Nn(t);return e}:ri;function ui(t,e,n){var r=e(t);return N(t)?r:Ln(r,n(t))}function li(t){return ui(t,Ke,ai)}function ci(t){return ui(t,nn,si)}var fi=ht(E,"DataView"),hi=ht(E,"Promise"),pi=ht(E,"Set"),di=it(fi),vi=it(yn),gi=it(hi),yi=it(pi),_i=it(pt),mi=R;(fi&&"[object DataView]"!=mi(new fi(new ArrayBuffer(1)))||yn&&"[object Map]"!=mi(new yn)||hi&&"[object Promise]"!=mi(hi.resolve())||pi&&"[object Set]"!=mi(new pi)||pt&&"[object WeakMap]"!=mi(new pt))&&(mi=function(t){var e=R(t),n="[object Object]"==e?t.constructor:void 0,r=n?it(n):"";if(r)switch(r){case di:return"[object DataView]";case vi:return"[object Map]";case gi:return"[object Promise]";case yi:return"[object Set]";case _i:return"[object WeakMap]"}return e});var bi=mi,xi=Object.prototype.hasOwnProperty;var wi=E.Uint8Array;function Oi(t){var e=new t.constructor(t.byteLength);return new wi(e).set(new wi(t)),e}var Ei=/\w*$/;var Ti=T?T.prototype:void 0,Si=Ti?Ti.valueOf:void 0;function Mi(t,e){var n=e?Oi(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Ai(t,e,n){var r,i=t.constructor;switch(e){case"[object ArrayBuffer]":return Oi(t);case"[object Boolean]":case"[object Date]":return new i(+t);case"[object DataView]":return function(t,e){var n=e?Oi(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Mi(t,n);case"[object Map]":return new i;case"[object Number]":case"[object String]":return new i(t);case"[object RegExp]":return function(t){var e=new t.constructor(t.source,Ei.exec(t));return e.lastIndex=t.lastIndex,e}(t);case"[object Set]":return new i;case"[object Symbol]":return r=t,Si?Object(Si.call(r)):{}}}function ki(t){return"function"!=typeof t.constructor||Te(t)?{}:yt(Nn(t))}var Li=Ge&&Ge.isMap,Ci=Li?Be(Li):function(t){return P(t)&&"[object Map]"==bi(t)};var Ri=Ge&&Ge.isSet,Pi=Ri?Be(Ri):function(t){return P(t)&&"[object Set]"==bi(t)},ji={};function Di(t,e,n,r,i,o){var a,s=1&e,u=2&e,l=4&e;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!U(t))return t;var c=N(t);if(c){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&xi.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!s)return Pt(t,a)}else{var f=bi(t),h="[object Function]"==f||"[object GeneratorFunction]"==f;if(Ie(t))return ei(t,s);if("[object Object]"==f||"[object Arguments]"==f||h&&!i){if(a=u||h?{}:ki(t),!s)return u?function(t,e){return ge(t,si(t),e)}(t,function(t,e){return t&&ge(e,nn(e),t)}(a,t)):function(t,e){return ge(t,ai(t),e)}(t,Zr(a,t))}else{if(!ji[f])return i?t:{};a=Ai(t,f,s)}}o||(o=new $r);var p=o.get(t);if(p)return p;o.set(t,a),Pi(t)?t.forEach((function(r){a.add(Di(r,e,n,r,t,o))})):Ci(t)&&t.forEach((function(r,i){a.set(i,Di(r,e,n,i,t,o))}));var d=l?u?ci:li:u?keysIn:Ke,v=c?void 0:d(t);return Yt(v||t,(function(r,i){v&&(r=t[i=r]),ve(a,i,Di(r,e,n,i,t,o))})),a}ji["[object Arguments]"]=ji["[object Array]"]=ji["[object ArrayBuffer]"]=ji["[object DataView]"]=ji["[object Boolean]"]=ji["[object Date]"]=ji["[object Float32Array]"]=ji["[object Float64Array]"]=ji["[object Int8Array]"]=ji["[object Int16Array]"]=ji["[object Int32Array]"]=ji["[object Map]"]=ji["[object Number]"]=ji["[object Object]"]=ji["[object RegExp]"]=ji["[object Set]"]=ji["[object String]"]=ji["[object Symbol]"]=ji["[object Uint8Array]"]=ji["[object Uint8ClampedArray]"]=ji["[object Uint16Array]"]=ji["[object Uint32Array]"]=!0,ji["[object Error]"]=ji["[object Function]"]=ji["[object WeakMap]"]=!1;function Ii(t){return Di(t,5)}function Ni(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new mn;++e<n;)this.add(t[e])}function Bi(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}function Fi(t,e){return t.has(e)}Ni.prototype.add=Ni.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},Ni.prototype.has=function(t){return this.__data__.has(t)};function zi(t,e,n,r,i,o){var a=1&n,s=t.length,u=e.length;if(s!=u&&!(a&&u>s))return!1;var l=o.get(t);if(l&&o.get(e))return l==e;var c=-1,f=!0,h=2&n?new Ni:void 0;for(o.set(t,e),o.set(e,t);++c<s;){var p=t[c],d=e[c];if(r)var v=a?r(d,p,c,e,t,o):r(p,d,c,t,e,o);if(void 0!==v){if(v)continue;f=!1;break}if(h){if(!Bi(e,(function(t,e){if(!Fi(h,e)&&(p===t||i(p,t,n,r,o)))return h.push(e)}))){f=!1;break}}else if(p!==d&&!i(p,d,n,r,o)){f=!1;break}}return o.delete(t),o.delete(e),f}function Vi(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function Gi(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var Ui=T?T.prototype:void 0,Hi=Ui?Ui.valueOf:void 0;var Wi=Object.prototype.hasOwnProperty;var qi=Object.prototype.hasOwnProperty;function Yi(t,e,n,r,i,o){var a=N(t),s=N(e),u=a?"[object Array]":bi(t),l=s?"[object Array]":bi(e),c="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),f="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),h=u==l;if(h&&Ie(t)){if(!Ie(e))return!1;a=!0,c=!1}if(h&&!c)return o||(o=new $r),a||He(t)?zi(t,e,n,r,i,o):function(t,e,n,r,i,o,a){switch(n){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!o(new wi(t),new wi(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return pe(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var s=Vi;case"[object Set]":var u=1&r;if(s||(s=Gi),t.size!=e.size&&!u)return!1;var l=a.get(t);if(l)return l==e;r|=2,a.set(t,e);var c=zi(s(t),s(e),r,i,o,a);return a.delete(t),c;case"[object Symbol]":if(Hi)return Hi.call(t)==Hi.call(e)}return!1}(t,e,u,n,r,i,o);if(!(1&n)){var p=c&&qi.call(t,"__wrapped__"),d=f&&qi.call(e,"__wrapped__");if(p||d){var v=p?t.value():t,g=d?e.value():e;return o||(o=new $r),i(v,g,n,r,o)}}return!!h&&(o||(o=new $r),function(t,e,n,r,i,o){var a=1&n,s=li(t),u=s.length;if(u!=li(e).length&&!a)return!1;for(var l=u;l--;){var c=s[l];if(!(a?c in e:Wi.call(e,c)))return!1}var f=o.get(t);if(f&&o.get(e))return f==e;var h=!0;o.set(t,e),o.set(e,t);for(var p=a;++l<u;){var d=t[c=s[l]],v=e[c];if(r)var g=a?r(v,d,c,e,t,o):r(d,v,c,t,e,o);if(!(void 0===g?d===v||i(d,v,n,r,o):g)){h=!1;break}p||(p="constructor"==c)}if(h&&!p){var y=t.constructor,_=e.constructor;y!=_&&"constructor"in t&&"constructor"in e&&!("function"==typeof y&&y instanceof y&&"function"==typeof _&&_ instanceof _)&&(h=!1)}return o.delete(t),o.delete(e),h}(t,e,n,r,i,o))}function Xi(t,e,n,r,i){return t===e||(null==t||null==e||!P(t)&&!P(e)?t!=t&&e!=e:Yi(t,e,n,r,Xi,i))}function $i(t,e,n,r){var i=n.length,o=i,a=!r;if(null==t)return!o;for(t=Object(t);i--;){var s=n[i];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in t))return!1}for(;++i<o;){var u=(s=n[i])[0],l=t[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in t))return!1}else{var f=new $r;if(r)var h=r(l,c,u,t,e,f);if(!(void 0===h?Xi(c,l,3,r,f):h))return!1}}return!0}function Zi(t){return t==t&&!U(t)}function Ki(t){for(var e=Ke(t),n=e.length;n--;){var r=e[n],i=t[r];e[n]=[r,i,Zi(i)]}return e}function Ji(t,e){return function(n){return null!=n&&(n[t]===e&&(void 0!==e||t in Object(n)))}}function Qi(t){var e=Ki(t);return 1==e.length&&e[0][2]?Ji(e[0][0],e[0][1]):function(n){return n===t||$i(n,t,e)}}function to(t,e){return null!=t&&e in Object(t)}function eo(t,e,n){for(var r=-1,i=(e=Tn(e,t)).length,o=!1;++r<i;){var a=Sn(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:!!(i=null==t?0:t.length)&&be(i)&&re(a,i)&&(N(t)||Ce(t))}function no(t,e){return null!=t&&eo(t,e,to)}function ro(t,e){return ln(t)&&Zi(e)?Ji(Sn(t),e):function(n){var r=An(n,t);return void 0===r&&r===e?no(n,t):Xi(e,r,3)}}function io(t){return function(e){return null==e?void 0:e[t]}}function oo(t){return ln(t)?io(Sn(t)):function(t){return function(e){return Mn(e,t)}}(t)}function ao(t){return"function"==typeof t?t:null==t?J:"object"==typeof t?N(t)?ro(t[0],t[1]):Qi(t):oo(t)}function so(t,e,n){var r=n.length;if(null==t)return!r;for(t=Object(t);r--;){var i=n[r],o=e[i],a=t[i];if(void 0===a&&!(i in t)||!o(a))return!1}return!0}function uo(t,e,n,r){for(var i=-1,o=null==t?0:t.length;++i<o;){var a=t[i];e(r,a,n(a),t)}return r}function lo(t){return function(e,n,r){for(var i=-1,o=Object(e),a=r(e),s=a.length;s--;){var u=a[t?s:++i];if(!1===n(o[u],u,o))break}return e}}var co=lo();function fo(t,e){return t&&co(t,e,Ke)}function ho(t,e){return function(n,r){if(null==n)return n;if(!xe(n))return t(n,r);for(var i=n.length,o=e?i:-1,a=Object(n);(e?o--:++o<i)&&!1!==r(a[o],o,a););return n}}var po=ho(fo);function vo(t,e,n,r){return po(t,(function(t,i,o){e(r,t,n(t),o)})),r}function go(t,e){return function(n,r){var i=N(n)?uo:vo,o=e?e():{};return i(n,t,ao(r),o)}}var yo=Object.prototype.hasOwnProperty,_o=go((function(t,e,n){yo.call(t,n)?++t[n]:he(t,n,1)}));function mo(t,e,n){var r=ce(t,8,void 0,void 0,void 0,void 0,void 0,e=n?void 0:e);return r.placeholder=mo.placeholder,r}mo.placeholder={};function bo(t,e,n){var r=ce(t,16,void 0,void 0,void 0,void 0,void 0,e=n?void 0:e);return r.placeholder=bo.placeholder,r}bo.placeholder={};var xo=function(){return E.Date.now()},wo=Math.max,Oo=Math.min;function Eo(t,e,n){var r,i,o,a,s,u,l=0,c=!1,f=!1,h=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function p(e){var n=r,o=i;return r=i=void 0,l=e,a=t.apply(o,n)}function d(t){return l=t,s=setTimeout(g,e),c?p(t):a}function v(t){var n=t-u;return void 0===u||n>=e||n<0||f&&t-l>=o}function g(){var t=xo();if(v(t))return y(t);s=setTimeout(g,function(t){var n=e-(t-u);return f?Oo(n,o-(t-l)):n}(t))}function y(t){return s=void 0,h&&r?p(t):(r=i=void 0,a)}function _(){var t=xo(),n=v(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return d(u);if(f)return clearTimeout(s),s=setTimeout(g,e),p(u)}return void 0===s&&(s=setTimeout(g,e)),a}return e=$(e)||0,U(n)&&(c=!!n.leading,o=(f="maxWait"in n)?wo($(n.maxWait)||0,e):o,h="trailing"in n?!!n.trailing:h),_.cancel=function(){void 0!==s&&clearTimeout(s),l=0,r=u=i=s=void 0},_.flush=function(){return void 0===s?a:y(xo())},_}var To=Object.prototype,So=To.hasOwnProperty,Mo=me((function(t,e){t=Object(t);var n=-1,r=e.length,i=r>2?e[2]:void 0;for(i&&we(e[0],e[1],i)&&(r=1);++n<r;)for(var o=e[n],a=nn(o),s=-1,u=a.length;++s<u;){var l=a[s],c=t[l];(void 0===c||pe(c,To[l])&&!So.call(t,l))&&(t[l]=o[l])}return t}));function Ao(t,e,n){(void 0===n||pe(t[e],n))&&(void 0!==n||e in t)||he(t,e,n)}function ko(t){return P(t)&&xe(t)}function Lo(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}function Co(t){return ge(t,nn(t))}function Ro(t,e,n,r,i){t!==e&&co(e,(function(o,a){if(i||(i=new $r),U(o))!function(t,e,n,r,i,o,a){var s=Lo(t,n),u=Lo(e,n),l=a.get(u);if(l)Ao(t,n,l);else{var c=o?o(s,u,n+"",t,e,a):void 0,f=void 0===c;if(f){var h=N(u),p=!h&&Ie(u),d=!h&&!p&&He(u);c=u,h||p||d?N(s)?c=s:ko(s)?c=Pt(s):p?(f=!1,c=ei(u,!0)):d?(f=!1,c=Mi(u,!0)):c=[]:Un(u)||Ce(u)?(c=s,Ce(s)?c=Co(s):U(s)&&!Q(s)||(c=ki(u))):f=!1}f&&(a.set(u,c),i(c,u,r,o,a),a.delete(u)),Ao(t,n,c)}}(t,e,a,n,Ro,r,i);else{var s=r?r(Lo(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),Ao(t,a,s)}}),nn)}function Po(t,e,n,r,i,o){return U(t)&&U(e)&&(o.set(e,t),Ro(t,e,void 0,Po,o),o.delete(e)),t}var jo=Oe((function(t,e,n,r){Ro(t,e,n,r)})),Do=me((function(t){return t.push(void 0,Po),mt(jo,void 0,t)}));function Io(t,e,n){if("function"!=typeof t)throw new TypeError("Expected a function");return setTimeout((function(){t.apply(void 0,n)}),e)}var No=me((function(t,e){return Io(t,1,e)})),Bo=me((function(t,e,n){return Io(t,$(e)||0,n)}));function Fo(t,e,n){for(var r=-1,i=null==t?0:t.length;++r<i;)if(n(e,t[r]))return!0;return!1}function zo(t,e,n,r){var i=-1,o=Kt,a=!0,s=t.length,u=[],l=e.length;if(!s)return u;n&&(e=I(e,Be(n))),r?(o=Fo,a=!1):e.length>=200&&(o=Fi,a=!1,e=new Ni(e));t:for(;++i<s;){var c=t[i],f=null==n?c:n(c);if(c=r||0!==c?c:0,a&&f==f){for(var h=l;h--;)if(e[h]===f)continue t;u.push(c)}else o(e,f,r)||u.push(c)}return u}var Vo=me((function(t,e){return ko(t)?zo(t,Pn(e,1,ko,!0)):[]}));function Go(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}var Uo=me((function(t,e){var n=Go(e);return ko(n)&&(n=void 0),ko(t)?zo(t,Pn(e,1,ko,!0),ao(n)):[]})),Ho=me((function(t,e){var n=Go(e);return ko(n)&&(n=void 0),ko(t)?zo(t,Pn(e,1,ko,!0),void 0,n):[]})),Wo=V((function(t,e){return t/e}),1);function qo(t,e,n,r){for(var i=t.length,o=r?i:-1;(r?o--:++o<i)&&e(t[o],o,t););return n?Zn(t,r?0:o,r?o+1:i):Zn(t,r?o+1:0,r?i:o)}function Yo(t){return"function"==typeof t?t:J}function Xo(t,e){return(N(t)?Yt:po)(t,Yo(e))}function $o(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}var Zo=lo(!0);function Ko(t,e){return t&&Zo(t,e,Ke)}var Jo=ho(Ko,!0);function Qo(t,e){return(N(t)?$o:Jo)(t,Yo(e))}function ta(t){return function(e){var n=bi(e);return"[object Map]"==n?Vi(e):"[object Set]"==n?function(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}(e):function(t,e){return I(e,(function(e){return[e,t[e]]}))}(e,t(e))}}var ea=ta(Ke),na=ta(nn),ra=vr({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"}),ia=/[&<>"']/g,oa=RegExp(ia.source);function aa(t){return(t=En(t))&&oa.test(t)?t.replace(ia,ra):t}var sa=/[\\^$.*+?()[\]{}|]/g,ua=RegExp(sa.source);function la(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function ca(t,e){var n=!0;return po(t,(function(t,r,i){return n=!!e(t,r,i)})),n}function fa(t){return t?Xr(K(t),0,4294967295):0}function ha(t,e){var n=[];return po(t,(function(t,r,i){e(t,r,i)&&n.push(t)})),n}function pa(t){return function(e,n,r){var i=Object(e);if(!xe(e)){var o=ao(n);e=Ke(e),n=function(t){return o(i[t],t,i)}}var a=t(e,n,r);return a>-1?i[o?e[a]:a]:void 0}}var da=Math.max;function va(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:K(n);return i<0&&(i=da(r+i,0)),Xt(t,ao(e),i)}var ga=pa(va);function ya(t,e,n){var r;return n(t,(function(t,n,i){if(e(t,n,i))return r=n,!1})),r}var _a=Math.max,ma=Math.min;function ba(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r-1;return void 0!==n&&(i=K(n),i=n<0?_a(r+i,0):ma(i,r-1)),Xt(t,ao(e),i,!0)}var xa=pa(ba);function wa(t){return t&&t.length?t[0]:void 0}function Oa(t,e){var n=-1,r=xe(t)?Array(t.length):[];return po(t,(function(t,i,o){r[++n]=e(t,i,o)})),r}function Ea(t,e){return(N(t)?I:Oa)(t,ao(e))}var Ta=Ur("floor");function Sa(t){return Dn((function(e){var n=e.length,r=n,i=Rt.prototype.thru;for(t&&e.reverse();r--;){var o=e[r];if("function"!=typeof o)throw new TypeError("Expected a function");if(i&&!a&&"wrapper"==Ct(o))var a=new Rt([],!0)}for(r=a?r:n;++r<n;){var s=Ct(o=e[r]),u="wrapper"==s?At(o):void 0;a=u&&Nt(u[0])&&424==u[1]&&!u[4].length&&1==u[9]?a[Ct(u[0])].apply(a,u[3]):1==o.length&&Nt(o)?a[s]():a.thru(o)}return function(){var t=arguments,r=t[0];if(a&&1==t.length&&N(r))return a.plant(r).value();for(var i=0,o=n?e[i].apply(this,t):r;++i<n;)o=e[i].call(this,o);return o}}))}var Ma=Sa(),Aa=Sa(!0);function ka(t,e){return ni(e,(function(e){return Q(t[e])}))}var La=Object.prototype.hasOwnProperty,Ca=go((function(t,e,n){La.call(t,n)?t[n].push(e):he(t,n,[e])}));function Ra(t,e){return t>e}function Pa(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=$(e),n=$(n)),t(e,n)}}var ja=Pa(Ra),Da=Pa((function(t,e){return t>=e})),Ia=Object.prototype.hasOwnProperty;function Na(t,e){return null!=t&&Ia.call(t,e)}var Ba=Math.max,Fa=Math.min;function za(t){return"string"==typeof t||!N(t)&&P(t)&&"[object String]"==R(t)}function Va(t,e){return I(e,(function(e){return t[e]}))}function Ga(t){return null==t?[]:Va(t,Ke(t))}var Ua=Math.max;var Ha=Math.max;var Wa=Math.min;function qa(t,e,n){for(var r=n?Fo:Kt,i=t[0].length,o=t.length,a=o,s=Array(o),u=1/0,l=[];a--;){var c=t[a];a&&e&&(c=I(c,Be(e))),u=Wa(c.length,u),s[a]=!n&&(e||i>=120&&c.length>=120)?new Ni(a&&c):void 0}c=t[0];var f=-1,h=s[0];t:for(;++f<i&&l.length<u;){var p=c[f],d=e?e(p):p;if(p=n||0!==p?p:0,!(h?Fi(h,d):r(l,d,n))){for(a=o;--a;){var v=s[a];if(!(v?Fi(v,d):r(t[a],d,n)))continue t}h&&h.push(d),l.push(p)}}return l}function Ya(t){return ko(t)?t:[]}var Xa=me((function(t){var e=I(t,Ya);return e.length&&e[0]===t[0]?qa(e):[]})),$a=me((function(t){var e=Go(t),n=I(t,Ya);return e===Go(n)?e=void 0:n.pop(),n.length&&n[0]===t[0]?qa(n,ao(e)):[]})),Za=me((function(t){var e=Go(t),n=I(t,Ya);return(e="function"==typeof e?e:void 0)&&n.pop(),n.length&&n[0]===t[0]?qa(n,void 0,e):[]}));function Ka(t,e){return function(n,r){return function(t,e,n,r){return fo(t,(function(t,i,o){e(r,n(t),i,o)})),r}(n,t,e(r),{})}}var Ja=Object.prototype.toString,Qa=Ka((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Ja.call(e)),t[e]=n}),Ht(J)),ts=Object.prototype,es=ts.hasOwnProperty,ns=ts.toString,rs=Ka((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=ns.call(e)),es.call(t,e)?t[e].push(n):t[e]=[n]}),ao);function is(t,e){return e.length<2?t:Mn(t,Zn(e,0,-1))}function os(t,e,n){var r=null==(t=is(t,e=Tn(e,t)))?t:t[Sn(Go(e))];return null==r?void 0:mt(r,t,n)}var as=me(os),ss=me((function(t,e,n){var r=-1,i="function"==typeof e,o=xe(t)?Array(t.length):[];return po(t,(function(t){o[++r]=i?mt(e,t,n):os(t,e,n)})),o}));var us=Ge&&Ge.isArrayBuffer,ls=us?Be(us):function(t){return P(t)&&"[object ArrayBuffer]"==R(t)};var cs=Ge&&Ge.isDate,fs=cs?Be(cs):function(t){return P(t)&&"[object Date]"==R(t)};var hs=Object.prototype.hasOwnProperty;var ps=E.isFinite;function ds(t){return"number"==typeof t&&t==K(t)}function vs(t){return"number"==typeof t||P(t)&&"[object Number]"==R(t)}var gs=et?Q:Re;var ys=Ge&&Ge.isRegExp,_s=ys?Be(ys):function(t){return P(t)&&"[object RegExp]"==R(t)};var ms=Array.prototype.join;var bs=Fr((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),xs=go((function(t,e,n){he(t,n,e)}));var ws=Math.max,Os=Math.min;var Es=Fr((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Ts=fr("toLowerCase");function Ss(t,e){return t<e}var Ms=Pa(Ss),As=Pa((function(t,e){return t<=e}));function ks(t,e,n){for(var r=-1,i=t.length;++r<i;){var o=t[r],a=e(o);if(null!=a&&(void 0===s?a==a&&!j(a):n(a,s)))var s=a,u=o}return u}function Ls(t,e){for(var n,r=-1,i=t.length;++r<i;){var o=e(t[r]);void 0!==o&&(n=void 0===n?o:n+o)}return n}function Cs(t,e){var n=null==t?0:t.length;return n?Ls(t,e)/n:NaN}var Rs=Oe((function(t,e,n){Ro(t,e,n)})),Ps=me((function(t,e){return function(n){return os(n,t,e)}})),js=me((function(t,e){return function(n){return os(t,n,e)}}));function Ds(t,e,n){var r=Ke(e),i=ka(e,r),o=!(U(n)&&"chain"in n&&!n.chain),a=Q(t);return Yt(i,(function(n){var r=e[n];t[n]=r,a&&(t.prototype[n]=function(){var e=this.__chain__;if(o||e){var n=t(this.__wrapped__),i=n.__actions__=Pt(this.__actions__);return i.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Ln([this.value()],arguments))})})),t}var Is=V((function(t,e){return t*e}),1);function Ns(t){if("function"!=typeof t)throw new TypeError("Expected a function");return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}var Bs=T?T.iterator:void 0;function Fs(t){if(!t)return[];if(xe(t))return za(t)?cr(t):Pt(t);if(Bs&&t[Bs])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[Bs]());var e=bi(t);return("[object Map]"==e?Vi:"[object Set]"==e?Gi:Ga)(t)}function zs(t,e){var n=t.length;if(n)return re(e+=e<0?n:0,n)?t[e]:void 0}function Vs(t,e){return null==(t=is(t,e=Tn(e,t)))||delete t[Sn(Go(e))]}function Gs(t){return Un(t)?void 0:t}var Us=Dn((function(t,e){var n={};if(null==t)return n;var r=!1;e=I(e,(function(e){return e=Tn(e,t),r||(r=e.length>1),e})),ge(t,ci(t),n),r&&(n=Di(n,7,Gs));for(var i=e.length;i--;)Vs(n,e[i]);return n}));function Hs(t,e,n,r){if(!U(t))return t;for(var i=-1,o=(e=Tn(e,t)).length,a=o-1,s=t;null!=s&&++i<o;){var u=Sn(e[i]),l=n;if(i!=a){var c=s[u];void 0===(l=r?r(c,u,s):void 0)&&(l=U(c)?c:re(e[i+1])?[]:{})}ve(s,u,l),s=s[u]}return t}function Ws(t,e,n){for(var r=-1,i=e.length,o={};++r<i;){var a=e[r],s=Mn(t,a);n(s,a)&&Hs(o,Tn(a,t),s)}return o}function qs(t,e){if(null==t)return{};var n=I(ci(t),(function(t){return[t]}));return e=ao(e),Ws(t,n,(function(t,n){return e(t,n[0])}))}function Ys(t,e){if(t!==e){var n=void 0!==t,r=null===t,i=t==t,o=j(t),a=void 0!==e,s=null===e,u=e==e,l=j(e);if(!s&&!l&&!o&&t>e||o&&a&&u&&!s&&!l||r&&a&&u||!n&&u||!i)return 1;if(!r&&!o&&!l&&t<e||l&&n&&i&&!r&&!o||s&&n&&i||!a&&i||!u)return-1}return 0}function Xs(t,e,n){var r=-1;return e=I(e.length?e:[J],Be(ao)),function(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t}(Oa(t,(function(t,n,i){return{criteria:I(e,(function(e){return e(t)})),index:++r,value:t}})),(function(t,e){return function(t,e,n){for(var r=-1,i=t.criteria,o=e.criteria,a=i.length,s=n.length;++r<a;){var u=Ys(i[r],o[r]);if(u)return r>=s?u:u*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))}function $s(t){return Dn((function(e){return e=I(e,Be(ao)),me((function(n){var r=this;return t(e,(function(t){return mt(t,r,n)}))}))}))}var Zs=$s(I),Ks=me,Js=Math.min,Qs=Ks((function(t,e){var n=(e=1==e.length&&N(e[0])?I(e[0],Be(ao)):I(Pn(e,1),Be(ao))).length;return me((function(r){for(var i=-1,o=Js(r.length,n);++i<o;)r[i]=e[i].call(this,r[i]);return mt(t,this,r)}))})),tu=$s(la),eu=$s(Bi),nu=Math.floor;function ru(t,e){var n="";if(!t||e<1||e>9007199254740991)return n;do{e%2&&(n+=t),(e=nu(e/2))&&(t+=t)}while(e);return n}var iu=io("length"),ou="[\\ud800-\\udfff]",au="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",su="\\ud83c[\\udffb-\\udfff]",uu="[^\\ud800-\\udfff]",lu="(?:\\ud83c[\\udde6-\\uddff]){2}",cu="[\\ud800-\\udbff][\\udc00-\\udfff]",fu="(?:"+au+"|"+su+")"+"?",hu="[\\ufe0e\\ufe0f]?"+fu+("(?:\\u200d(?:"+[uu,lu,cu].join("|")+")[\\ufe0e\\ufe0f]?"+fu+")*"),pu="(?:"+[uu+au+"?",au,lu,cu,ou].join("|")+")",du=RegExp(su+"(?="+su+")|"+pu+hu,"g");function vu(t){return Qn(t)?function(t){for(var e=du.lastIndex=0;du.test(t);)++e;return e}(t):iu(t)}var gu=Math.ceil;function yu(t,e){var n=(e=void 0===e?" ":z(e)).length;if(n<2)return n?ru(e,t):e;var r=ru(e,gu(t/vu(e)));return Qn(e)?Kn(cr(r),0,t).join(""):r.slice(0,t)}var _u=Math.ceil,mu=Math.floor;var bu=/^\s+/,xu=E.parseInt;var wu=me((function(t,e){return ce(t,32,void 0,e,ae(e,ee(wu)))}));wu.placeholder={};var Ou=me((function(t,e){return ce(t,64,void 0,e,ae(e,ee(Ou)))}));Ou.placeholder={};var Eu=go((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var Tu=Dn((function(t,e){return null==t?{}:function(t,e){return Ws(t,e,(function(e,n){return no(t,n)}))}(t,e)}));function Su(t,e,n,r){for(var i=n-1,o=t.length;++i<o;)if(r(t[i],e))return i;return-1}var Mu=Array.prototype.splice;function Au(t,e,n,r){var i=r?Su:Zt,o=-1,a=e.length,s=t;for(t===e&&(e=Pt(e)),n&&(s=I(t,Be(n)));++o<a;)for(var u=0,l=e[o],c=n?n(l):l;(u=i(s,c,u,r))>-1;)s!==t&&Mu.call(s,u,1),Mu.call(t,u,1);return t}function ku(t,e){return t&&t.length&&e&&e.length?Au(t,e):t}var Lu=me(ku);var Cu=Array.prototype.splice;function Ru(t,e){for(var n=t?e.length:0,r=n-1;n--;){var i=e[n];if(n==r||i!==o){var o=i;re(i)?Cu.call(t,i,1):Vs(t,i)}}return t}var Pu=Dn((function(t,e){var n=null==t?0:t.length,r=kn(t,e);return Ru(t,I(e,(function(t){return re(t,n)?+t:t})).sort(Ys)),r})),ju=Math.floor,Du=Math.random;function Iu(t,e){return t+ju(Du()*(e-t+1))}var Nu=parseFloat,Bu=Math.min,Fu=Math.random;var zu=Math.ceil,Vu=Math.max;function Gu(t){return function(e,n,r){return r&&"number"!=typeof r&&we(e,n,r)&&(n=r=void 0),e=Z(e),void 0===n?(n=e,e=0):n=Z(n),function(t,e,n,r){for(var i=-1,o=Vu(zu((e-t)/(n||1)),0),a=Array(o);o--;)a[r?o:++i]=t,t+=n;return a}(e,n,r=void 0===r?e<n?1:-1:Z(r),t)}}var Uu=Gu(),Hu=Gu(!0),Wu=Dn((function(t,e){return ce(t,256,void 0,void 0,void 0,e)}));function qu(t,e,n,r,i){return i(t,(function(t,i,o){n=r?(r=!1,t):e(n,t,i,o)})),n}function Yu(t,e,n,r){var i=null==t?0:t.length;for(r&&i&&(n=t[--i]);i--;)n=e(n,t[i],i,t);return n}var Xu=Array.prototype.reverse;function $u(t){return null==t?t:Xu.call(t)}var Zu=Ur("round");function Ku(t){var e=t.length;return e?t[Iu(0,e-1)]:void 0}function Ju(t){return Ku(Ga(t))}function Qu(t,e){var n=-1,r=t.length,i=r-1;for(e=void 0===e?r:e;++n<e;){var o=Iu(n,i),a=t[o];t[o]=t[n],t[n]=a}return t.length=e,t}function tl(t,e){return Qu(Pt(t),Xr(e,0,t.length))}function el(t,e){var n=Ga(t);return Qu(n,Xr(e,0,n.length))}function nl(t){return Qu(Pt(t))}function rl(t){return Qu(Ga(t))}var il=Fr((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));function ol(t,e){var n;return po(t,(function(t,r,i){return!(n=e(t,r,i))})),!!n}var al=me((function(t,e){if(null==t)return[];var n=e.length;return n>1&&we(t,e[0],e[1])?e=[]:n>2&&we(e[0],e[1],e[2])&&(e=[e[0]]),Xs(t,Pn(e,1),[])})),sl=Math.floor,ul=Math.min;function ll(t,e,n,r){e=n(e);for(var i=0,o=null==t?0:t.length,a=e!=e,s=null===e,u=j(e),l=void 0===e;i<o;){var c=sl((i+o)/2),f=n(t[c]),h=void 0!==f,p=null===f,d=f==f,v=j(f);if(a)var g=r||d;else g=l?d&&(r||h):s?d&&h&&(r||!p):u?d&&h&&!p&&(r||!v):!p&&!v&&(r?f<=e:f<e);g?i=c+1:o=c}return ul(o,4294967294)}function cl(t,e,n){var r=0,i=null==t?r:t.length;if("number"==typeof e&&e==e&&i<=2147483647){for(;r<i;){var o=r+i>>>1,a=t[o];null!==a&&!j(a)&&(n?a<=e:a<e)?r=o+1:i=o}return i}return ll(t,e,J,n)}function fl(t,e){for(var n=-1,r=t.length,i=0,o=[];++n<r;){var a=t[n],s=e?e(a):a;if(!n||!pe(s,u)){var u=s;o[i++]=0===a?0:a}}return o}var hl=Math.max;var pl=Fr((function(t,e,n){return t+(n?" ":"")+hr(e)}));var dl=V((function(t,e){return t-e}),0);var vl=Object.prototype,gl=vl.hasOwnProperty;function yl(t,e,n,r){return void 0===t||pe(t,vl[n])&&!gl.call(r,n)?e:t}var _l={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};function ml(t){return"\\"+_l[t]}var bl=/<%=([\s\S]+?)%>/g,xl={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:bl,variable:"",imports:{_:{escape:aa}}},wl=/\b__p \+= '';/g,Ol=/\b(__p \+=) '' \+/g,El=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Tl=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Sl=/($^)/,Ml=/['\n\r\u2028\u2029\\]/g,Al=Object.prototype.hasOwnProperty;function kl(t,e){return e(t)}var Ll=Math.min;function Cl(t,e){var n=t;return n instanceof St&&(n=n.value()),dr(e,(function(t,e){return e.func.apply(e.thisArg,Ln([t],e.args))}),n)}function Rl(){return Cl(this.__wrapped__,this.__actions__)}function Pl(t,e){for(var n=t.length;n--&&Zt(e,t[n],0)>-1;);return n}function jl(t,e){for(var n=-1,r=t.length;++n<r&&Zt(e,t[n],0)>-1;);return n}var Dl=/^\s+|\s+$/g;var Il=/\s+$/;var Nl=/^\s+/;var Bl=/\w*$/;var Fl=vr({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),zl=/&(?:amp|lt|gt|quot|#39);/g,Vl=RegExp(zl.source);var Gl=pi&&1/Gi(new pi([,-0]))[1]==1/0?function(t){return new pi(t)}:Mt;function Ul(t,e,n){var r=-1,i=Kt,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=Fo;else if(o>=200){var l=e?null:Gl(t);if(l)return Gi(l);a=!1,i=Fi,u=new Ni}else u=e?[]:s;t:for(;++r<o;){var c=t[r],f=e?e(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var h=u.length;h--;)if(u[h]===f)continue t;e&&u.push(f),s.push(c)}else i(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}var Hl=me((function(t){return Ul(Pn(t,1,ko,!0))})),Wl=me((function(t){var e=Go(t);return ko(e)&&(e=void 0),Ul(Pn(t,1,ko,!0),ao(e))})),ql=me((function(t){var e=Go(t);return e="function"==typeof e?e:void 0,Ul(Pn(t,1,ko,!0),void 0,e)}));function Yl(t){return t&&t.length?Ul(t):[]}var Xl=0;var $l=Math.max;function Zl(t){if(!t||!t.length)return[];var e=0;return t=ni(t,(function(t){if(ko(t))return e=$l(t.length,e),!0})),Se(e,(function(e){return I(t,io(e))}))}function Kl(t,e){if(!t||!t.length)return[];var n=Zl(t);return null==e?n:I(n,(function(t){return mt(e,void 0,t)}))}function Jl(t,e,n,r){return Hs(t,e,n(Mn(t,e)),r)}var Ql=Fr((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()}));var tc=me((function(t,e){return ko(t)?zo(t,e):[]}));var ec=Dn((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return kn(e,t)};return!(e>1||this.__actions__.length)&&r instanceof St&&re(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:kl,args:[i],thisArg:void 0}),new Rt(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(void 0),t}))):this.thru(i)}));function nc(t,e,n){var r=t.length;if(r<2)return r?Ul(t[0]):[];for(var i=-1,o=Array(r);++i<r;)for(var a=t[i],s=-1;++s<r;)s!=i&&(o[i]=zo(o[i]||a,t[s],e,n));return Ul(Pn(o,1),e,n)}var rc=me((function(t){return nc(ni(t,ko))})),ic=me((function(t){var e=Go(t);return ko(e)&&(e=void 0),nc(ni(t,ko),ao(e))})),oc=me((function(t){var e=Go(t);return e="function"==typeof e?e:void 0,nc(ni(t,ko),void 0,e)})),ac=me(Zl);function sc(t,e,n){for(var r=-1,i=t.length,o=e.length,a={};++r<i;){var s=r<o?e[r]:void 0;n(a,t[r],s)}return a}var uc=me((function(t){var e=t.length,n=e>1?t[e-1]:void 0;return n="function"==typeof n?(t.pop(),n):void 0,Kl(t,n)})),lc={chunk:function(t,e,n){e=(n?we(t,e,n):void 0===e)?1:Yr(K(e),0);var r=null==t?0:t.length;if(!r||e<1)return[];for(var i=0,o=0,a=Array(qr(r/e));i<r;)a[o++]=Zn(t,i,i+=e);return a},compact:function(t){for(var e=-1,n=null==t?0:t.length,r=0,i=[];++e<n;){var o=t[e];o&&(i[r++]=o)}return i},concat:function(){var t=arguments.length;if(!t)return[];for(var e=Array(t-1),n=arguments[0],r=t;r--;)e[r-1]=arguments[r];return Ln(N(n)?Pt(n):[n],Pn(e,1))},difference:Vo,differenceBy:Uo,differenceWith:Ho,drop:function(t,e,n){var r=null==t?0:t.length;return r?Zn(t,(e=n||void 0===e?1:K(e))<0?0:e,r):[]},dropRight:function(t,e,n){var r=null==t?0:t.length;return r?Zn(t,0,(e=r-(e=n||void 0===e?1:K(e)))<0?0:e):[]},dropRightWhile:function(t,e){return t&&t.length?qo(t,ao(e),!0,!0):[]},dropWhile:function(t,e){return t&&t.length?qo(t,ao(e),!0):[]},fill:function(t,e,n,r){var i=null==t?0:t.length;return i?(n&&"number"!=typeof n&&we(t,e,n)&&(n=0,r=i),function(t,e,n,r){var i=t.length;for((n=K(n))<0&&(n=-n>i?0:i+n),(r=void 0===r||r>i?i:K(r))<0&&(r+=i),r=n>r?0:fa(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},findIndex:va,findLastIndex:ba,first:wa,flatten:jn,flattenDeep:function(t){return(null==t?0:t.length)?Pn(t,1/0):[]},flattenDepth:function(t,e){return(null==t?0:t.length)?Pn(t,e=void 0===e?1:K(e)):[]},fromPairs:function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var i=t[e];r[i[0]]=i[1]}return r},head:wa,indexOf:function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:K(n);return i<0&&(i=Ha(r+i,0)),Zt(t,e,i)},initial:function(t){return(null==t?0:t.length)?Zn(t,0,-1):[]},intersection:Xa,intersectionBy:$a,intersectionWith:Za,join:function(t,e){return null==t?"":ms.call(t,e)},last:Go,lastIndexOf:function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r;return void 0!==n&&(i=(i=K(n))<0?ws(r+i,0):Os(i,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,i):Xt(t,$t,i,!0)},nth:function(t,e){return t&&t.length?zs(t,K(e)):void 0},pull:Lu,pullAll:ku,pullAllBy:function(t,e,n){return t&&t.length&&e&&e.length?Au(t,e,ao(n)):t},pullAllWith:function(t,e,n){return t&&t.length&&e&&e.length?Au(t,e,void 0,n):t},pullAt:Pu,remove:function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,i=[],o=t.length;for(e=ao(e);++r<o;){var a=t[r];e(a,r,t)&&(n.push(a),i.push(r))}return Ru(t,i),n},reverse:$u,slice:function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&we(t,e,n)?(e=0,n=r):(e=null==e?0:K(e),n=void 0===n?r:K(n)),Zn(t,e,n)):[]},sortedIndex:function(t,e){return cl(t,e)},sortedIndexBy:function(t,e,n){return ll(t,e,ao(n))},sortedIndexOf:function(t,e){var n=null==t?0:t.length;if(n){var r=cl(t,e);if(r<n&&pe(t[r],e))return r}return-1},sortedLastIndex:function(t,e){return cl(t,e,!0)},sortedLastIndexBy:function(t,e,n){return ll(t,e,ao(n),!0)},sortedLastIndexOf:function(t,e){if(null==t?0:t.length){var n=cl(t,e,!0)-1;if(pe(t[n],e))return n}return-1},sortedUniq:function(t){return t&&t.length?fl(t):[]},sortedUniqBy:function(t,e){return t&&t.length?fl(t,ao(e)):[]},tail:function(t){var e=null==t?0:t.length;return e?Zn(t,1,e):[]},take:function(t,e,n){return t&&t.length?Zn(t,0,(e=n||void 0===e?1:K(e))<0?0:e):[]},takeRight:function(t,e,n){var r=null==t?0:t.length;return r?Zn(t,(e=r-(e=n||void 0===e?1:K(e)))<0?0:e,r):[]},takeRightWhile:function(t,e){return t&&t.length?qo(t,ao(e),!1,!0):[]},takeWhile:function(t,e){return t&&t.length?qo(t,ao(e)):[]},union:Hl,unionBy:Wl,unionWith:ql,uniq:Yl,uniqBy:function(t,e){return t&&t.length?Ul(t,ao(e)):[]},uniqWith:function(t,e){return e="function"==typeof e?e:void 0,t&&t.length?Ul(t,void 0,e):[]},unzip:Zl,unzipWith:Kl,without:tc,xor:rc,xorBy:ic,xorWith:oc,zip:ac,zipObject:function(t,e){return sc(t||[],e||[],ve)},zipObjectDeep:function(t,e){return sc(t||[],e||[],Hs)},zipWith:uc},cc={countBy:_o,each:Xo,eachRight:Qo,every:function(t,e,n){var r=N(t)?la:ca;return n&&we(t,e,n)&&(e=void 0),r(t,ao(e))},filter:function(t,e){return(N(t)?ni:ha)(t,ao(e))},find:ga,findLast:xa,flatMap:function(t,e){return Pn(Ea(t,e),1)},flatMapDeep:function(t,e){return Pn(Ea(t,e),1/0)},flatMapDepth:function(t,e,n){return n=void 0===n?1:K(n),Pn(Ea(t,e),n)},forEach:Xo,forEachRight:Qo,groupBy:Ca,includes:function(t,e,n,r){t=xe(t)?t:Ga(t),n=n&&!r?K(n):0;var i=t.length;return n<0&&(n=Ua(i+n,0)),za(t)?n<=i&&t.indexOf(e,n)>-1:!!i&&Zt(t,e,n)>-1},invokeMap:ss,keyBy:xs,map:Ea,orderBy:function(t,e,n,r){return null==t?[]:(N(e)||(e=null==e?[]:[e]),N(n=r?void 0:n)||(n=null==n?[]:[n]),Xs(t,e,n))},partition:Eu,reduce:function(t,e,n){var r=N(t)?dr:qu,i=arguments.length<3;return r(t,ao(e),n,i,po)},reduceRight:function(t,e,n){var r=N(t)?Yu:qu,i=arguments.length<3;return r(t,ao(e),n,i,Jo)},reject:function(t,e){return(N(t)?ni:ha)(t,Ns(ao(e)))},sample:function(t){return(N(t)?Ku:Ju)(t)},sampleSize:function(t,e,n){return e=(n?we(t,e,n):void 0===e)?1:K(e),(N(t)?tl:el)(t,e)},shuffle:function(t){return(N(t)?nl:rl)(t)},size:function(t){if(null==t)return 0;if(xe(t))return za(t)?vu(t):t.length;var e=bi(t);return"[object Map]"==e||"[object Set]"==e?t.size:Ze(t).length},some:function(t,e,n){var r=N(t)?Bi:ol;return n&&we(t,e,n)&&(e=void 0),r(t,ao(e))},sortBy:al},fc=xo,hc={after:function(t,e){if("function"!=typeof e)throw new TypeError("Expected a function");return t=K(t),function(){if(--t<1)return e.apply(this,arguments)}},ary:fe,before:qn,bind:Yn,bindKey:$n,curry:mo,curryRight:bo,debounce:Eo,defer:No,delay:Bo,flip:function(t){return ce(t,512)},memoize:bn,negate:Ns,once:function(t){return qn(2,t)},overArgs:Qs,partial:wu,partialRight:Ou,rearg:Wu,rest:function(t,e){if("function"!=typeof t)throw new TypeError("Expected a function");return me(t,e=void 0===e?e:K(e))},spread:function(t,e){if("function"!=typeof t)throw new TypeError("Expected a function");return e=null==e?0:hl(K(e),0),me((function(n){var r=n[e],i=Kn(n,0,e);return r&&Ln(i,r),mt(t,this,i)}))},throttle:function(t,e,n){var r=!0,i=!0;if("function"!=typeof t)throw new TypeError("Expected a function");return U(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Eo(t,e,{leading:r,maxWait:e,trailing:i})},unary:function(t){return fe(t,1)},wrap:function(t,e){return wu(Yo(e),t)}},pc={castArray:function(){if(!arguments.length)return[];var t=arguments[0];return N(t)?t:[t]},clone:function(t){return Di(t,4)},cloneDeep:Ii,cloneDeepWith:function(t,e){return Di(t,5,e="function"==typeof e?e:void 0)},cloneWith:function(t,e){return Di(t,4,e="function"==typeof e?e:void 0)},conformsTo:function(t,e){return null==e||so(t,e,Ke(e))},eq:pe,gt:ja,gte:Da,isArguments:Ce,isArray:N,isArrayBuffer:ls,isArrayLike:xe,isArrayLikeObject:ko,isBoolean:function(t){return!0===t||!1===t||P(t)&&"[object Boolean]"==R(t)},isBuffer:Ie,isDate:fs,isElement:function(t){return P(t)&&1===t.nodeType&&!Un(t)},isEmpty:function(t){if(null==t)return!0;if(xe(t)&&(N(t)||"string"==typeof t||"function"==typeof t.splice||Ie(t)||He(t)||Ce(t)))return!t.length;var e=bi(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(Te(t))return!Ze(t).length;for(var n in t)if(hs.call(t,n))return!1;return!0},isEqual:function(t,e){return Xi(t,e)},isEqualWith:function(t,e,n){var r=(n="function"==typeof n?n:void 0)?n(t,e):void 0;return void 0===r?Xi(t,e,void 0,n):!!r},isError:Hn,isFinite:function(t){return"number"==typeof t&&ps(t)},isFunction:Q,isInteger:ds,isLength:be,isMap:Ci,isMatch:function(t,e){return t===e||$i(t,e,Ki(e))},isMatchWith:function(t,e,n){return n="function"==typeof n?n:void 0,$i(t,e,Ki(e),n)},isNaN:function(t){return vs(t)&&t!=+t},isNative:function(t){if(gs(t))throw new Error("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return ft(t)},isNil:function(t){return null==t},isNull:function(t){return null===t},isNumber:vs,isObject:U,isObjectLike:P,isPlainObject:Un,isRegExp:_s,isSafeInteger:function(t){return ds(t)&&t>=-9007199254740991&&t<=9007199254740991},isSet:Pi,isString:za,isSymbol:j,isTypedArray:He,isUndefined:function(t){return void 0===t},isWeakMap:function(t){return P(t)&&"[object WeakMap]"==bi(t)},isWeakSet:function(t){return P(t)&&"[object WeakSet]"==R(t)},lt:Ms,lte:As,toArray:Fs,toFinite:Z,toInteger:K,toLength:fa,toNumber:$,toPlainObject:Co,toSafeInteger:function(t){return t?Xr(K(t),-9007199254740991,9007199254740991):0===t?t:0},toString:En},dc={add:G,ceil:Hr,divide:Wo,floor:Ta,max:function(t){return t&&t.length?ks(t,J,Ra):void 0},maxBy:function(t,e){return t&&t.length?ks(t,ao(e),Ra):void 0},mean:function(t){return Cs(t,J)},meanBy:function(t,e){return Cs(t,ao(e))},min:function(t){return t&&t.length?ks(t,J,Ss):void 0},minBy:function(t,e){return t&&t.length?ks(t,ao(e),Ss):void 0},multiply:Is,round:Zu,subtract:dl,sum:function(t){return t&&t.length?Ls(t,J):0},sumBy:function(t,e){return t&&t.length?Ls(t,ao(e)):0}},vc=function(t,e,n){return void 0===n&&(n=e,e=void 0),void 0!==n&&(n=(n=$(n))==n?n:0),void 0!==e&&(e=(e=$(e))==e?e:0),Xr($(t),e,n)},gc=function(t,e,n){return e=Z(e),void 0===n?(n=e,e=0):n=Z(n),function(t,e,n){return t>=Fa(e,n)&&t<Ba(e,n)}(t=$(t),e,n)},yc=function(t,e,n){if(n&&"boolean"!=typeof n&&we(t,e,n)&&(e=n=void 0),void 0===n&&("boolean"==typeof e?(n=e,e=void 0):"boolean"==typeof t&&(n=t,t=void 0)),void 0===t&&void 0===e?(t=0,e=1):(t=Z(t),void 0===e?(e=t,t=0):e=Z(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var i=Fu();return Bu(t+i*(e-t+Nu("1e-"+((i+"").length-1))),e)}return Iu(t,e)},_c={assign:Qe,assignIn:rn,assignInWith:on,assignWith:an,at:In,create:function(t,e){var n=yt(t);return null==e?n:Zr(n,e)},defaults:Mo,defaultsDeep:Do,entries:ea,entriesIn:na,extend:rn,extendWith:on,findKey:function(t,e){return ya(t,ao(e),fo)},findLastKey:function(t,e){return ya(t,ao(e),Ko)},forIn:function(t,e){return null==t?t:co(t,Yo(e),nn)},forInRight:function(t,e){return null==t?t:Zo(t,Yo(e),nn)},forOwn:function(t,e){return t&&fo(t,Yo(e))},forOwnRight:function(t,e){return t&&Ko(t,Yo(e))},functions:function(t){return null==t?[]:ka(t,Ke(t))},functionsIn:function(t){return null==t?[]:ka(t,nn(t))},get:An,has:function(t,e){return null!=t&&eo(t,e,Na)},hasIn:no,invert:Qa,invertBy:rs,invoke:as,keys:Ke,keysIn:nn,mapKeys:function(t,e){var n={};return e=ao(e),fo(t,(function(t,r,i){he(n,e(t,r,i),t)})),n},mapValues:function(t,e){var n={};return e=ao(e),fo(t,(function(t,r,i){he(n,r,e(t,r,i))})),n},merge:Rs,mergeWith:jo,omit:Us,omitBy:function(t,e){return qs(t,Ns(ao(e)))},pick:Tu,pickBy:qs,result:function(t,e,n){var r=-1,i=(e=Tn(e,t)).length;for(i||(i=1,t=void 0);++r<i;){var o=null==t?void 0:t[Sn(e[r])];void 0===o&&(r=i,o=n),t=Q(o)?o.call(t):o}return t},set:function(t,e,n){return null==t?t:Hs(t,e,n)},setWith:function(t,e,n,r){return r="function"==typeof r?r:void 0,null==t?t:Hs(t,e,n,r)},toPairs:ea,toPairsIn:na,transform:function(t,e,n){var r=N(t),i=r||Ie(t)||He(t);if(e=ao(e),null==n){var o=t&&t.constructor;n=i?r?new o:[]:U(t)&&Q(o)?yt(Nn(t)):{}}return(i?Yt:fo)(t,(function(t,r,i){return e(n,t,r,i)})),n},unset:function(t,e){return null==t||Vs(t,e)},update:function(t,e,n){return null==t?t:Jl(t,e,Yo(n))},updateWith:function(t,e,n,r){return r="function"==typeof r?r:void 0,null==t?t:Jl(t,e,Yo(n),r)},values:Ga,valuesIn:function(t){return null==t?[]:Va(t,nn(t))}},mc={at:ec,chain:Wr,commit:function(){return new Rt(this.value(),this.__chain__)},lodash:It,next:function(){void 0===this.__values__&&(this.__values__=Fs(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?void 0:this.__values__[this.__index__++]}},plant:function(t){for(var e,n=this;n instanceof Tt;){var r=jt(n);r.__index__=0,r.__values__=void 0,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e},reverse:function(){var t=this.__wrapped__;if(t instanceof St){var e=t;return this.__actions__.length&&(e=new St(this)),(e=e.reverse()).__actions__.push({func:kl,args:[$u],thisArg:void 0}),new Rt(e,this.__chain__)}return this.thru($u)},tap:function(t,e){return e(t),t},thru:kl,toIterator:function(){return this},toJSON:Rl,value:Rl,valueOf:Rl,wrapperChain:function(){return Wr(this)}},bc={camelCase:zr,capitalize:pr,deburr:mr,endsWith:function(t,e,n){t=En(t),e=z(e);var r=t.length,i=n=void 0===n?r:Xr(K(n),0,r);return(n-=e.length)>=0&&t.slice(n,i)==e},escape:aa,escapeRegExp:function(t){return(t=En(t))&&ua.test(t)?t.replace(sa,"\\$&"):t},kebabCase:bs,lowerCase:Es,lowerFirst:Ts,pad:function(t,e,n){t=En(t);var r=(e=K(e))?vu(t):0;if(!e||r>=e)return t;var i=(e-r)/2;return yu(mu(i),n)+t+yu(_u(i),n)},padEnd:function(t,e,n){t=En(t);var r=(e=K(e))?vu(t):0;return e&&r<e?t+yu(e-r,n):t},padStart:function(t,e,n){t=En(t);var r=(e=K(e))?vu(t):0;return e&&r<e?yu(e-r,n)+t:t},parseInt:function(t,e,n){return n||null==e?e=0:e&&(e=+e),xu(En(t).replace(bu,""),e||0)},repeat:function(t,e,n){return e=(n?we(t,e,n):void 0===e)?1:K(e),ru(En(t),e)},replace:function(){var t=arguments,e=En(t[0]);return t.length<3?e:e.replace(t[1],t[2])},snakeCase:il,split:function(t,e,n){return n&&"number"!=typeof n&&we(t,e,n)&&(e=n=void 0),(n=void 0===n?4294967295:n>>>0)?(t=En(t))&&("string"==typeof e||null!=e&&!_s(e))&&!(e=z(e))&&Qn(t)?Kn(cr(t),0,n):t.split(e,n):[]},startCase:pl,startsWith:function(t,e,n){return t=En(t),n=null==n?0:Xr(K(n),0,t.length),e=z(e),t.slice(n,n+e.length)==e},template:function(t,e,n){var r=xl.imports._.templateSettings||xl;n&&we(t,e,n)&&(e=void 0),t=En(t),e=on({},e,r,yl);var i,o,a=on({},e.imports,r.imports,yl),s=Ke(a),u=Va(a,s),l=0,c=e.interpolate||Sl,f="__p += '",h=RegExp((e.escape||Sl).source+"|"+c.source+"|"+(c===bl?Tl:Sl).source+"|"+(e.evaluate||Sl).source+"|$","g"),p=Al.call(e,"sourceURL")?"//# sourceURL="+(e.sourceURL+"").replace(/[\r\n]/g," ")+"\n":"";t.replace(h,(function(e,n,r,a,s,u){return r||(r=a),f+=t.slice(l,u).replace(Ml,ml),n&&(i=!0,f+="' +\n__e("+n+") +\n'"),s&&(o=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+e.length,e})),f+="';\n";var d=Al.call(e,"variable")&&e.variable;d||(f="with (obj) {\n"+f+"\n}\n"),f=(o?f.replace(wl,""):f).replace(Ol,"$1").replace(El,"$1;"),f="function("+(d||"obj")+") {\n"+(d?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(o?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Wn((function(){return Function(s,p+"return "+f).apply(void 0,u)}));if(v.source=f,Hn(v))throw v;return v},templateSettings:xl,toLower:function(t){return En(t).toLowerCase()},toUpper:function(t){return En(t).toUpperCase()},trim:function(t,e,n){if((t=En(t))&&(n||void 0===e))return t.replace(Dl,"");if(!t||!(e=z(e)))return t;var r=cr(t),i=cr(e);return Kn(r,jl(r,i),Pl(r,i)+1).join("")},trimEnd:function(t,e,n){if((t=En(t))&&(n||void 0===e))return t.replace(Il,"");if(!t||!(e=z(e)))return t;var r=cr(t);return Kn(r,0,Pl(r,cr(e))+1).join("")},trimStart:function(t,e,n){if((t=En(t))&&(n||void 0===e))return t.replace(Nl,"");if(!t||!(e=z(e)))return t;var r=cr(t);return Kn(r,jl(r,cr(e))).join("")},truncate:function(t,e){var n=30,r="...";if(U(e)){var i="separator"in e?e.separator:i;n="length"in e?K(e.length):n,r="omission"in e?z(e.omission):r}var o=(t=En(t)).length;if(Qn(t)){var a=cr(t);o=a.length}if(n>=o)return t;var s=n-vu(r);if(s<1)return r;var u=a?Kn(a,0,s).join(""):t.slice(0,s);if(void 0===i)return u+r;if(a&&(s+=u.length-s),_s(i)){if(t.slice(s).search(i)){var l,c=u;for(i.global||(i=RegExp(i.source,En(Bl.exec(i))+"g")),i.lastIndex=0;l=i.exec(c);)var f=l.index;u=u.slice(0,void 0===f?s:f)}}else if(t.indexOf(z(i),s)!=s){var h=u.lastIndexOf(i);h>-1&&(u=u.slice(0,h))}return u+r},unescape:function(t){return(t=En(t))&&Vl.test(t)?t.replace(zl,Fl):t},upperCase:Ql,upperFirst:hr,words:Nr},xc={attempt:Wn,bindAll:Xn,cond:function(t){var e=null==t?0:t.length,n=ao;return t=e?I(t,(function(t){if("function"!=typeof t[1])throw new TypeError("Expected a function");return[n(t[0]),t[1]]})):[],me((function(n){for(var r=-1;++r<e;){var i=t[r];if(mt(i[0],this,n))return mt(i[1],this,n)}}))},conforms:function(t){return function(t){var e=Ke(t);return function(n){return so(n,t,e)}}(Di(t,1))},constant:Ht,defaultTo:function(t,e){return null==t||t!=t?e:t},flow:Ma,flowRight:Aa,identity:J,iteratee:function(t){return ao("function"==typeof t?t:Di(t,1))},matches:function(t){return Qi(Di(t,1))},matchesProperty:function(t,e){return ro(t,Di(e,1))},method:Ps,methodOf:js,mixin:Ds,noop:Mt,nthArg:function(t){return t=K(t),me((function(e){return zs(e,t)}))},over:Zs,overEvery:tu,overSome:eu,property:oo,propertyOf:function(t){return function(e){return null==t?void 0:Mn(t,e)}},range:Uu,rangeRight:Hu,stubArray:ri,stubFalse:Re,stubObject:function(){return{}},stubString:function(){return""},stubTrue:function(){return!0},times:function(t,e){if((t=K(t))<1||t>9007199254740991)return[];var n=4294967295,r=Ll(t,4294967295);t-=4294967295;for(var i=Se(r,e=Yo(e));++n<t;)e(n);return i},toPath:function(t){return N(t)?I(t,Sn):j(t)?[t]:Pt(On(En(t)))},uniqueId:function(t){var e=++Xl;return En(t)+e}};var wc=Math.max,Oc=Math.min;var Ec=Math.min;
16
- /**
17
- * @license
18
- * Lodash (Custom Build) <https://lodash.com/>
19
- * Build: `lodash modularize exports="es" -o ./`
20
- * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
21
- * Released under MIT license <https://lodash.com/license>
22
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
23
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
24
- */
25
- var Tc,Sc,Mc=Array.prototype,Ac=Object.prototype.hasOwnProperty,kc=T?T.iterator:void 0,Lc=Math.max,Cc=Math.min,Rc=function(t){return function(e,n,r){if(null==r){var i=U(n),o=i&&Ke(n),a=o&&o.length&&ka(n,o);(a?a.length:i)||(r=n,n=e,e=this)}return t(e,n,r)}}(Ds);It.after=hc.after,It.ary=hc.ary,It.assign=_c.assign,It.assignIn=_c.assignIn,It.assignInWith=_c.assignInWith,It.assignWith=_c.assignWith,It.at=_c.at,It.before=hc.before,It.bind=hc.bind,It.bindAll=xc.bindAll,It.bindKey=hc.bindKey,It.castArray=pc.castArray,It.chain=mc.chain,It.chunk=lc.chunk,It.compact=lc.compact,It.concat=lc.concat,It.cond=xc.cond,It.conforms=xc.conforms,It.constant=xc.constant,It.countBy=cc.countBy,It.create=_c.create,It.curry=hc.curry,It.curryRight=hc.curryRight,It.debounce=hc.debounce,It.defaults=_c.defaults,It.defaultsDeep=_c.defaultsDeep,It.defer=hc.defer,It.delay=hc.delay,It.difference=lc.difference,It.differenceBy=lc.differenceBy,It.differenceWith=lc.differenceWith,It.drop=lc.drop,It.dropRight=lc.dropRight,It.dropRightWhile=lc.dropRightWhile,It.dropWhile=lc.dropWhile,It.fill=lc.fill,It.filter=cc.filter,It.flatMap=cc.flatMap,It.flatMapDeep=cc.flatMapDeep,It.flatMapDepth=cc.flatMapDepth,It.flatten=lc.flatten,It.flattenDeep=lc.flattenDeep,It.flattenDepth=lc.flattenDepth,It.flip=hc.flip,It.flow=xc.flow,It.flowRight=xc.flowRight,It.fromPairs=lc.fromPairs,It.functions=_c.functions,It.functionsIn=_c.functionsIn,It.groupBy=cc.groupBy,It.initial=lc.initial,It.intersection=lc.intersection,It.intersectionBy=lc.intersectionBy,It.intersectionWith=lc.intersectionWith,It.invert=_c.invert,It.invertBy=_c.invertBy,It.invokeMap=cc.invokeMap,It.iteratee=xc.iteratee,It.keyBy=cc.keyBy,It.keys=Ke,It.keysIn=_c.keysIn,It.map=cc.map,It.mapKeys=_c.mapKeys,It.mapValues=_c.mapValues,It.matches=xc.matches,It.matchesProperty=xc.matchesProperty,It.memoize=hc.memoize,It.merge=_c.merge,It.mergeWith=_c.mergeWith,It.method=xc.method,It.methodOf=xc.methodOf,It.mixin=Rc,It.negate=Ns,It.nthArg=xc.nthArg,It.omit=_c.omit,It.omitBy=_c.omitBy,It.once=hc.once,It.orderBy=cc.orderBy,It.over=xc.over,It.overArgs=hc.overArgs,It.overEvery=xc.overEvery,It.overSome=xc.overSome,It.partial=hc.partial,It.partialRight=hc.partialRight,It.partition=cc.partition,It.pick=_c.pick,It.pickBy=_c.pickBy,It.property=xc.property,It.propertyOf=xc.propertyOf,It.pull=lc.pull,It.pullAll=lc.pullAll,It.pullAllBy=lc.pullAllBy,It.pullAllWith=lc.pullAllWith,It.pullAt=lc.pullAt,It.range=xc.range,It.rangeRight=xc.rangeRight,It.rearg=hc.rearg,It.reject=cc.reject,It.remove=lc.remove,It.rest=hc.rest,It.reverse=lc.reverse,It.sampleSize=cc.sampleSize,It.set=_c.set,It.setWith=_c.setWith,It.shuffle=cc.shuffle,It.slice=lc.slice,It.sortBy=cc.sortBy,It.sortedUniq=lc.sortedUniq,It.sortedUniqBy=lc.sortedUniqBy,It.split=bc.split,It.spread=hc.spread,It.tail=lc.tail,It.take=lc.take,It.takeRight=lc.takeRight,It.takeRightWhile=lc.takeRightWhile,It.takeWhile=lc.takeWhile,It.tap=mc.tap,It.throttle=hc.throttle,It.thru=kl,It.toArray=pc.toArray,It.toPairs=_c.toPairs,It.toPairsIn=_c.toPairsIn,It.toPath=xc.toPath,It.toPlainObject=pc.toPlainObject,It.transform=_c.transform,It.unary=hc.unary,It.union=lc.union,It.unionBy=lc.unionBy,It.unionWith=lc.unionWith,It.uniq=lc.uniq,It.uniqBy=lc.uniqBy,It.uniqWith=lc.uniqWith,It.unset=_c.unset,It.unzip=lc.unzip,It.unzipWith=lc.unzipWith,It.update=_c.update,It.updateWith=_c.updateWith,It.values=_c.values,It.valuesIn=_c.valuesIn,It.without=lc.without,It.words=bc.words,It.wrap=hc.wrap,It.xor=lc.xor,It.xorBy=lc.xorBy,It.xorWith=lc.xorWith,It.zip=lc.zip,It.zipObject=lc.zipObject,It.zipObjectDeep=lc.zipObjectDeep,It.zipWith=lc.zipWith,It.entries=_c.toPairs,It.entriesIn=_c.toPairsIn,It.extend=_c.assignIn,It.extendWith=_c.assignInWith,Rc(It,It),It.add=dc.add,It.attempt=xc.attempt,It.camelCase=bc.camelCase,It.capitalize=bc.capitalize,It.ceil=dc.ceil,It.clamp=vc,It.clone=pc.clone,It.cloneDeep=pc.cloneDeep,It.cloneDeepWith=pc.cloneDeepWith,It.cloneWith=pc.cloneWith,It.conformsTo=pc.conformsTo,It.deburr=bc.deburr,It.defaultTo=xc.defaultTo,It.divide=dc.divide,It.endsWith=bc.endsWith,It.eq=pc.eq,It.escape=bc.escape,It.escapeRegExp=bc.escapeRegExp,It.every=cc.every,It.find=cc.find,It.findIndex=lc.findIndex,It.findKey=_c.findKey,It.findLast=cc.findLast,It.findLastIndex=lc.findLastIndex,It.findLastKey=_c.findLastKey,It.floor=dc.floor,It.forEach=cc.forEach,It.forEachRight=cc.forEachRight,It.forIn=_c.forIn,It.forInRight=_c.forInRight,It.forOwn=_c.forOwn,It.forOwnRight=_c.forOwnRight,It.get=_c.get,It.gt=pc.gt,It.gte=pc.gte,It.has=_c.has,It.hasIn=_c.hasIn,It.head=lc.head,It.identity=J,It.includes=cc.includes,It.indexOf=lc.indexOf,It.inRange=gc,It.invoke=_c.invoke,It.isArguments=pc.isArguments,It.isArray=N,It.isArrayBuffer=pc.isArrayBuffer,It.isArrayLike=pc.isArrayLike,It.isArrayLikeObject=pc.isArrayLikeObject,It.isBoolean=pc.isBoolean,It.isBuffer=pc.isBuffer,It.isDate=pc.isDate,It.isElement=pc.isElement,It.isEmpty=pc.isEmpty,It.isEqual=pc.isEqual,It.isEqualWith=pc.isEqualWith,It.isError=pc.isError,It.isFinite=pc.isFinite,It.isFunction=pc.isFunction,It.isInteger=pc.isInteger,It.isLength=pc.isLength,It.isMap=pc.isMap,It.isMatch=pc.isMatch,It.isMatchWith=pc.isMatchWith,It.isNaN=pc.isNaN,It.isNative=pc.isNative,It.isNil=pc.isNil,It.isNull=pc.isNull,It.isNumber=pc.isNumber,It.isObject=U,It.isObjectLike=pc.isObjectLike,It.isPlainObject=pc.isPlainObject,It.isRegExp=pc.isRegExp,It.isSafeInteger=pc.isSafeInteger,It.isSet=pc.isSet,It.isString=pc.isString,It.isSymbol=pc.isSymbol,It.isTypedArray=pc.isTypedArray,It.isUndefined=pc.isUndefined,It.isWeakMap=pc.isWeakMap,It.isWeakSet=pc.isWeakSet,It.join=lc.join,It.kebabCase=bc.kebabCase,It.last=Go,It.lastIndexOf=lc.lastIndexOf,It.lowerCase=bc.lowerCase,It.lowerFirst=bc.lowerFirst,It.lt=pc.lt,It.lte=pc.lte,It.max=dc.max,It.maxBy=dc.maxBy,It.mean=dc.mean,It.meanBy=dc.meanBy,It.min=dc.min,It.minBy=dc.minBy,It.stubArray=xc.stubArray,It.stubFalse=xc.stubFalse,It.stubObject=xc.stubObject,It.stubString=xc.stubString,It.stubTrue=xc.stubTrue,It.multiply=dc.multiply,It.nth=lc.nth,It.noop=xc.noop,It.now=fc,It.pad=bc.pad,It.padEnd=bc.padEnd,It.padStart=bc.padStart,It.parseInt=bc.parseInt,It.random=yc,It.reduce=cc.reduce,It.reduceRight=cc.reduceRight,It.repeat=bc.repeat,It.replace=bc.replace,It.result=_c.result,It.round=dc.round,It.sample=cc.sample,It.size=cc.size,It.snakeCase=bc.snakeCase,It.some=cc.some,It.sortedIndex=lc.sortedIndex,It.sortedIndexBy=lc.sortedIndexBy,It.sortedIndexOf=lc.sortedIndexOf,It.sortedLastIndex=lc.sortedLastIndex,It.sortedLastIndexBy=lc.sortedLastIndexBy,It.sortedLastIndexOf=lc.sortedLastIndexOf,It.startCase=bc.startCase,It.startsWith=bc.startsWith,It.subtract=dc.subtract,It.sum=dc.sum,It.sumBy=dc.sumBy,It.template=bc.template,It.times=xc.times,It.toFinite=pc.toFinite,It.toInteger=K,It.toLength=pc.toLength,It.toLower=bc.toLower,It.toNumber=pc.toNumber,It.toSafeInteger=pc.toSafeInteger,It.toString=pc.toString,It.toUpper=bc.toUpper,It.trim=bc.trim,It.trimEnd=bc.trimEnd,It.trimStart=bc.trimStart,It.truncate=bc.truncate,It.unescape=bc.unescape,It.uniqueId=xc.uniqueId,It.upperCase=bc.upperCase,It.upperFirst=bc.upperFirst,It.each=cc.forEach,It.eachRight=cc.forEachRight,It.first=lc.head,Rc(It,(Tc={},fo(It,(function(t,e){Ac.call(It.prototype,e)||(Tc[e]=t)})),Tc),{chain:!1}),It.VERSION="4.17.15",(It.templateSettings=bc.templateSettings).imports._=It,Yt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){It[t].placeholder=It})),Yt(["drop","take"],(function(t,e){St.prototype[t]=function(n){n=void 0===n?1:Lc(K(n),0);var r=this.__filtered__&&!e?new St(this):this.clone();return r.__filtered__?r.__takeCount__=Cc(n,r.__takeCount__):r.__views__.push({size:Cc(n,4294967295),type:t+(r.__dir__<0?"Right":"")}),r},St.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Yt(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;St.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:ao(t),type:n}),e.__filtered__=e.__filtered__||r,e}})),Yt(["head","last"],(function(t,e){var n="take"+(e?"Right":"");St.prototype[t]=function(){return this[n](1).value()[0]}})),Yt(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");St.prototype[t]=function(){return this.__filtered__?new St(this):this[n](1)}})),St.prototype.compact=function(){return this.filter(J)},St.prototype.find=function(t){return this.filter(t).head()},St.prototype.findLast=function(t){return this.reverse().find(t)},St.prototype.invokeMap=me((function(t,e){return"function"==typeof t?new St(this):this.map((function(n){return os(n,t,e)}))})),St.prototype.reject=function(t){return this.filter(Ns(ao(t)))},St.prototype.slice=function(t,e){t=K(t);var n=this;return n.__filtered__&&(t>0||e<0)?new St(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),void 0!==e&&(n=(e=K(e))<0?n.dropRight(-e):n.take(e-t)),n)},St.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},St.prototype.toArray=function(){return this.take(4294967295)},fo(St.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=It[r?"take"+("last"==e?"Right":""):e],o=r||/^find/.test(e);i&&(It.prototype[e]=function(){var e=this.__wrapped__,a=r?[1]:arguments,s=e instanceof St,u=a[0],l=s||N(e),c=function(t){var e=i.apply(It,Ln([t],a));return r&&f?e[0]:e};l&&n&&"function"==typeof u&&1!=u.length&&(s=l=!1);var f=this.__chain__,h=!!this.__actions__.length,p=o&&!f,d=s&&!h;if(!o&&l){e=d?e:new St(this);var v=t.apply(e,a);return v.__actions__.push({func:kl,args:[c],thisArg:void 0}),new Rt(v,f)}return p&&d?t.apply(this,a):(v=this.thru(c),p?r?v.value()[0]:v.value():v)})})),Yt(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Mc[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);It.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var i=this.value();return e.apply(N(i)?i:[],t)}return this[n]((function(n){return e.apply(N(n)?n:[],t)}))}})),fo(St.prototype,(function(t,e){var n=It[e];if(n){var r=n.name+"";Ac.call(kt,r)||(kt[r]=[]),kt[r].push({name:e,func:n})}})),kt[se(void 0,2).name]=[{name:"wrapper",func:void 0}],St.prototype.clone=function(){var t=new St(this.__wrapped__);return t.__actions__=Pt(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Pt(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Pt(this.__views__),t},St.prototype.reverse=function(){if(this.__filtered__){var t=new St(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},St.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=N(t),r=e<0,i=n?t.length:0,o=function(t,e,n){for(var r=-1,i=n.length;++r<i;){var o=n[r],a=o.size;switch(o.type){case"drop":t+=a;break;case"dropRight":e-=a;break;case"take":e=Oc(e,t+a);break;case"takeRight":t=wc(t,e-a)}}return{start:t,end:e}}(0,i,this.__views__),a=o.start,s=o.end,u=s-a,l=r?s:a-1,c=this.__iteratees__,f=c.length,h=0,p=Ec(u,this.__takeCount__);if(!n||!r&&i==u&&p==u)return Cl(t,this.__actions__);var d=[];t:for(;u--&&h<p;){for(var v=-1,g=t[l+=e];++v<f;){var y=c[v],_=y.iteratee,m=y.type,b=_(g);if(2==m)g=b;else if(!b){if(1==m)continue t;break t}}d[h++]=g}return d},It.prototype.at=mc.at,It.prototype.chain=mc.wrapperChain,It.prototype.commit=mc.commit,It.prototype.next=mc.next,It.prototype.plant=mc.plant,It.prototype.reverse=mc.reverse,It.prototype.toJSON=It.prototype.valueOf=It.prototype.value=mc.value,It.prototype.first=It.prototype.head,kc&&(It.prototype[kc]=mc.toIterator),function(t){t.debounce=Eo,t.clone=Ii,t.merge=Rs,t.removeArrayDuplicates=Yl,t.getDimensions=function(t){return{width:parseFloat(t.style.width.replace("px","")||t.offsetWidth),height:parseFloat(t.style.height.replace("px","")||t.offsetHeight)}},t.getTranslationValues=function(t){var e=t.getAttribute("transform").match(/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/);if(e[0]){var n=e[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:n[0],ty:n[1]}}return null},t.getTranformOffsets=function(t){var e=/\(([^)]+)\)/.exec(t)[1].split(",");return{x:parseFloat(e[0]),y:parseFloat(e[1])}},t.capitalizeFirstLetter=function(t){return t[0].toUpperCase()+t.slice(1)},t.convertValueToPercentage=function(t,e){var n=t/e.reduce((function(t,e){return t+e.value}),0)*100;return n<1?n.toPrecision(1):Math.floor(n)},t.arrayDifferences=function(t,e){var n={missing:[],added:[]};return t.forEach((function(t){-1===e.indexOf(t)&&n.missing.push(t)})),e.forEach((function(e){-1===t.indexOf(e)&&n.added.push(e)})),n},t.getDuplicateValues=function(t){var e=[],n=[];return t.forEach((function(t){-1!==e.indexOf(t)&&-1===n.indexOf(t)&&n.push(t),e.push(t)})),n},t.moveToFront=function(t){return t.each((function(){this.parentNode.appendChild(this)}))},t.getProperty=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var r=t;if(r){for(var i=0,o=e;i<o.length;i++){var a=o[i];if(!r[a])return null;r=r[a]}return r}return null},t.flipSVGCoordinatesBasedOnOrientation=function(t,e){return e===c.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},t.generateSVGPathString=function(e,n){var r=t.flipSVGCoordinatesBasedOnOrientation(e,n),i=r.x0,o=r.x1,a=r.y0,s=r.y1;return"M"+i+","+a+"L"+i+","+s+"L"+o+","+s+"L"+o+","+a+"L"+i+","+a}}(Sc||(Sc={}));var Pc={position:v.BOTTOM,clickable:!0,enabled:!0,items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8},checkbox:{radius:6.5,spaceAfter:4}},jc={x:{numberOfTicks:5},y:{numberOfTicks:5}},Dc={datapoint:{horizontalOffset:10,enabled:!0},title:{verticalOffset:.75,width:.4}},Ic=Sc.merge({},Dc,{gridline:{enabled:!0,threshold:.25}}),Nc=Sc.merge({},Ic,{datapoint:{verticalOffset:4},gridline:{enabled:!1}}),Bc={addSpaceOnEdges:1},Fc={width:"100%",height:"100%",resizable:!0,tooltip:Dc,legend:Pc,style:{prefix:"cc"}},zc=Sc.merge({},Fc,{axes:{},timeScale:Bc,grid:jc,tooltip:Ic}),Vc=Sc.merge({},zc,{bars:{maxWidth:16},timeScale:Sc.merge(Bc,{addSpaceOnEdges:1}),tooltip:Nc}),Gc=Sc.merge({},Vc,{}),Uc=Sc.merge({},Vc,{}),Hc=Sc.merge({},Vc,{bars:Sc.merge({},Vc.bars,{dividerSize:1.5})}),Wc=Sc.merge({},zc,{points:{radius:3,filled:!1}}),qc=Sc.merge({},zc,{points:{radius:4,fillOpacity:.3,filled:!0}}),Yc=Sc.merge({},zc,{bubble:{radiusRange:function(t,e){var n=Math.min(t.width,t.height);return[3*n/400,25*n/400]},fillOpacity:.2}}),Xc=Sc.merge({},Fc,{pie:{radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2},labels:{formatter:null}}}),$c={chart:Fc,axisChart:zc,simpleBarChart:Gc,groupedBarChart:Uc,stackedBarChart:Hc,bubbleChart:Yc,lineChart:Wc,scatterChart:qc,pieChart:Xc,donutChart:Sc.merge({},Xc,{donut:{center:{numberFontSize:function(t){return Math.min(t/100*24,24)+"px"},titleFontSize:function(t){return Math.min(t/100*15,15)+"px"},titleYPosition:function(t){return Math.min(t/80*20,20)},numberFormatter:function(t){return Math.floor(t).toLocaleString()}}}})},Zc={opacity:{unselected:.3,selected:1}},Kc={default:{duration:300},pie_slice_mouseover:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},Jc={ticks:{number:7,rotateIfSmallerThan:30}},Qc={default:{size:24}},tf=Object.freeze({__proto__:null,legend:Pc,grid:jc,baseTooltip:Dc,axisChartTooltip:Ic,barChartTooltip:Nc,options:$c,lines:Zc,transitions:Kc,axis:Jc,spacers:Qc});var ef=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t,e){Object.defineProperty(e,"__esModule",{value:!0});var n={10:"#fff0f1",20:"#fcd0d3",30:"#ffa4a9",40:"#ff767c",50:"#fb4b53",60:"#da1e28",70:"#a51920",80:"#750e13",90:"#570408",100:"#2c080a"},r={10:"#fff0f6",20:"#ffcfe1",30:"#ffa0c2",40:"#fa75a6",50:"#ee538b",60:"#d12765",70:"#a11950",80:"#760a3a",90:"#57002b",100:"#2a0a16"},i={10:"#f7f1ff",20:"#e6d6ff",30:"#d0b0ff",40:"#bb8eff",50:"#a66efa",60:"#8a3ffc",70:"#6e32c9",80:"#4f2196",90:"#38146b",100:"#1e1033"},o={10:"#edf4ff",20:"#c9deff",30:"#97c1ff",40:"#6ea6ff",50:"#408bfc",60:"#0062ff",70:"#054ada",80:"#0530ad",90:"#061f80",100:"#051243"},a={10:"#e3f6ff",20:"#b3e6ff",30:"#6ccaff",40:"#30b0ff",50:"#1191e6",60:"#0072c3",70:"#0058a1",80:"#003d73",90:"#002b50",100:"#07192b"},s={10:"#dbfbfb",20:"#92eeee",30:"#20d5d2",40:"#00bab6",50:"#009c98",60:"#007d79",70:"#006161",80:"#004548",90:"#003137",100:"#081a1c"},u={10:"#dafbe4",20:"#9deeb2",30:"#56d679",40:"#3dbb61",50:"#24a148",60:"#198038",70:"#10642a",80:"#054719",90:"#01330f",100:"#081b09"},l={10:"#f2f4f8",20:"#d5d9e0",30:"#b9bfc7",40:"#9fa5ad",50:"#868d95",60:"#697077",70:"#50565b",80:"#373d42",90:"#242a2e",100:"#13171a"},c={10:"#f3f3f3",20:"#dcdcdc",30:"#bebebe",40:"#a4a4a4",50:"#8c8c8c",60:"#6f6f6f",70:"#565656",80:"#3d3d3d",90:"#282828",100:"#171717"},f={10:"#f7f3f1",20:"#e0dbda",30:"#c1bcbb",40:"#a7a2a2",50:"#8f8b8b",60:"#726e6e",70:"#595555",80:"#403c3c",90:"#2b2828",100:"#1a1717"},h={black:{100:"#000000"},blue:o,coolGray:l,cyan:a,gray:c,green:u,magenta:r,orange:{40:"#fc7b1e"},purple:i,red:n,teal:s,warmGray:f,white:{0:"#ffffff"},yellow:{20:"#fdd13a"}};e.black="#000000",e.black100="#000000",e.white="#ffffff",e.white0="#ffffff",e.yellow="#fdd13a",e.yellow20="#fdd13a",e.orange="#fc7b1e",e.orange40="#fc7b1e",e.red10="#fff0f1",e.red20="#fcd0d3",e.red30="#ffa4a9",e.red40="#ff767c",e.red50="#fb4b53",e.red60="#da1e28",e.red70="#a51920",e.red80="#750e13",e.red90="#570408",e.red100="#2c080a",e.red=n,e.magenta10="#fff0f6",e.magenta20="#ffcfe1",e.magenta30="#ffa0c2",e.magenta40="#fa75a6",e.magenta50="#ee538b",e.magenta60="#d12765",e.magenta70="#a11950",e.magenta80="#760a3a",e.magenta90="#57002b",e.magenta100="#2a0a16",e.magenta=r,e.purple10="#f7f1ff",e.purple20="#e6d6ff",e.purple30="#d0b0ff",e.purple40="#bb8eff",e.purple50="#a66efa",e.purple60="#8a3ffc",e.purple70="#6e32c9",e.purple80="#4f2196",e.purple90="#38146b",e.purple100="#1e1033",e.purple=i,e.blue10="#edf4ff",e.blue20="#c9deff",e.blue30="#97c1ff",e.blue40="#6ea6ff",e.blue50="#408bfc",e.blue60="#0062ff",e.blue70="#054ada",e.blue80="#0530ad",e.blue90="#061f80",e.blue100="#051243",e.blue=o,e.cyan10="#e3f6ff",e.cyan20="#b3e6ff",e.cyan30="#6ccaff",e.cyan40="#30b0ff",e.cyan50="#1191e6",e.cyan60="#0072c3",e.cyan70="#0058a1",e.cyan80="#003d73",e.cyan90="#002b50",e.cyan100="#07192b",e.cyan=a,e.teal10="#dbfbfb",e.teal20="#92eeee",e.teal30="#20d5d2",e.teal40="#00bab6",e.teal50="#009c98",e.teal60="#007d79",e.teal70="#006161",e.teal80="#004548",e.teal90="#003137",e.teal100="#081a1c",e.teal=s,e.green10="#dafbe4",e.green20="#9deeb2",e.green30="#56d679",e.green40="#3dbb61",e.green50="#24a148",e.green60="#198038",e.green70="#10642a",e.green80="#054719",e.green90="#01330f",e.green100="#081b09",e.green=u,e.coolGray10="#f2f4f8",e.coolGray20="#d5d9e0",e.coolGray30="#b9bfc7",e.coolGray40="#9fa5ad",e.coolGray50="#868d95",e.coolGray60="#697077",e.coolGray70="#50565b",e.coolGray80="#373d42",e.coolGray90="#242a2e",e.coolGray100="#13171a",e.coolGray=l,e.gray10="#f3f3f3",e.gray20="#dcdcdc",e.gray30="#bebebe",e.gray40="#a4a4a4",e.gray50="#8c8c8c",e.gray60="#6f6f6f",e.gray70="#565656",e.gray80="#3d3d3d",e.gray90="#282828",e.gray100="#171717",e.gray=c,e.warmGray10="#f7f3f1",e.warmGray20="#e0dbda",e.warmGray30="#c1bcbb",e.warmGray40="#a7a2a2",e.warmGray50="#8f8b8b",e.warmGray60="#726e6e",e.warmGray70="#595555",e.warmGray80="#403c3c",e.warmGray90="#2b2828",e.warmGray100="#1a1717",e.warmGray=f,e.colors=h,e.rgba=function(t,e){var n=[t.substring(1,3),t.substring(3,5),t.substring(5,7)].map((function(t){return parseInt(t,16)}));return"rgba(".concat(n[0],", ").concat(n[1],", ").concat(n[2],", ").concat(e,")")}}));!function(t){t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")&&t.default}(ef);ef.black,ef.black100,ef.white,ef.white0,ef.yellow,ef.yellow20,ef.orange,ef.orange40,ef.red10,ef.red20,ef.red30,ef.red40,ef.red50,ef.red60,ef.red70,ef.red80,ef.red90,ef.red100;var nf=ef.red,rf=(ef.magenta10,ef.magenta20,ef.magenta30,ef.magenta40,ef.magenta50,ef.magenta60,ef.magenta70,ef.magenta80,ef.magenta90,ef.magenta100,ef.magenta),of=(ef.purple10,ef.purple20,ef.purple30,ef.purple40,ef.purple50,ef.purple60,ef.purple70,ef.purple80,ef.purple90,ef.purple100,ef.purple),af=(ef.blue10,ef.blue20,ef.blue30,ef.blue40,ef.blue50,ef.blue60,ef.blue70,ef.blue80,ef.blue90,ef.blue100,ef.blue),sf=(ef.cyan10,ef.cyan20,ef.cyan30,ef.cyan40,ef.cyan50,ef.cyan60,ef.cyan70,ef.cyan80,ef.cyan90,ef.cyan100,ef.cyan),uf=(ef.teal10,ef.teal20,ef.teal30,ef.teal40,ef.teal50,ef.teal60,ef.teal70,ef.teal80,ef.teal90,ef.teal100,ef.teal),lf=(ef.green10,ef.green20,ef.green30,ef.green40,ef.green50,ef.green60,ef.green70,ef.green80,ef.green90,ef.green100,ef.green),cf=(ef.coolGray10,ef.coolGray20,ef.coolGray30,ef.coolGray40,ef.coolGray50,ef.coolGray60,ef.coolGray70,ef.coolGray80,ef.coolGray90,ef.coolGray100,ef.coolGray,ef.gray10,ef.gray20,ef.gray30,ef.gray40,ef.gray50,ef.gray60,ef.gray70,ef.gray80,ef.gray90,ef.gray100,ef.gray,ef.warmGray10,ef.warmGray20,ef.warmGray30,ef.warmGray40,ef.warmGray50,ef.warmGray60,ef.warmGray70,ef.warmGray80,ef.warmGray90,ef.warmGray100,ef.warmGray,ef.colors,ef.rgba,function(t,e){return t[e]}),ff=function(t){return cf(af,t)},hf=function(t){return cf(sf,t)},pf=function(t){return cf(lf,t)},df=function(t){return cf(rf,t)},vf=function(t){return cf(of,t)},gf=function(t){return cf(nf,t)},yf=function(t){return cf(uf,t)},_f=[vf(70),hf(50),yf(70),df(70),gf(50),gf(90),pf(60),ff(80),df(50),"#b28600",yf(50),hf(90),"#8a3800",vf(50)],mf=[vf(60),hf(40),yf(60),df(40),gf(50),gf(10),pf(30),ff(50),df(60),"#d2a106",yf(40),hf(20),"#ba4e00",vf(30)],bf=_f,xf=mf,wf=mf,Of=_f,Ef=Object.freeze({__proto__:null,WHITE:_f,DARK:mf,G10:bf,G90:xf,G100:wf,DEFAULT:Of});function Tf(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Sf(t){var e;return 1===t.length&&(e=t,t=function(t,n){return Tf(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)<0?r=o+1:i=o}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)>0?i=o:r=o+1}return r}}}var Mf=Sf(Tf).right;function Af(t,e){var n,r,i,o=t.length,a=-1;if(null==e){for(;++a<o;)if(null!=(n=t[a])&&n>=n)for(r=i=n;++a<o;)null!=(n=t[a])&&(r>n&&(r=n),i<n&&(i=n))}else for(;++a<o;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=i=n;++a<o;)null!=(n=e(t[a],a,t))&&(r>n&&(r=n),i<n&&(i=n));return[r,i]}function kf(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}var Lf=Math.sqrt(50),Cf=Math.sqrt(10),Rf=Math.sqrt(2);function Pf(t,e,n){var r,i,o,a,s=-1;if(n=+n,(t=+t)===(e=+e)&&n>0)return[t];if((r=e<t)&&(i=t,t=e,e=i),0===(a=jf(t,e,n))||!isFinite(a))return[];if(a>0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(i=Math.ceil(e-t+1));++s<i;)o[s]=(t+s)*a;else for(t=Math.floor(t*a),e=Math.ceil(e*a),o=new Array(i=Math.ceil(t-e+1));++s<i;)o[s]=(t-s)/a;return r&&o.reverse(),o}function jf(t,e,n){var r=(e-t)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),o=r/Math.pow(10,i);return i>=0?(o>=Lf?10:o>=Cf?5:o>=Rf?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=Lf?10:o>=Cf?5:o>=Rf?2:1)}function Df(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=Lf?i*=10:o>=Cf?i*=5:o>=Rf&&(i*=2),e<t?-i:i}function If(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function Nf(){}function Bf(t,e){var n=new Nf;if(t instanceof Nf)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==e)for(;++i<o;)n.set(i,t[i]);else for(;++i<o;)n.set(e(r=t[i],i,t),r)}else if(t)for(var a in t)n.set(a,t[a]);return n}function Ff(){}Nf.prototype=Bf.prototype={constructor:Nf,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var zf=Bf.prototype;Ff.prototype=function(t,e){var n=new Ff;if(t instanceof Ff)t.each((function(t){n.add(t)}));else if(t){var r=-1,i=t.length;if(null==e)for(;++r<i;)n.add(t[r]);else for(;++r<i;)n.add(e(t[r],r,t))}return n}.prototype={constructor:Ff,has:zf.has,add:function(t){return this["$"+(t+="")]=t,this},remove:zf.remove,clear:zf.clear,values:zf.keys,size:zf.size,empty:zf.empty,each:zf.each};var Vf=Array.prototype,Gf=Vf.map,Uf=Vf.slice,Hf={name:"implicit"};function Wf(){var t=Bf(),e=[],n=[],r=Hf;function i(i){var o=i+"",a=t.get(o);if(!a){if(r!==Hf)return r;t.set(o,a=e.push(i))}return n[(a-1)%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=Bf();for(var r,o,a=-1,s=n.length;++a<s;)t.has(o=(r=n[a])+"")||t.set(o,e.push(r));return i},i.range=function(t){return arguments.length?(n=Uf.call(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Wf(e,n).unknown(r)},If.apply(i,arguments),i}function qf(){var t,e,n=Wf().unknown(void 0),r=n.domain,i=n.range,o=[0,1],a=!1,s=0,u=0,l=.5;function c(){var n=r().length,c=o[1]<o[0],f=o[c-0],h=o[1-c];t=(h-f)/Math.max(1,n-s+2*u),a&&(t=Math.floor(t)),f+=(h-f-t*(n-s))*l,e=t*(1-s),a&&(f=Math.round(f),e=Math.round(e));var p=kf(n).map((function(e){return f+t*e}));return i(c?p.reverse():p)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),c()):r()},n.range=function(t){return arguments.length?(o=[+t[0],+t[1]],c()):o.slice()},n.rangeRound=function(t){return o=[+t[0],+t[1]],a=!0,c()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(a=!!t,c()):a},n.padding=function(t){return arguments.length?(s=Math.min(1,u=+t),c()):s},n.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),c()):s},n.paddingOuter=function(t){return arguments.length?(u=+t,c()):u},n.align=function(t){return arguments.length?(l=Math.max(0,Math.min(1,t)),c()):l},n.copy=function(){return qf(r(),o).round(a).paddingInner(s).paddingOuter(u).align(l)},If.apply(c(),arguments)}function Yf(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Xf(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function $f(){}var Zf="\\s*([+-]?\\d+)\\s*",Kf="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Jf="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Qf=/^#([0-9a-f]{3,8})$/,th=new RegExp("^rgb\\("+[Zf,Zf,Zf]+"\\)$"),eh=new RegExp("^rgb\\("+[Jf,Jf,Jf]+"\\)$"),nh=new RegExp("^rgba\\("+[Zf,Zf,Zf,Kf]+"\\)$"),rh=new RegExp("^rgba\\("+[Jf,Jf,Jf,Kf]+"\\)$"),ih=new RegExp("^hsl\\("+[Kf,Jf,Jf]+"\\)$"),oh=new RegExp("^hsla\\("+[Kf,Jf,Jf,Kf]+"\\)$"),ah={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function sh(){return this.rgb().formatHex()}function uh(){return this.rgb().formatRgb()}function lh(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=Qf.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?ch(e):3===n?new dh(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?new dh(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?new dh(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=th.exec(t))?new dh(e[1],e[2],e[3],1):(e=eh.exec(t))?new dh(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=nh.exec(t))?fh(e[1],e[2],e[3],e[4]):(e=rh.exec(t))?fh(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=ih.exec(t))?_h(e[1],e[2]/100,e[3]/100,1):(e=oh.exec(t))?_h(e[1],e[2]/100,e[3]/100,e[4]):ah.hasOwnProperty(t)?ch(ah[t]):"transparent"===t?new dh(NaN,NaN,NaN,0):null}function ch(t){return new dh(t>>16&255,t>>8&255,255&t,1)}function fh(t,e,n,r){return r<=0&&(t=e=n=NaN),new dh(t,e,n,r)}function hh(t){return t instanceof $f||(t=lh(t)),t?new dh((t=t.rgb()).r,t.g,t.b,t.opacity):new dh}function ph(t,e,n,r){return 1===arguments.length?hh(t):new dh(t,e,n,null==r?1:r)}function dh(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function vh(){return"#"+yh(this.r)+yh(this.g)+yh(this.b)}function gh(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function yh(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function _h(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new bh(t,e,n,r)}function mh(t){if(t instanceof bh)return new bh(t.h,t.s,t.l,t.opacity);if(t instanceof $f||(t=lh(t)),!t)return new bh;if(t instanceof bh)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new bh(a,s,u,t.opacity)}function bh(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function xh(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function wh(t){return function(){return t}}function Oh(t){return 1==(t=+t)?Eh:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):wh(isNaN(e)?n:e)}}function Eh(t,e){var n=e-t;return n?function(t,e){return function(n){return t+n*e}}(t,n):wh(isNaN(t)?e:t)}Yf($f,lh,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:sh,formatHex:sh,formatHsl:function(){return mh(this).formatHsl()},formatRgb:uh,toString:uh}),Yf(dh,ph,Xf($f,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new dh(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new dh(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:vh,formatHex:vh,formatRgb:gh,toString:gh})),Yf(bh,(function(t,e,n,r){return 1===arguments.length?mh(t):new bh(t,e,n,null==r?1:r)}),Xf($f,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new bh(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new bh(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new dh(xh(t>=240?t-240:t+120,i,r),xh(t,i,r),xh(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var Th=function t(e){var n=Oh(e);function r(t,e){var r=n((t=ph(t)).r,(e=ph(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=Eh(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function Sh(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}}function Mh(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=jh(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}function Ah(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function kh(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function Lh(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=jh(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var Ch=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Rh=new RegExp(Ch.source,"g");function Ph(t,e){var n,r,i,o=Ch.lastIndex=Rh.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=Ch.exec(t))&&(r=Rh.exec(e));)(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:kh(n,r)})),o=Rh.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})}function jh(t,e){var n,r=typeof e;return null==e||"boolean"===r?wh(e):("number"===r?kh:"string"===r?(n=lh(e))?(e=n,Th):Ph:e instanceof lh?Th:e instanceof Date?Ah:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}(e)?Sh:Array.isArray(e)?Mh:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?Lh:kh)(t,e)}function Dh(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}var Ih,Nh,Bh,Fh,zh=180/Math.PI,Vh={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Gh(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*zh,skewX:Math.atan(u)*zh,scaleX:a,scaleY:s}}function Uh(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:kh(t,i)},{i:u-2,x:kh(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:kh(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:kh(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:kh(t,n)},{i:s-2,x:kh(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var Hh=Uh((function(t){return"none"===t?Vh:(Ih||(Ih=document.createElement("DIV"),Nh=document.documentElement,Bh=document.defaultView),Ih.style.transform=t,t=Bh.getComputedStyle(Nh.appendChild(Ih),null).getPropertyValue("transform"),Nh.removeChild(Ih),Gh(+(t=t.slice(7,-1).split(","))[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),Wh=Uh((function(t){return null==t?Vh:(Fh||(Fh=document.createElementNS("http://www.w3.org/2000/svg","g")),Fh.setAttribute("transform",t),(t=Fh.transform.baseVal.consolidate())?Gh((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Vh)}),", ",")",")");function qh(t){return+t}var Yh=[0,1];function Xh(t){return t}function $h(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function Zh(t){var e,n=t[0],r=t[t.length-1];return n>r&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function Kh(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=$h(i,r),o=n(a,o)):(r=$h(r,i),o=n(o,a)),function(t){return o(r(t))}}function Jh(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=$h(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=Mf(t,e,1,r)-1;return o[n](i[n](e))}}function Qh(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function tp(){var t,e,n,r,i,o,a=Yh,s=Yh,u=jh,l=Xh;function c(){return r=Math.min(a.length,s.length)>2?Jh:Kh,i=o=null,f}function f(e){return isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(l(e)))}return f.invert=function(n){return l(e((o||(o=r(s,a.map(t),kh)))(n)))},f.domain=function(t){return arguments.length?(a=Gf.call(t,qh),l===Xh||(l=Zh(a)),c()):a.slice()},f.range=function(t){return arguments.length?(s=Uf.call(t),c()):s.slice()},f.rangeRound=function(t){return s=Uf.call(t),u=Dh,c()},f.clamp=function(t){return arguments.length?(l=t?Zh(a):Xh,f):l!==Xh},f.interpolate=function(t){return arguments.length?(u=t,c()):u},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,c()}}function ep(t,e){return tp()(t,e)}function np(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function rp(t){return(t=np(Math.abs(t)))?t[1]:NaN}var ip,op=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ap(t){if(!(e=op.exec(t)))throw new Error("invalid format: "+t);var e;return new sp({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function sp(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function up(t,e){var n=np(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}ap.prototype=sp.prototype,sp.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var lp={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return up(100*t,e)},r:up,s:function(t,e){var n=np(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(ip=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+np(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function cp(t){return t}var fp,hp,pp,dp=Array.prototype.map,vp=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function gp(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?cp:(e=dp.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?cp:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(dp.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=ap(t)).fill,n=t.align,f=t.sign,h=t.symbol,p=t.zero,d=t.width,v=t.comma,g=t.precision,y=t.trim,_=t.type;"n"===_?(v=!0,_="g"):lp[_]||(void 0===g&&(g=12),y=!0,_="g"),(p||"0"===e&&"="===n)&&(p=!0,e="0",n="=");var m="$"===h?i:"#"===h&&/[boxX]/.test(_)?"0"+_.toLowerCase():"",b="$"===h?o:/[%p]/.test(_)?u:"",x=lp[_],w=/[defgprs%]/.test(_);function O(t){var i,o,u,h=m,O=b;if("c"===_)O=x(t)+O,t="";else{var E=(t=+t)<0;if(t=isNaN(t)?c:x(Math.abs(t),g),y&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),E&&0==+t&&(E=!1),h=(E?"("===f?f:l:"-"===f||"("===f?"":f)+h,O=("s"===_?vp[8+ip/3]:"")+O+(E&&"("===f?")":""),w)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){O=(46===u?a+t.slice(i+1):t.slice(i))+O,t=t.slice(0,i);break}}v&&!p&&(t=r(t,1/0));var T=h.length+t.length+O.length,S=T<d?new Array(d-T+1).join(e):"";switch(v&&p&&(t=r(S+t,S.length?d-O.length:1/0),S=""),n){case"<":t=h+t+O+S;break;case"=":t=h+S+t+O;break;case"^":t=S.slice(0,T=S.length>>1)+h+t+O+S.slice(T);break;default:t=S+h+t+O}return s(t)}return g=void 0===g?6:/[gprs]/.test(_)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),O.toString=function(){return t+""},O}return{format:f,formatPrefix:function(t,e){var n=f(((t=ap(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(rp(e)/3))),i=Math.pow(10,-r),o=vp[8+r/3];return function(t){return n(i*t)+o}}}}function yp(t,e,n,r){var i,o=Df(t,e,n);switch((r=ap(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(rp(e)/3)))-rp(Math.abs(t)))}(o,a))||(r.precision=i),pp(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,rp(e)-rp(t))+1}(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(t){return Math.max(0,-rp(Math.abs(t)))}(o))||(r.precision=i-2*("%"===r.type))}return hp(r)}function _p(t){var e=t.domain;return t.ticks=function(t){var n=e();return Pf(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return yp(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),o=0,a=i.length-1,s=i[o],u=i[a];return u<s&&(r=s,s=u,u=r,r=o,o=a,a=r),(r=jf(s,u,n))>0?r=jf(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=jf(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(u/r)*r,e(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(u*r)/r,e(i)),t},t}function mp(){var t=ep(Xh,Xh);return t.copy=function(){return Qh(t,mp())},If.apply(t,arguments),_p(t)}function bp(t,e){var n,r=0,i=(t=t.slice()).length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function xp(t){return Math.log(t)}function wp(t){return Math.exp(t)}function Op(t){return-Math.log(-t)}function Ep(t){return-Math.exp(-t)}function Tp(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Sp(t){return function(e){return-t(-e)}}function Mp(t){var e,n,r=t(xp,wp),i=r.domain,o=10;function a(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(o),n=function(t){return 10===t?Tp:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(o),i()[0]<0?(e=Sp(e),n=Sp(n),t(Op,Ep)):t(xp,wp),r}return r.base=function(t){return arguments.length?(o=+t,a()):o},r.domain=function(t){return arguments.length?(i(t),a()):i()},r.ticks=function(t){var r,a=i(),s=a[0],u=a[a.length-1];(r=u<s)&&(h=s,s=u,u=h);var l,c,f,h=e(s),p=e(u),d=null==t?10:+t,v=[];if(!(o%1)&&p-h<d){if(h=Math.round(h)-1,p=Math.round(p)+1,s>0){for(;h<p;++h)for(c=1,l=n(h);c<o;++c)if(!((f=l*c)<s)){if(f>u)break;v.push(f)}}else for(;h<p;++h)for(c=o-1,l=n(h);c>=1;--c)if(!((f=l*c)<s)){if(f>u)break;v.push(f)}}else v=Pf(h,p,Math.min(p-h,d)).map(n);return r?v.reverse():v},r.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=hp(i)),t===1/0)return i;null==t&&(t=10);var a=Math.max(1,o*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*o<o-.5&&(r*=o),r<=a?i(t):""}},r.nice=function(){return i(bp(i(),{floor:function(t){return n(Math.floor(e(t)))},ceil:function(t){return n(Math.ceil(e(t)))}}))},r}fp=gp({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),hp=fp.format,pp=fp.formatPrefix;var Ap=new Date,kp=new Date;function Lp(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},i.round=function(t){var e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},i.range=function(n,r,o){var a,s=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<r);return s},i.filter=function(n){return Lp((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return Ap.setTime(+e),kp.setTime(+r),t(Ap),t(kp),Math.floor(n(Ap,kp))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var Cp=Lp((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));Cp.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?Lp((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):Cp:null};var Rp=Lp((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),Pp=Lp((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),jp=Lp((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),Dp=Lp((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1}));function Ip(t){return Lp((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var Np=Ip(0),Bp=Ip(1),Fp=(Ip(2),Ip(3),Ip(4)),zp=(Ip(5),Ip(6),Lp((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}))),Vp=Lp((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));Vp.every=function(t){return isFinite(t=Math.floor(t))&&t>0?Lp((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var Gp=Lp((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}));function Up(t){return Lp((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var Hp=Up(0),Wp=Up(1),qp=(Up(2),Up(3),Up(4)),Yp=(Up(5),Up(6),Lp((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()})));function Xp(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function $p(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Zp(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}Yp.every=function(t){return isFinite(t=Math.floor(t))&&t>0?Lp((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var Kp,Jp,Qp={"-":"",_:" ",0:"0"},td=/^\s*\d+/,ed=/^%/,nd=/[\\^$*+?|[\]().{}]/g;function rd(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function id(t){return t.replace(nd,"\\$&")}function od(t){return new RegExp("^(?:"+t.map(id).join("|")+")","i")}function ad(t){for(var e={},n=-1,r=t.length;++n<r;)e[t[n].toLowerCase()]=n;return e}function sd(t,e,n){var r=td.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function ud(t,e,n){var r=td.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function ld(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function cd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function fd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function hd(t,e,n){var r=td.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function pd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function dd(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function vd(t,e,n){var r=td.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function gd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function yd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function _d(t,e,n){var r=td.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function md(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function bd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function xd(t,e,n){var r=td.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function wd(t,e,n){var r=td.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function Od(t,e,n){var r=td.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ed(t,e,n){var r=ed.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function Td(t,e,n){var r=td.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function Sd(t,e,n){var r=td.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function Md(t,e){return rd(t.getDate(),e,2)}function Ad(t,e){return rd(t.getHours(),e,2)}function kd(t,e){return rd(t.getHours()%12||12,e,2)}function Ld(t,e){return rd(1+Dp.count(Vp(t),t),e,3)}function Cd(t,e){return rd(t.getMilliseconds(),e,3)}function Rd(t,e){return Cd(t,e)+"000"}function Pd(t,e){return rd(t.getMonth()+1,e,2)}function jd(t,e){return rd(t.getMinutes(),e,2)}function Dd(t,e){return rd(t.getSeconds(),e,2)}function Id(t){var e=t.getDay();return 0===e?7:e}function Nd(t,e){return rd(Np.count(Vp(t)-1,t),e,2)}function Bd(t,e){var n=t.getDay();return t=n>=4||0===n?Fp(t):Fp.ceil(t),rd(Fp.count(Vp(t),t)+(4===Vp(t).getDay()),e,2)}function Fd(t){return t.getDay()}function zd(t,e){return rd(Bp.count(Vp(t)-1,t),e,2)}function Vd(t,e){return rd(t.getFullYear()%100,e,2)}function Gd(t,e){return rd(t.getFullYear()%1e4,e,4)}function Ud(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+rd(e/60|0,"0",2)+rd(e%60,"0",2)}function Hd(t,e){return rd(t.getUTCDate(),e,2)}function Wd(t,e){return rd(t.getUTCHours(),e,2)}function qd(t,e){return rd(t.getUTCHours()%12||12,e,2)}function Yd(t,e){return rd(1+Gp.count(Yp(t),t),e,3)}function Xd(t,e){return rd(t.getUTCMilliseconds(),e,3)}function $d(t,e){return Xd(t,e)+"000"}function Zd(t,e){return rd(t.getUTCMonth()+1,e,2)}function Kd(t,e){return rd(t.getUTCMinutes(),e,2)}function Jd(t,e){return rd(t.getUTCSeconds(),e,2)}function Qd(t){var e=t.getUTCDay();return 0===e?7:e}function tv(t,e){return rd(Hp.count(Yp(t)-1,t),e,2)}function ev(t,e){var n=t.getUTCDay();return t=n>=4||0===n?qp(t):qp.ceil(t),rd(qp.count(Yp(t),t)+(4===Yp(t).getUTCDay()),e,2)}function nv(t){return t.getUTCDay()}function rv(t,e){return rd(Wp.count(Yp(t)-1,t),e,2)}function iv(t,e){return rd(t.getUTCFullYear()%100,e,2)}function ov(t,e){return rd(t.getUTCFullYear()%1e4,e,4)}function av(){return"+0000"}function sv(){return"%"}function uv(t){return+t}function lv(t){return Math.floor(+t/1e3)}function cv(t){return Kp=function(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,l=od(i),c=ad(i),f=od(o),h=ad(o),p=od(a),d=ad(a),v=od(s),g=ad(s),y=od(u),_=ad(u),m={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:Md,e:Md,f:Rd,H:Ad,I:kd,j:Ld,L:Cd,m:Pd,M:jd,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:uv,s:lv,S:Dd,u:Id,U:Nd,V:Bd,w:Fd,W:zd,x:null,X:null,y:Vd,Y:Gd,Z:Ud,"%":sv},b={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:Hd,e:Hd,f:$d,H:Wd,I:qd,j:Yd,L:Xd,m:Zd,M:Kd,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:uv,s:lv,S:Jd,u:Qd,U:tv,V:ev,w:nv,W:rv,x:null,X:null,y:iv,Y:ov,Z:av,"%":sv},x={a:function(t,e,n){var r=p.exec(e.slice(n));return r?(t.w=d[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=y.exec(e.slice(n));return r?(t.m=_[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=g[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return E(t,e,n,r)},d:yd,e:yd,f:Od,H:md,I:md,j:_d,L:wd,m:gd,M:bd,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=c[r[0].toLowerCase()],n+r[0].length):-1},q:vd,Q:Td,s:Sd,S:xd,u:ud,U:ld,V:cd,w:sd,W:fd,x:function(t,e,r){return E(t,n,e,r)},X:function(t,e,n){return E(t,r,e,n)},y:pd,Y:hd,Z:dd,"%":Ed};function w(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s<l;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Qp[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function O(t,e){return function(n){var r,i,o=Zp(1900,void 0,1);if(E(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(!e||"Z"in o||(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=$p(Zp(o.y,0,1))).getUTCDay(),r=i>4||0===i?Wp.ceil(r):Wp(r),r=Gp.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=Xp(Zp(o.y,0,1))).getDay(),r=i>4||0===i?Bp.ceil(r):Bp(r),r=Dp.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?$p(Zp(o.y,0,1)).getUTCDay():Xp(Zp(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,$p(o)):Xp(o)}}function E(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=x[i in Qp?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return(m.x=w(n,m),m.X=w(r,m),m.c=w(e,m),b.x=w(n,b),b.X=w(r,b),b.c=w(e,b),{format:function(t){var e=w(t+="",m);return e.toString=function(){return t},e},parse:function(t){var e=O(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=O(t+="",!0);return e.toString=function(){return t},e}})}(t),Jp=Kp.format,Kp.parse,Kp.utcFormat,Kp.utcParse,Kp}cv({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function fv(t){return new Date(t)}function hv(t){return t instanceof Date?+t:+new Date(+t)}function pv(t,e,n,r,i,o,a,s,u){var l=ep(Xh,Xh),c=l.invert,f=l.domain,h=u(".%L"),p=u(":%S"),d=u("%I:%M"),v=u("%I %p"),g=u("%a %d"),y=u("%b %d"),_=u("%B"),m=u("%Y"),b=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function x(s){return(a(s)<s?h:o(s)<s?p:i(s)<s?d:r(s)<s?v:e(s)<s?n(s)<s?g:y:t(s)<s?_:m)(s)}function w(e,n,r,i){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(r-n)/e,a=Sf((function(t){return t[2]})).right(b,o);a===b.length?(i=Df(n/31536e6,r/31536e6,e),e=t):a?(i=(a=b[o/b[a-1][2]<b[a][2]/o?a-1:a])[1],e=a[0]):(i=Math.max(Df(n,r,e),1),e=s)}return null==i?e:e.every(i)}return l.invert=function(t){return new Date(c(t))},l.domain=function(t){return arguments.length?f(Gf.call(t,hv)):f().map(fv)},l.ticks=function(t,e){var n,r=f(),i=r[0],o=r[r.length-1],a=o<i;return a&&(n=i,i=o,o=n),n=(n=w(t,i,o,e))?n.range(i,o+1):[],a?n.reverse():n},l.tickFormat=function(t,e){return null==e?x:u(e)},l.nice=function(t,e){var n=f();return(t=w(t,n[0],n[n.length-1],e))?f(bp(n,t)):l},l.copy=function(){return Qh(l,pv(t,e,n,r,i,o,a,s,u))},l}var dv=function(){function t(t){this.state={options:{}},this.patternScale={},this.colorScale={},this.services=t}return t.prototype.sanitize=function(t){return t.datasets.forEach((function(t){t.data=t.data.map((function(t){return t.date&&!t.date.getTime&&(t.date=new Date(t.date)),t}))})),t},t.prototype.getDisplayData=function(){var t=Pc.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=Sc.clone(this.get("data"));return n.datasets=n.datasets.filter((function(n){return e[n.label]===t})),n},t.prototype.getData=function(){return this.get("data")},t.prototype.setData=function(t){var e=this.sanitize(Sc.clone(t)),n=this.generateDataLabels(e);return this.set({data:e,dataLabels:n}),e},t.prototype.generateDataLabels=function(t){var e={};return t.datasets.forEach((function(t){e[t.label]=Pc.items.status.ACTIVE})),e},t.prototype.getOptions=function(){return this.state.options},t.prototype.set=function(t,e){void 0===e&&(e=!1),this.state=Object.assign({},this.state,t),e||this.update()},t.prototype.get=function(t){return t?this.state[t]:this.state},t.prototype.setOptions=function(t){this.set({options:Sc.merge(this.getOptions(),t)})},t.prototype.update=function(){this.getDisplayData()&&(this.updateAllDataLabels(),this.setColorScale(),this.services.events.dispatchEvent("model-update"))},t.prototype.setUpdateCallback=function(t){this.updateCallback=t},t.prototype.toggleDataLabel=function(t){var e=Pc.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.get("dataLabels"),o=Object.keys(i).some((function(t){return i[t]===r})),a=Object.keys(i).filter((function(t){return i[t]===n}));o?1===a.length&&a[0]===t?Object.keys(i).forEach((function(t){i[t]=n})):i[t]=i[t]===r?n:r:Object.keys(i).forEach((function(e){i[e]=e===t?n:r})),this.set({dataLabels:i})},t.prototype.setColorScale=function(){var t=this;if(this.getDisplayData().datasets[0].fillColors)this.getDisplayData().datasets.forEach((function(e){t.colorScale[e.label]=Wf().range(e.fillColors).domain(t.allDataLabels)}));else{var e=Of;this.getData().datasets.forEach((function(n,r){t.colorScale[n.label]=Wf().range([e[r]]).domain(t.allDataLabels)}))}},t.prototype.getIsFilled=function(t,e,n,r){var i=this.getOptions();return i.getIsFilled?i.getIsFilled(t,e,n,r):r},t.prototype.getFillColor=function(t,e,n){var r=this.getOptions(),i=this.getFillScale()[t](e);return r.getFillColor?r.getFillColor(t,e,n,i):i},t.prototype.getStrokeColor=function(t,e,n){var r=this.getOptions(),i=this.colorScale[t](e);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.getFillScale=function(){return this.colorScale},t.prototype.updateAllDataLabels=function(){var t=this;this.allDataLabels?this.getDisplayData().labels.forEach((function(e){-1===t.allDataLabels.indexOf(e)&&t.allDataLabels.push(e)})):this.allDataLabels=this.getDisplayData().labels},t}(),vv=function(){function t(t,e){this.model=t,this.services=e,this.init()}return t.prototype.init=function(){},t.prototype.update=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t}(),gv="http://www.w3.org/1999/xhtml",yv={svg:"http://www.w3.org/2000/svg",xhtml:gv,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function _v(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),yv.hasOwnProperty(e)?{space:yv[e],local:t}:t}function mv(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===gv&&e.documentElement.namespaceURI===gv?e.createElement(t):e.createElementNS(n,t)}}function bv(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function xv(t){var e=_v(t);return(e.local?bv:mv)(e)}function wv(){}function Ov(t){return null==t?wv:function(){return this.querySelector(t)}}function Ev(){return[]}function Tv(t){return null==t?Ev:function(){return this.querySelectorAll(t)}}function Sv(t){return function(){return this.matches(t)}}function Mv(t){return new Array(t.length)}function Av(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}Av.prototype={constructor:Av,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function kv(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new Av(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function Lv(t,e,n,r,i,o,a){var s,u,l,c={},f=e.length,h=o.length,p=new Array(f);for(s=0;s<f;++s)(u=e[s])&&(p[s]=l="$"+a.call(u,u.__data__,s,e),l in c?i[s]=u:c[l]=u);for(s=0;s<h;++s)(u=c[l="$"+a.call(t,o[s],s,o)])?(r[s]=u,u.__data__=o[s],c[l]=null):n[s]=new Av(t,o[s]);for(s=0;s<f;++s)(u=e[s])&&c[p[s]]===u&&(i[s]=u)}function Cv(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function Rv(t){return function(){this.removeAttribute(t)}}function Pv(t){return function(){this.removeAttributeNS(t.space,t.local)}}function jv(t,e){return function(){this.setAttribute(t,e)}}function Dv(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Iv(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Nv(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function Bv(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Fv(t){return function(){this.style.removeProperty(t)}}function zv(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Vv(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function Gv(t,e){return t.style.getPropertyValue(e)||Bv(t).getComputedStyle(t,null).getPropertyValue(e)}function Uv(t){return function(){delete this[t]}}function Hv(t,e){return function(){this[t]=e}}function Wv(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function qv(t){return t.trim().split(/^|\s+/)}function Yv(t){return t.classList||new Xv(t)}function Xv(t){this._node=t,this._names=qv(t.getAttribute("class")||"")}function $v(t,e){for(var n=Yv(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function Zv(t,e){for(var n=Yv(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function Kv(t){return function(){$v(this,t)}}function Jv(t){return function(){Zv(this,t)}}function Qv(t,e){return function(){(e.apply(this,arguments)?$v:Zv)(this,t)}}function tg(){this.textContent=""}function eg(t){return function(){this.textContent=t}}function ng(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function rg(){this.innerHTML=""}function ig(t){return function(){this.innerHTML=t}}function og(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function ag(){this.nextSibling&&this.parentNode.appendChild(this)}function sg(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function ug(){return null}function lg(){var t=this.parentNode;t&&t.removeChild(this)}function cg(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function fg(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}Xv.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var hg={},pg=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(hg={mouseenter:"mouseover",mouseleave:"mouseout"}));function dg(t,e,n){return t=vg(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function vg(t,e,n){return function(r){var i=pg;pg=r;try{t.call(this,this.__data__,e,n)}finally{pg=i}}}function gg(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function yg(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.capture);++i?e.length=i:delete this.__on}}}function _g(t,e,n){var r=hg.hasOwnProperty(t.type)?dg:vg;return function(i,o,a){var s,u=this.__on,l=r(e,o,a);if(u)for(var c=0,f=u.length;c<f;++c)if((s=u[c]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},u?u.push(s):this.__on=[s]}}function mg(t,e,n){var r=Bv(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function bg(t,e){return function(){return mg(this,t,e)}}function xg(t,e){return function(){return mg(this,t,e.apply(this,arguments))}}var wg=[null];function Og(t,e){this._groups=t,this._parents=e}function Eg(){return new Og([[document.documentElement]],wg)}function Tg(t){return"string"==typeof t?new Og([[document.querySelector(t)]],[document.documentElement]):new Og([[t]],wg)}function Sg(){for(var t,e=pg;t=e.sourceEvent;)e=t;return e}function Mg(t){var e=Sg();return e.changedTouches&&(e=e.changedTouches[0]),function(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}(t,e)}Og.prototype=Eg.prototype={constructor:Og,select:function(t){"function"!=typeof t&&(t=Ov(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,l=r[i]=new Array(u),c=0;c<u;++c)(o=s[c])&&(a=t.call(o,o.__data__,c,s))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new Og(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=Tv(t));for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new Og(r,i)},filter:function(t){"function"!=typeof t&&(t=Sv(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new Og(r,this._parents)},data:function(t,e){if(!t)return p=new Array(this.size()),l=-1,this.each((function(t){p[++l]=t})),p;var n=e?Lv:kv,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),l=0;l<o;++l){var c=r[l],f=i[l],h=f.length,p=t.call(c,c&&c.__data__,l,r),d=p.length,v=s[l]=new Array(d),g=a[l]=new Array(d);n(c,f,v,g,u[l]=new Array(h),p,e);for(var y,_,m=0,b=0;m<d;++m)if(y=v[m]){for(m>=b&&(b=m+1);!(_=g[b])&&++b<d;);y._next=_||null}}return(a=new Og(a,r))._enter=s,a._exit=u,a},enter:function(){return new Og(this._enter||this._groups.map(Mv),this._parents)},exit:function(){return new Og(this._exit||this._groups.map(Mv),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return r="function"==typeof t?t(r):r.append(t+""),null!=e&&(i=e(i)),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],f=l.length,h=a[s]=new Array(f),p=0;p<f;++p)(u=l[p]||c[p])&&(h[p]=u);for(;s<r;++s)a[s]=e[s];return new Og(a,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Cv);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new Og(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,e){var n=_v(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?Pv:Rv:"function"==typeof e?n.local?Nv:Iv:n.local?Dv:jv)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?Fv:"function"==typeof e?Vv:zv)(t,e,null==n?"":n)):Gv(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Uv:"function"==typeof e?Wv:Hv)(t,e)):this.node()[t]},classed:function(t,e){var n=qv(t+"");if(arguments.length<2){for(var r=Yv(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?Qv:e?Kv:Jv)(n,e))},text:function(t){return arguments.length?this.each(null==t?tg:("function"==typeof t?ng:eg)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?rg:("function"==typeof t?og:ig)(t)):this.node().innerHTML},raise:function(){return this.each(ag)},lower:function(){return this.each(sg)},append:function(t){var e="function"==typeof t?t:xv(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:xv(t),r=null==e?ug:"function"==typeof e?e:Ov(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(lg)},clone:function(t){return this.select(t?fg:cg)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=gg(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?_g:yg,null==n&&(n=!1),r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value},dispatch:function(t,e){return this.each(("function"==typeof e?xg:bg)(t,e))}};var Ag={prefix:"bx",selectorTabbable:"\n a[href], area[href], input:not([disabled]):not([tabindex='-1']),\n button:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']),\n textarea:not([disabled]):not([tabindex='-1']),\n iframe, object, embed, *[tabindex]:not([tabindex='-1']), *[contenteditable=true]\n "},kg=function(){if("undefined"!=typeof Map)return Map;function t(t,e){var n=-1;return t.some((function(t,r){return t[0]===e&&(n=r,!0)})),n}return function(){function e(){this.__entries__=[]}var n={size:{configurable:!0}};return n.size.get=function(){return this.__entries__.length},e.prototype.get=function(e){var n=t(this.__entries__,e),r=this.__entries__[n];return r&&r[1]},e.prototype.set=function(e,n){var r=t(this.__entries__,e);~r?this.__entries__[r][1]=n:this.__entries__.push([e,n])},e.prototype.delete=function(e){var n=this.__entries__,r=t(n,e);~r&&n.splice(r,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){void 0===e&&(e=null);for(var n=0,r=this.__entries__;n<r.length;n+=1){var i=r[n];t.call(e,i[1],i[0])}},Object.defineProperties(e.prototype,n),e}()}(),Lg="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,Cg="undefined"!=typeof global&&global.Math===Math?global:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),Rg="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(Cg):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)},Pg=["top","right","bottom","left","width","height","size","weight"],jg="undefined"!=typeof MutationObserver,Dg=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t,e){var n=!1,r=!1,i=0;function o(){n&&(n=!1,t()),r&&s()}function a(){Rg(o)}function s(){var t=Date.now();if(n){if(t-i<2)return;r=!0}else n=!0,r=!1,setTimeout(a,e);i=t}return s}(this.refresh.bind(this),20)};Dg.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},Dg.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},Dg.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},Dg.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},Dg.prototype.connect_=function(){Lg&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),jg?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},Dg.prototype.disconnect_=function(){Lg&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},Dg.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e=""),Pg.some((function(t){return!!~e.indexOf(t)}))&&this.refresh()},Dg.getInstance=function(){return this.instance_||(this.instance_=new Dg),this.instance_},Dg.instance_=null;var Ig=function(t,e){for(var n=0,r=Object.keys(e);n<r.length;n+=1){var i=r[n];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},Ng=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||Cg},Bg=Hg(0,0,0,0);function Fg(t){return parseFloat(t)||0}function zg(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return e.reduce((function(e,n){return e+Fg(t["border-"+n+"-width"])}),0)}function Vg(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return Bg;var r=Ng(t).getComputedStyle(t),i=function(t){for(var e={},n=0,r=["top","right","bottom","left"];n<r.length;n+=1){var i=r[n],o=t["padding-"+i];e[i]=Fg(o)}return e}(r),o=i.left+i.right,a=i.top+i.bottom,s=Fg(r.width),u=Fg(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=zg(r,"left","right")+o),Math.round(u+a)!==n&&(u-=zg(r,"top","bottom")+a)),!function(t){return t===Ng(t).document.documentElement}(t)){var l=Math.round(s+o)-e,c=Math.round(u+a)-n;1!==Math.abs(l)&&(s-=l),1!==Math.abs(c)&&(u-=c)}return Hg(i.left,i.top,s,u)}var Gg="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof Ng(t).SVGGraphicsElement}:function(t){return t instanceof Ng(t).SVGElement&&"function"==typeof t.getBBox};function Ug(t){return Lg?Gg(t)?function(t){var e=t.getBBox();return Hg(0,0,e.width,e.height)}(t):Vg(t):Bg}function Hg(t,e,n,r){return{x:t,y:e,width:n,height:r}}var Wg=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=Hg(0,0,0,0),this.target=t};Wg.prototype.isActive=function(){var t=Ug(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},Wg.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var qg=function(t,e){var n=function(t){var e=t.x,n=t.y,r=t.width,i=t.height,o="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,a=Object.create(o.prototype);return Ig(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}(e);Ig(this,{target:t,contentRect:n})},Yg=function(t,e,n){if(this.activeObservations_=[],this.observations_=new kg,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n};Yg.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof Ng(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new Wg(t)),this.controller_.addObserver(this),this.controller_.refresh())}},Yg.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof Ng(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},Yg.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},Yg.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},Yg.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new qg(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},Yg.prototype.clearActive=function(){this.activeObservations_.splice(0)},Yg.prototype.hasActive=function(){return this.activeObservations_.length>0};var Xg="undefined"!=typeof WeakMap?new WeakMap:new kg,$g=function(t){if(!(this instanceof $g))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var e=Dg.getInstance(),n=new Yg(t,e,this);Xg.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){$g.prototype[t]=function(){return(e=Xg.get(this))[t].apply(e,arguments);var e}}));var Zg=void 0!==Cg.ResizeObserver?Cg.ResizeObserver:$g,Kg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return s(e,t),e.getSVGElementSize=function(t,e){t.attr||(t=Tg(t));var n,r,i,o,a={width:t.attr("width"),height:t.attr("height")};try{r={width:(n=t.node().getBBox()).width,height:n.height}}catch(t){}try{o={width:(i=t.node().getBoundingClientRect()).width,height:i.height}}catch(t){}var s={width:t.node().clientWidth,height:t.node().clientHeight},u=function(t){return!!(t&&t.width&&t.height&&!isNaN(t.height)&&!isNaN(t.width)&&-1===(""+t.width+t.height).indexOf("%")&&t.width>0&&t.height>0)};if(e){if(e.useAttrs&&u(a))return a;if(e.useClientDimensions&&u(s))return s;if(e.useBBox&&u(r))return r;if(e.useBoundingRect&&u(o))return o}try{var l={width:Sc.getProperty(t.node(),"width","baseVal","value"),height:Sc.getProperty(t.node(),"height","baseVal","value")};if(u(l))return l}catch(t){if(u(s))return s;if(u(r))return r;if(u(a))return a}return{width:0,height:0}},e.appendOrSelect=function(t,e){var n=e.split("."),r=n[0],i=t.select(e);return i.empty()?t.append(r).attr("class",n.slice(1).join(" ")):i},e.prototype.init=function(){this.styleHolderElement(),this.addSVGElement(),this.model.getOptions().resizable&&this.addResizeListener()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder();Tg(this.getHolder()).classed(Ag.prefix+"--chart-holder",!0);var e=this.model.getOptions(),n=e.width,r=e.height;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.addSVGElement=function(){var t=Sc.getProperty(this.model.getOptions(),"style","prefix"),e=Tg(this.getHolder()).append("svg").classed(Ag.prefix+"--"+t+"--chart-svg",!0).attr("height","100%").attr("width","100%");this.svg=e.node()},e.prototype.getMainSVG=function(){return this.svg},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=Sc.debounce((function(i,o){e&&(Math.abs(n-e.clientWidth)>1||Math.abs(r-e.clientHeight)>1)&&(n=e.clientWidth,r=e.clientHeight,t.services.events.dispatchEvent("chart-resize"))}),12.5);new Zg(i).observe(e)}},e}(vv),Jg=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return s(e,t),e.prototype.init=function(){this.documentFragment=document.createDocumentFragment()},e.prototype.addEventListener=function(t,e){this.documentFragment.addEventListener(t,e)},e.prototype.removeEventListener=function(t,e){this.documentFragment.removeEventListener(t,e)},e.prototype.dispatchEvent=function(t,e){var n;e?n=new CustomEvent(t,{detail:e}):(n=document.createEvent("Event")).initEvent(t,!1,!0),this.documentFragment.dispatchEvent(n)},e}(vv),Qg={value:function(){}};function ty(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new ey(r)}function ey(t){this._=t}function ny(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function ry(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function iy(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=Qg,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}ey.prototype=ty.prototype={constructor:ey,on:function(t,e){var n,r=this._,i=ny(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o<a;)if(n=(t=i[o]).type)r[n]=iy(r[n],t.name,e);else if(null==e)for(n in r)r[n]=iy(r[n],t.name,null);return this}for(;++o<a;)if((n=(t=i[o]).type)&&(n=ry(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new ey(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(r=this._[t]).length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var oy,ay,sy=0,uy=0,ly=0,cy=0,fy=0,hy=0,py="object"==typeof performance&&performance.now?performance:Date,dy="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function vy(){return fy||(dy(gy),fy=py.now()+hy)}function gy(){fy=0}function yy(){this._call=this._time=this._next=null}function _y(t,e,n){var r=new yy;return r.restart(t,e,n),r}function my(){fy=(cy=py.now())+hy,sy=uy=0;try{!function(){vy(),++sy;for(var t,e=oy;e;)(t=fy-e._time)>=0&&e._call.call(null,t),e=e._next;--sy}()}finally{sy=0,function(){var t,e,n=oy,r=1/0;for(;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:oy=e);ay=t,xy(r)}(),fy=0}}function by(){var t=py.now(),e=t-cy;e>1e3&&(hy-=e,cy=t)}function xy(t){sy||(uy&&(uy=clearTimeout(uy)),t-fy>24?(t<1/0&&(uy=setTimeout(my,t-py.now()-hy)),ly&&(ly=clearInterval(ly))):(ly||(cy=py.now(),ly=setInterval(by,1e3)),sy=1,dy(my)))}function wy(t,e,n){var r=new yy;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}yy.prototype=_y.prototype={constructor:yy,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?vy():+n)+(null==e?0:+e),this._next||ay===this||(ay?ay._next=this:oy=this,ay=this),this._call=t,this._time=n,xy()},stop:function(){this._call&&(this._call=null,this._time=1/0,xy())}};var Oy=ty("start","end","cancel","interrupt"),Ey=[];function Ty(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(u){var l,c,f,h;if(1!==n.state)return s();for(l in i)if((h=i[l]).name===n.name){if(3===h.state)return wy(o);4===h.state?(h.state=6,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[l]):+l<e&&(h.state=6,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[l])}if(wy((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(u))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,r=new Array(f=n.tween.length),l=0,c=-1;l<f;++l)(h=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++c]=h);r.length=c+1}}function a(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=6,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=_y((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:r,group:i,on:Oy,tween:Ey,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Sy(t,e){var n=Ay(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function My(t,e){var n=Ay(t,e);if(n.state>3)throw new Error("too late; already running");return n}function Ay(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function ky(t,e){var n,r;return function(){var i=My(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function Ly(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=My(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}}function Cy(t,e,n){var r=t._id;return t.each((function(){var t=My(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return Ay(t,r).value[e]}}function Ry(t,e){var n;return("number"==typeof e?kh:e instanceof lh?Th:(n=lh(e))?(e=n,Th):Ph)(t,e)}function Py(t){return function(){this.removeAttribute(t)}}function jy(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Dy(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function Iy(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function Ny(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttribute(t))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function By(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttributeNS(t.space,t.local))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Fy(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function zy(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Vy(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&zy(t,i)),n}return i._value=e,i}function Gy(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Fy(t,i)),n}return i._value=e,i}function Uy(t,e){return function(){Sy(this,t).delay=+e.apply(this,arguments)}}function Hy(t,e){return e=+e,function(){Sy(this,t).delay=e}}function Wy(t,e){return function(){My(this,t).duration=+e.apply(this,arguments)}}function qy(t,e){return e=+e,function(){My(this,t).duration=e}}function Yy(t,e){if("function"!=typeof e)throw new Error;return function(){My(this,t).ease=e}}function Xy(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?Sy:My;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var $y=Eg.prototype.constructor;function Zy(t){return function(){this.style.removeProperty(t)}}function Ky(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function Jy(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&Ky(t,o,n)),r}return o._value=e,o}function Qy(t){return function(e){this.textContent=t.call(this,e)}}function t_(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&Qy(r)),e}return r._value=t,r}var e_=0;function n_(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function r_(t){return Eg().transition(t)}function i_(){return++e_}var o_=Eg.prototype;n_.prototype=r_.prototype={constructor:n_,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Ov(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,l=r[a],c=l.length,f=o[a]=new Array(c),h=0;h<c;++h)(s=l[h])&&(u=t.call(s,s.__data__,h,l))&&("__data__"in s&&(u.__data__=s.__data__),f[h]=u,Ty(f[h],e,n,h,f,Ay(s,n)));return new n_(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Tv(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,l=r[s],c=l.length,f=0;f<c;++f)if(u=l[f]){for(var h,p=t.call(u,u.__data__,f,l),d=Ay(u,n),v=0,g=p.length;v<g;++v)(h=p[v])&&Ty(h,e,n,v,p,d);o.push(p),a.push(u)}return new n_(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=Sv(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new n_(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],f=l.length,h=a[s]=new Array(f),p=0;p<f;++p)(u=l[p]||c[p])&&(h[p]=u);for(;s<r;++s)a[s]=e[s];return new n_(a,this._parents,this._name,this._id)},selection:function(){return new $y(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=i_(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=Ay(a,e);Ty(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new n_(r,this._parents,t,n)},call:o_.call,nodes:o_.nodes,node:o_.node,size:o_.size,empty:o_.empty,each:o_.each,on:function(t,e){var n=this._id;return arguments.length<2?Ay(this.node(),n).on.on(t):this.each(Xy(n,t,e))},attr:function(t,e){var n=_v(t),r="transform"===n?Wh:Ry;return this.attrTween(t,"function"==typeof e?(n.local?By:Ny)(n,r,Cy(this,"attr."+t,e)):null==e?(n.local?jy:Py)(n):(n.local?Iy:Dy)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=_v(t);return this.tween(n,(r.local?Vy:Gy)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?Hh:Ry;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=Gv(this,t),a=(this.style.removeProperty(t),Gv(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,Zy(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=Gv(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=Gv(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,Cy(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=My(this,t),l=u.on,c=null==u.value[a]?o||(o=Zy(e)):void 0;l===n&&i===c||(r=(n=l).copy()).on(s,i=c),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=Gv(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,Jy(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(Cy(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,t_(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=Ay(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?ky:Ly)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Uy:Hy)(e,t)):Ay(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Wy:qy)(e,t)):Ay(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(Yy(e,t)):Ay(this.node(),e).ease},end:function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0==--i&&o()}};n.each((function(){var n=My(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e}))}))}};var a_={time:null,delay:0,duration:250,ease:function(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}};function s_(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return a_.time=vy(),a_;return n}Eg.prototype.interrupt=function(t){return this.each((function(){!function(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}}(this,t)}))},Eg.prototype.transition=function(t){var e,n;t instanceof n_?(e=t._id,t=t._name):(e=i_(),(n=a_).time=vy(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&Ty(a,t,e,l,s,n||s_(a,e));return new n_(r,this._parents,t,e)};var u_=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return s(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener("model-update",(function(){t.pendingTransitions={}}))},e.prototype.getTransition=function(t,e){var n=this;if(!1===this.model.getOptions().animations||!1===e)return this.getInstantTransition(t);var r=r_(t).duration(Sc.getProperty(Kc,t,"duration")||Kc.default.duration);return this.pendingTransitions[r._id]=r,r.on("end interrupt cancel",(function(){delete n.pendingTransitions[r._id]})),r},e.prototype.getInstantTransition=function(t){var e=this,n=r_(t).duration(0);return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),n},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(vv);function l_(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Object.prototype.toString.call(t);return t instanceof Date||"object"==typeof t&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule"),console.warn((new Error).stack)),new Date(NaN))}function c_(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function f_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=c_(e);return n.setDate(n.getDate()+r),n}function h_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t).getTime(),r=c_(e);return new Date(n+r)}function p_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return h_(t,36e5*n)}function d_(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());return e.setSeconds(0,0),6e4*n+e.getTime()%6e4}function v_(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=l_(t);return e.setHours(0,0,0,0),e}function g_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=v_(t),r=v_(e),i=n.getTime()-d_(n),o=r.getTime()-d_(r);return Math.round((i-o)/864e5)}function y_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return h_(t,6e4*n)}function __(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=l_(t),n=e.getFullYear(),r=e.getMonth(),i=new Date(0);return i.setFullYear(n,r+1,0),i.setHours(0,0,0,0),i.getDate()}function m_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=c_(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=__(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function b_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return m_(t,12*n)}function x_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function w_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function O_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e);return n.getFullYear()-r.getFullYear()}function E_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e);return n.getTime()-r.getTime()}function T_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return f_(t,-n)}function S_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return p_(t,-n)}function M_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return y_(t,-n)}function A_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return m_(t,-n)}function k_(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=c_(e);return b_(t,-n)}var L_=require("d3-time-format/locale/en-US.json"),C_=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.scaleTypes={top:null,right:null,bottom:null,left:null},e.scales={top:null,right:null,bottom:null,left:null},e}return s(e,t),e.prototype.getDomainAxisPosition=function(){return this.domainAxisPosition},e.prototype.getRangeAxisPosition=function(){return this.rangeAxisPosition},e.prototype.update=function(t){var e=this;this.determineOrientation(),Object.keys(l).map((function(t){return l[t]})).forEach((function(t){e.scales[t]=e.createScale(t)}))},e.prototype.determineOrientation=function(){var t=this,e=this.model.getOptions();[l.LEFT,l.BOTTOM,l.RIGHT,l.TOP].forEach((function(n){var r=Sc.getProperty(e,"axes",n);if(r){var i=r.scaleType||h.LINEAR;t.scaleTypes[n]=i,i===h.LINEAR?t.rangeAxisPosition=n:t.domainAxisPosition=n}})),this.rangeAxisPosition===l.LEFT&&this.domainAxisPosition===l.BOTTOM?this.orientation=c.VERTICAL:this.orientation=c.HORIZONTAL},e.prototype.getOrientation=function(){return this.orientation},e.prototype.getScaleByPosition=function(t){return this.scales[t]},e.prototype.getScaleTypeByPosition=function(t){return this.scaleTypes[t]},e.prototype.getDomainScale=function(){return this.scales[this.domainAxisPosition]},e.prototype.getRangeScale=function(){return this.scales[this.rangeAxisPosition]},e.prototype.getMainXAxisPosition=function(){var t=[l.BOTTOM,l.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[l.LEFT,l.RIGHT];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainXScale=function(){return this.scales[this.getMainXAxisPosition()]},e.prototype.getMainYScale=function(){return this.scales[this.getMainYAxisPosition()]},e.prototype.getValueFromScale=function(t,e,n){var r=isNaN(e)?e.value:e,i=this.scaleTypes[t],o=this.scales[t];return i===h.LABELS?o(this.model.getDisplayData().labels[n])+o.step()/2:i===h.TIME?o(new Date(e.date||e.label)):o(r)},e.prototype.getDomainValue=function(t,e){return this.getValueFromScale(this.domainAxisPosition,t,e)},e.prototype.getRangeValue=function(t,e){return this.getValueFromScale(this.rangeAxisPosition,t,e)},e.prototype.getDataFromDomain=function(t){var e=this.model.getDisplayData(),n=[];switch(this.scaleTypes[this.domainAxisPosition]){case h.LABELS:var r=e.labels.indexOf(t);e.datasets.forEach((function(t){n.push({datasetLabel:t.label,value:t.data[r]})}));break;case h.TIME:var i=Object.keys(e.datasets[0].data[0]).filter((function(t){return"value"!==t}))[0];e.datasets.forEach((function(e){var r=e.label;e.data.filter((function(e){var n=new Date(e[i]),r=new Date(t);return n.getTime()===r.getTime()})).forEach((function(t){n.push(Object.assign({datasetLabel:r,value:t.value},t))}))}))}return n},e.prototype.getScaleDomain=function(t){var e,n=this.model.getOptions(),r=Sc.getProperty(n,"axes",t),i=this.model.getDisplayData(),o=i.datasets,a=i.labels;if(r&&r.scaleType===h.LABELS)return a||this.model.getDisplayData().datasets[0].data.map((function(t,e){return e+1}));if(r.stacked)e=Af(a.reduce((function(t,e,n){var r=o.map((function(t){return isNaN(t.data[n])?t.data[n].value:t.data[n]})),i=r.reduce((function(t,e){return t+e}),0);return t.concat(i,function(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&r>n&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&r>n&&(r=n);return r}(r))}),[]).concat(0));else{var s=o.reduce((function(t,e){return e.data.forEach((function(e){t=r.scaleType===h.TIME?t.concat(e.date):t.concat(isNaN(e)?e.value:e)})),t}),[]);r.scaleType!==h.TIME&&(s=s.concat(0)),e=Af(s)}if(r.scaleType===h.TIME){var u=Sc.getProperty(n,"timeScale","addSpaceOnEdges");if(u){var l=new Date(e[0]),c=new Date(e[1]);return function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e),i=x_(n,r),o=Math.abs(O_(n,r));n.setFullYear(n.getFullYear()-i*o);var a=x_(n,r)===-i,s=i*(o-a);return 0===s?0:s}(c,l)>1?[k_(l,u),b_(c,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e),i=x_(n,r),o=Math.abs(w_(n,r));n.setMonth(n.getMonth()-i*o);var a=x_(n,r)===-i,s=i*(o-a);return 0===s?0:s}(c,l)>1?[A_(l,u),m_(c,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=l_(t),r=l_(e),i=x_(n,r),o=Math.abs(g_(n,r));n.setDate(n.getDate()-i*o);var a=x_(n,r)===-i,s=i*(o-a);return 0===s?0:s}(c,l)>1?[T_(l,u),f_(c,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=E_(t,e)/36e5;return n>0?Math.floor(n):Math.ceil(n)}(c,l)>1?[S_(l,u),p_(c,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=E_(t,e)/6e4;return n>0?Math.floor(n):Math.ceil(n)}(c,l)>1?[M_(l,u),y_(c,u)]:[l,c]}return[new Date(e[0]),new Date(e[1])]}return e[1]=1.1*e[1],e[0]<0&&(e[0]=1.1*e[0]),e},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=Sc.getProperty(e,"axes",t);if(!n)return null;var r,i=Sc.getProperty(n,"scaleType")||h.LINEAR;(this.scaleTypes[t]=i,i===h.TIME)&&cv(Sc.getProperty(e,"locale","time")||L_);return(r=i===h.TIME?function(){return If.apply(pv(Vp,zp,Np,Dp,jp,Pp,Rp,Cp,Jp).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}():i===h.LOG?function t(){var e=Mp(tp()).domain([1,10]);return e.copy=function(){return Qh(e,t()).base(e.base())},If.apply(e,arguments),e}().base(n.base||10):i===h.LABELS?qf():mp()).domain(this.getScaleDomain(t)),r},e}(vv),R_=Math.PI,P_=2*R_,j_=P_-1e-6;function D_(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function I_(){return new D_}function N_(t){return function(){return t}}D_.prototype=I_.prototype={constructor:D_,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+o)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var o=this._x1,a=this._y1,s=n-t,u=r-e,l=o-t,c=a-e,f=l*l+c*c;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(f>1e-6)if(Math.abs(c*s-u*l)>1e-6&&i){var h=n-o,p=r-a,d=s*s+u*u,v=h*h+p*p,g=Math.sqrt(d),y=Math.sqrt(f),_=i*Math.tan((R_-Math.acos((d+f-v)/(2*g*y)))/2),m=_/y,b=_/g;Math.abs(m-1)>1e-6&&(this._+="L"+(t+m*l)+","+(e+m*c)),this._+="A"+i+","+i+",0,0,"+ +(c*h>l*p)+","+(this._x1=t+b*s)+","+(this._y1=e+b*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,o=!!o;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=t+a,l=e+s,c=1^o,f=o?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(f<0&&(f=f%P_+P_),f>j_?this._+="A"+n+","+n+",0,1,"+c+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):f>1e-6&&(this._+="A"+n+","+n+",0,"+ +(f>=R_)+","+c+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var B_=Math.abs,F_=Math.atan2,z_=Math.cos,V_=Math.max,G_=Math.min,U_=Math.sin,H_=Math.sqrt,W_=Math.PI,q_=W_/2,Y_=2*W_;function X_(t){return t>1?0:t<-1?W_:Math.acos(t)}function $_(t){return t>=1?q_:t<=-1?-q_:Math.asin(t)}function Z_(t){return t.innerRadius}function K_(t){return t.outerRadius}function J_(t){return t.startAngle}function Q_(t){return t.endAngle}function tm(t){return t&&t.padAngle}function em(t,e,n,r,i,o,a,s){var u=n-t,l=r-e,c=a-i,f=s-o,h=f*u-c*l;if(!(h*h<1e-12))return[t+(h=(c*(e-o)-f*(t-i))/h)*u,e+h*l]}function nm(t,e,n,r,i,o,a){var s=t-n,u=e-r,l=(a?o:-o)/H_(s*s+u*u),c=l*u,f=-l*s,h=t+c,p=e+f,d=n+c,v=r+f,g=(h+d)/2,y=(p+v)/2,_=d-h,m=v-p,b=_*_+m*m,x=i-o,w=h*v-d*p,O=(m<0?-1:1)*H_(V_(0,x*x*b-w*w)),E=(w*m-_*O)/b,T=(-w*_-m*O)/b,S=(w*m+_*O)/b,M=(-w*_+m*O)/b,A=E-g,k=T-y,L=S-g,C=M-y;return A*A+k*k>L*L+C*C&&(E=S,T=M),{cx:E,cy:T,x01:-c,y01:-f,x11:E*(i/x-1),y11:T*(i/x-1)}}function rm(){var t=Z_,e=K_,n=N_(0),r=null,i=J_,o=Q_,a=tm,s=null;function u(){var u,l,c=+t.apply(this,arguments),f=+e.apply(this,arguments),h=i.apply(this,arguments)-q_,p=o.apply(this,arguments)-q_,d=B_(p-h),v=p>h;if(s||(s=u=I_()),f<c&&(l=f,f=c,c=l),f>1e-12)if(d>Y_-1e-12)s.moveTo(f*z_(h),f*U_(h)),s.arc(0,0,f,h,p,!v),c>1e-12&&(s.moveTo(c*z_(p),c*U_(p)),s.arc(0,0,c,p,h,v));else{var g,y,_=h,m=p,b=h,x=p,w=d,O=d,E=a.apply(this,arguments)/2,T=E>1e-12&&(r?+r.apply(this,arguments):H_(c*c+f*f)),S=G_(B_(f-c)/2,+n.apply(this,arguments)),M=S,A=S;if(T>1e-12){var k=$_(T/c*U_(E)),L=$_(T/f*U_(E));(w-=2*k)>1e-12?(b+=k*=v?1:-1,x-=k):(w=0,b=x=(h+p)/2),(O-=2*L)>1e-12?(_+=L*=v?1:-1,m-=L):(O=0,_=m=(h+p)/2)}var C=f*z_(_),R=f*U_(_),P=c*z_(x),j=c*U_(x);if(S>1e-12){var D,I=f*z_(m),N=f*U_(m),B=c*z_(b),F=c*U_(b);if(d<W_&&(D=em(C,R,B,F,I,N,P,j))){var z=C-D[0],V=R-D[1],G=I-D[0],U=N-D[1],H=1/U_(X_((z*G+V*U)/(H_(z*z+V*V)*H_(G*G+U*U)))/2),W=H_(D[0]*D[0]+D[1]*D[1]);M=G_(S,(c-W)/(H-1)),A=G_(S,(f-W)/(H+1))}}O>1e-12?A>1e-12?(g=nm(B,F,C,R,f,A,v),y=nm(I,N,P,j,f,A,v),s.moveTo(g.cx+g.x01,g.cy+g.y01),A<S?s.arc(g.cx,g.cy,A,F_(g.y01,g.x01),F_(y.y01,y.x01),!v):(s.arc(g.cx,g.cy,A,F_(g.y01,g.x01),F_(g.y11,g.x11),!v),s.arc(0,0,f,F_(g.cy+g.y11,g.cx+g.x11),F_(y.cy+y.y11,y.cx+y.x11),!v),s.arc(y.cx,y.cy,A,F_(y.y11,y.x11),F_(y.y01,y.x01),!v))):(s.moveTo(C,R),s.arc(0,0,f,_,m,!v)):s.moveTo(C,R),c>1e-12&&w>1e-12?M>1e-12?(g=nm(P,j,I,N,c,-M,v),y=nm(C,R,B,F,c,-M,v),s.lineTo(g.cx+g.x01,g.cy+g.y01),M<S?s.arc(g.cx,g.cy,M,F_(g.y01,g.x01),F_(y.y01,y.x01),!v):(s.arc(g.cx,g.cy,M,F_(g.y01,g.x01),F_(g.y11,g.x11),!v),s.arc(0,0,c,F_(g.cy+g.y11,g.cx+g.x11),F_(y.cy+y.y11,y.cx+y.x11),v),s.arc(y.cx,y.cy,M,F_(y.y11,y.x11),F_(y.y01,y.x01),!v))):s.arc(0,0,c,x,b,v):s.lineTo(P,j)}else s.moveTo(0,0);if(s.closePath(),u)return s=null,u+""||null}return u.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-W_/2;return[z_(r)*n,U_(r)*n]},u.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:N_(+e),u):t},u.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:N_(+t),u):e},u.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:N_(+t),u):n},u.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:N_(+t),u):r},u.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:N_(+t),u):i},u.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:N_(+t),u):o},u.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:N_(+t),u):a},u.context=function(t){return arguments.length?(s=null==t?null:t,u):s},u}function im(t){this._context=t}function om(t){return new im(t)}function am(t){return t[0]}function sm(t){return t[1]}function um(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function lm(t){return t}im.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var cm=Array.prototype.slice;function fm(){}function hm(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function pm(t){this._context=t}function dm(t){return new pm(t)}function vm(t){this._context=t}function gm(t){return new vm(t)}function ym(t){this._context=t}function _m(t){return new ym(t)}function mm(t,e){this._basis=new pm(t),this._beta=e}pm.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:hm(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:hm(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},vm.prototype={areaStart:fm,areaEnd:fm,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:hm(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},ym.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:hm(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},mm.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var bm=function t(e){function n(t){return 1===e?new pm(t):new mm(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function xm(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function wm(t,e){this._context=t,this._k=(1-e)/6}wm.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:xm(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:xm(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Om=function t(e){function n(t){return new wm(t,e)}return n.tension=function(e){return t(+e)},n}(0);function Em(t,e){this._context=t,this._k=(1-e)/6}Em.prototype={areaStart:fm,areaEnd:fm,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:xm(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Tm=function t(e){function n(t){return new Em(t,e)}return n.tension=function(e){return t(+e)},n}(0);function Sm(t,e){this._context=t,this._k=(1-e)/6}Sm.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(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:xm(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Mm=function t(e){function n(t){return new Sm(t,e)}return n.tension=function(e){return t(+e)},n}(0);function Am(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>1e-12){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>1e-12){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*l+t._x1*t._l23_2a-e*t._l12_2a)/c,a=(a*l+t._y1*t._l23_2a-n*t._l12_2a)/c}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function km(t,e){this._context=t,this._alpha=e}km.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._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:Am(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Lm=function t(e){function n(t){return e?new km(t,e):new wm(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Cm(t,e){this._context=t,this._alpha=e}Cm.prototype={areaStart:fm,areaEnd:fm,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:Am(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Rm=function t(e){function n(t){return e?new Cm(t,e):new Em(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Pm(t,e){this._context=t,this._alpha=e}Pm.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._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Am(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var jm=function t(e){function n(t){return e?new Pm(t,e):new Sm(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Dm(t){this._context=t}function Im(t){return new Dm(t)}function Nm(t){return t<0?-1:1}function Bm(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(Nm(o)+Nm(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function Fm(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function zm(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function Vm(t){this._context=t}function Gm(t){this._context=new Um(t)}function Um(t){this._context=t}function Hm(t){return new Vm(t)}function Wm(t){return new Gm(t)}function qm(t){this._context=t}function Ym(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}function Xm(t){return new qm(t)}function $m(t,e){this._context=t,this._t=e}function Zm(t){return new $m(t,.5)}function Km(t){return new $m(t,0)}function Jm(t){return new $m(t,1)}function Qm(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]}function tb(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function eb(t,e){return t[e]}Dm.prototype={areaStart:fm,areaEnd:fm,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}},Vm.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:zm(this,this._t0,Fm(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,zm(this,Fm(this,n=Bm(this,t,e)),n);break;default:zm(this,this._t0,n=Bm(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(Gm.prototype=Object.create(Vm.prototype)).point=function(t,e){Vm.prototype.point.call(this,e,t)},Um.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},qm.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=Ym(t),i=Ym(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}},$m.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&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var nb,rb,ib=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:om,curveLinearClosed:Im,curveBasis:dm,curveBasisClosed:gm,curveBasisOpen:_m,curveBundle:bm,curveCardinal:Om,curveCardinalClosed:Tm,curveCardinalOpen:Mm,curveCatmullRom:Lm,curveCatmullRomClosed:Rm,curveCatmullRomOpen:jm,curveMonotoneX:Hm,curveMonotoneY:Wm,curveNatural:Xm,curveStep:Zm,curveStepAfter:Jm,curveStepBefore:Km},e}return s(e,t),e.prototype.getD3Curve=function(){var t="curveLinear",e=this.model.getOptions().curve;if(e&&(t="string"==typeof e?e:e.name),this.curveTypes[t]){var n=this.curveTypes[t];return e&&Object.keys(e).forEach((function(t){n[t]&&(n=n[t](e[t]))})),n}return console.warn("The curve type '"+t+"' is invalid, using 'curveLinear' instead"),this.curveTypes.curveLinear},e}(vv),ob=function(){function t(t,e,n){this.configs={},this.model=t,this.services=e,n&&(this.configs=n),this.parent||this.setParent(Tg(this.services.domUtils.getMainSVG()))}return t.prototype.init=function(){},t.prototype.render=function(t){console.error("render() method is not implemented")},t.prototype.destroy=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t.prototype.setParent=function(t){var e=this.parent;if(this.parent=t,(!e||e.node()!==t.node())&&this.type){var n=Sc.getProperty(this.model.getOptions(),"style","prefix");this.parent.classed(Ag.prefix+"--"+n+"--"+this.type,!0),e&&e.classed(Ag.prefix+"--"+n+"--"+this.type,!1)}},t.prototype.getParent=function(){return this.parent},t.prototype.getContainerSVG=function(){if(this.type){var t=Sc.getProperty(this.model.getOptions(),"style","prefix");return Kg.appendOrSelect(this.parent,"g."+Ag.prefix+"--"+t+"--"+this.type)}return this.parent},t}(),ab=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e}return s(n,t),n.prototype.render=function(){var t=this,n=this.getContainerSVG().attr("role",e.GRAPHICS_DOCUMENT),r=this.model.getOptions(),i=n.selectAll("g.legend-item").data(this.getLegendItemArray()),o=i.enter().append("g").classed("legend-item",!0),a=r.legend.checkbox.radius;o.append("rect").classed("checkbox",!0).merge(i.select("rect.checkbox")).attr("width",2*a).attr("height",2*a).attr("rx",1).attr("ry",1).style("fill",(function(e){return e.value===r.legend.items.status.ACTIVE?t.model.getStrokeColor(e.key):null})).classed("active",(function(t,e){return t.value===r.legend.items.status.ACTIVE})),o.append("text").merge(i.select("text")).text((function(t){return t.key})).attr("alignment-baseline","middle"),this.breakItemsIntoLines(o),i.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove();var s=Sc.getProperty(this.model.getOptions(),"legend","clickable");n.classed("clickable",s),s&&o.size()>0&&this.addEventListeners()},n.prototype.breakItemsIntoLines=function(t){var e,n=this,r=this.getContainerSVG(),i=this.model.getOptions(),o=i.legend.checkbox.radius,a=i.legend.items.horizontalSpace,s=i.legend.items.verticalSpace,u=i.legend.items.textYOffset,l=2*o+i.legend.checkbox.spaceAfter,c=i.legend.items.status.DISABLED,f=this.model.get("dataLabels"),h=Object.keys(f).some((function(t){return f[t]===c})),p=Sc.getProperty(i,"legend","orientation"),d=0,v=0,y=0;t.merge(r.selectAll("g.legend-item")).each((function(t,i){var c=Tg(this),f=Tg(r.selectAll("g.legend-item").nodes()[i-1]);if(0===y||f.empty()||p===g.VERTICAL)p===g.VERTICAL&&0!==i&&v++;else{var _=Kg.getSVGElementSize(n.parent,{useAttr:!0}),m=Kg.getSVGElementSize(Tg(this).select("text"),{useBBox:!0}),b=Kg.getSVGElementSize(f.select("text"),{useBBox:!0});(d=d+b.width+l+a)+l+m.width>_.width&&(v++,d=0,y=0)}c.select("rect.checkbox").attr("x",d).attr("y",0+v*s);var x=u+v*s;c.select("text").attr("x",d+l).attr("y",0+x),e=x,h&&c.select("g.check").empty()?(c.append("g").classed("check",!0).html('\n\t\t\t\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet"\n\t\t\t\t\t\t\t\txmlns="http://www.w3.org/2000/svg" width="32" height="32"\n\t\t\t\t\t\t\t\tviewBox="0 0 32 32" aria-hidden="true"\n\t\t\t\t\t\t\t\tstyle="will-change: transform;">\n\t\t\t\t\t\t\t\t<path d="M13 21.2l-7.1-7.1-1.4 1.4 7.1 7.1L13 24 27.1 9.9l-1.4-1.5z"></path>\n\t\t\t\t\t\t\t\t<title>Checkmark</title>\n\t\t\t\t\t\t\t</svg>\n\t\t\t\t\t\t'),c.select("g.check svg").attr("width",2*o-1).attr("height",2*o-1).attr("x",parseFloat(c.select("rect.checkbox").attr("x"))+.5).attr("y",parseFloat(c.select("rect.checkbox").attr("y"))+.5)):h||c.select("g.check").empty()||c.select("g.check").remove(),y++})),Kg.appendOrSelect(r,"rect.spacer").attr("x",0).attr("y",e).attr("width",16).attr("height",16).attr("fill","none")},n.prototype.getLegendItemArray=function(){var t=this.model.get("dataLabels");return Object.keys(t).map((function(e){return{key:e,value:t[e]}}))},n.prototype.addEventListeners=function(){var t=this,e=this.getContainerSVG(),n=this.model.getOptions();e.selectAll("g.legend-item").on("mouseover",(function(){t.services.events.dispatchEvent("legend-item-onhover",{hoveredElement:Tg(this)});var e=n.legend.checkbox.radius,r=Tg(this);r.append("rect").classed("hover-stroke",!0).attr("x",parseFloat(r.select("rect.checkbox").attr("x"))-2).attr("y",parseFloat(r.select("rect.checkbox").attr("y"))-2).attr("width",2*e+4).attr("height",2*e+4).attr("rx",3).attr("ry",3).lower()})).on("click",(function(){t.services.events.dispatchEvent("legend-item-onclick",{clickedElement:Tg(this)});var e=Tg(this).datum();t.model.toggleDataLabel(e.key)})).on("mouseout",(function(){var e=Tg(this);e.select("rect.hover-stroke").remove(),t.services.events.dispatchEvent("legend-item-onmouseout",{hoveredElement:e})}))},n}(ob),sb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="title",e}return s(e,t),e.prototype.truncateTitle=function(){var t=Kg.getSVGElementSize(this.services.domUtils.getMainSVG(),{useAttr:!0}).width,e=Kg.appendOrSelect(this.parent,"text.title");if(!(t<=0)&&e.node().getComputedTextLength()>t){e.append("tspan").text("...");var n=Kg.appendOrSelect(e,"tspan").node().getComputedTextLength(),r=Math.floor(t-n),i=this.model.getOptions().title,o=this.getSubstringIndex(e.node(),0,i.length-1,r);e.text(i.substring(0,o-1)).append("tspan").text("...");var a=this;e.on("mouseenter",(function(){a.services.events.dispatchEvent("show-tooltip",{hoveredElement:e,type:d.TITLE})})).on("mouseout",(function(){a.services.events.dispatchEvent("hide-tooltip",{hoveredElement:e})}))}},e.prototype.render=function(){var t=this.getContainerSVG();Kg.appendOrSelect(t,"text.title").attr("x",0).attr("y",20).text(this.model.getOptions().title),this.truncateTitle()},e.prototype.getSubstringIndex=function(t,e,n,r){var i=Math.floor((n+e)/2);return t.getSubStringLength(0,i)>r?this.getSubstringIndex(t,e,i,r):t.getSubStringLength(0,i)<r?t.getSubStringLength(0,i+1)>r?i:this.getSubstringIndex(t,i,n,r):i},e}(ob);!function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(rb||(rb={}));var ub=((nb={})[rb.LEFT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left-e.offsetWidth)}},nb[rb.RIGHT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left+n.width)}},nb[rb.TOP]=function(t,e,n){return{top:Math.round(t.top-e.offsetHeight),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},nb[rb.BOTTOM]=function(t,e,n){return{top:Math.round(t.top+n.height),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},nb),lb="undefined"!=typeof window?window:{innerHeight:0,scrollY:0,innerWidth:0,scrollX:0},cb=function(){function t(t){void 0===t&&(t={}),this.positions=ub,this.positions=Object.assign({},ub,t)}return t.prototype.getRelativeOffset=function(t){for(var e={left:t.offsetLeft,top:t.offsetTop};t.offsetParent&&"static"===getComputedStyle(t.offsetParent).position;)e.left+=t.offsetLeft,e.top+=t.offsetTop,t=t.offsetParent;return e},t.prototype.getAbsoluteOffset=function(t){for(var e=t,n={top:0,left:0};e.offsetParent;){var r=getComputedStyle(e.offsetParent);"static"===r.position&&r.marginLeft&&r.marginTop&&(parseInt(r.marginTop,10)&&(n.top+=parseInt(r.marginTop,10)),parseInt(r.marginLeft,10)&&(n.left+=parseInt(r.marginLeft,10))),e=e.offsetParent}var i=t.getBoundingClientRect(),o=document.body.getBoundingClientRect();return{top:i.top-o.top+n.top,left:i.left-o.left+n.left}},t.prototype.findRelative=function(t,e,n){var r=this.getRelativeOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findAbsolute=function(t,e,n){var r=this.getAbsoluteOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findPosition=function(t,e,n,r){void 0===r&&(r=this.getAbsoluteOffset);var i=r(t),o=t.getBoundingClientRect();return this.calculatePosition(i,o,e,n)},t.prototype.findPositionAt=function(t,e,n){return this.calculatePosition(t,{height:0,width:0},e,n)},t.prototype.getPlacementBox=function(t,e){var n=t.offsetHeight+e.top,r=t.offsetWidth+e.left;return{top:e.top,bottom:n,left:e.left,right:r}},t.prototype.addOffset=function(t,e,n){return void 0===e&&(e=0),void 0===n&&(n=0),Object.assign({},t,{top:t.top+e,left:t.left+n})},t.prototype.setElement=function(t,e){t.style.top=e.top+"px",t.style.left=e.left+"px"},t.prototype.findBestPlacement=function(t,e,n,r,i){var o=this;void 0===r&&(r=this.defaultContainerFunction),void 0===i&&(i=this.findPosition);var a=n.map((function(n){var a=i(t,e,n),s=o.getPlacementBox(e,a),u=s.bottom-r().height,l=s.right-r().width;u=u<0?e.offsetHeight:u,l=l<0?e.offsetWidth:l;var c=e.offsetHeight*e.offsetWidth,f=c-u*l;return{placement:n,weight:(f=0===f?c:f)/c}}));return a.sort((function(t,e){return e.weight-t.weight})),a[0].placement},t.prototype.findBestPlacementAt=function(t,e,n,r){var i=this;void 0===r&&(r=this.defaultContainerFunction);return this.findBestPlacement(null,e,n,r,(function(e,n,r){return i.findPositionAt(t,n,r)}))},t.prototype.defaultContainerFunction=function(){return{width:lb.innerHeight-lb.scrollY,height:lb.innerWidth-lb.scrollX}},t.prototype.calculatePosition=function(t,e,n,r){return this.positions[r]?this.positions[r](t,n,e):(console.error("No function found for placement, defaulting to 0,0"),{left:0,top:0})},t}(),fb=(new cb,function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="tooltip",i.positionService=new cb,i.init(),i}return s(e,t),e.prototype.init=function(){var t=this,e=Tg(this.services.domUtils.getHolder()),n=Sc.getProperty(this.model.getOptions(),"style","prefix");this.tooltip=Kg.appendOrSelect(e,"div."+Ag.prefix+"--"+n+"--tooltip");var r=Kg.appendOrSelect(this.tooltip,"div.content-box");this.tooltip.style("max-width",null),this.services.events.addEventListener("show-tooltip",(function(i){if(i.detail.type===d.DATAPOINT&&Sc.getProperty(t.model.getOptions(),"tooltip","datapoint","enabled")||i.detail.type===d.GRIDLINE&&Sc.getProperty(t.model.getOptions(),"tooltip","gridline","enabled")){var o=Tg(pg.target).datum(),a=void 0;i.detail.multidata?(o=i.detail.multidata,a=t.getMultilineTooltipHTML(o)):a=t.getTooltipHTML(o,d.DATAPOINT),Sc.getProperty(t.model.getOptions(),"tooltip","customHTML")?r.html(t.model.getOptions().tooltip.customHTML(o,a)):r.html(a),t.positionTooltip()}else if(i.detail.type===d.TITLE){var s=Kg.appendOrSelect(e,"svg."+Ag.prefix+"--"+n+"--chart-svg"),u=Kg.getSVGElementSize(s).width*Sc.getProperty(t.model.getOptions(),"tooltip","title","width");t.tooltip.style("max-width",u),r.html(t.getTooltipHTML(i.detail.hoveredElement,d.TITLE));var l=t.getTooltipPosition(i.detail.hoveredElement.node());t.positionTooltip(l)}t.tooltip.classed("hidden",!1)})),this.services.events.addEventListener("hide-tooltip",(function(){t.tooltip.classed("hidden",!0)}))},e.prototype.getTooltipHTML=function(t,e){if(e===d.TITLE)return'<div class="title-tooltip"><text>'+this.model.getOptions().title+"</text></div>";var n=Sc.getProperty(t,"data")?t.data:t,r=Sc.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(n.value):n.value.toLocaleString("en");return'<div class="datapoint-tooltip">\n\t\t\t\t\t<p class="label">'+(n.datasetLabel?n.datasetLabel:n.label)+'</p>\n\t\t\t\t\t<p class="value">'+r+"</p>\n\t\t\t\t</div>"},e.prototype.getMultilineTooltipHTML=function(t){var e=this,n=t;n.sort((function(t,e){return e.value-t.value}));var r=this.services.cartesianScales.getDomainScale().scaleType;return"<ul class='multi-tooltip'>"+n.map((function(t){var n=t.value;n instanceof Object&&(n=r===h.TIME?t.value.date:t.value.value);var i=Sc.getProperty(e.model.getOptions(),"tooltip","valueFormatter")?e.model.getOptions().tooltip.valueFormatter(n):n.toLocaleString("en");return'\n\t\t\t\t<li>\n\t\t\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t\t\t<a style="background-color:'+e.model.getStrokeColor(t.datasetLabel,t.label)+'" class="tooltip-color"></a>\n\t\t\t\t\t\t<p class="label">'+t.datasetLabel+'</p>\n\t\t\t\t\t\t<p class="value">'+i+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"</ul>"},e.prototype.render=function(){this.tooltip.classed("hidden",!0)},e.prototype.getTooltipPosition=function(t){var e=Tg(this.services.domUtils.getHolder()).node().getBoundingClientRect(),n=t.getBoundingClientRect(),r=this.model.getOptions().tooltip.title.verticalOffset,i={left:n.left-e.left+n.width/2,top:n.top-e.top-r};return{placement:p.BOTTOM,position:i}},e.prototype.positionTooltip=function(t){var e,n=this.services.domUtils.getHolder(),r=this.tooltip.node(),i=Mg(n);if(t){var o=t.placement===p.TOP?rb.TOP:rb.BOTTOM;e=this.positionService.findPositionAt(t.position,r,o)}else{var a=this.positionService.findBestPlacementAt({left:i[0],top:i[1]},r,[rb.RIGHT,rb.LEFT,rb.TOP,rb.BOTTOM],(function(){return{width:n.offsetWidth,height:n.offsetHeight}})),s=this.model.getOptions().tooltip.datapoint.horizontalOffset;a===rb.LEFT&&(s*=-1),e=this.positionService.findPositionAt({left:i[0]+s,top:i[1]},r,a)}this.positionService.setElement(r,e)},e}(ob)),hb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return s(e,t),e.prototype.init=function(){var e=this,n=Tg(this.services.domUtils.getHolder()),r=Sc.getProperty(this.model.getOptions(),"style","prefix");this.tooltip=Kg.appendOrSelect(n,"div."+Ag.prefix+"--"+r+"--tooltip");var i=Kg.appendOrSelect(this.tooltip,"div.content-box");this.tooltip.style("max-width",null),this.services.events.addEventListener("show-tooltip",(function(o){if(o.detail.type===d.DATAPOINT&&Sc.getProperty(e.model.getOptions(),"tooltip","datapoint","enabled")||o.detail.type===d.GRIDLINE&&Sc.getProperty(e.model.getOptions(),"tooltip","gridline","enabled")){var a=o.detail.hoveredElement.datum(),s=o.detail.hoveredElement.node(),u=void 0;o.detail.multidata?(a=o.detail.multidata,u=e.getMultilineTooltipHTML(a)):u=e.getTooltipHTML(o.detail.hoveredElement.datum()),Sc.getProperty(e.model.getOptions(),"tooltip","customHTML")?i.html(e.model.getOptions().tooltip.customHTML(a,u)):i.html(u);var l=e.getTooltipPosition(s);e.positionTooltip(o.detail.multidata?void 0:l)}else if(o.detail.type===d.TITLE){var c=Kg.appendOrSelect(n,"svg."+Ag.prefix+"--"+r+"--chart-svg"),f=Kg.getSVGElementSize(c).width*Sc.getProperty(e.model.getOptions(),"tooltip","title","width");e.tooltip.style("max-width",f),i.html(t.prototype.getTooltipHTML.call(e,o.detail.hoveredElement,d.TITLE));l=t.prototype.getTooltipPosition.call(e,o.detail.hoveredElement.node());e.positionTooltip(l)}e.tooltip.classed("hidden",!1)})),this.services.events.addEventListener("hide-tooltip",(function(){e.tooltip.classed("hidden",!0)}))},e.prototype.getTooltipPosition=function(t){var e=Tg(t).datum(),n=Tg(this.services.domUtils.getHolder()).node().getBoundingClientRect(),r=t.getBoundingClientRect(),i=this.model.getOptions().tooltip.datapoint.verticalOffset;if(e.value<=0){var o={left:r.left-n.left+r.width/2,top:r.bottom-n.top+i};return{placement:p.BOTTOM,position:o}}o={left:r.left-n.left+r.width/2,top:r.top-n.top-i};return{placement:p.TOP,position:o}},e.prototype.getTooltipHTML=function(t){return'<div class="datapoint-tooltip"><p class="value">'+(Sc.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(t.value):t.value.toLocaleString("en"))+"</p></div>"},e.prototype.getMultilineTooltipHTML=function(t){var e=this,n=t;n.reverse(),this.services.cartesianScales.getOrientation()===c.VERTICAL&&n.reverse();var r=n.reduce((function(t,e){return t+e.value}),0);return r=Sc.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(r):r.toLocaleString("en"),"<ul class='multi-tooltip'>"+n.map((function(t){var n=Sc.getProperty(e.model.getOptions(),"tooltip","valueFormatter")?e.model.getOptions().tooltip.valueFormatter(t.value):t.value.toLocaleString("en");return'\n\t\t\t\t<li>\n\t\t\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t\t\t<a style="background-color:'+e.model.getStrokeColor(t.datasetLabel,t.label)+'" class="tooltip-color"></a>\n\t\t\t\t\t\t<p class="label">'+t.datasetLabel+'</p>\n\t\t\t\t\t\t<p class="value">'+n+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"<li>\n\t\t\t\t\t<div class='total-val'>\n\t\t\t\t\t\t<p class='label'>Total</p>\n\t\t\t\t\t\t<p class='value'>"+r+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>\n\t\t\t</ul>"},e}(fb),pb=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return s(e,t),e.prototype.getTooltipHTML=function(e,n){if(n===d.TITLE)return t.prototype.getTooltipHTML.call(this,e,n);var r=Sc.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(e.value):e.value.toLocaleString("en");return'\n\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t<a style="background-color:'+this.model.getStrokeColor(e.datasetLabel,e.label)+'" class="tooltip-color"></a>\n\t\t\t\t<p class="label">'+e.datasetLabel+'</p>\n\t\t\t\t<p class="value">'+r+"</p>\n\t\t\t</div>"},e}(fb),db=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return s(e,t),e.prototype.getBarWidth=function(){var t=this.model.getOptions(),e=this.services.cartesianScales.getMainXScale();return e.step?Math.min(t.bars.maxWidth,e.step()/2):Math.min(t.bars.maxWidth,5/e.ticks().length*t.bars.maxWidth)},e}(ob),vb=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="simple-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-simple-bar")).attr("opacity",(function(t){return t.label!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-simple-bar")).attr("opacity",1)},e}return s(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.render=function(t){var n=this,r=this.getContainerSVG().selectAll("g.bars").data(this.model.getDisplayData().datasets,(function(t){return t.label}));r.exit().attr("opacity",0).remove();var i=r.enter().append("g").classed("bars",!0).attr("role",e.GROUP).merge(r).selectAll("path.bar").data((function(t,e){return n.addLabelsToDataPoints(t,e)}),(function(t){return t.label}));i.exit().attr("opacity",0).remove(),i.enter().append("path").attr("opacity",0).merge(i).classed("bar",!0).attr("width",this.getBarWidth.bind(this)).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()(t.label)})).attr("d",(function(t,e){var r=n.getBarWidth(),i=n.services.cartesianScales.getDomainValue(t,e)-r/2,o=i+r,a=n.services.cartesianScales.getRangeValue(0),s=n.services.cartesianScales.getRangeValue(t,e);return Sc.generateSVGPathString({x0:i,x1:o,y0:a,y1:s},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getDisplayData().labels;return t.data.map((function(e,r){return{date:e.date,label:n[r],datasetLabel:t.label,value:isNaN(e)?e.value:e}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=Tg(this);n.classed("hovered",!0),n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",lh(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOVER,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:d.DATAPOINT})})).on("mousemove",(function(e){t.services.events.dispatchEvent(b.Bar.BAR_MOUSEMOVE,{element:Tg(this),datum:e})})).on("click",(function(e){t.services.events.dispatchEvent(b.Bar.BAR_CLICK,{element:Tg(this),datum:e})})).on("mouseout",(function(e){var n=Tg(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()(e.label)})),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(db),gb=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grouped-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return s(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getGroupWidth=function(){var t=this.model.getDisplayData().datasets;return t.length*this.getBarWidth()+5*(t.length-1)},n.prototype.setGroupScale=function(){var t=this.model.getDisplayData().datasets;this.groupScale=qf().domain(t.map((function(t){return t.label}))).rangeRound([0,this.getGroupWidth()])},n.prototype.getBarWidth=function(){var e=this.model.getDisplayData().datasets,n=this.services.cartesianScales.getDomainScale();return Math.min(n.step()/2/e.length,t.prototype.getBarWidth.call(this))},n.prototype.render=function(t){var n=this,r=this.model.getDisplayData();this.setGroupScale();var i=this.getContainerSVG().selectAll("g.bars").data(r.labels);i.exit().attr("opacity",0).remove();var o=i.enter().append("g").classed("bars",!0).attr("role",e.GROUP).attr("aria-labelledby",(function(t){return t})).merge(i).attr("transform",(function(t,e){var r=n.services.cartesianScales.getDomainValue(t,e)-n.getGroupWidth()/2+n.getBarWidth();return n.services.cartesianScales.getOrientation()===c.VERTICAL?"translate("+r+", 0)":"translate(0, "+r+")"})).selectAll("path.bar").data((function(t,e){return n.addLabelsToDataPoints(t,e)}));o.exit().attr("opacity",0).remove(),o.enter().append("path").attr("opacity",0).merge(o).classed("bar",!0).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("d",(function(t){var e=n.groupScale(t.datasetLabel),r=n.getBarWidth(),i=e-r/2,o=e+r/2,a=n.services.cartesianScales.getRangeValue(0),s=n.services.cartesianScales.getRangeValue(t.value);return Sc.generateSVGPathString({x0:i,x1:o,y0:a,y1:s},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){return this.model.getDisplayData().datasets.map((function(n){return{label:t,datasetLabel:n.label,value:n.data[e].value?n.data[e].value:n.data[e]}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=Tg(this);n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",lh(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOVER,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:d.DATAPOINT})})).on("mousemove",(function(e){t.services.events.dispatchEvent(b.Bar.BAR_MOUSEMOVE,{element:Tg(this),datum:e})})).on("click",(function(e){t.services.events.dispatchEvent(b.Bar.BAR_CLICK,{element:Tg(this),datum:e})})).on("mouseout",(function(e){var n=Tg(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()[e.datasetLabel](e.label)})),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(db),yb=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="stacked-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return s(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getStackData=function(){var t,e=this.model.getDisplayData(),n=this.services.cartesianScales.getDomainAxisPosition();if(this.services.cartesianScales.getScaleTypeByPosition(n)===h.TIME){var r=[];e.datasets.forEach((function(t){r=r.concat(t.data.map((function(t){return Number(t.date)})))})),t=(r=Sc.removeArrayDuplicates(r).sort()).map((function(t,n){var r={};return e.datasets.forEach((function(e){var n=e.data.find((function(e){return Number(e.date)===Number(t)}));r[e.label]=n?n.value:0})),r.label=t,r}))}else t=e.labels.map((function(t,n){var r={};return e.datasets.forEach((function(t){r[t.label]=isNaN(t.data[n])?t.data[n].value:t.data[n]})),r.label=t,r}));return t},n.prototype.render=function(t){var n=this,r=this.model.getOptions(),i=this.getContainerSVG(),o=this.model.getDisplayData(),a=this.getStackData(),s=o.datasets.map((function(t){return t.label})),u=i.selectAll("g.bars").data(function(){var t=N_([]),e=tb,n=Qm,r=eb;function i(i){var o,a,s=t.apply(this,arguments),u=i.length,l=s.length,c=new Array(l);for(o=0;o<l;++o){for(var f,h=s[o],p=c[o]=new Array(u),d=0;d<u;++d)p[d]=f=[0,+r(i[d],h,d,i)],f.data=i[d];p.key=h}for(o=0,a=e(c);o<l;++o)c[a[o]].index=o;return n(c,a),c}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:N_(cm.call(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:N_(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?tb:"function"==typeof t?t:N_(cm.call(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?Qm:t,i):n},i}().keys(s)(a),(function(t){return t.key}));u.exit().attr("opacity",0).remove(),u.enter().append("g").classed("bars",!0).attr("role",e.GROUP);var l=i.selectAll("g.bars").selectAll("path.bar").data((function(t){return function(t){return Object.keys(t).map((function(e){"object"==typeof t[e]&&(t[e].datasetLabel=t.key,t[e].label=t[e].data.label,t[e].value=t[e].data[t.key])})),t}(t)}),(function(t){return t.label}));l.exit().remove();var f=this.services.cartesianScales.getRangeScale();l.enter().append("path").merge(l).classed("bar",!0).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("height",(function(t,e){var i,o=t.datasetLabel,a=s.indexOf(o);return i=f.scaleType===h.LABELS?Math.abs(f.scale.range()[0]-n.services.cartesianScales.getRangeValue(t.label,e)):n.services.cartesianScales.getRangeValue(t[0])-n.services.cartesianScales.getRangeValue(t[1]),a>0&&i>=r.bars.dividerSize?i-r.bars.dividerSize:i})).attr("d",(function(t,e){var i=n.getBarWidth(),o=n.services.cartesianScales.getDomainValue(t,e)-i/2,a=o+i,s=n.services.cartesianScales.getRangeValue(t[0],e),u=n.services.cartesianScales.getRangeValue(t[1],e);return Math.abs(u-s)>0&&Math.abs(u-s)>r.bars.dividerSize&&(n.services.cartesianScales.getOrientation()===c.VERTICAL?u+=1:u-=1),Sc.generateSVGPathString({x0:o,x1:a,y0:s,y1:u},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=Tg(this);n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",lh(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOVER,{element:n,datum:e})})).on("mousemove",(function(e){var n=Tg(this),r=Tg(this).datum();n.classed("hovered",!0);var i=r.data,o=i.label;delete i.label;var a=Object.keys(i).map((function(t){return{datasetLabel:t,value:i[t],label:o}}));t.services.events.dispatchEvent(b.Bar.BAR_MOUSEMOVE,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{multidata:a,hoveredElement:n,type:d.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(b.Bar.BAR_CLICK,{element:Tg(this),datum:e})})).on("mouseout",(function(e){var n=Tg(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()[e.datasetLabel](e.label)})),t.services.events.dispatchEvent(b.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(db),_b=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("circle.dot").transition(e.services.transitions.getTransition("legend-hover-scatter")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.dot").transition(e.services.transitions.getTransition("legend-mouseout-scatter")).attr("opacity",1)},e}return s(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.render=function(t){var n=this,r=(this.model.getOptions(),this.getContainerSVG().selectAll("g.dots").data(this.model.getDisplayData().datasets,(function(t){return t.label})));r.exit().attr("opacity",0).remove();var i=r.enter().append("g").classed("dots",!0).attr("role",e.GROUP).merge(r).selectAll("circle.dot").data((function(t,e){return n.addLabelsToDataPoints(t,e)})),o=i.enter().append("circle").attr("opacity",0).merge(i);this.styleCircles(o,t),this.addEventListeners()},n.prototype.styleCircles=function(t,n){var r=this,i=this.model.getOptions(),o=i.points.filled;t.raise().classed("dot",!0).classed("filled",(function(t){return r.model.getIsFilled(t.datasetLabel,t.label,t,o)})).classed("unfilled",(function(t){return!r.model.getIsFilled(t.datasetLabel,t.label,t,o)})).attr("cx",(function(t,e){return r.services.cartesianScales.getDomainValue(t,e)})).transition(this.services.transitions.getTransition("scatter-update-enter",n)).attr("cy",(function(t,e){return r.services.cartesianScales.getRangeValue(t,e)})).attr("r",i.points.radius).attr("fill",(function(t){if(r.model.getIsFilled(t.datasetLabel,t.label,t,o))return r.model.getFillColor(t.datasetLabel,t.label,t)})).attr("fill-opacity",o?.2:1).attr("stroke",(function(t){return r.model.getStrokeColor(t.datasetLabel,t.label,t)})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","point").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getDisplayData().labels;return t.data.map((function(e,r){return{date:e.date,label:n[r],datasetLabel:t.label,class:e.class,value:isNaN(e)?e.value:e}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("circle").on("mouseover mousemove",(function(e){var n=Tg(this);n.classed("hovered",!0).style("fill",(function(e){return t.model.getFillColor(e.datasetLabel,e.label,e)}));var r="mouseover"===pg.type?b.Scatter.SCATTER_MOUSEOVER:b.Scatter.SCATTER_MOUSEMOVE;t.services.events.dispatchEvent(r,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:d.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(b.Scatter.SCATTER_CLICK,{element:Tg(this),datum:e})})).on("mouseout",(function(e){var n=Tg(this);n.classed("hovered",!1),t.configs.filled||n.style("fill",null),t.services.events.dispatchEvent(b.Scatter.SCATTER_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("circle").on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(ob),mb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bubble",e}return s(e,t),e.prototype.getRadiusScale=function(t){var e=t.data(),n=e.map((function(t){return t.radius})).filter((function(t){return t})),r=this.model.getOptions(),i=Kg.getSVGElementSize(this.services.domUtils.getMainSVG(),{useAttr:!0});return mp().domain(Af(n)).range(r.bubble.radiusRange(i,e))},e.prototype.styleCircles=function(t,e){var n=this,r=this.model.getOptions(),i=this.getRadiusScale(t);t.raise().classed("dot",!0).attr("cx",(function(t,e){return n.services.cartesianScales.getDomainValue(t,e)})).transition(this.services.transitions.getTransition("bubble-update-enter",e)).attr("cy",(function(t,e){return n.services.cartesianScales.getRangeValue(t,e)})).attr("r",(function(t){return i(t.radius)})).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("fill-opacity",r.bubble.fillOpacity).attr("stroke",(function(t){return n.model.getStrokeColor(t.datasetLabel,t.label,t.value)})).attr("opacity",1)},e.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getOptions(),r=this.model.getDisplayData().labels;return t.data.map((function(e,i){return{date:e.date,label:r[i],datasetLabel:t.label,value:isNaN(e)?e.value:e,radius:e.radius||n.points.radius}}))},e}(_b),bb=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e}return s(n,t),n.prototype.init=function(){var t=this;this.services.events.addEventListener("legend-item-onhover",(function(e){var n=e.detail.hoveredElement;t.parent.selectAll("g.lines").transition(t.services.transitions.getTransition("legend-hover-line")).attr("opacity",(function(t){return t.label!==n.datum().key?Zc.opacity.unselected:Zc.opacity.selected}))})),this.services.events.addEventListener("legend-item-onmouseout",(function(e){t.parent.selectAll("g.lines").transition(t.services.transitions.getTransition("legend-mouseout-line")).attr("opacity",Zc.opacity.selected)}))},n.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this.getContainerSVG();this.lineGenerator=function(){var t=am,e=sm,n=N_(!0),r=null,i=om,o=null;function a(a){var s,u,l,c=a.length,f=!1;for(null==r&&(o=i(l=I_())),s=0;s<=c;++s)!(s<c&&n(u=a[s],s,a))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+t(u,s,a),+e(u,s,a));if(l)return o=null,l+""||null}return a.x=function(e){return arguments.length?(t="function"==typeof e?e:N_(+e),a):t},a.y=function(t){return arguments.length?(e="function"==typeof t?t:N_(+t),a):e},a.defined=function(t){return arguments.length?(n="function"==typeof t?t:N_(!!t),a):n},a.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),a):i},a.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),a):r},a}().x((function(t,e){return n.services.cartesianScales.getDomainValue(t,e)})).y((function(t,e){return n.services.cartesianScales.getRangeValue(t,e)})).curve(this.services.curves.getD3Curve());var i=r.selectAll("g.lines").data(this.model.getDisplayData().datasets,(function(t){return t.label}));i.exit().attr("opacity",0).remove();var o=i.enter().append("g").classed("lines",!0),a=this;o.append("path").attr("opacity",0).merge(r.selectAll("g.lines path")).attr("stroke",(function(t){var e=Tg(this.parentNode).datum();return a.model.getStrokeColor(e.label)})).datum((function(t){var e=Tg(this.parentNode).datum();return this._datasetLabel=e.label,e.data})).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","line").attr("aria-label",(function(t){return t.map((function(t){return t.value||t})).join(",")})).transition(this.services.transitions.getTransition("line-update-enter",t)).attr("opacity",1).attr("class","line").attr("d",this.lineGenerator)},n}(ob);function xb(t,e){var n=this,r=jh(this._current,t);return function(t){return n._current=r(t),e(n._current)}}var wb=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="pie",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.slice").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.data.label!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.slice").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return s(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getDataList=function(){var t=this.model.getDisplayData();return t.datasets[0].data.map((function(e,n){return{label:t.labels[n],value:e.value?e.value:e}}))},n.prototype.getInnerRadius=function(){return this.model.getOptions().pie.innerRadius},n.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this,i=this.getContainerSVG(),o=this.model.getOptions(),a=this.getDataList(),s=this.computeRadius();this.arc=rm().innerRadius(this.getInnerRadius()).outerRadius(s),this.hoverArc=rm().innerRadius(this.getInnerRadius()).outerRadius(s+o.pie.hoverArc.outerRadiusOffset);var u=function(){var t=lm,e=um,n=null,r=N_(0),i=N_(Y_),o=N_(0);function a(a){var s,u,l,c,f,h=a.length,p=0,d=new Array(h),v=new Array(h),g=+r.apply(this,arguments),y=Math.min(Y_,Math.max(-Y_,i.apply(this,arguments)-g)),_=Math.min(Math.abs(y)/h,o.apply(this,arguments)),m=_*(y<0?-1:1);for(s=0;s<h;++s)(f=v[d[s]=s]=+t(a[s],s,a))>0&&(p+=f);for(null!=e?d.sort((function(t,n){return e(v[t],v[n])})):null!=n&&d.sort((function(t,e){return n(a[t],a[e])})),s=0,l=p?(y-h*m)/p:0;s<h;++s,g=c)u=d[s],c=g+((f=v[u])>0?f*l:0)+m,v[u]={data:a[u],index:s,value:f,startAngle:g,endAngle:c,padAngle:_};return v}return a.value=function(e){return arguments.length?(t="function"==typeof e?e:N_(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:N_(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:N_(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:N_(+t),a):o},a}().value((function(t){return t.value})).sort(null).padAngle(o.pie.padAngle)(a).sort((function(t,e){return t.index-e.index})),l=Kg.appendOrSelect(i,"g.slices").attr("role",e.GROUP).selectAll("path.slice").data(u,(function(t){return t.data.label}));l.exit().attr("opacity",0).remove(),l.enter().append("path").classed("slice",!0).attr("opacity",0).merge(l).attr("fill",(function(t){return n.model.getFillScale()(t.data.label)})).attr("d",this.arc).transition(this.services.transitions.getTransition("pie-slice-enter-update",t)).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","slice").attr("aria-label",(function(t){return t.value+", "+Sc.convertValueToPercentage(t.data.value,a)+"%"})).attrTween("d",(function(t){return xb.bind(this)(t,r.arc)}));var c=Kg.appendOrSelect(i,"g.labels").attr("role",e.GROUP).selectAll("text.pie-label").data(u,(function(t){return t.data.label}));c.exit().attr("opacity",0).remove();var f=c.enter().append("text").classed("pie-label",!0),h=[];f.merge(c).style("text-anchor","middle").text((function(t){return o.pie.labels.formatter?o.pie.labels.formatter(t):Sc.convertValueToPercentage(t.data.value,a)+"%"})).datum((function(t){var e=this.getComputedTextLength();t.textOffsetX=e/2,t.textOffsetY=parseFloat(getComputedStyle(this).fontSize)/2;var n=s+7,r=(t.endAngle-t.startAngle)/2+t.startAngle;return t.xPosition=(t.textOffsetX+n)*Math.sin(r),t.yPosition=(t.textOffsetY+n)*-Math.cos(r),t})).attr("transform",(function(t,e){var n=a.length,r=(t.endAngle-t.startAngle)*(180/Math.PI);if(e>=n-2&&r<o.pie.callout.minSliceDegree){var i=void 0,s=void 0;return t.index===n-1?(i=t.xPosition+o.pie.callout.offsetX+o.pie.callout.textMargin+t.textOffsetX,s=t.yPosition-o.pie.callout.offsetY,t.direction=m.RIGHT,h.push(t)):(i=t.xPosition-o.pie.callout.offsetX-t.textOffsetX-o.pie.callout.textMargin,s=t.yPosition-o.pie.callout.offsetY,t.direction=m.LEFT,h.push(t)),"translate("+i+", "+s+")"}return"translate("+t.xPosition+", "+t.yPosition+")"})),this.renderCallouts(h);var p=s+o.pie.xOffset,d=s+o.pie.yOffset;h.length>0&&(d+=o.pie.yOffsetCallout),i.attr("transform","translate("+p+", "+d+")"),this.addEventListeners()},n.prototype.renderCallouts=function(t){var n=Kg.appendOrSelect(this.getContainerSVG(),"g.callouts").attr("role",e.GROUP),r=this.model.getOptions(),i=n.selectAll("g.callout").data(t);i.exit().remove();var o=i.enter().append("g").classed("callout",!0).attr("role",e.GRAPHICS_SYMBOL+" "+e.GROUP).attr("aria-roledescription","label callout");o.merge(i).datum((function(t){var e=t.xPosition,n=t.yPosition;return t.direction===m.RIGHT?(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e+r.pie.callout.offsetX,y:n-r.pie.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x-r.pie.callout.horizontalLineLength):(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e-r.pie.callout.offsetX,y:n-r.pie.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x+r.pie.callout.horizontalLineLength),t})),o.append("line").classed("vertical-line",!0).merge(n.selectAll("line.vertical-line")).datum((function(t){return Tg(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.startPos.x})).attr("y1",(function(t){return t.startPos.y})).attr("x2",(function(t){return t.intersectPointX})).attr("y2",(function(t){return t.endPos.y})),o.append("line").classed("horizontal-line",!0).merge(i.selectAll("line.horizontal-line")).datum((function(t){return Tg(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.intersectPointX})).attr("y1",(function(t){return t.endPos.y})).attr("x2",(function(t){return t.endPos.x})).attr("y2",(function(t){return t.endPos.y}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.slice").on("mouseover",(function(e){t.services.events.dispatchEvent(b.Pie.SLICE_MOUSEOVER,{element:Tg(this),datum:e})})).on("mousemove",(function(e){var n=Tg(this);n.classed("hovered",!0).transition(t.services.transitions.getTransition("pie_slice_mouseover")).attr("d",t.hoverArc),t.services.events.dispatchEvent(b.Pie.SLICE_MOUSEMOVE,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:d.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(b.Pie.SLICE_CLICK,{element:Tg(this),datum:e})})).on("mouseout",(function(e){var n=Tg(this);n.classed("hovered",!1).transition(t.services.transitions.getTransition("pie_slice_mouseover")).attr("d",t.arc),t.services.events.dispatchEvent(b.Pie.SLICE_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.computeRadius=function(){var t=this.model.getOptions(),e=Kg.getSVGElementSize(this.parent,{useAttrs:!0}),n=e.width,r=e.height;return Math.min(n,r)/2+t.pie.radiusOffset},n}(ob),Ob=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="donut",e}return s(e,t),e.prototype.render=function(e){void 0===e&&(e=!0),t.prototype.render.call(this,e);var n=this,r=Kg.appendOrSelect(this.getContainerSVG(),"g.center"),i=this.model.getOptions(),o=this.computeRadius();Kg.appendOrSelect(r,"text.donut-figure").attr("text-anchor","middle").style("font-size",(function(){return i.donut.center.numberFontSize(o)})).transition(this.services.transitions.getTransition("donut-figure-enter-update",e)).tween("text",(function(){return n.centerNumberTween(Tg(this))})),Kg.appendOrSelect(r,"text.donut-title").attr("text-anchor","middle").style("font-size",(function(){return i.donut.center.titleFontSize(o)})).attr("y",i.donut.center.titleYPosition(o)).text(Sc.getProperty(i,"donut","center","label"))},e.prototype.getInnerRadius=function(){return.75*this.computeRadius()},e.prototype.centerNumberTween=function(t){var e=this.model.getOptions(),n=Sc.getProperty(e,"donut","center","number");n||(n=this.getDataList().reduce((function(t,e){return t+e.value}),0));var r=kh(parseInt(t.text().replace(/[, ]+/g,""),10)||0,n);return function(n){var i=e.donut.center.numberFormatter;t.text(i(r(n)))}},e}(wb),Eb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="spacer",e}return s(e,t),e.prototype.render=function(){this.getContainerSVG().append("rect").attr("x",0).attr("y",0).attr("width",this.configs.size||Qc.default.size).attr("height",this.configs.size||Qc.default.size).attr("opacity",0)},e}(ob);function Tb(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function Sb(t,e){var n,r,i,o,a,s=new Lb(t),u=+t.value&&(s.value=t.value),l=[s];for(null==e&&(e=Mb);n=l.pop();)if(u&&(n.value=+n.data.value),(i=e(n.data))&&(a=i.length))for(n.children=new Array(a),o=a-1;o>=0;--o)l.push(r=n.children[o]=new Lb(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(kb)}function Mb(t){return t.children}function Ab(t){t.data=t.data.data}function kb(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function Lb(t){this.data=t,this.depth=this.height=0,this.parent=null}function Cb(t){if("function"!=typeof t)throw new Error;return t}function Rb(){return 0}function Pb(t){return function(){return t}}function jb(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function Db(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(r-e)/t.value;++s<u;)(o=a[s]).y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*l}function Ib(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,l=t.value&&(i-n)/t.value;++s<u;)(o=a[s]).x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*l}Lb.prototype=Sb.prototype={constructor:Lb,count:function(){return this.eachAfter(Tb)},each:function(t){var e,n,r,i,o=this,a=[o];do{for(e=a.reverse(),a=[];o=e.pop();)if(t(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r])}while(a.length);return this},eachAfter:function(t){for(var e,n,r,i=this,o=[i],a=[];i=o.pop();)if(a.push(i),e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n]);for(;i=a.pop();)t(i);return this},eachBefore:function(t){for(var e,n,r=this,i=[r];r=i.pop();)if(t(r),e=r.children)for(n=e.length-1;n>=0;--n)i.push(e[n]);return this},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();for(;t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){var t=[];return this.each((function(e){t.push(e)})),t},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return Sb(this).eachBefore(Ab)}};var Nb=function t(e){function n(t,n,r,i,o){!function(t,e,n,r,i,o){for(var a,s,u,l,c,f,h,p,d,v,g,y=[],_=e.children,m=0,b=0,x=_.length,w=e.value;m<x;){u=i-n,l=o-r;do{c=_[b++].value}while(!c&&b<x);for(f=h=c,g=c*c*(v=Math.max(l/u,u/l)/(w*t)),d=Math.max(h/g,g/f);b<x;++b){if(c+=s=_[b].value,s<f&&(f=s),s>h&&(h=s),g=c*c*v,(p=Math.max(h/g,g/f))>d){c-=s;break}d=p}y.push(a={value:c,dice:u<l,children:_.slice(m,b)}),a.dice?Db(a,n,r,i,w?r+=l*c/w:o):Ib(a,n,r,w?n+=u*c/w:i,o),w-=c,m=b}}(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}((1+Math.sqrt(5))/2);function Bb(){var t=Nb,e=!1,n=1,r=1,i=[0],o=Rb,a=Rb,s=Rb,u=Rb,l=Rb;function c(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(f),i=[0],e&&t.eachBefore(jb),t}function f(e){var n=i[e.depth],r=e.x0+n,c=e.y0+n,f=e.x1-n,h=e.y1-n;f<r&&(r=f=(r+f)/2),h<c&&(c=h=(c+h)/2),e.x0=r,e.y0=c,e.x1=f,e.y1=h,e.children&&(n=i[e.depth+1]=o(e)/2,r+=l(e)-n,c+=a(e)-n,(f-=s(e)-n)<r&&(r=f=(r+f)/2),(h-=u(e)-n)<c&&(c=h=(c+h)/2),t(e,r,c,f,h))}return c.round=function(t){return arguments.length?(e=!!t,c):e},c.size=function(t){return arguments.length?(n=+t[0],r=+t[1],c):[n,r]},c.tile=function(e){return arguments.length?(t=Cb(e),c):t},c.padding=function(t){return arguments.length?c.paddingInner(t).paddingOuter(t):c.paddingInner()},c.paddingInner=function(t){return arguments.length?(o="function"==typeof t?t:Pb(+t),c):o},c.paddingOuter=function(t){return arguments.length?c.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):c.paddingTop()},c.paddingTop=function(t){return arguments.length?(a="function"==typeof t?t:Pb(+t),c):a},c.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:Pb(+t),c):s},c.paddingBottom=function(t){return arguments.length?(u="function"==typeof t?t:Pb(+t),c):u},c.paddingLeft=function(t){return arguments.length?(l="function"==typeof t?t:Pb(+t),c):l},c}var Fb=function(t){function e(n,r,i,o){var a=t.call(this,n,r,o)||this;return a.type="layout",a.configs=o,a.children=i,a._instanceID=e.instanceID++,(a.configs.direction===y.ROW_REVERSE||a.configs.direction===y.COLUMN_REVERSE)&&(a.children=a.children.reverse()),a.init(),a}return s(e,t),e.prototype.init=function(){this.children.forEach((function(t){t.components.forEach((function(t){t.init()}))}))},e.prototype.getPreferedAndFixedSizeSum=function(){var t=this.parent,e=0;return t.selectAll("svg.layout-child-"+this._instanceID).filter((function(t){var e=Sc.getProperty(t,"data","growth","x");return e===_.PREFERRED||e===_.FIXED})).each((function(t){e+=t.data.size})),e},e.prototype.getNumOfStretchChildren=function(){return this.parent.selectAll("svg.layout-child-"+this._instanceID).filter((function(t){return Sc.getProperty(t,"data","growth","x")===_.STRETCH})).size()},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.parent,r=Kg.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height,a=Sb({children:this.children}).sum((function(t){return t.size})),s=this.configs.direction===y.ROW||this.configs.direction===y.ROW_REVERSE?Db:Ib;Bb().tile(s).size([i,o])(a);var u=this.configs.direction===y.ROW||this.configs.direction===y.ROW_REVERSE,l=n.selectAll("svg.layout-child-"+this._instanceID).data(a.leaves(),(function(t){return t.data.id}));l.attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})),l.enter().append("svg").attr("class",(function(t){return"layout-child layout-child-"+e._instanceID+" "+t.data.id})).attr("x",(function(t){return t.x0})).attr("y",(function(t){return t.y0})).merge(n.selectAll("svg.layout-child-"+this._instanceID)).each((function(e){var n=this;e.data.components.forEach((function(r){r.setParent(Tg(n));var i=Sc.getProperty(e,"data","growth","x");i!==_.PREFERRED&&i!==_.FIXED||r.render(t)}))})),n.selectAll("svg.layout-child-"+this._instanceID).each((function(t){var e=Sc.getProperty(t,"data","growth","x"),n=Kg.getSVGElementSize(Tg(this),{useBBox:!0});if(e===_.PREFERRED){var r=u?n.width:n.height,a=u?i:o;t.data.size=r/a*100}})),l.exit().remove(),this.children.filter((function(t){return Sc.getProperty(t,"growth","x")===_.STRETCH})).forEach((function(t,n){t.size=(100-+e.getPreferedAndFixedSizeSum())/+e.getNumOfStretchChildren()})),a=Sb({children:this.children}).sum((function(t){return t.size})),Bb().tile(s).size([i,o]).padding(0)(a),n.selectAll("svg.layout-child-"+this._instanceID).data(a.leaves(),(function(t){return t.data.id})).attr("x",(function(t){return t.x0})).attr("y",(function(t){return t.y0})).attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})).each((function(e,n){e.data.components.forEach((function(n){Sc.getProperty(e,"data","growth","x")===_.STRETCH&&n.render(t)}))}))},e.prototype.setModel=function(e){t.prototype.setModel.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setModel(e)}))}))},e.prototype.setServices=function(e){t.prototype.setServices.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setServices(e)}))}))},e.prototype.destroy=function(){this.children.forEach((function(t){t.components.forEach((function(t){return t.destroy()}))}))},e.instanceID=Math.floor(99999999999*Math.random()),e}(ob),zb=Array.prototype.slice;function Vb(t){return t}function Gb(t){return"translate("+(t+.5)+",0)"}function Ub(t){return"translate(0,"+(t+.5)+")"}function Hb(t){return function(e){return+t(e)}}function Wb(t){var e=Math.max(0,t.bandwidth()-1)/2;return t.round()&&(e=Math.round(e)),function(n){return+t(n)+e}}function qb(){return!this.__axis}function Yb(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u=1===t||4===t?-1:1,l=4===t||2===t?"x":"y",c=1===t||3===t?Gb:Ub;function f(f){var h=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,p=null==i?e.tickFormat?e.tickFormat.apply(e,n):Vb:i,d=Math.max(o,0)+s,v=e.range(),g=+v[0]+.5,y=+v[v.length-1]+.5,_=(e.bandwidth?Wb:Hb)(e.copy()),m=f.selection?f.selection():f,b=m.selectAll(".domain").data([null]),x=m.selectAll(".tick").data(h,e).order(),w=x.exit(),O=x.enter().append("g").attr("class","tick"),E=x.select("line"),T=x.select("text");b=b.merge(b.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),x=x.merge(O),E=E.merge(O.append("line").attr("stroke","currentColor").attr(l+"2",u*o)),T=T.merge(O.append("text").attr("fill","currentColor").attr(l,u*d).attr("dy",1===t?"0em":3===t?"0.71em":"0.32em")),f!==m&&(b=b.transition(f),x=x.transition(f),E=E.transition(f),T=T.transition(f),w=w.transition(f).attr("opacity",1e-6).attr("transform",(function(t){return isFinite(t=_(t))?c(t):this.getAttribute("transform")})),O.attr("opacity",1e-6).attr("transform",(function(t){var e=this.parentNode.__axis;return c(e&&isFinite(e=e(t))?e:_(t))}))),w.remove(),b.attr("d",4===t||2==t?a?"M"+u*a+","+g+"H0.5V"+y+"H"+u*a:"M0.5,"+g+"V"+y:a?"M"+g+","+u*a+"V0.5H"+y+"V"+u*a:"M"+g+",0.5H"+y),x.attr("opacity",1).attr("transform",(function(t){return c(_(t))})),E.attr(l+"2",u*o),T.attr(l,u*d).text(p),m.filter(qb).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",2===t?"start":4===t?"end":"middle"),m.each((function(){this.__axis=_}))}return f.scale=function(t){return arguments.length?(e=t,f):e},f.ticks=function(){return n=zb.call(arguments),f},f.tickArguments=function(t){return arguments.length?(n=null==t?[]:zb.call(t),f):n.slice()},f.tickValues=function(t){return arguments.length?(r=null==t?null:zb.call(t),f):r&&r.slice()},f.tickFormat=function(t){return arguments.length?(i=t,f):i},f.tickSize=function(t){return arguments.length?(o=a=+t,f):o},f.tickSizeInner=function(t){return arguments.length?(o=+t,f):o},f.tickSizeOuter=function(t){return arguments.length?(a=+t,f):a},f.tickPadding=function(t){return arguments.length?(s=+t,f):s},f}function Xb(t){return Yb(1,t)}function $b(t){return Yb(2,t)}function Zb(t){return Yb(3,t)}function Kb(t){return Yb(4,t)}var Jb=function(t){function n(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="axes",r&&(i.configs=r),i.margins=i.configs.margins,i}return s(n,t),n.prototype.render=function(t){void 0===t&&(t=!0);var n,r,i=this.configs.position,o=this.model.getOptions(),a=Sc.getProperty(o,"axes",i),s=this.getContainerSVG(),u=Kg.getSVGElementSize(this.parent,{useAttrs:!0}),c=u.width,f=u.height;i===l.BOTTOM||i===l.TOP?(n=this.configs.axes[l.LEFT]?this.margins.left:0,r=this.configs.axes[l.RIGHT]?c-this.margins.right:c):(n=f-this.margins.bottom,r=this.margins.top);var p,d=this.services.cartesianScales.getScaleByPosition(i);switch(this.scaleType===h.LABELS?d.rangeRound([n,r]):d.range([n,r]),i){case l.LEFT:p=Kb;break;case l.BOTTOM:p=Zb;break;case l.RIGHT:p=$b;break;case l.TOP:p=Xb}var v=p(d).tickSizeOuter(0).tickFormat(Sc.getProperty(a,"ticks","formatter"));if(d.ticks){var g=Sc.getProperty(a,"ticks","number")||Jc.ticks.number;if(v.ticks(g),this.scaleType===h.TIME){var y=d.ticks(g).concat(d.domain()).map((function(t){return+t})).sort();y=Sc.removeArrayDuplicates(y),Sc.getProperty(o,"timeScale","addSpaceOnEdges")&&y.length>2&&(y.splice(y.length-1,1),y.splice(0,1)),v.tickValues(y)}}var _=Kg.appendOrSelect(s,"g.axis."+i),m=!_.select("g.ticks").empty(),b=Kg.appendOrSelect(_,"g.ticks");m||b.attr("role",e.GRAPHICS_OBJECT+" "+e.GROUP);var x=Kg.appendOrSelect(_,"g.ticks.invisible").style("opacity","0").attr("aria-hidden",!0);switch(i){case l.LEFT:b.attr("transform","translate("+this.margins.left+", 0)");break;case l.BOTTOM:b.attr("transform","translate(0, "+(f-this.margins.bottom)+")");break;case l.RIGHT:b.attr("transform","translate("+(c-this.margins.right)+", 0)");break;case l.TOP:b.attr("transform","translate(0, "+this.margins.top+")")}if(a.title){var w=Kg.appendOrSelect(_,"text.axis-title").text(a.title);switch(i){case l.LEFT:w.attr("transform","rotate(-90)").attr("y",0).attr("x",-d.range()[0]/2).attr("dy","1em").style("text-anchor","middle");break;case l.BOTTOM:w.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+f+")").style("text-anchor","middle");break;case l.RIGHT:w.attr("transform","rotate(90)").attr("y",-c).attr("x",d.range()[0]/2).attr("dy","1em").style("text-anchor","middle");break;case l.TOP:var O=Kg.getSVGElementSize(w,{useBBox:!0}).height;w.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+O/2+")").style("text-anchor","middle")}}if(b=t&&m?b.transition(this.services.transitions.getTransition("axis-update")).call(v):b.call(v),x.call(v),i===l.BOTTOM||i===l.TOP){var E=!1;if(d.step){E=x.selectAll("g.tick text").nodes().some((function(t){return Kg.getSVGElementSize(t,{useBBox:!0}).width>=d.step()}))}else{var T=Sc.getProperty(a,"ticks","rotateIfSmallerThan")||Jc.ticks.rotateIfSmallerThan;E=c/d.ticks().length/2<T}E?_.selectAll("g.ticks g.tick text").attr("transform","rotate(45)").style("text-anchor",i===l.TOP?"end":"start"):_.selectAll("g.ticks g.tick text").attr("transform",null).style("text-anchor",null)}},n.prototype.getInvisibleAxisRef=function(){var t=this.configs.position;return this.getContainerSVG().select("g.axis."+t+" g.ticks.invisible")},n.prototype.getTitleRef=function(){var t=this.configs.position;return this.getContainerSVG().select("g.axis."+t+" text.axis-title")},n}(ob),Qb=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="2D-axes",e.children={},e.margins={top:0,right:0,bottom:0,left:0},e}return s(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n={},r=Object.keys(l),i=Sc.getProperty(this.model.getOptions(),"axes");i?r.forEach((function(t){var e=i[l[t]];e&&(n[l[t]]=!0,!0===e.primary||e.secondary)})):(this.model.getOptions().axes={left:{primary:!0},bottom:{secondary:!0,type:this.model.getDisplayData().labels?h.LABELS:void 0}},n[l.LEFT]=!0,n[l.BOTTOM]=!0),this.configs.axes=n,r.forEach((function(t){var n=l[t];if(e.configs.axes[n]&&!e.children[n]){var r=new Jb(e.model,e.services,{position:n,axes:e.configs.axes,margins:e.margins});r.setModel(e.model),r.setServices(e.services),r.setParent(e.parent),e.children[n]=r}})),Object.keys(this.children).forEach((function(n){e.children[n].render(t)}));var o={};Object.keys(this.children).forEach((function(t){var n,r=e.children[t],i=r.configs.position,a=r.getInvisibleAxisRef(),s=Kg.getSVGElementSize(a,{useBBox:!0}),u=s.width,c=s.height;switch(n=r.getTitleRef().empty()?0:Kg.getSVGElementSize(r.getTitleRef(),{useBBox:!0}).height,i){case l.TOP:o.top=c+n;break;case l.BOTTOM:o.bottom=c+n;break;case l.LEFT:o.left=u+n;break;case l.RIGHT:o.right=u+n}})),Object.keys(o).some((function(t){return e.margins[t]!==o[t]}))&&(this.margins=Object.assign(this.margins,o),Object.keys(this.children).forEach((function(t){e.children[t].margins=e.margins})),this.render(!0))},e}(ob),tx=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid",e}return s(e,t),e.prototype.render=function(){this.drawBackdrop(),Kg.appendOrSelect(this.backdrop,"g.x.grid"),Kg.appendOrSelect(this.backdrop,"g.y.grid"),this.drawXGrid(),this.drawYGrid(),Sc.getProperty(this.model.getOptions(),"tooltip","gridline","enabled")&&this.addGridEventListeners()},e.prototype.drawXGrid=function(){var t=this.parent,e=this.backdrop.attr("height"),n=Zb(this.services.cartesianScales.getMainXScale()).tickSizeInner(-e).tickSizeOuter(0),r=Sc.getProperty(this.model.getOptions(),"grid","x","numberOfTicks");n.ticks(r);var i=t.select(".x.grid").attr("transform","translate("+-this.backdrop.attr("x")+", "+e+")").call(n);this.cleanGrid(i)},e.prototype.drawYGrid=function(){var t=this.parent,e=this.backdrop.attr("width"),n=Kb(this.services.cartesianScales.getMainYScale()).tickSizeInner(-e).tickSizeOuter(0),r=Sc.getProperty(this.model.getOptions(),"grid","y","numberOfTicks");n.ticks(r);var i=t.select(".y.grid").attr("transform","translate(0, "+-this.backdrop.attr("y")+")").call(n);this.cleanGrid(i)},e.prototype.getGridlineThreshold=function(t){var e,n=this.parent,r=n.selectAll(".x.grid .tick").nodes().sort((function(t,e){return Number(Sc.getTranslationValues(t).tx)-Number(Sc.getTranslationValues(e).tx)})),i=-1;r.forEach((function(e,n){t[0]>=+Sc.getTranslationValues(e).tx&&i++})),e=i+1<r.length?i+1:r.length;var o,a=r[i],s=r[e];if(a)if(s)o=+Sc.getTranslationValues(s).tx-+Sc.getTranslationValues(a).tx;else{var u=n.select("rect.chart-grid-backdrop").node();o=Kg.getSVGElementSize(u).width-+Sc.getTranslationValues(a).tx}else o=+Sc.getTranslationValues(s).tx;return o*this.model.getOptions().tooltip.gridline.threshold},e.prototype.getActiveGridline=function(t){var e=Sc.getProperty(this.model.getOptions,"tooltip","gridline","threshold")?Sc.getProperty(this.model.getOptions,"tooltip","gridline","threshold"):this.getGridlineThreshold(t);return this.parent.selectAll(".x.grid .tick").filter((function(){var n=Sc.getTranslationValues(this),r=Number(n.tx)-e,i=Number(n.tx)+e;return r<=t[0]&&t[0]<=i}))},e.prototype.addGridEventListeners=function(){var t=this,e=this.parent;Kg.appendOrSelect(e,"rect.chart-grid-backdrop").on("mousemove mouseover",(function(){var n=Mg(t.services.domUtils.getMainSVG()),r=Tg(this);e.selectAll(".x.grid .tick").classed("active",!1);var i,o=t.getActiveGridline(n);o.empty()?t.services.events.dispatchEvent("hide-tooltip",{}):(o.classed("active",!0),o.each((function(e){i=t.services.cartesianScales.getDataFromDomain(e)})),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:r,multidata:i,type:d.GRIDLINE}))})).on("mouseout",(function(){e.selectAll(".x.grid .tick").classed("active",!1),t.services.events.dispatchEvent("hide-tooltip",{})}))},e.prototype.drawBackdrop=function(){var t=this.parent,e=this.services.cartesianScales.getMainXScale(),n=this.services.cartesianScales.getMainYScale(),r=e.range(),i=r[0],o=r[1],a=n.range(),s=a[0],u=a[1];this.backdrop=Kg.appendOrSelect(t,"svg.chart-grid-backdrop");var l=Kg.appendOrSelect(this.backdrop,"rect.chart-grid-backdrop");this.backdrop.merge(l).attr("x",i).attr("y",u).attr("width",o-i).attr("height",s-u).lower(),l.attr("width","100%").attr("height","100%")},e.prototype.cleanGrid=function(t){var e=this.model.getOptions();t.selectAll("line").attr("stroke",e.grid.strokeColor),t.selectAll("text").remove(),t.select(".domain").remove()},e}(ob),ex=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zero-line",e}return s(e,t),e.prototype.render=function(t){var e=this.getContainerSVG(),n=this.services.cartesianScales.getDomainScale().range(),r=n[0],i=n[1],o=+this.services.cartesianScales.getRangeValue(0)+.5,a=Sc.flipSVGCoordinatesBasedOnOrientation({x0:r,x1:i,y0:o,y1:o},this.services.cartesianScales.getOrientation());Kg.appendOrSelect(e,"line.domain").transition(this.services.transitions.getTransition("zero-line-update",t)).attr("y1",a.y0).attr("y2",a.y1).attr("x1",a.x0).attr("x2",a.x1)},e}(ob),nx=function(){function t(t,e){this.services={domUtils:Kg,events:Jg,transitions:u_},this.model=new dv(this.services)}return t.prototype.init=function(t,e){var n=this;this.model.set({holder:t},!0),Object.keys(this.services).forEach((function(t){var e=n.services[t];n.services[t]=new e(n.model,n.services)})),this.services.events.addEventListener("model-update",(function(){n.update(!0)})),this.model.setData(e.data),this.services.events.addEventListener("chart-resize",(function(){n.update(!1)})),this.components=this.getComponents(),this.update()},t.prototype.getComponents=function(){return console.error("getComponents() method is not implemented"),null},t.prototype.update=function(t){var e=this;if(void 0===t&&(t=!0),this.components){Object.keys(this.services).forEach((function(t){e.services[t].update()})),this.components.forEach((function(e){return e.render(t)}));var n=this.services.transitions.getPendingTransitions(),r=Object.keys(n).map((function(t){return n[t].end().catch((function(t){return t}))}));Promise.all(r).then((function(){return e.services.events.dispatchEvent("render-finished")}))}},t.prototype.destroy=function(){this.components.forEach((function(t){return t.destroy()})),this.services.domUtils.getHolder().remove(),this.model.set({destroyed:!0},!0)},t.prototype.getChartComponents=function(t){var e={id:"title",components:[new sb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},n={id:"legend",components:[new ab(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},r={id:"graph-frame",components:t,growth:{x:_.STRETCH,y:_.FIXED}},i=!1!==this.model.getOptions().legend.enabled,o=y.COLUMN;if(i){var a=Sc.getProperty(this.model.getOptions(),"legend","position");"left"===a?(o=y.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=g.VERTICAL)):"right"===a?(o=y.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=g.VERTICAL)):"bottom"===a&&(o=y.COLUMN_REVERSE)}var s={id:"spacer",components:[new Eb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},u={id:"full-frame",components:[new Fb(this.model,this.services,(i?[n]:[]).concat([s,r]),{direction:o})],growth:{x:_.STRETCH,y:_.FIXED}},l=[];if(this.model.getOptions().title){l.push(e);var c={id:"spacer",components:[new Eb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}};l.push(c)}return l.push(u),[new Fb(this.model,this.services,l,{direction:y.COLUMN})]},t}(),rx=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.services=Object.assign(r.services,{cartesianScales:C_,curves:ib}),r}return s(e,t),e.prototype.getAxisChartComponents=function(t){var e={id:"title",components:[new sb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},n={id:"legend",components:[new ab(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},r={id:"graph-frame",components:t,growth:{x:_.STRETCH,y:_.FIXED}},i=!1!==this.model.getOptions().legend.enabled,o=y.COLUMN;if(i){var a=Sc.getProperty(this.model.getOptions(),"legend","position");a===v.LEFT?(o=y.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=g.VERTICAL)):a===v.RIGHT?(o=y.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=g.VERTICAL)):a===v.BOTTOM&&(o=y.COLUMN_REVERSE)}var s={id:"spacer",components:[new Eb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}},u={id:"full-frame",components:[new Fb(this.model,this.services,(i?[n]:[]).concat([s,r]),{direction:o})],growth:{x:_.STRETCH,y:_.FIXED}},l=[];if(this.model.getOptions().title){l.push(e);var c={id:"spacer",components:[new Eb(this.model,this.services)],growth:{x:_.PREFERRED,y:_.FIXED}};l.push(c)}return l.push(u),[new Fb(this.model,this.services,l,{direction:y.COLUMN})]},e}(nx),ix=function(t){function e(e){return t.call(this,e)||this}return s(e,t),e.prototype.generateDataLabels=function(t){var e={};return t.labels.forEach((function(t){e[t]=Pc.items.status.ACTIVE})),e},e.prototype.getDisplayData=function(){var t=Pc.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=Sc.clone(this.get("data")),r=n.datasets[0];return r.data=r.data.filter((function(r,i){var o=n.labels[i];return e[o]===t})),n.labels=n.labels.filter((function(n){return e[n]===t})),n},e.prototype.setColorScale=function(){var t=this.getDisplayData().datasets[0];if(t.fillColors)this.colorScale=Wf().range(t.fillColors).domain(this.allDataLabels);else{var e=Of;this.colorScale=Wf().range(e).domain(this.allDataLabels)}},e.prototype.getFillColor=function(t){var e=this.getOptions();return e.getFillColor?e.getFillColor(t):this.getFillScale()(t)},e.prototype.getStrokeColor=function(t){var e=this.getOptions();return e.getStrokeColor?e.getStrokeColor(t):this.colorScale(t)},e}(dv),ox=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new ix(r.services),r.model.setOptions(Sc.merge(Sc.clone($c.simpleBarChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new vb(this.model,this.services),new ex(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new hb(this.model,this.services)),e},e}(rx),ax=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.groupedBarChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new gb(this.model,this.services),new ex(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new hb(this.model,this.services)),e},e}(rx),sx=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.stackedBarChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new yb(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new hb(this.model,this.services)),e},e}(rx),ux=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.bubbleChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new mb(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new pb(this.model,this.services)),e},e}(rx),lx=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.lineChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new bb(this.model,this.services),new _b(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new pb(this.model,this.services)),e},e}(rx),cx=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.scatterChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Qb(this.model,this.services),new tx(this.model,this.services),new _b(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new pb(this.model,this.services)),e},e}(rx),fx=function(t){function e(e){return t.call(this,e)||this}return s(e,t),e.prototype.sanitize=function(t){var e=Sc.getProperty(t,"datasets",0);if(e){var n=t.labels.map((function(t,n){return{label:t,value:e.data[n],fillColor:e.fillColors?e.fillColors[n]:void 0}})).sort((function(t,e){return e.value-t.value}));e.data=n.map((function(t){return t.value})),t.labels=n.map((function(t){return t.label})),e.fillColors&&(e.fillColors=n.map((function(t){return t.fillColor})))}return t},e.prototype.generateDataLabels=function(t){var e={};return t.labels.forEach((function(t){e[t]=Pc.items.status.ACTIVE})),e},e.prototype.getDisplayData=function(){var t=Pc.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=Sc.clone(this.get("data")),r=n.datasets[0];return r.data=r.data.filter((function(r,i){var o=n.labels[i];return e[o]===t})),n.labels=n.labels.filter((function(n){return e[n]===t})),n},e.prototype.toggleDataLabel=function(t){var e=Pc.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.get("dataLabels"),o=Object.keys(i).some((function(t){return i[t]===r})),a=Object.keys(i).filter((function(t){return i[t]===n}));o?1===a.length&&a[0]===t?Object.keys(i).forEach((function(t){i[t]=n})):i[t]=i[t]===r?n:r:Object.keys(i).forEach((function(e){i[e]=e===t?n:r})),this.set({dataLabels:i})},e.prototype.setColorScale=function(){var t=this.getDisplayData().datasets[0];if(t.fillColors)this.colorScale=Wf().range(t.fillColors).domain(this.allDataLabels);else{var e=Of;this.colorScale=Wf().range(e).domain(this.allDataLabels)}},e.prototype.getFillColor=function(t){var e=this.getOptions();return e.getFillColor?e.getFillColor(t):this.getFillScale()(t)},e.prototype.getStrokeColor=function(t){var e=this.getOptions();return e.getStrokeColor?e.getStrokeColor(t):this.colorScale(t)},e}(dv),hx=function(t){function e(e,n,r){void 0===r&&(r=!1);var i=t.call(this,e,n)||this;return i.model=new fx(i.services),r?i:(i.model.setOptions(Sc.merge(Sc.clone($c.pieChart),n.options)),i.init(e,n),i)}return s(e,t),e.prototype.getComponents=function(){var t=[new wb(this.model,this.services)],e=this.getChartComponents(t);return e.push(new fb(this.model,this.services)),e},e}(nx),px=function(t){function e(e,n){var r=t.call(this,e,n,!0)||this;return r.model.setOptions(Sc.merge(Sc.clone($c.donutChart),n.options)),r.init(e,n),r}return s(e,t),e.prototype.getComponents=function(){var t=[new Ob(this.model,this.services)],e=this.getChartComponents(t);return e.push(new fb(this.model,this.services)),e},e}(hx),dx=Of;t.BubbleChart=ux,t.DonutChart=px,t.GroupedBarChart=ax,t.LineChart=lx,t.PieChart=hx,t.ScatterChart=cx,t.SimpleBarChart=ox,t.StackedBarChart=sx,t.colorPalettes=Ef,t.configurations=tf,t.defaultColors=dx,t.interfaces=x,Object.defineProperty(t,"__esModule",{value:!0})}));
1
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t=t||self).Charts={})}(this,(function(t){"use strict";var e,n,r,i,o;!function(t){t.GRAPHICS_DOCUMENT="graphics-document",t.GRAPHICS_OBJECT="graphics-object",t.GRAPHICS_SYMBOL="graphics-symbol",t.GROUP="group"}(e||(e={})),function(t){t.SLICE_MOUSEOVER="pie-slice-mouseover",t.SLICE_MOUSEMOVE="pie-slice-mousemove",t.SLICE_CLICK="pie-slice-click",t.SLICE_MOUSEOUT="pie-slice-mouseout"}(n||(n={})),function(t){t.BAR_MOUSEOVER="bar-mouseover",t.BAR_MOUSEMOVE="bar-mousemove",t.BAR_CLICK="bar-click",t.BAR_MOUSEOUT="bar-mouseout"}(r||(r={})),function(t){t.SCATTER_MOUSEOVER="scatter-mouseover",t.SCATTER_MOUSEMOVE="scatter-mousemove",t.SCATTER_CLICK="scatter-click",t.SCATTER_MOUSEOUT="scatter-mouseout"}(i||(i={})),function(t){t.POINT_MOUSEOVER="scatter-mouseover",t.POINT_MOUSEMOVE="scatter-mousemove",t.POINT_CLICK="scatter-click",t.POINT_MOUSEOUT="scatter-mouseout"}(o||(o={}));var a,s,u,c,l,h,f,p,d,v,g,y,_=Object.freeze({__proto__:null,get Pie(){return n},get Bar(){return r},get Scatter(){return i},get Line(){return o}});!function(t){t.DEFAULT="default",t.G100="g100",t.G90="g90",t.G10="g10"}(a||(a={})),function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(s||(s={})),function(t){t.VERTICAL="vertical",t.HORIZONTAL="horizontal"}(u||(u={})),function(t){t.PRIMARY="primary",t.SECONDARY="secondary"}(c||(c={})),function(t){t.TIME="time",t.LINEAR="linear",t.LOG="log",t.LABELS="labels"}(l||(l={})),function(t){t.MOUSE="mouse",t.TOP="top",t.BOTTOM="bottom"}(h||(h={})),function(t){t.DATAPOINT="datapoint",t.GRIDLINE="gridline",t.TITLE="title"}(f||(f={})),function(t){t.RIGHT="right",t.LEFT="left",t.TOP="top",t.BOTTOM="bottom"}(p||(p={})),function(t){t.HORIZONTAL="horizontal",t.VERTICAL="vertical"}(d||(d={})),function(t){t.ROW="row",t.COLUMN="column",t.ROW_REVERSE="row-reverse",t.COLUMN_REVERSE="column-reverse"}(v||(v={})),function(t){t.FIXED="fixed",t.PREFERRED="preferred",t.STRETCH="stretch"}(g||(g={})),function(t){t.LEFT="left",t.RIGHT="right"}(y||(y={}));var m=Object.freeze({__proto__:null,get Roles(){return e},Events:_,get ChartTheme(){return a},get AxisPositions(){return s},get CartesianOrientations(){return u},get AxisTypes(){return c},get ScaleTypes(){return l},get TooltipPosition(){return h},get TooltipTypes(){return f},get LegendPositions(){return p},get LegendOrientations(){return d},get LayoutDirection(){return v},get LayoutGrowth(){return g},get CalloutDirections(){return y}}),b="object"==typeof global&&global&&global.Object===Object&&global,x="object"==typeof self&&self&&self.Object===Object&&self,w=b||x||Function("return this")(),O=w.Symbol,T=Object.prototype,E=T.hasOwnProperty,S=T.toString,M=O?O.toStringTag:void 0;var A=Object.prototype.toString;var P=O?O.toStringTag:void 0;function C(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":P&&P in Object(t)?function(t){var e=E.call(t,M),n=t[M];try{t[M]=void 0;var r=!0}catch(t){}var i=S.call(t);return r&&(e?t[M]=n:delete t[M]),i}(t):function(t){return A.call(t)}(t)}function L(t){return null!=t&&"object"==typeof t}var k=Array.isArray;function D(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var j=/^\s+|\s+$/g,R=/^[-+]0x[0-9a-f]+$/i,I=/^0b[01]+$/i,N=/^0o[0-7]+$/i,F=parseInt;function B(t){if("number"==typeof t)return t;if(function(t){return"symbol"==typeof t||L(t)&&"[object Symbol]"==C(t)}(t))return NaN;if(D(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=D(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(j,"");var n=I.test(t);return n||N.test(t)?F(t.slice(2),n?2:8):R.test(t)?NaN:+t}function V(t){return t}function U(t){if(!D(t))return!1;var e=C(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var H,z=w["__core-js_shared__"],G=(H=/[^.]+$/.exec(z&&z.keys&&z.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"";var Y=Function.prototype.toString;function q(t){if(null!=t){try{return Y.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var W=/^\[object .+?Constructor\]$/,X=Function.prototype,$=Object.prototype,Z=X.toString,K=$.hasOwnProperty,J=RegExp("^"+Z.call(K).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Q(t){return!(!D(t)||(e=t,G&&G in e))&&(U(t)?J:W).test(q(t));var e}function tt(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return Q(n)?n:void 0}var et=tt(w,"WeakMap"),nt=Object.create,rt=function(){function t(){}return function(e){if(!D(e))return{};if(nt)return nt(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();function it(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function ot(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}var at=Date.now;var st=function(){try{var t=tt(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),ut=function(t){var e=0,n=0;return function(){var r=at(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(st?function(t,e){return st(t,"toString",{configurable:!0,enumerable:!1,value:(n=e,function(){return n}),writable:!0});var n}:V);function ct(t){return t!=t}function lt(t,e){return!!(null==t?0:t.length)&&function(t,e,n){return e==e?function(t,e,n){for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}(t,e,n):function(t,e,n,r){for(var i=t.length,o=n+(r?1:-1);r?o--:++o<i;)if(e(t[o],o,t))return o;return-1}(t,ct,n)}(t,e,0)>-1}var ht=/^(?:0|[1-9]\d*)$/;function ft(t,e){var n=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==n||"symbol"!=n&&ht.test(t))&&t>-1&&t%1==0&&t<e}function pt(t,e,n){"__proto__"==e&&st?st(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function dt(t,e){return t===e||t!=t&&e!=e}var vt=Object.prototype.hasOwnProperty;function gt(t,e,n){var r=t[e];vt.call(t,e)&&dt(r,n)&&(void 0!==n||e in t)||pt(t,e,n)}function yt(t,e,n,r){var i=!n;n||(n={});for(var o=-1,a=e.length;++o<a;){var s=e[o],u=r?r(n[s],t[s],s,n,t):void 0;void 0===u&&(u=t[s]),i?pt(n,s,u):gt(n,s,u)}return n}var _t=Math.max;function mt(t,e){return ut(function(t,e,n){return e=_t(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,o=_t(r.length-e,0),a=Array(o);++i<o;)a[i]=r[e+i];i=-1;for(var s=Array(e+1);++i<e;)s[i]=r[i];return s[e]=n(a),it(t,this,s)}}(t,e,V),t+"")}function bt(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}function xt(t){return null!=t&&bt(t.length)&&!U(t)}var wt=Object.prototype;function Ot(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||wt)}function Tt(t){return L(t)&&"[object Arguments]"==C(t)}var Et=Object.prototype,St=Et.hasOwnProperty,Mt=Et.propertyIsEnumerable,At=Tt(function(){return arguments}())?Tt:function(t){return L(t)&&St.call(t,"callee")&&!Mt.call(t,"callee")};var Pt="object"==typeof t&&t&&!t.nodeType&&t,Ct=Pt&&"object"==typeof module&&module&&!module.nodeType&&module,Lt=Ct&&Ct.exports===Pt?w.Buffer:void 0,kt=(Lt?Lt.isBuffer:void 0)||function(){return!1},Dt={};function jt(t){return function(e){return t(e)}}Dt["[object Float32Array]"]=Dt["[object Float64Array]"]=Dt["[object Int8Array]"]=Dt["[object Int16Array]"]=Dt["[object Int32Array]"]=Dt["[object Uint8Array]"]=Dt["[object Uint8ClampedArray]"]=Dt["[object Uint16Array]"]=Dt["[object Uint32Array]"]=!0,Dt["[object Arguments]"]=Dt["[object Array]"]=Dt["[object ArrayBuffer]"]=Dt["[object Boolean]"]=Dt["[object DataView]"]=Dt["[object Date]"]=Dt["[object Error]"]=Dt["[object Function]"]=Dt["[object Map]"]=Dt["[object Number]"]=Dt["[object Object]"]=Dt["[object RegExp]"]=Dt["[object Set]"]=Dt["[object String]"]=Dt["[object WeakMap]"]=!1;var Rt="object"==typeof t&&t&&!t.nodeType&&t,It=Rt&&"object"==typeof module&&module&&!module.nodeType&&module,Nt=It&&It.exports===Rt&&b.process,Ft=function(){try{var t=It&&It.require&&It.require("util").types;return t||Nt&&Nt.binding&&Nt.binding("util")}catch(t){}}(),Bt=Ft&&Ft.isTypedArray,Vt=Bt?jt(Bt):function(t){return L(t)&&bt(t.length)&&!!Dt[C(t)]},Ut=Object.prototype.hasOwnProperty;function Ht(t,e){var n=k(t),r=!n&&At(t),i=!n&&!r&&kt(t),o=!n&&!r&&!i&&Vt(t),a=n||r||i||o,s=a?function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}(t.length,String):[],u=s.length;for(var c in t)!e&&!Ut.call(t,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||ft(c,u))||s.push(c);return s}function zt(t,e){return function(n){return t(e(n))}}var Gt=zt(Object.keys,Object),Yt=Object.prototype.hasOwnProperty;function qt(t){return xt(t)?Ht(t):function(t){if(!Ot(t))return Gt(t);var e=[];for(var n in Object(t))Yt.call(t,n)&&"constructor"!=n&&e.push(n);return e}(t)}var Wt=Object.prototype.hasOwnProperty;function Xt(t){if(!D(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=Ot(t),n=[];for(var r in t)("constructor"!=r||!e&&Wt.call(t,r))&&n.push(r);return n}function $t(t){return xt(t)?Ht(t,!0):Xt(t)}var Zt=tt(Object,"create");var Kt=Object.prototype.hasOwnProperty;var Jt=Object.prototype.hasOwnProperty;function Qt(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function te(t,e){for(var n=t.length;n--;)if(dt(t[n][0],e))return n;return-1}Qt.prototype.clear=function(){this.__data__=Zt?Zt(null):{},this.size=0},Qt.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Qt.prototype.get=function(t){var e=this.__data__;if(Zt){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return Kt.call(e,t)?e[t]:void 0},Qt.prototype.has=function(t){var e=this.__data__;return Zt?void 0!==e[t]:Jt.call(e,t)},Qt.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Zt&&void 0===e?"__lodash_hash_undefined__":e,this};var ee=Array.prototype.splice;function ne(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}ne.prototype.clear=function(){this.__data__=[],this.size=0},ne.prototype.delete=function(t){var e=this.__data__,n=te(e,t);return!(n<0)&&(n==e.length-1?e.pop():ee.call(e,n,1),--this.size,!0)},ne.prototype.get=function(t){var e=this.__data__,n=te(e,t);return n<0?void 0:e[n][1]},ne.prototype.has=function(t){return te(this.__data__,t)>-1},ne.prototype.set=function(t,e){var n=this.__data__,r=te(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var re=tt(w,"Map");function ie(t,e){var n,r,i=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof e?"string":"hash"]:i.map}function oe(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function ae(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}oe.prototype.clear=function(){this.size=0,this.__data__={hash:new Qt,map:new(re||ne),string:new Qt}},oe.prototype.delete=function(t){var e=ie(this,t).delete(t);return this.size-=e?1:0,e},oe.prototype.get=function(t){return ie(this,t).get(t)},oe.prototype.has=function(t){return ie(this,t).has(t)},oe.prototype.set=function(t,e){var n=ie(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};var se=zt(Object.getPrototypeOf,Object),ue=Function.prototype,ce=Object.prototype,le=ue.toString,he=ce.hasOwnProperty,fe=le.call(Object);function pe(t){var e=this.__data__=new ne(t);this.size=e.size}pe.prototype.clear=function(){this.__data__=new ne,this.size=0},pe.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},pe.prototype.get=function(t){return this.__data__.get(t)},pe.prototype.has=function(t){return this.__data__.has(t)},pe.prototype.set=function(t,e){var n=this.__data__;if(n instanceof ne){var r=n.__data__;if(!re||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new oe(r)}return n.set(t,e),this.size=n.size,this};var de="object"==typeof t&&t&&!t.nodeType&&t,ve=de&&"object"==typeof module&&module&&!module.nodeType&&module,ge=ve&&ve.exports===de?w.Buffer:void 0,ye=ge?ge.allocUnsafe:void 0;function _e(t,e){if(e)return t.slice();var n=t.length,r=ye?ye(n):new t.constructor(n);return t.copy(r),r}function me(){return[]}var be=Object.prototype.propertyIsEnumerable,xe=Object.getOwnPropertySymbols,we=xe?function(t){return null==t?[]:(t=Object(t),function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,o=[];++n<r;){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}(xe(t),(function(e){return be.call(t,e)})))}:me;var Oe=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)ae(e,we(t)),t=se(t);return e}:me;function Te(t,e,n){var r=e(t);return k(t)?r:ae(r,n(t))}function Ee(t){return Te(t,qt,we)}function Se(t){return Te(t,$t,Oe)}var Me=tt(w,"DataView"),Ae=tt(w,"Promise"),Pe=tt(w,"Set"),Ce=q(Me),Le=q(re),ke=q(Ae),De=q(Pe),je=q(et),Re=C;(Me&&"[object DataView]"!=Re(new Me(new ArrayBuffer(1)))||re&&"[object Map]"!=Re(new re)||Ae&&"[object Promise]"!=Re(Ae.resolve())||Pe&&"[object Set]"!=Re(new Pe)||et&&"[object WeakMap]"!=Re(new et))&&(Re=function(t){var e=C(t),n="[object Object]"==e?t.constructor:void 0,r=n?q(n):"";if(r)switch(r){case Ce:return"[object DataView]";case Le:return"[object Map]";case ke:return"[object Promise]";case De:return"[object Set]";case je:return"[object WeakMap]"}return e});var Ie=Re,Ne=Object.prototype.hasOwnProperty;var Fe=w.Uint8Array;function Be(t){var e=new t.constructor(t.byteLength);return new Fe(e).set(new Fe(t)),e}var Ve=/\w*$/;var Ue=O?O.prototype:void 0,He=Ue?Ue.valueOf:void 0;function ze(t,e){var n=e?Be(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Ge(t,e,n){var r,i,o,a=t.constructor;switch(e){case"[object ArrayBuffer]":return Be(t);case"[object Boolean]":case"[object Date]":return new a(+t);case"[object DataView]":return function(t,e){var n=e?Be(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return ze(t,n);case"[object Map]":return new a;case"[object Number]":case"[object String]":return new a(t);case"[object RegExp]":return(o=new(i=t).constructor(i.source,Ve.exec(i))).lastIndex=i.lastIndex,o;case"[object Set]":return new a;case"[object Symbol]":return r=t,He?Object(He.call(r)):{}}}function Ye(t){return"function"!=typeof t.constructor||Ot(t)?{}:rt(se(t))}var qe=Ft&&Ft.isMap,We=qe?jt(qe):function(t){return L(t)&&"[object Map]"==Ie(t)};var Xe=Ft&&Ft.isSet,$e=Xe?jt(Xe):function(t){return L(t)&&"[object Set]"==Ie(t)},Ze={};function Ke(t,e,n,r,i,o){var a,s=1&e,u=2&e,c=4&e;if(n&&(a=i?n(t,r,i,o):n(t)),void 0!==a)return a;if(!D(t))return t;var l=k(t);if(l){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&Ne.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!s)return ot(t,a)}else{var h=Ie(t),f="[object Function]"==h||"[object GeneratorFunction]"==h;if(kt(t))return _e(t,s);if("[object Object]"==h||"[object Arguments]"==h||f&&!i){if(a=u||f?{}:Ye(t),!s)return u?function(t,e){return yt(t,Oe(t),e)}(t,function(t,e){return t&&yt(e,$t(e),t)}(a,t)):function(t,e){return yt(t,we(t),e)}(t,function(t,e){return t&&yt(e,qt(e),t)}(a,t))}else{if(!Ze[h])return i?t:{};a=Ge(t,h,s)}}o||(o=new pe);var p=o.get(t);if(p)return p;o.set(t,a),$e(t)?t.forEach((function(r){a.add(Ke(r,e,n,r,t,o))})):We(t)&&t.forEach((function(r,i){a.set(i,Ke(r,e,n,i,t,o))}));var d=c?u?Se:Ee:u?keysIn:qt,v=l?void 0:d(t);return function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););}(v||t,(function(r,i){v&&(r=t[i=r]),gt(a,i,Ke(r,e,n,i,t,o))})),a}Ze["[object Arguments]"]=Ze["[object Array]"]=Ze["[object ArrayBuffer]"]=Ze["[object DataView]"]=Ze["[object Boolean]"]=Ze["[object Date]"]=Ze["[object Float32Array]"]=Ze["[object Float64Array]"]=Ze["[object Int8Array]"]=Ze["[object Int16Array]"]=Ze["[object Int32Array]"]=Ze["[object Map]"]=Ze["[object Number]"]=Ze["[object Object]"]=Ze["[object RegExp]"]=Ze["[object Set]"]=Ze["[object String]"]=Ze["[object Symbol]"]=Ze["[object Uint8Array]"]=Ze["[object Uint8ClampedArray]"]=Ze["[object Uint16Array]"]=Ze["[object Uint32Array]"]=!0,Ze["[object Error]"]=Ze["[object Function]"]=Ze["[object WeakMap]"]=!1;function Je(t){return Ke(t,5)}function Qe(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new oe;++e<n;)this.add(t[e])}function tn(t,e){return t.has(e)}function en(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}Qe.prototype.add=Qe.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},Qe.prototype.has=function(t){return this.__data__.has(t)};var nn,rn=function(t,e,n){for(var r=-1,i=Object(t),o=n(t),a=o.length;a--;){var s=o[nn?a:++r];if(!1===e(i[s],s,i))break}return t},on=function(){return w.Date.now()},an=Math.max,sn=Math.min;function un(t,e,n){var r,i,o,a,s,u,c=0,l=!1,h=!1,f=!0;if("function"!=typeof t)throw new TypeError("Expected a function");function p(e){var n=r,o=i;return r=i=void 0,c=e,a=t.apply(o,n)}function d(t){return c=t,s=setTimeout(g,e),l?p(t):a}function v(t){var n=t-u;return void 0===u||n>=e||n<0||h&&t-c>=o}function g(){var t=on();if(v(t))return y(t);s=setTimeout(g,function(t){var n=e-(t-u);return h?sn(n,o-(t-c)):n}(t))}function y(t){return s=void 0,f&&r?p(t):(r=i=void 0,a)}function _(){var t=on(),n=v(t);if(r=arguments,i=this,u=t,n){if(void 0===s)return d(u);if(h)return clearTimeout(s),s=setTimeout(g,e),p(u)}return void 0===s&&(s=setTimeout(g,e)),a}return e=B(e)||0,D(n)&&(l=!!n.leading,o=(h="maxWait"in n)?an(B(n.maxWait)||0,e):o,f="trailing"in n?!!n.trailing:f),_.cancel=function(){void 0!==s&&clearTimeout(s),c=0,r=u=i=s=void 0},_.flush=function(){return void 0===s?a:y(on())},_}function cn(t,e,n){(void 0===n||dt(t[e],n))&&(void 0!==n||e in t)||pt(t,e,n)}function ln(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}function hn(t,e,n,r,i,o,a){var s=ln(t,n),u=ln(e,n),c=a.get(u);if(c)cn(t,n,c);else{var l,h=o?o(s,u,n+"",t,e,a):void 0,f=void 0===h;if(f){var p=k(u),d=!p&&kt(u),v=!p&&!d&&Vt(u);h=u,p||d||v?k(s)?h=s:L(l=s)&&xt(l)?h=ot(s):d?(f=!1,h=_e(u,!0)):v?(f=!1,h=ze(u,!0)):h=[]:function(t){if(!L(t)||"[object Object]"!=C(t))return!1;var e=se(t);if(null===e)return!0;var n=he.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&le.call(n)==fe}(u)||At(u)?(h=s,At(s)?h=function(t){return yt(t,$t(t))}(s):D(s)&&!U(s)||(h=Ye(u))):f=!1}f&&(a.set(u,h),i(h,u,r,o,a),a.delete(u)),cn(t,n,h)}}function fn(t,e,n,r,i){t!==e&&rn(e,(function(o,a){if(i||(i=new pe),D(o))hn(t,e,a,n,fn,r,i);else{var s=r?r(ln(t,a),o,a+"",t,e,i):void 0;void 0===s&&(s=o),cn(t,a,s)}}),$t)}function pn(t,e,n){for(var r=-1,i=null==t?0:t.length;++r<i;)if(n(e,t[r]))return!0;return!1}var dn,vn,gn=(dn=function(t,e,n){fn(t,e,n)},mt((function(t,e){var n=-1,r=e.length,i=r>1?e[r-1]:void 0,o=r>2?e[2]:void 0;for(i=dn.length>3&&"function"==typeof i?(r--,i):void 0,o&&function(t,e,n){if(!D(n))return!1;var r=typeof e;return!!("number"==r?xt(n)&&ft(e,n.length):"string"==r&&e in n)&&dt(n[e],t)}(e[0],e[1],o)&&(i=r<3?void 0:i,r=1),t=Object(t);++n<r;){var a=e[n];a&&dn(t,a,n,i)}return t}))),yn=Pe&&1/en(new Pe([,-0]))[1]==1/0?function(t){return new Pe(t)}:function(){};function _n(t){return t&&t.length?function(t,e,n){var r=-1,i=lt,o=t.length,a=!0,s=[],u=s;if(n)a=!1,i=pn;else if(o>=200){var c=e?null:yn(t);if(c)return en(c);a=!1,i=tn,u=new Qe}else u=e?[]:s;t:for(;++r<o;){var l=t[r],h=e?e(l):l;if(l=n||0!==l?l:0,a&&h==h){for(var f=u.length;f--;)if(u[f]===h)continue t;e&&u.push(h),s.push(l)}else i(u,h,n)||(u!==s&&u.push(h),s.push(l))}return s}(t):[]}!function(t){t.debounce=un,t.clone=Je,t.merge=gn,t.removeArrayDuplicates=_n,t.getDimensions=function(t){return{width:parseFloat(t.style.width.replace("px","")||t.offsetWidth),height:parseFloat(t.style.height.replace("px","")||t.offsetHeight)}},t.getTranslationValues=function(t){var e=t.getAttribute("transform").match(/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/);if(e[0]){var n=e[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:n[0],ty:n[1]}}return null},t.getTranformOffsets=function(t){var e=/\(([^)]+)\)/.exec(t)[1].split(",");return{x:parseFloat(e[0]),y:parseFloat(e[1])}},t.capitalizeFirstLetter=function(t){return t[0].toUpperCase()+t.slice(1)},t.convertValueToPercentage=function(t,e){var n=t/e.reduce((function(t,e){return t+e.value}),0)*100;return n<1?n.toPrecision(1):Math.floor(n)},t.arrayDifferences=function(t,e){var n={missing:[],added:[]};return t.forEach((function(t){-1===e.indexOf(t)&&n.missing.push(t)})),e.forEach((function(e){-1===t.indexOf(e)&&n.added.push(e)})),n},t.getDuplicateValues=function(t){var e=[],n=[];return t.forEach((function(t){-1!==e.indexOf(t)&&-1===n.indexOf(t)&&n.push(t),e.push(t)})),n},t.moveToFront=function(t){return t.each((function(){this.parentNode.appendChild(this)}))},t.getProperty=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];var r=t;if(r){for(var i=0,o=e;i<o.length;i++){var a=o[i];if(!r[a])return null;r=r[a]}return r}return null},t.flipSVGCoordinatesBasedOnOrientation=function(t,e){return e===u.HORIZONTAL?{y0:t.x0,y1:t.x1,x0:t.y0,x1:t.y1}:t},t.generateSVGPathString=function(e,n){var r=t.flipSVGCoordinatesBasedOnOrientation(e,n),i=r.x0,o=r.x1,a=r.y0,s=r.y1;return"M"+i+","+a+"L"+i+","+s+"L"+o+","+s+"L"+o+","+a+"L"+i+","+a}}(vn||(vn={}));var mn={position:p.BOTTOM,clickable:!0,enabled:!0,items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8},checkbox:{radius:6.5,spaceAfter:4}},bn={x:{numberOfTicks:5},y:{numberOfTicks:5}},xn={datapoint:{horizontalOffset:10,enabled:!0},title:{verticalOffset:.75,width:.4}},wn=vn.merge({},xn,{gridline:{enabled:!0,threshold:.25}}),On=vn.merge({},wn,{datapoint:{verticalOffset:4},gridline:{enabled:!1}}),Tn={addSpaceOnEdges:1},En={width:"100%",height:"100%",resizable:!0,tooltip:xn,legend:mn,style:{prefix:"cc"}},Sn=vn.merge({},En,{axes:{},timeScale:Tn,grid:bn,tooltip:wn}),Mn=vn.merge({},Sn,{bars:{maxWidth:16},timeScale:vn.merge(Tn,{addSpaceOnEdges:1}),tooltip:On}),An=vn.merge({},Mn,{}),Pn=vn.merge({},Mn,{}),Cn=vn.merge({},Mn,{bars:vn.merge({},Mn.bars,{dividerSize:1.5})}),Ln=vn.merge({},Sn,{points:{radius:3,filled:!1}}),kn=vn.merge({},Sn,{points:{radius:4,fillOpacity:.3,filled:!0}}),Dn=vn.merge({},Sn,{bubble:{radiusRange:function(t,e){var n=Math.min(t.width,t.height);return[3*n/400,25*n/400]},fillOpacity:.2}}),jn=vn.merge({},En,{pie:{radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2},labels:{formatter:null}}}),Rn={chart:En,axisChart:Sn,simpleBarChart:An,groupedBarChart:Pn,stackedBarChart:Cn,bubbleChart:Dn,lineChart:Ln,scatterChart:kn,pieChart:jn,donutChart:vn.merge({},jn,{donut:{center:{numberFontSize:function(t){return Math.min(t/100*24,24)+"px"},titleFontSize:function(t){return Math.min(t/100*15,15)+"px"},titleYPosition:function(t){return Math.min(t/80*20,20)},numberFormatter:function(t){return Math.floor(t).toLocaleString()}}}})},In={opacity:{unselected:.3,selected:1}},Nn={default:{duration:300},pie_slice_mouseover:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},Fn={ticks:{number:7,rotateIfSmallerThan:30}},Bn={default:{size:24}},Vn=Object.freeze({__proto__:null,legend:mn,grid:bn,baseTooltip:xn,axisChartTooltip:wn,barChartTooltip:On,options:Rn,lines:In,transitions:Nn,axis:Fn,spacers:Bn}),Un={10:"#fff0f1",20:"#fcd0d3",30:"#ffa4a9",40:"#ff767c",50:"#fb4b53",60:"#da1e28",70:"#a51920",80:"#750e13",90:"#570408",100:"#2c080a"},Hn={10:"#fff0f6",20:"#ffcfe1",30:"#ffa0c2",40:"#fa75a6",50:"#ee538b",60:"#d12765",70:"#a11950",80:"#760a3a",90:"#57002b",100:"#2a0a16"},zn={10:"#f7f1ff",20:"#e6d6ff",30:"#d0b0ff",40:"#bb8eff",50:"#a66efa",60:"#8a3ffc",70:"#6e32c9",80:"#4f2196",90:"#38146b",100:"#1e1033"},Gn={10:"#edf4ff",20:"#c9deff",30:"#97c1ff",40:"#6ea6ff",50:"#408bfc",60:"#0062ff",70:"#054ada",80:"#0530ad",90:"#061f80",100:"#051243"},Yn={10:"#e3f6ff",20:"#b3e6ff",30:"#6ccaff",40:"#30b0ff",50:"#1191e6",60:"#0072c3",70:"#0058a1",80:"#003d73",90:"#002b50",100:"#07192b"},qn={10:"#dbfbfb",20:"#92eeee",30:"#20d5d2",40:"#00bab6",50:"#009c98",60:"#007d79",70:"#006161",80:"#004548",90:"#003137",100:"#081a1c"},Wn={10:"#dafbe4",20:"#9deeb2",30:"#56d679",40:"#3dbb61",50:"#24a148",60:"#198038",70:"#10642a",80:"#054719",90:"#01330f",100:"#081b09"},Xn=function(t,e){return t[e]},$n=function(t){return Xn(Gn,t)},Zn=function(t){return Xn(Yn,t)},Kn=function(t){return Xn(Wn,t)},Jn=function(t){return Xn(Hn,t)},Qn=function(t){return Xn(zn,t)},tr=function(t){return Xn(Un,t)},er=function(t){return Xn(qn,t)},nr=[Qn(70),Zn(50),er(70),Jn(70),tr(50),tr(90),Kn(60),$n(80),Jn(50),"#b28600",er(50),Zn(90),"#8a3800",Qn(50)],rr=[Qn(60),Zn(40),er(60),Jn(40),tr(50),tr(10),Kn(30),$n(50),Jn(60),"#d2a106",er(40),Zn(20),"#ba4e00",Qn(30)],ir=nr,or=rr,ar=rr,sr=nr,ur=Object.freeze({__proto__:null,WHITE:nr,DARK:rr,G10:ir,G90:or,G100:ar,DEFAULT:sr});function cr(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function lr(t){var e;return 1===t.length&&(e=t,t=function(t,n){return cr(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)<0?r=o+1:i=o}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var o=r+i>>>1;t(e[o],n)>0?i=o:r=o+1}return r}}}var hr=lr(cr).right;function fr(t,e){var n,r,i,o=t.length,a=-1;if(null==e){for(;++a<o;)if(null!=(n=t[a])&&n>=n)for(r=i=n;++a<o;)null!=(n=t[a])&&(r>n&&(r=n),i<n&&(i=n))}else for(;++a<o;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=i=n;++a<o;)null!=(n=e(t[a],a,t))&&(r>n&&(r=n),i<n&&(i=n));return[r,i]}function pr(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),o=new Array(i);++r<i;)o[r]=t+r*n;return o}var dr=Math.sqrt(50),vr=Math.sqrt(10),gr=Math.sqrt(2);function yr(t,e,n){var r,i,o,a,s=-1;if(n=+n,(t=+t)===(e=+e)&&n>0)return[t];if((r=e<t)&&(i=t,t=e,e=i),0===(a=_r(t,e,n))||!isFinite(a))return[];if(a>0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(i=Math.ceil(e-t+1));++s<i;)o[s]=(t+s)*a;else for(t=Math.floor(t*a),e=Math.ceil(e*a),o=new Array(i=Math.ceil(t-e+1));++s<i;)o[s]=(t-s)/a;return r&&o.reverse(),o}function _r(t,e,n){var r=(e-t)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),o=r/Math.pow(10,i);return i>=0?(o>=dr?10:o>=vr?5:o>=gr?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=dr?10:o>=vr?5:o>=gr?2:1)}function mr(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=dr?i*=10:o>=vr?i*=5:o>=gr&&(i*=2),e<t?-i:i}function br(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function xr(){}function wr(t,e){var n=new xr;if(t instanceof xr)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,o=t.length;if(null==e)for(;++i<o;)n.set(i,t[i]);else for(;++i<o;)n.set(e(r=t[i],i,t),r)}else if(t)for(var a in t)n.set(a,t[a]);return n}function Or(){}xr.prototype=wr.prototype={constructor:xr,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var Tr=wr.prototype;Or.prototype=function(t,e){var n=new Or;if(t instanceof Or)t.each((function(t){n.add(t)}));else if(t){var r=-1,i=t.length;if(null==e)for(;++r<i;)n.add(t[r]);else for(;++r<i;)n.add(e(t[r],r,t))}return n}.prototype={constructor:Or,has:Tr.has,add:function(t){return this["$"+(t+="")]=t,this},remove:Tr.remove,clear:Tr.clear,values:Tr.keys,size:Tr.size,empty:Tr.empty,each:Tr.each};var Er=Array.prototype,Sr=Er.map,Mr=Er.slice,Ar={name:"implicit"};function Pr(){var t=wr(),e=[],n=[],r=Ar;function i(i){var o=i+"",a=t.get(o);if(!a){if(r!==Ar)return r;t.set(o,a=e.push(i))}return n[(a-1)%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=wr();for(var r,o,a=-1,s=n.length;++a<s;)t.has(o=(r=n[a])+"")||t.set(o,e.push(r));return i},i.range=function(t){return arguments.length?(n=Mr.call(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Pr(e,n).unknown(r)},br.apply(i,arguments),i}function Cr(){var t,e,n=Pr().unknown(void 0),r=n.domain,i=n.range,o=[0,1],a=!1,s=0,u=0,c=.5;function l(){var n=r().length,l=o[1]<o[0],h=o[l-0],f=o[1-l];t=(f-h)/Math.max(1,n-s+2*u),a&&(t=Math.floor(t)),h+=(f-h-t*(n-s))*c,e=t*(1-s),a&&(h=Math.round(h),e=Math.round(e));var p=pr(n).map((function(e){return h+t*e}));return i(l?p.reverse():p)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),l()):r()},n.range=function(t){return arguments.length?(o=[+t[0],+t[1]],l()):o.slice()},n.rangeRound=function(t){return o=[+t[0],+t[1]],a=!0,l()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(a=!!t,l()):a},n.padding=function(t){return arguments.length?(s=Math.min(1,u=+t),l()):s},n.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),l()):s},n.paddingOuter=function(t){return arguments.length?(u=+t,l()):u},n.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),l()):c},n.copy=function(){return Cr(r(),o).round(a).paddingInner(s).paddingOuter(u).align(c)},br.apply(l(),arguments)}function Lr(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function kr(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Dr(){}var jr="\\s*([+-]?\\d+)\\s*",Rr="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ir="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Nr=/^#([0-9a-f]{3,8})$/,Fr=new RegExp("^rgb\\("+[jr,jr,jr]+"\\)$"),Br=new RegExp("^rgb\\("+[Ir,Ir,Ir]+"\\)$"),Vr=new RegExp("^rgba\\("+[jr,jr,jr,Rr]+"\\)$"),Ur=new RegExp("^rgba\\("+[Ir,Ir,Ir,Rr]+"\\)$"),Hr=new RegExp("^hsl\\("+[Rr,Ir,Ir]+"\\)$"),zr=new RegExp("^hsla\\("+[Rr,Ir,Ir,Rr]+"\\)$"),Gr={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function Yr(){return this.rgb().formatHex()}function qr(){return this.rgb().formatRgb()}function Wr(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=Nr.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?Xr(e):3===n?new Jr(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?new Jr(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?new Jr(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=Fr.exec(t))?new Jr(e[1],e[2],e[3],1):(e=Br.exec(t))?new Jr(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Vr.exec(t))?$r(e[1],e[2],e[3],e[4]):(e=Ur.exec(t))?$r(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=Hr.exec(t))?ni(e[1],e[2]/100,e[3]/100,1):(e=zr.exec(t))?ni(e[1],e[2]/100,e[3]/100,e[4]):Gr.hasOwnProperty(t)?Xr(Gr[t]):"transparent"===t?new Jr(NaN,NaN,NaN,0):null}function Xr(t){return new Jr(t>>16&255,t>>8&255,255&t,1)}function $r(t,e,n,r){return r<=0&&(t=e=n=NaN),new Jr(t,e,n,r)}function Zr(t){return t instanceof Dr||(t=Wr(t)),t?new Jr((t=t.rgb()).r,t.g,t.b,t.opacity):new Jr}function Kr(t,e,n,r){return 1===arguments.length?Zr(t):new Jr(t,e,n,null==r?1:r)}function Jr(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function Qr(){return"#"+ei(this.r)+ei(this.g)+ei(this.b)}function ti(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function ei(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function ni(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new ii(t,e,n,r)}function ri(t){if(t instanceof ii)return new ii(t.h,t.s,t.l,t.opacity);if(t instanceof Dr||(t=Wr(t)),!t)return new ii;if(t instanceof ii)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),o=Math.max(e,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(a=e===o?(n-r)/s+6*(n<r):n===o?(r-e)/s+2:(e-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new ii(a,s,u,t.opacity)}function ii(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function oi(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function ai(t){return function(){return t}}function si(t){return 1==(t=+t)?ui:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):ai(isNaN(e)?n:e)}}function ui(t,e){var n=e-t;return n?function(t,e){return function(n){return t+n*e}}(t,n):ai(isNaN(t)?e:t)}Lr(Dr,Wr,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:Yr,formatHex:Yr,formatHsl:function(){return ri(this).formatHsl()},formatRgb:qr,toString:qr}),Lr(Jr,Kr,kr(Dr,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Jr(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Jr(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Qr,formatHex:Qr,formatRgb:ti,toString:ti})),Lr(ii,(function(t,e,n,r){return 1===arguments.length?ri(t):new ii(t,e,n,null==r?1:r)}),kr(Dr,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new ii(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new ii(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new Jr(oi(t>=240?t-240:t+120,i,r),oi(t,i,r),oi(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var ci=function t(e){var n=si(e);function r(t,e){var r=n((t=Kr(t)).r,(e=Kr(e)).r),i=n(t.g,e.g),o=n(t.b,e.b),a=ui(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return r.gamma=t,r}(1);function li(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(n=0;n<r;++n)i[n]=t[n]*(1-o)+e[n]*o;return i}}function hi(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=_i(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}}function fi(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function pi(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function di(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=_i(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var vi=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,gi=new RegExp(vi.source,"g");function yi(t,e){var n,r,i,o=vi.lastIndex=gi.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=vi.exec(t))&&(r=gi.exec(e));)(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:pi(n,r)})),o=gi.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})}function _i(t,e){var n,r=typeof e;return null==e||"boolean"===r?ai(e):("number"===r?pi:"string"===r?(n=Wr(e))?(e=n,ci):yi:e instanceof Wr?ci:e instanceof Date?fi:function(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}(e)?li:Array.isArray(e)?hi:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?di:pi)(t,e)}function mi(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}var bi,xi,wi,Oi,Ti=180/Math.PI,Ei={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Si(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*Ti,skewX:Math.atan(u)*Ti,scaleX:a,scaleY:s}}function Mi(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:pi(t,i)},{i:u-2,x:pi(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:pi(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:pi(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:pi(t,n)},{i:s-2,x:pi(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var Ai=Mi((function(t){return"none"===t?Ei:(bi||(bi=document.createElement("DIV"),xi=document.documentElement,wi=document.defaultView),bi.style.transform=t,t=wi.getComputedStyle(xi.appendChild(bi),null).getPropertyValue("transform"),xi.removeChild(bi),Si(+(t=t.slice(7,-1).split(","))[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),Pi=Mi((function(t){return null==t?Ei:(Oi||(Oi=document.createElementNS("http://www.w3.org/2000/svg","g")),Oi.setAttribute("transform",t),(t=Oi.transform.baseVal.consolidate())?Si((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):Ei)}),", ",")",")");function Ci(t){return+t}var Li=[0,1];function ki(t){return t}function Di(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:function(t){return function(){return t}}(isNaN(e)?NaN:.5)}function ji(t){var e,n=t[0],r=t[t.length-1];return n>r&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function Ri(t,e,n){var r=t[0],i=t[1],o=e[0],a=e[1];return i<r?(r=Di(i,r),o=n(a,o)):(r=Di(r,i),o=n(o,a)),function(t){return o(r(t))}}function Ii(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<r;)i[a]=Di(t[a],t[a+1]),o[a]=n(e[a],e[a+1]);return function(e){var n=hr(t,e,1,r)-1;return o[n](i[n](e))}}function Ni(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Fi(){var t,e,n,r,i,o,a=Li,s=Li,u=_i,c=ki;function l(){return r=Math.min(a.length,s.length)>2?Ii:Ri,i=o=null,h}function h(e){return isNaN(e=+e)?n:(i||(i=r(a.map(t),s,u)))(t(c(e)))}return h.invert=function(n){return c(e((o||(o=r(s,a.map(t),pi)))(n)))},h.domain=function(t){return arguments.length?(a=Sr.call(t,Ci),c===ki||(c=ji(a)),l()):a.slice()},h.range=function(t){return arguments.length?(s=Mr.call(t),l()):s.slice()},h.rangeRound=function(t){return s=Mr.call(t),u=mi,l()},h.clamp=function(t){return arguments.length?(c=t?ji(a):ki,h):c!==ki},h.interpolate=function(t){return arguments.length?(u=t,l()):u},h.unknown=function(t){return arguments.length?(n=t,h):n},function(n,r){return t=n,e=r,l()}}function Bi(t,e){return Fi()(t,e)}function Vi(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function Ui(t){return(t=Vi(Math.abs(t)))?t[1]:NaN}var Hi,zi=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Gi(t){if(!(e=zi.exec(t)))throw new Error("invalid format: "+t);var e;return new Yi({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function Yi(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function qi(t,e){var n=Vi(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}Gi.prototype=Yi.prototype,Yi.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var Wi={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return qi(100*t,e)},r:qi,s:function(t,e){var n=Vi(t,e);if(!n)return t+"";var r=n[0],i=n[1],o=i-(Hi=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Vi(t,Math.max(0,e+o-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function Xi(t){return t}var $i,Zi,Ki,Ji=Array.prototype.map,Qi=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function to(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?Xi:(e=Ji.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(t.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Xi:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(Ji.call(t.numerals,String)),u=void 0===t.percent?"%":t.percent+"",c=void 0===t.minus?"-":t.minus+"",l=void 0===t.nan?"NaN":t.nan+"";function h(t){var e=(t=Gi(t)).fill,n=t.align,h=t.sign,f=t.symbol,p=t.zero,d=t.width,v=t.comma,g=t.precision,y=t.trim,_=t.type;"n"===_?(v=!0,_="g"):Wi[_]||(void 0===g&&(g=12),y=!0,_="g"),(p||"0"===e&&"="===n)&&(p=!0,e="0",n="=");var m="$"===f?i:"#"===f&&/[boxX]/.test(_)?"0"+_.toLowerCase():"",b="$"===f?o:/[%p]/.test(_)?u:"",x=Wi[_],w=/[defgprs%]/.test(_);function O(t){var i,o,u,f=m,O=b;if("c"===_)O=x(t)+O,t="";else{var T=(t=+t)<0;if(t=isNaN(t)?l:x(Math.abs(t),g),y&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),T&&0==+t&&(T=!1),f=(T?"("===h?h:c:"-"===h||"("===h?"":h)+f,O=("s"===_?Qi[8+Hi/3]:"")+O+(T&&"("===h?")":""),w)for(i=-1,o=t.length;++i<o;)if(48>(u=t.charCodeAt(i))||u>57){O=(46===u?a+t.slice(i+1):t.slice(i))+O,t=t.slice(0,i);break}}v&&!p&&(t=r(t,1/0));var E=f.length+t.length+O.length,S=E<d?new Array(d-E+1).join(e):"";switch(v&&p&&(t=r(S+t,S.length?d-O.length:1/0),S=""),n){case"<":t=f+t+O+S;break;case"=":t=f+S+t+O;break;case"^":t=S.slice(0,E=S.length>>1)+f+t+O+S.slice(E);break;default:t=S+f+t+O}return s(t)}return g=void 0===g?6:/[gprs]/.test(_)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),O.toString=function(){return t+""},O}return{format:h,formatPrefix:function(t,e){var n=h(((t=Gi(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(Ui(e)/3))),i=Math.pow(10,-r),o=Qi[8+r/3];return function(t){return n(i*t)+o}}}}function eo(t,e,n,r){var i,o=mr(t,e,n);switch((r=Gi(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Ui(e)/3)))-Ui(Math.abs(t)))}(o,a))||(r.precision=i),Ki(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Ui(e)-Ui(t))+1}(o,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(t){return Math.max(0,-Ui(Math.abs(t)))}(o))||(r.precision=i-2*("%"===r.type))}return Zi(r)}function no(t){var e=t.domain;return t.ticks=function(t){var n=e();return yr(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return eo(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),o=0,a=i.length-1,s=i[o],u=i[a];return u<s&&(r=s,s=u,u=r,r=o,o=a,a=r),(r=_r(s,u,n))>0?r=_r(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=_r(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(u/r)*r,e(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(u*r)/r,e(i)),t},t}function ro(){var t=Bi(ki,ki);return t.copy=function(){return Ni(t,ro())},br.apply(t,arguments),no(t)}function io(t,e){var n,r=0,i=(t=t.slice()).length-1,o=t[r],a=t[i];return a<o&&(n=r,r=i,i=n,n=o,o=a,a=n),t[r]=e.floor(o),t[i]=e.ceil(a),t}function oo(t){return Math.log(t)}function ao(t){return Math.exp(t)}function so(t){return-Math.log(-t)}function uo(t){return-Math.exp(-t)}function co(t){return isFinite(t)?+("1e"+t):t<0?0:t}function lo(t){return function(e){return-t(-e)}}function ho(t){var e,n,r=t(oo,ao),i=r.domain,o=10;function a(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(o),n=function(t){return 10===t?co:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(o),i()[0]<0?(e=lo(e),n=lo(n),t(so,uo)):t(oo,ao),r}return r.base=function(t){return arguments.length?(o=+t,a()):o},r.domain=function(t){return arguments.length?(i(t),a()):i()},r.ticks=function(t){var r,a=i(),s=a[0],u=a[a.length-1];(r=u<s)&&(f=s,s=u,u=f);var c,l,h,f=e(s),p=e(u),d=null==t?10:+t,v=[];if(!(o%1)&&p-f<d){if(f=Math.round(f)-1,p=Math.round(p)+1,s>0){for(;f<p;++f)for(l=1,c=n(f);l<o;++l)if(!((h=c*l)<s)){if(h>u)break;v.push(h)}}else for(;f<p;++f)for(l=o-1,c=n(f);l>=1;--l)if(!((h=c*l)<s)){if(h>u)break;v.push(h)}}else v=yr(f,p,Math.min(p-f,d)).map(n);return r?v.reverse():v},r.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=Zi(i)),t===1/0)return i;null==t&&(t=10);var a=Math.max(1,o*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*o<o-.5&&(r*=o),r<=a?i(t):""}},r.nice=function(){return i(io(i(),{floor:function(t){return n(Math.floor(e(t)))},ceil:function(t){return n(Math.ceil(e(t)))}}))},r}$i=to({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),Zi=$i.format,Ki=$i.formatPrefix;var fo=new Date,po=new Date;function vo(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},i.round=function(t){var e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},i.range=function(n,r,o){var a,s=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return s;do{s.push(a=new Date(+n)),e(n,o),t(n)}while(a<n&&n<r);return s},i.filter=function(n){return vo((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return fo.setTime(+e),po.setTime(+r),t(fo),t(po),Math.floor(n(fo,po))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var go=vo((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));go.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?vo((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):go:null};var yo=vo((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),_o=vo((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),mo=vo((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),bo=vo((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1}));function xo(t){return vo((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var wo=xo(0),Oo=xo(1),To=(xo(2),xo(3),xo(4)),Eo=(xo(5),xo(6),vo((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}))),So=vo((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));So.every=function(t){return isFinite(t=Math.floor(t))&&t>0?vo((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var Mo=vo((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}));function Ao(t){return vo((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var Po=Ao(0),Co=Ao(1),Lo=(Ao(2),Ao(3),Ao(4)),ko=(Ao(5),Ao(6),vo((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()})));function Do(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function jo(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Ro(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}ko.every=function(t){return isFinite(t=Math.floor(t))&&t>0?vo((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var Io,No,Fo={"-":"",_:" ",0:"0"},Bo=/^\s*\d+/,Vo=/^%/,Uo=/[\\^$*+?|[\]().{}]/g;function Ho(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(e)+i:i)}function zo(t){return t.replace(Uo,"\\$&")}function Go(t){return new RegExp("^(?:"+t.map(zo).join("|")+")","i")}function Yo(t){for(var e={},n=-1,r=t.length;++n<r;)e[t[n].toLowerCase()]=n;return e}function qo(t,e,n){var r=Bo.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function Wo(t,e,n){var r=Bo.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function Xo(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function $o(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Zo(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function Ko(t,e,n){var r=Bo.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function Jo(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Qo(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function ta(t,e,n){var r=Bo.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function ea(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function na(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function ra(t,e,n){var r=Bo.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function ia(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function oa(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function aa(t,e,n){var r=Bo.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function sa(t,e,n){var r=Bo.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ua(t,e,n){var r=Bo.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function ca(t,e,n){var r=Vo.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function la(t,e,n){var r=Bo.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function ha(t,e,n){var r=Bo.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function fa(t,e){return Ho(t.getDate(),e,2)}function pa(t,e){return Ho(t.getHours(),e,2)}function da(t,e){return Ho(t.getHours()%12||12,e,2)}function va(t,e){return Ho(1+bo.count(So(t),t),e,3)}function ga(t,e){return Ho(t.getMilliseconds(),e,3)}function ya(t,e){return ga(t,e)+"000"}function _a(t,e){return Ho(t.getMonth()+1,e,2)}function ma(t,e){return Ho(t.getMinutes(),e,2)}function ba(t,e){return Ho(t.getSeconds(),e,2)}function xa(t){var e=t.getDay();return 0===e?7:e}function wa(t,e){return Ho(wo.count(So(t)-1,t),e,2)}function Oa(t,e){var n=t.getDay();return t=n>=4||0===n?To(t):To.ceil(t),Ho(To.count(So(t),t)+(4===So(t).getDay()),e,2)}function Ta(t){return t.getDay()}function Ea(t,e){return Ho(Oo.count(So(t)-1,t),e,2)}function Sa(t,e){return Ho(t.getFullYear()%100,e,2)}function Ma(t,e){return Ho(t.getFullYear()%1e4,e,4)}function Aa(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Ho(e/60|0,"0",2)+Ho(e%60,"0",2)}function Pa(t,e){return Ho(t.getUTCDate(),e,2)}function Ca(t,e){return Ho(t.getUTCHours(),e,2)}function La(t,e){return Ho(t.getUTCHours()%12||12,e,2)}function ka(t,e){return Ho(1+Mo.count(ko(t),t),e,3)}function Da(t,e){return Ho(t.getUTCMilliseconds(),e,3)}function ja(t,e){return Da(t,e)+"000"}function Ra(t,e){return Ho(t.getUTCMonth()+1,e,2)}function Ia(t,e){return Ho(t.getUTCMinutes(),e,2)}function Na(t,e){return Ho(t.getUTCSeconds(),e,2)}function Fa(t){var e=t.getUTCDay();return 0===e?7:e}function Ba(t,e){return Ho(Po.count(ko(t)-1,t),e,2)}function Va(t,e){var n=t.getUTCDay();return t=n>=4||0===n?Lo(t):Lo.ceil(t),Ho(Lo.count(ko(t),t)+(4===ko(t).getUTCDay()),e,2)}function Ua(t){return t.getUTCDay()}function Ha(t,e){return Ho(Co.count(ko(t)-1,t),e,2)}function za(t,e){return Ho(t.getUTCFullYear()%100,e,2)}function Ga(t,e){return Ho(t.getUTCFullYear()%1e4,e,4)}function Ya(){return"+0000"}function qa(){return"%"}function Wa(t){return+t}function Xa(t){return Math.floor(+t/1e3)}function $a(t){return Io=function(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,u=t.shortMonths,c=Go(i),l=Yo(i),h=Go(o),f=Yo(o),p=Go(a),d=Yo(a),v=Go(s),g=Yo(s),y=Go(u),_=Yo(u),m={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:fa,e:fa,f:ya,H:pa,I:da,j:va,L:ga,m:_a,M:ma,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Wa,s:Xa,S:ba,u:xa,U:wa,V:Oa,w:Ta,W:Ea,x:null,X:null,y:Sa,Y:Ma,Z:Aa,"%":qa},b={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return u[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:Pa,e:Pa,f:ja,H:Ca,I:La,j:ka,L:Da,m:Ra,M:Ia,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Wa,s:Xa,S:Na,u:Fa,U:Ba,V:Va,w:Ua,W:Ha,x:null,X:null,y:za,Y:Ga,Z:Ya,"%":qa},x={a:function(t,e,n){var r=p.exec(e.slice(n));return r?(t.w=d[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=h.exec(e.slice(n));return r?(t.w=f[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=y.exec(e.slice(n));return r?(t.m=_[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=v.exec(e.slice(n));return r?(t.m=g[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return T(t,e,n,r)},d:na,e:na,f:ua,H:ia,I:ia,j:ra,L:sa,m:ea,M:oa,p:function(t,e,n){var r=c.exec(e.slice(n));return r?(t.p=l[r[0].toLowerCase()],n+r[0].length):-1},q:ta,Q:la,s:ha,S:aa,u:Wo,U:Xo,V:$o,w:qo,W:Zo,x:function(t,e,r){return T(t,n,e,r)},X:function(t,e,n){return T(t,r,e,n)},y:Jo,Y:Ko,Z:Qo,"%":ca};function w(t,e){return function(n){var r,i,o,a=[],s=-1,u=0,c=t.length;for(n instanceof Date||(n=new Date(+n));++s<c;)37===t.charCodeAt(s)&&(a.push(t.slice(u,s)),null!=(i=Fo[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(o=e[r])&&(r=o(n,i)),a.push(r),u=s+1);return a.push(t.slice(u,s)),a.join("")}}function O(t,e){return function(n){var r,i,o=Ro(1900,void 0,1);if(T(o,t,n+="",0)!=n.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(!e||"Z"in o||(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=jo(Ro(o.y,0,1))).getUTCDay(),r=i>4||0===i?Co.ceil(r):Co(r),r=Mo.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=Do(Ro(o.y,0,1))).getDay(),r=i>4||0===i?Oo.ceil(r):Oo(r),r=bo.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?jo(Ro(o.y,0,1)).getUTCDay():Do(Ro(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,jo(o)):Do(o)}}function T(t,e,n,r){for(var i,o,a=0,s=e.length,u=n.length;a<s;){if(r>=u)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=x[i in Fo?e.charAt(a++):i])||(r=o(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return(m.x=w(n,m),m.X=w(r,m),m.c=w(e,m),b.x=w(n,b),b.X=w(r,b),b.c=w(e,b),{format:function(t){var e=w(t+="",m);return e.toString=function(){return t},e},parse:function(t){var e=O(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=O(t+="",!0);return e.toString=function(){return t},e}})}(t),No=Io.format,Io.parse,Io.utcFormat,Io.utcParse,Io}$a({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Za(t){return new Date(t)}function Ka(t){return t instanceof Date?+t:+new Date(+t)}function Ja(t,e,n,r,i,o,a,s,u){var c=Bi(ki,ki),l=c.invert,h=c.domain,f=u(".%L"),p=u(":%S"),d=u("%I:%M"),v=u("%I %p"),g=u("%a %d"),y=u("%b %d"),_=u("%B"),m=u("%Y"),b=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function x(s){return(a(s)<s?f:o(s)<s?p:i(s)<s?d:r(s)<s?v:e(s)<s?n(s)<s?g:y:t(s)<s?_:m)(s)}function w(e,n,r,i){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(r-n)/e,a=lr((function(t){return t[2]})).right(b,o);a===b.length?(i=mr(n/31536e6,r/31536e6,e),e=t):a?(i=(a=b[o/b[a-1][2]<b[a][2]/o?a-1:a])[1],e=a[0]):(i=Math.max(mr(n,r,e),1),e=s)}return null==i?e:e.every(i)}return c.invert=function(t){return new Date(l(t))},c.domain=function(t){return arguments.length?h(Sr.call(t,Ka)):h().map(Za)},c.ticks=function(t,e){var n,r=h(),i=r[0],o=r[r.length-1],a=o<i;return a&&(n=i,i=o,o=n),n=(n=w(t,i,o,e))?n.range(i,o+1):[],a?n.reverse():n},c.tickFormat=function(t,e){return null==e?x:u(e)},c.nice=function(t,e){var n=h();return(t=w(t,n[0],n[n.length-1],e))?h(io(n,t)):c},c.copy=function(){return Ni(c,Ja(t,e,n,r,i,o,a,s,u))},c}var Qa=function(){function t(t){this.state={options:{}},this.patternScale={},this.colorScale={},this.services=t}return t.prototype.sanitize=function(t){return t.datasets.forEach((function(t){t.data=t.data.map((function(t){return t.date&&!t.date.getTime&&(t.date=new Date(t.date)),t}))})),t},t.prototype.getDisplayData=function(){var t=mn.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=vn.clone(this.get("data"));return n.datasets=n.datasets.filter((function(n){return e[n.label]===t})),n},t.prototype.getData=function(){return this.get("data")},t.prototype.setData=function(t){var e=this.sanitize(vn.clone(t)),n=this.generateDataLabels(e);return this.set({data:e,dataLabels:n}),e},t.prototype.generateDataLabels=function(t){var e={};return t.datasets.forEach((function(t){e[t.label]=mn.items.status.ACTIVE})),e},t.prototype.getOptions=function(){return this.state.options},t.prototype.set=function(t,e){void 0===e&&(e=!1),this.state=Object.assign({},this.state,t),e||this.update()},t.prototype.get=function(t){return t?this.state[t]:this.state},t.prototype.setOptions=function(t){this.set({options:vn.merge(this.getOptions(),t)})},t.prototype.update=function(){this.getDisplayData()&&(this.updateAllDataLabels(),this.setColorScale(),this.services.events.dispatchEvent("model-update"))},t.prototype.setUpdateCallback=function(t){this.updateCallback=t},t.prototype.toggleDataLabel=function(t){var e=mn.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.get("dataLabels"),o=Object.keys(i).some((function(t){return i[t]===r})),a=Object.keys(i).filter((function(t){return i[t]===n}));o?1===a.length&&a[0]===t?Object.keys(i).forEach((function(t){i[t]=n})):i[t]=i[t]===r?n:r:Object.keys(i).forEach((function(e){i[e]=e===t?n:r})),this.set({dataLabels:i})},t.prototype.setColorScale=function(){var t=this;if(this.getDisplayData().datasets[0].fillColors)this.getDisplayData().datasets.forEach((function(e){t.colorScale[e.label]=Pr().range(e.fillColors).domain(t.allDataLabels)}));else{var e=sr;this.getData().datasets.forEach((function(n,r){t.colorScale[n.label]=Pr().range([e[r]]).domain(t.allDataLabels)}))}},t.prototype.getIsFilled=function(t,e,n,r){var i=this.getOptions();return i.getIsFilled?i.getIsFilled(t,e,n,r):r},t.prototype.getFillColor=function(t,e,n){var r=this.getOptions(),i=this.getFillScale()[t](e);return r.getFillColor?r.getFillColor(t,e,n,i):i},t.prototype.getStrokeColor=function(t,e,n){var r=this.getOptions(),i=this.colorScale[t](e);return r.getStrokeColor?r.getStrokeColor(t,e,n,i):i},t.prototype.getFillScale=function(){return this.colorScale},t.prototype.updateAllDataLabels=function(){var t=this;this.allDataLabels?this.getDisplayData().labels.forEach((function(e){-1===t.allDataLabels.indexOf(e)&&t.allDataLabels.push(e)})):this.allDataLabels=this.getDisplayData().labels},t}(),ts=function(){function t(t,e){this.model=t,this.services=e,this.init()}return t.prototype.init=function(){},t.prototype.update=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t}(),es="http://www.w3.org/1999/xhtml",ns={svg:"http://www.w3.org/2000/svg",xhtml:es,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function rs(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),ns.hasOwnProperty(e)?{space:ns[e],local:t}:t}function is(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===es&&e.documentElement.namespaceURI===es?e.createElement(t):e.createElementNS(n,t)}}function os(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function as(t){var e=rs(t);return(e.local?os:is)(e)}function ss(){}function us(t){return null==t?ss:function(){return this.querySelector(t)}}function cs(){return[]}function ls(t){return null==t?cs:function(){return this.querySelectorAll(t)}}function hs(t){return function(){return this.matches(t)}}function fs(t){return new Array(t.length)}function ps(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}ps.prototype={constructor:ps,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function ds(t,e,n,r,i,o){for(var a,s=0,u=e.length,c=o.length;s<c;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new ps(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function vs(t,e,n,r,i,o,a){var s,u,c,l={},h=e.length,f=o.length,p=new Array(h);for(s=0;s<h;++s)(u=e[s])&&(p[s]=c="$"+a.call(u,u.__data__,s,e),c in l?i[s]=u:l[c]=u);for(s=0;s<f;++s)(u=l[c="$"+a.call(t,o[s],s,o)])?(r[s]=u,u.__data__=o[s],l[c]=null):n[s]=new ps(t,o[s]);for(s=0;s<h;++s)(u=e[s])&&l[p[s]]===u&&(i[s]=u)}function gs(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function ys(t){return function(){this.removeAttribute(t)}}function _s(t){return function(){this.removeAttributeNS(t.space,t.local)}}function ms(t,e){return function(){this.setAttribute(t,e)}}function bs(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function xs(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function ws(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function Os(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Ts(t){return function(){this.style.removeProperty(t)}}function Es(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Ss(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function Ms(t,e){return t.style.getPropertyValue(e)||Os(t).getComputedStyle(t,null).getPropertyValue(e)}function As(t){return function(){delete this[t]}}function Ps(t,e){return function(){this[t]=e}}function Cs(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function Ls(t){return t.trim().split(/^|\s+/)}function ks(t){return t.classList||new Ds(t)}function Ds(t){this._node=t,this._names=Ls(t.getAttribute("class")||"")}function js(t,e){for(var n=ks(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function Rs(t,e){for(var n=ks(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function Is(t){return function(){js(this,t)}}function Ns(t){return function(){Rs(this,t)}}function Fs(t,e){return function(){(e.apply(this,arguments)?js:Rs)(this,t)}}function Bs(){this.textContent=""}function Vs(t){return function(){this.textContent=t}}function Us(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function Hs(){this.innerHTML=""}function zs(t){return function(){this.innerHTML=t}}function Gs(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function Ys(){this.nextSibling&&this.parentNode.appendChild(this)}function qs(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Ws(){return null}function Xs(){var t=this.parentNode;t&&t.removeChild(this)}function $s(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Zs(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}Ds.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Ks={},Js=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(Ks={mouseenter:"mouseover",mouseleave:"mouseout"}));function Qs(t,e,n){return t=tu(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function tu(t,e,n){return function(r){var i=Js;Js=r;try{t.call(this,this.__data__,e,n)}finally{Js=i}}}function eu(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function nu(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.capture);++i?e.length=i:delete this.__on}}}function ru(t,e,n){var r=Ks.hasOwnProperty(t.type)?Qs:tu;return function(i,o,a){var s,u=this.__on,c=r(e,o,a);if(u)for(var l=0,h=u.length;l<h;++l)if((s=u[l]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=c,s.capture=n),void(s.value=e);this.addEventListener(t.type,c,n),s={type:t.type,name:t.name,value:e,listener:c,capture:n},u?u.push(s):this.__on=[s]}}function iu(t,e,n){var r=Os(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function ou(t,e){return function(){return iu(this,t,e)}}function au(t,e){return function(){return iu(this,t,e.apply(this,arguments))}}var su=[null];function uu(t,e){this._groups=t,this._parents=e}function cu(){return new uu([[document.documentElement]],su)}function lu(t){return"string"==typeof t?new uu([[document.querySelector(t)]],[document.documentElement]):new uu([[t]],su)}function hu(){for(var t,e=Js;t=e.sourceEvent;)e=t;return e}function fu(t){var e=hu();return e.changedTouches&&(e=e.changedTouches[0]),function(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}(t,e)}uu.prototype=cu.prototype={constructor:uu,select:function(t){"function"!=typeof t&&(t=us(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],u=s.length,c=r[i]=new Array(u),l=0;l<u;++l)(o=s[l])&&(a=t.call(o,o.__data__,l,s))&&("__data__"in o&&(a.__data__=o.__data__),c[l]=a);return new uu(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=ls(t));for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,c=0;c<u;++c)(a=s[c])&&(r.push(t.call(a,a.__data__,c,s)),i.push(a));return new uu(r,i)},filter:function(t){"function"!=typeof t&&(t=hs(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],c=0;c<s;++c)(o=a[c])&&t.call(o,o.__data__,c,a)&&u.push(o);return new uu(r,this._parents)},data:function(t,e){if(!t)return p=new Array(this.size()),c=-1,this.each((function(t){p[++c]=t})),p;var n=e?vs:ds,r=this._parents,i=this._groups;"function"!=typeof t&&(t=function(t){return function(){return t}}(t));for(var o=i.length,a=new Array(o),s=new Array(o),u=new Array(o),c=0;c<o;++c){var l=r[c],h=i[c],f=h.length,p=t.call(l,l&&l.__data__,c,r),d=p.length,v=s[c]=new Array(d),g=a[c]=new Array(d);n(l,h,v,g,u[c]=new Array(f),p,e);for(var y,_,m=0,b=0;m<d;++m)if(y=v[m]){for(m>=b&&(b=m+1);!(_=g[b])&&++b<d;);y._next=_||null}}return(a=new uu(a,r))._enter=s,a._exit=u,a},enter:function(){return new uu(this._enter||this._groups.map(fs),this._parents)},exit:function(){return new uu(this._exit||this._groups.map(fs),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,o=this.exit();return r="function"==typeof t?t(r):r.append(t+""),null!=e&&(i=e(i)),null==n?o.remove():n(o),r&&i?r.merge(i).order():i},merge:function(t){for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,c=e[s],l=n[s],h=c.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=c[p]||l[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new uu(a,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=gs);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,c=i[o]=new Array(u),l=0;l<u;++l)(a=s[l])&&(c[l]=a);c.sort(e)}return new uu(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,e){var n=rs(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?_s:ys:"function"==typeof e?n.local?ws:xs:n.local?bs:ms)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?Ts:"function"==typeof e?Ss:Es)(t,e,null==n?"":n)):Ms(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?As:"function"==typeof e?Cs:Ps)(t,e)):this.node()[t]},classed:function(t,e){var n=Ls(t+"");if(arguments.length<2){for(var r=ks(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?Fs:e?Is:Ns)(n,e))},text:function(t){return arguments.length?this.each(null==t?Bs:("function"==typeof t?Us:Vs)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?Hs:("function"==typeof t?Gs:zs)(t)):this.node().innerHTML},raise:function(){return this.each(Ys)},lower:function(){return this.each(qs)},append:function(t){var e="function"==typeof t?t:as(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:as(t),r=null==e?Ws:"function"==typeof e?e:us(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(Xs)},clone:function(t){return this.select(t?Zs:$s)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=eu(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?ru:nu,null==n&&(n=!1),r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,c=0,l=s.length;c<l;++c)for(r=0,u=s[c];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value},dispatch:function(t,e){return this.each(("function"==typeof e?au:ou)(t,e))}};var pu={prefix:"bx",selectorTabbable:"\n a[href], area[href], input:not([disabled]):not([tabindex='-1']),\n button:not([disabled]):not([tabindex='-1']),select:not([disabled]):not([tabindex='-1']),\n textarea:not([disabled]):not([tabindex='-1']),\n iframe, object, embed, *[tabindex]:not([tabindex='-1']), *[contenteditable=true]\n "},du=function(){if("undefined"!=typeof Map)return Map;function t(t,e){var n=-1;return t.some((function(t,r){return t[0]===e&&(n=r,!0)})),n}return function(){function e(){this.__entries__=[]}var n={size:{configurable:!0}};return n.size.get=function(){return this.__entries__.length},e.prototype.get=function(e){var n=t(this.__entries__,e),r=this.__entries__[n];return r&&r[1]},e.prototype.set=function(e,n){var r=t(this.__entries__,e);~r?this.__entries__[r][1]=n:this.__entries__.push([e,n])},e.prototype.delete=function(e){var n=this.__entries__,r=t(n,e);~r&&n.splice(r,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){void 0===e&&(e=null);for(var n=0,r=this.__entries__;n<r.length;n+=1){var i=r[n];t.call(e,i[1],i[0])}},Object.defineProperties(e.prototype,n),e}()}(),vu="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,gu="undefined"!=typeof global&&global.Math===Math?global:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),yu="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(gu):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)},_u=["top","right","bottom","left","width","height","size","weight"],mu="undefined"!=typeof MutationObserver,bu=function(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t,e){var n=!1,r=!1,i=0;function o(){n&&(n=!1,t()),r&&s()}function a(){yu(o)}function s(){var t=Date.now();if(n){if(t-i<2)return;r=!0}else n=!0,r=!1,setTimeout(a,e);i=t}return s}(this.refresh.bind(this),20)};bu.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},bu.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},bu.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},bu.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},bu.prototype.connect_=function(){vu&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),mu?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},bu.prototype.disconnect_=function(){vu&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},bu.prototype.onTransitionEnd_=function(t){var e=t.propertyName;void 0===e&&(e=""),_u.some((function(t){return!!~e.indexOf(t)}))&&this.refresh()},bu.getInstance=function(){return this.instance_||(this.instance_=new bu),this.instance_},bu.instance_=null;var xu=function(t,e){for(var n=0,r=Object.keys(e);n<r.length;n+=1){var i=r[n];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},wu=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||gu},Ou=Pu(0,0,0,0);function Tu(t){return parseFloat(t)||0}function Eu(t){for(var e=[],n=arguments.length-1;n-- >0;)e[n]=arguments[n+1];return e.reduce((function(e,n){return e+Tu(t["border-"+n+"-width"])}),0)}function Su(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return Ou;var r=wu(t).getComputedStyle(t),i=function(t){for(var e={},n=0,r=["top","right","bottom","left"];n<r.length;n+=1){var i=r[n],o=t["padding-"+i];e[i]=Tu(o)}return e}(r),o=i.left+i.right,a=i.top+i.bottom,s=Tu(r.width),u=Tu(r.height);if("border-box"===r.boxSizing&&(Math.round(s+o)!==e&&(s-=Eu(r,"left","right")+o),Math.round(u+a)!==n&&(u-=Eu(r,"top","bottom")+a)),!function(t){return t===wu(t).document.documentElement}(t)){var c=Math.round(s+o)-e,l=Math.round(u+a)-n;1!==Math.abs(c)&&(s-=c),1!==Math.abs(l)&&(u-=l)}return Pu(i.left,i.top,s,u)}var Mu="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof wu(t).SVGGraphicsElement}:function(t){return t instanceof wu(t).SVGElement&&"function"==typeof t.getBBox};function Au(t){return vu?Mu(t)?function(t){var e=t.getBBox();return Pu(0,0,e.width,e.height)}(t):Su(t):Ou}function Pu(t,e,n,r){return{x:t,y:e,width:n,height:r}}var Cu=function(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=Pu(0,0,0,0),this.target=t};Cu.prototype.isActive=function(){var t=Au(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},Cu.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t};var Lu=function(t,e){var n=function(t){var e=t.x,n=t.y,r=t.width,i=t.height,o="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,a=Object.create(o.prototype);return xu(a,{x:e,y:n,width:r,height:i,top:n,right:e+r,bottom:i+n,left:e}),a}(e);xu(this,{target:t,contentRect:n})},ku=function(t,e,n){if(this.activeObservations_=[],this.observations_=new du,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n};ku.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof wu(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new Cu(t)),this.controller_.addObserver(this),this.controller_.refresh())}},ku.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof wu(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},ku.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},ku.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},ku.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new Lu(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},ku.prototype.clearActive=function(){this.activeObservations_.splice(0)},ku.prototype.hasActive=function(){return this.activeObservations_.length>0};var Du="undefined"!=typeof WeakMap?new WeakMap:new du,ju=function(t){if(!(this instanceof ju))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var e=bu.getInstance(),n=new ku(t,e,this);Du.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){ju.prototype[t]=function(){return(e=Du.get(this))[t].apply(e,arguments);var e}}));var Ru,Iu=void 0!==gu.ResizeObserver?gu.ResizeObserver:ju,Nu=(Ru=function(t,e){return(Ru=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}Ru(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),Fu=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Nu(e,t),e.getSVGElementSize=function(t,e){t.attr||(t=lu(t));var n,r,i,o,a={width:t.attr("width"),height:t.attr("height")};try{r={width:(n=t.node().getBBox()).width,height:n.height}}catch(t){}try{o={width:(i=t.node().getBoundingClientRect()).width,height:i.height}}catch(t){}var s={width:t.node().clientWidth,height:t.node().clientHeight},u=function(t){return!!(t&&t.width&&t.height&&!isNaN(t.height)&&!isNaN(t.width)&&-1===(""+t.width+t.height).indexOf("%")&&t.width>0&&t.height>0)};if(e){if(e.useAttrs&&u(a))return a;if(e.useClientDimensions&&u(s))return s;if(e.useBBox&&u(r))return r;if(e.useBoundingRect&&u(o))return o}try{var c={width:vn.getProperty(t.node(),"width","baseVal","value"),height:vn.getProperty(t.node(),"height","baseVal","value")};if(u(c))return c}catch(t){if(u(s))return s;if(u(r))return r;if(u(a))return a}return{width:0,height:0}},e.appendOrSelect=function(t,e){var n=e.split("."),r=n[0],i=t.select(e);return i.empty()?t.append(r).attr("class",n.slice(1).join(" ")):i},e.prototype.init=function(){this.styleHolderElement(),this.addSVGElement(),this.model.getOptions().resizable&&this.addResizeListener()},e.prototype.update=function(){this.styleHolderElement()},e.prototype.styleHolderElement=function(){var t=this.getHolder();lu(this.getHolder()).classed(pu.prefix+"--chart-holder",!0);var e=this.model.getOptions(),n=e.width,r=e.height;n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r)},e.prototype.getHolder=function(){return this.model.get("holder")},e.prototype.addSVGElement=function(){var t=vn.getProperty(this.model.getOptions(),"style","prefix"),e=lu(this.getHolder()).append("svg").classed(pu.prefix+"--"+t+"--chart-svg",!0).attr("height","100%").attr("width","100%");this.svg=e.node()},e.prototype.getMainSVG=function(){return this.svg},e.prototype.addResizeListener=function(){var t=this,e=this.getHolder();if(e){var n=e.clientWidth,r=e.clientHeight,i=vn.debounce((function(i,o){e&&(Math.abs(n-e.clientWidth)>1||Math.abs(r-e.clientHeight)>1)&&(n=e.clientWidth,r=e.clientHeight,t.services.events.dispatchEvent("chart-resize"))}),12.5);new Iu(i).observe(e)}},e}(ts),Bu=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Vu=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Bu(e,t),e.prototype.init=function(){this.documentFragment=document.createDocumentFragment()},e.prototype.addEventListener=function(t,e){this.documentFragment.addEventListener(t,e)},e.prototype.removeEventListener=function(t,e){this.documentFragment.removeEventListener(t,e)},e.prototype.dispatchEvent=function(t,e){var n;e?n=new CustomEvent(t,{detail:e}):(n=document.createEvent("Event")).initEvent(t,!1,!0),this.documentFragment.dispatchEvent(n)},e}(ts),Uu={value:function(){}};function Hu(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new zu(r)}function zu(t){this._=t}function Gu(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function Yu(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function qu(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=Uu,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}zu.prototype=Hu.prototype={constructor:zu,on:function(t,e){var n,r=this._,i=Gu(t+"",r),o=-1,a=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++o<a;)if(n=(t=i[o]).type)r[n]=qu(r[n],t.name,e);else if(null==e)for(n in r)r[n]=qu(r[n],t.name,null);return this}for(;++o<a;)if((n=(t=i[o]).type)&&(n=Yu(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new zu(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(r=this._[t]).length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var Wu,Xu,$u=0,Zu=0,Ku=0,Ju=0,Qu=0,tc=0,ec="object"==typeof performance&&performance.now?performance:Date,nc="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function rc(){return Qu||(nc(ic),Qu=ec.now()+tc)}function ic(){Qu=0}function oc(){this._call=this._time=this._next=null}function ac(t,e,n){var r=new oc;return r.restart(t,e,n),r}function sc(){Qu=(Ju=ec.now())+tc,$u=Zu=0;try{!function(){rc(),++$u;for(var t,e=Wu;e;)(t=Qu-e._time)>=0&&e._call.call(null,t),e=e._next;--$u}()}finally{$u=0,function(){var t,e,n=Wu,r=1/0;for(;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:Wu=e);Xu=t,cc(r)}(),Qu=0}}function uc(){var t=ec.now(),e=t-Ju;e>1e3&&(tc-=e,Ju=t)}function cc(t){$u||(Zu&&(Zu=clearTimeout(Zu)),t-Qu>24?(t<1/0&&(Zu=setTimeout(sc,t-ec.now()-tc)),Ku&&(Ku=clearInterval(Ku))):(Ku||(Ju=ec.now(),Ku=setInterval(uc,1e3)),$u=1,nc(sc)))}function lc(t,e,n){var r=new oc;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}oc.prototype=ac.prototype={constructor:oc,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?rc():+n)+(null==e?0:+e),this._next||Xu===this||(Xu?Xu._next=this:Wu=this,Xu=this),this._call=t,this._time=n,cc()},stop:function(){this._call&&(this._call=null,this._time=1/0,cc())}};var hc=Hu("start","end","cancel","interrupt"),fc=[];function pc(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(u){var c,l,h,f;if(1!==n.state)return s();for(c in i)if((f=i[c]).name===n.name){if(3===f.state)return lc(o);4===f.state?(f.state=6,f.timer.stop(),f.on.call("interrupt",t,t.__data__,f.index,f.group),delete i[c]):+c<e&&(f.state=6,f.timer.stop(),f.on.call("cancel",t,t.__data__,f.index,f.group),delete i[c])}if(lc((function(){3===n.state&&(n.state=4,n.timer.restart(a,n.delay,n.time),a(u))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,r=new Array(h=n.tween.length),c=0,l=-1;c<h;++c)(f=n.tween[c].value.call(t,t.__data__,n.index,n.group))&&(r[++l]=f);r.length=l+1}}function a(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=6,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=ac((function(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}),0,n.time)}(t,n,{name:e,index:r,group:i,on:hc,tween:fc,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function dc(t,e){var n=gc(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function vc(t,e){var n=gc(t,e);if(n.state>3)throw new Error("too late; already running");return n}function gc(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function yc(t,e){var n,r;return function(){var i=vc(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}function _c(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=vc(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,c=i.length;u<c;++u)if(i[u].name===e){i[u]=s;break}u===c&&i.push(s)}o.tween=i}}function mc(t,e,n){var r=t._id;return t.each((function(){var t=vc(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return gc(t,r).value[e]}}function bc(t,e){var n;return("number"==typeof e?pi:e instanceof Wr?ci:(n=Wr(e))?(e=n,ci):yi)(t,e)}function xc(t){return function(){this.removeAttribute(t)}}function wc(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Oc(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=e(r=a,n)}}function Tc(t,e,n){var r,i,o=n+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=e(r=a,n)}}function Ec(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttribute(t))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttribute(t)}}function Sc(t,e,n){var r,i,o;return function(){var a,s,u=n(this);if(null!=u)return(a=this.getAttributeNS(t.space,t.local))===(s=u+"")?null:a===r&&s===i?o:(i=s,o=e(r=a,u));this.removeAttributeNS(t.space,t.local)}}function Mc(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function Ac(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Pc(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Ac(t,i)),n}return i._value=e,i}function Cc(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Mc(t,i)),n}return i._value=e,i}function Lc(t,e){return function(){dc(this,t).delay=+e.apply(this,arguments)}}function kc(t,e){return e=+e,function(){dc(this,t).delay=e}}function Dc(t,e){return function(){vc(this,t).duration=+e.apply(this,arguments)}}function jc(t,e){return e=+e,function(){vc(this,t).duration=e}}function Rc(t,e){if("function"!=typeof e)throw new Error;return function(){vc(this,t).ease=e}}function Ic(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?dc:vc;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}var Nc=cu.prototype.constructor;function Fc(t){return function(){this.style.removeProperty(t)}}function Bc(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function Vc(t,e,n){var r,i;function o(){var o=e.apply(this,arguments);return o!==i&&(r=(i=o)&&Bc(t,o,n)),r}return o._value=e,o}function Uc(t){return function(e){this.textContent=t.call(this,e)}}function Hc(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&Uc(r)),e}return r._value=t,r}var zc=0;function Gc(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function Yc(t){return cu().transition(t)}function qc(){return++zc}var Wc=cu.prototype;Gc.prototype=Yc.prototype={constructor:Gc,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=us(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s,u,c=r[a],l=c.length,h=o[a]=new Array(l),f=0;f<l;++f)(s=c[f])&&(u=t.call(s,s.__data__,f,c))&&("__data__"in s&&(u.__data__=s.__data__),h[f]=u,pc(h[f],e,n,f,h,gc(s,n)));return new Gc(o,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=ls(t));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var u,c=r[s],l=c.length,h=0;h<l;++h)if(u=c[h]){for(var f,p=t.call(u,u.__data__,h,c),d=gc(u,n),v=0,g=p.length;v<g;++v)(f=p[v])&&pc(f,e,n,v,p,d);o.push(p),a.push(u)}return new Gc(o,a,e,n)},filter:function(t){"function"!=typeof t&&(t=hs(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],c=0;c<s;++c)(o=a[c])&&t.call(o,o.__data__,c,a)&&u.push(o);return new Gc(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,c=e[s],l=n[s],h=c.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=c[p]||l[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new Gc(a,this._parents,this._name,this._id)},selection:function(){return new Nc(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=qc(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,c=0;c<u;++c)if(a=s[c]){var l=gc(a,e);pc(a,t,n,c,s,{time:l.time+l.delay+l.duration,delay:0,duration:l.duration,ease:l.ease})}return new Gc(r,this._parents,t,n)},call:Wc.call,nodes:Wc.nodes,node:Wc.node,size:Wc.size,empty:Wc.empty,each:Wc.each,on:function(t,e){var n=this._id;return arguments.length<2?gc(this.node(),n).on.on(t):this.each(Ic(n,t,e))},attr:function(t,e){var n=rs(t),r="transform"===n?Pi:bc;return this.attrTween(t,"function"==typeof e?(n.local?Sc:Ec)(n,r,mc(this,"attr."+t,e)):null==e?(n.local?wc:xc)(n):(n.local?Tc:Oc)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=rs(t);return this.tween(n,(r.local?Pc:Cc)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?Ai:bc;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var o=Ms(this,t),a=(this.style.removeProperty(t),Ms(this,t));return o===a?null:o===n&&a===r?i:i=e(n=o,r=a)}}(t,r)).on("end.style."+t,Fc(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,o;return function(){var a=Ms(this,t),s=n(this),u=s+"";return null==s&&(this.style.removeProperty(t),u=s=Ms(this,t)),a===u?null:a===r&&u===i?o:(i=u,o=e(r=a,s))}}(t,r,mc(this,"style."+t,e))).each(function(t,e){var n,r,i,o,a="style."+e,s="end."+a;return function(){var u=vc(this,t),c=u.on,l=null==u.value[a]?o||(o=Fc(e)):void 0;c===n&&i===l||(r=(n=c).copy()).on(s,i=l),u.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,o=n+"";return function(){var a=Ms(this,t);return a===o?null:a===r?i:i=e(r=a,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,Vc(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(mc(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,Hc(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=gc(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?yc:_c)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Lc:kc)(e,t)):gc(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Dc:jc)(e,t)):gc(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(Rc(e,t)):gc(this.node(),e).ease},end:function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(o,a){var s={value:a},u={value:function(){0==--i&&o()}};n.each((function(){var n=vc(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(u)),n.on=e}))}))}};var Xc={time:null,delay:0,duration:250,ease:function(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}};function $c(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return Xc.time=rc(),Xc;return n}cu.prototype.interrupt=function(t){return this.each((function(){!function(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}}(this,t)}))},cu.prototype.transition=function(t){var e,n;t instanceof Gc?(e=t._id,t=t._name):(e=qc(),(n=Xc).time=rc(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,c=0;c<u;++c)(a=s[c])&&pc(a,t,e,c,s,n||$c(a,e));return new Gc(r,this._parents,t,e)};var Zc=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Kc=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.pendingTransitions={},e}return Zc(e,t),e.prototype.init=function(){var t=this;this.services.events.addEventListener("model-update",(function(){t.pendingTransitions={}}))},e.prototype.getTransition=function(t,e){var n=this;if(!1===this.model.getOptions().animations||!1===e)return this.getInstantTransition(t);var r=Yc(t).duration(vn.getProperty(Nn,t,"duration")||Nn.default.duration);return this.pendingTransitions[r._id]=r,r.on("end interrupt cancel",(function(){delete n.pendingTransitions[r._id]})),r},e.prototype.getInstantTransition=function(t){var e=this,n=Yc(t).duration(0);return this.pendingTransitions[n._id]=n,n.on("end interrupt cancel",(function(){delete e.pendingTransitions[n._id]})),n},e.prototype.getPendingTransitions=function(){return this.pendingTransitions},e}(ts);function Jc(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Object.prototype.toString.call(t);return t instanceof Date||"object"==typeof t&&"[object Date]"===e?new Date(t.getTime()):"number"==typeof t||"[object Number]"===e?new Date(t):("string"!=typeof t&&"[object String]"!==e||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule"),console.warn((new Error).stack)),new Date(NaN))}function Qc(t){if(null===t||!0===t||!1===t)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function tl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Qc(e);return n.setDate(n.getDate()+r),n}function el(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t).getTime(),r=Qc(e);return new Date(n+r)}function nl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return el(t,36e5*n)}function rl(t){var e=new Date(t.getTime()),n=Math.ceil(e.getTimezoneOffset());return e.setSeconds(0,0),6e4*n+e.getTime()%6e4}function il(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Jc(t);return e.setHours(0,0,0,0),e}function ol(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=il(t),r=il(e),i=n.getTime()-rl(n),o=r.getTime()-rl(r);return Math.round((i-o)/864e5)}function al(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return el(t,6e4*n)}function sl(t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");var e=Jc(t),n=e.getFullYear(),r=e.getMonth(),i=new Date(0);return i.setFullYear(n,r+1,0),i.setHours(0,0,0,0),i.getDate()}function ul(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Qc(e),i=n.getMonth()+r,o=new Date(0);o.setFullYear(n.getFullYear(),i,1),o.setHours(0,0,0,0);var a=sl(o);return n.setMonth(i,Math.min(a,n.getDate())),n}function cl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return ul(t,12*n)}function ll(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e),i=n.getTime()-r.getTime();return i<0?-1:i>0?1:i}function hl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e),i=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return 12*i+o}function fl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e);return n.getFullYear()-r.getFullYear()}function pl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e);return n.getTime()-r.getTime()}function dl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return tl(t,-n)}function vl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return nl(t,-n)}function gl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return al(t,-n)}function yl(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return ul(t,-n)}function _l(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Qc(e);return cl(t,-n)}var ml=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),bl=require("d3-time-format/locale/en-US.json"),xl=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.scaleTypes={top:null,right:null,bottom:null,left:null},e.scales={top:null,right:null,bottom:null,left:null},e}return ml(e,t),e.prototype.getDomainAxisPosition=function(){return this.domainAxisPosition},e.prototype.getRangeAxisPosition=function(){return this.rangeAxisPosition},e.prototype.update=function(t){var e=this;this.determineOrientation(),Object.keys(s).map((function(t){return s[t]})).forEach((function(t){e.scales[t]=e.createScale(t)}))},e.prototype.determineOrientation=function(){var t=this,e=this.model.getOptions();[s.LEFT,s.BOTTOM,s.RIGHT,s.TOP].forEach((function(n){var r=vn.getProperty(e,"axes",n);if(r){var i=r.scaleType||l.LINEAR;t.scaleTypes[n]=i,i===l.LINEAR?t.rangeAxisPosition=n:t.domainAxisPosition=n}})),this.rangeAxisPosition===s.LEFT&&this.domainAxisPosition===s.BOTTOM?this.orientation=u.VERTICAL:this.orientation=u.HORIZONTAL},e.prototype.getOrientation=function(){return this.orientation},e.prototype.getScaleByPosition=function(t){return this.scales[t]},e.prototype.getScaleTypeByPosition=function(t){return this.scaleTypes[t]},e.prototype.getDomainScale=function(){return this.scales[this.domainAxisPosition]},e.prototype.getRangeScale=function(){return this.scales[this.rangeAxisPosition]},e.prototype.getMainXAxisPosition=function(){var t=[s.BOTTOM,s.TOP];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainYAxisPosition=function(){var t=[s.LEFT,s.RIGHT];return[this.domainAxisPosition,this.rangeAxisPosition].find((function(e){return t.indexOf(e)>-1}))},e.prototype.getMainXScale=function(){return this.scales[this.getMainXAxisPosition()]},e.prototype.getMainYScale=function(){return this.scales[this.getMainYAxisPosition()]},e.prototype.getValueFromScale=function(t,e,n){var r=isNaN(e)?e.value:e,i=this.scaleTypes[t],o=this.scales[t];return i===l.LABELS?o(this.model.getDisplayData().labels[n])+o.step()/2:i===l.TIME?o(new Date(e.date||e.label)):o(r)},e.prototype.getDomainValue=function(t,e){return this.getValueFromScale(this.domainAxisPosition,t,e)},e.prototype.getRangeValue=function(t,e){return this.getValueFromScale(this.rangeAxisPosition,t,e)},e.prototype.getDataFromDomain=function(t){var e=this.model.getDisplayData(),n=[];switch(this.scaleTypes[this.domainAxisPosition]){case l.LABELS:var r=e.labels.indexOf(t);e.datasets.forEach((function(t){n.push({datasetLabel:t.label,value:t.data[r]})}));break;case l.TIME:var i=Object.keys(e.datasets[0].data[0]).filter((function(t){return"value"!==t}))[0];e.datasets.forEach((function(e){var r=e.label;e.data.filter((function(e){var n=new Date(e[i]),r=new Date(t);return n.getTime()===r.getTime()})).forEach((function(t){n.push(Object.assign({datasetLabel:r,value:t.value},t))}))}))}return n},e.prototype.getScaleDomain=function(t){var e,n=this.model.getOptions(),r=vn.getProperty(n,"axes",t),i=this.model.getDisplayData(),o=i.datasets,a=i.labels;if(r&&r.scaleType===l.LABELS)return a||this.model.getDisplayData().datasets[0].data.map((function(t,e){return e+1}));if(r.stacked)e=fr(a.reduce((function(t,e,n){var r=o.map((function(t){return isNaN(t.data[n])?t.data[n].value:t.data[n]})),i=r.reduce((function(t,e){return t+e}),0);return t.concat(i,function(t,e){var n,r,i=t.length,o=-1;if(null==e){for(;++o<i;)if(null!=(n=t[o])&&n>=n)for(r=n;++o<i;)null!=(n=t[o])&&r>n&&(r=n)}else for(;++o<i;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=n;++o<i;)null!=(n=e(t[o],o,t))&&r>n&&(r=n);return r}(r))}),[]).concat(0));else{var s=o.reduce((function(t,e){return e.data.forEach((function(e){t=r.scaleType===l.TIME?t.concat(e.date):t.concat(isNaN(e)?e.value:e)})),t}),[]);r.scaleType!==l.TIME&&(s=s.concat(0)),e=fr(s)}if(r.scaleType===l.TIME){var u=vn.getProperty(n,"timeScale","addSpaceOnEdges");if(u){var c=new Date(e[0]),h=new Date(e[1]);return function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e),i=ll(n,r),o=Math.abs(fl(n,r));n.setFullYear(n.getFullYear()-i*o);var a=ll(n,r)===-i,s=i*(o-a);return 0===s?0:s}(h,c)>1?[_l(c,u),cl(h,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e),i=ll(n,r),o=Math.abs(hl(n,r));n.setMonth(n.getMonth()-i*o);var a=ll(n,r)===-i,s=i*(o-a);return 0===s?0:s}(h,c)>1?[yl(c,u),ul(h,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=Jc(t),r=Jc(e),i=ll(n,r),o=Math.abs(ol(n,r));n.setDate(n.getDate()-i*o);var a=ll(n,r)===-i,s=i*(o-a);return 0===s?0:s}(h,c)>1?[dl(c,u),tl(h,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=pl(t,e)/36e5;return n>0?Math.floor(n):Math.ceil(n)}(h,c)>1?[vl(c,u),nl(h,u)]:function(t,e){if(arguments.length<2)throw new TypeError("2 arguments required, but only "+arguments.length+" present");var n=pl(t,e)/6e4;return n>0?Math.floor(n):Math.ceil(n)}(h,c)>1?[gl(c,u),al(h,u)]:[c,h]}return[new Date(e[0]),new Date(e[1])]}return e[1]=1.1*e[1],e[0]<0&&(e[0]=1.1*e[0]),e},e.prototype.createScale=function(t){var e=this.model.getOptions(),n=vn.getProperty(e,"axes",t);if(!n)return null;var r,i=vn.getProperty(n,"scaleType")||l.LINEAR;(this.scaleTypes[t]=i,i===l.TIME)&&$a(vn.getProperty(e,"locale","time")||bl);return(r=i===l.TIME?function(){return br.apply(Ja(So,Eo,wo,bo,mo,_o,yo,go,No).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}():i===l.LOG?function t(){var e=ho(Fi()).domain([1,10]);return e.copy=function(){return Ni(e,t()).base(e.base())},br.apply(e,arguments),e}().base(n.base||10):i===l.LABELS?Cr():ro()).domain(this.getScaleDomain(t)),r},e}(ts),wl=Math.PI,Ol=2*wl,Tl=Ol-1e-6;function El(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function Sl(){return new El}function Ml(t){return function(){return t}}El.prototype=Sl.prototype={constructor:El,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,o){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+o)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var o=this._x1,a=this._y1,s=n-t,u=r-e,c=o-t,l=a-e,h=c*c+l*l;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(h>1e-6)if(Math.abs(l*s-u*c)>1e-6&&i){var f=n-o,p=r-a,d=s*s+u*u,v=f*f+p*p,g=Math.sqrt(d),y=Math.sqrt(h),_=i*Math.tan((wl-Math.acos((d+h-v)/(2*g*y)))/2),m=_/y,b=_/g;Math.abs(m-1)>1e-6&&(this._+="L"+(t+m*c)+","+(e+m*l)),this._+="A"+i+","+i+",0,0,"+ +(l*f>c*p)+","+(this._x1=t+b*s)+","+(this._y1=e+b*u)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,o){t=+t,e=+e,o=!!o;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=t+a,c=e+s,l=1^o,h=o?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+c:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-c)>1e-6)&&(this._+="L"+u+","+c),n&&(h<0&&(h=h%Ol+Ol),h>Tl?this._+="A"+n+","+n+",0,1,"+l+","+(t-a)+","+(e-s)+"A"+n+","+n+",0,1,"+l+","+(this._x1=u)+","+(this._y1=c):h>1e-6&&(this._+="A"+n+","+n+",0,"+ +(h>=wl)+","+l+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var Al=Math.abs,Pl=Math.atan2,Cl=Math.cos,Ll=Math.max,kl=Math.min,Dl=Math.sin,jl=Math.sqrt,Rl=Math.PI,Il=Rl/2,Nl=2*Rl;function Fl(t){return t>1?0:t<-1?Rl:Math.acos(t)}function Bl(t){return t>=1?Il:t<=-1?-Il:Math.asin(t)}function Vl(t){return t.innerRadius}function Ul(t){return t.outerRadius}function Hl(t){return t.startAngle}function zl(t){return t.endAngle}function Gl(t){return t&&t.padAngle}function Yl(t,e,n,r,i,o,a,s){var u=n-t,c=r-e,l=a-i,h=s-o,f=h*u-l*c;if(!(f*f<1e-12))return[t+(f=(l*(e-o)-h*(t-i))/f)*u,e+f*c]}function ql(t,e,n,r,i,o,a){var s=t-n,u=e-r,c=(a?o:-o)/jl(s*s+u*u),l=c*u,h=-c*s,f=t+l,p=e+h,d=n+l,v=r+h,g=(f+d)/2,y=(p+v)/2,_=d-f,m=v-p,b=_*_+m*m,x=i-o,w=f*v-d*p,O=(m<0?-1:1)*jl(Ll(0,x*x*b-w*w)),T=(w*m-_*O)/b,E=(-w*_-m*O)/b,S=(w*m+_*O)/b,M=(-w*_+m*O)/b,A=T-g,P=E-y,C=S-g,L=M-y;return A*A+P*P>C*C+L*L&&(T=S,E=M),{cx:T,cy:E,x01:-l,y01:-h,x11:T*(i/x-1),y11:E*(i/x-1)}}function Wl(){var t=Vl,e=Ul,n=Ml(0),r=null,i=Hl,o=zl,a=Gl,s=null;function u(){var u,c,l=+t.apply(this,arguments),h=+e.apply(this,arguments),f=i.apply(this,arguments)-Il,p=o.apply(this,arguments)-Il,d=Al(p-f),v=p>f;if(s||(s=u=Sl()),h<l&&(c=h,h=l,l=c),h>1e-12)if(d>Nl-1e-12)s.moveTo(h*Cl(f),h*Dl(f)),s.arc(0,0,h,f,p,!v),l>1e-12&&(s.moveTo(l*Cl(p),l*Dl(p)),s.arc(0,0,l,p,f,v));else{var g,y,_=f,m=p,b=f,x=p,w=d,O=d,T=a.apply(this,arguments)/2,E=T>1e-12&&(r?+r.apply(this,arguments):jl(l*l+h*h)),S=kl(Al(h-l)/2,+n.apply(this,arguments)),M=S,A=S;if(E>1e-12){var P=Bl(E/l*Dl(T)),C=Bl(E/h*Dl(T));(w-=2*P)>1e-12?(b+=P*=v?1:-1,x-=P):(w=0,b=x=(f+p)/2),(O-=2*C)>1e-12?(_+=C*=v?1:-1,m-=C):(O=0,_=m=(f+p)/2)}var L=h*Cl(_),k=h*Dl(_),D=l*Cl(x),j=l*Dl(x);if(S>1e-12){var R,I=h*Cl(m),N=h*Dl(m),F=l*Cl(b),B=l*Dl(b);if(d<Rl&&(R=Yl(L,k,F,B,I,N,D,j))){var V=L-R[0],U=k-R[1],H=I-R[0],z=N-R[1],G=1/Dl(Fl((V*H+U*z)/(jl(V*V+U*U)*jl(H*H+z*z)))/2),Y=jl(R[0]*R[0]+R[1]*R[1]);M=kl(S,(l-Y)/(G-1)),A=kl(S,(h-Y)/(G+1))}}O>1e-12?A>1e-12?(g=ql(F,B,L,k,h,A,v),y=ql(I,N,D,j,h,A,v),s.moveTo(g.cx+g.x01,g.cy+g.y01),A<S?s.arc(g.cx,g.cy,A,Pl(g.y01,g.x01),Pl(y.y01,y.x01),!v):(s.arc(g.cx,g.cy,A,Pl(g.y01,g.x01),Pl(g.y11,g.x11),!v),s.arc(0,0,h,Pl(g.cy+g.y11,g.cx+g.x11),Pl(y.cy+y.y11,y.cx+y.x11),!v),s.arc(y.cx,y.cy,A,Pl(y.y11,y.x11),Pl(y.y01,y.x01),!v))):(s.moveTo(L,k),s.arc(0,0,h,_,m,!v)):s.moveTo(L,k),l>1e-12&&w>1e-12?M>1e-12?(g=ql(D,j,I,N,l,-M,v),y=ql(L,k,F,B,l,-M,v),s.lineTo(g.cx+g.x01,g.cy+g.y01),M<S?s.arc(g.cx,g.cy,M,Pl(g.y01,g.x01),Pl(y.y01,y.x01),!v):(s.arc(g.cx,g.cy,M,Pl(g.y01,g.x01),Pl(g.y11,g.x11),!v),s.arc(0,0,l,Pl(g.cy+g.y11,g.cx+g.x11),Pl(y.cy+y.y11,y.cx+y.x11),v),s.arc(y.cx,y.cy,M,Pl(y.y11,y.x11),Pl(y.y01,y.x01),!v))):s.arc(0,0,l,x,b,v):s.lineTo(D,j)}else s.moveTo(0,0);if(s.closePath(),u)return s=null,u+""||null}return u.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-Rl/2;return[Cl(r)*n,Dl(r)*n]},u.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:Ml(+e),u):t},u.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:Ml(+t),u):e},u.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:Ml(+t),u):n},u.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:Ml(+t),u):r},u.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:Ml(+t),u):i},u.endAngle=function(t){return arguments.length?(o="function"==typeof t?t:Ml(+t),u):o},u.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:Ml(+t),u):a},u.context=function(t){return arguments.length?(s=null==t?null:t,u):s},u}function Xl(t){this._context=t}function $l(t){return new Xl(t)}function Zl(t){return t[0]}function Kl(t){return t[1]}function Jl(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function Ql(t){return t}Xl.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var th=Array.prototype.slice;function eh(){}function nh(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function rh(t){this._context=t}function ih(t){return new rh(t)}function oh(t){this._context=t}function ah(t){return new oh(t)}function sh(t){this._context=t}function uh(t){return new sh(t)}function ch(t,e){this._basis=new rh(t),this._beta=e}rh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:nh(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:nh(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},oh.prototype={areaStart:eh,areaEnd:eh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:nh(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},sh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:nh(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},ch.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],o=e[0],a=t[n]-i,s=e[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*t[u]+(1-this._beta)*(i+r*a),this._beta*e[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var lh=function t(e){function n(t){return 1===e?new rh(t):new ch(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function hh(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function fh(t,e){this._context=t,this._k=(1-e)/6}fh.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:hh(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:hh(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var ph=function t(e){function n(t){return new fh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function dh(t,e){this._context=t,this._k=(1-e)/6}dh.prototype={areaStart:eh,areaEnd:eh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:hh(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var vh=function t(e){function n(t){return new dh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function gh(t,e){this._context=t,this._k=(1-e)/6}gh.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(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:hh(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var yh=function t(e){function n(t){return new gh(t,e)}return n.tension=function(e){return t(+e)},n}(0);function _h(t,e,n){var r=t._x1,i=t._y1,o=t._x2,a=t._y2;if(t._l01_a>1e-12){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,u=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/u,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/u}if(t._l23_a>1e-12){var c=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,l=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*c+t._x1*t._l23_2a-e*t._l12_2a)/l,a=(a*c+t._y1*t._l23_2a-n*t._l12_2a)/l}t._context.bezierCurveTo(r,i,o,a,t._x2,t._y2)}function mh(t,e){this._context=t,this._alpha=e}mh.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._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:_h(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var bh=function t(e){function n(t){return e?new mh(t,e):new fh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function xh(t,e){this._context=t,this._alpha=e}xh.prototype={areaStart:eh,areaEnd:eh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:_h(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var wh=function t(e){function n(t){return e?new xh(t,e):new dh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Oh(t,e){this._context=t,this._alpha=e}Oh.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._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:_h(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Th=function t(e){function n(t){return e?new Oh(t,e):new gh(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Eh(t){this._context=t}function Sh(t){return new Eh(t)}function Mh(t){return t<0?-1:1}function Ah(t,e,n){var r=t._x1-t._x0,i=e-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),a=(n-t._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(Mh(o)+Mh(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function Ph(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function Ch(t,e,n){var r=t._x0,i=t._y0,o=t._x1,a=t._y1,s=(o-r)/3;t._context.bezierCurveTo(r+s,i+s*e,o-s,a-s*n,o,a)}function Lh(t){this._context=t}function kh(t){this._context=new Dh(t)}function Dh(t){this._context=t}function jh(t){return new Lh(t)}function Rh(t){return new kh(t)}function Ih(t){this._context=t}function Nh(t){var e,n,r=t.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,o[e]=4,a[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,o[r-1]=7,a[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/o[e-1],o[e]-=n,a[e]-=n*a[e-1];for(i[r-1]=a[r-1]/o[r-1],e=r-2;e>=0;--e)i[e]=(a[e]-i[e+1])/o[e];for(o[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)o[e]=2*t[e+1]-i[e+1];return[i,o]}function Fh(t){return new Ih(t)}function Bh(t,e){this._context=t,this._t=e}function Vh(t){return new Bh(t,.5)}function Uh(t){return new Bh(t,0)}function Hh(t){return new Bh(t,1)}function zh(t,e){if((i=t.length)>1)for(var n,r,i,o=1,a=t[e[0]],s=a.length;o<i;++o)for(r=a,a=t[e[o]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]}function Gh(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function Yh(t,e){return t[e]}Eh.prototype={areaStart:eh,areaEnd:eh,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}},Lh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Ch(this,this._t0,Ph(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,Ch(this,Ph(this,n=Ah(this,t,e)),n);break;default:Ch(this,this._t0,n=Ah(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(kh.prototype=Object.create(Lh.prototype)).point=function(t,e){Lh.prototype.point.call(this,e,t)},Dh.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,o){this._context.bezierCurveTo(e,t,r,n,o,i)}},Ih.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=Nh(t),i=Nh(e),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],t[a],e[a]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}},Bh.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&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var qh,Wh,Xh=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),$h=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.curveTypes={curveLinear:$l,curveLinearClosed:Sh,curveBasis:ih,curveBasisClosed:ah,curveBasisOpen:uh,curveBundle:lh,curveCardinal:ph,curveCardinalClosed:vh,curveCardinalOpen:yh,curveCatmullRom:bh,curveCatmullRomClosed:wh,curveCatmullRomOpen:Th,curveMonotoneX:jh,curveMonotoneY:Rh,curveNatural:Fh,curveStep:Vh,curveStepAfter:Hh,curveStepBefore:Uh},e}return Xh(e,t),e.prototype.getD3Curve=function(){var t="curveLinear",e=this.model.getOptions().curve;if(e&&(t="string"==typeof e?e:e.name),this.curveTypes[t]){var n=this.curveTypes[t];return e&&Object.keys(e).forEach((function(t){n[t]&&(n=n[t](e[t]))})),n}return console.warn("The curve type '"+t+"' is invalid, using 'curveLinear' instead"),this.curveTypes.curveLinear},e}(ts),Zh=function(){function t(t,e,n){this.configs={},this.model=t,this.services=e,n&&(this.configs=n),this.parent||this.setParent(lu(this.services.domUtils.getMainSVG()))}return t.prototype.init=function(){},t.prototype.render=function(t){console.error("render() method is not implemented")},t.prototype.destroy=function(){},t.prototype.setModel=function(t){this.model=t},t.prototype.setServices=function(t){this.services=t},t.prototype.setParent=function(t){var e=this.parent;if(this.parent=t,(!e||e.node()!==t.node())&&this.type){var n=vn.getProperty(this.model.getOptions(),"style","prefix");this.parent.classed(pu.prefix+"--"+n+"--"+this.type,!0),e&&e.classed(pu.prefix+"--"+n+"--"+this.type,!1)}},t.prototype.getParent=function(){return this.parent},t.prototype.getContainerSVG=function(){if(this.type){var t=vn.getProperty(this.model.getOptions(),"style","prefix");return Fu.appendOrSelect(this.parent,"g."+pu.prefix+"--"+t+"--"+this.type)}return this.parent},t}(),Kh=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Jh=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="legend",e}return Kh(n,t),n.prototype.render=function(){var t=this,n=this.getContainerSVG().attr("role",e.GRAPHICS_DOCUMENT),r=this.model.getOptions(),i=n.selectAll("g.legend-item").data(this.getLegendItemArray()),o=i.enter().append("g").classed("legend-item",!0),a=r.legend.checkbox.radius;o.append("rect").classed("checkbox",!0).merge(i.select("rect.checkbox")).attr("width",2*a).attr("height",2*a).attr("rx",1).attr("ry",1).style("fill",(function(e){return e.value===r.legend.items.status.ACTIVE?t.model.getStrokeColor(e.key):null})).classed("active",(function(t,e){return t.value===r.legend.items.status.ACTIVE})),o.append("text").merge(i.select("text")).text((function(t){return t.key})).attr("alignment-baseline","middle"),this.breakItemsIntoLines(o),i.exit().on("mouseover",null).on("click",null).on("mouseout",null).remove();var s=vn.getProperty(this.model.getOptions(),"legend","clickable");n.classed("clickable",s),s&&o.size()>0&&this.addEventListeners()},n.prototype.breakItemsIntoLines=function(t){var e,n=this,r=this.getContainerSVG(),i=this.model.getOptions(),o=i.legend.checkbox.radius,a=i.legend.items.horizontalSpace,s=i.legend.items.verticalSpace,u=i.legend.items.textYOffset,c=2*o+i.legend.checkbox.spaceAfter,l=i.legend.items.status.DISABLED,h=this.model.get("dataLabels"),f=Object.keys(h).some((function(t){return h[t]===l})),p=vn.getProperty(i,"legend","orientation"),v=0,g=0,y=0;t.merge(r.selectAll("g.legend-item")).each((function(t,i){var l=lu(this),h=lu(r.selectAll("g.legend-item").nodes()[i-1]);if(0===y||h.empty()||p===d.VERTICAL)p===d.VERTICAL&&0!==i&&g++;else{var _=Fu.getSVGElementSize(n.parent,{useAttr:!0}),m=Fu.getSVGElementSize(lu(this).select("text"),{useBBox:!0}),b=Fu.getSVGElementSize(h.select("text"),{useBBox:!0});(v=v+b.width+c+a)+c+m.width>_.width&&(g++,v=0,y=0)}l.select("rect.checkbox").attr("x",v).attr("y",0+g*s);var x=u+g*s;l.select("text").attr("x",v+c).attr("y",0+x),e=x,f&&l.select("g.check").empty()?(l.append("g").classed("check",!0).html('\n\t\t\t\t\t\t\t<svg focusable="false" preserveAspectRatio="xMidYMid meet"\n\t\t\t\t\t\t\t\txmlns="http://www.w3.org/2000/svg" width="32" height="32"\n\t\t\t\t\t\t\t\tviewBox="0 0 32 32" aria-hidden="true"\n\t\t\t\t\t\t\t\tstyle="will-change: transform;">\n\t\t\t\t\t\t\t\t<path d="M13 21.2l-7.1-7.1-1.4 1.4 7.1 7.1L13 24 27.1 9.9l-1.4-1.5z"></path>\n\t\t\t\t\t\t\t\t<title>Checkmark</title>\n\t\t\t\t\t\t\t</svg>\n\t\t\t\t\t\t'),l.select("g.check svg").attr("width",2*o-1).attr("height",2*o-1).attr("x",parseFloat(l.select("rect.checkbox").attr("x"))+.5).attr("y",parseFloat(l.select("rect.checkbox").attr("y"))+.5)):f||l.select("g.check").empty()||l.select("g.check").remove(),y++})),Fu.appendOrSelect(r,"rect.spacer").attr("x",0).attr("y",e).attr("width",16).attr("height",16).attr("fill","none")},n.prototype.getLegendItemArray=function(){var t=this.model.get("dataLabels");return Object.keys(t).map((function(e){return{key:e,value:t[e]}}))},n.prototype.addEventListeners=function(){var t=this,e=this.getContainerSVG(),n=this.model.getOptions();e.selectAll("g.legend-item").on("mouseover",(function(){t.services.events.dispatchEvent("legend-item-onhover",{hoveredElement:lu(this)});var e=n.legend.checkbox.radius,r=lu(this);r.append("rect").classed("hover-stroke",!0).attr("x",parseFloat(r.select("rect.checkbox").attr("x"))-2).attr("y",parseFloat(r.select("rect.checkbox").attr("y"))-2).attr("width",2*e+4).attr("height",2*e+4).attr("rx",3).attr("ry",3).lower()})).on("click",(function(){t.services.events.dispatchEvent("legend-item-onclick",{clickedElement:lu(this)});var e=lu(this).datum();t.model.toggleDataLabel(e.key)})).on("mouseout",(function(){var e=lu(this);e.select("rect.hover-stroke").remove(),t.services.events.dispatchEvent("legend-item-onmouseout",{hoveredElement:e})}))},n}(Zh),Qh=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tf=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="title",e}return Qh(e,t),e.prototype.truncateTitle=function(){var t=Fu.getSVGElementSize(this.services.domUtils.getMainSVG(),{useAttr:!0}).width,e=Fu.appendOrSelect(this.parent,"text.title");if(!(t<=0)&&e.node().getComputedTextLength()>t){e.append("tspan").text("...");var n=Fu.appendOrSelect(e,"tspan").node().getComputedTextLength(),r=Math.floor(t-n),i=this.model.getOptions().title,o=this.getSubstringIndex(e.node(),0,i.length-1,r);e.text(i.substring(0,o-1)).append("tspan").text("...");var a=this;e.on("mouseenter",(function(){a.services.events.dispatchEvent("show-tooltip",{hoveredElement:e,type:f.TITLE})})).on("mouseout",(function(){a.services.events.dispatchEvent("hide-tooltip",{hoveredElement:e})}))}},e.prototype.render=function(){var t=this.getContainerSVG();Fu.appendOrSelect(t,"text.title").attr("x",0).attr("y",20).text(this.model.getOptions().title),this.truncateTitle()},e.prototype.getSubstringIndex=function(t,e,n,r){var i=Math.floor((n+e)/2);return t.getSubStringLength(0,i)>r?this.getSubstringIndex(t,e,i,r):t.getSubStringLength(0,i)<r?t.getSubStringLength(0,i+1)>r?i:this.getSubstringIndex(t,i,n,r):i},e}(Zh);!function(t){t.LEFT="left",t.RIGHT="right",t.TOP="top",t.BOTTOM="bottom"}(Wh||(Wh={}));var ef=((qh={})[Wh.LEFT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left-e.offsetWidth)}},qh[Wh.RIGHT]=function(t,e,n){return{top:t.top-Math.round(e.offsetHeight/2)+Math.round(n.height/2),left:Math.round(t.left+n.width)}},qh[Wh.TOP]=function(t,e,n){return{top:Math.round(t.top-e.offsetHeight),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},qh[Wh.BOTTOM]=function(t,e,n){return{top:Math.round(t.top+n.height),left:t.left-Math.round(e.offsetWidth/2)+Math.round(n.width/2)}},qh),nf="undefined"!=typeof window?window:{innerHeight:0,scrollY:0,innerWidth:0,scrollX:0},rf=function(){function t(t){void 0===t&&(t={}),this.positions=ef,this.positions=Object.assign({},ef,t)}return t.prototype.getRelativeOffset=function(t){for(var e={left:t.offsetLeft,top:t.offsetTop};t.offsetParent&&"static"===getComputedStyle(t.offsetParent).position;)e.left+=t.offsetLeft,e.top+=t.offsetTop,t=t.offsetParent;return e},t.prototype.getAbsoluteOffset=function(t){for(var e=t,n={top:0,left:0};e.offsetParent;){var r=getComputedStyle(e.offsetParent);"static"===r.position&&r.marginLeft&&r.marginTop&&(parseInt(r.marginTop,10)&&(n.top+=parseInt(r.marginTop,10)),parseInt(r.marginLeft,10)&&(n.left+=parseInt(r.marginLeft,10))),e=e.offsetParent}var i=t.getBoundingClientRect(),o=document.body.getBoundingClientRect();return{top:i.top-o.top+n.top,left:i.left-o.left+n.left}},t.prototype.findRelative=function(t,e,n){var r=this.getRelativeOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findAbsolute=function(t,e,n){var r=this.getAbsoluteOffset(t),i=t.getBoundingClientRect();return this.calculatePosition(r,i,e,n)},t.prototype.findPosition=function(t,e,n,r){void 0===r&&(r=this.getAbsoluteOffset);var i=r(t),o=t.getBoundingClientRect();return this.calculatePosition(i,o,e,n)},t.prototype.findPositionAt=function(t,e,n){return this.calculatePosition(t,{height:0,width:0},e,n)},t.prototype.getPlacementBox=function(t,e){var n=t.offsetHeight+e.top,r=t.offsetWidth+e.left;return{top:e.top,bottom:n,left:e.left,right:r}},t.prototype.addOffset=function(t,e,n){return void 0===e&&(e=0),void 0===n&&(n=0),Object.assign({},t,{top:t.top+e,left:t.left+n})},t.prototype.setElement=function(t,e){t.style.top=e.top+"px",t.style.left=e.left+"px"},t.prototype.findBestPlacement=function(t,e,n,r,i){var o=this;void 0===r&&(r=this.defaultContainerFunction),void 0===i&&(i=this.findPosition);var a=n.map((function(n){var a=i(t,e,n),s=o.getPlacementBox(e,a),u=s.bottom-r().height,c=s.right-r().width;u=u<0?e.offsetHeight:u,c=c<0?e.offsetWidth:c;var l=e.offsetHeight*e.offsetWidth,h=l-u*c;return{placement:n,weight:(h=0===h?l:h)/l}}));return a.sort((function(t,e){return e.weight-t.weight})),a[0].placement},t.prototype.findBestPlacementAt=function(t,e,n,r){var i=this;void 0===r&&(r=this.defaultContainerFunction);return this.findBestPlacement(null,e,n,r,(function(e,n,r){return i.findPositionAt(t,n,r)}))},t.prototype.defaultContainerFunction=function(){return{width:nf.innerHeight-nf.scrollY,height:nf.innerWidth-nf.scrollX}},t.prototype.calculatePosition=function(t,e,n,r){return this.positions[r]?this.positions[r](t,n,e):(console.error("No function found for placement, defaulting to 0,0"),{left:0,top:0})},t}(),of=(new rf,function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}()),af=function(t){function e(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="tooltip",i.positionService=new rf,i.init(),i}return of(e,t),e.prototype.init=function(){var t=this,e=lu(this.services.domUtils.getHolder()),n=vn.getProperty(this.model.getOptions(),"style","prefix");this.tooltip=Fu.appendOrSelect(e,"div."+pu.prefix+"--"+n+"--tooltip");var r=Fu.appendOrSelect(this.tooltip,"div.content-box");this.tooltip.style("max-width",null),this.services.events.addEventListener("show-tooltip",(function(i){if(i.detail.type===f.DATAPOINT&&vn.getProperty(t.model.getOptions(),"tooltip","datapoint","enabled")||i.detail.type===f.GRIDLINE&&vn.getProperty(t.model.getOptions(),"tooltip","gridline","enabled")){var o=lu(Js.target).datum(),a=void 0;i.detail.multidata?(o=i.detail.multidata,a=t.getMultilineTooltipHTML(o)):a=t.getTooltipHTML(o,f.DATAPOINT),vn.getProperty(t.model.getOptions(),"tooltip","customHTML")?r.html(t.model.getOptions().tooltip.customHTML(o,a)):r.html(a),t.positionTooltip()}else if(i.detail.type===f.TITLE){var s=Fu.appendOrSelect(e,"svg."+pu.prefix+"--"+n+"--chart-svg"),u=Fu.getSVGElementSize(s).width*vn.getProperty(t.model.getOptions(),"tooltip","title","width");t.tooltip.style("max-width",u),r.html(t.getTooltipHTML(i.detail.hoveredElement,f.TITLE));var c=t.getTooltipPosition(i.detail.hoveredElement.node());t.positionTooltip(c)}t.tooltip.classed("hidden",!1)})),this.services.events.addEventListener("hide-tooltip",(function(){t.tooltip.classed("hidden",!0)}))},e.prototype.getTooltipHTML=function(t,e){if(e===f.TITLE)return'<div class="title-tooltip"><text>'+this.model.getOptions().title+"</text></div>";var n=vn.getProperty(t,"data")?t.data:t,r=vn.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(n.value):n.value.toLocaleString("en");return'<div class="datapoint-tooltip">\n\t\t\t\t\t<p class="label">'+(n.datasetLabel?n.datasetLabel:n.label)+'</p>\n\t\t\t\t\t<p class="value">'+r+"</p>\n\t\t\t\t</div>"},e.prototype.getMultilineTooltipHTML=function(t){var e=this,n=t;n.sort((function(t,e){return e.value-t.value}));var r=this.services.cartesianScales.getDomainScale().scaleType;return"<ul class='multi-tooltip'>"+n.map((function(t){var n=t.value;n instanceof Object&&(n=r===l.TIME?t.value.date:t.value.value);var i=vn.getProperty(e.model.getOptions(),"tooltip","valueFormatter")?e.model.getOptions().tooltip.valueFormatter(n):n.toLocaleString("en");return'\n\t\t\t\t<li>\n\t\t\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t\t\t<a style="background-color:'+e.model.getStrokeColor(t.datasetLabel,t.label)+'" class="tooltip-color"></a>\n\t\t\t\t\t\t<p class="label">'+t.datasetLabel+'</p>\n\t\t\t\t\t\t<p class="value">'+i+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"</ul>"},e.prototype.render=function(){this.tooltip.classed("hidden",!0)},e.prototype.getTooltipPosition=function(t){var e=lu(this.services.domUtils.getHolder()).node().getBoundingClientRect(),n=t.getBoundingClientRect(),r=this.model.getOptions().tooltip.title.verticalOffset,i={left:n.left-e.left+n.width/2,top:n.top-e.top-r};return{placement:h.BOTTOM,position:i}},e.prototype.positionTooltip=function(t){var e,n=this.services.domUtils.getHolder(),r=this.tooltip.node(),i=fu(n);if(t){var o=t.placement===h.TOP?Wh.TOP:Wh.BOTTOM;e=this.positionService.findPositionAt(t.position,r,o)}else{var a=this.positionService.findBestPlacementAt({left:i[0],top:i[1]},r,[Wh.RIGHT,Wh.LEFT,Wh.TOP,Wh.BOTTOM],(function(){return{width:n.offsetWidth,height:n.offsetHeight}})),s=this.model.getOptions().tooltip.datapoint.horizontalOffset;a===Wh.LEFT&&(s*=-1),e=this.positionService.findPositionAt({left:i[0]+s,top:i[1]},r,a)}this.positionService.setElement(r,e)},e}(Zh),sf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),uf=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return sf(e,t),e.prototype.init=function(){var e=this,n=lu(this.services.domUtils.getHolder()),r=vn.getProperty(this.model.getOptions(),"style","prefix");this.tooltip=Fu.appendOrSelect(n,"div."+pu.prefix+"--"+r+"--tooltip");var i=Fu.appendOrSelect(this.tooltip,"div.content-box");this.tooltip.style("max-width",null),this.services.events.addEventListener("show-tooltip",(function(o){if(o.detail.type===f.DATAPOINT&&vn.getProperty(e.model.getOptions(),"tooltip","datapoint","enabled")||o.detail.type===f.GRIDLINE&&vn.getProperty(e.model.getOptions(),"tooltip","gridline","enabled")){var a=o.detail.hoveredElement.datum(),s=o.detail.hoveredElement.node(),u=void 0;o.detail.multidata?(a=o.detail.multidata,u=e.getMultilineTooltipHTML(a)):u=e.getTooltipHTML(o.detail.hoveredElement.datum()),vn.getProperty(e.model.getOptions(),"tooltip","customHTML")?i.html(e.model.getOptions().tooltip.customHTML(a,u)):i.html(u);var c=e.getTooltipPosition(s);e.positionTooltip(o.detail.multidata?void 0:c)}else if(o.detail.type===f.TITLE){var l=Fu.appendOrSelect(n,"svg."+pu.prefix+"--"+r+"--chart-svg"),h=Fu.getSVGElementSize(l).width*vn.getProperty(e.model.getOptions(),"tooltip","title","width");e.tooltip.style("max-width",h),i.html(t.prototype.getTooltipHTML.call(e,o.detail.hoveredElement,f.TITLE));c=t.prototype.getTooltipPosition.call(e,o.detail.hoveredElement.node());e.positionTooltip(c)}e.tooltip.classed("hidden",!1)})),this.services.events.addEventListener("hide-tooltip",(function(){e.tooltip.classed("hidden",!0)}))},e.prototype.getTooltipPosition=function(t){var e=lu(t).datum(),n=lu(this.services.domUtils.getHolder()).node().getBoundingClientRect(),r=t.getBoundingClientRect(),i=this.model.getOptions().tooltip.datapoint.verticalOffset;if(e.value<=0){var o={left:r.left-n.left+r.width/2,top:r.bottom-n.top+i};return{placement:h.BOTTOM,position:o}}o={left:r.left-n.left+r.width/2,top:r.top-n.top-i};return{placement:h.TOP,position:o}},e.prototype.getTooltipHTML=function(t){return'<div class="datapoint-tooltip"><p class="value">'+(vn.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(t.value):t.value.toLocaleString("en"))+"</p></div>"},e.prototype.getMultilineTooltipHTML=function(t){var e=this,n=t;n.reverse(),this.services.cartesianScales.getOrientation()===u.VERTICAL&&n.reverse();var r=n.reduce((function(t,e){return t+e.value}),0);return r=vn.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(r):r.toLocaleString("en"),"<ul class='multi-tooltip'>"+n.map((function(t){var n=vn.getProperty(e.model.getOptions(),"tooltip","valueFormatter")?e.model.getOptions().tooltip.valueFormatter(t.value):t.value.toLocaleString("en");return'\n\t\t\t\t<li>\n\t\t\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t\t\t<a style="background-color:'+e.model.getStrokeColor(t.datasetLabel,t.label)+'" class="tooltip-color"></a>\n\t\t\t\t\t\t<p class="label">'+t.datasetLabel+'</p>\n\t\t\t\t\t\t<p class="value">'+n+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>"})).join("")+"<li>\n\t\t\t\t\t<div class='total-val'>\n\t\t\t\t\t\t<p class='label'>Total</p>\n\t\t\t\t\t\t<p class='value'>"+r+"</p>\n\t\t\t\t\t</div>\n\t\t\t\t</li>\n\t\t\t</ul>"},e}(af),cf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),lf=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return cf(e,t),e.prototype.getTooltipHTML=function(e,n){if(n===f.TITLE)return t.prototype.getTooltipHTML.call(this,e,n);var r=vn.getProperty(this.model.getOptions(),"tooltip","valueFormatter")?this.model.getOptions().tooltip.valueFormatter(e.value):e.value.toLocaleString("en");return'\n\t\t\t<div class="datapoint-tooltip">\n\t\t\t\t<a style="background-color:'+this.model.getStrokeColor(e.datasetLabel,e.label)+'" class="tooltip-color"></a>\n\t\t\t\t<p class="label">'+e.datasetLabel+'</p>\n\t\t\t\t<p class="value">'+r+"</p>\n\t\t\t</div>"},e}(af),hf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ff=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return hf(e,t),e.prototype.getBarWidth=function(){var t=this.model.getOptions(),e=this.services.cartesianScales.getMainXScale();return e.step?Math.min(t.bars.maxWidth,e.step()/2):Math.min(t.bars.maxWidth,5/e.ticks().length*t.bars.maxWidth)},e}(Zh),pf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),df=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="simple-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-simple-bar")).attr("opacity",(function(t){return t.label!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-simple-bar")).attr("opacity",1)},e}return pf(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.render=function(t){var n=this,r=this.getContainerSVG().selectAll("g.bars").data(this.model.getDisplayData().datasets,(function(t){return t.label}));r.exit().attr("opacity",0).remove();var i=r.enter().append("g").classed("bars",!0).attr("role",e.GROUP).merge(r).selectAll("path.bar").data((function(t,e){return n.addLabelsToDataPoints(t,e)}),(function(t){return t.label}));i.exit().attr("opacity",0).remove(),i.enter().append("path").attr("opacity",0).merge(i).classed("bar",!0).attr("width",this.getBarWidth.bind(this)).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()(t.label)})).attr("d",(function(t,e){var r=n.getBarWidth(),i=n.services.cartesianScales.getDomainValue(t,e)-r/2,o=i+r,a=n.services.cartesianScales.getRangeValue(0),s=n.services.cartesianScales.getRangeValue(t,e);return vn.generateSVGPathString({x0:i,x1:o,y0:a,y1:s},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getDisplayData().labels;return t.data.map((function(e,r){return{date:e.date,label:n[r],datasetLabel:t.label,value:isNaN(e)?e.value:e}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=lu(this);n.classed("hovered",!0),n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",Wr(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOVER,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:f.DATAPOINT})})).on("mousemove",(function(e){t.services.events.dispatchEvent(_.Bar.BAR_MOUSEMOVE,{element:lu(this),datum:e})})).on("click",(function(e){t.services.events.dispatchEvent(_.Bar.BAR_CLICK,{element:lu(this),datum:e})})).on("mouseout",(function(e){var n=lu(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()(e.label)})),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(ff),vf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),gf=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grouped-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return vf(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getGroupWidth=function(){var t=this.model.getDisplayData().datasets;return t.length*this.getBarWidth()+5*(t.length-1)},n.prototype.setGroupScale=function(){var t=this.model.getDisplayData().datasets;this.groupScale=Cr().domain(t.map((function(t){return t.label}))).rangeRound([0,this.getGroupWidth()])},n.prototype.getBarWidth=function(){var e=this.model.getDisplayData().datasets,n=this.services.cartesianScales.getDomainScale();return Math.min(n.step()/2/e.length,t.prototype.getBarWidth.call(this))},n.prototype.render=function(t){var n=this,r=this.model.getDisplayData();this.setGroupScale();var i=this.getContainerSVG().selectAll("g.bars").data(r.labels);i.exit().attr("opacity",0).remove();var o=i.enter().append("g").classed("bars",!0).attr("role",e.GROUP).attr("aria-labelledby",(function(t){return t})).merge(i).attr("transform",(function(t,e){var r=n.services.cartesianScales.getDomainValue(t,e)-n.getGroupWidth()/2+n.getBarWidth();return n.services.cartesianScales.getOrientation()===u.VERTICAL?"translate("+r+", 0)":"translate(0, "+r+")"})).selectAll("path.bar").data((function(t,e){return n.addLabelsToDataPoints(t,e)}));o.exit().attr("opacity",0).remove(),o.enter().append("path").attr("opacity",0).merge(o).classed("bar",!0).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("d",(function(t){var e=n.groupScale(t.datasetLabel),r=n.getBarWidth(),i=e-r/2,o=e+r/2,a=n.services.cartesianScales.getRangeValue(0),s=n.services.cartesianScales.getRangeValue(t.value);return vn.generateSVGPathString({x0:i,x1:o,y0:a,y1:s},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){return this.model.getDisplayData().datasets.map((function(n){return{label:t,datasetLabel:n.label,value:n.data[e].value?n.data[e].value:n.data[e]}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=lu(this);n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",Wr(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOVER,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:f.DATAPOINT})})).on("mousemove",(function(e){t.services.events.dispatchEvent(_.Bar.BAR_MOUSEMOVE,{element:lu(this),datum:e})})).on("click",(function(e){t.services.events.dispatchEvent(_.Bar.BAR_CLICK,{element:lu(this),datum:e})})).on("mouseout",(function(e){var n=lu(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()[e.datasetLabel](e.label)})),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(ff),yf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),_f=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="stacked-bar",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.bar").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return yf(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getStackData=function(){var t,e=this.model.getDisplayData(),n=this.services.cartesianScales.getDomainAxisPosition();if(this.services.cartesianScales.getScaleTypeByPosition(n)===l.TIME){var r=[];e.datasets.forEach((function(t){r=r.concat(t.data.map((function(t){return Number(t.date)})))})),t=(r=vn.removeArrayDuplicates(r).sort()).map((function(t,n){var r={};return e.datasets.forEach((function(e){var n=e.data.find((function(e){return Number(e.date)===Number(t)}));r[e.label]=n?n.value:0})),r.label=t,r}))}else t=e.labels.map((function(t,n){var r={};return e.datasets.forEach((function(t){r[t.label]=isNaN(t.data[n])?t.data[n].value:t.data[n]})),r.label=t,r}));return t},n.prototype.render=function(t){var n=this,r=this.model.getOptions(),i=this.getContainerSVG(),o=this.model.getDisplayData(),a=this.getStackData(),s=o.datasets.map((function(t){return t.label})),c=i.selectAll("g.bars").data(function(){var t=Ml([]),e=Gh,n=zh,r=Yh;function i(i){var o,a,s=t.apply(this,arguments),u=i.length,c=s.length,l=new Array(c);for(o=0;o<c;++o){for(var h,f=s[o],p=l[o]=new Array(u),d=0;d<u;++d)p[d]=h=[0,+r(i[d],f,d,i)],h.data=i[d];p.key=f}for(o=0,a=e(l);o<c;++o)l[a[o]].index=o;return n(l,a),l}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:Ml(th.call(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:Ml(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?Gh:"function"==typeof t?t:Ml(th.call(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?zh:t,i):n},i}().keys(s)(a),(function(t){return t.key}));c.exit().attr("opacity",0).remove(),c.enter().append("g").classed("bars",!0).attr("role",e.GROUP);var h=i.selectAll("g.bars").selectAll("path.bar").data((function(t){return function(t){return Object.keys(t).map((function(e){"object"==typeof t[e]&&(t[e].datasetLabel=t.key,t[e].label=t[e].data.label,t[e].value=t[e].data[t.key])})),t}(t)}),(function(t){return t.label}));h.exit().remove();var f=this.services.cartesianScales.getRangeScale();h.enter().append("path").merge(h).classed("bar",!0).transition(this.services.transitions.getTransition("bar-update-enter",t)).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("height",(function(t,e){var i,o=t.datasetLabel,a=s.indexOf(o);return i=f.scaleType===l.LABELS?Math.abs(f.scale.range()[0]-n.services.cartesianScales.getRangeValue(t.label,e)):n.services.cartesianScales.getRangeValue(t[0])-n.services.cartesianScales.getRangeValue(t[1]),a>0&&i>=r.bars.dividerSize?i-r.bars.dividerSize:i})).attr("d",(function(t,e){var i=n.getBarWidth(),o=n.services.cartesianScales.getDomainValue(t,e)-i/2,a=o+i,s=n.services.cartesianScales.getRangeValue(t[0],e),c=n.services.cartesianScales.getRangeValue(t[1],e);return Math.abs(c-s)>0&&Math.abs(c-s)>r.bars.dividerSize&&(n.services.cartesianScales.getOrientation()===u.VERTICAL?c+=1:c-=1),vn.generateSVGPathString({x0:o,x1:a,y0:s,y1:c},n.services.cartesianScales.getOrientation())})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","bar").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.bar").on("mouseover",(function(e){var n=lu(this);n.transition(t.services.transitions.getTransition("graph_element_mouseover_fill_update")).attr("fill",Wr(n.attr("fill")).darker(.7).toString()),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOVER,{element:n,datum:e})})).on("mousemove",(function(e){var n=lu(this),r=lu(this).datum();n.classed("hovered",!0);var i=r.data,o=i.label;delete i.label;var a=Object.keys(i).map((function(t){return{datasetLabel:t,value:i[t],label:o}}));t.services.events.dispatchEvent(_.Bar.BAR_MOUSEMOVE,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{multidata:a,hoveredElement:n,type:f.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(_.Bar.BAR_CLICK,{element:lu(this),datum:e})})).on("mouseout",(function(e){var n=lu(this);n.classed("hovered",!1),n.transition(t.services.transitions.getTransition("graph_element_mouseout_fill_update")).attr("fill",(function(e){return t.model.getFillScale()[e.datasetLabel](e.label)})),t.services.events.dispatchEvent(_.Bar.BAR_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("path.bar").on("mouseover",null).on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(ff),mf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),bf=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="scatter",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("circle.dot").transition(e.services.transitions.getTransition("legend-hover-scatter")).attr("opacity",(function(t){return t.datasetLabel!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("circle.dot").transition(e.services.transitions.getTransition("legend-mouseout-scatter")).attr("opacity",1)},e}return mf(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.render=function(t){var n=this,r=(this.model.getOptions(),this.getContainerSVG().selectAll("g.dots").data(this.model.getDisplayData().datasets,(function(t){return t.label})));r.exit().attr("opacity",0).remove();var i=r.enter().append("g").classed("dots",!0).attr("role",e.GROUP).merge(r).selectAll("circle.dot").data((function(t,e){return n.addLabelsToDataPoints(t,e)})),o=i.enter().append("circle").attr("opacity",0).merge(i);this.styleCircles(o,t),this.addEventListeners()},n.prototype.styleCircles=function(t,n){var r=this,i=this.model.getOptions(),o=i.points.filled;t.raise().classed("dot",!0).classed("filled",(function(t){return r.model.getIsFilled(t.datasetLabel,t.label,t,o)})).classed("unfilled",(function(t){return!r.model.getIsFilled(t.datasetLabel,t.label,t,o)})).attr("cx",(function(t,e){return r.services.cartesianScales.getDomainValue(t,e)})).transition(this.services.transitions.getTransition("scatter-update-enter",n)).attr("cy",(function(t,e){return r.services.cartesianScales.getRangeValue(t,e)})).attr("r",i.points.radius).attr("fill",(function(t){if(r.model.getIsFilled(t.datasetLabel,t.label,t,o))return r.model.getFillColor(t.datasetLabel,t.label,t)})).attr("fill-opacity",o?.2:1).attr("stroke",(function(t){return r.model.getStrokeColor(t.datasetLabel,t.label,t)})).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","point").attr("aria-label",(function(t){return t.value})),this.addEventListeners()},n.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getDisplayData().labels;return t.data.map((function(e,r){return{date:e.date,label:n[r],datasetLabel:t.label,class:e.class,value:isNaN(e)?e.value:e}}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("circle").on("mouseover mousemove",(function(e){var n=lu(this);n.classed("hovered",!0).style("fill",(function(e){return t.model.getFillColor(e.datasetLabel,e.label,e)}));var r="mouseover"===Js.type?_.Scatter.SCATTER_MOUSEOVER:_.Scatter.SCATTER_MOUSEMOVE;t.services.events.dispatchEvent(r,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:f.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(_.Scatter.SCATTER_CLICK,{element:lu(this),datum:e})})).on("mouseout",(function(e){var n=lu(this);n.classed("hovered",!1),t.configs.filled||n.style("fill",null),t.services.events.dispatchEvent(_.Scatter.SCATTER_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.destroy=function(){this.parent.selectAll("circle").on("mousemove",null).on("mouseout",null);var t=this.services.events;t.removeEventListener("legend-item-onhover",this.handleLegendOnHover),t.removeEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n}(Zh),xf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),wf=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bubble",e}return xf(e,t),e.prototype.getRadiusScale=function(t){var e=t.data(),n=e.map((function(t){return t.radius})).filter((function(t){return t})),r=this.model.getOptions(),i=Fu.getSVGElementSize(this.services.domUtils.getMainSVG(),{useAttr:!0});return ro().domain(fr(n)).range(r.bubble.radiusRange(i,e))},e.prototype.styleCircles=function(t,e){var n=this,r=this.model.getOptions(),i=this.getRadiusScale(t);t.raise().classed("dot",!0).attr("cx",(function(t,e){return n.services.cartesianScales.getDomainValue(t,e)})).transition(this.services.transitions.getTransition("bubble-update-enter",e)).attr("cy",(function(t,e){return n.services.cartesianScales.getRangeValue(t,e)})).attr("r",(function(t){return i(t.radius)})).attr("fill",(function(t){return n.model.getFillScale()[t.datasetLabel](t.label)})).attr("fill-opacity",r.bubble.fillOpacity).attr("stroke",(function(t){return n.model.getStrokeColor(t.datasetLabel,t.label,t.value)})).attr("opacity",1)},e.prototype.addLabelsToDataPoints=function(t,e){var n=this.model.getOptions(),r=this.model.getDisplayData().labels;return t.data.map((function(e,i){return{date:e.date,label:r[i],datasetLabel:t.label,value:isNaN(e)?e.value:e,radius:e.radius||n.points.radius}}))},e}(bf),Of=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Tf=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e}return Of(n,t),n.prototype.init=function(){var t=this;this.services.events.addEventListener("legend-item-onhover",(function(e){var n=e.detail.hoveredElement;t.parent.selectAll("g.lines").transition(t.services.transitions.getTransition("legend-hover-line")).attr("opacity",(function(t){return t.label!==n.datum().key?In.opacity.unselected:In.opacity.selected}))})),this.services.events.addEventListener("legend-item-onmouseout",(function(e){t.parent.selectAll("g.lines").transition(t.services.transitions.getTransition("legend-mouseout-line")).attr("opacity",In.opacity.selected)}))},n.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this.getContainerSVG();this.lineGenerator=function(){var t=Zl,e=Kl,n=Ml(!0),r=null,i=$l,o=null;function a(a){var s,u,c,l=a.length,h=!1;for(null==r&&(o=i(c=Sl())),s=0;s<=l;++s)!(s<l&&n(u=a[s],s,a))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+t(u,s,a),+e(u,s,a));if(c)return o=null,c+""||null}return a.x=function(e){return arguments.length?(t="function"==typeof e?e:Ml(+e),a):t},a.y=function(t){return arguments.length?(e="function"==typeof t?t:Ml(+t),a):e},a.defined=function(t){return arguments.length?(n="function"==typeof t?t:Ml(!!t),a):n},a.curve=function(t){return arguments.length?(i=t,null!=r&&(o=i(r)),a):i},a.context=function(t){return arguments.length?(null==t?r=o=null:o=i(r=t),a):r},a}().x((function(t,e){return n.services.cartesianScales.getDomainValue(t,e)})).y((function(t,e){return n.services.cartesianScales.getRangeValue(t,e)})).curve(this.services.curves.getD3Curve());var i=r.selectAll("g.lines").data(this.model.getDisplayData().datasets,(function(t){return t.label}));i.exit().attr("opacity",0).remove();var o=i.enter().append("g").classed("lines",!0),a=this;o.append("path").attr("opacity",0).merge(r.selectAll("g.lines path")).attr("stroke",(function(t){var e=lu(this.parentNode).datum();return a.model.getStrokeColor(e.label)})).datum((function(t){var e=lu(this.parentNode).datum();return this._datasetLabel=e.label,e.data})).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","line").attr("aria-label",(function(t){return t.map((function(t){return t.value||t})).join(",")})).transition(this.services.transitions.getTransition("line-update-enter",t)).attr("opacity",1).attr("class","line").attr("d",this.lineGenerator)},n}(Zh),Ef=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();function Sf(t,e){var n=this,r=_i(this._current,t);return function(t){return n._current=r(t),e(n._current)}}var Mf=function(t){function n(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="pie",e.handleLegendOnHover=function(t){var n=t.detail.hoveredElement;e.parent.selectAll("path.slice").transition(e.services.transitions.getTransition("legend-hover-bar")).attr("opacity",(function(t){return t.data.label!==n.datum().key?.3:1}))},e.handleLegendMouseOut=function(t){e.parent.selectAll("path.slice").transition(e.services.transitions.getTransition("legend-mouseout-bar")).attr("opacity",1)},e}return Ef(n,t),n.prototype.init=function(){var t=this.services.events;t.addEventListener("legend-item-onhover",this.handleLegendOnHover),t.addEventListener("legend-item-onmouseout",this.handleLegendMouseOut)},n.prototype.getDataList=function(){var t=this.model.getDisplayData();return t.datasets[0].data.map((function(e,n){return{label:t.labels[n],value:e.value?e.value:e}}))},n.prototype.getInnerRadius=function(){return this.model.getOptions().pie.innerRadius},n.prototype.render=function(t){var n=this;void 0===t&&(t=!0);var r=this,i=this.getContainerSVG(),o=this.model.getOptions(),a=this.getDataList(),s=this.computeRadius();this.arc=Wl().innerRadius(this.getInnerRadius()).outerRadius(s),this.hoverArc=Wl().innerRadius(this.getInnerRadius()).outerRadius(s+o.pie.hoverArc.outerRadiusOffset);var u=function(){var t=Ql,e=Jl,n=null,r=Ml(0),i=Ml(Nl),o=Ml(0);function a(a){var s,u,c,l,h,f=a.length,p=0,d=new Array(f),v=new Array(f),g=+r.apply(this,arguments),y=Math.min(Nl,Math.max(-Nl,i.apply(this,arguments)-g)),_=Math.min(Math.abs(y)/f,o.apply(this,arguments)),m=_*(y<0?-1:1);for(s=0;s<f;++s)(h=v[d[s]=s]=+t(a[s],s,a))>0&&(p+=h);for(null!=e?d.sort((function(t,n){return e(v[t],v[n])})):null!=n&&d.sort((function(t,e){return n(a[t],a[e])})),s=0,c=p?(y-f*m)/p:0;s<f;++s,g=l)u=d[s],l=g+((h=v[u])>0?h*c:0)+m,v[u]={data:a[u],index:s,value:h,startAngle:g,endAngle:l,padAngle:_};return v}return a.value=function(e){return arguments.length?(t="function"==typeof e?e:Ml(+e),a):t},a.sortValues=function(t){return arguments.length?(e=t,n=null,a):e},a.sort=function(t){return arguments.length?(n=t,e=null,a):n},a.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:Ml(+t),a):r},a.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:Ml(+t),a):i},a.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:Ml(+t),a):o},a}().value((function(t){return t.value})).sort(null).padAngle(o.pie.padAngle)(a).sort((function(t,e){return t.index-e.index})),c=Fu.appendOrSelect(i,"g.slices").attr("role",e.GROUP).selectAll("path.slice").data(u,(function(t){return t.data.label}));c.exit().attr("opacity",0).remove(),c.enter().append("path").classed("slice",!0).attr("opacity",0).merge(c).attr("fill",(function(t){return n.model.getFillScale()(t.data.label)})).attr("d",this.arc).transition(this.services.transitions.getTransition("pie-slice-enter-update",t)).attr("opacity",1).attr("role",e.GRAPHICS_SYMBOL).attr("aria-roledescription","slice").attr("aria-label",(function(t){return t.value+", "+vn.convertValueToPercentage(t.data.value,a)+"%"})).attrTween("d",(function(t){return Sf.bind(this)(t,r.arc)}));var l=Fu.appendOrSelect(i,"g.labels").attr("role",e.GROUP).selectAll("text.pie-label").data(u,(function(t){return t.data.label}));l.exit().attr("opacity",0).remove();var h=l.enter().append("text").classed("pie-label",!0),f=[];h.merge(l).style("text-anchor","middle").text((function(t){return o.pie.labels.formatter?o.pie.labels.formatter(t):vn.convertValueToPercentage(t.data.value,a)+"%"})).datum((function(t){var e=this.getComputedTextLength();t.textOffsetX=e/2,t.textOffsetY=parseFloat(getComputedStyle(this).fontSize)/2;var n=s+7,r=(t.endAngle-t.startAngle)/2+t.startAngle;return t.xPosition=(t.textOffsetX+n)*Math.sin(r),t.yPosition=(t.textOffsetY+n)*-Math.cos(r),t})).attr("transform",(function(t,e){var n=a.length,r=(t.endAngle-t.startAngle)*(180/Math.PI);if(e>=n-2&&r<o.pie.callout.minSliceDegree){var i=void 0,s=void 0;return t.index===n-1?(i=t.xPosition+o.pie.callout.offsetX+o.pie.callout.textMargin+t.textOffsetX,s=t.yPosition-o.pie.callout.offsetY,t.direction=y.RIGHT,f.push(t)):(i=t.xPosition-o.pie.callout.offsetX-t.textOffsetX-o.pie.callout.textMargin,s=t.yPosition-o.pie.callout.offsetY,t.direction=y.LEFT,f.push(t)),"translate("+i+", "+s+")"}return"translate("+t.xPosition+", "+t.yPosition+")"})),this.renderCallouts(f);var p=s+o.pie.xOffset,d=s+o.pie.yOffset;f.length>0&&(d+=o.pie.yOffsetCallout),i.attr("transform","translate("+p+", "+d+")"),this.addEventListeners()},n.prototype.renderCallouts=function(t){var n=Fu.appendOrSelect(this.getContainerSVG(),"g.callouts").attr("role",e.GROUP),r=this.model.getOptions(),i=n.selectAll("g.callout").data(t);i.exit().remove();var o=i.enter().append("g").classed("callout",!0).attr("role",e.GRAPHICS_SYMBOL+" "+e.GROUP).attr("aria-roledescription","label callout");o.merge(i).datum((function(t){var e=t.xPosition,n=t.yPosition;return t.direction===y.RIGHT?(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e+r.pie.callout.offsetX,y:n-r.pie.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x-r.pie.callout.horizontalLineLength):(t.startPos={x:e,y:n+t.textOffsetY},t.endPos={x:e-r.pie.callout.offsetX,y:n-r.pie.callout.offsetY+t.textOffsetY},t.intersectPointX=t.endPos.x+r.pie.callout.horizontalLineLength),t})),o.append("line").classed("vertical-line",!0).merge(n.selectAll("line.vertical-line")).datum((function(t){return lu(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.startPos.x})).attr("y1",(function(t){return t.startPos.y})).attr("x2",(function(t){return t.intersectPointX})).attr("y2",(function(t){return t.endPos.y})),o.append("line").classed("horizontal-line",!0).merge(i.selectAll("line.horizontal-line")).datum((function(t){return lu(this.parentNode).datum()})).style("stroke-width","1px").attr("x1",(function(t){return t.intersectPointX})).attr("y1",(function(t){return t.endPos.y})).attr("x2",(function(t){return t.endPos.x})).attr("y2",(function(t){return t.endPos.y}))},n.prototype.addEventListeners=function(){var t=this;this.parent.selectAll("path.slice").on("mouseover",(function(e){t.services.events.dispatchEvent(_.Pie.SLICE_MOUSEOVER,{element:lu(this),datum:e})})).on("mousemove",(function(e){var n=lu(this);n.classed("hovered",!0).transition(t.services.transitions.getTransition("pie_slice_mouseover")).attr("d",t.hoverArc),t.services.events.dispatchEvent(_.Pie.SLICE_MOUSEMOVE,{element:n,datum:e}),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:n,type:f.DATAPOINT})})).on("click",(function(e){t.services.events.dispatchEvent(_.Pie.SLICE_CLICK,{element:lu(this),datum:e})})).on("mouseout",(function(e){var n=lu(this);n.classed("hovered",!1).transition(t.services.transitions.getTransition("pie_slice_mouseover")).attr("d",t.arc),t.services.events.dispatchEvent(_.Pie.SLICE_MOUSEOUT,{element:n,datum:e}),t.services.events.dispatchEvent("hide-tooltip",{hoveredElement:n})}))},n.prototype.computeRadius=function(){var t=this.model.getOptions(),e=Fu.getSVGElementSize(this.parent,{useAttrs:!0}),n=e.width,r=e.height;return Math.min(n,r)/2+t.pie.radiusOffset},n}(Zh),Af=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Pf=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="donut",e}return Af(e,t),e.prototype.render=function(e){void 0===e&&(e=!0),t.prototype.render.call(this,e);var n=this,r=Fu.appendOrSelect(this.getContainerSVG(),"g.center"),i=this.model.getOptions(),o=this.computeRadius();Fu.appendOrSelect(r,"text.donut-figure").attr("text-anchor","middle").style("font-size",(function(){return i.donut.center.numberFontSize(o)})).transition(this.services.transitions.getTransition("donut-figure-enter-update",e)).tween("text",(function(){return n.centerNumberTween(lu(this))})),Fu.appendOrSelect(r,"text.donut-title").attr("text-anchor","middle").style("font-size",(function(){return i.donut.center.titleFontSize(o)})).attr("y",i.donut.center.titleYPosition(o)).text(vn.getProperty(i,"donut","center","label"))},e.prototype.getInnerRadius=function(){return.75*this.computeRadius()},e.prototype.centerNumberTween=function(t){var e=this.model.getOptions(),n=vn.getProperty(e,"donut","center","number");n||(n=this.getDataList().reduce((function(t,e){return t+e.value}),0));var r=pi(parseInt(t.text().replace(/[, ]+/g,""),10)||0,n);return function(n){var i=e.donut.center.numberFormatter;t.text(i(r(n)))}},e}(Mf),Cf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Lf=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="spacer",e}return Cf(e,t),e.prototype.render=function(){this.getContainerSVG().append("rect").attr("x",0).attr("y",0).attr("width",this.configs.size||Bn.default.size).attr("height",this.configs.size||Bn.default.size).attr("opacity",0)},e}(Zh);function kf(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function Df(t,e){var n,r,i,o,a,s=new Nf(t),u=+t.value&&(s.value=t.value),c=[s];for(null==e&&(e=jf);n=c.pop();)if(u&&(n.value=+n.data.value),(i=e(n.data))&&(a=i.length))for(n.children=new Array(a),o=a-1;o>=0;--o)c.push(r=n.children[o]=new Nf(i[o])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(If)}function jf(t){return t.children}function Rf(t){t.data=t.data.data}function If(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function Nf(t){this.data=t,this.depth=this.height=0,this.parent=null}function Ff(t){if("function"!=typeof t)throw new Error;return t}function Bf(){return 0}function Vf(t){return function(){return t}}function Uf(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function Hf(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,c=t.value&&(r-e)/t.value;++s<u;)(o=a[s]).y0=n,o.y1=i,o.x0=e,o.x1=e+=o.value*c}function zf(t,e,n,r,i){for(var o,a=t.children,s=-1,u=a.length,c=t.value&&(i-n)/t.value;++s<u;)(o=a[s]).x0=e,o.x1=r,o.y0=n,o.y1=n+=o.value*c}Nf.prototype=Df.prototype={constructor:Nf,count:function(){return this.eachAfter(kf)},each:function(t){var e,n,r,i,o=this,a=[o];do{for(e=a.reverse(),a=[];o=e.pop();)if(t(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r])}while(a.length);return this},eachAfter:function(t){for(var e,n,r,i=this,o=[i],a=[];i=o.pop();)if(a.push(i),e=i.children)for(n=0,r=e.length;n<r;++n)o.push(e[n]);for(;i=a.pop();)t(i);return this},eachBefore:function(t){for(var e,n,r=this,i=[r];r=i.pop();)if(t(r),e=r.children)for(n=e.length-1;n>=0;--n)i.push(e[n]);return this},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();for(;t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){var t=[];return this.each((function(e){t.push(e)})),t},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return Df(this).eachBefore(Rf)}};var Gf=function t(e){function n(t,n,r,i,o){!function(t,e,n,r,i,o){for(var a,s,u,c,l,h,f,p,d,v,g,y=[],_=e.children,m=0,b=0,x=_.length,w=e.value;m<x;){u=i-n,c=o-r;do{l=_[b++].value}while(!l&&b<x);for(h=f=l,g=l*l*(v=Math.max(c/u,u/c)/(w*t)),d=Math.max(f/g,g/h);b<x;++b){if(l+=s=_[b].value,s<h&&(h=s),s>f&&(f=s),g=l*l*v,(p=Math.max(f/g,g/h))>d){l-=s;break}d=p}y.push(a={value:l,dice:u<c,children:_.slice(m,b)}),a.dice?Hf(a,n,r,i,w?r+=c*l/w:o):zf(a,n,r,w?n+=u*l/w:i,o),w-=l,m=b}}(e,t,n,r,i,o)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}((1+Math.sqrt(5))/2);function Yf(){var t=Gf,e=!1,n=1,r=1,i=[0],o=Bf,a=Bf,s=Bf,u=Bf,c=Bf;function l(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(h),i=[0],e&&t.eachBefore(Uf),t}function h(e){var n=i[e.depth],r=e.x0+n,l=e.y0+n,h=e.x1-n,f=e.y1-n;h<r&&(r=h=(r+h)/2),f<l&&(l=f=(l+f)/2),e.x0=r,e.y0=l,e.x1=h,e.y1=f,e.children&&(n=i[e.depth+1]=o(e)/2,r+=c(e)-n,l+=a(e)-n,(h-=s(e)-n)<r&&(r=h=(r+h)/2),(f-=u(e)-n)<l&&(l=f=(l+f)/2),t(e,r,l,h,f))}return l.round=function(t){return arguments.length?(e=!!t,l):e},l.size=function(t){return arguments.length?(n=+t[0],r=+t[1],l):[n,r]},l.tile=function(e){return arguments.length?(t=Ff(e),l):t},l.padding=function(t){return arguments.length?l.paddingInner(t).paddingOuter(t):l.paddingInner()},l.paddingInner=function(t){return arguments.length?(o="function"==typeof t?t:Vf(+t),l):o},l.paddingOuter=function(t){return arguments.length?l.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):l.paddingTop()},l.paddingTop=function(t){return arguments.length?(a="function"==typeof t?t:Vf(+t),l):a},l.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:Vf(+t),l):s},l.paddingBottom=function(t){return arguments.length?(u="function"==typeof t?t:Vf(+t),l):u},l.paddingLeft=function(t){return arguments.length?(c="function"==typeof t?t:Vf(+t),l):c},l}var qf=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Wf=function(t){function e(n,r,i,o){var a=t.call(this,n,r,o)||this;return a.type="layout",a.configs=o,a.children=i,a._instanceID=e.instanceID++,(a.configs.direction===v.ROW_REVERSE||a.configs.direction===v.COLUMN_REVERSE)&&(a.children=a.children.reverse()),a.init(),a}return qf(e,t),e.prototype.init=function(){this.children.forEach((function(t){t.components.forEach((function(t){t.init()}))}))},e.prototype.getPreferedAndFixedSizeSum=function(){var t=this.parent,e=0;return t.selectAll("svg.layout-child-"+this._instanceID).filter((function(t){var e=vn.getProperty(t,"data","growth","x");return e===g.PREFERRED||e===g.FIXED})).each((function(t){e+=t.data.size})),e},e.prototype.getNumOfStretchChildren=function(){return this.parent.selectAll("svg.layout-child-"+this._instanceID).filter((function(t){return vn.getProperty(t,"data","growth","x")===g.STRETCH})).size()},e.prototype.render=function(t){var e=this;void 0===t&&(t=!0);var n=this.parent,r=Fu.getSVGElementSize(n,{useAttrs:!0}),i=r.width,o=r.height,a=Df({children:this.children}).sum((function(t){return t.size})),s=this.configs.direction===v.ROW||this.configs.direction===v.ROW_REVERSE?Hf:zf;Yf().tile(s).size([i,o])(a);var u=this.configs.direction===v.ROW||this.configs.direction===v.ROW_REVERSE,c=n.selectAll("svg.layout-child-"+this._instanceID).data(a.leaves(),(function(t){return t.data.id}));c.attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})),c.enter().append("svg").attr("class",(function(t){return"layout-child layout-child-"+e._instanceID+" "+t.data.id})).attr("x",(function(t){return t.x0})).attr("y",(function(t){return t.y0})).merge(n.selectAll("svg.layout-child-"+this._instanceID)).each((function(e){var n=this;e.data.components.forEach((function(r){r.setParent(lu(n));var i=vn.getProperty(e,"data","growth","x");i!==g.PREFERRED&&i!==g.FIXED||r.render(t)}))})),n.selectAll("svg.layout-child-"+this._instanceID).each((function(t){var e=vn.getProperty(t,"data","growth","x"),n=Fu.getSVGElementSize(lu(this),{useBBox:!0});if(e===g.PREFERRED){var r=u?n.width:n.height,a=u?i:o;t.data.size=r/a*100}})),c.exit().remove(),this.children.filter((function(t){return vn.getProperty(t,"growth","x")===g.STRETCH})).forEach((function(t,n){t.size=(100-+e.getPreferedAndFixedSizeSum())/+e.getNumOfStretchChildren()})),a=Df({children:this.children}).sum((function(t){return t.size})),Yf().tile(s).size([i,o]).padding(0)(a),n.selectAll("svg.layout-child-"+this._instanceID).data(a.leaves(),(function(t){return t.data.id})).attr("x",(function(t){return t.x0})).attr("y",(function(t){return t.y0})).attr("width",(function(t){return t.x1-t.x0})).attr("height",(function(t){return t.y1-t.y0})).each((function(e,n){e.data.components.forEach((function(n){vn.getProperty(e,"data","growth","x")===g.STRETCH&&n.render(t)}))}))},e.prototype.setModel=function(e){t.prototype.setModel.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setModel(e)}))}))},e.prototype.setServices=function(e){t.prototype.setServices.call(this,e),this.children.forEach((function(t){t.components.forEach((function(t){return t.setServices(e)}))}))},e.prototype.destroy=function(){this.children.forEach((function(t){t.components.forEach((function(t){return t.destroy()}))}))},e.instanceID=Math.floor(99999999999*Math.random()),e}(Zh),Xf=Array.prototype.slice;function $f(t){return t}function Zf(t){return"translate("+(t+.5)+",0)"}function Kf(t){return"translate(0,"+(t+.5)+")"}function Jf(t){return function(e){return+t(e)}}function Qf(t){var e=Math.max(0,t.bandwidth()-1)/2;return t.round()&&(e=Math.round(e)),function(n){return+t(n)+e}}function tp(){return!this.__axis}function ep(t,e){var n=[],r=null,i=null,o=6,a=6,s=3,u=1===t||4===t?-1:1,c=4===t||2===t?"x":"y",l=1===t||3===t?Zf:Kf;function h(h){var f=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,p=null==i?e.tickFormat?e.tickFormat.apply(e,n):$f:i,d=Math.max(o,0)+s,v=e.range(),g=+v[0]+.5,y=+v[v.length-1]+.5,_=(e.bandwidth?Qf:Jf)(e.copy()),m=h.selection?h.selection():h,b=m.selectAll(".domain").data([null]),x=m.selectAll(".tick").data(f,e).order(),w=x.exit(),O=x.enter().append("g").attr("class","tick"),T=x.select("line"),E=x.select("text");b=b.merge(b.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),x=x.merge(O),T=T.merge(O.append("line").attr("stroke","currentColor").attr(c+"2",u*o)),E=E.merge(O.append("text").attr("fill","currentColor").attr(c,u*d).attr("dy",1===t?"0em":3===t?"0.71em":"0.32em")),h!==m&&(b=b.transition(h),x=x.transition(h),T=T.transition(h),E=E.transition(h),w=w.transition(h).attr("opacity",1e-6).attr("transform",(function(t){return isFinite(t=_(t))?l(t):this.getAttribute("transform")})),O.attr("opacity",1e-6).attr("transform",(function(t){var e=this.parentNode.__axis;return l(e&&isFinite(e=e(t))?e:_(t))}))),w.remove(),b.attr("d",4===t||2==t?a?"M"+u*a+","+g+"H0.5V"+y+"H"+u*a:"M0.5,"+g+"V"+y:a?"M"+g+","+u*a+"V0.5H"+y+"V"+u*a:"M"+g+",0.5H"+y),x.attr("opacity",1).attr("transform",(function(t){return l(_(t))})),T.attr(c+"2",u*o),E.attr(c,u*d).text(p),m.filter(tp).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",2===t?"start":4===t?"end":"middle"),m.each((function(){this.__axis=_}))}return h.scale=function(t){return arguments.length?(e=t,h):e},h.ticks=function(){return n=Xf.call(arguments),h},h.tickArguments=function(t){return arguments.length?(n=null==t?[]:Xf.call(t),h):n.slice()},h.tickValues=function(t){return arguments.length?(r=null==t?null:Xf.call(t),h):r&&r.slice()},h.tickFormat=function(t){return arguments.length?(i=t,h):i},h.tickSize=function(t){return arguments.length?(o=a=+t,h):o},h.tickSizeInner=function(t){return arguments.length?(o=+t,h):o},h.tickSizeOuter=function(t){return arguments.length?(a=+t,h):a},h.tickPadding=function(t){return arguments.length?(s=+t,h):s},h}function np(t){return ep(1,t)}function rp(t){return ep(2,t)}function ip(t){return ep(3,t)}function op(t){return ep(4,t)}var ap=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),sp=function(t){function n(e,n,r){var i=t.call(this,e,n,r)||this;return i.type="axes",r&&(i.configs=r),i.margins=i.configs.margins,i}return ap(n,t),n.prototype.render=function(t){void 0===t&&(t=!0);var n,r,i=this.configs.position,o=this.model.getOptions(),a=vn.getProperty(o,"axes",i),u=this.getContainerSVG(),c=Fu.getSVGElementSize(this.parent,{useAttrs:!0}),h=c.width,f=c.height;i===s.BOTTOM||i===s.TOP?(n=this.configs.axes[s.LEFT]?this.margins.left:0,r=this.configs.axes[s.RIGHT]?h-this.margins.right:h):(n=f-this.margins.bottom,r=this.margins.top);var p,d=this.services.cartesianScales.getScaleByPosition(i);switch(this.scaleType===l.LABELS?d.rangeRound([n,r]):d.range([n,r]),i){case s.LEFT:p=op;break;case s.BOTTOM:p=ip;break;case s.RIGHT:p=rp;break;case s.TOP:p=np}var v=p(d).tickSizeOuter(0).tickFormat(vn.getProperty(a,"ticks","formatter"));if(d.ticks){var g=vn.getProperty(a,"ticks","number")||Fn.ticks.number;if(v.ticks(g),this.scaleType===l.TIME){var y=d.ticks(g).concat(d.domain()).map((function(t){return+t})).sort();y=vn.removeArrayDuplicates(y),vn.getProperty(o,"timeScale","addSpaceOnEdges")&&y.length>2&&(y.splice(y.length-1,1),y.splice(0,1)),v.tickValues(y)}}var _=Fu.appendOrSelect(u,"g.axis."+i),m=!_.select("g.ticks").empty(),b=Fu.appendOrSelect(_,"g.ticks");m||b.attr("role",e.GRAPHICS_OBJECT+" "+e.GROUP);var x=Fu.appendOrSelect(_,"g.ticks.invisible").style("opacity","0").attr("aria-hidden",!0);switch(i){case s.LEFT:b.attr("transform","translate("+this.margins.left+", 0)");break;case s.BOTTOM:b.attr("transform","translate(0, "+(f-this.margins.bottom)+")");break;case s.RIGHT:b.attr("transform","translate("+(h-this.margins.right)+", 0)");break;case s.TOP:b.attr("transform","translate(0, "+this.margins.top+")")}if(a.title){var w=Fu.appendOrSelect(_,"text.axis-title").text(a.title);switch(i){case s.LEFT:w.attr("transform","rotate(-90)").attr("y",0).attr("x",-d.range()[0]/2).attr("dy","1em").style("text-anchor","middle");break;case s.BOTTOM:w.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+f+")").style("text-anchor","middle");break;case s.RIGHT:w.attr("transform","rotate(90)").attr("y",-h).attr("x",d.range()[0]/2).attr("dy","1em").style("text-anchor","middle");break;case s.TOP:var O=Fu.getSVGElementSize(w,{useBBox:!0}).height;w.attr("transform","translate("+(this.margins.left/2+d.range()[1]/2)+", "+O/2+")").style("text-anchor","middle")}}if(b=t&&m?b.transition(this.services.transitions.getTransition("axis-update")).call(v):b.call(v),x.call(v),i===s.BOTTOM||i===s.TOP){var T=!1;if(d.step){T=x.selectAll("g.tick text").nodes().some((function(t){return Fu.getSVGElementSize(t,{useBBox:!0}).width>=d.step()}))}else{var E=vn.getProperty(a,"ticks","rotateIfSmallerThan")||Fn.ticks.rotateIfSmallerThan;T=h/d.ticks().length/2<E}T?_.selectAll("g.ticks g.tick text").attr("transform","rotate(45)").style("text-anchor",i===s.TOP?"end":"start"):_.selectAll("g.ticks g.tick text").attr("transform",null).style("text-anchor",null)}},n.prototype.getInvisibleAxisRef=function(){var t=this.configs.position;return this.getContainerSVG().select("g.axis."+t+" g.ticks.invisible")},n.prototype.getTitleRef=function(){var t=this.configs.position;return this.getContainerSVG().select("g.axis."+t+" text.axis-title")},n}(Zh),up=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),cp=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="2D-axes",e.children={},e.margins={top:0,right:0,bottom:0,left:0},e}return up(e,t),e.prototype.render=function(t){var e=this;void 0===t&&(t=!1);var n={},r=Object.keys(s),i=vn.getProperty(this.model.getOptions(),"axes");i?r.forEach((function(t){var e=i[s[t]];e&&(n[s[t]]=!0,!0===e.primary||e.secondary)})):(this.model.getOptions().axes={left:{primary:!0},bottom:{secondary:!0,type:this.model.getDisplayData().labels?l.LABELS:void 0}},n[s.LEFT]=!0,n[s.BOTTOM]=!0),this.configs.axes=n,r.forEach((function(t){var n=s[t];if(e.configs.axes[n]&&!e.children[n]){var r=new sp(e.model,e.services,{position:n,axes:e.configs.axes,margins:e.margins});r.setModel(e.model),r.setServices(e.services),r.setParent(e.parent),e.children[n]=r}})),Object.keys(this.children).forEach((function(n){e.children[n].render(t)}));var o={};Object.keys(this.children).forEach((function(t){var n,r=e.children[t],i=r.configs.position,a=r.getInvisibleAxisRef(),u=Fu.getSVGElementSize(a,{useBBox:!0}),c=u.width,l=u.height;switch(n=r.getTitleRef().empty()?0:Fu.getSVGElementSize(r.getTitleRef(),{useBBox:!0}).height,i){case s.TOP:o.top=l+n;break;case s.BOTTOM:o.bottom=l+n;break;case s.LEFT:o.left=c+n;break;case s.RIGHT:o.right=c+n}})),Object.keys(o).some((function(t){return e.margins[t]!==o[t]}))&&(this.margins=Object.assign(this.margins,o),Object.keys(this.children).forEach((function(t){e.children[t].margins=e.margins})),this.render(!0))},e}(Zh),lp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),hp=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="grid",e}return lp(e,t),e.prototype.render=function(){this.drawBackdrop(),Fu.appendOrSelect(this.backdrop,"g.x.grid"),Fu.appendOrSelect(this.backdrop,"g.y.grid"),this.drawXGrid(),this.drawYGrid(),vn.getProperty(this.model.getOptions(),"tooltip","gridline","enabled")&&this.addGridEventListeners()},e.prototype.drawXGrid=function(){var t=this.parent,e=this.backdrop.attr("height"),n=ip(this.services.cartesianScales.getMainXScale()).tickSizeInner(-e).tickSizeOuter(0),r=vn.getProperty(this.model.getOptions(),"grid","x","numberOfTicks");n.ticks(r);var i=t.select(".x.grid").attr("transform","translate("+-this.backdrop.attr("x")+", "+e+")").call(n);this.cleanGrid(i)},e.prototype.drawYGrid=function(){var t=this.parent,e=this.backdrop.attr("width"),n=op(this.services.cartesianScales.getMainYScale()).tickSizeInner(-e).tickSizeOuter(0),r=vn.getProperty(this.model.getOptions(),"grid","y","numberOfTicks");n.ticks(r);var i=t.select(".y.grid").attr("transform","translate(0, "+-this.backdrop.attr("y")+")").call(n);this.cleanGrid(i)},e.prototype.getGridlineThreshold=function(t){var e,n=this.parent,r=n.selectAll(".x.grid .tick").nodes().sort((function(t,e){return Number(vn.getTranslationValues(t).tx)-Number(vn.getTranslationValues(e).tx)})),i=-1;r.forEach((function(e,n){t[0]>=+vn.getTranslationValues(e).tx&&i++})),e=i+1<r.length?i+1:r.length;var o,a=r[i],s=r[e];if(a)if(s)o=+vn.getTranslationValues(s).tx-+vn.getTranslationValues(a).tx;else{var u=n.select("rect.chart-grid-backdrop").node();o=Fu.getSVGElementSize(u).width-+vn.getTranslationValues(a).tx}else o=+vn.getTranslationValues(s).tx;return o*this.model.getOptions().tooltip.gridline.threshold},e.prototype.getActiveGridline=function(t){var e=vn.getProperty(this.model.getOptions,"tooltip","gridline","threshold")?vn.getProperty(this.model.getOptions,"tooltip","gridline","threshold"):this.getGridlineThreshold(t);return this.parent.selectAll(".x.grid .tick").filter((function(){var n=vn.getTranslationValues(this),r=Number(n.tx)-e,i=Number(n.tx)+e;return r<=t[0]&&t[0]<=i}))},e.prototype.addGridEventListeners=function(){var t=this,e=this.parent;Fu.appendOrSelect(e,"rect.chart-grid-backdrop").on("mousemove mouseover",(function(){var n=fu(t.services.domUtils.getMainSVG()),r=lu(this);e.selectAll(".x.grid .tick").classed("active",!1);var i,o=t.getActiveGridline(n);o.empty()?t.services.events.dispatchEvent("hide-tooltip",{}):(o.classed("active",!0),o.each((function(e){i=t.services.cartesianScales.getDataFromDomain(e)})),t.services.events.dispatchEvent("show-tooltip",{hoveredElement:r,multidata:i,type:f.GRIDLINE}))})).on("mouseout",(function(){e.selectAll(".x.grid .tick").classed("active",!1),t.services.events.dispatchEvent("hide-tooltip",{})}))},e.prototype.drawBackdrop=function(){var t=this.parent,e=this.services.cartesianScales.getMainXScale(),n=this.services.cartesianScales.getMainYScale(),r=e.range(),i=r[0],o=r[1],a=n.range(),s=a[0],u=a[1];this.backdrop=Fu.appendOrSelect(t,"svg.chart-grid-backdrop");var c=Fu.appendOrSelect(this.backdrop,"rect.chart-grid-backdrop");this.backdrop.merge(c).attr("x",i).attr("y",u).attr("width",o-i).attr("height",s-u).lower(),c.attr("width","100%").attr("height","100%")},e.prototype.cleanGrid=function(t){var e=this.model.getOptions();t.selectAll("line").attr("stroke",e.grid.strokeColor),t.selectAll("text").remove(),t.select(".domain").remove()},e}(Zh),fp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),pp=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="zero-line",e}return fp(e,t),e.prototype.render=function(t){var e=this.getContainerSVG(),n=this.services.cartesianScales.getDomainScale().range(),r=n[0],i=n[1],o=+this.services.cartesianScales.getRangeValue(0)+.5,a=vn.flipSVGCoordinatesBasedOnOrientation({x0:r,x1:i,y0:o,y1:o},this.services.cartesianScales.getOrientation());Fu.appendOrSelect(e,"line.domain").transition(this.services.transitions.getTransition("zero-line-update",t)).attr("y1",a.y0).attr("y2",a.y1).attr("x1",a.x0).attr("x2",a.x1)},e}(Zh),dp=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},vp=function(){function t(t,e){this.services={domUtils:Fu,events:Vu,transitions:Kc},this.model=new Qa(this.services)}return t.prototype.init=function(t,e){var n=this;this.model.set({holder:t},!0),Object.keys(this.services).forEach((function(t){var e=n.services[t];n.services[t]=new e(n.model,n.services)})),this.services.events.addEventListener("model-update",(function(){n.update(!0)})),this.model.setData(e.data),this.services.events.addEventListener("chart-resize",(function(){n.update(!1)})),this.components=this.getComponents(),this.update()},t.prototype.getComponents=function(){return console.error("getComponents() method is not implemented"),null},t.prototype.update=function(t){var e=this;if(void 0===t&&(t=!0),this.components){Object.keys(this.services).forEach((function(t){e.services[t].update()})),this.components.forEach((function(e){return e.render(t)}));var n=this.services.transitions.getPendingTransitions(),r=Object.keys(n).map((function(t){return n[t].end().catch((function(t){return t}))}));Promise.all(r).then((function(){return e.services.events.dispatchEvent("render-finished")}))}},t.prototype.destroy=function(){this.components.forEach((function(t){return t.destroy()})),this.services.domUtils.getHolder().remove(),this.model.set({destroyed:!0},!0)},t.prototype.getChartComponents=function(t){var e={id:"title",components:[new tf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},n={id:"legend",components:[new Jh(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},r={id:"graph-frame",components:t,growth:{x:g.STRETCH,y:g.FIXED}},i=!1!==this.model.getOptions().legend.enabled,o=v.COLUMN;if(i){var a=vn.getProperty(this.model.getOptions(),"legend","position");"left"===a?(o=v.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=d.VERTICAL)):"right"===a?(o=v.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=d.VERTICAL)):"bottom"===a&&(o=v.COLUMN_REVERSE)}var s={id:"spacer",components:[new Lf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},u={id:"full-frame",components:[new Wf(this.model,this.services,dp(i?[n]:[],[s,r]),{direction:o})],growth:{x:g.STRETCH,y:g.FIXED}},c=[];if(this.model.getOptions().title){c.push(e);var l={id:"spacer",components:[new Lf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}};c.push(l)}return c.push(u),[new Wf(this.model,this.services,c,{direction:v.COLUMN})]},t}(),gp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),yp=function(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),i=0;for(e=0;e<n;e++)for(var o=arguments[e],a=0,s=o.length;a<s;a++,i++)r[i]=o[a];return r},_p=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.services=Object.assign(r.services,{cartesianScales:xl,curves:$h}),r}return gp(e,t),e.prototype.getAxisChartComponents=function(t){var e={id:"title",components:[new tf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},n={id:"legend",components:[new Jh(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},r={id:"graph-frame",components:t,growth:{x:g.STRETCH,y:g.FIXED}},i=!1!==this.model.getOptions().legend.enabled,o=v.COLUMN;if(i){var a=vn.getProperty(this.model.getOptions(),"legend","position");a===p.LEFT?(o=v.ROW,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=d.VERTICAL)):a===p.RIGHT?(o=v.ROW_REVERSE,this.model.getOptions().legend.orientation||(this.model.getOptions().legend.orientation=d.VERTICAL)):a===p.BOTTOM&&(o=v.COLUMN_REVERSE)}var s={id:"spacer",components:[new Lf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}},u={id:"full-frame",components:[new Wf(this.model,this.services,yp(i?[n]:[],[s,r]),{direction:o})],growth:{x:g.STRETCH,y:g.FIXED}},c=[];if(this.model.getOptions().title){c.push(e);var l={id:"spacer",components:[new Lf(this.model,this.services)],growth:{x:g.PREFERRED,y:g.FIXED}};c.push(l)}return c.push(u),[new Wf(this.model,this.services,c,{direction:v.COLUMN})]},e}(vp),mp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),bp=function(t){function e(e){return t.call(this,e)||this}return mp(e,t),e.prototype.generateDataLabels=function(t){var e={};return t.labels.forEach((function(t){e[t]=mn.items.status.ACTIVE})),e},e.prototype.getDisplayData=function(){var t=mn.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=vn.clone(this.get("data")),r=n.datasets[0];return r.data=r.data.filter((function(r,i){var o=n.labels[i];return e[o]===t})),n.labels=n.labels.filter((function(n){return e[n]===t})),n},e.prototype.setColorScale=function(){var t=this.getDisplayData().datasets[0];if(t.fillColors)this.colorScale=Pr().range(t.fillColors).domain(this.allDataLabels);else{var e=sr;this.colorScale=Pr().range(e).domain(this.allDataLabels)}},e.prototype.getFillColor=function(t){var e=this.getOptions();return e.getFillColor?e.getFillColor(t):this.getFillScale()(t)},e.prototype.getStrokeColor=function(t){var e=this.getOptions();return e.getStrokeColor?e.getStrokeColor(t):this.colorScale(t)},e}(Qa),xp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),wp=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model=new bp(r.services),r.model.setOptions(vn.merge(vn.clone(Rn.simpleBarChart),n.options)),r.init(e,n),r}return xp(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new df(this.model,this.services),new pp(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new uf(this.model,this.services)),e},e}(_p),Op=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Tp=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.groupedBarChart),n.options)),r.init(e,n),r}return Op(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new gf(this.model,this.services),new pp(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new uf(this.model,this.services)),e},e}(_p),Ep=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Sp=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.stackedBarChart),n.options)),r.init(e,n),r}return Ep(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new _f(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new uf(this.model,this.services)),e},e}(_p),Mp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Ap=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.bubbleChart),n.options)),r.init(e,n),r}return Mp(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new wf(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new lf(this.model,this.services)),e},e}(_p),Pp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Cp=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.lineChart),n.options)),r.init(e,n),r}return Pp(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new Tf(this.model,this.services),new bf(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new lf(this.model,this.services)),e},e}(_p),Lp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kp=function(t){function e(e,n){var r=t.call(this,e,n)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.scatterChart),n.options)),r.init(e,n),r}return Lp(e,t),e.prototype.getComponents=function(){var t=[new cp(this.model,this.services),new hp(this.model,this.services),new bf(this.model,this.services)],e=this.getAxisChartComponents(t);return e.push(new lf(this.model,this.services)),e},e}(_p),Dp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),jp=function(t){function e(e){return t.call(this,e)||this}return Dp(e,t),e.prototype.sanitize=function(t){var e=vn.getProperty(t,"datasets",0);if(e){var n=t.labels.map((function(t,n){return{label:t,value:e.data[n],fillColor:e.fillColors?e.fillColors[n]:void 0}})).sort((function(t,e){return e.value-t.value}));e.data=n.map((function(t){return t.value})),t.labels=n.map((function(t){return t.label})),e.fillColors&&(e.fillColors=n.map((function(t){return t.fillColor})))}return t},e.prototype.generateDataLabels=function(t){var e={};return t.labels.forEach((function(t){e[t]=mn.items.status.ACTIVE})),e},e.prototype.getDisplayData=function(){var t=mn.items.status.ACTIVE,e=this.get("dataLabels");if(!this.get("data"))return null;var n=vn.clone(this.get("data")),r=n.datasets[0];return r.data=r.data.filter((function(r,i){var o=n.labels[i];return e[o]===t})),n.labels=n.labels.filter((function(n){return e[n]===t})),n},e.prototype.toggleDataLabel=function(t){var e=mn.items.status,n=e.ACTIVE,r=e.DISABLED,i=this.get("dataLabels"),o=Object.keys(i).some((function(t){return i[t]===r})),a=Object.keys(i).filter((function(t){return i[t]===n}));o?1===a.length&&a[0]===t?Object.keys(i).forEach((function(t){i[t]=n})):i[t]=i[t]===r?n:r:Object.keys(i).forEach((function(e){i[e]=e===t?n:r})),this.set({dataLabels:i})},e.prototype.setColorScale=function(){var t=this.getDisplayData().datasets[0];if(t.fillColors)this.colorScale=Pr().range(t.fillColors).domain(this.allDataLabels);else{var e=sr;this.colorScale=Pr().range(e).domain(this.allDataLabels)}},e.prototype.getFillColor=function(t){var e=this.getOptions();return e.getFillColor?e.getFillColor(t):this.getFillScale()(t)},e.prototype.getStrokeColor=function(t){var e=this.getOptions();return e.getStrokeColor?e.getStrokeColor(t):this.colorScale(t)},e}(Qa),Rp=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Ip=function(t){function e(e,n,r){void 0===r&&(r=!1);var i=t.call(this,e,n)||this;return i.model=new jp(i.services),r?i:(i.model.setOptions(vn.merge(vn.clone(Rn.pieChart),n.options)),i.init(e,n),i)}return Rp(e,t),e.prototype.getComponents=function(){var t=[new Mf(this.model,this.services)],e=this.getChartComponents(t);return e.push(new af(this.model,this.services)),e},e}(vp),Np=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(e,n)};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Fp=function(t){function e(e,n){var r=t.call(this,e,n,!0)||this;return r.model.setOptions(vn.merge(vn.clone(Rn.donutChart),n.options)),r.init(e,n),r}return Np(e,t),e.prototype.getComponents=function(){var t=[new Pf(this.model,this.services)],e=this.getChartComponents(t);return e.push(new af(this.model,this.services)),e},e}(Ip),Bp=sr;t.BubbleChart=Ap,t.DonutChart=Fp,t.GroupedBarChart=Tp,t.LineChart=Cp,t.PieChart=Ip,t.ScatterChart=kp,t.SimpleBarChart=wp,t.StackedBarChart=Sp,t.colorPalettes=ur,t.configurations=Vn,t.defaultColors=Bp,t.interfaces=m,Object.defineProperty(t,"__esModule",{value:!0})}));