Skip to content

Persist and display recent searches throughout the app#2

Open
Edictor96 wants to merge 10 commits into
BeldhariSwapna:mainfrom
Edictor96:main
Open

Persist and display recent searches throughout the app#2
Edictor96 wants to merge 10 commits into
BeldhariSwapna:mainfrom
Edictor96:main

Conversation

@Edictor96

Copy link
Copy Markdown

This pull request introduces a recent searches feature across the application, allowing users to quickly access and reuse their previous search queries. The implementation includes both client-side (localStorage) and server-side (for authenticated users) storage and retrieval of recent searches, as well as UI components to display and interact with them in various pages.

Recent Searches Feature Implementation:

  • API and Backend Support:

    • Added new API endpoints and controller methods to get and save recent searches for authenticated users, including updates to the user model to store recent searches. [1] [2] [3] [4] [5]
  • Search Bar Enhancements:

    • Updated SearchBar to display a dropdown of recent searches when focused and empty, support keyboard shortcuts (/ to focus, Escape to clear), and synchronize recent searches between localStorage and the server. [1] [2] [3] [4]
  • Reusable Recent Searches UI Component:

    • Introduced a new RecentSearchesPanel component for displaying recent searches, which is now used in the Ask Question, Dashboard, and Query pages. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11]
  • Styling:

    • Added styles for the recent searches dropdown in the search bar for a consistent and user-friendly appearance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant