-
Notifications
You must be signed in to change notification settings - Fork 111
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
Product Selector - Reset filters after completing selection or dismissal #14764
base: trunk
Are you sure you want to change the base?
Conversation
…or closing the product selector screen.
📲 You can test the changes from this Pull Request in WooCommerce iOS by scanning the QR code below to install the corresponding build.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the fix! When testing I found that the product selector can be dragged to dismiss, in which case the filter is not updated. We should handle that case also:
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2024-12-25.at.15.11.57.mp4
Thanks for reporting this, @itsmeichigo! Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-12-25.at.18.25.57.mp4On a simulator running iOS 17.4, I cannot swipe and dismiss the product selector. Also, I see that the Could you please share in which simulator version you tested this? |
Interesting! I can confirm that I cannot dismiss the product selector on 17.4 either but can dismiss on both 18.1 and 18.2. This seems to be an issue with iOS 18. |
What do you think about resetting the filter on the product list upon |
Good find. Thanks for sharing, @itsmeichigo!
I tried this option initially and decided not to go this way. I want to avoid reloading the screen from viewWillAppear to avoid changing the table view scroll position. I think we can merge this PR, considering this is an iOS issue. What do you think? |
Did you see the table changing position when you tried the solution? I did a quick check as well and didn't see it, but I may have missed something. If we can confirm the above, I suppose it's alright to merge the PR. |
Closes: #14624
Description
When you apply filters in the product selector screen the main product list screen is affected as the applied core data predicate changes are received by the main product list screen as well.
To avoid the above issue, this PR starts resetting the filters once the product selection process is complete using the saved product settings.
Steps to reproduce
Prerequisites
Products list
Testing information
Screenshots
Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-12-25.at.10.34.28.mp4
RELEASE-NOTES.txt
if necessary.Reviewer (or Author, in the case of optional code reviews):
Please make sure these conditions are met before approving the PR, or request changes if the PR needs improvement: