/** * @dev Main export file for liquidation module */ import { Trade, LiquidationParams } from ".."; import { GetLiquidationPriceContext } from "./types"; /** * @dev Calculate liquidation price with structured context * @param trade The trade to calculate liquidation price for * @param context Structured context with all required data * @returns Liquidation price */ export declare const getLiquidationPrice: (trade: Trade, context: GetLiquidationPriceContext) => number; /** * @dev Calculate liquidation price after a position size update * @dev Mirrors the contract's IncreasePositionSizeUtils.sol and DecreasePositionSizeUtils.sol logic * @param existingTrade The current trade before the update * @param newCollateralAmount New collateral amount after the update * @param newLeverage New leverage after the update * @param isLeverageUpdate Whether this is a leverage update vs regular position change * @param positionSizeCollateralDelta The absolute change in position size (in collateral terms) * @param pnlToRealizeCollateral PnL to be realized (only relevant for leverage decrease) * @param context Structured context with all required data (including additionalFeesCollateral for increases) * @returns New liquidation price after the update */ export declare const getLiquidationPriceAfterPositionUpdate: (existingTrade: Trade, newCollateralAmount: number, newLeverage: number, isLeverageUpdate: boolean, positionSizeCollateralDelta: number, pnlToRealizeCollateral: number, context: GetLiquidationPriceContext) => number; export declare const getLiqPnlThresholdP: (liquidationParams: LiquidationParams | undefined, leverage: number | undefined) => number; export { convertLiquidationParams, convertLiquidationParamsArray, encodeLiquidationParams, } from "./converter"; export * from "./types"; export * from "./builder";