/** * Internal helper functions for liquidity manager operations. */ import type { EvmReadProvider, EvmWriteProvider } from "../../types/evm.js"; /** * Sentinel address used by liquidity manager contracts to represent the native token. * @remarks This is used for "ETH" / "MATIC" style underlying tokens. */ export declare const NATIVE_TOKEN_ADDRESS: `0x${string}`; /** Decimals assumed for native tokens. */ export declare const NATIVE_DECIMALS = 18; /** * Resolve the default account address from an `EvmWriteProvider`. * @throws If the provider has no default account configured. * @internal */ export declare function ensureAccount(provider: EvmWriteProvider): `0x${string}`; /** * Resolve a read provider, falling back to the write provider if it supports `readContract`. * @throws If neither `readProvider` nor `writeProvider` has `readContract`. * @internal */ export declare function resolveReadProvider(writeProvider: EvmWriteProvider, readProvider?: EvmReadProvider): EvmReadProvider; /** * Choose which provider should be used for transaction receipt polling. * @throws If neither `readProvider` nor `writeProvider` has `waitForTransactionReceipt`. * @internal */ export declare function receiptProvider(writeProvider: EvmWriteProvider, readProvider?: EvmReadProvider): Required>; /** * Convert a value to bigint, accepting common "bigint-like" inputs. * @param value - bigint | number | string * @param label - Used in error messages for easier debugging. * @throws If the value cannot be converted to bigint. * @internal */ export declare function ensureBigintLike(value: unknown, label: string): bigint; /** * Normalize an address-like string to `0x`-prefixed hex. * @remarks This does not checksum; it only normalizes hex formatting. * @internal */ export declare function normalizeAddress(value: string): `0x${string}`; /** * Check whether an address represents the native token sentinel. * @internal */ export declare function isNativeToken(address: `0x${string}`): boolean; /** * Remove "dust" amounts that are smaller than the given conversion rate. * @remarks * OFT contracts may truncate to shared decimals internally; callers must ensure amounts * align to the conversion rate to avoid on-chain comparisons failing. * @internal */ export declare function removeDust(amount: bigint, decimalConversionRate: bigint): bigint; //# sourceMappingURL=helpers.d.ts.map