@metamask/assets-controllers 73.3.0 → 74.0.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.
@@ -0,0 +1,734 @@
1
+ import type { AccountGroupId } from "@metamask/account-api";
2
+ import type { AccountTreeControllerState } from "@metamask/account-tree-controller";
3
+ import type { AccountsControllerState } from "@metamask/accounts-controller";
4
+ import type { NetworkState } from "@metamask/network-controller";
5
+ import { type Hex } from "@metamask/utils";
6
+ import type { CurrencyRateState } from "../CurrencyRateController.cjs";
7
+ import type { MultichainAssetsControllerState } from "../MultichainAssetsController/index.cjs";
8
+ import type { MultichainAssetsRatesControllerState } from "../MultichainAssetsRatesController/index.cjs";
9
+ import type { MultichainBalancesControllerState } from "../MultichainBalancesController/index.cjs";
10
+ import type { TokenBalancesControllerState } from "../TokenBalancesController.cjs";
11
+ import type { Token, TokenRatesControllerState } from "../TokenRatesController.cjs";
12
+ import type { TokensControllerState } from "../TokensController.cjs";
13
+ type AssetsByAccountGroup = {
14
+ [accountGroupId: AccountGroupId]: AccountGroupAssets;
15
+ };
16
+ export type AccountGroupAssets = {
17
+ [network: string]: Asset[];
18
+ };
19
+ export type Asset = ({
20
+ type: 'evm';
21
+ assetId: Hex;
22
+ address: Hex;
23
+ chainId: Hex;
24
+ } | {
25
+ type: 'multichain';
26
+ assetId: `${string}:${string}/${string}:${string}`;
27
+ chainId: `${string}:${string}`;
28
+ }) & {
29
+ image: string;
30
+ name: string;
31
+ symbol: string;
32
+ decimals: number;
33
+ isNative: boolean;
34
+ balance: string;
35
+ fiat: {
36
+ balance: number;
37
+ currency: string;
38
+ conversionRate: number;
39
+ } | undefined;
40
+ };
41
+ export type AssetListState = {
42
+ accountTree: AccountTreeControllerState['accountTree'];
43
+ internalAccounts: AccountsControllerState['internalAccounts'];
44
+ allTokens: TokensControllerState['allTokens'];
45
+ allIgnoredTokens: TokensControllerState['allIgnoredTokens'];
46
+ tokenBalances: TokenBalancesControllerState['tokenBalances'];
47
+ marketData: TokenRatesControllerState['marketData'];
48
+ currencyRates: CurrencyRateState['currencyRates'];
49
+ accountsAssets: MultichainAssetsControllerState['accountsAssets'];
50
+ assetsMetadata: MultichainAssetsControllerState['assetsMetadata'];
51
+ balances: MultichainBalancesControllerState['balances'];
52
+ conversionRates: MultichainAssetsRatesControllerState['conversionRates'];
53
+ currentCurrency: CurrencyRateState['currentCurrency'];
54
+ networkConfigurationsByChainId: NetworkState['networkConfigurationsByChainId'];
55
+ accountsByChainId: Record<Hex, Record<Hex, {
56
+ balance: Hex | null;
57
+ }>>;
58
+ };
59
+ export declare const selectAssetsBySelectedAccountGroup: ((state: AssetListState) => AccountGroupAssets) & {
60
+ clearCache: () => void;
61
+ resultsCount: () => number;
62
+ resetResultsCount: () => void;
63
+ } & {
64
+ resultFunc: (resultFuncArgs_0: AssetsByAccountGroup, resultFuncArgs_1: {
65
+ wallets: {
66
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
67
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
68
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
69
+ };
70
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
71
+ }) => AccountGroupAssets;
72
+ memoizedResultFunc: ((resultFuncArgs_0: AssetsByAccountGroup, resultFuncArgs_1: {
73
+ wallets: {
74
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
75
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
76
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
77
+ };
78
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
79
+ }) => AccountGroupAssets) & {
80
+ clearCache: () => void;
81
+ resultsCount: () => number;
82
+ resetResultsCount: () => void;
83
+ };
84
+ lastResult: () => AccountGroupAssets;
85
+ dependencies: [((state: AssetListState) => AssetsByAccountGroup) & {
86
+ clearCache: () => void;
87
+ resultsCount: () => number;
88
+ resetResultsCount: () => void;
89
+ } & {
90
+ resultFunc: (resultFuncArgs_0: AssetsByAccountGroup, resultFuncArgs_1: AssetsByAccountGroup, resultFuncArgs_2: AssetsByAccountGroup) => AssetsByAccountGroup;
91
+ memoizedResultFunc: ((resultFuncArgs_0: AssetsByAccountGroup, resultFuncArgs_1: AssetsByAccountGroup, resultFuncArgs_2: AssetsByAccountGroup) => AssetsByAccountGroup) & {
92
+ clearCache: () => void;
93
+ resultsCount: () => number;
94
+ resetResultsCount: () => void;
95
+ };
96
+ lastResult: () => AssetsByAccountGroup;
97
+ dependencies: [((state: AssetListState) => AssetsByAccountGroup) & {
98
+ clearCache: () => void;
99
+ resultsCount: () => number;
100
+ resetResultsCount: () => void;
101
+ } & {
102
+ resultFunc: (resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: {
103
+ [chainId: `0x${string}`]: {
104
+ [key: string]: Token[];
105
+ };
106
+ }, resultFuncArgs_2: {
107
+ [chainId: `0x${string}`]: {
108
+ [key: string]: string[];
109
+ };
110
+ }, resultFuncArgs_3: import("../TokenBalancesController.cjs").TokenBalances, resultFuncArgs_4: Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, resultFuncArgs_5: Record<string, {
111
+ conversionDate: number | null;
112
+ conversionRate: number | null;
113
+ usdConversionRate: number | null;
114
+ }>, resultFuncArgs_6: string) => AssetsByAccountGroup;
115
+ memoizedResultFunc: ((resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: {
116
+ [chainId: `0x${string}`]: {
117
+ [key: string]: Token[];
118
+ };
119
+ }, resultFuncArgs_2: {
120
+ [chainId: `0x${string}`]: {
121
+ [key: string]: string[];
122
+ };
123
+ }, resultFuncArgs_3: import("../TokenBalancesController.cjs").TokenBalances, resultFuncArgs_4: Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, resultFuncArgs_5: Record<string, {
124
+ conversionDate: number | null;
125
+ conversionRate: number | null;
126
+ usdConversionRate: number | null;
127
+ }>, resultFuncArgs_6: string) => AssetsByAccountGroup) & {
128
+ clearCache: () => void;
129
+ resultsCount: () => number;
130
+ resetResultsCount: () => void;
131
+ };
132
+ lastResult: () => AssetsByAccountGroup;
133
+ dependencies: [((state: AssetListState) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
134
+ clearCache: () => void;
135
+ resultsCount: () => number;
136
+ resetResultsCount: () => void;
137
+ } & {
138
+ resultFunc: (resultFuncArgs_0: {
139
+ wallets: {
140
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
141
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
142
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
143
+ };
144
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
145
+ }, resultFuncArgs_1: {
146
+ accounts: Record<string, {
147
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
148
+ id: string;
149
+ options: Record<string, import("@metamask/utils").Json> & {
150
+ entropy?: {
151
+ type: "mnemonic";
152
+ id: string;
153
+ derivationPath: string;
154
+ groupIndex: number;
155
+ } | {
156
+ type: "private-key";
157
+ } | undefined;
158
+ exportable?: boolean | undefined;
159
+ };
160
+ metadata: {
161
+ name: string;
162
+ importTime: number;
163
+ keyring: {
164
+ type: string;
165
+ };
166
+ nameLastUpdatedAt?: number | undefined;
167
+ snap?: {
168
+ name: string;
169
+ id: string;
170
+ enabled: boolean;
171
+ } | undefined;
172
+ lastSelected?: number | undefined;
173
+ };
174
+ address: string;
175
+ scopes: `${string}:${string}`[];
176
+ methods: string[];
177
+ }>;
178
+ selectedAccount: string;
179
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
180
+ memoizedResultFunc: ((resultFuncArgs_0: {
181
+ wallets: {
182
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
183
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
184
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
185
+ };
186
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
187
+ }, resultFuncArgs_1: {
188
+ accounts: Record<string, {
189
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
190
+ id: string;
191
+ options: Record<string, import("@metamask/utils").Json> & {
192
+ entropy?: {
193
+ type: "mnemonic";
194
+ id: string;
195
+ derivationPath: string;
196
+ groupIndex: number;
197
+ } | {
198
+ type: "private-key";
199
+ } | undefined;
200
+ exportable?: boolean | undefined;
201
+ };
202
+ metadata: {
203
+ name: string;
204
+ importTime: number;
205
+ keyring: {
206
+ type: string;
207
+ };
208
+ nameLastUpdatedAt?: number | undefined;
209
+ snap?: {
210
+ name: string;
211
+ id: string;
212
+ enabled: boolean;
213
+ } | undefined;
214
+ lastSelected?: number | undefined;
215
+ };
216
+ address: string;
217
+ scopes: `${string}:${string}`[];
218
+ methods: string[];
219
+ }>;
220
+ selectedAccount: string;
221
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
222
+ clearCache: () => void;
223
+ resultsCount: () => number;
224
+ resetResultsCount: () => void;
225
+ };
226
+ lastResult: () => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
227
+ dependencies: [(state: AssetListState) => {
228
+ wallets: {
229
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
230
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
231
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
232
+ };
233
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
234
+ }, (state: AssetListState) => {
235
+ accounts: Record<string, {
236
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
237
+ id: string;
238
+ options: Record<string, import("@metamask/utils").Json> & {
239
+ entropy?: {
240
+ type: "mnemonic";
241
+ id: string;
242
+ derivationPath: string;
243
+ groupIndex: number;
244
+ } | {
245
+ type: "private-key";
246
+ } | undefined;
247
+ exportable?: boolean | undefined;
248
+ };
249
+ metadata: {
250
+ name: string;
251
+ importTime: number;
252
+ keyring: {
253
+ type: string;
254
+ };
255
+ nameLastUpdatedAt?: number | undefined;
256
+ snap?: {
257
+ name: string;
258
+ id: string;
259
+ enabled: boolean;
260
+ } | undefined;
261
+ lastSelected?: number | undefined;
262
+ };
263
+ address: string;
264
+ scopes: `${string}:${string}`[];
265
+ methods: string[];
266
+ }>;
267
+ selectedAccount: string;
268
+ }];
269
+ recomputations: () => number;
270
+ resetRecomputations: () => void;
271
+ dependencyRecomputations: () => number;
272
+ resetDependencyRecomputations: () => void;
273
+ } & {
274
+ argsMemoize: typeof import("reselect").weakMapMemoize;
275
+ memoize: typeof import("reselect").weakMapMemoize;
276
+ }, (state: AssetListState) => {
277
+ [chainId: `0x${string}`]: {
278
+ [key: string]: Token[];
279
+ };
280
+ }, (state: AssetListState) => {
281
+ [chainId: `0x${string}`]: {
282
+ [key: string]: string[];
283
+ };
284
+ }, (state: AssetListState) => import("../TokenBalancesController.cjs").TokenBalances, (state: AssetListState) => Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, (state: AssetListState) => Record<string, {
285
+ conversionDate: number | null;
286
+ conversionRate: number | null;
287
+ usdConversionRate: number | null;
288
+ }>, (state: AssetListState) => string];
289
+ recomputations: () => number;
290
+ resetRecomputations: () => void;
291
+ dependencyRecomputations: () => number;
292
+ resetDependencyRecomputations: () => void;
293
+ } & {
294
+ argsMemoize: typeof import("reselect").weakMapMemoize;
295
+ memoize: typeof import("reselect").weakMapMemoize;
296
+ }, ((state: AssetListState) => AssetsByAccountGroup) & {
297
+ clearCache: () => void;
298
+ resultsCount: () => number;
299
+ resetResultsCount: () => void;
300
+ } & {
301
+ resultFunc: (resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: {
302
+ [account: string]: `${string}:${string}/${string}:${string}`[];
303
+ }, resultFuncArgs_2: {
304
+ [asset: `${string}:${string}/${string}:${string}`]: {
305
+ fungible: true;
306
+ iconUrl: string;
307
+ units: {
308
+ decimals: number;
309
+ symbol?: string | undefined;
310
+ name?: string | undefined;
311
+ }[];
312
+ symbol?: string | undefined;
313
+ name?: string | undefined;
314
+ };
315
+ }, resultFuncArgs_3: {
316
+ [account: string]: {
317
+ [asset: string]: {
318
+ amount: string;
319
+ unit: string;
320
+ };
321
+ };
322
+ }, resultFuncArgs_4: Record<`${string}:${string}/${string}:${string}`, import("@metamask/snaps-sdk").AssetConversion & {
323
+ marketData?: import("@metamask/snaps-sdk").FungibleAssetMarketData | undefined;
324
+ }>, resultFuncArgs_5: string) => AssetsByAccountGroup;
325
+ memoizedResultFunc: ((resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: {
326
+ [account: string]: `${string}:${string}/${string}:${string}`[];
327
+ }, resultFuncArgs_2: {
328
+ [asset: `${string}:${string}/${string}:${string}`]: {
329
+ fungible: true;
330
+ iconUrl: string;
331
+ units: {
332
+ decimals: number;
333
+ symbol?: string | undefined;
334
+ name?: string | undefined;
335
+ }[];
336
+ symbol?: string | undefined;
337
+ name?: string | undefined;
338
+ };
339
+ }, resultFuncArgs_3: {
340
+ [account: string]: {
341
+ [asset: string]: {
342
+ amount: string;
343
+ unit: string;
344
+ };
345
+ };
346
+ }, resultFuncArgs_4: Record<`${string}:${string}/${string}:${string}`, import("@metamask/snaps-sdk").AssetConversion & {
347
+ marketData?: import("@metamask/snaps-sdk").FungibleAssetMarketData | undefined;
348
+ }>, resultFuncArgs_5: string) => AssetsByAccountGroup) & {
349
+ clearCache: () => void;
350
+ resultsCount: () => number;
351
+ resetResultsCount: () => void;
352
+ };
353
+ lastResult: () => AssetsByAccountGroup;
354
+ dependencies: [((state: AssetListState) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
355
+ clearCache: () => void;
356
+ resultsCount: () => number;
357
+ resetResultsCount: () => void;
358
+ } & {
359
+ resultFunc: (resultFuncArgs_0: {
360
+ wallets: {
361
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
362
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
363
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
364
+ };
365
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
366
+ }, resultFuncArgs_1: {
367
+ accounts: Record<string, {
368
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
369
+ id: string;
370
+ options: Record<string, import("@metamask/utils").Json> & {
371
+ entropy?: {
372
+ type: "mnemonic";
373
+ id: string;
374
+ derivationPath: string;
375
+ groupIndex: number;
376
+ } | {
377
+ type: "private-key";
378
+ } | undefined;
379
+ exportable?: boolean | undefined;
380
+ };
381
+ metadata: {
382
+ name: string;
383
+ importTime: number;
384
+ keyring: {
385
+ type: string;
386
+ };
387
+ nameLastUpdatedAt?: number | undefined;
388
+ snap?: {
389
+ name: string;
390
+ id: string;
391
+ enabled: boolean;
392
+ } | undefined;
393
+ lastSelected?: number | undefined;
394
+ };
395
+ address: string;
396
+ scopes: `${string}:${string}`[];
397
+ methods: string[];
398
+ }>;
399
+ selectedAccount: string;
400
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
401
+ memoizedResultFunc: ((resultFuncArgs_0: {
402
+ wallets: {
403
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
404
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
405
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
406
+ };
407
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
408
+ }, resultFuncArgs_1: {
409
+ accounts: Record<string, {
410
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
411
+ id: string;
412
+ options: Record<string, import("@metamask/utils").Json> & {
413
+ entropy?: {
414
+ type: "mnemonic";
415
+ id: string;
416
+ derivationPath: string;
417
+ groupIndex: number;
418
+ } | {
419
+ type: "private-key";
420
+ } | undefined;
421
+ exportable?: boolean | undefined;
422
+ };
423
+ metadata: {
424
+ name: string;
425
+ importTime: number;
426
+ keyring: {
427
+ type: string;
428
+ };
429
+ nameLastUpdatedAt?: number | undefined;
430
+ snap?: {
431
+ name: string;
432
+ id: string;
433
+ enabled: boolean;
434
+ } | undefined;
435
+ lastSelected?: number | undefined;
436
+ };
437
+ address: string;
438
+ scopes: `${string}:${string}`[];
439
+ methods: string[];
440
+ }>;
441
+ selectedAccount: string;
442
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
443
+ clearCache: () => void;
444
+ resultsCount: () => number;
445
+ resetResultsCount: () => void;
446
+ };
447
+ lastResult: () => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
448
+ dependencies: [(state: AssetListState) => {
449
+ wallets: {
450
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
451
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
452
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
453
+ };
454
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
455
+ }, (state: AssetListState) => {
456
+ accounts: Record<string, {
457
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
458
+ id: string;
459
+ options: Record<string, import("@metamask/utils").Json> & {
460
+ entropy?: {
461
+ type: "mnemonic";
462
+ id: string;
463
+ derivationPath: string;
464
+ groupIndex: number;
465
+ } | {
466
+ type: "private-key";
467
+ } | undefined;
468
+ exportable?: boolean | undefined;
469
+ };
470
+ metadata: {
471
+ name: string;
472
+ importTime: number;
473
+ keyring: {
474
+ type: string;
475
+ };
476
+ nameLastUpdatedAt?: number | undefined;
477
+ snap?: {
478
+ name: string;
479
+ id: string;
480
+ enabled: boolean;
481
+ } | undefined;
482
+ lastSelected?: number | undefined;
483
+ };
484
+ address: string;
485
+ scopes: `${string}:${string}`[];
486
+ methods: string[];
487
+ }>;
488
+ selectedAccount: string;
489
+ }];
490
+ recomputations: () => number;
491
+ resetRecomputations: () => void;
492
+ dependencyRecomputations: () => number;
493
+ resetDependencyRecomputations: () => void;
494
+ } & {
495
+ argsMemoize: typeof import("reselect").weakMapMemoize;
496
+ memoize: typeof import("reselect").weakMapMemoize;
497
+ }, (state: AssetListState) => {
498
+ [account: string]: `${string}:${string}/${string}:${string}`[];
499
+ }, (state: AssetListState) => {
500
+ [asset: `${string}:${string}/${string}:${string}`]: {
501
+ fungible: true;
502
+ iconUrl: string;
503
+ units: {
504
+ decimals: number;
505
+ symbol?: string | undefined;
506
+ name?: string | undefined;
507
+ }[];
508
+ symbol?: string | undefined;
509
+ name?: string | undefined;
510
+ };
511
+ }, (state: AssetListState) => {
512
+ [account: string]: {
513
+ [asset: string]: {
514
+ amount: string;
515
+ unit: string;
516
+ };
517
+ };
518
+ }, (state: AssetListState) => Record<`${string}:${string}/${string}:${string}`, import("@metamask/snaps-sdk").AssetConversion & {
519
+ marketData?: import("@metamask/snaps-sdk").FungibleAssetMarketData | undefined;
520
+ }>, (state: AssetListState) => string];
521
+ recomputations: () => number;
522
+ resetRecomputations: () => void;
523
+ dependencyRecomputations: () => number;
524
+ resetDependencyRecomputations: () => void;
525
+ } & {
526
+ argsMemoize: typeof import("reselect").weakMapMemoize;
527
+ memoize: typeof import("reselect").weakMapMemoize;
528
+ }, ((state: AssetListState) => AssetsByAccountGroup) & {
529
+ clearCache: () => void;
530
+ resultsCount: () => number;
531
+ resetResultsCount: () => void;
532
+ } & {
533
+ resultFunc: (resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: Record<`0x${string}`, Record<`0x${string}`, {
534
+ balance: Hex | null;
535
+ }>>, resultFuncArgs_2: Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, resultFuncArgs_3: Record<string, {
536
+ conversionDate: number | null;
537
+ conversionRate: number | null;
538
+ usdConversionRate: number | null;
539
+ }>, resultFuncArgs_4: string, resultFuncArgs_5: Record<`0x${string}`, import("@metamask/network-controller").NetworkConfiguration>) => AssetsByAccountGroup;
540
+ memoizedResultFunc: ((resultFuncArgs_0: Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>, resultFuncArgs_1: Record<`0x${string}`, Record<`0x${string}`, {
541
+ balance: Hex | null;
542
+ }>>, resultFuncArgs_2: Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, resultFuncArgs_3: Record<string, {
543
+ conversionDate: number | null;
544
+ conversionRate: number | null;
545
+ usdConversionRate: number | null;
546
+ }>, resultFuncArgs_4: string, resultFuncArgs_5: Record<`0x${string}`, import("@metamask/network-controller").NetworkConfiguration>) => AssetsByAccountGroup) & {
547
+ clearCache: () => void;
548
+ resultsCount: () => number;
549
+ resetResultsCount: () => void;
550
+ };
551
+ lastResult: () => AssetsByAccountGroup;
552
+ dependencies: [((state: AssetListState) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
553
+ clearCache: () => void;
554
+ resultsCount: () => number;
555
+ resetResultsCount: () => void;
556
+ } & {
557
+ resultFunc: (resultFuncArgs_0: {
558
+ wallets: {
559
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
560
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
561
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
562
+ };
563
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
564
+ }, resultFuncArgs_1: {
565
+ accounts: Record<string, {
566
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
567
+ id: string;
568
+ options: Record<string, import("@metamask/utils").Json> & {
569
+ entropy?: {
570
+ type: "mnemonic";
571
+ id: string;
572
+ derivationPath: string;
573
+ groupIndex: number;
574
+ } | {
575
+ type: "private-key";
576
+ } | undefined;
577
+ exportable?: boolean | undefined;
578
+ };
579
+ metadata: {
580
+ name: string;
581
+ importTime: number;
582
+ keyring: {
583
+ type: string;
584
+ };
585
+ nameLastUpdatedAt?: number | undefined;
586
+ snap?: {
587
+ name: string;
588
+ id: string;
589
+ enabled: boolean;
590
+ } | undefined;
591
+ lastSelected?: number | undefined;
592
+ };
593
+ address: string;
594
+ scopes: `${string}:${string}`[];
595
+ methods: string[];
596
+ }>;
597
+ selectedAccount: string;
598
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
599
+ memoizedResultFunc: ((resultFuncArgs_0: {
600
+ wallets: {
601
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
602
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
603
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
604
+ };
605
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
606
+ }, resultFuncArgs_1: {
607
+ accounts: Record<string, {
608
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
609
+ id: string;
610
+ options: Record<string, import("@metamask/utils").Json> & {
611
+ entropy?: {
612
+ type: "mnemonic";
613
+ id: string;
614
+ derivationPath: string;
615
+ groupIndex: number;
616
+ } | {
617
+ type: "private-key";
618
+ } | undefined;
619
+ exportable?: boolean | undefined;
620
+ };
621
+ metadata: {
622
+ name: string;
623
+ importTime: number;
624
+ keyring: {
625
+ type: string;
626
+ };
627
+ nameLastUpdatedAt?: number | undefined;
628
+ snap?: {
629
+ name: string;
630
+ id: string;
631
+ enabled: boolean;
632
+ } | undefined;
633
+ lastSelected?: number | undefined;
634
+ };
635
+ address: string;
636
+ scopes: `${string}:${string}`[];
637
+ methods: string[];
638
+ }>;
639
+ selectedAccount: string;
640
+ }) => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>) & {
641
+ clearCache: () => void;
642
+ resultsCount: () => number;
643
+ resetResultsCount: () => void;
644
+ };
645
+ lastResult: () => Record<string, `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`>;
646
+ dependencies: [(state: AssetListState) => {
647
+ wallets: {
648
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
649
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
650
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
651
+ };
652
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
653
+ }, (state: AssetListState) => {
654
+ accounts: Record<string, {
655
+ type: "eip155:eoa" | "eip155:erc4337" | "bip122:p2pkh" | "bip122:p2sh" | "bip122:p2wpkh" | "bip122:p2tr" | "solana:data-account" | "tron:eoa" | "any:account";
656
+ id: string;
657
+ options: Record<string, import("@metamask/utils").Json> & {
658
+ entropy?: {
659
+ type: "mnemonic";
660
+ id: string;
661
+ derivationPath: string;
662
+ groupIndex: number;
663
+ } | {
664
+ type: "private-key";
665
+ } | undefined;
666
+ exportable?: boolean | undefined;
667
+ };
668
+ metadata: {
669
+ name: string;
670
+ importTime: number;
671
+ keyring: {
672
+ type: string;
673
+ };
674
+ nameLastUpdatedAt?: number | undefined;
675
+ snap?: {
676
+ name: string;
677
+ id: string;
678
+ enabled: boolean;
679
+ } | undefined;
680
+ lastSelected?: number | undefined;
681
+ };
682
+ address: string;
683
+ scopes: `${string}:${string}`[];
684
+ methods: string[];
685
+ }>;
686
+ selectedAccount: string;
687
+ }];
688
+ recomputations: () => number;
689
+ resetRecomputations: () => void;
690
+ dependencyRecomputations: () => number;
691
+ resetDependencyRecomputations: () => void;
692
+ } & {
693
+ argsMemoize: typeof import("reselect").weakMapMemoize;
694
+ memoize: typeof import("reselect").weakMapMemoize;
695
+ }, (state: AssetListState) => Record<`0x${string}`, Record<`0x${string}`, {
696
+ balance: Hex | null;
697
+ }>>, (state: AssetListState) => Record<`0x${string}`, Record<`0x${string}`, import("../TokenRatesController.cjs").MarketDataDetails>>, (state: AssetListState) => Record<string, {
698
+ conversionDate: number | null;
699
+ conversionRate: number | null;
700
+ usdConversionRate: number | null;
701
+ }>, (state: AssetListState) => string, (state: AssetListState) => Record<`0x${string}`, import("@metamask/network-controller").NetworkConfiguration>];
702
+ recomputations: () => number;
703
+ resetRecomputations: () => void;
704
+ dependencyRecomputations: () => number;
705
+ resetDependencyRecomputations: () => void;
706
+ } & {
707
+ argsMemoize: typeof import("reselect").weakMapMemoize;
708
+ memoize: typeof import("reselect").weakMapMemoize;
709
+ }];
710
+ recomputations: () => number;
711
+ resetRecomputations: () => void;
712
+ dependencyRecomputations: () => number;
713
+ resetDependencyRecomputations: () => void;
714
+ } & {
715
+ argsMemoize: typeof import("reselect").weakMapMemoize;
716
+ memoize: typeof import("reselect").weakMapMemoize;
717
+ }, (state: AssetListState) => {
718
+ wallets: {
719
+ [walletId: `entropy:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
720
+ [walletId: `keyring:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
721
+ [walletId: `snap:${string}`]: import("../../../account-tree-controller/src/wallet.cjs").AccountWalletEntropyObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletSnapObject | import("../../../account-tree-controller/src/wallet.cjs").AccountWalletKeyringObject;
722
+ };
723
+ selectedAccountGroup: "" | `entropy:${string}/${string}` | `keyring:${string}/${string}` | `snap:${string}/${string}`;
724
+ }];
725
+ recomputations: () => number;
726
+ resetRecomputations: () => void;
727
+ dependencyRecomputations: () => number;
728
+ resetDependencyRecomputations: () => void;
729
+ } & {
730
+ argsMemoize: typeof import("reselect").weakMapMemoize;
731
+ memoize: typeof import("reselect").weakMapMemoize;
732
+ };
733
+ export {};
734
+ //# sourceMappingURL=token-selectors.d.cts.map