axidio-styleguide-library1-v2 0.0.948 → 0.0.950
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.
|
@@ -8791,10 +8791,6 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8791
8791
|
.selectAll('g.x1.axis1 g.tick text')
|
|
8792
8792
|
.attr('class', 'lib-xaxis-labels-texts-weeklycharts')
|
|
8793
8793
|
.attr('y', function () {
|
|
8794
|
-
// Minimize gap in maximized (fullscreen) view for weekly charts
|
|
8795
|
-
if (self.chartConfiguration.isFullScreen) {
|
|
8796
|
-
return short_tick_length_bg;
|
|
8797
|
-
}
|
|
8798
8794
|
if (alternate_text) {
|
|
8799
8795
|
alternate_text = false;
|
|
8800
8796
|
return long_tick_length_bg;
|
|
@@ -8813,19 +8809,11 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8813
8809
|
.attr('y', function (d) {
|
|
8814
8810
|
// For grouped bar charts with many bars and xLabel present, do NOT add extra space (avoid overlap)
|
|
8815
8811
|
if (subgroups.length > 1 && data.length > 8 && metaData.xLabel) {
|
|
8816
|
-
// In maximized (fullscreen) view, keep the gap minimal
|
|
8817
|
-
if (self.chartConfiguration.isFullScreen) {
|
|
8818
|
-
return short_tick_length_bg;
|
|
8819
|
-
}
|
|
8820
8812
|
return short_tick_length_bg;
|
|
8821
8813
|
}
|
|
8822
|
-
// For grouped bar charts with many bars and NO xLabel, add space as before
|
|
8814
|
+
// For grouped bar charts with many bars and NO xLabel, add space as before
|
|
8823
8815
|
if (subgroups.length > 1 && data.length > 8 && !metaData.xLabel) {
|
|
8824
8816
|
const chartHasExtraBottom = (self.chartConfiguration.margin && self.chartConfiguration.margin.bottom >= 40);
|
|
8825
|
-
if (self.chartConfiguration.isFullScreen) {
|
|
8826
|
-
// Reduce extra gap in maximized view
|
|
8827
|
-
return short_tick_length_bg + 2;
|
|
8828
|
-
}
|
|
8829
8817
|
return chartHasExtraBottom ? short_tick_length_bg : short_tick_length_bg + 10;
|
|
8830
8818
|
}
|
|
8831
8819
|
// Default/fallback logic for other cases
|
|
@@ -8838,10 +8826,6 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8838
8826
|
if (/\d{2,4}[-\/]\d{2,4}/.test(d) && d.indexOf(' ') > -1) {
|
|
8839
8827
|
baseY += 4;
|
|
8840
8828
|
}
|
|
8841
|
-
// In maximized view, reduce baseY slightly for grouped bars
|
|
8842
|
-
if (self.chartConfiguration.isFullScreen && subgroups.length > 1) {
|
|
8843
|
-
baseY = Math.max(short_tick_length_bg, baseY - 10);
|
|
8844
|
-
}
|
|
8845
8829
|
return baseY;
|
|
8846
8830
|
})
|
|
8847
8831
|
.attr('x', function (d) {
|
|
@@ -8852,7 +8836,9 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8852
8836
|
})
|
|
8853
8837
|
.text(function (d) {
|
|
8854
8838
|
var isValueToBeIgnored = false;
|
|
8855
|
-
if (
|
|
8839
|
+
// Check if this should show truncated text (mobile or ria conditions)
|
|
8840
|
+
const shouldTruncate = (isMobile && !self.isHeaderVisible) || (isria && self.chartData.data.length > 8);
|
|
8841
|
+
if (shouldTruncate) {
|
|
8856
8842
|
let firstPart = d.split(/[\s\-]+/)[0];
|
|
8857
8843
|
return firstPart.substring(0, 3).toLowerCase();
|
|
8858
8844
|
}
|
|
@@ -8908,7 +8894,7 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8908
8894
|
});
|
|
8909
8895
|
}
|
|
8910
8896
|
}
|
|
8911
|
-
if (isMobile && !
|
|
8897
|
+
if ((isMobile && !self.isHeaderVisible) || (isria && self.chartData.data.length > 8)) {
|
|
8912
8898
|
svg
|
|
8913
8899
|
.selectAll('g.x1.axis1 g.tick text')
|
|
8914
8900
|
.classed('mobile-xaxis-override', true);
|