CircuitVerse / Blog

Blog for updates from circuitverse
https://blog.circuitverse.org
5 stars 53 forks source link

Prevent Blank Search Triggering Results, fixing issue #196 #199

Closed deepak05kr18 closed 7 months ago

deepak05kr18 commented 7 months ago

This pull request addresses the issue where a blank search query triggers search results. The change ensures that the search functionality checks if the search query is empty before initiating a search. If the search query is empty, users will be prompted to enter a valid search term.

Changes Made: Added a condition in the JavaScript code responsible for handling the search to check if the search query is empty. If the search query is empty, an alert is displayed to notify users to enter a valid search term. If the search query is not empty, the search logic proceeds as usual.

Testing: Tested locally to ensure that the search functionality behaves correctly. Verified that submitting a blank search query now prompts users to enter a valid search term.

https://github.com/CircuitVerse/Blog/assets/122279122/8dc6f87f-2bfb-48af-9da5-201c4fd899ec

deepak05kr18 commented 7 months ago

@tanmoysrt @gr455 ,please review this PR

tachyons commented 7 months ago

@deepak05kr18 , Thanks for your attempt. But it seems that you are trying to make the changes on the theme, Issue need to fixed on the upstream repo. We can update the git submodule once the PR to that repo is merged .

deepak05kr18 commented 7 months ago

@deepak05kr18 , Thanks for your attempt. But it seems that you are trying to make the changes on the theme, Issue need to fixed on the upstream repo. We can update the git submodule once the PR to that repo is merged .

Thank you for the guidance. I'll make sure to submit a pull request to the upstream repository to address the issue. Once it's merged, I'll update the git submodule accordingly.