feat(frontend): add stop button to cancel streaming response#485
feat(frontend): add stop button to cancel streaming response#485bot-kiwi[bot] wants to merge 2 commits into
Conversation
- Add stop() from useChat to destructure - Add conditional Stop button visible only while isAssistantTyping - Stop button replaces send button during streaming - Call stop() on click to cancel the AI response Closes #484
|
@greptile review |
|
| Filename | Overview |
|---|---|
| apps/frontend/components/chat/ProjectChat.tsx | Adds stop from useChat and swaps the Send button for a Stop button while isAssistantTyping is true; the isAssistantTyping guard is correctly removed from the Send button's disabled list since the button is now hidden during streaming. |
| apps/frontend/messages/en.json | Adds the stop.response translation key required by the new Stop button. |
| apps/frontend/messages/de.json | Adds the German stop.response translation key alongside its English counterpart. |
Reviews (4): Last reviewed commit: "fix(frontend): add missing stop.response..." | Re-trigger Greptile
|
@greptile review |
Summary
Add a Stop button to cancel streaming AI responses. When the assistant is generating a response, users can now click the Stop button to abort the stream instead of waiting for it to complete.
Type of Change
Changes Made
stopto theuseChatdestructure inProjectChat.tsxisAssistantTypingis truestop()on clickRelated Issues
Testing
Checklist
make generateif SQL queries were modified (backend)