@carbon/charts 0.50.10 → 0.51.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 (87) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/build/src/charts/alluvial.d.ts +2 -0
  3. package/build/src/charts/bullet.d.ts +2 -0
  4. package/build/src/charts/radar.d.ts +3 -1
  5. package/build/src/charts/tree.d.ts +2 -0
  6. package/build/src/charts/treemap.d.ts +2 -0
  7. package/build/src/charts/wordcloud.d.ts +2 -0
  8. package/build/src/components/graphs/bullet.d.ts +0 -1
  9. package/build/src/model/alluvial.d.ts +8 -0
  10. package/build/src/model/boxplot.d.ts +1 -0
  11. package/build/src/model/bullet.d.ts +14 -0
  12. package/build/src/model/cartesian-charts.d.ts +0 -1
  13. package/build/src/model/circle-pack.d.ts +10 -0
  14. package/build/src/model/gauge.d.ts +4 -1
  15. package/build/src/model/meter.d.ts +1 -0
  16. package/build/src/model/model.d.ts +2 -0
  17. package/build/src/model/pie.d.ts +1 -0
  18. package/build/src/model/radar.d.ts +7 -0
  19. package/build/src/model/tree.d.ts +14 -0
  20. package/build/src/model/treemap.d.ts +8 -0
  21. package/build/src/model/wordcloud.d.ts +7 -0
  22. package/build/src/services/scales-cartesian.d.ts +1 -1
  23. package/bundle.js +1 -1
  24. package/chart.js +42 -20
  25. package/chart.js.map +1 -1
  26. package/charts/alluvial.d.ts +2 -0
  27. package/charts/alluvial.js +2 -0
  28. package/charts/alluvial.js.map +1 -1
  29. package/charts/bullet.d.ts +2 -0
  30. package/charts/bullet.js +2 -0
  31. package/charts/bullet.js.map +1 -1
  32. package/charts/radar.d.ts +3 -1
  33. package/charts/radar.js +3 -7
  34. package/charts/radar.js.map +1 -1
  35. package/charts/tree.d.ts +2 -0
  36. package/charts/tree.js +2 -0
  37. package/charts/tree.js.map +1 -1
  38. package/charts/treemap.d.ts +2 -0
  39. package/charts/treemap.js +2 -0
  40. package/charts/treemap.js.map +1 -1
  41. package/charts/wordcloud.d.ts +2 -0
  42. package/charts/wordcloud.js +3 -0
  43. package/charts/wordcloud.js.map +1 -1
  44. package/components/graphs/bullet.d.ts +0 -1
  45. package/components/graphs/bullet.js +1 -12
  46. package/components/graphs/bullet.js.map +1 -1
  47. package/model/alluvial.d.ts +8 -0
  48. package/model/alluvial.js +47 -0
  49. package/model/alluvial.js.map +1 -0
  50. package/model/boxplot.d.ts +1 -0
  51. package/model/boxplot.js +54 -0
  52. package/model/boxplot.js.map +1 -1
  53. package/model/bullet.d.ts +14 -0
  54. package/model/bullet.js +74 -0
  55. package/model/bullet.js.map +1 -0
  56. package/model/cartesian-charts.d.ts +0 -1
  57. package/model/cartesian-charts.js +0 -11
  58. package/model/cartesian-charts.js.map +1 -1
  59. package/model/circle-pack.d.ts +10 -0
  60. package/model/circle-pack.js +51 -0
  61. package/model/circle-pack.js.map +1 -1
  62. package/model/gauge.d.ts +4 -1
  63. package/model/gauge.js +24 -1
  64. package/model/gauge.js.map +1 -1
  65. package/model/meter.d.ts +1 -0
  66. package/model/meter.js +40 -0
  67. package/model/meter.js.map +1 -1
  68. package/model/model.d.ts +2 -0
  69. package/model/model.js +14 -0
  70. package/model/model.js.map +1 -1
  71. package/model/pie.d.ts +1 -0
  72. package/model/pie.js +21 -0
  73. package/model/pie.js.map +1 -1
  74. package/model/radar.d.ts +7 -0
  75. package/model/radar.js +52 -0
  76. package/model/radar.js.map +1 -0
  77. package/model/tree.d.ts +14 -0
  78. package/model/tree.js +56 -0
  79. package/model/tree.js.map +1 -0
  80. package/model/treemap.d.ts +8 -0
  81. package/model/treemap.js +37 -0
  82. package/model/treemap.js.map +1 -0
  83. package/model/wordcloud.d.ts +7 -0
  84. package/model/wordcloud.js +47 -0
  85. package/model/wordcloud.js.map +1 -0
  86. package/package.json +1 -1
  87. package/tsconfig.tsbuildinfo +139 -30
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [0.51.0](https://github.com/carbon-design-system/carbon-charts/compare/v0.50.10...v0.51.0) (2021-11-01)
7
+
8
+
9
+ ### Features
10
+
11
+ * **core:** add toolbar to non-cartesian charts ([#1191](https://github.com/carbon-design-system/carbon-charts/issues/1191)) ([3574f4f](https://github.com/carbon-design-system/carbon-charts/commit/3574f4f376cc064e0f58de14c61d6442c527aa17))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [0.50.10](https://github.com/carbon-design-system/carbon-charts/compare/v0.50.9...v0.50.10) (2021-10-27)
7
18
 
8
19
 
@@ -1,6 +1,8 @@
1
1
  import { Chart } from '../chart';
2
+ import { AlluvialChartModel } from '../model/alluvial';
2
3
  import { ChartConfig, AlluvialChartOptions } from '../interfaces/index';
3
4
  export declare class AlluvialChart extends Chart {
5
+ model: AlluvialChartModel;
4
6
  constructor(holder: Element, chartConfigs: ChartConfig<AlluvialChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -1,6 +1,8 @@
1
1
  import { AxisChart } from '../axis-chart';
2
+ import { BulletChartModel } from '../model/bullet';
2
3
  import { ChartConfig, BulletChartOptions } from '../interfaces/index';
3
4
  export declare class BulletChart extends AxisChart {
5
+ model: BulletChartModel;
4
6
  constructor(holder: Element, chartConfigs: ChartConfig<BulletChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -1,6 +1,8 @@
1
+ import { RadarChartModel } from '../model/radar';
1
2
  import { Chart } from '../chart';
2
3
  import { ChartConfig, RadarChartOptions } from '../interfaces/index';
3
4
  export declare class RadarChart extends Chart {
4
- constructor(holder: Element, chartConfigs: ChartConfig<RadarChartOptions>, extending?: boolean);
5
+ model: RadarChartModel;
6
+ constructor(holder: Element, chartConfigs: ChartConfig<RadarChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -1,6 +1,8 @@
1
1
  import { Chart } from '../chart';
2
+ import { TreeChartModel } from '../model/tree';
2
3
  import { ChartConfig, TreeChartOptions } from '../interfaces/index';
3
4
  export declare class TreeChart extends Chart {
5
+ model: TreeChartModel;
4
6
  constructor(holder: Element, chartConfigs: ChartConfig<TreeChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -1,6 +1,8 @@
1
1
  import { Chart } from '../chart';
2
+ import { TreemapChartModel } from '../model/treemap';
2
3
  import { ChartConfig, TreemapChartOptions } from '../interfaces/index';
3
4
  export declare class TreemapChart extends Chart {
5
+ model: TreemapChartModel;
4
6
  constructor(holder: Element, chartConfigs: ChartConfig<TreemapChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -1,6 +1,8 @@
1
+ import { WordCloudModel } from '../model/wordcloud';
1
2
  import { Chart } from '../chart';
2
3
  import { ChartConfig, WorldCloudChartOptions } from '../interfaces/index';
3
4
  export declare class WordCloudChart extends Chart {
5
+ model: WordCloudModel;
4
6
  constructor(holder: Element, chartConfigs: ChartConfig<WorldCloudChartOptions>);
5
7
  getComponents(): any[];
6
8
  }
@@ -7,7 +7,6 @@ export declare class Bullet extends Component {
7
7
  render(animate: boolean): void;
8
8
  handleLegendOnHover: (event: CustomEvent<any>) => void;
9
9
  handleLegendMouseOut: (event: CustomEvent<any>) => void;
10
- getMatchingRangeIndexForDatapoint(datum: any): any;
11
10
  addEventListeners(): void;
12
11
  destroy(): void;
13
12
  }
@@ -0,0 +1,8 @@
1
+ import { ChartModelCartesian } from './cartesian-charts';
2
+ /**
3
+ * Alluvial chart model layer
4
+ */
5
+ export declare class AlluvialChartModel extends ChartModelCartesian {
6
+ constructor(services: any);
7
+ getTabularDataArray(): any[];
8
+ }
@@ -9,5 +9,6 @@ export declare class BoxplotChartModel extends ChartModelCartesian {
9
9
  q_75: number;
10
10
  };
11
11
  getBoxplotData(): any[];
12
+ getTabularDataArray(): any[][];
12
13
  protected setColorClassNames(): void;
13
14
  }
@@ -0,0 +1,14 @@
1
+ import { ChartModelCartesian } from './cartesian-charts';
2
+ /**
3
+ * Bullet chart model layer
4
+ */
5
+ export declare class BulletChartModel extends ChartModelCartesian {
6
+ constructor(services: any);
7
+ /**
8
+ * Determines the index of the performance area titles to use
9
+ * @param datum
10
+ * @returns number
11
+ */
12
+ getMatchingRangeIndexForDatapoint(datum: any): any;
13
+ getTabularDataArray(): any[];
14
+ }
@@ -6,7 +6,6 @@ export declare class ChartModelCartesian extends ChartModel {
6
6
  constructor(services: any);
7
7
  private assignRangeAndDomains;
8
8
  getTabularDataArray(): any[];
9
- exportToCSV(): void;
10
9
  setData(newData: any): any;
11
10
  /**
12
11
  * @param zoomBarData any special zoom bar data to use instead of the model data
@@ -23,4 +23,14 @@ export declare class CirclePackChartModel extends ChartModel {
23
23
  hasParentNode(): boolean;
24
24
  setDataGroups(): void;
25
25
  protected setChildrenDataGroup(node: any, name: any): any;
26
+ getTabularDataArray(): string[][];
27
+ /**
28
+ * Recursively determine the relationship between all the nested elements in the child
29
+ * @param children: Object
30
+ * @param parent: String
31
+ * @param result: Array<Object>
32
+ * @param totalSum: number
33
+ * @returns: number
34
+ */
35
+ private getChildrenDatums;
26
36
  }
@@ -1,6 +1,9 @@
1
1
  import { ChartModel } from './model';
2
- /** The gauge chart model layer */
2
+ /**
3
+ * The gauge chart model layer
4
+ */
3
5
  export declare class GaugeChartModel extends ChartModel {
4
6
  constructor(services: any);
5
7
  getDataGroups(): any;
8
+ getTabularDataArray(): any[];
6
9
  }
@@ -15,4 +15,5 @@ export declare class MeterChartModel extends ChartModel {
15
15
  * Get the associated status for the data by checking the ranges
16
16
  */
17
17
  getStatus(): any;
18
+ getTabularDataArray(): any[];
18
19
  }
@@ -96,6 +96,8 @@ export declare class ChartModel {
96
96
  *
97
97
  */
98
98
  protected transformToTabularData(data: any): any[];
99
+ getTabularDataArray(): any[];
100
+ exportToCSV(): void;
99
101
  protected getTabularData(data: any): any[];
100
102
  protected sanitize(data: any): any;
101
103
  protected updateAllDataGroups(): void;
@@ -4,5 +4,6 @@ import { ChartModel } from './model';
4
4
  export declare class PieChartModel extends ChartModel {
5
5
  constructor(services: any);
6
6
  getTabularData(data: any): any[];
7
+ getTabularDataArray(): any[];
7
8
  sanitize(data: any): any[];
8
9
  }
@@ -0,0 +1,7 @@
1
+ import { ChartModelCartesian } from './cartesian-charts';
2
+ /** The charting model layer which includes mainly the chart data and options,
3
+ * as well as some misc. information to be shared among components */
4
+ export declare class RadarChartModel extends ChartModelCartesian {
5
+ constructor(services: any);
6
+ getTabularDataArray(): any[][];
7
+ }
@@ -0,0 +1,14 @@
1
+ import { ChartModel } from './model';
2
+ /**
3
+ * The tree chart model layer
4
+ */
5
+ export declare class TreeChartModel extends ChartModel {
6
+ constructor(services: any);
7
+ getTabularDataArray(): string[][];
8
+ /**
9
+ * Determine the child parent relationship in nested data
10
+ * @param datum: Object
11
+ * @param result: Array<Object>
12
+ */
13
+ private getChildrenDatums;
14
+ }
@@ -0,0 +1,8 @@
1
+ import { ChartModel } from './model';
2
+ /**
3
+ * The treemap chart model layer
4
+ */
5
+ export declare class TreemapChartModel extends ChartModel {
6
+ constructor(services: any);
7
+ getTabularDataArray(): string[][];
8
+ }
@@ -0,0 +1,7 @@
1
+ import { ChartModel } from './model';
2
+ /** The charting model layer which includes mainly the chart data and options,
3
+ * as well as some misc. information to be shared among components */
4
+ export declare class WordCloudModel extends ChartModel {
5
+ constructor(services: any);
6
+ getTabularDataArray(): any[];
7
+ }
@@ -57,7 +57,7 @@ export declare class CartesianScales extends Service {
57
57
  getMainYScaleType(): any;
58
58
  getDomainIdentifier(datum?: any): any;
59
59
  getRangeIdentifier(datum?: any): any;
60
- extendsDomain(axisPosition: AxisPositions, domain: any): Date[] | number[];
60
+ extendsDomain(axisPosition: AxisPositions, domain: any): number[] | Date[];
61
61
  protected findVerticalAxesPositions(): {
62
62
  primary: AxisPositions;
63
63
  secondary: AxisPositions;