Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search Reselection #833

Merged
merged 2 commits into from
Dec 28, 2023
Merged

Search Reselection #833

merged 2 commits into from
Dec 28, 2023

Conversation

EricBAndrews
Copy link
Member

Checklist

Pull Request Information

This PR enables re-selecting the search tab to focus the search bar, provided that the feed is already scrolled to the top. I needed to do some slightly unsightly things to the SwiftUIX search bar to make the reselection work, as let uiView = uiView as? _UISearchBar never seems to execute and so the stock .focused doesn't work--the hack I've written doesn't have binding support, so *de-*selecting search requires some manual work, but since navigating off of the search tab usually requires dismissing the keyboard and therefore unfocusing search I don't think that's a huge problem.

Screen.Recording.2023-12-28.at.5.51.17.PM.mov
Screen.Recording.2023-12-28.at.5.51.42.PM.mov

@EricBAndrews EricBAndrews requested a review from a team as a code owner December 28, 2023 22:52
@EricBAndrews EricBAndrews requested review from WestonHanners and ShadowJonathan and removed request for a team December 28, 2023 22:52
Copy link
Contributor

@Sjmarf Sjmarf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 😄

@EricBAndrews EricBAndrews merged commit 8935336 into dev Dec 28, 2023
4 checks passed
@EricBAndrews EricBAndrews deleted the eric/search-reselection-2 branch December 28, 2023 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Tapping search tab again to focus search bar
2 participants