-
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
HACK Week: Add filter history to order list filter #14820
base: trunk
Are you sure you want to change the base?
Conversation
📲 You can test the changes from this Pull Request in WooCommerce iOS by scanning the QR code below to install the corresponding build.
|
Generated by 🚫 Danger |
private let title = NSLocalizedString( | ||
"filterHistoryView.title", | ||
value: "Filter History", | ||
comment: "Title of the Filter History view" | ||
) |
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.
Since the view has to be generic, using the static variables for localization is not supported. I'm keeping them all as constants instead.
@State private var selectedFilter: ViewModel.Criteria? | ||
@State private var savedFilters: [ViewModel.Criteria] = [] | ||
@State private var error: Error? | ||
@State private var shouldConfirmClearingHistory = false |
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.
It's not possible to have a generic observable object as a view model, so I'm keeping the states in the view for simplicity.
Version |
Part of #14791
Description
This PR adds UI and logic for the filter history screen of the order list. Features include:
Steps to reproduce
filterHistoryOnOrderAndProductLists
feature flag is enabled and run the app.Testing information
Tested on simulator iPhone 16 Pro iOS 18.2 in light mode, dark mode and different text sizes and confirmed that all look good and work as expected.
Screenshots
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2025-01-08.at.17.18.19.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: