@getpara/react-sdk-lite 2.0.0-alpha.33 → 2.0.0-alpha.35
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/modal/components/Account/AccountProfile.js +22 -4
- package/dist/modal/components/Account/AccountProfileLink.js +10 -5
- package/dist/modal/components/Account/AccountProfileLinkOptions.js +21 -13
- package/dist/modal/components/Account/AccountProfileUnlink.js +6 -4
- package/dist/modal/components/AddFunds/AddFundsAwaiting.d.ts +1 -1
- package/dist/modal/components/AddFunds/AddFundsAwaiting.js +3 -54
- package/dist/modal/components/AddFunds/AddFundsProvider.js +2 -6
- package/dist/modal/components/AuthMainStep/AuthMainStepContent.js +2 -2
- package/dist/modal/components/ExternalWalletNetworkSelectStep/ExternalWalletNetworkSelectStep.js +6 -6
- package/dist/modal/components/ExternalWallets/ExternalWallets.js +5 -5
- package/dist/modal/components/OAuth/OAuth.js +3 -5
- package/dist/modal/components/VerificationCodeStep/VerificationCodeStep.js +2 -2
- package/dist/modal/components/common.d.ts +7 -5
- package/dist/modal/components/common.js +5 -4
- package/dist/modal/constants/constants.js +1 -1
- package/dist/modal/constants/oAuthLogos.d.ts +2 -3
- package/dist/modal/constants/oAuthLogos.js +28 -28
- package/dist/modal/stores/modal/actions.js +2 -2
- package/dist/modal/stores/modal/useModalStore.d.ts +8 -2
- package/dist/modal/stores/modal/useModalStore.js +1 -1
- package/dist/provider/components/ExternalWalletWrapper.js +3 -26
- package/dist/provider/hooks/mutations/index.d.ts +28 -2
- package/dist/provider/hooks/mutations/index.js +57 -3
- package/dist/provider/hooks/mutations/useClaimPregenWallets.d.ts +40 -0
- package/dist/provider/hooks/mutations/useClaimPregenWallets.js +28 -0
- package/dist/provider/hooks/mutations/useCreateGuestWallets.d.ts +33 -0
- package/dist/provider/hooks/mutations/useCreateGuestWallets.js +28 -0
- package/dist/provider/hooks/mutations/useCreatePregenWallet.d.ts +120 -0
- package/dist/provider/hooks/mutations/useCreatePregenWallet.js +28 -0
- package/dist/provider/hooks/mutations/useCreatePregenWalletPerType.d.ts +42 -0
- package/dist/provider/hooks/mutations/useCreatePregenWalletPerType.js +28 -0
- package/dist/provider/hooks/mutations/useCreateWallet.d.ts +42 -0
- package/dist/provider/hooks/mutations/useCreateWallet.js +28 -0
- package/dist/provider/hooks/mutations/useCreateWalletPerType.d.ts +54 -0
- package/dist/provider/hooks/mutations/useCreateWalletPerType.js +28 -0
- package/dist/provider/hooks/mutations/useEnable2fa.d.ts +39 -0
- package/dist/provider/hooks/mutations/useEnable2fa.js +28 -0
- package/dist/provider/hooks/mutations/useHasPregenWallet.d.ts +40 -0
- package/dist/provider/hooks/mutations/useHasPregenWallet.js +28 -0
- package/dist/provider/hooks/mutations/useIssueJwt.d.ts +48 -0
- package/dist/provider/hooks/mutations/useIssueJwt.js +28 -0
- package/dist/provider/hooks/mutations/useKeepSessionAlive.d.ts +34 -0
- package/dist/provider/hooks/mutations/useKeepSessionAlive.js +28 -0
- package/dist/provider/hooks/mutations/useLinkAccount.d.ts +30 -1
- package/dist/provider/hooks/mutations/useLinkAccount.js +3 -1
- package/dist/provider/hooks/mutations/useLoginExternalWallet.d.ts +46 -0
- package/dist/provider/hooks/mutations/useLoginExternalWallet.js +28 -0
- package/dist/provider/hooks/mutations/useLogout.d.ts +39 -0
- package/dist/provider/hooks/mutations/useLogout.js +28 -0
- package/dist/provider/hooks/mutations/useResendVerificationCode.d.ts +40 -0
- package/dist/provider/hooks/mutations/useResendVerificationCode.js +28 -0
- package/dist/provider/hooks/mutations/useSetup2fa.d.ts +34 -0
- package/dist/provider/hooks/mutations/useSetup2fa.js +28 -0
- package/dist/provider/hooks/mutations/useSignMessage.d.ts +58 -0
- package/dist/provider/hooks/mutations/useSignMessage.js +28 -0
- package/dist/provider/hooks/mutations/useSignTransaction.d.ts +58 -0
- package/dist/provider/hooks/mutations/useSignTransaction.js +28 -0
- package/dist/provider/hooks/mutations/useSignUpOrLogIn.d.ts +46 -0
- package/dist/provider/hooks/mutations/useSignUpOrLogIn.js +28 -0
- package/dist/provider/hooks/mutations/useUpdatePregenWalletIdentifier.d.ts +42 -0
- package/dist/provider/hooks/mutations/useUpdatePregenWalletIdentifier.js +28 -0
- package/dist/provider/hooks/mutations/useVerify2fa.d.ts +57 -0
- package/dist/provider/hooks/mutations/useVerify2fa.js +28 -0
- package/dist/provider/hooks/mutations/useVerifyExternalWallet.d.ts +93 -0
- package/dist/provider/hooks/mutations/useVerifyExternalWallet.js +28 -0
- package/dist/provider/hooks/mutations/useVerifyFarcaster.d.ts +55 -0
- package/dist/provider/hooks/mutations/useVerifyFarcaster.js +28 -0
- package/dist/provider/hooks/mutations/useVerifyNewAccount.d.ts +84 -0
- package/dist/provider/hooks/mutations/useVerifyNewAccount.js +28 -0
- package/dist/provider/hooks/mutations/useVerifyOAuth.d.ts +64 -0
- package/dist/provider/hooks/mutations/useVerifyOAuth.js +28 -0
- package/dist/provider/hooks/mutations/useVerifyTelegram.d.ts +46 -0
- package/dist/provider/hooks/mutations/useVerifyTelegram.js +28 -0
- package/dist/provider/hooks/mutations/useWaitForLogin.d.ts +57 -0
- package/dist/provider/hooks/mutations/useWaitForLogin.js +28 -0
- package/dist/provider/hooks/mutations/useWaitForSignup.d.ts +45 -0
- package/dist/provider/hooks/mutations/useWaitForSignup.js +28 -0
- package/dist/provider/hooks/mutations/useWaitForWalletCreation.d.ts +54 -0
- package/dist/provider/hooks/mutations/useWaitForWalletCreation.js +28 -0
- package/dist/provider/hooks/mutations/utils.d.ts +2 -7
- package/dist/provider/hooks/mutations/utils.js +0 -24
- package/dist/provider/hooks/queries/index.d.ts +2 -1
- package/dist/provider/hooks/queries/index.js +4 -1
- package/dist/provider/hooks/queries/useAccountLinkInProgress.d.ts +6 -0
- package/dist/provider/hooks/queries/useAccountLinkInProgress.js +24 -0
- package/dist/provider/hooks/queries/useLinkedAccounts.d.ts +11 -0
- package/dist/provider/hooks/queries/useLinkedAccounts.js +24 -0
- package/dist/provider/providers/AccountLinkProvider.d.ts +4 -4
- package/dist/provider/providers/AccountLinkProvider.js +17 -13
- package/dist/provider/providers/AuthProvider.d.ts +0 -1
- package/dist/provider/providers/AuthProvider.js +18 -45
- package/dist/provider/providers/ExternalWalletProvider.d.ts +6 -5
- package/dist/provider/providers/ExternalWalletProvider.js +21 -26
- package/dist/provider/utils/externalWalletDefaults.d.ts +6 -0
- package/dist/provider/utils/externalWalletDefaults.js +33 -0
- package/dist/provider/utils/renameMutations.d.ts +9 -5
- package/dist/provider/utils/renameMutations.js +3 -5
- package/package.json +8 -8
- package/dist/provider/hooks/mutations/core.d.ts +0 -27
- package/dist/provider/hooks/mutations/core.js +0 -66
- package/dist/provider/hooks/queries/core.d.ts +0 -4
- package/dist/provider/hooks/queries/core.js +0 -16
- package/dist/provider/hooks/queries/utils.d.ts +0 -7
- package/dist/provider/hooks/queries/utils.js +0 -25
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
export declare const useSignUpOrLogIn: () => import("../../types/utils.js").CoreMethodMutationHook<"signUpOrLogIn">;
|
|
2
|
-
export declare const useVerifyNewAccount: () => import("../../types/utils.js").CoreMethodMutationHook<"verifyNewAccount">;
|
|
3
|
-
export declare const useWaitForLogin: () => import("../../types/utils.js").CoreMethodMutationHook<"waitForLogin">;
|
|
4
|
-
export declare const useWaitForSignup: () => import("../../types/utils.js").CoreMethodMutationHook<"waitForSignup">;
|
|
5
|
-
export declare const useWaitForWalletCreation: () => import("../../types/utils.js").CoreMethodMutationHook<"waitForWalletCreation">;
|
|
6
|
-
export declare const useVerifyOAuth: () => import("../../types/utils.js").CoreMethodMutationHook<"verifyOAuth">;
|
|
7
|
-
export declare const useVerifyFarcaster: () => import("../../types/utils.js").CoreMethodMutationHook<"verifyFarcaster">;
|
|
8
|
-
export declare const useVerifyTelegram: () => import("../../types/utils.js").CoreMethodMutationHook<"verifyTelegram">;
|
|
9
|
-
export declare const useLoginExternalWallet: () => import("../../types/utils.js").CoreMethodMutationHook<"loginExternalWallet">;
|
|
10
|
-
export declare const useVerifyExternalWallet: () => import("../../types/utils.js").CoreMethodMutationHook<"verifyExternalWallet">;
|
|
11
|
-
export declare const useSetup2fa: () => import("../../types/utils.js").CoreMethodMutationHook<"setup2fa">;
|
|
12
|
-
export declare const useEnable2fa: () => import("../../types/utils.js").CoreMethodMutationHook<"enable2fa">;
|
|
13
|
-
export declare const useVerify2fa: () => import("../../types/utils.js").CoreMethodMutationHook<"verify2fa">;
|
|
14
|
-
export declare const useKeepSessionAlive: () => import("../../types/utils.js").CoreMethodMutationHook<"keepSessionAlive">;
|
|
15
|
-
export declare const useLogout: () => import("../../types/utils.js").CoreMethodMutationHook<"logout">;
|
|
16
|
-
export declare const useResendVerificationCode: () => import("../../types/utils.js").CoreMethodMutationHook<"resendVerificationCode">;
|
|
17
|
-
export declare const useCreateWallet: () => import("../../types/utils.js").CoreMethodMutationHook<"createWallet">;
|
|
18
|
-
export declare const useCreateWalletPerType: () => import("../../types/utils.js").CoreMethodMutationHook<"createWalletPerType">;
|
|
19
|
-
export declare const useCreatePregenWallet: () => import("../../types/utils.js").CoreMethodMutationHook<"createPregenWallet">;
|
|
20
|
-
export declare const useCreatePregenWalletPerType: () => import("../../types/utils.js").CoreMethodMutationHook<"createPregenWalletPerType">;
|
|
21
|
-
export declare const useClaimPregenWallets: () => import("../../types/utils.js").CoreMethodMutationHook<"claimPregenWallets">;
|
|
22
|
-
export declare const useHasPregenWallet: () => import("../../types/utils.js").CoreMethodMutationHook<"hasPregenWallet">;
|
|
23
|
-
export declare const useUpdatePregenWalletIdentifier: () => import("../../types/utils.js").CoreMethodMutationHook<"updatePregenWalletIdentifier">;
|
|
24
|
-
export declare const useCreateGuestWallets: () => import("../../types/utils.js").CoreMethodMutationHook<"createGuestWallets">;
|
|
25
|
-
export declare const useSignMessage: () => import("../../types/utils.js").CoreMethodMutationHook<"signMessage">;
|
|
26
|
-
export declare const useSignTransaction: () => import("../../types/utils.js").CoreMethodMutationHook<"signTransaction">;
|
|
27
|
-
export declare const useIssueJwt: () => import("../../types/utils.js").CoreMethodMutationHook<"issueJwt">;
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import "../../../chunk-MMUBH76A.js";
|
|
3
|
-
import * as actions from "../../actions/index.js";
|
|
4
|
-
import { generateCoreMutation } from "./utils.js";
|
|
5
|
-
const useSignUpOrLogIn = generateCoreMutation("signUpOrLogIn", actions.signUpOrLogIn);
|
|
6
|
-
const useVerifyNewAccount = generateCoreMutation("verifyNewAccount", actions.verifyNewAccount);
|
|
7
|
-
const useWaitForLogin = generateCoreMutation("waitForLogin", actions.waitForLogin);
|
|
8
|
-
const useWaitForSignup = generateCoreMutation("waitForSignup", actions.waitForSignup);
|
|
9
|
-
const useWaitForWalletCreation = generateCoreMutation("waitForWalletCreation", actions.waitForWalletCreation);
|
|
10
|
-
const useVerifyOAuth = generateCoreMutation("verifyOAuth", actions.verifyOAuth);
|
|
11
|
-
const useVerifyFarcaster = generateCoreMutation("verifyFarcaster", actions.verifyFarcaster);
|
|
12
|
-
const useVerifyTelegram = generateCoreMutation("verifyTelegram", actions.verifyTelegram);
|
|
13
|
-
const useLoginExternalWallet = generateCoreMutation("loginExternalWallet", actions.loginExternalWallet);
|
|
14
|
-
const useVerifyExternalWallet = generateCoreMutation("verifyExternalWallet", actions.verifyExternalWallet);
|
|
15
|
-
const useSetup2fa = generateCoreMutation("setup2fa", actions.setup2fa);
|
|
16
|
-
const useEnable2fa = generateCoreMutation("enable2fa", actions.enable2fa);
|
|
17
|
-
const useVerify2fa = generateCoreMutation("verify2fa", actions.verify2fa);
|
|
18
|
-
const useKeepSessionAlive = generateCoreMutation("keepSessionAlive", actions.keepSessionAlive);
|
|
19
|
-
const useLogout = generateCoreMutation("logout", actions.logout);
|
|
20
|
-
const useResendVerificationCode = generateCoreMutation("resendVerificationCode", actions.resendVerificationCode);
|
|
21
|
-
const useCreateWallet = generateCoreMutation("createWallet", actions.createWallet);
|
|
22
|
-
const useCreateWalletPerType = generateCoreMutation("createWalletPerType", actions.createWalletPerType);
|
|
23
|
-
const useCreatePregenWallet = generateCoreMutation("createPregenWallet", actions.createPregenWallet);
|
|
24
|
-
const useCreatePregenWalletPerType = generateCoreMutation(
|
|
25
|
-
"createPregenWalletPerType",
|
|
26
|
-
actions.createPregenWalletPerType
|
|
27
|
-
);
|
|
28
|
-
const useClaimPregenWallets = generateCoreMutation("claimPregenWallets", actions.claimPregenWallets);
|
|
29
|
-
const useHasPregenWallet = generateCoreMutation("hasPregenWallet", actions.hasPregenWallet);
|
|
30
|
-
const useUpdatePregenWalletIdentifier = generateCoreMutation(
|
|
31
|
-
"updatePregenWalletIdentifier",
|
|
32
|
-
actions.updatePregenWalletIdentifier
|
|
33
|
-
);
|
|
34
|
-
const useCreateGuestWallets = generateCoreMutation("createGuestWallets", actions.createGuestWallets);
|
|
35
|
-
const useSignMessage = generateCoreMutation("signMessage", actions.signMessage);
|
|
36
|
-
const useSignTransaction = generateCoreMutation("signTransaction", actions.signTransaction);
|
|
37
|
-
const useIssueJwt = generateCoreMutation("issueJwt", actions.issueJwt);
|
|
38
|
-
export {
|
|
39
|
-
useClaimPregenWallets,
|
|
40
|
-
useCreateGuestWallets,
|
|
41
|
-
useCreatePregenWallet,
|
|
42
|
-
useCreatePregenWalletPerType,
|
|
43
|
-
useCreateWallet,
|
|
44
|
-
useCreateWalletPerType,
|
|
45
|
-
useEnable2fa,
|
|
46
|
-
useHasPregenWallet,
|
|
47
|
-
useIssueJwt,
|
|
48
|
-
useKeepSessionAlive,
|
|
49
|
-
useLoginExternalWallet,
|
|
50
|
-
useLogout,
|
|
51
|
-
useResendVerificationCode,
|
|
52
|
-
useSetup2fa,
|
|
53
|
-
useSignMessage,
|
|
54
|
-
useSignTransaction,
|
|
55
|
-
useSignUpOrLogIn,
|
|
56
|
-
useUpdatePregenWalletIdentifier,
|
|
57
|
-
useVerify2fa,
|
|
58
|
-
useVerifyExternalWallet,
|
|
59
|
-
useVerifyFarcaster,
|
|
60
|
-
useVerifyNewAccount,
|
|
61
|
-
useVerifyOAuth,
|
|
62
|
-
useVerifyTelegram,
|
|
63
|
-
useWaitForLogin,
|
|
64
|
-
useWaitForSignup,
|
|
65
|
-
useWaitForWalletCreation
|
|
66
|
-
};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
export declare const useLinkedAccounts: (params?: {
|
|
2
|
-
withMetadata?: boolean;
|
|
3
|
-
} | undefined) => import("../../types/utils.js").CoreMethodQueryHook<"getLinkedAccounts">;
|
|
4
|
-
export declare const useAccountLinkInProgress: (params?: undefined) => import("../../types/utils.js").CoreMethodQueryHook<"accountLinkInProgress">;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import "../../../chunk-MMUBH76A.js";
|
|
3
|
-
import * as actions from "../../actions/index.js";
|
|
4
|
-
import { generateCoreQueryHook } from "./utils.js";
|
|
5
|
-
const useLinkedAccounts = generateCoreQueryHook("getLinkedAccounts", actions.getLinkedAccounts, {
|
|
6
|
-
defaultParams: { withMetadata: false }
|
|
7
|
-
});
|
|
8
|
-
const useAccountLinkInProgress = generateCoreQueryHook(
|
|
9
|
-
"accountLinkInProgress",
|
|
10
|
-
actions.accountLinkInProgress,
|
|
11
|
-
{ isGetter: true }
|
|
12
|
-
);
|
|
13
|
-
export {
|
|
14
|
-
useAccountLinkInProgress,
|
|
15
|
-
useLinkedAccounts
|
|
16
|
-
};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { CoreMethodName, CoreMethodParams, CoreMethods } from '@getpara/web-sdk';
|
|
2
|
-
import { CoreMethodQueryHook } from '../../types/utils.js';
|
|
3
|
-
import { CoreAction } from '../../actions/utils.js';
|
|
4
|
-
export declare function generateCoreQueryHook<const method extends CoreMethodName & keyof CoreMethods>(method: method, action: CoreAction<method>, { isGetter, defaultParams }?: {
|
|
5
|
-
isGetter?: boolean;
|
|
6
|
-
defaultParams?: CoreMethodParams<method>;
|
|
7
|
-
}): (params?: CoreMethodParams<method>) => CoreMethodQueryHook<method>;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import {
|
|
3
|
-
__async
|
|
4
|
-
} from "../../../chunk-MMUBH76A.js";
|
|
5
|
-
import { useClient } from "../utils/index.js";
|
|
6
|
-
import { useQuery } from "@tanstack/react-query";
|
|
7
|
-
function generateCoreQueryHook(method, action, { isGetter = false, defaultParams } = {}) {
|
|
8
|
-
return (params = defaultParams) => {
|
|
9
|
-
var _a;
|
|
10
|
-
const para = useClient();
|
|
11
|
-
return useQuery({
|
|
12
|
-
queryKey: [method, params != null ? params : null, isGetter ? (_a = para == null ? void 0 : para[method]) != null ? _a : null : null],
|
|
13
|
-
queryFn: (_0) => __async(this, [_0], function* ({ queryKey: [_, params2] }) {
|
|
14
|
-
if (!para) {
|
|
15
|
-
return null;
|
|
16
|
-
}
|
|
17
|
-
const result = params2 ? yield action(para, params2) : defaultParams ? yield action(para, defaultParams) : yield action(para);
|
|
18
|
-
return result != null ? result : null;
|
|
19
|
-
})
|
|
20
|
-
});
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
export {
|
|
24
|
-
generateCoreQueryHook
|
|
25
|
-
};
|