import * as react from 'react'; import { CSSProperties } from 'react'; import { SeatingChartOptions, SeatingChartHandle, EmbeddedDesignerMessage, SeatPickerOptions, SelectedSeat, PickerSelectionValidity, SeatPickerBestAvailableOptions, HoldResult, PickerMapTheme, SeatPickerPricing, RendererViewMode, SeatPickerBuyerView, SeatPickerBuyerViewOptions, SeasonPickerOptions, SeasonCheckoutHandoff, SeasonRenewalIntent, SeasonDescriptor, SeasonAvailability } from '@seatlayer/js'; export { AttachPickerFrameOptions, BestAvailableResult, BuyerAccessExpiredEvent, BuyerAccessRefreshReason, BuyerAccessToken, BuyerAccessTokenProvider, BuyerAccessUnavailableEvent, BuyerAccessUnavailableReason, CheckoutHandoff, CheckoutLineItem, EmbeddedDesignerMessage, GAAreaAvailability, HoldLineItem, HoldResult, PickerMapTheme, RendererViewMode, SeasonAvailability, SeasonCheckoutHandoff, SeasonDescriptor, SeasonOfferPresentation, SeasonOperation, SeasonOperationState, SeasonPickerOptions, SeasonRenewalIntent, SeasonStatusEvent, SeatHoverDetails, SeatPickerBestAvailableOptions, SeatPickerBuyerView, SeatPickerBuyerViewOptions, SeatPickerOptions, SeatPickerPricing, SeatPickerTheme, SeatPicker as SeatPickerWidget, SeatingChartHandle, SelectedObjectUnavailableEvent, SelectedSeat, attachPickerFrame } from '@seatlayer/js'; export { SeatManager, SeatManagerHandle, SeatManagerProps } from './manager.cjs'; export { ControlRoomActivityEntry, ControlRoomSectionMetric, ControlRoomSnapshot, EventScopedManageToken, SeatManagerActionResult, SeatManagerActivity, SeatManagerConnection, SeatManagerMode, SeatManagerOptions, SeatManagerTallies } from '@seatlayer/js/manager'; interface SeatingChartProps extends Omit { className?: string; style?: CSSProperties; } /** * React wrapper around the framework-agnostic `@seatlayer/js` SDK. * * The underlying canvas is created once and torn down on unmount. Callback props * (`onSelectionChange`, `onHold`, `onError`, `onDeckTap`, `onHint`) may change * freely between renders without re-mounting the canvas — only the props in * `SEATING_CHART_IDENTITY_PROPS` (`event`, `apiBase`, `maxSelection`, `numberOfPlacesToSelect`, `selectionValidators`, * `publicKey`, `locale`, `currency`, `colorblindSafe`, `initialView`, * `errorDisplay`) trigger a rebuild. * (`messages`, `selectedObjects`, and `selectableObjects` are read once per * mount; change selection policy later through the imperative handle.) */ declare const SeatingChart: react.ForwardRefExoticComponent>; interface EmbeddedDesignerHandle { /** Recreate the iframe with a newly-minted session URL. */ setDesignerUrl(designerUrl: string): void; /** The currently mounted iframe, if any. */ getIframe(): HTMLIFrameElement | null; } interface EmbeddedDesignerProps { /** Short-lived `designerUrl` returned by your backend. Never pass an `sk_` key. */ designerUrl: string; expectedChartId?: string; expectedWorkspaceId?: string; title?: string; className?: string; style?: CSSProperties; iframeClassName?: string; iframeStyle?: Partial; allow?: string; referrerPolicy?: ReferrerPolicy; /** * Show the built-in branded loading skeleton and error/expiry card inside the * container while the Designer boots. Defaults to `true`. Set `false` when you * render your own loading and error chrome. */ showLoadingState?: boolean; /** * If the Designer never posts `ready` within this many milliseconds, the host * shows the error card with a timeout message. Defaults to `20000`. */ loadingTimeoutMs?: number; /** * How the iframe is sized. `'fill'` (the default) is **container-aware**: if the * container has a definite height (a sized block, `flex-1 min-h-0`, a resolved * `%`) the Designer fills 100% of it and tracks its size via a `ResizeObserver`; * if the container is content-sized (full-page usage) the Designer fills the * viewport (`window.innerHeight` minus the iframe's top offset). Either way the * result is clamped to `minHeight` and re-probed on resize. Heights are applied * with `!important` so a host theme can't override them. Pass a number for a * fixed pixel height you manage yourself. */ height?: 'fill' | number; /** Lower bound for `'fill'` sizing. Defaults to `480`. */ minHeight?: number; /** * Legacy content-height auto-grow via the `seatlayer.designer.resize` * protocol. Only honored when `height` is a number; with the default * `height: 'fill'` the resize messages are ignored and the SDK sizes the iframe * to the container or viewport. */ autoResize?: boolean; /** * Called when the user presses "Try again" on the error card. Mint a fresh * session and set the new `designerUrl` (recreating the iframe returns it to * the loading state). When omitted, "Try again" reloads the current URL. * * When supplied, it also powers automatic session renewal — see * {@link EmbeddedDesignerProps.autoRenewSession}. */ onRequestRelaunch?: () => void; /** * Keep long editing sessions alive with no expiry wall. When you supply * `onRequestRelaunch`, the SDK schedules a silent relaunch shortly before the * session's `expiresAt` (mint a fresh session and update `designerUrl` in your * `onRequestRelaunch` handler), and makes one automatic recovery attempt if an * expiry error still slips through before showing the "Try again" card. Defaults * to `true` whenever `onRequestRelaunch` is provided; a no-op without it. Set * `false` to keep the fully manual "Try again" behavior. */ autoRenewSession?: boolean; onReady?: (message: EmbeddedDesignerMessage) => void; onSaved?: (message: EmbeddedDesignerMessage) => void; onPublished?: (message: EmbeddedDesignerMessage) => void; onClose?: (message: EmbeddedDesignerMessage) => void; onError?: (message: EmbeddedDesignerMessage) => void; } /** * Native-feeling React host for the secure SeatLayer Designer iframe. * A new `designerUrl` always recreates the iframe, so a new fragment token can * never retain state from an earlier chart session. */ declare const EmbeddedDesigner: react.ForwardRefExoticComponent>; /** Imperative handle for the full-experience picker widget. */ interface SeatPickerHandle { /** Logically close the picker. React still owns component unmount/teardown. */ close(): void; /** Current selection with resolved prices. */ getSelection(): SelectedSeat[]; /** Select free objects by engine id or public label. */ selectObjects(objects: string[]): SelectedSeat[]; /** Deselect objects by engine id or public label. */ deselectObjects(objects: string[]): void; /** Clear every unheld selection. */ clearSelection(): void; /** Select every selectable object in the named categories. */ selectCategories(categoryKeys: string[]): SelectedSeat[]; /** Deselect every selected object in the named categories. */ deselectCategories(categoryKeys: string[]): void; /** Replace the buyer-selectable object allow-list without remounting. */ setSelectableObjects(objects: string[] | null): void; /** Change the active selection cap without remounting. */ setMaxSelection(maxSelection: number): void; /** Current exact-count validity, or null when exact selection is disabled. */ getSelectionValidity(): PickerSelectionValidity | null; /** Server-side best seats + hold, reflected in the widget tray. */ bestAvailable(qty: number, categoryKey?: string, options?: SeatPickerBestAvailableOptions): Promise; /** Current active/restored hold reflected in the tray. */ getCurrentHold(): HoldResult | null; /** Restore an active hold by its opaque id. */ resumeHold(holdId: string): Promise; /** Remove one held ticket while preserving the remainder. */ removeHeldTicket(label: string): Promise; /** Release the current hold (if any) and reset the tray. */ release(): Promise; /** * Re-acquire the buyer access session after your app re-authorizes the buyer * (Sales Channels). Resolves false when the picker is not access-scoped. */ refreshAccess(): Promise; /** Re-ink the drawn map without rebuilding the picker or disturbing a hold. */ setMapTheme(map: PickerMapTheme | null): void; /** Hide or restore duplicate event identity after mount. */ setEventDetailsHidden(hidden: boolean): void; /** Replace host display-pricing overrides without remounting. */ setPricing(pricing: SeatPickerPricing | undefined): void; /** Current colorblind-safe buyer preference. */ isColorblindSafe(): boolean; /** Update the colorblind-safe buyer preference and renderer. */ setColorblindSafe(on: boolean): void; /** Switch the underlying 2D map projection. */ setViewMode(mode: RendererViewMode): void; /** Current 2D map projection. */ getViewMode(): RendererViewMode; /** Current buyer surface: map or interactive 3D venue. */ getBuyerView(): SeatPickerBuyerView; /** Switch the buyer surface, optionally carrying a 3D camera intent. */ setBuyerView(view: SeatPickerBuyerView, options?: SeatPickerBuyerViewOptions): void; } interface SeatPickerProps extends Omit { className?: string; style?: CSSProperties; } /** * React wrapper around the full SeatPicker widget (header · live price panel · * tray · GA · hold countdown · toasts). The widget is container-adaptive: give * the wrapping div a size and it lays itself out for that box (side panel wide, * bottom sheet narrow). For the one-call modal, use `SeatPicker.open()` from * `@seatlayer/js` directly. */ declare const SeatPicker: react.ForwardRefExoticComponent>; /** Imperative controls for the fixed-inclusion Season buyer flow. */ interface SeasonPickerHandle { holdSameSeat(labels: readonly string[], operationId: string): Promise; restoreOperation(operationId: string): Promise; release(releaseActionId: string): Promise; createRenewalIntent(offerId: string): Promise; getDescriptor(): SeasonDescriptor | null; getAvailability(): SeasonAvailability | null; getHandoff(): SeasonCheckoutHandoff | null; } /** Props accepted by the React Season wrapper. */ interface SeasonPickerProps extends Omit { className?: string; style?: CSSProperties; } /** * React lifecycle adapter for the distinct fixed-inclusion `SeasonPicker`. * It never receives a secret key and never turns a browser handoff into proof * of price, payment, booking, or renewal. */ declare const SeasonPicker: react.ForwardRefExoticComponent>; export { EmbeddedDesigner, type EmbeddedDesignerHandle, type EmbeddedDesignerProps, SeasonPicker, type SeasonPickerHandle, type SeasonPickerProps, SeatPicker, type SeatPickerHandle, type SeatPickerProps, SeatingChart, type SeatingChartProps };