@ammarkhalidfarooq/dashboard-package 0.6.124 → 0.6.125
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/MetricCard.cjs.js.map +1 -1
- package/dist/MetricCard.es.js.map +1 -1
- package/dist/RenderChartCard.cjs.js +1 -1
- package/dist/RenderChartCard.cjs.js.map +1 -1
- package/dist/RenderChartCard.es.js +1 -1
- package/dist/RenderChartCard.es.js.map +1 -1
- package/dist/index.cjs.js +7 -17
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +7 -17
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
- package/dist/index.d.js +0 -2
package/dist/index.es.js
CHANGED
|
@@ -430,19 +430,10 @@ function getTrendArrow(valueOrText) {
|
|
|
430
430
|
return "";
|
|
431
431
|
}
|
|
432
432
|
function formatCurrency(value) {
|
|
433
|
-
return "$".concat(Number(value !== null && value !== void 0 ? value : 0).
|
|
433
|
+
return "$".concat(Number(value !== null && value !== void 0 ? value : 0).toFixed(2));
|
|
434
434
|
}
|
|
435
435
|
function formatNumber(num) {
|
|
436
|
-
|
|
437
|
-
return (num / 1000000000).toFixed(1).replace(/\.0$/, "") + "B";
|
|
438
|
-
}
|
|
439
|
-
if (num >= 1000000) {
|
|
440
|
-
return (num / 1000000).toFixed(1).replace(/\.0$/, "") + "M";
|
|
441
|
-
}
|
|
442
|
-
if (num >= 1000) {
|
|
443
|
-
return (num / 1000).toFixed(1).replace(/\.0$/, "") + "K";
|
|
444
|
-
}
|
|
445
|
-
return (num !== null && num !== void 0 ? num : 0).toString();
|
|
436
|
+
return Number(num !== null && num !== void 0 ? num : 0).toFixed(2);
|
|
446
437
|
}
|
|
447
438
|
|
|
448
439
|
var RevenueChart = function RevenueChart(_ref) {
|
|
@@ -3756,9 +3747,9 @@ var ExportPdfLayout = /*#__PURE__*/React.forwardRef(function (_ref34, ref) {
|
|
|
3756
3747
|
});
|
|
3757
3748
|
ExportPdfLayout.displayName = "ExportPdfLayout";
|
|
3758
3749
|
|
|
3759
|
-
/**
|
|
3760
|
-
* Captures [data-export-page] elements and saves a multi-page PDF.
|
|
3761
|
-
* Each page uses a custom size matching the captured content so nothing is cropped.
|
|
3750
|
+
/**
|
|
3751
|
+
* Captures [data-export-page] elements and saves a multi-page PDF.
|
|
3752
|
+
* Each page uses a custom size matching the captured content so nothing is cropped.
|
|
3762
3753
|
*/
|
|
3763
3754
|
function exportReportPdf(_x, _x2) {
|
|
3764
3755
|
return _exportReportPdf.apply(this, arguments);
|
|
@@ -6920,8 +6911,7 @@ var RefundsChargebacksCard = function RefundsChargebacksCard(_ref) {
|
|
|
6920
6911
|
data: chargebackSeries
|
|
6921
6912
|
}];
|
|
6922
6913
|
var fmt = function fmt(n) {
|
|
6923
|
-
|
|
6924
|
-
return n >= 1000 ? "".concat((n / 1000).toFixed(1), "k") : parseFloat((_n$toFixed = n === null || n === void 0 ? void 0 : n.toFixed(2)) !== null && _n$toFixed !== void 0 ? _n$toFixed : 0).toString();
|
|
6914
|
+
return Number(n !== null && n !== void 0 ? n : 0).toFixed(2);
|
|
6925
6915
|
};
|
|
6926
6916
|
var growthColor = growthPercentage > 0 ? "#EF4444" : growthPercentage < 0 ? "#22C55E" : "rgba(0,0,0,0.4)";
|
|
6927
6917
|
var growthLabel = growthPercentage > 0 ? "\u25B2 ".concat(growthPercentage.toFixed(1), "%") : growthPercentage < 0 ? "\u25BC ".concat(Math.abs(growthPercentage).toFixed(1), "%") : "stable";
|
|
@@ -8095,7 +8085,7 @@ var UTMPerformance = function UTMPerformance() {
|
|
|
8095
8085
|
tickAmount: 3,
|
|
8096
8086
|
labels: {
|
|
8097
8087
|
formatter: function formatter(v) {
|
|
8098
|
-
return metric === "Revenue" ? "$".concat(
|
|
8088
|
+
return metric === "Revenue" ? "$".concat(Number(v).toFixed(2)) : Number(v).toFixed(2);
|
|
8099
8089
|
},
|
|
8100
8090
|
style: {
|
|
8101
8091
|
fontSize: "11px",
|