import { Abi, Address, ContractEventName, ContractFunctionName, GetContractReturnType, Hash, Hex, parseEventLogs, PublicClient, SimulateContractParameters, TransactionReceipt } from 'viem'; import { Wallet } from '../../clients/contracts'; /** * Options of a `safeContractWrite` call. `dataSuffix` is appended verbatim after * the ABI-encoded arguments, both in the simulation and in the broadcast * transaction (viem's `writeContract` forwards it to `sendTransaction`, which * concatenates it onto `data`); Solidity's decoder ignores trailing bytes, so a * suffix never changes what the contract executes. */ export type SafeContractWriteOptions = { value?: bigint; dataSuffix?: Hex; }; export declare class BaseContract { abi: TAbi; address: Address; bcClient: PublicClient; wallet: Wallet; contract: GetContractReturnType; safeContractWrite: { [TFunctionName in ContractFunctionName]: (args: SimulateContractParameters['args'], options?: SafeContractWriteOptions) => Promise; }; parseEventLogs: >(eventName: TFunctionName, logs: TransactionReceipt['logs']) => ReturnType>; constructor({ walletClient, address, abi, publicClient, }: { walletClient: Wallet; address: Address; abi: TAbi; publicClient?: PublicClient; }); sendTransactionData(data: Hex, value?: bigint): Promise<{ txHash: `0x${string}`; waitTxInBlock: () => Promise; }>; private sendRawTransaction; private sendTransactionWithAbiValidation; }