Customize: Skip attaching expansion event handlers to section containers with the `cannot-expand` class.
Props kkoppenhaver, celloexpressions. Fixes #37980. git-svn-id: https://develop.svn.wordpress.org/trunk@38900 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
7e9848df2b
commit
31156b0bfb
|
@ -463,14 +463,16 @@ h3.customize-section-title {
|
|||
display: block;
|
||||
}
|
||||
|
||||
.panel-meta.customize-info .accordion-section-title {
|
||||
#customize-controls .panel-meta.customize-info .accordion-section-title {
|
||||
margin-left: 48px;
|
||||
border-left: none;
|
||||
}
|
||||
|
||||
#customize-controls .panel-meta.customize-info .accordion-section-title:hover {
|
||||
#customize-controls .panel-meta.customize-info .accordion-section-title:hover,
|
||||
#customize-controls .cannot-expand:hover .accordion-section-title {
|
||||
background: #fff;
|
||||
color: #555;
|
||||
border-left: none;
|
||||
border-left-color: #fff;
|
||||
}
|
||||
|
||||
.customize-controls-close:focus,
|
||||
|
|
|
@ -906,6 +906,10 @@
|
|||
attachEvents: function () {
|
||||
var meta, content, section = this;
|
||||
|
||||
if ( section.container.hasClass( 'cannot-expand' ) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Expand/Collapse accordion sections on click.
|
||||
section.container.find( '.accordion-section-title, .customize-section-back' ).on( 'click keydown', function( event ) {
|
||||
if ( api.utils.isKeydownButNotEnterEvent( event ) ) {
|
||||
|
|
Loading…
Reference in New Issue