claude-statusline-powerline
Version:
Beautiful powerline-style statusline for Claude Code with git integration, session tracking, and cost monitoring
26 lines • 1.74 kB
TypeScript
import { ClaudeStatusInput, SegmentBuilder, SegmentData, SegmentStyleConfig, StatuslineConfig } from '../types';
export { SegmentBuilder, SegmentData } from '../types';
export declare abstract class BaseSegment implements SegmentBuilder {
abstract name: string;
abstract build(data: ClaudeStatusInput, config: StatuslineConfig): SegmentData | null;
protected createSegment(content: string, bg_color: string, fg_color: string, separator_from_color: string, separator_style?: string, style_override?: SegmentStyleConfig): SegmentData;
protected getSegmentConfig(config: StatuslineConfig): SegmentStyleConfig | undefined;
/**
* Common setup pattern used by all segments
* Returns font profile, style override, and icon getter function
*/
protected setup_segment(config: StatuslineConfig): {
style_override: SegmentStyleConfig | undefined;
font_profile: import("../types").FontProfileData;
get_icon: (icon_name: "clean" | "dirty" | "ahead" | "behind" | "conflicts" | "untracked" | "error" | "branch" | "folder" | "ai" | "warning" | "info" | "cost" | "staged_add" | "staged_del" | "unstaged" | "brain") => string;
};
/**
* Truncate text for this segment using config
*/
protected truncate_text(text: string, config: StatuslineConfig, style_override?: SegmentStyleConfig): string;
/**
* Create segment with fallback colors for the segment type
*/
protected create_segment_with_fallback(content: string, theme_segment: any, fallback_type: 'model' | 'directory' | 'git_clean' | 'git_dirty' | 'session' | 'context' | 'usage' | 'error', separator_style?: string, style_override?: SegmentStyleConfig): SegmentData;
}
//# sourceMappingURL=base.d.ts.map