import { FeedbackDialogCloseReason } from './FeedbackDialog'; /** Localized strings the modal renders — resolved by the caller (see FeedbackModalActionBlock). */ export interface FeedbackModalContent { /** Dialog title, e.g. "Can you tell us why?". */ title: string; /** Optional paragraph under the title, e.g. "We'd love to hear why…". */ description?: string; /** Survey reasons; the last option reveals the free-text detail field. */ options: string[]; /** Primary (Submit) button label. */ submitText: string; /** Secondary (No thanks) button label. */ cancelText: string; /** ARIA label for the dialog close button. */ closeAriaLabel: string; /** Helper text under the detail field, e.g. "250 character limit". */ characterLimitLabel?: string; /** Success snackbar message, e.g. "Your feedback has been submitted.". */ successMessage: string; /** Error snackbar message, e.g. "Your feedback could not be submitted.". */ errorMessage: string; /** Error snackbar action label, e.g. "Try Again". */ tryAgainText: string; /** ARIA label for the snackbar close button. */ toastCloseAriaLabel: string; } interface FeedbackModalProps { isOpen: boolean; copy: FeedbackModalContent; /** * Fired when the survey is submitted. May return a promise: a rejection * switches to the error snackbar (Figma `1941:167637`), whose Try Again * action re-submits the same selection. Sync/resolved submissions show the * success snackbar. */ onSubmit: (option: string, detail?: string) => void | Promise; /** * Fired when the whole flow ends: the dialog is dismissed without submitting * (reason set), or either snackbar is closed / auto-hides (no reason). */ onClose: (reason?: FeedbackDialogCloseReason) => void; /** * When provided, the secondary button acts as "Back" — it fires this instead * of ending the flow via `onClose` (e.g. SurveyModal returning to its survey * step). When absent, the secondary ("No thanks") ends the flow as before. */ onBack?: () => void; } /** * The CTA feedback drilldown (Figma `1941:192803`): a "Can you tell us why?" * survey dialog followed by a success snackbar (Figma `1941:167636`) — or an * error snackbar with a Try Again action (Figma `1941:167637`) when the * submission fails. * * Purely presentational — copy arrives resolved via `FeedbackModalContent`; * the `feedback_modal_block` action block wires it to the copy store, the beat * actions, and the action-drawer session. */ declare const FeedbackModal: ({ copy, isOpen, onBack, onClose, onSubmit }: FeedbackModalProps) => import("react/jsx-runtime").JSX.Element; export default FeedbackModal;