@ammarkhalidfarooq/dashboard-package 0.4.89 → 0.4.90
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 +8 -7
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +8 -7
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -5271,7 +5271,7 @@ var MetricCard = function MetricCard(_ref) {
|
|
|
5271
5271
|
};
|
|
5272
5272
|
|
|
5273
5273
|
var OverallSection = function OverallSection(_ref) {
|
|
5274
|
-
var _apiData$totalRaisedP, _apiData$
|
|
5274
|
+
var _apiData$overviewStat, _apiData$totalRaisedP, _apiData$overviewStat2, _apiData$netRaisedPre, _apiData$overviewStat3, _apiData$overviewStat4, _apiData$averageDonat, _apiData$roasCard, _apiData$roasCardPrev, _orderBumpData$prevTr;
|
|
5275
5275
|
var _ref$apiData = _ref.apiData,
|
|
5276
5276
|
apiData = _ref$apiData === void 0 ? {} : _ref$apiData,
|
|
5277
5277
|
primaryCharts = _ref.primaryCharts,
|
|
@@ -5330,7 +5330,7 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5330
5330
|
};
|
|
5331
5331
|
var metricInfo = {
|
|
5332
5332
|
"Total Raised": {
|
|
5333
|
-
value: "$".concat(formatNumber(apiData === null || apiData === void 0 ? void 0 :
|
|
5333
|
+
value: "$".concat(formatNumber(apiData === null || apiData === void 0 || (_apiData$overviewStat = apiData.overviewStats) === null || _apiData$overviewStat === void 0 || (_apiData$overviewStat = _apiData$overviewStat.overview) === null || _apiData$overviewStat === void 0 ? void 0 : _apiData$overviewStat.totalRevenue)) || "$240.9K",
|
|
5334
5334
|
subValue: "".concat(Number((_apiData$totalRaisedP = apiData === null || apiData === void 0 ? void 0 : apiData.totalRaisedPrev) !== null && _apiData$totalRaisedP !== void 0 ? _apiData$totalRaisedP : 0).toFixed(2), "% vs ").concat(dateName || "last month"),
|
|
5335
5335
|
label: "Total Raised",
|
|
5336
5336
|
icon: /*#__PURE__*/jsx(PaidOutlined, {}),
|
|
@@ -5339,7 +5339,7 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5339
5339
|
warning: false
|
|
5340
5340
|
},
|
|
5341
5341
|
"Net Raised": {
|
|
5342
|
-
value: "$".concat(formatNumber((_apiData$
|
|
5342
|
+
value: "$".concat(formatNumber(apiData === null || apiData === void 0 || (_apiData$overviewStat2 = apiData.overviewStats) === null || _apiData$overviewStat2 === void 0 || (_apiData$overviewStat2 = _apiData$overviewStat2.overview) === null || _apiData$overviewStat2 === void 0 ? void 0 : _apiData$overviewStat2.netRevenue)),
|
|
5343
5343
|
subValue: "".concat(Number((_apiData$netRaisedPre = apiData === null || apiData === void 0 ? void 0 : apiData.netRaisedPrev) !== null && _apiData$netRaisedPre !== void 0 ? _apiData$netRaisedPre : 0).toFixed(2), "% vs ").concat(dateName !== null && dateName !== void 0 ? dateName : "previous period"),
|
|
5344
5344
|
label: "Net Raised",
|
|
5345
5345
|
icon: /*#__PURE__*/jsx(FavoriteOutlined, {}),
|
|
@@ -5348,7 +5348,7 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5348
5348
|
warning: false
|
|
5349
5349
|
},
|
|
5350
5350
|
"Total Donors": {
|
|
5351
|
-
value: (apiData === null || apiData === void 0 ? void 0 :
|
|
5351
|
+
value: (apiData === null || apiData === void 0 || (_apiData$overviewStat3 = apiData.overviewStats) === null || _apiData$overviewStat3 === void 0 || (_apiData$overviewStat3 = _apiData$overviewStat3.overview) === null || _apiData$overviewStat3 === void 0 ? void 0 : _apiData$overviewStat3.totalDonations) || "215",
|
|
5352
5352
|
subValue: "".concat(apiData === null || apiData === void 0 ? void 0 : apiData.totalDonorsPrev, " new") || "31 new",
|
|
5353
5353
|
label: "Total Donors",
|
|
5354
5354
|
icon: /*#__PURE__*/jsx(PeopleAltOutlined, {}),
|
|
@@ -5357,8 +5357,8 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5357
5357
|
warning: false
|
|
5358
5358
|
},
|
|
5359
5359
|
"Avg donation": {
|
|
5360
|
-
value: "$".concat(formatNumber((_apiData$
|
|
5361
|
-
subValue: "".concat(Number((_apiData$
|
|
5360
|
+
value: "$".concat(formatNumber(apiData === null || apiData === void 0 || (_apiData$overviewStat4 = apiData.overviewStats) === null || _apiData$overviewStat4 === void 0 || (_apiData$overviewStat4 = _apiData$overviewStat4.overview) === null || _apiData$overviewStat4 === void 0 ? void 0 : _apiData$overviewStat4.overallAVGDonations)),
|
|
5361
|
+
subValue: "".concat(Number((_apiData$averageDonat = apiData === null || apiData === void 0 ? void 0 : apiData.averageDonationsCardPrev) !== null && _apiData$averageDonat !== void 0 ? _apiData$averageDonat : 0).toFixed(2), "% vs ").concat(dateName !== null && dateName !== void 0 ? dateName : "last month"),
|
|
5362
5362
|
label: "Average Donation Amount",
|
|
5363
5363
|
icon: /*#__PURE__*/jsx(PaidOutlined, {}),
|
|
5364
5364
|
money: true,
|
|
@@ -5459,7 +5459,8 @@ var OverallSection = function OverallSection(_ref) {
|
|
|
5459
5459
|
return c.label === selectedInfo.label;
|
|
5460
5460
|
}) || primaryCharts[0];
|
|
5461
5461
|
if (activeMetric === "Total Raised") {
|
|
5462
|
-
var
|
|
5462
|
+
var _apiData$overviewStat5;
|
|
5463
|
+
var stackedData = apiData === null || apiData === void 0 || (_apiData$overviewStat5 = apiData.overviewStats) === null || _apiData$overviewStat5 === void 0 ? void 0 : _apiData$overviewStat5.totalRaised;
|
|
5463
5464
|
var hasStackedData = (stackedData === null || stackedData === void 0 ? void 0 : stackedData.paidAds) || (stackedData === null || stackedData === void 0 ? void 0 : stackedData.email) || (stackedData === null || stackedData === void 0 ? void 0 : stackedData.organic);
|
|
5464
5465
|
if (hasStackedData) {
|
|
5465
5466
|
var categories = ((stackedData === null || stackedData === void 0 ? void 0 : stackedData.organic) || (stackedData === null || stackedData === void 0 ? void 0 : stackedData.paidAds) || (stackedData === null || stackedData === void 0 ? void 0 : stackedData.email) || []).map(function (item) {
|