Customizer: Fix live preview for menu item titles.

Show also a default label for menu items without a label which are assigned to a menu. This is currently only supported in the Customizer, see #24146 for nav menus screen.

see #32576.
Built from https://develop.svn.wordpress.org/trunk@32895


git-svn-id: http://core.svn.wordpress.org/trunk@32866 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dominik Schilling 2015-06-20 22:33:26 +00:00
parent c13cb27c14
commit 095dfe5386
3 changed files with 5 additions and 3 deletions

View File

@ -1558,7 +1558,7 @@ class WP_Customize_Nav_Menu_Item_Control extends WP_Customize_Control {
<span class="item-type">{{ data.item_type_label }}</span>
<span class="item-title">
<span class="spinner"></span>
<span class="menu-item-title">{{ data.title }}</span>
<span class="menu-item-title<# if ( ! data.title ) { #> no-title<# } #>">{{ data.title || wp.customize.Menus.data.l10n.untitled }}</span>
</span>
<span class="item-controls">
<button type="button" class="not-a-button item-edit"><span class="screen-reader-text"><?php _e( 'Edit Menu Item' ); ?></span></button>

View File

@ -580,7 +580,9 @@ final class WP_Customize_Nav_Menus {
<div class="menu-item-bar">
<div class="menu-item-handle">
<span class="item-type">{{ data.type_label }}</span>
<span class="item-title">{{ data.title || wp.customize.Menus.data.l10n.untitled }}</span>
<span class="item-title">
<span class="menu-item-title<# if ( ! data.title ) { #> no-title<# } #>">{{ data.title || wp.customize.Menus.data.l10n.untitled }}</span>
</span>
<button type="button" class="not-a-button item-add"><span class="screen-reader-text"><?php _e( 'Add Menu Item' ) ?></span></button>
</div>
</div>

View File

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