axidio-styleguide-library1-v2 0.0.784 → 0.0.785

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.
@@ -8419,7 +8419,7 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
8419
8419
  isDisplayBarDetailsAtBottom: undefined,
8420
8420
  howmanyBarDetailsToDisplay: 0,
8421
8421
  barVauleColor: undefined,
8422
- defaultBarHeight: 2,
8422
+ defaultBarHeight: 4,
8423
8423
  };
8424
8424
  this.uniqueId = this.getUniqueId();
8425
8425
  this.isZoomedOut = false;
@@ -8765,16 +8765,15 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
8765
8765
  });
8766
8766
  svg
8767
8767
  .selectAll('g.x1.axis1 g.tick')
8768
- .each((d) => {
8769
- // Only append second <text> for non-date labels
8770
- if (!/\d{2,4}[-\/]/.test(d) && d.trim().indexOf(' ') > -1) {
8771
- d3.select(this)
8772
- .append('text')
8773
- .attr('class', 'lib-xaxis-labels-texts-drilldown')
8774
- .attr('y', long_tick_length_bg)
8775
- .attr('fill', 'var(--chart-text-color)')
8776
- .text(d.trim().substring(d.indexOf(' '), d.length).toLowerCase());
8768
+ .append('text')
8769
+ .attr('class', 'lib-xaxis-labels-texts-drilldown')
8770
+ .attr('y', long_tick_length_bg)
8771
+ .attr('fill', 'var(--chart-text-color)')
8772
+ .text(function (d) {
8773
+ if (d.trim().indexOf(' ') > -1) {
8774
+ return d.trim().substring(d.indexOf(' '), d.length).toLowerCase();
8777
8775
  }
8776
+ return '';
8778
8777
  });
8779
8778
  }
8780
8779
  /**y scale for left y axis */
@@ -8980,10 +8979,14 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
8980
8979
  if (d.value == -1) {
8981
8980
  return y(0);
8982
8981
  }
8983
- if (d.value >= 0) {
8984
- const barHeight = height - y(d.value);
8985
- const minHeight = self.chartConfiguration.defaultBarHeight || 2;
8986
- return barHeight < minHeight ? y(0) - minHeight : y(d.value);
8982
+ if (d.value) {
8983
+ // For values between 0 and 10, position bar at baseline with default height
8984
+ if (d.value <= 10 && d.value >= 0) {
8985
+ const defaultHeight = self.chartConfiguration.defaultBarHeight || 8;
8986
+ return y(0) - defaultHeight;
8987
+ }
8988
+ // For values greater than 10, use normal calculated position
8989
+ return y(d.value);
8987
8990
  }
8988
8991
  return y(0);
8989
8992
  })
@@ -9027,10 +9030,13 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
9027
9030
  if (d.value == -1) {
9028
9031
  return height - y(0);
9029
9032
  }
9030
- if (d.value >= 0) {
9031
- const barHeight = height - y(d.value);
9032
- const minHeight = self.chartConfiguration.defaultBarHeight || 2;
9033
- return Math.max(barHeight, minHeight);
9033
+ if (d.value) {
9034
+ // For values between 0 and 10 (inclusive), use default height
9035
+ if (d.value <= 10 && d.value >= 0) {
9036
+ return self.chartConfiguration.defaultBarHeight || 8;
9037
+ }
9038
+ // For values greater than 10, use calculated height
9039
+ return height - y(d.value);
9034
9040
  }
9035
9041
  return height - y(0);
9036
9042
  })
@@ -9359,10 +9365,10 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
9359
9365
  .tickSize(0)
9360
9366
  .ticks(self.chartConfiguration.numberOfYTicks)
9361
9367
  .tickFormat(function (d) {
9362
- if (self.chartConfiguration.yAxisLabelFomatter) {
9363
- return self.chartConfiguration.yAxisLabelFomatter(d);
9364
- }
9365
- return d;
9368
+ const formatted = self.chartConfiguration.yAxisLabelFomatter
9369
+ ? self.chartConfiguration.yAxisLabelFomatter(d)
9370
+ : d;
9371
+ return formatted >= 1000 ? formatted / 1000 + 'k' : formatted;
9366
9372
  }))
9367
9373
  .call((g) => {
9368
9374
  // Style the domain line for theme support