@redsift/charts 10.1.0-alpha.1 → 10.1.0-alpha.3

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.
package/index.js CHANGED
@@ -1697,6 +1697,9 @@ const RenderedLinearBarChart = /*#__PURE__*/forwardRef((props, ref) => {
1697
1697
  const domain = extent(data, d => d.value);
1698
1698
  domain[0] = (_ref7 = yAxisMinValue) !== null && _ref7 !== void 0 ? _ref7 : domain[0];
1699
1699
  domain[1] = (_ref8 = yAxisMaxValue) !== null && _ref8 !== void 0 ? _ref8 : domain[1];
1700
+ if (domain[1] === 0 && domain[0] === 0) {
1701
+ domain[1] = 1;
1702
+ }
1700
1703
  return scaleLinear().domain(domain).range([chartHeight, 0]).nice();
1701
1704
  })();
1702
1705
  const xAxisTickFormat = propsXAxisTickFormat !== null && propsXAxisTickFormat !== void 0 ? propsXAxisTickFormat : xScaleType === 'Date' || xScaleType === 'dateString' ? scaleX.tickFormat() : undefined;