@matchain/matchid-sdk-react 0.1.51-alpha.2 → 0.1.52
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/{chunk-5W2S6QMI.mjs → chunk-KJQKG6RI.mjs} +2 -2
- package/dist/{chunk-OWEJPD4R.mjs → chunk-OL4R4SZU.mjs} +17 -28
- package/dist/chunk-OL4R4SZU.mjs.map +1 -0
- package/dist/components/index.js +3 -3
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +2 -2
- package/dist/hooks/api/index.js +2 -2
- package/dist/hooks/api/index.js.map +1 -1
- package/dist/hooks/api/index.mjs +3 -3
- package/dist/hooks/index.js +2 -2
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +2 -2
- package/dist/index.js +3 -14
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -3
- package/example/src/components/Login/index.tsx +9 -1
- package/package.json +1 -1
- package/dist/chunk-OWEJPD4R.mjs.map +0 -1
- /package/dist/{chunk-5W2S6QMI.mjs.map → chunk-KJQKG6RI.mjs.map} +0 -0
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
useUserInfo,
|
|
12
12
|
verifyPohApi,
|
|
13
13
|
wallet_exports
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-OL4R4SZU.mjs";
|
|
15
15
|
import {
|
|
16
16
|
__export
|
|
17
17
|
} from "./chunk-J5LGTIGS.mjs";
|
|
@@ -94,4 +94,4 @@ export {
|
|
|
94
94
|
user_exports,
|
|
95
95
|
api_exports
|
|
96
96
|
};
|
|
97
|
-
//# sourceMappingURL=chunk-
|
|
97
|
+
//# sourceMappingURL=chunk-KJQKG6RI.mjs.map
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
NumberFormatter,
|
|
3
|
-
encodeBase64,
|
|
4
|
-
formatAddress,
|
|
5
|
-
formatDate,
|
|
6
|
-
getAppClientId,
|
|
7
|
-
getVersion,
|
|
8
|
-
isInTgApp,
|
|
9
|
-
isValidEmail,
|
|
10
|
-
isValidUsername,
|
|
11
|
-
truncateAddress
|
|
12
|
-
} from "./chunk-HLUFAIFV.mjs";
|
|
13
1
|
import {
|
|
14
2
|
AlphaAvatar,
|
|
15
3
|
Button,
|
|
@@ -29,6 +17,18 @@ import {
|
|
|
29
17
|
useHash,
|
|
30
18
|
useLayout_exports
|
|
31
19
|
} from "./chunk-FB5MHLWX.mjs";
|
|
20
|
+
import {
|
|
21
|
+
NumberFormatter,
|
|
22
|
+
encodeBase64,
|
|
23
|
+
formatAddress,
|
|
24
|
+
formatDate,
|
|
25
|
+
getAppClientId,
|
|
26
|
+
getVersion,
|
|
27
|
+
isInTgApp,
|
|
28
|
+
isValidEmail,
|
|
29
|
+
isValidUsername,
|
|
30
|
+
truncateAddress
|
|
31
|
+
} from "./chunk-HLUFAIFV.mjs";
|
|
32
32
|
import {
|
|
33
33
|
ArrowDownIcon,
|
|
34
34
|
ArrowRightIcon,
|
|
@@ -603,7 +603,7 @@ var useLocalStore_default = useLocalStore;
|
|
|
603
603
|
import { useMemo as useMemo7 } from "react";
|
|
604
604
|
|
|
605
605
|
// src/MatchContext.tsx
|
|
606
|
-
import { createContext as createContext3, useContext as useContext3
|
|
606
|
+
import { createContext as createContext3, useContext as useContext3 } from "react";
|
|
607
607
|
|
|
608
608
|
// src/hooks/index.tsx
|
|
609
609
|
var hooks_exports = {};
|
|
@@ -3658,17 +3658,6 @@ var MatchProvider = ({
|
|
|
3658
3658
|
useWalletInit({
|
|
3659
3659
|
config: wallet
|
|
3660
3660
|
});
|
|
3661
|
-
useEffect13(() => {
|
|
3662
|
-
if (!window.Telegram) {
|
|
3663
|
-
const script = document.createElement("script");
|
|
3664
|
-
script.src = "https://telegram.org/js/telegram-web-app.js?56";
|
|
3665
|
-
script.async = true;
|
|
3666
|
-
document.body.appendChild(script);
|
|
3667
|
-
return () => {
|
|
3668
|
-
document.body.removeChild(script);
|
|
3669
|
-
};
|
|
3670
|
-
}
|
|
3671
|
-
}, []);
|
|
3672
3661
|
return /* @__PURE__ */ jsx12(IntlProvider, { locale: realLocale, messages: messages[realLocale], children: /* @__PURE__ */ jsx12(QueryClientProvider, { client: queryClient, children: /* @__PURE__ */ jsx12(
|
|
3673
3662
|
MatchContext.Provider,
|
|
3674
3663
|
{
|
|
@@ -3808,11 +3797,11 @@ function useUserInfo() {
|
|
|
3808
3797
|
};
|
|
3809
3798
|
const getLoginEmailCode = async (email) => {
|
|
3810
3799
|
const res = await getEmailCodeApi(email);
|
|
3811
|
-
if (
|
|
3800
|
+
if (isSuccess(res)) {
|
|
3812
3801
|
window.sessionStorage.setItem("loginkey", res.data.key);
|
|
3813
3802
|
return res.data.key;
|
|
3814
3803
|
}
|
|
3815
|
-
|
|
3804
|
+
throw new Error(res.message);
|
|
3816
3805
|
};
|
|
3817
3806
|
const loginByEmail = async ({
|
|
3818
3807
|
email,
|
|
@@ -3997,8 +3986,8 @@ function StepVerify(props) {
|
|
|
3997
3986
|
try {
|
|
3998
3987
|
setError("");
|
|
3999
3988
|
setSending(true);
|
|
4000
|
-
sendTimeRef.current = intervalTime;
|
|
4001
3989
|
await getLoginEmailCode(props.email);
|
|
3990
|
+
sendTimeRef.current = intervalTime;
|
|
4002
3991
|
setSendBtnText(`${sendTimeRef.current}s`);
|
|
4003
3992
|
intervalRef.current = setInterval(() => {
|
|
4004
3993
|
sendTimeRef.current--;
|
|
@@ -6462,4 +6451,4 @@ export {
|
|
|
6462
6451
|
MatchProvider,
|
|
6463
6452
|
useMatch
|
|
6464
6453
|
};
|
|
6465
|
-
//# sourceMappingURL=chunk-
|
|
6454
|
+
//# sourceMappingURL=chunk-OL4R4SZU.mjs.map
|