[wp-trac] [WordPress Trac] #28038: Only show the Edit Image option in the media modal if applicable

WordPress Trac noreply at wordpress.org
Mon May 26 14:30:07 UTC 2014


#28038: Only show the Edit Image option in the media modal if applicable
--------------------------+---------------------------------------------
 Reporter:  Clorith       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  3.9.2
Component:  Media         |     Version:  3.9
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:  ui, javascript, administration
--------------------------+---------------------------------------------
Changes (by ericlewis):

 * keywords:  needs-patch => has-patch
 * focuses:  ui, administration => ui, javascript, administration


Comment:

 Riffing a bit, attachment:28038.2.diff sets a property
 `imageEditorSupports` on the `settings` object, which is a flat array of
 image mime-types the system can handle. Then compare the attachments mime-
 type at microtemplate compile-time to decide whether to show the Edit
 Image link or not.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/28038#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list