feat: Add support for POST requests on searches for privacy#5551
Open
Fijxu wants to merge 1 commit intoiv-org:masterfrom
Open
feat: Add support for POST requests on searches for privacy#5551Fijxu wants to merge 1 commit intoiv-org:masterfrom
Fijxu wants to merge 1 commit intoiv-org:masterfrom
Conversation
9c19a18 to
68c4de1
Compare
Member
|
Sounds like a neat feature. I know searx(ng) have that feature too. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a privacy-focused search feature that allows users to submit search queries via POST requests instead of GET requests, preventing search terms from being saved in browser history. Users can enable this feature through a new "Search privacy" preference in their settings.
Key Changes:
- Added a new
search_privacyboolean preference to user and config preferences - Modified the search form to use POST method when search privacy is enabled
- Updated the search page title to display "Search" instead of the query text when privacy mode is active
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/invidious/routing.cr | Added POST route handler for /search endpoint |
| src/invidious/routes/search.cr | Updated search handler to accept both GET and POST requests by checking request method |
| src/invidious/views/components/search_box.ecr | Conditionally sets form method to POST or GET based on search_privacy preference |
| src/invidious/views/search.ecr | Modified page title to hide search query when search_privacy is enabled |
| src/invidious/user/preferences.cr | Added search_privacy property to Preferences struct |
| src/invidious/routes/preferences.cr | Added handling for search_privacy form parameter |
| src/invidious/config.cr | Added search_privacy default configuration option |
| locales/en-US.json | Added localization strings for the search privacy preference UI |
| src/invidious/views/user/preferences.ecr | Added checkbox UI for enabling/disabling search privacy feature |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Member
Author
Use already set preferences variable Use span for description, grammar fix from Copilot
57beac8 to
2f67855
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Add support for POST requests on the search field for people that do not want their search history saved in their browser history.