import { IkasProductPrice } from "../../../../../storefront-models/src"; /** * Returns the final effective price for a product, using the discount price if available or falling back to the sell price. * * @ai-category VariantPrice, Product * @ai-related hasIkasProductPriceDiscount, getIkasProductPriceDiscountAmount, getIkasProductDiscountPercentage * * @param price - The product price object containing sell and discount prices. * @returns The discount price if it exists, otherwise the sell price. * * @example * ```typescript * import { getIkasProductPriceFinalPrice } from "@ikas/bp-storefront"; * const finalPrice = getIkasProductPriceFinalPrice(variant.price); * console.log(`Final price: ${finalPrice}`); * ``` */ export declare function getIkasProductPriceFinalPrice(price: IkasProductPrice): number; /** * Determines whether a product price has an active discount by checking if the discount price is not null. * * @ai-category VariantPrice, Product * @ai-related getIkasProductPriceFinalPrice, getIkasProductPriceDiscountAmount, getIkasProductDiscountPercentage * * @param price - The product price object to check for a discount. * @returns True if a discount price exists, false otherwise. * * @example * ```typescript * import { hasIkasProductPriceDiscount } from "@ikas/bp-storefront"; * if (hasIkasProductPriceDiscount(variant.price)) { * console.log("This product is on sale!"); * } * ``` */ export declare function hasIkasProductPriceDiscount(price: IkasProductPrice): boolean; /** * Calculates the absolute discount amount by subtracting the discount price from the sell price. * * @ai-category VariantPrice, Product * @ai-related hasIkasProductPriceDiscount, getIkasProductPriceFinalPrice, getIkasProductDiscountPercentage * * @param price - The product price object to calculate the discount amount for. * @returns The discount amount as a number, or 0 if there is no discount. * * @example * ```typescript * import { getIkasProductPriceDiscountAmount } from "@ikas/bp-storefront"; * const savings = getIkasProductPriceDiscountAmount(variant.price); * console.log(`You save: ${savings}`); * ``` */ export declare function getIkasProductPriceDiscountAmount(price: IkasProductPrice): number; /** * Calculates the discount percentage as a whole number string representing how much the price has been reduced from the original sell price. * * @ai-category VariantPrice, Product * @ai-related hasIkasProductPriceDiscount, getIkasProductPriceDiscountAmount, getIkasProductPriceFinalPrice * * @param price - The product price object to calculate the discount percentage for. * @returns A string representing the discount percentage (e.g. "25"), or 0 if there is no discount. * * @example * ```typescript * import { getIkasProductDiscountPercentage } from "@ikas/bp-storefront"; * const percentage = getIkasProductDiscountPercentage(variant.price); * console.log(`${percentage}% off`); * ``` */ export declare function getIkasProductDiscountPercentage(price: IkasProductPrice): string | 0;