@ammarkhalidfarooq/dashboard-package 0.5.14 → 0.5.15
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 +4 -2
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +4 -2
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -940,7 +940,7 @@ var NewOverview = function NewOverview(_ref) {
|
|
|
940
940
|
if (exportTrigger <= 0) return;
|
|
941
941
|
var buildAndDownloadPdf = /*#__PURE__*/function () {
|
|
942
942
|
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
|
|
943
|
-
var _apiData$overviewStat, _apiData$overviewStat2, _apiData$trafficSourc, _apiData$recurringBar, _apiData$recurringBar2, _apiData$roasCard, _apiData$overviewStat3, _apiData$overviewStat4, _apiData$overviewStat5, _apiData$overviewStat6, _apiData$overviewStat7, _apiData$overviewStat8, _doc$lastAutoTable, _doc$lastAutoTable2, _apiData$orderBumpDet, _apiData$orderBumpDet2, _apiData$orderBumpDet3, _apiData$orderBumpDet4, _apiData$upSellDetail, _apiData$upSellDetail2, _apiData$downSellDeta, _apiData$downSellDeta2, _apiData$referralDeta, _apiData$referralDeta2, _yield$Promise$all, _yield$Promise$all2, jsPDF, autoTableModule, autoTable, growth, overview, dateLabel, generatedAt, generatedLabel, fmtPct, fmtSigned, doc, pageWidth, marginX, contentWidth, cardGap, cardWidth, addHeader, addFooter, metricCard, donorMixRaw, newDonorsCount, returningDonorsCount, avgGift, newDonorsObj, returningDonorsObj, totalAmount, totalCount, activeCampaignRows, trafficRows, donorMixRows, recurringTotal, oneTimeTotalValue, donorGeoRows, refundsData, totalRaised, netRaised, totalDonors, convRate, avgDonation, totalVisits, passThrough, refundRate, chargebackRate, page1Cards, y, trendY, donorCardTop, cardsTop, halfGap, halfW, drawInfoCard, safeDate, _t;
|
|
943
|
+
var _apiData$overviewStat, _apiData$overviewStat2, _apiData$trafficSourc, _apiData$recurringBar, _apiData$recurringBar2, _apiData$roasCard, _apiData$overviewStat3, _apiData$overviewStat4, _apiData$overviewStat5, _apiData$overviewStat6, _apiData$overviewStat7, _apiData$overviewStat8, _doc$lastAutoTable, _doc$lastAutoTable2, _apiData$orderBumpDet, _apiData$orderBumpDet2, _apiData$orderBumpDet3, _apiData$orderBumpDet4, _apiData$upSellDetail, _apiData$upSellDetail2, _apiData$downSellDeta, _apiData$downSellDeta2, _apiData$referralDeta, _apiData$referralDeta2, _yield$Promise$all, _yield$Promise$all2, jsPDF, autoTableModule, autoTable, growth, overview, dateLabel, generatedAt, generatedLabel, fmtPct, fmtSigned, doc, pageWidth, marginX, contentWidth, cardGap, cardWidth, addHeader, addFooter, metricCard, donorMixRaw, newDonorsCount, returningDonorsCount, avgGift, newDonorsObj, returningDonorsObj, totalAmount, totalCount, activeCampaignRows, trafficRows, donorMixRows, recurringTotal, oneTimeTotalValue, donorGeographyRaw, donorGeographyList, donorGeoRows, refundsData, totalRaised, netRaised, totalDonors, convRate, avgDonation, totalVisits, passThrough, refundRate, chargebackRate, page1Cards, y, trendY, donorCardTop, cardsTop, halfGap, halfW, drawInfoCard, safeDate, _t;
|
|
944
944
|
return _regenerator().w(function (_context) {
|
|
945
945
|
while (1) switch (_context.p = _context.n) {
|
|
946
946
|
case 0:
|
|
@@ -1063,7 +1063,9 @@ var NewOverview = function NewOverview(_ref) {
|
|
|
1063
1063
|
donorMixRows = [["New donors", "".concat(formatNumber(newDonorsCount))], ["Returning donors", "".concat(formatNumber(returningDonorsCount))], ["Avg gift", "$".concat(formatNumber(avgGift))]];
|
|
1064
1064
|
recurringTotal = Number((apiData === null || apiData === void 0 || (_apiData$recurringBar = apiData.recurringBarChartData) === null || _apiData$recurringBar === void 0 ? void 0 : _apiData$recurringBar.recurringTotal) || 0);
|
|
1065
1065
|
oneTimeTotalValue = Number((apiData === null || apiData === void 0 || (_apiData$recurringBar2 = apiData.recurringBarChartData) === null || _apiData$recurringBar2 === void 0 ? void 0 : _apiData$recurringBar2.oneTimeTotal) || 0);
|
|
1066
|
-
|
|
1066
|
+
donorGeographyRaw = apiData === null || apiData === void 0 ? void 0 : apiData.donorGeography;
|
|
1067
|
+
donorGeographyList = Array.isArray(donorGeographyRaw) ? donorGeographyRaw : Array.isArray(donorGeographyRaw === null || donorGeographyRaw === void 0 ? void 0 : donorGeographyRaw.data) ? donorGeographyRaw.data : [];
|
|
1068
|
+
donorGeoRows = donorGeographyList.slice(0, 6).map(function (item) {
|
|
1067
1069
|
return [item.country || item.name || "-", "".concat(formatNumber(item.totalDonors || item.donors || 0)), "".concat(formatNumber(item.percentage || 0), "%")];
|
|
1068
1070
|
});
|
|
1069
1071
|
refundsData = (apiData === null || apiData === void 0 ? void 0 : apiData.refundAndChargeBacks) || {};
|