-
Notifications
You must be signed in to change notification settings - Fork 368
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(webviews): chat history tab with pagination #7020
base: main
Are you sure you want to change the base?
Conversation
This PR refactors the chat history tab to match prompts tab with several UX improvements: - Add pagination support with configurable items per page - Add export and delete all functionality in the header - Improve search functionality with a cleaner command palette style interface - Remove period-based grouping of chat history items - Add confirmation dialog for delete all action - Make history items more compact and consistent - Add keyboard navigation support - Improve empty state messaging and layout ## Test plan - Verify pagination works correctly with different page sizes - Test search functionality filters correctly - Confirm export and delete all actions work as expected - Check keyboard navigation and accessibility - Verify empty state renders appropriately - Test history item interactions and delete functionality
- Add strict boolean check for human message text filtering - Move filtering logic to avoid duplicate filtering operations - Fix empty state to only show when there are no filtered chats and no search text - Simplify filtered chats logic by combining conditions - Remove unnecessary newline in component
// Ensure the chat view is ready before we start typing | ||
await expect(sidebarTabHistoryButton).toBeVisible() | ||
await expect(sidebarChat.getByRole('button', { name: 'Export' })).toBeVisible() | ||
await expect(sidebarChat.getByRole('button', { name: 'Delete all' })).toBeVisible() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noice Changes! ^o^
Some suggestions
- Can we add some space between the export button and delete all button?
- Can we make the two buttons align with the search bar?
- The export button didn't work when I tested this locally.
- The text colors are white for light Color themes, which are hard to see.
- Can we make the buttons slightly smaller?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
while we're here, can we make the chat titles editable by the user? |
@alexromano yea that was on my mind as well and I think this is a good building block for that 😃 I can do that in a follow up since I don't think that's urgent? |
This PR refactors the chat history tab to match prompts tab with several UX improvements:
Fixed bugs:
Delete All
andExport
buttons show up when chat history is emptyTest plan
Updated unit test and e2e test.
After
20 chats per page
Before
With 400+ chat in my history the list gets too long for scrolling.