I am trying to change a few of the options in the Set Featured Image
popup in the WordPress admin. I can’t seem to find anything that determines if the popup window is a Featured Image
or an Add Media
popup.
I want to hide Align and Sizes fields for the Set Featured Image
popup but have them visible for the Add Media
panel.
I am able to use the attachment_fields_to_edit
filter to remove certain fields but not for the two different pop up box types.
Is it possible to do this?
I’m familiar with attachment_fields_to_edit and don’t recall ever seeing anything on being able to do modification as granular as you’re suggesting. There’s a WP global $screen (or is it $screens) that perhaps might help but I’m not too sure.
Have you considered – as hacky as it might sound – doing these things with CSS and/or javascript?