@ammarkhalidfarooq/dashboard-package 0.4.80 → 0.4.82
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 +5 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +5 -4
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -5295,6 +5295,7 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5295
5295
|
}
|
|
5296
5296
|
};
|
|
5297
5297
|
var activeCampaignsData = (apiData === null || apiData === void 0 ? void 0 : apiData.activeCampaigns) || [];
|
|
5298
|
+
console.log("ACtive campaigns", activeCampaignsData);
|
|
5298
5299
|
var donorMix = (apiData === null || apiData === void 0 ? void 0 : apiData.donorMix) || {};
|
|
5299
5300
|
var totalDonorsMix = (donorMix.newDonors || 0) + (donorMix.returningDonors || 0);
|
|
5300
5301
|
var newDonorsPerc = totalDonorsMix > 0 ? Math.round(donorMix.newDonors / totalDonorsMix * 100) : 0;
|
|
@@ -5673,11 +5674,11 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5673
5674
|
id: campaign.campaignName ? campaign.campaignName.split(" ").filter(Boolean).map(function (word) {
|
|
5674
5675
|
return word[0];
|
|
5675
5676
|
}).join("").toUpperCase().slice(0, 2) : "??",
|
|
5676
|
-
name: campaign.
|
|
5677
|
-
val1: "$".concat(formatNumber(campaign.
|
|
5677
|
+
name: campaign.title || "Untitled Campaign",
|
|
5678
|
+
val1: "$".concat(formatNumber(campaign.collectedAmount || 0)),
|
|
5678
5679
|
type: "progress",
|
|
5679
|
-
progress: Math.round((campaign.
|
|
5680
|
-
val3: formatNumber(campaign.
|
|
5680
|
+
progress: Math.round((campaign.collectedAmount || 0) / (campaign.usdTargetAmount || 1) * 100),
|
|
5681
|
+
val3: formatNumber(campaign.uniqueDonationsCount || 0),
|
|
5681
5682
|
val4: "$".concat(formatNumber(campaign.avgGift || 0))
|
|
5682
5683
|
};
|
|
5683
5684
|
})
|