axidio-styleguide-library1-v2 0.0.930 → 0.0.932

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.
@@ -8818,13 +8818,18 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
8818
8818
  })
8819
8819
  .attr('y', function (d) {
8820
8820
  // If grouped chart, no xLabel, and label is a date, add extra offset
8821
+ let baseY = self.isHeaderVisible ? short_tick_length_bg + 25 : short_tick_length_bg;
8821
8822
  if (subgroups.length > 1 &&
8822
8823
  !metaData.xLabel &&
8823
8824
  (/\d{2,4}[-\/]\d{2}[-\/]\d{2,4}/.test(d) || /\d{2,4}[-\/]\d{2,4}/.test(d))) {
8824
8825
  // 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);
8826
+ baseY = self.isHeaderVisible ? short_tick_length_bg + 15 : short_tick_length_bg + 25;
8826
8827
  }
8827
- return self.isHeaderVisible ? short_tick_length_bg + 25 : short_tick_length_bg;
8828
+ // Add a little extra space if the date label contains a space (will be split into two lines)
8829
+ if (/\d{2,4}[-\/]\d{2,4}/.test(d) && d.indexOf(' ') > -1) {
8830
+ baseY += 4; // Add 4px extra space for two-line date labels
8831
+ }
8832
+ return baseY;
8828
8833
  })
8829
8834
  .attr('x', function (d) {
8830
8835
  if (self.chartData.data.length > 8 && !self.isZoomedOut) {
@@ -9582,7 +9587,7 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
9582
9587
  text.append('tspan')
9583
9588
  .text(line)
9584
9589
  .attr('x', 0)
9585
- .attr('dy', idx === 0 ? '0em' : '1.1em');
9590
+ .attr('dy', idx === 0 ? '1em' : '1.1em');
9586
9591
  });
9587
9592
  }
9588
9593
  else {