[wp-trac] [WordPress Trac] #35941: Eliminate WP_Customize_Site_Logo_Control

WordPress Trac noreply at wordpress.org
Thu Feb 25 02:43:01 UTC 2016


#35941: Eliminate WP_Customize_Site_Logo_Control
------------------------------+-------------------------
 Reporter:  celloexpressions  |      Owner:
     Type:  defect (bug)      |     Status:  new
 Priority:  normal            |  Milestone:  4.5
Component:  Customize         |    Version:  trunk
 Severity:  normal            |   Keywords:  needs-patch
  Focuses:                    |
------------------------------+-------------------------
 This is basically a duplicate of `WP_Customize_Image_Control`, causing the
 following problems:
 - API fragmentation - there are multiple controls that do exactly the same
 thing, which will cause confusion for developers as to why they both exist
 in core.
 - Improper use of the customizer API. This is why we have parameters that
 can be set when registering a control - so that the same UI can be used to
 modify different settings with minor adjustments between them.
 - Bad example for theme and plugin authors - implies that every control
 needs a custom control class associated with it even when it's the same.
 - Unnecessary bloat. There is significantly more code to maintain by
 having a separate control, and we gain literally nothing by having it as a
 separate control because they are the same.
 - The site logo control duplicates a lot of code unnecessarily, extending
 the image control instead of the media control and then undoing everything
 that the image control does. The image control only exists for backwards
 compatibility.
 - Logos are one of the primary use-cases for the media/image controls in
 core. If those controls can't fulfill that use case even for a new core
 feature, something is seriously wrong with the media controls API as a
 whole.

 It needs to be removed before RC and can NOT ship in 4.5 or we will be
 stuck with it forever.

 See https://core.trac.wordpress.org/attachment/ticket/33755/33755.14.diff
 for the correct approach to adding a site logo control. The core media
 control requires two trivial changes. All of the css and other bloat that
 was added in [36698] also needs to be cleaned up. One of the changes can
 happen in #35542, then the other piece can happen here.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35941>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list