@dodoex/wallet-web3-react 0.0.1-beta.1 → 0.0.1-beta.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.
@@ -0,0 +1 @@
1
+ /*eslint-disable*/module.exports={messages:JSON.parse("{\"Sz0SkD\":[\"1、Ledger Live APP is closed\",[\"BR\"],\"2、The device plugged in via USB,NOT Bluetooth\",[\"BR\"],\"3、The device is unlocked and in the \",[\"ledgerAppName\"],\" app\",[\"BR\"],\"4、”Blind Signing” is enabled in \",[\"ledgerAppName\"],\" app\"],\"AeXO77\":\"Account\",\"XJOV1Y\":\"Activity\",\"OBdohg\":\"Add Liquidity\",\"Du6bPw\":\"Address\",\"Z7ZXbT\":\"Approve\",\"vN+hAq\":\"Available Ledger Account\",\"fsBGk0\":\"Balance\",\"E/yE9x\":\"Before proceeding make sure\",\"3UCJ3e\":\"Check your email and click the link to complete login\",\"Mlg3Ds\":\"Choose existing passkey\",\"zXCpR0\":\"Claim Rewards\",\"RETKSh\":\"Connect Alchemy\",\"CtByM7\":\"Connect Wallet\",\"QHcLEN\":\"Connected\",\"9zb2WA\":\"Connecting\",\"xGVfLh\":\"Continue\",\"6V3Ea3\":\"Copied\",\"gCNLBV\":\"Copy wallet address\",\"14s9LL\":\"Create Liquidity Mining\",\"OzjK0A\":\"Create new passkey\",\"WZRsOg\":\"End mining\\\\n\",\"6KnyG0\":\"Enter email\",\"7Bj3x9\":\"Failed\",\"sr0UJD\":\"Go Back\",\"S0kLOH\":\"ID\",\"9ow2PX\":\"Installed Wallet\",\"B2Tpo0\":\"Invalid email\",\"rwC96V\":\"Invalid wallet address\",\"xHr8Pp\":\"Last connection\",\"EYDfo2\":\"Loading more\",\"Z3FXyt\":\"Loading...\",\"6Ui8nZ\":\"Log in with your email\",\"3y6FjD\":\"Log in with your email or a passkey\",\"yN5k0R\":\"More Wallets\",\"JE8mMQ\":\"No tokens\",\"zga9sT\":\"OK\",\"U8oDGg\":\"On-chain transaction records\",\"BzEFor\":\"or\",\"UbRKMZ\":\"Pending\",\"8OiU8L\":\"Pool Creation\",\"lDgVWA\":\"Receive\",\"pkRuyd\":\"Receiver address\",\"3XBvkd\":\"Remove Liquidity\",\"OfhWJH\":\"Reset\",\"JlFcis\":\"Send\",\"JYKRJS\":\"Stake\",\"hQRttt\":\"Submit\",\"KAbcm2\":\"Succeeded\",\"vH2C/2\":\"Swap\",\"kdetxi\":\"The Ledger Device is locked\\nPlease unlock from the device\",\"FzJ11V\":\"This is empty\",\"TP9/K5\":\"Token\",\"zPGNJm\":\"Transfer\",\"LobdAW\":\"Unknown Error\"}")};
@@ -0,0 +1 @@
1
+ /*eslint-disable*/module.exports={messages:JSON.parse("{\"Sz0SkD\":[\"1、Ledger Live APP is closed\",[\"BR\"],\"2、The device plugged in via USB,NOT Bluetooth\",[\"BR\"],\"3、The device is unlocked and in the \",[\"ledgerAppName\"],\" app\",[\"BR\"],\"4、”Blind Signing” is enabled in \",[\"ledgerAppName\"],\" app\"],\"AeXO77\":\"Account\",\"XJOV1Y\":\"Activity\",\"OBdohg\":\"Add Liquidity\",\"Du6bPw\":\"Address\",\"Z7ZXbT\":\"Approve\",\"vN+hAq\":\"Available Ledger Account\",\"fsBGk0\":\"Balance\",\"E/yE9x\":\"Before proceeding make sure\",\"3UCJ3e\":\"Check your email and click the link to complete login\",\"Mlg3Ds\":\"Choose existing passkey\",\"zXCpR0\":\"Claim Rewards\",\"RETKSh\":\"Connect Alchemy\",\"CtByM7\":\"Connect Wallet\",\"QHcLEN\":\"Connected\",\"9zb2WA\":\"Connecting\",\"xGVfLh\":\"Continue\",\"6V3Ea3\":\"Copied\",\"gCNLBV\":\"Copy wallet address\",\"14s9LL\":\"Create Liquidity Mining\",\"OzjK0A\":\"Create new passkey\",\"WZRsOg\":\"End mining\\\\n\",\"6KnyG0\":\"Enter email\",\"7Bj3x9\":\"Failed\",\"sr0UJD\":\"Go Back\",\"S0kLOH\":\"ID\",\"9ow2PX\":\"Installed Wallet\",\"B2Tpo0\":\"Invalid email\",\"rwC96V\":\"Invalid wallet address\",\"xHr8Pp\":\"Last connection\",\"EYDfo2\":\"Loading more\",\"Z3FXyt\":\"Loading...\",\"6Ui8nZ\":\"Log in with your email\",\"3y6FjD\":\"Log in with your email or a passkey\",\"yN5k0R\":\"More Wallets\",\"JE8mMQ\":\"No tokens\",\"zga9sT\":\"OK\",\"U8oDGg\":\"On-chain transaction records\",\"BzEFor\":\"or\",\"UbRKMZ\":\"Pending\",\"8OiU8L\":\"Pool Creation\",\"lDgVWA\":\"Receive\",\"pkRuyd\":\"Receiver address\",\"3XBvkd\":\"Remove Liquidity\",\"OfhWJH\":\"Reset\",\"JlFcis\":\"Send\",\"JYKRJS\":\"Stake\",\"hQRttt\":\"Submit\",\"KAbcm2\":\"Succeeded\",\"vH2C/2\":\"Swap\",\"kdetxi\":\"The Ledger Device is locked\\nPlease unlock from the device\",\"FzJ11V\":\"This is empty\",\"TP9/K5\":\"Token\",\"zPGNJm\":\"Transfer\",\"LobdAW\":\"Unknown Error\"}")};
@@ -1,2 +1 @@
1
- /// <reference types="react" />
2
1
  export default function ClientProvider({ children }: React.PropsWithChildren): JSX.Element;
@@ -9,4 +9,4 @@ export declare function useConnectAlchemyQuery({ walletWeb3, showAlchemyConnect,
9
9
  }): void;
10
10
  export declare function useConnectAlchemy({ walletWeb3 }: {
11
11
  walletWeb3: WalletWeb3;
12
- }): import("@tanstack/react-query/build/legacy/types").UseMutationResult<void, Error, import("@alchemy/aa-alchemy").AuthParams | undefined, unknown>;
12
+ }): import("@tanstack/react-query").UseMutationResult<void, Error, import("@alchemy/aa-alchemy").AuthParams | undefined, unknown>;
@@ -3,19 +3,19 @@ import React from 'react';
3
3
  import { TokenInfo } from './components/TokenLogo';
4
4
  import { WalletItem } from './hooks/useConnectWalet';
5
5
  export declare const WalletConnectProvider: React.Provider<{
6
- chainId?: number | undefined;
6
+ chainId?: number;
7
7
  termsOfServiceLink?: React.ReactNode;
8
- connectTimeout?: number | undefined;
9
- graphQLRequests?: GraphQLRequests | undefined;
8
+ connectTimeout?: number;
9
+ graphQLRequests?: GraphQLRequests;
10
10
  tokenList: Array<TokenInfo>;
11
- restApiRequests?: RestApiRequests | undefined;
12
- SendTokenPage?: ((params: {
11
+ restApiRequests?: RestApiRequests;
12
+ SendTokenPage?: (params: {
13
13
  open?: boolean;
14
14
  onClose: () => void;
15
15
  onBack: () => void;
16
- }) => JSX.Element) | undefined;
17
- encryptFiatPriceToken?: (() => string) | undefined;
18
- loadAccountListEthBalance?: ((accountList: string[], chainId?: number) => Promise<Map<string, number | null>>) | undefined;
16
+ }) => JSX.Element;
17
+ encryptFiatPriceToken?: () => string;
18
+ loadAccountListEthBalance?: (accountList: string[], chainId?: number) => Promise<Map<string, number | null>>;
19
19
  getChain: (chainId: number) => null | {
20
20
  name: string;
21
21
  scanUrl: string;
@@ -26,31 +26,31 @@ export declare const WalletConnectProvider: React.Provider<{
26
26
  logo: React.ReactNode;
27
27
  logoBg?: React.ReactNode;
28
28
  };
29
- getTokenLogoUrl?: ((op: {
29
+ getTokenLogoUrl?: (op: {
30
30
  chainId?: number | null;
31
31
  address?: string | null;
32
32
  width?: number;
33
33
  height?: number;
34
- }) => string | null) | undefined;
35
- onConnectTimeout?: (() => void) | undefined;
36
- switchNetwork?: ((chainId: number) => void) | undefined;
37
- onConnected?: ((chainId: number, wallet: WalletItem) => void) | undefined;
38
- onClickToken?: ((token: TokenInfo) => void) | undefined;
34
+ }) => string | null;
35
+ onConnectTimeout?: () => void;
36
+ switchNetwork?: (chainId: number) => void;
37
+ onConnected?: (chainId: number, wallet: WalletItem) => void;
38
+ onClickToken?: (token: TokenInfo) => void;
39
39
  }>;
40
40
  export declare const useWalletConnectContext: () => {
41
- chainId?: number | undefined;
41
+ chainId?: number;
42
42
  termsOfServiceLink?: React.ReactNode;
43
- connectTimeout?: number | undefined;
44
- graphQLRequests?: GraphQLRequests | undefined;
43
+ connectTimeout?: number;
44
+ graphQLRequests?: GraphQLRequests;
45
45
  tokenList: Array<TokenInfo>;
46
- restApiRequests?: RestApiRequests | undefined;
47
- SendTokenPage?: ((params: {
46
+ restApiRequests?: RestApiRequests;
47
+ SendTokenPage?: (params: {
48
48
  open?: boolean;
49
49
  onClose: () => void;
50
50
  onBack: () => void;
51
- }) => JSX.Element) | undefined;
52
- encryptFiatPriceToken?: (() => string) | undefined;
53
- loadAccountListEthBalance?: ((accountList: string[], chainId?: number) => Promise<Map<string, number | null>>) | undefined;
51
+ }) => JSX.Element;
52
+ encryptFiatPriceToken?: () => string;
53
+ loadAccountListEthBalance?: (accountList: string[], chainId?: number) => Promise<Map<string, number | null>>;
54
54
  getChain: (chainId: number) => null | {
55
55
  name: string;
56
56
  scanUrl: string;
@@ -61,14 +61,14 @@ export declare const useWalletConnectContext: () => {
61
61
  logo: React.ReactNode;
62
62
  logoBg?: React.ReactNode;
63
63
  };
64
- getTokenLogoUrl?: ((op: {
64
+ getTokenLogoUrl?: (op: {
65
65
  chainId?: number | null;
66
66
  address?: string | null;
67
67
  width?: number;
68
68
  height?: number;
69
- }) => string | null) | undefined;
70
- onConnectTimeout?: (() => void) | undefined;
71
- switchNetwork?: ((chainId: number) => void) | undefined;
72
- onConnected?: ((chainId: number, wallet: WalletItem) => void) | undefined;
73
- onClickToken?: ((token: TokenInfo) => void) | undefined;
69
+ }) => string | null;
70
+ onConnectTimeout?: () => void;
71
+ switchNetwork?: (chainId: number) => void;
72
+ onConnected?: (chainId: number, wallet: WalletItem) => void;
73
+ onClickToken?: (token: TokenInfo) => void;
74
74
  };
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { BoxProps } from '@dodoex/components';
3
2
  export declare function truncatePoolAddress(address: string): string;
4
3
  interface AddressTextProps {
@@ -9,22 +9,22 @@ export interface WalletItem {
9
9
  isInstalled?: boolean;
10
10
  }
11
11
  export declare const useConnectWallet: ({ walletWeb3, matchTestChain, showOtherInjectWallet, selectedChainId, hasTermsOfServiceLink, }: {
12
- walletWeb3?: WalletWeb3 | undefined;
12
+ walletWeb3?: WalletWeb3;
13
13
  /** Match the test chain and display the first bit of showName and chainIds as the matching test chain. If it is false or not transmitted, the main network information will still be displayed. */
14
- matchTestChain?: boolean | undefined;
14
+ matchTestChain?: boolean;
15
15
  /**
16
16
  * No need to display when switching wallets
17
17
  */
18
- showOtherInjectWallet?: boolean | undefined;
19
- selectedChainId?: number | undefined;
20
- hasTermsOfServiceLink?: boolean | undefined;
18
+ showOtherInjectWallet?: boolean;
19
+ selectedChainId?: number;
20
+ hasTermsOfServiceLink?: boolean;
21
21
  }) => {
22
22
  walletList: WalletItem[];
23
23
  userReadAndChecked: boolean;
24
24
  handleChangeUserReadAndChecked: (val: boolean) => void;
25
25
  activeWalletType: import("@dodoex/wallet-web3").WalletType | undefined;
26
26
  };
27
- export declare const connectToWallet: (walletWeb3: WalletWeb3 | undefined, wallet: Wallet, config?: Partial<WalletWeb3['providerConfig']>) => Promise<import("@ethersproject/providers").JsonRpcProvider | undefined>;
27
+ export declare const connectToWallet: (walletWeb3: WalletWeb3 | undefined, wallet: Wallet, config?: Partial<WalletWeb3["providerConfig"]>) => Promise<import("@ethersproject/providers").JsonRpcProvider | undefined>;
28
28
  export declare function useWalletListByNetwork(chainId?: number, walletWeb3?: WalletWeb3, showOtherInjectWallet?: boolean, closeSingleWalletConnectModal?: () => void): {
29
29
  walletList: WalletItem[];
30
30
  };
@@ -1,3 +1,3 @@
1
1
  import { TokenInfo } from '../components/TokenLogo';
2
2
  export declare function getFiatPriceQueryKeys(tokens?: TokenInfo[]): (string | TokenInfo[] | undefined)[];
3
- export declare function useFetchFiatPrice(tokens: TokenInfo[]): import("@tanstack/react-query/build/legacy/types").UseQueryResult<Map<string, number>, Error>;
3
+ export declare function useFetchFiatPrice(tokens: TokenInfo[]): import("@tanstack/react-query").UseQueryResult<Map<string, number>, Error>;
@@ -10,12 +10,12 @@ export declare function useHasBalanceTokenList({ account, chainId, visible, }: {
10
10
  balance: BigNumber;
11
11
  chainId: number;
12
12
  address: string;
13
- symbol?: string | undefined;
14
- name?: string | undefined;
15
- decimals?: number | undefined;
16
- logoURI?: string | undefined;
13
+ symbol?: string;
14
+ name?: string;
15
+ decimals?: number;
16
+ logoURI?: string;
17
17
  }[];
18
- fiatPriceQuery: import("@tanstack/react-query/build/legacy/types").UseQueryResult<Map<string, number>, Error>;
18
+ fiatPriceQuery: import("@tanstack/react-query").UseQueryResult<Map<string, number>, Error>;
19
19
  allFiatPriceBalance: BigNumber;
20
20
  allFiatPriceBalanceLoading: boolean;
21
21
  };
@@ -11,24 +11,24 @@ export declare function useTransactionList({ account, chainId, }: {
11
11
  chainId?: number;
12
12
  }): {
13
13
  list: ({
14
- chainId?: number | null | undefined;
15
- createTime?: string | null | undefined;
16
- extend?: any;
17
- from?: string | null | undefined;
18
- id?: number | null | undefined;
19
- key?: string | null | undefined;
20
- type?: string | null | undefined;
14
+ chainId?: number | null;
15
+ createTime?: string | null;
16
+ extend?: any | null;
17
+ from?: string | null;
18
+ id?: number | null;
19
+ key?: string | null;
20
+ type?: string | null;
21
21
  } | null)[];
22
22
  pendingList: ({
23
- chainId?: number | null | undefined;
24
- createTime?: string | null | undefined;
25
- extend?: any;
26
- from?: string | null | undefined;
27
- id?: number | null | undefined;
28
- key?: string | null | undefined;
29
- type?: string | null | undefined;
23
+ chainId?: number | null;
24
+ createTime?: string | null;
25
+ extend?: any | null;
26
+ from?: string | null;
27
+ id?: number | null;
28
+ key?: string | null;
29
+ type?: string | null;
30
30
  } | null)[];
31
- data: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>;
31
+ data: import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>;
32
32
  error: Error;
33
33
  isError: true;
34
34
  isPending: false;
@@ -36,9 +36,10 @@ export declare function useTransactionList({ account, chainId, }: {
36
36
  isLoadingError: false;
37
37
  isRefetchError: true;
38
38
  isSuccess: false;
39
+ isPlaceholderData: false;
39
40
  status: "error";
40
- fetchNextPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ao | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
41
- fetchPreviousPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ap | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
41
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
42
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
42
43
  hasNextPage: boolean;
43
44
  hasPreviousPage: boolean;
44
45
  isFetchNextPageError: boolean;
@@ -55,32 +56,31 @@ export declare function useTransactionList({ account, chainId, }: {
55
56
  isFetching: boolean;
56
57
  isInitialLoading: boolean;
57
58
  isPaused: boolean;
58
- isPlaceholderData: boolean;
59
59
  isRefetching: boolean;
60
60
  isStale: boolean;
61
- refetch: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aj | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").az<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
62
- fetchStatus: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ar;
63
- promise: Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
61
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
62
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
63
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
64
64
  } | {
65
65
  list: ({
66
- chainId?: number | null | undefined;
67
- createTime?: string | null | undefined;
68
- extend?: any;
69
- from?: string | null | undefined;
70
- id?: number | null | undefined;
71
- key?: string | null | undefined;
72
- type?: string | null | undefined;
66
+ chainId?: number | null;
67
+ createTime?: string | null;
68
+ extend?: any | null;
69
+ from?: string | null;
70
+ id?: number | null;
71
+ key?: string | null;
72
+ type?: string | null;
73
73
  } | null)[];
74
74
  pendingList: ({
75
- chainId?: number | null | undefined;
76
- createTime?: string | null | undefined;
77
- extend?: any;
78
- from?: string | null | undefined;
79
- id?: number | null | undefined;
80
- key?: string | null | undefined;
81
- type?: string | null | undefined;
75
+ chainId?: number | null;
76
+ createTime?: string | null;
77
+ extend?: any | null;
78
+ from?: string | null;
79
+ id?: number | null;
80
+ key?: string | null;
81
+ type?: string | null;
82
82
  } | null)[];
83
- data: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>;
83
+ data: import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>;
84
84
  error: null;
85
85
  isError: false;
86
86
  isPending: false;
@@ -90,9 +90,10 @@ export declare function useTransactionList({ account, chainId, }: {
90
90
  isFetchNextPageError: false;
91
91
  isFetchPreviousPageError: false;
92
92
  isSuccess: true;
93
+ isPlaceholderData: false;
93
94
  status: "success";
94
- fetchNextPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ao | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
95
- fetchPreviousPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ap | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
95
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
96
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
96
97
  hasNextPage: boolean;
97
98
  hasPreviousPage: boolean;
98
99
  isFetchingNextPage: boolean;
@@ -107,30 +108,29 @@ export declare function useTransactionList({ account, chainId, }: {
107
108
  isFetching: boolean;
108
109
  isInitialLoading: boolean;
109
110
  isPaused: boolean;
110
- isPlaceholderData: boolean;
111
111
  isRefetching: boolean;
112
112
  isStale: boolean;
113
- refetch: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aj | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").az<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
114
- fetchStatus: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ar;
115
- promise: Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
113
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
114
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
115
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
116
116
  } | {
117
117
  list: ({
118
- chainId?: number | null | undefined;
119
- createTime?: string | null | undefined;
120
- extend?: any;
121
- from?: string | null | undefined;
122
- id?: number | null | undefined;
123
- key?: string | null | undefined;
124
- type?: string | null | undefined;
118
+ chainId?: number | null;
119
+ createTime?: string | null;
120
+ extend?: any | null;
121
+ from?: string | null;
122
+ id?: number | null;
123
+ key?: string | null;
124
+ type?: string | null;
125
125
  } | null)[];
126
126
  pendingList: ({
127
- chainId?: number | null | undefined;
128
- createTime?: string | null | undefined;
129
- extend?: any;
130
- from?: string | null | undefined;
131
- id?: number | null | undefined;
132
- key?: string | null | undefined;
133
- type?: string | null | undefined;
127
+ chainId?: number | null;
128
+ createTime?: string | null;
129
+ extend?: any | null;
130
+ from?: string | null;
131
+ id?: number | null;
132
+ key?: string | null;
133
+ type?: string | null;
134
134
  } | null)[];
135
135
  data: undefined;
136
136
  error: Error;
@@ -142,9 +142,10 @@ export declare function useTransactionList({ account, chainId, }: {
142
142
  isFetchNextPageError: false;
143
143
  isFetchPreviousPageError: false;
144
144
  isSuccess: false;
145
+ isPlaceholderData: false;
145
146
  status: "error";
146
- fetchNextPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ao | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
147
- fetchPreviousPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ap | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
147
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
148
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
148
149
  hasNextPage: boolean;
149
150
  hasPreviousPage: boolean;
150
151
  isFetchingNextPage: boolean;
@@ -159,30 +160,29 @@ export declare function useTransactionList({ account, chainId, }: {
159
160
  isFetching: boolean;
160
161
  isInitialLoading: boolean;
161
162
  isPaused: boolean;
162
- isPlaceholderData: boolean;
163
163
  isRefetching: boolean;
164
164
  isStale: boolean;
165
- refetch: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aj | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").az<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
166
- fetchStatus: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ar;
167
- promise: Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
165
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
166
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
167
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
168
168
  } | {
169
169
  list: ({
170
- chainId?: number | null | undefined;
171
- createTime?: string | null | undefined;
172
- extend?: any;
173
- from?: string | null | undefined;
174
- id?: number | null | undefined;
175
- key?: string | null | undefined;
176
- type?: string | null | undefined;
170
+ chainId?: number | null;
171
+ createTime?: string | null;
172
+ extend?: any | null;
173
+ from?: string | null;
174
+ id?: number | null;
175
+ key?: string | null;
176
+ type?: string | null;
177
177
  } | null)[];
178
178
  pendingList: ({
179
- chainId?: number | null | undefined;
180
- createTime?: string | null | undefined;
181
- extend?: any;
182
- from?: string | null | undefined;
183
- id?: number | null | undefined;
184
- key?: string | null | undefined;
185
- type?: string | null | undefined;
179
+ chainId?: number | null;
180
+ createTime?: string | null;
181
+ extend?: any | null;
182
+ from?: string | null;
183
+ id?: number | null;
184
+ key?: string | null;
185
+ type?: string | null;
186
186
  } | null)[];
187
187
  data: undefined;
188
188
  error: null;
@@ -194,9 +194,10 @@ export declare function useTransactionList({ account, chainId, }: {
194
194
  isFetchNextPageError: false;
195
195
  isFetchPreviousPageError: false;
196
196
  isSuccess: false;
197
+ isPlaceholderData: false;
197
198
  status: "pending";
198
- fetchNextPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ao | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
199
- fetchPreviousPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ap | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
199
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
200
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
200
201
  hasNextPage: boolean;
201
202
  hasPreviousPage: boolean;
202
203
  isFetchingNextPage: boolean;
@@ -211,30 +212,29 @@ export declare function useTransactionList({ account, chainId, }: {
211
212
  isFetching: boolean;
212
213
  isInitialLoading: boolean;
213
214
  isPaused: boolean;
214
- isPlaceholderData: boolean;
215
215
  isRefetching: boolean;
216
216
  isStale: boolean;
217
- refetch: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aj | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").az<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
218
- fetchStatus: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ar;
219
- promise: Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
217
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
218
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
219
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
220
220
  } | {
221
221
  list: ({
222
- chainId?: number | null | undefined;
223
- createTime?: string | null | undefined;
224
- extend?: any;
225
- from?: string | null | undefined;
226
- id?: number | null | undefined;
227
- key?: string | null | undefined;
228
- type?: string | null | undefined;
222
+ chainId?: number | null;
223
+ createTime?: string | null;
224
+ extend?: any | null;
225
+ from?: string | null;
226
+ id?: number | null;
227
+ key?: string | null;
228
+ type?: string | null;
229
229
  } | null)[];
230
230
  pendingList: ({
231
- chainId?: number | null | undefined;
232
- createTime?: string | null | undefined;
233
- extend?: any;
234
- from?: string | null | undefined;
235
- id?: number | null | undefined;
236
- key?: string | null | undefined;
237
- type?: string | null | undefined;
231
+ chainId?: number | null;
232
+ createTime?: string | null;
233
+ extend?: any | null;
234
+ from?: string | null;
235
+ id?: number | null;
236
+ key?: string | null;
237
+ type?: string | null;
238
238
  } | null)[];
239
239
  data: undefined;
240
240
  error: null;
@@ -245,9 +245,10 @@ export declare function useTransactionList({ account, chainId, }: {
245
245
  isFetchNextPageError: false;
246
246
  isFetchPreviousPageError: false;
247
247
  isSuccess: false;
248
+ isPlaceholderData: false;
248
249
  status: "pending";
249
- fetchNextPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ao | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
250
- fetchPreviousPage: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ap | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aH<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
250
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
251
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
251
252
  hasNextPage: boolean;
252
253
  hasPreviousPage: boolean;
253
254
  isFetchingNextPage: boolean;
@@ -263,10 +264,61 @@ export declare function useTransactionList({ account, chainId, }: {
263
264
  isLoading: boolean;
264
265
  isInitialLoading: boolean;
265
266
  isPaused: boolean;
266
- isPlaceholderData: boolean;
267
267
  isRefetching: boolean;
268
268
  isStale: boolean;
269
- refetch: (options?: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").aj | undefined) => Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").az<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
270
- fetchStatus: import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").ar;
271
- promise: Promise<import("@tanstack/query-core/build/legacy/hydration-DiTAi-4H").a0<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
269
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
270
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
271
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
272
+ } | {
273
+ list: ({
274
+ chainId?: number | null;
275
+ createTime?: string | null;
276
+ extend?: any | null;
277
+ from?: string | null;
278
+ id?: number | null;
279
+ key?: string | null;
280
+ type?: string | null;
281
+ } | null)[];
282
+ pendingList: ({
283
+ chainId?: number | null;
284
+ createTime?: string | null;
285
+ extend?: any | null;
286
+ from?: string | null;
287
+ id?: number | null;
288
+ key?: string | null;
289
+ type?: string | null;
290
+ } | null)[];
291
+ data: import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>;
292
+ isError: false;
293
+ error: null;
294
+ isPending: false;
295
+ isLoading: false;
296
+ isLoadingError: false;
297
+ isRefetchError: false;
298
+ isSuccess: true;
299
+ isPlaceholderData: true;
300
+ isFetchNextPageError: false;
301
+ isFetchPreviousPageError: false;
302
+ status: "success";
303
+ fetchNextPage: (options?: import("@tanstack/react-query").FetchNextPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
304
+ fetchPreviousPage: (options?: import("@tanstack/react-query").FetchPreviousPageOptions) => Promise<import("@tanstack/react-query").InfiniteQueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
305
+ hasNextPage: boolean;
306
+ hasPreviousPage: boolean;
307
+ isFetchingNextPage: boolean;
308
+ isFetchingPreviousPage: boolean;
309
+ dataUpdatedAt: number;
310
+ errorUpdatedAt: number;
311
+ failureCount: number;
312
+ failureReason: Error | null;
313
+ errorUpdateCount: number;
314
+ isFetched: boolean;
315
+ isFetchedAfterMount: boolean;
316
+ isFetching: boolean;
317
+ isInitialLoading: boolean;
318
+ isPaused: boolean;
319
+ isRefetching: boolean;
320
+ isStale: boolean;
321
+ refetch: (options?: import("@tanstack/react-query").RefetchOptions) => Promise<import("@tanstack/react-query").QueryObserverResult<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>, Error>>;
322
+ fetchStatus: import("@tanstack/react-query").FetchStatus;
323
+ promise: Promise<import("@tanstack/react-query").InfiniteData<import("@dodoex/api/dist/types/gql/graphql").FetchNoticeCenterTransactionListQuery, unknown>>;
272
324
  };
package/lingui.config.ts CHANGED
@@ -3,7 +3,7 @@ const config = {
3
3
  sourceLocale: 'en',
4
4
  catalogs: [
5
5
  {
6
- path: 'locales/{locale}',
6
+ path: 'src/locales/{locale}',
7
7
  include: ['src'],
8
8
  },
9
9
  ],
package/package.json CHANGED
@@ -1,15 +1,15 @@
1
1
  {
2
2
  "name": "@dodoex/wallet-web3-react",
3
- "version": "0.0.1-beta.1",
3
+ "version": "0.0.1-beta.3",
4
4
  "source": "src/index.tsx",
5
5
  "types": "dist/types/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
8
8
  "scripts": {
9
9
  "start": "yarn workspace doc start",
10
- "build": "rm -rf dist/* && yarn extract && yarn compile && rollup -c",
10
+ "build": "yarn extract && yarn compile && rollup -c",
11
11
  "extract": "lingui extract --clean",
12
- "compile": "lingui compile --typescript"
12
+ "compile": "lingui compile"
13
13
  },
14
14
  "author": "",
15
15
  "license": "GPL-3.0-or-later",
@@ -32,14 +32,15 @@
32
32
  ]
33
33
  },
34
34
  "peerDependencies": {
35
+ "@dodoex/wallet-web3": "0.0.61-beta.0",
35
36
  "react": ">=17.0.2",
36
- "react-dom": ">=17.0.2",
37
- "@dodoex/wallet-web3": "0.0.61-beta.0"
37
+ "react-dom": ">=17.0.2"
38
38
  },
39
39
  "devDependencies": {
40
40
  "@lingui/cli": "^4.11.4",
41
41
  "@lingui/loader": "^4.11.4",
42
42
  "@lingui/swc-plugin": "4.0.6",
43
+ "@rollup/plugin-replace": "^6.0.2",
43
44
  "@rollup/plugin-terser": "^0.4.4",
44
45
  "@rollup/plugin-typescript": "^12.1.1",
45
46
  "@rollup/plugin-url": "^8.0.2",
@@ -49,7 +50,7 @@
49
50
  "rollup": "^4.28.0",
50
51
  "rollup-plugin-clear": "^2.0.7",
51
52
  "rollup-plugin-import-css": "^3.5.7",
52
- "typescript": "^4.7.3"
53
+ "typescript": "^5.6.3"
53
54
  },
54
55
  "dependencies": {
55
56
  "@dodoex/api": "^3.0.2",
@@ -59,7 +60,7 @@
59
60
  "@dodoex/icons": "^2.0.2",
60
61
  "@lingui/macro": "^4.11.4",
61
62
  "@lingui/react": "^4.11.4",
62
- "@tanstack/react-query": "^5.62.8",
63
+ "@tanstack/react-query": "^5.18.1",
63
64
  "bignumber.js": "^9.1.2",
64
65
  "copy-to-clipboard": "^3.3.3",
65
66
  "dayjs": "^1.11.13",