axidio-styleguide-library1-v2 0.0.928 → 0.0.929
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.
|
@@ -8806,19 +8806,27 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8806
8806
|
.selectAll('g.x1.axis1 g.tick text')
|
|
8807
8807
|
.attr('class', 'lib-xaxis-labels-texts-drilldown')
|
|
8808
8808
|
.style('font-size', this.isHeaderVisible ? '18px' : '14px')
|
|
8809
|
+
.style('font-weight', function (d) {
|
|
8810
|
+
// Make bold if grouped, no xLabel, date, and header not visible (+25 case)
|
|
8811
|
+
if (subgroups.length > 1 &&
|
|
8812
|
+
!metaData.xLabel &&
|
|
8813
|
+
!self.isHeaderVisible &&
|
|
8814
|
+
(/\d{2,4}[-\/]\d{2}[-\/]\d{2,4}/.test(d) || /\d{2,4}[-\/]\d{2,4}/.test(d))) {
|
|
8815
|
+
return 'bold';
|
|
8816
|
+
}
|
|
8817
|
+
return null;
|
|
8818
|
+
})
|
|
8809
8819
|
.attr('y', function (d) {
|
|
8810
|
-
// If grouped chart, no xLabel, and label is a date, add
|
|
8820
|
+
// If grouped chart, no xLabel, and label is a date, add extra offset
|
|
8811
8821
|
if (subgroups.length > 1 &&
|
|
8812
8822
|
!metaData.xLabel &&
|
|
8813
8823
|
(/\d{2,4}[-\/]\d{2}[-\/]\d{2,4}/.test(d) || /\d{2,4}[-\/]\d{2,4}/.test(d))) {
|
|
8814
|
-
|
|
8824
|
+
// If header is visible, use a smaller offset (e.g., +15), else +25
|
|
8825
|
+
return (self.isHeaderVisible ? short_tick_length_bg + 15 : short_tick_length_bg + 25);
|
|
8815
8826
|
}
|
|
8816
8827
|
return self.isHeaderVisible ? short_tick_length_bg + 25 : short_tick_length_bg;
|
|
8817
8828
|
})
|
|
8818
8829
|
.attr('x', function (d) {
|
|
8819
|
-
if (isria && self.chartData.data.length > 8) {
|
|
8820
|
-
return -10;
|
|
8821
|
-
}
|
|
8822
8830
|
if (self.chartData.data.length > 8 && !self.isZoomedOut) {
|
|
8823
8831
|
return -25; // Move first line text slightly to the left too
|
|
8824
8832
|
}
|
|
@@ -8826,10 +8834,6 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8826
8834
|
})
|
|
8827
8835
|
.text(function (d) {
|
|
8828
8836
|
var isValueToBeIgnored = false;
|
|
8829
|
-
if (isria && self.chartData.data.length > 8) {
|
|
8830
|
-
// Show only first 3 letters, lowercase
|
|
8831
|
-
return d.substring(0, 3).toLowerCase();
|
|
8832
|
-
}
|
|
8833
8837
|
if (isMobile && !self.isHeaderVisible) {
|
|
8834
8838
|
let firstPart = d.split(/[\s\-]+/)[0];
|
|
8835
8839
|
return firstPart.substring(0, 3).toLowerCase();
|
|
@@ -8851,12 +8855,6 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
8851
8855
|
return d.trim().substring(0, d.indexOf(' ')).toLowerCase();
|
|
8852
8856
|
}
|
|
8853
8857
|
return d.toLowerCase();
|
|
8854
|
-
}).attr('transform', function (d) {
|
|
8855
|
-
// Rotate if RIA and >8
|
|
8856
|
-
if (isria && self.chartData.data.length > 8) {
|
|
8857
|
-
return 'rotate(-45)';
|
|
8858
|
-
}
|
|
8859
|
-
return null;
|
|
8860
8858
|
});
|
|
8861
8859
|
if (!isMobile) {
|
|
8862
8860
|
svg
|