@swimlane/ngx-charts 18.0.1 → 19.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (211) hide show
  1. package/bundles/swimlane-ngx-charts.umd.js +1259 -497
  2. package/bundles/swimlane-ngx-charts.umd.js.map +1 -1
  3. package/esm2015/lib/area-chart/area-chart-normalized.component.js +12 -9
  4. package/esm2015/lib/area-chart/area-chart-stacked.component.js +10 -7
  5. package/esm2015/lib/area-chart/area-chart.component.js +7 -6
  6. package/esm2015/lib/area-chart/area-chart.module.js +1 -1
  7. package/esm2015/lib/area-chart/area-series.component.js +2 -2
  8. package/esm2015/lib/bar-chart/bar-chart.module.js +1 -1
  9. package/esm2015/lib/bar-chart/bar-horizontal-2d.component.js +10 -7
  10. package/esm2015/lib/bar-chart/bar-horizontal-normalized.component.js +10 -7
  11. package/esm2015/lib/bar-chart/bar-horizontal-stacked.component.js +10 -7
  12. package/esm2015/lib/bar-chart/bar-horizontal.component.js +4 -3
  13. package/esm2015/lib/bar-chart/bar-label.component.js +2 -2
  14. package/esm2015/lib/bar-chart/bar-vertical-2d.component.js +10 -7
  15. package/esm2015/lib/bar-chart/bar-vertical-normalized.component.js +10 -7
  16. package/esm2015/lib/bar-chart/bar-vertical-stacked.component.js +10 -7
  17. package/esm2015/lib/bar-chart/bar-vertical.component.js +5 -3
  18. package/esm2015/lib/bar-chart/bar.component.js +5 -9
  19. package/esm2015/lib/bar-chart/series-horizontal.component.js +11 -8
  20. package/esm2015/lib/bar-chart/series-vertical.component.js +11 -8
  21. package/esm2015/lib/bar-chart/types/bar-chart-type.enum.js +1 -1
  22. package/esm2015/lib/bar-chart/types/bar.model.js +1 -1
  23. package/esm2015/lib/bar-chart/types/d0-type.enum.js +1 -1
  24. package/esm2015/lib/box-chart/box-chart.component.js +254 -0
  25. package/esm2015/lib/box-chart/box-chart.module.js +15 -0
  26. package/esm2015/lib/box-chart/box-series.component.js +183 -0
  27. package/esm2015/lib/box-chart/box.component.js +294 -0
  28. package/esm2015/lib/bubble-chart/bubble-chart.component.js +5 -4
  29. package/esm2015/lib/bubble-chart/bubble-chart.module.js +1 -1
  30. package/esm2015/lib/bubble-chart/bubble-chart.utils.js +17 -14
  31. package/esm2015/lib/bubble-chart/bubble-series.component.js +8 -4
  32. package/esm2015/lib/common/area.component.js +14 -9
  33. package/esm2015/lib/common/axes/axes.module.js +1 -1
  34. package/esm2015/lib/common/axes/axis-label.component.js +1 -1
  35. package/esm2015/lib/common/axes/ticks.helper.js +1 -1
  36. package/esm2015/lib/common/axes/x-axis-ticks.component.js +1 -1
  37. package/esm2015/lib/common/axes/x-axis.component.js +3 -3
  38. package/esm2015/lib/common/axes/y-axis-ticks.component.js +1 -1
  39. package/esm2015/lib/common/axes/y-axis.component.js +1 -1
  40. package/esm2015/lib/common/base-chart.component.js +3 -3
  41. package/esm2015/lib/common/chart-common.module.js +1 -1
  42. package/esm2015/lib/common/charts/chart.component.js +4 -10
  43. package/esm2015/lib/common/circle-series.component.js +13 -7
  44. package/esm2015/lib/common/circle.component.js +1 -1
  45. package/esm2015/lib/common/color.helper.js +34 -19
  46. package/esm2015/lib/common/constants/font-widths.js +1 -1
  47. package/esm2015/lib/common/count/count.directive.js +1 -1
  48. package/esm2015/lib/common/count/count.helper.js +1 -1
  49. package/esm2015/lib/common/domain.helper.js +39 -2
  50. package/esm2015/lib/common/grid-layout.helper.js +1 -1
  51. package/esm2015/lib/common/grid-panel-series.component.js +4 -8
  52. package/esm2015/lib/common/grid-panel.component.js +1 -1
  53. package/esm2015/lib/common/label.helper.js +1 -1
  54. package/esm2015/lib/common/legend/advanced-legend.component.js +3 -3
  55. package/esm2015/lib/common/legend/legend-entry.component.js +1 -1
  56. package/esm2015/lib/common/legend/legend.component.js +2 -2
  57. package/esm2015/lib/common/legend/scale-legend.component.js +2 -2
  58. package/esm2015/lib/common/shape.helper.js +1 -1
  59. package/esm2015/lib/common/svg-linear-gradient.component.js +5 -9
  60. package/esm2015/lib/common/svg-radial-gradient.component.js +1 -1
  61. package/esm2015/lib/common/tick-format.helper.js +1 -1
  62. package/esm2015/lib/common/timeline/timeline.component.js +9 -14
  63. package/esm2015/lib/common/tooltip/injection-registery.service.js +1 -1
  64. package/esm2015/lib/common/tooltip/injection.service.js +3 -3
  65. package/esm2015/lib/common/tooltip/position/index.js +2 -2
  66. package/esm2015/lib/common/tooltip/position/placement-type.enum.js +9 -0
  67. package/esm2015/lib/common/tooltip/position/position.js +2 -2
  68. package/esm2015/lib/common/tooltip/show.type.js +1 -1
  69. package/esm2015/lib/common/tooltip/style.type.js +3 -3
  70. package/esm2015/lib/common/tooltip/tooltip.component.js +2 -2
  71. package/esm2015/lib/common/tooltip/tooltip.directive.js +1 -2
  72. package/esm2015/lib/common/tooltip/tooltip.module.js +1 -1
  73. package/esm2015/lib/common/tooltip/tooltip.service.js +1 -1
  74. package/esm2015/lib/common/tooltip-area.component.js +8 -4
  75. package/esm2015/lib/common/trim-label.helper.js +1 -1
  76. package/esm2015/lib/common/types/bar-orientation.enum.js +6 -0
  77. package/esm2015/lib/common/types/gradient.interface.js +1 -1
  78. package/esm2015/lib/common/types/legend.model.js +1 -1
  79. package/esm2015/lib/common/types/orientation.enum.js +1 -1
  80. package/esm2015/lib/common/types/scale-type.enum.js +1 -1
  81. package/esm2015/lib/common/types/text-anchor.enum.js +1 -1
  82. package/esm2015/lib/common/types/view-dimension.interface.js +1 -1
  83. package/esm2015/lib/common/view-dimensions.helper.js +3 -2
  84. package/esm2015/lib/events.js +1 -1
  85. package/esm2015/lib/gauge/gauge-arc.component.js +7 -3
  86. package/esm2015/lib/gauge/gauge-axis.component.js +2 -2
  87. package/esm2015/lib/gauge/gauge.component.js +4 -3
  88. package/esm2015/lib/gauge/gauge.module.js +1 -1
  89. package/esm2015/lib/gauge/linear-gauge.component.js +7 -5
  90. package/esm2015/lib/heat-map/heat-map-cell-series.component.js +7 -3
  91. package/esm2015/lib/heat-map/heat-map-cell.component.js +9 -3
  92. package/esm2015/lib/heat-map/heat-map.component.js +4 -3
  93. package/esm2015/lib/heat-map/heat-map.module.js +1 -1
  94. package/esm2015/lib/line-chart/line-chart.component.js +5 -4
  95. package/esm2015/lib/line-chart/line-chart.module.js +1 -1
  96. package/esm2015/lib/line-chart/line-series.component.js +5 -3
  97. package/esm2015/lib/line-chart/line.component.js +1 -1
  98. package/esm2015/lib/models/chart-data.model.js +1 -1
  99. package/esm2015/lib/models/coordinates.model.js +2 -0
  100. package/esm2015/lib/ngx-charts.module.js +3 -1
  101. package/esm2015/lib/number-card/card-series.component.js +1 -1
  102. package/esm2015/lib/number-card/card.component.js +1 -1
  103. package/esm2015/lib/number-card/number-card.component.js +3 -3
  104. package/esm2015/lib/number-card/number-card.module.js +1 -1
  105. package/esm2015/lib/pie-chart/advanced-pie-chart.component.js +3 -3
  106. package/esm2015/lib/pie-chart/pie-arc.component.js +4 -8
  107. package/esm2015/lib/pie-chart/pie-chart.component.js +4 -3
  108. package/esm2015/lib/pie-chart/pie-chart.module.js +1 -1
  109. package/esm2015/lib/pie-chart/pie-grid-series.component.js +1 -1
  110. package/esm2015/lib/pie-chart/pie-grid.component.js +9 -5
  111. package/esm2015/lib/pie-chart/pie-label.component.js +2 -2
  112. package/esm2015/lib/pie-chart/pie-series.component.js +7 -3
  113. package/esm2015/lib/polar-chart/polar-chart.component.js +8 -5
  114. package/esm2015/lib/polar-chart/polar-chart.module.js +1 -1
  115. package/esm2015/lib/polar-chart/polar-series.component.js +10 -5
  116. package/esm2015/lib/polyfills.js +1 -1
  117. package/esm2015/lib/tree-map/tree-map-cell-series.component.js +7 -3
  118. package/esm2015/lib/tree-map/tree-map-cell.component.js +9 -3
  119. package/esm2015/lib/tree-map/tree-map.component.js +3 -3
  120. package/esm2015/lib/tree-map/tree-map.module.js +1 -1
  121. package/esm2015/lib/utils/calculate-width.js +1 -1
  122. package/esm2015/lib/utils/color-sets.js +2 -2
  123. package/esm2015/lib/utils/color-utils.js +1 -1
  124. package/esm2015/lib/utils/id.js +1 -1
  125. package/esm2015/lib/utils/sort.js +1 -1
  126. package/esm2015/lib/utils/throttle.js +1 -1
  127. package/esm2015/lib/utils/types.js +1 -1
  128. package/esm2015/lib/utils/visibility-observer.js +1 -1
  129. package/esm2015/public-api.js +13 -3
  130. package/esm2015/swimlane-ngx-charts.js +1 -2
  131. package/fesm2015/swimlane-ngx-charts.js +1109 -309
  132. package/fesm2015/swimlane-ngx-charts.js.map +1 -1
  133. package/lib/area-chart/area-chart-normalized.component.d.ts +7 -3
  134. package/lib/area-chart/area-chart-stacked.component.d.ts +5 -1
  135. package/lib/area-chart/area-chart.component.d.ts +7 -5
  136. package/lib/area-chart/area-series.component.d.ts +2 -1
  137. package/lib/bar-chart/bar-horizontal-2d.component.d.ts +7 -3
  138. package/lib/bar-chart/bar-horizontal-normalized.component.d.ts +7 -3
  139. package/lib/bar-chart/bar-horizontal-stacked.component.d.ts +7 -3
  140. package/lib/bar-chart/bar-horizontal.component.d.ts +3 -1
  141. package/lib/bar-chart/bar-label.component.d.ts +2 -1
  142. package/lib/bar-chart/bar-vertical-2d.component.d.ts +7 -3
  143. package/lib/bar-chart/bar-vertical-normalized.component.d.ts +7 -3
  144. package/lib/bar-chart/bar-vertical-stacked.component.d.ts +7 -3
  145. package/lib/bar-chart/bar-vertical.component.d.ts +4 -2
  146. package/lib/bar-chart/bar.component.d.ts +3 -8
  147. package/lib/bar-chart/series-horizontal.component.d.ts +8 -6
  148. package/lib/bar-chart/series-vertical.component.d.ts +6 -4
  149. package/lib/bar-chart/types/bar.model.d.ts +3 -1
  150. package/lib/box-chart/box-chart.component.d.ts +73 -0
  151. package/lib/box-chart/box-chart.module.d.ts +2 -0
  152. package/lib/box-chart/box-series.component.d.ts +39 -0
  153. package/lib/box-chart/box.component.d.ts +72 -0
  154. package/lib/bubble-chart/bubble-chart.component.d.ts +3 -1
  155. package/lib/bubble-chart/bubble-chart.utils.d.ts +3 -2
  156. package/lib/bubble-chart/bubble-series.component.d.ts +5 -1
  157. package/lib/common/area.component.d.ts +4 -2
  158. package/lib/common/axes/x-axis.component.d.ts +1 -1
  159. package/lib/common/base-chart.component.d.ts +5 -3
  160. package/lib/common/circle-series.component.d.ts +10 -4
  161. package/lib/common/circle.component.d.ts +4 -4
  162. package/lib/common/color.helper.d.ts +5 -3
  163. package/lib/common/domain.helper.d.ts +6 -1
  164. package/lib/common/grid-panel-series.component.d.ts +2 -5
  165. package/lib/common/legend/advanced-legend.component.d.ts +5 -5
  166. package/lib/common/legend/legend.component.d.ts +1 -1
  167. package/lib/common/svg-linear-gradient.component.d.ts +2 -6
  168. package/lib/common/timeline/timeline.component.d.ts +3 -7
  169. package/lib/common/tooltip/position/index.d.ts +1 -1
  170. package/lib/common/tooltip/position/{placement.type.d.ts → placement-type.enum.d.ts} +0 -0
  171. package/lib/common/tooltip/position/position.d.ts +1 -1
  172. package/lib/common/tooltip/style.type.d.ts +2 -2
  173. package/lib/common/tooltip/tooltip.directive.d.ts +1 -1
  174. package/lib/common/tooltip-area.component.d.ts +5 -1
  175. package/lib/common/types/bar-orientation.enum.d.ts +4 -0
  176. package/lib/common/view-dimensions.helper.d.ts +2 -1
  177. package/lib/events.d.ts +1 -4
  178. package/lib/gauge/gauge-arc.component.d.ts +4 -0
  179. package/lib/gauge/gauge-axis.component.d.ts +1 -1
  180. package/lib/gauge/gauge.component.d.ts +2 -1
  181. package/lib/gauge/linear-gauge.component.d.ts +3 -1
  182. package/lib/heat-map/heat-map-cell-series.component.d.ts +4 -0
  183. package/lib/heat-map/heat-map-cell.component.d.ts +3 -1
  184. package/lib/heat-map/heat-map.component.d.ts +4 -2
  185. package/lib/line-chart/line-chart.component.d.ts +3 -1
  186. package/lib/line-chart/line-series.component.d.ts +4 -1
  187. package/lib/models/chart-data.model.d.ts +28 -0
  188. package/lib/models/coordinates.model.d.ts +8 -0
  189. package/lib/number-card/card-series.component.d.ts +4 -1
  190. package/lib/number-card/number-card.component.d.ts +1 -1
  191. package/lib/pie-chart/advanced-pie-chart.component.d.ts +1 -1
  192. package/lib/pie-chart/pie-arc.component.d.ts +2 -1
  193. package/lib/pie-chart/pie-chart.component.d.ts +3 -2
  194. package/lib/pie-chart/pie-grid.component.d.ts +5 -1
  195. package/lib/pie-chart/pie-label.component.d.ts +1 -4
  196. package/lib/pie-chart/pie-series.component.d.ts +5 -1
  197. package/lib/polar-chart/polar-chart.component.d.ts +5 -1
  198. package/lib/polar-chart/polar-series.component.d.ts +6 -1
  199. package/lib/tree-map/tree-map-cell-series.component.d.ts +5 -1
  200. package/lib/tree-map/tree-map-cell.component.d.ts +3 -1
  201. package/lib/tree-map/tree-map.component.d.ts +1 -1
  202. package/lib/utils/color-sets.d.ts +1 -1
  203. package/package.json +10 -10
  204. package/public-api.d.ts +12 -2
  205. package/swimlane-ngx-charts.d.ts +0 -1
  206. package/swimlane-ngx-charts.metadata.json +1 -1
  207. package/bundles/swimlane-ngx-charts.umd.min.js +0 -16
  208. package/bundles/swimlane-ngx-charts.umd.min.js.map +0 -1
  209. package/esm2015/lib/common/tooltip/position/placement.type.js +0 -9
  210. package/esm2015/lib/common/types/index.js +0 -7
  211. package/lib/common/types/index.d.ts +0 -6
@@ -1,8 +1,33 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@angular/animations'), require('@angular/cdk/portal'), require('rxjs'), require('rxjs/operators'), require('d3-selection'), require('d3-brush'), require('d3-scale'), require('d3-shape'), require('d3-array'), require('d3-interpolate'), require('d3-format'), require('d3-color'), require('d3-hierarchy'), require('d3-time-format')) :
3
- typeof define === 'function' && define.amd ? define('@swimlane/ngx-charts', ['exports', '@angular/core', '@angular/common', '@angular/animations', '@angular/cdk/portal', 'rxjs', 'rxjs/operators', 'd3-selection', 'd3-brush', 'd3-scale', 'd3-shape', 'd3-array', 'd3-interpolate', 'd3-format', 'd3-color', 'd3-hierarchy', 'd3-time-format'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.swimlane = global.swimlane || {}, global.swimlane['ngx-charts'] = {}), global.ng.core, global.ng.common, global.ng.animations, global.ng.cdk.portal, global.rxjs, global.rxjs.operators, global.d3Selection, global.d3Brush, global.d3Scale, global.d3Shape, global.d3Array, global.d3Interpolate, global.d3Format, global.d3_color, global.d3Hierarchy, global.d3TimeFormat));
5
- }(this, (function (exports, core, common, animations, portal, rxjs, operators, d3Selection, d3Brush, d3Scale, d3Shape, d3Array, d3Interpolate, d3Format, d3_color, d3Hierarchy, d3TimeFormat) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@angular/cdk/portal'), require('rxjs'), require('rxjs/operators'), require('@angular/animations'), require('d3-selection'), require('d3-brush'), require('d3-scale'), require('d3-shape'), require('d3-array'), require('d3-interpolate'), require('d3-ease'), require('clone-deep'), require('d3-format'), require('d3-color'), require('d3-hierarchy'), require('d3-time-format')) :
3
+ typeof define === 'function' && define.amd ? define('@swimlane/ngx-charts', ['exports', '@angular/core', '@angular/common', '@angular/cdk/portal', 'rxjs', 'rxjs/operators', '@angular/animations', 'd3-selection', 'd3-brush', 'd3-scale', 'd3-shape', 'd3-array', 'd3-interpolate', 'd3-ease', 'clone-deep', 'd3-format', 'd3-color', 'd3-hierarchy', 'd3-time-format'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.swimlane = global.swimlane || {}, global.swimlane['ngx-charts'] = {}), global.ng.core, global.ng.common, global.ng.cdk.portal, global.rxjs, global.rxjs.operators, global.ng.animations, global['d3-selection'], global['d3-brush'], global['d3-scale'], global['d3-shape'], global['d3-array'], global['d3-interpolate'], global.d3Ease, global.cloneDeep, global['d3-format'], global['d3-color'], global['d3-hierarchy'], global['d3-time-format']));
5
+ }(this, (function (exports, core, common, portal, rxjs, operators, animations, d3Selection, d3Brush, d3Scale, d3Shape, d3Array, d3Interpolate, d3Ease, cloneDeep, d3Format, d3_color, d3Hierarchy, d3TimeFormat) { 'use strict';
6
+
7
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
8
+
9
+ function _interopNamespace(e) {
10
+ if (e && e.__esModule) return e;
11
+ var n = Object.create(null);
12
+ if (e) {
13
+ Object.keys(e).forEach(function (k) {
14
+ if (k !== 'default') {
15
+ var d = Object.getOwnPropertyDescriptor(e, k);
16
+ Object.defineProperty(n, k, d.get ? d : {
17
+ enumerable: true,
18
+ get: function () {
19
+ return e[k];
20
+ }
21
+ });
22
+ }
23
+ });
24
+ }
25
+ n['default'] = e;
26
+ return Object.freeze(n);
27
+ }
28
+
29
+ var cloneDeep__default = /*#__PURE__*/_interopDefaultLegacy(cloneDeep);
30
+ var d3_color__namespace = /*#__PURE__*/_interopNamespace(d3_color);
6
31
 
7
32
  /*! *****************************************************************************
8
33
  Copyright (c) Microsoft Corporation.
@@ -28,6 +53,8 @@
28
53
  return extendStatics(d, b);
29
54
  };
30
55
  function __extends(d, b) {
56
+ if (typeof b !== "function" && b !== null)
57
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
31
58
  extendStatics(d, b);
32
59
  function __() { this.constructor = d; }
33
60
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -213,11 +240,13 @@
213
240
  }
214
241
  return ar;
215
242
  }
243
+ /** @deprecated */
216
244
  function __spread() {
217
245
  for (var ar = [], i = 0; i < arguments.length; i++)
218
246
  ar = ar.concat(__read(arguments[i]));
219
247
  return ar;
220
248
  }
249
+ /** @deprecated */
221
250
  function __spreadArrays() {
222
251
  for (var s = 0, i = 0, il = arguments.length; i < il; i++)
223
252
  s += arguments[i].length;
@@ -226,7 +255,17 @@
226
255
  r[k] = a[j];
227
256
  return r;
228
257
  }
229
- ;
258
+ function __spreadArray(to, from, pack) {
259
+ if (pack || arguments.length === 2)
260
+ for (var i = 0, l = from.length, ar; i < l; i++) {
261
+ if (ar || !(i in from)) {
262
+ if (!ar)
263
+ ar = Array.prototype.slice.call(from, 0, i);
264
+ ar[i] = from[i];
265
+ }
266
+ }
267
+ return to.concat(ar || Array.prototype.slice.call(from));
268
+ }
230
269
  function __await(v) {
231
270
  return this instanceof __await ? (this.v = v, this) : new __await(v);
232
271
  }
@@ -291,18 +330,21 @@
291
330
  function __importDefault(mod) {
292
331
  return (mod && mod.__esModule) ? mod : { default: mod };
293
332
  }
294
- function __classPrivateFieldGet(receiver, privateMap) {
295
- if (!privateMap.has(receiver)) {
296
- throw new TypeError("attempted to get private field on non-instance");
297
- }
298
- return privateMap.get(receiver);
333
+ function __classPrivateFieldGet(receiver, state, kind, f) {
334
+ if (kind === "a" && !f)
335
+ throw new TypeError("Private accessor was defined without a getter");
336
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
337
+ throw new TypeError("Cannot read private member from an object whose class did not declare it");
338
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
299
339
  }
300
- function __classPrivateFieldSet(receiver, privateMap, value) {
301
- if (!privateMap.has(receiver)) {
302
- throw new TypeError("attempted to set private field on non-instance");
303
- }
304
- privateMap.set(receiver, value);
305
- return value;
340
+ function __classPrivateFieldSet(receiver, state, value, kind, f) {
341
+ if (kind === "m")
342
+ throw new TypeError("Private method is not writable");
343
+ if (kind === "a" && !f)
344
+ throw new TypeError("Private accessor was defined without a setter");
345
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
346
+ throw new TypeError("Cannot write private member to an object whose class did not declare it");
347
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
306
348
  }
307
349
 
308
350
  function isViewContainerRef(x) {
@@ -440,7 +482,7 @@
440
482
  if (!location)
441
483
  location = this.getRootViewContainer();
442
484
  var appendLocation = this.getComponentRootNode(location);
443
- var portalHost = new portal.DomPortalHost(appendLocation, this.componentFactoryResolver, this.applicationRef, this.injector);
485
+ var portalHost = new portal.DomPortalOutlet(appendLocation, this.componentFactoryResolver, this.applicationRef, this.injector);
444
486
  var portal$1 = new portal.ComponentPortal(componentClass);
445
487
  var componentRef = portalHost.attach(portal$1);
446
488
  this.projectComponentBindings(componentRef, bindings);
@@ -519,6 +561,7 @@
519
561
  };
520
562
  }
521
563
 
564
+ exports.PlacementTypes = void 0;
522
565
  (function (PlacementTypes) {
523
566
  PlacementTypes["Top"] = "top";
524
567
  PlacementTypes["Bottom"] = "bottom";
@@ -799,7 +842,7 @@
799
842
  selector: 'ngx-tooltip-content',
800
843
  template: "\n <div>\n <span #caretElm [hidden]=\"!showCaret\" class=\"tooltip-caret position-{{ this.placement }}\"> </span>\n <div class=\"tooltip-content\">\n <span *ngIf=\"!title\">\n <ng-template [ngTemplateOutlet]=\"template\" [ngTemplateOutletContext]=\"{ model: context }\"> </ng-template>\n </span>\n <span *ngIf=\"title\" [innerHTML]=\"title\"> </span>\n </div>\n </div>\n ",
801
844
  encapsulation: core.ViewEncapsulation.None,
802
- styles: [".ngx-charts-tooltip-content{border-radius:3px;display:block;font-weight:400;opacity:0;pointer-events:none!important;position:fixed;z-index:5000}.ngx-charts-tooltip-content.type-popover{background:#fff;border:1px solid #72809b;box-shadow:0 1px 3px 0 rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 2px 1px -1px rgba(0,0,0,.12);color:#060709;font-size:13px;padding:4px}.ngx-charts-tooltip-content.type-popover .tooltip-caret{height:0;position:absolute;width:0;z-index:5001}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-left{border-bottom:7px solid transparent;border-left:7px solid #fff;border-top:7px solid transparent}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-right{border-bottom:7px solid transparent;border-right:7px solid #fff;border-top:7px solid transparent}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-bottom{border-bottom:7px solid #fff;border-left:7px solid transparent;border-right:7px solid transparent}.ngx-charts-tooltip-content.type-tooltip{background:rgba(0,0,0,.75);color:#fff;font-size:12px;padding:0 10px;pointer-events:auto;text-align:center}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-left{border-bottom:7px solid transparent;border-left:7px solid rgba(0,0,0,.75);border-top:7px solid transparent}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-right{border-bottom:7px solid transparent;border-right:7px solid rgba(0,0,0,.75);border-top:7px solid transparent}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-bottom{border-bottom:7px solid rgba(0,0,0,.75);border-left:7px solid transparent;border-right:7px solid transparent}.ngx-charts-tooltip-content .tooltip-label{display:block;font-size:1em;line-height:1em;padding:8px 5px 5px}.ngx-charts-tooltip-content .tooltip-val{display:block;font-size:1.3em;line-height:1em;padding:0 5px 8px}.ngx-charts-tooltip-content .tooltip-caret{height:0;position:absolute;width:0;z-index:5001}.ngx-charts-tooltip-content.position-right{transform:translate3d(10px,0,0)}.ngx-charts-tooltip-content.position-left{transform:translate3d(-10px,0,0)}.ngx-charts-tooltip-content.position-top{transform:translate3d(0,-10px,0)}.ngx-charts-tooltip-content.position-bottom{transform:translate3d(0,10px,0)}.ngx-charts-tooltip-content.animate{opacity:1;pointer-events:auto;transform:translateZ(0);transition:opacity .3s,transform .3s}.area-tooltip-container{padding:5px 0;pointer-events:none}.tooltip-item{line-height:1.2em;padding:5px 0;text-align:left}.tooltip-item .tooltip-item-color{border-radius:3px;color:#5b646b;display:inline-block;height:12px;margin-right:5px;width:12px}"]
845
+ styles: [".ngx-charts-tooltip-content{position:fixed;border-radius:3px;z-index:5000;display:block;font-weight:normal;opacity:0;pointer-events:none!important}.ngx-charts-tooltip-content.type-popover{background:#fff;color:#060709;border:1px solid #72809b;box-shadow:0 1px 3px #0003,0 1px 1px #00000024,0 2px 1px -1px #0000001f;font-size:13px;padding:4px}.ngx-charts-tooltip-content.type-popover .tooltip-caret{position:absolute;z-index:5001;width:0;height:0}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-left{border-top:7px solid transparent;border-bottom:7px solid transparent;border-left:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-right{border-top:7px solid transparent;border-bottom:7px solid transparent;border-right:7px solid #fff}.ngx-charts-tooltip-content.type-popover .tooltip-caret.position-bottom{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid #fff}.ngx-charts-tooltip-content.type-tooltip{color:#fff;background:rgba(0,0,0,.75);font-size:12px;padding:0 10px;text-align:center;pointer-events:auto}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-left{border-top:7px solid transparent;border-bottom:7px solid transparent;border-left:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-top{border-left:7px solid transparent;border-right:7px solid transparent;border-top:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-right{border-top:7px solid transparent;border-bottom:7px solid transparent;border-right:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content.type-tooltip .tooltip-caret.position-bottom{border-left:7px solid transparent;border-right:7px solid transparent;border-bottom:7px solid rgba(0,0,0,.75)}.ngx-charts-tooltip-content .tooltip-label{display:block;line-height:1em;padding:8px 5px 5px;font-size:1em}.ngx-charts-tooltip-content .tooltip-val{display:block;font-size:1.3em;line-height:1em;padding:0 5px 8px}.ngx-charts-tooltip-content .tooltip-caret{position:absolute;z-index:5001;width:0;height:0}.ngx-charts-tooltip-content.position-right{transform:translate(10px)}.ngx-charts-tooltip-content.position-left{transform:translate(-10px)}.ngx-charts-tooltip-content.position-top{transform:translateY(-10px)}.ngx-charts-tooltip-content.position-bottom{transform:translateY(10px)}.ngx-charts-tooltip-content.animate{opacity:1;transition:opacity .3s,transform .3s;transform:translate(0);pointer-events:auto}.area-tooltip-container{padding:5px 0;pointer-events:none}.tooltip-item{text-align:left;line-height:1.2em;padding:5px 0}.tooltip-item .tooltip-item-color{display:inline-block;height:12px;width:12px;margin-right:5px;color:#5b646b;border-radius:3px}\n"]
803
846
  },] }
804
847
  ];
805
848
  TooltipContentComponent.ctorParameters = function () { return [
@@ -911,34 +954,24 @@
911
954
  { type: InjectionService }
912
955
  ]; };
913
956
 
957
+ exports.LegendPosition = void 0;
914
958
  (function (LegendPosition) {
915
959
  LegendPosition["Right"] = "right";
916
960
  LegendPosition["Below"] = "below";
917
961
  })(exports.LegendPosition || (exports.LegendPosition = {}));
962
+ exports.LegendType = void 0;
918
963
  (function (LegendType) {
919
964
  LegendType["ScaleLegend"] = "scaleLegend";
920
965
  LegendType["Legend"] = "legend";
921
966
  })(exports.LegendType || (exports.LegendType = {}));
922
967
 
923
- (function (Orientation) {
924
- Orientation["Top"] = "top";
925
- Orientation["Bottom"] = "bottom";
926
- Orientation["Left"] = "left";
927
- Orientation["Right"] = "right";
928
- })(exports.Orientation || (exports.Orientation = {}));
929
-
930
- (function (TextAnchor) {
931
- TextAnchor["Start"] = "start";
932
- TextAnchor["Middle"] = "middle";
933
- TextAnchor["End"] = "end";
934
- })(exports.TextAnchor || (exports.TextAnchor = {}));
935
-
968
+ exports.ScaleType = void 0;
936
969
  (function (ScaleType) {
937
970
  ScaleType["Time"] = "time";
938
971
  ScaleType["Linear"] = "linear";
939
972
  ScaleType["Ordinal"] = "ordinal";
940
973
  ScaleType["Quantile"] = "quantile";
941
- })(exports.ɵc || (exports.ɵc = {}));
974
+ })(exports.ScaleType || (exports.ScaleType = {}));
942
975
 
943
976
  var ChartComponent = /** @class */ (function () {
944
977
  function ChartComponent() {
@@ -974,7 +1007,7 @@
974
1007
  : this.chartWidth;
975
1008
  };
976
1009
  ChartComponent.prototype.getLegendType = function () {
977
- return this.legendOptions.scaleType === exports.ɵc.Linear ? exports.LegendType.ScaleLegend : exports.LegendType.Legend;
1010
+ return this.legendOptions.scaleType === exports.ScaleType.Linear ? exports.LegendType.ScaleLegend : exports.LegendType.Legend;
978
1011
  };
979
1012
  return ChartComponent;
980
1013
  }());
@@ -982,13 +1015,8 @@
982
1015
  { type: core.Component, args: [{
983
1016
  providers: [TooltipService],
984
1017
  selector: 'ngx-charts-chart',
985
- template: "\n <div class=\"ngx-charts-outer\" [style.width.px]=\"view[0]\" [@animationState]=\"'active'\" [@.disabled]=\"!animations\">\n <svg class=\"ngx-charts\" [attr.width]=\"chartWidth\" [attr.height]=\"view[1]\">\n <ng-content></ng-content>\n </svg>\n <ngx-charts-scale-legend\n *ngIf=\"showLegend && legendType === LegendType.ScaleLegend\"\n class=\"chart-legend\"\n [horizontal]=\"legendOptions && legendOptions.position === LegendPosition.Below\"\n [valueRange]=\"legendOptions.domain\"\n [colors]=\"legendOptions.colors\"\n [height]=\"view[1]\"\n [width]=\"legendWidth\"\n >\n </ngx-charts-scale-legend>\n <ngx-charts-legend\n *ngIf=\"showLegend && legendType === LegendType.Legend\"\n class=\"chart-legend\"\n [horizontal]=\"legendOptions && legendOptions.position === LegendPosition.Below\"\n [data]=\"legendOptions.domain\"\n [title]=\"legendOptions.title\"\n [colors]=\"legendOptions.colors\"\n [height]=\"view[1]\"\n [width]=\"legendWidth\"\n [activeEntries]=\"activeEntries\"\n (labelClick)=\"legendLabelClick.emit($event)\"\n (labelActivate)=\"legendLabelActivate.emit($event)\"\n (labelDeactivate)=\"legendLabelDeactivate.emit($event)\"\n >\n </ngx-charts-legend>\n </div>\n ",
986
- changeDetection: core.ChangeDetectionStrategy.OnPush,
987
- animations: [
988
- animations.trigger('animationState', [
989
- animations.transition(':enter', [animations.style({ opacity: 0 }), animations.animate('500ms 100ms', animations.style({ opacity: 1 }))])
990
- ])
991
- ]
1018
+ template: "\n <div class=\"ngx-charts-outer\" [style.width.px]=\"view[0]\">\n <svg class=\"ngx-charts\" [attr.width]=\"chartWidth\" [attr.height]=\"view[1]\">\n <ng-content></ng-content>\n </svg>\n <ngx-charts-scale-legend\n *ngIf=\"showLegend && legendType === LegendType.ScaleLegend\"\n class=\"chart-legend\"\n [horizontal]=\"legendOptions && legendOptions.position === LegendPosition.Below\"\n [valueRange]=\"legendOptions.domain\"\n [colors]=\"legendOptions.colors\"\n [height]=\"view[1]\"\n [width]=\"legendWidth\"\n >\n </ngx-charts-scale-legend>\n <ngx-charts-legend\n *ngIf=\"showLegend && legendType === LegendType.Legend\"\n class=\"chart-legend\"\n [horizontal]=\"legendOptions && legendOptions.position === LegendPosition.Below\"\n [data]=\"legendOptions.domain\"\n [title]=\"legendOptions.title\"\n [colors]=\"legendOptions.colors\"\n [height]=\"view[1]\"\n [width]=\"legendWidth\"\n [activeEntries]=\"activeEntries\"\n (labelClick)=\"legendLabelClick.emit($event)\"\n (labelActivate)=\"legendLabelActivate.emit($event)\"\n (labelDeactivate)=\"legendLabelDeactivate.emit($event)\"\n >\n </ngx-charts-legend>\n </div>\n ",
1019
+ changeDetection: core.ChangeDetectionStrategy.OnPush
992
1020
  },] }
993
1021
  ];
994
1022
  ChartComponent.propDecorators = {
@@ -1077,7 +1105,7 @@
1077
1105
  this.cd = cd;
1078
1106
  this.platformId = platformId;
1079
1107
  this.scheme = 'cool';
1080
- this.schemeType = exports.ɵc.Ordinal;
1108
+ this.schemeType = exports.ScaleType.Ordinal;
1081
1109
  this.animations = true;
1082
1110
  this.select = new core.EventEmitter();
1083
1111
  }
@@ -1088,7 +1116,7 @@
1088
1116
  };
1089
1117
  BaseChartComponent.prototype.ngAfterViewInit = function () {
1090
1118
  this.bindWindowResizeEvent();
1091
- // listen for visibility ofhe element for hidden by default scenario
1119
+ // listen for visibility of the element for hidden by default scenario
1092
1120
  this.visibilityObserver = new VisibilityObserver(this.chartElement, this.zone);
1093
1121
  this.visibilityObserver.visible.subscribe(this.update.bind(this));
1094
1122
  };
@@ -1262,6 +1290,14 @@
1262
1290
  select: [{ type: core.Output }]
1263
1291
  };
1264
1292
 
1293
+ exports.Orientation = void 0;
1294
+ (function (Orientation) {
1295
+ Orientation["Top"] = "top";
1296
+ Orientation["Bottom"] = "bottom";
1297
+ Orientation["Left"] = "left";
1298
+ Orientation["Right"] = "right";
1299
+ })(exports.Orientation || (exports.Orientation = {}));
1300
+
1265
1301
  var AxisLabelComponent = /** @class */ (function () {
1266
1302
  function AxisLabelComponent(element) {
1267
1303
  this.textHeight = 25;
@@ -1350,6 +1386,13 @@
1350
1386
  return ticks;
1351
1387
  }
1352
1388
 
1389
+ exports.TextAnchor = void 0;
1390
+ (function (TextAnchor) {
1391
+ TextAnchor["Start"] = "start";
1392
+ TextAnchor["Middle"] = "middle";
1393
+ TextAnchor["End"] = "end";
1394
+ })(exports.TextAnchor || (exports.TextAnchor = {}));
1395
+
1353
1396
  var XAxisTicksComponent = /** @class */ (function () {
1354
1397
  function XAxisTicksComponent(platformId) {
1355
1398
  this.platformId = platformId;
@@ -1524,7 +1567,7 @@
1524
1567
  this.tickStroke = '#ccc';
1525
1568
  this.strokeWidth = 'none';
1526
1569
  this.padding = 5;
1527
- this.Orientation = exports.Orientation;
1570
+ this.orientation = exports.Orientation;
1528
1571
  }
1529
1572
  XAxisComponent.prototype.ngOnChanges = function (changes) {
1530
1573
  this.update();
@@ -1551,7 +1594,7 @@
1551
1594
  XAxisComponent.decorators = [
1552
1595
  { type: core.Component, args: [{
1553
1596
  selector: 'g[ngx-charts-x-axis]',
1554
- template: "\n <svg:g [attr.class]=\"xAxisClassName\" [attr.transform]=\"transform\">\n <svg:g\n ngx-charts-x-axis-ticks\n *ngIf=\"xScale\"\n [trimTicks]=\"trimTicks\"\n [rotateTicks]=\"rotateTicks\"\n [maxTickLength]=\"maxTickLength\"\n [tickFormatting]=\"tickFormatting\"\n [tickArguments]=\"tickArguments\"\n [tickStroke]=\"tickStroke\"\n [scale]=\"xScale\"\n [orient]=\"xOrient\"\n [showGridLines]=\"showGridLines\"\n [gridLineHeight]=\"dims.height\"\n [width]=\"dims.width\"\n [tickValues]=\"ticks\"\n (dimensionsChanged)=\"emitTicksHeight($event)\"\n />\n <svg:g\n ngx-charts-axis-label\n *ngIf=\"showLabel\"\n [label]=\"labelText\"\n [offset]=\"labelOffset\"\n [orient]=\"Orientation.Bottom\"\n [height]=\"dims.height\"\n [width]=\"dims.width\"\n ></svg:g>\n </svg:g>\n ",
1597
+ template: "\n <svg:g [attr.class]=\"xAxisClassName\" [attr.transform]=\"transform\">\n <svg:g\n ngx-charts-x-axis-ticks\n *ngIf=\"xScale\"\n [trimTicks]=\"trimTicks\"\n [rotateTicks]=\"rotateTicks\"\n [maxTickLength]=\"maxTickLength\"\n [tickFormatting]=\"tickFormatting\"\n [tickArguments]=\"tickArguments\"\n [tickStroke]=\"tickStroke\"\n [scale]=\"xScale\"\n [orient]=\"xOrient\"\n [showGridLines]=\"showGridLines\"\n [gridLineHeight]=\"dims.height\"\n [width]=\"dims.width\"\n [tickValues]=\"ticks\"\n (dimensionsChanged)=\"emitTicksHeight($event)\"\n />\n <svg:g\n ngx-charts-axis-label\n *ngIf=\"showLabel\"\n [label]=\"labelText\"\n [offset]=\"labelOffset\"\n [orient]=\"orientation.Bottom\"\n [height]=\"dims.height\"\n [width]=\"dims.width\"\n ></svg:g>\n </svg:g>\n ",
1555
1598
  changeDetection: core.ChangeDetectionStrategy.OnPush
1556
1599
  },] }
1557
1600
  ];
@@ -1773,7 +1816,7 @@
1773
1816
  };
1774
1817
  YAxisTicksComponent.prototype.getApproximateAxisWidth = function () {
1775
1818
  var _this = this;
1776
- var maxChars = Math.max.apply(Math, __spread(this.ticks.map(function (t) { return _this.tickTrim(_this.tickFormat(t)).length; })));
1819
+ var maxChars = Math.max.apply(Math, __spreadArray([], __read(this.ticks.map(function (t) { return _this.tickTrim(_this.tickFormat(t)).length; }))));
1777
1820
  var charWidth = 7;
1778
1821
  return maxChars * charWidth;
1779
1822
  };
@@ -1897,11 +1940,13 @@
1897
1940
  },] }
1898
1941
  ];
1899
1942
 
1943
+ exports.StyleTypes = void 0;
1900
1944
  (function (StyleTypes) {
1901
- StyleTypes[StyleTypes["popover"] = 'popover'] = "popover";
1902
- StyleTypes[StyleTypes["tooltip"] = 'tooltip'] = "tooltip";
1945
+ StyleTypes["popover"] = "popover";
1946
+ StyleTypes["tooltip"] = "tooltip";
1903
1947
  })(exports.StyleTypes || (exports.StyleTypes = {}));
1904
1948
 
1949
+ exports.ShowTypes = void 0;
1905
1950
  (function (ShowTypes) {
1906
1951
  ShowTypes[ShowTypes["all"] = 'all'] = "all";
1907
1952
  ShowTypes[ShowTypes["focus"] = 'focus'] = "focus";
@@ -1914,7 +1959,6 @@
1914
1959
  this.viewContainerRef = viewContainerRef;
1915
1960
  this.renderer = renderer;
1916
1961
  this.tooltipCssClass = '';
1917
- this.tooltipTitle = '';
1918
1962
  this.tooltipAppendToBody = true;
1919
1963
  this.tooltipSpacing = 10;
1920
1964
  this.tooltipDisabled = false;
@@ -2171,19 +2215,28 @@
2171
2215
  return id();
2172
2216
  }
2173
2217
 
2174
- var SeriesType;
2218
+ exports.BarOrientation = void 0;
2219
+ (function (BarOrientation) {
2220
+ BarOrientation["Vertical"] = "vertical";
2221
+ BarOrientation["Horizontal"] = "horizontal";
2222
+ })(exports.BarOrientation || (exports.BarOrientation = {}));
2223
+
2224
+ exports.SeriesType = void 0;
2175
2225
  (function (SeriesType) {
2176
2226
  SeriesType["Standard"] = "standard";
2177
2227
  SeriesType["Stacked"] = "stacked";
2178
- })(SeriesType || (SeriesType = {}));
2228
+ })(exports.SeriesType || (exports.SeriesType = {}));
2179
2229
  var CircleSeriesComponent = /** @class */ (function () {
2180
2230
  function CircleSeriesComponent() {
2181
- this.type = SeriesType.Standard;
2231
+ this.type = exports.SeriesType.Standard;
2182
2232
  this.tooltipDisabled = false;
2183
2233
  this.select = new core.EventEmitter();
2184
2234
  this.activate = new core.EventEmitter();
2185
2235
  this.deactivate = new core.EventEmitter();
2186
2236
  this.barVisible = false;
2237
+ this.barOrientation = exports.BarOrientation;
2238
+ this.placementTypes = exports.PlacementTypes;
2239
+ this.styleTypes = exports.StyleTypes;
2187
2240
  }
2188
2241
  CircleSeriesComponent.prototype.ngOnInit = function () {
2189
2242
  this.gradientId = 'grad' + id().toString();
@@ -2213,22 +2266,22 @@
2213
2266
  var label = d.name;
2214
2267
  var tooltipLabel = formatLabel(label);
2215
2268
  var cx;
2216
- if (this.scaleType === exports.ɵc.Time) {
2269
+ if (this.scaleType === exports.ScaleType.Time) {
2217
2270
  cx = this.xScale(label);
2218
2271
  }
2219
- else if (this.scaleType === exports.ɵc.Linear) {
2272
+ else if (this.scaleType === exports.ScaleType.Linear) {
2220
2273
  cx = this.xScale(Number(label));
2221
2274
  }
2222
2275
  else {
2223
2276
  cx = this.xScale(label);
2224
2277
  }
2225
- var cy = this.yScale(this.type === SeriesType.Standard ? value : d.d1);
2278
+ var cy = this.yScale(this.type === exports.SeriesType.Standard ? value : d.d1);
2226
2279
  var radius = 5;
2227
2280
  var height = this.yScale.range()[0] - cy;
2228
2281
  var opacity = 1;
2229
2282
  var color;
2230
- if (this.colors.scaleType === exports.ɵc.Linear) {
2231
- if (this.type === SeriesType.Standard) {
2283
+ if (this.colors.scaleType === exports.ScaleType.Linear) {
2284
+ if (this.type === exports.SeriesType.Standard) {
2232
2285
  color = this.colors.getColor(value);
2233
2286
  }
2234
2287
  else {
@@ -2329,7 +2382,7 @@
2329
2382
  CircleSeriesComponent.decorators = [
2330
2383
  { type: core.Component, args: [{
2331
2384
  selector: 'g[ngx-charts-circle-series]',
2332
- template: "\n <svg:g *ngIf=\"circle\">\n <defs>\n <svg:g\n ngx-charts-svg-linear-gradient\n orientation=\"vertical\"\n [name]=\"gradientId\"\n [stops]=\"circle.gradientStops\"\n />\n </defs>\n <svg:rect\n *ngIf=\"barVisible && type === 'standard'\"\n [@animationState]=\"'active'\"\n [attr.x]=\"circle.cx - circle.radius\"\n [attr.y]=\"circle.cy\"\n [attr.width]=\"circle.radius * 2\"\n [attr.height]=\"circle.height\"\n [attr.fill]=\"gradientFill\"\n class=\"tooltip-bar\"\n />\n <svg:g\n ngx-charts-circle\n class=\"circle\"\n [cx]=\"circle.cx\"\n [cy]=\"circle.cy\"\n [r]=\"circle.radius\"\n [fill]=\"circle.color\"\n [class.active]=\"isActive({ name: circle.seriesName })\"\n [pointerEvents]=\"circle.value === 0 ? 'none' : 'all'\"\n [data]=\"circle.value\"\n [classNames]=\"circle.classNames\"\n (select)=\"onClick(circle.data)\"\n (activate)=\"activateCircle()\"\n (deactivate)=\"deactivateCircle()\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n />\n </svg:g>\n ",
2385
+ template: "\n <svg:g *ngIf=\"circle\">\n <defs>\n <svg:g\n ngx-charts-svg-linear-gradient\n [orientation]=\"barOrientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"circle.gradientStops\"\n />\n </defs>\n <svg:rect\n *ngIf=\"barVisible && type === 'standard'\"\n [@animationState]=\"'active'\"\n [attr.x]=\"circle.cx - circle.radius\"\n [attr.y]=\"circle.cy\"\n [attr.width]=\"circle.radius * 2\"\n [attr.height]=\"circle.height\"\n [attr.fill]=\"gradientFill\"\n class=\"tooltip-bar\"\n />\n <svg:g\n ngx-charts-circle\n class=\"circle\"\n [cx]=\"circle.cx\"\n [cy]=\"circle.cy\"\n [r]=\"circle.radius\"\n [fill]=\"circle.color\"\n [class.active]=\"isActive({ name: circle.seriesName })\"\n [pointerEvents]=\"circle.value === 0 ? 'none' : 'all'\"\n [data]=\"circle.value\"\n [classNames]=\"circle.classNames\"\n (select)=\"onClick(circle.data)\"\n (activate)=\"activateCircle()\"\n (deactivate)=\"deactivateCircle()\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n />\n </svg:g>\n ",
2333
2386
  changeDetection: core.ChangeDetectionStrategy.OnPush,
2334
2387
  animations: [
2335
2388
  animations.trigger('animationState', [
@@ -2424,11 +2477,6 @@
2424
2477
  y: [{ type: core.Input }]
2425
2478
  };
2426
2479
 
2427
- var GridOrientation;
2428
- (function (GridOrientation) {
2429
- GridOrientation["Vertical"] = "vertical";
2430
- GridOrientation["Horizontal"] = "horizontal";
2431
- })(GridOrientation || (GridOrientation = {}));
2432
2480
  var ClassEnum;
2433
2481
  (function (ClassEnum) {
2434
2482
  ClassEnum["Odd"] = "odd";
@@ -2452,7 +2500,7 @@
2452
2500
  var x;
2453
2501
  var y;
2454
2502
  var className = ClassEnum.Odd;
2455
- if (_this.orient === GridOrientation.Vertical) {
2503
+ if (_this.orient === exports.BarOrientation.Vertical) {
2456
2504
  var position = _this.xScale(d.name);
2457
2505
  var positionIndex = Number.parseInt((position / _this.xScale.step()).toString(), 10);
2458
2506
  if (positionIndex % 2 === 1) {
@@ -2464,7 +2512,7 @@
2464
2512
  x = _this.xScale(d.name) - offset / 2;
2465
2513
  y = 0;
2466
2514
  }
2467
- else if (_this.orient === GridOrientation.Horizontal) {
2515
+ else if (_this.orient === exports.BarOrientation.Horizontal) {
2468
2516
  var position = _this.yScale(d.name);
2469
2517
  var positionIndex = Number.parseInt((position / _this.yScale.step()).toString(), 10);
2470
2518
  if (positionIndex % 2 === 1) {
@@ -2503,24 +2551,19 @@
2503
2551
  orient: [{ type: core.Input }]
2504
2552
  };
2505
2553
 
2506
- var Orientation;
2507
- (function (Orientation) {
2508
- Orientation["Vertical"] = "vertical";
2509
- Orientation["Horizontal"] = "horizontal";
2510
- })(Orientation || (Orientation = {}));
2511
2554
  var SvgLinearGradientComponent = /** @class */ (function () {
2512
2555
  function SvgLinearGradientComponent() {
2513
- this.orientation = Orientation.Vertical;
2556
+ this.orientation = exports.BarOrientation.Vertical;
2514
2557
  }
2515
2558
  SvgLinearGradientComponent.prototype.ngOnChanges = function (changes) {
2516
2559
  this.x1 = '0%';
2517
2560
  this.x2 = '0%';
2518
2561
  this.y1 = '0%';
2519
2562
  this.y2 = '0%';
2520
- if (this.orientation === Orientation.Horizontal) {
2563
+ if (this.orientation === exports.BarOrientation.Horizontal) {
2521
2564
  this.x2 = '100%';
2522
2565
  }
2523
- else if (this.orientation === Orientation.Vertical) {
2566
+ else if (this.orientation === exports.BarOrientation.Vertical) {
2524
2567
  this.y1 = '100%';
2525
2568
  }
2526
2569
  };
@@ -2599,17 +2642,16 @@
2599
2642
  this.gradient = false;
2600
2643
  this.animations = true;
2601
2644
  this.select = new core.EventEmitter();
2602
- this.initialized = false;
2645
+ this.animationsLoaded = false;
2603
2646
  this.hasGradient = false;
2647
+ this.barOrientation = exports.BarOrientation;
2604
2648
  this.element = element.nativeElement;
2605
2649
  }
2606
2650
  AreaComponent.prototype.ngOnChanges = function () {
2607
- if (!this.initialized) {
2651
+ this.update();
2652
+ if (!this.animationsLoaded) {
2608
2653
  this.loadAnimation();
2609
- this.initialized = true;
2610
- }
2611
- else {
2612
- this.update();
2654
+ this.animationsLoaded = true;
2613
2655
  }
2614
2656
  };
2615
2657
  AreaComponent.prototype.update = function () {
@@ -2626,7 +2668,7 @@
2626
2668
  };
2627
2669
  AreaComponent.prototype.loadAnimation = function () {
2628
2670
  this.areaPath = this.startingPath;
2629
- setTimeout(this.update.bind(this), 100);
2671
+ setTimeout(this.updatePathEl.bind(this), 100);
2630
2672
  };
2631
2673
  AreaComponent.prototype.updatePathEl = function () {
2632
2674
  var node = d3Selection.select(this.element).select('.area');
@@ -2659,7 +2701,7 @@
2659
2701
  AreaComponent.decorators = [
2660
2702
  { type: core.Component, args: [{
2661
2703
  selector: 'g[ngx-charts-area]',
2662
- template: "\n <svg:defs *ngIf=\"gradient\">\n <svg:g ngx-charts-svg-linear-gradient orientation=\"vertical\" [name]=\"gradientId\" [stops]=\"gradientStops\" />\n </svg:defs>\n <svg:path class=\"area\" [attr.d]=\"areaPath\" [attr.fill]=\"gradient ? gradientFill : fill\" [style.opacity]=\"opacity\" />\n ",
2704
+ template: "\n <svg:defs *ngIf=\"gradient\">\n <svg:g\n ngx-charts-svg-linear-gradient\n [orientation]=\"barOrientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n </svg:defs>\n <svg:path class=\"area\" [attr.d]=\"areaPath\" [attr.fill]=\"gradient ? gradientFill : fill\" [style.opacity]=\"opacity\" />\n ",
2663
2705
  changeDetection: core.ChangeDetectionStrategy.OnPush
2664
2706
  },] }
2665
2707
  ];
@@ -2873,6 +2915,8 @@
2873
2915
  this.anchorOpacity = 0;
2874
2916
  this.anchorPos = -1;
2875
2917
  this.anchorValues = [];
2918
+ this.placementTypes = exports.PlacementTypes;
2919
+ this.styleTypes = exports.StyleTypes;
2876
2920
  this.showPercentage = false;
2877
2921
  this.tooltipDisabled = false;
2878
2922
  this.hover = new core.EventEmitter();
@@ -2895,7 +2939,7 @@
2895
2939
  val = (item.d1 - item.d0).toFixed(2) + '%';
2896
2940
  }
2897
2941
  var color = void 0;
2898
- if (this.colors.scaleType === exports.ɵc.Linear) {
2942
+ if (this.colors.scaleType === exports.ScaleType.Linear) {
2899
2943
  var v = val;
2900
2944
  if (item.d1) {
2901
2945
  v = item.d1;
@@ -3023,7 +3067,7 @@
3023
3067
  TooltipArea.decorators = [
3024
3068
  { type: core.Component, args: [{
3025
3069
  selector: 'g[ngx-charts-tooltip-area]',
3026
- template: "\n <svg:g>\n <svg:rect\n class=\"tooltip-area\"\n [attr.x]=\"0\"\n y=\"0\"\n [attr.width]=\"dims.width\"\n [attr.height]=\"dims.height\"\n style=\"opacity: 0; cursor: 'auto';\"\n (mousemove)=\"mouseMove($event)\"\n (mouseleave)=\"hideTooltip()\"\n />\n <ng-template #defaultTooltipTemplate let-model=\"model\">\n <xhtml:div class=\"area-tooltip-container\">\n <xhtml:div *ngFor=\"let tooltipItem of model\" class=\"tooltip-item\">\n <xhtml:span class=\"tooltip-item-color\" [style.background-color]=\"tooltipItem.color\"></xhtml:span>\n {{ getToolTipText(tooltipItem) }}\n </xhtml:div>\n </xhtml:div>\n </ng-template>\n <svg:rect\n #tooltipAnchor\n [@animationState]=\"anchorOpacity !== 0 ? 'active' : 'inactive'\"\n class=\"tooltip-anchor\"\n [attr.x]=\"anchorPos\"\n y=\"0\"\n [attr.width]=\"1\"\n [attr.height]=\"dims.height\"\n [style.opacity]=\"anchorOpacity\"\n [style.pointer-events]=\"'none'\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'right'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipSpacing]=\"15\"\n [tooltipTemplate]=\"tooltipTemplate ? tooltipTemplate : defaultTooltipTemplate\"\n [tooltipContext]=\"anchorValues\"\n [tooltipImmediateExit]=\"true\"\n />\n </svg:g>\n ",
3070
+ template: "\n <svg:g>\n <svg:rect\n class=\"tooltip-area\"\n [attr.x]=\"0\"\n y=\"0\"\n [attr.width]=\"dims.width\"\n [attr.height]=\"dims.height\"\n style=\"opacity: 0; cursor: 'auto';\"\n (mousemove)=\"mouseMove($event)\"\n (mouseleave)=\"hideTooltip()\"\n />\n <ng-template #defaultTooltipTemplate let-model=\"model\">\n <xhtml:div class=\"area-tooltip-container\">\n <xhtml:div *ngFor=\"let tooltipItem of model\" class=\"tooltip-item\">\n <xhtml:span class=\"tooltip-item-color\" [style.background-color]=\"tooltipItem.color\"></xhtml:span>\n {{ getToolTipText(tooltipItem) }}\n </xhtml:div>\n </xhtml:div>\n </ng-template>\n <svg:rect\n #tooltipAnchor\n [@animationState]=\"anchorOpacity !== 0 ? 'active' : 'inactive'\"\n class=\"tooltip-anchor\"\n [attr.x]=\"anchorPos\"\n y=\"0\"\n [attr.width]=\"1\"\n [attr.height]=\"dims.height\"\n [style.opacity]=\"anchorOpacity\"\n [style.pointer-events]=\"'none'\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Right\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipSpacing]=\"15\"\n [tooltipTemplate]=\"tooltipTemplate ? tooltipTemplate : defaultTooltipTemplate\"\n [tooltipContext]=\"anchorValues\"\n [tooltipImmediateExit]=\"true\"\n />\n </svg:g>\n ",
3027
3071
  changeDetection: core.ChangeDetectionStrategy.OnPush,
3028
3072
  animations: [
3029
3073
  animations.trigger('animationState', [
@@ -3060,11 +3104,6 @@
3060
3104
  tooltipAnchor: [{ type: core.ViewChild, args: ['tooltipAnchor', { static: false },] }]
3061
3105
  };
3062
3106
 
3063
- (function (TimelineScaleType) {
3064
- TimelineScaleType["Time"] = "time";
3065
- TimelineScaleType["Linear"] = "linear";
3066
- TimelineScaleType["Ordinal"] = "ordinal";
3067
- })(exports.TimelineScaleType || (exports.TimelineScaleType = {}));
3068
3107
  var Timeline = /** @class */ (function () {
3069
3108
  function Timeline(element, cd) {
3070
3109
  this.cd = cd;
@@ -3126,15 +3165,15 @@
3126
3165
  finally { if (e_1) throw e_1.error; }
3127
3166
  }
3128
3167
  var domain = [];
3129
- if (this.scaleType === exports.TimelineScaleType.Time) {
3130
- var min = Math.min.apply(Math, __spread(values));
3131
- var max = Math.max.apply(Math, __spread(values));
3168
+ if (this.scaleType === exports.ScaleType.Time) {
3169
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
3170
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
3132
3171
  domain = [min, max];
3133
3172
  }
3134
- else if (this.scaleType === exports.TimelineScaleType.Linear) {
3173
+ else if (this.scaleType === exports.ScaleType.Linear) {
3135
3174
  values = values.map(function (v) { return Number(v); });
3136
- var min = Math.min.apply(Math, __spread(values));
3137
- var max = Math.max.apply(Math, __spread(values));
3175
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
3176
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
3138
3177
  domain = [min, max];
3139
3178
  }
3140
3179
  else {
@@ -3144,13 +3183,13 @@
3144
3183
  };
3145
3184
  Timeline.prototype.getXScale = function () {
3146
3185
  var scale;
3147
- if (this.scaleType === exports.TimelineScaleType.Time) {
3186
+ if (this.scaleType === exports.ScaleType.Time) {
3148
3187
  scale = d3Scale.scaleTime().range([0, this.dims.width]).domain(this.xDomain);
3149
3188
  }
3150
- else if (this.scaleType === exports.TimelineScaleType.Linear) {
3189
+ else if (this.scaleType === exports.ScaleType.Linear) {
3151
3190
  scale = d3Scale.scaleLinear().range([0, this.dims.width]).domain(this.xDomain);
3152
3191
  }
3153
- else if (this.scaleType === exports.TimelineScaleType.Ordinal) {
3192
+ else if (this.scaleType === exports.ScaleType.Ordinal) {
3154
3193
  scale = d3Scale.scalePoint().range([0, this.dims.width]).padding(0.1).domain(this.xDomain);
3155
3194
  }
3156
3195
  return scale;
@@ -3209,7 +3248,7 @@
3209
3248
  template: "\n <svg:g class=\"timeline\" [attr.transform]=\"transform\">\n <svg:filter [attr.id]=\"filterId\">\n <svg:feColorMatrix\n in=\"SourceGraphic\"\n type=\"matrix\"\n values=\"0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0\"\n />\n </svg:filter>\n <svg:g class=\"embedded-chart\">\n <ng-content></ng-content>\n </svg:g>\n <svg:rect x=\"0\" [attr.width]=\"view[0]\" y=\"0\" [attr.height]=\"height\" class=\"brush-background\" />\n <svg:g class=\"brush\"></svg:g>\n </svg:g>\n ",
3210
3249
  encapsulation: core.ViewEncapsulation.None,
3211
3250
  changeDetection: core.ChangeDetectionStrategy.OnPush,
3212
- styles: [".timeline .brush-background{fill:rgba(0,0,0,.05)}.timeline .brush .selection{fill:rgba(0,0,0,.1);stroke:#888;stroke-width:1px}.timeline .brush .handle{fill-opacity:0}.timeline .embedded-chart{opacity:.6}"]
3251
+ styles: [".timeline .brush-background{fill:#0000000d}.timeline .brush .selection{fill:#0000001a;stroke-width:1px;stroke:#888}.timeline .brush .handle{fill-opacity:0}.timeline .embedded-chart{opacity:.6}\n"]
3213
3252
  },] }
3214
3253
  ];
3215
3254
  Timeline.ctorParameters = function () { return [
@@ -3302,7 +3341,7 @@
3302
3341
  template: "\n <div [style.width.px]=\"width\">\n <header class=\"legend-title\" *ngIf=\"title?.length > 0\">\n <span class=\"legend-title-text\">{{ title }}</span>\n </header>\n <div class=\"legend-wrap\">\n <ul class=\"legend-labels\" [class.horizontal-legend]=\"horizontal\" [style.max-height.px]=\"height - 45\">\n <li *ngFor=\"let entry of legendEntries; trackBy: trackBy\" class=\"legend-label\">\n <ngx-charts-legend-entry\n [label]=\"entry.label\"\n [formattedLabel]=\"entry.formattedLabel\"\n [color]=\"entry.color\"\n [isActive]=\"isActive(entry)\"\n (select)=\"labelClick.emit($event)\"\n (activate)=\"activate($event)\"\n (deactivate)=\"deactivate($event)\"\n >\n </ngx-charts-legend-entry>\n </li>\n </ul>\n </div>\n </div>\n ",
3303
3342
  encapsulation: core.ViewEncapsulation.None,
3304
3343
  changeDetection: core.ChangeDetectionStrategy.OnPush,
3305
- styles: [".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .legend-title{font-size:14px;font-weight:700;margin-bottom:5px;margin-left:10px;overflow:hidden;white-space:nowrap}.chart-legend li,.chart-legend ul{list-style:none;margin:0;padding:0}.chart-legend .horizontal-legend li{display:inline-block}.chart-legend .legend-wrap{width:calc(100% - 10px)}.chart-legend .legend-labels{background:rgba(0,0,0,.05);border-radius:3px;float:left;line-height:85%;list-style:none;overflow-x:hidden;overflow-y:auto;text-align:left;white-space:nowrap;width:100%}.chart-legend .legend-label{color:#afb7c8;cursor:pointer;font-size:90%;margin:8px}.chart-legend .legend-label:hover{color:#000;transition:.2s}.chart-legend .legend-label .active .legend-label-text{color:#000}.chart-legend .legend-label-color{border-radius:3px;color:#5b646b;display:inline-block;height:15px;margin-right:5px;width:15px}.chart-legend .legend-label-text{font-size:12px;line-height:15px;vertical-align:top;width:calc(100% - 20px)}.chart-legend .legend-label-text,.chart-legend .legend-title-text{display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chart-legend .legend-title-text{line-height:16px;vertical-align:bottom}"]
3344
+ styles: [".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .legend-title{white-space:nowrap;overflow:hidden;margin-left:10px;margin-bottom:5px;font-size:14px;font-weight:bold}.chart-legend ul,.chart-legend li{padding:0;margin:0;list-style:none}.chart-legend .horizontal-legend li{display:inline-block}.chart-legend .legend-wrap{width:calc(100% - 10px)}.chart-legend .legend-labels{line-height:85%;list-style:none;text-align:left;float:left;width:100%;border-radius:3px;overflow-y:auto;overflow-x:hidden;white-space:nowrap;background:rgba(0,0,0,.05)}.chart-legend .legend-label{cursor:pointer;font-size:90%;margin:8px;color:#afb7c8}.chart-legend .legend-label:hover{color:#000;transition:.2s}.chart-legend .legend-label .active .legend-label-text{color:#000}.chart-legend .legend-label-color{display:inline-block;height:15px;width:15px;margin-right:5px;color:#5b646b;border-radius:3px}.chart-legend .legend-label-text{display:inline-block;vertical-align:top;line-height:15px;font-size:12px;width:calc(100% - 20px);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.chart-legend .legend-title-text{vertical-align:bottom;display:inline-block;line-height:16px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"]
3306
3345
  },] }
3307
3346
  ];
3308
3347
  LegendComponent.ctorParameters = function () { return [
@@ -3395,7 +3434,7 @@
3395
3434
  template: "\n <div\n class=\"scale-legend\"\n [class.horizontal-legend]=\"horizontal\"\n [style.height.px]=\"horizontal ? undefined : height\"\n [style.width.px]=\"width\"\n >\n <div class=\"scale-legend-label\">\n <span>{{ valueRange[1].toLocaleString() }}</span>\n </div>\n <div class=\"scale-legend-wrap\" [style.background]=\"gradient\"></div>\n <div class=\"scale-legend-label\">\n <span>{{ valueRange[0].toLocaleString() }}</span>\n </div>\n </div>\n ",
3396
3435
  encapsulation: core.ViewEncapsulation.None,
3397
3436
  changeDetection: core.ChangeDetectionStrategy.OnPush,
3398
- styles: [".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .scale-legend{display:flex;flex-direction:column;text-align:center}.chart-legend .scale-legend-wrap{border-radius:5px;display:inline-block;flex:1;margin:0 auto;width:30px}.chart-legend .scale-legend-label{font-size:12px}.chart-legend .horizontal-legend.scale-legend{flex-direction:row}.chart-legend .horizontal-legend .scale-legend-wrap{height:30px;margin:0 16px;width:auto}"]
3437
+ styles: [".chart-legend{display:inline-block;padding:0;width:auto!important}.chart-legend .scale-legend{text-align:center;display:flex;flex-direction:column}.chart-legend .scale-legend-wrap{display:inline-block;flex:1;width:30px;border-radius:5px;margin:0 auto}.chart-legend .scale-legend-label{font-size:12px}.chart-legend .horizontal-legend.scale-legend{flex-direction:row}.chart-legend .horizontal-legend .scale-legend-wrap{width:auto;height:30px;margin:0 16px}\n"]
3399
3438
  },] }
3400
3439
  ];
3401
3440
  ScaleLegendComponent.propDecorators = {
@@ -3449,7 +3488,7 @@
3449
3488
  };
3450
3489
  });
3451
3490
  };
3452
- AdvancedLegendComponent.prototype.trackBy = function (item) {
3491
+ AdvancedLegendComponent.prototype.trackBy = function (index, item) {
3453
3492
  return item.label;
3454
3493
  };
3455
3494
  return AdvancedLegendComponent;
@@ -3460,7 +3499,7 @@
3460
3499
  template: "\n <div class=\"advanced-pie-legend\" [style.width.px]=\"width\">\n <div\n *ngIf=\"animations\"\n class=\"total-value\"\n ngx-charts-count-up\n [countTo]=\"roundedTotal\"\n [valueFormatting]=\"valueFormatting\"\n ></div>\n <div class=\"total-value\" *ngIf=\"!animations\">\n {{ valueFormatting ? valueFormatting(roundedTotal) : defaultValueFormatting(roundedTotal) }}\n </div>\n <div class=\"total-label\">\n {{ label }}\n </div>\n <div class=\"legend-items-container\">\n <div class=\"legend-items\">\n <div\n *ngFor=\"let legendItem of legendItems; trackBy: trackBy\"\n tabindex=\"-1\"\n class=\"legend-item\"\n (mouseenter)=\"activate.emit(legendItem.data)\"\n (mouseleave)=\"deactivate.emit(legendItem.data)\"\n (click)=\"select.emit(legendItem.data)\"\n >\n <div class=\"item-color\" [style.border-left-color]=\"legendItem.color\"></div>\n <div\n *ngIf=\"animations\"\n class=\"item-value\"\n ngx-charts-count-up\n [countTo]=\"legendItem._value\"\n [valueFormatting]=\"valueFormatting\"\n ></div>\n <div *ngIf=\"!animations\" class=\"item-value\">\n {{ valueFormatting ? valueFormatting(legendItem.value) : defaultValueFormatting(legendItem.value) }}\n </div>\n <div class=\"item-label\">{{ legendItem.displayLabel }}</div>\n <div\n *ngIf=\"animations\"\n class=\"item-percent\"\n ngx-charts-count-up\n [countTo]=\"legendItem.percentage\"\n [countSuffix]=\"'%'\"\n ></div>\n <div *ngIf=\"!animations\" class=\"item-percent\">{{ legendItem.percentage.toLocaleString() }}%</div>\n </div>\n </div>\n </div>\n </div>\n ",
3461
3500
  encapsulation: core.ViewEncapsulation.None,
3462
3501
  changeDetection: core.ChangeDetectionStrategy.OnPush,
3463
- styles: [".advanced-pie-legend{float:left;position:relative;top:50%;transform:translateY(-50%)}.advanced-pie-legend .total-value{font-size:36px}.advanced-pie-legend .total-label{font-size:24px;margin-bottom:19px}.advanced-pie-legend .legend-items-container{width:100%}.advanced-pie-legend .legend-items-container .legend-items{overflow:auto;white-space:nowrap}.advanced-pie-legend .legend-items-container .legend-items .legend-item{cursor:pointer;display:inline-block;margin-right:20px}.advanced-pie-legend .legend-items-container .legend-items .legend-item:focus{outline:none}.advanced-pie-legend .legend-items-container .legend-items .legend-item:hover{color:#000;transition:.2s}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-value{font-size:24px;margin-left:11px;margin-top:-6px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-label{font-size:14px;margin-left:11px;margin-top:-6px;opacity:.7}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-percent{font-size:24px;margin-left:11px;opacity:.7}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-color{border-left:4px solid;float:left;height:42px;margin-right:7px;width:4px}"]
3502
+ styles: [".advanced-pie-legend{float:left;position:relative;top:50%;transform:translateY(-50%)}.advanced-pie-legend .total-value{font-size:36px}.advanced-pie-legend .total-label{font-size:24px;margin-bottom:19px}.advanced-pie-legend .legend-items-container{width:100%}.advanced-pie-legend .legend-items-container .legend-items{white-space:nowrap;overflow:auto}.advanced-pie-legend .legend-items-container .legend-items .legend-item{margin-right:20px;display:inline-block;cursor:pointer}.advanced-pie-legend .legend-items-container .legend-items .legend-item:focus{outline:none}.advanced-pie-legend .legend-items-container .legend-items .legend-item:hover{color:#000;transition:.2s}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-value{font-size:24px;margin-top:-6px;margin-left:11px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-label{font-size:14px;opacity:.7;margin-left:11px;margin-top:-6px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-percent{font-size:24px;opacity:.7;margin-left:11px}.advanced-pie-legend .legend-items-container .legend-items .legend-item .item-color{border-left:4px solid;width:4px;height:42px;float:left;margin-right:7px}\n"]
3464
3503
  },] }
3465
3504
  ];
3466
3505
  AdvancedLegendComponent.propDecorators = {
@@ -3503,18 +3542,18 @@
3503
3542
  ChartCommonModule.decorators = [
3504
3543
  { type: core.NgModule, args: [{
3505
3544
  imports: [common.CommonModule, AxesModule, TooltipModule],
3506
- declarations: __spread(COMPONENTS, [VisibilityObserver]),
3507
- exports: __spread([common.CommonModule, AxesModule, TooltipModule], COMPONENTS, [VisibilityObserver])
3545
+ declarations: __spreadArray(__spreadArray([], __read(COMPONENTS)), [VisibilityObserver]),
3546
+ exports: __spreadArray(__spreadArray([common.CommonModule, AxesModule, TooltipModule], __read(COMPONENTS)), [VisibilityObserver])
3508
3547
  },] }
3509
3548
  ];
3510
3549
 
3511
3550
  function calculateViewDimensions(_a) {
3512
- var width = _a.width, height = _a.height, margins = _a.margins, _b = _a.showXAxis, showXAxis = _b === void 0 ? false : _b, _c = _a.showYAxis, showYAxis = _c === void 0 ? false : _c, _d = _a.xAxisHeight, xAxisHeight = _d === void 0 ? 0 : _d, _e = _a.yAxisWidth, yAxisWidth = _e === void 0 ? 0 : _e, _f = _a.showXLabel, showXLabel = _f === void 0 ? false : _f, _g = _a.showYLabel, showYLabel = _g === void 0 ? false : _g, _h = _a.showLegend, showLegend = _h === void 0 ? false : _h, _j = _a.legendType, legendType = _j === void 0 ? exports.ɵc.Ordinal : _j, _k = _a.legendPosition, legendPosition = _k === void 0 ? exports.LegendPosition.Right : _k, _l = _a.columns, columns = _l === void 0 ? 12 : _l;
3551
+ var width = _a.width, height = _a.height, margins = _a.margins, _b = _a.showXAxis, showXAxis = _b === void 0 ? false : _b, _c = _a.showYAxis, showYAxis = _c === void 0 ? false : _c, _d = _a.xAxisHeight, xAxisHeight = _d === void 0 ? 0 : _d, _e = _a.yAxisWidth, yAxisWidth = _e === void 0 ? 0 : _e, _f = _a.showXLabel, showXLabel = _f === void 0 ? false : _f, _g = _a.showYLabel, showYLabel = _g === void 0 ? false : _g, _h = _a.showLegend, showLegend = _h === void 0 ? false : _h, _j = _a.legendType, legendType = _j === void 0 ? exports.ScaleType.Ordinal : _j, _k = _a.legendPosition, legendPosition = _k === void 0 ? exports.LegendPosition.Right : _k, _l = _a.columns, columns = _l === void 0 ? 12 : _l;
3513
3552
  var xOffset = margins[3];
3514
3553
  var chartWidth = width;
3515
3554
  var chartHeight = height - margins[0] - margins[2];
3516
3555
  if (showLegend && legendPosition === exports.LegendPosition.Right) {
3517
- if (legendType === exports.ɵc.Ordinal) {
3556
+ if (legendType === exports.ScaleType.Ordinal) {
3518
3557
  columns -= 2;
3519
3558
  }
3520
3559
  else {
@@ -3557,7 +3596,7 @@
3557
3596
  {
3558
3597
  name: 'vivid',
3559
3598
  selectable: true,
3560
- group: exports.ɵc.Ordinal,
3599
+ group: exports.ScaleType.Ordinal,
3561
3600
  domain: [
3562
3601
  '#647c8a',
3563
3602
  '#3f51b5',
@@ -3574,7 +3613,7 @@
3574
3613
  {
3575
3614
  name: 'natural',
3576
3615
  selectable: true,
3577
- group: exports.ɵc.Ordinal,
3616
+ group: exports.ScaleType.Ordinal,
3578
3617
  domain: [
3579
3618
  '#bf9d76',
3580
3619
  '#e99450',
@@ -3591,7 +3630,7 @@
3591
3630
  {
3592
3631
  name: 'cool',
3593
3632
  selectable: true,
3594
- group: exports.ɵc.Ordinal,
3633
+ group: exports.ScaleType.Ordinal,
3595
3634
  domain: [
3596
3635
  '#a8385d',
3597
3636
  '#7aa3e5',
@@ -3608,13 +3647,13 @@
3608
3647
  {
3609
3648
  name: 'fire',
3610
3649
  selectable: true,
3611
- group: exports.ɵc.Ordinal,
3650
+ group: exports.ScaleType.Ordinal,
3612
3651
  domain: ['#ff3d00', '#bf360c', '#ff8f00', '#ff6f00', '#ff5722', '#e65100', '#ffca28', '#ffab00']
3613
3652
  },
3614
3653
  {
3615
3654
  name: 'solar',
3616
3655
  selectable: true,
3617
- group: exports.ɵc.Linear,
3656
+ group: exports.ScaleType.Linear,
3618
3657
  domain: [
3619
3658
  '#fff8e1',
3620
3659
  '#ffecb3',
@@ -3631,7 +3670,7 @@
3631
3670
  {
3632
3671
  name: 'air',
3633
3672
  selectable: true,
3634
- group: exports.ɵc.Linear,
3673
+ group: exports.ScaleType.Linear,
3635
3674
  domain: [
3636
3675
  '#e1f5fe',
3637
3676
  '#b3e5fc',
@@ -3648,7 +3687,7 @@
3648
3687
  {
3649
3688
  name: 'aqua',
3650
3689
  selectable: true,
3651
- group: exports.ɵc.Linear,
3690
+ group: exports.ScaleType.Linear,
3652
3691
  domain: [
3653
3692
  '#e0f7fa',
3654
3693
  '#b2ebf2',
@@ -3665,7 +3704,7 @@
3665
3704
  {
3666
3705
  name: 'flame',
3667
3706
  selectable: false,
3668
- group: exports.ɵc.Ordinal,
3707
+ group: exports.ScaleType.Ordinal,
3669
3708
  domain: [
3670
3709
  '#A10A28',
3671
3710
  '#D3342D',
@@ -3682,7 +3721,7 @@
3682
3721
  {
3683
3722
  name: 'ocean',
3684
3723
  selectable: false,
3685
- group: exports.ɵc.Ordinal,
3724
+ group: exports.ScaleType.Ordinal,
3686
3725
  domain: [
3687
3726
  '#1D68FB',
3688
3727
  '#33C0FC',
@@ -3699,7 +3738,7 @@
3699
3738
  {
3700
3739
  name: 'forest',
3701
3740
  selectable: false,
3702
- group: exports.ɵc.Ordinal,
3741
+ group: exports.ScaleType.Ordinal,
3703
3742
  domain: [
3704
3743
  '#55C22D',
3705
3744
  '#C1F33D',
@@ -3716,7 +3755,7 @@
3716
3755
  {
3717
3756
  name: 'horizon',
3718
3757
  selectable: false,
3719
- group: exports.ɵc.Ordinal,
3758
+ group: exports.ScaleType.Ordinal,
3720
3759
  domain: [
3721
3760
  '#2597FB',
3722
3761
  '#65EBFD',
@@ -3733,7 +3772,7 @@
3733
3772
  {
3734
3773
  name: 'neons',
3735
3774
  selectable: false,
3736
- group: exports.ɵc.Ordinal,
3775
+ group: exports.ScaleType.Ordinal,
3737
3776
  domain: [
3738
3777
  '#FF3333',
3739
3778
  '#FF33FF',
@@ -3750,7 +3789,7 @@
3750
3789
  {
3751
3790
  name: 'picnic',
3752
3791
  selectable: false,
3753
- group: exports.ɵc.Ordinal,
3792
+ group: exports.ScaleType.Ordinal,
3754
3793
  domain: [
3755
3794
  '#FAC51D',
3756
3795
  '#66BD6D',
@@ -3767,7 +3806,7 @@
3767
3806
  {
3768
3807
  name: 'night',
3769
3808
  selectable: false,
3770
- group: exports.ɵc.Ordinal,
3809
+ group: exports.ScaleType.Ordinal,
3771
3810
  domain: [
3772
3811
  '#2B1B5A',
3773
3812
  '#501356',
@@ -3789,7 +3828,7 @@
3789
3828
  {
3790
3829
  name: 'nightLights',
3791
3830
  selectable: false,
3792
- group: exports.ɵc.Ordinal,
3831
+ group: exports.ScaleType.Ordinal,
3793
3832
  domain: [
3794
3833
  '#4e31a5',
3795
3834
  '#9c25a7',
@@ -3830,21 +3869,32 @@
3830
3869
  });
3831
3870
  }
3832
3871
  var colorScale;
3833
- if (type === exports.ɵc.Quantile) {
3834
- colorScale = d3Scale.scaleQuantile().range(scheme.domain).domain(domain);
3835
- }
3836
- else if (type === exports.ɵc.Ordinal) {
3837
- colorScale = d3Scale.scaleOrdinal().range(scheme.domain).domain(domain);
3838
- }
3839
- else if (type === exports.ɵc.Linear) {
3840
- // linear schemes must have at least 2 colors
3841
- var colorDomain = __spread(scheme.domain);
3842
- if (colorDomain.length === 1) {
3843
- colorDomain.push(colorDomain[0]);
3844
- this.colorDomain = colorDomain;
3845
- }
3846
- var points = d3Array.range(0, 1, 1.0 / colorDomain.length);
3847
- colorScale = d3Scale.scaleLinear().domain(points).range(colorDomain);
3872
+ switch (type) {
3873
+ case exports.ScaleType.Quantile:
3874
+ colorScale = d3Scale.scaleQuantile()
3875
+ .range(scheme.domain)
3876
+ .domain(domain);
3877
+ break;
3878
+ case exports.ScaleType.Ordinal:
3879
+ colorScale = d3Scale.scaleOrdinal()
3880
+ .range(scheme.domain)
3881
+ .domain(domain);
3882
+ break;
3883
+ case exports.ScaleType.Linear:
3884
+ {
3885
+ var colorDomain = __spreadArray([], __read(scheme.domain));
3886
+ if (colorDomain.length === 1) {
3887
+ colorDomain.push(colorDomain[0]);
3888
+ this.colorDomain = colorDomain;
3889
+ }
3890
+ var points = d3Array.range(0, 1, 1.0 / colorDomain.length);
3891
+ colorScale = d3Scale.scaleLinear()
3892
+ .range(colorDomain)
3893
+ .domain(points);
3894
+ }
3895
+ break;
3896
+ default:
3897
+ break;
3848
3898
  }
3849
3899
  return colorScale;
3850
3900
  };
@@ -3852,8 +3902,10 @@
3852
3902
  if (value === undefined || value === null) {
3853
3903
  throw new Error('Value can not be null');
3854
3904
  }
3855
- if (this.scaleType === exports.ɵc.Linear) {
3856
- var valueScale = d3Scale.scaleLinear().domain(this.domain).range([0, 1]);
3905
+ if (this.scaleType === exports.ScaleType.Linear) {
3906
+ var valueScale = d3Scale.scaleLinear()
3907
+ .domain(this.domain)
3908
+ .range([0, 1]);
3857
3909
  return this.scale(valueScale(value));
3858
3910
  }
3859
3911
  else {
@@ -3881,7 +3933,9 @@
3881
3933
  if (start === undefined) {
3882
3934
  start = this.domain[0];
3883
3935
  }
3884
- var valueScale = d3Scale.scaleLinear().domain(this.domain).range([0, 1]);
3936
+ var valueScale = d3Scale.scaleLinear()
3937
+ .domain(this.domain)
3938
+ .range([0, 1]);
3885
3939
  var colorValueScale = d3Scale.scaleBand().domain(this.colorDomain).range([0, 1]);
3886
3940
  var endColor = this.getColor(value);
3887
3941
  // generate the stops
@@ -3994,20 +4048,57 @@
3994
4048
  if (checkDateType) {
3995
4049
  var allDates = values.every(function (value) { return value instanceof Date; });
3996
4050
  if (allDates) {
3997
- return exports.ɵc.Time;
4051
+ return exports.ScaleType.Time;
3998
4052
  }
3999
4053
  }
4000
4054
  var allNumbers = values.every(function (value) { return typeof value === 'number'; });
4001
4055
  if (allNumbers) {
4002
- return exports.ɵc.Linear;
4056
+ return exports.ScaleType.Linear;
4003
4057
  }
4004
- return exports.ɵc.Ordinal;
4058
+ return exports.ScaleType.Ordinal;
4059
+ }
4060
+ function getXDomainArray(values, xScaleMin, xScaleMax) {
4061
+ var scaleType = getScaleType(values);
4062
+ var xSet = [];
4063
+ var domain = [];
4064
+ if (scaleType === exports.ScaleType.Linear) {
4065
+ values = values.map(function (v) { return Number(v); });
4066
+ }
4067
+ var min;
4068
+ var max;
4069
+ if (scaleType === exports.ScaleType.Time || scaleType === exports.ScaleType.Linear) {
4070
+ var mappedValues = values.map(function (v) { return Number(v); });
4071
+ min = xScaleMin ? xScaleMin : Math.min.apply(Math, __spreadArray([], __read(mappedValues)));
4072
+ max = xScaleMax ? xScaleMax : Math.max.apply(Math, __spreadArray([], __read(mappedValues)));
4073
+ }
4074
+ if (scaleType === exports.ScaleType.Time) {
4075
+ domain = [new Date(min), new Date(max)];
4076
+ xSet = __spreadArray([], __read(values)).sort(function (a, b) {
4077
+ var aDate = a.getTime();
4078
+ var bDate = b.getTime();
4079
+ if (aDate > bDate)
4080
+ return 1;
4081
+ if (bDate > aDate)
4082
+ return -1;
4083
+ return 0;
4084
+ });
4085
+ }
4086
+ else if (scaleType === exports.ScaleType.Linear) {
4087
+ domain = [min, max];
4088
+ // Use compare function to sort numbers numerically
4089
+ xSet = __spreadArray([], __read(values)).sort(function (a, b) { return a - b; });
4090
+ }
4091
+ else {
4092
+ domain = values;
4093
+ xSet = values;
4094
+ }
4095
+ return { domain: domain, xSet: xSet, scaleType: scaleType };
4005
4096
  }
4006
4097
 
4007
4098
  var AreaChartComponent = /** @class */ (function (_super) {
4008
4099
  __extends(AreaChartComponent, _super);
4009
4100
  function AreaChartComponent() {
4010
- var _this = _super.apply(this, __spread(arguments)) || this;
4101
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
4011
4102
  _this.legend = false;
4012
4103
  _this.legendTitle = 'Legend';
4013
4104
  _this.legendPosition = exports.LegendPosition.Right;
@@ -4033,6 +4124,9 @@
4033
4124
  _this.yAxisWidth = 0;
4034
4125
  _this.timelineHeight = 50;
4035
4126
  _this.timelinePadding = 10;
4127
+ _this.trackBy = function (index, item) {
4128
+ return item.name;
4129
+ };
4036
4130
  return _this;
4037
4131
  }
4038
4132
  AreaChartComponent.prototype.update = function () {
@@ -4082,18 +4176,18 @@
4082
4176
  var values = getUniqueXDomainValues(this.results);
4083
4177
  this.scaleType = getScaleType(values);
4084
4178
  var domain = [];
4085
- if (this.scaleType === exports.ɵc.Linear) {
4179
+ if (this.scaleType === exports.ScaleType.Linear) {
4086
4180
  values = values.map(function (v) { return Number(v); });
4087
4181
  }
4088
4182
  var min;
4089
4183
  var max;
4090
- if (this.scaleType === exports.ɵc.Time || this.scaleType === exports.ɵc.Linear) {
4091
- min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spread(values));
4092
- max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spread(values));
4184
+ if (this.scaleType === exports.ScaleType.Time || this.scaleType === exports.ScaleType.Linear) {
4185
+ min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spreadArray([], __read(values)));
4186
+ max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spreadArray([], __read(values)));
4093
4187
  }
4094
- if (this.scaleType === exports.ɵc.Time) {
4188
+ if (this.scaleType === exports.ScaleType.Time) {
4095
4189
  domain = [new Date(min), new Date(max)];
4096
- this.xSet = __spread(values).sort(function (a, b) {
4190
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) {
4097
4191
  var aDate = a.getTime();
4098
4192
  var bDate = b.getTime();
4099
4193
  if (aDate > bDate)
@@ -4103,10 +4197,10 @@
4103
4197
  return 0;
4104
4198
  });
4105
4199
  }
4106
- else if (this.scaleType === exports.ɵc.Linear) {
4200
+ else if (this.scaleType === exports.ScaleType.Linear) {
4107
4201
  domain = [min, max];
4108
4202
  // Use compare function to sort numbers numerically
4109
- this.xSet = __spread(values).sort(function (a, b) { return a - b; });
4203
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) { return a - b; });
4110
4204
  }
4111
4205
  else {
4112
4206
  domain = values;
@@ -4144,15 +4238,15 @@
4144
4238
  }
4145
4239
  finally { if (e_1) throw e_1.error; }
4146
4240
  }
4147
- var values = __spread(domain);
4241
+ var values = __spreadArray([], __read(domain));
4148
4242
  if (!this.autoScale) {
4149
4243
  values.push(0);
4150
4244
  }
4151
4245
  if (this.baseValue !== 'auto') {
4152
4246
  values.push(this.baseValue);
4153
4247
  }
4154
- var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spread(values));
4155
- var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spread(values));
4248
+ var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spreadArray([], __read(values)));
4249
+ var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spreadArray([], __read(values)));
4156
4250
  return [min, max];
4157
4251
  };
4158
4252
  AreaChartComponent.prototype.getSeriesDomain = function () {
@@ -4160,13 +4254,13 @@
4160
4254
  };
4161
4255
  AreaChartComponent.prototype.getXScale = function (domain, width) {
4162
4256
  var scale;
4163
- if (this.scaleType === exports.ɵc.Time) {
4257
+ if (this.scaleType === exports.ScaleType.Time) {
4164
4258
  scale = d3Scale.scaleTime();
4165
4259
  }
4166
- else if (this.scaleType === exports.ɵc.Linear) {
4260
+ else if (this.scaleType === exports.ScaleType.Linear) {
4167
4261
  scale = d3Scale.scaleLinear();
4168
4262
  }
4169
- else if (this.scaleType === exports.ɵc.Ordinal) {
4263
+ else if (this.scaleType === exports.ScaleType.Ordinal) {
4170
4264
  scale = d3Scale.scalePoint().padding(0.1);
4171
4265
  }
4172
4266
  scale.range([0, width]).domain(domain);
@@ -4199,12 +4293,12 @@
4199
4293
  finally { if (e_3) throw e_3.error; }
4200
4294
  }
4201
4295
  if (date) {
4202
- return exports.ɵc.Time;
4296
+ return exports.ScaleType.Time;
4203
4297
  }
4204
4298
  if (num) {
4205
- return exports.ɵc.Linear;
4299
+ return exports.ScaleType.Linear;
4206
4300
  }
4207
- return exports.ɵc.Ordinal;
4301
+ return exports.ScaleType.Ordinal;
4208
4302
  };
4209
4303
  AreaChartComponent.prototype.updateDomain = function (domain) {
4210
4304
  this.filteredDomain = domain;
@@ -4225,12 +4319,9 @@
4225
4319
  }
4226
4320
  this.select.emit(data);
4227
4321
  };
4228
- AreaChartComponent.prototype.trackBy = function (index, item) {
4229
- return item.name;
4230
- };
4231
4322
  AreaChartComponent.prototype.setColors = function () {
4232
4323
  var domain;
4233
- if (this.schemeType === exports.ɵc.Ordinal) {
4324
+ if (this.schemeType === exports.ScaleType.Ordinal) {
4234
4325
  domain = this.seriesDomain;
4235
4326
  }
4236
4327
  else {
@@ -4246,7 +4337,7 @@
4246
4337
  title: undefined,
4247
4338
  position: this.legendPosition
4248
4339
  };
4249
- if (opts.scaleType === exports.ɵc.Ordinal) {
4340
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
4250
4341
  opts.domain = this.seriesDomain;
4251
4342
  opts.colors = this.colors;
4252
4343
  opts.title = this.legendTitle;
@@ -4274,7 +4365,7 @@
4274
4365
  if (idx > -1) {
4275
4366
  return;
4276
4367
  }
4277
- this.activeEntries = __spread([item], this.activeEntries);
4368
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
4278
4369
  this.activate.emit({ value: item, entries: this.activeEntries });
4279
4370
  };
4280
4371
  AreaChartComponent.prototype.onDeactivate = function (item) {
@@ -4282,12 +4373,12 @@
4282
4373
  return d.name === item.name && d.value === item.value;
4283
4374
  });
4284
4375
  this.activeEntries.splice(idx, 1);
4285
- this.activeEntries = __spread(this.activeEntries);
4376
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4286
4377
  this.deactivate.emit({ value: item, entries: this.activeEntries });
4287
4378
  };
4288
4379
  AreaChartComponent.prototype.deactivateAll = function () {
4289
4380
  var e_4, _a;
4290
- this.activeEntries = __spread(this.activeEntries);
4381
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4291
4382
  try {
4292
4383
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
4293
4384
  var entry = _c.value;
@@ -4311,7 +4402,7 @@
4311
4402
  template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:defs>\n <svg:clipPath [attr.id]=\"clipPathId\">\n <svg:rect\n [attr.width]=\"dims.width + 10\"\n [attr.height]=\"dims.height + 10\"\n [attr.transform]=\"'translate(-5, -5)'\"\n />\n </svg:clipPath>\n </svg:defs>\n <svg:g [attr.transform]=\"transform\" class=\"area-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g [attr.clip-path]=\"clipPath\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [baseValue]=\"baseValue\"\n [colors]=\"colors\"\n [data]=\"series\"\n [activeEntries]=\"activeEntries\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n\n <svg:g *ngIf=\"!tooltipDisabled\" (mouseleave)=\"hideCircles()\">\n <svg:g\n ngx-charts-tooltip-area\n [dims]=\"dims\"\n [xSet]=\"xSet\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [results]=\"results\"\n [colors]=\"colors\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"seriesTooltipTemplate\"\n (hover)=\"updateHoveredVertical($event)\"\n />\n\n <svg:g *ngFor=\"let series of results\">\n <svg:g\n ngx-charts-circle-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [activeEntries]=\"activeEntries\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [visibleValue]=\"hoveredVertical\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event, series)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-timeline\n *ngIf=\"timeline && scaleType != 'ordinal'\"\n [attr.transform]=\"timelineTransform\"\n [results]=\"results\"\n [view]=\"[timelineWidth, height]\"\n [height]=\"timelineHeight\"\n [scheme]=\"scheme\"\n [customColors]=\"customColors\"\n [legend]=\"legend\"\n [scaleType]=\"scaleType\"\n (onDomainChange)=\"updateDomain($event)\"\n >\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"timelineXScale\"\n [yScale]=\"timelineYScale\"\n [baseValue]=\"baseValue\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
4312
4403
  changeDetection: core.ChangeDetectionStrategy.OnPush,
4313
4404
  encapsulation: core.ViewEncapsulation.None,
4314
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
4405
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
4315
4406
  },] }
4316
4407
  ];
4317
4408
  AreaChartComponent.propDecorators = {
@@ -4357,7 +4448,7 @@
4357
4448
  var AreaChartNormalizedComponent = /** @class */ (function (_super) {
4358
4449
  __extends(AreaChartNormalizedComponent, _super);
4359
4450
  function AreaChartNormalizedComponent() {
4360
- var _this = _super.apply(this, __spread(arguments)) || this;
4451
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
4361
4452
  _this.legend = false;
4362
4453
  _this.legendTitle = 'Legend';
4363
4454
  _this.legendPosition = exports.LegendPosition.Right;
@@ -4379,8 +4470,12 @@
4379
4470
  _this.margin = [10, 20, 10, 20];
4380
4471
  _this.xAxisHeight = 0;
4381
4472
  _this.yAxisWidth = 0;
4473
+ _this.seriesType = exports.SeriesType;
4382
4474
  _this.timelineHeight = 50;
4383
4475
  _this.timelinePadding = 10;
4476
+ _this.trackBy = function (index, item) {
4477
+ return item.name;
4478
+ };
4384
4479
  return _this;
4385
4480
  }
4386
4481
  AreaChartNormalizedComponent.prototype.update = function () {
@@ -4421,7 +4516,7 @@
4421
4516
  var d = group.series.find(function (item) {
4422
4517
  var a = item.name;
4423
4518
  var b = val;
4424
- if (_this.scaleType === exports.ɵc.Time) {
4519
+ if (_this.scaleType === exports.ScaleType.Time) {
4425
4520
  a = a.valueOf();
4426
4521
  b = b.valueOf();
4427
4522
  }
@@ -4445,7 +4540,7 @@
4445
4540
  var d = group.series.find(function (item) {
4446
4541
  var a = item.name;
4447
4542
  var b = val;
4448
- if (_this.scaleType === exports.ɵc.Time) {
4543
+ if (_this.scaleType === exports.ScaleType.Time) {
4449
4544
  a = a.valueOf();
4450
4545
  b = b.valueOf();
4451
4546
  }
@@ -4507,11 +4602,11 @@
4507
4602
  var values = getUniqueXDomainValues(this.results);
4508
4603
  this.scaleType = getScaleType(values);
4509
4604
  var domain = [];
4510
- if (this.scaleType === exports.ɵc.Time) {
4511
- var min = Math.min.apply(Math, __spread(values));
4512
- var max = Math.max.apply(Math, __spread(values));
4605
+ if (this.scaleType === exports.ScaleType.Time) {
4606
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
4607
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
4513
4608
  domain = [new Date(min), new Date(max)];
4514
- this.xSet = __spread(values).sort(function (a, b) {
4609
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) {
4515
4610
  var aDate = a.getTime();
4516
4611
  var bDate = b.getTime();
4517
4612
  if (aDate > bDate)
@@ -4521,13 +4616,13 @@
4521
4616
  return 0;
4522
4617
  });
4523
4618
  }
4524
- else if (this.scaleType === exports.ɵc.Linear) {
4619
+ else if (this.scaleType === exports.ScaleType.Linear) {
4525
4620
  values = values.map(function (v) { return Number(v); });
4526
- var min = Math.min.apply(Math, __spread(values));
4527
- var max = Math.max.apply(Math, __spread(values));
4621
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
4622
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
4528
4623
  domain = [min, max];
4529
4624
  // Use compare function to sort numbers numerically
4530
- this.xSet = __spread(values).sort(function (a, b) { return a - b; });
4625
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) { return a - b; });
4531
4626
  }
4532
4627
  else {
4533
4628
  domain = values;
@@ -4540,13 +4635,13 @@
4540
4635
  };
4541
4636
  AreaChartNormalizedComponent.prototype.getXScale = function (domain, width) {
4542
4637
  var scale;
4543
- if (this.scaleType === exports.ɵc.Time) {
4638
+ if (this.scaleType === exports.ScaleType.Time) {
4544
4639
  scale = d3Scale.scaleTime();
4545
4640
  }
4546
- else if (this.scaleType === exports.ɵc.Linear) {
4641
+ else if (this.scaleType === exports.ScaleType.Linear) {
4547
4642
  scale = d3Scale.scaleLinear();
4548
4643
  }
4549
- else if (this.scaleType === exports.ɵc.Ordinal) {
4644
+ else if (this.scaleType === exports.ScaleType.Ordinal) {
4550
4645
  scale = d3Scale.scalePoint().padding(0.1);
4551
4646
  }
4552
4647
  scale.range([0, width]).domain(domain);
@@ -4575,12 +4670,9 @@
4575
4670
  }
4576
4671
  this.select.emit(data);
4577
4672
  };
4578
- AreaChartNormalizedComponent.prototype.trackBy = function (index, item) {
4579
- return item.name;
4580
- };
4581
4673
  AreaChartNormalizedComponent.prototype.setColors = function () {
4582
4674
  var domain;
4583
- if (this.schemeType === exports.ɵc.Ordinal) {
4675
+ if (this.schemeType === exports.ScaleType.Ordinal) {
4584
4676
  domain = this.seriesDomain;
4585
4677
  }
4586
4678
  else {
@@ -4596,7 +4688,7 @@
4596
4688
  title: undefined,
4597
4689
  position: this.legendPosition
4598
4690
  };
4599
- if (opts.scaleType === exports.ɵc.Ordinal) {
4691
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
4600
4692
  opts.domain = this.seriesDomain;
4601
4693
  opts.colors = this.colors;
4602
4694
  opts.title = this.legendTitle;
@@ -4624,7 +4716,7 @@
4624
4716
  if (idx > -1) {
4625
4717
  return;
4626
4718
  }
4627
- this.activeEntries = __spread([item], this.activeEntries);
4719
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
4628
4720
  this.activate.emit({ value: item, entries: this.activeEntries });
4629
4721
  };
4630
4722
  AreaChartNormalizedComponent.prototype.onDeactivate = function (item) {
@@ -4632,12 +4724,12 @@
4632
4724
  return d.name === item.name && d.value === item.value;
4633
4725
  });
4634
4726
  this.activeEntries.splice(idx, 1);
4635
- this.activeEntries = __spread(this.activeEntries);
4727
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4636
4728
  this.deactivate.emit({ value: item, entries: this.activeEntries });
4637
4729
  };
4638
4730
  AreaChartNormalizedComponent.prototype.deactivateAll = function () {
4639
4731
  var e_3, _a;
4640
- this.activeEntries = __spread(this.activeEntries);
4732
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4641
4733
  try {
4642
4734
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
4643
4735
  var entry = _c.value;
@@ -4658,10 +4750,10 @@
4658
4750
  AreaChartNormalizedComponent.decorators = [
4659
4751
  { type: core.Component, args: [{
4660
4752
  selector: 'ngx-charts-area-chart-normalized',
4661
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:defs>\n <svg:clipPath [attr.id]=\"clipPathId\">\n <svg:rect\n [attr.width]=\"dims.width + 10\"\n [attr.height]=\"dims.height + 10\"\n [attr.transform]=\"'translate(-5, -5)'\"\n />\n </svg:clipPath>\n </svg:defs>\n <svg:g [attr.transform]=\"transform\" class=\"area-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g [attr.clip-path]=\"clipPath\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [activeEntries]=\"activeEntries\"\n [gradient]=\"gradient\"\n normalized=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n\n <svg:g *ngIf=\"!tooltipDisabled\" (mouseleave)=\"hideCircles()\">\n <svg:g\n ngx-charts-tooltip-area\n [dims]=\"dims\"\n [xSet]=\"xSet\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [results]=\"results\"\n [colors]=\"colors\"\n [showPercentage]=\"true\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"seriesTooltipTemplate\"\n (hover)=\"updateHoveredVertical($event)\"\n />\n\n <svg:g *ngFor=\"let series of results\">\n <svg:g\n ngx-charts-circle-series\n type=\"stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [activeEntries]=\"activeEntries\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [visibleValue]=\"hoveredVertical\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event, series)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-timeline\n *ngIf=\"timeline && scaleType != 'ordinal'\"\n [attr.transform]=\"timelineTransform\"\n [results]=\"results\"\n [view]=\"[timelineWidth, height]\"\n [height]=\"timelineHeight\"\n [scheme]=\"scheme\"\n [customColors]=\"customColors\"\n [legend]=\"legend\"\n [scaleType]=\"scaleType\"\n (onDomainChange)=\"updateDomain($event)\"\n >\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"timelineXScale\"\n [yScale]=\"timelineYScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n normalized=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
4753
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:defs>\n <svg:clipPath [attr.id]=\"clipPathId\">\n <svg:rect\n [attr.width]=\"dims.width + 10\"\n [attr.height]=\"dims.height + 10\"\n [attr.transform]=\"'translate(-5, -5)'\"\n />\n </svg:clipPath>\n </svg:defs>\n <svg:g [attr.transform]=\"transform\" class=\"area-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g [attr.clip-path]=\"clipPath\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [activeEntries]=\"activeEntries\"\n [gradient]=\"gradient\"\n [normalized]=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n\n <svg:g *ngIf=\"!tooltipDisabled\" (mouseleave)=\"hideCircles()\">\n <svg:g\n ngx-charts-tooltip-area\n [dims]=\"dims\"\n [xSet]=\"xSet\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [results]=\"results\"\n [colors]=\"colors\"\n [showPercentage]=\"true\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"seriesTooltipTemplate\"\n (hover)=\"updateHoveredVertical($event)\"\n />\n\n <svg:g *ngFor=\"let series of results\">\n <svg:g\n ngx-charts-circle-series\n [type]=\"seriesType.Stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [activeEntries]=\"activeEntries\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [visibleValue]=\"hoveredVertical\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event, series)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-timeline\n *ngIf=\"timeline && scaleType != 'ordinal'\"\n [attr.transform]=\"timelineTransform\"\n [results]=\"results\"\n [view]=\"[timelineWidth, height]\"\n [height]=\"timelineHeight\"\n [scheme]=\"scheme\"\n [customColors]=\"customColors\"\n [legend]=\"legend\"\n [scaleType]=\"scaleType\"\n (onDomainChange)=\"updateDomain($event)\"\n >\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"timelineXScale\"\n [yScale]=\"timelineYScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [normalized]=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
4662
4754
  changeDetection: core.ChangeDetectionStrategy.OnPush,
4663
4755
  encapsulation: core.ViewEncapsulation.None,
4664
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
4756
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
4665
4757
  },] }
4666
4758
  ];
4667
4759
  AreaChartNormalizedComponent.propDecorators = {
@@ -4701,7 +4793,7 @@
4701
4793
  var AreaChartStackedComponent = /** @class */ (function (_super) {
4702
4794
  __extends(AreaChartStackedComponent, _super);
4703
4795
  function AreaChartStackedComponent() {
4704
- var _this = _super.apply(this, __spread(arguments)) || this;
4796
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
4705
4797
  _this.legend = false;
4706
4798
  _this.legendTitle = 'Legend';
4707
4799
  _this.legendPosition = exports.LegendPosition.Right;
@@ -4725,6 +4817,7 @@
4725
4817
  _this.yAxisWidth = 0;
4726
4818
  _this.timelineHeight = 50;
4727
4819
  _this.timelinePadding = 10;
4820
+ _this.seriesType = exports.SeriesType;
4728
4821
  return _this;
4729
4822
  }
4730
4823
  AreaChartStackedComponent.prototype.update = function () {
@@ -4765,7 +4858,7 @@
4765
4858
  var d = group.series.find(function (item) {
4766
4859
  var a = item.name;
4767
4860
  var b = val;
4768
- if (_this.scaleType === exports.ɵc.Time) {
4861
+ if (_this.scaleType === exports.ScaleType.Time) {
4769
4862
  a = a.valueOf();
4770
4863
  b = b.valueOf();
4771
4864
  }
@@ -4819,18 +4912,18 @@
4819
4912
  var values = getUniqueXDomainValues(this.results);
4820
4913
  this.scaleType = getScaleType(values);
4821
4914
  var domain = [];
4822
- if (this.scaleType === exports.ɵc.Linear) {
4915
+ if (this.scaleType === exports.ScaleType.Linear) {
4823
4916
  values = values.map(function (v) { return Number(v); });
4824
4917
  }
4825
4918
  var min;
4826
4919
  var max;
4827
- if (this.scaleType === exports.ɵc.Time || this.scaleType === exports.ɵc.Linear) {
4828
- min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spread(values));
4829
- max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spread(values));
4920
+ if (this.scaleType === exports.ScaleType.Time || this.scaleType === exports.ScaleType.Linear) {
4921
+ min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spreadArray([], __read(values)));
4922
+ max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spreadArray([], __read(values)));
4830
4923
  }
4831
- if (this.scaleType === exports.ɵc.Time) {
4924
+ if (this.scaleType === exports.ScaleType.Time) {
4832
4925
  domain = [new Date(min), new Date(max)];
4833
- this.xSet = __spread(values).sort(function (a, b) {
4926
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) {
4834
4927
  var aDate = a.getTime();
4835
4928
  var bDate = b.getTime();
4836
4929
  if (aDate > bDate)
@@ -4840,10 +4933,10 @@
4840
4933
  return 0;
4841
4934
  });
4842
4935
  }
4843
- else if (this.scaleType === exports.ɵc.Linear) {
4936
+ else if (this.scaleType === exports.ScaleType.Linear) {
4844
4937
  domain = [min, max];
4845
4938
  // Use compare function to sort numbers numerically
4846
- this.xSet = __spread(values).sort(function (a, b) { return a - b; });
4939
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) { return a - b; });
4847
4940
  }
4848
4941
  else {
4849
4942
  domain = values;
@@ -4864,7 +4957,7 @@
4864
4957
  var d = group.series.find(function (item) {
4865
4958
  var a = item.name;
4866
4959
  var b = val;
4867
- if (_this.scaleType === exports.ɵc.Time) {
4960
+ if (_this.scaleType === exports.ScaleType.Time) {
4868
4961
  a = a.valueOf();
4869
4962
  b = b.valueOf();
4870
4963
  }
@@ -4888,8 +4981,8 @@
4888
4981
  for (var i = 0; i < this.xSet.length; i++) {
4889
4982
  _loop_2(i);
4890
4983
  }
4891
- var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spread([0], domain));
4892
- var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spread(domain));
4984
+ var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spreadArray([0], __read(domain)));
4985
+ var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spreadArray([], __read(domain)));
4893
4986
  return [min, max];
4894
4987
  };
4895
4988
  AreaChartStackedComponent.prototype.getSeriesDomain = function () {
@@ -4897,13 +4990,13 @@
4897
4990
  };
4898
4991
  AreaChartStackedComponent.prototype.getXScale = function (domain, width) {
4899
4992
  var scale;
4900
- if (this.scaleType === exports.ɵc.Time) {
4993
+ if (this.scaleType === exports.ScaleType.Time) {
4901
4994
  scale = d3Scale.scaleTime();
4902
4995
  }
4903
- else if (this.scaleType === exports.ɵc.Linear) {
4996
+ else if (this.scaleType === exports.ScaleType.Linear) {
4904
4997
  scale = d3Scale.scaleLinear();
4905
4998
  }
4906
- else if (this.scaleType === exports.ɵc.Ordinal) {
4999
+ else if (this.scaleType === exports.ScaleType.Ordinal) {
4907
5000
  scale = d3Scale.scalePoint().padding(0.1);
4908
5001
  }
4909
5002
  scale.range([0, width]).domain(domain);
@@ -4933,11 +5026,11 @@
4933
5026
  this.select.emit(data);
4934
5027
  };
4935
5028
  AreaChartStackedComponent.prototype.trackBy = function (index, item) {
4936
- return item.name;
5029
+ return "" + item.name;
4937
5030
  };
4938
5031
  AreaChartStackedComponent.prototype.setColors = function () {
4939
5032
  var domain;
4940
- if (this.schemeType === exports.ɵc.Ordinal) {
5033
+ if (this.schemeType === exports.ScaleType.Ordinal) {
4941
5034
  domain = this.seriesDomain;
4942
5035
  }
4943
5036
  else {
@@ -4953,7 +5046,7 @@
4953
5046
  title: undefined,
4954
5047
  position: this.legendPosition
4955
5048
  };
4956
- if (opts.scaleType === exports.ɵc.Ordinal) {
5049
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
4957
5050
  opts.domain = this.seriesDomain;
4958
5051
  opts.colors = this.colors;
4959
5052
  opts.title = this.legendTitle;
@@ -4981,7 +5074,7 @@
4981
5074
  if (idx > -1) {
4982
5075
  return;
4983
5076
  }
4984
- this.activeEntries = __spread([item], this.activeEntries);
5077
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
4985
5078
  this.activate.emit({ value: item, entries: this.activeEntries });
4986
5079
  };
4987
5080
  AreaChartStackedComponent.prototype.onDeactivate = function (item) {
@@ -4989,12 +5082,12 @@
4989
5082
  return d.name === item.name && d.value === item.value;
4990
5083
  });
4991
5084
  this.activeEntries.splice(idx, 1);
4992
- this.activeEntries = __spread(this.activeEntries);
5085
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4993
5086
  this.deactivate.emit({ value: item, entries: this.activeEntries });
4994
5087
  };
4995
5088
  AreaChartStackedComponent.prototype.deactivateAll = function () {
4996
5089
  var e_3, _a;
4997
- this.activeEntries = __spread(this.activeEntries);
5090
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
4998
5091
  try {
4999
5092
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
5000
5093
  var entry = _c.value;
@@ -5015,10 +5108,10 @@
5015
5108
  AreaChartStackedComponent.decorators = [
5016
5109
  { type: core.Component, args: [{
5017
5110
  selector: 'ngx-charts-area-chart-stacked',
5018
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:defs>\n <svg:clipPath [attr.id]=\"clipPathId\">\n <svg:rect\n [attr.width]=\"dims.width + 10\"\n [attr.height]=\"dims.height + 10\"\n [attr.transform]=\"'translate(-5, -5)'\"\n />\n </svg:clipPath>\n </svg:defs>\n <svg:g [attr.transform]=\"transform\" class=\"area-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g [attr.clip-path]=\"clipPath\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [activeEntries]=\"activeEntries\"\n stacked=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n\n <svg:g *ngIf=\"!tooltipDisabled\" (mouseleave)=\"hideCircles()\">\n <svg:g\n ngx-charts-tooltip-area\n [dims]=\"dims\"\n [xSet]=\"xSet\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [results]=\"results\"\n [colors]=\"colors\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"seriesTooltipTemplate\"\n (hover)=\"updateHoveredVertical($event)\"\n />\n\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-circle-series\n type=\"stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [activeEntries]=\"activeEntries\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [visibleValue]=\"hoveredVertical\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event, series)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-timeline\n *ngIf=\"timeline && scaleType != 'ordinal'\"\n [attr.transform]=\"timelineTransform\"\n [results]=\"results\"\n [view]=\"[timelineWidth, height]\"\n [height]=\"timelineHeight\"\n [scheme]=\"scheme\"\n [customColors]=\"customColors\"\n [legend]=\"legend\"\n [scaleType]=\"scaleType\"\n (onDomainChange)=\"updateDomain($event)\"\n >\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"timelineXScale\"\n [yScale]=\"timelineYScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n stacked=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
5111
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:defs>\n <svg:clipPath [attr.id]=\"clipPathId\">\n <svg:rect\n [attr.width]=\"dims.width + 10\"\n [attr.height]=\"dims.height + 10\"\n [attr.transform]=\"'translate(-5, -5)'\"\n />\n </svg:clipPath>\n </svg:defs>\n <svg:g [attr.transform]=\"transform\" class=\"area-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g [attr.clip-path]=\"clipPath\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [activeEntries]=\"activeEntries\"\n [stacked]=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n\n <svg:g *ngIf=\"!tooltipDisabled\" (mouseleave)=\"hideCircles()\">\n <svg:g\n ngx-charts-tooltip-area\n [dims]=\"dims\"\n [xSet]=\"xSet\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [results]=\"results\"\n [colors]=\"colors\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"seriesTooltipTemplate\"\n (hover)=\"updateHoveredVertical($event)\"\n />\n\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-circle-series\n [type]=\"seriesType.Stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [activeEntries]=\"activeEntries\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [visibleValue]=\"hoveredVertical\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event, series)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-timeline\n *ngIf=\"timeline && scaleType != 'ordinal'\"\n [attr.transform]=\"timelineTransform\"\n [results]=\"results\"\n [view]=\"[timelineWidth, height]\"\n [height]=\"timelineHeight\"\n [scheme]=\"scheme\"\n [customColors]=\"customColors\"\n [legend]=\"legend\"\n [scaleType]=\"scaleType\"\n (onDomainChange)=\"updateDomain($event)\"\n >\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-area-series\n [xScale]=\"timelineXScale\"\n [yScale]=\"timelineYScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [scaleType]=\"scaleType\"\n [gradient]=\"gradient\"\n [stacked]=\"true\"\n [curve]=\"curve\"\n [animations]=\"animations\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
5019
5112
  changeDetection: core.ChangeDetectionStrategy.OnPush,
5020
5113
  encapsulation: core.ViewEncapsulation.None,
5021
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
5114
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
5022
5115
  },] }
5023
5116
  ];
5024
5117
  AreaChartStackedComponent.propDecorators = {
@@ -5151,10 +5244,10 @@
5151
5244
  startingArea.curve(this.curve);
5152
5245
  this.opacity = 0.8;
5153
5246
  var data = this.data.series;
5154
- if (this.scaleType === exports.ɵc.Linear) {
5247
+ if (this.scaleType === exports.ScaleType.Linear) {
5155
5248
  data = sortLinear(data, 'name');
5156
5249
  }
5157
- else if (this.scaleType === exports.ɵc.Time) {
5250
+ else if (this.scaleType === exports.ScaleType.Time) {
5158
5251
  data = sortByTime(data, 'name');
5159
5252
  }
5160
5253
  else {
@@ -5164,18 +5257,18 @@
5164
5257
  this.startingPath = startingArea(data);
5165
5258
  };
5166
5259
  AreaSeriesComponent.prototype.updateGradient = function () {
5167
- if (this.colors.scaleType === exports.ɵc.Linear) {
5260
+ if (this.colors.scaleType === exports.ScaleType.Linear) {
5168
5261
  this.hasGradient = true;
5169
5262
  if (this.stacked || this.normalized) {
5170
5263
  var d0values = this.data.series.map(function (d) { return d.d0; });
5171
5264
  var d1values = this.data.series.map(function (d) { return d.d1; });
5172
- var max = Math.max.apply(Math, __spread(d1values));
5173
- var min = Math.min.apply(Math, __spread(d0values));
5265
+ var max = Math.max.apply(Math, __spreadArray([], __read(d1values)));
5266
+ var min = Math.min.apply(Math, __spreadArray([], __read(d0values)));
5174
5267
  this.gradientStops = this.colors.getLinearGradientStops(max, min);
5175
5268
  }
5176
5269
  else {
5177
5270
  var values = this.data.series.map(function (d) { return d.value; });
5178
- var max = Math.max.apply(Math, __spread(values));
5271
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
5179
5272
  this.gradientStops = this.colors.getLinearGradientStops(max);
5180
5273
  }
5181
5274
  }
@@ -5238,11 +5331,6 @@
5238
5331
  },] }
5239
5332
  ];
5240
5333
 
5241
- var BarOrientation;
5242
- (function (BarOrientation) {
5243
- BarOrientation["Vertical"] = "vertical";
5244
- BarOrientation["Horizontal"] = "horizontal";
5245
- })(BarOrientation || (BarOrientation = {}));
5246
5334
  var BarComponent = /** @class */ (function () {
5247
5335
  function BarComponent(element) {
5248
5336
  this.roundEdges = true;
@@ -5315,20 +5403,20 @@
5315
5403
  var radius = this.getRadius();
5316
5404
  var path;
5317
5405
  if (this.roundEdges) {
5318
- if (this.orientation === BarOrientation.Vertical) {
5406
+ if (this.orientation === exports.BarOrientation.Vertical) {
5319
5407
  radius = Math.min(this.height, radius);
5320
5408
  path = roundedRect(this.x, this.y + this.height, this.width, 1, 0, this.edges);
5321
5409
  }
5322
- else if (this.orientation === BarOrientation.Horizontal) {
5410
+ else if (this.orientation === exports.BarOrientation.Horizontal) {
5323
5411
  radius = Math.min(this.width, radius);
5324
5412
  path = roundedRect(this.x, this.y, 1, this.height, 0, this.edges);
5325
5413
  }
5326
5414
  }
5327
5415
  else {
5328
- if (this.orientation === BarOrientation.Vertical) {
5416
+ if (this.orientation === exports.BarOrientation.Vertical) {
5329
5417
  path = roundedRect(this.x, this.y + this.height, this.width, 1, 0, this.edges);
5330
5418
  }
5331
- else if (this.orientation === BarOrientation.Horizontal) {
5419
+ else if (this.orientation === exports.BarOrientation.Horizontal) {
5332
5420
  path = roundedRect(this.x, this.y, 1, this.height, 0, this.edges);
5333
5421
  }
5334
5422
  }
@@ -5338,11 +5426,11 @@
5338
5426
  var radius = this.getRadius();
5339
5427
  var path;
5340
5428
  if (this.roundEdges) {
5341
- if (this.orientation === 'vertical') {
5429
+ if (this.orientation === exports.BarOrientation.Vertical) {
5342
5430
  radius = Math.min(this.height, radius);
5343
5431
  path = roundedRect(this.x, this.y, this.width, this.height, radius, this.edges);
5344
5432
  }
5345
- else if (this.orientation === 'horizontal') {
5433
+ else if (this.orientation === exports.BarOrientation.Horizontal) {
5346
5434
  radius = Math.min(this.width, radius);
5347
5435
  path = roundedRect(this.x, this.y, this.width, this.height, radius, this.edges);
5348
5436
  }
@@ -5371,7 +5459,7 @@
5371
5459
  get: function () {
5372
5460
  var edges = [false, false, false, false];
5373
5461
  if (this.roundEdges) {
5374
- if (this.orientation === BarOrientation.Vertical) {
5462
+ if (this.orientation === exports.BarOrientation.Vertical) {
5375
5463
  if (this.data.value > 0) {
5376
5464
  edges = [true, true, false, false];
5377
5465
  }
@@ -5379,7 +5467,7 @@
5379
5467
  edges = [false, false, true, true];
5380
5468
  }
5381
5469
  }
5382
- else if (this.orientation === BarOrientation.Horizontal) {
5470
+ else if (this.orientation === exports.BarOrientation.Horizontal) {
5383
5471
  if (this.data.value > 0) {
5384
5472
  edges = [false, true, false, true];
5385
5473
  }
@@ -5402,8 +5490,8 @@
5402
5490
  BarComponent.prototype.checkToHideBar = function () {
5403
5491
  this.hideBar =
5404
5492
  this.noBarWhenZero &&
5405
- ((this.orientation === BarOrientation.Vertical && this.height === 0) ||
5406
- (this.orientation === BarOrientation.Horizontal && this.width === 0));
5493
+ ((this.orientation === exports.BarOrientation.Vertical && this.height === 0) ||
5494
+ (this.orientation === exports.BarOrientation.Horizontal && this.width === 0));
5407
5495
  };
5408
5496
  return BarComponent;
5409
5497
  }());
@@ -5443,7 +5531,7 @@
5443
5531
  var BarHorizontalComponent = /** @class */ (function (_super) {
5444
5532
  __extends(BarHorizontalComponent, _super);
5445
5533
  function BarHorizontalComponent() {
5446
- var _this = _super.apply(this, __spread(arguments)) || this;
5534
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
5447
5535
  _this.legend = false;
5448
5536
  _this.legendTitle = 'Legend';
5449
5537
  _this.legendPosition = exports.LegendPosition.Right;
@@ -5507,8 +5595,8 @@
5507
5595
  };
5508
5596
  BarHorizontalComponent.prototype.getXDomain = function () {
5509
5597
  var values = this.results.map(function (d) { return d.value; });
5510
- var min = this.xScaleMin ? Math.min.apply(Math, __spread([this.xScaleMin], values)) : Math.min.apply(Math, __spread([0], values));
5511
- var max = this.xScaleMax ? Math.max.apply(Math, __spread([this.xScaleMax], values)) : Math.max.apply(Math, __spread([0], values));
5598
+ var min = this.xScaleMin ? Math.min.apply(Math, __spreadArray([this.xScaleMin], __read(values))) : Math.min.apply(Math, __spreadArray([0], __read(values)));
5599
+ var max = this.xScaleMax ? Math.max.apply(Math, __spreadArray([this.xScaleMax], __read(values))) : Math.max.apply(Math, __spreadArray([0], __read(values)));
5512
5600
  return [min, max];
5513
5601
  };
5514
5602
  BarHorizontalComponent.prototype.getYDomain = function () {
@@ -5519,7 +5607,7 @@
5519
5607
  };
5520
5608
  BarHorizontalComponent.prototype.setColors = function () {
5521
5609
  var domain;
5522
- if (this.schemeType === exports.ɵc.Ordinal) {
5610
+ if (this.schemeType === exports.ScaleType.Ordinal) {
5523
5611
  domain = this.yDomain;
5524
5612
  }
5525
5613
  else {
@@ -5584,7 +5672,7 @@
5584
5672
  if (idx > -1) {
5585
5673
  return;
5586
5674
  }
5587
- this.activeEntries = __spread([item], this.activeEntries);
5675
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
5588
5676
  this.activate.emit({ value: item, entries: this.activeEntries });
5589
5677
  };
5590
5678
  BarHorizontalComponent.prototype.onDeactivate = function (item, fromLegend) {
@@ -5601,7 +5689,7 @@
5601
5689
  return d.name === item.name && d.value === item.value && d.series === item.series;
5602
5690
  });
5603
5691
  this.activeEntries.splice(idx, 1);
5604
- this.activeEntries = __spread(this.activeEntries);
5692
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
5605
5693
  this.deactivate.emit({ value: item, entries: this.activeEntries });
5606
5694
  };
5607
5695
  return BarHorizontalComponent;
@@ -5612,7 +5700,7 @@
5612
5700
  template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, true)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n [yAxisOffset]=\"dataLabelMaxWidth.negative\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-series-horizontal\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [series]=\"results\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [activeEntries]=\"activeEntries\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n (dataLabelWidthChanged)=\"onDataLabelMaxWidthChanged($event)\"\n ></svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
5613
5701
  changeDetection: core.ChangeDetectionStrategy.OnPush,
5614
5702
  encapsulation: core.ViewEncapsulation.None,
5615
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
5703
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
5616
5704
  },] }
5617
5705
  ];
5618
5706
  BarHorizontalComponent.propDecorators = {
@@ -5655,7 +5743,7 @@
5655
5743
  var BarHorizontal2DComponent = /** @class */ (function (_super) {
5656
5744
  __extends(BarHorizontal2DComponent, _super);
5657
5745
  function BarHorizontal2DComponent() {
5658
- var _this = _super.apply(this, __spread(arguments)) || this;
5746
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
5659
5747
  _this.legend = false;
5660
5748
  _this.legendTitle = 'Legend';
5661
5749
  _this.legendPosition = exports.LegendPosition.Right;
@@ -5679,6 +5767,10 @@
5679
5767
  _this.xAxisHeight = 0;
5680
5768
  _this.yAxisWidth = 0;
5681
5769
  _this.dataLabelMaxWidth = { negative: 0, positive: 0 };
5770
+ _this.barOrientation = exports.BarOrientation;
5771
+ _this.trackBy = function (index, item) {
5772
+ return item.name;
5773
+ };
5682
5774
  return _this;
5683
5775
  }
5684
5776
  BarHorizontal2DComponent.prototype.update = function () {
@@ -5811,8 +5903,8 @@
5811
5903
  }
5812
5904
  finally { if (e_4) throw e_4.error; }
5813
5905
  }
5814
- var min = Math.min.apply(Math, __spread([0], domain));
5815
- var max = this.xScaleMax ? Math.max.apply(Math, __spread([this.xScaleMax], domain)) : Math.max.apply(Math, __spread([0], domain));
5906
+ var min = Math.min.apply(Math, __spreadArray([0], __read(domain)));
5907
+ var max = this.xScaleMax ? Math.max.apply(Math, __spreadArray([this.xScaleMax], __read(domain))) : Math.max.apply(Math, __spreadArray([0], __read(domain)));
5816
5908
  return [min, max];
5817
5909
  };
5818
5910
  BarHorizontal2DComponent.prototype.groupTransform = function (group) {
@@ -5824,12 +5916,9 @@
5824
5916
  }
5825
5917
  this.select.emit(data);
5826
5918
  };
5827
- BarHorizontal2DComponent.prototype.trackBy = function (index, item) {
5828
- return item.name;
5829
- };
5830
5919
  BarHorizontal2DComponent.prototype.setColors = function () {
5831
5920
  var domain;
5832
- if (this.schemeType === exports.ɵc.Ordinal) {
5921
+ if (this.schemeType === exports.ScaleType.Ordinal) {
5833
5922
  domain = this.innerDomain;
5834
5923
  }
5835
5924
  else {
@@ -5845,7 +5934,7 @@
5845
5934
  title: undefined,
5846
5935
  position: this.legendPosition
5847
5936
  };
5848
- if (opts.scaleType === exports.ɵc.Ordinal) {
5937
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
5849
5938
  opts.domain = this.innerDomain;
5850
5939
  opts.colors = this.colors;
5851
5940
  opts.title = this.legendTitle;
@@ -5895,7 +5984,7 @@
5895
5984
  return i.name === item.name && i.series === item.series;
5896
5985
  }
5897
5986
  });
5898
- this.activeEntries = __spread(items);
5987
+ this.activeEntries = __spreadArray([], __read(items));
5899
5988
  this.activate.emit({ value: item, entries: this.activeEntries });
5900
5989
  };
5901
5990
  BarHorizontal2DComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -5919,7 +6008,7 @@
5919
6008
  BarHorizontal2DComponent.decorators = [
5920
6009
  { type: core.Component, args: [{
5921
6010
  selector: 'ngx-charts-bar-horizontal-2d',
5922
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-grid-panel-series\n [xScale]=\"valueScale\"\n [yScale]=\"groupScale\"\n [data]=\"results\"\n [dims]=\"dims\"\n orient=\"horizontal\"\n ></svg:g>\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"valueScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"groupScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n [yAxisOffset]=\"dataLabelMaxWidth.negative\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n [xScale]=\"valueScale\"\n [activeEntries]=\"activeEntries\"\n [yScale]=\"innerScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelWidthChanged)=\"onDataLabelMaxWidthChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6011
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-grid-panel-series\n [xScale]=\"valueScale\"\n [yScale]=\"groupScale\"\n [data]=\"results\"\n [dims]=\"dims\"\n [orient]=\"barOrientation.Horizontal\"\n ></svg:g>\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"valueScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"groupScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n [yAxisOffset]=\"dataLabelMaxWidth.negative\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n [xScale]=\"valueScale\"\n [activeEntries]=\"activeEntries\"\n [yScale]=\"innerScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelWidthChanged)=\"onDataLabelMaxWidthChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
5923
6012
  changeDetection: core.ChangeDetectionStrategy.OnPush,
5924
6013
  encapsulation: core.ViewEncapsulation.None,
5925
6014
  animations: [
@@ -5933,7 +6022,7 @@
5933
6022
  ])
5934
6023
  ])
5935
6024
  ],
5936
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
6025
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
5937
6026
  },] }
5938
6027
  ];
5939
6028
  BarHorizontal2DComponent.propDecorators = {
@@ -5973,10 +6062,17 @@
5973
6062
  tooltipTemplate: [{ type: core.ContentChild, args: ['tooltipTemplate',] }]
5974
6063
  };
5975
6064
 
6065
+ exports.BarChartType = void 0;
6066
+ (function (BarChartType) {
6067
+ BarChartType["Standard"] = "standard";
6068
+ BarChartType["Normalized"] = "normalized";
6069
+ BarChartType["Stacked"] = "stacked";
6070
+ })(exports.BarChartType || (exports.BarChartType = {}));
6071
+
5976
6072
  var BarHorizontalNormalizedComponent = /** @class */ (function (_super) {
5977
6073
  __extends(BarHorizontalNormalizedComponent, _super);
5978
6074
  function BarHorizontalNormalizedComponent() {
5979
- var _this = _super.apply(this, __spread(arguments)) || this;
6075
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
5980
6076
  _this.legend = false;
5981
6077
  _this.legendTitle = 'Legend';
5982
6078
  _this.legendPosition = exports.LegendPosition.Right;
@@ -5997,6 +6093,10 @@
5997
6093
  _this.margin = [10, 20, 10, 20];
5998
6094
  _this.xAxisHeight = 0;
5999
6095
  _this.yAxisWidth = 0;
6096
+ _this.barChartType = exports.BarChartType;
6097
+ _this.trackBy = function (index, item) {
6098
+ return item.name;
6099
+ };
6000
6100
  return _this;
6001
6101
  }
6002
6102
  BarHorizontalNormalizedComponent.prototype.update = function () {
@@ -6093,12 +6193,9 @@
6093
6193
  }
6094
6194
  this.select.emit(data);
6095
6195
  };
6096
- BarHorizontalNormalizedComponent.prototype.trackBy = function (index, item) {
6097
- return item.name;
6098
- };
6099
6196
  BarHorizontalNormalizedComponent.prototype.setColors = function () {
6100
6197
  var domain;
6101
- if (this.schemeType === exports.ɵc.Ordinal) {
6198
+ if (this.schemeType === exports.ScaleType.Ordinal) {
6102
6199
  domain = this.innerDomain;
6103
6200
  }
6104
6201
  else {
@@ -6114,7 +6211,7 @@
6114
6211
  title: undefined,
6115
6212
  position: this.legendPosition
6116
6213
  };
6117
- if (opts.scaleType === exports.ɵc.Ordinal) {
6214
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
6118
6215
  opts.domain = this.innerDomain;
6119
6216
  opts.colors = this.colors;
6120
6217
  opts.title = this.legendTitle;
@@ -6152,7 +6249,7 @@
6152
6249
  return i.name === item.name && i.series === item.series;
6153
6250
  }
6154
6251
  });
6155
- this.activeEntries = __spread(items);
6252
+ this.activeEntries = __spreadArray([], __read(items));
6156
6253
  this.activate.emit({ value: item, entries: this.activeEntries });
6157
6254
  };
6158
6255
  BarHorizontalNormalizedComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -6176,7 +6273,7 @@
6176
6273
  BarHorizontalNormalizedComponent.decorators = [
6177
6274
  { type: core.Component, args: [{
6178
6275
  selector: 'ngx-charts-bar-horizontal-normalized',
6179
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n type=\"normalized\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n [noBarWhenZero]=\"noBarWhenZero\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6276
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n [type]=\"barChartType.Normalized\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n [noBarWhenZero]=\"noBarWhenZero\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6180
6277
  changeDetection: core.ChangeDetectionStrategy.OnPush,
6181
6278
  encapsulation: core.ViewEncapsulation.None,
6182
6279
  animations: [
@@ -6190,7 +6287,7 @@
6190
6287
  ])
6191
6288
  ])
6192
6289
  ],
6193
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
6290
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
6194
6291
  },] }
6195
6292
  ];
6196
6293
  BarHorizontalNormalizedComponent.propDecorators = {
@@ -6228,7 +6325,7 @@
6228
6325
  var BarHorizontalStackedComponent = /** @class */ (function (_super) {
6229
6326
  __extends(BarHorizontalStackedComponent, _super);
6230
6327
  function BarHorizontalStackedComponent() {
6231
- var _this = _super.apply(this, __spread(arguments)) || this;
6328
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
6232
6329
  _this.legend = false;
6233
6330
  _this.legendTitle = 'Legend';
6234
6331
  _this.legendPosition = exports.LegendPosition.Right;
@@ -6250,6 +6347,10 @@
6250
6347
  _this.xAxisHeight = 0;
6251
6348
  _this.yAxisWidth = 0;
6252
6349
  _this.dataLabelMaxWidth = { negative: 0, positive: 0 };
6350
+ _this.barChartType = exports.BarChartType;
6351
+ _this.trackBy = function (index, item) {
6352
+ return item.name;
6353
+ };
6253
6354
  return _this;
6254
6355
  }
6255
6356
  BarHorizontalStackedComponent.prototype.update = function () {
@@ -6377,8 +6478,8 @@
6377
6478
  }
6378
6479
  domain.push(smallest);
6379
6480
  domain.push(biggest);
6380
- var min = Math.min.apply(Math, __spread([0], domain));
6381
- var max = this.xScaleMax ? Math.max.apply(Math, __spread([this.xScaleMax], domain)) : Math.max.apply(Math, __spread(domain));
6481
+ var min = Math.min.apply(Math, __spreadArray([0], __read(domain)));
6482
+ var max = this.xScaleMax ? Math.max.apply(Math, __spreadArray([this.xScaleMax], __read(domain))) : Math.max.apply(Math, __spreadArray([], __read(domain)));
6382
6483
  return [min, max];
6383
6484
  };
6384
6485
  BarHorizontalStackedComponent.prototype.getYScale = function () {
@@ -6398,12 +6499,9 @@
6398
6499
  }
6399
6500
  this.select.emit(data);
6400
6501
  };
6401
- BarHorizontalStackedComponent.prototype.trackBy = function (index, item) {
6402
- return item.name;
6403
- };
6404
6502
  BarHorizontalStackedComponent.prototype.setColors = function () {
6405
6503
  var domain;
6406
- if (this.schemeType === exports.ɵc.Ordinal) {
6504
+ if (this.schemeType === exports.ScaleType.Ordinal) {
6407
6505
  domain = this.innerDomain;
6408
6506
  }
6409
6507
  else {
@@ -6419,7 +6517,7 @@
6419
6517
  title: undefined,
6420
6518
  position: this.legendPosition
6421
6519
  };
6422
- if (opts.scaleType === exports.ɵc.Ordinal) {
6520
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
6423
6521
  opts.domain = this.innerDomain;
6424
6522
  opts.colors = this.colors;
6425
6523
  opts.title = this.legendTitle;
@@ -6469,7 +6567,7 @@
6469
6567
  return i.name === item.name && i.series === item.series;
6470
6568
  }
6471
6569
  });
6472
- this.activeEntries = __spread(items);
6570
+ this.activeEntries = __spreadArray([], __read(items));
6473
6571
  this.activate.emit({ value: item, entries: this.activeEntries });
6474
6572
  };
6475
6573
  BarHorizontalStackedComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -6493,7 +6591,7 @@
6493
6591
  BarHorizontalStackedComponent.decorators = [
6494
6592
  { type: core.Component, args: [{
6495
6593
  selector: 'ngx-charts-bar-horizontal-stacked',
6496
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n [yAxisOffset]=\"dataLabelMaxWidth.negative\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n type=\"stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [activeEntries]=\"activeEntries\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelWidthChanged)=\"onDataLabelMaxWidthChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6594
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n [yAxisOffset]=\"dataLabelMaxWidth.negative\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-horizontal\n [type]=\"barChartType.Stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [activeEntries]=\"activeEntries\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelWidthChanged)=\"onDataLabelMaxWidthChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6497
6595
  changeDetection: core.ChangeDetectionStrategy.OnPush,
6498
6596
  encapsulation: core.ViewEncapsulation.None,
6499
6597
  animations: [
@@ -6507,7 +6605,7 @@
6507
6605
  ])
6508
6606
  ])
6509
6607
  ],
6510
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
6608
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
6511
6609
  },] }
6512
6610
  ];
6513
6611
  BarHorizontalStackedComponent.propDecorators = {
@@ -6548,7 +6646,7 @@
6548
6646
  var BarVerticalComponent = /** @class */ (function (_super) {
6549
6647
  __extends(BarVerticalComponent, _super);
6550
6648
  function BarVerticalComponent() {
6551
- var _this = _super.apply(this, __spread(arguments)) || this;
6649
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
6552
6650
  _this.legend = false;
6553
6651
  _this.legendTitle = 'Legend';
6554
6652
  _this.legendPosition = exports.LegendPosition.Right;
@@ -6618,13 +6716,13 @@
6618
6716
  };
6619
6717
  BarVerticalComponent.prototype.getYDomain = function () {
6620
6718
  var values = this.results.map(function (d) { return d.value; });
6621
- var min = this.yScaleMin ? Math.min.apply(Math, __spread([this.yScaleMin], values)) : Math.min.apply(Math, __spread([0], values));
6719
+ var min = this.yScaleMin ? Math.min.apply(Math, __spreadArray([this.yScaleMin], __read(values))) : Math.min.apply(Math, __spreadArray([0], __read(values)));
6622
6720
  if (this.yAxisTicks && !this.yAxisTicks.some(isNaN)) {
6623
- min = Math.min.apply(Math, __spread([min], this.yAxisTicks));
6721
+ min = Math.min.apply(Math, __spreadArray([min], __read(this.yAxisTicks)));
6624
6722
  }
6625
- var max = this.yScaleMax ? Math.max.apply(Math, __spread([this.yScaleMax], values)) : Math.max.apply(Math, __spread([0], values));
6723
+ var max = this.yScaleMax ? Math.max.apply(Math, __spreadArray([this.yScaleMax], __read(values))) : Math.max.apply(Math, __spreadArray([0], __read(values)));
6626
6724
  if (this.yAxisTicks && !this.yAxisTicks.some(isNaN)) {
6627
- max = Math.max.apply(Math, __spread([max], this.yAxisTicks));
6725
+ max = Math.max.apply(Math, __spreadArray([max], __read(this.yAxisTicks)));
6628
6726
  }
6629
6727
  return [min, max];
6630
6728
  };
@@ -6633,7 +6731,7 @@
6633
6731
  };
6634
6732
  BarVerticalComponent.prototype.setColors = function () {
6635
6733
  var domain;
6636
- if (this.schemeType === exports.ɵc.Ordinal) {
6734
+ if (this.schemeType === exports.ScaleType.Ordinal) {
6637
6735
  domain = this.xDomain;
6638
6736
  }
6639
6737
  else {
@@ -6649,7 +6747,7 @@
6649
6747
  title: undefined,
6650
6748
  position: this.legendPosition
6651
6749
  };
6652
- if (opts.scaleType === exports.ɵc.Ordinal) {
6750
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
6653
6751
  opts.domain = this.xDomain;
6654
6752
  opts.colors = this.colors;
6655
6753
  opts.title = this.legendTitle;
@@ -6698,7 +6796,7 @@
6698
6796
  if (idx > -1) {
6699
6797
  return;
6700
6798
  }
6701
- this.activeEntries = __spread([item], this.activeEntries);
6799
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
6702
6800
  this.activate.emit({ value: item, entries: this.activeEntries });
6703
6801
  };
6704
6802
  BarVerticalComponent.prototype.onDeactivate = function (item, fromLegend) {
@@ -6715,7 +6813,7 @@
6715
6813
  return d.name === item.name && d.value === item.value && d.series === item.series;
6716
6814
  });
6717
6815
  this.activeEntries.splice(idx, 1);
6718
- this.activeEntries = __spread(this.activeEntries);
6816
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
6719
6817
  this.deactivate.emit({ value: item, entries: this.activeEntries });
6720
6818
  };
6721
6819
  return BarVerticalComponent;
@@ -6723,10 +6821,10 @@
6723
6821
  BarVerticalComponent.decorators = [
6724
6822
  { type: core.Component, args: [{
6725
6823
  selector: 'ngx-charts-bar-vertical',
6726
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, true)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-series-vertical\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [series]=\"results\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [activeEntries]=\"activeEntries\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n (select)=\"onClick($event)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event)\"\n ></svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6824
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, true)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-series-vertical\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [series]=\"results\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [activeEntries]=\"activeEntries\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n (select)=\"onClick($event)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event)\"\n ></svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
6727
6825
  changeDetection: core.ChangeDetectionStrategy.OnPush,
6728
6826
  encapsulation: core.ViewEncapsulation.None,
6729
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
6827
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
6730
6828
  },] }
6731
6829
  ];
6732
6830
  BarVerticalComponent.propDecorators = {
@@ -6769,12 +6867,12 @@
6769
6867
  var BarVertical2DComponent = /** @class */ (function (_super) {
6770
6868
  __extends(BarVertical2DComponent, _super);
6771
6869
  function BarVertical2DComponent() {
6772
- var _this = _super.apply(this, __spread(arguments)) || this;
6870
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
6773
6871
  _this.legend = false;
6774
6872
  _this.legendTitle = 'Legend';
6775
6873
  _this.legendPosition = exports.LegendPosition.Right;
6776
6874
  _this.tooltipDisabled = false;
6777
- _this.scaleType = exports.ɵc.Ordinal;
6875
+ _this.scaleType = exports.ScaleType.Ordinal;
6778
6876
  _this.showGridLines = true;
6779
6877
  _this.activeEntries = [];
6780
6878
  _this.trimXAxisTicks = true;
@@ -6794,6 +6892,10 @@
6794
6892
  _this.xAxisHeight = 0;
6795
6893
  _this.yAxisWidth = 0;
6796
6894
  _this.dataLabelMaxHeight = { negative: 0, positive: 0 };
6895
+ _this.barOrientation = exports.BarOrientation;
6896
+ _this.trackBy = function (index, item) {
6897
+ return item.name;
6898
+ };
6797
6899
  return _this;
6798
6900
  }
6799
6901
  BarVertical2DComponent.prototype.update = function () {
@@ -6941,8 +7043,8 @@
6941
7043
  }
6942
7044
  finally { if (e_4) throw e_4.error; }
6943
7045
  }
6944
- var min = Math.min.apply(Math, __spread([0], domain));
6945
- var max = this.yScaleMax ? Math.max.apply(Math, __spread([this.yScaleMax], domain)) : Math.max.apply(Math, __spread([0], domain));
7046
+ var min = Math.min.apply(Math, __spreadArray([0], __read(domain)));
7047
+ var max = this.yScaleMax ? Math.max.apply(Math, __spreadArray([this.yScaleMax], __read(domain))) : Math.max.apply(Math, __spreadArray([0], __read(domain)));
6946
7048
  return [min, max];
6947
7049
  };
6948
7050
  BarVertical2DComponent.prototype.groupTransform = function (group) {
@@ -6954,12 +7056,9 @@
6954
7056
  }
6955
7057
  this.select.emit(data);
6956
7058
  };
6957
- BarVertical2DComponent.prototype.trackBy = function (index, item) {
6958
- return item.name;
6959
- };
6960
7059
  BarVertical2DComponent.prototype.setColors = function () {
6961
7060
  var domain;
6962
- if (this.schemeType === exports.ɵc.Ordinal) {
7061
+ if (this.schemeType === exports.ScaleType.Ordinal) {
6963
7062
  domain = this.innerDomain;
6964
7063
  }
6965
7064
  else {
@@ -6975,7 +7074,7 @@
6975
7074
  title: undefined,
6976
7075
  position: this.legendPosition
6977
7076
  };
6978
- if (opts.scaleType === exports.ɵc.Ordinal) {
7077
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
6979
7078
  opts.domain = this.innerDomain;
6980
7079
  opts.colors = this.colors;
6981
7080
  opts.title = this.legendTitle;
@@ -7013,7 +7112,7 @@
7013
7112
  return i.name === item.name && i.series === item.series;
7014
7113
  }
7015
7114
  });
7016
- this.activeEntries = __spread(items);
7115
+ this.activeEntries = __spreadArray([], __read(items));
7017
7116
  this.activate.emit({ value: item, entries: this.activeEntries });
7018
7117
  };
7019
7118
  BarVertical2DComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -7037,7 +7136,7 @@
7037
7136
  BarVertical2DComponent.decorators = [
7038
7137
  { type: core.Component, args: [{
7039
7138
  selector: 'ngx-charts-bar-vertical-2d',
7040
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-grid-panel-series\n [xScale]=\"groupScale\"\n [yScale]=\"valueScale\"\n [data]=\"results\"\n [dims]=\"dims\"\n orient=\"vertical\"\n ></svg:g>\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"groupScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"valueScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-series-vertical\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n [activeEntries]=\"activeEntries\"\n [xScale]=\"innerScale\"\n [yScale]=\"valueScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [seriesName]=\"group.name\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event, index)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
7139
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-grid-panel-series\n [xScale]=\"groupScale\"\n [yScale]=\"valueScale\"\n [data]=\"results\"\n [dims]=\"dims\"\n [orient]=\"barOrientation.Vertical\"\n ></svg:g>\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"groupScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"valueScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-series-vertical\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n [activeEntries]=\"activeEntries\"\n [xScale]=\"innerScale\"\n [yScale]=\"valueScale\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [seriesName]=\"group.name\"\n [roundEdges]=\"roundEdges\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event, index)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
7041
7140
  encapsulation: core.ViewEncapsulation.None,
7042
7141
  changeDetection: core.ChangeDetectionStrategy.OnPush,
7043
7142
  animations: [
@@ -7051,7 +7150,7 @@
7051
7150
  ])
7052
7151
  ])
7053
7152
  ],
7054
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
7153
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
7055
7154
  },] }
7056
7155
  ];
7057
7156
  BarVertical2DComponent.propDecorators = {
@@ -7095,7 +7194,7 @@
7095
7194
  var BarVerticalNormalizedComponent = /** @class */ (function (_super) {
7096
7195
  __extends(BarVerticalNormalizedComponent, _super);
7097
7196
  function BarVerticalNormalizedComponent() {
7098
- var _this = _super.apply(this, __spread(arguments)) || this;
7197
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
7099
7198
  _this.legend = false;
7100
7199
  _this.legendTitle = 'Legend';
7101
7200
  _this.legendPosition = exports.LegendPosition.Right;
@@ -7116,6 +7215,10 @@
7116
7215
  _this.margin = [10, 20, 10, 20];
7117
7216
  _this.xAxisHeight = 0;
7118
7217
  _this.yAxisWidth = 0;
7218
+ _this.barChartType = exports.BarChartType;
7219
+ _this.trackBy = function (index, item) {
7220
+ return item.name;
7221
+ };
7119
7222
  return _this;
7120
7223
  }
7121
7224
  BarVerticalNormalizedComponent.prototype.update = function () {
@@ -7212,12 +7315,9 @@
7212
7315
  }
7213
7316
  this.select.emit(data);
7214
7317
  };
7215
- BarVerticalNormalizedComponent.prototype.trackBy = function (index, item) {
7216
- return item.name;
7217
- };
7218
7318
  BarVerticalNormalizedComponent.prototype.setColors = function () {
7219
7319
  var domain;
7220
- if (this.schemeType === exports.ɵc.Ordinal) {
7320
+ if (this.schemeType === exports.ScaleType.Ordinal) {
7221
7321
  domain = this.innerDomain;
7222
7322
  }
7223
7323
  else {
@@ -7233,7 +7333,7 @@
7233
7333
  title: undefined,
7234
7334
  position: this.legendPosition
7235
7335
  };
7236
- if (opts.scaleType === exports.ɵc.Ordinal) {
7336
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
7237
7337
  opts.domain = this.innerDomain;
7238
7338
  opts.colors = this.colors;
7239
7339
  opts.title = this.legendTitle;
@@ -7271,7 +7371,7 @@
7271
7371
  return i.name === item.name && i.series === item.series;
7272
7372
  }
7273
7373
  });
7274
- this.activeEntries = __spread(items);
7374
+ this.activeEntries = __spreadArray([], __read(items));
7275
7375
  this.activate.emit({ value: item, entries: this.activeEntries });
7276
7376
  };
7277
7377
  BarVerticalNormalizedComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -7295,7 +7395,7 @@
7295
7395
  BarVerticalNormalizedComponent.decorators = [
7296
7396
  { type: core.Component, args: [{
7297
7397
  selector: 'ngx-charts-bar-vertical-normalized',
7298
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-vertical\n type=\"normalized\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
7398
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-vertical\n [type]=\"barChartType.Normalized\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
7299
7399
  encapsulation: core.ViewEncapsulation.None,
7300
7400
  changeDetection: core.ChangeDetectionStrategy.OnPush,
7301
7401
  animations: [
@@ -7309,7 +7409,7 @@
7309
7409
  ])
7310
7410
  ])
7311
7411
  ],
7312
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
7412
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
7313
7413
  },] }
7314
7414
  ];
7315
7415
  BarVerticalNormalizedComponent.propDecorators = {
@@ -7347,7 +7447,7 @@
7347
7447
  var BarVerticalStackedComponent = /** @class */ (function (_super) {
7348
7448
  __extends(BarVerticalStackedComponent, _super);
7349
7449
  function BarVerticalStackedComponent() {
7350
- var _this = _super.apply(this, __spread(arguments)) || this;
7450
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
7351
7451
  _this.legend = false;
7352
7452
  _this.legendTitle = 'Legend';
7353
7453
  _this.legendPosition = exports.LegendPosition.Right;
@@ -7369,6 +7469,10 @@
7369
7469
  _this.xAxisHeight = 0;
7370
7470
  _this.yAxisWidth = 0;
7371
7471
  _this.dataLabelMaxHeight = { negative: 0, positive: 0 };
7472
+ _this.barChartType = exports.BarChartType;
7473
+ _this.trackBy = function (index, item) {
7474
+ return item.name;
7475
+ };
7372
7476
  return _this;
7373
7477
  }
7374
7478
  BarVerticalStackedComponent.prototype.update = function () {
@@ -7499,8 +7603,8 @@
7499
7603
  }
7500
7604
  domain.push(smallest);
7501
7605
  domain.push(biggest);
7502
- var min = Math.min.apply(Math, __spread([0], domain));
7503
- var max = this.yScaleMax ? Math.max.apply(Math, __spread([this.yScaleMax], domain)) : Math.max.apply(Math, __spread(domain));
7606
+ var min = Math.min.apply(Math, __spreadArray([0], __read(domain)));
7607
+ var max = this.yScaleMax ? Math.max.apply(Math, __spreadArray([this.yScaleMax], __read(domain))) : Math.max.apply(Math, __spreadArray([], __read(domain)));
7504
7608
  return [min, max];
7505
7609
  };
7506
7610
  BarVerticalStackedComponent.prototype.getXScale = function () {
@@ -7532,12 +7636,9 @@
7532
7636
  }
7533
7637
  this.select.emit(data);
7534
7638
  };
7535
- BarVerticalStackedComponent.prototype.trackBy = function (index, item) {
7536
- return item.name;
7537
- };
7538
7639
  BarVerticalStackedComponent.prototype.setColors = function () {
7539
7640
  var domain;
7540
- if (this.schemeType === exports.ɵc.Ordinal) {
7641
+ if (this.schemeType === exports.ScaleType.Ordinal) {
7541
7642
  domain = this.innerDomain;
7542
7643
  }
7543
7644
  else {
@@ -7553,7 +7654,7 @@
7553
7654
  title: undefined,
7554
7655
  position: this.legendPosition
7555
7656
  };
7556
- if (opts.scaleType === exports.ɵc.Ordinal) {
7657
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
7557
7658
  opts.domain = this.innerDomain;
7558
7659
  opts.colors = this.colors;
7559
7660
  opts.title = this.legendTitle;
@@ -7591,7 +7692,7 @@
7591
7692
  return i.name === item.name && i.series === item.series;
7592
7693
  }
7593
7694
  });
7594
- this.activeEntries = __spread(items);
7695
+ this.activeEntries = __spreadArray([], __read(items));
7595
7696
  this.activate.emit({ value: item, entries: this.activeEntries });
7596
7697
  };
7597
7698
  BarVerticalStackedComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -7615,7 +7716,7 @@
7615
7716
  BarVerticalStackedComponent.decorators = [
7616
7717
  { type: core.Component, args: [{
7617
7718
  selector: 'ngx-charts-bar-vertical-stacked',
7618
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-vertical\n type=\"stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
7719
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, undefined, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, undefined, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"bar-chart chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n [xAxisOffset]=\"dataLabelMaxHeight.negative\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n *ngFor=\"let group of results; let index = index; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [attr.transform]=\"groupTransform(group)\"\n >\n <svg:g\n ngx-charts-series-vertical\n [type]=\"barChartType.Stacked\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [activeEntries]=\"activeEntries\"\n [colors]=\"colors\"\n [series]=\"group.series\"\n [dims]=\"dims\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [showDataLabel]=\"showDataLabel\"\n [dataLabelFormatting]=\"dataLabelFormatting\"\n [seriesName]=\"group.name\"\n [animations]=\"animations\"\n [noBarWhenZero]=\"noBarWhenZero\"\n (select)=\"onClick($event, group)\"\n (activate)=\"onActivate($event, group)\"\n (deactivate)=\"onDeactivate($event, group)\"\n (dataLabelHeightChanged)=\"onDataLabelMaxHeightChanged($event, index)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
7619
7720
  encapsulation: core.ViewEncapsulation.None,
7620
7721
  changeDetection: core.ChangeDetectionStrategy.OnPush,
7621
7722
  animations: [
@@ -7629,7 +7730,7 @@
7629
7730
  ])
7630
7731
  ])
7631
7732
  ],
7632
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
7733
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
7633
7734
  },] }
7634
7735
  ];
7635
7736
  BarVerticalStackedComponent.propDecorators = {
@@ -7667,12 +7768,7 @@
7667
7768
  tooltipTemplate: [{ type: core.ContentChild, args: ['tooltipTemplate',] }]
7668
7769
  };
7669
7770
 
7670
- (function (BarChartType) {
7671
- BarChartType["Standard"] = "standard";
7672
- BarChartType["Normalized"] = "normalized";
7673
- BarChartType["Stacked"] = "stacked";
7674
- })(exports.BarChartType || (exports.BarChartType = {}));
7675
-
7771
+ exports.D0Types = void 0;
7676
7772
  (function (D0Types) {
7677
7773
  D0Types["positive"] = "positive";
7678
7774
  D0Types["negative"] = "negative";
@@ -7690,18 +7786,19 @@
7690
7786
  this.deactivate = new core.EventEmitter();
7691
7787
  this.dataLabelWidthChanged = new core.EventEmitter();
7692
7788
  this.barsForDataLabels = [];
7789
+ this.barOrientation = exports.BarOrientation;
7693
7790
  }
7694
7791
  SeriesHorizontal.prototype.ngOnChanges = function (changes) {
7695
7792
  this.update();
7696
7793
  };
7697
7794
  SeriesHorizontal.prototype.update = function () {
7698
- var _a;
7795
+ var _b;
7699
7796
  var _this = this;
7700
7797
  this.updateTooltipSettings();
7701
- var d0 = (_a = {},
7702
- _a[exports.D0Types.positive] = 0,
7703
- _a[exports.D0Types.negative] = 0,
7704
- _a);
7798
+ var d0 = (_b = {},
7799
+ _b[exports.D0Types.positive] = 0,
7800
+ _b[exports.D0Types.negative] = 0,
7801
+ _b);
7705
7802
  var d0Type;
7706
7803
  d0Type = exports.D0Types.positive;
7707
7804
  var total;
@@ -7762,7 +7859,7 @@
7762
7859
  bar.offset1 = offset1;
7763
7860
  value = (offset1 - offset0).toFixed(2) + '%';
7764
7861
  }
7765
- if (_this.colors.scaleType === exports.ɵc.Ordinal) {
7862
+ if (_this.colors.scaleType === exports.ScaleType.Ordinal) {
7766
7863
  bar.color = _this.colors.getColor(label);
7767
7864
  }
7768
7865
  else {
@@ -7777,7 +7874,7 @@
7777
7874
  }
7778
7875
  var tooltipLabel = formattedLabel;
7779
7876
  bar.ariaLabel = formattedLabel + ' ' + value.toLocaleString();
7780
- if (_this.seriesName) {
7877
+ if (_this.seriesName !== null && _this.seriesName !== undefined) {
7781
7878
  tooltipLabel = _this.seriesName + " \u2022 " + formattedLabel;
7782
7879
  bar.data.series = _this.seriesName;
7783
7880
  bar.ariaLabel = _this.seriesName + ' ' + bar.ariaLabel;
@@ -7812,8 +7909,9 @@
7812
7909
  }
7813
7910
  else {
7814
7911
  this.barsForDataLabels = this.series.map(function (d) {
7912
+ var _a;
7815
7913
  var section = {};
7816
- section.series = _this.seriesName ? _this.seriesName : d.label;
7914
+ section.series = (_a = _this.seriesName) !== null && _a !== void 0 ? _a : d.label;
7817
7915
  section.total = d.value;
7818
7916
  section.x = _this.xScale(0);
7819
7917
  section.y = _this.yScale(d.label);
@@ -7830,8 +7928,8 @@
7830
7928
  SeriesHorizontal.prototype.isActive = function (entry) {
7831
7929
  if (!this.activeEntries)
7832
7930
  return false;
7833
- var item = this.activeEntries.find(function (d) {
7834
- return entry.name === d.name && entry.series === d.series;
7931
+ var item = this.activeEntries.find(function (active) {
7932
+ return entry.name === active.name && entry.value === active.value;
7835
7933
  });
7836
7934
  return item !== undefined;
7837
7935
  };
@@ -7855,7 +7953,7 @@
7855
7953
  SeriesHorizontal.decorators = [
7856
7954
  { type: core.Component, args: [{
7857
7955
  selector: 'g[ngx-charts-series-horizontal]',
7858
- template: "\n <svg:g\n ngx-charts-bar\n *ngFor=\"let bar of bars; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [width]=\"bar.width\"\n [height]=\"bar.height\"\n [x]=\"bar.x\"\n [y]=\"bar.y\"\n [fill]=\"bar.color\"\n [stops]=\"bar.gradientStops\"\n [data]=\"bar.data\"\n [orientation]=\"'horizontal'\"\n [roundEdges]=\"bar.roundEdges\"\n (select)=\"click($event)\"\n [gradient]=\"gradient\"\n [isActive]=\"isActive(bar.data)\"\n [ariaLabel]=\"bar.ariaLabel\"\n [animations]=\"animations\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"tooltipPlacement\"\n [tooltipType]=\"tooltipType\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : bar.tooltipText\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"bar.data\"\n [noBarWhenZero]=\"noBarWhenZero\"\n ></svg:g>\n <svg:g *ngIf=\"showDataLabel\">\n <svg:g\n ngx-charts-bar-label\n *ngFor=\"let b of barsForDataLabels; let i = index; trackBy: trackDataLabelBy\"\n [barX]=\"b.x\"\n [barY]=\"b.y\"\n [barWidth]=\"b.width\"\n [barHeight]=\"b.height\"\n [value]=\"b.total\"\n [valueFormatting]=\"dataLabelFormatting\"\n [orientation]=\"'horizontal'\"\n (dimensionsChanged)=\"dataLabelWidthChanged.emit({ size: $event, index: i })\"\n />\n </svg:g>\n ",
7956
+ template: "\n <svg:g\n ngx-charts-bar\n *ngFor=\"let bar of bars; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [width]=\"bar.width\"\n [height]=\"bar.height\"\n [x]=\"bar.x\"\n [y]=\"bar.y\"\n [fill]=\"bar.color\"\n [stops]=\"bar.gradientStops\"\n [data]=\"bar.data\"\n [orientation]=\"barOrientation.Horizontal\"\n [roundEdges]=\"bar.roundEdges\"\n (select)=\"click($event)\"\n [gradient]=\"gradient\"\n [isActive]=\"isActive(bar.data)\"\n [ariaLabel]=\"bar.ariaLabel\"\n [animations]=\"animations\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"tooltipPlacement\"\n [tooltipType]=\"tooltipType\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : bar.tooltipText\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"bar.data\"\n [noBarWhenZero]=\"noBarWhenZero\"\n ></svg:g>\n <svg:g *ngIf=\"showDataLabel\">\n <svg:g\n ngx-charts-bar-label\n *ngFor=\"let b of barsForDataLabels; let i = index; trackBy: trackDataLabelBy\"\n [barX]=\"b.x\"\n [barY]=\"b.y\"\n [barWidth]=\"b.width\"\n [barHeight]=\"b.height\"\n [value]=\"b.total\"\n [valueFormatting]=\"dataLabelFormatting\"\n [orientation]=\"barOrientation.Horizontal\"\n (dimensionsChanged)=\"dataLabelWidthChanged.emit({ size: $event, index: i })\"\n />\n </svg:g>\n ",
7859
7957
  changeDetection: core.ChangeDetectionStrategy.OnPush,
7860
7958
  animations: [
7861
7959
  animations.trigger('animationState', [
@@ -7904,12 +8002,13 @@
7904
8002
  this.deactivate = new core.EventEmitter();
7905
8003
  this.dataLabelHeightChanged = new core.EventEmitter();
7906
8004
  this.barsForDataLabels = [];
8005
+ this.barOrientation = exports.BarOrientation;
7907
8006
  }
7908
8007
  SeriesVerticalComponent.prototype.ngOnChanges = function (changes) {
7909
8008
  this.update();
7910
8009
  };
7911
8010
  SeriesVerticalComponent.prototype.update = function () {
7912
- var _a;
8011
+ var _b;
7913
8012
  var _this = this;
7914
8013
  this.updateTooltipSettings();
7915
8014
  var width;
@@ -7918,10 +8017,10 @@
7918
8017
  }
7919
8018
  width = Math.round(width);
7920
8019
  var yScaleMin = Math.max(this.yScale.domain()[0], 0);
7921
- var d0 = (_a = {},
7922
- _a[exports.D0Types.positive] = 0,
7923
- _a[exports.D0Types.negative] = 0,
7924
- _a);
8020
+ var d0 = (_b = {},
8021
+ _b[exports.D0Types.positive] = 0,
8022
+ _b[exports.D0Types.negative] = 0,
8023
+ _b);
7925
8024
  var d0Type = exports.D0Types.positive;
7926
8025
  var total;
7927
8026
  if (this.type === exports.BarChartType.Normalized) {
@@ -7983,7 +8082,7 @@
7983
8082
  bar.offset1 = offset1;
7984
8083
  value = (offset1 - offset0).toFixed(2) + '%';
7985
8084
  }
7986
- if (_this.colors.scaleType === exports.ɵc.Ordinal) {
8085
+ if (_this.colors.scaleType === exports.ScaleType.Ordinal) {
7987
8086
  bar.color = _this.colors.getColor(label);
7988
8087
  }
7989
8088
  else {
@@ -7998,7 +8097,7 @@
7998
8097
  }
7999
8098
  var tooltipLabel = formattedLabel;
8000
8099
  bar.ariaLabel = formattedLabel + ' ' + value.toLocaleString();
8001
- if (_this.seriesName) {
8100
+ if (_this.seriesName !== null && _this.seriesName !== undefined) {
8002
8101
  tooltipLabel = _this.seriesName + " \u2022 " + formattedLabel;
8003
8102
  bar.data.series = _this.seriesName;
8004
8103
  bar.ariaLabel = _this.seriesName + ' ' + bar.ariaLabel;
@@ -8032,8 +8131,9 @@
8032
8131
  }
8033
8132
  else {
8034
8133
  this.barsForDataLabels = this.series.map(function (d) {
8134
+ var _a;
8035
8135
  var section = {};
8036
- section.series = _this.seriesName ? _this.seriesName : d.label;
8136
+ section.series = (_a = _this.seriesName) !== null && _a !== void 0 ? _a : d.label;
8037
8137
  section.total = d.value;
8038
8138
  section.x = _this.xScale(d.label);
8039
8139
  section.y = _this.yScale(0);
@@ -8050,8 +8150,8 @@
8050
8150
  SeriesVerticalComponent.prototype.isActive = function (entry) {
8051
8151
  if (!this.activeEntries)
8052
8152
  return false;
8053
- var item = this.activeEntries.find(function (d) {
8054
- return entry.name === d.name && entry.series === d.series;
8153
+ var item = this.activeEntries.find(function (active) {
8154
+ return entry.name === active.name && entry.value === active.value;
8055
8155
  });
8056
8156
  return item !== undefined;
8057
8157
  };
@@ -8075,7 +8175,7 @@
8075
8175
  SeriesVerticalComponent.decorators = [
8076
8176
  { type: core.Component, args: [{
8077
8177
  selector: 'g[ngx-charts-series-vertical]',
8078
- template: "\n <svg:g\n ngx-charts-bar\n *ngFor=\"let bar of bars; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [@.disabled]=\"!animations\"\n [width]=\"bar.width\"\n [height]=\"bar.height\"\n [x]=\"bar.x\"\n [y]=\"bar.y\"\n [fill]=\"bar.color\"\n [stops]=\"bar.gradientStops\"\n [data]=\"bar.data\"\n [orientation]=\"'vertical'\"\n [roundEdges]=\"bar.roundEdges\"\n [gradient]=\"gradient\"\n [ariaLabel]=\"bar.ariaLabel\"\n [isActive]=\"isActive(bar.data)\"\n (select)=\"onClick($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"tooltipPlacement\"\n [tooltipType]=\"tooltipType\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : bar.tooltipText\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"bar.data\"\n [noBarWhenZero]=\"noBarWhenZero\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g *ngIf=\"showDataLabel\">\n <svg:g\n ngx-charts-bar-label\n *ngFor=\"let b of barsForDataLabels; let i = index; trackBy: trackDataLabelBy\"\n [barX]=\"b.x\"\n [barY]=\"b.y\"\n [barWidth]=\"b.width\"\n [barHeight]=\"b.height\"\n [value]=\"b.total\"\n [valueFormatting]=\"dataLabelFormatting\"\n [orientation]=\"'vertical'\"\n (dimensionsChanged)=\"dataLabelHeightChanged.emit({ size: $event, index: i })\"\n />\n </svg:g>\n ",
8178
+ template: "\n <svg:g\n ngx-charts-bar\n *ngFor=\"let bar of bars; trackBy: trackBy\"\n [@animationState]=\"'active'\"\n [@.disabled]=\"!animations\"\n [width]=\"bar.width\"\n [height]=\"bar.height\"\n [x]=\"bar.x\"\n [y]=\"bar.y\"\n [fill]=\"bar.color\"\n [stops]=\"bar.gradientStops\"\n [data]=\"bar.data\"\n [orientation]=\"barOrientation.Vertical\"\n [roundEdges]=\"bar.roundEdges\"\n [gradient]=\"gradient\"\n [ariaLabel]=\"bar.ariaLabel\"\n [isActive]=\"isActive(bar.data)\"\n (select)=\"onClick($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"tooltipPlacement\"\n [tooltipType]=\"tooltipType\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : bar.tooltipText\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"bar.data\"\n [noBarWhenZero]=\"noBarWhenZero\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g *ngIf=\"showDataLabel\">\n <svg:g\n ngx-charts-bar-label\n *ngFor=\"let b of barsForDataLabels; let i = index; trackBy: trackDataLabelBy\"\n [barX]=\"b.x\"\n [barY]=\"b.y\"\n [barWidth]=\"b.width\"\n [barHeight]=\"b.height\"\n [value]=\"b.total\"\n [valueFormatting]=\"dataLabelFormatting\"\n [orientation]=\"barOrientation.Vertical\"\n (dimensionsChanged)=\"dataLabelHeightChanged.emit({ size: $event, index: i })\"\n />\n </svg:g>\n ",
8079
8179
  changeDetection: core.ChangeDetectionStrategy.OnPush,
8080
8180
  animations: [
8081
8181
  animations.trigger('animationState', [
@@ -8173,7 +8273,7 @@
8173
8273
  selector: 'g[ngx-charts-bar-label]',
8174
8274
  template: "\n <svg:text\n class=\"textDataLabel\"\n alignment-baseline=\"middle\"\n [attr.text-anchor]=\"textAnchor\"\n [attr.transform]=\"transform\"\n [attr.x]=\"x\"\n [attr.y]=\"y\"\n >\n {{ formatedValue }}\n </svg:text>\n ",
8175
8275
  changeDetection: core.ChangeDetectionStrategy.OnPush,
8176
- styles: [".textDataLabel{font-size:11px}"]
8276
+ styles: [".textDataLabel{font-size:11px}\n"]
8177
8277
  },] }
8178
8278
  ];
8179
8279
  BarLabelComponent.ctorParameters = function () { return [
@@ -8229,17 +8329,650 @@
8229
8329
  },] }
8230
8330
  ];
8231
8331
 
8332
+ var BoxChartComponent = /** @class */ (function (_super) {
8333
+ __extends(BoxChartComponent, _super);
8334
+ function BoxChartComponent() {
8335
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
8336
+ /** Show or hide the legend. */
8337
+ _this.legend = false;
8338
+ _this.legendPosition = exports.LegendPosition.Right;
8339
+ _this.legendTitle = 'Legend';
8340
+ _this.showGridLines = true;
8341
+ _this.xAxis = true;
8342
+ _this.yAxis = true;
8343
+ _this.showXAxisLabel = true;
8344
+ _this.showYAxisLabel = true;
8345
+ _this.roundDomains = false;
8346
+ _this.roundEdges = true;
8347
+ _this.strokeColor = '#FFFFFF';
8348
+ _this.strokeWidth = 2;
8349
+ _this.tooltipDisabled = false;
8350
+ _this.select = new core.EventEmitter();
8351
+ _this.activate = new core.EventEmitter();
8352
+ _this.deactivate = new core.EventEmitter();
8353
+ /** Chart Margins (For each side, counterclock wise). */
8354
+ _this.margin = [10, 20, 10, 20];
8355
+ /** Chart X axis dimension. */
8356
+ _this.xAxisHeight = 0;
8357
+ /** Chart Y axis dimension. */
8358
+ _this.yAxisWidth = 0;
8359
+ return _this;
8360
+ }
8361
+ BoxChartComponent.prototype.trackBy = function (index, item) {
8362
+ return item.name;
8363
+ };
8364
+ BoxChartComponent.prototype.update = function () {
8365
+ _super.prototype.update.call(this);
8366
+ this.dims = calculateViewDimensions({
8367
+ width: this.width,
8368
+ height: this.height,
8369
+ margins: this.margin,
8370
+ showXAxis: this.xAxis,
8371
+ showYAxis: this.yAxis,
8372
+ xAxisHeight: this.xAxisHeight,
8373
+ yAxisWidth: this.yAxisWidth,
8374
+ showXLabel: this.showXAxisLabel,
8375
+ showYLabel: this.showYAxisLabel,
8376
+ showLegend: this.legend,
8377
+ legendPosition: this.legendPosition
8378
+ });
8379
+ this.xDomain = this.getXDomain();
8380
+ this.yDomain = this.getYDomain();
8381
+ this.seriesDomain = this.getSeriesDomain();
8382
+ this.setScales();
8383
+ this.setColors();
8384
+ this.legendOptions = this.getLegendOptions();
8385
+ this.transform = "translate(" + this.dims.xOffset + " , " + this.margin[0] + ")";
8386
+ };
8387
+ BoxChartComponent.prototype.setColors = function () {
8388
+ var domain = [];
8389
+ if (this.schemeType === exports.ScaleType.Ordinal) {
8390
+ domain = this.seriesDomain;
8391
+ }
8392
+ else {
8393
+ domain = this.yDomain;
8394
+ }
8395
+ this.colors = new ColorHelper(this.scheme, this.schemeType, domain, this.customColors);
8396
+ };
8397
+ BoxChartComponent.prototype.setScales = function () {
8398
+ this.xScale = this.getXScale(this.xDomain, this.dims.width);
8399
+ this.yScale = this.getYScale(this.yDomain, this.dims.height);
8400
+ };
8401
+ BoxChartComponent.prototype.getXScale = function (domain, width) {
8402
+ var scale = d3Scale.scaleBand()
8403
+ .domain(domain.map(function (d) { return d.toString(); }))
8404
+ .rangeRound([0, width])
8405
+ .padding(0.5);
8406
+ return scale;
8407
+ };
8408
+ BoxChartComponent.prototype.getYScale = function (domain, height) {
8409
+ var scale = d3Scale.scaleLinear().domain(domain).range([height, 0]);
8410
+ return this.roundDomains ? scale.nice() : scale;
8411
+ };
8412
+ BoxChartComponent.prototype.getUniqueBoxChartXDomainValues = function (results) {
8413
+ var e_1, _a;
8414
+ var valueSet = new Set();
8415
+ try {
8416
+ for (var results_1 = __values(results), results_1_1 = results_1.next(); !results_1_1.done; results_1_1 = results_1.next()) {
8417
+ var result = results_1_1.value;
8418
+ valueSet.add(result.name);
8419
+ }
8420
+ }
8421
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
8422
+ finally {
8423
+ try {
8424
+ if (results_1_1 && !results_1_1.done && (_a = results_1.return)) _a.call(results_1);
8425
+ }
8426
+ finally { if (e_1) throw e_1.error; }
8427
+ }
8428
+ return Array.from(valueSet);
8429
+ };
8430
+ BoxChartComponent.prototype.getXDomain = function () {
8431
+ var domain = [];
8432
+ var values = this.getUniqueBoxChartXDomainValues(this.results);
8433
+ var min;
8434
+ var max;
8435
+ if (typeof values[0] === 'string') {
8436
+ domain = values.map(function (val) { return val.toString(); });
8437
+ }
8438
+ else if (typeof values[0] === 'number') {
8439
+ var mappedValues = values.map(function (v) { return Number(v); });
8440
+ min = Math.min.apply(Math, __spreadArray([], __read(mappedValues)));
8441
+ max = Math.max.apply(Math, __spreadArray([], __read(mappedValues)));
8442
+ domain = [min, max];
8443
+ }
8444
+ else {
8445
+ var mappedValues = values.map(function (v) { return Number(new Date(v)); });
8446
+ min = Math.min.apply(Math, __spreadArray([], __read(mappedValues)));
8447
+ max = Math.max.apply(Math, __spreadArray([], __read(mappedValues)));
8448
+ domain = [new Date(min), new Date(max)];
8449
+ }
8450
+ return domain;
8451
+ };
8452
+ BoxChartComponent.prototype.getYDomain = function () {
8453
+ var e_2, _a, e_3, _b;
8454
+ var domain = [];
8455
+ try {
8456
+ for (var _c = __values(this.results), _d = _c.next(); !_d.done; _d = _c.next()) {
8457
+ var results = _d.value;
8458
+ try {
8459
+ for (var _e = (e_3 = void 0, __values(results.series)), _f = _e.next(); !_f.done; _f = _e.next()) {
8460
+ var d = _f.value;
8461
+ if (domain.indexOf(d.value) < 0) {
8462
+ domain.push(d.value);
8463
+ }
8464
+ }
8465
+ }
8466
+ catch (e_3_1) { e_3 = { error: e_3_1 }; }
8467
+ finally {
8468
+ try {
8469
+ if (_f && !_f.done && (_b = _e.return)) _b.call(_e);
8470
+ }
8471
+ finally { if (e_3) throw e_3.error; }
8472
+ }
8473
+ }
8474
+ }
8475
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
8476
+ finally {
8477
+ try {
8478
+ if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
8479
+ }
8480
+ finally { if (e_2) throw e_2.error; }
8481
+ }
8482
+ var values = __spreadArray([], __read(domain));
8483
+ var mappedValues = values.map(function (v) { return Number(v); });
8484
+ var min = Math.min.apply(Math, __spreadArray([], __read(mappedValues)));
8485
+ var max = Math.max.apply(Math, __spreadArray([], __read(mappedValues)));
8486
+ return [min, max];
8487
+ };
8488
+ BoxChartComponent.prototype.getSeriesDomain = function () {
8489
+ return this.results.map(function (d) { return "" + d.name; });
8490
+ };
8491
+ BoxChartComponent.prototype.updateYAxisWidth = function (_a) {
8492
+ var width = _a.width;
8493
+ this.yAxisWidth = width;
8494
+ this.update();
8495
+ };
8496
+ BoxChartComponent.prototype.updateXAxisHeight = function (_a) {
8497
+ var height = _a.height;
8498
+ this.xAxisHeight = height;
8499
+ this.update();
8500
+ };
8501
+ BoxChartComponent.prototype.onClick = function (data) {
8502
+ this.select.emit(data);
8503
+ };
8504
+ BoxChartComponent.prototype.onActivate = function (data) {
8505
+ this.activate.emit(data);
8506
+ };
8507
+ BoxChartComponent.prototype.onDeactivate = function (data) {
8508
+ this.deactivate.emit(data);
8509
+ };
8510
+ BoxChartComponent.prototype.getLegendOptions = function () {
8511
+ var legendOpts = {
8512
+ scaleType: this.schemeType,
8513
+ colors: this.colors,
8514
+ domain: [],
8515
+ position: this.legendPosition,
8516
+ title: this.legendTitle
8517
+ };
8518
+ if (this.schemeType === exports.ScaleType.Ordinal) {
8519
+ legendOpts.domain = this.xDomain;
8520
+ legendOpts.colors = this.colors;
8521
+ }
8522
+ else {
8523
+ legendOpts.domain = this.yDomain;
8524
+ legendOpts.colors = this.colors.scale;
8525
+ }
8526
+ return legendOpts;
8527
+ };
8528
+ return BoxChartComponent;
8529
+ }(BaseChartComponent));
8530
+ BoxChartComponent.decorators = [
8531
+ { type: core.Component, args: [{
8532
+ selector: 'ngx-charts-box-chart',
8533
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"box-chart chart\">\n <svg:g\n ngx-charts-x-axis\n [showGridLines]=\"showGridLines\"\n [dims]=\"dims\"\n [xScale]=\"xScale\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n />\n <svg:g\n ngx-charts-y-axis\n [showGridLines]=\"showGridLines\"\n [dims]=\"dims\"\n [yScale]=\"yScale\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n />\n </svg:g>\n <svg:g [attr.transform]=\"transform\">\n <svg:g *ngFor=\"let result of results; trackBy: trackBy\">\n <svg:g\n ngx-charts-box-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [roundEdges]=\"roundEdges\"\n [strokeColor]=\"strokeColor\"\n [strokeWidth]=\"strokeWidth\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [series]=\"result\"\n [dims]=\"dims\"\n [animations]=\"animations\"\n [gradient]=\"gradient\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n (select)=\"onClick($event)\"\n />\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
8534
+ changeDetection: core.ChangeDetectionStrategy.OnPush,
8535
+ encapsulation: core.ViewEncapsulation.None,
8536
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
8537
+ },] }
8538
+ ];
8539
+ BoxChartComponent.propDecorators = {
8540
+ legend: [{ type: core.Input }],
8541
+ legendPosition: [{ type: core.Input }],
8542
+ legendTitle: [{ type: core.Input }],
8543
+ legendOptionsConfig: [{ type: core.Input }],
8544
+ showGridLines: [{ type: core.Input }],
8545
+ xAxis: [{ type: core.Input }],
8546
+ yAxis: [{ type: core.Input }],
8547
+ showXAxisLabel: [{ type: core.Input }],
8548
+ showYAxisLabel: [{ type: core.Input }],
8549
+ roundDomains: [{ type: core.Input }],
8550
+ xAxisLabel: [{ type: core.Input }],
8551
+ yAxisLabel: [{ type: core.Input }],
8552
+ roundEdges: [{ type: core.Input }],
8553
+ strokeColor: [{ type: core.Input }],
8554
+ strokeWidth: [{ type: core.Input }],
8555
+ tooltipDisabled: [{ type: core.Input }],
8556
+ gradient: [{ type: core.Input }],
8557
+ select: [{ type: core.Output }],
8558
+ activate: [{ type: core.Output }],
8559
+ deactivate: [{ type: core.Output }],
8560
+ tooltipTemplate: [{ type: core.ContentChild, args: ['tooltipTemplate', { static: false },] }]
8561
+ };
8562
+
8563
+ var BoxSeriesComponent = /** @class */ (function () {
8564
+ function BoxSeriesComponent() {
8565
+ this.animations = true;
8566
+ this.tooltipDisabled = false;
8567
+ this.gradient = false;
8568
+ this.select = new core.EventEmitter();
8569
+ this.activate = new core.EventEmitter();
8570
+ this.deactivate = new core.EventEmitter();
8571
+ }
8572
+ BoxSeriesComponent.prototype.ngOnChanges = function (changes) {
8573
+ this.update();
8574
+ };
8575
+ BoxSeriesComponent.prototype.onClick = function (data) {
8576
+ this.select.emit(data);
8577
+ };
8578
+ BoxSeriesComponent.prototype.update = function () {
8579
+ this.updateTooltipSettings();
8580
+ var width = this.series && this.series.series.length ? Math.round(this.xScale.bandwidth()) : null;
8581
+ var seriesName = this.series.name;
8582
+ // Calculate Quantile and Whiskers for each box serie.
8583
+ this.counts = this.series.series;
8584
+ var mappedCounts = this.counts.map(function (serie) { return Number(serie.value); });
8585
+ this.whiskers = [d3Array.min(mappedCounts), d3Array.max(mappedCounts)];
8586
+ // We get the group count and must sort it in order to retrieve quantiles.
8587
+ var groupCounts = this.counts.map(function (item) { return item.value; }).sort(function (a, b) { return Number(a) - Number(b); });
8588
+ this.quartiles = this.getBoxQuantiles(groupCounts);
8589
+ this.lineCoordinates = this.getLinesCoordinates(seriesName.toString(), this.whiskers, this.quartiles, width);
8590
+ var value = this.quartiles[1];
8591
+ var formattedLabel = formatLabel(seriesName);
8592
+ var box = {
8593
+ value: value,
8594
+ data: this.counts,
8595
+ label: seriesName,
8596
+ formattedLabel: formattedLabel,
8597
+ width: width,
8598
+ height: 0,
8599
+ x: 0,
8600
+ y: 0,
8601
+ roundEdges: this.roundEdges,
8602
+ quartiles: this.quartiles,
8603
+ lineCoordinates: this.lineCoordinates
8604
+ };
8605
+ box.height = Math.abs(this.yScale(this.quartiles[0]) - this.yScale(this.quartiles[2]));
8606
+ box.x = this.xScale(seriesName.toString());
8607
+ box.y = this.yScale(this.quartiles[2]);
8608
+ box.ariaLabel = formattedLabel + ' - Median: ' + value.toLocaleString();
8609
+ if (this.colors.scaleType === exports.ScaleType.Ordinal) {
8610
+ box.color = this.colors.getColor(seriesName);
8611
+ }
8612
+ else {
8613
+ box.color = this.colors.getColor(this.quartiles[1]);
8614
+ box.gradientStops = this.colors.getLinearGradientStops(this.quartiles[0], this.quartiles[2]);
8615
+ }
8616
+ var tooltipLabel = formattedLabel;
8617
+ var formattedTooltipLabel = "\n <span class=\"tooltip-label\">" + escapeLabel(tooltipLabel) + "</span>\n <span class=\"tooltip-val\">\n \u2022 Q1: " + this.quartiles[0] + " \u2022 Q2: " + this.quartiles[1] + " \u2022 Q3: " + this.quartiles[2] + "<br>\n \u2022 Min: " + this.whiskers[0] + " \u2022 Max: " + this.whiskers[1] + "\n </span>";
8618
+ box.tooltipText = this.tooltipDisabled ? undefined : formattedTooltipLabel;
8619
+ this.tooltipTitle = this.tooltipDisabled ? undefined : box.tooltipText;
8620
+ this.box = box;
8621
+ };
8622
+ BoxSeriesComponent.prototype.getBoxQuantiles = function (inputData) {
8623
+ return [d3Array.quantile(inputData, 0.25), d3Array.quantile(inputData, 0.5), d3Array.quantile(inputData, 0.75)];
8624
+ };
8625
+ BoxSeriesComponent.prototype.getLinesCoordinates = function (seriesName, whiskers, quartiles, barWidth) {
8626
+ // The X value is not being centered, so had to sum half the width to align it.
8627
+ var commonX = this.xScale(seriesName);
8628
+ var offsetX = commonX + barWidth / 2;
8629
+ var medianLineWidth = Math.max(barWidth + 4 * this.strokeWidth, 1);
8630
+ var whiskerLineWidth = Math.max(barWidth / 3, 1);
8631
+ var whiskerZero = this.yScale(whiskers[0]);
8632
+ var whiskerOne = this.yScale(whiskers[1]);
8633
+ var median = this.yScale(quartiles[1]);
8634
+ var topLine = {
8635
+ v1: { x: offsetX + whiskerLineWidth / 2, y: whiskerZero },
8636
+ v2: { x: offsetX - whiskerLineWidth / 2, y: whiskerZero }
8637
+ };
8638
+ var medianLine = {
8639
+ v1: { x: offsetX + medianLineWidth / 2, y: median },
8640
+ v2: { x: offsetX - medianLineWidth / 2, y: median }
8641
+ };
8642
+ var bottomLine = {
8643
+ v1: { x: offsetX + whiskerLineWidth / 2, y: whiskerOne },
8644
+ v2: { x: offsetX - whiskerLineWidth / 2, y: whiskerOne }
8645
+ };
8646
+ var verticalLine = {
8647
+ v1: { x: offsetX, y: whiskerZero },
8648
+ v2: { x: offsetX, y: whiskerOne }
8649
+ };
8650
+ return [verticalLine, topLine, medianLine, bottomLine];
8651
+ };
8652
+ BoxSeriesComponent.prototype.updateTooltipSettings = function () {
8653
+ if (this.tooltipDisabled) {
8654
+ this.tooltipPlacement = undefined;
8655
+ this.tooltipType = undefined;
8656
+ }
8657
+ else {
8658
+ if (!this.tooltipPlacement) {
8659
+ this.tooltipPlacement = exports.PlacementTypes.Top;
8660
+ }
8661
+ if (!this.tooltipType) {
8662
+ this.tooltipType = exports.StyleTypes.tooltip;
8663
+ }
8664
+ }
8665
+ };
8666
+ return BoxSeriesComponent;
8667
+ }());
8668
+ BoxSeriesComponent.decorators = [
8669
+ { type: core.Component, args: [{
8670
+ selector: 'g[ngx-charts-box-series]',
8671
+ template: "\n <svg:g\n ngx-charts-box\n [@animationState]=\"'active'\"\n [@.disabled]=\"!animations\"\n [width]=\"box.width\"\n [height]=\"box.height\"\n [x]=\"box.x\"\n [y]=\"box.y\"\n [roundEdges]=\"box.roundEdges\"\n [fill]=\"box.color\"\n [gradientStops]=\"box.gradientStops\"\n [strokeColor]=\"strokeColor\"\n [strokeWidth]=\"strokeWidth\"\n [data]=\"box.data\"\n [lineCoordinates]=\"box.lineCoordinates\"\n [gradient]=\"gradient\"\n [ariaLabel]=\"box.ariaLabel\"\n (select)=\"onClick($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"tooltipPlacement\"\n [tooltipType]=\"tooltipType\"\n [tooltipTitle]=\"tooltipTitle\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"box.data\"\n [animations]=\"animations\"\n ></svg:g>\n ",
8672
+ changeDetection: core.ChangeDetectionStrategy.OnPush,
8673
+ animations: [
8674
+ animations.trigger('animationState', [
8675
+ animations.transition(':leave', [
8676
+ animations.style({
8677
+ opacity: 1
8678
+ }),
8679
+ animations.animate(500, animations.style({ opacity: 0 }))
8680
+ ])
8681
+ ])
8682
+ ]
8683
+ },] }
8684
+ ];
8685
+ BoxSeriesComponent.propDecorators = {
8686
+ dims: [{ type: core.Input }],
8687
+ series: [{ type: core.Input }],
8688
+ xScale: [{ type: core.Input }],
8689
+ yScale: [{ type: core.Input }],
8690
+ colors: [{ type: core.Input }],
8691
+ animations: [{ type: core.Input }],
8692
+ strokeColor: [{ type: core.Input }],
8693
+ strokeWidth: [{ type: core.Input }],
8694
+ tooltipDisabled: [{ type: core.Input }],
8695
+ tooltipTemplate: [{ type: core.Input }],
8696
+ tooltipPlacement: [{ type: core.Input }],
8697
+ tooltipType: [{ type: core.Input }],
8698
+ roundEdges: [{ type: core.Input }],
8699
+ gradient: [{ type: core.Input }],
8700
+ select: [{ type: core.Output }],
8701
+ activate: [{ type: core.Output }],
8702
+ deactivate: [{ type: core.Output }]
8703
+ };
8704
+
8705
+ var BoxComponent = /** @class */ (function () {
8706
+ function BoxComponent(element, cd) {
8707
+ this.cd = cd;
8708
+ this.roundEdges = true;
8709
+ this.gradient = false;
8710
+ this.offset = 0;
8711
+ this.isActive = false;
8712
+ this.animations = true;
8713
+ this.noBarWhenZero = true;
8714
+ this.select = new core.EventEmitter();
8715
+ this.activate = new core.EventEmitter();
8716
+ this.deactivate = new core.EventEmitter();
8717
+ this.BarOrientation = exports.BarOrientation;
8718
+ this.initialized = false;
8719
+ this.hasGradient = false;
8720
+ this.hideBar = false;
8721
+ this.nativeElm = element.nativeElement;
8722
+ }
8723
+ BoxComponent.prototype.ngOnChanges = function (changes) {
8724
+ if (!this.initialized) {
8725
+ this.loadAnimation();
8726
+ this.initialized = true;
8727
+ }
8728
+ else {
8729
+ this.update();
8730
+ }
8731
+ };
8732
+ BoxComponent.prototype.update = function () {
8733
+ this.boxStrokeWidth = Math.max(this.strokeWidth, 1);
8734
+ this.whiskerStrokeWidth = Math.max(this.strokeWidth / 2, 1);
8735
+ this.medianLineWidth = 1.5 * this.strokeWidth;
8736
+ this.gradientId = 'grad' + id().toString();
8737
+ this.gradientFill = "url(#" + this.gradientId + ")";
8738
+ if (this.gradient) {
8739
+ this.gradientStops = this.getGradient();
8740
+ this.hasGradient = true;
8741
+ }
8742
+ else {
8743
+ this.hasGradient = false;
8744
+ }
8745
+ this.updateLineEl();
8746
+ this.updatePathEl();
8747
+ this.checkToHideBar();
8748
+ this.maskLineId = 'mask' + id().toString();
8749
+ this.maskLine = "url(#" + this.maskLineId + ")";
8750
+ if (this.cd) {
8751
+ this.cd.markForCheck();
8752
+ }
8753
+ };
8754
+ BoxComponent.prototype.loadAnimation = function () {
8755
+ this.boxPath = this.oldPath = this.getStartingPath();
8756
+ this.oldLineCoordinates = this.getStartingLineCoordinates();
8757
+ setTimeout(this.update.bind(this), 100);
8758
+ };
8759
+ BoxComponent.prototype.updatePathEl = function () {
8760
+ var nodeBar = d3Selection.select(this.nativeElm).selectAll('.bar');
8761
+ var path = this.getPath();
8762
+ if (this.animations) {
8763
+ nodeBar
8764
+ .attr('d', this.oldPath)
8765
+ .transition()
8766
+ .ease(d3Ease.easeSinInOut)
8767
+ .duration(500)
8768
+ .attrTween('d', this.pathTween(path, 4));
8769
+ }
8770
+ else {
8771
+ nodeBar.attr('d', path);
8772
+ }
8773
+ this.oldPath = path;
8774
+ };
8775
+ BoxComponent.prototype.updateLineEl = function () {
8776
+ var lineEl = d3Selection.select(this.nativeElm).selectAll('.bar-line');
8777
+ var lineCoordinates = this.lineCoordinates;
8778
+ var oldLineCoordinates = this.oldLineCoordinates;
8779
+ if (this.animations) {
8780
+ lineEl
8781
+ .attr('x1', function (_, index) { return oldLineCoordinates[index].v1.x; })
8782
+ .attr('y1', function (_, index) { return oldLineCoordinates[index].v1.y; })
8783
+ .attr('x2', function (_, index) { return oldLineCoordinates[index].v2.x; })
8784
+ .attr('y2', function (_, index) { return oldLineCoordinates[index].v2.y; })
8785
+ .transition()
8786
+ .ease(d3Ease.easeSinInOut)
8787
+ .duration(500)
8788
+ .attr('x1', function (_, index) { return lineCoordinates[index].v1.x; })
8789
+ .attr('y1', function (_, index) { return lineCoordinates[index].v1.y; })
8790
+ .attr('x2', function (_, index) { return lineCoordinates[index].v2.x; })
8791
+ .attr('y2', function (_, index) { return lineCoordinates[index].v2.y; });
8792
+ }
8793
+ else {
8794
+ lineEl
8795
+ .attr('x1', function (_, index) { return lineCoordinates[index].v1.x; })
8796
+ .attr('y1', function (_, index) { return lineCoordinates[index].v1.y; })
8797
+ .attr('x2', function (_, index) { return lineCoordinates[index].v2.x; })
8798
+ .attr('y2', function (_, index) { return lineCoordinates[index].v2.y; });
8799
+ }
8800
+ this.oldLineCoordinates = __spreadArray([], __read(lineCoordinates));
8801
+ };
8802
+ /**
8803
+ * See [D3 Selections](https://www.d3indepth.com/selections/)
8804
+ * @param d The joined data.
8805
+ * @param index The index of the element within the selection
8806
+ * @param node The node element (Line).
8807
+ */
8808
+ BoxComponent.prototype.lineTween = function (attr, d, index, node) {
8809
+ var nodeLineEl = node[index];
8810
+ return nodeLineEl[attr].baseVal.value;
8811
+ };
8812
+ // TODO: Refactor into another .ts file if https://github.com/swimlane/ngx-charts/pull/1179 gets merged.
8813
+ BoxComponent.prototype.pathTween = function (d1, precision) {
8814
+ return function () {
8815
+ // tslint:disable-next-line: no-this-assignment
8816
+ var path0 = this;
8817
+ var path1 = this.cloneNode();
8818
+ path1.setAttribute('d', d1);
8819
+ var n0 = path0 === null || path0 === void 0 ? void 0 : path0.getTotalLength();
8820
+ var n1 = path1 === null || path1 === void 0 ? void 0 : path1.getTotalLength();
8821
+ // Uniform sampling of distance based on specified precision.
8822
+ var distances = [0];
8823
+ var i = 0;
8824
+ var dt = precision / Math.max(n0, n1);
8825
+ while (i < 1) {
8826
+ distances.push(i);
8827
+ i += dt;
8828
+ }
8829
+ distances.push(1);
8830
+ // Compute point-interpolators at each distance.
8831
+ var points = distances.map(function (t) {
8832
+ var p0 = path0.getPointAtLength(t * n0);
8833
+ var p1 = path1.getPointAtLength(t * n1);
8834
+ return d3Interpolate.interpolate([p0.x, p0.y], [p1.x, p1.y]);
8835
+ });
8836
+ // 't': T is the fraction of time (between 0 and 1) since the transition began.
8837
+ return function (t) {
8838
+ return t < 1 ? 'M' + points.map(function (p) { return p(t); }).join('L') : d1;
8839
+ };
8840
+ };
8841
+ };
8842
+ BoxComponent.prototype.getStartingPath = function () {
8843
+ if (!this.animations) {
8844
+ return this.getPath();
8845
+ }
8846
+ var radius = this.roundEdges ? 1 : 0;
8847
+ var _a = this.lineCoordinates[2].v1, x = _a.x, y = _a.y;
8848
+ return roundedRect(x - this.width, y - 1, this.width, 2, radius, this.edges);
8849
+ };
8850
+ BoxComponent.prototype.getPath = function () {
8851
+ var radius = this.getRadius();
8852
+ var path = '';
8853
+ path = roundedRect(this.x, this.y, this.width, this.height, Math.min(this.height, radius), this.edges);
8854
+ return path;
8855
+ };
8856
+ BoxComponent.prototype.getStartingLineCoordinates = function () {
8857
+ if (!this.animations) {
8858
+ return __spreadArray([], __read(this.lineCoordinates));
8859
+ }
8860
+ var lineCoordinates = cloneDeep__default['default'](this.lineCoordinates);
8861
+ lineCoordinates[1].v1.y = lineCoordinates[1].v2.y = lineCoordinates[3].v1.y = lineCoordinates[3].v2.y = lineCoordinates[0].v1.y = lineCoordinates[0].v2.y =
8862
+ lineCoordinates[2].v1.y;
8863
+ return lineCoordinates;
8864
+ };
8865
+ BoxComponent.prototype.getRadius = function () {
8866
+ var radius = 0;
8867
+ if (this.roundEdges && this.height > 5 && this.width > 5) {
8868
+ radius = Math.floor(Math.min(5, this.height / 2, this.width / 2));
8869
+ }
8870
+ return radius;
8871
+ };
8872
+ BoxComponent.prototype.getGradient = function () {
8873
+ return [
8874
+ {
8875
+ offset: 0,
8876
+ color: this.fill,
8877
+ opacity: this.getStartOpacity()
8878
+ },
8879
+ {
8880
+ offset: 100,
8881
+ color: this.fill,
8882
+ opacity: 1
8883
+ }
8884
+ ];
8885
+ };
8886
+ BoxComponent.prototype.getStartOpacity = function () {
8887
+ if (this.roundEdges) {
8888
+ return 0.2;
8889
+ }
8890
+ else {
8891
+ return 0.5;
8892
+ }
8893
+ };
8894
+ Object.defineProperty(BoxComponent.prototype, "edges", {
8895
+ get: function () {
8896
+ var edges = [false, false, false, false];
8897
+ if (this.roundEdges) {
8898
+ edges = [true, true, true, true];
8899
+ }
8900
+ return edges;
8901
+ },
8902
+ enumerable: false,
8903
+ configurable: true
8904
+ });
8905
+ BoxComponent.prototype.onMouseEnter = function () {
8906
+ this.activate.emit(this.data);
8907
+ };
8908
+ BoxComponent.prototype.onMouseLeave = function () {
8909
+ this.deactivate.emit(this.data);
8910
+ };
8911
+ BoxComponent.prototype.checkToHideBar = function () {
8912
+ this.hideBar = this.noBarWhenZero && this.height === 0;
8913
+ };
8914
+ return BoxComponent;
8915
+ }());
8916
+ BoxComponent.decorators = [
8917
+ { type: core.Component, args: [{
8918
+ selector: 'g[ngx-charts-box]',
8919
+ template: "\n <svg:defs>\n <svg:g\n *ngIf=\"hasGradient\"\n ngx-charts-svg-linear-gradient\n [orientation]=\"BarOrientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n <svg:mask [attr.id]=\"maskLineId\">\n <svg:g>\n <rect height=\"100%\" width=\"100%\" fill=\"white\" fill-opacity=\"1\" />\n <path class=\"bar\" [attr.d]=\"boxPath\" fill=\"black\" fill-opacity=\"1\" />\n </svg:g>\n </svg:mask>\n </svg:defs>\n <svg:g>\n <svg:path\n class=\"bar\"\n role=\"img\"\n tabIndex=\"-1\"\n [class.active]=\"isActive\"\n [class.hidden]=\"hideBar\"\n [attr.d]=\"boxPath\"\n [attr.stroke]=\"strokeColor\"\n [attr.stroke-width]=\"boxStrokeWidth\"\n [attr.aria-label]=\"ariaLabel\"\n [attr.fill]=\"hasGradient ? gradientFill : fill\"\n (click)=\"select.emit(data)\"\n />\n <svg:line\n *ngFor=\"let line of lineCoordinates; let i = index\"\n class=\"bar-line\"\n [class.hidden]=\"hideBar\"\n [attr.x1]=\"line.v1.x\"\n [attr.y1]=\"line.v1.y\"\n [attr.x2]=\"line.v2.x\"\n [attr.y2]=\"line.v2.y\"\n [attr.stroke]=\"strokeColor\"\n [attr.stroke-width]=\"i === 2 ? medianLineWidth : whiskerStrokeWidth\"\n [attr.mask]=\"i ? undefined : maskLine\"\n fill=\"none\"\n />\n </svg:g>\n ",
8920
+ changeDetection: core.ChangeDetectionStrategy.OnPush
8921
+ },] }
8922
+ ];
8923
+ BoxComponent.ctorParameters = function () { return [
8924
+ { type: core.ElementRef },
8925
+ { type: core.ChangeDetectorRef }
8926
+ ]; };
8927
+ BoxComponent.propDecorators = {
8928
+ strokeColor: [{ type: core.Input }],
8929
+ strokeWidth: [{ type: core.Input }],
8930
+ fill: [{ type: core.Input }],
8931
+ data: [{ type: core.Input }],
8932
+ width: [{ type: core.Input }],
8933
+ height: [{ type: core.Input }],
8934
+ x: [{ type: core.Input }],
8935
+ y: [{ type: core.Input }],
8936
+ lineCoordinates: [{ type: core.Input }],
8937
+ roundEdges: [{ type: core.Input }],
8938
+ gradient: [{ type: core.Input }],
8939
+ gradientStops: [{ type: core.Input }],
8940
+ offset: [{ type: core.Input }],
8941
+ isActive: [{ type: core.Input }],
8942
+ animations: [{ type: core.Input }],
8943
+ ariaLabel: [{ type: core.Input }],
8944
+ noBarWhenZero: [{ type: core.Input }],
8945
+ select: [{ type: core.Output }],
8946
+ activate: [{ type: core.Output }],
8947
+ deactivate: [{ type: core.Output }],
8948
+ onMouseEnter: [{ type: core.HostListener, args: ['mouseenter',] }],
8949
+ onMouseLeave: [{ type: core.HostListener, args: ['mouseleave',] }]
8950
+ };
8951
+
8952
+ var BoxChartModule = /** @class */ (function () {
8953
+ function BoxChartModule() {
8954
+ }
8955
+ return BoxChartModule;
8956
+ }());
8957
+ BoxChartModule.decorators = [
8958
+ { type: core.NgModule, args: [{
8959
+ imports: [ChartCommonModule],
8960
+ declarations: [BoxChartComponent, BoxSeriesComponent, BoxComponent],
8961
+ exports: [BoxChartComponent, BoxSeriesComponent, BoxComponent]
8962
+ },] }
8963
+ ];
8964
+
8232
8965
  function getDomain(values, scaleType, autoScale, minVal, maxVal) {
8233
8966
  var domain = [];
8234
- if (scaleType === exports.ɵc.Linear) {
8967
+ if (scaleType === exports.ScaleType.Linear) {
8235
8968
  values = values.map(function (v) { return Number(v); });
8236
8969
  if (!autoScale) {
8237
8970
  values.push(0);
8238
8971
  }
8239
8972
  }
8240
- if (scaleType === exports.ɵc.Time || scaleType === exports.ɵc.Linear) {
8241
- var min = minVal ? minVal : Math.min.apply(Math, __spread(values));
8242
- var max = maxVal ? maxVal : Math.max.apply(Math, __spread(values));
8973
+ if (scaleType === exports.ScaleType.Time || scaleType === exports.ScaleType.Linear) {
8974
+ var min = minVal ? minVal : Math.min.apply(Math, __spreadArray([], __read(values)));
8975
+ var max = maxVal ? maxVal : Math.max.apply(Math, __spreadArray([], __read(values)));
8243
8976
  domain = [min, max];
8244
8977
  }
8245
8978
  else {
@@ -8248,26 +8981,29 @@
8248
8981
  return domain;
8249
8982
  }
8250
8983
  function getScale(domain, range, scaleType, roundDomains) {
8251
- var scale;
8252
- if (scaleType === exports.ɵc.Time) {
8253
- scale = d3Scale.scaleTime().range(range).domain(domain);
8254
- }
8255
- else if (scaleType === exports.ɵc.Linear) {
8256
- scale = d3Scale.scaleLinear().range(range).domain(domain);
8257
- if (roundDomains) {
8258
- scale = scale.nice();
8259
- }
8260
- }
8261
- else if (scaleType === exports.ɵc.Ordinal) {
8262
- scale = d3Scale.scalePoint().range([range[0], range[1]]).domain(domain);
8984
+ switch (scaleType) {
8985
+ case exports.ScaleType.Time:
8986
+ return d3Scale.scaleTime().range(range).domain(domain);
8987
+ case exports.ScaleType.Linear: {
8988
+ var scale = d3Scale.scaleLinear().range(range).domain(domain);
8989
+ if (roundDomains) {
8990
+ return scale.nice();
8991
+ }
8992
+ return scale;
8993
+ }
8994
+ case exports.ScaleType.Ordinal:
8995
+ return d3Scale.scalePoint()
8996
+ .range([range[0], range[1]])
8997
+ .domain(domain.map(function (r) { return r.toString(); }));
8998
+ default:
8999
+ return undefined;
8263
9000
  }
8264
- return scale;
8265
9001
  }
8266
9002
 
8267
9003
  var BubbleChartComponent = /** @class */ (function (_super) {
8268
9004
  __extends(BubbleChartComponent, _super);
8269
9005
  function BubbleChartComponent() {
8270
- var _this = _super.apply(this, __spread(arguments)) || this;
9006
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
8271
9007
  _this.showGridLines = true;
8272
9008
  _this.legend = false;
8273
9009
  _this.legendTitle = 'Legend';
@@ -8282,11 +9018,11 @@
8282
9018
  _this.roundDomains = false;
8283
9019
  _this.maxRadius = 10;
8284
9020
  _this.minRadius = 3;
8285
- _this.schemeType = exports.ɵc.Ordinal;
9021
+ _this.schemeType = exports.ScaleType.Ordinal;
8286
9022
  _this.tooltipDisabled = false;
8287
9023
  _this.activate = new core.EventEmitter();
8288
9024
  _this.deactivate = new core.EventEmitter();
8289
- _this.scaleType = exports.ɵc.Linear;
9025
+ _this.scaleType = exports.ScaleType.Linear;
8290
9026
  _this.margin = [10, 20, 10, 20];
8291
9027
  _this.bubblePadding = [0, 0, 0, 0];
8292
9028
  _this.xAxisHeight = 0;
@@ -8315,7 +9051,7 @@
8315
9051
  this.xDomain = this.getXDomain();
8316
9052
  this.yDomain = this.getYDomain();
8317
9053
  this.transform = "translate(" + this.dims.xOffset + "," + this.margin[0] + ")";
8318
- var colorDomain = this.schemeType === exports.ɵc.Ordinal ? this.seriesDomain : this.rDomain;
9054
+ var colorDomain = this.schemeType === exports.ScaleType.Ordinal ? this.seriesDomain : this.rDomain;
8319
9055
  this.colors = new ColorHelper(this.scheme, this.schemeType, colorDomain, this.customColors);
8320
9056
  this.data = this.results;
8321
9057
  this.minRadius = Math.max(this.minRadius, 1);
@@ -8351,8 +9087,8 @@
8351
9087
  for (var _e = (e_2 = void 0, __values(s.series)), _f = _e.next(); !_f.done; _f = _e.next()) {
8352
9088
  var d = _f.value;
8353
9089
  var r = this.rScale(d.r);
8354
- var cx = this.xScaleType === exports.ɵc.Linear ? this.xScale(Number(d.x)) : this.xScale(d.x);
8355
- var cy = this.yScaleType === exports.ɵc.Linear ? this.yScale(Number(d.y)) : this.yScale(d.y);
9090
+ var cx = this.xScaleType === exports.ScaleType.Linear ? this.xScale(Number(d.x)) : this.xScale(d.x);
9091
+ var cy = this.yScaleType === exports.ScaleType.Linear ? this.yScale(Number(d.y)) : this.yScale(d.y);
8356
9092
  xMin = Math.max(r - cx, xMin);
8357
9093
  yMin = Math.max(r - cy, yMin);
8358
9094
  yMax = Math.max(cy + r, yMax);
@@ -8409,7 +9145,7 @@
8409
9145
  position: this.legendPosition,
8410
9146
  title: undefined
8411
9147
  };
8412
- if (opts.scaleType === exports.ɵc.Ordinal) {
9148
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
8413
9149
  opts.domain = this.seriesDomain;
8414
9150
  opts.colors = this.colors;
8415
9151
  opts.title = this.legendTitle;
@@ -8536,7 +9272,7 @@
8536
9272
  if (idx > -1) {
8537
9273
  return;
8538
9274
  }
8539
- this.activeEntries = __spread([item], this.activeEntries);
9275
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
8540
9276
  this.activate.emit({ value: item, entries: this.activeEntries });
8541
9277
  };
8542
9278
  BubbleChartComponent.prototype.onDeactivate = function (item) {
@@ -8544,12 +9280,12 @@
8544
9280
  return d.name === item.name;
8545
9281
  });
8546
9282
  this.activeEntries.splice(idx, 1);
8547
- this.activeEntries = __spread(this.activeEntries);
9283
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
8548
9284
  this.deactivate.emit({ value: item, entries: this.activeEntries });
8549
9285
  };
8550
9286
  BubbleChartComponent.prototype.deactivateAll = function () {
8551
9287
  var e_9, _a;
8552
- this.activeEntries = __spread(this.activeEntries);
9288
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
8553
9289
  try {
8554
9290
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
8555
9291
  var entry = _c.value;
@@ -8566,7 +9302,7 @@
8566
9302
  this.activeEntries = [];
8567
9303
  };
8568
9304
  BubbleChartComponent.prototype.trackBy = function (index, item) {
8569
- return item.name;
9305
+ return "" + item.name;
8570
9306
  };
8571
9307
  return BubbleChartComponent;
8572
9308
  }(BaseChartComponent));
@@ -8588,7 +9324,7 @@
8588
9324
  ])
8589
9325
  ])
8590
9326
  ],
8591
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
9327
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
8592
9328
  },] }
8593
9329
  ];
8594
9330
  BubbleChartComponent.propDecorators = {
@@ -8633,6 +9369,8 @@
8633
9369
  this.select = new core.EventEmitter();
8634
9370
  this.activate = new core.EventEmitter();
8635
9371
  this.deactivate = new core.EventEmitter();
9372
+ this.placementTypes = exports.PlacementTypes;
9373
+ this.styleTypes = exports.StyleTypes;
8636
9374
  }
8637
9375
  BubbleSeriesComponent.prototype.ngOnChanges = function (changes) {
8638
9376
  this.update();
@@ -8651,9 +9389,9 @@
8651
9389
  var r = d.r;
8652
9390
  var radius = _this.rScale(r || 1);
8653
9391
  var tooltipLabel = formatLabel(d.name);
8654
- var cx = _this.xScaleType === exports.ɵc.Linear ? _this.xScale(Number(x)) : _this.xScale(x);
8655
- var cy = _this.yScaleType === exports.ɵc.Linear ? _this.yScale(Number(y)) : _this.yScale(y);
8656
- var color = _this.colors.scaleType === exports.ɵc.Linear ? _this.colors.getColor(r) : _this.colors.getColor(seriesName);
9392
+ var cx = _this.xScaleType === exports.ScaleType.Linear ? _this.xScale(Number(x)) : _this.xScale(x);
9393
+ var cy = _this.yScaleType === exports.ScaleType.Linear ? _this.yScale(Number(y)) : _this.yScale(y);
9394
+ var color = _this.colors.scaleType === exports.ScaleType.Linear ? _this.colors.getColor(r) : _this.colors.getColor(seriesName);
8657
9395
  var isActive = !_this.activeEntries.length ? true : _this.isActive({ name: seriesName });
8658
9396
  var opacity = isActive ? 1 : 0.3;
8659
9397
  var data = Object.assign({}, d, {
@@ -8733,7 +9471,7 @@
8733
9471
  BubbleSeriesComponent.decorators = [
8734
9472
  { type: core.Component, args: [{
8735
9473
  selector: 'g[ngx-charts-bubble-series]',
8736
- template: "\n <svg:g *ngFor=\"let circle of circles; trackBy: trackBy\">\n <svg:g [attr.transform]=\"circle.transform\">\n <svg:g\n ngx-charts-circle\n [@animationState]=\"'active'\"\n class=\"circle\"\n [cx]=\"0\"\n [cy]=\"0\"\n [r]=\"circle.radius\"\n [fill]=\"circle.color\"\n [style.opacity]=\"circle.opacity\"\n [class.active]=\"circle.isActive\"\n [pointerEvents]=\"'all'\"\n [data]=\"circle.value\"\n [classNames]=\"circle.classNames\"\n (select)=\"onClick(circle.data)\"\n (activate)=\"activateCircle(circle)\"\n (deactivate)=\"deactivateCircle(circle)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n />\n </svg:g>\n </svg:g>\n ",
9474
+ template: "\n <svg:g *ngFor=\"let circle of circles; trackBy: trackBy\">\n <svg:g [attr.transform]=\"circle.transform\">\n <svg:g\n ngx-charts-circle\n [@animationState]=\"'active'\"\n class=\"circle\"\n [cx]=\"0\"\n [cy]=\"0\"\n [r]=\"circle.radius\"\n [fill]=\"circle.color\"\n [style.opacity]=\"circle.opacity\"\n [class.active]=\"circle.isActive\"\n [pointerEvents]=\"'all'\"\n [data]=\"circle.value\"\n [classNames]=\"circle.classNames\"\n (select)=\"onClick(circle.data)\"\n (activate)=\"activateCircle(circle)\"\n (deactivate)=\"deactivateCircle(circle)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n />\n </svg:g>\n </svg:g>\n ",
8737
9475
  changeDetection: core.ChangeDetectionStrategy.OnPush,
8738
9476
  animations: [
8739
9477
  animations.trigger('animationState', [
@@ -8787,6 +9525,7 @@
8787
9525
  this.select = new core.EventEmitter();
8788
9526
  this.activate = new core.EventEmitter();
8789
9527
  this.deactivate = new core.EventEmitter();
9528
+ this.barOrientation = exports.BarOrientation;
8790
9529
  this.element = element.nativeElement;
8791
9530
  }
8792
9531
  HeatMapCellComponent.prototype.ngOnChanges = function (changes) {
@@ -8836,7 +9575,7 @@
8836
9575
  HeatMapCellComponent.decorators = [
8837
9576
  { type: core.Component, args: [{
8838
9577
  selector: 'g[ngx-charts-heat-map-cell]',
8839
- template: "\n <svg:g [attr.transform]=\"transform\" class=\"cell\">\n <defs *ngIf=\"gradient\">\n <svg:g ngx-charts-svg-linear-gradient orientation=\"vertical\" [name]=\"gradientId\" [stops]=\"gradientStops\" />\n </defs>\n <svg:rect\n [attr.fill]=\"gradient ? gradientUrl : fill\"\n rx=\"3\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n class=\"cell\"\n style=\"cursor: pointer\"\n (click)=\"onClick()\"\n />\n </svg:g>\n ",
9578
+ template: "\n <svg:g [attr.transform]=\"transform\" class=\"cell\">\n <defs *ngIf=\"gradient\">\n <svg:g\n ngx-charts-svg-linear-gradient\n [orientation]=\"barOrientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:rect\n [attr.fill]=\"gradient ? gradientUrl : fill\"\n rx=\"3\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n class=\"cell\"\n (click)=\"onClick()\"\n />\n </svg:g>\n ",
8840
9579
  changeDetection: core.ChangeDetectionStrategy.OnPush
8841
9580
  },] }
8842
9581
  ];
@@ -8866,6 +9605,8 @@
8866
9605
  this.select = new core.EventEmitter();
8867
9606
  this.activate = new core.EventEmitter();
8868
9607
  this.deactivate = new core.EventEmitter();
9608
+ this.placementTypes = exports.PlacementTypes;
9609
+ this.styleTypes = exports.StyleTypes;
8869
9610
  }
8870
9611
  HeatCellSeriesComponent.prototype.ngOnInit = function () {
8871
9612
  if (!this.tooltipText) {
@@ -8916,7 +9657,7 @@
8916
9657
  HeatCellSeriesComponent.decorators = [
8917
9658
  { type: core.Component, args: [{
8918
9659
  selector: 'g[ngx-charts-heat-map-cell-series]',
8919
- template: "\n <svg:g\n ngx-charts-heat-map-cell\n *ngFor=\"let c of cells; trackBy: trackBy\"\n [x]=\"c.x\"\n [y]=\"c.y\"\n [width]=\"c.width\"\n [height]=\"c.height\"\n [fill]=\"c.fill\"\n [data]=\"c.data\"\n (select)=\"onClick(c.cell)\"\n (activate)=\"activate.emit(c.cell)\"\n (deactivate)=\"deactivate.emit(c.cell)\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(c)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"{ series: c.series, name: c.label, value: c.data }\"\n ></svg:g>\n ",
9660
+ template: "\n <svg:g\n ngx-charts-heat-map-cell\n *ngFor=\"let c of cells; trackBy: trackBy\"\n [x]=\"c.x\"\n [y]=\"c.y\"\n [width]=\"c.width\"\n [height]=\"c.height\"\n [fill]=\"c.fill\"\n [data]=\"c.data\"\n (select)=\"onClick(c.cell)\"\n (activate)=\"activate.emit(c.cell)\"\n (deactivate)=\"deactivate.emit(c.cell)\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(c)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"{ series: c.series, name: c.label, value: c.data }\"\n ></svg:g>\n ",
8920
9661
  changeDetection: core.ChangeDetectionStrategy.OnPush
8921
9662
  },] }
8922
9663
  ];
@@ -8938,7 +9679,7 @@
8938
9679
  var HeatMapComponent = /** @class */ (function (_super) {
8939
9680
  __extends(HeatMapComponent, _super);
8940
9681
  function HeatMapComponent() {
8941
- var _this = _super.apply(this, __spread(arguments)) || this;
9682
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
8942
9683
  _this.legendTitle = 'Legend';
8943
9684
  _this.legendPosition = exports.LegendPosition.Right;
8944
9685
  _this.innerPadding = 8;
@@ -8954,7 +9695,7 @@
8954
9695
  _this.margin = [10, 20, 10, 20];
8955
9696
  _this.xAxisHeight = 0;
8956
9697
  _this.yAxisWidth = 0;
8957
- _this.scaleType = exports.ɵc.Linear;
9698
+ _this.scaleType = exports.ScaleType.Linear;
8958
9699
  return _this;
8959
9700
  }
8960
9701
  HeatMapComponent.prototype.update = function () {
@@ -8978,14 +9719,14 @@
8978
9719
  legendType: this.scaleType,
8979
9720
  legendPosition: this.legendPosition
8980
9721
  });
8981
- if (this.scaleType === exports.ɵc.Linear) {
9722
+ if (this.scaleType === exports.ScaleType.Linear) {
8982
9723
  var min = this.min;
8983
9724
  var max = this.max;
8984
9725
  if (!this.min) {
8985
- min = Math.min.apply(Math, __spread([0], this.valueDomain));
9726
+ min = Math.min.apply(Math, __spreadArray([0], __read(this.valueDomain)));
8986
9727
  }
8987
9728
  if (!this.max) {
8988
- max = Math.max.apply(Math, __spread(this.valueDomain));
9729
+ max = Math.max.apply(Math, __spreadArray([], __read(this.valueDomain)));
8989
9730
  }
8990
9731
  this.valueDomain = [min, max];
8991
9732
  }
@@ -9146,8 +9887,8 @@
9146
9887
  return {
9147
9888
  scaleType: this.scaleType,
9148
9889
  domain: this.valueDomain,
9149
- colors: this.scaleType === exports.ɵc.Ordinal ? this.colors : this.colors.scale,
9150
- title: this.scaleType === exports.ɵc.Ordinal ? this.legendTitle : undefined,
9890
+ colors: this.scaleType === exports.ScaleType.Ordinal ? this.colors : this.colors.scale,
9891
+ title: this.scaleType === exports.ScaleType.Ordinal ? this.legendTitle : undefined,
9151
9892
  position: this.legendPosition
9152
9893
  };
9153
9894
  };
@@ -9178,7 +9919,7 @@
9178
9919
  return i.name === item.name && i.series === item.series;
9179
9920
  }
9180
9921
  });
9181
- this.activeEntries = __spread(items);
9922
+ this.activeEntries = __spreadArray([], __read(items));
9182
9923
  this.activate.emit({ value: item, entries: this.activeEntries });
9183
9924
  };
9184
9925
  HeatMapComponent.prototype.onDeactivate = function (event, group, fromLegend) {
@@ -9205,7 +9946,7 @@
9205
9946
  template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [animations]=\"animations\"\n [legendOptions]=\"legendOptions\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"heat-map chart\">\n <svg:g\n ngx-charts-x-axis\n *ngIf=\"xAxis\"\n [xScale]=\"xScale\"\n [dims]=\"dims\"\n [showLabel]=\"showXAxisLabel\"\n [labelText]=\"xAxisLabel\"\n [trimTicks]=\"trimXAxisTicks\"\n [rotateTicks]=\"rotateXAxisTicks\"\n [maxTickLength]=\"maxXAxisTickLength\"\n [tickFormatting]=\"xAxisTickFormatting\"\n [ticks]=\"xAxisTicks\"\n (dimensionsChanged)=\"updateXAxisHeight($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-y-axis\n *ngIf=\"yAxis\"\n [yScale]=\"yScale\"\n [dims]=\"dims\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n [ticks]=\"yAxisTicks\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:rect\n *ngFor=\"let rect of rects\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.rx]=\"rect.rx\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"rect.fill\"\n />\n <svg:g\n ngx-charts-heat-map-cell-series\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"results\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipText]=\"tooltipText\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event, undefined)\"\n (deactivate)=\"onDeactivate($event, undefined)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
9206
9947
  changeDetection: core.ChangeDetectionStrategy.OnPush,
9207
9948
  encapsulation: core.ViewEncapsulation.None,
9208
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
9949
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
9209
9950
  },] }
9210
9951
  ];
9211
9952
  HeatMapComponent.propDecorators = {
@@ -9314,7 +10055,7 @@
9314
10055
  var LineChartComponent = /** @class */ (function (_super) {
9315
10056
  __extends(LineChartComponent, _super);
9316
10057
  function LineChartComponent() {
9317
- var _this = _super.apply(this, __spread(arguments)) || this;
10058
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
9318
10059
  _this.legendTitle = 'Legend';
9319
10060
  _this.legendPosition = exports.LegendPosition.Right;
9320
10061
  _this.showGridLines = true;
@@ -9385,18 +10126,18 @@
9385
10126
  var values = getUniqueXDomainValues(this.results);
9386
10127
  this.scaleType = getScaleType(values);
9387
10128
  var domain = [];
9388
- if (this.scaleType === exports.ɵc.Linear) {
10129
+ if (this.scaleType === exports.ScaleType.Linear) {
9389
10130
  values = values.map(function (v) { return Number(v); });
9390
10131
  }
9391
10132
  var min;
9392
10133
  var max;
9393
- if (this.scaleType === exports.ɵc.Time || this.scaleType === exports.ɵc.Linear) {
9394
- min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spread(values));
9395
- max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spread(values));
10134
+ if (this.scaleType === exports.ScaleType.Time || this.scaleType === exports.ScaleType.Linear) {
10135
+ min = this.xScaleMin ? this.xScaleMin : Math.min.apply(Math, __spreadArray([], __read(values)));
10136
+ max = this.xScaleMax ? this.xScaleMax : Math.max.apply(Math, __spreadArray([], __read(values)));
9396
10137
  }
9397
- if (this.scaleType === exports.ɵc.Time) {
10138
+ if (this.scaleType === exports.ScaleType.Time) {
9398
10139
  domain = [new Date(min), new Date(max)];
9399
- this.xSet = __spread(values).sort(function (a, b) {
10140
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) {
9400
10141
  var aDate = a.getTime();
9401
10142
  var bDate = b.getTime();
9402
10143
  if (aDate > bDate)
@@ -9406,10 +10147,10 @@
9406
10147
  return 0;
9407
10148
  });
9408
10149
  }
9409
- else if (this.scaleType === exports.ɵc.Linear) {
10150
+ else if (this.scaleType === exports.ScaleType.Linear) {
9410
10151
  domain = [min, max];
9411
10152
  // Use compare function to sort numbers numerically
9412
- this.xSet = __spread(values).sort(function (a, b) { return a - b; });
10153
+ this.xSet = __spreadArray([], __read(values)).sort(function (a, b) { return a - b; });
9413
10154
  }
9414
10155
  else {
9415
10156
  domain = values;
@@ -9459,12 +10200,12 @@
9459
10200
  }
9460
10201
  finally { if (e_1) throw e_1.error; }
9461
10202
  }
9462
- var values = __spread(domain);
10203
+ var values = __spreadArray([], __read(domain));
9463
10204
  if (!this.autoScale) {
9464
10205
  values.push(0);
9465
10206
  }
9466
- var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spread(values));
9467
- var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spread(values));
10207
+ var min = this.yScaleMin ? this.yScaleMin : Math.min.apply(Math, __spreadArray([], __read(values)));
10208
+ var max = this.yScaleMax ? this.yScaleMax : Math.max.apply(Math, __spreadArray([], __read(values)));
9468
10209
  return [min, max];
9469
10210
  };
9470
10211
  LineChartComponent.prototype.getSeriesDomain = function () {
@@ -9472,16 +10213,16 @@
9472
10213
  };
9473
10214
  LineChartComponent.prototype.getXScale = function (domain, width) {
9474
10215
  var scale;
9475
- if (this.scaleType === exports.ɵc.Time) {
10216
+ if (this.scaleType === exports.ScaleType.Time) {
9476
10217
  scale = d3Scale.scaleTime().range([0, width]).domain(domain);
9477
10218
  }
9478
- else if (this.scaleType === exports.ɵc.Linear) {
10219
+ else if (this.scaleType === exports.ScaleType.Linear) {
9479
10220
  scale = d3Scale.scaleLinear().range([0, width]).domain(domain);
9480
10221
  if (this.roundDomains) {
9481
10222
  scale = scale.nice();
9482
10223
  }
9483
10224
  }
9484
- else if (this.scaleType === exports.ɵc.Ordinal) {
10225
+ else if (this.scaleType === exports.ScaleType.Ordinal) {
9485
10226
  scale = d3Scale.scalePoint().range([0, width]).padding(0.1).domain(domain);
9486
10227
  }
9487
10228
  return scale;
@@ -9507,11 +10248,11 @@
9507
10248
  this.select.emit(data);
9508
10249
  };
9509
10250
  LineChartComponent.prototype.trackBy = function (index, item) {
9510
- return item.name;
10251
+ return "" + item.name;
9511
10252
  };
9512
10253
  LineChartComponent.prototype.setColors = function () {
9513
10254
  var domain;
9514
- if (this.schemeType === exports.ɵc.Ordinal) {
10255
+ if (this.schemeType === exports.ScaleType.Ordinal) {
9515
10256
  domain = this.seriesDomain;
9516
10257
  }
9517
10258
  else {
@@ -9527,7 +10268,7 @@
9527
10268
  title: undefined,
9528
10269
  position: this.legendPosition
9529
10270
  };
9530
- if (opts.scaleType === exports.ɵc.Ordinal) {
10271
+ if (opts.scaleType === exports.ScaleType.Ordinal) {
9531
10272
  opts.domain = this.seriesDomain;
9532
10273
  opts.colors = this.colors;
9533
10274
  opts.title = this.legendTitle;
@@ -9564,12 +10305,12 @@
9564
10305
  return d.name === item.name && d.value === item.value;
9565
10306
  });
9566
10307
  this.activeEntries.splice(idx, 1);
9567
- this.activeEntries = __spread(this.activeEntries);
10308
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
9568
10309
  this.deactivate.emit({ value: item, entries: this.activeEntries });
9569
10310
  };
9570
10311
  LineChartComponent.prototype.deactivateAll = function () {
9571
10312
  var e_3, _a;
9572
- this.activeEntries = __spread(this.activeEntries);
10313
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
9573
10314
  try {
9574
10315
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
9575
10316
  var entry = _c.value;
@@ -9605,7 +10346,7 @@
9605
10346
  ])
9606
10347
  ])
9607
10348
  ],
9608
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}"]
10349
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n"]
9609
10350
  },] }
9610
10351
  ];
9611
10352
  LineChartComponent.propDecorators = {
@@ -9654,6 +10395,7 @@
9654
10395
  var LineSeriesComponent = /** @class */ (function () {
9655
10396
  function LineSeriesComponent() {
9656
10397
  this.animations = true;
10398
+ this.barOrientation = exports.BarOrientation;
9657
10399
  }
9658
10400
  LineSeriesComponent.prototype.ngOnChanges = function (changes) {
9659
10401
  this.update();
@@ -9672,8 +10414,8 @@
9672
10414
  if (this.hasGradient) {
9673
10415
  this.stroke = this.gradientUrl;
9674
10416
  var values = this.data.series.map(function (d) { return d.value; });
9675
- var max = Math.max.apply(Math, __spread(values));
9676
- var min = Math.min.apply(Math, __spread(values));
10417
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
10418
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
9677
10419
  if (max === min) {
9678
10420
  this.stroke = this.colors.getColor(max);
9679
10421
  }
@@ -9688,10 +10430,10 @@
9688
10430
  .x(function (d) {
9689
10431
  var label = d.name;
9690
10432
  var value;
9691
- if (_this.scaleType === exports.ɵc.Time) {
10433
+ if (_this.scaleType === exports.ScaleType.Time) {
9692
10434
  value = _this.xScale(label);
9693
10435
  }
9694
- else if (_this.scaleType === exports.ɵc.Linear) {
10436
+ else if (_this.scaleType === exports.ScaleType.Linear) {
9695
10437
  value = _this.xScale(Number(label));
9696
10438
  }
9697
10439
  else {
@@ -9708,10 +10450,10 @@
9708
10450
  .x(function (d) {
9709
10451
  var label = d.name;
9710
10452
  var value;
9711
- if (_this.scaleType === exports.ɵc.Time) {
10453
+ if (_this.scaleType === exports.ScaleType.Time) {
9712
10454
  value = _this.xScale(label);
9713
10455
  }
9714
- else if (_this.scaleType === exports.ɵc.Linear) {
10456
+ else if (_this.scaleType === exports.ScaleType.Linear) {
9715
10457
  value = _this.xScale(Number(label));
9716
10458
  }
9717
10459
  else {
@@ -9736,10 +10478,10 @@
9736
10478
  .curve(this.curve);
9737
10479
  };
9738
10480
  LineSeriesComponent.prototype.sortData = function (data) {
9739
- if (this.scaleType === exports.ɵc.Linear) {
10481
+ if (this.scaleType === exports.ScaleType.Linear) {
9740
10482
  data = sortLinear(data, 'name');
9741
10483
  }
9742
- else if (this.scaleType === exports.ɵc.Time) {
10484
+ else if (this.scaleType === exports.ScaleType.Time) {
9743
10485
  data = sortByTime(data, 'name');
9744
10486
  }
9745
10487
  else {
@@ -9748,13 +10490,13 @@
9748
10490
  return data;
9749
10491
  };
9750
10492
  LineSeriesComponent.prototype.updateGradients = function () {
9751
- if (this.colors.scaleType === exports.ɵc.Linear) {
10493
+ if (this.colors.scaleType === exports.ScaleType.Linear) {
9752
10494
  this.hasGradient = true;
9753
10495
  this.gradientId = 'grad' + id().toString();
9754
10496
  this.gradientUrl = "url(#" + this.gradientId + ")";
9755
10497
  var values = this.data.series.map(function (d) { return d.value; });
9756
- var max = Math.max.apply(Math, __spread(values));
9757
- var min = Math.min.apply(Math, __spread(values));
10498
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
10499
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
9758
10500
  this.gradientStops = this.colors.getLinearGradientStops(max, min);
9759
10501
  this.areaGradientStops = this.colors.getLinearGradientStops(max);
9760
10502
  }
@@ -9785,7 +10527,7 @@
9785
10527
  LineSeriesComponent.decorators = [
9786
10528
  { type: core.Component, args: [{
9787
10529
  selector: 'g[ngx-charts-line-series]',
9788
- template: "\n <svg:g>\n <defs>\n <svg:g\n ngx-charts-svg-linear-gradient\n *ngIf=\"hasGradient\"\n orientation=\"vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:g\n ngx-charts-area\n class=\"line-highlight\"\n [data]=\"data\"\n [path]=\"areaPath\"\n [fill]=\"hasGradient ? gradientUrl : colors.getColor(data.name)\"\n [opacity]=\"0.25\"\n [startOpacity]=\"0\"\n [gradient]=\"true\"\n [stops]=\"areaGradientStops\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n [animations]=\"animations\"\n />\n <svg:g\n ngx-charts-line\n class=\"line-series\"\n [data]=\"data\"\n [path]=\"path\"\n [stroke]=\"stroke\"\n [animations]=\"animations\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n />\n <svg:g\n ngx-charts-area\n *ngIf=\"hasRange\"\n class=\"line-series-range\"\n [data]=\"data\"\n [path]=\"outerPath\"\n [fill]=\"hasGradient ? gradientUrl : colors.getColor(data.name)\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n [opacity]=\"rangeFillOpacity\"\n [animations]=\"animations\"\n />\n </svg:g>\n ",
10530
+ template: "\n <svg:g>\n <defs>\n <svg:g\n ngx-charts-svg-linear-gradient\n *ngIf=\"hasGradient\"\n [orientation]=\"barOrientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:g\n ngx-charts-area\n class=\"line-highlight\"\n [data]=\"data\"\n [path]=\"areaPath\"\n [fill]=\"hasGradient ? gradientUrl : colors.getColor(data.name)\"\n [opacity]=\"0.25\"\n [startOpacity]=\"0\"\n [gradient]=\"true\"\n [stops]=\"areaGradientStops\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n [animations]=\"animations\"\n />\n <svg:g\n ngx-charts-line\n class=\"line-series\"\n [data]=\"data\"\n [path]=\"path\"\n [stroke]=\"stroke\"\n [animations]=\"animations\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n />\n <svg:g\n ngx-charts-area\n *ngIf=\"hasRange\"\n class=\"line-series-range\"\n [data]=\"data\"\n [path]=\"outerPath\"\n [fill]=\"hasGradient ? gradientUrl : colors.getColor(data.name)\"\n [class.active]=\"isActive(data)\"\n [class.inactive]=\"isInactive(data)\"\n [opacity]=\"rangeFillOpacity\"\n [animations]=\"animations\"\n />\n </svg:g>\n ",
9789
10531
  changeDetection: core.ChangeDetectionStrategy.OnPush
9790
10532
  },] }
9791
10533
  ];
@@ -9819,7 +10561,7 @@
9819
10561
  var PolarChartComponent = /** @class */ (function (_super) {
9820
10562
  __extends(PolarChartComponent, _super);
9821
10563
  function PolarChartComponent() {
9822
- var _this = _super.apply(this, __spread(arguments)) || this;
10564
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
9823
10565
  _this.legendTitle = 'Legend';
9824
10566
  _this.legendPosition = exports.LegendPosition.Right;
9825
10567
  _this.showGridLines = true;
@@ -9841,6 +10583,7 @@
9841
10583
  _this.margin = [10, 20, 10, 20];
9842
10584
  _this.xAxisHeight = 0;
9843
10585
  _this.yAxisWidth = 0;
10586
+ _this.orientation = exports.Orientation;
9844
10587
  return _this;
9845
10588
  }
9846
10589
  PolarChartComponent.prototype.update = function () {
@@ -9975,15 +10718,15 @@
9975
10718
  };
9976
10719
  PolarChartComponent.prototype.getXDomain = function (values) {
9977
10720
  if (values === void 0) { values = this.getXValues(); }
9978
- if (this.scaleType === exports.ɵc.Time) {
9979
- var min = Math.min.apply(Math, __spread(values));
9980
- var max = Math.max.apply(Math, __spread(values));
10721
+ if (this.scaleType === exports.ScaleType.Time) {
10722
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
10723
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
9981
10724
  return [min, max];
9982
10725
  }
9983
- else if (this.scaleType === exports.ɵc.Linear) {
10726
+ else if (this.scaleType === exports.ScaleType.Linear) {
9984
10727
  values = values.map(function (v) { return Number(v); });
9985
- var min = Math.min.apply(Math, __spread(values));
9986
- var max = Math.max.apply(Math, __spread(values));
10728
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
10729
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
9987
10730
  return [min, max];
9988
10731
  }
9989
10732
  return values;
@@ -10032,8 +10775,8 @@
10032
10775
  };
10033
10776
  PolarChartComponent.prototype.getYDomain = function (domain) {
10034
10777
  if (domain === void 0) { domain = this.getYValues(); }
10035
- var min = Math.min.apply(Math, __spread(domain));
10036
- var max = Math.max.apply(Math, __spread([this.yAxisMinScale], domain));
10778
+ var min = Math.min.apply(Math, __spreadArray([], __read(domain)));
10779
+ var max = Math.max.apply(Math, __spreadArray([this.yAxisMinScale], __read(domain)));
10037
10780
  min = Math.max(0, min);
10038
10781
  if (!this.autoScale) {
10039
10782
  min = Math.min(0, min);
@@ -10045,9 +10788,9 @@
10045
10788
  };
10046
10789
  PolarChartComponent.prototype.getXScale = function (domain, width) {
10047
10790
  switch (this.scaleType) {
10048
- case exports.ɵc.Time:
10791
+ case exports.ScaleType.Time:
10049
10792
  return d3Scale.scaleTime().range([0, width]).domain(domain);
10050
- case exports.ɵc.Linear:
10793
+ case exports.ScaleType.Linear:
10051
10794
  var scale = d3Scale.scaleLinear().range([0, width]).domain(domain);
10052
10795
  return this.roundDomains ? scale.nice() : scale;
10053
10796
  default:
@@ -10068,11 +10811,11 @@
10068
10811
  this.select.emit(data);
10069
10812
  };
10070
10813
  PolarChartComponent.prototype.setColors = function () {
10071
- var domain = this.schemeType === exports.ɵc.Ordinal ? this.seriesDomain : this.yDomain.reverse();
10814
+ var domain = this.schemeType === exports.ScaleType.Ordinal ? this.seriesDomain : this.yDomain.reverse();
10072
10815
  this.colors = new ColorHelper(this.scheme, this.schemeType, domain, this.customColors);
10073
10816
  };
10074
10817
  PolarChartComponent.prototype.getLegendOptions = function () {
10075
- if (this.schemeType === exports.ɵc.Ordinal) {
10818
+ if (this.schemeType === exports.ScaleType.Ordinal) {
10076
10819
  return {
10077
10820
  scaleType: this.schemeType,
10078
10821
  colors: this.colors,
@@ -10106,7 +10849,7 @@
10106
10849
  if (idx > -1) {
10107
10850
  return;
10108
10851
  }
10109
- this.activeEntries = this.showSeriesOnHover ? __spread([item], this.activeEntries) : this.activeEntries;
10852
+ this.activeEntries = this.showSeriesOnHover ? __spreadArray([item], __read(this.activeEntries)) : this.activeEntries;
10110
10853
  this.activate.emit({ value: item, entries: this.activeEntries });
10111
10854
  };
10112
10855
  PolarChartComponent.prototype.onDeactivate = function (item) {
@@ -10114,12 +10857,12 @@
10114
10857
  return d.name === item.name && d.value === item.value;
10115
10858
  });
10116
10859
  this.activeEntries.splice(idx, 1);
10117
- this.activeEntries = __spread(this.activeEntries);
10860
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
10118
10861
  this.deactivate.emit({ value: item, entries: this.activeEntries });
10119
10862
  };
10120
10863
  PolarChartComponent.prototype.deactivateAll = function () {
10121
10864
  var e_5, _a;
10122
- this.activeEntries = __spread(this.activeEntries);
10865
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
10123
10866
  try {
10124
10867
  for (var _b = __values(this.activeEntries), _c = _b.next(); !_c.done; _c = _b.next()) {
10125
10868
  var entry = _c.value;
@@ -10136,14 +10879,14 @@
10136
10879
  this.activeEntries = [];
10137
10880
  };
10138
10881
  PolarChartComponent.prototype.trackBy = function (index, item) {
10139
- return item.name;
10882
+ return "" + item.name;
10140
10883
  };
10141
10884
  return PolarChartComponent;
10142
10885
  }(BaseChartComponent));
10143
10886
  PolarChartComponent.decorators = [
10144
10887
  { type: core.Component, args: [{
10145
10888
  selector: 'ngx-charts-polar-chart',
10146
- template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:g class=\"polar-chart chart\" [attr.transform]=\"transform\">\n <svg:g [attr.transform]=\"transformPlot\">\n <svg:circle class=\"polar-chart-background\" cx=\"0\" cy=\"0\" [attr.r]=\"this.outerRadius\" />\n <svg:g *ngIf=\"showGridLines\">\n <svg:circle\n *ngFor=\"let r of radiusTicks\"\n class=\"gridline-path radial-gridline-path\"\n cx=\"0\"\n cy=\"0\"\n [attr.r]=\"r\"\n />\n </svg:g>\n <svg:g *ngIf=\"xAxis\">\n <svg:g\n ngx-charts-pie-label\n *ngFor=\"let tick of thetaTicks\"\n [data]=\"tick\"\n [radius]=\"outerRadius\"\n [label]=\"tick.label\"\n [max]=\"outerRadius\"\n [value]=\"showGridLines ? 1 : outerRadius\"\n [explodeSlices]=\"true\"\n [animations]=\"animations\"\n [labelTrim]=\"labelTrim\"\n [labelTrimSize]=\"labelTrimSize\"\n ></svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-y-axis\n [attr.transform]=\"transformYAxis\"\n *ngIf=\"yAxis\"\n [yScale]=\"yAxisScale\"\n [dims]=\"yAxisDims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-axis-label\n *ngIf=\"xAxis && showXAxisLabel\"\n [label]=\"xAxisLabel\"\n [offset]=\"labelOffset\"\n [orient]=\"'bottom'\"\n [height]=\"dims.height\"\n [width]=\"dims.width\"\n ></svg:g>\n <svg:g [attr.transform]=\"transformPlot\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\" [@animationState]=\"'active'\">\n <svg:g\n ngx-charts-polar-series\n [gradient]=\"gradient\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [activeEntries]=\"activeEntries\"\n [scaleType]=\"scaleType\"\n [curve]=\"curve\"\n [rangeFillOpacity]=\"rangeFillOpacity\"\n [animations]=\"animations\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
10889
+ template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:g class=\"polar-chart chart\" [attr.transform]=\"transform\">\n <svg:g [attr.transform]=\"transformPlot\">\n <svg:circle class=\"polar-chart-background\" cx=\"0\" cy=\"0\" [attr.r]=\"this.outerRadius\" />\n <svg:g *ngIf=\"showGridLines\">\n <svg:circle\n *ngFor=\"let r of radiusTicks\"\n class=\"gridline-path radial-gridline-path\"\n cx=\"0\"\n cy=\"0\"\n [attr.r]=\"r\"\n />\n </svg:g>\n <svg:g *ngIf=\"xAxis\">\n <svg:g\n ngx-charts-pie-label\n *ngFor=\"let tick of thetaTicks\"\n [data]=\"tick\"\n [radius]=\"outerRadius\"\n [label]=\"tick.label\"\n [max]=\"outerRadius\"\n [value]=\"showGridLines ? 1 : outerRadius\"\n [explodeSlices]=\"true\"\n [animations]=\"animations\"\n [labelTrim]=\"labelTrim\"\n [labelTrimSize]=\"labelTrimSize\"\n ></svg:g>\n </svg:g>\n </svg:g>\n <svg:g\n ngx-charts-y-axis\n [attr.transform]=\"transformYAxis\"\n *ngIf=\"yAxis\"\n [yScale]=\"yAxisScale\"\n [dims]=\"yAxisDims\"\n [showGridLines]=\"showGridLines\"\n [showLabel]=\"showYAxisLabel\"\n [labelText]=\"yAxisLabel\"\n [trimTicks]=\"trimYAxisTicks\"\n [maxTickLength]=\"maxYAxisTickLength\"\n [tickFormatting]=\"yAxisTickFormatting\"\n (dimensionsChanged)=\"updateYAxisWidth($event)\"\n ></svg:g>\n <svg:g\n ngx-charts-axis-label\n *ngIf=\"xAxis && showXAxisLabel\"\n [label]=\"xAxisLabel\"\n [offset]=\"labelOffset\"\n [orient]=\"orientation.Bottom\"\n [height]=\"dims.height\"\n [width]=\"dims.width\"\n ></svg:g>\n <svg:g [attr.transform]=\"transformPlot\">\n <svg:g *ngFor=\"let series of results; trackBy: trackBy\" [@animationState]=\"'active'\">\n <svg:g\n ngx-charts-polar-series\n [gradient]=\"gradient\"\n [xScale]=\"xScale\"\n [yScale]=\"yScale\"\n [colors]=\"colors\"\n [data]=\"series\"\n [activeEntries]=\"activeEntries\"\n [scaleType]=\"scaleType\"\n [curve]=\"curve\"\n [rangeFillOpacity]=\"rangeFillOpacity\"\n [animations]=\"animations\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
10147
10890
  encapsulation: core.ViewEncapsulation.None,
10148
10891
  changeDetection: core.ChangeDetectionStrategy.OnPush,
10149
10892
  animations: [
@@ -10158,7 +10901,7 @@
10158
10901
  ])
10159
10902
  ])
10160
10903
  ],
10161
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".pie-label{font-size:11px}.pie-label.animation{-webkit-animation:fadeIn .75s ease-in;animation:fadeIn .75s ease-in}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{-webkit-animation:drawOut 3s linear;animation:drawOut 3s linear;transition:d .75s}@-webkit-keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}", ".polar-chart .polar-chart-background{fill:none}.polar-chart .radial-gridline-path{fill:none;stroke-dasharray:10 10}.polar-chart .pie-label-line{stroke:#2f3646}.polar-charts-series .polar-series-area,.polar-series-path{pointer-events:none}"]
10904
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".pie-label{font-size:11px}.pie-label.animation{-webkit-animation:.75s ease-in fadeIn;animation:.75s ease-in fadeIn}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{-webkit-animation:3s linear drawOut;animation:3s linear drawOut;transition:d .75s}@-webkit-keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}\n", ".polar-chart .polar-chart-background{fill:none}.polar-chart .radial-gridline-path{stroke-dasharray:10 10;fill:none}.polar-chart .pie-label-line{stroke:#2f3646}.polar-charts-series .polar-series-area{pointer-events:none}.polar-series-path{pointer-events:none}\n"]
10162
10905
  },] }
10163
10906
  ];
10164
10907
  PolarChartComponent.propDecorators = {
@@ -10202,6 +10945,9 @@
10202
10945
  this.activate = new core.EventEmitter();
10203
10946
  this.deactivate = new core.EventEmitter();
10204
10947
  this.circleRadius = 3;
10948
+ this.barOrientation = exports.BarOrientation;
10949
+ this.placementTypes = exports.PlacementTypes;
10950
+ this.styleTypes = exports.StyleTypes;
10205
10951
  }
10206
10952
  PolarSeriesComponent.prototype.ngOnChanges = function (changes) {
10207
10953
  this.update();
@@ -10212,7 +10958,7 @@
10212
10958
  var line = this.getLineGenerator();
10213
10959
  var data = this.sortData(this.data.series);
10214
10960
  var seriesName = this.data.name;
10215
- var linearScaleType = this.colors.scaleType === exports.ɵc.Linear;
10961
+ var linearScaleType = this.colors.scaleType === exports.ScaleType.Linear;
10216
10962
  var min = this.yScale.domain()[0];
10217
10963
  this.seriesColor = this.colors.getColor(linearScaleType ? min : seriesName);
10218
10964
  this.path = line(data) || '';
@@ -10241,10 +10987,10 @@
10241
10987
  };
10242
10988
  PolarSeriesComponent.prototype.getAngle = function (d) {
10243
10989
  var label = d.name;
10244
- if (this.scaleType === exports.ɵc.Time) {
10990
+ if (this.scaleType === exports.ScaleType.Time) {
10245
10991
  return this.xScale(label);
10246
10992
  }
10247
- else if (this.scaleType === exports.ɵc.Linear) {
10993
+ else if (this.scaleType === exports.ScaleType.Linear) {
10248
10994
  return this.xScale(Number(label));
10249
10995
  }
10250
10996
  return this.xScale(label);
@@ -10260,10 +11006,10 @@
10260
11006
  .curve(this.curve);
10261
11007
  };
10262
11008
  PolarSeriesComponent.prototype.sortData = function (data) {
10263
- if (this.scaleType === exports.ɵc.Linear) {
11009
+ if (this.scaleType === exports.ScaleType.Linear) {
10264
11010
  return sortLinear(data, 'name');
10265
11011
  }
10266
- else if (this.scaleType === exports.ɵc.Time) {
11012
+ else if (this.scaleType === exports.ScaleType.Time) {
10267
11013
  return sortByTime(data, 'name');
10268
11014
  }
10269
11015
  return sortByDomain(data, 'name', 'asc', this.xScale.domain());
@@ -10289,16 +11035,16 @@
10289
11035
  return "\n <span class=\"tooltip-label\">" + escapeLabel(this.data.name) + " \u2022 " + escapeLabel(label) + "</span>\n <span class=\"tooltip-val\">" + value.toLocaleString() + "</span>\n ";
10290
11036
  };
10291
11037
  PolarSeriesComponent.prototype.updateGradients = function () {
10292
- this.hasGradient = this.gradient || this.colors.scaleType === exports.ɵc.Linear;
11038
+ this.hasGradient = this.gradient || this.colors.scaleType === exports.ScaleType.Linear;
10293
11039
  if (!this.hasGradient) {
10294
11040
  return;
10295
11041
  }
10296
11042
  this.gradientId = 'grad' + id().toString();
10297
11043
  this.gradientUrl = "url(#" + this.gradientId + ")";
10298
- if (this.colors.scaleType === exports.ɵc.Linear) {
11044
+ if (this.colors.scaleType === exports.ScaleType.Linear) {
10299
11045
  var values = this.data.series.map(function (d) { return d.value; });
10300
- var max = Math.max.apply(Math, __spread(values));
10301
- var min = Math.min.apply(Math, __spread(values));
11046
+ var max = Math.max.apply(Math, __spreadArray([], __read(values)));
11047
+ var min = Math.min.apply(Math, __spreadArray([], __read(values)));
10302
11048
  this.gradientStops = this.colors.getLinearGradientStops(max, min);
10303
11049
  }
10304
11050
  else {
@@ -10310,7 +11056,7 @@
10310
11056
  PolarSeriesComponent.decorators = [
10311
11057
  { type: core.Component, args: [{
10312
11058
  selector: 'g[ngx-charts-polar-series]',
10313
- template: "\n <svg:g class=\"polar-charts-series\">\n <defs>\n <svg:g\n ngx-charts-svg-radial-gradient\n *ngIf=\"hasGradient\"\n orientation=\"vertical\"\n [color]=\"seriesColor\"\n [name]=\"gradientId\"\n [startOpacity]=\"0.25\"\n [endOpacity]=\"1\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:g\n ngx-charts-line\n class=\"polar-series-path\"\n [path]=\"path\"\n [stroke]=\"hasGradient ? gradientUrl : seriesColor\"\n [class.active]=\"active\"\n [class.inactive]=\"inactive\"\n [attr.fill-opacity]=\"rangeFillOpacity\"\n [fill]=\"hasGradient ? gradientUrl : seriesColor\"\n [animations]=\"animations\"\n />\n <svg:g\n ngx-charts-circle\n *ngFor=\"let circle of circles\"\n class=\"circle\"\n [cx]=\"circle.cx\"\n [cy]=\"circle.cy\"\n [r]=\"circleRadius\"\n [fill]=\"circle.color\"\n [style.opacity]=\"inactive ? 0.2 : 1\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n tooltipType=\"tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n (select)=\"select.emit(circle.data)\"\n (activate)=\"activate.emit({ name: circle.data.series })\"\n (deactivate)=\"deactivate.emit({ name: circle.data.series })\"\n ></svg:g>\n </svg:g>\n ",
11059
+ template: "\n <svg:g class=\"polar-charts-series\">\n <defs>\n <svg:g\n ngx-charts-svg-radial-gradient\n *ngIf=\"hasGradient\"\n [color]=\"seriesColor\"\n [name]=\"gradientId\"\n [startOpacity]=\"0.25\"\n [endOpacity]=\"1\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:g\n ngx-charts-line\n class=\"polar-series-path\"\n [path]=\"path\"\n [stroke]=\"hasGradient ? gradientUrl : seriesColor\"\n [class.active]=\"active\"\n [class.inactive]=\"inactive\"\n [attr.fill-opacity]=\"rangeFillOpacity\"\n [fill]=\"hasGradient ? gradientUrl : seriesColor\"\n [animations]=\"animations\"\n />\n <svg:g\n ngx-charts-circle\n *ngFor=\"let circle of circles\"\n class=\"circle\"\n [cx]=\"circle.cx\"\n [cy]=\"circle.cy\"\n [r]=\"circleRadius\"\n [fill]=\"circle.color\"\n [style.opacity]=\"inactive ? 0.2 : 1\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(circle)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"circle.data\"\n (select)=\"select.emit(circle.data)\"\n (activate)=\"activate.emit({ name: circle.data.series })\"\n (deactivate)=\"deactivate.emit({ name: circle.data.series })\"\n ></svg:g>\n </svg:g>\n ",
10314
11060
  changeDetection: core.ChangeDetectionStrategy.OnPush
10315
11061
  },] }
10316
11062
  ];
@@ -10337,7 +11083,7 @@
10337
11083
  var AdvancedPieChartComponent = /** @class */ (function (_super) {
10338
11084
  __extends(AdvancedPieChartComponent, _super);
10339
11085
  function AdvancedPieChartComponent() {
10340
- var _this = _super.apply(this, __spread(arguments)) || this;
11086
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
10341
11087
  _this.activeEntries = [];
10342
11088
  _this.tooltipDisabled = false;
10343
11089
  _this.label = 'Total';
@@ -10370,7 +11116,7 @@
10370
11116
  this.select.emit(data);
10371
11117
  };
10372
11118
  AdvancedPieChartComponent.prototype.setColors = function () {
10373
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
11119
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
10374
11120
  };
10375
11121
  AdvancedPieChartComponent.prototype.onActivate = function (item, fromLegend) {
10376
11122
  if (fromLegend === void 0) { fromLegend = false; }
@@ -10388,7 +11134,7 @@
10388
11134
  if (idx > -1) {
10389
11135
  return;
10390
11136
  }
10391
- this.activeEntries = __spread([item], this.activeEntries);
11137
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
10392
11138
  this.activate.emit({ value: item, entries: this.activeEntries });
10393
11139
  };
10394
11140
  AdvancedPieChartComponent.prototype.onDeactivate = function (item, fromLegend) {
@@ -10405,7 +11151,7 @@
10405
11151
  return d.name === item.name && d.value === item.value && d.series === item.series;
10406
11152
  });
10407
11153
  this.activeEntries.splice(idx, 1);
10408
- this.activeEntries = __spread(this.activeEntries);
11154
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
10409
11155
  this.deactivate.emit({ value: item, entries: this.activeEntries });
10410
11156
  };
10411
11157
  return AdvancedPieChartComponent;
@@ -10416,7 +11162,7 @@
10416
11162
  template: "\n <div [style.width.px]=\"width\" [style.height.px]=\"height\">\n <div class=\"advanced-pie chart\" [style.width.px]=\"dims.width\" [style.height.px]=\"dims.height\">\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\">\n <svg:g [attr.transform]=\"transform\" class=\"pie chart\">\n <svg:g\n ngx-charts-pie-series\n [colors]=\"colors\"\n [series]=\"results\"\n [innerRadius]=\"innerRadius\"\n [activeEntries]=\"activeEntries\"\n [outerRadius]=\"outerRadius\"\n [gradient]=\"gradient\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipText]=\"tooltipText\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n [animations]=\"animations\"\n ></svg:g>\n </svg:g>\n </ngx-charts-chart>\n </div>\n <div class=\"advanced-pie-legend-wrapper\" [style.width.px]=\"width - dims.width\" [style.height.px]=\"height\">\n <ngx-charts-advanced-legend\n [data]=\"results\"\n [colors]=\"colors\"\n [width]=\"width - dims.width - margin[1]\"\n [label]=\"label\"\n [animations]=\"animations\"\n [valueFormatting]=\"valueFormatting\"\n [labelFormatting]=\"nameFormatting\"\n [percentageFormatting]=\"percentageFormatting\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event, true)\"\n (deactivate)=\"onDeactivate($event, true)\"\n >\n </ngx-charts-advanced-legend>\n </div>\n </div>\n ",
10417
11163
  encapsulation: core.ViewEncapsulation.None,
10418
11164
  changeDetection: core.ChangeDetectionStrategy.OnPush,
10419
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".advanced-pie{float:left}.advanced-pie,.advanced-pie-legend-wrapper{display:inline-block}"]
11165
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".advanced-pie{display:inline-block;float:left}.advanced-pie-legend-wrapper{display:inline-block}\n"]
10420
11166
  },] }
10421
11167
  ];
10422
11168
  AdvancedPieChartComponent.propDecorators = {
@@ -10532,6 +11278,7 @@
10532
11278
  this.activate = new core.EventEmitter();
10533
11279
  this.deactivate = new core.EventEmitter();
10534
11280
  this.dblclick = new core.EventEmitter();
11281
+ this.barOrientation = exports.BarOrientation;
10535
11282
  this.initialized = false;
10536
11283
  this.element = element.nativeElement;
10537
11284
  }
@@ -10633,7 +11380,7 @@
10633
11380
  PieArcComponent.decorators = [
10634
11381
  { type: core.Component, args: [{
10635
11382
  selector: 'g[ngx-charts-pie-arc]',
10636
- template: "\n <svg:g class=\"arc-group\">\n <svg:defs *ngIf=\"gradient\">\n <svg:g\n ngx-charts-svg-radial-gradient\n [color]=\"fill\"\n orientation=\"vertical\"\n [name]=\"radialGradientId\"\n [startOpacity]=\"startOpacity\"\n />\n </svg:defs>\n <svg:path\n [attr.d]=\"path\"\n class=\"arc\"\n [class.active]=\"isActive\"\n [attr.fill]=\"getGradient()\"\n (click)=\"onClick()\"\n (dblclick)=\"onDblClick($event)\"\n (mouseenter)=\"activate.emit(data)\"\n (mouseleave)=\"deactivate.emit(data)\"\n [style.pointer-events]=\"getPointerEvents()\"\n />\n </svg:g>\n ",
11383
+ template: "\n <svg:g class=\"arc-group\">\n <svg:defs *ngIf=\"gradient\">\n <svg:g ngx-charts-svg-radial-gradient [color]=\"fill\" [name]=\"radialGradientId\" [startOpacity]=\"startOpacity\" />\n </svg:defs>\n <svg:path\n [attr.d]=\"path\"\n class=\"arc\"\n [class.active]=\"isActive\"\n [attr.fill]=\"getGradient()\"\n (click)=\"onClick()\"\n (dblclick)=\"onDblClick($event)\"\n (mouseenter)=\"activate.emit(data)\"\n (mouseleave)=\"deactivate.emit(data)\"\n [style.pointer-events]=\"getPointerEvents()\"\n />\n </svg:g>\n ",
10637
11384
  changeDetection: core.ChangeDetectionStrategy.OnPush
10638
11385
  },] }
10639
11386
  ];
@@ -10664,7 +11411,7 @@
10664
11411
  var PieChartComponent = /** @class */ (function (_super) {
10665
11412
  __extends(PieChartComponent, _super);
10666
11413
  function PieChartComponent() {
10667
- var _this = _super.apply(this, __spread(arguments)) || this;
11414
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
10668
11415
  _this.labels = false;
10669
11416
  _this.legend = false;
10670
11417
  _this.legendTitle = 'Legend';
@@ -10730,11 +11477,11 @@
10730
11477
  this.select.emit(data);
10731
11478
  };
10732
11479
  PieChartComponent.prototype.setColors = function () {
10733
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
11480
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
10734
11481
  };
10735
11482
  PieChartComponent.prototype.getLegendOptions = function () {
10736
11483
  return {
10737
- scaleType: exports.ɵc.Ordinal,
11484
+ scaleType: exports.ScaleType.Ordinal,
10738
11485
  domain: this.domain,
10739
11486
  colors: this.colors,
10740
11487
  title: this.legendTitle,
@@ -10757,7 +11504,7 @@
10757
11504
  if (idx > -1) {
10758
11505
  return;
10759
11506
  }
10760
- this.activeEntries = __spread([item], this.activeEntries);
11507
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
10761
11508
  this.activate.emit({ value: item, entries: this.activeEntries });
10762
11509
  };
10763
11510
  PieChartComponent.prototype.onDeactivate = function (item, fromLegend) {
@@ -10774,7 +11521,7 @@
10774
11521
  return d.name === item.name && d.value === item.value && d.series === item.series;
10775
11522
  });
10776
11523
  this.activeEntries.splice(idx, 1);
10777
- this.activeEntries = __spread(this.activeEntries);
11524
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
10778
11525
  this.deactivate.emit({ value: item, entries: this.activeEntries });
10779
11526
  };
10780
11527
  PieChartComponent.prototype.hasNoOptionalMarginsSet = function () {
@@ -10788,7 +11535,7 @@
10788
11535
  template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelActivate)=\"onActivate($event, true)\"\n (legendLabelDeactivate)=\"onDeactivate($event, true)\"\n (legendLabelClick)=\"onClick($event)\"\n >\n <svg:g [attr.transform]=\"translation\" class=\"pie-chart chart\">\n <svg:g\n ngx-charts-pie-series\n [colors]=\"colors\"\n [series]=\"data\"\n [showLabels]=\"labels\"\n [labelFormatting]=\"labelFormatting\"\n [trimLabels]=\"trimLabels\"\n [maxLabelLength]=\"maxLabelLength\"\n [activeEntries]=\"activeEntries\"\n [innerRadius]=\"innerRadius\"\n [outerRadius]=\"outerRadius\"\n [explodeSlices]=\"explodeSlices\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipText]=\"tooltipText\"\n (dblclick)=\"dblclick.emit($event)\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
10789
11536
  encapsulation: core.ViewEncapsulation.None,
10790
11537
  changeDetection: core.ChangeDetectionStrategy.OnPush,
10791
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".pie-label{font-size:11px}.pie-label.animation{-webkit-animation:fadeIn .75s ease-in;animation:fadeIn .75s ease-in}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{-webkit-animation:drawOut 3s linear;animation:drawOut 3s linear;transition:d .75s}@-webkit-keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}"]
11538
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".pie-label{font-size:11px}.pie-label.animation{-webkit-animation:.75s ease-in fadeIn;animation:.75s ease-in fadeIn}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.pie-label-line{stroke-dasharray:100%}.pie-label-line.animation{-webkit-animation:3s linear drawOut;animation:3s linear drawOut;transition:d .75s}@-webkit-keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}@keyframes drawOut{0%{stroke-dashoffset:100%}to{stroke-dashoffset:0}}\n"]
10792
11539
  },] }
10793
11540
  ];
10794
11541
  PieChartComponent.propDecorators = {
@@ -10872,7 +11619,7 @@
10872
11619
  var PieGridComponent = /** @class */ (function (_super) {
10873
11620
  __extends(PieGridComponent, _super);
10874
11621
  function PieGridComponent() {
10875
- var _this = _super.apply(this, __spread(arguments)) || this;
11622
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
10876
11623
  _this.tooltipDisabled = false;
10877
11624
  _this.label = 'Total';
10878
11625
  _this.minWidth = 150;
@@ -10880,6 +11627,8 @@
10880
11627
  _this.activate = new core.EventEmitter();
10881
11628
  _this.deactivate = new core.EventEmitter();
10882
11629
  _this.margin = [20, 20, 20, 20];
11630
+ _this.placementTypes = exports.PlacementTypes;
11631
+ _this.styleTypes = exports.StyleTypes;
10883
11632
  return _this;
10884
11633
  }
10885
11634
  PieGridComponent.prototype.update = function () {
@@ -10959,7 +11708,7 @@
10959
11708
  this.select.emit(data);
10960
11709
  };
10961
11710
  PieGridComponent.prototype.setColors = function () {
10962
- this.colorScale = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
11711
+ this.colorScale = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
10963
11712
  };
10964
11713
  PieGridComponent.prototype.onActivate = function (item, fromLegend) {
10965
11714
  if (fromLegend === void 0) { fromLegend = false; }
@@ -10977,7 +11726,7 @@
10977
11726
  if (idx > -1) {
10978
11727
  return;
10979
11728
  }
10980
- this.activeEntries = __spread([item], this.activeEntries);
11729
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
10981
11730
  this.activate.emit({ value: item, entries: this.activeEntries });
10982
11731
  };
10983
11732
  PieGridComponent.prototype.onDeactivate = function (item, fromLegend) {
@@ -10994,7 +11743,7 @@
10994
11743
  return d.name === item.name && d.value === item.value && d.series === item.series;
10995
11744
  });
10996
11745
  this.activeEntries.splice(idx, 1);
10997
- this.activeEntries = __spread(this.activeEntries);
11746
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
10998
11747
  this.deactivate.emit({ value: item, entries: this.activeEntries });
10999
11748
  };
11000
11749
  return PieGridComponent;
@@ -11002,10 +11751,10 @@
11002
11751
  PieGridComponent.decorators = [
11003
11752
  { type: core.Component, args: [{
11004
11753
  selector: 'ngx-charts-pie-grid',
11005
- template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\">\n <svg:g [attr.transform]=\"transform\" class=\"pie-grid chart\">\n <svg:g *ngFor=\"let series of series\" class=\"pie-grid-item\" [attr.transform]=\"series.transform\">\n <svg:g\n ngx-charts-pie-grid-series\n [colors]=\"series.colors\"\n [data]=\"series.data\"\n [innerRadius]=\"series.innerRadius\"\n [outerRadius]=\"series.outerRadius\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText({ data: series })\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"series.data[0].data\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n <svg:text\n *ngIf=\"animations\"\n class=\"label percent-label\"\n dy=\"-0.5em\"\n x=\"0\"\n y=\"5\"\n ngx-charts-count-up\n [countTo]=\"series.percent\"\n [countSuffix]=\"'%'\"\n text-anchor=\"middle\"\n ></svg:text>\n <svg:text *ngIf=\"!animations\" class=\"label percent-label\" dy=\"-0.5em\" x=\"0\" y=\"5\" text-anchor=\"middle\">\n {{ series.percent.toLocaleString() }}\n </svg:text>\n <svg:text class=\"label\" dy=\"0.5em\" x=\"0\" y=\"5\" text-anchor=\"middle\">\n {{ series.label }}\n </svg:text>\n <svg:text\n *ngIf=\"animations\"\n class=\"label\"\n dy=\"1.23em\"\n x=\"0\"\n [attr.y]=\"series.outerRadius\"\n text-anchor=\"middle\"\n ngx-charts-count-up\n [countTo]=\"series.total\"\n [countPrefix]=\"label + ': '\"\n ></svg:text>\n <svg:text\n *ngIf=\"!animations\"\n class=\"label\"\n dy=\"1.23em\"\n x=\"0\"\n [attr.y]=\"series.outerRadius\"\n text-anchor=\"middle\"\n >\n {{ label }}: {{ series.total.toLocaleString() }}\n </svg:text>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
11754
+ template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\">\n <svg:g [attr.transform]=\"transform\" class=\"pie-grid chart\">\n <svg:g *ngFor=\"let series of series\" class=\"pie-grid-item\" [attr.transform]=\"series.transform\">\n <svg:g\n ngx-charts-pie-grid-series\n [colors]=\"series.colors\"\n [data]=\"series.data\"\n [innerRadius]=\"series.innerRadius\"\n [outerRadius]=\"series.outerRadius\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText({ data: series })\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"series.data[0].data\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n />\n <svg:text\n *ngIf=\"animations\"\n class=\"label percent-label\"\n dy=\"-0.5em\"\n x=\"0\"\n y=\"5\"\n ngx-charts-count-up\n [countTo]=\"series.percent\"\n [countSuffix]=\"'%'\"\n text-anchor=\"middle\"\n ></svg:text>\n <svg:text *ngIf=\"!animations\" class=\"label percent-label\" dy=\"-0.5em\" x=\"0\" y=\"5\" text-anchor=\"middle\">\n {{ series.percent.toLocaleString() }}\n </svg:text>\n <svg:text class=\"label\" dy=\"0.5em\" x=\"0\" y=\"5\" text-anchor=\"middle\">\n {{ series.label }}\n </svg:text>\n <svg:text\n *ngIf=\"animations\"\n class=\"label\"\n dy=\"1.23em\"\n x=\"0\"\n [attr.y]=\"series.outerRadius\"\n text-anchor=\"middle\"\n ngx-charts-count-up\n [countTo]=\"series.total\"\n [countPrefix]=\"label + ': '\"\n ></svg:text>\n <svg:text\n *ngIf=\"!animations\"\n class=\"label\"\n dy=\"1.23em\"\n x=\"0\"\n [attr.y]=\"series.outerRadius\"\n text-anchor=\"middle\"\n >\n {{ label }}: {{ series.total.toLocaleString() }}\n </svg:text>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
11006
11755
  encapsulation: core.ViewEncapsulation.None,
11007
11756
  changeDetection: core.ChangeDetectionStrategy.OnPush,
11008
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".pie-grid .arc1{opacity:.4}.pie-grid .percent-label{font-size:16px;font-weight:400}"]
11757
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".pie-grid .arc1{opacity:.4}.pie-grid .percent-label{font-size:16px;font-weight:400}\n"]
11009
11758
  },] }
11010
11759
  ];
11011
11760
  PieGridComponent.propDecorators = {
@@ -11107,6 +11856,8 @@
11107
11856
  this.activate = new core.EventEmitter();
11108
11857
  this.deactivate = new core.EventEmitter();
11109
11858
  this.dblclick = new core.EventEmitter();
11859
+ this.placementTypes = exports.PlacementTypes;
11860
+ this.styleTypes = exports.StyleTypes;
11110
11861
  }
11111
11862
  PieSeriesComponent.prototype.ngOnChanges = function (changes) {
11112
11863
  this.update();
@@ -11205,7 +11956,7 @@
11205
11956
  PieSeriesComponent.decorators = [
11206
11957
  { type: core.Component, args: [{
11207
11958
  selector: 'g[ngx-charts-pie-series]',
11208
- template: "\n <svg:g *ngFor=\"let arc of data; trackBy: trackBy\">\n <svg:g\n ngx-charts-pie-label\n *ngIf=\"labelVisible(arc)\"\n [data]=\"arc\"\n [radius]=\"outerRadius\"\n [color]=\"color(arc)\"\n [label]=\"labelText(arc)\"\n [labelTrim]=\"trimLabels\"\n [labelTrimSize]=\"maxLabelLength\"\n [max]=\"max\"\n [value]=\"arc.value\"\n [explodeSlices]=\"explodeSlices\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g\n ngx-charts-pie-arc\n [startAngle]=\"arc.startAngle\"\n [endAngle]=\"arc.endAngle\"\n [innerRadius]=\"innerRadius\"\n [outerRadius]=\"outerRadius\"\n [fill]=\"color(arc)\"\n [value]=\"arc.data.value\"\n [gradient]=\"gradient\"\n [data]=\"arc.data\"\n [max]=\"max\"\n [explodeSlices]=\"explodeSlices\"\n [isActive]=\"isActive(arc.data)\"\n [animate]=\"animations\"\n (select)=\"onClick($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n (dblclick)=\"dblclick.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"getTooltipTitle(arc)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"arc.data\"\n ></svg:g>\n </svg:g>\n ",
11959
+ template: "\n <svg:g *ngFor=\"let arc of data; trackBy: trackBy\">\n <svg:g\n ngx-charts-pie-label\n *ngIf=\"labelVisible(arc)\"\n [data]=\"arc\"\n [radius]=\"outerRadius\"\n [color]=\"color(arc)\"\n [label]=\"labelText(arc)\"\n [labelTrim]=\"trimLabels\"\n [labelTrimSize]=\"maxLabelLength\"\n [max]=\"max\"\n [value]=\"arc.value\"\n [explodeSlices]=\"explodeSlices\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g\n ngx-charts-pie-arc\n [startAngle]=\"arc.startAngle\"\n [endAngle]=\"arc.endAngle\"\n [innerRadius]=\"innerRadius\"\n [outerRadius]=\"outerRadius\"\n [fill]=\"color(arc)\"\n [value]=\"arc.data.value\"\n [gradient]=\"gradient\"\n [data]=\"arc.data\"\n [max]=\"max\"\n [explodeSlices]=\"explodeSlices\"\n [isActive]=\"isActive(arc.data)\"\n [animate]=\"animations\"\n (select)=\"onClick($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n (dblclick)=\"dblclick.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"getTooltipTitle(arc)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"arc.data\"\n ></svg:g>\n </svg:g>\n ",
11209
11960
  changeDetection: core.ChangeDetectionStrategy.OnPush
11210
11961
  },] }
11211
11962
  ];
@@ -11538,7 +12289,7 @@
11538
12289
  */
11539
12290
  function hexToRgb(value) {
11540
12291
  // deprecated, use d3.color()
11541
- return d3_color.rgb(value);
12292
+ return d3_color__namespace.rgb(value);
11542
12293
  }
11543
12294
  /**
11544
12295
  * Accepts a color (string) and returns a inverted hex color (string)
@@ -11547,7 +12298,7 @@
11547
12298
  * @export
11548
12299
  */
11549
12300
  function invertColor(value) {
11550
- var color = d3_color.rgb(value);
12301
+ var color = d3_color__namespace.rgb(value);
11551
12302
  var r = color.r, g = color.g, b = color.b, opacity = color.opacity;
11552
12303
  if (opacity === 0) {
11553
12304
  return color.toString();
@@ -11667,7 +12418,7 @@
11667
12418
  var NumberCardComponent = /** @class */ (function (_super) {
11668
12419
  __extends(NumberCardComponent, _super);
11669
12420
  function NumberCardComponent() {
11670
- var _this = _super.apply(this, __spread(arguments)) || this;
12421
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
11671
12422
  _this.emptyColor = 'rgba(0, 0, 0, 0)';
11672
12423
  _this.innerPadding = 15;
11673
12424
  _this.margin = [10, 10, 10, 10];
@@ -11706,7 +12457,7 @@
11706
12457
  this.select.emit(data);
11707
12458
  };
11708
12459
  NumberCardComponent.prototype.setColors = function () {
11709
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
12460
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
11710
12461
  };
11711
12462
  return NumberCardComponent;
11712
12463
  }(BaseChartComponent));
@@ -11716,7 +12467,7 @@
11716
12467
  template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\">\n <svg:g [attr.transform]=\"transform\" class=\"number-card chart\" [class.clickable]=\"clickable\">\n <svg:g\n ngx-charts-card-series\n [colors]=\"colors\"\n [cardColor]=\"cardColor\"\n [bandColor]=\"bandColor\"\n [textColor]=\"textColor\"\n [emptyColor]=\"emptyColor\"\n [data]=\"data\"\n [dims]=\"dims\"\n [innerPadding]=\"innerPadding\"\n [valueFormatting]=\"valueFormatting\"\n [labelFormatting]=\"labelFormatting\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
11717
12468
  encapsulation: core.ViewEncapsulation.None,
11718
12469
  changeDetection: core.ChangeDetectionStrategy.OnPush,
11719
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", "ngx-charts-number-card .cell .trimmed-label{font-size:12px;line-height:1em;overflow:hidden;pointer-events:none;text-align:left}ngx-charts-number-card .cell .trimmed-label p{margin:0;overflow:hidden;padding:0;text-overflow:ellipsis;white-space:nowrap;width:100%}ngx-charts-number-card .cell .value-text{pointer-events:none}ngx-charts-number-card .number-card.clickable .cell .card,ngx-charts-number-card .number-card.clickable .cell .card-band{cursor:pointer}"]
12470
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", "ngx-charts-number-card .cell .trimmed-label{font-size:12px;pointer-events:none;overflow:hidden;text-align:left;line-height:1em}ngx-charts-number-card .cell .trimmed-label p{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;width:100%;padding:0;margin:0}ngx-charts-number-card .cell .value-text{pointer-events:none}ngx-charts-number-card .number-card.clickable .cell .card,ngx-charts-number-card .number-card.clickable .cell .card-band{cursor:pointer}\n"]
11720
12471
  },] }
11721
12472
  ];
11722
12473
  NumberCardComponent.propDecorators = {
@@ -11749,6 +12500,7 @@
11749
12500
  this.animations = true;
11750
12501
  this.select = new core.EventEmitter();
11751
12502
  this.initialized = false;
12503
+ this.orientation = exports.BarOrientation;
11752
12504
  this.element = element.nativeElement;
11753
12505
  }
11754
12506
  TreeMapCellComponent.prototype.ngOnChanges = function () {
@@ -11823,7 +12575,7 @@
11823
12575
  TreeMapCellComponent.decorators = [
11824
12576
  { type: core.Component, args: [{
11825
12577
  selector: 'g[ngx-charts-tree-map-cell]',
11826
- template: "\n <svg:g>\n <defs *ngIf=\"gradient\">\n <svg:g ngx-charts-svg-linear-gradient orientation=\"vertical\" [name]=\"gradientId\" [stops]=\"gradientStops\" />\n </defs>\n <svg:rect\n [attr.fill]=\"gradient ? gradientUrl : fill\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n [attr.x]=\"x\"\n [attr.y]=\"y\"\n [style.cursor]=\"'pointer'\"\n class=\"cell\"\n (click)=\"onClick()\"\n />\n <svg:foreignObject\n *ngIf=\"width >= 70 && height >= 35\"\n [attr.x]=\"x\"\n [attr.y]=\"y\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n class=\"treemap-label\"\n [style.pointer-events]=\"'none'\"\n >\n <xhtml:p [style.color]=\"getTextColor()\" [style.height]=\"height + 'px'\" [style.width]=\"width + 'px'\">\n <xhtml:span class=\"treemap-label\" [innerHTML]=\"formattedLabel\"> </xhtml:span>\n <xhtml:br />\n <xhtml:span\n *ngIf=\"animations\"\n class=\"treemap-val\"\n ngx-charts-count-up\n [countTo]=\"value\"\n [valueFormatting]=\"valueFormatting\"\n >\n </xhtml:span>\n <xhtml:span *ngIf=\"!animations\" class=\"treemap-val\">\n {{ formattedValue }}\n </xhtml:span>\n </xhtml:p>\n </svg:foreignObject>\n </svg:g>\n ",
12578
+ template: "\n <svg:g>\n <defs *ngIf=\"gradient\">\n <svg:g\n ngx-charts-svg-linear-gradient\n [orientation]=\"orientation.Vertical\"\n [name]=\"gradientId\"\n [stops]=\"gradientStops\"\n />\n </defs>\n <svg:rect\n [attr.fill]=\"gradient ? gradientUrl : fill\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n [attr.x]=\"x\"\n [attr.y]=\"y\"\n class=\"cell\"\n (click)=\"onClick()\"\n />\n <svg:foreignObject\n *ngIf=\"width >= 70 && height >= 35\"\n [attr.x]=\"x\"\n [attr.y]=\"y\"\n [attr.width]=\"width\"\n [attr.height]=\"height\"\n class=\"treemap-label\"\n [style.pointer-events]=\"'none'\"\n >\n <xhtml:p [style.color]=\"getTextColor()\" [style.height]=\"height + 'px'\" [style.width]=\"width + 'px'\">\n <xhtml:span class=\"treemap-label\" [innerHTML]=\"formattedLabel\"> </xhtml:span>\n <xhtml:br />\n <xhtml:span\n *ngIf=\"animations\"\n class=\"treemap-val\"\n ngx-charts-count-up\n [countTo]=\"value\"\n [valueFormatting]=\"valueFormatting\"\n >\n </xhtml:span>\n <xhtml:span *ngIf=\"!animations\" class=\"treemap-val\">\n {{ formattedValue }}\n </xhtml:span>\n </xhtml:p>\n </svg:foreignObject>\n </svg:g>\n ",
11827
12579
  changeDetection: core.ChangeDetectionStrategy.OnPush
11828
12580
  },] }
11829
12581
  ];
@@ -11852,6 +12604,8 @@
11852
12604
  this.tooltipDisabled = false;
11853
12605
  this.animations = true;
11854
12606
  this.select = new core.EventEmitter();
12607
+ this.styleTypes = exports.StyleTypes;
12608
+ this.placementTypes = exports.PlacementTypes;
11855
12609
  }
11856
12610
  TreeMapCellSeriesComponent.prototype.ngOnChanges = function (changes) {
11857
12611
  this.cells = this.getCells();
@@ -11891,7 +12645,7 @@
11891
12645
  TreeMapCellSeriesComponent.decorators = [
11892
12646
  { type: core.Component, args: [{
11893
12647
  selector: 'g[ngx-charts-tree-map-cell-series]',
11894
- template: "\n <svg:g\n ngx-charts-tree-map-cell\n *ngFor=\"let c of cells; trackBy: trackBy\"\n [data]=\"c.data\"\n [x]=\"c.x\"\n [y]=\"c.y\"\n [width]=\"c.width\"\n [height]=\"c.height\"\n [fill]=\"c.fill\"\n [label]=\"c.label\"\n [value]=\"c.value\"\n [valueFormatting]=\"valueFormatting\"\n [labelFormatting]=\"labelFormatting\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(c)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"c.data\"\n ></svg:g>\n ",
12648
+ template: "\n <svg:g\n ngx-charts-tree-map-cell\n *ngFor=\"let c of cells; trackBy: trackBy\"\n [data]=\"c.data\"\n [x]=\"c.x\"\n [y]=\"c.y\"\n [width]=\"c.width\"\n [height]=\"c.height\"\n [fill]=\"c.fill\"\n [label]=\"c.label\"\n [value]=\"c.value\"\n [valueFormatting]=\"valueFormatting\"\n [labelFormatting]=\"labelFormatting\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : getTooltipText(c)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"c.data\"\n ></svg:g>\n ",
11895
12649
  changeDetection: core.ChangeDetectionStrategy.OnPush
11896
12650
  },] }
11897
12651
  ];
@@ -11911,7 +12665,7 @@
11911
12665
  var TreeMapComponent = /** @class */ (function (_super) {
11912
12666
  __extends(TreeMapComponent, _super);
11913
12667
  function TreeMapComponent() {
11914
- var _this = _super.apply(this, __spread(arguments)) || this;
12668
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
11915
12669
  _this.tooltipDisabled = false;
11916
12670
  _this.gradient = false;
11917
12671
  _this.select = new core.EventEmitter();
@@ -11943,7 +12697,7 @@
11943
12697
  }
11944
12698
  return label;
11945
12699
  })
11946
- .parentId(function (d) { return (d.isRoot ? null : 'root'); })(__spread([rootNode], this.results))
12700
+ .parentId(function (d) { return (d.isRoot ? null : 'root'); })(__spreadArray([rootNode], __read(this.results)))
11947
12701
  .sum(function (d) { return d.value; });
11948
12702
  this.data = this.treemap(root);
11949
12703
  this.setColors();
@@ -11956,7 +12710,7 @@
11956
12710
  this.select.emit(data);
11957
12711
  };
11958
12712
  TreeMapComponent.prototype.setColors = function () {
11959
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
12713
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
11960
12714
  };
11961
12715
  return TreeMapComponent;
11962
12716
  }(BaseChartComponent));
@@ -11966,7 +12720,7 @@
11966
12720
  template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\">\n <svg:g [attr.transform]=\"transform\" class=\"tree-map chart\">\n <svg:g\n ngx-charts-tree-map-cell-series\n [colors]=\"colors\"\n [data]=\"data\"\n [dims]=\"dims\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [valueFormatting]=\"valueFormatting\"\n [labelFormatting]=\"labelFormatting\"\n [gradient]=\"gradient\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n />\n </svg:g>\n </ngx-charts-chart>\n ",
11967
12721
  encapsulation: core.ViewEncapsulation.None,
11968
12722
  changeDetection: core.ChangeDetectionStrategy.OnPush,
11969
- styles: [".tree-map .treemap-val{display:inline-block;font-size:1.3em;padding-top:5px}.tree-map .treemap-label p{display:table-cell;line-height:1.2em;text-align:center;vertical-align:middle}"]
12723
+ styles: [".tree-map .treemap-val{font-size:1.3em;padding-top:5px;display:inline-block}.tree-map .treemap-label p{display:table-cell;text-align:center;line-height:1.2em;vertical-align:middle}\n"]
11970
12724
  },] }
11971
12725
  ];
11972
12726
  TreeMapComponent.propDecorators = {
@@ -12000,7 +12754,7 @@
12000
12754
  var LinearGaugeComponent = /** @class */ (function (_super) {
12001
12755
  __extends(LinearGaugeComponent, _super);
12002
12756
  function LinearGaugeComponent() {
12003
- var _this = _super.apply(this, __spread(arguments)) || this;
12757
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
12004
12758
  _this.min = 0;
12005
12759
  _this.max = 100;
12006
12760
  _this.value = 0;
@@ -12011,6 +12765,7 @@
12011
12765
  _this.valueTranslate = '';
12012
12766
  _this.unitsTextTransform = '';
12013
12767
  _this.unitsTranslate = '';
12768
+ _this.barOrientation = exports.BarOrientation;
12014
12769
  return _this;
12015
12770
  }
12016
12771
  LinearGaugeComponent.prototype.ngAfterViewInit = function () {
@@ -12133,17 +12888,17 @@
12133
12888
  });
12134
12889
  };
12135
12890
  LinearGaugeComponent.prototype.setColors = function () {
12136
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, [this.value], this.customColors);
12891
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, [this.value], this.customColors);
12137
12892
  };
12138
12893
  return LinearGaugeComponent;
12139
12894
  }(BaseChartComponent));
12140
12895
  LinearGaugeComponent.decorators = [
12141
12896
  { type: core.Component, args: [{
12142
12897
  selector: 'ngx-charts-linear-gauge',
12143
- template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\" (click)=\"onClick()\">\n <svg:g class=\"linear-gauge chart\">\n <svg:g\n ngx-charts-bar\n class=\"background-bar\"\n [width]=\"dims.width\"\n [height]=\"3\"\n [x]=\"margin[3]\"\n [y]=\"dims.height / 2 + margin[0] - 2\"\n [data]=\"{}\"\n [orientation]=\"'horizontal'\"\n [roundEdges]=\"true\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g\n ngx-charts-bar\n [width]=\"valueScale(value)\"\n [height]=\"3\"\n [x]=\"margin[3]\"\n [y]=\"dims.height / 2 + margin[0] - 2\"\n [fill]=\"colors.getColor(units)\"\n [data]=\"{}\"\n [orientation]=\"'horizontal'\"\n [roundEdges]=\"true\"\n [animations]=\"animations\"\n ></svg:g>\n\n <svg:line\n *ngIf=\"hasPreviousValue\"\n [attr.transform]=\"transformLine\"\n x1=\"0\"\n y1=\"5\"\n x2=\"0\"\n y2=\"15\"\n [attr.stroke]=\"colors.getColor(units)\"\n />\n\n <svg:line\n *ngIf=\"hasPreviousValue\"\n [attr.transform]=\"transformLine\"\n x1=\"0\"\n y1=\"-5\"\n x2=\"0\"\n y2=\"-15\"\n [attr.stroke]=\"colors.getColor(units)\"\n />\n\n <svg:g [attr.transform]=\"transform\">\n <svg:g [attr.transform]=\"valueTranslate\">\n <svg:text\n #valueTextEl\n class=\"value\"\n [style.textAnchor]=\"'middle'\"\n [attr.transform]=\"valueTextTransform\"\n alignment-baseline=\"after-edge\"\n >\n {{ displayValue }}\n </svg:text>\n </svg:g>\n\n <svg:g [attr.transform]=\"unitsTranslate\">\n <svg:text\n #unitsTextEl\n class=\"units\"\n [style.textAnchor]=\"'middle'\"\n [attr.transform]=\"unitsTextTransform\"\n alignment-baseline=\"before-edge\"\n >\n {{ units }}\n </svg:text>\n </svg:g>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
12898
+ template: "\n <ngx-charts-chart [view]=\"[width, height]\" [showLegend]=\"false\" [animations]=\"animations\" (click)=\"onClick()\">\n <svg:g class=\"linear-gauge chart\">\n <svg:g\n ngx-charts-bar\n class=\"background-bar\"\n [width]=\"dims.width\"\n [height]=\"3\"\n [x]=\"margin[3]\"\n [y]=\"dims.height / 2 + margin[0] - 2\"\n [data]=\"{}\"\n [orientation]=\"barOrientation.Horizontal\"\n [roundEdges]=\"true\"\n [animations]=\"animations\"\n ></svg:g>\n <svg:g\n ngx-charts-bar\n [width]=\"valueScale(value)\"\n [height]=\"3\"\n [x]=\"margin[3]\"\n [y]=\"dims.height / 2 + margin[0] - 2\"\n [fill]=\"colors.getColor(units)\"\n [data]=\"{}\"\n [orientation]=\"barOrientation.Horizontal\"\n [roundEdges]=\"true\"\n [animations]=\"animations\"\n ></svg:g>\n\n <svg:line\n *ngIf=\"hasPreviousValue\"\n [attr.transform]=\"transformLine\"\n x1=\"0\"\n y1=\"5\"\n x2=\"0\"\n y2=\"15\"\n [attr.stroke]=\"colors.getColor(units)\"\n />\n\n <svg:line\n *ngIf=\"hasPreviousValue\"\n [attr.transform]=\"transformLine\"\n x1=\"0\"\n y1=\"-5\"\n x2=\"0\"\n y2=\"-15\"\n [attr.stroke]=\"colors.getColor(units)\"\n />\n\n <svg:g [attr.transform]=\"transform\">\n <svg:g [attr.transform]=\"valueTranslate\">\n <svg:text\n #valueTextEl\n class=\"value\"\n [style.textAnchor]=\"'middle'\"\n [attr.transform]=\"valueTextTransform\"\n alignment-baseline=\"after-edge\"\n >\n {{ displayValue }}\n </svg:text>\n </svg:g>\n\n <svg:g [attr.transform]=\"unitsTranslate\">\n <svg:text\n #unitsTextEl\n class=\"units\"\n [style.textAnchor]=\"'middle'\"\n [attr.transform]=\"unitsTextTransform\"\n alignment-baseline=\"before-edge\"\n >\n {{ units }}\n </svg:text>\n </svg:g>\n </svg:g>\n </svg:g>\n </ngx-charts-chart>\n ",
12144
12899
  encapsulation: core.ViewEncapsulation.None,
12145
12900
  changeDetection: core.ChangeDetectionStrategy.OnPush,
12146
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".linear-gauge{cursor:pointer}.linear-gauge .background-bar path{fill:rgba(0,0,0,.05)}.linear-gauge .units{fill:#666}"]
12901
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".linear-gauge{cursor:pointer}.linear-gauge .background-bar path{fill:#0000000d}.linear-gauge .units{fill:#666}\n"]
12147
12902
  },] }
12148
12903
  ];
12149
12904
  LinearGaugeComponent.propDecorators = {
@@ -12160,7 +12915,7 @@
12160
12915
  var GaugeComponent = /** @class */ (function (_super) {
12161
12916
  __extends(GaugeComponent, _super);
12162
12917
  function GaugeComponent() {
12163
- var _this = _super.apply(this, __spread(arguments)) || this;
12918
+ var _this = _super.apply(this, __spreadArray([], __read(arguments))) || this;
12164
12919
  _this.legend = false;
12165
12920
  _this.legendTitle = 'Legend';
12166
12921
  _this.legendPosition = exports.LegendPosition.Right;
@@ -12280,8 +13035,8 @@
12280
13035
  };
12281
13036
  GaugeComponent.prototype.getValueDomain = function () {
12282
13037
  var values = this.results.map(function (d) { return d.value; });
12283
- var dataMin = Math.min.apply(Math, __spread(values));
12284
- var dataMax = Math.max.apply(Math, __spread(values));
13038
+ var dataMin = Math.min.apply(Math, __spreadArray([], __read(values)));
13039
+ var dataMax = Math.max.apply(Math, __spreadArray([], __read(values)));
12285
13040
  if (this.min !== undefined) {
12286
13041
  this.min = Math.min(this.min, dataMin);
12287
13042
  }
@@ -12337,7 +13092,7 @@
12337
13092
  };
12338
13093
  GaugeComponent.prototype.getLegendOptions = function () {
12339
13094
  return {
12340
- scaleType: exports.ɵc.Ordinal,
13095
+ scaleType: exports.ScaleType.Ordinal,
12341
13096
  colors: this.colors,
12342
13097
  domain: this.domain,
12343
13098
  title: this.legendTitle,
@@ -12345,7 +13100,7 @@
12345
13100
  };
12346
13101
  };
12347
13102
  GaugeComponent.prototype.setColors = function () {
12348
- this.colors = new ColorHelper(this.scheme, exports.ɵc.Ordinal, this.domain, this.customColors);
13103
+ this.colors = new ColorHelper(this.scheme, exports.ScaleType.Ordinal, this.domain, this.customColors);
12349
13104
  };
12350
13105
  GaugeComponent.prototype.onActivate = function (item) {
12351
13106
  var idx = this.activeEntries.findIndex(function (d) {
@@ -12354,7 +13109,7 @@
12354
13109
  if (idx > -1) {
12355
13110
  return;
12356
13111
  }
12357
- this.activeEntries = __spread([item], this.activeEntries);
13112
+ this.activeEntries = __spreadArray([item], __read(this.activeEntries));
12358
13113
  this.activate.emit({ value: item, entries: this.activeEntries });
12359
13114
  };
12360
13115
  GaugeComponent.prototype.onDeactivate = function (item) {
@@ -12362,7 +13117,7 @@
12362
13117
  return d.name === item.name && d.value === item.value;
12363
13118
  });
12364
13119
  this.activeEntries.splice(idx, 1);
12365
- this.activeEntries = __spread(this.activeEntries);
13120
+ this.activeEntries = __spreadArray([], __read(this.activeEntries));
12366
13121
  this.deactivate.emit({ value: item, entries: this.activeEntries });
12367
13122
  };
12368
13123
  GaugeComponent.prototype.isActive = function (entry) {
@@ -12384,7 +13139,7 @@
12384
13139
  template: "\n <ngx-charts-chart\n [view]=\"[width, height]\"\n [showLegend]=\"legend\"\n [legendOptions]=\"legendOptions\"\n [activeEntries]=\"activeEntries\"\n [animations]=\"animations\"\n (legendLabelClick)=\"onClick($event)\"\n (legendLabelActivate)=\"onActivate($event)\"\n (legendLabelDeactivate)=\"onDeactivate($event)\"\n >\n <svg:g [attr.transform]=\"transform\" class=\"gauge chart\">\n <svg:g *ngFor=\"let arc of arcs; trackBy: trackBy\" [attr.transform]=\"rotation\">\n <svg:g\n ngx-charts-gauge-arc\n [backgroundArc]=\"arc.backgroundArc\"\n [valueArc]=\"arc.valueArc\"\n [cornerRadius]=\"cornerRadius\"\n [colors]=\"colors\"\n [isActive]=\"isActive(arc.valueArc.data)\"\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [valueFormatting]=\"valueFormatting\"\n [animations]=\"animations\"\n (select)=\"onClick($event)\"\n (activate)=\"onActivate($event)\"\n (deactivate)=\"onDeactivate($event)\"\n ></svg:g>\n </svg:g>\n\n <svg:g\n ngx-charts-gauge-axis\n *ngIf=\"showAxis\"\n [bigSegments]=\"bigSegments\"\n [smallSegments]=\"smallSegments\"\n [min]=\"min\"\n [max]=\"max\"\n [radius]=\"outerRadius\"\n [angleSpan]=\"angleSpan\"\n [valueScale]=\"valueScale\"\n [startAngle]=\"startAngle\"\n [tickFormatting]=\"axisTickFormatting\"\n ></svg:g>\n\n <svg:text\n #textEl\n *ngIf=\"showText\"\n [style.textAnchor]=\"'middle'\"\n [attr.transform]=\"textTransform\"\n alignment-baseline=\"central\"\n >\n <tspan x=\"0\" dy=\"0\">{{ displayValue }}</tspan>\n <tspan x=\"0\" dy=\"1.2em\">{{ units }}</tspan>\n </svg:text>\n </svg:g>\n </ngx-charts-chart>\n ",
12385
13140
  encapsulation: core.ViewEncapsulation.None,
12386
13141
  changeDetection: core.ChangeDetectionStrategy.OnPush,
12387
- styles: [".ngx-charts{float:left;overflow:visible}.ngx-charts .arc,.ngx-charts .bar,.ngx-charts .circle{cursor:pointer}.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .card.active,.ngx-charts .card:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .arc:focus,.ngx-charts .bar:focus,.ngx-charts .card:focus,.ngx-charts .cell:focus{outline:none}.ngx-charts .arc.hidden,.ngx-charts .bar.hidden,.ngx-charts .card.hidden,.ngx-charts .cell.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .area-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .line-series.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .polar-series-path.inactive{opacity:.2;transition:opacity .1s ease-in-out}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:400}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{fill:none;stroke:#ddd;stroke-width:1}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-dasharray:5;stroke-dashoffset:5;stroke-width:1}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill:#000;fill-opacity:.05}.ngx-charts .gridline-path-dotted{fill:none;stroke:#ddd;stroke-dasharray:1,20;stroke-dashoffset:3;stroke-width:1}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:rgba(0,0,0,.05)}", ".gauge .background-arc path{fill:rgba(0,0,0,.05)}.gauge .gauge-tick path{stroke:#666}.gauge .gauge-tick text{fill:#666;font-size:12px;font-weight:700}.gauge .gauge-tick-large path{stroke-width:2px}.gauge .gauge-tick-small path{stroke-width:1px}"]
13142
+ styles: [".ngx-charts-outer{-webkit-animation:chartFadeIn linear .6s;animation:chartFadeIn linear .6s}@-webkit-keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}@keyframes chartFadeIn{0%{opacity:0}20%{opacity:0}to{opacity:1}}.ngx-charts{float:left;overflow:visible}.ngx-charts .circle,.ngx-charts .cell,.ngx-charts .bar,.ngx-charts .arc{cursor:pointer}.ngx-charts .bar.active,.ngx-charts .bar:hover,.ngx-charts .cell.active,.ngx-charts .cell:hover,.ngx-charts .arc.active,.ngx-charts .arc:hover,.ngx-charts .card.active,.ngx-charts .card:hover{opacity:.8;transition:opacity .1s ease-in-out}.ngx-charts .bar:focus,.ngx-charts .cell:focus,.ngx-charts .arc:focus,.ngx-charts .card:focus{outline:none}.ngx-charts .bar.hidden,.ngx-charts .cell.hidden,.ngx-charts .arc.hidden,.ngx-charts .card.hidden{display:none}.ngx-charts g:focus{outline:none}.ngx-charts .line-series.inactive,.ngx-charts .line-series-range.inactive,.ngx-charts .polar-series-path.inactive,.ngx-charts .polar-series-area.inactive,.ngx-charts .area-series.inactive{transition:opacity .1s ease-in-out;opacity:.2}.ngx-charts .line-highlight{display:none}.ngx-charts .line-highlight.active{display:block}.ngx-charts .area{opacity:.6}.ngx-charts .circle:hover{cursor:pointer}.ngx-charts .label{font-size:12px;font-weight:normal}.ngx-charts .tooltip-anchor{fill:#000}.ngx-charts .gridline-path{stroke:#ddd;stroke-width:1;fill:none}.ngx-charts .refline-path{stroke:#a8b2c7;stroke-width:1;stroke-dasharray:5;stroke-dashoffset:5}.ngx-charts .refline-label{font-size:9px}.ngx-charts .reference-area{fill-opacity:.05;fill:#000}.ngx-charts .gridline-path-dotted{stroke:#ddd;stroke-width:1;fill:none;stroke-dasharray:1,20;stroke-dashoffset:3}.ngx-charts .grid-panel rect{fill:none}.ngx-charts .grid-panel.odd rect{fill:#0000000d}\n", ".gauge .background-arc path{fill:#0000000d}.gauge .gauge-tick path{stroke:#666}.gauge .gauge-tick text{font-size:12px;fill:#666;font-weight:bold}.gauge .gauge-tick-large path{stroke-width:2px}.gauge .gauge-tick-small path{stroke-width:1px}\n"]
12388
13143
  },] }
12389
13144
  ];
12390
13145
  GaugeComponent.propDecorators = {
@@ -12421,6 +13176,8 @@
12421
13176
  this.select = new core.EventEmitter();
12422
13177
  this.activate = new core.EventEmitter();
12423
13178
  this.deactivate = new core.EventEmitter();
13179
+ this.placementTypes = exports.PlacementTypes;
13180
+ this.styleTypes = exports.StyleTypes;
12424
13181
  }
12425
13182
  GaugeArcComponent.prototype.tooltipText = function (arc) {
12426
13183
  var label = formatLabel(arc.data.name);
@@ -12438,7 +13195,7 @@
12438
13195
  GaugeArcComponent.decorators = [
12439
13196
  { type: core.Component, args: [{
12440
13197
  selector: 'g[ngx-charts-gauge-arc]',
12441
- template: "\n <svg:g\n ngx-charts-pie-arc\n class=\"background-arc\"\n [startAngle]=\"0\"\n [endAngle]=\"backgroundArc.endAngle\"\n [innerRadius]=\"backgroundArc.innerRadius\"\n [outerRadius]=\"backgroundArc.outerRadius\"\n [cornerRadius]=\"cornerRadius\"\n [data]=\"backgroundArc.data\"\n [animate]=\"false\"\n [pointerEvents]=\"false\"\n ></svg:g>\n <svg:g\n ngx-charts-pie-arc\n [startAngle]=\"0\"\n [endAngle]=\"valueArc.endAngle\"\n [innerRadius]=\"valueArc.innerRadius\"\n [outerRadius]=\"valueArc.outerRadius\"\n [cornerRadius]=\"cornerRadius\"\n [fill]=\"colors.getColor(valueArc.data.name)\"\n [data]=\"valueArc.data\"\n [animate]=\"animations\"\n [isActive]=\"isActive\"\n (select)=\"select.emit($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"'top'\"\n [tooltipType]=\"'tooltip'\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(valueArc)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"valueArc.data\"\n ></svg:g>\n ",
13198
+ template: "\n <svg:g\n ngx-charts-pie-arc\n class=\"background-arc\"\n [startAngle]=\"0\"\n [endAngle]=\"backgroundArc.endAngle\"\n [innerRadius]=\"backgroundArc.innerRadius\"\n [outerRadius]=\"backgroundArc.outerRadius\"\n [cornerRadius]=\"cornerRadius\"\n [data]=\"backgroundArc.data\"\n [animate]=\"false\"\n [pointerEvents]=\"false\"\n ></svg:g>\n <svg:g\n ngx-charts-pie-arc\n [startAngle]=\"0\"\n [endAngle]=\"valueArc.endAngle\"\n [innerRadius]=\"valueArc.innerRadius\"\n [outerRadius]=\"valueArc.outerRadius\"\n [cornerRadius]=\"cornerRadius\"\n [fill]=\"colors.getColor(valueArc.data.name)\"\n [data]=\"valueArc.data\"\n [animate]=\"animations\"\n [isActive]=\"isActive\"\n (select)=\"select.emit($event)\"\n (activate)=\"activate.emit($event)\"\n (deactivate)=\"deactivate.emit($event)\"\n ngx-tooltip\n [tooltipDisabled]=\"tooltipDisabled\"\n [tooltipPlacement]=\"placementTypes.Top\"\n [tooltipType]=\"styleTypes.tooltip\"\n [tooltipTitle]=\"tooltipTemplate ? undefined : tooltipText(valueArc)\"\n [tooltipTemplate]=\"tooltipTemplate\"\n [tooltipContext]=\"valueArc.data\"\n ></svg:g>\n ",
12442
13199
  changeDetection: core.ChangeDetectionStrategy.OnPush
12443
13200
  },] }
12444
13201
  ];
@@ -12596,6 +13353,7 @@
12596
13353
  ChartCommonModule,
12597
13354
  AreaChartModule,
12598
13355
  BarChartModule,
13356
+ BoxChartModule,
12599
13357
  BubbleChartModule,
12600
13358
  HeatMapModule,
12601
13359
  LineChartModule,
@@ -12652,6 +13410,10 @@
12652
13410
  exports.BarVerticalNormalizedComponent = BarVerticalNormalizedComponent;
12653
13411
  exports.BarVerticalStackedComponent = BarVerticalStackedComponent;
12654
13412
  exports.BaseChartComponent = BaseChartComponent;
13413
+ exports.BoxChartComponent = BoxChartComponent;
13414
+ exports.BoxChartModule = BoxChartModule;
13415
+ exports.BoxComponent = BoxComponent;
13416
+ exports.BoxSeriesComponent = BoxSeriesComponent;
12655
13417
  exports.BubbleChartComponent = BubbleChartComponent;
12656
13418
  exports.BubbleChartModule = BubbleChartModule;
12657
13419
  exports.BubbleSeriesComponent = BubbleSeriesComponent;
@@ -12694,7 +13456,6 @@
12694
13456
  exports.PolarChartModule = PolarChartModule;
12695
13457
  exports.PolarSeriesComponent = PolarSeriesComponent;
12696
13458
  exports.ScaleLegendComponent = ScaleLegendComponent;
12697
- exports.ScaleType = exports.ɵc;
12698
13459
  exports.SeriesHorizontal = SeriesHorizontal;
12699
13460
  exports.SeriesVerticalComponent = SeriesVerticalComponent;
12700
13461
  exports.SvgLinearGradientComponent = SvgLinearGradientComponent;
@@ -12724,6 +13485,7 @@
12724
13485
  exports.getScale = getScale;
12725
13486
  exports.getScaleType = getScaleType;
12726
13487
  exports.getUniqueXDomainValues = getUniqueXDomainValues;
13488
+ exports.getXDomainArray = getXDomainArray;
12727
13489
  exports.gridLayout = gridLayout;
12728
13490
  exports.gridSize = gridSize;
12729
13491
  exports.hexToRgb = hexToRgb;