[wp-trac] [WordPress Trac] #40199: Customize: collapse suggested and previously uploaded header images with accordions

WordPress Trac noreply at wordpress.org
Mon Jul 31 18:45:41 UTC 2017


#40199: Customize: collapse suggested and previously uploaded header images with
accordions
------------------------------+------------------
 Reporter:  celloexpressions  |       Owner:
     Type:  defect (bug)      |      Status:  new
 Priority:  normal            |   Milestone:  4.9
Component:  Customize         |     Version:  3.9
 Severity:  normal            |  Resolution:
 Keywords:  needs-patch       |     Focuses:  ui
------------------------------+------------------

Comment (by westonruter):

 > Apparently the way the current Customizer API is structured requires a
 sub-panel to have a specific kind of label in the panel that opens it
 (similar to what we have in the main navigation list, or in the widget
 list). This means that we don't have the flexibility to just load the sub-
 panel from anywhere.

 That's not absolutely the case. We ''can'' put anything we want in the
 label area with a custom section. My concern was more surrounding that
 there historically have not been controls placed in these locations. The
 API is written in a way where panels contain sections and sections contain
 controls. We've not had a situation where a full-on control is embedded in
 this context, outside of a containing section. There is, in fact, an issue
 (#38077) where we've prototyped allowing controls to be embedded outside
 of sections and outside of the traditional UI structure entirely. So that
 would need to be a dependency here. For a control embedded in a section
 label (technically the `headContainer`), and for any such detached
 controls, we'd need to override the `focus` method to skip trying to
 expand its containing section, since it wouldn't have one. Instead, it
 would need to expand the containing panel.

 In the future the Customizer JS API and UI architecture should be made
 more flexible to allow for more complex flows as well. Adding a control to
 a section label can be done in 4.9, though it may not be the cleanest
 implementation.

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


More information about the wp-trac mailing list