Commit 08ccbea
fix(chat): Prevent input clearing when clicking chat buttons (#1521)
The chat box is no longer cleared when clicking buttons
Previously, we had a bug where if either of the buttons in the agent chat was clicked, the ChatTextArea would get cleared. Now, the text box will only get cleared if the message is sent as part of the response.
Moved input clearing logic to only execute when a message is successfully sent,
preventing the input field from clearing prematurely when clicking "yes" or "no"
buttons in the chat interface. This improves user experience by retaining the
input content if an action fails or requires further interaction
Fixes #1520
Co-authored-by: Chris Hasson <[email protected]>1 parent b7585ea commit 08ccbea
File tree
2 files changed
+15
-8
lines changed- .changeset
- webview-ui/src/components/chat
2 files changed
+15
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
658 | 658 | | |
659 | 659 | | |
660 | 660 | | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
661 | 664 | | |
662 | 665 | | |
663 | 666 | | |
664 | | - | |
665 | | - | |
666 | | - | |
667 | 667 | | |
668 | 668 | | |
669 | 669 | | |
| |||
721 | 721 | | |
722 | 722 | | |
723 | 723 | | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
724 | 727 | | |
725 | 728 | | |
726 | 729 | | |
727 | 730 | | |
728 | | - | |
729 | | - | |
730 | | - | |
731 | 731 | | |
732 | 732 | | |
733 | 733 | | |
| |||
1909 | 1909 | | |
1910 | 1910 | | |
1911 | 1911 | | |
1912 | | - | |
| 1912 | + | |
1913 | 1913 | | |
1914 | 1914 | | |
1915 | 1915 | | |
| |||
1931 | 1931 | | |
1932 | 1932 | | |
1933 | 1933 | | |
1934 | | - | |
| 1934 | + | |
1935 | 1935 | | |
1936 | 1936 | | |
1937 | 1937 | | |
| |||
0 commit comments