axidio-styleguide-library1-v2 0.0.987 → 0.0.988
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.
|
@@ -9017,20 +9017,9 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
9017
9017
|
});
|
|
9018
9018
|
}
|
|
9019
9019
|
var xSubgroup = d3.scaleBand().domain(subgroups);
|
|
9020
|
-
|
|
9021
|
-
|
|
9022
|
-
|
|
9023
|
-
const isDateLabel = /^\d{2,4}[-\/]\d{2,4}([-\/]\d{2,4})?$/.test(label.trim());
|
|
9024
|
-
const isWeekLabel = /week|wk|w\d+/i.test(label);
|
|
9025
|
-
return isDateLabel && !isWeekLabel;
|
|
9026
|
-
});
|
|
9027
|
-
if (isGroupedWithExactDateLabels) {
|
|
9028
|
-
// Increase bar width for both zoom-in and zoom-out views
|
|
9029
|
-
xSubgroup.range([0, x.bandwidth() * 0.7]);
|
|
9030
|
-
}
|
|
9031
|
-
else if (subgroups.length > 1 && !this.isZoomedOut) {
|
|
9032
|
-
// For grouped bar charts in zoom-in view, use default width
|
|
9033
|
-
xSubgroup.range([0, x.bandwidth() * 0.5]);
|
|
9020
|
+
if (subgroups.length > 1 && !this.isZoomedOut) {
|
|
9021
|
+
// For grouped bar charts in zoom-in view, reduce padding between bars
|
|
9022
|
+
xSubgroup.range([0, x.bandwidth()]);
|
|
9034
9023
|
}
|
|
9035
9024
|
else if (subgroups.length === 1 && !this.isZoomedOut) {
|
|
9036
9025
|
// For single-bar (non-grouped) charts in zoom-in view, set bar width to 80
|