@loafmarkets/ui 0.1.19 → 0.1.21
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 +10 -5
- package/dist/index.d.ts +10 -5
- package/dist/index.js +273 -69
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +273 -69
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -4447,7 +4447,8 @@ var Header = ({
|
|
|
4447
4447
|
onTradeClick,
|
|
4448
4448
|
onProfileNavigate: _onProfileNavigate,
|
|
4449
4449
|
onOrdersNavigate: _onOrdersNavigate,
|
|
4450
|
-
onWalletNavigate: _onWalletNavigate
|
|
4450
|
+
onWalletNavigate: _onWalletNavigate,
|
|
4451
|
+
showTradeTab = true
|
|
4451
4452
|
}) => {
|
|
4452
4453
|
const [isUserMenuOpen, setIsUserMenuOpen] = useState(false);
|
|
4453
4454
|
const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false);
|
|
@@ -4537,6 +4538,9 @@ var Header = ({
|
|
|
4537
4538
|
performNavigation(resolvedLoafLiquidityPath);
|
|
4538
4539
|
};
|
|
4539
4540
|
const handleTradeNavigation = () => {
|
|
4541
|
+
if (!showTradeTab) {
|
|
4542
|
+
return;
|
|
4543
|
+
}
|
|
4540
4544
|
closeMenus();
|
|
4541
4545
|
if (onTradeClick) {
|
|
4542
4546
|
onTradeClick();
|
|
@@ -4634,7 +4638,7 @@ var Header = ({
|
|
|
4634
4638
|
const resolvedPortfolioPath = portfolioPath ?? DEFAULT_PORTFOLIO_PATH;
|
|
4635
4639
|
const resolvedLoafLiquidityPath = loafLiquidityPath ?? DEFAULT_LOAF_LIQUIDITY_PATH;
|
|
4636
4640
|
const inferredActiveTab = (() => {
|
|
4637
|
-
if (locationPath === resolvedTradePath) return "trade";
|
|
4641
|
+
if (showTradeTab && locationPath === resolvedTradePath) return "trade";
|
|
4638
4642
|
if (locationPath === resolvedHomePath) return "home";
|
|
4639
4643
|
if (locationPath === resolvedAboutPath) return "about";
|
|
4640
4644
|
if (locationPath === resolvedLearnPath) return "learn";
|
|
@@ -4644,7 +4648,7 @@ var Header = ({
|
|
|
4644
4648
|
return null;
|
|
4645
4649
|
})();
|
|
4646
4650
|
const resolvedActiveTab = activeTab ?? inferredActiveTab;
|
|
4647
|
-
const tradeActive = resolvedActiveTab === "trade";
|
|
4651
|
+
const tradeActive = showTradeTab && resolvedActiveTab === "trade";
|
|
4648
4652
|
const homeActive = resolvedActiveTab === "home";
|
|
4649
4653
|
const offeringsActive = resolvedActiveTab === "offerings";
|
|
4650
4654
|
const propertyMapActive = resolvedActiveTab === "propertyMap";
|
|
@@ -4681,25 +4685,25 @@ var Header = ({
|
|
|
4681
4685
|
/* @__PURE__ */ jsx(
|
|
4682
4686
|
NavLink,
|
|
4683
4687
|
{
|
|
4684
|
-
href:
|
|
4685
|
-
className:
|
|
4688
|
+
href: resolvedPortfolioPath,
|
|
4689
|
+
className: portfolioActive ? "active" : "",
|
|
4686
4690
|
onClick: (event) => {
|
|
4687
4691
|
event.preventDefault();
|
|
4688
|
-
|
|
4692
|
+
handleNavigation(resolvedPortfolioPath);
|
|
4689
4693
|
},
|
|
4690
|
-
children: "
|
|
4694
|
+
children: "Portfolio"
|
|
4691
4695
|
}
|
|
4692
4696
|
),
|
|
4693
|
-
/* @__PURE__ */ jsx(
|
|
4697
|
+
showTradeTab && /* @__PURE__ */ jsx(
|
|
4694
4698
|
NavLink,
|
|
4695
4699
|
{
|
|
4696
|
-
href:
|
|
4697
|
-
className:
|
|
4700
|
+
href: resolvedTradePath,
|
|
4701
|
+
className: tradeActive ? "active" : "",
|
|
4698
4702
|
onClick: (event) => {
|
|
4699
4703
|
event.preventDefault();
|
|
4700
|
-
|
|
4704
|
+
handleTradeNavigation();
|
|
4701
4705
|
},
|
|
4702
|
-
children: "
|
|
4706
|
+
children: "Trade"
|
|
4703
4707
|
}
|
|
4704
4708
|
),
|
|
4705
4709
|
/* @__PURE__ */ jsx(
|
|
@@ -4777,6 +4781,13 @@ var Header = ({
|
|
|
4777
4781
|
] }),
|
|
4778
4782
|
/* @__PURE__ */ jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedHomePath), children: "Home" }),
|
|
4779
4783
|
/* @__PURE__ */ jsx(
|
|
4784
|
+
MobileNavItem,
|
|
4785
|
+
{
|
|
4786
|
+
onClick: () => handleNavigation(resolvedPortfolioPath),
|
|
4787
|
+
children: "Portfolio"
|
|
4788
|
+
}
|
|
4789
|
+
),
|
|
4790
|
+
showTradeTab && /* @__PURE__ */ jsx(
|
|
4780
4791
|
MobileNavItem,
|
|
4781
4792
|
{
|
|
4782
4793
|
onClick: () => {
|
|
@@ -4785,7 +4796,6 @@ var Header = ({
|
|
|
4785
4796
|
children: "Trade"
|
|
4786
4797
|
}
|
|
4787
4798
|
),
|
|
4788
|
-
/* @__PURE__ */ jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedPortfolioPath), children: "Portfolio" }),
|
|
4789
4799
|
/* @__PURE__ */ jsx(MobileNavItem, { onClick: () => handleNavigation(offeringsHref), children: "Initial Offerings" }),
|
|
4790
4800
|
/* @__PURE__ */ jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedPropertyMapPath), children: "Property Map" }),
|
|
4791
4801
|
/* @__PURE__ */ jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedLearnPath), children: "Learn" }),
|
|
@@ -5442,8 +5452,10 @@ var LoginPopup = ({
|
|
|
5442
5452
|
const [fundingAmount, setFundingAmount] = useState("");
|
|
5443
5453
|
const [kycLoading, setKycLoading] = useState(false);
|
|
5444
5454
|
const [showKycWidget, setShowKycWidget] = useState(false);
|
|
5445
|
-
const [
|
|
5455
|
+
const [cryptoFundingLoading, setCryptoFundingLoading] = useState(false);
|
|
5456
|
+
const [fiatFundingLoading, setFiatFundingLoading] = useState(false);
|
|
5446
5457
|
const [fundingError, setFundingError] = useState("");
|
|
5458
|
+
const [transakWidgetUrl, setTransakWidgetUrl] = useState(null);
|
|
5447
5459
|
const suppressAutoCloseRef = React5__default.useRef(false);
|
|
5448
5460
|
useEffect(() => {
|
|
5449
5461
|
console.log("[LoginTrace][Popup] mounted");
|
|
@@ -5461,6 +5473,35 @@ var LoginPopup = ({
|
|
|
5461
5473
|
setView(initialView);
|
|
5462
5474
|
}
|
|
5463
5475
|
}, [initialView]);
|
|
5476
|
+
useEffect(() => {
|
|
5477
|
+
if (!transakWidgetUrl) return;
|
|
5478
|
+
const handleTransakMessage = (event) => {
|
|
5479
|
+
if (!event.origin.includes("transak.com") && !event.origin.includes("global.transak.com")) {
|
|
5480
|
+
return;
|
|
5481
|
+
}
|
|
5482
|
+
console.log("[LoginTrace][Popup] Transak message received", event.data);
|
|
5483
|
+
try {
|
|
5484
|
+
const data = typeof event.data === "string" ? JSON.parse(event.data) : event.data;
|
|
5485
|
+
if (data.event_id === "TRANSAK_ORDER_SUCCESSFUL") {
|
|
5486
|
+
console.log("[LoginTrace][Popup] Transak order successful", data);
|
|
5487
|
+
setTimeout(() => {
|
|
5488
|
+
onClose();
|
|
5489
|
+
}, 2e3);
|
|
5490
|
+
} else if (data.event_id === "TRANSAK_ORDER_FAILED") {
|
|
5491
|
+
console.error("[LoginTrace][Popup] Transak order failed", data);
|
|
5492
|
+
setFundingError("Transaction failed. Please try again.");
|
|
5493
|
+
setTransakWidgetUrl(null);
|
|
5494
|
+
} else if (data.event_id === "TRANSAK_WIDGET_CLOSE") {
|
|
5495
|
+
console.log("[LoginTrace][Popup] Transak widget closed by user");
|
|
5496
|
+
setTransakWidgetUrl(null);
|
|
5497
|
+
}
|
|
5498
|
+
} catch (err) {
|
|
5499
|
+
console.warn("[LoginTrace][Popup] Failed to parse Transak message", err);
|
|
5500
|
+
}
|
|
5501
|
+
};
|
|
5502
|
+
window.addEventListener("message", handleTransakMessage);
|
|
5503
|
+
return () => window.removeEventListener("message", handleTransakMessage);
|
|
5504
|
+
}, [transakWidgetUrl, onClose]);
|
|
5464
5505
|
useEffect(() => {
|
|
5465
5506
|
if (!autoCloseOnAuth) {
|
|
5466
5507
|
console.log("[LoginTrace][Popup] autoClose disabled", { autoCloseOnAuth, view });
|
|
@@ -5644,6 +5685,10 @@ var LoginPopup = ({
|
|
|
5644
5685
|
setView("kyc-failed");
|
|
5645
5686
|
}
|
|
5646
5687
|
};
|
|
5688
|
+
const handleKycWidgetClose = () => {
|
|
5689
|
+
setShowKycWidget(false);
|
|
5690
|
+
onClose();
|
|
5691
|
+
};
|
|
5647
5692
|
const handleKycStart = async () => {
|
|
5648
5693
|
if (renderKycWidget) {
|
|
5649
5694
|
setShowKycWidget(true);
|
|
@@ -5671,28 +5716,54 @@ var LoginPopup = ({
|
|
|
5671
5716
|
const handleKycSkip = () => {
|
|
5672
5717
|
onClose();
|
|
5673
5718
|
};
|
|
5674
|
-
const
|
|
5719
|
+
const handleCryptoFund = async () => {
|
|
5675
5720
|
if (!onFundWallet) {
|
|
5676
5721
|
onClose();
|
|
5677
5722
|
return;
|
|
5678
5723
|
}
|
|
5679
|
-
setFundingLoading(true);
|
|
5680
5724
|
setFundingError("");
|
|
5725
|
+
setCryptoFundingLoading(true);
|
|
5681
5726
|
try {
|
|
5682
|
-
const result = await onFundWallet({ amount: fundingAmount || "100" });
|
|
5683
|
-
if (result
|
|
5727
|
+
const result = await onFundWallet({ amount: fundingAmount || "100", mode: "crypto" });
|
|
5728
|
+
if (result?.funded) {
|
|
5729
|
+
onClose();
|
|
5730
|
+
}
|
|
5731
|
+
} catch (err) {
|
|
5732
|
+
setFundingError(err instanceof Error ? err.message : "Unable to launch funding. Please try again.");
|
|
5733
|
+
} finally {
|
|
5734
|
+
setCryptoFundingLoading(false);
|
|
5735
|
+
}
|
|
5736
|
+
};
|
|
5737
|
+
const handleFiatFund = async () => {
|
|
5738
|
+
if (!onFundWallet) {
|
|
5739
|
+
onClose();
|
|
5740
|
+
return;
|
|
5741
|
+
}
|
|
5742
|
+
setFundingError("");
|
|
5743
|
+
setFiatFundingLoading(true);
|
|
5744
|
+
try {
|
|
5745
|
+
const result = await onFundWallet({ amount: fundingAmount || "100", mode: "fiat" });
|
|
5746
|
+
if (result?.widgetUrl) {
|
|
5747
|
+
setTransakWidgetUrl(result.widgetUrl);
|
|
5748
|
+
} else if (result?.requiresKyc) {
|
|
5749
|
+
setView("kyc");
|
|
5750
|
+
setShowKycWidget(true);
|
|
5751
|
+
} else if (result?.funded) {
|
|
5684
5752
|
onClose();
|
|
5685
|
-
} else {
|
|
5686
|
-
setFundingLoading(false);
|
|
5687
5753
|
}
|
|
5688
5754
|
} catch (err) {
|
|
5689
5755
|
setFundingError(err instanceof Error ? err.message : "Unable to launch funding. Please try again.");
|
|
5690
|
-
|
|
5756
|
+
} finally {
|
|
5757
|
+
setFiatFundingLoading(false);
|
|
5691
5758
|
}
|
|
5692
5759
|
};
|
|
5693
5760
|
const handleFundingSkip = () => {
|
|
5694
5761
|
onClose();
|
|
5695
5762
|
};
|
|
5763
|
+
const handleTransakClose = () => {
|
|
5764
|
+
setTransakWidgetUrl(null);
|
|
5765
|
+
setFundingError("");
|
|
5766
|
+
};
|
|
5696
5767
|
const handleFundingAmountChange = (event) => {
|
|
5697
5768
|
const next = event.target.value.replace(/[^0-9.]/g, "");
|
|
5698
5769
|
setFundingAmount(next);
|
|
@@ -5868,7 +5939,10 @@ var LoginPopup = ({
|
|
|
5868
5939
|
$expanded: showKycWidget,
|
|
5869
5940
|
children: [
|
|
5870
5941
|
/* @__PURE__ */ jsx(CloseButton, { onClick: onClose, "aria-label": "Close login popup", children: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }) }) }),
|
|
5871
|
-
showKycWidget && renderKycWidget ? /* @__PURE__ */
|
|
5942
|
+
showKycWidget && renderKycWidget ? /* @__PURE__ */ jsxs(KycWidgetContainer, { children: [
|
|
5943
|
+
/* @__PURE__ */ jsx(InlineCloseButton, { onClick: handleKycWidgetClose, "aria-label": "Close KYC widget", children: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }) }) }),
|
|
5944
|
+
renderKycWidget(handleKycWidgetResult)
|
|
5945
|
+
] }) : /* @__PURE__ */ jsxs(OnboardingStepContainer, { children: [
|
|
5872
5946
|
/* @__PURE__ */ jsx(OnboardingHeading, { children: "KYC to Continue" }),
|
|
5873
5947
|
/* @__PURE__ */ jsx(OnboardingSubtext, { children: "Loaf requires all users to KYC before they can start purchasing properties." }),
|
|
5874
5948
|
/* @__PURE__ */ jsxs(OnboardingButtonGroup, { children: [
|
|
@@ -5886,15 +5960,14 @@ var LoginPopup = ({
|
|
|
5886
5960
|
/* @__PURE__ */ jsx(CloseButton, { onClick: onClose, "aria-label": "Close login popup", children: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }) }) }),
|
|
5887
5961
|
/* @__PURE__ */ jsxs(OnboardingStepContainer, { children: [
|
|
5888
5962
|
/* @__PURE__ */ jsx(KycSuccessIcon, { children: /* @__PURE__ */ jsx("svg", { width: "64", height: "64", viewBox: "0 0 64 64", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M20 34.5L28.5 43 44 25", stroke: "var(--color-accent, #e6c656)", strokeWidth: "4", strokeLinecap: "round", strokeLinejoin: "round" }) }) }),
|
|
5889
|
-
/* @__PURE__ */ jsx(OnboardingHeading, { children: "
|
|
5963
|
+
/* @__PURE__ */ jsx(OnboardingHeading, { children: "KYC pending review" }),
|
|
5890
5964
|
/* @__PURE__ */ jsxs(OnboardingSubtext, { children: [
|
|
5891
|
-
"
|
|
5892
|
-
/* @__PURE__ */ jsx("br", {})
|
|
5893
|
-
"You can start purchasing properties."
|
|
5965
|
+
"Thanks for submitting your documents.",
|
|
5966
|
+
/* @__PURE__ */ jsx("br", {})
|
|
5894
5967
|
] }),
|
|
5895
5968
|
/* @__PURE__ */ jsxs(OnboardingButtonGroup, { children: [
|
|
5896
|
-
/* @__PURE__ */ jsx(SubmitButton, { onClick:
|
|
5897
|
-
/* @__PURE__ */ jsx(OnboardingSkipButton, { onClick:
|
|
5969
|
+
/* @__PURE__ */ jsx(SubmitButton, { onClick: onClose, children: "Close" }),
|
|
5970
|
+
/* @__PURE__ */ jsx(OnboardingSkipButton, { onClick: () => setView("funding"), children: "Fund now" })
|
|
5898
5971
|
] })
|
|
5899
5972
|
] })
|
|
5900
5973
|
] }) });
|
|
@@ -5930,32 +6003,62 @@ var LoginPopup = ({
|
|
|
5930
6003
|
] }) });
|
|
5931
6004
|
}
|
|
5932
6005
|
if (view === "funding") {
|
|
5933
|
-
return /* @__PURE__ */ jsx(Overlay2, { children: /* @__PURE__ */ jsxs(
|
|
5934
|
-
|
|
5935
|
-
|
|
5936
|
-
|
|
5937
|
-
|
|
5938
|
-
|
|
5939
|
-
/* @__PURE__ */ jsx(
|
|
5940
|
-
/* @__PURE__ */ jsxs(
|
|
5941
|
-
/* @__PURE__ */
|
|
5942
|
-
|
|
5943
|
-
|
|
6006
|
+
return /* @__PURE__ */ jsx(Overlay2, { children: /* @__PURE__ */ jsxs(
|
|
6007
|
+
FundingPopupContainer,
|
|
6008
|
+
{
|
|
6009
|
+
onClick: (event) => event.stopPropagation(),
|
|
6010
|
+
$hasWidget: !!transakWidgetUrl,
|
|
6011
|
+
children: [
|
|
6012
|
+
/* @__PURE__ */ jsx(CloseButton, { onClick: onClose, "aria-label": "Close login popup", children: /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }) }) }),
|
|
6013
|
+
transakWidgetUrl ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
6014
|
+
/* @__PURE__ */ jsxs(BackButton, { onClick: handleTransakClose, style: { position: "absolute", top: "1rem", left: "1rem", zIndex: 1 }, children: [
|
|
6015
|
+
/* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsx("path", { d: "M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z" }) }),
|
|
6016
|
+
"Back"
|
|
6017
|
+
] }),
|
|
6018
|
+
/* @__PURE__ */ jsx(TransakWidgetContainer, { children: /* @__PURE__ */ jsx(
|
|
6019
|
+
TransakIframe,
|
|
5944
6020
|
{
|
|
5945
|
-
|
|
5946
|
-
|
|
5947
|
-
|
|
5948
|
-
onChange: handleFundingAmountChange,
|
|
5949
|
-
placeholder: "0"
|
|
6021
|
+
src: transakWidgetUrl,
|
|
6022
|
+
title: "Transak Onramp Widget",
|
|
6023
|
+
allow: "camera; microphone; payment"
|
|
5950
6024
|
}
|
|
5951
|
-
)
|
|
5952
|
-
] }),
|
|
5953
|
-
|
|
5954
|
-
|
|
5955
|
-
|
|
5956
|
-
|
|
5957
|
-
|
|
5958
|
-
|
|
6025
|
+
) })
|
|
6026
|
+
] }) : /* @__PURE__ */ jsxs(OnboardingStepContainer, { children: [
|
|
6027
|
+
/* @__PURE__ */ jsx(OnboardingHeading, { children: "Fund your account" }),
|
|
6028
|
+
/* @__PURE__ */ jsxs(FundingCard, { children: [
|
|
6029
|
+
/* @__PURE__ */ jsx(FundingCardLabel, { children: "How much would you like to transfer?" }),
|
|
6030
|
+
/* @__PURE__ */ jsxs(FundingInputWrapper, { children: [
|
|
6031
|
+
/* @__PURE__ */ jsx(FundingCurrencyLabel, { children: "AUD" }),
|
|
6032
|
+
/* @__PURE__ */ jsx(
|
|
6033
|
+
FundingAmountInput,
|
|
6034
|
+
{
|
|
6035
|
+
type: "text",
|
|
6036
|
+
inputMode: "decimal",
|
|
6037
|
+
value: fundingAmount,
|
|
6038
|
+
onChange: handleFundingAmountChange,
|
|
6039
|
+
placeholder: "0"
|
|
6040
|
+
}
|
|
6041
|
+
)
|
|
6042
|
+
] }),
|
|
6043
|
+
/* @__PURE__ */ jsxs(FundingOptionsGrid, { children: [
|
|
6044
|
+
/* @__PURE__ */ jsxs(FundingOptionCard, { children: [
|
|
6045
|
+
/* @__PURE__ */ jsx(FundingOptionHeading, { children: "Crypto transfer" }),
|
|
6046
|
+
/* @__PURE__ */ jsx(FundingOptionSubtext, { children: "Use Privy's Coinbase onramp to move crypto from another exchange or wallet." }),
|
|
6047
|
+
/* @__PURE__ */ jsx(SubmitButton, { onClick: handleCryptoFund, disabled: cryptoFundingLoading, children: cryptoFundingLoading ? "Opening Coinbase\u2026" : "Use crypto deposit" })
|
|
6048
|
+
] }),
|
|
6049
|
+
/* @__PURE__ */ jsxs(FundingOptionCard, { children: [
|
|
6050
|
+
/* @__PURE__ */ jsx(FundingOptionHeading, { children: "Fiat onramp" }),
|
|
6051
|
+
/* @__PURE__ */ jsx(FundingOptionSubtext, { children: "Buy USDC instantly with your card or local payment methods via Transak." }),
|
|
6052
|
+
/* @__PURE__ */ jsx(SubmitButton, { onClick: handleFiatFund, disabled: fiatFundingLoading, children: fiatFundingLoading ? "Loading widget\u2026" : "Use onramp" })
|
|
6053
|
+
] })
|
|
6054
|
+
] }),
|
|
6055
|
+
/* @__PURE__ */ jsx(OnboardingSkipButton, { onClick: handleFundingSkip, style: { marginTop: "1.25rem" }, children: "Skip for now" }),
|
|
6056
|
+
fundingError && /* @__PURE__ */ jsx(StatusMessage, { $error: true, children: fundingError })
|
|
6057
|
+
] })
|
|
6058
|
+
] })
|
|
6059
|
+
]
|
|
6060
|
+
}
|
|
6061
|
+
) });
|
|
5959
6062
|
}
|
|
5960
6063
|
return null;
|
|
5961
6064
|
};
|
|
@@ -6042,6 +6145,34 @@ var KycWidgetContainer = styled23.div`
|
|
|
6042
6145
|
width: 100%;
|
|
6043
6146
|
display: flex;
|
|
6044
6147
|
flex-direction: column;
|
|
6148
|
+
position: relative;
|
|
6149
|
+
gap: 0.75rem;
|
|
6150
|
+
`;
|
|
6151
|
+
var InlineCloseButton = styled23.button`
|
|
6152
|
+
position: absolute;
|
|
6153
|
+
top: -12px;
|
|
6154
|
+
right: -12px;
|
|
6155
|
+
background: rgba(0, 0, 0, 0.4);
|
|
6156
|
+
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
6157
|
+
border-radius: 999px;
|
|
6158
|
+
color: var(--color-text-secondary, #848e9c);
|
|
6159
|
+
width: 32px;
|
|
6160
|
+
height: 32px;
|
|
6161
|
+
display: flex;
|
|
6162
|
+
align-items: center;
|
|
6163
|
+
justify-content: center;
|
|
6164
|
+
cursor: pointer;
|
|
6165
|
+
transition: color 0.2s ease, background 0.2s ease;
|
|
6166
|
+
|
|
6167
|
+
&:hover {
|
|
6168
|
+
background: rgba(0, 0, 0, 0.6);
|
|
6169
|
+
color: var(--color-accent, #e6c656);
|
|
6170
|
+
}
|
|
6171
|
+
|
|
6172
|
+
svg {
|
|
6173
|
+
width: 18px;
|
|
6174
|
+
height: 18px;
|
|
6175
|
+
}
|
|
6045
6176
|
`;
|
|
6046
6177
|
var CloseButton = styled23.button`
|
|
6047
6178
|
position: absolute;
|
|
@@ -6215,7 +6346,7 @@ var OTPInput = styled23.input`
|
|
|
6215
6346
|
`;
|
|
6216
6347
|
var SubmitButton = styled23.button`
|
|
6217
6348
|
width: 100%;
|
|
6218
|
-
padding:
|
|
6349
|
+
padding: 0.85rem;
|
|
6219
6350
|
background-color: var(--color-accent, #e6c656);
|
|
6220
6351
|
border: none;
|
|
6221
6352
|
border-radius: var(--border-radius, 8px);
|
|
@@ -6262,13 +6393,14 @@ var OnboardingStepContainer = styled23.div`
|
|
|
6262
6393
|
flex-direction: column;
|
|
6263
6394
|
align-items: center;
|
|
6264
6395
|
text-align: center;
|
|
6265
|
-
padding:
|
|
6396
|
+
padding: 0.25rem 0;
|
|
6397
|
+
gap: 0.5rem;
|
|
6266
6398
|
`;
|
|
6267
6399
|
var OnboardingHeading = styled23.h2`
|
|
6268
|
-
font-size: 1.
|
|
6400
|
+
font-size: 1.2rem;
|
|
6269
6401
|
font-weight: 600;
|
|
6270
6402
|
color: var(--color-text, #eaecef);
|
|
6271
|
-
margin
|
|
6403
|
+
margin: 0;
|
|
6272
6404
|
`;
|
|
6273
6405
|
var OnboardingSubtext = styled23.p`
|
|
6274
6406
|
font-size: 0.95rem;
|
|
@@ -6284,7 +6416,7 @@ var OnboardingButtonGroup = styled23.div`
|
|
|
6284
6416
|
`;
|
|
6285
6417
|
var OnboardingSkipButton = styled23.button`
|
|
6286
6418
|
width: 100%;
|
|
6287
|
-
padding: 0.
|
|
6419
|
+
padding: 0.75rem 0.9rem;
|
|
6288
6420
|
background-color: rgba(255, 255, 255, 0.05);
|
|
6289
6421
|
border: none;
|
|
6290
6422
|
border-radius: var(--border-radius, 8px);
|
|
@@ -6321,22 +6453,22 @@ var KycFailedIcon = styled23.div`
|
|
|
6321
6453
|
`;
|
|
6322
6454
|
var FundingCard = styled23.div`
|
|
6323
6455
|
width: 100%;
|
|
6324
|
-
border-radius:
|
|
6456
|
+
border-radius: 14px;
|
|
6325
6457
|
background-color: var(--color-background-light, #14151e);
|
|
6326
|
-
padding:
|
|
6458
|
+
padding: 1rem;
|
|
6327
6459
|
text-align: left;
|
|
6328
|
-
box-shadow: 0
|
|
6460
|
+
box-shadow: 0 18px 60px rgba(0, 0, 0, 0.4);
|
|
6329
6461
|
`;
|
|
6330
6462
|
var FundingCardLabel = styled23.p`
|
|
6331
|
-
font-size:
|
|
6463
|
+
font-size: 0.9rem;
|
|
6332
6464
|
color: var(--color-text, #eaecef);
|
|
6333
|
-
margin-bottom:
|
|
6465
|
+
margin-bottom: 0.5rem;
|
|
6334
6466
|
`;
|
|
6335
6467
|
var FundingInputWrapper = styled23.div`
|
|
6336
|
-
border-radius:
|
|
6337
|
-
border: 1px solid rgba(255, 255, 255, 0.
|
|
6468
|
+
border-radius: 12px;
|
|
6469
|
+
border: 1px solid rgba(255, 255, 255, 0.08);
|
|
6338
6470
|
background-color: var(--color-background, #0d0e14);
|
|
6339
|
-
padding:
|
|
6471
|
+
padding: 0.75rem 0.85rem;
|
|
6340
6472
|
`;
|
|
6341
6473
|
var FundingCurrencyLabel = styled23.label`
|
|
6342
6474
|
display: block;
|
|
@@ -6350,10 +6482,10 @@ var FundingAmountInput = styled23.input`
|
|
|
6350
6482
|
background: transparent;
|
|
6351
6483
|
border: none;
|
|
6352
6484
|
outline: none;
|
|
6353
|
-
font-size:
|
|
6485
|
+
font-size: 1.7rem;
|
|
6354
6486
|
font-weight: 400;
|
|
6355
6487
|
color: var(--color-text, #eaecef);
|
|
6356
|
-
margin-top: 0.
|
|
6488
|
+
margin-top: 0.4rem;
|
|
6357
6489
|
font-family: "Geist Mono", "Space Grotesk", monospace;
|
|
6358
6490
|
font-variant-numeric: slashed-zero;
|
|
6359
6491
|
|
|
@@ -6361,6 +6493,79 @@ var FundingAmountInput = styled23.input`
|
|
|
6361
6493
|
color: rgba(255, 255, 255, 0.4);
|
|
6362
6494
|
}
|
|
6363
6495
|
`;
|
|
6496
|
+
var FundingOptionsGrid = styled23.div`
|
|
6497
|
+
display: grid;
|
|
6498
|
+
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
|
|
6499
|
+
gap: 0.6rem;
|
|
6500
|
+
margin-top: 0.75rem;
|
|
6501
|
+
`;
|
|
6502
|
+
var FundingOptionCard = styled23.div`
|
|
6503
|
+
background-color: rgba(255, 255, 255, 0.03);
|
|
6504
|
+
border: 1px solid rgba(255, 255, 255, 0.08);
|
|
6505
|
+
border-radius: 12px;
|
|
6506
|
+
padding: 0.85rem;
|
|
6507
|
+
display: flex;
|
|
6508
|
+
flex-direction: column;
|
|
6509
|
+
gap: 0.4rem;
|
|
6510
|
+
`;
|
|
6511
|
+
var FundingOptionHeading = styled23.h4`
|
|
6512
|
+
margin: 0;
|
|
6513
|
+
font-size: 0.9rem;
|
|
6514
|
+
color: var(--color-text, #eaecef);
|
|
6515
|
+
`;
|
|
6516
|
+
var FundingOptionSubtext = styled23.p`
|
|
6517
|
+
margin: 0;
|
|
6518
|
+
font-size: 0.75rem;
|
|
6519
|
+
line-height: 1.3;
|
|
6520
|
+
color: var(--color-text-secondary, #848e9c);
|
|
6521
|
+
flex: 1;
|
|
6522
|
+
`;
|
|
6523
|
+
var FundingPopupContainer = styled23.div`
|
|
6524
|
+
background-color: var(--color-background, #0a0a0a);
|
|
6525
|
+
border: 1px solid rgba(230, 198, 86, 0.3);
|
|
6526
|
+
border-radius: var(--border-radius, 12px);
|
|
6527
|
+
padding: ${(props) => props.$hasWidget ? "0" : "2.5rem"};
|
|
6528
|
+
max-width: ${(props) => props.$hasWidget ? "900px" : "440px"};
|
|
6529
|
+
width: 90%;
|
|
6530
|
+
position: relative;
|
|
6531
|
+
animation: slideUp 0.3s ease-out;
|
|
6532
|
+
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
|
|
6533
|
+
overflow: hidden;
|
|
6534
|
+
|
|
6535
|
+
@keyframes slideUp {
|
|
6536
|
+
from {
|
|
6537
|
+
transform: translateY(20px);
|
|
6538
|
+
opacity: 0;
|
|
6539
|
+
}
|
|
6540
|
+
to {
|
|
6541
|
+
transform: translateY(0);
|
|
6542
|
+
opacity: 1;
|
|
6543
|
+
}
|
|
6544
|
+
}
|
|
6545
|
+
|
|
6546
|
+
@media (max-width: 768px) {
|
|
6547
|
+
padding: ${(props) => props.$hasWidget ? "0" : "2rem"};
|
|
6548
|
+
max-width: 95%;
|
|
6549
|
+
}
|
|
6550
|
+
`;
|
|
6551
|
+
var TransakWidgetContainer = styled23.div`
|
|
6552
|
+
width: 100%;
|
|
6553
|
+
height: 700px;
|
|
6554
|
+
display: flex;
|
|
6555
|
+
flex-direction: column;
|
|
6556
|
+
border-radius: var(--border-radius, 12px);
|
|
6557
|
+
overflow: hidden;
|
|
6558
|
+
|
|
6559
|
+
@media (max-width: 768px) {
|
|
6560
|
+
height: 600px;
|
|
6561
|
+
}
|
|
6562
|
+
`;
|
|
6563
|
+
var TransakIframe = styled23.iframe`
|
|
6564
|
+
width: 100%;
|
|
6565
|
+
height: 100%;
|
|
6566
|
+
border: none;
|
|
6567
|
+
border-radius: var(--border-radius, 12px);
|
|
6568
|
+
`;
|
|
6364
6569
|
var MiniLiveFeed = () => {
|
|
6365
6570
|
const [purchases, setPurchases] = useState([]);
|
|
6366
6571
|
useEffect(() => {
|
|
@@ -10389,8 +10594,7 @@ function PropertyBuy({
|
|
|
10389
10594
|
setLastOrderDetails({
|
|
10390
10595
|
tokens: tokenAmountInt,
|
|
10391
10596
|
total: orderTotal,
|
|
10392
|
-
price: tokenPrice
|
|
10393
|
-
orderNumber: Math.floor(1e7 + Math.random() * 9e7)
|
|
10597
|
+
price: tokenPrice
|
|
10394
10598
|
});
|
|
10395
10599
|
setOrderPlacedSuccess(true);
|
|
10396
10600
|
setSliderValue(0);
|