@retinalabsllc/zairusjs 14.0.40 → 14.0.50
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.d.mts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +23 -12
- package/dist/index.mjs +28 -17
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -209,6 +209,8 @@ interface UniversalTransaction {
|
|
|
209
209
|
direction: 'CREDIT' | 'DEBIT';
|
|
210
210
|
amount: string;
|
|
211
211
|
currency: string;
|
|
212
|
+
name?: string;
|
|
213
|
+
description?: string;
|
|
212
214
|
status: 'PENDING' | 'COMPLETED' | 'FAILED' | 'REVERSED';
|
|
213
215
|
reference: string;
|
|
214
216
|
metadata?: any;
|
package/dist/index.d.ts
CHANGED
|
@@ -209,6 +209,8 @@ interface UniversalTransaction {
|
|
|
209
209
|
direction: 'CREDIT' | 'DEBIT';
|
|
210
210
|
amount: string;
|
|
211
211
|
currency: string;
|
|
212
|
+
name?: string;
|
|
213
|
+
description?: string;
|
|
212
214
|
status: 'PENDING' | 'COMPLETED' | 'FAILED' | 'REVERSED';
|
|
213
215
|
reference: string;
|
|
214
216
|
metadata?: any;
|
package/dist/index.js
CHANGED
|
@@ -1362,11 +1362,6 @@ var UniversalTransactionPage = ({
|
|
|
1362
1362
|
setLocalSearchQuery("");
|
|
1363
1363
|
}
|
|
1364
1364
|
}, [searchQuery]);
|
|
1365
|
-
const getDisplayName = (tx) => {
|
|
1366
|
-
if (tx.metadata?.merchantName) return tx.metadata.merchantName;
|
|
1367
|
-
if (tx.metadata?.description) return tx.metadata.description;
|
|
1368
|
-
return tx.type === "CARD_TRANSACTION" ? "Card Transaction" : "Wallet Transaction";
|
|
1369
|
-
};
|
|
1370
1365
|
const handleGenerateReceipt = async () => {
|
|
1371
1366
|
if (!onGenerateReceipt || !selectedTransaction) return;
|
|
1372
1367
|
setIsGeneratingReceipt(true);
|
|
@@ -1417,7 +1412,7 @@ var UniversalTransactionPage = ({
|
|
|
1417
1412
|
onClick: () => setSelectedTransaction(tx),
|
|
1418
1413
|
className: "flex items-center justify-between py-4 hover:bg-neutral-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-xl"
|
|
1419
1414
|
},
|
|
1420
|
-
/* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center gap-4 min-w-0 flex-1" }, /* @__PURE__ */ import_react23.default.createElement("div", { className: `w-10 h-10 shrink-0 rounded-full flex items-center justify-center bg-neutral-100 text-black` }, /* @__PURE__ */ import_react23.default.createElement(import_react24.HugeiconsIcon, { icon: tx.direction === "CREDIT" ? import_core_free_icons7.ArrowDownRight01Icon : import_core_free_icons7.ArrowUpRight01Icon, size: 18 })), /* @__PURE__ */ import_react23.default.createElement("div", { className: "min-w-0 flex-1 flex flex-col gap-1" }, /* @__PURE__ */ import_react23.default.createElement("p", { className: "text-[13px] text-black truncate" },
|
|
1415
|
+
/* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center gap-4 min-w-0 flex-1" }, /* @__PURE__ */ import_react23.default.createElement("div", { className: `w-10 h-10 shrink-0 rounded-full flex items-center justify-center bg-neutral-100 text-black` }, /* @__PURE__ */ import_react23.default.createElement(import_react24.HugeiconsIcon, { icon: tx.direction === "CREDIT" ? import_core_free_icons7.ArrowDownRight01Icon : import_core_free_icons7.ArrowUpRight01Icon, size: 18 })), /* @__PURE__ */ import_react23.default.createElement("div", { className: "min-w-0 flex-1 flex flex-col gap-1" }, /* @__PURE__ */ import_react23.default.createElement("p", { className: "text-[13px] text-black truncate" }, tx.name), /* @__PURE__ */ import_react23.default.createElement("p", { className: `text-[12px] text-neutral-500 truncate transition-all duration-300 ${hideBalanceAmounts ? "blur-sm opacity-40 select-none" : ""}` }, tx.amount))),
|
|
1421
1416
|
/* @__PURE__ */ import_react23.default.createElement("div", { className: "shrink-0 flex flex-col items-end gap-1 text-right" }, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] text-neutral-400" }, formatDate2(tx.createdAt)), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] text-neutral-400 capitalize" }, tx.direction.toLowerCase()))
|
|
1422
1417
|
))), !hidePagination && /* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center justify-between pt-6 mt-2 " }, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] text-neutral-400 tracking-[0.2em]" }, "Page ", currentPage, " of ", totalPages === 0 ? 1 : totalPages), /* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ import_react23.default.createElement(
|
|
1423
1418
|
"button",
|
|
@@ -1442,7 +1437,7 @@ var UniversalTransactionPage = ({
|
|
|
1442
1437
|
className: "text-neutral-400 hover:text-black transition-colors outline-none"
|
|
1443
1438
|
},
|
|
1444
1439
|
/* @__PURE__ */ import_react23.default.createElement(import_react24.HugeiconsIcon, { icon: import_core_free_icons7.Copy01Icon, size: 14 })
|
|
1445
|
-
))), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Date & Time"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black" }, formatDate2(selectedTransaction.createdAt), " at ", formatTime(selectedTransaction.createdAt))), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transaction Type"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.type.replace("_", " ").toLowerCase())), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Flow Direction"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.direction.toLowerCase())), selectedTransaction.metadata?.fromAddress && selectedTransaction.metadata?.toAddress && /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transfer Route"), /* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center gap-2 text-[13px] text-black" }, /* @__PURE__ */ import_react23.default.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.fromAddress))), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-neutral-400" }, "\u2192"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.toAddress))))), selectedTransaction.metadata && Object.entries(selectedTransaction.metadata).map(([key, value]) => {
|
|
1440
|
+
))), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Description"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black" }, selectedTransaction.description)), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Date & Time"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black" }, formatDate2(selectedTransaction.createdAt), " at ", formatTime(selectedTransaction.createdAt))), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transaction Type"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.type.replace("_", " ").toLowerCase())), /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Flow Direction"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.direction.toLowerCase())), selectedTransaction.metadata?.fromAddress && selectedTransaction.metadata?.toAddress && /* @__PURE__ */ import_react23.default.createElement("div", null, /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transfer Route"), /* @__PURE__ */ import_react23.default.createElement("div", { className: "flex items-center gap-2 text-[13px] text-black" }, /* @__PURE__ */ import_react23.default.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.fromAddress))), /* @__PURE__ */ import_react23.default.createElement("span", { className: "text-neutral-400" }, "\u2192"), /* @__PURE__ */ import_react23.default.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.toAddress))))), selectedTransaction.metadata && Object.entries(selectedTransaction.metadata).map(([key, value]) => {
|
|
1446
1441
|
if (key === "fromAddress" || key === "toAddress") return null;
|
|
1447
1442
|
if (value === null || value === void 0 || typeof value === "object") return null;
|
|
1448
1443
|
const formattedKey = key.includes(" ") ? key : key.replace(/([A-Z])/g, " $1").replace(/^./, (str) => str.toUpperCase());
|
|
@@ -1523,7 +1518,23 @@ var renderKMT = (val, currencySymbol) => {
|
|
|
1523
1518
|
suffix = "k";
|
|
1524
1519
|
}
|
|
1525
1520
|
const displayStr = parseFloat(formatted.toFixed(2)).toString();
|
|
1526
|
-
return /* @__PURE__ */ import_react25.default.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[13px] text-neutral-
|
|
1521
|
+
return /* @__PURE__ */ import_react25.default.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[13px] text-neutral-800 mr-0.5 " }, currencySymbol), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-xl text-neutral-800 tracking-tight " }, displayStr), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[14px] text-neutral-600 ml-0.5 " }, suffix));
|
|
1522
|
+
};
|
|
1523
|
+
var renderKMT2 = (val, currencySymbol) => {
|
|
1524
|
+
let formatted = val;
|
|
1525
|
+
let suffix = "";
|
|
1526
|
+
if (val >= 1e12) {
|
|
1527
|
+
formatted = val / 1e12;
|
|
1528
|
+
suffix = "T";
|
|
1529
|
+
} else if (val >= 1e6) {
|
|
1530
|
+
formatted = val / 1e6;
|
|
1531
|
+
suffix = "M";
|
|
1532
|
+
} else if (val >= 1e3) {
|
|
1533
|
+
formatted = val / 1e3;
|
|
1534
|
+
suffix = "k";
|
|
1535
|
+
}
|
|
1536
|
+
const displayStr = parseFloat(formatted.toFixed(2)).toString();
|
|
1537
|
+
return /* @__PURE__ */ import_react25.default.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[13px] text-white mr-0.5 " }, currencySymbol), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-xl text-white tracking-tight " }, displayStr), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[14px] text-white/50 ml-0.5 " }, suffix));
|
|
1527
1538
|
};
|
|
1528
1539
|
var UniversalHomeView = ({
|
|
1529
1540
|
fullName = "",
|
|
@@ -1623,17 +1634,17 @@ var UniversalHomeView = ({
|
|
|
1623
1634
|
className: "px-6 py-2 bg-transparent border border-white/20 text-white truncate text-[12px] rounded-full transition-colors hover:bg-white/10 outline-none text-center"
|
|
1624
1635
|
},
|
|
1625
1636
|
"Rewards"
|
|
1626
|
-
)))), /* @__PURE__ */ import_react25.default.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "bg-[
|
|
1637
|
+
)))), /* @__PURE__ */ import_react25.default.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "bg-[#143731] rounded-2xl p-5 relative overflow-hidden flex flex-col h-45 sm:h-50" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-white mb-1" }, "Cashback"), renderKMT2(cashbackValue, balanceCurrency)), /* @__PURE__ */ import_react25.default.createElement(
|
|
1627
1638
|
"img",
|
|
1628
1639
|
{
|
|
1629
|
-
src: "https://retinalabs.company/assets/images/
|
|
1640
|
+
src: "https://retinalabs.company/assets/images/save_box.avif",
|
|
1630
1641
|
alt: "Cashback",
|
|
1631
1642
|
className: "absolute bottom-6 right-4 translate-x-1/4 translate-y-1/2 w-40 h-auto object-contain z-0 pointer-events-none drop-shadow-md"
|
|
1632
1643
|
}
|
|
1633
|
-
)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "bg-[
|
|
1644
|
+
)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "bg-[#ceff8a] rounded-2xl p-5 relative overflow-hidden flex flex-col h-45 sm:h-50" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-black mb-1" }, "Rewards"), renderKMT(rewardsValue, balanceCurrency)), /* @__PURE__ */ import_react25.default.createElement(
|
|
1634
1645
|
"img",
|
|
1635
1646
|
{
|
|
1636
|
-
src: "https://retinalabs.company/assets/images/
|
|
1647
|
+
src: "https://retinalabs.company/assets/images/gift_box.avif",
|
|
1637
1648
|
alt: "Rewards",
|
|
1638
1649
|
className: "absolute bottom-6 right-4 translate-x-1/4 translate-y-1/2 w-40 h-auto object-contain z-0 pointer-events-none drop-shadow-md"
|
|
1639
1650
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -1311,11 +1311,6 @@ var UniversalTransactionPage = ({
|
|
|
1311
1311
|
setLocalSearchQuery("");
|
|
1312
1312
|
}
|
|
1313
1313
|
}, [searchQuery]);
|
|
1314
|
-
const getDisplayName = (tx) => {
|
|
1315
|
-
if (tx.metadata?.merchantName) return tx.metadata.merchantName;
|
|
1316
|
-
if (tx.metadata?.description) return tx.metadata.description;
|
|
1317
|
-
return tx.type === "CARD_TRANSACTION" ? "Card Transaction" : "Wallet Transaction";
|
|
1318
|
-
};
|
|
1319
1314
|
const handleGenerateReceipt = async () => {
|
|
1320
1315
|
if (!onGenerateReceipt || !selectedTransaction) return;
|
|
1321
1316
|
setIsGeneratingReceipt(true);
|
|
@@ -1366,7 +1361,7 @@ var UniversalTransactionPage = ({
|
|
|
1366
1361
|
onClick: () => setSelectedTransaction(tx),
|
|
1367
1362
|
className: "flex items-center justify-between py-4 hover:bg-neutral-50 transition-colors cursor-pointer group min-w-0 px-3 -mx-3 rounded-xl"
|
|
1368
1363
|
},
|
|
1369
|
-
/* @__PURE__ */ React15.createElement("div", { className: "flex items-center gap-4 min-w-0 flex-1" }, /* @__PURE__ */ React15.createElement("div", { className: `w-10 h-10 shrink-0 rounded-full flex items-center justify-center bg-neutral-100 text-black` }, /* @__PURE__ */ React15.createElement(HugeiconsIcon9, { icon: tx.direction === "CREDIT" ? ArrowDownRight01Icon : ArrowUpRight01Icon, size: 18 })), /* @__PURE__ */ React15.createElement("div", { className: "min-w-0 flex-1 flex flex-col gap-1" }, /* @__PURE__ */ React15.createElement("p", { className: "text-[13px] text-black truncate" },
|
|
1364
|
+
/* @__PURE__ */ React15.createElement("div", { className: "flex items-center gap-4 min-w-0 flex-1" }, /* @__PURE__ */ React15.createElement("div", { className: `w-10 h-10 shrink-0 rounded-full flex items-center justify-center bg-neutral-100 text-black` }, /* @__PURE__ */ React15.createElement(HugeiconsIcon9, { icon: tx.direction === "CREDIT" ? ArrowDownRight01Icon : ArrowUpRight01Icon, size: 18 })), /* @__PURE__ */ React15.createElement("div", { className: "min-w-0 flex-1 flex flex-col gap-1" }, /* @__PURE__ */ React15.createElement("p", { className: "text-[13px] text-black truncate" }, tx.name), /* @__PURE__ */ React15.createElement("p", { className: `text-[12px] text-neutral-500 truncate transition-all duration-300 ${hideBalanceAmounts ? "blur-sm opacity-40 select-none" : ""}` }, tx.amount))),
|
|
1370
1365
|
/* @__PURE__ */ React15.createElement("div", { className: "shrink-0 flex flex-col items-end gap-1 text-right" }, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] text-neutral-400" }, formatDate2(tx.createdAt)), /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] text-neutral-400 capitalize" }, tx.direction.toLowerCase()))
|
|
1371
1366
|
))), !hidePagination && /* @__PURE__ */ React15.createElement("div", { className: "flex items-center justify-between pt-6 mt-2 " }, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] text-neutral-400 tracking-[0.2em]" }, "Page ", currentPage, " of ", totalPages === 0 ? 1 : totalPages), /* @__PURE__ */ React15.createElement("div", { className: "flex items-center gap-2" }, /* @__PURE__ */ React15.createElement(
|
|
1372
1367
|
"button",
|
|
@@ -1391,7 +1386,7 @@ var UniversalTransactionPage = ({
|
|
|
1391
1386
|
className: "text-neutral-400 hover:text-black transition-colors outline-none"
|
|
1392
1387
|
},
|
|
1393
1388
|
/* @__PURE__ */ React15.createElement(HugeiconsIcon9, { icon: Copy01Icon, size: 14 })
|
|
1394
|
-
))), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Date & Time"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black" }, formatDate2(selectedTransaction.createdAt), " at ", formatTime(selectedTransaction.createdAt))), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transaction Type"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.type.replace("_", " ").toLowerCase())), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Flow Direction"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.direction.toLowerCase())), selectedTransaction.metadata?.fromAddress && selectedTransaction.metadata?.toAddress && /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transfer Route"), /* @__PURE__ */ React15.createElement("div", { className: "flex items-center gap-2 text-[13px] text-black" }, /* @__PURE__ */ React15.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.fromAddress))), /* @__PURE__ */ React15.createElement("span", { className: "text-neutral-400" }, "\u2192"), /* @__PURE__ */ React15.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.toAddress))))), selectedTransaction.metadata && Object.entries(selectedTransaction.metadata).map(([key, value]) => {
|
|
1389
|
+
))), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Description"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black" }, selectedTransaction.description)), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Date & Time"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black" }, formatDate2(selectedTransaction.createdAt), " at ", formatTime(selectedTransaction.createdAt))), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transaction Type"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.type.replace("_", " ").toLowerCase())), /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Flow Direction"), /* @__PURE__ */ React15.createElement("span", { className: "text-[13px] text-black capitalize" }, selectedTransaction.direction.toLowerCase())), selectedTransaction.metadata?.fromAddress && selectedTransaction.metadata?.toAddress && /* @__PURE__ */ React15.createElement("div", null, /* @__PURE__ */ React15.createElement("span", { className: "text-[11px] tracking-[0.2em] text-neutral-400 block mb-2" }, "Transfer Route"), /* @__PURE__ */ React15.createElement("div", { className: "flex items-center gap-2 text-[13px] text-black" }, /* @__PURE__ */ React15.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.fromAddress))), /* @__PURE__ */ React15.createElement("span", { className: "text-neutral-400" }, "\u2192"), /* @__PURE__ */ React15.createElement("span", { className: "truncate" }, truncateAddress(String(selectedTransaction.metadata.toAddress))))), selectedTransaction.metadata && Object.entries(selectedTransaction.metadata).map(([key, value]) => {
|
|
1395
1390
|
if (key === "fromAddress" || key === "toAddress") return null;
|
|
1396
1391
|
if (value === null || value === void 0 || typeof value === "object") return null;
|
|
1397
1392
|
const formattedKey = key.includes(" ") ? key : key.replace(/([A-Z])/g, " $1").replace(/^./, (str) => str.toUpperCase());
|
|
@@ -1480,7 +1475,23 @@ var renderKMT = (val, currencySymbol) => {
|
|
|
1480
1475
|
suffix = "k";
|
|
1481
1476
|
}
|
|
1482
1477
|
const displayStr = parseFloat(formatted.toFixed(2)).toString();
|
|
1483
|
-
return /* @__PURE__ */ React16.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ React16.createElement("span", { className: "text-[13px] text-neutral-
|
|
1478
|
+
return /* @__PURE__ */ React16.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ React16.createElement("span", { className: "text-[13px] text-neutral-800 mr-0.5 " }, currencySymbol), /* @__PURE__ */ React16.createElement("span", { className: "text-xl text-neutral-800 tracking-tight " }, displayStr), /* @__PURE__ */ React16.createElement("span", { className: "text-[14px] text-neutral-600 ml-0.5 " }, suffix));
|
|
1479
|
+
};
|
|
1480
|
+
var renderKMT2 = (val, currencySymbol) => {
|
|
1481
|
+
let formatted = val;
|
|
1482
|
+
let suffix = "";
|
|
1483
|
+
if (val >= 1e12) {
|
|
1484
|
+
formatted = val / 1e12;
|
|
1485
|
+
suffix = "T";
|
|
1486
|
+
} else if (val >= 1e6) {
|
|
1487
|
+
formatted = val / 1e6;
|
|
1488
|
+
suffix = "M";
|
|
1489
|
+
} else if (val >= 1e3) {
|
|
1490
|
+
formatted = val / 1e3;
|
|
1491
|
+
suffix = "k";
|
|
1492
|
+
}
|
|
1493
|
+
const displayStr = parseFloat(formatted.toFixed(2)).toString();
|
|
1494
|
+
return /* @__PURE__ */ React16.createElement("span", { className: "flex items-baseline mt-1" }, /* @__PURE__ */ React16.createElement("span", { className: "text-[13px] text-white mr-0.5 " }, currencySymbol), /* @__PURE__ */ React16.createElement("span", { className: "text-xl text-white tracking-tight " }, displayStr), /* @__PURE__ */ React16.createElement("span", { className: "text-[14px] text-white/50 ml-0.5 " }, suffix));
|
|
1484
1495
|
};
|
|
1485
1496
|
var UniversalHomeView = ({
|
|
1486
1497
|
fullName = "",
|
|
@@ -1580,17 +1591,17 @@ var UniversalHomeView = ({
|
|
|
1580
1591
|
className: "px-6 py-2 bg-transparent border border-white/20 text-white truncate text-[12px] rounded-full transition-colors hover:bg-white/10 outline-none text-center"
|
|
1581
1592
|
},
|
|
1582
1593
|
"Rewards"
|
|
1583
|
-
)))), /* @__PURE__ */ React16.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ React16.createElement("div", { className: "bg-[
|
|
1594
|
+
)))), /* @__PURE__ */ React16.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ React16.createElement("div", { className: "bg-[#143731] rounded-2xl p-5 relative overflow-hidden flex flex-col h-45 sm:h-50" }, /* @__PURE__ */ React16.createElement("div", { className: "relative z-10" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-white mb-1" }, "Cashback"), renderKMT2(cashbackValue, balanceCurrency)), /* @__PURE__ */ React16.createElement(
|
|
1584
1595
|
"img",
|
|
1585
1596
|
{
|
|
1586
|
-
src: "https://retinalabs.company/assets/images/
|
|
1597
|
+
src: "https://retinalabs.company/assets/images/save_box.avif",
|
|
1587
1598
|
alt: "Cashback",
|
|
1588
1599
|
className: "absolute bottom-6 right-4 translate-x-1/4 translate-y-1/2 w-40 h-auto object-contain z-0 pointer-events-none drop-shadow-md"
|
|
1589
1600
|
}
|
|
1590
|
-
)), /* @__PURE__ */ React16.createElement("div", { className: "bg-[
|
|
1601
|
+
)), /* @__PURE__ */ React16.createElement("div", { className: "bg-[#ceff8a] rounded-2xl p-5 relative overflow-hidden flex flex-col h-45 sm:h-50" }, /* @__PURE__ */ React16.createElement("div", { className: "relative z-10" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-black mb-1" }, "Rewards"), renderKMT(rewardsValue, balanceCurrency)), /* @__PURE__ */ React16.createElement(
|
|
1591
1602
|
"img",
|
|
1592
1603
|
{
|
|
1593
|
-
src: "https://retinalabs.company/assets/images/
|
|
1604
|
+
src: "https://retinalabs.company/assets/images/gift_box.avif",
|
|
1594
1605
|
alt: "Rewards",
|
|
1595
1606
|
className: "absolute bottom-6 right-4 translate-x-1/4 translate-y-1/2 w-40 h-auto object-contain z-0 pointer-events-none drop-shadow-md"
|
|
1596
1607
|
}
|
|
@@ -2259,7 +2270,7 @@ var MenuRow = ({
|
|
|
2259
2270
|
import React21, { useState as useState13 } from "react";
|
|
2260
2271
|
import { HugeiconsIcon as HugeiconsIcon15 } from "@hugeicons/react";
|
|
2261
2272
|
import {
|
|
2262
|
-
UserIcon
|
|
2273
|
+
UserIcon,
|
|
2263
2274
|
LockKeyIcon as LockKeyIcon2,
|
|
2264
2275
|
ShieldUserIcon,
|
|
2265
2276
|
MessageQuestionIcon,
|
|
@@ -2313,10 +2324,10 @@ var UniversalProfilePage = ({
|
|
|
2313
2324
|
onLoad: () => setIsAvatarLoaded(true),
|
|
2314
2325
|
className: `w-full h-full object-cover transition-opacity duration-300 ${isAvatarLoaded ? "opacity-100" : "opacity-0"}`
|
|
2315
2326
|
}
|
|
2316
|
-
)) : /* @__PURE__ */ React21.createElement(HugeiconsIcon15, { icon:
|
|
2327
|
+
)) : /* @__PURE__ */ React21.createElement(HugeiconsIcon15, { icon: UserIcon, size: 40, className: "text-neutral-300" }))), /* @__PURE__ */ React21.createElement("div", { className: "bg-white rounded-full px-4 py-2 flex items-center justify-center gap-2 mb-3" }, /* @__PURE__ */ React21.createElement("span", { className: "text-[12px] text-black" }, roleName), /* @__PURE__ */ React21.createElement("span", { className: getBadgeColorClass(roleName), "aria-hidden": true }, /* @__PURE__ */ React21.createElement("svg", { width: "15", height: "15", viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, /* @__PURE__ */ React21.createElement("g", { id: "SVGRepo_bgCarrier", strokeWidth: "0" }), /* @__PURE__ */ React21.createElement("g", { id: "SVGRepo_tracerCarrier", strokeLinecap: "round", strokeLinejoin: "round" }), /* @__PURE__ */ React21.createElement("g", { id: "SVGRepo_iconCarrier" }, " ", /* @__PURE__ */ React21.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M9.5924 3.20027C9.34888 3.4078 9.22711 3.51158 9.09706 3.59874C8.79896 3.79854 8.46417 3.93721 8.1121 4.00672C7.95851 4.03705 7.79903 4.04977 7.48008 4.07522C6.6787 4.13918 6.278 4.17115 5.94371 4.28923C5.17051 4.56233 4.56233 5.17051 4.28923 5.94371C4.17115 6.278 4.13918 6.6787 4.07522 7.48008C4.04977 7.79903 4.03705 7.95851 4.00672 8.1121C3.93721 8.46417 3.79854 8.79896 3.59874 9.09706C3.51158 9.22711 3.40781 9.34887 3.20027 9.5924C2.67883 10.2043 2.4181 10.5102 2.26522 10.8301C1.91159 11.57 1.91159 12.43 2.26522 13.1699C2.41811 13.4898 2.67883 13.7957 3.20027 14.4076C3.40778 14.6511 3.51158 14.7729 3.59874 14.9029C3.79854 15.201 3.93721 15.5358 4.00672 15.8879C4.03705 16.0415 4.04977 16.201 4.07522 16.5199C4.13918 17.3213 4.17115 17.722 4.28923 18.0563C4.56233 18.8295 5.17051 19.4377 5.94371 19.7108C6.278 19.8288 6.6787 19.8608 7.48008 19.9248C7.79903 19.9502 7.95851 19.963 8.1121 19.9933C8.46417 20.0628 8.79896 20.2015 9.09706 20.4013C9.22711 20.4884 9.34887 20.5922 9.5924 20.7997C10.2043 21.3212 10.5102 21.5819 10.8301 21.7348C11.57 22.0884 12.43 22.0884 13.1699 21.7348C13.4898 21.5819 13.7957 21.3212 14.4076 20.7997C14.6511 20.5922 14.7729 20.4884 14.9029 20.4013C15.201 20.2015 15.5358 20.0628 15.8879 19.9933C16.0415 19.963 16.201 19.9502 16.5199 19.9248C17.3213 19.8608 17.722 19.8288 18.0563 19.7108C18.8295 19.4377 19.4377 18.8295 19.7108 18.0563C19.8288 17.722 19.8608 17.3213 19.9248 16.5199C19.9502 16.201 19.963 16.0415 19.9933 15.8879C20.0628 15.5358 20.2015 15.201 20.4013 14.9029C20.4884 14.7729 20.5922 14.6511 20.7997 14.4076C21.3212 13.7957 21.5819 13.4898 21.7348 13.1699C22.0884 12.43 22.0884 11.57 21.7348 10.8301C21.5819 10.5102 21.3212 10.2043 20.7997 9.5924C20.5922 9.34887 20.4884 9.22711 20.4013 9.09706C20.2015 8.79896 20.0628 8.46417 19.9933 8.1121C19.963 7.95851 19.9502 7.79903 19.9248 7.48008C19.8608 6.6787 19.8288 6.278 19.7108 5.94371C19.4377 5.17051 18.8295 4.56233 18.0563 4.28923C17.722 4.17115 17.3213 4.13918 16.5199 4.07522C16.201 4.04977 16.0415 4.03705 15.8879 4.00672C15.5358 3.93721 15.201 3.79854 14.9029 3.59874C14.7729 3.51158 14.6511 3.40781 14.4076 3.20027C13.7957 2.67883 13.4898 2.41811 13.1699 2.26522C12.43 1.91159 11.57 1.91159 10.8301 2.26522C10.5102 2.4181 10.2043 2.67883 9.5924 3.20027ZM16.3735 9.86314C16.6913 9.5453 16.6913 9.03 16.3735 8.71216C16.0557 8.39433 15.5403 8.39433 15.2225 8.71216L10.3723 13.5624L8.77746 11.9676C8.45963 11.6498 7.94432 11.6498 7.62649 11.9676C7.30866 12.2854 7.30866 12.8007 7.62649 13.1186L9.79678 15.2889C10.1146 15.6067 10.6299 15.6067 10.9478 15.2889L16.3735 9.86314Z", fill: "currentColor" }), " ")))), /* @__PURE__ */ React21.createElement("span", { className: "text-[12px] text-neutral-500" }, memberSince)), /* @__PURE__ */ React21.createElement("div", { className: "w-full flex flex-col gap-4 mt-2" }, /* @__PURE__ */ React21.createElement("div", { className: "w-full bg-white rounded-2xl overflow-hidden" }, /* @__PURE__ */ React21.createElement(
|
|
2317
2328
|
MenuRow2,
|
|
2318
2329
|
{
|
|
2319
|
-
icon:
|
|
2330
|
+
icon: UserIcon,
|
|
2320
2331
|
title: "Account",
|
|
2321
2332
|
subtitle: "Your account details",
|
|
2322
2333
|
onClick: onAccountTap
|
|
@@ -3895,7 +3906,7 @@ import {
|
|
|
3895
3906
|
ArrowLeft01Icon as ArrowLeft01Icon8,
|
|
3896
3907
|
Mail01Icon,
|
|
3897
3908
|
SmartPhone01Icon,
|
|
3898
|
-
UserIcon as
|
|
3909
|
+
UserIcon as UserIcon2,
|
|
3899
3910
|
CheckmarkCircle01Icon,
|
|
3900
3911
|
Time02Icon,
|
|
3901
3912
|
InformationCircleIcon as InformationCircleIcon2,
|
|
@@ -3996,7 +4007,7 @@ var UniversalVerificationPage = ({
|
|
|
3996
4007
|
), /* @__PURE__ */ React41.createElement(
|
|
3997
4008
|
VerificationRow,
|
|
3998
4009
|
{
|
|
3999
|
-
icon:
|
|
4010
|
+
icon: UserIcon2,
|
|
4000
4011
|
title: "Identity Verification",
|
|
4001
4012
|
status: identityStatus,
|
|
4002
4013
|
isLoading: activeLoadingType === "IDENTITY",
|