impaktapps-design 0.2.993-alpha.253 → 0.2.993-alpha.254

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.
@@ -18661,7 +18661,7 @@ function DrawBarGraph({
18661
18661
  value
18662
18662
  }) {
18663
18663
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
18664
- const graphData = ((_b = (_a = value.main) == null ? void 0 : _a.data) == null ? void 0 : _b.length) ? value.main.data : [];
18664
+ const graphData = ((_b = (_a = value.main) == null ? void 0 : _a.data) == null ? void 0 : _b.length) ? value.main.data : [{}];
18665
18665
  const disableLeftLabel = (_c = value.main) == null ? void 0 : _c.disableLeftLabel;
18666
18666
  const xAxisValue = ((_d = value.main) == null ? void 0 : _d.xAxisValue) || "label";
18667
18667
  const labelsArray = Object.keys(graphData[0]).filter((d2) => d2 !== xAxisValue);
@@ -22778,10 +22778,10 @@ var DrawHorizontalBarGraph = ({
22778
22778
  }) => {
22779
22779
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
22780
22780
  const [hoveredBar, setHoveredBar] = useState({});
22781
- const graphData = ((_b = (_a = barValue.main) == null ? void 0 : _a.data) == null ? void 0 : _b.length) ? barValue.main.data : [];
22781
+ const graphData = ((_b = (_a = barValue.main) == null ? void 0 : _a.data) == null ? void 0 : _b.length) ? barValue.main.data : [{}];
22782
22782
  const disableLeftLabel = (_c = barValue.main) == null ? void 0 : _c.disableLeftLabel;
22783
22783
  const xAxisValue = ((_d = barValue.main) == null ? void 0 : _d.xAxisValue) || "label";
22784
- const labelsArray = Object.keys(graphData[0]).filter((d2) => d2 !== xAxisValue);
22784
+ const labelsArray = graphData.length ? Object.keys(graphData[0]).filter((d2) => d2 !== xAxisValue) : [];
22785
22785
  const legendAvailable = (_f = (_e = barValue == null ? void 0 : barValue.main) == null ? void 0 : _e.legendAvailable) != null ? _f : true;
22786
22786
  const colorMap = (_g = barValue.style) == null ? void 0 : _g.colorMap;
22787
22787
  const legendLabels = (_h = barValue.main) == null ? void 0 : _h.legendLabels;