Customize: Make the menu edit button look like a link.

The button was introduced in [37901] to allow users switching to the selected menu for further edits. A link makes it more clear that the user is taken away from the current view.
This also adds an aria label and makes the button label more verbose, 'Edit Menu'.

Props afercia.
Props helen for review.
Fixes #36795.
Built from https://develop.svn.wordpress.org/trunk@38189


git-svn-id: http://core.svn.wordpress.org/trunk@38130 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dominik Schilling 2016-08-03 22:45:30 +00:00
parent 4d71eb8423
commit 7ff940d217
6 changed files with 32 additions and 6 deletions

View File

@ -16,8 +16,21 @@
color: #555;
}
/* The `edit-menu` button uses also the `button-link` class. */
.customize-control-nav_menu_location .edit-menu {
margin-top: 1px;
margin-right: 6px;
vertical-align: middle;
color: #0073aa;
text-decoration: underline;
}
.customize-control-nav_menu_location .edit-menu:hover,
.customize-control-nav_menu_location .edit-menu:active {
color: #00a0d2;
}
.customize-control-nav_menu_location .edit-menu:focus {
color: #124964;
}
.wp-customizer .menu-item-bar .menu-item-handle,

File diff suppressed because one or more lines are too long

View File

@ -16,8 +16,21 @@
color: #555;
}
/* The `edit-menu` button uses also the `button-link` class. */
.customize-control-nav_menu_location .edit-menu {
margin-top: 1px;
margin-left: 6px;
vertical-align: middle;
color: #0073aa;
text-decoration: underline;
}
.customize-control-nav_menu_location .edit-menu:hover,
.customize-control-nav_menu_location .edit-menu:active {
color: #00a0d2;
}
.customize-control-nav_menu_location .edit-menu:focus {
color: #124964;
}
.wp-customizer .menu-item-bar .menu-item-handle,

File diff suppressed because one or more lines are too long

View File

@ -77,7 +77,7 @@ class WP_Customize_Nav_Menu_Location_Control extends WP_Customize_Control {
?>
</select>
</label>
<button type="button" class="button edit-menu<?php if ( ! $this->value() ) { echo ' hidden'; } ?>"><?php _e( 'Edit' ); ?></button>
<button type="button" class="button-link edit-menu<?php if ( ! $this->value() ) { echo ' hidden'; } ?>" aria-label="<?php esc_attr_e( 'Edit selected menu' ); ?>"><?php _e( 'Edit Menu' ); ?></button>
<?php
}
}

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.7-alpha-38186';
$wp_version = '4.7-alpha-38189';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.