@ammarkhalidfarooq/dashboard-package 0.4.44 → 0.4.45
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 +58 -23
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +58 -23
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -6238,40 +6238,58 @@ var OrganicSection = function OrganicSection(_ref) {
|
|
|
6238
6238
|
var categories = ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"];
|
|
6239
6239
|
var metricInfo = {
|
|
6240
6240
|
"Organic Users": {
|
|
6241
|
-
value: (
|
|
6241
|
+
value: "".concat(formatNumber(8420)),
|
|
6242
6242
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.totalRaisedTrend) || "18% vs last month",
|
|
6243
6243
|
data: [3200, 4100, 2800, 5600, 4200, 6100, 7500],
|
|
6244
|
-
icon: PeopleAltOutlined
|
|
6244
|
+
icon: /*#__PURE__*/jsx(PeopleAltOutlined, {}),
|
|
6245
|
+
money: false,
|
|
6246
|
+
warning: false,
|
|
6247
|
+
error: false
|
|
6245
6248
|
},
|
|
6246
6249
|
"Search Clicks": {
|
|
6247
|
-
value: (
|
|
6250
|
+
value: "".concat(formatNumber(5842)),
|
|
6248
6251
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.netRaisedSub) || "92.3% pass-through",
|
|
6249
6252
|
data: [1500, 1800, 1600, 2200, 2000, 2400, 2800],
|
|
6250
|
-
icon: SearchOutlined
|
|
6253
|
+
icon: /*#__PURE__*/jsx(SearchOutlined, {}),
|
|
6254
|
+
money: false,
|
|
6255
|
+
warning: false,
|
|
6256
|
+
error: false
|
|
6251
6257
|
},
|
|
6252
6258
|
Donations: {
|
|
6253
|
-
value: (
|
|
6259
|
+
value: "".concat(formatNumber(420)),
|
|
6254
6260
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.totalRaisedTrend) || "18% vs last month",
|
|
6255
6261
|
data: [15, 22, 18, 30, 25, 35, 42],
|
|
6256
|
-
icon: FavoriteOutlined
|
|
6262
|
+
icon: /*#__PURE__*/jsx(FavoriteOutlined, {}),
|
|
6263
|
+
money: false,
|
|
6264
|
+
warning: false,
|
|
6265
|
+
error: false
|
|
6257
6266
|
},
|
|
6258
6267
|
"Conversion Rate": {
|
|
6259
6268
|
value: "3.1%",
|
|
6260
6269
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.avgDonationTrend) || "8.4% vs last month",
|
|
6261
6270
|
data: [2.5, 2.7, 2.6, 3.1, 3.0, 2.9, 3.1],
|
|
6262
|
-
icon: Adjust
|
|
6271
|
+
icon: /*#__PURE__*/jsx(Adjust, {}),
|
|
6272
|
+
money: false,
|
|
6273
|
+
warning: false,
|
|
6274
|
+
error: false
|
|
6263
6275
|
},
|
|
6264
6276
|
"Revenue raised": {
|
|
6265
|
-
value: (
|
|
6277
|
+
value: "$".concat(formatNumber(240398)),
|
|
6266
6278
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.roasTrend) || "0.4x vs last month",
|
|
6267
6279
|
data: [2.5, 3.1, 2.8, 4.2, 3.8, 4.5, 5.2],
|
|
6268
|
-
icon: PaidOutlined
|
|
6280
|
+
icon: /*#__PURE__*/jsx(PaidOutlined, {}),
|
|
6281
|
+
money: true,
|
|
6282
|
+
warning: false,
|
|
6283
|
+
error: false
|
|
6269
6284
|
},
|
|
6270
6285
|
"Avg donation": {
|
|
6271
|
-
value: (
|
|
6286
|
+
value: "$".concat(formatNumber(130.58)),
|
|
6272
6287
|
subValue: (apiData === null || apiData === void 0 ? void 0 : apiData.totalRaisedTrend) || "18% vs last month",
|
|
6273
6288
|
data: [110, 125, 120, 135, 130, 128, 130.58],
|
|
6274
|
-
icon: PaidOutlined
|
|
6289
|
+
icon: /*#__PURE__*/jsx(PaidOutlined, {}),
|
|
6290
|
+
money: true,
|
|
6291
|
+
warning: false,
|
|
6292
|
+
error: false
|
|
6275
6293
|
}
|
|
6276
6294
|
};
|
|
6277
6295
|
var selectedInfo = metricInfo[activeMetric];
|
|
@@ -6291,23 +6309,40 @@ var OrganicSection = function OrganicSection(_ref) {
|
|
|
6291
6309
|
flexWrap: "wrap"
|
|
6292
6310
|
},
|
|
6293
6311
|
children: Object.keys(metricInfo).map(function (title) {
|
|
6294
|
-
return /*#__PURE__*/jsx(
|
|
6312
|
+
return /*#__PURE__*/jsx(MetricCard
|
|
6313
|
+
// key={title}
|
|
6314
|
+
, {
|
|
6295
6315
|
title: title,
|
|
6296
|
-
value: metricInfo[title].value,
|
|
6297
|
-
|
|
6316
|
+
value: metricInfo[title].money ? metricInfo[title].value : metricInfo[title].value,
|
|
6317
|
+
caption: metricInfo[title].subValue,
|
|
6298
6318
|
icon: metricInfo[title].icon,
|
|
6319
|
+
error: metricInfo[title].error,
|
|
6320
|
+
active: activeMetric === title,
|
|
6299
6321
|
onClick: function onClick() {
|
|
6300
6322
|
return setActiveMetric(title);
|
|
6301
6323
|
},
|
|
6302
|
-
|
|
6303
|
-
|
|
6304
|
-
|
|
6305
|
-
|
|
6306
|
-
|
|
6307
|
-
|
|
6308
|
-
|
|
6309
|
-
|
|
6310
|
-
}
|
|
6324
|
+
sx: metricInfo[title].error ? {
|
|
6325
|
+
border: "2px solid #ef4444",
|
|
6326
|
+
bgcolor: "#fffafa"
|
|
6327
|
+
} : {}
|
|
6328
|
+
})
|
|
6329
|
+
// <DisplayCard
|
|
6330
|
+
// key={title}
|
|
6331
|
+
// title={title}
|
|
6332
|
+
// value={metricInfo[title].value}
|
|
6333
|
+
// subValue={metricInfo[title].subValue}
|
|
6334
|
+
// icon={metricInfo[title].icon}
|
|
6335
|
+
// onClick={() => setActiveMetric(title)}
|
|
6336
|
+
// isActive={activeMetric === title}
|
|
6337
|
+
// sx={{
|
|
6338
|
+
// flex: 1,
|
|
6339
|
+
// // border:
|
|
6340
|
+
// // activeMetric === title
|
|
6341
|
+
// // ? "2px solid rgb(99, 99, 230)"
|
|
6342
|
+
// // : "2px solid #f0f0f0",
|
|
6343
|
+
// }}
|
|
6344
|
+
// />
|
|
6345
|
+
;
|
|
6311
6346
|
})
|
|
6312
6347
|
}), /*#__PURE__*/jsxs(Grid, {
|
|
6313
6348
|
container: true,
|