import { Locator, Page } from '@playwright/test';
import type { CreditBalancePlan } from './credit-balance-helpers';
export type BillingAutoRechargeStatus = 'Enabled' | 'Disabled';
/** Locator for the Plan section card on the BillingTab. */
export declare function billingPlanSection(page: Page): Locator;
/** Locator for the Credits section card on the BillingTab. */
export declare function billingCreditsSection(page: Page): Locator;
/** Locator for the Auto Recharge section card on the BillingTab.
 *  This section is only rendered for non-Free plans with a payment method on file.
 */
export declare function billingAutoRechargeSection(page: Page): Locator;
/** Reads the plan label (Free / Trial / Premium) from the Plan section. */
export declare function getBillingPlanLabel(page: Page): Promise<CreditBalancePlan | null>;
/** Reads the auto-recharge status badge (Enabled / Disabled) when the section is rendered. */
export declare function getBillingAutoRechargeStatus(page: Page): Promise<BillingAutoRechargeStatus | null>;
/** Waits for the BillingTab loading skeletons to clear by waiting for the Plan
 *  section card to mount. */
export declare function waitForBillingTabReady(page: Page): Promise<void>;
/**
 * Asserts the Plan section state for a given plan. Verifies:
 *  - The plan label text matches `options.plan`
 *  - The "Current" pill is visible
 *  - The Upgrade button is visible iff the plan is not Premium
 */
export declare function expectBillingPlanSection(page: Page, options: {
    plan: CreditBalancePlan;
}): Promise<void>;
/**
 * Asserts the Credits section state. Always verifies the "Available" stat row.
 * The action button rule mirrors the component:
 *   - Free plan → no Add Credits / Manage Billing button
 *   - Non-Free + hasPaymentMethod=true → "Add Credits" visible, "Manage Billing" absent
 *   - Non-Free + hasPaymentMethod=false → "Manage Billing" visible, "Add Credits" absent
 *   - Non-Free with hasPaymentMethod omitted → only the "Available" row is asserted
 */
export declare function expectBillingCreditsSection(page: Page, options: {
    plan: CreditBalancePlan;
    hasPaymentMethod?: boolean;
}): Promise<void>;
/**
 * Asserts the Auto Recharge section visibility. Section is rendered only when
 * `hasPaymentMethod && !isFreePlan` in the component. Pass `expectVisible: false`
 * to assert the section is absent. When visible and `status` is provided, also
 * asserts the Enabled/Disabled badge text.
 */
export declare function expectBillingAutoRechargeSection(page: Page, options: {
    expectVisible: boolean;
    status?: BillingAutoRechargeStatus;
}): Promise<void>;
/**
 * Free plan: Plan="Free" with Upgrade visible; Credits section has no action;
 * Auto Recharge section is hidden entirely (regardless of has_payment_method).
 */
export declare function expectBillingTabForFreePlan(page: Page): Promise<void>;
/**
 * Trial plan: Plan="Trial" with Upgrade visible; Credits action depends on
 * `hasPaymentMethod` (Add Credits when true, Manage Billing when false);
 * Auto Recharge section is rendered iff `hasPaymentMethod` is true.
 */
export declare function expectBillingTabForTrialPlan(page: Page, options: {
    hasPaymentMethod: boolean;
}): Promise<void>;
/**
 * Premium plan: Plan="Premium" with Upgrade hidden; Credits action depends on
 * `hasPaymentMethod` (Add Credits when true, Manage Billing when false);
 * Auto Recharge section is rendered iff `hasPaymentMethod` is true.
 */
export declare function expectBillingTabForPremiumPlan(page: Page, options: {
    hasPaymentMethod: boolean;
}): Promise<void>;
/**
 * Convenience: detects the active plan from the Plan section badge and runs
 * the matching state assertions. Returns the detected plan.
 *
 * For non-Free plans, pass `hasPaymentMethod` to assert the Credits/Auto Recharge
 * sub-states; if omitted, only the Plan section + base Credits row is verified.
 */
export declare function expectBillingTabForCurrentPlan(page: Page, options?: {
    hasPaymentMethod?: boolean;
}): Promise<CreditBalancePlan>;
/** Clicks the Upgrade button in the Plan section (visible only on non-Premium plans). */
export declare function clickBillingUpgrade(page: Page): Promise<void>;
/** Clicks the Add Credits button in the Credits section (non-Free + has payment method). */
export declare function clickBillingAddCredits(page: Page): Promise<void>;
/** Clicks the Manage Billing button in the Credits section (non-Free + no payment method). */
export declare function clickBillingManageBilling(page: Page): Promise<void>;
/** Clicks the Manage Usage button in the Auto Recharge section. */
export declare function clickBillingManageUsage(page: Page): Promise<void>;
