Replace Google suggest API with TheMovieDB multi-search endpoint#2500
Open
NivinCNC wants to merge 12 commits intorecloudstream:masterfrom
Open
Replace Google suggest API with TheMovieDB multi-search endpoint#2500NivinCNC wants to merge 12 commits intorecloudstream:masterfrom
NivinCNC wants to merge 12 commits intorecloudstream:masterfrom
Conversation
Implemented search suggestions using Google's autocomplete API. Added SearchSuggestionAdapter, SearchSuggestionApi, and related UI components to display and interact with suggestions in both mobile and TV search fragments. Suggestions are fetched with debounce and can be selected to search or fill the search box.
Changed root layout from LinearLayout to FrameLayout in both search and search_tv fragments. Moved search suggestions RecyclerView to overlay above content for better UI layering and increased elevation for improved visibility.
Introduces a new setting to enable or disable search suggestions while typing. Updates UI logic to respect this setting, improves suggestion parsing, and adjusts search suggestion recycler margin for better layout.
Updated the text size of search suggestions from 16sp to 18sp for improved readability in the UI.
Introduces a clear suggestions button to the search suggestions overlay, visible on TV layouts. Refactors the suggestions overlay into a FrameLayout to support the button, updates focus handling for TV, and adds a new string resource for the button label.
Moved 'clear history' and 'clear suggestions' buttons into adapter footers for TV and emulator layouts, removing them from the main fragment layouts. Updated SearchHistoryAdaptor and SearchSuggestionAdapter to support footers, and adjusted SearchFragment logic to handle new clear actions. This improves modularity and focus handling, especially for non-phone devices.
Changed SearchHistoryAdaptor and SearchSuggestionAdapter to always display the footer regardless of layout, instead of only on TV or EMULATOR. Updated footer visibility logic to use isGone when the list is empty and ensured footers rebind on list changes to update their state.
Added import for androidx.core.view.isGone in both SearchHistoryAdaptor and SearchSuggestionAdapter. This prepares the adapters to use the isGone extension for view visibility handling.
Ensures the search history recycler view scrolls to the top when new items are added, so the newest entries are always visible first.
Replace Google suggest API with TheMovieDB multi-search endpoint to avoid junky suggestions
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.
Replace Google suggest API with TheMovieDB multi-search endpoint to avoid junky suggestions (Now the suggestions are only related to movies, series, animes etc)