@unisat/wallet-state 1.0.5 → 1.2.0
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/LICENSE +0 -5
- package/lib/actions/global.d.ts +2 -0
- package/lib/actions/global.d.ts.map +1 -0
- package/lib/context/ApprovalContext.d.ts +9 -0
- package/lib/context/ApprovalContext.d.ts.map +1 -0
- package/lib/context/DeviceContext.d.ts +17 -0
- package/lib/context/DeviceContext.d.ts.map +1 -0
- package/lib/context/I18nContext.d.ts +13 -0
- package/lib/context/I18nContext.d.ts.map +1 -0
- package/lib/context/NavigationContext.d.ts +218 -0
- package/lib/context/NavigationContext.d.ts.map +1 -0
- package/lib/context/PriceContext.d.ts +13 -0
- package/lib/context/PriceContext.d.ts.map +1 -0
- package/lib/context/StorageContext.d.ts +60 -0
- package/lib/context/StorageContext.d.ts.map +1 -0
- package/lib/context/ToolsContext.d.ts +17 -0
- package/lib/context/ToolsContext.d.ts.map +1 -0
- package/lib/context/WalletContext.d.ts +493 -0
- package/lib/context/WalletContext.d.ts.map +1 -0
- package/lib/context/index.d.ts +9 -0
- package/lib/context/index.d.ts.map +1 -0
- package/lib/hooks/accounts.d.ts +34 -0
- package/lib/hooks/accounts.d.ts.map +1 -0
- package/lib/hooks/base.d.ts +14 -0
- package/lib/hooks/base.d.ts.map +1 -0
- package/lib/hooks/browser.d.ts +32 -0
- package/lib/hooks/browser.d.ts.map +1 -0
- package/lib/hooks/discovery.d.ts +17 -0
- package/lib/hooks/discovery.d.ts.map +1 -0
- package/lib/hooks/global.d.ts +43 -0
- package/lib/hooks/global.d.ts.map +1 -0
- package/lib/hooks/index.d.ts +10 -0
- package/lib/hooks/index.d.ts.map +1 -0
- package/lib/hooks/keyrings.d.ts +5 -0
- package/lib/hooks/keyrings.d.ts.map +1 -0
- package/lib/hooks/settings.d.ts +43 -0
- package/lib/hooks/settings.d.ts.map +1 -0
- package/lib/hooks/transactions.d.ts +67 -0
- package/lib/hooks/transactions.d.ts.map +1 -0
- package/lib/hooks/ui.d.ts +112 -0
- package/lib/hooks/ui.d.ts.map +1 -0
- package/lib/index.d.mts +2072 -199
- package/lib/index.d.ts +31 -946
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +7176 -582
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +6971 -525
- package/lib/index.mjs.map +1 -1
- package/lib/reducers/accounts.d.ts +49 -0
- package/lib/reducers/accounts.d.ts.map +1 -0
- package/lib/reducers/browser.d.ts +49 -0
- package/lib/reducers/browser.d.ts.map +1 -0
- package/lib/reducers/discovery.d.ts +22 -0
- package/lib/reducers/discovery.d.ts.map +1 -0
- package/lib/reducers/global.d.ts +35 -0
- package/lib/reducers/global.d.ts.map +1 -0
- package/lib/reducers/index.d.ts +9 -0
- package/lib/reducers/index.d.ts.map +1 -0
- package/lib/reducers/keyrings.d.ts +10 -0
- package/lib/reducers/keyrings.d.ts.map +1 -0
- package/lib/reducers/settings.d.ts +16 -0
- package/lib/reducers/settings.d.ts.map +1 -0
- package/lib/reducers/transactions.d.ts +61 -0
- package/lib/reducers/transactions.d.ts.map +1 -0
- package/lib/reducers/ui.d.ts +55 -0
- package/lib/reducers/ui.d.ts.map +1 -0
- package/lib/types/index.d.mts +7 -3
- package/lib/types/index.d.ts +3 -30
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/index.js +7 -1
- package/lib/types/index.js.map +1 -1
- package/lib/types/index.mjs +7 -2
- package/lib/types/index.mjs.map +1 -1
- package/lib/types/ui.d.ts +31 -0
- package/lib/types/ui.d.ts.map +1 -0
- package/lib/ui-hooks/index.d.ts +55 -0
- package/lib/ui-hooks/index.d.ts.map +1 -0
- package/lib/ui-hooks/useActionOverviewSectionLogic.d.ts +12 -0
- package/lib/ui-hooks/useActionOverviewSectionLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAddressTypeScreenLogic.d.ts +19 -0
- package/lib/ui-hooks/useAddressTypeScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesBalanceCardLogic.d.ts +19 -0
- package/lib/ui-hooks/useAlkanesBalanceCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesCollectionListLogic.d.ts +11 -0
- package/lib/ui-hooks/useAlkanesCollectionListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesListLogic.d.ts +14 -0
- package/lib/ui-hooks/useAlkanesListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesNFTListLogic.d.ts +11 -0
- package/lib/ui-hooks/useAlkanesNFTListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesNFTScreenLogic.d.ts +9 -0
- package/lib/ui-hooks/useAlkanesNFTScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAlkanesTokenScreenLogic.d.ts +22 -0
- package/lib/ui-hooks/useAlkanesTokenScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAmountInputLogic.d.ts +22 -0
- package/lib/ui-hooks/useAmountInputLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useAnnouncementCardLogic.d.ts +11 -0
- package/lib/ui-hooks/useAnnouncementCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20BalanceCardLogic.d.ts +26 -0
- package/lib/ui-hooks/useBRC20BalanceCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20InscribeTransferLogic.d.ts +103 -0
- package/lib/ui-hooks/useBRC20InscribeTransferLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20ListLogic.d.ts +14 -0
- package/lib/ui-hooks/useBRC20ListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20ProgListLogic.d.ts +14 -0
- package/lib/ui-hooks/useBRC20ProgListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20SendScreenLogic.d.ts +67 -0
- package/lib/ui-hooks/useBRC20SendScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20SingleStepScreenLogic.d.ts +36 -0
- package/lib/ui-hooks/useBRC20SingleStepScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBRC20TokenScreenLogic.d.ts +75 -0
- package/lib/ui-hooks/useBRC20TokenScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBalanceCardLogic.d.ts +26 -0
- package/lib/ui-hooks/useBalanceCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useBtcDisplayLogic.d.ts +5 -0
- package/lib/ui-hooks/useBtcDisplayLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCAT20BalanceCardLogic.d.ts +20 -0
- package/lib/ui-hooks/useCAT20BalanceCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCAT20ListLogic.d.ts +14 -0
- package/lib/ui-hooks/useCAT20ListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCAT20TokenScreenLogic.d.ts +19 -0
- package/lib/ui-hooks/useCAT20TokenScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCAT721ListLogic.d.ts +11 -0
- package/lib/ui-hooks/useCAT721ListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCAT721NFTScreenLogic.d.ts +9 -0
- package/lib/ui-hooks/useCAT721NFTScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCreatePasswordScreenLogic.d.ts +27 -0
- package/lib/ui-hooks/useCreatePasswordScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useCreateWalletLogicImportWordsStep.d.ts +78 -0
- package/lib/ui-hooks/useCreateWalletLogicImportWordsStep.d.ts.map +1 -0
- package/lib/ui-hooks/useEditAccountNameScreenLogic.d.ts +18 -0
- package/lib/ui-hooks/useEditAccountNameScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useEditContactScreenLogic.d.ts +24 -0
- package/lib/ui-hooks/useEditContactScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useEditWalletNameScreenLogic.d.ts +15 -0
- package/lib/ui-hooks/useEditWalletNameScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useExportMnemonicsScreenLogic.d.ts +18 -0
- package/lib/ui-hooks/useExportMnemonicsScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useExportPrivateKeyScreenLogic.d.ts +17 -0
- package/lib/ui-hooks/useExportPrivateKeyScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useFeeRateBarLogic.d.ts +34 -0
- package/lib/ui-hooks/useFeeRateBarLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useInfiniteList.d.ts +19 -0
- package/lib/ui-hooks/useInfiniteList.d.ts.map +1 -0
- package/lib/ui-hooks/useInscriptionListLogic.d.ts +11 -0
- package/lib/ui-hooks/useInscriptionListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useLockTimePageLogic.d.ts +11 -0
- package/lib/ui-hooks/useLockTimePageLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useNotificationsLogic.d.ts +14 -0
- package/lib/ui-hooks/useNotificationsLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useOrdinalsInscriptionScreenLogic.d.ts +27 -0
- package/lib/ui-hooks/useOrdinalsInscriptionScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useRunesBalanceCardLogic.d.ts +19 -0
- package/lib/ui-hooks/useRunesBalanceCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useRunesListLogic.d.ts +14 -0
- package/lib/ui-hooks/useRunesListLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useRunesTokenScreenLogic.d.ts +22 -0
- package/lib/ui-hooks/useRunesTokenScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSecurityCardLogic.d.ts +1 -0
- package/lib/ui-hooks/useSecurityCardLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendAlkanesNFTScreenLogic.d.ts +32 -0
- package/lib/ui-hooks/useSendAlkanesNFTScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendAlkanesScreenLogic.d.ts +37 -0
- package/lib/ui-hooks/useSendAlkanesScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendCAT20ScreenLogic.d.ts +44 -0
- package/lib/ui-hooks/useSendCAT20ScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendCAT721ScreenLogic.d.ts +40 -0
- package/lib/ui-hooks/useSendCAT721ScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendOrdinalsInscriptionScreenLogic.d.ts +22 -0
- package/lib/ui-hooks/useSendOrdinalsInscriptionScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSendRunesScreenLogic.d.ts +30 -0
- package/lib/ui-hooks/useSendRunesScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSettingsTabScreenLogic.d.ts +72 -0
- package/lib/ui-hooks/useSettingsTabScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSignMessageLogic.d.ts +54 -0
- package/lib/ui-hooks/useSignMessageLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSignPsbtLogic.d.ts +82 -0
- package/lib/ui-hooks/useSignPsbtLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useSplitOrdinalsInscriptionScreenLogic.d.ts +15 -0
- package/lib/ui-hooks/useSplitOrdinalsInscriptionScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useTxConfirmScreenLogic.d.ts +8 -0
- package/lib/ui-hooks/useTxConfirmScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useTxCreateScreenLogic.d.ts +28 -0
- package/lib/ui-hooks/useTxCreateScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useTxFailScreenLogic.d.ts +7 -0
- package/lib/ui-hooks/useTxFailScreenLogic.d.ts.map +1 -0
- package/lib/ui-hooks/useTxSuccessScreenLogic.d.ts +8 -0
- package/lib/ui-hooks/useTxSuccessScreenLogic.d.ts.map +1 -0
- package/lib/updater/accounts.d.ts +2 -0
- package/lib/updater/accounts.d.ts.map +1 -0
- package/lib/updater/index.d.ts +2 -0
- package/lib/updater/index.d.ts.map +1 -0
- package/lib/utils/bitcoin-utils.d.ts +7 -0
- package/lib/utils/bitcoin-utils.d.ts.map +1 -0
- package/lib/utils/eventBus.d.ts +12 -0
- package/lib/utils/eventBus.d.ts.map +1 -0
- package/lib/utils/password-utils.d.ts +12 -0
- package/lib/utils/password-utils.d.ts.map +1 -0
- package/lib/utils/ui-utils.d.ts +4 -0
- package/lib/utils/ui-utils.d.ts.map +1 -0
- package/package.json +19 -15
- package/src/.DS_Store +0 -0
- package/src/context/ApprovalContext.tsx +27 -0
- package/src/context/DeviceContext.tsx +36 -0
- package/src/context/I18nContext.tsx +14 -172
- package/src/context/NavigationContext.tsx +305 -0
- package/src/context/PriceContext.tsx +2 -2
- package/src/context/StorageContext.tsx +393 -0
- package/src/context/ToolsContext.tsx +50 -0
- package/src/context/WalletContext.tsx +170 -126
- package/src/context/index.ts +17 -2
- package/src/hooks/accounts.ts +11 -5
- package/src/hooks/browser.ts +11 -0
- package/src/hooks/global.ts +170 -7
- package/src/hooks/index.ts +1 -2
- package/src/hooks/settings.ts +38 -37
- package/src/hooks/transactions.ts +45 -151
- package/src/hooks/ui.ts +239 -35
- package/src/index.ts +33 -24
- package/src/reducers/accounts.ts +22 -2
- package/src/reducers/browser.ts +223 -0
- package/src/reducers/global.ts +67 -1
- package/src/reducers/index.ts +1 -0
- package/src/reducers/transactions.ts +0 -9
- package/src/reducers/ui.ts +144 -4
- package/src/types/index.ts +1 -1
- package/src/types/ui.ts +6 -1
- package/src/ui-hooks/index.ts +107 -0
- package/src/ui-hooks/useActionOverviewSectionLogic.ts +150 -0
- package/src/ui-hooks/useAddressTypeScreenLogic.ts +160 -0
- package/src/ui-hooks/useAlkanesBalanceCardLogic.ts +41 -0
- package/src/ui-hooks/useAlkanesCollectionListLogic.ts +68 -0
- package/src/ui-hooks/useAlkanesListLogic.ts +69 -0
- package/src/ui-hooks/useAlkanesNFTListLogic.ts +42 -0
- package/src/ui-hooks/useAlkanesNFTScreenLogic.ts +45 -0
- package/src/ui-hooks/useAlkanesTokenScreenLogic.ts +138 -0
- package/src/ui-hooks/useAmountInputLogic.ts +80 -0
- package/src/ui-hooks/useAnnouncementCardLogic.ts +91 -0
- package/src/ui-hooks/useBRC20BalanceCardLogic.ts +115 -0
- package/src/ui-hooks/useBRC20InscribeTransferLogic.ts +418 -0
- package/src/ui-hooks/useBRC20ListLogic.ts +79 -0
- package/src/ui-hooks/useBRC20ProgListLogic.ts +81 -0
- package/src/ui-hooks/useBRC20SendScreenLogic.ts +424 -0
- package/src/ui-hooks/useBRC20SingleStepScreenLogic.ts +208 -0
- package/src/ui-hooks/useBRC20TokenScreenLogic.ts +489 -0
- package/src/ui-hooks/useBalanceCardLogic.ts +164 -0
- package/src/ui-hooks/useBtcDisplayLogic.ts +16 -0
- package/src/ui-hooks/useCAT20BalanceCardLogic.ts +35 -0
- package/src/ui-hooks/useCAT20ListLogic.ts +83 -0
- package/src/ui-hooks/useCAT20TokenScreenLogic.ts +127 -0
- package/src/ui-hooks/useCAT721ListLogic.ts +68 -0
- package/src/ui-hooks/useCAT721NFTScreenLogic.ts +37 -0
- package/src/ui-hooks/useCreatePasswordScreenLogic.ts +92 -0
- package/src/ui-hooks/useCreateWalletLogicImportWordsStep.ts +299 -0
- package/src/ui-hooks/useEditAccountNameScreenLogic.ts +71 -0
- package/src/ui-hooks/useEditContactScreenLogic.ts +162 -0
- package/src/ui-hooks/useEditWalletNameScreenLogic.ts +60 -0
- package/src/ui-hooks/useExportMnemonicsScreenLogic.ts +75 -0
- package/src/ui-hooks/useExportPrivateKeyScreenLogic.ts +64 -0
- package/src/ui-hooks/useFeeRateBarLogic.ts +303 -0
- package/src/ui-hooks/useInfiniteList.ts +85 -0
- package/src/ui-hooks/useInscriptionListLogic.ts +68 -0
- package/src/ui-hooks/useLockTimePageLogic.ts +43 -0
- package/src/ui-hooks/useNotificationsLogic.ts +115 -0
- package/src/ui-hooks/useOrdinalsInscriptionScreenLogic.ts +130 -0
- package/src/ui-hooks/useRunesBalanceCardLogic.ts +44 -0
- package/src/ui-hooks/useRunesListLogic.ts +74 -0
- package/src/ui-hooks/useRunesTokenScreenLogic.ts +156 -0
- package/src/ui-hooks/useSecurityCardLogic.ts +0 -0
- package/src/ui-hooks/useSendAlkanesNFTScreenLogic.ts +160 -0
- package/src/ui-hooks/useSendAlkanesScreenLogic.ts +208 -0
- package/src/ui-hooks/useSendCAT20ScreenLogic.ts +297 -0
- package/src/ui-hooks/useSendCAT721ScreenLogic.ts +205 -0
- package/src/ui-hooks/useSendOrdinalsInscriptionScreenLogic.ts +152 -0
- package/src/ui-hooks/useSendRunesScreenLogic.ts +189 -0
- package/src/ui-hooks/useSettingsTabScreenLogic.ts +211 -0
- package/src/ui-hooks/useSignMessageLogic.ts +302 -0
- package/src/ui-hooks/useSignPsbtLogic.ts +517 -0
- package/src/ui-hooks/useSplitOrdinalsInscriptionScreenLogic.ts +109 -0
- package/src/ui-hooks/useTxConfirmScreenLogic.ts +47 -0
- package/src/ui-hooks/useTxCreateScreenLogic.ts +177 -0
- package/src/ui-hooks/useTxFailScreenLogic.ts +26 -0
- package/src/ui-hooks/useTxSuccessScreenLogic.ts +33 -0
- package/src/updater/accounts.ts +11 -11
- package/src/utils/bitcoin-utils.ts +17 -8
- package/src/utils/eventBus.ts +2 -1
- package/src/utils/password-utils.ts +78 -0
- package/src/utils/ui-utils.ts +28 -0
- package/src/hooks/approval.ts +0 -72
- package/src/hooks/i18n.ts +0 -53
- package/src/utils/i18n.ts +0 -41
package/lib/index.d.mts
CHANGED
|
@@ -1,15 +1,65 @@
|
|
|
1
1
|
import * as _reduxjs_toolkit_dist_configureStore from '@reduxjs/toolkit/dist/configureStore';
|
|
2
2
|
import * as _reduxjs_toolkit from '@reduxjs/toolkit';
|
|
3
|
+
import * as redux from 'redux';
|
|
4
|
+
import * as _unisat_wallet_shared from '@unisat/wallet-shared';
|
|
5
|
+
import { AppInfo, Inscription, WalletKeyring, WalletConfig, UnspentOutput, Account, BitcoinBalanceV2, TxHistoryItem, AppSummary, InscriptionSummary, AddressSummary, TokenBalance, TokenInfo, RuneBalance, RuneInfo, AlkanesBalance, AlkanesInfo, CAT_VERSION, CAT20Balance, CAT20TokenInfo, CAT721CollectionInfo, BabylonTxInfo, ToSignData, CoinPrice, VersionDetail, BitcoinBalance, SignedData, ToSignMessage, SignedMessage, ConnectedSite, FeeSummary, TickPriceItem, InscribeOrder, TokenTransfer, DecodedPsbt, LocalPsbtSummary, AddressTokenSummary, UTXO_Detail, UTXO, WebsiteResult, SignPsbtOptions, ToSignInput, AddressFlagType, CosmosSignDataType, AddressRunesTokenSummary, AddressCAT20TokenSummary, AddressCAT20UtxoSummary, CAT20MergeOrder, AppExtra, CAT721Balance, AddressCAT721CollectionSummary, BtcChannelItem, BabylonAddressSummary, CosmosBalance, AddressAlkanesTokenSummary, AlkanesCollection, BRC20HistoryItem, RateUsStatus, Announcement, StoredNotification, DummyTxType, ToAddressInfo, RawTxInfo, SignPsbtParams, SignPsbtResult, WordsType, RestoreWalletType, ApprovalSession, PsbtActionInfo } from '@unisat/wallet-shared';
|
|
6
|
+
export { PsbtLocalInfo } from '@unisat/wallet-shared';
|
|
3
7
|
import * as _unisat_wallet_types from '@unisat/wallet-types';
|
|
4
8
|
import { ChainType, NetworkType, AddressType } from '@unisat/wallet-types';
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
+
import { AssetTabKey, OrdinalsAssetTabKey, CATAssetTabKey, AlkanesAssetTabKey, MoreAssetTabKey, NavigationSource, TabOption } from './types/index.mjs';
|
|
10
|
+
import * as react from 'react';
|
|
11
|
+
import react__default, { ReactNode } from 'react';
|
|
12
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
9
13
|
import * as _unisat_babylon_service_types from '@unisat/babylon-service/types';
|
|
10
14
|
import { BabylonConfigV2 } from '@unisat/babylon-service/types';
|
|
15
|
+
import * as redux_thunk from 'redux-thunk';
|
|
11
16
|
import { TypedUseSelectorHook } from 'react-redux';
|
|
12
17
|
|
|
18
|
+
declare enum WalletTabScreenTabKey {
|
|
19
|
+
ALL = 0,
|
|
20
|
+
BRC20 = 1
|
|
21
|
+
}
|
|
22
|
+
type suspensionType = {
|
|
23
|
+
suspensionIf: boolean;
|
|
24
|
+
info: AppInfo | object | any;
|
|
25
|
+
web: any;
|
|
26
|
+
};
|
|
27
|
+
type wcars = {
|
|
28
|
+
if?: boolean;
|
|
29
|
+
url: string;
|
|
30
|
+
};
|
|
31
|
+
type guideListsType = {
|
|
32
|
+
id: number;
|
|
33
|
+
title: string;
|
|
34
|
+
content: string;
|
|
35
|
+
img: string;
|
|
36
|
+
};
|
|
37
|
+
interface setSessionDateProps {
|
|
38
|
+
icon: string;
|
|
39
|
+
name: string;
|
|
40
|
+
origin: string;
|
|
41
|
+
}
|
|
42
|
+
interface BrowserState {
|
|
43
|
+
walletTabScreen: {
|
|
44
|
+
tabKey: wcars;
|
|
45
|
+
riskIf: boolean;
|
|
46
|
+
collect: any;
|
|
47
|
+
historyList: any;
|
|
48
|
+
suspension: suspensionType;
|
|
49
|
+
yy: any;
|
|
50
|
+
riseHeight: number;
|
|
51
|
+
ScanData: string;
|
|
52
|
+
amountValue: string;
|
|
53
|
+
guideList: guideListsType[];
|
|
54
|
+
popUp: boolean;
|
|
55
|
+
setStatusBar: boolean;
|
|
56
|
+
i18Class: string;
|
|
57
|
+
setSessionDate: setSessionDateProps;
|
|
58
|
+
webViewLod: boolean;
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
declare const browserActions: _reduxjs_toolkit.CaseReducerActions<_reduxjs_toolkit.SliceCaseReducers<BrowserState>, string>;
|
|
62
|
+
|
|
13
63
|
interface DiscoveryState {
|
|
14
64
|
bannerList: {
|
|
15
65
|
id: string;
|
|
@@ -27,11 +77,19 @@ interface DiscoveryState {
|
|
|
27
77
|
}
|
|
28
78
|
declare const discoveryActions: _reduxjs_toolkit.CaseReducerActions<_reduxjs_toolkit.SliceCaseReducers<DiscoveryState>, string>;
|
|
29
79
|
|
|
80
|
+
declare enum WallettopTabScreenTabKey {
|
|
81
|
+
Ordinals = 0,
|
|
82
|
+
Atomicals = 1,
|
|
83
|
+
Runes = 2,
|
|
84
|
+
CAT20 = 3,
|
|
85
|
+
Alkanes = 4
|
|
86
|
+
}
|
|
30
87
|
interface UIState {
|
|
31
88
|
assetTabKey: AssetTabKey;
|
|
32
89
|
ordinalsAssetTabKey: OrdinalsAssetTabKey;
|
|
33
90
|
catAssetTabKey: CATAssetTabKey;
|
|
34
91
|
alkanesAssetTabKey: AlkanesAssetTabKey;
|
|
92
|
+
moreAssetTabKey: MoreAssetTabKey;
|
|
35
93
|
uiTxCreateScreen: {
|
|
36
94
|
toInfo: {
|
|
37
95
|
address: string;
|
|
@@ -40,7 +98,21 @@ interface UIState {
|
|
|
40
98
|
};
|
|
41
99
|
inputAmount: string;
|
|
42
100
|
enableRBF: boolean;
|
|
101
|
+
};
|
|
102
|
+
addressInput: {
|
|
103
|
+
address: string;
|
|
104
|
+
domain: string;
|
|
105
|
+
inscription?: Inscription;
|
|
106
|
+
};
|
|
107
|
+
amountInput: {
|
|
108
|
+
amount: string;
|
|
109
|
+
};
|
|
110
|
+
feeRateBar: {
|
|
43
111
|
feeRate: number;
|
|
112
|
+
feeRateInputVal: string;
|
|
113
|
+
enableLowFeeRate: boolean;
|
|
114
|
+
feeOptionIndex: number;
|
|
115
|
+
showCustomInput: boolean;
|
|
44
116
|
};
|
|
45
117
|
babylonSendScreen: {
|
|
46
118
|
inputAmount: string;
|
|
@@ -48,6 +120,10 @@ interface UIState {
|
|
|
48
120
|
};
|
|
49
121
|
navigationSource: NavigationSource;
|
|
50
122
|
isBalanceHidden: boolean;
|
|
123
|
+
balanceDetailExpanded: boolean;
|
|
124
|
+
walletTopTabScreen: {
|
|
125
|
+
toptabKey: WallettopTabScreenTabKey;
|
|
126
|
+
};
|
|
51
127
|
}
|
|
52
128
|
declare const uiActions: _reduxjs_toolkit.CaseReducerActions<_reduxjs_toolkit.SliceCaseReducers<UIState>, string>;
|
|
53
129
|
|
|
@@ -62,6 +138,29 @@ interface GlobalState {
|
|
|
62
138
|
isUnlocked: boolean;
|
|
63
139
|
isReady: boolean;
|
|
64
140
|
isBooted: boolean;
|
|
141
|
+
screenState?: {
|
|
142
|
+
type: string;
|
|
143
|
+
options: any;
|
|
144
|
+
};
|
|
145
|
+
isRefresh: boolean;
|
|
146
|
+
backRefresh: boolean;
|
|
147
|
+
wallRefresh: boolean;
|
|
148
|
+
wallTabRefresh: boolean;
|
|
149
|
+
unlockRefres: boolean;
|
|
150
|
+
unlockRead: boolean;
|
|
151
|
+
layerState: boolean;
|
|
152
|
+
isUnlockTimeRefres: boolean;
|
|
153
|
+
infiniteListScrollOffset: number;
|
|
154
|
+
infiniteListScrollDirection: 'up' | 'down';
|
|
155
|
+
infiniteListScrollActiveTime: number;
|
|
156
|
+
isScrollViewTop: number;
|
|
157
|
+
isScrollViewBot: number;
|
|
158
|
+
isBiometricsSupported: boolean;
|
|
159
|
+
hasBiometricsKey: boolean;
|
|
160
|
+
wallTabFocusRefresh: 0;
|
|
161
|
+
goBackRefresh: 0;
|
|
162
|
+
switchChainModalVisible: boolean;
|
|
163
|
+
isLockedOverlayVisible: boolean;
|
|
65
164
|
}
|
|
66
165
|
declare const globalActions: any;
|
|
67
166
|
|
|
@@ -90,7 +189,6 @@ interface BitcoinTx {
|
|
|
90
189
|
psbtHex: string;
|
|
91
190
|
feeRate: number;
|
|
92
191
|
toDomain: string;
|
|
93
|
-
enableRBF: boolean;
|
|
94
192
|
}
|
|
95
193
|
interface OrdinalsTx {
|
|
96
194
|
fromAddress: string;
|
|
@@ -106,7 +204,6 @@ interface OrdinalsTx {
|
|
|
106
204
|
feeRate: number;
|
|
107
205
|
toDomain: string;
|
|
108
206
|
outputValue: number;
|
|
109
|
-
enableRBF: boolean;
|
|
110
207
|
}
|
|
111
208
|
interface RunesTx {
|
|
112
209
|
fromAddress: string;
|
|
@@ -121,7 +218,6 @@ interface RunesTx {
|
|
|
121
218
|
feeRate: number;
|
|
122
219
|
toDomain: string;
|
|
123
220
|
outputValue: number;
|
|
124
|
-
enableRBF: boolean;
|
|
125
221
|
runeid?: string;
|
|
126
222
|
runeAmount?: string;
|
|
127
223
|
}
|
|
@@ -136,6 +232,14 @@ interface TransactionsState {
|
|
|
136
232
|
}
|
|
137
233
|
declare const transactionsActions: _reduxjs_toolkit.CaseReducerActions<_reduxjs_toolkit.SliceCaseReducers<TransactionsState>, string>;
|
|
138
234
|
|
|
235
|
+
interface Molels {
|
|
236
|
+
states: boolean;
|
|
237
|
+
}
|
|
238
|
+
interface MolelsPopover {
|
|
239
|
+
state: boolean;
|
|
240
|
+
title: string;
|
|
241
|
+
data: any;
|
|
242
|
+
}
|
|
139
243
|
interface AccountsState {
|
|
140
244
|
accounts: Account[];
|
|
141
245
|
current: Account;
|
|
@@ -168,12 +272,342 @@ interface AccountsState {
|
|
|
168
272
|
appSummary: AppSummary;
|
|
169
273
|
inscriptionSummary: InscriptionSummary;
|
|
170
274
|
addressSummary: AddressSummary;
|
|
275
|
+
model: Molels;
|
|
276
|
+
molelsPopover: MolelsPopover;
|
|
171
277
|
}
|
|
172
278
|
declare const accountActions: _reduxjs_toolkit.CaseReducerActions<_reduxjs_toolkit.SliceCaseReducers<AccountsState>, string>;
|
|
173
279
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
280
|
+
interface ApprovalContextType {
|
|
281
|
+
getApproval: () => Promise<any>;
|
|
282
|
+
resolveApproval: (data?: any, stay?: boolean, forceReject?: boolean) => Promise<void>;
|
|
283
|
+
rejectApproval: (reason?: string, stay?: boolean, isInternal?: boolean) => Promise<void>;
|
|
284
|
+
}
|
|
285
|
+
declare const ApprovalContext: react__default.Context<ApprovalContextType>;
|
|
286
|
+
declare function useApproval(): ApprovalContextType;
|
|
287
|
+
|
|
288
|
+
interface DeviceContextType {
|
|
289
|
+
isMobile: boolean;
|
|
290
|
+
isIOS: boolean;
|
|
291
|
+
isAndroid: boolean;
|
|
292
|
+
isExtensionInExpandView: boolean;
|
|
293
|
+
isExtensionInSideBar: boolean;
|
|
294
|
+
isExtension: boolean;
|
|
295
|
+
isMobileScreenSize: boolean;
|
|
296
|
+
isDesktopScreenSize: boolean;
|
|
297
|
+
platform: string;
|
|
298
|
+
hasBottomButton: boolean;
|
|
299
|
+
cardColumnsInList: number;
|
|
300
|
+
}
|
|
301
|
+
declare const DeviceContext: react__default.Context<DeviceContextType>;
|
|
302
|
+
declare function useDevice(): DeviceContextType;
|
|
303
|
+
|
|
304
|
+
interface I18nContextType {
|
|
305
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
306
|
+
locale: string;
|
|
307
|
+
supportedLocales: string[];
|
|
308
|
+
localeNames: Record<string, string>;
|
|
309
|
+
changeLocale: (locale: string) => Promise<void>;
|
|
310
|
+
addResourceBundle?: (locale: string) => Promise<void>;
|
|
311
|
+
isSpecialLocale: boolean;
|
|
312
|
+
}
|
|
313
|
+
declare const I18nContext: react__default.Context<I18nContextType>;
|
|
314
|
+
declare function useI18n(): I18nContextType;
|
|
315
|
+
|
|
316
|
+
type RouteParamList = {
|
|
317
|
+
WelcomeScreen: undefined;
|
|
318
|
+
UnlockScreen: {
|
|
319
|
+
autoUnlockByFace: boolean;
|
|
320
|
+
};
|
|
321
|
+
CreatePasswordScreen: {
|
|
322
|
+
isNewAccount?: boolean;
|
|
323
|
+
isKeystone?: boolean;
|
|
324
|
+
fromColdWallet?: boolean;
|
|
325
|
+
};
|
|
326
|
+
MainScreen: undefined;
|
|
327
|
+
WalletTabScreen: undefined;
|
|
328
|
+
AppTabScreen: undefined;
|
|
329
|
+
TabMainScreen: undefined;
|
|
330
|
+
DiscoverTabScreen: undefined;
|
|
331
|
+
SettingsTabScreen: undefined;
|
|
332
|
+
CreateHDWalletScreen: {
|
|
333
|
+
restoreTiTle?: boolean;
|
|
334
|
+
topTitle?: boolean;
|
|
335
|
+
finalButton?: string;
|
|
336
|
+
existingMnemonic?: string;
|
|
337
|
+
isBackupFlow?: boolean;
|
|
338
|
+
isImport?: boolean;
|
|
339
|
+
comeFrom?: string;
|
|
340
|
+
fromUnlock?: boolean;
|
|
341
|
+
goBack?: boolean;
|
|
342
|
+
};
|
|
343
|
+
CreateSimpleWalletScreen: undefined;
|
|
344
|
+
CreateWatchWalletScreen: undefined;
|
|
345
|
+
CreateColdWalletScreen: {
|
|
346
|
+
fromUnlock?: boolean;
|
|
347
|
+
};
|
|
348
|
+
CreateKeystoneWalletScreen: {
|
|
349
|
+
fromUnlock?: boolean;
|
|
350
|
+
};
|
|
351
|
+
EditWalletNameScreen: {
|
|
352
|
+
keyring: WalletKeyring;
|
|
353
|
+
};
|
|
354
|
+
ExportMnemonicsScreen: {
|
|
355
|
+
keyring: WalletKeyring;
|
|
356
|
+
};
|
|
357
|
+
ExportPrivateKeyScreen: {
|
|
358
|
+
account: Account;
|
|
359
|
+
};
|
|
360
|
+
SwitchAccountScreen: undefined;
|
|
361
|
+
ReceiveScreen: undefined;
|
|
362
|
+
HistoryScreen: undefined;
|
|
363
|
+
KeyringOrAccountScreen: undefined;
|
|
364
|
+
AddKeyringScreen: undefined;
|
|
365
|
+
ImportHDWalletScreen: {
|
|
366
|
+
comeFrom?: string;
|
|
367
|
+
};
|
|
368
|
+
CreateAccountScreen: {
|
|
369
|
+
keyringKey?: string;
|
|
370
|
+
};
|
|
371
|
+
CreateKeystoneScreen: {
|
|
372
|
+
comeFrom?: string;
|
|
373
|
+
goBack?: boolean;
|
|
374
|
+
};
|
|
375
|
+
EditAccountNameScreen: {
|
|
376
|
+
account: Account;
|
|
377
|
+
};
|
|
378
|
+
KeyringDetailScreen: {
|
|
379
|
+
keyringKey?: string;
|
|
380
|
+
};
|
|
381
|
+
ConnectedSitesScreen: undefined;
|
|
382
|
+
AddressTypeScreen: undefined;
|
|
383
|
+
AdvancedScreen: undefined;
|
|
384
|
+
ContactsScreen: {
|
|
385
|
+
returnWithNetwork?: ChainType;
|
|
386
|
+
lastEditedContactAddress?: string;
|
|
387
|
+
};
|
|
388
|
+
EditContactScreen: {
|
|
389
|
+
address?: string;
|
|
390
|
+
chain?: string;
|
|
391
|
+
selectedNetworkFilter: string;
|
|
392
|
+
};
|
|
393
|
+
AboutUsScreen: undefined;
|
|
394
|
+
LanguageScreen: undefined;
|
|
395
|
+
ChangePasswordScreen: undefined;
|
|
396
|
+
ModuleAssets: undefined;
|
|
397
|
+
NotificationListScreen: undefined;
|
|
398
|
+
UtxoToolsMainScreen: undefined;
|
|
399
|
+
ScanScreen: {
|
|
400
|
+
from?: string;
|
|
401
|
+
};
|
|
402
|
+
BrowserScreen: {
|
|
403
|
+
info: any;
|
|
404
|
+
};
|
|
405
|
+
TxCreateScreen: undefined;
|
|
406
|
+
OrdinalsInscriptionScreen: {
|
|
407
|
+
inscription: Inscription;
|
|
408
|
+
inscriptionId?: string;
|
|
409
|
+
withSend?: boolean;
|
|
410
|
+
};
|
|
411
|
+
SendOrdinalsInscriptionScreen: {
|
|
412
|
+
inscription: Inscription;
|
|
413
|
+
inscriptionId?: string;
|
|
414
|
+
};
|
|
415
|
+
SplitOrdinalsInscriptionScreen: {
|
|
416
|
+
inscription: Inscription;
|
|
417
|
+
inscriptionId?: string;
|
|
418
|
+
};
|
|
419
|
+
BRC20TokenScreen: {
|
|
420
|
+
ticker: string;
|
|
421
|
+
tokenBalance?: TokenBalance;
|
|
422
|
+
};
|
|
423
|
+
BRC20SendScreen: {
|
|
424
|
+
tokenBalance: TokenBalance;
|
|
425
|
+
tokenInfo: TokenInfo;
|
|
426
|
+
selectedInscriptionIds?: string[];
|
|
427
|
+
selectedAmount?: string;
|
|
428
|
+
};
|
|
429
|
+
BRC20InscribeTransfer: {
|
|
430
|
+
ticker: string;
|
|
431
|
+
};
|
|
432
|
+
BRC20SingleStepScreen: {
|
|
433
|
+
tokenBalance: TokenBalance;
|
|
434
|
+
tokenInfo: TokenInfo;
|
|
435
|
+
};
|
|
436
|
+
InscribeTransferScreen: {
|
|
437
|
+
ticker: string;
|
|
438
|
+
};
|
|
439
|
+
RunesTokenScreen: {
|
|
440
|
+
runeid: string;
|
|
441
|
+
};
|
|
442
|
+
SendRunesScreen: {
|
|
443
|
+
runeBalance: RuneBalance;
|
|
444
|
+
runeInfo: RuneInfo;
|
|
445
|
+
};
|
|
446
|
+
AlkanesTokenScreen: {
|
|
447
|
+
alkaneid: string;
|
|
448
|
+
};
|
|
449
|
+
SendAlkanesScreen: {
|
|
450
|
+
tokenBalance: AlkanesBalance;
|
|
451
|
+
tokenInfo: AlkanesInfo;
|
|
452
|
+
};
|
|
453
|
+
AlkanesCollectionScreen: {
|
|
454
|
+
collectionId: string;
|
|
455
|
+
};
|
|
456
|
+
AlkanesNFTScreen: {
|
|
457
|
+
alkanesInfo: AlkanesInfo;
|
|
458
|
+
};
|
|
459
|
+
SendAlkanesNFTScreen: {
|
|
460
|
+
alkanesInfo: AlkanesInfo;
|
|
461
|
+
};
|
|
462
|
+
CAT20TokenScreen: {
|
|
463
|
+
tokenId: string;
|
|
464
|
+
version: CAT_VERSION;
|
|
465
|
+
};
|
|
466
|
+
SendCAT20Screen: {
|
|
467
|
+
version: CAT_VERSION;
|
|
468
|
+
cat20Balance: CAT20Balance;
|
|
469
|
+
cat20Info: CAT20TokenInfo;
|
|
470
|
+
};
|
|
471
|
+
MergeCAT20Screen: {
|
|
472
|
+
version: CAT_VERSION;
|
|
473
|
+
cat20Balance: CAT20Balance;
|
|
474
|
+
cat20Info: CAT20TokenInfo;
|
|
475
|
+
};
|
|
476
|
+
CAT721CollectionScreen: {
|
|
477
|
+
collectionId: string;
|
|
478
|
+
version: CAT_VERSION;
|
|
479
|
+
};
|
|
480
|
+
CAT721NFTScreen: {
|
|
481
|
+
version: CAT_VERSION;
|
|
482
|
+
collectionInfo: CAT721CollectionInfo;
|
|
483
|
+
localId: string;
|
|
484
|
+
};
|
|
485
|
+
SendCAT721Screen: {
|
|
486
|
+
version: CAT_VERSION;
|
|
487
|
+
collectionInfo: CAT721CollectionInfo;
|
|
488
|
+
localId: string;
|
|
489
|
+
};
|
|
490
|
+
BabylonTxConfirmScreen: {
|
|
491
|
+
txInfo: BabylonTxInfo;
|
|
492
|
+
};
|
|
493
|
+
BabylonStakingScreen: undefined;
|
|
494
|
+
SendBabyScreen: undefined;
|
|
495
|
+
TxConfirmScreen: {
|
|
496
|
+
toSignData: ToSignData;
|
|
497
|
+
};
|
|
498
|
+
TxSuccessScreen: {
|
|
499
|
+
txid: string;
|
|
500
|
+
};
|
|
501
|
+
TxFailScreen: {
|
|
502
|
+
error: string;
|
|
503
|
+
};
|
|
504
|
+
};
|
|
505
|
+
type RouteTypes = keyof RouteParamList;
|
|
506
|
+
type NavigateArgs<T extends RouteTypes> = RouteParamList[T] extends undefined ? [screenName: T] : [screenName: T, params: RouteParamList[T]];
|
|
507
|
+
interface NavigationContextType {
|
|
508
|
+
navigate<T extends RouteTypes>(...args: NavigateArgs<T>): void;
|
|
509
|
+
replace<T extends RouteTypes>(...args: NavigateArgs<T>): void;
|
|
510
|
+
poptotop: () => void;
|
|
511
|
+
goBack: () => void;
|
|
512
|
+
navToTab: () => void;
|
|
513
|
+
navToTest: () => void;
|
|
514
|
+
navToLock: (params?: any) => void;
|
|
515
|
+
navToWelcome: () => void;
|
|
516
|
+
getRouteState<T extends RouteTypes>(): RouteParamList[T];
|
|
517
|
+
navToUtxoTools: () => void;
|
|
518
|
+
navToUrl: (url: string, externalBrowser?: boolean) => void;
|
|
519
|
+
navToExplorerTx: (txid: string) => void;
|
|
520
|
+
navToExplorerAddress: (address: string) => void;
|
|
521
|
+
navToMarketPlace: () => void;
|
|
522
|
+
navToMarketPlaceBrc20: (ticker: string) => void;
|
|
523
|
+
navToInscribeBrc20: (ticker: string) => void;
|
|
524
|
+
openExtensionInTab?: () => void;
|
|
525
|
+
navToRootHome: () => void;
|
|
526
|
+
}
|
|
527
|
+
declare const NavigationContext: react__default.Context<NavigationContextType>;
|
|
528
|
+
declare function useNavigation(): NavigationContextType;
|
|
529
|
+
|
|
530
|
+
interface PriceContextType {
|
|
531
|
+
isLoadingCoinPrice: boolean;
|
|
532
|
+
coinPrice: CoinPrice;
|
|
533
|
+
refreshCoinPrice: () => void;
|
|
534
|
+
}
|
|
535
|
+
declare function usePrice(): PriceContextType;
|
|
536
|
+
declare function PriceProvider({ children }: {
|
|
537
|
+
children: ReactNode;
|
|
538
|
+
}): react_jsx_runtime.JSX.Element;
|
|
539
|
+
|
|
540
|
+
type AutoLockTime = {
|
|
541
|
+
id: number;
|
|
542
|
+
time: number;
|
|
543
|
+
label: string;
|
|
544
|
+
};
|
|
545
|
+
type WebSearchHistoryItem = string;
|
|
546
|
+
type WebRiskWarningItem = {
|
|
547
|
+
url: string;
|
|
548
|
+
};
|
|
549
|
+
interface BaseStorageProvider {
|
|
550
|
+
get: (key: string) => Promise<any>;
|
|
551
|
+
set: (key: string, value: any) => Promise<void>;
|
|
552
|
+
}
|
|
553
|
+
interface StorageContextType {
|
|
554
|
+
get: (key: string) => Promise<string>;
|
|
555
|
+
set: (key: string, value: string) => Promise<void>;
|
|
556
|
+
clear: () => Promise<void>;
|
|
557
|
+
getAutomaticLockTime: () => Promise<AutoLockTime>;
|
|
558
|
+
clearAutomaticLockTime: () => Promise<void>;
|
|
559
|
+
getAnnouncementDismissedIds: () => Promise<string[]>;
|
|
560
|
+
setAnnouncementDismissedIds: (ids: string[]) => Promise<void>;
|
|
561
|
+
clearAnnouncementDismissedIds: () => Promise<void>;
|
|
562
|
+
getI18nSavedLang: () => Promise<string>;
|
|
563
|
+
setI18nSavedLang: (lang: string) => Promise<void>;
|
|
564
|
+
clearI18nSavedLang: () => Promise<void>;
|
|
565
|
+
getWebSearchHistory: () => Promise<WebSearchHistoryItem[]>;
|
|
566
|
+
setWebSearchHistory: (history: WebSearchHistoryItem[]) => Promise<void>;
|
|
567
|
+
clearWebSearchHistory: () => Promise<void>;
|
|
568
|
+
getWebRiskWarning: () => Promise<WebRiskWarningItem[]>;
|
|
569
|
+
setWebRiskWarning: (warnings: WebRiskWarningItem[]) => Promise<void>;
|
|
570
|
+
clearWebRiskWarning: () => Promise<void>;
|
|
571
|
+
getEnableExplore: () => Promise<boolean>;
|
|
572
|
+
setEnableExplore: (enable: boolean) => Promise<void>;
|
|
573
|
+
clearEnableExplore: () => Promise<void>;
|
|
574
|
+
getUnbackupKeyringIds: () => Promise<string[]>;
|
|
575
|
+
setUnbackupKeyringIds: (keyrings: string[]) => Promise<void>;
|
|
576
|
+
clearUnbackupKeyringIds: () => Promise<void>;
|
|
577
|
+
getEnableFaceId: () => Promise<boolean>;
|
|
578
|
+
setEnableFaceId: (enable: boolean) => Promise<void>;
|
|
579
|
+
clearEnableFaceId: () => Promise<void>;
|
|
580
|
+
getBalanceHidden: () => Promise<boolean>;
|
|
581
|
+
setBalanceHidden: (enable: boolean) => Promise<void>;
|
|
582
|
+
clearBalanceHidden: () => Promise<void>;
|
|
583
|
+
getVersionDetail: () => Promise<VersionDetail>;
|
|
584
|
+
setVersionDetail: (detail: VersionDetail) => Promise<void>;
|
|
585
|
+
clearVersionDetail: () => Promise<void>;
|
|
586
|
+
getThemeMode: () => Promise<string>;
|
|
587
|
+
setThemeMode: (mode: string) => Promise<void>;
|
|
588
|
+
clearThemeMode: () => Promise<void>;
|
|
589
|
+
getUtxoManageVisited: () => Promise<boolean>;
|
|
590
|
+
setUtxoManageVisited: () => Promise<void>;
|
|
591
|
+
clearUtxoManageVisited: () => Promise<void>;
|
|
592
|
+
}
|
|
593
|
+
declare function createStorageProvider(base: BaseStorageProvider): StorageContextType;
|
|
594
|
+
declare const StorageContext: react__default.Context<StorageContextType>;
|
|
595
|
+
declare function useStorage(): StorageContextType;
|
|
596
|
+
|
|
597
|
+
type ToastFunction = (content: string) => void;
|
|
598
|
+
type LoadingFunction = (visible: boolean, content?: string) => void;
|
|
599
|
+
interface ToolsContextType {
|
|
600
|
+
toast: ToastFunction;
|
|
601
|
+
toastSuccess: ToastFunction;
|
|
602
|
+
toastError: ToastFunction;
|
|
603
|
+
toastWarning: ToastFunction;
|
|
604
|
+
showLoading: LoadingFunction;
|
|
605
|
+
showTip: ToastFunction;
|
|
606
|
+
copyToClipboard: (text: string) => void;
|
|
607
|
+
openUrl: (url: string) => void;
|
|
608
|
+
}
|
|
609
|
+
declare const ToolsContext: react__default.Context<ToolsContextType>;
|
|
610
|
+
declare function useTools(): ToolsContextType;
|
|
177
611
|
|
|
178
612
|
interface ContactBookItem {
|
|
179
613
|
name: string;
|
|
@@ -188,13 +622,17 @@ interface WalletController {
|
|
|
188
622
|
openapi: {
|
|
189
623
|
[key: string]: (...params: any) => Promise<any>;
|
|
190
624
|
};
|
|
625
|
+
requestMethod: (...params: any) => Promise<any>;
|
|
626
|
+
setBackgroundInited(value: boolean): Promise<void>;
|
|
627
|
+
getBackgroundInited(): Promise<boolean>;
|
|
628
|
+
getDesc: () => string;
|
|
191
629
|
boot(password: string): Promise<void>;
|
|
192
630
|
isBooted(): Promise<boolean>;
|
|
193
631
|
getApproval(): Promise<any>;
|
|
194
632
|
resolveApproval(data?: any, data2?: any): Promise<void>;
|
|
195
633
|
rejectApproval(data?: any, data2?: any, data3?: any): Promise<void>;
|
|
196
634
|
hasVault(): Promise<boolean>;
|
|
197
|
-
verifyPassword(password: string): Promise<
|
|
635
|
+
verifyPassword(password: string): Promise<boolean>;
|
|
198
636
|
changePassword: (password: string, newPassword: string) => Promise<void>;
|
|
199
637
|
unlock(password: string): Promise<void>;
|
|
200
638
|
isUnlocked(): Promise<boolean>;
|
|
@@ -252,7 +690,7 @@ interface WalletController {
|
|
|
252
690
|
getPreMnemonics(): Promise<any>;
|
|
253
691
|
generatePreMnemonic(): Promise<string>;
|
|
254
692
|
removePreMnemonics(): void;
|
|
255
|
-
createKeyringWithMnemonics(mnemonic: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount: number): Promise<{
|
|
693
|
+
createKeyringWithMnemonics(mnemonic: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount: number, accountIndexDerivation?: boolean): Promise<{
|
|
256
694
|
address: string;
|
|
257
695
|
type: string;
|
|
258
696
|
}[]>;
|
|
@@ -267,7 +705,9 @@ interface WalletController {
|
|
|
267
705
|
pubkey: string;
|
|
268
706
|
address: string;
|
|
269
707
|
}[]>;
|
|
270
|
-
createTmpKeyringWithMnemonics(mnemonic: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount?: number): Promise<WalletKeyring>;
|
|
708
|
+
createTmpKeyringWithMnemonics(mnemonic: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount?: number, accountIndexDerivation?: boolean): Promise<WalletKeyring>;
|
|
709
|
+
createTmpKeyringWithMnemonics2(mnemonic: string, passphrase: string, hdPaths: string[], addressTypes: AddressType[]): Promise<WalletKeyring[]>;
|
|
710
|
+
createTmpKeyringWithMnemonicsScan(mnemonic: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount: number, accountIndexDerivation?: boolean): Promise<WalletKeyring>;
|
|
271
711
|
removeKeyring(keyring: WalletKeyring): Promise<WalletKeyring>;
|
|
272
712
|
deriveNewAccountFromMnemonic(keyring: WalletKeyring, alianName?: string): Promise<string[]>;
|
|
273
713
|
getAccountsCount(): Promise<number>;
|
|
@@ -277,65 +717,45 @@ interface WalletController {
|
|
|
277
717
|
getAccounts(): Promise<Account[]>;
|
|
278
718
|
getNextAlianName: (keyring: WalletKeyring) => Promise<string>;
|
|
279
719
|
getCurrentKeyringAccounts(): Promise<Account[]>;
|
|
280
|
-
|
|
281
|
-
|
|
720
|
+
signPsbtV2(toSignData: ToSignData): Promise<SignedData>;
|
|
721
|
+
signMessage(params: ToSignMessage): Promise<SignedMessage>;
|
|
722
|
+
createSendBTCPsbt(data: {
|
|
282
723
|
to: string;
|
|
283
724
|
amount: number;
|
|
284
725
|
btcUtxos: UnspentOutput[];
|
|
285
726
|
feeRate: number;
|
|
286
|
-
enableRBF
|
|
727
|
+
enableRBF?: boolean;
|
|
287
728
|
memo?: string;
|
|
288
729
|
memos?: string[];
|
|
289
|
-
}): Promise<
|
|
290
|
-
|
|
291
|
-
rawtx: string;
|
|
292
|
-
fee: number;
|
|
293
|
-
}>;
|
|
294
|
-
sendAllBTC(data: {
|
|
730
|
+
}): Promise<ToSignData>;
|
|
731
|
+
createSendAllBTCPsbt(data: {
|
|
295
732
|
to: string;
|
|
296
733
|
btcUtxos: UnspentOutput[];
|
|
297
734
|
feeRate: number;
|
|
298
|
-
enableRBF
|
|
299
|
-
}): Promise<
|
|
300
|
-
|
|
301
|
-
rawtx: string;
|
|
302
|
-
fee: number;
|
|
303
|
-
}>;
|
|
304
|
-
sendOrdinalsInscription(data: {
|
|
735
|
+
enableRBF?: boolean;
|
|
736
|
+
}): Promise<ToSignData>;
|
|
737
|
+
createSendInscriptionPsbt(data: {
|
|
305
738
|
to: string;
|
|
306
739
|
inscriptionId: string;
|
|
307
740
|
feeRate: number;
|
|
308
741
|
outputValue?: number;
|
|
309
|
-
enableRBF: boolean;
|
|
310
742
|
btcUtxos: UnspentOutput[];
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
fee: number;
|
|
315
|
-
}>;
|
|
316
|
-
sendOrdinalsInscriptions(data: {
|
|
743
|
+
enableRBF?: boolean;
|
|
744
|
+
}): Promise<ToSignData>;
|
|
745
|
+
createSendMultipleInscriptionsPsbt(data: {
|
|
317
746
|
to: string;
|
|
318
747
|
inscriptionIds: string[];
|
|
319
748
|
feeRate: number;
|
|
320
|
-
enableRBF: boolean;
|
|
321
749
|
btcUtxos: UnspentOutput[];
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
fee: number;
|
|
326
|
-
}>;
|
|
327
|
-
splitOrdinalsInscription(data: {
|
|
750
|
+
enableRBF?: boolean;
|
|
751
|
+
}): Promise<ToSignData>;
|
|
752
|
+
createSplitInscriptionPsbt(data: {
|
|
328
753
|
inscriptionId: string;
|
|
329
754
|
feeRate: number;
|
|
330
755
|
outputValue: number;
|
|
331
|
-
enableRBF: boolean;
|
|
332
756
|
btcUtxos: UnspentOutput[];
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
rawtx: string;
|
|
336
|
-
fee: number;
|
|
337
|
-
splitedCount: number;
|
|
338
|
-
}>;
|
|
757
|
+
enableRBF?: boolean;
|
|
758
|
+
}): Promise<ToSignData>;
|
|
339
759
|
pushTx(rawtx: string): Promise<string>;
|
|
340
760
|
queryDomainInfo(domain: string): Promise<Inscription>;
|
|
341
761
|
getInscriptionSummary(): Promise<InscriptionSummary>;
|
|
@@ -349,14 +769,17 @@ interface WalletController {
|
|
|
349
769
|
getConnectedSites(): Promise<ConnectedSite[]>;
|
|
350
770
|
removeConnectedSite(origin: string): Promise<void>;
|
|
351
771
|
getCurrentConnectedSite(id: string): Promise<ConnectedSite>;
|
|
772
|
+
updateConnectSite(origin: string, data: Partial<ConnectedSite>): Promise<void>;
|
|
352
773
|
getCurrentKeyring(): Promise<WalletKeyring>;
|
|
353
774
|
getKeyrings(): Promise<WalletKeyring[]>;
|
|
775
|
+
getTotalKeyringCount(): Promise<number>;
|
|
354
776
|
changeKeyring(keyring: WalletKeyring, accountIndex?: number): Promise<void>;
|
|
355
777
|
getAllAddresses(keyring: WalletKeyring, index: number): Promise<string[]>;
|
|
356
778
|
setKeyringAlianName(keyring: WalletKeyring, name: string): Promise<WalletKeyring>;
|
|
357
779
|
changeAddressType(addressType: AddressType): Promise<void>;
|
|
358
780
|
setAccountAlianName(account: Account, name: string): Promise<Account>;
|
|
359
781
|
getFeeSummary(): Promise<FeeSummary>;
|
|
782
|
+
getLowFeeSummary(): Promise<FeeSummary>;
|
|
360
783
|
getCoinPrice(): Promise<CoinPrice>;
|
|
361
784
|
getBrc20sPrice(ticks: string[]): Promise<{
|
|
362
785
|
[tick: string]: TickPriceItem;
|
|
@@ -377,6 +800,7 @@ interface WalletController {
|
|
|
377
800
|
inscribeBRC20Transfer(address: string, tick: string, amount: string, feeRate: number, outputValue: number): Promise<InscribeOrder>;
|
|
378
801
|
getInscribeResult(orderId: string): Promise<TokenTransfer>;
|
|
379
802
|
decodePsbt(psbtHex: string, website: string): Promise<DecodedPsbt>;
|
|
803
|
+
analyzeLocalPsbts(toSignDatas: ToSignData[]): Promise<LocalPsbtSummary>;
|
|
380
804
|
decodeContracts(contracts: any[], account: any): Promise<any[]>;
|
|
381
805
|
getAllInscriptionList(address: string, currentPage: number, pageSize: number): Promise<{
|
|
382
806
|
currentPage: number;
|
|
@@ -384,19 +808,33 @@ interface WalletController {
|
|
|
384
808
|
total: number;
|
|
385
809
|
list: Inscription[];
|
|
386
810
|
}>;
|
|
387
|
-
getBRC20List(address
|
|
811
|
+
getBRC20List({ address, currentPage, pageSize, }: {
|
|
812
|
+
address: string;
|
|
813
|
+
currentPage: number;
|
|
814
|
+
pageSize: number;
|
|
815
|
+
}): Promise<{
|
|
388
816
|
currentPage: number;
|
|
389
817
|
pageSize: number;
|
|
390
818
|
total: number;
|
|
391
819
|
list: TokenBalance[];
|
|
392
820
|
}>;
|
|
393
|
-
getBRC20ProgList(address
|
|
821
|
+
getBRC20ProgList({ address, currentPage, pageSize, }: {
|
|
822
|
+
address: string;
|
|
823
|
+
currentPage: number;
|
|
824
|
+
pageSize: number;
|
|
825
|
+
}): Promise<{
|
|
394
826
|
currentPage: number;
|
|
395
827
|
pageSize: number;
|
|
396
828
|
total: number;
|
|
397
829
|
list: TokenBalance[];
|
|
398
830
|
}>;
|
|
399
|
-
getBRC20TransferableList(address
|
|
831
|
+
getBRC20TransferableList({ address, ticker, tickerHex, currentPage, pageSize, }: {
|
|
832
|
+
address: string;
|
|
833
|
+
ticker: string;
|
|
834
|
+
tickerHex: string;
|
|
835
|
+
currentPage: number;
|
|
836
|
+
pageSize: number;
|
|
837
|
+
}): Promise<{
|
|
400
838
|
currentPage: number;
|
|
401
839
|
pageSize: number;
|
|
402
840
|
total: number;
|
|
@@ -408,7 +846,10 @@ interface WalletController {
|
|
|
408
846
|
total: number;
|
|
409
847
|
list: Inscription[];
|
|
410
848
|
}>;
|
|
411
|
-
getBRC20Summary(address
|
|
849
|
+
getBRC20Summary({ address, ticker, }: {
|
|
850
|
+
address: string;
|
|
851
|
+
ticker: string;
|
|
852
|
+
}): Promise<AddressTokenSummary>;
|
|
412
853
|
expireUICachedData(address: string): Promise<void>;
|
|
413
854
|
getWalletConfig(): Promise<WalletConfig>;
|
|
414
855
|
getSkippedVersion(): Promise<string>;
|
|
@@ -471,20 +912,16 @@ interface WalletController {
|
|
|
471
912
|
}>;
|
|
472
913
|
getAssetUtxosRunes(rune: string): Promise<UnspentOutput[]>;
|
|
473
914
|
getAddressRunesTokenSummary(address: string, runeid: string): Promise<AddressRunesTokenSummary>;
|
|
474
|
-
|
|
915
|
+
createSendRunesPsbt(data: {
|
|
475
916
|
to: string;
|
|
476
917
|
runeid: string;
|
|
477
918
|
runeAmount: string;
|
|
478
919
|
feeRate: number;
|
|
479
|
-
enableRBF: boolean;
|
|
480
920
|
btcUtxos?: UnspentOutput[];
|
|
481
921
|
assetUtxos?: UnspentOutput[];
|
|
482
922
|
outputValue?: number;
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
rawtx: string;
|
|
486
|
-
fee: number;
|
|
487
|
-
}>;
|
|
923
|
+
enableRBF?: boolean;
|
|
924
|
+
}): Promise<ToSignData>;
|
|
488
925
|
setAutoLockTimeId(timeId: number): Promise<void>;
|
|
489
926
|
getAutoLockTimeId(): Promise<number>;
|
|
490
927
|
getDeveloperMode(): Promise<boolean>;
|
|
@@ -499,29 +936,27 @@ interface WalletController {
|
|
|
499
936
|
getAddressCAT20UtxoSummary(version: 'v1' | 'v2', address: string, tokenId: string): Promise<AddressCAT20UtxoSummary>;
|
|
500
937
|
transferCAT20Step1(version: 'v1' | 'v2', to: string, tokenId: string, tokenAmount: string, feeRate: number): Promise<{
|
|
501
938
|
id: string;
|
|
502
|
-
commitTx: string;
|
|
503
|
-
toSignInputs: UserToSignInput[];
|
|
504
939
|
feeRate: number;
|
|
940
|
+
toSignData: ToSignData;
|
|
505
941
|
}>;
|
|
506
|
-
transferCAT20Step2(version: 'v1' | 'v2', transferId: string,
|
|
507
|
-
|
|
508
|
-
toSignInputs: UserToSignInput[];
|
|
942
|
+
transferCAT20Step2(version: 'v1' | 'v2', transferId: string, psbtHex: string): Promise<{
|
|
943
|
+
toSignData: ToSignData;
|
|
509
944
|
}>;
|
|
510
|
-
transferCAT20Step3(version: 'v1' | 'v2', transferId: string,
|
|
945
|
+
transferCAT20Step3(version: 'v1' | 'v2', transferId: string, psbtHex: string): Promise<{
|
|
511
946
|
txid: string;
|
|
512
947
|
}>;
|
|
513
948
|
mergeCAT20Prepare(version: 'v1' | 'v2', tokenId: string, utxoCount: number, feeRate: number): Promise<CAT20MergeOrder>;
|
|
514
949
|
transferCAT20Step1ByMerge(version: 'v1' | 'v2', mergeId: string): Promise<{
|
|
515
950
|
id: string;
|
|
516
|
-
commitTx: string;
|
|
517
|
-
toSignInputs: UserToSignInput[];
|
|
518
951
|
feeRate: number;
|
|
952
|
+
toSignData: ToSignData;
|
|
519
953
|
}>;
|
|
520
954
|
getMergeCAT20Status(version: 'v1' | 'v2', mergeId: string): Promise<any>;
|
|
521
955
|
getAppList(): Promise<{
|
|
522
956
|
tab: string;
|
|
523
957
|
items: AppInfo[];
|
|
524
958
|
}[]>;
|
|
959
|
+
getAppExtra(id: string | number, locale?: string): Promise<AppExtra>;
|
|
525
960
|
getBannerList(): Promise<{
|
|
526
961
|
id: string;
|
|
527
962
|
img: string;
|
|
@@ -540,15 +975,13 @@ interface WalletController {
|
|
|
540
975
|
getAddressCAT721CollectionSummary(version: 'v1' | 'v2', address: string, collectionId: string): Promise<AddressCAT721CollectionSummary>;
|
|
541
976
|
transferCAT721Step1(version: 'v1' | 'v2', to: string, collectionId: string, localId: string, feeRate: number): Promise<{
|
|
542
977
|
id: string;
|
|
543
|
-
commitTx: string;
|
|
544
|
-
toSignInputs: UserToSignInput[];
|
|
545
978
|
feeRate: number;
|
|
979
|
+
toSignData: ToSignData;
|
|
546
980
|
}>;
|
|
547
|
-
transferCAT721Step2(version: 'v1' | 'v2', transferId: string,
|
|
548
|
-
|
|
549
|
-
toSignInputs: UserToSignInput[];
|
|
981
|
+
transferCAT721Step2(version: 'v1' | 'v2', transferId: string, psbtHex: string): Promise<{
|
|
982
|
+
toSignData: ToSignData;
|
|
550
983
|
}>;
|
|
551
|
-
transferCAT721Step3(version: 'v1' | 'v2', transferId: string,
|
|
984
|
+
transferCAT721Step3(version: 'v1' | 'v2', transferId: string, psbtHex: string): Promise<{
|
|
552
985
|
txid: string;
|
|
553
986
|
}>;
|
|
554
987
|
getBuyCoinChannelList(coin: string): Promise<BtcChannelItem[]>;
|
|
@@ -581,35 +1014,27 @@ interface WalletController {
|
|
|
581
1014
|
feeRate: number;
|
|
582
1015
|
}): Promise<{
|
|
583
1016
|
orderId: string;
|
|
584
|
-
|
|
585
|
-
toSignInputs: UserToSignInput[];
|
|
1017
|
+
toSignData: ToSignData;
|
|
586
1018
|
}>;
|
|
587
1019
|
singleStepTransferBRC20Step2(params: {
|
|
588
1020
|
orderId: string;
|
|
589
1021
|
commitTx: string;
|
|
590
|
-
toSignInputs: UserToSignInput[];
|
|
591
1022
|
}): Promise<{
|
|
592
|
-
|
|
593
|
-
toSignInputs: UserToSignInput[];
|
|
1023
|
+
toSignData: ToSignData;
|
|
594
1024
|
}>;
|
|
595
1025
|
singleStepTransferBRC20Step3(params: {
|
|
596
1026
|
orderId: string;
|
|
597
1027
|
revealTx: string;
|
|
598
|
-
toSignInputs: UserToSignInput[];
|
|
599
1028
|
}): Promise<{
|
|
600
1029
|
txid: string;
|
|
601
1030
|
}>;
|
|
602
1031
|
setLastActiveTime(): void;
|
|
603
1032
|
getOpenInSidePanel(): Promise<boolean>;
|
|
604
1033
|
setOpenInSidePanel(openInSidePanel: boolean): Promise<void>;
|
|
605
|
-
|
|
1034
|
+
createSendBTCOffsetPsbt(tos: {
|
|
606
1035
|
address: string;
|
|
607
1036
|
satoshis: number;
|
|
608
|
-
}[], feeRate: number): Promise<
|
|
609
|
-
psbtHex: string;
|
|
610
|
-
rawtx: string;
|
|
611
|
-
fee: number;
|
|
612
|
-
}>;
|
|
1037
|
+
}[], feeRate: number, enableRBF?: boolean): Promise<ToSignData>;
|
|
613
1038
|
getAlkanesList(address: string, currentPage: number, pageSize: number): Promise<{
|
|
614
1039
|
currentPage: number;
|
|
615
1040
|
pageSize: number;
|
|
@@ -618,30 +1043,14 @@ interface WalletController {
|
|
|
618
1043
|
}>;
|
|
619
1044
|
getAssetUtxosAlkanes(rune: string): Promise<UnspentOutput[]>;
|
|
620
1045
|
getAddressAlkanesTokenSummary(address: string, alkaneid: string, fetchAvailable: boolean): Promise<AddressAlkanesTokenSummary>;
|
|
621
|
-
|
|
622
|
-
userAddress: string;
|
|
623
|
-
userPubkey: string;
|
|
624
|
-
receiver: string;
|
|
625
|
-
alkaneid: string;
|
|
626
|
-
amount: string;
|
|
627
|
-
feeRate: number;
|
|
628
|
-
}): Promise<{
|
|
629
|
-
psbtHex: string;
|
|
630
|
-
toSignInputs: UserToSignInput[];
|
|
631
|
-
}>;
|
|
632
|
-
signAlkanesSendTx(params: {
|
|
633
|
-
commitTx: string;
|
|
634
|
-
toSignInputs: ToSignInput[];
|
|
635
|
-
}): Promise<{
|
|
636
|
-
txid: string;
|
|
637
|
-
}>;
|
|
638
|
-
sendAlkanes(params: {
|
|
1046
|
+
createSendAlkanesPsbt(params: {
|
|
639
1047
|
to: string;
|
|
640
1048
|
alkaneid: string;
|
|
641
1049
|
amount: string;
|
|
642
1050
|
feeRate: number;
|
|
643
|
-
|
|
644
|
-
|
|
1051
|
+
type: 'ft' | 'nft';
|
|
1052
|
+
enableRBF?: boolean;
|
|
1053
|
+
}): Promise<ToSignData>;
|
|
645
1054
|
getAlkanesCollectionList(address: string, currentPage: number, pageSize: number): Promise<{
|
|
646
1055
|
list: AlkanesCollection[];
|
|
647
1056
|
total: number;
|
|
@@ -653,23 +1062,41 @@ interface WalletController {
|
|
|
653
1062
|
total: number;
|
|
654
1063
|
}>;
|
|
655
1064
|
getBRC20RecentHistory(address: string, ticker: string): Promise<BRC20HistoryItem[]>;
|
|
1065
|
+
resetAllData(): Promise<void>;
|
|
1066
|
+
getGuideReaded(): Promise<boolean>;
|
|
1067
|
+
setGuideReaded(): Promise<void>;
|
|
1068
|
+
getRateUsStatus(): Promise<RateUsStatus>;
|
|
1069
|
+
setHasRated(hasRated: boolean): Promise<void>;
|
|
1070
|
+
setRatePromptDismissedAt(timestamp: number | null): Promise<void>;
|
|
1071
|
+
setHasShownSecondPrompt(hasShown: boolean): Promise<void>;
|
|
1072
|
+
resetRateUsStatus(): Promise<void>;
|
|
1073
|
+
getAnnouncements(cursor: number, size: number): Promise<{
|
|
1074
|
+
hasMore: boolean;
|
|
1075
|
+
list: Announcement[];
|
|
1076
|
+
}>;
|
|
1077
|
+
getNotifications(): Promise<StoredNotification[]>;
|
|
1078
|
+
readNotification(id: string): Promise<void>;
|
|
1079
|
+
readAllNotifications(): Promise<void>;
|
|
1080
|
+
deleteNotification(id: string): Promise<void>;
|
|
1081
|
+
getNotificationUnreadCount(): Promise<number>;
|
|
1082
|
+
getAcceptLowFeeMode(): Promise<boolean>;
|
|
1083
|
+
setAcceptLowFeeMode(accept: boolean): Promise<void>;
|
|
1084
|
+
getEnableRBF(): Promise<boolean>;
|
|
1085
|
+
setEnableRBF(enableRBF: boolean): Promise<void>;
|
|
1086
|
+
createTmpKeyringWithPublicKey(publicKey: string, addressType: AddressType): Promise<WalletKeyring>;
|
|
1087
|
+
createKeyringWithPublicKey(data: string, addressType: AddressType): Promise<void>;
|
|
1088
|
+
createTmpKeyringWithAddress(address: string): Promise<WalletKeyring>;
|
|
1089
|
+
createKeyringWithAddress(address: string): Promise<void>;
|
|
1090
|
+
createDummyPsbt(params: {
|
|
1091
|
+
txType: DummyTxType;
|
|
1092
|
+
}): Promise<ToSignData>;
|
|
656
1093
|
}
|
|
657
1094
|
declare const WalletProvider: ({ children, wallet, }: {
|
|
658
1095
|
children?: ReactNode;
|
|
659
1096
|
wallet: WalletController;
|
|
660
|
-
}) => JSX.Element;
|
|
1097
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
661
1098
|
declare const useWallet: () => WalletController;
|
|
662
1099
|
|
|
663
|
-
interface PriceContextType {
|
|
664
|
-
isLoadingCoinPrice: boolean;
|
|
665
|
-
coinPrice: CoinPrice;
|
|
666
|
-
refreshCoinPrice: () => void;
|
|
667
|
-
}
|
|
668
|
-
declare function usePrice(): PriceContextType;
|
|
669
|
-
declare function PriceProvider({ children }: {
|
|
670
|
-
children: ReactNode;
|
|
671
|
-
}): JSX.Element;
|
|
672
|
-
|
|
673
1100
|
declare function useAccountsState(): AppState['accounts'];
|
|
674
1101
|
declare function useCurrentAccount(): Account;
|
|
675
1102
|
declare function useCurrentAddress(): string;
|
|
@@ -699,17 +1126,9 @@ declare function useChangeAddressFlagCallback(): (isAdd: boolean, flag: number)
|
|
|
699
1126
|
declare function useFetchBalanceCallback(): () => Promise<void>;
|
|
700
1127
|
declare function useReloadAccounts(): () => Promise<void>;
|
|
701
1128
|
declare function useIsKeystoneWallet(): boolean;
|
|
1129
|
+
declare function useModelPopover(): MolelsPopover;
|
|
702
1130
|
|
|
703
|
-
|
|
704
|
-
isTab: boolean;
|
|
705
|
-
isNotification: boolean;
|
|
706
|
-
isPop: boolean;
|
|
707
|
-
isSidePanel: boolean;
|
|
708
|
-
};
|
|
709
|
-
declare const getUiType: () => UiTypeCheck;
|
|
710
|
-
declare const useApproval: () => readonly [() => Promise<any>, (data?: any, stay?: boolean, forceReject?: boolean) => Promise<void>, (err: any, stay?: boolean, isInternal?: boolean) => Promise<void>];
|
|
711
|
-
|
|
712
|
-
declare const useAppDispatch: () => _reduxjs_toolkit.ThunkDispatch<{
|
|
1131
|
+
declare const useAppDispatch: () => redux_thunk.ThunkDispatch<{
|
|
713
1132
|
accounts: AccountsState;
|
|
714
1133
|
transactions: TransactionsState;
|
|
715
1134
|
settings: SettingsState;
|
|
@@ -717,7 +1136,8 @@ declare const useAppDispatch: () => _reduxjs_toolkit.ThunkDispatch<{
|
|
|
717
1136
|
keyrings: KeyringsState;
|
|
718
1137
|
ui: UIState;
|
|
719
1138
|
discovery: DiscoveryState;
|
|
720
|
-
|
|
1139
|
+
browser: BrowserState;
|
|
1140
|
+
}, undefined, redux.AnyAction> & redux.Dispatch<redux.AnyAction>;
|
|
721
1141
|
declare const useAppSelector: TypedUseSelectorHook<AppState>;
|
|
722
1142
|
|
|
723
1143
|
declare function useDiscoveryState(): AppState['discovery'];
|
|
@@ -738,34 +1158,44 @@ declare function useHasNewBanner(): boolean;
|
|
|
738
1158
|
|
|
739
1159
|
declare function useGlobalState(): AppState['global'];
|
|
740
1160
|
declare function useTab(): TabOption;
|
|
1161
|
+
declare function useScreenState(): {
|
|
1162
|
+
type: string;
|
|
1163
|
+
options: any;
|
|
1164
|
+
};
|
|
1165
|
+
declare function useUpdateScreenStateCallback(): (screenState: Partial<AppState['global']['screenState']>) => void;
|
|
741
1166
|
declare function useSetTabCallback(): (tab: TabOption) => void;
|
|
742
1167
|
declare function useBooted(): boolean;
|
|
743
1168
|
declare function useIsUnlocked(): boolean;
|
|
744
1169
|
declare function useIsReady(): boolean;
|
|
1170
|
+
declare function useIsRefresh(): boolean;
|
|
1171
|
+
declare function useBackRefresh(): boolean;
|
|
1172
|
+
declare function useWallRefresh(): boolean;
|
|
1173
|
+
declare function useWallTabRefresh(): boolean;
|
|
1174
|
+
declare function useWallTabFocusRefresh(): 0;
|
|
1175
|
+
declare function useGoBackRefresh(): 0;
|
|
1176
|
+
declare function useLayerState(): boolean;
|
|
1177
|
+
declare function useUnlockRefresh(): boolean;
|
|
1178
|
+
declare function useUnlockRead(): boolean;
|
|
1179
|
+
declare function useIsUnlockTimeRefres(): boolean;
|
|
1180
|
+
declare function useInfiniteListScrollOffset(): number;
|
|
1181
|
+
declare function useInfiniteListScrollState(): {
|
|
1182
|
+
offset: number;
|
|
1183
|
+
direction: "up" | "down";
|
|
1184
|
+
activeTime: number;
|
|
1185
|
+
};
|
|
1186
|
+
declare function useIsScrollViewTop(): number;
|
|
1187
|
+
declare function useIsScrollViewBot(): number;
|
|
1188
|
+
declare function useIsBiometricsSupported(): boolean;
|
|
1189
|
+
declare function useHasBiometricsKey(): boolean;
|
|
1190
|
+
declare function useSwitchChainModalVisible(): boolean;
|
|
1191
|
+
declare function useSetLockedOverlayVisibleCallback(): (visible: boolean) => void;
|
|
1192
|
+
declare function useLockedOverlayVisible(): boolean;
|
|
1193
|
+
declare function useLockCallback(): () => Promise<void>;
|
|
745
1194
|
declare function useUnlockCallback(): (password: string) => Promise<void>;
|
|
746
|
-
declare function useCreateAccountCallback(): (mnemonics: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount: number) => Promise<void>;
|
|
1195
|
+
declare function useCreateAccountCallback(): (mnemonics: string, hdPath: string, passphrase: string, addressType: AddressType, accountCount: number, accountIndexDerivation?: boolean) => Promise<void>;
|
|
747
1196
|
declare function useImportAccountsFromKeystoneCallback(): (urType: string, urCbor: string, addressType: AddressType, accountCount: number, hdPath: string, filterPubkey?: string[], connectionType?: 'USB' | 'QR') => Promise<void>;
|
|
748
1197
|
declare function useCreateColdWalletCallback(): (xpub: string, addressType: AddressType, alianName?: string, hdPath?: string, accountCount?: number) => Promise<void>;
|
|
749
1198
|
|
|
750
|
-
/**
|
|
751
|
-
* Use i18n Hook
|
|
752
|
-
* @returns i18n context
|
|
753
|
-
*/
|
|
754
|
-
declare const useI18n: () => any;
|
|
755
|
-
/**
|
|
756
|
-
* Get current language
|
|
757
|
-
* @returns current language code
|
|
758
|
-
*/
|
|
759
|
-
declare const getCurrentLocale: () => Promise<string>;
|
|
760
|
-
/**
|
|
761
|
-
* Select special languages for style adaptation
|
|
762
|
-
* @returns { currentLocale: string, isSpecialLocale: boolean }
|
|
763
|
-
*/
|
|
764
|
-
declare const getSpecialLocale: () => Promise<{
|
|
765
|
-
currentLocale: string;
|
|
766
|
-
isSpecialLocale: boolean;
|
|
767
|
-
}>;
|
|
768
|
-
|
|
769
1199
|
declare function useKeyringsState(): AppState['keyrings'];
|
|
770
1200
|
declare function useKeyrings(): _unisat_wallet_shared.WalletKeyring[];
|
|
771
1201
|
declare function useCurrentKeyring(): _unisat_wallet_shared.WalletKeyring;
|
|
@@ -783,7 +1213,11 @@ declare function useTxExplorerUrl(txid: string): string;
|
|
|
783
1213
|
declare function useGetTxExplorerUrlCallback(): (txid: string) => string;
|
|
784
1214
|
declare function useAddressExplorerUrl(address: string): string;
|
|
785
1215
|
declare function useCAT20TokenInfoExplorerUrl(version: CAT_VERSION, tokenId: string): string;
|
|
1216
|
+
declare function useBRC20TokenInfoExplorerUrl(ticker: string): string;
|
|
1217
|
+
declare function useRunesTokenInfoExplorerUrl(runeId: string): string;
|
|
1218
|
+
declare function useAlkanesTokenInfoExplorerUrl(alkaneId: string): string;
|
|
786
1219
|
declare function useUnisatWebsite(): string;
|
|
1220
|
+
declare function useIconBaseUrl(): string;
|
|
787
1221
|
declare function useOrdinalsWebsite(): string;
|
|
788
1222
|
declare function useWalletConfig(): _unisat_wallet_shared.WalletConfig;
|
|
789
1223
|
declare function useVersionInfo(): {
|
|
@@ -791,21 +1225,16 @@ declare function useVersionInfo(): {
|
|
|
791
1225
|
newVersion: string;
|
|
792
1226
|
latestVersion: string;
|
|
793
1227
|
skipped: boolean;
|
|
1228
|
+
downloadUrl: string;
|
|
1229
|
+
isNewest: boolean;
|
|
794
1230
|
};
|
|
795
1231
|
declare function useSkipVersionCallback(): (version: string) => void;
|
|
796
1232
|
declare function useAutoLockTimeId(): number;
|
|
797
|
-
declare function getAddressTips(address: string, chanEnum: ChainType): {
|
|
798
|
-
homeTip: string;
|
|
799
|
-
sendTip: string;
|
|
800
|
-
};
|
|
801
1233
|
declare function useAddressTips(): {
|
|
802
1234
|
homeTip: string;
|
|
803
1235
|
sendTip: string;
|
|
804
1236
|
};
|
|
805
1237
|
declare function useCAT721NFTContentBaseUrl(version: CAT_VERSION): "" | "https://tracker-fractal-mainnet.catprotocol.org" | "https://tracker2-fractal-mainnet.catprotocol.org" | "https://tracker-fractal-testnet.catprotocol.org";
|
|
806
|
-
declare function useBRC20MarketPlaceWebsite(ticker: string): string;
|
|
807
|
-
declare function useRunesMarketPlaceWebsite(ticker: string): string;
|
|
808
|
-
declare function useCAT20MarketPlaceWebsite(tokenId: string): string;
|
|
809
1238
|
declare function useBabylonConfig(): _unisat_babylon_service_types.BabylonConfig;
|
|
810
1239
|
declare function useIsMainnetChain(): boolean;
|
|
811
1240
|
declare function useDeveloperMode(): boolean;
|
|
@@ -813,20 +1242,21 @@ declare function useSetDeveloperModeCallback(): (developerMode: boolean) => Prom
|
|
|
813
1242
|
|
|
814
1243
|
declare function useTransactionsState(): AppState['transactions'];
|
|
815
1244
|
declare function useBitcoinTx(): BitcoinTx;
|
|
816
|
-
declare function usePrepareSendBTCCallback(): ({ toAddressInfo, toAmount, feeRate,
|
|
1245
|
+
declare function usePrepareSendBTCCallback(): ({ toAddressInfo, toAmount, feeRate, memo, memos, disableAutoAdjust, enableRBF, }: {
|
|
817
1246
|
toAddressInfo: ToAddressInfo;
|
|
818
1247
|
toAmount: number;
|
|
819
1248
|
feeRate?: number;
|
|
820
|
-
enableRBF: boolean;
|
|
821
1249
|
memo?: string;
|
|
822
1250
|
memos?: string[];
|
|
823
1251
|
disableAutoAdjust?: boolean;
|
|
824
|
-
|
|
825
|
-
|
|
1252
|
+
enableRBF?: boolean;
|
|
1253
|
+
}) => Promise<ToSignData>;
|
|
1254
|
+
declare function usePrepareSendBypassHeadOffsetsCallback(): ({ toAddressInfo, toAmount, feeRate, enableRBF, }: {
|
|
826
1255
|
toAddressInfo: ToAddressInfo;
|
|
827
1256
|
toAmount: number;
|
|
828
1257
|
feeRate: number;
|
|
829
|
-
|
|
1258
|
+
enableRBF?: boolean;
|
|
1259
|
+
}) => Promise<ToSignData>;
|
|
830
1260
|
declare function usePushBitcoinTxCallback(): (rawtx: string) => Promise<{
|
|
831
1261
|
success: boolean;
|
|
832
1262
|
txid: string;
|
|
@@ -838,23 +1268,20 @@ declare function usePrepareSendOrdinalsInscriptionCallback(): ({ toAddressInfo,
|
|
|
838
1268
|
inscriptionId: string;
|
|
839
1269
|
feeRate?: number;
|
|
840
1270
|
outputValue?: number;
|
|
841
|
-
enableRBF
|
|
842
|
-
}) => Promise<
|
|
1271
|
+
enableRBF?: boolean;
|
|
1272
|
+
}) => Promise<ToSignData>;
|
|
843
1273
|
declare function usePrepareSendOrdinalsInscriptionsCallback(): ({ toAddressInfo, inscriptionIds, feeRate, enableRBF, }: {
|
|
844
1274
|
toAddressInfo: ToAddressInfo;
|
|
845
1275
|
inscriptionIds: string[];
|
|
846
1276
|
feeRate?: number;
|
|
847
|
-
enableRBF
|
|
848
|
-
}) => Promise<
|
|
1277
|
+
enableRBF?: boolean;
|
|
1278
|
+
}) => Promise<ToSignData>;
|
|
849
1279
|
declare function useCreateSplitTxCallback(): ({ inscriptionId, feeRate, outputValue, enableRBF, }: {
|
|
850
1280
|
inscriptionId: string;
|
|
851
1281
|
feeRate: number;
|
|
852
1282
|
outputValue: number;
|
|
853
|
-
enableRBF
|
|
854
|
-
}) => Promise<
|
|
855
|
-
rawTxInfo: RawTxInfo;
|
|
856
|
-
splitedCount: number;
|
|
857
|
-
}>;
|
|
1283
|
+
enableRBF?: boolean;
|
|
1284
|
+
}) => Promise<ToSignData>;
|
|
858
1285
|
declare function usePushOrdinalsTxCallback(): (rawtx: string) => Promise<{
|
|
859
1286
|
success: boolean;
|
|
860
1287
|
txid: string;
|
|
@@ -873,16 +1300,17 @@ declare function usePrepareSendRunesCallback(): ({ toAddressInfo, runeid, runeAm
|
|
|
873
1300
|
runeAmount: string;
|
|
874
1301
|
outputValue?: number;
|
|
875
1302
|
feeRate: number;
|
|
876
|
-
enableRBF
|
|
877
|
-
}) => Promise<
|
|
1303
|
+
enableRBF?: boolean;
|
|
1304
|
+
}) => Promise<ToSignData>;
|
|
878
1305
|
declare function useRunesTx(): RunesTx;
|
|
879
|
-
declare function usePrepareSendAlkanesCallback(): (toAddressInfo: ToAddressInfo, alkaneid: string, amount: string, feeRate: number, enableRBF?: boolean) => Promise<
|
|
1306
|
+
declare function usePrepareSendAlkanesCallback(): (toAddressInfo: ToAddressInfo, alkaneid: string, amount: string, feeRate: number, type: 'ft' | 'nft', enableRBF?: boolean) => Promise<ToSignData>;
|
|
880
1307
|
|
|
881
1308
|
declare function useUIState(): AppState['ui'];
|
|
882
1309
|
declare function useAssetTabKey(): AssetTabKey;
|
|
883
1310
|
declare function useOrdinalsAssetTabKey(): OrdinalsAssetTabKey;
|
|
884
1311
|
declare function useCATAssetTabKey(): CATAssetTabKey;
|
|
885
1312
|
declare function useAlkanesAssetTabKey(): AlkanesAssetTabKey;
|
|
1313
|
+
declare function useMoreAssetTabKey(): MoreAssetTabKey;
|
|
886
1314
|
declare function useUiTxCreateScreen(): {
|
|
887
1315
|
toInfo: {
|
|
888
1316
|
address: string;
|
|
@@ -891,9 +1319,8 @@ declare function useUiTxCreateScreen(): {
|
|
|
891
1319
|
};
|
|
892
1320
|
inputAmount: string;
|
|
893
1321
|
enableRBF: boolean;
|
|
894
|
-
feeRate: number;
|
|
895
1322
|
};
|
|
896
|
-
declare function useUpdateUiTxCreateScreen(): ({ toInfo, inputAmount, enableRBF,
|
|
1323
|
+
declare function useUpdateUiTxCreateScreen(): ({ toInfo, inputAmount, enableRBF, }: {
|
|
897
1324
|
toInfo?: {
|
|
898
1325
|
address: string;
|
|
899
1326
|
domain: string;
|
|
@@ -901,46 +1328,1492 @@ declare function useUpdateUiTxCreateScreen(): ({ toInfo, inputAmount, enableRBF,
|
|
|
901
1328
|
};
|
|
902
1329
|
inputAmount?: string;
|
|
903
1330
|
enableRBF?: boolean;
|
|
1331
|
+
}) => void;
|
|
1332
|
+
declare function useFeeRateBar(): {
|
|
1333
|
+
feeRate: number;
|
|
1334
|
+
feeRateInputVal: string;
|
|
1335
|
+
enableLowFeeRate: boolean;
|
|
1336
|
+
feeOptionIndex: number;
|
|
1337
|
+
showCustomInput: boolean;
|
|
1338
|
+
};
|
|
1339
|
+
declare function useUpdateFeeRateBar(): ({ feeRate, feeRateInputVal, enableLowFeeRate, feeOptionIndex, showCustomInput, }: {
|
|
904
1340
|
feeRate?: number;
|
|
1341
|
+
feeRateInputVal?: string;
|
|
1342
|
+
enableLowFeeRate?: boolean;
|
|
1343
|
+
feeOptionIndex?: number;
|
|
1344
|
+
showCustomInput?: boolean;
|
|
1345
|
+
}) => void;
|
|
1346
|
+
declare function useResetFeeRateBar(): () => void;
|
|
1347
|
+
declare function useAddressInput(): {
|
|
1348
|
+
address: string;
|
|
1349
|
+
domain: string;
|
|
1350
|
+
inscription?: Inscription;
|
|
1351
|
+
};
|
|
1352
|
+
declare function useUpdateAddressInput(): ({ address, domain }: {
|
|
1353
|
+
address?: string;
|
|
1354
|
+
domain?: string;
|
|
1355
|
+
}) => void;
|
|
1356
|
+
declare function useResetAddressInput(): () => void;
|
|
1357
|
+
declare function useAmountInput(): {
|
|
1358
|
+
amount: string;
|
|
1359
|
+
};
|
|
1360
|
+
declare function useUpdateAmountInput(): ({ amount }: {
|
|
1361
|
+
amount?: string;
|
|
905
1362
|
}) => void;
|
|
1363
|
+
declare function useResetAmountInput(): () => void;
|
|
1364
|
+
declare function useResetTxState(): () => void;
|
|
906
1365
|
declare function useResetUiTxCreateScreen(): () => void;
|
|
907
|
-
declare
|
|
1366
|
+
declare const useThrottle: (callback: any, delay: any, lastCallRef: any) => (...args: any[]) => void;
|
|
1367
|
+
declare function getSupportedAssets(chainType: ChainType, address: string): {
|
|
1368
|
+
assets: {
|
|
1369
|
+
ordinals: boolean;
|
|
1370
|
+
runes: boolean;
|
|
1371
|
+
CAT20: boolean;
|
|
1372
|
+
alkanes: boolean;
|
|
1373
|
+
brc20Prog: boolean;
|
|
1374
|
+
};
|
|
908
1375
|
tabKeys: AssetTabKey[];
|
|
1376
|
+
key: string;
|
|
1377
|
+
};
|
|
1378
|
+
declare function useSupportedAssets(): {
|
|
909
1379
|
assets: {
|
|
910
1380
|
ordinals: boolean;
|
|
911
1381
|
runes: boolean;
|
|
912
1382
|
CAT20: boolean;
|
|
913
1383
|
alkanes: boolean;
|
|
1384
|
+
brc20Prog: boolean;
|
|
914
1385
|
};
|
|
1386
|
+
tabKeys: AssetTabKey[];
|
|
915
1387
|
key: string;
|
|
916
1388
|
};
|
|
917
1389
|
declare const useIsInExpandView: () => boolean;
|
|
918
|
-
declare
|
|
919
|
-
|
|
1390
|
+
declare function useWalletTopTabScreenState(): {
|
|
1391
|
+
toptabKey: WallettopTabScreenTabKey;
|
|
1392
|
+
};
|
|
1393
|
+
declare function useBRC20IconInfo(ticker: string): {
|
|
1394
|
+
iconUrl: string;
|
|
1395
|
+
iconShortName: string;
|
|
1396
|
+
};
|
|
1397
|
+
declare function useRunesIconInfo(spacedRune: string): {
|
|
1398
|
+
iconUrl: string;
|
|
1399
|
+
iconShortName: string;
|
|
1400
|
+
};
|
|
1401
|
+
declare function useAlkanesIconInfo(name: string, alkaneid: string): {
|
|
1402
|
+
iconUrl: string;
|
|
1403
|
+
iconShortName: string;
|
|
1404
|
+
};
|
|
1405
|
+
declare function useCAT20IconInfo(name: string, tokenId: string): {
|
|
1406
|
+
iconUrl: string;
|
|
1407
|
+
iconShortName: string;
|
|
1408
|
+
};
|
|
1409
|
+
declare function useBRC20MarketPlaceWebsite(ticker: string): string;
|
|
1410
|
+
declare function useRunesMarketUrl(ticker: string): string;
|
|
1411
|
+
declare function useAlkanesMarketPlaceWebsite(alkaneid: string): string;
|
|
1412
|
+
declare function useCAT20MarketPlaceWebsite(tokenId: string): string;
|
|
1413
|
+
declare function useRunesInscribeUrl(rune: string): string;
|
|
1414
|
+
declare function useBalanceCardDetailExpanded(): boolean;
|
|
1415
|
+
declare function useToggleBalanceCardDetailExpanded(): () => void;
|
|
1416
|
+
|
|
1417
|
+
declare function useBrowserState(): AppState['browser'];
|
|
1418
|
+
declare function useWalletTabScreenState(): {
|
|
1419
|
+
tabKey: {
|
|
1420
|
+
if?: boolean;
|
|
1421
|
+
url: string;
|
|
1422
|
+
};
|
|
1423
|
+
riskIf: boolean;
|
|
1424
|
+
collect: any;
|
|
1425
|
+
historyList: any;
|
|
1426
|
+
suspension: {
|
|
1427
|
+
suspensionIf: boolean;
|
|
1428
|
+
info: any;
|
|
1429
|
+
web: any;
|
|
1430
|
+
};
|
|
1431
|
+
yy: any;
|
|
1432
|
+
riseHeight: number;
|
|
1433
|
+
ScanData: string;
|
|
1434
|
+
amountValue: string;
|
|
1435
|
+
guideList: {
|
|
1436
|
+
id: number;
|
|
1437
|
+
title: string;
|
|
1438
|
+
content: string;
|
|
1439
|
+
img: string;
|
|
1440
|
+
}[];
|
|
1441
|
+
popUp: boolean;
|
|
1442
|
+
setStatusBar: boolean;
|
|
1443
|
+
i18Class: string;
|
|
1444
|
+
setSessionDate: setSessionDateProps;
|
|
1445
|
+
webViewLod: boolean;
|
|
920
1446
|
};
|
|
921
|
-
declare function useLocationState<T>(): T;
|
|
922
1447
|
|
|
923
1448
|
declare function AccountUpdater(): any;
|
|
924
1449
|
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
1450
|
+
interface AddressTypeItem {
|
|
1451
|
+
address: string;
|
|
1452
|
+
assets: {
|
|
1453
|
+
total_btc: string;
|
|
1454
|
+
satoshis: number;
|
|
1455
|
+
total_inscription: number;
|
|
1456
|
+
};
|
|
1457
|
+
name: string;
|
|
1458
|
+
value: AddressType;
|
|
1459
|
+
}
|
|
1460
|
+
declare function useAddressTypeScreenLogic(): {
|
|
1461
|
+
currentKeyring: _unisat_wallet_shared.WalletKeyring;
|
|
1462
|
+
items: AddressTypeItem[];
|
|
1463
|
+
wallet: WalletController;
|
|
1464
|
+
onClickItem: (item: AddressTypeItem) => Promise<void>;
|
|
1465
|
+
};
|
|
1466
|
+
|
|
1467
|
+
declare function useAlkanesListLogic(): {
|
|
1468
|
+
items: AlkanesBalance[];
|
|
1469
|
+
total: number;
|
|
1470
|
+
loading: boolean;
|
|
1471
|
+
hasMore: boolean;
|
|
1472
|
+
onRefresh: () => Promise<void>;
|
|
1473
|
+
onLoadMore: () => void;
|
|
1474
|
+
onClickItem: (item: AlkanesBalance) => void;
|
|
1475
|
+
priceMap: {
|
|
1476
|
+
[key: string]: TickPriceItem;
|
|
1477
|
+
};
|
|
1478
|
+
};
|
|
1479
|
+
|
|
1480
|
+
declare function useAmountInputLogic(props: {
|
|
1481
|
+
value?: string;
|
|
1482
|
+
runesDecimal?: number;
|
|
1483
|
+
disableDecimal?: boolean;
|
|
1484
|
+
enableBrc20Decimal?: boolean;
|
|
1485
|
+
onAmountInputChange?: (amount: string) => void;
|
|
1486
|
+
min?: number;
|
|
1487
|
+
step?: number;
|
|
1488
|
+
}): {
|
|
1489
|
+
handleInputAmount: (e: {
|
|
1490
|
+
target: {
|
|
1491
|
+
value: string;
|
|
1492
|
+
};
|
|
1493
|
+
} | string) => void;
|
|
1494
|
+
handleStepUp: () => void;
|
|
1495
|
+
handleStepDown: () => void;
|
|
1496
|
+
handleReset: () => void;
|
|
1497
|
+
inputValue: string;
|
|
1498
|
+
};
|
|
1499
|
+
|
|
1500
|
+
declare function useAnnouncementCardLogic(): {
|
|
1501
|
+
loading: boolean;
|
|
1502
|
+
validAnnouncements: Announcement[];
|
|
1503
|
+
current: Announcement;
|
|
1504
|
+
activeIndex: number;
|
|
1505
|
+
handleDotClick: (index: number) => void;
|
|
1506
|
+
handleDismissAll: () => Promise<void>;
|
|
1507
|
+
isLinkable: (announcement: Announcement) => boolean;
|
|
1508
|
+
};
|
|
1509
|
+
|
|
1510
|
+
declare enum BRC20SendTabKey {
|
|
1511
|
+
STEP1 = 0,
|
|
1512
|
+
STEP2 = 1,
|
|
1513
|
+
STEP3 = 2
|
|
1514
|
+
}
|
|
1515
|
+
interface ContextData$2 {
|
|
1516
|
+
tabKey: BRC20SendTabKey;
|
|
1517
|
+
tokenBalance: TokenBalance;
|
|
1518
|
+
transferAmount: string;
|
|
1519
|
+
transferableList: TokenTransfer[];
|
|
1520
|
+
inscriptionIdSet: Set<string>;
|
|
1521
|
+
receiver: string;
|
|
1522
|
+
enableRBF: boolean;
|
|
1523
|
+
rawTxInfo: RawTxInfo;
|
|
1524
|
+
tokenInfo: TokenInfo;
|
|
1525
|
+
}
|
|
1526
|
+
interface UpdateContextDataParams$2 {
|
|
1527
|
+
tabKey?: BRC20SendTabKey;
|
|
1528
|
+
tokenBalance?: TokenBalance;
|
|
1529
|
+
transferAmount?: string;
|
|
1530
|
+
transferableList?: TokenTransfer[];
|
|
1531
|
+
inscriptionIdSet?: Set<string>;
|
|
1532
|
+
receiver?: string;
|
|
1533
|
+
enableRBF?: boolean;
|
|
1534
|
+
rawTxInfo?: RawTxInfo;
|
|
1535
|
+
}
|
|
1536
|
+
interface BRC20SendStepParams {
|
|
1537
|
+
contextData: ContextData$2;
|
|
1538
|
+
updateContextData: (params: UpdateContextDataParams$2) => void;
|
|
1539
|
+
}
|
|
1540
|
+
declare function useBRC20SendScreenLogic(): {
|
|
1541
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1542
|
+
contextData: ContextData$2;
|
|
1543
|
+
updateContextData: (params: UpdateContextDataParams$2) => void;
|
|
1544
|
+
onHeaderBack: () => void;
|
|
1545
|
+
onTabClick: (key: string) => void;
|
|
1546
|
+
};
|
|
1547
|
+
declare function useBRC20SendScreenLogicStep1({ contextData, updateContextData, }: BRC20SendStepParams): {
|
|
1548
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1549
|
+
disabled: boolean;
|
|
1550
|
+
tokenBalance: TokenBalance;
|
|
1551
|
+
onClickNext: () => void;
|
|
1552
|
+
};
|
|
1553
|
+
declare function useBRC20SendScreenLogicStep2({ contextData, updateContextData, }: BRC20SendStepParams): {
|
|
1554
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1555
|
+
disabled: boolean;
|
|
1556
|
+
onStep2ClickNext: () => Promise<void>;
|
|
1557
|
+
onStep2ClickBack: () => Promise<void>;
|
|
1558
|
+
};
|
|
1559
|
+
declare function useBRC20SendScreenLogicStep3({ contextData, updateContextData, }: BRC20SendStepParams): {
|
|
1560
|
+
signPsbtParams: SignPsbtParams;
|
|
1561
|
+
onSignPsbtConfirm: (res: any) => Promise<void>;
|
|
1562
|
+
};
|
|
1563
|
+
declare function useTransferableListLogic({ contextData, updateContextData }: BRC20SendStepParams): {
|
|
1564
|
+
items: TokenTransfer[];
|
|
1565
|
+
selectedCount: number;
|
|
1566
|
+
allSelected: boolean;
|
|
1567
|
+
loading: boolean;
|
|
1568
|
+
loadingLump: boolean;
|
|
1569
|
+
onClickItem: (item: TokenTransfer) => void;
|
|
1570
|
+
onCheckBoxChange: (e: any) => void;
|
|
1571
|
+
onClickCheckBoxInMobile: () => void;
|
|
1572
|
+
onClickRefresh: () => void;
|
|
1573
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1574
|
+
};
|
|
1575
|
+
|
|
1576
|
+
declare enum BRC20SingleStepKey {
|
|
1577
|
+
STEP1 = "STEP1",
|
|
1578
|
+
STEP2 = "STEP2",
|
|
1579
|
+
STEP3 = "STEP3"
|
|
1580
|
+
}
|
|
1581
|
+
declare function useBRC20SingleStepScreenLogic(): {
|
|
1582
|
+
signPsbtParamsStep2: SignPsbtParams;
|
|
1583
|
+
signPsbtParamsStep3: SignPsbtParams;
|
|
1584
|
+
availableBalance: string;
|
|
1585
|
+
tokenBalance: _unisat_wallet_shared.TokenBalance;
|
|
1586
|
+
tokenInfo: _unisat_wallet_shared.TokenInfo;
|
|
1587
|
+
inputAmount: string;
|
|
1588
|
+
setInputAmount: react.Dispatch<react.SetStateAction<string>>;
|
|
1589
|
+
disabled: boolean;
|
|
1590
|
+
error: string;
|
|
1591
|
+
toInfo: {
|
|
1592
|
+
address: string;
|
|
1593
|
+
domain: string;
|
|
1594
|
+
inscription?: Inscription;
|
|
1595
|
+
};
|
|
1596
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
1597
|
+
address: string;
|
|
1598
|
+
domain: string;
|
|
1599
|
+
inscription?: Inscription;
|
|
1600
|
+
}>>;
|
|
1601
|
+
step: BRC20SingleStepKey;
|
|
1602
|
+
onClickBack: () => void;
|
|
1603
|
+
onClickConfirmStep1: () => Promise<void>;
|
|
1604
|
+
onClickConfirmStep2: (signPsbtResult: SignPsbtResult) => Promise<void>;
|
|
1605
|
+
onClickConfirmStep3: (signPsbtResult: SignPsbtResult) => Promise<void>;
|
|
1606
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1607
|
+
tools: ToolsContextType;
|
|
1608
|
+
};
|
|
1609
|
+
|
|
1610
|
+
declare enum BRC20TokenScreenTabKey {
|
|
1611
|
+
DETAILS = "details",
|
|
1612
|
+
HISTORY = "history"
|
|
1613
|
+
}
|
|
1614
|
+
interface BRC20OutWalletBalanceItem {
|
|
1615
|
+
key: 'wallet' | 'swap' | 'prog';
|
|
1616
|
+
label: string;
|
|
1617
|
+
amount: string;
|
|
1618
|
+
}
|
|
1619
|
+
declare function useBRC20TokenHistoryLogic(props: {
|
|
1620
|
+
ticker: string;
|
|
1621
|
+
displayName?: string;
|
|
1622
|
+
}): {
|
|
1623
|
+
displayItems: {
|
|
1624
|
+
date: string;
|
|
1625
|
+
items: {
|
|
1626
|
+
key: string;
|
|
1627
|
+
icon: string;
|
|
1628
|
+
mainTitle: string;
|
|
1629
|
+
subTitle: string;
|
|
1630
|
+
amount: string;
|
|
1631
|
+
pending: boolean;
|
|
1632
|
+
txid: string;
|
|
1633
|
+
}[];
|
|
1634
|
+
}[];
|
|
1635
|
+
isFailed: boolean;
|
|
1636
|
+
isEmpty: boolean;
|
|
1637
|
+
isLoading: boolean;
|
|
1638
|
+
};
|
|
1639
|
+
declare function useBRC20TokenScreenLogic(): {
|
|
1640
|
+
totalBalance: string;
|
|
1641
|
+
onSwapBalance: string;
|
|
1642
|
+
onProgBalance: string;
|
|
1643
|
+
inWalletBalance: string;
|
|
1644
|
+
outWalletBalanceItems: BRC20OutWalletBalanceItem[];
|
|
1645
|
+
enableHistory: boolean;
|
|
1646
|
+
enableTrade: boolean;
|
|
1647
|
+
enableMint: boolean;
|
|
1648
|
+
enableTransfer: boolean;
|
|
1649
|
+
loading: boolean;
|
|
1650
|
+
tokenSummary: AddressTokenSummary;
|
|
1651
|
+
deployInscription: Inscription;
|
|
1652
|
+
activeTab: BRC20TokenScreenTabKey;
|
|
1653
|
+
setActiveTab: react.Dispatch<react.SetStateAction<BRC20TokenScreenTabKey>>;
|
|
1654
|
+
tabItems: {
|
|
1655
|
+
key: BRC20TokenScreenTabKey;
|
|
1656
|
+
label: string;
|
|
1657
|
+
}[];
|
|
1658
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1659
|
+
ticker: string;
|
|
1660
|
+
chain: _unisat_wallet_shared.TypeChain;
|
|
1661
|
+
tools: ToolsContextType;
|
|
1662
|
+
isBrc20Prog: boolean;
|
|
1663
|
+
iconInfo: {
|
|
1664
|
+
iconUrl: string;
|
|
1665
|
+
iconShortName: string;
|
|
1666
|
+
};
|
|
1667
|
+
showProgBalance: boolean;
|
|
1668
|
+
showSwapBalance: boolean;
|
|
1669
|
+
onClickWrapBrc20Prog: () => void;
|
|
1670
|
+
onClickUnwrapBrc20Prog: () => void;
|
|
1671
|
+
onClickSendBrc20Prog: () => void;
|
|
1672
|
+
onClickSwapInSwap: () => void;
|
|
1673
|
+
onClickAddLiquidityInSwap: () => void;
|
|
1674
|
+
onClickWrapInSwap: () => void;
|
|
1675
|
+
onClickUnwrapInSwap: () => void;
|
|
1676
|
+
onClickSendInSwap: () => void;
|
|
1677
|
+
onClickMint: () => void;
|
|
1678
|
+
onClickSend: () => void;
|
|
1679
|
+
onClickTrade: () => void;
|
|
1680
|
+
onClickSingleStepSend: () => void;
|
|
1681
|
+
};
|
|
1682
|
+
|
|
1683
|
+
declare function useEditWalletNameScreenLogic(): {
|
|
1684
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1685
|
+
keyring: _unisat_wallet_shared.WalletKeyring;
|
|
1686
|
+
isValidName: boolean;
|
|
1687
|
+
truncatedTitle: string;
|
|
1688
|
+
handleOnClick: () => Promise<void>;
|
|
1689
|
+
handleOnKeyUp: (e: React.KeyboardEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
1690
|
+
onInputChange: (e: {
|
|
1691
|
+
target: {
|
|
1692
|
+
value: string;
|
|
1693
|
+
};
|
|
1694
|
+
} | string) => void;
|
|
1695
|
+
};
|
|
942
1696
|
|
|
943
|
-
|
|
944
|
-
|
|
1697
|
+
declare enum FeeRateType {
|
|
1698
|
+
SLOW = 0,
|
|
1699
|
+
AVG = 1,
|
|
1700
|
+
FAST = 2,
|
|
1701
|
+
CUSTOM = 3
|
|
1702
|
+
}
|
|
1703
|
+
interface FeeOption {
|
|
1704
|
+
type?: FeeRateType;
|
|
1705
|
+
title: string;
|
|
1706
|
+
desc?: string;
|
|
1707
|
+
feeRate: number;
|
|
1708
|
+
}
|
|
1709
|
+
declare function useFeeRateBarLogic({ readonly }: {
|
|
1710
|
+
readonly?: boolean;
|
|
1711
|
+
}): {
|
|
1712
|
+
feeOptions: FeeOption[];
|
|
1713
|
+
feeOptionIndex: number;
|
|
1714
|
+
setFeeOptionIndex: (index: number) => Promise<void>;
|
|
1715
|
+
feeRateInputVal: string;
|
|
1716
|
+
adjustFeeRateInput: (inputVal: string) => void;
|
|
1717
|
+
isCustomOption: (option: FeeOption) => boolean;
|
|
1718
|
+
fontSize: string;
|
|
1719
|
+
isSpecialLocale: boolean;
|
|
1720
|
+
toggleLowFeeRate: () => Promise<void>;
|
|
1721
|
+
showCustomInput: boolean;
|
|
1722
|
+
toggleCustomInput: (show: boolean) => void;
|
|
1723
|
+
supportLowFeeMode: boolean;
|
|
1724
|
+
showLowFeeModeTipsPopover: boolean;
|
|
1725
|
+
setShowLowFeeModeTipsPopover: react.Dispatch<react.SetStateAction<boolean>>;
|
|
1726
|
+
isSub1FeeOptionOn: boolean;
|
|
1727
|
+
};
|
|
1728
|
+
|
|
1729
|
+
declare function useLockTimePageLogic(): {
|
|
1730
|
+
autoLockTimeId: number;
|
|
1731
|
+
autoLockTimes: {
|
|
1732
|
+
id: number;
|
|
1733
|
+
time: number;
|
|
1734
|
+
label: string;
|
|
1735
|
+
}[];
|
|
1736
|
+
loading: boolean;
|
|
1737
|
+
handleSelectOption: (option: any) => Promise<void>;
|
|
1738
|
+
};
|
|
1739
|
+
|
|
1740
|
+
declare function useUnreadNotificationsCount(): number;
|
|
1741
|
+
declare function useNotificationsLogic(): {
|
|
1742
|
+
notifications: StoredNotification[];
|
|
1743
|
+
loading: boolean;
|
|
1744
|
+
unreadCount: number;
|
|
1745
|
+
handleReadNotification: (id: string) => Promise<void>;
|
|
1746
|
+
handleReadAll: () => Promise<void>;
|
|
1747
|
+
handleDeleteNotification: (id: string) => Promise<void>;
|
|
1748
|
+
fetchNotifications: () => Promise<void>;
|
|
1749
|
+
handleCardClick: (notification: StoredNotification) => Promise<void>;
|
|
1750
|
+
formatTime: (timestamp: number) => string;
|
|
1751
|
+
};
|
|
1752
|
+
|
|
1753
|
+
declare function useSendOrdinalsInscriptionScreenLogic(): {
|
|
1754
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1755
|
+
onAddressInputChange: (val: any) => void;
|
|
1756
|
+
toInfo: {
|
|
1757
|
+
address: string;
|
|
1758
|
+
domain: string;
|
|
1759
|
+
};
|
|
1760
|
+
outputValue: number;
|
|
1761
|
+
enableRBF: boolean;
|
|
1762
|
+
setEnableRBF: (value: boolean) => void;
|
|
1763
|
+
minOutputValue: number;
|
|
1764
|
+
defaultOutputValue: number;
|
|
1765
|
+
setOutputValue: react.Dispatch<react.SetStateAction<number>>;
|
|
1766
|
+
inscriptions: Inscription[];
|
|
1767
|
+
disabled: boolean;
|
|
1768
|
+
error: string;
|
|
1769
|
+
onClickBack: () => void;
|
|
1770
|
+
onClickNext: () => void;
|
|
1771
|
+
};
|
|
1772
|
+
|
|
1773
|
+
declare function useTxCreateScreenLogic(): {
|
|
1774
|
+
headerTitle: string;
|
|
1775
|
+
chain: _unisat_wallet_shared.TypeChain;
|
|
1776
|
+
toInfo: {
|
|
1777
|
+
address: string;
|
|
1778
|
+
domain: string;
|
|
1779
|
+
inscription?: _unisat_wallet_shared.Inscription;
|
|
1780
|
+
};
|
|
1781
|
+
onAddressInputChange: (val: any) => void;
|
|
1782
|
+
toSatoshis: number;
|
|
1783
|
+
inputAmount: string;
|
|
1784
|
+
onAmountInputChange: (amount: any) => void;
|
|
1785
|
+
onAmountMaxClick: () => void;
|
|
1786
|
+
enableRBF: boolean;
|
|
1787
|
+
onRBFChange: (value: boolean) => void;
|
|
1788
|
+
showUnavailable: boolean;
|
|
1789
|
+
availableAmount: string;
|
|
1790
|
+
unavailableAmount: string;
|
|
1791
|
+
unavailableTipText: string;
|
|
1792
|
+
btcUnit: string;
|
|
1793
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1794
|
+
walletConfig: _unisat_wallet_shared.WalletConfig;
|
|
1795
|
+
isSpecialLocale: boolean;
|
|
1796
|
+
error: string;
|
|
1797
|
+
disabled: boolean;
|
|
1798
|
+
onClickNext: () => void;
|
|
1799
|
+
};
|
|
1800
|
+
|
|
1801
|
+
declare enum Step {
|
|
1802
|
+
STEP1 = 0,
|
|
1803
|
+
STEP2 = 1,
|
|
1804
|
+
STEP3 = 2,
|
|
1805
|
+
STEP4 = 3
|
|
1806
|
+
}
|
|
1807
|
+
interface ContextData$1 {
|
|
1808
|
+
step: Step;
|
|
1809
|
+
ticker: string;
|
|
1810
|
+
session?: any;
|
|
1811
|
+
tokenBalance?: TokenBalance;
|
|
1812
|
+
order?: InscribeOrder;
|
|
1813
|
+
toSignData?: ToSignData;
|
|
1814
|
+
amount?: string;
|
|
1815
|
+
isApproval: boolean;
|
|
1816
|
+
tokenInfo?: TokenInfo;
|
|
1817
|
+
amountEditable?: boolean;
|
|
1818
|
+
enableRBF: boolean;
|
|
1819
|
+
}
|
|
1820
|
+
interface UpdateContextDataParams$1 {
|
|
1821
|
+
step?: Step;
|
|
1822
|
+
ticket?: string;
|
|
1823
|
+
session?: any;
|
|
1824
|
+
tokenBalance?: TokenBalance;
|
|
1825
|
+
order?: InscribeOrder;
|
|
1826
|
+
toSignData?: ToSignData;
|
|
1827
|
+
amount?: string;
|
|
1828
|
+
tokenInfo?: TokenInfo;
|
|
1829
|
+
amountEditable?: boolean;
|
|
1830
|
+
enableRBF?: boolean;
|
|
1831
|
+
}
|
|
1832
|
+
interface BRC20InscribeTransferParams {
|
|
1833
|
+
contextData: ContextData$1;
|
|
1834
|
+
updateContextData: (params: UpdateContextDataParams$1) => void;
|
|
1835
|
+
}
|
|
1836
|
+
declare function useBRC20InscribeTransferLogic(): {
|
|
1837
|
+
contextData: ContextData$1;
|
|
1838
|
+
updateContextData: (params: UpdateContextDataParams$1) => void;
|
|
1839
|
+
};
|
|
1840
|
+
declare function useBRC20InscribeTransferLogicStep1(params: BRC20InscribeTransferParams): {
|
|
1841
|
+
onClickInscribe: () => Promise<void>;
|
|
1842
|
+
loading: boolean;
|
|
1843
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1844
|
+
nav: NavigationContextType;
|
|
1845
|
+
inputAmount: string;
|
|
1846
|
+
inputError: string;
|
|
1847
|
+
setInputAmount: react.Dispatch<react.SetStateAction<string>>;
|
|
1848
|
+
inputDisabled: boolean;
|
|
1849
|
+
inputErrorAvailable: string;
|
|
1850
|
+
defaultOutputValue: number;
|
|
1851
|
+
setOutputValue: react.Dispatch<react.SetStateAction<number>>;
|
|
1852
|
+
disabled: boolean;
|
|
1853
|
+
enableRBF: boolean;
|
|
1854
|
+
setEnableRBF: (value: boolean) => void;
|
|
1855
|
+
loadingOnly: boolean;
|
|
1856
|
+
handleCancel: () => void;
|
|
1857
|
+
};
|
|
1858
|
+
declare function useBRC20InscribeTransferLogicStep2(params: BRC20InscribeTransferParams): {
|
|
1859
|
+
isEmpty: boolean;
|
|
1860
|
+
networkFee: string;
|
|
1861
|
+
outputValue: string;
|
|
1862
|
+
minerFee: string;
|
|
1863
|
+
originServiceFee: string;
|
|
1864
|
+
serviceFee: string;
|
|
1865
|
+
totalFee: string;
|
|
1866
|
+
btcUnit: string;
|
|
1867
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1868
|
+
session: any;
|
|
1869
|
+
amount: string;
|
|
1870
|
+
tokenBalance: TokenBalance;
|
|
1871
|
+
order?: undefined;
|
|
1872
|
+
toSignData?: undefined;
|
|
1873
|
+
} | {
|
|
1874
|
+
networkFee: string;
|
|
1875
|
+
outputValue: string;
|
|
1876
|
+
minerFee: string;
|
|
1877
|
+
originServiceFee: string;
|
|
1878
|
+
serviceFee: string;
|
|
1879
|
+
totalFee: string;
|
|
1880
|
+
btcUnit: string;
|
|
1881
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1882
|
+
session: any;
|
|
1883
|
+
amount: string;
|
|
1884
|
+
tokenBalance: TokenBalance;
|
|
1885
|
+
order: InscribeOrder;
|
|
1886
|
+
toSignData: ToSignData;
|
|
1887
|
+
isEmpty?: undefined;
|
|
1888
|
+
};
|
|
1889
|
+
declare function useBRC20InscribeTransferLogicStep3(params: BRC20InscribeTransferParams): {
|
|
1890
|
+
signPsbtParams: SignPsbtParams;
|
|
1891
|
+
onSignPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
1892
|
+
onSignPsbtHandleCancel: () => void;
|
|
1893
|
+
onHeaderBack: () => void;
|
|
1894
|
+
};
|
|
1895
|
+
declare function useBRC20InscribeTransferLogicStep4(params: BRC20InscribeTransferParams): {
|
|
1896
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1897
|
+
result: any;
|
|
1898
|
+
onClickConfirm: () => void;
|
|
1899
|
+
};
|
|
1900
|
+
|
|
1901
|
+
declare function useAlkanesNFTScreenLogic(): {
|
|
1902
|
+
alkanesInfo: _unisat_wallet_shared.AlkanesInfo;
|
|
1903
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1904
|
+
availableUtxo: number;
|
|
1905
|
+
onClickBack: () => void;
|
|
1906
|
+
onClickSend: () => void;
|
|
1907
|
+
disabledSend: boolean;
|
|
1908
|
+
};
|
|
1909
|
+
|
|
1910
|
+
declare function useAlkanesTokenScreenLogic(): {
|
|
1911
|
+
tokenSummary: AddressAlkanesTokenSummary;
|
|
1912
|
+
loading: boolean;
|
|
1913
|
+
enableMint: boolean;
|
|
1914
|
+
enableTransfer: boolean;
|
|
1915
|
+
enableTrade: boolean;
|
|
1916
|
+
warning: boolean;
|
|
1917
|
+
setWarning: react.Dispatch<react.SetStateAction<boolean>>;
|
|
1918
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1919
|
+
tools: ToolsContextType;
|
|
1920
|
+
onClickMint: () => void;
|
|
1921
|
+
onClickSend: () => void;
|
|
1922
|
+
onClickTrade: () => void;
|
|
1923
|
+
onClickViewOnExplorer: () => void;
|
|
1924
|
+
iconInfo: {
|
|
1925
|
+
iconUrl: string;
|
|
1926
|
+
iconShortName: string;
|
|
1927
|
+
};
|
|
1928
|
+
};
|
|
1929
|
+
|
|
1930
|
+
declare enum TabType {
|
|
1931
|
+
STEP1 = "STEP1",
|
|
1932
|
+
STEP2 = "STEP2",
|
|
1933
|
+
CHOOSE_ADDRESS_TYPE = "CHOOSE_ADDRESS_TYPE"
|
|
1934
|
+
}
|
|
1935
|
+
interface ContextData {
|
|
1936
|
+
mnemonics: string;
|
|
1937
|
+
hdPath: string;
|
|
1938
|
+
passphrase: string;
|
|
1939
|
+
addressType: AddressType;
|
|
1940
|
+
step1Completed: boolean;
|
|
1941
|
+
tabType: TabType;
|
|
1942
|
+
restoreWalletType: RestoreWalletType;
|
|
1943
|
+
isRestore: boolean;
|
|
1944
|
+
isCustom: boolean;
|
|
1945
|
+
customHdPath: string;
|
|
1946
|
+
addressTypeIndex: number;
|
|
1947
|
+
wordsType: WordsType;
|
|
1948
|
+
walletName?: string;
|
|
1949
|
+
}
|
|
1950
|
+
interface UpdateContextDataParams {
|
|
1951
|
+
mnemonics?: string;
|
|
1952
|
+
hdPath?: string;
|
|
1953
|
+
passphrase?: string;
|
|
1954
|
+
addressType?: AddressType;
|
|
1955
|
+
step1Completed?: boolean;
|
|
1956
|
+
tabType?: TabType;
|
|
1957
|
+
restoreWalletType?: RestoreWalletType;
|
|
1958
|
+
isCustom?: boolean;
|
|
1959
|
+
customHdPath?: string;
|
|
1960
|
+
addressTypeIndex?: number;
|
|
1961
|
+
wordsType?: WordsType;
|
|
1962
|
+
walletName?: string;
|
|
1963
|
+
}
|
|
1964
|
+
interface WordsItem {
|
|
1965
|
+
key: WordsType;
|
|
1966
|
+
label: string;
|
|
1967
|
+
count: number;
|
|
1968
|
+
}
|
|
1969
|
+
interface CreateWalletLogicParams {
|
|
1970
|
+
contextData: ContextData;
|
|
1971
|
+
updateContextData: (params: UpdateContextDataParams) => void;
|
|
1972
|
+
}
|
|
1973
|
+
declare function useCreateWalletLogicImportWordsStep(params: CreateWalletLogicParams): {
|
|
1974
|
+
wordsItems: WordsItem[];
|
|
1975
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
1976
|
+
disabled: boolean;
|
|
1977
|
+
inputWords: string[];
|
|
1978
|
+
inputWordsText: string;
|
|
1979
|
+
onHandleEventPaste: (event: any, index: number) => void;
|
|
1980
|
+
onClickNext: () => Promise<void>;
|
|
1981
|
+
onClickWordsItem: (wordsItem: WordsItem) => void;
|
|
1982
|
+
inputWordsError: boolean;
|
|
1983
|
+
onInputWordsTextChange: (e: {
|
|
1984
|
+
target: {
|
|
1985
|
+
value: string;
|
|
1986
|
+
};
|
|
1987
|
+
} | string) => void;
|
|
1988
|
+
onInputWordsChange: (e: {
|
|
1989
|
+
target: {
|
|
1990
|
+
value: string;
|
|
1991
|
+
};
|
|
1992
|
+
} | string, index: number) => void;
|
|
1993
|
+
loading: boolean;
|
|
1994
|
+
enablePhrase: boolean;
|
|
1995
|
+
walletName: string;
|
|
1996
|
+
onInputWalletNameChange: (e: {
|
|
1997
|
+
target: {
|
|
1998
|
+
value: string;
|
|
1999
|
+
};
|
|
2000
|
+
} | string) => void;
|
|
2001
|
+
enteredWordsCount: number;
|
|
2002
|
+
shouldEnteredWordsCount: number;
|
|
2003
|
+
};
|
|
2004
|
+
|
|
2005
|
+
declare enum TabKey {
|
|
2006
|
+
DETAILS = "DETAILS",
|
|
2007
|
+
PROVENANCE = "PROVENANCE"
|
|
2008
|
+
}
|
|
2009
|
+
declare function useOrdinalsInscriptionScreenLogic(): {
|
|
2010
|
+
inscription: Inscription;
|
|
2011
|
+
isLoadingDetails: boolean;
|
|
2012
|
+
isInitialLoading: boolean;
|
|
2013
|
+
isNeedToSplit: boolean;
|
|
2014
|
+
isMultiStuck: boolean;
|
|
2015
|
+
tabKey: TabKey;
|
|
2016
|
+
setTabKey: react.Dispatch<react.SetStateAction<TabKey>>;
|
|
2017
|
+
TabKey: typeof TabKey;
|
|
2018
|
+
resetState: () => void;
|
|
2019
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2020
|
+
inscriptionId: string;
|
|
2021
|
+
onClickSend: () => void;
|
|
2022
|
+
onClickSplit: () => void;
|
|
2023
|
+
isUnconfirmed: boolean;
|
|
2024
|
+
withSend: boolean;
|
|
2025
|
+
shouldShowTabs: boolean;
|
|
2026
|
+
nav: NavigationContextType;
|
|
2027
|
+
};
|
|
2028
|
+
|
|
2029
|
+
declare function useRunesTokenScreenLogic(): {
|
|
2030
|
+
runeid: string;
|
|
2031
|
+
tokenSummary: AddressRunesTokenSummary;
|
|
2032
|
+
iconInfo: {
|
|
2033
|
+
iconUrl: string;
|
|
2034
|
+
iconShortName: string;
|
|
2035
|
+
};
|
|
2036
|
+
loading: boolean;
|
|
2037
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2038
|
+
enableMint: boolean;
|
|
2039
|
+
onClickMint: () => void;
|
|
2040
|
+
tools: ToolsContextType;
|
|
2041
|
+
ordinalsWebsite: string;
|
|
2042
|
+
txExplorerUrl: string;
|
|
2043
|
+
enableTransfer: boolean;
|
|
2044
|
+
onClickSend: () => void;
|
|
2045
|
+
enableTrade: boolean;
|
|
2046
|
+
onClickTrade: () => void;
|
|
2047
|
+
onClickViewOnExplorer: () => void;
|
|
2048
|
+
};
|
|
2049
|
+
|
|
2050
|
+
interface BRC20BalanceCardProps {
|
|
2051
|
+
tokenBalance: TokenBalance;
|
|
2052
|
+
onClick?: () => void;
|
|
2053
|
+
price?: TickPriceItem;
|
|
2054
|
+
}
|
|
2055
|
+
declare function useBRC20BalanceCardLogic(props: BRC20BalanceCardProps): {
|
|
2056
|
+
ticker: string;
|
|
2057
|
+
displayName: string;
|
|
2058
|
+
selfMint: boolean;
|
|
2059
|
+
tag: string;
|
|
2060
|
+
iconInfo: {
|
|
2061
|
+
iconUrl: string;
|
|
2062
|
+
iconShortName: string;
|
|
2063
|
+
};
|
|
2064
|
+
totalBalance: string;
|
|
2065
|
+
hasOutWalletBalance: boolean;
|
|
2066
|
+
onProgBalance: string;
|
|
2067
|
+
inWalletBalance: string;
|
|
2068
|
+
onSwapBalance: string;
|
|
2069
|
+
price: TickPriceItem;
|
|
2070
|
+
showPrice: boolean;
|
|
2071
|
+
onClick: () => void;
|
|
2072
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2073
|
+
};
|
|
2074
|
+
|
|
2075
|
+
declare function useExportMnemonicsScreenLogic(): {
|
|
2076
|
+
words: string[];
|
|
2077
|
+
pathName: string;
|
|
2078
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2079
|
+
setPassword: react.Dispatch<react.SetStateAction<string>>;
|
|
2080
|
+
disabled: boolean;
|
|
2081
|
+
btnClick: () => Promise<void>;
|
|
2082
|
+
handleOnKeyUp: (e: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
2083
|
+
mnemonic: string;
|
|
2084
|
+
passphrase: string;
|
|
2085
|
+
error: string;
|
|
2086
|
+
copy: (str: string) => void;
|
|
2087
|
+
keyring: _unisat_wallet_shared.WalletKeyring;
|
|
2088
|
+
onClickBack: () => void;
|
|
2089
|
+
};
|
|
2090
|
+
|
|
2091
|
+
declare function useExportPrivateKeyScreenLogic(): {
|
|
2092
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2093
|
+
setPassword: react.Dispatch<react.SetStateAction<string>>;
|
|
2094
|
+
disabled: boolean;
|
|
2095
|
+
btnClick: () => Promise<void>;
|
|
2096
|
+
handleOnKeyUp: (e: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
2097
|
+
privateKey: {
|
|
2098
|
+
hex: string;
|
|
2099
|
+
wif: string;
|
|
2100
|
+
};
|
|
2101
|
+
error: string;
|
|
2102
|
+
copy: (str: string) => void;
|
|
2103
|
+
onClickBack: () => void;
|
|
2104
|
+
};
|
|
2105
|
+
|
|
2106
|
+
declare function useSendRunesScreenLogic(): {
|
|
2107
|
+
runeInfo: _unisat_wallet_shared.RuneInfo;
|
|
2108
|
+
inputAmount: string;
|
|
2109
|
+
totalBalanceStr: string;
|
|
2110
|
+
availableBalanceStr: string;
|
|
2111
|
+
setInputAmount: react.Dispatch<react.SetStateAction<string>>;
|
|
2112
|
+
disabled: boolean;
|
|
2113
|
+
toInfo: {
|
|
2114
|
+
address: string;
|
|
2115
|
+
domain: string;
|
|
2116
|
+
inscription?: Inscription;
|
|
2117
|
+
};
|
|
2118
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
2119
|
+
address: string;
|
|
2120
|
+
domain: string;
|
|
2121
|
+
inscription?: Inscription;
|
|
2122
|
+
}>>;
|
|
2123
|
+
error: string;
|
|
2124
|
+
defaultOutputValue: number;
|
|
2125
|
+
minOutputValue: number;
|
|
2126
|
+
setOutputValue: react.Dispatch<react.SetStateAction<number>>;
|
|
2127
|
+
enableRBF: boolean;
|
|
2128
|
+
setEnableRBF: (value: boolean) => void;
|
|
2129
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2130
|
+
onClickBack: () => void;
|
|
2131
|
+
onClickNext: () => void;
|
|
2132
|
+
};
|
|
2133
|
+
|
|
2134
|
+
declare function useEditContactScreenLogic(): {
|
|
2135
|
+
name: string;
|
|
2136
|
+
contactAddress: string;
|
|
2137
|
+
chainType: ChainType;
|
|
2138
|
+
error: string;
|
|
2139
|
+
loading: boolean;
|
|
2140
|
+
handleNameChange: (e: {
|
|
2141
|
+
target: {
|
|
2142
|
+
value: string;
|
|
2143
|
+
};
|
|
2144
|
+
} | string) => void;
|
|
2145
|
+
handleAddressChange: (e: {
|
|
2146
|
+
target: {
|
|
2147
|
+
value: string;
|
|
2148
|
+
};
|
|
2149
|
+
} | string) => void;
|
|
2150
|
+
handleSubmit: () => Promise<void>;
|
|
2151
|
+
handleDelete: () => Promise<void>;
|
|
2152
|
+
onClickBack: () => void;
|
|
2153
|
+
address: string;
|
|
2154
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2155
|
+
};
|
|
2156
|
+
|
|
2157
|
+
declare function useEditAccountNameScreenLogic(): {
|
|
2158
|
+
alianName: string;
|
|
2159
|
+
handleOnClick: () => Promise<void>;
|
|
2160
|
+
handleOnKeyUp: (e: React.KeyboardEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
2161
|
+
isValidName: boolean;
|
|
2162
|
+
truncatedTitle: string;
|
|
2163
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2164
|
+
account: Account;
|
|
2165
|
+
onInputChange: (e: {
|
|
2166
|
+
target: {
|
|
2167
|
+
value: string;
|
|
2168
|
+
};
|
|
2169
|
+
} | string) => void;
|
|
2170
|
+
onClickBack: () => void;
|
|
2171
|
+
};
|
|
2172
|
+
|
|
2173
|
+
declare function useAlkanesCollectionListLogic(): {
|
|
2174
|
+
items: AlkanesCollection[];
|
|
2175
|
+
total: number;
|
|
2176
|
+
loading: boolean;
|
|
2177
|
+
hasMore: boolean;
|
|
2178
|
+
onRefresh: () => Promise<void>;
|
|
2179
|
+
onLoadMore: () => void;
|
|
2180
|
+
onClickItem: (item: AlkanesCollection) => void;
|
|
2181
|
+
};
|
|
2182
|
+
|
|
2183
|
+
declare function useBRC20ListLogic(): {
|
|
2184
|
+
items: TokenBalance[];
|
|
2185
|
+
total: number;
|
|
2186
|
+
loading: boolean;
|
|
2187
|
+
hasMore: boolean;
|
|
2188
|
+
onRefresh: () => Promise<void>;
|
|
2189
|
+
onLoadMore: () => void;
|
|
2190
|
+
onClickItem: (item: TokenBalance) => void;
|
|
2191
|
+
priceMap: {
|
|
2192
|
+
[key: string]: TickPriceItem;
|
|
2193
|
+
};
|
|
2194
|
+
};
|
|
2195
|
+
|
|
2196
|
+
declare function useInscriptionListLogic(): {
|
|
2197
|
+
items: Inscription[];
|
|
2198
|
+
total: number;
|
|
2199
|
+
loading: boolean;
|
|
2200
|
+
hasMore: boolean;
|
|
2201
|
+
onRefresh: () => Promise<void>;
|
|
2202
|
+
onLoadMore: () => void;
|
|
2203
|
+
onClickItem: (item: Inscription) => void;
|
|
2204
|
+
};
|
|
2205
|
+
|
|
2206
|
+
declare function useRunesListLogic(): {
|
|
2207
|
+
items: RuneBalance[];
|
|
2208
|
+
total: number;
|
|
2209
|
+
loading: boolean;
|
|
2210
|
+
hasMore: boolean;
|
|
2211
|
+
onRefresh: () => Promise<void>;
|
|
2212
|
+
onLoadMore: () => void;
|
|
2213
|
+
onClickItem: (item: RuneBalance) => void;
|
|
2214
|
+
priceMap: {
|
|
2215
|
+
[key: string]: TickPriceItem;
|
|
2216
|
+
};
|
|
2217
|
+
};
|
|
2218
|
+
|
|
2219
|
+
declare function useCAT20ListLogic(version: CAT_VERSION): {
|
|
2220
|
+
tokens: CAT20Balance[];
|
|
2221
|
+
total: number;
|
|
2222
|
+
loading: boolean;
|
|
2223
|
+
hasMore: boolean;
|
|
2224
|
+
onRefresh: () => Promise<void>;
|
|
2225
|
+
onLoadMore: () => void;
|
|
2226
|
+
onClickItem: (item: CAT20Balance) => void;
|
|
2227
|
+
priceMap: {
|
|
2228
|
+
[key: string]: TickPriceItem;
|
|
2229
|
+
};
|
|
2230
|
+
};
|
|
2231
|
+
|
|
2232
|
+
declare enum SendCAT20ScreenStep {
|
|
2233
|
+
PREPARE = 0,
|
|
2234
|
+
SIGN_COMMIT = 1,
|
|
2235
|
+
WAITING = 2,
|
|
2236
|
+
SIGN_REVEAL = 3
|
|
2237
|
+
}
|
|
2238
|
+
declare function useSendCAT20ScreenLogic(): {
|
|
2239
|
+
cat20Info: _unisat_wallet_shared.CAT20TokenInfo;
|
|
2240
|
+
cat20Balance: _unisat_wallet_shared.CAT20Balance;
|
|
2241
|
+
availableTokenAmount: string;
|
|
2242
|
+
toInfo: {
|
|
2243
|
+
address: string;
|
|
2244
|
+
domain: string;
|
|
2245
|
+
inscription?: Inscription;
|
|
2246
|
+
};
|
|
2247
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
2248
|
+
address: string;
|
|
2249
|
+
domain: string;
|
|
2250
|
+
inscription?: Inscription;
|
|
2251
|
+
}>>;
|
|
2252
|
+
inputAmount: string;
|
|
2253
|
+
setInputAmount: react.Dispatch<react.SetStateAction<string>>;
|
|
2254
|
+
error: string;
|
|
2255
|
+
disabled: boolean;
|
|
2256
|
+
step: SendCAT20ScreenStep;
|
|
2257
|
+
showMergeBTCUTXOPopover: boolean;
|
|
2258
|
+
setShowMergeBTCUTXOPopover: react.Dispatch<react.SetStateAction<boolean>>;
|
|
2259
|
+
shouldShowMerge: boolean;
|
|
2260
|
+
onClickNext: () => Promise<void>;
|
|
2261
|
+
onClickBack: () => void;
|
|
2262
|
+
onSignCommitPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2263
|
+
onSignCommitPsbtHandleCancel: () => void;
|
|
2264
|
+
onSignCommitPsbtHandleBack: () => void;
|
|
2265
|
+
signCommitPsbtParams: SignPsbtParams;
|
|
2266
|
+
onSignRevealPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2267
|
+
onSignRevealPsbtHandleCancel: () => void;
|
|
2268
|
+
onSignRevealPsbtHandleBack: () => void;
|
|
2269
|
+
signRevealPsbtParams: SignPsbtParams;
|
|
2270
|
+
onClickMergeUTXO: () => void;
|
|
2271
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2272
|
+
};
|
|
2273
|
+
|
|
2274
|
+
declare enum SendCAT721ScreenStep {
|
|
2275
|
+
PREPARE = 0,
|
|
2276
|
+
SIGN_COMMIT = 1,
|
|
2277
|
+
WAITING = 2,
|
|
2278
|
+
SIGN_REVEAL = 3
|
|
2279
|
+
}
|
|
2280
|
+
declare function useSendCAT721ScreenLogic(): {
|
|
2281
|
+
version: _unisat_wallet_shared.CAT_VERSION;
|
|
2282
|
+
localId: string;
|
|
2283
|
+
collectionInfo: _unisat_wallet_shared.CAT721CollectionInfo;
|
|
2284
|
+
toInfo: {
|
|
2285
|
+
address: string;
|
|
2286
|
+
domain: string;
|
|
2287
|
+
inscription?: Inscription;
|
|
2288
|
+
};
|
|
2289
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
2290
|
+
address: string;
|
|
2291
|
+
domain: string;
|
|
2292
|
+
inscription?: Inscription;
|
|
2293
|
+
}>>;
|
|
2294
|
+
error: string;
|
|
2295
|
+
disabled: boolean;
|
|
2296
|
+
step: SendCAT721ScreenStep;
|
|
2297
|
+
showMergeBTCUTXOPopover: boolean;
|
|
2298
|
+
setShowMergeBTCUTXOPopover: react.Dispatch<react.SetStateAction<boolean>>;
|
|
2299
|
+
onClickNext: () => Promise<void>;
|
|
2300
|
+
onClickBack: () => void;
|
|
2301
|
+
onSignCommitPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2302
|
+
onSignCommitPsbtHandleCancel: () => void;
|
|
2303
|
+
onSignCommitPsbtHandleBack: () => void;
|
|
2304
|
+
signCommitPsbtParams: SignPsbtParams;
|
|
2305
|
+
onSignRevealPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2306
|
+
onSignRevealPsbtHandleCancel: () => void;
|
|
2307
|
+
onSignRevealPsbtHandleBack: () => void;
|
|
2308
|
+
signRevealPsbtParams: SignPsbtParams;
|
|
2309
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2310
|
+
};
|
|
2311
|
+
|
|
2312
|
+
declare function useAlkanesNFTListLogic(collectionId: string): {
|
|
2313
|
+
items: AlkanesInfo[];
|
|
2314
|
+
total: number;
|
|
2315
|
+
loading: boolean;
|
|
2316
|
+
hasMore: boolean;
|
|
2317
|
+
onRefresh: () => Promise<void>;
|
|
2318
|
+
onLoadMore: () => void;
|
|
2319
|
+
onClickItem: (item: AlkanesInfo) => void;
|
|
2320
|
+
};
|
|
2321
|
+
|
|
2322
|
+
declare function useBRC20ProgListLogic(): {
|
|
2323
|
+
items: TokenBalance[];
|
|
2324
|
+
total: number;
|
|
2325
|
+
loading: boolean;
|
|
2326
|
+
hasMore: boolean;
|
|
2327
|
+
onRefresh: () => Promise<void>;
|
|
2328
|
+
onLoadMore: () => void;
|
|
2329
|
+
onClickItem: (item: TokenBalance) => void;
|
|
2330
|
+
priceMap: {
|
|
2331
|
+
[key: string]: TickPriceItem;
|
|
2332
|
+
};
|
|
2333
|
+
};
|
|
2334
|
+
|
|
2335
|
+
declare function useCAT721ListLogic(version: CAT_VERSION): {
|
|
2336
|
+
tokens: CAT721Balance[];
|
|
2337
|
+
total: number;
|
|
2338
|
+
loading: boolean;
|
|
2339
|
+
hasMore: boolean;
|
|
2340
|
+
onRefresh: () => Promise<void>;
|
|
2341
|
+
onLoadMore: () => void;
|
|
2342
|
+
onClickItem: (item: CAT721Balance) => void;
|
|
2343
|
+
};
|
|
2344
|
+
|
|
2345
|
+
declare function useCAT20TokenScreenLogic(): {
|
|
2346
|
+
tokenSummary: AddressCAT20TokenSummary;
|
|
2347
|
+
loading: boolean;
|
|
2348
|
+
tokenUrl: string;
|
|
2349
|
+
enableTransfer: boolean;
|
|
2350
|
+
enableTrade: boolean;
|
|
2351
|
+
iconInfo: {
|
|
2352
|
+
iconUrl: string;
|
|
2353
|
+
iconShortName: string;
|
|
2354
|
+
};
|
|
2355
|
+
onClickMerge: (e: any) => void;
|
|
2356
|
+
onClickSend: (e: any) => void;
|
|
2357
|
+
onClickTrade: (e: any) => void;
|
|
2358
|
+
onClickBack: () => void;
|
|
2359
|
+
onClickViewOnExplorer: (e: any) => void;
|
|
2360
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2361
|
+
};
|
|
2362
|
+
|
|
2363
|
+
declare function useSplitOrdinalsInscriptionScreenLogic(): {
|
|
2364
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2365
|
+
inscriptions: Inscription[];
|
|
2366
|
+
minOutputValue: number;
|
|
2367
|
+
splitedCount: number;
|
|
2368
|
+
enableRBF: boolean;
|
|
2369
|
+
setEnableRBF: (value: boolean) => void;
|
|
2370
|
+
error: string;
|
|
2371
|
+
disabled: boolean;
|
|
2372
|
+
onOutputValueChange: (value: number) => void;
|
|
2373
|
+
onClickBack: () => void;
|
|
2374
|
+
onClickNext: () => void;
|
|
2375
|
+
};
|
|
2376
|
+
|
|
2377
|
+
declare function useCreatePasswordScreenLogic(): {
|
|
2378
|
+
disabled: boolean;
|
|
2379
|
+
strongTextRenderData: {
|
|
2380
|
+
text: any;
|
|
2381
|
+
color: string;
|
|
2382
|
+
tip: any;
|
|
2383
|
+
} | {
|
|
2384
|
+
text: any;
|
|
2385
|
+
color: string;
|
|
2386
|
+
tip?: undefined;
|
|
2387
|
+
};
|
|
2388
|
+
matchTextRenderData: {
|
|
2389
|
+
text: string;
|
|
2390
|
+
};
|
|
2391
|
+
onClickConfirm: () => void;
|
|
2392
|
+
onPasswordChange: (e: string | {
|
|
2393
|
+
target: {
|
|
2394
|
+
value: string;
|
|
2395
|
+
};
|
|
2396
|
+
}) => void;
|
|
2397
|
+
onConfirmPasswordChange: (e: string | {
|
|
2398
|
+
target: {
|
|
2399
|
+
value: string;
|
|
2400
|
+
};
|
|
2401
|
+
}) => void;
|
|
2402
|
+
};
|
|
2403
|
+
|
|
2404
|
+
declare enum SendAlkanesNFTScreenStep {
|
|
2405
|
+
CREATE_TX = 0,
|
|
2406
|
+
SIGN_TX = 1
|
|
2407
|
+
}
|
|
2408
|
+
declare function useSendAlkanesNFTScreenLogic(): {
|
|
2409
|
+
step: number;
|
|
2410
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2411
|
+
alkanesInfo: _unisat_wallet_shared.AlkanesInfo;
|
|
2412
|
+
toInfo: {
|
|
2413
|
+
address: string;
|
|
2414
|
+
domain: string;
|
|
2415
|
+
inscription?: Inscription;
|
|
2416
|
+
};
|
|
2417
|
+
enableRBF: boolean;
|
|
2418
|
+
disabled: boolean;
|
|
2419
|
+
error: string;
|
|
2420
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
2421
|
+
address: string;
|
|
2422
|
+
domain: string;
|
|
2423
|
+
inscription?: Inscription;
|
|
2424
|
+
}>>;
|
|
2425
|
+
setEnableRBF: (value: boolean) => void;
|
|
2426
|
+
onCreateTxHandleConfirm: () => Promise<void>;
|
|
2427
|
+
onCreateTxHandleBack: () => void;
|
|
2428
|
+
onSignPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2429
|
+
onSignPsbtHandleCancel: () => void;
|
|
2430
|
+
onSignPsbtHandleBack: () => void;
|
|
2431
|
+
signPsbtParams: SignPsbtParams;
|
|
2432
|
+
};
|
|
2433
|
+
|
|
2434
|
+
declare enum SendAlkanesScreenStep {
|
|
2435
|
+
CREATE_TX = 0,
|
|
2436
|
+
SIGN_TX = 1
|
|
2437
|
+
}
|
|
2438
|
+
declare function useSendAlkanesScreenLogic(): {
|
|
2439
|
+
step: SendAlkanesScreenStep;
|
|
2440
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2441
|
+
tokenBalance: _unisat_wallet_shared.AlkanesBalance;
|
|
2442
|
+
tokenInfo: _unisat_wallet_shared.AlkanesInfo;
|
|
2443
|
+
toInfo: {
|
|
2444
|
+
address: string;
|
|
2445
|
+
domain: string;
|
|
2446
|
+
inscription?: Inscription;
|
|
2447
|
+
};
|
|
2448
|
+
totalBalanceStr: string;
|
|
2449
|
+
availableBalanceStr: string;
|
|
2450
|
+
inputAmount: string;
|
|
2451
|
+
enableRBF: boolean;
|
|
2452
|
+
disabled: boolean;
|
|
2453
|
+
error: string;
|
|
2454
|
+
setToInfo: react.Dispatch<react.SetStateAction<{
|
|
2455
|
+
address: string;
|
|
2456
|
+
domain: string;
|
|
2457
|
+
inscription?: Inscription;
|
|
2458
|
+
}>>;
|
|
2459
|
+
setInputAmount: react.Dispatch<react.SetStateAction<string>>;
|
|
2460
|
+
setEnableRBF: (value: boolean) => void;
|
|
2461
|
+
onClickBack: () => void;
|
|
2462
|
+
onClickNext: () => Promise<void>;
|
|
2463
|
+
onSignPsbtHandleConfirm: (signedDatas: SignedData[]) => Promise<void>;
|
|
2464
|
+
onSignPsbtHandleCancel: () => void;
|
|
2465
|
+
onSignPsbtHandleBack: () => void;
|
|
2466
|
+
signPsbtParams: SignPsbtParams;
|
|
2467
|
+
};
|
|
2468
|
+
|
|
2469
|
+
interface RunesBalanceCardProps {
|
|
2470
|
+
tokenBalance: RuneBalance;
|
|
2471
|
+
onClick?: () => void;
|
|
2472
|
+
price?: TickPriceItem;
|
|
2473
|
+
}
|
|
2474
|
+
declare function useRunesBalanceCardLogic(props: RunesBalanceCardProps): {
|
|
2475
|
+
tokenBalance: RuneBalance;
|
|
2476
|
+
balance: BigNumber;
|
|
2477
|
+
balanceStr: string;
|
|
2478
|
+
showPrice: boolean;
|
|
2479
|
+
price: TickPriceItem;
|
|
2480
|
+
iconInfo: {
|
|
2481
|
+
iconUrl: string;
|
|
2482
|
+
iconShortName: string;
|
|
2483
|
+
};
|
|
2484
|
+
onClick: () => void;
|
|
2485
|
+
};
|
|
2486
|
+
|
|
2487
|
+
interface CAT20BalanceCardProps {
|
|
2488
|
+
tokenBalance: CAT20Balance;
|
|
2489
|
+
onClick?: () => void;
|
|
2490
|
+
showPrice?: boolean;
|
|
2491
|
+
price?: TickPriceItem;
|
|
2492
|
+
}
|
|
2493
|
+
declare function useCAT20BalanceCardLogic(props: CAT20BalanceCardProps): {
|
|
2494
|
+
tokenBalance: CAT20Balance;
|
|
2495
|
+
balance: BigNumber;
|
|
2496
|
+
balanceStr: string;
|
|
2497
|
+
price: TickPriceItem;
|
|
2498
|
+
showPrice: boolean;
|
|
2499
|
+
iconInfo: {
|
|
2500
|
+
iconUrl: string;
|
|
2501
|
+
iconShortName: string;
|
|
2502
|
+
};
|
|
2503
|
+
onClick: () => void;
|
|
2504
|
+
};
|
|
2505
|
+
|
|
2506
|
+
interface AlkanesBalanceCardProps {
|
|
2507
|
+
tokenBalance: AlkanesBalance;
|
|
2508
|
+
onClick?: () => void;
|
|
2509
|
+
price?: TickPriceItem;
|
|
2510
|
+
}
|
|
2511
|
+
declare function useAlkanesBalanceCardLogic(props: AlkanesBalanceCardProps): {
|
|
2512
|
+
tokenBalance: AlkanesBalance;
|
|
2513
|
+
balance: BigNumber;
|
|
2514
|
+
balanceStr: string;
|
|
2515
|
+
showPrice: boolean;
|
|
2516
|
+
price: TickPriceItem;
|
|
2517
|
+
iconInfo: {
|
|
2518
|
+
iconUrl: string;
|
|
2519
|
+
iconShortName: string;
|
|
2520
|
+
};
|
|
2521
|
+
onClick: () => void;
|
|
2522
|
+
};
|
|
2523
|
+
|
|
2524
|
+
declare function useCAT721NFTScreenLogic(): {
|
|
2525
|
+
collectionInfo: _unisat_wallet_shared.CAT721CollectionInfo;
|
|
2526
|
+
localId: string;
|
|
2527
|
+
version: _unisat_wallet_shared.CAT_VERSION;
|
|
2528
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2529
|
+
onClickBack: () => void;
|
|
2530
|
+
onClickSend: () => void;
|
|
2531
|
+
};
|
|
2532
|
+
|
|
2533
|
+
interface SignMessageProps {
|
|
2534
|
+
header?: React.ReactNode;
|
|
2535
|
+
params: {
|
|
2536
|
+
data: {
|
|
2537
|
+
toSignMessages: ToSignMessage[];
|
|
2538
|
+
};
|
|
2539
|
+
session?: {
|
|
2540
|
+
origin: string;
|
|
2541
|
+
icon: string;
|
|
2542
|
+
name: string;
|
|
2543
|
+
};
|
|
2544
|
+
};
|
|
2545
|
+
handleCancel?: () => void;
|
|
2546
|
+
handleConfirm?: (signedMessages: SignedMessage[]) => void;
|
|
2547
|
+
}
|
|
2548
|
+
declare function useSignMessageLogic(props: SignMessageProps): {
|
|
2549
|
+
loading: boolean;
|
|
2550
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2551
|
+
session: {
|
|
2552
|
+
origin: string;
|
|
2553
|
+
icon: string;
|
|
2554
|
+
name: string;
|
|
2555
|
+
};
|
|
2556
|
+
isKeystoneSigning: boolean;
|
|
2557
|
+
isColdWalletSigning: boolean;
|
|
2558
|
+
showMultiSignView: boolean;
|
|
2559
|
+
disclaimerVisible: boolean;
|
|
2560
|
+
toSignMessages: ToSignMessage[];
|
|
2561
|
+
currentToSignMessage: ToSignMessage;
|
|
2562
|
+
isScammer: boolean;
|
|
2563
|
+
allowQuickMultiSign: boolean;
|
|
2564
|
+
isAllSigned: boolean;
|
|
2565
|
+
signedCount: number;
|
|
2566
|
+
multiSignList: {
|
|
2567
|
+
index: number;
|
|
2568
|
+
title: string;
|
|
2569
|
+
buttonText: string;
|
|
2570
|
+
buttonPreset: string;
|
|
2571
|
+
onClick: () => void;
|
|
2572
|
+
}[];
|
|
2573
|
+
onClickBack: () => void;
|
|
2574
|
+
onClickSign: () => void;
|
|
2575
|
+
onQuickMultiSign: () => Promise<void>;
|
|
2576
|
+
onTryMultiSign: () => Promise<void>;
|
|
2577
|
+
onTrustSite: () => Promise<void>;
|
|
2578
|
+
onKeystoneSigningSuccess: (data: SignedMessage) => void;
|
|
2579
|
+
onKeystoneSigningBack: () => void;
|
|
2580
|
+
onColdWalletSigningSuccess: (data: SignedMessage) => void;
|
|
2581
|
+
onColdWalletSigningBack: () => void;
|
|
2582
|
+
onDisclaimerModalClose: () => void;
|
|
2583
|
+
};
|
|
2584
|
+
|
|
2585
|
+
interface SignPsbtProps {
|
|
2586
|
+
header?: React.ReactNode;
|
|
2587
|
+
params: {
|
|
2588
|
+
data: {
|
|
2589
|
+
toSignDatas: ToSignData[];
|
|
2590
|
+
};
|
|
2591
|
+
session?: ApprovalSession;
|
|
2592
|
+
};
|
|
2593
|
+
handleCancel?: () => void;
|
|
2594
|
+
handleConfirm?: (signedDatas: SignedData[]) => void;
|
|
2595
|
+
fromApproval?: boolean;
|
|
2596
|
+
}
|
|
2597
|
+
declare function useSignPsbtLogic(props: SignPsbtProps): {
|
|
2598
|
+
isPsbtRiskPopoverVisible: boolean;
|
|
2599
|
+
contractPopoverData: any;
|
|
2600
|
+
setContractPopoverData: react.Dispatch<any>;
|
|
2601
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2602
|
+
brc20PriceMap: Record<string, TickPriceItem>;
|
|
2603
|
+
runesPriceMap: Record<string, TickPriceItem>;
|
|
2604
|
+
session: ApprovalSession;
|
|
2605
|
+
isPsbtSigning: boolean;
|
|
2606
|
+
isKeystoneSigning: boolean;
|
|
2607
|
+
isColdWalletSigning: boolean;
|
|
2608
|
+
showMultiSignView: boolean;
|
|
2609
|
+
showLoading: boolean;
|
|
2610
|
+
disclaimerVisible: boolean;
|
|
2611
|
+
localPsbtSummary: LocalPsbtSummary;
|
|
2612
|
+
toSignDatas: ToSignData[];
|
|
2613
|
+
currentToSignData: ToSignData;
|
|
2614
|
+
currentDecodedPsbt: DecodedPsbt;
|
|
2615
|
+
networkFee: string;
|
|
2616
|
+
isValid: boolean;
|
|
2617
|
+
hasRisk: boolean;
|
|
2618
|
+
showFeeSection: boolean;
|
|
2619
|
+
isScammer: boolean;
|
|
2620
|
+
allowQuickMultiSign: boolean;
|
|
2621
|
+
isAllSigned: boolean;
|
|
2622
|
+
signedCount: number;
|
|
2623
|
+
multiSignList: {
|
|
2624
|
+
index: number;
|
|
2625
|
+
buttonText: string;
|
|
2626
|
+
buttonPreset: string;
|
|
2627
|
+
psbtInfo: _unisat_wallet_shared.PsbtLocalInfo;
|
|
2628
|
+
onClick: () => void;
|
|
2629
|
+
}[];
|
|
2630
|
+
backButtonText: string;
|
|
2631
|
+
onClickBack: () => void;
|
|
2632
|
+
onClickSign: () => void;
|
|
2633
|
+
onQuickMultiSign: () => Promise<void>;
|
|
2634
|
+
onTryMultiSign: () => Promise<void>;
|
|
2635
|
+
onTrustSite: () => Promise<void>;
|
|
2636
|
+
onKeystoneSigningSuccess: (data: SignedData) => void;
|
|
2637
|
+
onKeystoneSigningBack: () => void;
|
|
2638
|
+
onColdWalletSigningSuccess: (data: {
|
|
2639
|
+
psbtHex: string;
|
|
2640
|
+
rawtx: string;
|
|
2641
|
+
}) => void;
|
|
2642
|
+
onColdWalletSigningBack: () => void;
|
|
2643
|
+
onRiskPopoverConfirm: () => void;
|
|
2644
|
+
onRiskPopoverClose: () => void;
|
|
2645
|
+
onDisclaimerModalClose: () => void;
|
|
2646
|
+
};
|
|
2647
|
+
|
|
2648
|
+
declare function useTxConfirmScreenLogic(): {
|
|
2649
|
+
signPsbtParams: SignPsbtParams;
|
|
2650
|
+
onClickBack: () => void;
|
|
2651
|
+
onClickCancel: () => void;
|
|
2652
|
+
onClickConfirm: (signedDatas: SignPsbtResult) => Promise<void>;
|
|
2653
|
+
};
|
|
2654
|
+
|
|
2655
|
+
declare function useTxFailScreenLogic(): {
|
|
2656
|
+
error: string;
|
|
2657
|
+
onClickBack: () => void;
|
|
2658
|
+
onClickDone: () => void;
|
|
2659
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2660
|
+
};
|
|
2661
|
+
|
|
2662
|
+
declare function useTxSuccessScreenLogic(): {
|
|
2663
|
+
txid: string;
|
|
2664
|
+
onClickExploreTx: () => void;
|
|
2665
|
+
onClickDone: () => void;
|
|
2666
|
+
onClickCopy: () => void;
|
|
2667
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2668
|
+
};
|
|
2669
|
+
|
|
2670
|
+
interface ActionOverviewSectionProps {
|
|
2671
|
+
action: PsbtActionInfo;
|
|
2672
|
+
decodedPsbt: DecodedPsbt;
|
|
2673
|
+
}
|
|
2674
|
+
declare function useActionOverviewSectionLogic({ action, decodedPsbt }: ActionOverviewSectionProps): {
|
|
2675
|
+
decodedPsbt: DecodedPsbt;
|
|
2676
|
+
action: PsbtActionInfo;
|
|
2677
|
+
commonDetails: any[];
|
|
2678
|
+
chain: _unisat_wallet_shared.TypeChain;
|
|
2679
|
+
};
|
|
2680
|
+
|
|
2681
|
+
interface SettingsItemType {
|
|
2682
|
+
key: string;
|
|
2683
|
+
label?: string;
|
|
2684
|
+
value?: string;
|
|
2685
|
+
desc?: string;
|
|
2686
|
+
danger?: boolean;
|
|
2687
|
+
right: boolean;
|
|
2688
|
+
icon?: string;
|
|
2689
|
+
badge?: string;
|
|
2690
|
+
onClick?: () => void;
|
|
2691
|
+
}
|
|
2692
|
+
declare function useSettingsTabScreenLogic(): {
|
|
2693
|
+
settings_connectedSites: SettingsItemType;
|
|
2694
|
+
settings_addressBook: SettingsItemType;
|
|
2695
|
+
settings_addressType: SettingsItemType;
|
|
2696
|
+
settings_advanced: {
|
|
2697
|
+
key: string;
|
|
2698
|
+
label: string;
|
|
2699
|
+
value: string;
|
|
2700
|
+
desc: string;
|
|
2701
|
+
right: boolean;
|
|
2702
|
+
icon: string;
|
|
2703
|
+
onClick: () => void;
|
|
2704
|
+
};
|
|
2705
|
+
settings_feedback: {
|
|
2706
|
+
key: string;
|
|
2707
|
+
label: string;
|
|
2708
|
+
value: string;
|
|
2709
|
+
desc: string;
|
|
2710
|
+
route: string;
|
|
2711
|
+
right: boolean;
|
|
2712
|
+
icon: string;
|
|
2713
|
+
onClick: () => void;
|
|
2714
|
+
};
|
|
2715
|
+
settings_rateus: {
|
|
2716
|
+
key: string;
|
|
2717
|
+
label: string;
|
|
2718
|
+
value: string;
|
|
2719
|
+
desc: string;
|
|
2720
|
+
route: string;
|
|
2721
|
+
right: boolean;
|
|
2722
|
+
icon: string;
|
|
2723
|
+
onClick: () => void;
|
|
2724
|
+
};
|
|
2725
|
+
settings_aboutus: {
|
|
2726
|
+
key: string;
|
|
2727
|
+
label: string;
|
|
2728
|
+
value: string;
|
|
2729
|
+
desc: string;
|
|
2730
|
+
right: boolean;
|
|
2731
|
+
icon: string;
|
|
2732
|
+
badge: string;
|
|
2733
|
+
onClick: () => void;
|
|
2734
|
+
};
|
|
2735
|
+
settings_lockwallet: {
|
|
2736
|
+
key: string;
|
|
2737
|
+
label: string;
|
|
2738
|
+
value: string;
|
|
2739
|
+
desc: string;
|
|
2740
|
+
right: boolean;
|
|
2741
|
+
onClick: () => void;
|
|
2742
|
+
};
|
|
2743
|
+
settings_expandview: {
|
|
2744
|
+
key: string;
|
|
2745
|
+
label: string;
|
|
2746
|
+
value: string;
|
|
2747
|
+
desc: string;
|
|
2748
|
+
right: boolean;
|
|
2749
|
+
onClick: () => void;
|
|
2750
|
+
};
|
|
2751
|
+
};
|
|
2752
|
+
|
|
2753
|
+
declare function useBalanceCardLogic(): {
|
|
2754
|
+
totalBalance: number;
|
|
2755
|
+
availableBalance: number;
|
|
2756
|
+
unavailableBalance: number;
|
|
2757
|
+
totalAmount: string;
|
|
2758
|
+
availableAmount: string;
|
|
2759
|
+
unavailableAmount: string;
|
|
2760
|
+
totalAmountMainPart: string;
|
|
2761
|
+
totalAmountSubPart: string;
|
|
2762
|
+
balanceValue: string;
|
|
2763
|
+
unavailableTipText: string;
|
|
2764
|
+
isCurrentChainBalance: boolean;
|
|
2765
|
+
showUtxoToolButton: boolean;
|
|
2766
|
+
handleUnlock: (e?: React.MouseEvent) => void;
|
|
2767
|
+
isDetailExpanded: boolean;
|
|
2768
|
+
handleExpandToggle: () => void;
|
|
2769
|
+
isBalanceHidden: boolean;
|
|
2770
|
+
handleHiddenToggle: (e?: React.MouseEvent) => void;
|
|
2771
|
+
refreshBalance: (e?: React.MouseEvent) => void;
|
|
2772
|
+
btcUnit: string;
|
|
2773
|
+
isBtcMainnet: boolean;
|
|
2774
|
+
chain: _unisat_wallet_shared.TypeChain;
|
|
2775
|
+
t: (key: string, substitutions?: string | string[] | Record<string, string | number>) => string;
|
|
2776
|
+
};
|
|
2777
|
+
|
|
2778
|
+
declare function useBtcDisplayLogic(balance: string): {
|
|
2779
|
+
totalAmountMainPart: string;
|
|
2780
|
+
totalAmountSubPart: string;
|
|
2781
|
+
};
|
|
2782
|
+
|
|
2783
|
+
type Listener = (params?: any) => void;
|
|
2784
|
+
declare class EventBus {
|
|
2785
|
+
events: Record<string, Listener[]>;
|
|
2786
|
+
emit: (type: string, params?: any) => void;
|
|
2787
|
+
once: (type: string, fn: Listener) => void;
|
|
2788
|
+
addEventListener: (type: string, fn: Listener) => void;
|
|
2789
|
+
removeEventListener: (type: string, fn: Listener) => void;
|
|
2790
|
+
removeAllEventListeners: (type: string) => void;
|
|
2791
|
+
}
|
|
2792
|
+
declare const uiEventBus: EventBus;
|
|
2793
|
+
|
|
2794
|
+
declare function useAsyncEffect(effect: () => Promise<void | (() => void)>, deps?: React.DependencyList): void;
|
|
2795
|
+
|
|
2796
|
+
declare function createAppStore(): _reduxjs_toolkit_dist_configureStore.ToolkitStore<{
|
|
2797
|
+
accounts: AccountsState;
|
|
2798
|
+
transactions: TransactionsState;
|
|
2799
|
+
settings: SettingsState;
|
|
2800
|
+
global: GlobalState;
|
|
2801
|
+
keyrings: KeyringsState;
|
|
2802
|
+
ui: UIState;
|
|
2803
|
+
discovery: DiscoveryState;
|
|
2804
|
+
browser: BrowserState;
|
|
2805
|
+
}, redux.AnyAction, _reduxjs_toolkit.MiddlewareArray<[_reduxjs_toolkit.ThunkMiddleware<{
|
|
2806
|
+
accounts: AccountsState;
|
|
2807
|
+
transactions: TransactionsState;
|
|
2808
|
+
settings: SettingsState;
|
|
2809
|
+
global: GlobalState;
|
|
2810
|
+
keyrings: KeyringsState;
|
|
2811
|
+
ui: UIState;
|
|
2812
|
+
discovery: DiscoveryState;
|
|
2813
|
+
browser: BrowserState;
|
|
2814
|
+
}, redux.AnyAction>, redux.Middleware<{}, any, redux.Dispatch<redux.AnyAction>>]>>;
|
|
2815
|
+
type AppStore = ReturnType<typeof createAppStore>;
|
|
2816
|
+
type AppState = ReturnType<AppStore['getState']>;
|
|
2817
|
+
type AppDispatch = AppStore['dispatch'];
|
|
945
2818
|
|
|
946
|
-
export { AccountUpdater, AlkanesAssetTabKey, AppDispatch, AppState, AssetTabKey, CATAssetTabKey,
|
|
2819
|
+
export { AccountUpdater, ActionOverviewSectionProps, AlkanesAssetTabKey, AlkanesBalanceCardProps, AppDispatch, AppState, AppStore, ApprovalContext, ApprovalContextType, AssetTabKey, BRC20BalanceCardProps, BRC20InscribeTransferParams, BRC20OutWalletBalanceItem, BRC20SendStepParams, BRC20SendTabKey, BRC20SingleStepKey, BRC20TokenScreenTabKey, CAT20BalanceCardProps, CATAssetTabKey, ContextData$2 as ContextData, DeviceContext, DeviceContextType, I18nContext, I18nContextType, MoreAssetTabKey, NavigationContext, NavigationContextType, NavigationSource, OrdinalsAssetTabKey, PriceProvider, RouteTypes, RunesBalanceCardProps, SendAlkanesNFTScreenStep, SendAlkanesScreenStep, SendCAT20ScreenStep, SendCAT721ScreenStep, SettingsItemType, SignMessageProps, SignPsbtProps, StorageContext, StorageContextType, TabOption, ToolsContext, ToolsContextType, UpdateContextDataParams$2 as UpdateContextDataParams, WalletProvider, WalletTabScreenTabKey, accountActions, browserActions, createAppStore, createStorageProvider, discoveryActions, getSupportedAssets, globalActions, keyringsActions, settingsActions, transactionsActions, uiActions, uiEventBus, useAccountAddress, useAccountBalance, useAccountInscriptions, useAccounts, useAccountsState, useActionOverviewSectionLogic, useAddressExplorerUrl, useAddressInput, useAddressSummary, useAddressTips, useAddressTypeScreenLogic, useAlkanesAssetTabKey, useAlkanesBalanceCardLogic, useAlkanesCollectionListLogic, useAlkanesIconInfo, useAlkanesListLogic, useAlkanesMarketPlaceWebsite, useAlkanesNFTListLogic, useAlkanesNFTScreenLogic, useAlkanesTokenInfoExplorerUrl, useAlkanesTokenScreenLogic, useAmountInput, useAmountInputLogic, useAnnouncementCardLogic, useAppDispatch, useAppList, useAppSelector, useAppSummary, useApproval, useAssetTabKey, useAssetUtxosRunes, useAsyncEffect, useAutoLockTimeId, useBRC20BalanceCardLogic, useBRC20IconInfo, useBRC20InscribeTransferLogic, useBRC20InscribeTransferLogicStep1, useBRC20InscribeTransferLogicStep2, useBRC20InscribeTransferLogicStep3, useBRC20InscribeTransferLogicStep4, useBRC20ListLogic, useBRC20MarketPlaceWebsite, useBRC20ProgListLogic, useBRC20SendScreenLogic, useBRC20SendScreenLogicStep1, useBRC20SendScreenLogicStep2, useBRC20SendScreenLogicStep3, useBRC20SingleStepScreenLogic, useBRC20TokenHistoryLogic, useBRC20TokenInfoExplorerUrl, useBRC20TokenScreenLogic, useBTCUnit, useBabylonConfig, useBackRefresh, useBalanceCardDetailExpanded, useBalanceCardLogic, useBannerList, useBitcoinTx, useBooted, useBrowserState, useBtcDisplayLogic, useCAT20BalanceCardLogic, useCAT20IconInfo, useCAT20ListLogic, useCAT20MarketPlaceWebsite, useCAT20TokenInfoExplorerUrl, useCAT20TokenScreenLogic, useCAT721ListLogic, useCAT721NFTContentBaseUrl, useCAT721NFTScreenLogic, useCATAssetTabKey, useChain, useChainType, useChangeAddressFlagCallback, useChangeChainTypeCallback, useChangeLocaleCallback, useChangeNetworkTypeCallback, useCreateAccountCallback, useCreateColdWalletCallback, useCreatePasswordScreenLogic, useCreateSplitTxCallback, useCreateWalletLogicImportWordsStep, useCurrentAccount, useCurrentAddress, useCurrentKeyring, useDeveloperMode, useDevice, useDiscoveryState, useEditAccountNameScreenLogic, useEditContactScreenLogic, useEditWalletNameScreenLogic, useExportMnemonicsScreenLogic, useExportPrivateKeyScreenLogic, useFeeRateBar, useFeeRateBarLogic, useFetchAssetUtxosRunesCallback, useFetchBalanceCallback, useFetchUtxosCallback, useGetTxExplorerUrlCallback, useGlobalState, useGoBackRefresh, useHasBiometricsKey, useHasNewBanner, useHistory, useI18n, useIconBaseUrl, useImportAccountCallback, useImportAccountsFromKeystoneCallback, useInfiniteListScrollOffset, useInfiniteListScrollState, useInscriptionListLogic, useInscriptionSummary, useIsBiometricsSupported, useIsInExpandView, useIsKeystoneWallet, useIsMainnetChain, useIsReady, useIsRefresh, useIsScrollViewBot, useIsScrollViewTop, useIsUnlockTimeRefres, useIsUnlocked, useKeyrings, useKeyringsState, useLastFetchInfo, useLayerState, useLocale, useLockCallback, useLockTimePageLogic, useLockedOverlayVisible, useModelPopover, useMoreAssetTabKey, useNavigation, useNetworkType, useNotificationsLogic, useOrdinalsAssetTabKey, useOrdinalsInscriptionScreenLogic, useOrdinalsTx, useOrdinalsWebsite, usePrepareSendAlkanesCallback, usePrepareSendBTCCallback, usePrepareSendBypassHeadOffsetsCallback, usePrepareSendOrdinalsInscriptionCallback, usePrepareSendOrdinalsInscriptionsCallback, usePrepareSendRunesCallback, usePrice, usePushBitcoinTxCallback, usePushOrdinalsTxCallback, useReadApp, useReadTab, useReloadAccounts, useResetAddressInput, useResetAmountInput, useResetFeeRateBar, useResetTxState, useResetUiTxCreateScreen, useRunesBalanceCardLogic, useRunesIconInfo, useRunesInscribeUrl, useRunesListLogic, useRunesMarketUrl, useRunesTokenInfoExplorerUrl, useRunesTokenScreenLogic, useRunesTx, useSafeBalance, useScreenState, useSendAlkanesNFTScreenLogic, useSendAlkanesScreenLogic, useSendCAT20ScreenLogic, useSendCAT721ScreenLogic, useSendOrdinalsInscriptionScreenLogic, useSendRunesScreenLogic, useSetCurrentAccountCallback, useSetDeveloperModeCallback, useSetLockedOverlayVisibleCallback, useSetSpendUnavailableUtxosCallback, useSetTabCallback, useSettingsState, useSettingsTabScreenLogic, useSignMessageLogic, useSignPsbtLogic, useSkipVersionCallback, useSpendUnavailableUtxos, useSplitOrdinalsInscriptionScreenLogic, useStorage, useSupportedAssets, useSwitchChainModalVisible, useTab, useThrottle, useToggleBalanceCardDetailExpanded, useTools, useTransactionsState, useTransferableListLogic, useTxConfirmScreenLogic, useTxCreateScreenLogic, useTxExplorerUrl, useTxFailScreenLogic, useTxSuccessScreenLogic, useUIState, useUiTxCreateScreen, useUnisatWebsite, useUnlockCallback, useUnlockRead, useUnlockRefresh, useUnreadAppSummary, useUnreadNotificationsCount, useUpdateAddressInput, useUpdateAmountInput, useUpdateFeeRateBar, useUpdateScreenStateCallback, useUpdateUiTxCreateScreen, useUtxos, useVersionInfo, useWallRefresh, useWallTabFocusRefresh, useWallTabRefresh, useWallet, useWalletConfig, useWalletTabScreenState, useWalletTopTabScreenState };
|