DuoChat: Implement prompt abort button
Overview
Implement a user interface change in the GitLab Duo Chat component to include a "Stop" button. This button will be enabled during the loading or streaming of chat content, allowing users to terminate the process if desired.
Designs
Requirements
- Visibility of the Stop Button: The "Stop" button should be prominently displayed and become active once a chat prompt begins processing.
- Interactive Feedback: Upon clicking the "Stop" button, the component should emit an event to notify the host application that the user has requested to terminate the operation. Pressing the Esc key should do the same.
Technical Implementation
- Event Handling: The Duo Chat component needs to throw the 'chat-abort' event, once the abort mechanism was triggered by the user.
Edited by Jannik Lehmann