@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.
@@ -4,7 +4,7 @@ import {
4
4
  useMatchEvents,
5
5
  useUserInfo,
6
6
  useWallet
7
- } from "../chunk-KITTHHSR.mjs";
7
+ } from "../chunk-KCESOJHY.mjs";
8
8
  import "../chunk-SQIJR7RA.mjs";
9
9
  import "../chunk-DPXMCLYK.mjs";
10
10
  import "../chunk-J5LGTIGS.mjs";
@@ -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 SOLModalProps = ModalWithHeaderProps & {
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 TRONConnectModalProps = ModalWithHeaderProps & {
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 TonModalProps = ModalWithHeaderProps & {
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 BTCConnectModalProps = ModalWithHeaderProps & {
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, index_WalletModal as WalletModal };
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, WalletModal as W, ModalWithHeader as a, LoginButton as b, LoginPanel as c, LoginModal as d, PasswordModal as e, TONModal as f, BTCModal as g, index as i };
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 SOLModalProps = ModalWithHeaderProps & {
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 TRONConnectModalProps = ModalWithHeaderProps & {
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 TonModalProps = ModalWithHeaderProps & {
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 BTCConnectModalProps = ModalWithHeaderProps & {
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, index_WalletModal as WalletModal };
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, WalletModal as W, ModalWithHeader as a, LoginButton as b, LoginPanel as c, LoginModal as d, PasswordModal as e, TONModal as f, BTCModal as g, index as i };
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, Chain } from 'viem';
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 | "wallet", extra?: {
50
- [key: string]: any;
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' | 'chain'> & {
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, Chain } from 'viem';
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 | "wallet", extra?: {
50
- [key: string]: any;
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' | 'chain'> & {
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-DlhAHm_s.mjs';
4
- export { i as Hooks } from './index-Bluim2ZP.mjs';
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: WalletConfigType;
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-CLvQH5gM.js';
4
- export { i as Hooks } from './index-EqksEEto.js';
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: WalletConfigType;
33
+ wallet?: WalletConfigType;
34
34
  }>;
35
35
  declare const useMatch: () => MatchContextType;
36
36