sag_components 2.0.0-beta63 → 2.0.0-beta65

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/dist/index.js CHANGED
@@ -31488,15 +31488,15 @@ const SeparatedLineBarChart = ({
31488
31488
  payload
31489
31489
  } = props;
31490
31490
  const label = payload.value;
31491
- const words = label.split(' ');
31491
+ const words = label.split(" ");
31492
31492
  const chunks = [];
31493
- let currentChunk = '';
31493
+ let currentChunk = "";
31494
31494
  words.forEach(word => {
31495
31495
  if (currentChunk.length + word.length > 15) {
31496
31496
  chunks.push(currentChunk.trim());
31497
31497
  currentChunk = word;
31498
31498
  } else {
31499
- currentChunk += (currentChunk ? ' ' : '') + word;
31499
+ currentChunk += (currentChunk ? " " : "") + word;
31500
31500
  }
31501
31501
  });
31502
31502
  if (currentChunk) {
@@ -31543,11 +31543,11 @@ const SeparatedLineBarChart = ({
31543
31543
  return /*#__PURE__*/React__default["default"].createElement("div", {
31544
31544
  style: {
31545
31545
  width: "100%",
31546
- height: "700px"
31546
+ height: "100%"
31547
31547
  }
31548
31548
  }, /*#__PURE__*/React__default["default"].createElement("div", {
31549
31549
  style: {
31550
- height: "40%"
31550
+ height: "25%"
31551
31551
  }
31552
31552
  }, /*#__PURE__*/React__default["default"].createElement(recharts.ResponsiveContainer, {
31553
31553
  width: "100%",
@@ -31587,7 +31587,7 @@ const SeparatedLineBarChart = ({
31587
31587
  }, /*#__PURE__*/React__default["default"].createElement(recharts.LabelList, {
31588
31588
  dataKey: "inc_roi",
31589
31589
  position: "top",
31590
- formatter: value => value.toFixed(1),
31590
+ formatter: value => `$${getFormattedValue(value)}${getFormattedUnits(value)}`,
31591
31591
  fill: "#212121",
31592
31592
  fontSize: 12,
31593
31593
  fontWeight: "400",
@@ -31604,7 +31604,7 @@ const SeparatedLineBarChart = ({
31604
31604
  hide: true
31605
31605
  })))), /*#__PURE__*/React__default["default"].createElement("div", {
31606
31606
  style: {
31607
- height: "60%"
31607
+ height: "70%"
31608
31608
  }
31609
31609
  }, /*#__PURE__*/React__default["default"].createElement(recharts.ResponsiveContainer, {
31610
31610
  width: "100%",
@@ -31640,7 +31640,7 @@ const SeparatedLineBarChart = ({
31640
31640
  }, /*#__PURE__*/React__default["default"].createElement(recharts.LabelList, {
31641
31641
  dataKey: "inc_sales",
31642
31642
  position: "top",
31643
- formatter: value => `${value / 1000}k`,
31643
+ formatter: value => `$${getFormattedValue(value)}${getFormattedUnits(value)}`,
31644
31644
  fill: "#212121",
31645
31645
  fontSize: 12,
31646
31646
  fontWeight: "400",
@@ -31651,10 +31651,11 @@ const SeparatedLineBarChart = ({
31651
31651
  stroke: "#212121",
31652
31652
  startIndex: 0,
31653
31653
  endIndex: Math.min(6, processedData.length - 1),
31654
- y: 330,
31655
31654
  travellerWidth: 10,
31656
31655
  tickFormatter: (value, index) => index + 1
31657
- })), /*#__PURE__*/React__default["default"].createElement("div", null, /*#__PURE__*/React__default["default"].createElement(PerformanceAnalyticsLegend, {
31656
+ })), /*#__PURE__*/React__default["default"].createElement("div", null)), /*#__PURE__*/React__default["default"].createElement(PerformanceAnalyticsLegend, {
31657
+ width: "100%",
31658
+ height: "40px",
31658
31659
  legendData: [{
31659
31660
  iconColor: "#CCDCDD",
31660
31661
  iconType: "Square",
@@ -31664,7 +31665,7 @@ const SeparatedLineBarChart = ({
31664
31665
  iconType: "LegendUnionIcon",
31665
31666
  title: "INC Sales ROI"
31666
31667
  }]
31667
- })))));
31668
+ })));
31668
31669
  };
31669
31670
 
31670
31671
  function SingleChart({
@@ -31724,11 +31725,12 @@ function SingleChart({
31724
31725
  };
31725
31726
  return /*#__PURE__*/React__default["default"].createElement("div", {
31726
31727
  style: {
31727
- width: "100%"
31728
+ width: "100%",
31729
+ height: "100%"
31728
31730
  }
31729
31731
  }, /*#__PURE__*/React__default["default"].createElement(recharts.ResponsiveContainer, {
31730
- width: width,
31731
- height: height
31732
+ width: "100%",
31733
+ height: "95%"
31732
31734
  }, /*#__PURE__*/React__default["default"].createElement(recharts.ComposedChart, {
31733
31735
  data: dataWithIndex,
31734
31736
  margin: {
@@ -31765,7 +31767,7 @@ function SingleChart({
31765
31767
  }, /*#__PURE__*/React__default["default"].createElement(recharts.LabelList, {
31766
31768
  dataKey: "value",
31767
31769
  position: "top",
31768
- formatter: value => `$${value / 1000}k`,
31770
+ formatter: value => `$${getFormattedValue(value)}${getFormattedUnits(value)}`,
31769
31771
  fill: "#212121",
31770
31772
  fontSize: 12,
31771
31773
  fontWeight: "400",
@@ -31774,15 +31776,16 @@ function SingleChart({
31774
31776
  height: 30,
31775
31777
  travellerWidth: 10,
31776
31778
  startIndex: 0,
31777
- endIndex: Math.min(6, barData.length - 1),
31778
- y: 380
31779
- })), /*#__PURE__*/React__default["default"].createElement(PerformanceAnalyticsLegend, {
31779
+ endIndex: Math.min(6, barData.length - 1)
31780
+ }))), /*#__PURE__*/React__default["default"].createElement(PerformanceAnalyticsLegend, {
31781
+ width: "100%",
31782
+ height: "40px",
31780
31783
  legendData: [{
31781
31784
  iconColor: "#CCDCDD",
31782
31785
  iconType: "Square",
31783
31786
  title: "INC Units"
31784
31787
  }]
31785
- })));
31788
+ }));
31786
31789
  }
31787
31790
 
31788
31791
  styled__default["default"].div`
@@ -32080,15 +32083,15 @@ function InnerBarChart({
32080
32083
  const label = payload.value;
32081
32084
 
32082
32085
  // Split the label into chunks of words
32083
- const words = label.split(' ');
32086
+ const words = label.split(" ");
32084
32087
  const chunks = [];
32085
- let currentChunk = '';
32088
+ let currentChunk = "";
32086
32089
  words.forEach(word => {
32087
32090
  if (currentChunk.length + word.length > 15) {
32088
32091
  chunks.push(currentChunk.trim());
32089
32092
  currentChunk = word;
32090
32093
  } else {
32091
- currentChunk += ' ' + word;
32094
+ currentChunk += " " + word;
32092
32095
  }
32093
32096
  });
32094
32097
  if (currentChunk) {
@@ -32110,9 +32113,14 @@ function InnerBarChart({
32110
32113
  dy: i === 0 ? "0.71em" : "1.2em"
32111
32114
  }, chunk))));
32112
32115
  };
32113
- return /*#__PURE__*/React__default["default"].createElement(recharts.ResponsiveContainer, {
32116
+ return /*#__PURE__*/React__default["default"].createElement("div", {
32117
+ style: {
32118
+ width: "100%",
32119
+ height: "100%"
32120
+ }
32121
+ }, /*#__PURE__*/React__default["default"].createElement(recharts.ResponsiveContainer, {
32114
32122
  width: "100%",
32115
- height: "100%"
32123
+ height: "95%"
32116
32124
  }, /*#__PURE__*/React__default["default"].createElement(recharts.BarChart, {
32117
32125
  data: brushInnerBarData,
32118
32126
  margin: {
@@ -32144,7 +32152,19 @@ function InnerBarChart({
32144
32152
  travellerWidth: 10,
32145
32153
  startIndex: 0,
32146
32154
  endIndex: Math.min(6, brushInnerBarData.length - 1)
32147
- })));
32155
+ }))), /*#__PURE__*/React__default["default"].createElement(PerformanceAnalyticsLegend, {
32156
+ width: "100%",
32157
+ height: "40px",
32158
+ legendData: [{
32159
+ iconColor: "#CCDCDD",
32160
+ iconType: "Square",
32161
+ title: "New Shoppers"
32162
+ }, {
32163
+ iconColor: "#07575b",
32164
+ iconType: "Square",
32165
+ title: "Repeaters"
32166
+ }]
32167
+ }));
32148
32168
  }
32149
32169
 
32150
32170
  const BrushChart = props => {