(text: string)
| 1134 | } |
| 1135 | |
| 1136 | private async persistInputHistory(text: string): Promise<void> { |
| 1137 | const trimmed = text.trim(); |
| 1138 | if (trimmed.length === 0) return; |
| 1139 | if (trimmed === this.lastHistoryContent) return; |
| 1140 | this.state.editor.addToHistory(trimmed); |
| 1141 | try { |
| 1142 | const file = getInputHistoryFile(this.state.appState.workDir); |
| 1143 | const written = await appendInputHistory(file, trimmed, this.lastHistoryContent); |
| 1144 | if (written) this.lastHistoryContent = trimmed; |
| 1145 | } catch { |
| 1146 | this.lastHistoryContent = trimmed; |
| 1147 | } |
| 1148 | } |
| 1149 | |
| 1150 | recallLastQueued(): QueuedMessage | undefined { |
| 1151 | if (this.state.queuedMessages.length === 0) return undefined; |
no test coverage detected