Customize: Auto-expand a widget area section when expanding the Widgets panel if there is only one registered sidebar and it is active.

Introduces `WP_Customize_Panel::$auto_expand_sole_section` property which allows panels to opt-in to the behavior, which the Widgets panel is made to do by default.

Props delawski, westonruter, melchoyce.
Fixes #37471.

Built from https://develop.svn.wordpress.org/trunk@40395


git-svn-id: http://core.svn.wordpress.org/trunk@40302 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Weston Ruter
2017-04-07 19:27:40 +00:00
parent 8473f9ef66
commit ad293eade7
9 changed files with 83 additions and 31 deletions

View File

@@ -303,6 +303,11 @@ body {
transition: 0.18s transform cubic-bezier(0.645, 0.045, 0.355, 1), 0.18s -webkit-transform cubic-bezier(0.645, 0.045, 0.355, 1); /* easeInOutCubic */
}
#customize-theme-controls .customize-pane-child.skip-transition {
-webkit-transition: none;
transition: none;
}
#customize-info,
#customize-theme-controls .customize-pane-parent {
position: relative;