@talken/talkenkit 2.5.0 → 2.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AbcCredentialManager-DDHLW2IH.js → AbcCredentialManager-5W3B7GI4.js} +1 -1
- package/dist/{abcWallet-5GTT47V6.js → abcWallet-O5IRLUXL.js} +2 -2
- package/dist/{chunk-ALBABQ53.js → chunk-PN6K4CMZ.js} +4 -1
- package/dist/{chunk-REVMSQIO.js → chunk-UHZL3WSM.js} +465 -58
- package/dist/components/TransactionResultModal/TransactionResultModal.css.d.ts +17 -0
- package/dist/components/TransactionResultModal/TransactionResultModal.d.ts +9 -0
- package/dist/index.css +138 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1344 -980
- package/dist/providers/TransactionResultProvider/TransactionResultContext.d.ts +6 -0
- package/dist/providers/TransactionResultProvider/TransactionResultProvider.d.ts +7 -0
- package/dist/providers/TransactionResultProvider/TransactionResultSingleton.d.ts +16 -0
- package/dist/providers/TransactionResultProvider/index.d.ts +4 -0
- package/dist/providers/TransactionResultProvider/types.d.ts +14 -0
- package/dist/wallets/walletConnectors/abcWallet/AbcCredentialManager.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/AbcEvmAutoConnector.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/abcAccessKeyProvider.d.ts +29 -3
- package/dist/wallets/walletConnectors/abcWallet/abcAccessKeyProvider.js +4 -4
- package/dist/wallets/walletConnectors/abcWallet/abcBitcoinConnector.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/abcBitcoinProvider.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/abcConnector.js +8 -8
- package/dist/wallets/walletConnectors/abcWallet/abcProvider.d.ts +8 -0
- package/dist/wallets/walletConnectors/abcWallet/abcProvider.js +5 -5
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaProvider.d.ts +1 -0
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaProvider.js +8 -8
- package/dist/wallets/walletConnectors/abcWallet/abcSolanaWalletAdapter.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/abcTronProvider.d.ts +1 -0
- package/dist/wallets/walletConnectors/abcWallet/abcTronProvider.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/abcWallet.js +9 -9
- package/dist/wallets/walletConnectors/abcWallet/api/ConfigApi.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiClient.d.ts +25 -0
- package/dist/wallets/walletConnectors/abcWallet/api/TalkenApiClient.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/api/TokenApi.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/api/WalletscanApi.js +3 -3
- package/dist/wallets/walletConnectors/abcWallet/api/index.js +9 -9
- package/dist/wallets/walletConnectors/abcWallet/constants.d.ts +3 -0
- package/dist/wallets/walletConnectors/abcWallet/constants.js +1 -1
- package/dist/wallets/walletConnectors/abcWallet/index.d.ts +1 -1
- package/dist/wallets/walletConnectors/abcWallet/index.js +34 -34
- package/dist/wallets/walletConnectors/abcWallet/sessionUtils.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/types.d.ts +9 -0
- package/dist/wallets/walletConnectors/abcWallet/utils.js +2 -2
- package/dist/wallets/walletConnectors/abcWallet/walletGeneration.js +3 -3
- package/dist/wallets/walletConnectors/{chunk-VDWJ3NQ5.js → chunk-25ZDAJ3L.js} +1 -1
- package/dist/wallets/walletConnectors/chunk-4JZPP3S7.js +380 -0
- package/dist/wallets/walletConnectors/{chunk-HWXOTEC3.js → chunk-4YEALKXG.js} +66 -16
- package/dist/wallets/walletConnectors/{chunk-IN3HEGZM.js → chunk-645DT4TS.js} +46 -5
- package/dist/wallets/walletConnectors/{chunk-QSP2A4LA.js → chunk-6TAU7OQK.js} +3 -3
- package/dist/wallets/walletConnectors/{chunk-MO2AXXLI.js → chunk-FKI5AZVH.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-JADQLTFW.js → chunk-H2AZTZMM.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-NULM3THX.js → chunk-HWRZGGGN.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-BHEVY4QY.js → chunk-KIYXONNH.js} +35 -2
- package/dist/wallets/walletConnectors/{chunk-TQHS6APN.js → chunk-L6FCF3FH.js} +89 -7
- package/dist/wallets/walletConnectors/{chunk-ACLPF2UW.js → chunk-LIGH2LEU.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-K66HU6GX.js → chunk-OASBABPG.js} +15 -1
- package/dist/wallets/walletConnectors/{chunk-A66MTFML.js → chunk-PF65YS3T.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-6WF4SXLB.js → chunk-QKK3OPQA.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-3LF7FVL6.js → chunk-RGYZNNB6.js} +1 -1
- package/dist/wallets/walletConnectors/{chunk-DPTDOCWL.js → chunk-RX2VOIUB.js} +4 -1
- package/dist/wallets/walletConnectors/{chunk-YV6IZWGE.js → chunk-URS2KVYK.js} +45 -2
- package/dist/wallets/walletConnectors/{chunk-BXH3GDX5.js → chunk-YKFI6ZGM.js} +1 -1
- package/dist/wallets/walletConnectors/index.js +36 -36
- package/package.json +1 -1
- package/dist/wallets/walletConnectors/chunk-S2SQYPGR.js +0 -220
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "./chunk-4P3SPC44.js";
|
|
11
11
|
import {
|
|
12
12
|
getCredentialManager
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-QKK3OPQA.js";
|
|
14
14
|
|
|
15
15
|
// src/wallets/walletConnectors/abcWallet/walletGeneration.ts
|
|
16
16
|
import { getTalkenApiClient } from "@talken/talkenkit";
|
|
@@ -4,12 +4,12 @@ import {
|
|
|
4
4
|
} from "./chunk-4P3SPC44.js";
|
|
5
5
|
import {
|
|
6
6
|
getCredentialManager
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-QKK3OPQA.js";
|
|
8
8
|
import {
|
|
9
9
|
DEFAULT_TALKEN_API_CONFIG,
|
|
10
10
|
TALKEN_API_ENDPOINTS,
|
|
11
11
|
TOKEN_EXPIRY
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-RX2VOIUB.js";
|
|
13
13
|
|
|
14
14
|
// src/wallets/walletConnectors/abcWallet/api/TalkenApiClient.ts
|
|
15
15
|
var STORAGE_KEY_PREFIX = "talken_api_";
|
|
@@ -365,6 +365,21 @@ var TalkenEvmModule = class {
|
|
|
365
365
|
const qs = new URLSearchParams({ network, address }).toString();
|
|
366
366
|
return this.client.get(`${TALKEN_API_ENDPOINTS.NONCE}?${qs}`);
|
|
367
367
|
}
|
|
368
|
+
/**
|
|
369
|
+
* Get native balance for address
|
|
370
|
+
* GET /wallet/address/balance?network=&address=
|
|
371
|
+
*/
|
|
372
|
+
async getBalance(network, address) {
|
|
373
|
+
const qs = new URLSearchParams({ network, address }).toString();
|
|
374
|
+
return this.client.get(`${TALKEN_API_ENDPOINTS.ADDRESS_BALANCE}?${qs}`);
|
|
375
|
+
}
|
|
376
|
+
/**
|
|
377
|
+
* Execute read-only eth_call
|
|
378
|
+
* POST /wallet/contract/eth-call { network, to, data, from? }
|
|
379
|
+
*/
|
|
380
|
+
async ethCall(params) {
|
|
381
|
+
return this.client.post(TALKEN_API_ENDPOINTS.ETH_CALL, params);
|
|
382
|
+
}
|
|
368
383
|
};
|
|
369
384
|
var TalkenSolanaModule = class {
|
|
370
385
|
constructor(client) {
|
|
@@ -536,6 +551,24 @@ var TalkenTronModule = class {
|
|
|
536
551
|
params
|
|
537
552
|
);
|
|
538
553
|
}
|
|
554
|
+
/**
|
|
555
|
+
* Get TRON account info (balance, resource, permissions)
|
|
556
|
+
* GET /wallet/tron?mode=account&network=&address=
|
|
557
|
+
*/
|
|
558
|
+
async getAccount(network, address) {
|
|
559
|
+
return this.client.get(
|
|
560
|
+
`${TALKEN_API_ENDPOINTS.TRON_UTIL}?mode=account&network=${encodeURIComponent(network)}&address=${encodeURIComponent(address)}`
|
|
561
|
+
);
|
|
562
|
+
}
|
|
563
|
+
/**
|
|
564
|
+
* Get TRC20 token balance
|
|
565
|
+
* GET /wallet/tron?mode=trc20Balance&network=&address=&contractAddress=
|
|
566
|
+
*/
|
|
567
|
+
async getTrc20Balance(network, address, contractAddress) {
|
|
568
|
+
return this.client.get(
|
|
569
|
+
`${TALKEN_API_ENDPOINTS.TRON_UTIL}?mode=trc20Balance&network=${encodeURIComponent(network)}&address=${encodeURIComponent(address)}&contractAddress=${encodeURIComponent(contractAddress)}`
|
|
570
|
+
);
|
|
571
|
+
}
|
|
539
572
|
};
|
|
540
573
|
var TalkenWalletscanModule = class {
|
|
541
574
|
constructor(client) {
|
|
@@ -1,21 +1,26 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
getChainKey,
|
|
4
|
+
getExplorerTxUrl,
|
|
4
5
|
getNetworkName
|
|
5
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-OASBABPG.js";
|
|
6
7
|
import {
|
|
7
8
|
hexToNumber,
|
|
8
9
|
numberToHex
|
|
9
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-PF65YS3T.js";
|
|
10
11
|
import {
|
|
11
12
|
TalkenApiError
|
|
12
13
|
} from "./chunk-4P3SPC44.js";
|
|
13
14
|
import {
|
|
14
15
|
getCredentialManager
|
|
15
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-QKK3OPQA.js";
|
|
16
17
|
|
|
17
18
|
// src/wallets/walletConnectors/abcWallet/abcProvider.ts
|
|
18
|
-
import {
|
|
19
|
+
import {
|
|
20
|
+
getShowPendingTransaction,
|
|
21
|
+
getTalkenApiClient,
|
|
22
|
+
getUpdateTransactionResult
|
|
23
|
+
} from "@talken/talkenkit";
|
|
19
24
|
import { parseGwei } from "viem";
|
|
20
25
|
var EventEmitter = class {
|
|
21
26
|
constructor() {
|
|
@@ -260,10 +265,12 @@ var AbcEvmProvider = class extends EventEmitter {
|
|
|
260
265
|
return this.eth_getTransactionCount(
|
|
261
266
|
Array.isArray(params) ? params : []
|
|
262
267
|
);
|
|
263
|
-
case "eth_blockNumber":
|
|
264
268
|
case "eth_call":
|
|
265
|
-
|
|
269
|
+
return this.eth_call(params);
|
|
266
270
|
case "eth_getBalance":
|
|
271
|
+
return this.eth_getBalance(params);
|
|
272
|
+
case "eth_blockNumber":
|
|
273
|
+
case "eth_gasPrice":
|
|
267
274
|
case "eth_getBlockByHash":
|
|
268
275
|
case "eth_getBlockByNumber":
|
|
269
276
|
case "eth_getCode":
|
|
@@ -386,10 +393,20 @@ var AbcEvmProvider = class extends EventEmitter {
|
|
|
386
393
|
const hexValue = tx.value || "0x0";
|
|
387
394
|
const amountWei = BigInt(hexValue).toString();
|
|
388
395
|
const email = this.getRecoveryEmail();
|
|
396
|
+
const chainKey = getChainKey(this.chainId);
|
|
397
|
+
const showPending = getShowPendingTransaction();
|
|
398
|
+
if (showPending) {
|
|
399
|
+
showPending({
|
|
400
|
+
txHash: "",
|
|
401
|
+
network: chainKey,
|
|
402
|
+
chain: "evm",
|
|
403
|
+
explorerUrl: void 0
|
|
404
|
+
});
|
|
405
|
+
}
|
|
389
406
|
const api = this.getTalkenApiClientOrThrow();
|
|
390
407
|
const result = await this.withSigningCredentialRetry(
|
|
391
408
|
() => api.evm.sendTransaction({
|
|
392
|
-
chainKey
|
|
409
|
+
chainKey,
|
|
393
410
|
to: tx.to,
|
|
394
411
|
amountWei,
|
|
395
412
|
pin: pinHash,
|
|
@@ -397,9 +414,20 @@ var AbcEvmProvider = class extends EventEmitter {
|
|
|
397
414
|
gasLimit: tx.gas || tx.gasLimit,
|
|
398
415
|
maxFeePerGas: tx.maxFeePerGas,
|
|
399
416
|
maxPriorityFeePerGas: tx.maxPriorityFeePerGas,
|
|
417
|
+
waitForReceipt: true,
|
|
400
418
|
...email && { email }
|
|
401
419
|
})
|
|
402
420
|
);
|
|
421
|
+
const updateResult = getUpdateTransactionResult();
|
|
422
|
+
if (updateResult) {
|
|
423
|
+
updateResult({
|
|
424
|
+
txHash: result.txHash,
|
|
425
|
+
network: chainKey,
|
|
426
|
+
chain: "evm",
|
|
427
|
+
receipt: result.receipt ?? null,
|
|
428
|
+
explorerUrl: getExplorerTxUrl(this.chainId, result.txHash)
|
|
429
|
+
});
|
|
430
|
+
}
|
|
403
431
|
return result.txHash;
|
|
404
432
|
}
|
|
405
433
|
/**
|
|
@@ -730,6 +758,60 @@ var AbcEvmProvider = class extends EventEmitter {
|
|
|
730
758
|
return "0x5208";
|
|
731
759
|
}
|
|
732
760
|
}
|
|
761
|
+
/**
|
|
762
|
+
* Execute read-only eth_call via talken-api
|
|
763
|
+
*/
|
|
764
|
+
async eth_call(params) {
|
|
765
|
+
const p = Array.isArray(params) ? params : [];
|
|
766
|
+
const tx = p[0];
|
|
767
|
+
if (!tx?.to || !tx?.data) {
|
|
768
|
+
throw new ProviderRpcError(
|
|
769
|
+
ErrorCode.INVALID_PARAMS,
|
|
770
|
+
"eth_call requires to and data"
|
|
771
|
+
);
|
|
772
|
+
}
|
|
773
|
+
try {
|
|
774
|
+
const api = this.getTalkenApiClientOrThrow();
|
|
775
|
+
const response = await api.evm.ethCall({
|
|
776
|
+
network: getNetworkName(this.chainId),
|
|
777
|
+
to: tx.to,
|
|
778
|
+
data: tx.data,
|
|
779
|
+
from: tx.from || this.wallet?.address
|
|
780
|
+
});
|
|
781
|
+
return response?.result ?? response?.data ?? "0x";
|
|
782
|
+
} catch (error) {
|
|
783
|
+
throw new ProviderRpcError(
|
|
784
|
+
ErrorCode.INTERNAL_ERROR,
|
|
785
|
+
`eth_call failed: ${error instanceof Error ? error.message : String(error)}`
|
|
786
|
+
);
|
|
787
|
+
}
|
|
788
|
+
}
|
|
789
|
+
/**
|
|
790
|
+
* Get native balance via talken-api
|
|
791
|
+
*/
|
|
792
|
+
async eth_getBalance(params) {
|
|
793
|
+
const p = Array.isArray(params) ? params : [];
|
|
794
|
+
const address = p[0] || this.wallet?.address;
|
|
795
|
+
if (!address) {
|
|
796
|
+
throw new ProviderRpcError(
|
|
797
|
+
ErrorCode.INVALID_PARAMS,
|
|
798
|
+
"Missing address parameter"
|
|
799
|
+
);
|
|
800
|
+
}
|
|
801
|
+
try {
|
|
802
|
+
const api = this.getTalkenApiClientOrThrow();
|
|
803
|
+
const response = await api.evm.getBalance(
|
|
804
|
+
getNetworkName(this.chainId),
|
|
805
|
+
address
|
|
806
|
+
);
|
|
807
|
+
return response?.balance ?? "0x0";
|
|
808
|
+
} catch (error) {
|
|
809
|
+
throw new ProviderRpcError(
|
|
810
|
+
ErrorCode.INTERNAL_ERROR,
|
|
811
|
+
`eth_getBalance failed: ${error instanceof Error ? error.message : String(error)}`
|
|
812
|
+
);
|
|
813
|
+
}
|
|
814
|
+
}
|
|
733
815
|
/**
|
|
734
816
|
* Check if connected
|
|
735
817
|
*/
|
|
@@ -692,6 +692,12 @@ var NETWORK_BY_PARAM = Object.values(
|
|
|
692
692
|
},
|
|
693
693
|
{}
|
|
694
694
|
);
|
|
695
|
+
function getNetworkByChainId(chainId) {
|
|
696
|
+
return NETWORK_CONFIGS[chainId];
|
|
697
|
+
}
|
|
698
|
+
function getNetworkByParam(network) {
|
|
699
|
+
return NETWORK_BY_PARAM[network];
|
|
700
|
+
}
|
|
695
701
|
function getNetworkName(chainId, fallback = "ethereum") {
|
|
696
702
|
return NETWORK_CONFIGS[chainId]?.network ?? fallback;
|
|
697
703
|
}
|
|
@@ -725,8 +731,16 @@ function getChainKey(chainId) {
|
|
|
725
731
|
}
|
|
726
732
|
return key;
|
|
727
733
|
}
|
|
734
|
+
function getExplorerTxUrl(chainIdOrNetwork, txHash) {
|
|
735
|
+
const config = typeof chainIdOrNetwork === "number" ? getNetworkByChainId(chainIdOrNetwork) : getNetworkByParam(chainIdOrNetwork);
|
|
736
|
+
if (!config) {
|
|
737
|
+
throw new Error(`Unknown network: ${chainIdOrNetwork}`);
|
|
738
|
+
}
|
|
739
|
+
return `${config.explorer}/tx/${txHash}`;
|
|
740
|
+
}
|
|
728
741
|
|
|
729
742
|
export {
|
|
730
743
|
getNetworkName,
|
|
731
|
-
getChainKey
|
|
744
|
+
getChainKey,
|
|
745
|
+
getExplorerTxUrl
|
|
732
746
|
};
|
|
@@ -165,12 +165,15 @@ var TALKEN_API_ENDPOINTS = {
|
|
|
165
165
|
SOLANA_TX_STATUS: "/wallet/solana/tx-status",
|
|
166
166
|
TX_BTC: "/wallet/tx/btc",
|
|
167
167
|
TX_TVM: "/wallet/tx/tvm",
|
|
168
|
+
TRON_UTIL: "/wallet/tron",
|
|
168
169
|
// ── Gas (WaaS proxy) ───────────────────────────────────────────────
|
|
169
170
|
GAS_PRICE: "/wallet/gas/price",
|
|
170
171
|
GAS_SUGGESTED: "/wallet/gas/suggested",
|
|
171
172
|
GAS_ESTIMATE: "/wallet/gas/estimate",
|
|
172
|
-
// ── Nonce (WaaS proxy)
|
|
173
|
+
// ── Nonce / Balance / eth_call (WaaS proxy) ───────────────────────
|
|
173
174
|
NONCE: "/wallet/nonce",
|
|
175
|
+
ADDRESS_BALANCE: "/wallet/address/balance",
|
|
176
|
+
ETH_CALL: "/wallet/contract/eth-call",
|
|
174
177
|
// ── Relayer ────────────────────────────────────────────────────────
|
|
175
178
|
RELAYER_FEE_ESTIMATE: "/relayer/estimate-fee",
|
|
176
179
|
// ── Config / Runtime ───────────────────────────────────────────────
|
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
getCredentialManager
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-QKK3OPQA.js";
|
|
5
5
|
|
|
6
6
|
// src/wallets/walletConnectors/abcWallet/abcTronProvider.ts
|
|
7
|
-
import {
|
|
7
|
+
import {
|
|
8
|
+
getShowPendingTransaction,
|
|
9
|
+
getTalkenApiClient,
|
|
10
|
+
getUpdateTransactionResult
|
|
11
|
+
} from "@talken/talkenkit";
|
|
8
12
|
import { keccak256 } from "viem";
|
|
9
13
|
function isTalkenApiClient(client) {
|
|
10
14
|
return typeof client?.tron?.transferTrx === "function";
|
|
@@ -325,6 +329,7 @@ ${msgBytes.length}`
|
|
|
325
329
|
toAddress: params.toAddress,
|
|
326
330
|
amountSun: amountRaw,
|
|
327
331
|
pin: pinHash,
|
|
332
|
+
waitForConfirmation: true,
|
|
328
333
|
...email && { email }
|
|
329
334
|
} : {
|
|
330
335
|
kind: "trc20",
|
|
@@ -334,10 +339,21 @@ ${msgBytes.length}`
|
|
|
334
339
|
amount: amountRaw,
|
|
335
340
|
feeLimit: params.feeLimit,
|
|
336
341
|
pin: pinHash,
|
|
342
|
+
waitForConfirmation: true,
|
|
337
343
|
...email && { email }
|
|
338
344
|
};
|
|
345
|
+
const showPending = getShowPendingTransaction();
|
|
346
|
+
if (showPending) {
|
|
347
|
+
showPending({
|
|
348
|
+
txHash: "",
|
|
349
|
+
network: this.network.type,
|
|
350
|
+
chain: "tron",
|
|
351
|
+
explorerUrl: void 0
|
|
352
|
+
});
|
|
353
|
+
}
|
|
339
354
|
const result = await api.tron.transferTrx(request);
|
|
340
355
|
const txHash = result.txHash;
|
|
356
|
+
this.updateTransactionResult(result);
|
|
341
357
|
console.log(
|
|
342
358
|
`[TronProvider] \u2705 ${txType === "NATIVE" ? "TRX" : "TRC-20"} transaction complete via TalkenApiClient:`,
|
|
343
359
|
txHash
|
|
@@ -384,6 +400,33 @@ ${msgBytes.length}`
|
|
|
384
400
|
network: this.network.type
|
|
385
401
|
};
|
|
386
402
|
}
|
|
403
|
+
updateTransactionResult(result) {
|
|
404
|
+
const updateResult = getUpdateTransactionResult();
|
|
405
|
+
if (!updateResult)
|
|
406
|
+
return;
|
|
407
|
+
let receipt = result.receipt;
|
|
408
|
+
if (!receipt && result.confirmation) {
|
|
409
|
+
const conf = result.confirmation;
|
|
410
|
+
const info = conf?.info ?? conf;
|
|
411
|
+
const tx = conf?.transaction ?? conf;
|
|
412
|
+
const blockNumber = info?.blockNumber ?? info?.result?.blockNumber ?? null;
|
|
413
|
+
const rcpt = info?.receipt ?? info?.result?.receipt;
|
|
414
|
+
const ret = tx?.ret ?? tx?.result?.ret;
|
|
415
|
+
const contractRet = Array.isArray(ret) ? ret[0]?.contractRet : void 0;
|
|
416
|
+
receipt = {
|
|
417
|
+
status: contractRet === "SUCCESS" ? 1 : contractRet ? 0 : null,
|
|
418
|
+
blockNumber,
|
|
419
|
+
gasUsed: rcpt?.energy_usage_total != null ? String(rcpt.energy_usage_total) : null
|
|
420
|
+
};
|
|
421
|
+
}
|
|
422
|
+
updateResult({
|
|
423
|
+
txHash: result.txHash,
|
|
424
|
+
network: this.network.type,
|
|
425
|
+
chain: "tron",
|
|
426
|
+
receipt,
|
|
427
|
+
explorerUrl: `${this.network.explorer}/#/transaction/${result.txHash}`
|
|
428
|
+
});
|
|
429
|
+
}
|
|
387
430
|
};
|
|
388
431
|
|
|
389
432
|
export {
|
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
bestWallet
|
|
4
|
-
} from "./chunk-OPAPBEA5.js";
|
|
5
2
|
import {
|
|
6
3
|
abcWallet
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import
|
|
4
|
+
} from "./chunk-6TAU7OQK.js";
|
|
5
|
+
import {
|
|
6
|
+
argentWallet
|
|
7
|
+
} from "./chunk-XT2WYPN5.js";
|
|
8
|
+
import "./chunk-4YEALKXG.js";
|
|
9
9
|
import "./chunk-R6ZE7JAZ.js";
|
|
10
10
|
import "./chunk-GFWUFYT2.js";
|
|
11
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-KIYXONNH.js";
|
|
12
|
+
import "./chunk-4JZPP3S7.js";
|
|
12
13
|
import "./chunk-O4AU63LK.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-BHEVY4QY.js";
|
|
14
|
+
import "./chunk-L6FCF3FH.js";
|
|
15
|
+
import "./chunk-OASBABPG.js";
|
|
16
|
+
import "./chunk-PF65YS3T.js";
|
|
17
17
|
import "./chunk-4P3SPC44.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-QKK3OPQA.js";
|
|
19
|
+
import "./chunk-RX2VOIUB.js";
|
|
20
|
+
import {
|
|
21
|
+
tokenaryWallet
|
|
22
|
+
} from "./chunk-U24COF36.js";
|
|
20
23
|
import {
|
|
21
24
|
uniswapWallet
|
|
22
25
|
} from "./chunk-DLDZUVTB.js";
|
|
23
26
|
import {
|
|
24
27
|
valoraWallet
|
|
25
28
|
} from "./chunk-CVUEWUDI.js";
|
|
26
|
-
import {
|
|
27
|
-
walletConnectWallet
|
|
28
|
-
} from "./chunk-KU5R3WAJ.js";
|
|
29
29
|
import {
|
|
30
30
|
wigwamWallet
|
|
31
31
|
} from "./chunk-EFYKBPOB.js";
|
|
32
32
|
import {
|
|
33
|
-
|
|
34
|
-
} from "./chunk-
|
|
33
|
+
walletConnectWallet
|
|
34
|
+
} from "./chunk-KU5R3WAJ.js";
|
|
35
35
|
import {
|
|
36
36
|
zealWallet
|
|
37
37
|
} from "./chunk-SCOX5RF4.js";
|
|
@@ -39,8 +39,11 @@ import {
|
|
|
39
39
|
zerionWallet
|
|
40
40
|
} from "./chunk-53IBFGVW.js";
|
|
41
41
|
import {
|
|
42
|
-
|
|
43
|
-
} from "./chunk-
|
|
42
|
+
xdefiWallet
|
|
43
|
+
} from "./chunk-26RJNF7V.js";
|
|
44
|
+
import {
|
|
45
|
+
safeheronWallet
|
|
46
|
+
} from "./chunk-PHF4VWKP.js";
|
|
44
47
|
import {
|
|
45
48
|
safepalWallet
|
|
46
49
|
} from "./chunk-ATQWOE4J.js";
|
|
@@ -59,9 +62,6 @@ import {
|
|
|
59
62
|
import {
|
|
60
63
|
tokenPocketWallet
|
|
61
64
|
} from "./chunk-5NM2LK2G.js";
|
|
62
|
-
import {
|
|
63
|
-
tokenaryWallet
|
|
64
|
-
} from "./chunk-U24COF36.js";
|
|
65
65
|
import {
|
|
66
66
|
trustWallet
|
|
67
67
|
} from "./chunk-S2PY4MDO.js";
|
|
@@ -87,20 +87,20 @@ import {
|
|
|
87
87
|
roninWallet
|
|
88
88
|
} from "./chunk-D7U5WEH2.js";
|
|
89
89
|
import {
|
|
90
|
-
|
|
91
|
-
} from "./chunk-
|
|
90
|
+
safeWallet
|
|
91
|
+
} from "./chunk-Z2QCE6O6.js";
|
|
92
92
|
import {
|
|
93
93
|
magicEdenWallet
|
|
94
94
|
} from "./chunk-WB7EEKPS.js";
|
|
95
95
|
import {
|
|
96
96
|
metaMaskWallet
|
|
97
97
|
} from "./chunk-AKLKCDXT.js";
|
|
98
|
-
import {
|
|
99
|
-
mewWallet
|
|
100
|
-
} from "./chunk-ZRY6ILYP.js";
|
|
101
98
|
import {
|
|
102
99
|
nestWallet
|
|
103
100
|
} from "./chunk-NN4KGG3I.js";
|
|
101
|
+
import {
|
|
102
|
+
mewWallet
|
|
103
|
+
} from "./chunk-ZRY6ILYP.js";
|
|
104
104
|
import {
|
|
105
105
|
oktoWallet
|
|
106
106
|
} from "./chunk-7SSXG35M.js";
|
|
@@ -152,12 +152,12 @@ import {
|
|
|
152
152
|
import {
|
|
153
153
|
gateWallet
|
|
154
154
|
} from "./chunk-K6UZPSBG.js";
|
|
155
|
-
import {
|
|
156
|
-
frontierWallet
|
|
157
|
-
} from "./chunk-JWO4ZQLK.js";
|
|
158
155
|
import {
|
|
159
156
|
imTokenWallet
|
|
160
157
|
} from "./chunk-EHE2536P.js";
|
|
158
|
+
import {
|
|
159
|
+
frontierWallet
|
|
160
|
+
} from "./chunk-JWO4ZQLK.js";
|
|
161
161
|
import {
|
|
162
162
|
bloomWallet
|
|
163
163
|
} from "./chunk-3KPCADAF.js";
|
|
@@ -170,27 +170,27 @@ import {
|
|
|
170
170
|
import {
|
|
171
171
|
clvWallet
|
|
172
172
|
} from "./chunk-3IVTKZ7V.js";
|
|
173
|
-
import {
|
|
174
|
-
coin98Wallet
|
|
175
|
-
} from "./chunk-GILMNC3J.js";
|
|
176
173
|
import {
|
|
177
174
|
coinbaseWallet
|
|
178
175
|
} from "./chunk-PNEDRY6O.js";
|
|
176
|
+
import {
|
|
177
|
+
coin98Wallet
|
|
178
|
+
} from "./chunk-GILMNC3J.js";
|
|
179
179
|
import {
|
|
180
180
|
compassWallet
|
|
181
181
|
} from "./chunk-3OO564GS.js";
|
|
182
182
|
import {
|
|
183
183
|
coreWallet
|
|
184
184
|
} from "./chunk-FBI7UGNO.js";
|
|
185
|
-
import {
|
|
186
|
-
argentWallet
|
|
187
|
-
} from "./chunk-XT2WYPN5.js";
|
|
188
185
|
import {
|
|
189
186
|
berasigWallet
|
|
190
187
|
} from "./chunk-KM55XFBI.js";
|
|
191
188
|
import {
|
|
192
189
|
bifrostWallet
|
|
193
190
|
} from "./chunk-B6DM7J4N.js";
|
|
191
|
+
import {
|
|
192
|
+
bestWallet
|
|
193
|
+
} from "./chunk-OPAPBEA5.js";
|
|
194
194
|
import {
|
|
195
195
|
binanceWallet
|
|
196
196
|
} from "./chunk-4T3UOJYR.js";
|