@carbon/charts-vue 1.3.2 → 1.4.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.
- package/CHANGELOG.md +8 -0
- package/charts-vue.common.js +7 -4
- package/charts-vue.common.js.map +1 -1
- package/charts-vue.umd.js +7 -4
- package/charts-vue.umd.js.map +1 -1
- package/charts-vue.umd.min.js +1 -1
- package/charts-vue.umd.min.js.map +1 -1
- package/package.json +2 -2
package/charts-vue.umd.js
CHANGED
|
@@ -691,7 +691,7 @@ var RenderTypes;
|
|
|
691
691
|
*/
|
|
692
692
|
var ChartTheme;
|
|
693
693
|
(function (ChartTheme) {
|
|
694
|
-
ChartTheme["
|
|
694
|
+
ChartTheme["WHITE"] = "white";
|
|
695
695
|
ChartTheme["G100"] = "g100";
|
|
696
696
|
ChartTheme["G90"] = "g90";
|
|
697
697
|
ChartTheme["G10"] = "g10";
|
|
@@ -8477,6 +8477,7 @@ var chart = {
|
|
|
8477
8477
|
width: null,
|
|
8478
8478
|
height: null,
|
|
8479
8479
|
resizable: true,
|
|
8480
|
+
theme: ChartTheme.WHITE,
|
|
8480
8481
|
tooltip: baseTooltip,
|
|
8481
8482
|
legend: configuration_legend,
|
|
8482
8483
|
style: {
|
|
@@ -11468,12 +11469,10 @@ var dom_utils_DOMUtils = /** @class */ (function (_super) {
|
|
|
11468
11469
|
};
|
|
11469
11470
|
DOMUtils.prototype.styleHolderElement = function () {
|
|
11470
11471
|
var holderElement = this.getHolder();
|
|
11471
|
-
// Add class to chart holder
|
|
11472
|
-
src_select(this.getHolder()).classed(carbonPrefix + "--chart-holder", true);
|
|
11473
11472
|
// In order for resize events to not clash with these updates
|
|
11474
11473
|
// We'll check if the width & height values passed in options
|
|
11475
11474
|
// Have changed, before setting them to the holder
|
|
11476
|
-
var _a = this.model.getOptions(), width = _a.width, height = _a.height;
|
|
11475
|
+
var _a = this.model.getOptions(), width = _a.width, height = _a.height, theme = _a.theme;
|
|
11477
11476
|
if (width !== this.width) {
|
|
11478
11477
|
// Apply formatted width attribute to chart
|
|
11479
11478
|
holderElement.style.width = width;
|
|
@@ -11484,6 +11483,10 @@ var dom_utils_DOMUtils = /** @class */ (function (_super) {
|
|
|
11484
11483
|
holderElement.style.height = height;
|
|
11485
11484
|
this.height = height;
|
|
11486
11485
|
}
|
|
11486
|
+
// Add class to chart holder
|
|
11487
|
+
src_select(this.getHolder())
|
|
11488
|
+
.classed(carbonPrefix + "--chart-holder", true)
|
|
11489
|
+
.attr('data-carbon-theme', theme);
|
|
11487
11490
|
};
|
|
11488
11491
|
DOMUtils.prototype.getHolder = function () {
|
|
11489
11492
|
return this.model.get('holder');
|