@code-yeongyu/senpi
Version:
Coding agent CLI with read, bash, edit, write tools and session management
27 lines • 939 B
JavaScript
import { truncateToWidth } from "@earendil-works/pi-tui";
import { getGrokChromeTokens } from "./chrome-tokens.js";
/** Compact status footer for grok chrome. */
export class GrokFooter {
constructor(session, _footerData) {
this.session = session;
}
setSession(session) {
this.session = session;
}
setAutoCompactEnabled(_enabled) {
// The grok footer intentionally presents model and cwd only.
}
invalidate() {
// Values are read directly from the session during rendering.
}
dispose() {
// No resources are owned by this footer.
}
render(width) {
const tokens = getGrokChromeTokens();
const cwd = this.session.sessionManager.getCwd();
const model = this.session.state.model?.id ?? "no-model";
return [truncateToWidth(`${tokens.cwd(cwd)} ${tokens.modelLabel(model)}`, width, "")];
}
}
//# sourceMappingURL=footer.js.map