(session: Session, input: string[])
| 1273 | } |
| 1274 | |
| 1275 | steerMessage(session: Session, input: string[]): void { |
| 1276 | if (this.deferUserMessages || this.state.appState.isCompacting) { |
| 1277 | for (const part of input) { |
| 1278 | this.enqueueMessage(part); |
| 1279 | } |
| 1280 | return; |
| 1281 | } |
| 1282 | if (this.state.appState.streamingPhase === 'idle') { |
| 1283 | for (const part of input) { |
| 1284 | this.sendMessageInternal(session, part); |
| 1285 | } |
| 1286 | return; |
| 1287 | } |
| 1288 | |
| 1289 | for (const part of input) { |
| 1290 | this.appendTranscriptEntry({ |
| 1291 | id: nextTranscriptId(), |
| 1292 | kind: 'user', |
| 1293 | turnId: this.streamingUI.getTurnContext().turnId, |
| 1294 | renderMode: 'plain', |
| 1295 | content: part, |
| 1296 | }); |
| 1297 | } |
| 1298 | |
| 1299 | void session.steer(input.join('\n\n')).catch((error: unknown) => { |
| 1300 | const message = formatErrorMessage(error); |
| 1301 | this.showError(`Failed to steer: ${message}`); |
| 1302 | }); |
| 1303 | } |
| 1304 | |
| 1305 | // ========================================================================= |
| 1306 | // State & Accessors |
nothing calls this directly
no test coverage detected