import "./record_progress.css"; import type * as React from "react"; import { useRender } from "@base-ui/react/use-render"; import { type ConfirmRequest } from "./alert"; import { type RecordLabels } from "./locale"; import type { LifecycleStage } from "./shape_frame"; import { type StyleProps } from "./style_props"; /** * WHERE THE RECORD IS IN ITS LIFECYCLE — the stages as a connected run, and the * one act that moves it on. * * The stage itself is never set by hand here (`templates.md` rule 5). So the run * REPORTS — no ticks to press — and the only control is the committing act, * which moves the record to the next stage. * * The OUTCOME stages are the reason this is not a plain checklist: a lifecycle * leaves the flow by one of several doors, and only the one a record actually * left by is shown, and only once it has. */ export interface RecordProgressProps extends StyleProps { /** The lifecycle field's options, in the field's own order. */ options: readonly LifecycleStage[]; /** The record's stage. A value naming no option leaves the run un-started. */ value: string | null | undefined; /** What is holding the record here, in words — the act waits on them. */ blockers?: readonly string[]; /** * The committing acts. Absent, the run only reports. * * ONE HANDLER, EVERY DOOR. `onPress` receives the stage the record moves to — * the next flow stage, or an outcome the record leaves the flow by. * * ONE OF THEM IS PRIMARY AND IT IS THE NEXT STAGE. The doors are drawn in the * quiet overflow beside it, never as pills of their own weight. * * `confirm` names the moves worth stopping for — the transition that issues a * document, sends an email, posts a figure. It asks the question and nothing * else: the COMMIT is `onPress`, once, for every door. */ advance?: { onPress: (next: LifecycleStage) => void; busy?: boolean; confirm?: (next: LifecycleStage) => Omit; }; labels?: Partial; testID?: string; ref?: React.Ref; render?: useRender.RenderProp; } export declare function RecordProgress(props: RecordProgressProps): React.ReactElement>;