creativecommons / legaldb

CC Legal Database: curated repository of Case Law and Scholarship data from around the world in a Django based website.
https://LegalDB.CreativeCommons.org/
MIT License
44 stars 68 forks source link

[Feature] Add Clear/Reset Button to Search Boxes in Cases and Scholarship Sections #221

Open rypptc opened 1 week ago

rypptc commented 1 week ago

Problem

Currently, when using the search box on the Cases or Scholarship pages, there is no option to quickly reset or clear the search field. Users are required to manually delete the search text and press the search button again, which is not very intuitive.

Description

Add a clear/reset button to the search boxes on both the Cases and Scholarship pages, allowing users to easily reset their search and view all results again without manually clearing the text.

Alternatives

Keep the current status. When the user wants to see the list of results again they need to delete the text in the search box and click on the search button. This is less intuitive.

Additional context

This is how it looks now

image

This is the Github search box as an example of how can be this implemented

image

Implementation

TimidRobot commented 1 week ago

@rypptc This is a good issue! It really bugs me when I use websites without the ability to clear search input.

However, I'm marking this https://github.com/creativecommons/legaldb/labels/%F0%9F%9A%A7%20status%3A%20blocked as I think this should be logged, discussed, and implemented in Vocabulary first (it might be decided that LegalDB is used to prove initial implementation):