@retinalabsllc/zairusjs 15.1.30 → 15.1.40
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 +0 -4
- package/dist/index.d.ts +0 -4
- package/dist/index.js +6 -55
- package/dist/index.mjs +30 -81
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -256,10 +256,6 @@ interface NotificationItem {
|
|
|
256
256
|
interface UniversalHomeViewProps {
|
|
257
257
|
fullName?: string;
|
|
258
258
|
avatarSrc?: string | null;
|
|
259
|
-
balanceLabel?: string;
|
|
260
|
-
balanceAmount: string;
|
|
261
|
-
balanceCurrency?: string;
|
|
262
|
-
calculatorAction?: HomeActionBtn;
|
|
263
259
|
buyCryptoAction?: HomeActionBtn;
|
|
264
260
|
referralAction?: HomeActionBtn;
|
|
265
261
|
notifications?: NotificationItem[];
|
package/dist/index.d.ts
CHANGED
|
@@ -256,10 +256,6 @@ interface NotificationItem {
|
|
|
256
256
|
interface UniversalHomeViewProps {
|
|
257
257
|
fullName?: string;
|
|
258
258
|
avatarSrc?: string | null;
|
|
259
|
-
balanceLabel?: string;
|
|
260
|
-
balanceAmount: string;
|
|
261
|
-
balanceCurrency?: string;
|
|
262
|
-
calculatorAction?: HomeActionBtn;
|
|
263
259
|
buyCryptoAction?: HomeActionBtn;
|
|
264
260
|
referralAction?: HomeActionBtn;
|
|
265
261
|
notifications?: NotificationItem[];
|
package/dist/index.js
CHANGED
|
@@ -482,7 +482,8 @@ var PhoneInput = ({
|
|
|
482
482
|
var SUPPORTED_COUNTRIES = [
|
|
483
483
|
{ code: "NG", dialCode: "+234", name: "Nigeria" },
|
|
484
484
|
{ code: "GH", dialCode: "+233", name: "Ghana" },
|
|
485
|
-
{ code: "KE", dialCode: "+254", name: "Kenya" }
|
|
485
|
+
{ code: "KE", dialCode: "+254", name: "Kenya" },
|
|
486
|
+
{ code: "UG", dialCode: "+256", name: "Uganda" }
|
|
486
487
|
];
|
|
487
488
|
var InputSpinner2 = () => /* @__PURE__ */ import_react7.default.createElement("svg", { className: "animate-spin h-4 w-4 text-neutral-400", xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24" }, /* @__PURE__ */ import_react7.default.createElement("circle", { className: "opacity-25", cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }), /* @__PURE__ */ import_react7.default.createElement("path", { className: "opacity-75", fill: "currentColor", d: "M4 12a8 8 0 018-8V0C5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z" }));
|
|
488
489
|
var CountrySelectorDialog = ({ isOpen, onClose, onSelect }) => {
|
|
@@ -1617,10 +1618,6 @@ var import_core_free_icons8 = require("@hugeicons/core-free-icons");
|
|
|
1617
1618
|
var UniversalHomeView = ({
|
|
1618
1619
|
fullName = "",
|
|
1619
1620
|
avatarSrc,
|
|
1620
|
-
balanceLabel = "Pending Balance",
|
|
1621
|
-
balanceAmount,
|
|
1622
|
-
balanceCurrency = "$",
|
|
1623
|
-
calculatorAction,
|
|
1624
1621
|
buyCryptoAction,
|
|
1625
1622
|
referralAction,
|
|
1626
1623
|
notifications = [],
|
|
@@ -1633,44 +1630,12 @@ var UniversalHomeView = ({
|
|
|
1633
1630
|
customContent,
|
|
1634
1631
|
transactionsProps
|
|
1635
1632
|
}) => {
|
|
1636
|
-
const [displayAmount, setDisplayAmount] = (0, import_react25.useState)("0.00");
|
|
1637
|
-
const [isBalanceHidden, setIsBalanceHidden] = (0, import_react25.useState)(false);
|
|
1638
1633
|
const [isAvatarLoaded, setIsAvatarLoaded] = (0, import_react25.useState)(false);
|
|
1639
1634
|
const [showNotifDialog, setShowNotifDialog] = (0, import_react25.useState)(false);
|
|
1640
1635
|
const [selectedNotif, setSelectedNotif] = (0, import_react25.useState)(null);
|
|
1641
1636
|
const fallbackAvatarUrl = `/api/avatar/?name=${encodeURIComponent(fullName || " ")}&background=ffffff&color=000000&size=200&font-size=0.33`;
|
|
1642
1637
|
const finalAvatarSrc = avatarSrc || fallbackAvatarUrl;
|
|
1643
1638
|
const hasUnreadNotifs = notifications.some((n) => !n.isRead);
|
|
1644
|
-
(0, import_react25.useEffect)(() => {
|
|
1645
|
-
const target = parseFloat(balanceAmount.replace(/,/g, ""));
|
|
1646
|
-
if (isNaN(target)) {
|
|
1647
|
-
setDisplayAmount(balanceAmount);
|
|
1648
|
-
return;
|
|
1649
|
-
}
|
|
1650
|
-
const decimalMatch = balanceAmount.match(/\.(\d+)/);
|
|
1651
|
-
const fractionDigits = decimalMatch ? decimalMatch[1].length : 0;
|
|
1652
|
-
let startTimestamp = null;
|
|
1653
|
-
const duration = 1e3;
|
|
1654
|
-
const step = (timestamp) => {
|
|
1655
|
-
if (!startTimestamp) startTimestamp = timestamp;
|
|
1656
|
-
const progress = Math.min((timestamp - startTimestamp) / duration, 1);
|
|
1657
|
-
const easeProgress = progress === 1 ? 1 : 1 - Math.pow(2, -10 * progress);
|
|
1658
|
-
const currentCount = easeProgress * target;
|
|
1659
|
-
setDisplayAmount(currentCount.toLocaleString("en-US", {
|
|
1660
|
-
minimumFractionDigits: fractionDigits,
|
|
1661
|
-
maximumFractionDigits: fractionDigits
|
|
1662
|
-
}));
|
|
1663
|
-
if (progress < 1) requestAnimationFrame(step);
|
|
1664
|
-
else {
|
|
1665
|
-
setDisplayAmount(target.toLocaleString("en-US", {
|
|
1666
|
-
minimumFractionDigits: fractionDigits,
|
|
1667
|
-
maximumFractionDigits: fractionDigits
|
|
1668
|
-
}));
|
|
1669
|
-
}
|
|
1670
|
-
};
|
|
1671
|
-
requestAnimationFrame(step);
|
|
1672
|
-
}, [balanceAmount]);
|
|
1673
|
-
const [intPart, decPart] = displayAmount.includes(".") ? displayAmount.split(".") : [displayAmount, ""];
|
|
1674
1639
|
return /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center " }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-neutral-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ import_react25.default.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-neutral-100" }, /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.Loading03Icon, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ import_react25.default.createElement(
|
|
1675
1640
|
"img",
|
|
1676
1641
|
{
|
|
@@ -1690,27 +1655,13 @@ var UniversalHomeView = ({
|
|
|
1690
1655
|
},
|
|
1691
1656
|
/* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.Notification01Icon, size: 20, className: "text-black" }),
|
|
1692
1657
|
hasUnreadNotifs && /* @__PURE__ */ import_react25.default.createElement("span", { className: "absolute top-2.5 right-2.5 w-2 h-2 bg-red-500 rounded-full border border-white" })
|
|
1693
|
-
)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-full pb-6 flex flex-col gap-4" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "
|
|
1694
|
-
"button",
|
|
1695
|
-
{
|
|
1696
|
-
onClick: () => setIsBalanceHidden(!isBalanceHidden),
|
|
1697
|
-
className: "text-neutral-400 hover:text-white transition-colors outline-none"
|
|
1698
|
-
},
|
|
1699
|
-
/* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: isBalanceHidden ? import_core_free_icons8.ViewIcon : import_core_free_icons8.ViewOffSlashIcon, size: 16 })
|
|
1700
|
-
)), /* @__PURE__ */ import_react25.default.createElement("p", { className: `text-2xl text-white tracking-tight mb-6 tabular-nums flex items-baseline transition-all duration-300 ${isBalanceHidden ? "blur-sm opacity-40 select-none" : ""}` }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-lg text-neutral-400 mr-1" }, balanceCurrency), intPart, decPart && /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-lg text-neutral-400" }, ".", decPart)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "flex items-center w-full" }, calculatorAction && /* @__PURE__ */ import_react25.default.createElement(
|
|
1701
|
-
"button",
|
|
1702
|
-
{
|
|
1703
|
-
onClick: calculatorAction.onClick,
|
|
1704
|
-
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"
|
|
1705
|
-
},
|
|
1706
|
-
calculatorAction.label || "Rate Calculator"
|
|
1707
|
-
)))), /* @__PURE__ */ import_react25.default.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ import_react25.default.createElement(
|
|
1658
|
+
)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-full pb-6 flex flex-col gap-4" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ import_react25.default.createElement(
|
|
1708
1659
|
"div",
|
|
1709
1660
|
{
|
|
1710
1661
|
onClick: buyCryptoAction?.onClick,
|
|
1711
1662
|
className: "bg-[#143731] rounded-2xl p-5 relative overflow-hidden flex flex-col h-32 sm:h-36 cursor-pointer hover:opacity-90 transition-opacity"
|
|
1712
1663
|
},
|
|
1713
|
-
/* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-white " }, "Buy Crypto"), /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-8 h-8 rounded-full bg-white/10
|
|
1664
|
+
/* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-white leading-tight " }, "Buy", /* @__PURE__ */ import_react25.default.createElement("br", null), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-white/70" }, "Crypto")), /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-8 h-8 rounded-full bg-white/10 flex items-center justify-center" }, /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.ArrowUpRight01Icon, size: 16, className: "text-white" }))),
|
|
1714
1665
|
/* @__PURE__ */ import_react25.default.createElement(
|
|
1715
1666
|
"img",
|
|
1716
1667
|
{
|
|
@@ -1725,7 +1676,7 @@ var UniversalHomeView = ({
|
|
|
1725
1676
|
onClick: referralAction?.onClick,
|
|
1726
1677
|
className: "bg-[#ceff8a] rounded-2xl p-5 relative overflow-hidden flex flex-col h-32 sm:h-36 cursor-pointer hover:opacity-90 transition-opacity"
|
|
1727
1678
|
},
|
|
1728
|
-
/* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-black " }, "
|
|
1679
|
+
/* @__PURE__ */ import_react25.default.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[15px] sm:text-[15px] text-black leading-tight " }, "My", /* @__PURE__ */ import_react25.default.createElement("br", null), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-black/60" }, "Rewards")), /* @__PURE__ */ import_react25.default.createElement("div", { className: "w-8 h-8 rounded-full bg-black/5 flex items-center justify-center" }, /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.ArrowRight01Icon, size: 16, className: "text-black" }))),
|
|
1729
1680
|
/* @__PURE__ */ import_react25.default.createElement(
|
|
1730
1681
|
"img",
|
|
1731
1682
|
{
|
|
@@ -1739,7 +1690,7 @@ var UniversalHomeView = ({
|
|
|
1739
1690
|
{
|
|
1740
1691
|
...transactionsProps,
|
|
1741
1692
|
hideControls: true,
|
|
1742
|
-
hideBalanceAmounts:
|
|
1693
|
+
hideBalanceAmounts: false,
|
|
1743
1694
|
hidePagination: true
|
|
1744
1695
|
}
|
|
1745
1696
|
)), showNotifDialog && /* @__PURE__ */ import_react25.default.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowNotifDialog(false) }), /* @__PURE__ */ import_react25.default.createElement("div", { className: "relative w-full max-w-sm bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "flex items-center justify-between p-5 shrink-0 " }, selectedNotif ? /* @__PURE__ */ import_react25.default.createElement("button", { onClick: () => setSelectedNotif(null), className: "text-neutral-400 hover:text-black transition-colors outline-none flex items-center gap-2 text-[11px] tracking-widest " }, /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.ArrowLeft01Icon, size: 14 }), " Back") : /* @__PURE__ */ import_react25.default.createElement("h3", { className: "text-[15px] text-black tracking-tight flex items-center gap-2" }, "Notifications", isNotifsLoading && /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.Loading03Icon, size: 14, className: "animate-spin text-neutral-400" })), /* @__PURE__ */ import_react25.default.createElement("button", { onClick: () => setShowNotifDialog(false), className: "text-neutral-400 hover:text-black transition-colors outline-none" }, /* @__PURE__ */ import_react25.default.createElement(import_react26.HugeiconsIcon, { icon: import_core_free_icons8.CancelCircleIcon, size: 18 }))), /* @__PURE__ */ import_react25.default.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, selectedNotif ? /* @__PURE__ */ import_react25.default.createElement("div", { className: "p-4 text-left" }, /* @__PURE__ */ import_react25.default.createElement("h4", { className: "text-[14px] text-black mb-1 " }, selectedNotif.title), /* @__PURE__ */ import_react25.default.createElement("span", { className: "text-[10px] text-neutral-400 tracking-widest mb-4 block " }, formatNotifDate(selectedNotif.createdAt)), /* @__PURE__ */ import_react25.default.createElement("p", { className: "text-[12px] text-neutral-600 leading-relaxed whitespace-pre-wrap" }, selectedNotif.message)) : /* @__PURE__ */ import_react25.default.createElement("div", { className: "flex flex-col divide-y divide-neutral-50/50" }, notifications?.length === 0 && !isNotifsLoading ? /* @__PURE__ */ import_react25.default.createElement("div", { className: "p-8 text-center text-xs text-neutral-400" }, "You have no notifications.") : notifications?.map((notif) => /* @__PURE__ */ import_react25.default.createElement(
|
package/dist/index.mjs
CHANGED
|
@@ -403,7 +403,8 @@ var PhoneInput = ({
|
|
|
403
403
|
var SUPPORTED_COUNTRIES = [
|
|
404
404
|
{ code: "NG", dialCode: "+234", name: "Nigeria" },
|
|
405
405
|
{ code: "GH", dialCode: "+233", name: "Ghana" },
|
|
406
|
-
{ code: "KE", dialCode: "+254", name: "Kenya" }
|
|
406
|
+
{ code: "KE", dialCode: "+254", name: "Kenya" },
|
|
407
|
+
{ code: "UG", dialCode: "+256", name: "Uganda" }
|
|
407
408
|
];
|
|
408
409
|
var InputSpinner2 = () => /* @__PURE__ */ React6.createElement("svg", { className: "animate-spin h-4 w-4 text-neutral-400", xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24" }, /* @__PURE__ */ React6.createElement("circle", { className: "opacity-25", cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }), /* @__PURE__ */ React6.createElement("path", { className: "opacity-75", fill: "currentColor", d: "M4 12a8 8 0 018-8V0C5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z" }));
|
|
409
410
|
var CountrySelectorDialog = ({ isOpen, onClose, onSelect }) => {
|
|
@@ -1557,11 +1558,9 @@ var UniversalTransactionPage = ({
|
|
|
1557
1558
|
};
|
|
1558
1559
|
|
|
1559
1560
|
// src/components/UniversalHomeView.tsx
|
|
1560
|
-
import React16, { useState as useState10
|
|
1561
|
+
import React16, { useState as useState10 } from "react";
|
|
1561
1562
|
import { HugeiconsIcon as HugeiconsIcon10 } from "@hugeicons/react";
|
|
1562
1563
|
import {
|
|
1563
|
-
ViewOffSlashIcon,
|
|
1564
|
-
ViewIcon,
|
|
1565
1564
|
Loading03Icon as Loading03Icon5,
|
|
1566
1565
|
Notification01Icon,
|
|
1567
1566
|
ArrowLeft01Icon as ArrowLeft01Icon4,
|
|
@@ -1572,10 +1571,6 @@ import {
|
|
|
1572
1571
|
var UniversalHomeView = ({
|
|
1573
1572
|
fullName = "",
|
|
1574
1573
|
avatarSrc,
|
|
1575
|
-
balanceLabel = "Pending Balance",
|
|
1576
|
-
balanceAmount,
|
|
1577
|
-
balanceCurrency = "$",
|
|
1578
|
-
calculatorAction,
|
|
1579
1574
|
buyCryptoAction,
|
|
1580
1575
|
referralAction,
|
|
1581
1576
|
notifications = [],
|
|
@@ -1588,44 +1583,12 @@ var UniversalHomeView = ({
|
|
|
1588
1583
|
customContent,
|
|
1589
1584
|
transactionsProps
|
|
1590
1585
|
}) => {
|
|
1591
|
-
const [displayAmount, setDisplayAmount] = useState10("0.00");
|
|
1592
|
-
const [isBalanceHidden, setIsBalanceHidden] = useState10(false);
|
|
1593
1586
|
const [isAvatarLoaded, setIsAvatarLoaded] = useState10(false);
|
|
1594
1587
|
const [showNotifDialog, setShowNotifDialog] = useState10(false);
|
|
1595
1588
|
const [selectedNotif, setSelectedNotif] = useState10(null);
|
|
1596
1589
|
const fallbackAvatarUrl = `/api/avatar/?name=${encodeURIComponent(fullName || " ")}&background=ffffff&color=000000&size=200&font-size=0.33`;
|
|
1597
1590
|
const finalAvatarSrc = avatarSrc || fallbackAvatarUrl;
|
|
1598
1591
|
const hasUnreadNotifs = notifications.some((n) => !n.isRead);
|
|
1599
|
-
useEffect7(() => {
|
|
1600
|
-
const target = parseFloat(balanceAmount.replace(/,/g, ""));
|
|
1601
|
-
if (isNaN(target)) {
|
|
1602
|
-
setDisplayAmount(balanceAmount);
|
|
1603
|
-
return;
|
|
1604
|
-
}
|
|
1605
|
-
const decimalMatch = balanceAmount.match(/\.(\d+)/);
|
|
1606
|
-
const fractionDigits = decimalMatch ? decimalMatch[1].length : 0;
|
|
1607
|
-
let startTimestamp = null;
|
|
1608
|
-
const duration = 1e3;
|
|
1609
|
-
const step = (timestamp) => {
|
|
1610
|
-
if (!startTimestamp) startTimestamp = timestamp;
|
|
1611
|
-
const progress = Math.min((timestamp - startTimestamp) / duration, 1);
|
|
1612
|
-
const easeProgress = progress === 1 ? 1 : 1 - Math.pow(2, -10 * progress);
|
|
1613
|
-
const currentCount = easeProgress * target;
|
|
1614
|
-
setDisplayAmount(currentCount.toLocaleString("en-US", {
|
|
1615
|
-
minimumFractionDigits: fractionDigits,
|
|
1616
|
-
maximumFractionDigits: fractionDigits
|
|
1617
|
-
}));
|
|
1618
|
-
if (progress < 1) requestAnimationFrame(step);
|
|
1619
|
-
else {
|
|
1620
|
-
setDisplayAmount(target.toLocaleString("en-US", {
|
|
1621
|
-
minimumFractionDigits: fractionDigits,
|
|
1622
|
-
maximumFractionDigits: fractionDigits
|
|
1623
|
-
}));
|
|
1624
|
-
}
|
|
1625
|
-
};
|
|
1626
|
-
requestAnimationFrame(step);
|
|
1627
|
-
}, [balanceAmount]);
|
|
1628
|
-
const [intPart, decPart] = displayAmount.includes(".") ? displayAmount.split(".") : [displayAmount, ""];
|
|
1629
1592
|
return /* @__PURE__ */ React16.createElement("div", { className: "w-full max-w-3xl mx-auto flex flex-col animate-in fade-in duration-300 relative" }, /* @__PURE__ */ React16.createElement("div", { className: "flex items-center justify-between w-full pb-4 " }, /* @__PURE__ */ React16.createElement("div", { className: "w-10 h-10 rounded-full bg-white p-0.75 flex items-center justify-center " }, /* @__PURE__ */ React16.createElement("div", { className: "relative w-full h-full rounded-full overflow-hidden bg-neutral-100 flex items-center justify-center" }, !isAvatarLoaded && /* @__PURE__ */ React16.createElement("div", { className: "absolute inset-0 flex items-center justify-center z-10 bg-neutral-100" }, /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: Loading03Icon5, size: 16, className: "animate-spin text-black" })), /* @__PURE__ */ React16.createElement(
|
|
1630
1593
|
"img",
|
|
1631
1594
|
{
|
|
@@ -1645,27 +1608,13 @@ var UniversalHomeView = ({
|
|
|
1645
1608
|
},
|
|
1646
1609
|
/* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: Notification01Icon, size: 20, className: "text-black" }),
|
|
1647
1610
|
hasUnreadNotifs && /* @__PURE__ */ React16.createElement("span", { className: "absolute top-2.5 right-2.5 w-2 h-2 bg-red-500 rounded-full border border-white" })
|
|
1648
|
-
)), /* @__PURE__ */ React16.createElement("div", { className: "w-full pb-6 flex flex-col gap-4" }, /* @__PURE__ */ React16.createElement("div", { className: "
|
|
1649
|
-
"button",
|
|
1650
|
-
{
|
|
1651
|
-
onClick: () => setIsBalanceHidden(!isBalanceHidden),
|
|
1652
|
-
className: "text-neutral-400 hover:text-white transition-colors outline-none"
|
|
1653
|
-
},
|
|
1654
|
-
/* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: isBalanceHidden ? ViewIcon : ViewOffSlashIcon, size: 16 })
|
|
1655
|
-
)), /* @__PURE__ */ React16.createElement("p", { className: `text-2xl text-white tracking-tight mb-6 tabular-nums flex items-baseline transition-all duration-300 ${isBalanceHidden ? "blur-sm opacity-40 select-none" : ""}` }, /* @__PURE__ */ React16.createElement("span", { className: "text-lg text-neutral-400 mr-1" }, balanceCurrency), intPart, decPart && /* @__PURE__ */ React16.createElement("span", { className: "text-lg text-neutral-400" }, ".", decPart)), /* @__PURE__ */ React16.createElement("div", { className: "flex items-center w-full" }, calculatorAction && /* @__PURE__ */ React16.createElement(
|
|
1656
|
-
"button",
|
|
1657
|
-
{
|
|
1658
|
-
onClick: calculatorAction.onClick,
|
|
1659
|
-
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"
|
|
1660
|
-
},
|
|
1661
|
-
calculatorAction.label || "Rate Calculator"
|
|
1662
|
-
)))), /* @__PURE__ */ React16.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ React16.createElement(
|
|
1611
|
+
)), /* @__PURE__ */ React16.createElement("div", { className: "w-full pb-6 flex flex-col gap-4" }, /* @__PURE__ */ React16.createElement("div", { className: "grid grid-cols-2 gap-2" }, /* @__PURE__ */ React16.createElement(
|
|
1663
1612
|
"div",
|
|
1664
1613
|
{
|
|
1665
1614
|
onClick: buyCryptoAction?.onClick,
|
|
1666
1615
|
className: "bg-[#143731] rounded-2xl p-5 relative overflow-hidden flex flex-col h-32 sm:h-36 cursor-pointer hover:opacity-90 transition-opacity"
|
|
1667
1616
|
},
|
|
1668
|
-
/* @__PURE__ */ React16.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-white " }, "Buy Crypto"), /* @__PURE__ */ React16.createElement("div", { className: "w-8 h-8 rounded-full bg-white/10
|
|
1617
|
+
/* @__PURE__ */ React16.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-white leading-tight " }, "Buy", /* @__PURE__ */ React16.createElement("br", null), /* @__PURE__ */ React16.createElement("span", { className: "text-white/70" }, "Crypto")), /* @__PURE__ */ React16.createElement("div", { className: "w-8 h-8 rounded-full bg-white/10 flex items-center justify-center" }, /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: ArrowUpRight01Icon2, size: 16, className: "text-white" }))),
|
|
1669
1618
|
/* @__PURE__ */ React16.createElement(
|
|
1670
1619
|
"img",
|
|
1671
1620
|
{
|
|
@@ -1680,7 +1629,7 @@ var UniversalHomeView = ({
|
|
|
1680
1629
|
onClick: referralAction?.onClick,
|
|
1681
1630
|
className: "bg-[#ceff8a] rounded-2xl p-5 relative overflow-hidden flex flex-col h-32 sm:h-36 cursor-pointer hover:opacity-90 transition-opacity"
|
|
1682
1631
|
},
|
|
1683
|
-
/* @__PURE__ */ React16.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-black " }, "
|
|
1632
|
+
/* @__PURE__ */ React16.createElement("div", { className: "relative z-10 flex flex-col h-full justify-between" }, /* @__PURE__ */ React16.createElement("p", { className: "text-[15px] sm:text-[15px] text-black leading-tight " }, "My", /* @__PURE__ */ React16.createElement("br", null), /* @__PURE__ */ React16.createElement("span", { className: "text-black/60" }, "Rewards")), /* @__PURE__ */ React16.createElement("div", { className: "w-8 h-8 rounded-full bg-black/5 flex items-center justify-center" }, /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: ArrowRight01Icon2, size: 16, className: "text-black" }))),
|
|
1684
1633
|
/* @__PURE__ */ React16.createElement(
|
|
1685
1634
|
"img",
|
|
1686
1635
|
{
|
|
@@ -1694,7 +1643,7 @@ var UniversalHomeView = ({
|
|
|
1694
1643
|
{
|
|
1695
1644
|
...transactionsProps,
|
|
1696
1645
|
hideControls: true,
|
|
1697
|
-
hideBalanceAmounts:
|
|
1646
|
+
hideBalanceAmounts: false,
|
|
1698
1647
|
hidePagination: true
|
|
1699
1648
|
}
|
|
1700
1649
|
)), showNotifDialog && /* @__PURE__ */ React16.createElement("div", { className: "fixed inset-0 z-120 flex items-center justify-center p-4 pointer-events-auto" }, /* @__PURE__ */ React16.createElement("div", { className: "absolute inset-0 bg-black/30", onClick: () => setShowNotifDialog(false) }), /* @__PURE__ */ React16.createElement("div", { className: "relative w-full max-w-sm bg-white rounded-2xl flex flex-col overflow-hidden shadow-2xl animate-in zoom-in-95 duration-200 h-[80vh]" }, /* @__PURE__ */ React16.createElement("div", { className: "flex items-center justify-between p-5 shrink-0 " }, selectedNotif ? /* @__PURE__ */ React16.createElement("button", { onClick: () => setSelectedNotif(null), className: "text-neutral-400 hover:text-black transition-colors outline-none flex items-center gap-2 text-[11px] tracking-widest " }, /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: ArrowLeft01Icon4, size: 14 }), " Back") : /* @__PURE__ */ React16.createElement("h3", { className: "text-[15px] text-black tracking-tight flex items-center gap-2" }, "Notifications", isNotifsLoading && /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: Loading03Icon5, size: 14, className: "animate-spin text-neutral-400" })), /* @__PURE__ */ React16.createElement("button", { onClick: () => setShowNotifDialog(false), className: "text-neutral-400 hover:text-black transition-colors outline-none" }, /* @__PURE__ */ React16.createElement(HugeiconsIcon10, { icon: CancelCircleIcon3, size: 18 }))), /* @__PURE__ */ React16.createElement("div", { className: "flex-1 overflow-y-auto custom-scrollbar p-2" }, selectedNotif ? /* @__PURE__ */ React16.createElement("div", { className: "p-4 text-left" }, /* @__PURE__ */ React16.createElement("h4", { className: "text-[14px] text-black mb-1 " }, selectedNotif.title), /* @__PURE__ */ React16.createElement("span", { className: "text-[10px] text-neutral-400 tracking-widest mb-4 block " }, formatNotifDate(selectedNotif.createdAt)), /* @__PURE__ */ React16.createElement("p", { className: "text-[12px] text-neutral-600 leading-relaxed whitespace-pre-wrap" }, selectedNotif.message)) : /* @__PURE__ */ React16.createElement("div", { className: "flex flex-col divide-y divide-neutral-50/50" }, notifications?.length === 0 && !isNotifsLoading ? /* @__PURE__ */ React16.createElement("div", { className: "p-8 text-center text-xs text-neutral-400" }, "You have no notifications.") : notifications?.map((notif) => /* @__PURE__ */ React16.createElement(
|
|
@@ -2015,7 +1964,7 @@ var UniversalWalletPage = ({
|
|
|
2015
1964
|
};
|
|
2016
1965
|
|
|
2017
1966
|
// src/components/UniversalCardPage.tsx
|
|
2018
|
-
import React19, { useState as useState12, useEffect as
|
|
1967
|
+
import React19, { useState as useState12, useEffect as useEffect7 } from "react";
|
|
2019
1968
|
import { useRouter } from "next/navigation";
|
|
2020
1969
|
import toast6 from "react-hot-toast";
|
|
2021
1970
|
import { HugeiconsIcon as HugeiconsIcon13 } from "@hugeicons/react";
|
|
@@ -2023,7 +1972,7 @@ import {
|
|
|
2023
1972
|
SnowIcon,
|
|
2024
1973
|
Delete02Icon,
|
|
2025
1974
|
ArrowRight01Icon as ArrowRight01Icon3,
|
|
2026
|
-
ViewOffSlashIcon
|
|
1975
|
+
ViewOffSlashIcon,
|
|
2027
1976
|
Loading03Icon as Loading03Icon8,
|
|
2028
1977
|
CancelCircleIcon as CancelCircleIcon5,
|
|
2029
1978
|
Copy01Icon as Copy01Icon3,
|
|
@@ -2051,7 +2000,7 @@ var UniversalCardPage = ({
|
|
|
2051
2000
|
const [isFreezing, setIsFreezing] = useState12(false);
|
|
2052
2001
|
const [showDeleteDialog, setShowDeleteDialog] = useState12(false);
|
|
2053
2002
|
const [isDeleting, setIsDeleting] = useState12(false);
|
|
2054
|
-
|
|
2003
|
+
useEffect7(() => {
|
|
2055
2004
|
setIsBgLoaded(false);
|
|
2056
2005
|
if (!activeCard?.cardBgSrc) return;
|
|
2057
2006
|
const img = new Image();
|
|
@@ -2132,7 +2081,7 @@ var UniversalCardPage = ({
|
|
|
2132
2081
|
), /* @__PURE__ */ React19.createElement(
|
|
2133
2082
|
MenuRow,
|
|
2134
2083
|
{
|
|
2135
|
-
icon:
|
|
2084
|
+
icon: ViewOffSlashIcon,
|
|
2136
2085
|
title: "Reveal Information",
|
|
2137
2086
|
subtitle: "Show secure card details",
|
|
2138
2087
|
onClick: () => {
|
|
@@ -2192,7 +2141,7 @@ var CardInfoDialog = ({ isOpen, onClose, cardDetails }) => {
|
|
|
2192
2141
|
var FundCardDialog = ({ isOpen, onClose, onSubmit }) => {
|
|
2193
2142
|
const [amount, setAmount] = useState12("");
|
|
2194
2143
|
const [isProcessing, setIsProcessing] = useState12(false);
|
|
2195
|
-
|
|
2144
|
+
useEffect7(() => {
|
|
2196
2145
|
if (isOpen) {
|
|
2197
2146
|
setAmount("");
|
|
2198
2147
|
}
|
|
@@ -2472,7 +2421,7 @@ var UniversalSidebar = ({
|
|
|
2472
2421
|
};
|
|
2473
2422
|
|
|
2474
2423
|
// src/components/HeroSection.tsx
|
|
2475
|
-
import React23, { useState as useState16, useEffect as
|
|
2424
|
+
import React23, { useState as useState16, useEffect as useEffect8, useRef as useRef4 } from "react";
|
|
2476
2425
|
import Link6 from "next/link";
|
|
2477
2426
|
import Image3 from "next/image";
|
|
2478
2427
|
|
|
@@ -2587,7 +2536,7 @@ var HeroSection = ({
|
|
|
2587
2536
|
const [isAnimating, setIsAnimating] = useState16(false);
|
|
2588
2537
|
const [isWaitlistOpen, setIsWaitlistOpen] = useState16(false);
|
|
2589
2538
|
const titleRef = useRef4(null);
|
|
2590
|
-
|
|
2539
|
+
useEffect8(() => {
|
|
2591
2540
|
const observer = new IntersectionObserver(
|
|
2592
2541
|
([entry]) => {
|
|
2593
2542
|
if (entry.isIntersecting) {
|
|
@@ -2680,12 +2629,12 @@ var HeroSection = ({
|
|
|
2680
2629
|
};
|
|
2681
2630
|
|
|
2682
2631
|
// src/components/AppBento2.tsx
|
|
2683
|
-
import React24, { useState as useState17, useEffect as
|
|
2632
|
+
import React24, { useState as useState17, useEffect as useEffect9, useRef as useRef5 } from "react";
|
|
2684
2633
|
import { HugeiconsIcon as HugeiconsIcon16 } from "@hugeicons/react";
|
|
2685
2634
|
var AppBento2 = ({ tagline, headline, features }) => {
|
|
2686
2635
|
const [isAnimating, setIsAnimating] = useState17(false);
|
|
2687
2636
|
const titleRef = useRef5(null);
|
|
2688
|
-
|
|
2637
|
+
useEffect9(() => {
|
|
2689
2638
|
const observer = new IntersectionObserver(
|
|
2690
2639
|
([entry]) => {
|
|
2691
2640
|
if (entry.isIntersecting) {
|
|
@@ -2961,7 +2910,7 @@ var MenuRow3 = ({
|
|
|
2961
2910
|
);
|
|
2962
2911
|
|
|
2963
2912
|
// src/components/FeatureScroll.tsx
|
|
2964
|
-
import React26, { useRef as useRef6, useState as useState19, useEffect as
|
|
2913
|
+
import React26, { useRef as useRef6, useState as useState19, useEffect as useEffect10 } from "react";
|
|
2965
2914
|
import Image4 from "next/image";
|
|
2966
2915
|
import { HugeiconsIcon as HugeiconsIcon18 } from "@hugeicons/react";
|
|
2967
2916
|
import { ArrowLeft01Icon as ArrowLeft01Icon7, ArrowRight01Icon as ArrowRight01Icon6, Loading03Icon as Loading03Icon11 } from "@hugeicons/core-free-icons";
|
|
@@ -3015,7 +2964,7 @@ var FeatureScroll = ({ tagline, headline, features }) => {
|
|
|
3015
2964
|
setCanScrollRight(scrollLeft < scrollWidth - clientWidth - 2);
|
|
3016
2965
|
}
|
|
3017
2966
|
};
|
|
3018
|
-
|
|
2967
|
+
useEffect10(() => {
|
|
3019
2968
|
checkScroll();
|
|
3020
2969
|
window.addEventListener("resize", checkScroll);
|
|
3021
2970
|
return () => window.removeEventListener("resize", checkScroll);
|
|
@@ -3096,7 +3045,7 @@ var PlatformFeatures = ({
|
|
|
3096
3045
|
};
|
|
3097
3046
|
|
|
3098
3047
|
// src/components/ManagedDocument.tsx
|
|
3099
|
-
import React28, { useState as useState20, useEffect as
|
|
3048
|
+
import React28, { useState as useState20, useEffect as useEffect11, useRef as useRef7 } from "react";
|
|
3100
3049
|
var ManagedDocument = ({
|
|
3101
3050
|
tagline,
|
|
3102
3051
|
title,
|
|
@@ -3106,7 +3055,7 @@ var ManagedDocument = ({
|
|
|
3106
3055
|
}) => {
|
|
3107
3056
|
const [isAnimating, setIsAnimating] = useState20(false);
|
|
3108
3057
|
const titleRef = useRef7(null);
|
|
3109
|
-
|
|
3058
|
+
useEffect11(() => {
|
|
3110
3059
|
const observer = new IntersectionObserver(
|
|
3111
3060
|
([entry]) => {
|
|
3112
3061
|
if (entry.isIntersecting) {
|
|
@@ -3146,11 +3095,11 @@ var ManagedDocument = ({
|
|
|
3146
3095
|
};
|
|
3147
3096
|
|
|
3148
3097
|
// src/components/ManagedContactBlock.tsx
|
|
3149
|
-
import React29, { useState as useState21, useEffect as
|
|
3098
|
+
import React29, { useState as useState21, useEffect as useEffect12 } from "react";
|
|
3150
3099
|
import { HugeiconsIcon as HugeiconsIcon20 } from "@hugeicons/react";
|
|
3151
3100
|
var SecureEmail = ({ user, domain, className }) => {
|
|
3152
3101
|
const [isMounted, setIsMounted] = useState21(false);
|
|
3153
|
-
|
|
3102
|
+
useEffect12(() => {
|
|
3154
3103
|
setIsMounted(true);
|
|
3155
3104
|
}, []);
|
|
3156
3105
|
if (!isMounted) {
|
|
@@ -3211,7 +3160,7 @@ var ManagedContactBlock = ({
|
|
|
3211
3160
|
};
|
|
3212
3161
|
|
|
3213
3162
|
// src/components/ManagedPricingBlock.tsx
|
|
3214
|
-
import React30, { useState as useState22, useEffect as
|
|
3163
|
+
import React30, { useState as useState22, useEffect as useEffect13, useRef as useRef8 } from "react";
|
|
3215
3164
|
import Link7 from "next/link";
|
|
3216
3165
|
import Image5 from "next/image";
|
|
3217
3166
|
var CheckIcon = ({ className = "" }) => /* @__PURE__ */ React30.createElement("svg", { viewBox: "0 0 24 24", fill: "none", className: `w-4 h-4 shrink-0 ${className}`, xmlns: "http://www.w3.org/2000/svg" }, /* @__PURE__ */ React30.createElement("circle", { cx: "12", cy: "12", r: "10", fill: "black" }), /* @__PURE__ */ React30.createElement("path", { d: "M8 12L11 15L16 9", stroke: "white", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }));
|
|
@@ -3225,7 +3174,7 @@ var ManagedPricingBlock = ({
|
|
|
3225
3174
|
const [isAnimating, setIsAnimating] = useState22(false);
|
|
3226
3175
|
const [activeTabIndex, setActiveTabIndex] = useState22(0);
|
|
3227
3176
|
const titleRef = useRef8(null);
|
|
3228
|
-
|
|
3177
|
+
useEffect13(() => {
|
|
3229
3178
|
const observer = new IntersectionObserver(
|
|
3230
3179
|
([entry]) => {
|
|
3231
3180
|
if (entry.isIntersecting) {
|
|
@@ -3440,14 +3389,14 @@ var ManagedNewsletterSplitBlock = ({
|
|
|
3440
3389
|
};
|
|
3441
3390
|
|
|
3442
3391
|
// src/components/PortfolioHero.tsx
|
|
3443
|
-
import React34, { useEffect as
|
|
3392
|
+
import React34, { useEffect as useEffect14, useRef as useRef9 } from "react";
|
|
3444
3393
|
import Link8 from "next/link";
|
|
3445
3394
|
import Image8 from "next/image";
|
|
3446
3395
|
import { HugeiconsIcon as HugeiconsIcon22 } from "@hugeicons/react";
|
|
3447
3396
|
import { ArrowRight01Icon as ArrowRight01Icon7 } from "@hugeicons/core-free-icons";
|
|
3448
3397
|
var useScrollAnimation = () => {
|
|
3449
3398
|
const elementRef = useRef9(null);
|
|
3450
|
-
|
|
3399
|
+
useEffect14(() => {
|
|
3451
3400
|
const el = elementRef.current;
|
|
3452
3401
|
if (!el) return;
|
|
3453
3402
|
const observer = new IntersectionObserver(
|
|
@@ -3575,7 +3524,7 @@ var GifFeatureCard = ({
|
|
|
3575
3524
|
};
|
|
3576
3525
|
|
|
3577
3526
|
// src/components/MedicalFeatureStatsBlock.tsx
|
|
3578
|
-
import React36, { useState as useState24, useEffect as
|
|
3527
|
+
import React36, { useState as useState24, useEffect as useEffect15, useRef as useRef10 } from "react";
|
|
3579
3528
|
import Image10 from "next/image";
|
|
3580
3529
|
var MedicalFeatureStatsBlock = ({
|
|
3581
3530
|
bottomHeadline,
|
|
@@ -3586,7 +3535,7 @@ var MedicalFeatureStatsBlock = ({
|
|
|
3586
3535
|
}) => {
|
|
3587
3536
|
const [isAnimating, setIsAnimating] = useState24(false);
|
|
3588
3537
|
const titleRef = useRef10(null);
|
|
3589
|
-
|
|
3538
|
+
useEffect15(() => {
|
|
3590
3539
|
const observer = new IntersectionObserver(
|
|
3591
3540
|
([entry]) => {
|
|
3592
3541
|
if (entry.isIntersecting) {
|
|
@@ -4291,7 +4240,7 @@ var UniversalCardActionPage = ({
|
|
|
4291
4240
|
};
|
|
4292
4241
|
|
|
4293
4242
|
// src/components/PinDialerBottomSheet.tsx
|
|
4294
|
-
import React44, { useState as useState30, useEffect as
|
|
4243
|
+
import React44, { useState as useState30, useEffect as useEffect16 } from "react";
|
|
4295
4244
|
import { HugeiconsIcon as HugeiconsIcon30 } from "@hugeicons/react";
|
|
4296
4245
|
import { CancelCircleIcon as CancelCircleIcon8 } from "@hugeicons/core-free-icons";
|
|
4297
4246
|
var PinDialerBottomSheet = ({
|
|
@@ -4302,7 +4251,7 @@ var PinDialerBottomSheet = ({
|
|
|
4302
4251
|
onComplete
|
|
4303
4252
|
}) => {
|
|
4304
4253
|
const [pin, setPin] = useState30("");
|
|
4305
|
-
|
|
4254
|
+
useEffect16(() => {
|
|
4306
4255
|
setPin("");
|
|
4307
4256
|
}, [isOpen]);
|
|
4308
4257
|
const handleSubmit = (e) => {
|