@carbon/charts 0.41.60 → 0.41.64
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.
- package/CHANGELOG.md +31 -4
- package/axis-chart.js +2 -2
- package/axis-chart.js.map +1 -1
- package/build/demo/data/CHART_TYPES.d.ts +10 -0
- package/build/demo/data/bullet.d.ts +30 -0
- package/build/demo/data/circle-pack.d.ts +82 -0
- package/build/demo/data/index.d.ts +2 -0
- package/build/src/charts/bullet.d.ts +6 -0
- package/build/src/charts/circle-pack.d.ts +8 -0
- package/build/src/charts/index.d.ts +2 -0
- package/build/src/components/essentials/canvas-chart-clip.d.ts +6 -0
- package/build/src/components/graphs/bullet.d.ts +11 -0
- package/build/src/components/graphs/circle-pack.d.ts +17 -0
- package/build/src/components/index.d.ts +3 -0
- package/build/src/configuration-non-customizable.d.ts +39 -11
- package/build/src/configuration.d.ts +3 -1
- package/build/src/interfaces/axis-scales.d.ts +7 -0
- package/build/src/interfaces/charts.d.ts +23 -0
- package/build/src/interfaces/enums.d.ts +4 -2
- package/build/src/interfaces/events.d.ts +16 -0
- package/build/src/model-circle-pack.d.ts +26 -0
- package/build/src/services/canvas-zoom.d.ts +11 -0
- package/build/src/services/index.d.ts +1 -0
- package/bundle.js +1 -1
- package/chart.js +9 -3
- package/chart.js.map +1 -1
- package/charts/bullet.d.ts +6 -0
- package/charts/bullet.js +48 -0
- package/charts/bullet.js.map +1 -0
- package/charts/circle-pack.d.ts +8 -0
- package/charts/circle-pack.js +45 -0
- package/charts/circle-pack.js.map +1 -0
- package/charts/index.d.ts +2 -0
- package/charts/index.js +2 -0
- package/charts/index.js.map +1 -1
- package/components/axes/axis.js +5 -4
- package/components/axes/axis.js.map +1 -1
- package/components/axes/grid.js +2 -2
- package/components/axes/grid.js.map +1 -1
- package/components/essentials/canvas-chart-clip.d.ts +6 -0
- package/components/essentials/canvas-chart-clip.js +46 -0
- package/components/essentials/canvas-chart-clip.js.map +1 -0
- package/components/essentials/legend.js +39 -12
- package/components/essentials/legend.js.map +1 -1
- package/components/essentials/tooltip-axis.js +1 -1
- package/components/essentials/tooltip-axis.js.map +1 -1
- package/components/essentials/tooltip.js +6 -3
- package/components/essentials/tooltip.js.map +1 -1
- package/components/graphs/area-stacked.js +9 -6
- package/components/graphs/area-stacked.js.map +1 -1
- package/components/graphs/area.js +3 -1
- package/components/graphs/area.js.map +1 -1
- package/components/graphs/bar-simple.js +17 -3
- package/components/graphs/bar-simple.js.map +1 -1
- package/components/graphs/bar-stacked.js +1 -1
- package/components/graphs/bar-stacked.js.map +1 -1
- package/components/graphs/bubble.js +7 -6
- package/components/graphs/bubble.js.map +1 -1
- package/components/graphs/bullet.d.ts +11 -0
- package/components/graphs/bullet.js +360 -0
- package/components/graphs/bullet.js.map +1 -0
- package/components/graphs/circle-pack.d.ts +17 -0
- package/components/graphs/circle-pack.js +340 -0
- package/components/graphs/circle-pack.js.map +1 -0
- package/components/graphs/line.js +1 -1
- package/components/graphs/line.js.map +1 -1
- package/components/graphs/scatter-stacked.js +1 -1
- package/components/graphs/scatter-stacked.js.map +1 -1
- package/components/index.d.ts +3 -0
- package/components/index.js +3 -0
- package/components/index.js.map +1 -1
- package/configuration-non-customizable.d.ts +39 -11
- package/configuration-non-customizable.js +37 -13
- package/configuration-non-customizable.js.map +1 -1
- package/configuration.d.ts +3 -1
- package/configuration.js +27 -0
- package/configuration.js.map +1 -1
- package/demo/data/CHART_TYPES.d.ts +10 -0
- package/demo/data/CHART_TYPES.js +10 -0
- package/demo/data/CHART_TYPES.js.map +1 -1
- package/demo/data/bullet.d.ts +30 -0
- package/demo/data/bullet.js +75 -0
- package/demo/data/bullet.js.map +1 -0
- package/demo/data/bundle.js +1 -1
- package/demo/data/circle-pack.d.ts +82 -0
- package/demo/data/circle-pack.js +215 -0
- package/demo/data/circle-pack.js.map +1 -0
- package/demo/data/index.d.ts +2 -0
- package/demo/data/index.js +44 -5
- package/demo/data/index.js.map +1 -1
- package/demo/styles.css +308 -32
- package/demo/styles.css.map +1 -1
- package/demo/styles.min.css +1 -1
- package/demo/styles.min.css.map +1 -1
- package/demo/tsconfig.tsbuildinfo +32 -4
- package/interfaces/axis-scales.d.ts +7 -0
- package/interfaces/axis-scales.js.map +1 -1
- package/interfaces/charts.d.ts +23 -0
- package/interfaces/charts.js.map +1 -1
- package/interfaces/enums.d.ts +4 -2
- package/interfaces/enums.js +2 -0
- package/interfaces/enums.js.map +1 -1
- package/interfaces/events.d.ts +16 -0
- package/interfaces/events.js +18 -0
- package/interfaces/events.js.map +1 -1
- package/model-circle-pack.d.ts +26 -0
- package/model-circle-pack.js +137 -0
- package/model-circle-pack.js.map +1 -0
- package/package.json +1 -1
- package/services/canvas-zoom.d.ts +11 -0
- package/services/canvas-zoom.js +72 -0
- package/services/canvas-zoom.js.map +1 -0
- package/services/index.d.ts +1 -0
- package/services/index.js +1 -0
- package/services/index.js.map +1 -1
- package/services/scales-cartesian.js +13 -5
- package/services/scales-cartesian.js.map +1 -1
- package/styles/colors.scss +28 -0
- package/styles/components/_axis.scss +3 -1
- package/styles/components/_legend.scss +6 -0
- package/styles/components/_tooltip.scss +33 -10
- package/styles/graphs/_bullet.scss +67 -0
- package/styles/graphs/_circle-pack.scss +23 -0
- package/styles/graphs/index.scss +2 -0
- package/styles-g10.css +80 -8
- package/styles-g10.css.map +1 -1
- package/styles-g10.min.css +1 -1
- package/styles-g10.min.css.map +1 -1
- package/styles-g100.css +80 -8
- package/styles-g100.css.map +1 -1
- package/styles-g100.min.css +1 -1
- package/styles-g100.min.css.map +1 -1
- package/styles-g90.css +80 -8
- package/styles-g90.css.map +1 -1
- package/styles-g90.min.css +1 -1
- package/styles-g90.min.css.map +1 -1
- package/styles.css +80 -8
- package/styles.css.map +1 -1
- package/styles.min.css +1 -1
- package/styles.min.css.map +1 -1
- package/tsconfig.tsbuildinfo +212 -52
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
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.41.
|
|
6
|
+
## [0.41.64](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.63...v0.41.64) (2021-05-10)
|
|
7
7
|
|
|
8
8
|
**Note:** Version bump only for package @carbon/charts
|
|
9
9
|
|
|
@@ -11,7 +11,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
## [0.41.
|
|
14
|
+
## [0.41.63](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.62...v0.41.63) (2021-05-10)
|
|
15
15
|
|
|
16
16
|
**Note:** Version bump only for package @carbon/charts
|
|
17
17
|
|
|
@@ -19,21 +19,48 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
# Change Log
|
|
23
|
+
|
|
24
|
+
All notable changes to this project will be documented in this file. See
|
|
25
|
+
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
26
|
+
|
|
27
|
+
## [0.41.62](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.61...v0.41.62) (2021-04-29)
|
|
28
|
+
|
|
29
|
+
### Bug Fixes
|
|
30
|
+
|
|
31
|
+
- **core:** fix minor bug with data values that are undefined
|
|
32
|
+
([#1007](https://github.com/carbon-design-system/carbon-charts/issues/1007))
|
|
33
|
+
([5c4db99](https://github.com/carbon-design-system/carbon-charts/commit/5c4db996e3aaf5b8c8146b686945c9eb4a191b46))
|
|
34
|
+
|
|
35
|
+
# Change Log
|
|
36
|
+
|
|
37
|
+
All notable changes to this project will be documented in this file. See
|
|
38
|
+
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
39
|
+
|
|
40
|
+
## [0.41.61](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.60...v0.41.61) (2021-04-28)
|
|
23
41
|
|
|
24
42
|
**Note:** Version bump only for package @carbon/charts
|
|
25
43
|
|
|
44
|
+
# Change Log
|
|
26
45
|
|
|
46
|
+
All notable changes to this project will be documented in this file. See
|
|
47
|
+
[Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
27
48
|
|
|
49
|
+
## [0.41.60](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.59...v0.41.60) (2021-04-28)
|
|
28
50
|
|
|
51
|
+
**Note:** Version bump only for package @carbon/charts
|
|
29
52
|
|
|
30
|
-
## [0.41.
|
|
53
|
+
## [0.41.59](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.58...v0.41.59) (2021-04-27)
|
|
31
54
|
|
|
32
55
|
**Note:** Version bump only for package @carbon/charts
|
|
33
56
|
|
|
57
|
+
## [0.41.58](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.57...v0.41.58) (2021-04-26)
|
|
34
58
|
|
|
59
|
+
**Note:** Version bump only for package @carbon/charts
|
|
35
60
|
|
|
61
|
+
## [0.41.57](https://github.com/carbon-design-system/carbon-charts/compare/v0.41.56...v0.41.57) (2021-04-20)
|
|
36
62
|
|
|
63
|
+
**Note:** Version bump only for package @carbon/charts
|
|
37
64
|
|
|
38
65
|
# Change Log
|
|
39
66
|
|
package/axis-chart.js
CHANGED
|
@@ -88,7 +88,7 @@ var AxisChart = /** @class */ (function (_super) {
|
|
|
88
88
|
components: [new Legend(this.model, this.services)],
|
|
89
89
|
growth: {
|
|
90
90
|
x: LayoutGrowth.PREFERRED,
|
|
91
|
-
y: LayoutGrowth.
|
|
91
|
+
y: LayoutGrowth.PREFERRED,
|
|
92
92
|
},
|
|
93
93
|
};
|
|
94
94
|
// if all zoom bars are locked, no need to add chart brush
|
|
@@ -101,7 +101,7 @@ var AxisChart = /** @class */ (function (_super) {
|
|
|
101
101
|
components: graphFrameComponents,
|
|
102
102
|
growth: {
|
|
103
103
|
x: LayoutGrowth.STRETCH,
|
|
104
|
-
y: LayoutGrowth.
|
|
104
|
+
y: LayoutGrowth.STRETCH,
|
|
105
105
|
},
|
|
106
106
|
};
|
|
107
107
|
var isLegendEnabled = Tools.getProperty(configs, 'legend', 'enabled') !== false &&
|
package/axis-chart.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"axis-chart.js","sourceRoot":"","sources":["axis-chart.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EACN,eAAe,EACf,YAAY,EACZ,kBAAkB,EAClB,eAAe,EAGf,aAAa,EACb,UAAU,GACV,MAAM,cAAc,CAAC;AACtB,OAAO,EACN,UAAU,EACV,SAAS,EACT,eAAe,EACf,MAAM,EACN,SAAS,EACT,KAAK,EACL,iBAAiB,EACjB,MAAM,EACN,OAAO,EACP,OAAO,GACP,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAEhC,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAE3D;IAA+B,6BAAK;IAQnC,mBAAY,MAAe,EAAE,YAA2C;QAAxE,YACC,kBAAM,MAAM,EAAE,YAAY,CAAC,SAC3B;QATD,cAAQ,GAAQ,MAAM,CAAC,MAAM,CAAC,KAAI,CAAC,QAAQ,EAAE;YAC5C,eAAe,EAAE,eAAe;YAChC,MAAM,EAAE,MAAM;YACd,IAAI,EAAE,IAAI;SACV,CAAC,CAAC;QACH,WAAK,GAAwB,IAAI,mBAAmB,CAAC,KAAI,CAAC,QAAQ,CAAC,CAAC;;IAIpE,CAAC;IAES,0CAAsB,GAAhC,UACC,oBAA2B,EAC3B,OAAgB;QAEhB,IAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC;QACxC,IAAM,gBAAgB,GAAG,KAAK,CA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BACX,IAAI,MAAM,CACT,IAAI,CAAC,KAAK,EACV,IAAI,CAAC,QAAQ,EACb,cAAc,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC,SAAS,CACzC;iBACD;gBACD,MAAM,EAAE;oBACP,CAAC,EAAE,YAAY,CAAC,SAAS;oBACzB,CAAC,EAAE,YAAY,CAAC,KAAK;iBACrB;aACD,CAAC;YAEF,wBAAwB,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC;SACpD;QACD,IAAI,cAAc,EAAE;YACnB,wBAAwB,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;SAChD;QACD,wBAAwB,CAAC,IAAI,CAAC,kBAAkB,CAAC,CAAC;QAElD,OAAO;YACN,IAAI,iBAAiB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC;YAChD,IAAI,eAAe,CAClB,IAAI,CAAC,KAAK,EACV,IAAI,CAAC,QAAQ,EACb,wBAAwB,EACxB;gBACC,SAAS,EAAE,eAAe,CAAC,MAAM;aACjC,CACD;SACD,CAAC;IACH,CAAC;IACF,gBAAC;AAAD,CAAC,AAlOD,CAA+B,KAAK,GAkOnC","sourcesContent":["import { Chart } from './chart';\nimport { ChartModelCartesian } from './model-cartesian-charts';\nimport {\n\tLayoutDirection,\n\tLayoutGrowth,\n\tLegendOrientations,\n\tLegendPositions,\n\tChartConfig,\n\tAxisChartOptions,\n\tAxisPositions,\n\tScaleTypes,\n} from './interfaces';\nimport {\n\tChartBrush,\n\tChartClip,\n\tLayoutComponent,\n\tLegend,\n\tThreshold,\n\tTitle,\n\tAxisChartsTooltip,\n\tSpacer,\n\tToolbar,\n\tZoomBar,\n} from './components';\nimport { Tools } from './tools';\n\nimport { CartesianScales, Curves, Zoom } from './services';\n\nexport class AxisChart extends Chart {\n\tservices: any = Object.assign(this.services, {\n\t\tcartesianScales: CartesianScales,\n\t\tcurves: Curves,\n\t\tzoom: Zoom,\n\t});\n\tmodel: ChartModelCartesian = new ChartModelCartesian(this.services);\n\n\tconstructor(holder: Element, chartConfigs: ChartConfig<AxisChartOptions>) {\n\t\tsuper(holder, chartConfigs);\n\t}\n\n\tprotected getAxisChartComponents(\n\t\tgraphFrameComponents: any[],\n\t\tconfigs?: object\n\t) {\n\t\tconst options = this.model.getOptions();\n\t\tconst isZoomBarEnabled = Tools.getProperty(\n\t\t\toptions,\n\t\t\t'zoomBar',\n\t\t\tAxisPositions.TOP,\n\t\t\t'enabled'\n\t\t);\n\t\tconst toolbarEnabled = Tools.getProperty(options, 'toolbar', 'enabled');\n\n\t\tthis.services.cartesianScales.determineAxisDuality();\n\t\tthis.services.cartesianScales.findDomainAndRangeAxes(); // need to do this before getMainXAxisPosition()\n\t\tthis.services.cartesianScales.determineOrientation();\n\n\t\tconst mainXAxisPosition = this.services.cartesianScales.getMainXAxisPosition();\n\t\tconst mainXScaleType = Tools.getProperty(\n\t\t\toptions,\n\t\t\t'axes',\n\t\t\tmainXAxisPosition,\n\t\t\t'scaleType'\n\t\t);\n\t\t// @todo - Zoom Bar only supports main axis at BOTTOM axis and time scale for now\n\t\tconst zoomBarEnabled =\n\t\t\tisZoomBarEnabled &&\n\t\t\tmainXAxisPosition === AxisPositions.BOTTOM &&\n\t\t\tmainXScaleType === ScaleTypes.TIME;\n\n\t\t// @todo - should check if zoom bar in all axes are locked\n\t\tconst isZoomBarLocked = this.services.zoom.isZoomBarLocked(\n\t\t\tAxisPositions.TOP\n\t\t);\n\n\t\tconst titleAvailable = !!this.model.getOptions().title;\n\t\tconst titleComponent = {\n\t\t\tid: 'title',\n\t\t\tcomponents: [new Title(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst toolbarComponent = {\n\t\t\tid: 'toolbar',\n\t\t\tcomponents: [new Toolbar(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst headerComponent = {\n\t\t\tid: 'header',\n\t\t\tcomponents: [\n\t\t\t\tnew LayoutComponent(\n\t\t\t\t\tthis.model,\n\t\t\t\t\tthis.services,\n\t\t\t\t\t[\n\t\t\t\t\t\t// always add title to keep layout correct\n\t\t\t\t\t\ttitleComponent,\n\t\t\t\t\t\t...(toolbarEnabled ? [toolbarComponent] : []),\n\t\t\t\t\t],\n\t\t\t\t\t{\n\t\t\t\t\t\tdirection: LayoutDirection.ROW,\n\t\t\t\t\t}\n\t\t\t\t),\n\t\t\t],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst legendComponent = {\n\t\t\tid: 'legend',\n\t\t\tcomponents: [new Legend(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\t// if all zoom bars are locked, no need to add chart brush\n\t\tif (zoomBarEnabled && !isZoomBarLocked) {\n\t\t\tgraphFrameComponents.push(\n\t\t\t\tnew ChartClip(this.model, this.services),\n\t\t\t\tnew ChartBrush(this.model, this.services)\n\t\t\t);\n\t\t}\n\n\t\tgraphFrameComponents.push(new Threshold(this.model, this.services));\n\n\t\tconst graphFrameComponent = {\n\t\t\tid: 'graph-frame',\n\t\t\tcomponents: graphFrameComponents,\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst isLegendEnabled =\n\t\t\tTools.getProperty(configs, 'legend', 'enabled') !== false &&\n\t\t\tthis.model.getOptions().legend.enabled !== false;\n\n\t\t// Decide the position of the legend in reference to the chart\n\t\tlet fullFrameComponentDirection = LayoutDirection.COLUMN;\n\t\tif (isLegendEnabled) {\n\t\t\tconst legendPosition = Tools.getProperty(\n\t\t\t\tthis.model.getOptions(),\n\t\t\t\t'legend',\n\t\t\t\t'position'\n\t\t\t);\n\t\t\tif (legendPosition === LegendPositions.LEFT) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.ROW;\n\n\t\t\t\tif (!this.model.getOptions().legend.orientation) {\n\t\t\t\t\tthis.model.getOptions().legend.orientation =\n\t\t\t\t\t\tLegendOrientations.VERTICAL;\n\t\t\t\t}\n\t\t\t} else if (legendPosition === LegendPositions.RIGHT) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.ROW_REVERSE;\n\n\t\t\t\tif (!this.model.getOptions().legend.orientation) {\n\t\t\t\t\tthis.model.getOptions().legend.orientation =\n\t\t\t\t\t\tLegendOrientations.VERTICAL;\n\t\t\t\t}\n\t\t\t} else if (legendPosition === LegendPositions.BOTTOM) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.COLUMN_REVERSE;\n\t\t\t}\n\t\t}\n\n\t\tconst legendSpacerComponent = {\n\t\t\tid: 'spacer',\n\t\t\tcomponents: [new Spacer(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst fullFrameComponent = {\n\t\t\tid: 'full-frame',\n\t\t\tcomponents: [\n\t\t\t\tnew LayoutComponent(\n\t\t\t\t\tthis.model,\n\t\t\t\t\tthis.services,\n\t\t\t\t\t[\n\t\t\t\t\t\t...(isLegendEnabled ? [legendComponent] : []),\n\t\t\t\t\t\t...(isLegendEnabled ? [legendSpacerComponent] : []),\n\t\t\t\t\t\tgraphFrameComponent,\n\t\t\t\t\t],\n\t\t\t\t\t{\n\t\t\t\t\t\tdirection: fullFrameComponentDirection,\n\t\t\t\t\t}\n\t\t\t\t),\n\t\t\t],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst zoomBarComponent = {\n\t\t\tid: 'zoom-bar',\n\t\t\tcomponents: [new ZoomBar(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst topLevelLayoutComponents = [];\n\t\t// header component is required for either title or toolbar\n\t\tif (titleAvailable || toolbarEnabled) {\n\t\t\ttopLevelLayoutComponents.push(headerComponent);\n\n\t\t\tconst titleSpacerComponent = {\n\t\t\t\tid: 'spacer',\n\t\t\t\tcomponents: [\n\t\t\t\t\tnew Spacer(\n\t\t\t\t\t\tthis.model,\n\t\t\t\t\t\tthis.services,\n\t\t\t\t\t\ttoolbarEnabled ? { size: 15 } : undefined\n\t\t\t\t\t),\n\t\t\t\t],\n\t\t\t\tgrowth: {\n\t\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t\t},\n\t\t\t};\n\n\t\t\ttopLevelLayoutComponents.push(titleSpacerComponent);\n\t\t}\n\t\tif (zoomBarEnabled) {\n\t\t\ttopLevelLayoutComponents.push(zoomBarComponent);\n\t\t}\n\t\ttopLevelLayoutComponents.push(fullFrameComponent);\n\n\t\treturn [\n\t\t\tnew AxisChartsTooltip(this.model, this.services),\n\t\t\tnew LayoutComponent(\n\t\t\t\tthis.model,\n\t\t\t\tthis.services,\n\t\t\t\ttopLevelLayoutComponents,\n\t\t\t\t{\n\t\t\t\t\tdirection: LayoutDirection.COLUMN,\n\t\t\t\t}\n\t\t\t),\n\t\t];\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"file":"axis-chart.js","sourceRoot":"","sources":["axis-chart.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAA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AAoB,CAAC,CAAC;SACpD;QACD,IAAI,cAAc,EAAE;YACnB,wBAAwB,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;SAChD;QACD,wBAAwB,CAAC,IAAI,CAAC,kBAAkB,CAAC,CAAC;QAElD,OAAO;YACN,IAAI,iBAAiB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC;YAChD,IAAI,eAAe,CAClB,IAAI,CAAC,KAAK,EACV,IAAI,CAAC,QAAQ,EACb,wBAAwB,EACxB;gBACC,SAAS,EAAE,eAAe,CAAC,MAAM;aACjC,CACD;SACD,CAAC;IACH,CAAC;IACF,gBAAC;AAAD,CAAC,AAlOD,CAA+B,KAAK,GAkOnC","sourcesContent":["import { Chart } from './chart';\nimport { ChartModelCartesian } from './model-cartesian-charts';\nimport {\n\tLayoutDirection,\n\tLayoutGrowth,\n\tLegendOrientations,\n\tLegendPositions,\n\tChartConfig,\n\tAxisChartOptions,\n\tAxisPositions,\n\tScaleTypes,\n} from './interfaces';\nimport {\n\tChartBrush,\n\tChartClip,\n\tLayoutComponent,\n\tLegend,\n\tThreshold,\n\tTitle,\n\tAxisChartsTooltip,\n\tSpacer,\n\tToolbar,\n\tZoomBar,\n} from './components';\nimport { Tools } from './tools';\n\nimport { CartesianScales, Curves, Zoom } from './services';\n\nexport class AxisChart extends Chart {\n\tservices: any = Object.assign(this.services, {\n\t\tcartesianScales: CartesianScales,\n\t\tcurves: Curves,\n\t\tzoom: Zoom,\n\t});\n\tmodel: ChartModelCartesian = new ChartModelCartesian(this.services);\n\n\tconstructor(holder: Element, chartConfigs: ChartConfig<AxisChartOptions>) {\n\t\tsuper(holder, chartConfigs);\n\t}\n\n\tprotected getAxisChartComponents(\n\t\tgraphFrameComponents: any[],\n\t\tconfigs?: object\n\t) {\n\t\tconst options = this.model.getOptions();\n\t\tconst isZoomBarEnabled = Tools.getProperty(\n\t\t\toptions,\n\t\t\t'zoomBar',\n\t\t\tAxisPositions.TOP,\n\t\t\t'enabled'\n\t\t);\n\t\tconst toolbarEnabled = Tools.getProperty(options, 'toolbar', 'enabled');\n\n\t\tthis.services.cartesianScales.determineAxisDuality();\n\t\tthis.services.cartesianScales.findDomainAndRangeAxes(); // need to do this before getMainXAxisPosition()\n\t\tthis.services.cartesianScales.determineOrientation();\n\n\t\tconst mainXAxisPosition = this.services.cartesianScales.getMainXAxisPosition();\n\t\tconst mainXScaleType = Tools.getProperty(\n\t\t\toptions,\n\t\t\t'axes',\n\t\t\tmainXAxisPosition,\n\t\t\t'scaleType'\n\t\t);\n\t\t// @todo - Zoom Bar only supports main axis at BOTTOM axis and time scale for now\n\t\tconst zoomBarEnabled =\n\t\t\tisZoomBarEnabled &&\n\t\t\tmainXAxisPosition === AxisPositions.BOTTOM &&\n\t\t\tmainXScaleType === ScaleTypes.TIME;\n\n\t\t// @todo - should check if zoom bar in all axes are locked\n\t\tconst isZoomBarLocked = this.services.zoom.isZoomBarLocked(\n\t\t\tAxisPositions.TOP\n\t\t);\n\n\t\tconst titleAvailable = !!this.model.getOptions().title;\n\t\tconst titleComponent = {\n\t\t\tid: 'title',\n\t\t\tcomponents: [new Title(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst toolbarComponent = {\n\t\t\tid: 'toolbar',\n\t\t\tcomponents: [new Toolbar(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst headerComponent = {\n\t\t\tid: 'header',\n\t\t\tcomponents: [\n\t\t\t\tnew LayoutComponent(\n\t\t\t\t\tthis.model,\n\t\t\t\t\tthis.services,\n\t\t\t\t\t[\n\t\t\t\t\t\t// always add title to keep layout correct\n\t\t\t\t\t\ttitleComponent,\n\t\t\t\t\t\t...(toolbarEnabled ? [toolbarComponent] : []),\n\t\t\t\t\t],\n\t\t\t\t\t{\n\t\t\t\t\t\tdirection: LayoutDirection.ROW,\n\t\t\t\t\t}\n\t\t\t\t),\n\t\t\t],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst legendComponent = {\n\t\t\tid: 'legend',\n\t\t\tcomponents: [new Legend(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.PREFERRED,\n\t\t\t},\n\t\t};\n\n\t\t// if all zoom bars are locked, no need to add chart brush\n\t\tif (zoomBarEnabled && !isZoomBarLocked) {\n\t\t\tgraphFrameComponents.push(\n\t\t\t\tnew ChartClip(this.model, this.services),\n\t\t\t\tnew ChartBrush(this.model, this.services)\n\t\t\t);\n\t\t}\n\n\t\tgraphFrameComponents.push(new Threshold(this.model, this.services));\n\n\t\tconst graphFrameComponent = {\n\t\t\tid: 'graph-frame',\n\t\t\tcomponents: graphFrameComponents,\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.STRETCH,\n\t\t\t},\n\t\t};\n\n\t\tconst isLegendEnabled =\n\t\t\tTools.getProperty(configs, 'legend', 'enabled') !== false &&\n\t\t\tthis.model.getOptions().legend.enabled !== false;\n\n\t\t// Decide the position of the legend in reference to the chart\n\t\tlet fullFrameComponentDirection = LayoutDirection.COLUMN;\n\t\tif (isLegendEnabled) {\n\t\t\tconst legendPosition = Tools.getProperty(\n\t\t\t\tthis.model.getOptions(),\n\t\t\t\t'legend',\n\t\t\t\t'position'\n\t\t\t);\n\t\t\tif (legendPosition === LegendPositions.LEFT) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.ROW;\n\n\t\t\t\tif (!this.model.getOptions().legend.orientation) {\n\t\t\t\t\tthis.model.getOptions().legend.orientation =\n\t\t\t\t\t\tLegendOrientations.VERTICAL;\n\t\t\t\t}\n\t\t\t} else if (legendPosition === LegendPositions.RIGHT) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.ROW_REVERSE;\n\n\t\t\t\tif (!this.model.getOptions().legend.orientation) {\n\t\t\t\t\tthis.model.getOptions().legend.orientation =\n\t\t\t\t\t\tLegendOrientations.VERTICAL;\n\t\t\t\t}\n\t\t\t} else if (legendPosition === LegendPositions.BOTTOM) {\n\t\t\t\tfullFrameComponentDirection = LayoutDirection.COLUMN_REVERSE;\n\t\t\t}\n\t\t}\n\n\t\tconst legendSpacerComponent = {\n\t\t\tid: 'spacer',\n\t\t\tcomponents: [new Spacer(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst fullFrameComponent = {\n\t\t\tid: 'full-frame',\n\t\t\tcomponents: [\n\t\t\t\tnew LayoutComponent(\n\t\t\t\t\tthis.model,\n\t\t\t\t\tthis.services,\n\t\t\t\t\t[\n\t\t\t\t\t\t...(isLegendEnabled ? [legendComponent] : []),\n\t\t\t\t\t\t...(isLegendEnabled ? [legendSpacerComponent] : []),\n\t\t\t\t\t\tgraphFrameComponent,\n\t\t\t\t\t],\n\t\t\t\t\t{\n\t\t\t\t\t\tdirection: fullFrameComponentDirection,\n\t\t\t\t\t}\n\t\t\t\t),\n\t\t\t],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.STRETCH,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst zoomBarComponent = {\n\t\t\tid: 'zoom-bar',\n\t\t\tcomponents: [new ZoomBar(this.model, this.services)],\n\t\t\tgrowth: {\n\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t},\n\t\t};\n\n\t\tconst topLevelLayoutComponents = [];\n\t\t// header component is required for either title or toolbar\n\t\tif (titleAvailable || toolbarEnabled) {\n\t\t\ttopLevelLayoutComponents.push(headerComponent);\n\n\t\t\tconst titleSpacerComponent = {\n\t\t\t\tid: 'spacer',\n\t\t\t\tcomponents: [\n\t\t\t\t\tnew Spacer(\n\t\t\t\t\t\tthis.model,\n\t\t\t\t\t\tthis.services,\n\t\t\t\t\t\ttoolbarEnabled ? { size: 15 } : undefined\n\t\t\t\t\t),\n\t\t\t\t],\n\t\t\t\tgrowth: {\n\t\t\t\t\tx: LayoutGrowth.PREFERRED,\n\t\t\t\t\ty: LayoutGrowth.FIXED,\n\t\t\t\t},\n\t\t\t};\n\n\t\t\ttopLevelLayoutComponents.push(titleSpacerComponent);\n\t\t}\n\t\tif (zoomBarEnabled) {\n\t\t\ttopLevelLayoutComponents.push(zoomBarComponent);\n\t\t}\n\t\ttopLevelLayoutComponents.push(fullFrameComponent);\n\n\t\treturn [\n\t\t\tnew AxisChartsTooltip(this.model, this.services),\n\t\t\tnew LayoutComponent(\n\t\t\t\tthis.model,\n\t\t\t\tthis.services,\n\t\t\t\ttopLevelLayoutComponents,\n\t\t\t\t{\n\t\t\t\t\tdirection: LayoutDirection.COLUMN,\n\t\t\t\t}\n\t\t\t),\n\t\t];\n\t}\n}\n"]}
|
|
@@ -14,6 +14,16 @@ declare const _default: {
|
|
|
14
14
|
angular: string;
|
|
15
15
|
vue: string;
|
|
16
16
|
};
|
|
17
|
+
CirclePackChart: {
|
|
18
|
+
vanilla: string;
|
|
19
|
+
angular: string;
|
|
20
|
+
vue: string;
|
|
21
|
+
};
|
|
22
|
+
BulletChart: {
|
|
23
|
+
vanilla: string;
|
|
24
|
+
angular: string;
|
|
25
|
+
vue: string;
|
|
26
|
+
};
|
|
17
27
|
ComboChart: {
|
|
18
28
|
vanilla: string;
|
|
19
29
|
angular: string;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export declare const basicBulletData: {
|
|
2
|
+
title: string;
|
|
3
|
+
group: string;
|
|
4
|
+
ranges: number[];
|
|
5
|
+
marker: number;
|
|
6
|
+
value: number;
|
|
7
|
+
}[];
|
|
8
|
+
export declare const basicBulletOptions: {
|
|
9
|
+
title: string;
|
|
10
|
+
axes: {
|
|
11
|
+
bottom: {
|
|
12
|
+
mapsTo: string;
|
|
13
|
+
extendLinearDomainBy: string;
|
|
14
|
+
};
|
|
15
|
+
left: {
|
|
16
|
+
scaleType: string;
|
|
17
|
+
mapsTo: string;
|
|
18
|
+
};
|
|
19
|
+
right: {
|
|
20
|
+
scaleType: string;
|
|
21
|
+
mapsTo: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
legend: {
|
|
25
|
+
additionalItems: {
|
|
26
|
+
type: string;
|
|
27
|
+
name: string;
|
|
28
|
+
}[];
|
|
29
|
+
};
|
|
30
|
+
};
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
export declare const circlePackTwoLevelData: {
|
|
2
|
+
name: string;
|
|
3
|
+
children: {
|
|
4
|
+
name: string;
|
|
5
|
+
value: number;
|
|
6
|
+
}[];
|
|
7
|
+
}[];
|
|
8
|
+
export declare const circlePackTwoLevelOptions: {
|
|
9
|
+
experimental: string;
|
|
10
|
+
title: string;
|
|
11
|
+
canvasZoom: {
|
|
12
|
+
enabled: boolean;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export declare const circlePackSingleOptions: {
|
|
16
|
+
experimental: string;
|
|
17
|
+
title: string;
|
|
18
|
+
canvasZoom: {
|
|
19
|
+
enabled: boolean;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
export declare const circlePackSingleLevelData: {
|
|
23
|
+
name: string;
|
|
24
|
+
value: number;
|
|
25
|
+
}[];
|
|
26
|
+
export declare const circlePackThreeLevelOptions: {
|
|
27
|
+
experimental: string;
|
|
28
|
+
title: string;
|
|
29
|
+
canvasZoom: {
|
|
30
|
+
enabled: boolean;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
export declare const circlePackThreeLevelData: {
|
|
34
|
+
name: string;
|
|
35
|
+
children: ({
|
|
36
|
+
name: string;
|
|
37
|
+
children: {
|
|
38
|
+
name: string;
|
|
39
|
+
value: number;
|
|
40
|
+
}[];
|
|
41
|
+
value?: undefined;
|
|
42
|
+
} | {
|
|
43
|
+
name: string;
|
|
44
|
+
value: number;
|
|
45
|
+
children?: undefined;
|
|
46
|
+
})[];
|
|
47
|
+
}[];
|
|
48
|
+
export declare const circlePackThreeLevelsMonochromeOptions: {
|
|
49
|
+
experimental: string;
|
|
50
|
+
title: string;
|
|
51
|
+
canvasZoom: {
|
|
52
|
+
enabled: boolean;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
export declare const circlePackThreeLevelsMonochromeData: {
|
|
56
|
+
name: string;
|
|
57
|
+
children: {
|
|
58
|
+
name: string;
|
|
59
|
+
children: ({
|
|
60
|
+
name: string;
|
|
61
|
+
children: {
|
|
62
|
+
name: string;
|
|
63
|
+
value: number;
|
|
64
|
+
}[];
|
|
65
|
+
value?: undefined;
|
|
66
|
+
} | {
|
|
67
|
+
name: string;
|
|
68
|
+
value: number;
|
|
69
|
+
children?: undefined;
|
|
70
|
+
})[];
|
|
71
|
+
}[];
|
|
72
|
+
}[];
|
|
73
|
+
export declare const circlePackThreeLevelNoZoomOptions: {
|
|
74
|
+
experimental: string;
|
|
75
|
+
title: string;
|
|
76
|
+
circlePack: {
|
|
77
|
+
hierarchyLevel: number;
|
|
78
|
+
};
|
|
79
|
+
canvasZoom: {
|
|
80
|
+
enabled: boolean;
|
|
81
|
+
};
|
|
82
|
+
};
|
|
@@ -2,6 +2,7 @@ export * from './area';
|
|
|
2
2
|
export * from './bar';
|
|
3
3
|
export * from './boxplot';
|
|
4
4
|
export * from './bubble';
|
|
5
|
+
export * from './bullet';
|
|
5
6
|
export * from './combo';
|
|
6
7
|
export * from './donut';
|
|
7
8
|
export * from './gauge';
|
|
@@ -14,6 +15,7 @@ export * from './scatter';
|
|
|
14
15
|
export * from './step';
|
|
15
16
|
export * from './time-series-axis';
|
|
16
17
|
export * from './treemap';
|
|
18
|
+
export * from './circle-pack';
|
|
17
19
|
export * from './toolbar';
|
|
18
20
|
export * from './wordcloud';
|
|
19
21
|
export * from './zoom-bar';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { AxisChart } from '../axis-chart';
|
|
2
|
+
import { ChartConfig, BulletChartOptions } from '../interfaces/index';
|
|
3
|
+
export declare class BulletChart extends AxisChart {
|
|
4
|
+
constructor(holder: Element, chartConfigs: ChartConfig<BulletChartOptions>);
|
|
5
|
+
getComponents(): any[];
|
|
6
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Chart } from '../chart';
|
|
2
|
+
import { CirclePackChartModel } from './../model-circle-pack';
|
|
3
|
+
import { ChartConfig, CirclePackChartOptions } from '../interfaces/index';
|
|
4
|
+
export declare class CirclePackChart extends Chart {
|
|
5
|
+
model: CirclePackChartModel;
|
|
6
|
+
constructor(holder: Element, chartConfigs: ChartConfig<CirclePackChartOptions>);
|
|
7
|
+
getComponents(): any[];
|
|
8
|
+
}
|
|
@@ -5,6 +5,7 @@ export * from './bar-grouped';
|
|
|
5
5
|
export * from './bar-stacked';
|
|
6
6
|
export * from './boxplot';
|
|
7
7
|
export * from './bubble';
|
|
8
|
+
export * from './bullet';
|
|
8
9
|
export * from './line';
|
|
9
10
|
export * from './lollipop';
|
|
10
11
|
export * from './scatter';
|
|
@@ -15,4 +16,5 @@ export * from './radar';
|
|
|
15
16
|
export * from './gauge';
|
|
16
17
|
export * from './combo';
|
|
17
18
|
export * from './treemap';
|
|
19
|
+
export * from './circle-pack';
|
|
18
20
|
export * from './wordcloud';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Component } from '../component';
|
|
2
|
+
export declare class Bullet extends Component {
|
|
3
|
+
type: string;
|
|
4
|
+
init(): void;
|
|
5
|
+
render(animate: boolean): void;
|
|
6
|
+
handleLegendOnHover: (event: CustomEvent<any>) => void;
|
|
7
|
+
handleLegendMouseOut: (event: CustomEvent<any>) => void;
|
|
8
|
+
getMatchingRangeIndexForDatapoint(datum: any): any;
|
|
9
|
+
addEventListeners(): void;
|
|
10
|
+
destroy(): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Component } from '../component';
|
|
2
|
+
export declare class CirclePack extends Component {
|
|
3
|
+
type: string;
|
|
4
|
+
focal: any;
|
|
5
|
+
render(animate?: boolean): void;
|
|
6
|
+
unhighlightChildren(childData: any): void;
|
|
7
|
+
highlightChildren(childData: any, classname?: any): void;
|
|
8
|
+
getZoomClass(node: any): "focal" | "non-focal";
|
|
9
|
+
addLegendListeners(): void;
|
|
10
|
+
removeBackgroundListeners(): void;
|
|
11
|
+
setBackgroundListeners(): void;
|
|
12
|
+
handleLegendOnHover: (event: CustomEvent<any>) => void;
|
|
13
|
+
handleLegendMouseOut: (event: CustomEvent<any>) => void;
|
|
14
|
+
getZoomIcon(): string;
|
|
15
|
+
addEventListeners(): void;
|
|
16
|
+
destroy(): void;
|
|
17
|
+
}
|
|
@@ -5,6 +5,7 @@ export * from './essentials/title';
|
|
|
5
5
|
export * from './essentials/title-meter';
|
|
6
6
|
export * from './essentials/tooltip';
|
|
7
7
|
export * from './essentials/tooltip-axis';
|
|
8
|
+
export * from './essentials/canvas-chart-clip';
|
|
8
9
|
export * from './graphs/area';
|
|
9
10
|
export * from './graphs/area-stacked';
|
|
10
11
|
export * from './graphs/bar-simple';
|
|
@@ -12,6 +13,7 @@ export * from './graphs/bar-grouped';
|
|
|
12
13
|
export * from './graphs/bar-stacked';
|
|
13
14
|
export * from './graphs/boxplot';
|
|
14
15
|
export * from './graphs/bubble';
|
|
16
|
+
export * from './graphs/bullet';
|
|
15
17
|
export * from './graphs/line';
|
|
16
18
|
export * from './graphs/lollipop';
|
|
17
19
|
export * from './graphs/scatter';
|
|
@@ -23,6 +25,7 @@ export * from './graphs/skeleton';
|
|
|
23
25
|
export * from './graphs/skeleton-lines';
|
|
24
26
|
export * from './graphs/treemap';
|
|
25
27
|
export * from './graphs/radar';
|
|
28
|
+
export * from './graphs/circle-pack';
|
|
26
29
|
export * from './graphs/wordcloud';
|
|
27
30
|
export * from './layout/spacer';
|
|
28
31
|
export * from './layout/layout';
|
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
import { ZoomBarTypes } from './interfaces';
|
|
2
|
-
|
|
3
|
-
pairingOptions: {
|
|
4
|
-
'1-color': number;
|
|
5
|
-
'2-color': number;
|
|
6
|
-
'3-color': number;
|
|
7
|
-
'4-color': number;
|
|
8
|
-
'5-color': number;
|
|
9
|
-
'14-color': number;
|
|
10
|
-
};
|
|
11
|
-
};
|
|
2
|
+
import { easeCubicInOut } from 'd3-ease';
|
|
12
3
|
export declare const area: {
|
|
13
4
|
opacity: {
|
|
14
5
|
unselected: number;
|
|
@@ -22,8 +13,37 @@ export declare const axis: {
|
|
|
22
13
|
verticalSpaceRatio: number;
|
|
23
14
|
horizontalSpaceRatio: number;
|
|
24
15
|
};
|
|
16
|
+
ratio: {
|
|
17
|
+
reference: string;
|
|
18
|
+
compareTo: string;
|
|
19
|
+
};
|
|
25
20
|
paddingRatio: number;
|
|
26
21
|
};
|
|
22
|
+
export declare const canvasZoomSettings: {
|
|
23
|
+
duration: number;
|
|
24
|
+
ease: typeof easeCubicInOut;
|
|
25
|
+
zoomLevel: number;
|
|
26
|
+
};
|
|
27
|
+
export declare const circlePack: {
|
|
28
|
+
circles: {
|
|
29
|
+
fillOpacity: number;
|
|
30
|
+
};
|
|
31
|
+
padding: {
|
|
32
|
+
mainGroup: number;
|
|
33
|
+
children: number;
|
|
34
|
+
};
|
|
35
|
+
hierarchyLevel: number;
|
|
36
|
+
};
|
|
37
|
+
export declare const color: {
|
|
38
|
+
pairingOptions: {
|
|
39
|
+
'1-color': number;
|
|
40
|
+
'2-color': number;
|
|
41
|
+
'3-color': number;
|
|
42
|
+
'4-color': number;
|
|
43
|
+
'5-color': number;
|
|
44
|
+
'14-color': number;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
27
47
|
export declare const boxplot: {
|
|
28
48
|
circle: {
|
|
29
49
|
radius: number;
|
|
@@ -93,9 +113,17 @@ export declare const legend: {
|
|
|
93
113
|
y: number;
|
|
94
114
|
width: number;
|
|
95
115
|
height: number;
|
|
96
|
-
color: string;
|
|
97
116
|
}[];
|
|
98
117
|
};
|
|
118
|
+
zoom: {
|
|
119
|
+
iconData: {
|
|
120
|
+
x: number;
|
|
121
|
+
y: number;
|
|
122
|
+
width: number;
|
|
123
|
+
height: number;
|
|
124
|
+
}[];
|
|
125
|
+
color: string;
|
|
126
|
+
};
|
|
99
127
|
};
|
|
100
128
|
export declare const lines: {
|
|
101
129
|
opacity: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseChartOptions, AxisChartOptions, ScatterChartOptions, LollipopChartOptions, LineChartOptions, BarChartOptions, StackedBarChartOptions, BoxplotChartOptions, AreaChartOptions, PieChartOptions, GaugeChartOptions, DonutChartOptions, BubbleChartOptions, RadarChartOptions, ComboChartOptions, TreemapChartOptions, WorldCloudChartOptions, GridOptions, RulerOptions, TimeScaleOptions, TooltipOptions, MeterChartOptions } from './interfaces';
|
|
1
|
+
import { BaseChartOptions, AxisChartOptions, ScatterChartOptions, LollipopChartOptions, LineChartOptions, BarChartOptions, StackedBarChartOptions, BoxplotChartOptions, AreaChartOptions, PieChartOptions, GaugeChartOptions, DonutChartOptions, BubbleChartOptions, BulletChartOptions, RadarChartOptions, ComboChartOptions, TreemapChartOptions, CirclePackChartOptions, WorldCloudChartOptions, GridOptions, RulerOptions, TimeScaleOptions, TooltipOptions, MeterChartOptions } from './interfaces';
|
|
2
2
|
/**
|
|
3
3
|
* Grid options
|
|
4
4
|
*/
|
|
@@ -20,6 +20,7 @@ export declare const options: {
|
|
|
20
20
|
stackedBarChart: StackedBarChartOptions;
|
|
21
21
|
boxplotChart: BoxplotChartOptions;
|
|
22
22
|
bubbleChart: BubbleChartOptions;
|
|
23
|
+
bulletChart: BulletChartOptions;
|
|
23
24
|
lineChart: LineChartOptions;
|
|
24
25
|
areaChart: AreaChartOptions;
|
|
25
26
|
stackedAreaChart: AreaChartOptions;
|
|
@@ -32,6 +33,7 @@ export declare const options: {
|
|
|
32
33
|
gaugeChart: GaugeChartOptions;
|
|
33
34
|
comboChart: ComboChartOptions;
|
|
34
35
|
treemapChart: TreemapChartOptions;
|
|
36
|
+
circlePackChart: CirclePackChartOptions;
|
|
35
37
|
wordCloudChart: WorldCloudChartOptions;
|
|
36
38
|
};
|
|
37
39
|
export * from './configuration-non-customizable';
|
|
@@ -28,6 +28,13 @@ export interface AxisOptions {
|
|
|
28
28
|
* No need to define domain for percentage axis scale
|
|
29
29
|
*/
|
|
30
30
|
domain?: AxisDomain[];
|
|
31
|
+
/**
|
|
32
|
+
* an additional key from the charting data that is used to
|
|
33
|
+
* extend the domain of an axis by
|
|
34
|
+
* (e.g. in the bullet graph we need both the marker &
|
|
35
|
+
* the data values to define the domain of the linear scale)
|
|
36
|
+
*/
|
|
37
|
+
extendLinearDomainBy?: string;
|
|
31
38
|
/**
|
|
32
39
|
* Whether the Axis should be forced to include 0 as a starting point
|
|
33
40
|
* (or ending point, in case of all negative axis).
|
|
@@ -181,6 +181,17 @@ export interface BubbleChartOptions extends AxisChartOptions {
|
|
|
181
181
|
enabled?: boolean;
|
|
182
182
|
};
|
|
183
183
|
}
|
|
184
|
+
/**
|
|
185
|
+
* options specific to bullet charts
|
|
186
|
+
*/
|
|
187
|
+
export interface BulletChartOptions extends AxisChartOptions {
|
|
188
|
+
/**
|
|
189
|
+
* options for the individual bullets
|
|
190
|
+
*/
|
|
191
|
+
bullet?: {
|
|
192
|
+
performanceAreaTitles?: string[];
|
|
193
|
+
};
|
|
194
|
+
}
|
|
184
195
|
/**
|
|
185
196
|
* options specific to line charts
|
|
186
197
|
*/
|
|
@@ -337,3 +348,15 @@ export interface ComboChartOptions extends AxisChartOptions {
|
|
|
337
348
|
}
|
|
338
349
|
export interface TreemapChartOptions extends BaseChartOptions {
|
|
339
350
|
}
|
|
351
|
+
export interface CirclePackChartOptions extends BaseChartOptions {
|
|
352
|
+
circlePack?: {
|
|
353
|
+
circles: {
|
|
354
|
+
fillOpacity: number;
|
|
355
|
+
};
|
|
356
|
+
hierachyLevel: number;
|
|
357
|
+
padding?: {
|
|
358
|
+
outer?: number;
|
|
359
|
+
inner?: number;
|
|
360
|
+
};
|
|
361
|
+
};
|
|
362
|
+
}
|
|
@@ -59,7 +59,8 @@ export declare enum ScaleTypes {
|
|
|
59
59
|
TIME = "time",
|
|
60
60
|
LINEAR = "linear",
|
|
61
61
|
LOG = "log",
|
|
62
|
-
LABELS = "labels"
|
|
62
|
+
LABELS = "labels",
|
|
63
|
+
LABELS_RATIO = "labels-ratio"
|
|
63
64
|
}
|
|
64
65
|
/**
|
|
65
66
|
* enum of all possible legend positions
|
|
@@ -197,5 +198,6 @@ export declare enum LegendItemType {
|
|
|
197
198
|
AREA = "area",
|
|
198
199
|
SIZE = "size",
|
|
199
200
|
LINE = "line",
|
|
200
|
-
QUARTILE = "quartile"
|
|
201
|
+
QUARTILE = "quartile",
|
|
202
|
+
ZOOM = "zoom"
|
|
201
203
|
}
|
|
@@ -35,6 +35,13 @@ export declare enum ZoomBar {
|
|
|
35
35
|
export declare enum ZoomDomain {
|
|
36
36
|
CHANGE = "zoom-domain-change"
|
|
37
37
|
}
|
|
38
|
+
/** enum of all events related to canvas zoom *
|
|
39
|
+
*
|
|
40
|
+
*/
|
|
41
|
+
export declare enum CanvasZoom {
|
|
42
|
+
CANVAS_ZOOM_IN = "canvas-zoom-in",
|
|
43
|
+
CANVAS_ZOOM_OUT = "canvas-zoom-out"
|
|
44
|
+
}
|
|
38
45
|
/**
|
|
39
46
|
* enum of all axis-related events
|
|
40
47
|
*/
|
|
@@ -162,3 +169,12 @@ export declare enum Legend {
|
|
|
162
169
|
ITEM_MOUSEOUT = "legend-item-onmouseout",
|
|
163
170
|
ITEMS_UPDATE = "legend-items-update"
|
|
164
171
|
}
|
|
172
|
+
/**
|
|
173
|
+
* enum of all circlepack related events
|
|
174
|
+
*/
|
|
175
|
+
export declare enum CirclePack {
|
|
176
|
+
CIRCLE_MOUSEOVER = "circle-leaf-mouseover",
|
|
177
|
+
CIRCLE_CLICK = "circle-leaf-click",
|
|
178
|
+
CIRCLE_MOUSEOUT = "circle-leaf-mouseout",
|
|
179
|
+
CIRCLE_MOUSEMOVE = "circle-leaf-mousemove"
|
|
180
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ChartModel } from './model';
|
|
2
|
+
import { LegendItemType } from './interfaces/enums';
|
|
3
|
+
/** The charting model layer which includes mainly the chart data and options,
|
|
4
|
+
* as well as some misc. information to be shared among components */
|
|
5
|
+
export declare class CirclePackChartModel extends ChartModel {
|
|
6
|
+
parentNode: boolean;
|
|
7
|
+
constructor(services: any);
|
|
8
|
+
setData(newData: any): void;
|
|
9
|
+
setOptions(newOptions: any): void;
|
|
10
|
+
getZoomOptions(options?: any): {
|
|
11
|
+
legend?: undefined;
|
|
12
|
+
} | {
|
|
13
|
+
legend: {
|
|
14
|
+
additionalItems: {
|
|
15
|
+
type: LegendItemType;
|
|
16
|
+
name: string;
|
|
17
|
+
}[];
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
setZoom(options?: any): void;
|
|
21
|
+
updateHierarchyLevel(depth: number): void;
|
|
22
|
+
getHierarchyLevel(): any;
|
|
23
|
+
hasParentNode(): boolean;
|
|
24
|
+
setDataGroups(): void;
|
|
25
|
+
protected setChildrenDataGroup(node: any, name: any): any;
|
|
26
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Service } from './service';
|
|
2
|
+
export declare class CanvasZoom extends Service {
|
|
3
|
+
protected model: any;
|
|
4
|
+
/**
|
|
5
|
+
* focal: object to zoom into
|
|
6
|
+
* canvasElements: all the elements to translate and zoom on the chart area
|
|
7
|
+
* zoomSettings: object containing duration, easing and zoomlevel for the zoom behaviours
|
|
8
|
+
* */
|
|
9
|
+
zoomIn(focal: any, canvasElements: any, zoomSettings?: any): void;
|
|
10
|
+
zoomOut(canvasElements: any, zoomSettings?: any): void;
|
|
11
|
+
}
|