API reference
flagstaff/progress
Every export of flagstaff/progress, with its signature and doc comment: progress, plus 2 types.
The progress bar, which reports to an MCP client instead of drawing when it runs inside a
burgee --mcp tool call that asked for progress (mcp-current R5).
import { progress } from 'flagstaff/progress';Functions
progress
A progress bar: 12/30 files · 40% off a terminal, a drawn bar on one, and MCP progress inside a call that asked.
function progress(options?: ProgressOptions): Component<ProgressState>;| Parameter | Type |
|---|---|
options (optional) | ProgressOptions |
Returns Component<ProgressState>
Interfaces
ProgressOptions
interface ProgressOptions {
/** Cells the bar occupies on a terminal. Default 24. */
width?: number;
/** The two characters the bar is drawn with. Default `█` and `░`. */
glyphs?: {
filled: string;
empty: string;
};
}ProgressState
interface ProgressState {
/** Units done so far; clamped into `[0, total]` on the way out. */
done: number;
total: number;
/** What is being counted, e.g. `files`. Read in both projections. */
label?: string;
}