@matchain/matchid-sdk-react 0.1.48-alpha.23 → 0.1.48-alpha.25
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/assets/icon/index.d.mts +1 -1
- package/dist/assets/icon/index.d.ts +1 -1
- package/dist/{chunk-SB54XHCJ.mjs → chunk-MD3AVLZD.mjs} +2 -2
- package/dist/{chunk-FYW4P7HS.mjs → chunk-UR57LTMH.mjs} +26 -27
- package/dist/chunk-UR57LTMH.mjs.map +1 -0
- package/dist/components/index.d.mts +3 -3
- package/dist/components/index.d.ts +3 -3
- package/dist/components/index.js +14 -15
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +2 -2
- package/dist/hooks/api/index.d.mts +2 -2
- package/dist/hooks/api/index.d.ts +2 -2
- package/dist/hooks/api/index.js +5 -5
- package/dist/hooks/api/index.js.map +1 -1
- package/dist/hooks/api/index.mjs +3 -3
- package/dist/hooks/index.d.mts +2 -2
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/index.js +9 -7
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +2 -2
- package/dist/{index-Ca30Hgn7.d.mts → index-BMfaixEx.d.mts} +1 -1
- package/dist/{index-CN2jy6bb.d.ts → index-BMsj8hJv.d.ts} +2 -2
- package/dist/{index-BOsoQSmx.d.ts → index-BcEreCxd.d.ts} +1 -1
- package/dist/{index-BFSCCmlU.d.ts → index-Bpmrd7mh.d.ts} +1 -1
- package/dist/{index-DTYp8DRd.d.ts → index-Bvc8cjpN.d.ts} +2 -2
- package/dist/{index-Bk_dqXKp.d.mts → index-C9F6f2iz.d.mts} +2 -2
- package/dist/{index-B4gKj0ro.d.mts → index-C9qYyRgt.d.mts} +2 -2
- package/dist/{index-CdM22eod.d.mts → index-Cou96DpL.d.mts} +1 -1
- package/dist/{index-BHXlpUg5.d.ts → index-Cy3K-Yao.d.ts} +1 -1
- package/dist/{index-D3GBq1P1.d.mts → index-D4ju2J_e.d.mts} +1 -1
- package/dist/{index-BObJQar4.d.mts → index-DUHkH5t-.d.mts} +11 -1
- package/dist/{index-CSTyna62.d.ts → index-DcQm2dkr.d.ts} +11 -1
- package/dist/index.d.mts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +14 -15
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -9
- package/dist/types/index.d.mts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/{types-Dc15ure7.d.mts → types-DzVVzMYU.d.mts} +1 -1
- package/dist/{types-Dc15ure7.d.ts → types-DzVVzMYU.d.ts} +1 -1
- package/dist/ui/index.d.mts +3 -3
- package/dist/ui/index.d.ts +3 -3
- package/example/src/pages/Wallet/components/MatchWallet.tsx +24 -2
- package/package.json +1 -1
- package/dist/chunk-FYW4P7HS.mjs.map +0 -1
- /package/dist/{chunk-SB54XHCJ.mjs.map → chunk-MD3AVLZD.mjs.map} +0 -0
package/dist/hooks/index.mjs
CHANGED
|
@@ -12,12 +12,12 @@ import {
|
|
|
12
12
|
useTransaction,
|
|
13
13
|
useUserInfo,
|
|
14
14
|
useWallet
|
|
15
|
-
} from "../chunk-
|
|
15
|
+
} from "../chunk-UR57LTMH.mjs";
|
|
16
16
|
import "../chunk-UA6XHZHX.mjs";
|
|
17
|
-
import "../chunk-5JHHHLG4.mjs";
|
|
18
17
|
import {
|
|
19
18
|
useLayout_exports
|
|
20
19
|
} from "../chunk-FB5MHLWX.mjs";
|
|
20
|
+
import "../chunk-5JHHHLG4.mjs";
|
|
21
21
|
import "../chunk-LHNKZISB.mjs";
|
|
22
22
|
import "../chunk-J5LGTIGS.mjs";
|
|
23
23
|
export {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { A as AuthParams, C as ChainType, E as EmbeddedWalletsParams, R as RecoveryType } from './mpc-CTbBWHld.mjs';
|
|
2
|
-
import { A as Address,
|
|
2
|
+
import { A as Address, k as AnyObject, o as AppConfigType, p as BindInfoType, q as BindItemType, r as BindWalletParam, B as ButtonProps, C as CEXType, D as DeepPartial, s as DrawerProps, E as EmailModalProps, H as Hash, a as IEnvConfigType, t as IEnvName, v as ILoginWalletReq, I as IMatchEvents, h as ISocialLoginMethod, w as IconProps, x as InputProps, L as LocaleType, b as LoginBoxProps, j as LoginMethodType, f as LoginModalProps, e as LoginPanelProps, y as MessageType, z as MetaPageType, F as ModalProps, M as ModalWithHeaderProps, O as OtherLoginMethodType, i as OverviewInfo, G as PohItemType, J as PohZkpassParams, P as PopoverPositionType, K as PopoverProps, d as PopoverTypeType, R as RecommendLoginMethodType, T as ThemeType, N as UIProps, n as UserAssetToken, U as UserChainType, m as UserImportTokenType, Q as UserPopoverProps, S as UserTransactionNextPageParams, V as UserTransactionRecordType, l as UserTransactionType, g as WalletAssetMergeType, X as WalletAssetType, Y as WalletChainType, W as WalletConfigType, Z as WalletNFTType, _ as WalletPanelProps, $ as WalletReceiveMessageType, c as WalletType, u as useMatchWalletAssetsProps } from './types-DzVVzMYU.mjs';
|
|
3
3
|
|
|
4
4
|
declare const index_Address: typeof Address;
|
|
5
5
|
declare const index_AnyObject: typeof AnyObject;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-
|
|
1
|
+
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-BcEreCxd.js';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
-
import { s as DrawerProps, _ as WalletPanelProps, N as UIProps } from './types-
|
|
3
|
+
import { s as DrawerProps, _ as WalletPanelProps, N as UIProps } from './types-DzVVzMYU.js';
|
|
4
4
|
import { Hash, Chain } from 'viem';
|
|
5
5
|
import { CSSProperties } from 'react';
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode, PropsWithChildren } from 'react';
|
|
3
|
-
import { x as InputProps, B as ButtonProps, F as ModalProps, M as ModalWithHeaderProps, K as PopoverProps } from './types-
|
|
3
|
+
import { x as InputProps, B as ButtonProps, F as ModalProps, M as ModalWithHeaderProps, K as PopoverProps } from './types-DzVVzMYU.js';
|
|
4
4
|
|
|
5
5
|
declare function Field({ label, children, error, required, className }: {
|
|
6
6
|
label: ReactNode;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { A as AuthParams, C as ChainType, E as EmbeddedWalletsParams, R as RecoveryType } from './mpc-CTbBWHld.js';
|
|
2
|
-
import { A as Address,
|
|
2
|
+
import { A as Address, k as AnyObject, o as AppConfigType, p as BindInfoType, q as BindItemType, r as BindWalletParam, B as ButtonProps, C as CEXType, D as DeepPartial, s as DrawerProps, E as EmailModalProps, H as Hash, a as IEnvConfigType, t as IEnvName, v as ILoginWalletReq, I as IMatchEvents, h as ISocialLoginMethod, w as IconProps, x as InputProps, L as LocaleType, b as LoginBoxProps, j as LoginMethodType, f as LoginModalProps, e as LoginPanelProps, y as MessageType, z as MetaPageType, F as ModalProps, M as ModalWithHeaderProps, O as OtherLoginMethodType, i as OverviewInfo, G as PohItemType, J as PohZkpassParams, P as PopoverPositionType, K as PopoverProps, d as PopoverTypeType, R as RecommendLoginMethodType, T as ThemeType, N as UIProps, n as UserAssetToken, U as UserChainType, m as UserImportTokenType, Q as UserPopoverProps, S as UserTransactionNextPageParams, V as UserTransactionRecordType, l as UserTransactionType, g as WalletAssetMergeType, X as WalletAssetType, Y as WalletChainType, W as WalletConfigType, Z as WalletNFTType, _ as WalletPanelProps, $ as WalletReceiveMessageType, c as WalletType, u as useMatchWalletAssetsProps } from './types-DzVVzMYU.js';
|
|
3
3
|
|
|
4
4
|
declare const index_Address: typeof Address;
|
|
5
5
|
declare const index_AnyObject: typeof AnyObject;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { E as EmailModalProps,
|
|
3
|
-
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-
|
|
2
|
+
import { E as EmailModalProps, b as LoginBoxProps, B as ButtonProps, O as OtherLoginMethodType, R as RecommendLoginMethodType, c as WalletType, P as PopoverPositionType, d as PopoverTypeType, e as LoginPanelProps, f as LoginModalProps, M as ModalWithHeaderProps, g as WalletAssetMergeType, u as useMatchWalletAssetsProps } from './types-DzVVzMYU.js';
|
|
3
|
+
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-BcEreCxd.js';
|
|
4
4
|
import { ReactNode } from 'react';
|
|
5
5
|
|
|
6
6
|
declare function EmailModal({ isOpen, width, onClose, onBack, onLogin }: EmailModalProps): react_jsx_runtime.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-
|
|
1
|
+
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-Cou96DpL.mjs';
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
-
import { s as DrawerProps, _ as WalletPanelProps, N as UIProps } from './types-
|
|
3
|
+
import { s as DrawerProps, _ as WalletPanelProps, N as UIProps } from './types-DzVVzMYU.mjs';
|
|
4
4
|
import { Hash, Chain } from 'viem';
|
|
5
5
|
import { CSSProperties } from 'react';
|
|
6
6
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { E as EmailModalProps,
|
|
3
|
-
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-
|
|
2
|
+
import { E as EmailModalProps, b as LoginBoxProps, B as ButtonProps, O as OtherLoginMethodType, R as RecommendLoginMethodType, c as WalletType, P as PopoverPositionType, d as PopoverTypeType, e as LoginPanelProps, f as LoginModalProps, M as ModalWithHeaderProps, g as WalletAssetMergeType, u as useMatchWalletAssetsProps } from './types-DzVVzMYU.mjs';
|
|
3
|
+
import { B as Button, F as Field, I as Input, M as Modal, a as ModalWithHeader, O as Overlay, P as Popover } from './index-Cou96DpL.mjs';
|
|
4
4
|
import { ReactNode } from 'react';
|
|
5
5
|
|
|
6
6
|
declare function EmailModal({ isOpen, width, onClose, onBack, onLogin }: EmailModalProps): react_jsx_runtime.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode, PropsWithChildren } from 'react';
|
|
3
|
-
import { x as InputProps, B as ButtonProps, F as ModalProps, M as ModalWithHeaderProps, K as PopoverProps } from './types-
|
|
3
|
+
import { x as InputProps, B as ButtonProps, F as ModalProps, M as ModalWithHeaderProps, K as PopoverProps } from './types-DzVVzMYU.mjs';
|
|
4
4
|
|
|
5
5
|
declare function Field({ label, children, error, required, className }: {
|
|
6
6
|
label: ReactNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { UseQueryOptions } from '@tanstack/react-query/src/types';
|
|
3
|
-
import { J as PohZkpassParams,
|
|
3
|
+
import { J as PohZkpassParams, l as UserTransactionType, S as UserTransactionNextPageParams, X as WalletAssetType, z as MetaPageType, q as BindItemType, p as BindInfoType, G as PohItemType, U as UserChainType, n as UserAssetToken, m as UserImportTokenType, Y as WalletChainType, Z as WalletNFTType } from './types-DzVVzMYU.js';
|
|
4
4
|
|
|
5
5
|
declare const isSuccess: (res: {
|
|
6
6
|
code: number;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { UseQueryOptions } from '@tanstack/react-query/src/types';
|
|
3
|
-
import { J as PohZkpassParams,
|
|
3
|
+
import { J as PohZkpassParams, l as UserTransactionType, S as UserTransactionNextPageParams, X as WalletAssetType, z as MetaPageType, q as BindItemType, p as BindInfoType, G as PohItemType, U as UserChainType, n as UserAssetToken, m as UserImportTokenType, Y as WalletChainType, Z as WalletNFTType } from './types-DzVVzMYU.mjs';
|
|
4
4
|
|
|
5
5
|
declare const isSuccess: (res: {
|
|
6
6
|
code: number;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { h as ISocialLoginMethod, i as OverviewInfo, C as CEXType, j as LoginMethodType, I as IMatchEvents, U as UserChainType, A as Address, H as Hash$1, k as AnyObject, l as UserTransactionType, u as useMatchWalletAssetsProps, m as UserImportTokenType, n as UserAssetToken, g as WalletAssetMergeType } from './types-DzVVzMYU.mjs';
|
|
2
2
|
import * as viem from 'viem';
|
|
3
3
|
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters, Chain } from 'viem';
|
|
4
4
|
import { C as ChainType } from './mpc-CTbBWHld.mjs';
|
|
@@ -3257,6 +3257,16 @@ declare function useMatchWalletAssetList({ list }: {
|
|
|
3257
3257
|
list: WalletAssetMergeType[];
|
|
3258
3258
|
isLoading: boolean;
|
|
3259
3259
|
isFetched: boolean;
|
|
3260
|
+
nativeBalanceQuery: _tanstack_react_query.UseQueryResult<bigint | null, Error>;
|
|
3261
|
+
erc20BalanceQuery: _tanstack_react_query.UseQueryResult<({
|
|
3262
|
+
error?: undefined;
|
|
3263
|
+
result: unknown;
|
|
3264
|
+
status: "success";
|
|
3265
|
+
} | {
|
|
3266
|
+
error: Error;
|
|
3267
|
+
result?: undefined;
|
|
3268
|
+
status: "failure";
|
|
3269
|
+
})[], Error>;
|
|
3260
3270
|
nativeBalance: bigint | null | undefined;
|
|
3261
3271
|
erc20Balances: ({
|
|
3262
3272
|
error?: undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { h as ISocialLoginMethod, i as OverviewInfo, C as CEXType, j as LoginMethodType, I as IMatchEvents, U as UserChainType, A as Address, H as Hash$1, k as AnyObject, l as UserTransactionType, u as useMatchWalletAssetsProps, m as UserImportTokenType, n as UserAssetToken, g as WalletAssetMergeType } from './types-DzVVzMYU.js';
|
|
2
2
|
import * as viem from 'viem';
|
|
3
3
|
import { Account, WalletClientConfig, createWalletClient, SignableMessage, Hex, TransactionSerializable, DeployContractParameters, SendTransactionParameters, WriteContractParameters, Chain } from 'viem';
|
|
4
4
|
import { C as ChainType } from './mpc-CTbBWHld.js';
|
|
@@ -3257,6 +3257,16 @@ declare function useMatchWalletAssetList({ list }: {
|
|
|
3257
3257
|
list: WalletAssetMergeType[];
|
|
3258
3258
|
isLoading: boolean;
|
|
3259
3259
|
isFetched: boolean;
|
|
3260
|
+
nativeBalanceQuery: _tanstack_react_query.UseQueryResult<bigint | null, Error>;
|
|
3261
|
+
erc20BalanceQuery: _tanstack_react_query.UseQueryResult<({
|
|
3262
|
+
error?: undefined;
|
|
3263
|
+
result: unknown;
|
|
3264
|
+
status: "success";
|
|
3265
|
+
} | {
|
|
3266
|
+
error: Error;
|
|
3267
|
+
result?: undefined;
|
|
3268
|
+
status: "failure";
|
|
3269
|
+
})[], Error>;
|
|
3260
3270
|
nativeBalance: bigint | null | undefined;
|
|
3261
3271
|
erc20Balances: ({
|
|
3262
3272
|
error?: undefined;
|
package/dist/index.d.mts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
|
-
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-
|
|
3
|
-
export { i as Components } from './index-
|
|
4
|
-
export { i as UI } from './index-
|
|
5
|
-
export { i as Hooks } from './index-
|
|
6
|
-
export { i as Api } from './index-
|
|
2
|
+
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-DzVVzMYU.mjs';
|
|
3
|
+
export { i as Components } from './index-C9qYyRgt.mjs';
|
|
4
|
+
export { i as UI } from './index-C9F6f2iz.mjs';
|
|
5
|
+
export { i as Hooks } from './index-DUHkH5t-.mjs';
|
|
6
|
+
export { i as Api } from './index-D4ju2J_e.mjs';
|
|
7
7
|
export { i as Chains } from './index-DXRGMAbv.mjs';
|
|
8
|
-
export { i as Types } from './index-
|
|
8
|
+
export { i as Types } from './index-BMfaixEx.mjs';
|
|
9
9
|
import '@tanstack/react-query/src/types';
|
|
10
10
|
import 'react/jsx-runtime';
|
|
11
|
-
import './index-
|
|
11
|
+
import './index-Cou96DpL.mjs';
|
|
12
12
|
import 'viem';
|
|
13
13
|
import './mpc-CTbBWHld.mjs';
|
|
14
14
|
import 'viem/types/misc';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
|
-
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-
|
|
3
|
-
export { i as Components } from './index-
|
|
4
|
-
export { i as UI } from './index-
|
|
5
|
-
export { i as Hooks } from './index-
|
|
6
|
-
export { i as Api } from './index-
|
|
2
|
+
import { I as IMatchEvents, a as IEnvConfigType, L as LocaleType, W as WalletConfigType } from './types-DzVVzMYU.js';
|
|
3
|
+
export { i as Components } from './index-Bvc8cjpN.js';
|
|
4
|
+
export { i as UI } from './index-BMsj8hJv.js';
|
|
5
|
+
export { i as Hooks } from './index-DcQm2dkr.js';
|
|
6
|
+
export { i as Api } from './index-Cy3K-Yao.js';
|
|
7
7
|
export { i as Chains } from './index-DXRGMAbv.js';
|
|
8
|
-
export { i as Types } from './index-
|
|
8
|
+
export { i as Types } from './index-Bpmrd7mh.js';
|
|
9
9
|
import '@tanstack/react-query/src/types';
|
|
10
10
|
import 'react/jsx-runtime';
|
|
11
|
-
import './index-
|
|
11
|
+
import './index-BcEreCxd.js';
|
|
12
12
|
import 'viem';
|
|
13
13
|
import './mpc-CTbBWHld.js';
|
|
14
14
|
import 'viem/types/misc';
|
package/dist/index.js
CHANGED
|
@@ -5655,11 +5655,11 @@ var persistedState3 = (0, import_middleware3.persist)(
|
|
|
5655
5655
|
(set, get) => ({
|
|
5656
5656
|
contracts: {},
|
|
5657
5657
|
getContract: (chainId, contractAddress) => {
|
|
5658
|
-
const key = `${chainId}-${contractAddress}`;
|
|
5658
|
+
const key = `${chainId}-${contractAddress.toLowerCase()}`;
|
|
5659
5659
|
return get().contracts[key];
|
|
5660
5660
|
},
|
|
5661
5661
|
setContractName: (chainId, contractAddress, name) => {
|
|
5662
|
-
const key = `${chainId}-${contractAddress}`;
|
|
5662
|
+
const key = `${chainId}-${contractAddress.toLowerCase()}`;
|
|
5663
5663
|
set((state) => {
|
|
5664
5664
|
const updatedContracts = {
|
|
5665
5665
|
...state.contracts,
|
|
@@ -5669,7 +5669,7 @@ var persistedState3 = (0, import_middleware3.persist)(
|
|
|
5669
5669
|
});
|
|
5670
5670
|
},
|
|
5671
5671
|
setContractSymbol: (chainId, contractAddress, symbol) => {
|
|
5672
|
-
const key = `${chainId}-${contractAddress}`;
|
|
5672
|
+
const key = `${chainId}-${contractAddress.toLowerCase()}`;
|
|
5673
5673
|
set((state) => {
|
|
5674
5674
|
const updatedContracts = {
|
|
5675
5675
|
...state.contracts,
|
|
@@ -5679,7 +5679,7 @@ var persistedState3 = (0, import_middleware3.persist)(
|
|
|
5679
5679
|
});
|
|
5680
5680
|
},
|
|
5681
5681
|
setContractDecimals: (chainId, contractAddress, decimals) => {
|
|
5682
|
-
const key = `${chainId}-${contractAddress}`;
|
|
5682
|
+
const key = `${chainId}-${contractAddress.toLowerCase()}`;
|
|
5683
5683
|
set((state) => {
|
|
5684
5684
|
const updatedContracts = {
|
|
5685
5685
|
...state.contracts,
|
|
@@ -5692,7 +5692,7 @@ var persistedState3 = (0, import_middleware3.persist)(
|
|
|
5692
5692
|
set((state) => {
|
|
5693
5693
|
const newContracts = { ...state.contracts };
|
|
5694
5694
|
data.forEach(({ chainId, contractAddress, info }) => {
|
|
5695
|
-
const key = `${chainId}-${contractAddress}`;
|
|
5695
|
+
const key = `${chainId}-${contractAddress.toLowerCase()}`;
|
|
5696
5696
|
newContracts[key] = { ...newContracts[key], ...info };
|
|
5697
5697
|
});
|
|
5698
5698
|
return { contracts: newContracts };
|
|
@@ -5709,7 +5709,7 @@ var import_react_intl17 = require("react-intl");
|
|
|
5709
5709
|
var import_jsx_runtime88 = require("react/jsx-runtime");
|
|
5710
5710
|
var Item = ({ data }) => {
|
|
5711
5711
|
const { address } = useWallet();
|
|
5712
|
-
const isOut = data.from == address;
|
|
5712
|
+
const isOut = data.from.toLowerCase() == address.toLowerCase();
|
|
5713
5713
|
const { chain, chainId, explorerLink, formatUnits: chainFormatUnits } = useMatchChain();
|
|
5714
5714
|
const { getContract } = useContractStore_default();
|
|
5715
5715
|
const [shouldRefetch, setShouldRefetch] = (0, import_react32.useState)(true);
|
|
@@ -5744,11 +5744,6 @@ var Item = ({ data }) => {
|
|
|
5744
5744
|
}
|
|
5745
5745
|
return chainFormatUnits(BigInt(data.value));
|
|
5746
5746
|
}, [data.input, transferType, data.value, getContract, chainId, data.to]);
|
|
5747
|
-
(0, import_react32.useEffect)(() => {
|
|
5748
|
-
if (data.hash) {
|
|
5749
|
-
setShouldRefetch(true);
|
|
5750
|
-
}
|
|
5751
|
-
}, [data.hash]);
|
|
5752
5747
|
const hashQuery = useHash({
|
|
5753
5748
|
hash: data.hash,
|
|
5754
5749
|
//@ts-ignore
|
|
@@ -5784,8 +5779,10 @@ var Item = ({ data }) => {
|
|
|
5784
5779
|
return "loading";
|
|
5785
5780
|
}, [data.extra?.status, data.source, hashQuery.data]);
|
|
5786
5781
|
(0, import_react32.useEffect)(() => {
|
|
5787
|
-
|
|
5788
|
-
|
|
5782
|
+
if (data.hash) {
|
|
5783
|
+
setShouldRefetch(status == "loading");
|
|
5784
|
+
}
|
|
5785
|
+
}, [status, data.hash]);
|
|
5789
5786
|
const symbol = (0, import_react32.useMemo)(() => {
|
|
5790
5787
|
if (transferType == "erc20_transfer") {
|
|
5791
5788
|
return getContract(chainId || 0, data.to)?.symbol || getContract(chainId || 0, data.to)?.name || "unknown";
|
|
@@ -6268,7 +6265,7 @@ function useMatchWalletAssets({
|
|
|
6268
6265
|
list.unshift({
|
|
6269
6266
|
chain_id: chain?.id.toString() || "",
|
|
6270
6267
|
address: NATIVE_TOKEN_ADDRESS,
|
|
6271
|
-
decimals: 18,
|
|
6268
|
+
decimals: chain?.nativeCurrency.decimals || 18,
|
|
6272
6269
|
symbol: chain?.nativeCurrency.symbol,
|
|
6273
6270
|
name: chain?.nativeCurrency.name,
|
|
6274
6271
|
balance: 0,
|
|
@@ -6340,7 +6337,7 @@ function useMatchWalletAssetList({
|
|
|
6340
6337
|
}
|
|
6341
6338
|
return balances;
|
|
6342
6339
|
},
|
|
6343
|
-
enabled:
|
|
6340
|
+
enabled: !!publicClient,
|
|
6344
6341
|
refetchInterval: 15e3,
|
|
6345
6342
|
// Refresh every 15 seconds
|
|
6346
6343
|
retry: 3
|
|
@@ -6383,6 +6380,8 @@ function useMatchWalletAssetList({
|
|
|
6383
6380
|
list: assets,
|
|
6384
6381
|
isLoading: nativeBalanceQuery.isLoading || erc20BalanceQuery.isLoading,
|
|
6385
6382
|
isFetched: nativeBalanceQuery.isFetched && erc20BalanceQuery.isFetched,
|
|
6383
|
+
nativeBalanceQuery,
|
|
6384
|
+
erc20BalanceQuery,
|
|
6386
6385
|
nativeBalance: nativeBalanceQuery.data,
|
|
6387
6386
|
erc20Balances: erc20BalanceQuery.data
|
|
6388
6387
|
};
|