-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Featured Image dialogue missing "Mine", "Uploaded to this post", "Unattached" filters #8748
Comments
Related #7736 |
@danielbauchhuber, if you're changing the title of this issue, please don't forget the "Uploaded to this post" as that is one of the more important features of that filter. @designsimply, does the "type enhancement" mean that this is not going to be fixed by the 5.0 release of WordPress? |
Done. |
Not necessarily! However, I will note that developers working full time on the project are focused mainly on fixing bugs prior to the 5.0 release, and of course this project is open source and any developer who would like to take on submitting updates may do so. |
I would characterize this as a bug, not a feature request or enhancement , because it's something that worked before and now does not work. As mentioned above, it does work in one situation: Gallery Media Dialogue |
Here's how the Gallery frames factor in this filter as we would expect: https://github.com/WordPress/gutenberg/blob/master/packages/edit-post/src/hooks/components/media-upload/index.js#L36 We'd need to make frames for each instance of the media library and also define a default state. I'm not positive yet how it currently gets the initial frame from the featured image and image block, but I'll investigate. It may just be adding A condition might be needed for
I'm thinking the media frame default (and especially the featured image default) view will need to match this here from Core: https://github.com/WordPress/wordpress-develop/blob/6b366c6620fdd5960cedcdf80955966a715efa82/src/js/media/controllers/featured-image.js#L40-L47 I'll keep digging into this tomorrow. Just wanted to throw a quick brain dump from my initial findings. :) |
I've opened a PR. Would love some testing on it and a review. This adds a condition for featuredImage to allow for the proper frame features (uploaded, mine, not uploaded) to be available. #10810 |
In #10810 there is some discussion around how the featured image flow should go. @joemcgill outlined much of the pending decisions/blockers in this comment: #10810 (comment) The PR currently uses the @joemcgill and I discussed this again today in slack DMs and have come to the agreement that it would be better to push this issue to a later version in favor of a more complete solution that is applicable to all forms of media, and not just featured images. We need to make some decisions and changes in the Media Library structure that would allow it to be better extended or filtered. Just wanted to outline this before moving the milestone without reasoning. Open to suggestions if anyone has any thoughts around this. |
I'm just bumping this thread to point out that this requirement doesn't only apply to featured images, but also to adding/changing any image -- I don't see this mentioned in the thread above. This is particularly needed when changing themes where image resolutions are different. In this use case, and you need to edit a page/post to reinsert the page's/post's images again at a different resolution. Trying to find the images among 1,000s is impossible without the 'Uploaded to this post' feature in the media browser. This is definitely a bug/omission this functionality is present in the Classic editor. |
@antpb I understand the need for better media flow. Just for recap what I remember from past experience with wp. In past years there were various flows for inserting image. WP 3.0 - Up 7, ADD 3 steps - default view was uploaded to post WP 3.5 - UP 5, ADD 5 or 3 steps - default view changed to all media (using plugin Default Media Uploader View) WP 3.9 - UP 4, ADD 5 or 3 steps WP 5.1 - UP 4 (multiplied by the number of single images added to post), ADD 25 Difference between 5.1 and previous - In the previous version, it was possible to upload all files for a given post, and then return back and choose files needed. In 5.1 we are back to WP 3.0 flow, when you have to upload one by one specific file types or separate images. It is very frustrating to see this regress. For better flow, I am thinking about things that could be fixed
|
Definitely a bug/regression rather than diff --git a/wp-includes/js/media-views.js b/wp-includes/js/media-views.js
index 2ffa44b..7edfb19 100644
--- a/wp-includes/js/media-views.js
+++ b/wp-includes/js/media-views.js
@@ -949,7 +949,7 @@ function(module, exports) {
router: 'browse',
toolbar: 'select',
searchable: true,
- filterable: false,
+ filterable: 'uploaded',
sortable: true,
autoSelect: true,
describe: false, |
Thank you drzraf! The missing filters were driving me batty and your fix works! I'm admittedly clueless about github workflows, but I hope someone can get this fix pushed up the chain and into core. My clients and I use 'uploaded to this post' on a daily basis and we've been floundering around without it. |
fwiw, if anyone else comes across this, the media-views.min.js file needs to be updated as well (or at least it did in my case)....once I made that change, and reloaded it, voila, filter has returned! :) thanks! |
Is it possible to implement this fix with a hook, so that when core updates the fix remains in place? |
I have opened a PR that fixes this issue. There was an old PR from over a year ago that had much of the discussion that landed us on the new PR's changes. Link above! |
With #17410 merged, I think we can close this now. Yay! |
Is this ever going to be fixed? I have no option for "Uploaded to this post" in any of my Wordpress installations with Gutenberg. It's present in Classic. Guess I will go back to classic until Gutenberg is actually ready for prime time. |
I confirm, that the problem exists still. As shown in first post (#8748 (comment)) there is no filter with "Mine" when adding image from media library in block editor. (Surprisly when adding gallery the filter exists. When adding thumbnail to the post - the filter exists.) Does anyone know when it will be fixed ? |
It seems this issue has been resolved at However we confirm issue repeats again. Changing Theme to default. Image block dialogue missing Filter Media as "Mine", "Uploaded to this post", "Unattached" filters Any chance to check issue again? |
Still not fixed. Is the status closed because Wordpress isn't planning to fix it, or can we please reopen? Having to search for images adds so much to my workflow when updating posts (which is what a lot of us spend a lot of time doing). |
"Set Featured Image" not as useful
The new editor removes the ability for the "Featured Image" button dialogue to "know" what images have been uploaded to the current Post, as well as what images are "Mine" or "Unattached."
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Having an image "attached" to a Post can be a very useful thing.
This feature makes it handy to find a relevant image when there may be hundreds if not thousands of images to choose from. There may be some importance for this related to WooCommerce.
The two useful popups, one that shows items by owner/relationship and one by date, have been replaced by a smaller popup that is just by date.
Screenshots
Classic editor:
New editor:
Oddly the Gallery Media Dialogue does know how to filter:
Desktop (please complete the following information):
Smartphone
Additional context
The text was updated successfully, but these errors were encountered: