@matchain/matchid-sdk-react 0.1.42-alpha.17 → 0.1.42-alpha.3
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-L3G6YN2D.mjs → chunk-AIYRR4YQ.mjs} +2 -2
- package/dist/{chunk-KITTHHSR.mjs → chunk-KCESOJHY.mjs} +280 -392
- package/dist/chunk-KCESOJHY.mjs.map +1 -0
- package/dist/components/index.d.mts +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/index.js +233 -322
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +3 -5
- package/dist/hooks/api/index.js +30 -52
- package/dist/hooks/api/index.js.map +1 -1
- package/dist/hooks/api/index.mjs +2 -2
- package/dist/hooks/index.d.mts +1 -1
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.js +53 -87
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +1 -1
- package/dist/{index-CLvQH5gM.d.ts → index--yBVwkf9.d.ts} +10 -21
- package/dist/{index-DlhAHm_s.d.mts → index-CGpyQlbI.d.mts} +10 -21
- package/dist/{index-EqksEEto.d.ts → index-DKMrpRJC.d.ts} +4 -10
- package/dist/{index-Bluim2ZP.d.mts → index-sOVSnYF4.d.mts} +4 -10
- package/dist/index.d.mts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +317 -426
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/example/src/config/index.ts +0 -1
- package/example/src/pages/Wallet.tsx +9 -135
- package/example/src/store/useLocalStore.ts +1 -7
- package/example/tsconfig.json +0 -1
- package/package.json +1 -1
- package/dist/chunk-KITTHHSR.mjs.map +0 -1
- package/example/src/abi/erc20.json +0 -222
- /package/dist/{chunk-L3G6YN2D.mjs.map → chunk-AIYRR4YQ.mjs.map} +0 -0
package/dist/hooks/index.mjs
CHANGED
|
@@ -48,41 +48,31 @@ declare function PasswordModal({ title, isOpen, onSuccess, chainType, recoveryTy
|
|
|
48
48
|
recoveryType?: `${RecoveryType}`;
|
|
49
49
|
}): react_jsx_runtime.JSX.Element;
|
|
50
50
|
|
|
51
|
-
type
|
|
51
|
+
declare function SOLModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
52
52
|
type?: 'login' | 'bind' | '';
|
|
53
53
|
onSuccess?: () => void;
|
|
54
|
-
};
|
|
55
|
-
declare function SOLModal(props: SOLModalProps): false | react_jsx_runtime.JSX.Element;
|
|
54
|
+
}): react_jsx_runtime.JSX.Element;
|
|
56
55
|
|
|
57
|
-
type
|
|
56
|
+
declare function TRONModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
58
57
|
type?: 'login' | 'bind' | '';
|
|
59
58
|
onSuccess?: () => void;
|
|
60
|
-
};
|
|
61
|
-
declare function TRONModal(props: TRONConnectModalProps): false | react_jsx_runtime.JSX.Element;
|
|
59
|
+
}): react_jsx_runtime.JSX.Element;
|
|
62
60
|
|
|
63
|
-
type
|
|
61
|
+
declare function TONModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
64
62
|
type?: 'login' | 'bind' | '';
|
|
65
63
|
onSuccess?: () => void;
|
|
66
|
-
};
|
|
67
|
-
declare function TONModal(props: TonModalProps): false | react_jsx_runtime.JSX.Element;
|
|
64
|
+
}): react_jsx_runtime.JSX.Element;
|
|
68
65
|
|
|
69
|
-
type
|
|
66
|
+
declare function BTCModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
70
67
|
type?: 'login' | 'bind' | '';
|
|
71
68
|
onSuccess?: () => void;
|
|
72
|
-
};
|
|
73
|
-
declare function BTCModal(props: BTCConnectModalProps): false | react_jsx_runtime.JSX.Element;
|
|
69
|
+
}): react_jsx_runtime.JSX.Element;
|
|
74
70
|
|
|
75
71
|
declare function Overlay({ isOpen, children, zIndex, }: {
|
|
76
72
|
isOpen?: boolean;
|
|
77
73
|
zIndex?: number;
|
|
78
74
|
} & PropsWithChildren): react_jsx_runtime.JSX.Element;
|
|
79
75
|
|
|
80
|
-
type WalletModalProps = ModalWithHeaderProps & {
|
|
81
|
-
type?: 'login' | 'bind' | '';
|
|
82
|
-
methods?: WalletType[];
|
|
83
|
-
};
|
|
84
|
-
declare function WalletModal(props: WalletModalProps): false | react_jsx_runtime.JSX.Element;
|
|
85
|
-
|
|
86
76
|
declare const index_BTCModal: typeof BTCModal;
|
|
87
77
|
declare const index_Button: typeof Button;
|
|
88
78
|
declare const index_EmailModal: typeof EmailModal;
|
|
@@ -101,9 +91,8 @@ declare const index_SOLModal: typeof SOLModal;
|
|
|
101
91
|
declare const index_TONModal: typeof TONModal;
|
|
102
92
|
declare const index_TRONModal: typeof TRONModal;
|
|
103
93
|
declare const index_UsernameModal: typeof UsernameModal;
|
|
104
|
-
declare const index_WalletModal: typeof WalletModal;
|
|
105
94
|
declare namespace index {
|
|
106
|
-
export { index_BTCModal as BTCModal, index_Button as Button, index_EmailModal as EmailModal, index_Field as Field, index_Input as Input, index_LoginBox as LoginBox, index_LoginButton as LoginButton, index_LoginModal as LoginModal, index_LoginPanel as LoginPanel, index_Modal as Modal, index_ModalWithHeader as ModalWithHeader, index_Overlay as Overlay, index_PasswordModal as PasswordModal, index_Popover as Popover, index_SOLModal as SOLModal, index_TONModal as TONModal, index_TRONModal as TRONModal, index_UsernameModal as UsernameModal
|
|
95
|
+
export { index_BTCModal as BTCModal, index_Button as Button, index_EmailModal as EmailModal, index_Field as Field, index_Input as Input, index_LoginBox as LoginBox, index_LoginButton as LoginButton, index_LoginModal as LoginModal, index_LoginPanel as LoginPanel, index_Modal as Modal, index_ModalWithHeader as ModalWithHeader, index_Overlay as Overlay, index_PasswordModal as PasswordModal, index_Popover as Popover, index_SOLModal as SOLModal, index_TONModal as TONModal, index_TRONModal as TRONModal, index_UsernameModal as UsernameModal };
|
|
107
96
|
}
|
|
108
97
|
|
|
109
|
-
export { Button as B, EmailModal as E, Field as F, Input as I, LoginBox as L, Modal as M, Overlay as O, Popover as P, SOLModal as S, TRONModal as T, UsernameModal as U,
|
|
98
|
+
export { Button as B, EmailModal as E, Field as F, Input as I, LoginBox as L, Modal as M, Overlay as O, Popover as P, SOLModal as S, TRONModal as T, UsernameModal as U, ModalWithHeader as a, LoginButton as b, LoginPanel as c, LoginModal as d, PasswordModal as e, TONModal as f, BTCModal as g, index as i };
|
|
@@ -48,41 +48,31 @@ declare function PasswordModal({ title, isOpen, onSuccess, chainType, recoveryTy
|
|
|
48
48
|
recoveryType?: `${RecoveryType}`;
|
|
49
49
|
}): react_jsx_runtime.JSX.Element;
|
|
50
50
|
|
|
51
|
-
type
|
|
51
|
+
declare function SOLModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
52
52
|
type?: 'login' | 'bind' | '';
|
|
53
53
|
onSuccess?: () => void;
|
|
54
|
-
};
|
|
55
|
-
declare function SOLModal(props: SOLModalProps): false | react_jsx_runtime.JSX.Element;
|
|
54
|
+
}): react_jsx_runtime.JSX.Element;
|
|
56
55
|
|
|
57
|
-
type
|
|
56
|
+
declare function TRONModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
58
57
|
type?: 'login' | 'bind' | '';
|
|
59
58
|
onSuccess?: () => void;
|
|
60
|
-
};
|
|
61
|
-
declare function TRONModal(props: TRONConnectModalProps): false | react_jsx_runtime.JSX.Element;
|
|
59
|
+
}): react_jsx_runtime.JSX.Element;
|
|
62
60
|
|
|
63
|
-
type
|
|
61
|
+
declare function TONModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
64
62
|
type?: 'login' | 'bind' | '';
|
|
65
63
|
onSuccess?: () => void;
|
|
66
|
-
};
|
|
67
|
-
declare function TONModal(props: TonModalProps): false | react_jsx_runtime.JSX.Element;
|
|
64
|
+
}): react_jsx_runtime.JSX.Element;
|
|
68
65
|
|
|
69
|
-
type
|
|
66
|
+
declare function BTCModal({ type, onSuccess, ...props }: ModalWithHeaderProps & {
|
|
70
67
|
type?: 'login' | 'bind' | '';
|
|
71
68
|
onSuccess?: () => void;
|
|
72
|
-
};
|
|
73
|
-
declare function BTCModal(props: BTCConnectModalProps): false | react_jsx_runtime.JSX.Element;
|
|
69
|
+
}): react_jsx_runtime.JSX.Element;
|
|
74
70
|
|
|
75
71
|
declare function Overlay({ isOpen, children, zIndex, }: {
|
|
76
72
|
isOpen?: boolean;
|
|
77
73
|
zIndex?: number;
|
|
78
74
|
} & PropsWithChildren): react_jsx_runtime.JSX.Element;
|
|
79
75
|
|
|
80
|
-
type WalletModalProps = ModalWithHeaderProps & {
|
|
81
|
-
type?: 'login' | 'bind' | '';
|
|
82
|
-
methods?: WalletType[];
|
|
83
|
-
};
|
|
84
|
-
declare function WalletModal(props: WalletModalProps): false | react_jsx_runtime.JSX.Element;
|
|
85
|
-
|
|
86
76
|
declare const index_BTCModal: typeof BTCModal;
|
|
87
77
|
declare const index_Button: typeof Button;
|
|
88
78
|
declare const index_EmailModal: typeof EmailModal;
|
|
@@ -101,9 +91,8 @@ declare const index_SOLModal: typeof SOLModal;
|
|
|
101
91
|
declare const index_TONModal: typeof TONModal;
|
|
102
92
|
declare const index_TRONModal: typeof TRONModal;
|
|
103
93
|
declare const index_UsernameModal: typeof UsernameModal;
|
|
104
|
-
declare const index_WalletModal: typeof WalletModal;
|
|
105
94
|
declare namespace index {
|
|
106
|
-
export { index_BTCModal as BTCModal, index_Button as Button, index_EmailModal as EmailModal, index_Field as Field, index_Input as Input, index_LoginBox as LoginBox, index_LoginButton as LoginButton, index_LoginModal as LoginModal, index_LoginPanel as LoginPanel, index_Modal as Modal, index_ModalWithHeader as ModalWithHeader, index_Overlay as Overlay, index_PasswordModal as PasswordModal, index_Popover as Popover, index_SOLModal as SOLModal, index_TONModal as TONModal, index_TRONModal as TRONModal, index_UsernameModal as UsernameModal
|
|
95
|
+
export { index_BTCModal as BTCModal, index_Button as Button, index_EmailModal as EmailModal, index_Field as Field, index_Input as Input, index_LoginBox as LoginBox, index_LoginButton as LoginButton, index_LoginModal as LoginModal, index_LoginPanel as LoginPanel, index_Modal as Modal, index_ModalWithHeader as ModalWithHeader, index_Overlay as Overlay, index_PasswordModal as PasswordModal, index_Popover as Popover, index_SOLModal as SOLModal, index_TONModal as TONModal, index_TRONModal as TRONModal, index_UsernameModal as UsernameModal };
|
|
107
96
|
}
|
|
108
97
|
|
|
109
|
-
export { Button as B, EmailModal as E, Field as F, Input as I, LoginBox as L, Modal as M, Overlay as O, Popover as P, SOLModal as S, TRONModal as T, UsernameModal as U,
|
|
98
|
+
export { Button as B, EmailModal as E, Field as F, Input as I, LoginBox as L, Modal as M, Overlay as O, Popover as P, SOLModal as S, TRONModal as T, UsernameModal as U, ModalWithHeader as a, LoginButton as b, LoginPanel as c, LoginModal as d, PasswordModal as e, TONModal as f, BTCModal as g, index as i };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as ISocialLoginMethod, k as OverviewInfo, C as CEXType, l as LoginMethodType, I as IMatchEvents } from './types-CVwZEgQ0.js';
|
|
2
2
|
import * as viem from 'viem';
|
|
3
|
-
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters
|
|
3
|
+
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters } from 'viem';
|
|
4
4
|
import { C as ChainType, R as RecoveryType } from './mpc-CTbBWHld.js';
|
|
5
5
|
import { Hash } from 'viem/types/misc';
|
|
6
6
|
import { Abi } from 'abitype';
|
|
@@ -46,12 +46,8 @@ declare function useUserInfo(): {
|
|
|
46
46
|
bindCex: (type: CEXType) => void;
|
|
47
47
|
username: string;
|
|
48
48
|
auth: () => Promise<any>;
|
|
49
|
-
login: (method: LoginMethodType |
|
|
50
|
-
|
|
51
|
-
}) => Promise<void | Window | null>;
|
|
52
|
-
bind: (method: LoginMethodType | "wallet", extra?: {
|
|
53
|
-
[key: string]: any;
|
|
54
|
-
}) => Promise<void | Window | null>;
|
|
49
|
+
login: (method: LoginMethodType) => Promise<void | Window | null>;
|
|
50
|
+
bind: (method: LoginMethodType) => Promise<void | Window | null>;
|
|
55
51
|
getAuthInfo: (method: keyof typeof LOGIN_METHOD_MAP) => Promise<unknown>;
|
|
56
52
|
};
|
|
57
53
|
|
|
@@ -98,9 +94,7 @@ type SendTransactionParametersType = Omit<SendTransactionParameters, 'account'>;
|
|
|
98
94
|
type SendTransactionType = (transaction: SendTransactionParametersType) => Promise<SendTransactionReturnType>;
|
|
99
95
|
type DeployContractReturnType = SendTransactionReturnType;
|
|
100
96
|
type DeployContractType = <const abi extends Abi | readonly unknown[]>(parameters: DeployContractParameters<abi>) => Promise<DeployContractReturnType>;
|
|
101
|
-
type WriteContractParametersType = Omit<WriteContractParameters, 'account'
|
|
102
|
-
chain?: Chain;
|
|
103
|
-
};
|
|
97
|
+
type WriteContractParametersType = Omit<WriteContractParameters, 'account'>;
|
|
104
98
|
type WriteContractReturnType = SendTransactionReturnType;
|
|
105
99
|
type WriteContractType = (params: WriteContractParametersType) => Promise<WriteContractReturnType>;
|
|
106
100
|
interface UseWalletReturnType {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as ISocialLoginMethod, k as OverviewInfo, C as CEXType, l as LoginMethodType, I as IMatchEvents } from './types-CVwZEgQ0.mjs';
|
|
2
2
|
import * as viem from 'viem';
|
|
3
|
-
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters
|
|
3
|
+
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters } from 'viem';
|
|
4
4
|
import { C as ChainType, R as RecoveryType } from './mpc-CTbBWHld.mjs';
|
|
5
5
|
import { Hash } from 'viem/types/misc';
|
|
6
6
|
import { Abi } from 'abitype';
|
|
@@ -46,12 +46,8 @@ declare function useUserInfo(): {
|
|
|
46
46
|
bindCex: (type: CEXType) => void;
|
|
47
47
|
username: string;
|
|
48
48
|
auth: () => Promise<any>;
|
|
49
|
-
login: (method: LoginMethodType |
|
|
50
|
-
|
|
51
|
-
}) => Promise<void | Window | null>;
|
|
52
|
-
bind: (method: LoginMethodType | "wallet", extra?: {
|
|
53
|
-
[key: string]: any;
|
|
54
|
-
}) => Promise<void | Window | null>;
|
|
49
|
+
login: (method: LoginMethodType) => Promise<void | Window | null>;
|
|
50
|
+
bind: (method: LoginMethodType) => Promise<void | Window | null>;
|
|
55
51
|
getAuthInfo: (method: keyof typeof LOGIN_METHOD_MAP) => Promise<unknown>;
|
|
56
52
|
};
|
|
57
53
|
|
|
@@ -98,9 +94,7 @@ type SendTransactionParametersType = Omit<SendTransactionParameters, 'account'>;
|
|
|
98
94
|
type SendTransactionType = (transaction: SendTransactionParametersType) => Promise<SendTransactionReturnType>;
|
|
99
95
|
type DeployContractReturnType = SendTransactionReturnType;
|
|
100
96
|
type DeployContractType = <const abi extends Abi | readonly unknown[]>(parameters: DeployContractParameters<abi>) => Promise<DeployContractReturnType>;
|
|
101
|
-
type WriteContractParametersType = Omit<WriteContractParameters, 'account'
|
|
102
|
-
chain?: Chain;
|
|
103
|
-
};
|
|
97
|
+
type WriteContractParametersType = Omit<WriteContractParameters, 'account'>;
|
|
104
98
|
type WriteContractReturnType = SendTransactionReturnType;
|
|
105
99
|
type WriteContractType = (params: WriteContractParametersType) => Promise<WriteContractReturnType>;
|
|
106
100
|
interface UseWalletReturnType {
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-CVwZEgQ0.mjs';
|
|
3
|
-
export { i as Components } from './index-
|
|
4
|
-
export { i as Hooks } from './index-
|
|
3
|
+
export { i as Components } from './index-CGpyQlbI.mjs';
|
|
4
|
+
export { i as Hooks } from './index-sOVSnYF4.mjs';
|
|
5
5
|
export { i as Api } from './index-DFZpfAfc.mjs';
|
|
6
6
|
export { i as Chains } from './index-DXRGMAbv.mjs';
|
|
7
7
|
export { i as Types } from './index-q5XDobUF.mjs';
|
|
@@ -30,7 +30,7 @@ declare const MatchProvider: React.FC<{
|
|
|
30
30
|
theme?: "light" | "dark";
|
|
31
31
|
endpoints?: IEnvConfigType['endpoints'];
|
|
32
32
|
locale?: LocaleType;
|
|
33
|
-
wallet
|
|
33
|
+
wallet?: WalletConfigType;
|
|
34
34
|
}>;
|
|
35
35
|
declare const useMatch: () => MatchContextType;
|
|
36
36
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-CVwZEgQ0.js';
|
|
3
|
-
export { i as Components } from './index
|
|
4
|
-
export { i as Hooks } from './index-
|
|
3
|
+
export { i as Components } from './index--yBVwkf9.js';
|
|
4
|
+
export { i as Hooks } from './index-DKMrpRJC.js';
|
|
5
5
|
export { i as Api } from './index-Ca9nh_8s.js';
|
|
6
6
|
export { i as Chains } from './index-DXRGMAbv.js';
|
|
7
7
|
export { i as Types } from './index-BxS06a5O.js';
|
|
@@ -30,7 +30,7 @@ declare const MatchProvider: React.FC<{
|
|
|
30
30
|
theme?: "light" | "dark";
|
|
31
31
|
endpoints?: IEnvConfigType['endpoints'];
|
|
32
32
|
locale?: LocaleType;
|
|
33
|
-
wallet
|
|
33
|
+
wallet?: WalletConfigType;
|
|
34
34
|
}>;
|
|
35
35
|
declare const useMatch: () => MatchContextType;
|
|
36
36
|
|