Fix #4924 : Hide Search Bar and Filter in "Add to Playlist" When Playlists Are Less Than Two
Pull Request Type
- [ ] Bugfix
- [x] Feature Implementation
- [ ] Documentation
- [ ] Other
Related issue
closes #4924
Description
I have checked whether the playlist length is greater than two before displaying the search bar and search filter in the "Add to Playlist" section. This ensures that these elements will only appear when there are more than two playlists, improving UI clarity and user experience.
Additionally, I have applied the same fix to the Channel List and History pages, ensuring that the search bar will only appear when there is more than one channel or video. This keeps the interface clean and consistent across different sections.
Screenshots
Playlist Before
Playlist After
Channels Before
Channels After
History Before
History After
Desktop
- OS: Windows 11
- OS Version: 24H2 (OS Build 26100.3476)
- FreeTube version: 0.23.2
Additional context
This update prevents unnecessary UI elements from appearing when there are fewer than two playlists, channels, or videos, making the interface cleaner and more intuitive across the "Add to Playlist," Channel List, and History pages.
@efb4f5ff-1298-471a-8973-3d47447115dc Please review it
I believe you misunderstood the problem. The problem is with the Add to playlist prompt:
Thanks for the feedback, @MarmadileManteater ! I now understand that the issue is with the add to playlist prompt specifically. Would you prefer me to revert the earlier commit and apply the correct fix, or should I add another commit on top of the existing one to address the issue?
It does not matter. You could reset to a previous commit, or you could keep going. It will be squash merged either way. I typically prefer a continuous history of what happened.
Hi @MarmadileManteater , Please Review . Thanks!