Customizer: Improve accessibility of Add Menu Items button and its panel.
props afercia, ocean90. fixes #32682. git-svn-id: https://develop.svn.wordpress.org/trunk@32848 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
ee24335ba5
commit
413d24c47f
@ -1800,8 +1800,10 @@
|
||||
}
|
||||
|
||||
if ( ! $( 'body' ).hasClass( 'adding-menu-items' ) ) {
|
||||
$( this ).attr( 'aria-expanded', 'true' );
|
||||
api.Menus.availableMenuItemsPanel.open( self );
|
||||
} else {
|
||||
$( this ).attr( 'aria-expanded', 'false' );
|
||||
api.Menus.availableMenuItemsPanel.close();
|
||||
event.stopPropagation();
|
||||
}
|
||||
|
@ -1538,7 +1538,7 @@ class WP_Customize_Nav_Menu_Control extends WP_Customize_Control {
|
||||
*/
|
||||
public function content_template() {
|
||||
?>
|
||||
<button type="button" class="button-secondary add-new-menu-item">
|
||||
<button type="button" class="button-secondary add-new-menu-item" aria-expanded="false" aria-controls="available-menu-items">
|
||||
<?php _e( 'Add Items' ); ?>
|
||||
</button>
|
||||
<button type="button" class="not-a-button reorder-toggle">
|
||||
|
Loading…
Reference in New Issue
Block a user