UNPKG

@code-yeongyu/senpi

Version:

Coding agent CLI with read, bash, edit, write tools and session management

22 lines • 1.34 kB
import type { Theme } from "../../../../modes/interactive/theme/theme.ts"; import type { JobWidgetEntry } from "./view-types.ts"; export type JobWidgetLineToken = "accent" | "success" | "error" | "muted"; export interface JobWidgetLineStyle { fg(token: JobWidgetLineToken, text: string): string; } export declare const PLAIN_LINE_STYLE: JobWidgetLineStyle; /** Theme colors, or none at all when `NO_COLOR` is set to a non-empty value. */ export declare function jobWidgetLineStyle(theme: Theme, env?: NodeJS.ProcessEnv): JobWidgetLineStyle; export declare function sparkGlyphs(values: readonly number[], min: number, max: number, columns: number): string; /** `truncateToWidth` closes every cut with SGR resets; text that carried no styling keeps none. */ export declare function cutPlain(text: string, columns: number): string; export interface JobWidgetLineOptions { /** Lead with the job id (the widget area does; a `bash_output` result already names its job). */ showId?: boolean; } /** * The entry as one line no wider than `width` columns, or `undefined` for an entry with nothing to * draw (skipped, or no view). */ export declare function formatJobWidgetLine(entry: JobWidgetEntry, width: number, style: JobWidgetLineStyle, options?: JobWidgetLineOptions): string | undefined; //# sourceMappingURL=tui-line.d.ts.map