import type { XCredit, XSubscription, XUser } from '../../clerk/fingerprint/types';
/**
 * Money Price Component Types
 * 价格组件类型定义
 */
export declare enum UserState {
    Anonymous = "anonymous",
    FreeUser = "free",
    ProUser = "pro",
    UltraUser = "ultra"
}
export interface UserContext {
    isAuthenticated: boolean;
    subscriptionStatus: UserState;
    subscriptionType?: string;
    subscriptionEndDate?: string;
}
export interface InitUserContext {
    fingerprintId: string | null;
    xUser: XUser | null;
    xCredit: XCredit | null;
    xSubscription: XSubscription | null;
    isClerkAuthenticated?: boolean;
}
export type PaymentProvider = 'stripe' | 'apple' | 'paypal' | 'wechat' | 'alipay';
export interface EnhancePricePlan {
    priceId: string;
    amount: number;
    originalAmount?: number;
    discountPercent?: number;
    currency: string;
    credits?: number;
}
export interface SubscriptionProductConfig {
    key: string;
    plans: Record<string, EnhancePricePlan>;
}
export interface CreditPackProductConfig {
    key: string;
    priceId: string;
    amount: number;
    currency: string;
    credits: number;
}
export interface PaymentProviderConfig {
    provider: PaymentProvider;
    enabled: boolean;
    subscriptionProducts?: {
        F1: SubscriptionProductConfig;
        P2: SubscriptionProductConfig;
        U3: SubscriptionProductConfig;
    };
    creditPackProducts?: {
        F1: CreditPackProductConfig;
        P2: CreditPackProductConfig;
        U3: CreditPackProductConfig;
    };
    products?: {
        F1: SubscriptionProductConfig;
        P2: SubscriptionProductConfig;
        U3: SubscriptionProductConfig;
    };
}
export interface MoneyPriceConfig {
    paymentProviders: {
        [provider: string]: PaymentProviderConfig;
    };
    activeProvider: string;
    display: {
        currency: string;
        locale: string;
        minFeaturesCount: number;
    };
}
export interface MoneyPriceProps {
    locale: string;
    config: MoneyPriceConfig;
    className?: string;
    checkoutApiEndpoint?: string;
    customerPortalApiEndpoint?: string;
    enableClerkModal?: boolean;
    sectionClassName?: string;
    enabledBillingTypes?: string[];
    enableSubscriptionUpgrade?: boolean;
    initUserContext?: InitUserContext;
    initialBillingType?: string;
}
export interface MoneyPriceInteractiveProps {
    data: MoneyPriceData;
    config: MoneyPriceConfig;
    checkoutApiEndpoint?: string;
    customerPortalApiEndpoint?: string;
    enableClerkModal?: boolean;
    enabledBillingTypes?: string[];
    enableSubscriptionUpgrade?: boolean;
    initialBillingType?: string;
    disableAutoDetectBilling?: boolean;
    initUserContext?: InitUserContext;
}
export interface MoneyPriceButtonProps {
    planKey: 'F1' | 'P2' | 'U3';
    userContext: UserContext;
    billingType: string;
    onAuth: () => void;
    onAction: (plan: string, billingType: string) => void | Promise<void>;
    texts: {
        buyCredits: string;
        getStarted: string;
        getPro: string;
        getUltra: string;
        currentPlan: string;
        upgrade: string;
    };
    isProcessing?: boolean;
    isInitLoading: boolean;
    enableSubscriptionUpgrade?: boolean;
}
export interface MoneyPriceData {
    title: string;
    subtitle: string;
    billingSwitch: {
        options: Array<{
            key: string;
            name: string;
            unit: string;
            discountText: string;
            subTitle?: string;
        }>;
        defaultKey: string;
    };
    subscriptionPlans: Array<{
        key: string;
        title: string;
        showBillingSubTitle?: boolean;
        titleTags?: string[];
        features?: Array<{
            description: string;
            icon?: string;
            tag?: string;
            tooltip?: string;
        }>;
    }>;
    creditsPlans: Array<{
        key: string;
        title: string;
        subtitle?: string;
        showBillingSubTitle?: boolean;
        titleTags?: string[];
        features?: Array<{
            description: string;
            icon?: string;
            tag?: string;
            tooltip?: string;
        }>;
    }>;
    buttonTexts: {
        buyCredits: string;
        getStarted: string;
        getPro: string;
        getUltra: string;
        currentPlan: string;
        upgrade: string;
    };
    currency: string;
}
