axidio-styleguide-library1-v2 0.0.916 → 0.0.917
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.
|
@@ -8798,7 +8798,7 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8798
8798
|
.style('font-size', this.isHeaderVisible ? '18px' : '14px')
|
|
8799
8799
|
.attr('y', this.isHeaderVisible
|
|
8800
8800
|
? short_tick_length_bg + 25
|
|
8801
|
-
: short_tick_length_bg
|
|
8801
|
+
: short_tick_length_bg)
|
|
8802
8802
|
.attr('x', function (d) {
|
|
8803
8803
|
if (self.chartData.data.length > 8 && !self.isZoomedOut) {
|
|
8804
8804
|
return -25; // Move first line text slightly to the left too
|
|
@@ -8970,13 +8970,13 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8970
8970
|
}
|
|
8971
8971
|
var xSubgroup = d3.scaleBand().domain(subgroups);
|
|
8972
8972
|
if (this.chartConfiguration.isMultiChartGridLine == undefined) {
|
|
8973
|
-
|
|
8974
|
-
const barWidthRatio = 0.6;
|
|
8975
|
-
const offset = (x.bandwidth() * (1 - barWidthRatio)) / 2;
|
|
8976
|
-
xSubgroup.range([offset, x.bandwidth() - offset]);
|
|
8973
|
+
xSubgroup.range([0, x.bandwidth()]);
|
|
8977
8974
|
}
|
|
8978
8975
|
else {
|
|
8979
|
-
|
|
8976
|
+
/**
|
|
8977
|
+
* used to make grouped bars with lesser width as we are not using padding for width
|
|
8978
|
+
* used by weekly charts
|
|
8979
|
+
*/
|
|
8980
8980
|
xSubgroup.range([0, x.bandwidth()]);
|
|
8981
8981
|
}
|
|
8982
8982
|
// if (this.chartConfiguration.isDrilldownChart) {
|
|
@@ -9030,25 +9030,25 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
9030
9030
|
let keys = Object.keys(indiv).filter((temp, i) => i != 0);
|
|
9031
9031
|
tempScale = d3.scaleBand().domain(keys).range([0, x.bandwidth()]);
|
|
9032
9032
|
if (x.bandwidth() > 100) {
|
|
9033
|
+
// Reduce bar width for normal drill down (not zoomed/grouped)
|
|
9034
|
+
const reducedBarWidth = 60;
|
|
9033
9035
|
if (self.chartData.data.length == 1) {
|
|
9034
9036
|
if (Object.keys(self.chartData.data[0]).length == 2) {
|
|
9035
9037
|
tempScale.range([
|
|
9036
|
-
0 + (x.bandwidth() -
|
|
9037
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9038
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9039
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9038
9040
|
]);
|
|
9039
|
-
// .padding(0.05);
|
|
9040
9041
|
}
|
|
9041
9042
|
else
|
|
9042
9043
|
tempScale.range([
|
|
9043
|
-
0 + (x.bandwidth() -
|
|
9044
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9044
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9045
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9045
9046
|
]);
|
|
9046
|
-
// .padding(0.05);
|
|
9047
9047
|
}
|
|
9048
9048
|
else
|
|
9049
9049
|
tempScale.range([
|
|
9050
|
-
0 + (x.bandwidth() -
|
|
9051
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9050
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9051
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9052
9052
|
]);
|
|
9053
9053
|
}
|
|
9054
9054
|
}
|
|
@@ -9070,32 +9070,30 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
9070
9070
|
})
|
|
9071
9071
|
.attr('width', function (d) {
|
|
9072
9072
|
if (self.chartConfiguration.isDrilldownChart) {
|
|
9073
|
-
// var tempScale;
|
|
9074
9073
|
data.map((indiv) => {
|
|
9075
9074
|
if (indiv.name == d.name) {
|
|
9076
9075
|
let keys = Object.keys(indiv).filter((temp, i) => i != 0);
|
|
9077
|
-
var temp;
|
|
9078
9076
|
tempScale = d3.scaleBand().domain(keys).range([0, x.bandwidth()]);
|
|
9079
9077
|
if (x.bandwidth() > 100) {
|
|
9078
|
+
// Reduce bar width for normal drill down (not zoomed/grouped)
|
|
9079
|
+
const reducedBarWidth = 60;
|
|
9080
9080
|
if (self.chartData.data.length == 1) {
|
|
9081
9081
|
if (Object.keys(self.chartData.data[0]).length == 2) {
|
|
9082
9082
|
tempScale.range([
|
|
9083
|
-
0 + (x.bandwidth() -
|
|
9084
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9083
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9084
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9085
9085
|
]);
|
|
9086
|
-
// .padding(0.05);
|
|
9087
9086
|
}
|
|
9088
9087
|
else
|
|
9089
9088
|
tempScale.range([
|
|
9090
|
-
0 + (x.bandwidth() -
|
|
9091
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9089
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9090
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9092
9091
|
]);
|
|
9093
|
-
// .padding(0.05);
|
|
9094
9092
|
}
|
|
9095
9093
|
else
|
|
9096
9094
|
tempScale.range([
|
|
9097
|
-
0 + (x.bandwidth() -
|
|
9098
|
-
x.bandwidth() - (x.bandwidth() -
|
|
9095
|
+
0 + (x.bandwidth() - reducedBarWidth) / 2,
|
|
9096
|
+
x.bandwidth() - (x.bandwidth() - reducedBarWidth) / 2,
|
|
9099
9097
|
]);
|
|
9100
9098
|
}
|
|
9101
9099
|
}
|