(host: SlashCommandHost)
| 136 | } |
| 137 | |
| 138 | export async function showStatusReport(host: SlashCommandHost): Promise<void> { |
| 139 | const [runtimeStatus, managedUsage] = await Promise.all([ |
| 140 | loadRuntimeStatusReport(host), |
| 141 | loadManagedUsageReport(host), |
| 142 | ]); |
| 143 | const appState = host.state.appState; |
| 144 | const reportArgs = { |
| 145 | version: appState.version, |
| 146 | model: appState.model, |
| 147 | workDir: appState.workDir, |
| 148 | sessionId: appState.sessionId, |
| 149 | sessionTitle: appState.sessionTitle, |
| 150 | thinkingEffort: appState.thinkingEffort, |
| 151 | permissionMode: appState.permissionMode, |
| 152 | planMode: appState.planMode, |
| 153 | contextUsage: appState.contextUsage, |
| 154 | contextTokens: appState.contextTokens, |
| 155 | maxContextTokens: appState.maxContextTokens, |
| 156 | availableModels: appState.availableModels, |
| 157 | status: runtimeStatus.status, |
| 158 | statusError: runtimeStatus.error, |
| 159 | managedUsage: managedUsage?.usage, |
| 160 | managedUsageError: managedUsage?.error, |
| 161 | }; |
| 162 | const panel = new UsagePanelComponent(() => buildStatusReportLines(reportArgs), 'primary', ' Status '); |
| 163 | host.state.transcriptContainer.addChild(panel); |
| 164 | host.state.ui.requestRender(); |
| 165 | } |
| 166 | |
| 167 | export async function showMcpServers(host: SlashCommandHost): Promise<void> { |
| 168 | let servers: readonly McpServerInfo[]; |
no test coverage detected