import { IPromoCodeDetails } from '@roomstay/core';
import BasketAddonRow from '../models/BasketAddonRow';
import BasketRow from '../models/BasketRow';
/**
 * For `flatQuantity` and `flatQuantityPerStay` promo codes, discount allocation is SEQUENTIAL:
 * The discount is consumed in this order:
 * 1. Room rates
 * 2. First addon added to basket
 * 3. Second addon added to basket
 * 4. Etc
 *
 * For `flatPercent` types, order doesn't matter as each addon gets its own percentage discount.
 */
export declare class AddonDiscountCalculator {
    /**
     * Calculate total price of all addons with promo code discounts applied.
     * Discounts are applied sequentially for flatQuantityPerStay promo codes.
     *
     * @param addonRows - Array of basket addon rows (ORDER MATTERS for flatQuantityPerStay!)
     * @param roomRows - Array of basket room rows
     * @param promoCodeDetails - Promo code details from basket context
     * @returns Total price of all addons after discounts
     */
    static calculateTotal(addonRows: BasketAddonRow[], roomRows: BasketRow[], promoCodeDetails: IPromoCodeDetails | null): number;
    /**
     * Calculate discount for each addon individually with remaining discount tracking.
     * Useful for displaying discounts in the UI where you need to show each addon's
     * discount separately.
     *
     * @param addonRows - Array of basket addon rows (ORDER MATTERS!)
     * @param roomRows - Array of basket room rows
     * @param promoCodeDetails - Promo code details
     * @returns Array of objects with addon, its discount, and remaining discount available
     */
    static calculateIndividualDiscounts(addonRows: BasketAddonRow[], roomRows: BasketRow[], promoCodeDetails: IPromoCodeDetails | null): Array<{
        addon: BasketAddonRow;
        discount: number;
        remainingDiscount: number;
    }>;
    /**
     * Calculate discount for an addon being previewed (not yet in basket).
     * This is used in the addon selection UI to show what discount would apply.
     *
     * For flatQuantityPerStay promos, this calculates the remaining discount after
     * accounting for rooms and OTHER addons already in the basket.
     *
     * @param basePrice - Base price of the addon (before discount, before fees)
     * @param addonRows - Array of basket addon rows (addons already in basket)
     * @param roomRows - Array of basket room rows
     * @param promoCodeDetails - Promo code details
     * @returns Discount amount that would apply to this addon
     */
    static calculatePreviewDiscount(basePrice: number, addonRows: BasketAddonRow[], roomRows: BasketRow[], promoCodeDetails: IPromoCodeDetails | null): number;
    /**
     * Get discount info including total available and initial running discount from rooms.
     *
     * @param roomRows - Array of basket room rows
     * @param promoCodeDetails - Promo code details
     * @returns Object with totalDiscountAvailable and runningDiscount (from rooms)
     */
    private static getDiscountInfo;
    /**
     * Calculate remaining fixed discount available.
     *
     * @param promoCodeDetails - Promo code details
     * @param totalDiscountAvailable - Total discount available
     * @param runningDiscount - Discount already consumed
     * @returns Remaining discount available (0 for FlatPercent)
     */
    private static getRemainingFixedDiscount;
    /**
     * Calculate total discount already consumed by room rates.
     * This is used as the starting point for addon discount calculations.
     *
     * @param roomRows - Array of basket room rows
     * @returns Total discount amount consumed by all rooms
     */
    private static calculateRoomDiscount;
}
