import { ReactNode } from 'react'; import { ShopifyProductRef } from '../config'; import { FanfareDenialReason } from './use-fanfare-grant'; export interface FanfareCheckoutGateProps { /** * Your cart's line items — each a Shopify product reference (the same * `ShopifyProductRef` shape `useFanfareExperience` takes). The gate resolves * each to its Fanfare experience to find out whether any line is gated. * * The gating decision uses the same tolerant product lookup key as * `useFanfareExperience`: a handle, storefront product URL/path, or product id. * At least one of `handle` or `id` is required for each line. */ cartItems: ShopifyProductRef[]; /** * Rendered when a gated line is present but the shopper has no valid grant. A * node, or a render prop passed the verifier's denial reason. * * `reason` is a `FanfareDenialReason` (an OPEN union) — a short machine-readable * code you can branch on for tailored copy. The gate emits only the three * client-side codes: `"no_grant"`, `"grant_expired"`, and `"verify_failed"`. * The proxy/transport family (`"no_checkout_context"`, `"verify_unreachable"`, * and the DYNAMIC `` `proxy_${status}` ``) is surfaced by `claim()` / the SDK's * internal reserve verifier, NOT by this gate. `reason` is `undefined` only if a future * verifier denies without a code. Send the shopper back to clear the drop. */ onDenied: ReactNode | ((reason: FanfareDenialReason) => ReactNode); /** * Rendered while the gate is resolving the cart / verifying the grant. Keep it * quiet (a spinner, or nothing) — defaults to rendering nothing so the gate does * not flash. Never let the shopper proceed during this state. */ fallback?: ReactNode; /** Rendered once the shopper is allowed (no gated line, or a valid grant). */ children: ReactNode; } export declare function FanfareCheckoutGate({ cartItems, onDenied, fallback, children }: FanfareCheckoutGateProps): import("react/jsx-runtime").JSX.Element;