-
Notifications
You must be signed in to change notification settings - Fork 799
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
External Media: Update Google Photo Filters #16190
Conversation
Caution: This PR has changes that must be merged to WordPress.com |
This is an automated check which relies on E2E results is available here (for debugging purposes): https://jetpack-e2e-dashboard.herokuapp.com/pr-16190 |
2f76359
to
34fe076
Compare
value: DATE_RANGE_OLDER, | ||
label: __( 'Older than a year', 'jetpack' ), | ||
}, | ||
// TODO: Implement a UI for selecting month & year. |
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.
Intentionally left in, as the filtering logic is fully implemented. UI will follow in a different PR.
extensions/shared/external-media/sources/google-photos/google-photos-media.js
Show resolved
Hide resolved
extensions/shared/external-media/sources/google-photos/filter-request.js
Show resolved
Hide resolved
extensions/shared/external-media/sources/google-photos/filter-request.js
Outdated
Show resolved
Hide resolved
Thanks @marekhrabe! A few changes I'd like to suggest:
|
@marekhrabe Can we please use Gutenberg text fields where the label is above the field? Examples: This way, we don't take up too much horizontal space and can accommodate this design. |
I also noticed the "View" toggle moves a pixel up/down when switching views. See: https://cloudup.com/cb-bZ6ZVIwL |
Absolutely, I will look into the styling as a followup PR soon. I plan no more changes in this one and I think we are ready for a final code review. |
implement simpler date filter and hide other filters update the label for recent photos colocate filters and recent/album switch comment out custom range simplified date range update recent label change 'older' filter to 'last 12 months' [not verified] update date range select label remove extraneous import
fe66f93
to
166ccf2
Compare
@jancavan How strongly do you feel about |
extensions/shared/external-media/sources/google-photos/google-photos-media.js
Show resolved
Hide resolved
@obenland @marekhrabe I don't have strong opinions as long as we say, "... by time period". Please feel free to change it :) Thanks. |
Also removes unneeded import. Props @jancavan.
@obenland I think we should add events for this (if we don't have them already), to see if users ever use this? Would be nice to know which options in each dropdown they interact with. Can be in a separate PR of course. |
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.
Good to go from my end. Let's get it in and continue iterating!
Followup work started in… #16266 |
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.
If I use the view filter to switch to the Album view for example, the time period filter disappears. Is that on purpose for now?
Right now I can't say that the time period filter is really useful since it doesn't change what pictures I have access to; I still have to click on Load More if I want to access more than the last 12 pictures on my account. But I guess that will all change once we add more filters.
Approving this PR for now just in case the album use case is on purpose for now as well.
It is, yes, we took that over like that from Tinker. It might be that Google's API doesn't support date filtering for albums? |
r209626-wpcom |
Fixes #15880
Changes proposed in this Pull Request:
Screenshot
New filtering options allow you to:
In a separate PR, I will add an additional date range option that will allow you to customize it. Based on #15880 design
Testing instructions:
Proposed changelog entry for your changes: