@ammarkhalidfarooq/dashboard-package 0.6.25 → 0.6.27
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.cjs.js +7 -6
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +7 -6
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -5909,8 +5909,9 @@ var RefundsChargebacksCard = function RefundsChargebacksCard(_ref) {
|
|
|
5909
5909
|
var chargebackSeries = chartData.map(function (item) {
|
|
5910
5910
|
return parseFloat((item.chargebackRate || 0).toFixed(2));
|
|
5911
5911
|
});
|
|
5912
|
-
var
|
|
5913
|
-
var
|
|
5912
|
+
var dataMax = Math.max.apply(Math, [0].concat(_toConsumableArray(chargebackSeries), _toConsumableArray(refundSeries)));
|
|
5913
|
+
var hasChartData = dataMax > 0;
|
|
5914
|
+
var yAxisMax = hasChartData ? Math.ceil(Math.max(dataMax, 1) * 1.2) : 0.5;
|
|
5914
5915
|
var chartOptions = {
|
|
5915
5916
|
chart: {
|
|
5916
5917
|
type: "area",
|
|
@@ -5996,7 +5997,7 @@ var RefundsChargebacksCard = function RefundsChargebacksCard(_ref) {
|
|
|
5996
5997
|
legend: {
|
|
5997
5998
|
show: false
|
|
5998
5999
|
},
|
|
5999
|
-
annotations: {
|
|
6000
|
+
annotations: hasChartData ? {
|
|
6000
6001
|
yaxis: [{
|
|
6001
6002
|
y: 1,
|
|
6002
6003
|
borderColor: "#EF4444",
|
|
@@ -6014,7 +6015,7 @@ var RefundsChargebacksCard = function RefundsChargebacksCard(_ref) {
|
|
|
6014
6015
|
offsetX: 10
|
|
6015
6016
|
}
|
|
6016
6017
|
}]
|
|
6017
|
-
},
|
|
6018
|
+
} : {},
|
|
6018
6019
|
tooltip: {
|
|
6019
6020
|
shared: true,
|
|
6020
6021
|
y: {
|
|
@@ -17070,7 +17071,7 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
17070
17071
|
spacing: 3,
|
|
17071
17072
|
sx: {
|
|
17072
17073
|
mb: 0,
|
|
17073
|
-
mt: "
|
|
17074
|
+
mt: "12px"
|
|
17074
17075
|
},
|
|
17075
17076
|
children: /*#__PURE__*/jsx(RenderChartCard, {
|
|
17076
17077
|
item: mainChart,
|
|
@@ -17746,7 +17747,7 @@ var OrganicSection = function OrganicSection(_ref) {
|
|
|
17746
17747
|
container: true,
|
|
17747
17748
|
spacing: 3,
|
|
17748
17749
|
sx: {
|
|
17749
|
-
mt: "
|
|
17750
|
+
mt: "12px"
|
|
17750
17751
|
},
|
|
17751
17752
|
children: [/*#__PURE__*/jsx(RenderChartCard, {
|
|
17752
17753
|
item: mainChart,
|