/// import { BN } from 'luxnet'; import { UnsignedTx as XVMUnsignedTx, UTXO as XVMUTXO, UTXOSet as XVMUTXOSet, UTXOSet } from 'luxnet/dist/apis/xvm'; import { PayloadBase } from 'luxnet/dist/utils'; import { UTXOSet as PlatformUTXOSet } from 'luxnet/dist/apis/platformvm'; import { FeeMarketEIP1559Transaction, Transaction } from '@ethereumjs/tx'; import { ExportChainsC, ExportChainsP, ExportChainsX } from '@/Wallet/types'; export declare function buildCreateNftFamilyTx(name: string, symbol: string, groupNum: number, fromAddrs: string[], minterAddr: string, changeAddr: string, utxoSet: UTXOSet): Promise; export declare function buildMintNftTx(mintUtxo: XVMUTXO, payload: PayloadBase, quantity: number, ownerAddress: string, changeAddress: string, fromAddresses: string[], utxoSet: UTXOSet): Promise; export declare function buildXvmExportTransaction(destinationChain: ExportChainsX, utxoSet: XVMUTXOSet, fromAddresses: string[], toAddress: string, amount: BN, // export amount + fee sourceChangeAddress: string): Promise; export declare function buildPlatformExportTransaction(utxoSet: PlatformUTXOSet, fromAddresses: string[], toAddress: string, amount: BN, // export amount + fee sourceChangeAddress: string, destinationChain: ExportChainsP): Promise; /** * * @param fromAddresses * @param toAddress * @param amount * @param fromAddressBech * @param destinationChain Either `X` or `P` * @param fee Export fee in nLUX */ export declare function buildEvmExportTransaction(fromAddresses: string[], toAddress: string, amount: BN, // export amount + fee fromAddressBech: string, destinationChain: ExportChainsC, fee: BN): Promise; export declare function buildEvmTransferEIP1559Tx(from: string, to: string, amount: BN, // in wei priorityFee: BN, maxFee: BN, gasLimit: number): Promise; export declare function buildEvmTransferNativeTx(from: string, to: string, amount: BN, // in wei gasPrice: BN, gasLimit: number): Promise; export declare function buildCustomEvmTx(from: string, gasPrice: BN, gasLimit: number, data?: string, to?: string, value?: string, nonce?: number): Promise; export declare function buildEvmTransferErc20Tx(from: string, to: string, amount: BN, // in wei gasPrice: BN, gasLimit: number, contractAddress: string): Promise; export declare function buildEvmTransferErc721Tx(from: string, to: string, gasPrice: BN, gasLimit: number, tokenContract: string, tokenId: number): Promise; export declare function estimateErc20Gas(tokenContract: string, from: string, to: string, value: BN): Promise; /** * Estimate the gas limit for the ERC721 `safeTransferFrom(address,address,uint256)` method. * @param contract * @param from * @param to * @param tokenID */ export declare function estimateErc721TransferGas(contract: string, from: string, to: string, tokenID: number): Promise; /** * Estimates the gas needed to send LUX * @param to Destination address * @param amount Amount of LUX to send, given in WEI * @param gasPrice Given in WEI */ export declare function estimateLuxGas(from: string, to: string, amount: BN, gasPrice: BN): Promise; export declare enum XvmTxNameEnum { 'Transaction', 'Mint', 'Operation', 'Import', 'Export' } export declare enum PlatfromTxNameEnum { 'Transaction', 'Add Validator', 'Add Delegator', 'Import', 'Export', 'Add Subnet Validator', 'Create Chain', 'Create Subnet', 'Advance Time', 'Reward Validator' } export declare enum ParseableXvmTxEnum { 'Transaction', 'Import', 'Export' } export declare enum ParseablePlatformEnum { 'Transaction', 'Add Validator', 'Add Delegator', 'Import', 'Export' } export declare enum ParseableEvmTxEnum { 'Import', 'Export' }