@loafmarkets/ui 0.1.298 → 0.1.300
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 +52 -15
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +52 -15
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -6300,7 +6300,8 @@ var LoginPopup = ({
|
|
|
6300
6300
|
onKycStart,
|
|
6301
6301
|
renderKycWidget,
|
|
6302
6302
|
onFundWallet,
|
|
6303
|
-
initialView
|
|
6303
|
+
initialView,
|
|
6304
|
+
kycStatus: kycStatusProp
|
|
6304
6305
|
}) => {
|
|
6305
6306
|
const [view, setView] = useState(() => initialView ?? "main");
|
|
6306
6307
|
const [email, setEmail] = useState("");
|
|
@@ -6537,10 +6538,6 @@ var LoginPopup = ({
|
|
|
6537
6538
|
setView("kyc-failed");
|
|
6538
6539
|
}
|
|
6539
6540
|
};
|
|
6540
|
-
const handleKycWidgetClose = () => {
|
|
6541
|
-
setShowKycWidget(false);
|
|
6542
|
-
onClose();
|
|
6543
|
-
};
|
|
6544
6541
|
const handleKycStart = async () => {
|
|
6545
6542
|
if (renderKycWidget) {
|
|
6546
6543
|
setShowKycWidget(true);
|
|
@@ -6786,19 +6783,26 @@ var LoginPopup = ({
|
|
|
6786
6783
|
$expanded: showKycWidget,
|
|
6787
6784
|
children: [
|
|
6788
6785
|
/* @__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" }) }) }),
|
|
6789
|
-
|
|
6790
|
-
|
|
6791
|
-
|
|
6792
|
-
|
|
6786
|
+
renderKycWidget && /* @__PURE__ */ jsxs(KycWidgetContainer, { style: showKycWidget ? void 0 : { position: "absolute", left: "-9999px", opacity: 0, pointerEvents: "none" }, children: [
|
|
6787
|
+
renderKycWidget(handleKycWidgetResult),
|
|
6788
|
+
/* @__PURE__ */ jsxs(KycWidgetFooter, { children: [
|
|
6789
|
+
/* @__PURE__ */ jsxs(KycProgressSaved, { children: [
|
|
6790
|
+
/* @__PURE__ */ jsx("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "#0ecb81", strokeWidth: "2.5", strokeLinecap: "round", strokeLinejoin: "round", children: /* @__PURE__ */ jsx("polyline", { points: "20 6 9 17 4 12" }) }),
|
|
6791
|
+
"Progress saved"
|
|
6792
|
+
] }),
|
|
6793
|
+
/* @__PURE__ */ jsx(KycExitButton, { type: "button", onClick: onClose, children: "Save & Exit" })
|
|
6794
|
+
] })
|
|
6795
|
+
] }),
|
|
6796
|
+
!showKycWidget && /* @__PURE__ */ jsxs(OnboardingStepContainer, { style: { alignItems: "stretch", textAlign: "left" }, children: [
|
|
6793
6797
|
/* @__PURE__ */ jsx(OnboardingHeading, { style: { textAlign: "center" }, children: "Verify to Gain Access" }),
|
|
6794
6798
|
/* @__PURE__ */ jsx("div", { style: { display: "flex", flexDirection: "column", gap: "0.75rem" }, children: /* @__PURE__ */ jsxs(ModalOptionCard, { onClick: handleKycStart, disabled: kycLoading, children: [
|
|
6795
6799
|
/* @__PURE__ */ jsx("svg", { width: "22", height: "22", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", style: { color: "rgba(255,255,255,0.6)", flexShrink: 0 }, children: /* @__PURE__ */ jsx("path", { d: "M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" }) }),
|
|
6796
6800
|
/* @__PURE__ */ jsxs("div", { style: { flex: 1 }, children: [
|
|
6797
|
-
/* @__PURE__ */ jsx("div", { style: { color: "#fff", fontWeight: 600, fontSize: "0.95rem", marginBottom: "0.25rem" }, children: kycLoading ? "Verifying\u2026" : "Start Verification" }),
|
|
6801
|
+
/* @__PURE__ */ jsx("div", { style: { color: "#fff", fontWeight: 600, fontSize: "0.95rem", marginBottom: "0.25rem" }, children: kycLoading ? "Verifying\u2026" : kycStatusProp === "PENDING" || kycStatusProp === "ON_HOLD" ? "Resume Verification" : "Start Verification" }),
|
|
6798
6802
|
/* @__PURE__ */ jsx("div", { style: { color: "rgba(255,255,255,0.5)", fontSize: "0.8rem" }, children: "Takes about 2 minutes" })
|
|
6799
6803
|
] })
|
|
6800
6804
|
] }) }),
|
|
6801
|
-
/* @__PURE__ */ jsx(OnboardingSkipButton, { onClick: handleKycSkip, style: { marginTop: "1rem" }, children: "
|
|
6805
|
+
/* @__PURE__ */ jsx(OnboardingSkipButton, { onClick: handleKycSkip, style: { marginTop: "1rem" }, children: "Exit" }),
|
|
6802
6806
|
error && /* @__PURE__ */ jsx(StatusMessage, { $error: true, children: error })
|
|
6803
6807
|
] })
|
|
6804
6808
|
]
|
|
@@ -6984,7 +6988,38 @@ var KycWidgetContainer = styled9.div`
|
|
|
6984
6988
|
position: relative;
|
|
6985
6989
|
gap: 0.75rem;
|
|
6986
6990
|
`;
|
|
6987
|
-
var
|
|
6991
|
+
var KycWidgetFooter = styled9.div`
|
|
6992
|
+
display: flex;
|
|
6993
|
+
justify-content: space-between;
|
|
6994
|
+
align-items: center;
|
|
6995
|
+
padding-top: 0.75rem;
|
|
6996
|
+
border-top: 1px solid rgba(255,255,255,0.08);
|
|
6997
|
+
margin-top: 0.5rem;
|
|
6998
|
+
`;
|
|
6999
|
+
var KycProgressSaved = styled9.div`
|
|
7000
|
+
display: flex;
|
|
7001
|
+
align-items: center;
|
|
7002
|
+
gap: 0.4rem;
|
|
7003
|
+
font-size: 0.75rem;
|
|
7004
|
+
font-weight: 500;
|
|
7005
|
+
color: #0ecb81;
|
|
7006
|
+
`;
|
|
7007
|
+
var KycExitButton = styled9.button`
|
|
7008
|
+
background: rgba(255,255,255,0.06);
|
|
7009
|
+
border: 1px solid rgba(255,255,255,0.1);
|
|
7010
|
+
border-radius: 6px;
|
|
7011
|
+
padding: 0.4rem 0.85rem;
|
|
7012
|
+
font-size: 0.75rem;
|
|
7013
|
+
font-weight: 500;
|
|
7014
|
+
color: rgba(255,255,255,0.6);
|
|
7015
|
+
cursor: pointer;
|
|
7016
|
+
transition: all 0.15s ease;
|
|
7017
|
+
&:hover {
|
|
7018
|
+
background: rgba(255,255,255,0.1);
|
|
7019
|
+
color: rgba(255,255,255,0.8);
|
|
7020
|
+
}
|
|
7021
|
+
`;
|
|
7022
|
+
styled9.button`
|
|
6988
7023
|
position: absolute;
|
|
6989
7024
|
top: -12px;
|
|
6990
7025
|
right: -12px;
|
|
@@ -7014,8 +7049,10 @@ var CloseButton = styled9.button`
|
|
|
7014
7049
|
position: absolute;
|
|
7015
7050
|
top: 1rem;
|
|
7016
7051
|
right: 1rem;
|
|
7017
|
-
|
|
7018
|
-
|
|
7052
|
+
z-index: 10;
|
|
7053
|
+
background: rgba(0, 0, 0, 0.6);
|
|
7054
|
+
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
7055
|
+
border-radius: 999px;
|
|
7019
7056
|
color: var(--color-text-secondary, #848e9c);
|
|
7020
7057
|
font-size: 1.5rem;
|
|
7021
7058
|
cursor: pointer;
|
|
@@ -7023,7 +7060,7 @@ var CloseButton = styled9.button`
|
|
|
7023
7060
|
display: flex;
|
|
7024
7061
|
align-items: center;
|
|
7025
7062
|
justify-content: center;
|
|
7026
|
-
transition: color 0.2s ease;
|
|
7063
|
+
transition: color 0.2s ease, background 0.2s ease;
|
|
7027
7064
|
|
|
7028
7065
|
&:hover {
|
|
7029
7066
|
color: var(--color-accent, #e6c656);
|