Opened 10 years ago
Closed 10 years ago
#24327 closed defect (bug) (fixed)
'Add Media' and Title should show for all formats if Post Formats UI is disabled
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 3.6 | Priority: | high |
Severity: | normal | Version: | 3.6 |
Component: | Post Formats | Keywords: | dev-feedback has-patch |
Focuses: | Cc: |
Description
In [24037] and [24098], we opted to hide the 'Add Media' button for the Aside, Status, Image, Video, and Audio formats in lieu of their respective UIs.
However, if the Post Formats UI is deactivated through either the screen option, the filter, or lack of post_type support, the 'Add Media' button should show as before, assuming the user has the correct capabilities.
Attachments (2)
Change History (19)
#4
@
10 years ago
Currently the show/hide UI checkbox toggles a class in two different places that affect only some elements on the screen. Thinking we should toggle a class on the body so we can properly reset the screen when the post formats UI is hidden.
Also currently we have two code blocks that check whether post formats are supported/enabled: in admin-header.php and edit-form-advanced.php (the part in the second code block is not needed).
We can easily move the check whether to show the UI ($user_wants = get_user_option...) in admin-header, allowing us to toggle a class on the body.
#6
@
10 years ago
- Keywords has-patch added; needs-patch removed
24327.diff deals with the Add Media button and the title field.
#7
@
10 years ago
24327.diff works great in my testing.
#9
@
10 years ago
- Summary changed from 'Add Media' button should show for all formats if Post Formats UI is disabled to 'Add Media' and Title should show for all formats if Post Formats UI is disabled
#11
@
10 years ago
24327.2.diff enforces the post format UI display if there's some structured data associated with the post.
#12
@
10 years ago
Quick test says that 24327.2.diff does exactly as advertised. Seems to work when turning it off WHILE editing an existing post with structured data as well as when it's already off before you edit said post.
#16
in reply to:
↑ 15
@
10 years ago
Replying to kovshenin:
Is there anything else that should be done here?
I think [24264] and [24282] pretty much covered it. I think we can close this as fixed.
Just so it's clear, we're only forcing the UI if the screen option is turned off and the post has a format and not forcing it if it's disabled via the filter, correct?
This brings up a fairly serious UX issue: what happens when you turn off the UI? Is your structured data in any way discoverable? How can you even edit a post when the UI is off? Most of your data would be missing.