UNPKG

@betterstore/react

Version:

E-commerce for Developers

25 lines (24 loc) 1.05 kB
import { CheckoutSession, createStoreClient } from "@betterstore/sdk"; import { StripeElementLocale } from "@stripe/stripe-js"; import React from "react"; import { AppearanceConfig, Fonts } from "./appearance"; interface CheckoutFormProps { storeClient: ReturnType<typeof createStoreClient>; checkoutId: string; onSuccess: () => void; onError: () => void; cancelUrl: string; clientSecret: string; customer?: CheckoutSession["customer"]; currency: string; checkoutAppearance?: AppearanceConfig; fonts?: Fonts; locale?: StripeElementLocale; setShippingCost: (cost: number) => void; exchangeRate: number; paymentSecret: string | null; publicKey: string | null; paymentComponentKey: number; } export default function CheckoutForm({ storeClient, checkoutId, onSuccess, onError, cancelUrl, clientSecret, customer, currency, checkoutAppearance, fonts, locale, setShippingCost, exchangeRate, paymentSecret, publicKey, paymentComponentKey, }: CheckoutFormProps): React.JSX.Element; export {};