Overview
Reference usage
Ordered step-by-step execution rail for async operations. Shows pending, running, waiting, waiting approval, succeeded, failed, timed-out, canceled, skipped, and retrying states with per-step durations, attempt counts, action counts, optional progress indicators, nested child-workflow lanes, links, and expandable inline detail panels for logs, payloads, and errors.
Use RunStepTimeline for CI jobs, workflow engine runs, import pipelines, deployment flows, and queue workers. Use Timeline for timestamp-first event logs. Use Steps for interactive wizard navigation.
See the chronological display boundary decision for the distinction between execution state, event history, schedules, activity feeds, and operational streams.
Overview
RunStepTimeline takes a steps array and renders an ordered list. Each step shows:
- A status dot on the rail (color-coded by state, decorative and hidden from assistive technology)
- A status badge (text label so state is not communicated by color alone)
- Start time, end time, and duration when available
- An attempt count badge when the step has been retried
- An action count badge when actions are available
- An optional link rendered with
Link - A progress bar for
running,retrying, orwaiting_approvalsteps with a knownprogressvalue - Indented child-workflow lanes from recursive
children - Expandable Collapsible panels for logs, payloads, and errors via the
detailsarray
The component marks the currently active step with aria-current="step". running, retrying, and waiting_approval are current, non-terminal states.
Usage
With expandable details
With inline detail panels
With nested child-workflow lanes
Branch / coordination groups
A top-level entry can be a branch group instead of a step. A branch group fans out into N parallel sub-lanes, each a sequence of steps with an optional outcome (won / lost / settled). The winning lane is emphasized, losers are muted, and the group is collapsible (collapsed by default once the lane count reaches collapseThreshold, default 3). Branch groups are opt-in via the kind: 'branch' discriminator, so existing RunStep[] arrays keep working unchanged — widen your array type to RunStepTimelineEntry[] to mix them in.
Rewound and compensated steps
Set rewound: true on a step that was speculatively executed and then unwound. It renders struck-through and de-emphasized (and announces its rewound state as text) while staying inspectable. Set compensates: '<forward-step-id>' on a step that reverses an earlier forward step, as in a saga rollback; the compensating step keeps its own place in execution order and renders inset with a dashed reversal connector and a Compensates <label> badge that names the forward step it reverses. The compensates id must reference a sibling step (one under the same parent); an unresolved id renders the step in place without the badge.
Telling a run's story
variant="narrative" reads the same steps as a story for someone who wants to know what happened, as on a run page's "What happened". Each step is a drawn marker, the label with a short time at its end, and one muted description; there are no status chips and no metadata lists, though the status word is still read aloud. Text between backticks in a description renders as inline code.
A step that is under way (running) draws a ring, now as its time, and may carry a note that is streaming: an open block with a bold title and the lines so far, followed by a text cursor, so the entry reads as partial and growing. Steps that have not started (pending) and steps that never ran (skipped) draw a dashed ring. A failure (failed) draws a red cross, and a note with tone: 'danger' opens its cause under it. A run blocked on an external signal ends in an open ring (waiting), and an event with no outcome of its own, such as the start, is recorded.
The line above the timeline is a StatusDot word, not part of the list: word="Live · last event 1 s ago" while the stream is open, and word="Reconnecting…" with label="Reconnecting… last event 40 s ago" (a hollow ring) while it has dropped. A step whose entry may be behind shows how stale it is as its time ("last update 40 s ago").
Folding a long story
A narrative timeline of many entries folds its middle with fold: the first 3 and last 3 entries stay, with one row between them that reads "3 more calls" and an action "Show all 9". Show all opens the middle in place. A step that failed, timed out, is waiting or is under way never folds and splits the folded middle into separate rows that each count what they hide. A fold hides at least two entries, so seven entries show all seven. Pass label and actionLabel to say what the entries are; the defaults read "3 more steps" and "Show all 9".
A note can carry label ("Your note") to read as somebody's words: "Your note · The customer already got a replacement."
Step states
RunStepStatus is intentionally domain-agnostic. Map your domain state onto one of these:
pending— not yet startedrunning— currently executing within its lanewaiting_approval— paused on required approval and expected to continuesucceeded— completed successfullyfailed— completed with a terminal errortimed-out— exceeded its allowed execution timecancelled— stopped before it could completeskipped— bypassed intentionallyretrying— a prior attempt ended unsuccessfully; a new attempt is in progresswaiting— paused on something that is not a person's approval, such as an external signalrecorded— an event with no outcome of its own, such as the run's start or end
Map engine-specific deadline states such as timed_out, timeout, or deadline_exceeded to timed-out. Keep other terminal errors mapped to failed so consumers can present deadline expiry distinctly without introducing product-specific status vocabulary.
Props
RunStepTimeline props
RunStep shape
RunStepDetail shape
RunStepNote shape
RunStepLink shape
Accessibility
RunStepTimeline renders an ol (ordered list) because steps are numbered and sequential. The list takes an accessible name via label (used as aria-label when neither aria-label nor aria-labelledby is provided directly).
The active step (running, retrying, or waiting_approval) receives aria-current="step" on its li element, matching the same pattern used by the Steps component. This allows assistive technology to identify which step is current without requiring a live region announcement.
Status dots on the rail are decorative: the marker element is marked aria-hidden="true" and inert. The status badge rendered as text includes an accessible label such as "Status: Waiting approval", so the step state is communicated to assistive technology through text, not color alone (WCAG 1.4.1).
Progress bars include an aria-label derived from the step label (e.g. "Build Docker image progress"), satisfying the ARIA progressbar accessible name requirement.
Expandable detail panels use Collapsible which implements the disclosure button pattern with aria-expanded and aria-controls wiring.
- Validate configuration Succeeded
- Build Docker image Running
- Deploy to staging Pending
When to use
- Showing live or completed CI, workflow, import, or deployment steps.
- Showing speculative parallel branches or saga compensation.
- Guiding users through an interactive wizard where they choose what to do next — use steps instead.
- Showing a flat timestamp-first event log without structured step state — use timeline instead.
- Showing an activity stream — use feed instead.
- Showing a dense operational log without structured step state, such as raw CI or job output — use feed's log arm instead.
Examples
Basic run step timeline
A multi-step async run with pending, running, and succeeded steps.
Branch group with a winning lane
A speculative race across three parallel deploy candidates. The winning lane is emphasized and the losers are muted, with the group outcome summarized as text.
Failed and timed-out steps
Keep deadline expiry distinct from other terminal errors by mapping the engine timeout state to timed-out.
Rewound speculative step
A step that was speculatively executed and then unwound after a conflict. It renders struck-through and de-emphasized but stays inspectable, and announces its rewound state as text.
What happened: a canceled run
A canceled run lists what it did. "Drafting the summary" was interrupted, so it is a neutral ring ("Interrupted while writing"), and the last entry, "Canceled", has a prohibition glyph: "The goal was stopped. Work already done is kept."
What happened: finished runs
A finished run told as a story: Started has a plain grey dot and the entries after it green checks, times sit at the end of each line, and "Used Lookup order lookup-order" shows the identifier small and monospaced. The three runs are a chat reply, a run a schedule started ("The Daily summary schedule started this run at 4:00 AM (9:00 AM UTC)"), and a refund that asked for approval and was approved.
What happened: a long rail, collapsed
A rail of eight or more entries shows the first three and the last three, with one row between reading "3 more calls" and a "Show all 9" action. Show all opens the middle in place. Failed and waiting entries are never collapsed.
What happened: a failed call and a denied approval
A run that is Done keeps a failed tool call visible: its entry has a red mark and an open note, "This call failed", and the run still ends "Finished; one tool call failed". After a denied approval the entry reads Denied with a neutral dot, the note you typed shows as "Your note · …", and the run ends "Done · refund not issued".
What happened: waiting and checking
A run waiting for you draws an amber ring on "Asked a question" with "Waiting for your answer", and "Next steps" dashed ("Continue once you’ve answered"). A goal attempt that finished is checked against the goal’s check: its entries have no outcome yet, so they are plain grey dots, and the last entry, "Checking the result now", is a hollow in-progress ring.
Saga compensation
A saga where a later step compensates (reverses) an earlier forward step by id. The compensating step renders inset beneath its forward step with a dashed reversal connector.
Temporal child workflow with approval wait
A Temporal-style workflow lane that moves from model planning to tool execution, waits on approval, then shows a retrying subagent lane.
Props
Name | Type | Default | Description |
|---|---|---|---|
steps required | RunStepTimelineEntry[] | Ordered list of timeline entries to render. Each entry is either a
{@link RunStep} or a {@link RunStepBranchGroup}. Plain RunStep[] arrays
remain valid — branch groups are opt-in via the kind discriminator. | |
label | text | Accessible label for the timeline list.
Used as aria-label when aria-labelledby is absent. | |
selectedStepId | text | Rendered step path key to visually mark as selected.
Accepts null so consumers can clear linked selection without omitting
the prop. Use the value passed to onStepSelect, or a row's
data-cinder-path attribute, for nested or branch-lane steps. | |
onStepSelect | ((pathKey: string) => void)undefined | Fired when the user activates a rendered step row. Receives that row's rendered path key. | |
variant | 'detailed' | 'narrative' | 'detailed' | How a step reads. detailed (the default) marks each step with a status dot and a status chip
and lists its start, end, duration and attempts. narrative tells the run as a story for
someone who wants to know what happened: a drawn marker (a check, a cross, a ring, a dashed
ring for what has not run), the label and its time, one line of description, and no chips or
metadata lists. The status word is still read aloud. |
fold | {
/** How many entries stay visible at the start. @default 3 */
first?: number | undefined;
/** How many entries stay visible at the end. @default 3 */
last?: number | undefined;
/** The fold row's label for how many entries it hides. Defaults to "3 more steps". */
label?: ((hidden: number) => string) | undefined;
/** The fold row's action, given how many entries the timeline holds. Defaults to "Show all 9". */
actionLabel?: ((total: number) => string)undefined;
} | Folds the middle of a long narrative timeline behind one "N more" row. Ignored by detailed. | |
children | Snippet<[RunStep]> | undefined | Optional per-step body content rendered after the step metadata. |