Make WordPress Core

Ticket #13134: 13134.ui.2.patch

File 13134.ui.2.patch, 45.7 KB (added by koopersmith, 15 years ago)
  • wp-admin/includes/template.php

     
    35823582        if ( !isset($_wp_contextual_help) )
    35833583                $_wp_contextual_help = array();
    35843584
    3585         $settings = '';
     3585        $settings = apply_filters('screen_settings', '', $screen);
    35863586
    35873587        switch ( $screen->id ) {
    35883588                case 'widgets':
    35893589                        $settings = '<p><a id="access-on" href="widgets.php?widgets-access=on">' . __('Enable accessibility mode') . '</a><a id="access-off" href="widgets.php?widgets-access=off">' . __('Disable accessibility mode') . "</a></p>\n";
    3590                         $show_screen = true;
    35913590                        break;
    35923591        }
     3592        if( $settings )
     3593                $show_screen = true;
    35933594?>
    35943595<div id="screen-meta">
    35953596<?php
    35963597        if ( $show_screen ) :
     3598                $default_text = __('Show on screen');
    35973599?>
    35983600<div id="screen-options-wrap" class="hidden">
    35993601        <form id="adv-settings" action="" method="post">
    3600         <h5><?php _e('Show on screen') ?></h5>
    3601         <div class="metabox-prefs">
    3602 <?php
    3603         if ( !meta_box_prefs($screen) && isset($column_screens) ) {
    3604                 manage_columns_prefs($screen);
    3605         }
    3606 ?>
    3607         <br class="clear" />
    3608         </div>
    3609 <?php echo screen_layout($screen); ?>
    3610 <?php echo $screen_options; ?>
    3611 <?php echo $settings; ?>
     3602        <?php if ( isset($wp_meta_boxes[$screen->id]) ) : ?>
     3603                <h5><?php echo apply_filters('meta_box_prefs_header', $default_text); ?></h5>
     3604                <div class="metabox-prefs">
     3605                        <?php meta_box_prefs($screen); ?>
     3606                        <br class="clear" />
     3607                </div>
     3608                <?php endif;
     3609                if ( isset($column_screens) ) : ?>
     3610                <h5><?php echo apply_filters('columns_prefs_header', $default_text); ?></h5>
     3611                <div class="metabox-prefs">
     3612                        <?php manage_columns_prefs($screen); ?>
     3613                        <br class="clear" />
     3614                </div>
     3615        <?php endif;
     3616        echo screen_layout($screen);
     3617        echo $screen_options;
     3618        echo $settings; ?>
    36123619<div><?php wp_nonce_field( 'screen-options-nonce', 'screenoptionnonce', false ); ?></div>
    36133620</form>
    36143621</div>
  • wp-admin/includes/nav-menu.php

     
    3232                        'page-tab',
    3333                        '_wpnonce',
    3434                );
     35               
     36                $original_title = '';
     37                if ( 'taxonomy' == $item->type ) {
     38                        $original_title = get_term_field( 'name', $item->object_id, $item->object, 'raw' );
     39                } elseif ( 'post_type' == $item->type ) {
     40                        $original_object = get_post( $item->object_id );
     41                        $original_title = $original_object->post_title;
     42                }
    3543                ?>
    36                 <li id="menu-item-<?php echo $item_id; ?>">
    37                         <dl>
     44                <li id="menu-item-<?php echo $item_id; ?>" class="menu-item-<?php echo strtolower(esc_attr( $item->append )); ?>">
     45                        <dl class="<?php
     46                                if ( isset($_GET['edit-menu-item']) && $item_id == $_GET['edit-menu-item'] )
     47                                        echo 'menu-item-edit-active';
     48                                else
     49                                        echo 'menu-item-edit-inactive';
     50                        ?>">
    3851                                <dt>
    3952                                        <span class="item-title"><?php echo esc_html( $item->title ); ?></span>
    4053                                        <span class="item-controls">
     
    6578                                                                        'move-item'
    6679                                                                );
    6780                                                        ?>" class="item-move-down"><abbr title="<?php esc_attr_e('Move down'); ?>">&#8595;</abbr></a>
    68                                                         |
    6981                                                </span>
    7082                                                <a class="item-edit" id="edit-<?php echo $item_id; ?>" title="<?php _e('Edit Menu Item'); ?>" href="<?php
    7183                                                        echo add_query_arg('edit-menu-item', $item_id, remove_query_arg($removed_args, admin_url( 'nav-menus.php' ) ) );
    72                                                 ?>#menu-item-settings-<?php echo $item_id; ?>"><?php _e('Edit'); ?></a> |
    73                                                 <a class="item-delete submitdelete deletion" id="delete-<?php echo $item_id; ?>" href="<?php
    74                                                 echo wp_nonce_url(
    75                                                         add_query_arg(
    76                                                                 array(
    77                                                                         'action' => 'delete-menu-item',
    78                                                                         'menu-item' => $item_id,
    79                                                                 ),
    80                                                                 remove_query_arg($removed_args, admin_url( 'nav-menus.php' ) )
    81                                                         ),
    82                                                         'delete-menu_item_' . $item_id
    83                                                 ); ?>"><?php _e('Delete'); ?></a>
     84                                                ?>#menu-item-settings-<?php echo $item_id; ?>">Edit Menu Item</a>
    8485                                        </span>
    8586                                </dt>
    8687                        </dl>
    8788
    8889                        <div class="menu-item-settings <?php
    89                                 if ( isset($_GET['edit-menu-item']) && $item_id == $_GET['edit-menu-item'] ) :
    90                                         echo ' menu-item-edit-active';
    91                                 else :
    92                                         echo ' menu-item-edit-inactive';
    93                                 endif;
    94                         ?>" id="menu-item-settings-<?php echo $item_id; ?>">
    95                                 <p class="description">
     90                                if ( isset($_GET['edit-menu-item']) && $item_id == $_GET['edit-menu-item'] )
     91                                        echo 'menu-item-edit-active';
     92                                else
     93                                        echo 'menu-item-edit-inactive';
     94                        ?>" id="menu-item-settings-<?php echo $item_id; ?>">           
     95                                <?php if( 'custom' == $item->type ) : ?>
     96                                        <p class="field-url description description-wide">
     97                                                <label for="edit-menu-item-url-<?php echo $item_id; ?>">
     98                                                        <?php _e( 'URL' ); ?><br />
     99                                                        <input type="text" id="edit-menu-item-url-<?php echo $item_id; ?>" class="widefat code edit-menu-item-url" name="menu-item-url[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->url ); ?>" />
     100                                                </label>
     101                                        </p>
     102                                <?php endif; ?>
     103                                <p class="description description-thin">
    96104                                        <label for="edit-menu-item-title-<?php echo $item_id; ?>">
    97                                                 <?php _e( 'Menu Title' ); ?><br />
     105                                                <?php _e( 'Navigation Label' ); ?><br />
    98106                                                <input type="text" id="edit-menu-item-title-<?php echo $item_id; ?>" class="widefat edit-menu-item-title" name="menu-item-title[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->title ); ?>" />
    99107                                        </label>
    100108                                </p>
    101                                 <p class="description">
    102                                         <label for="edit-menu-item-url-<?php echo $item_id; ?>">
    103                                                 <?php _e( 'URL' ); ?><br />
    104                                                 <input type="text" id="edit-menu-item-url-<?php echo $item_id; ?>" class="widefat code edit-menu-item-url" name="menu-item-url[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->url ); ?>" />
    105                                         </label>
    106                                 </p>
    107                                 <p class="description">
     109                                <p class="description description-thin">
    108110                                        <label for="edit-menu-item-attr-title-<?php echo $item_id; ?>">
    109111                                                <?php _e( 'Title Attribute' ); ?><br />
    110112                                                <input type="text" id="edit-menu-item-attr-title-<?php echo $item_id; ?>" class="widefat edit-menu-item-attr-title" name="menu-item-attr-title[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->post_excerpt ); ?>" />
    111113                                        </label>
    112114                                </p>
    113                                 <p class="description">
     115                                <p class="field-link-target description description-thin">
    114116                                        <label for="edit-menu-item-target-<?php echo $item_id; ?>">
    115117                                                <?php _e( 'Link Target' ); ?><br />
    116118                                                <select id="edit-menu-item-target-<?php echo $item_id; ?>" class="widefat edit-menu-item-target" name="menu-item-target[<?php echo $item_id; ?>]">
     
    119121                                                </select>
    120122                                        </label>
    121123                                </p>
    122                                 <p class="description">
     124                                <p class="field-css-classes description description-thin">
    123125                                        <label for="edit-menu-item-classes-<?php echo $item_id; ?>">
    124126                                                <?php _e( 'CSS Classes (optional)' ); ?><br />
    125127                                                <input type="text" id="edit-menu-item-classes-<?php echo $item_id; ?>" class="widefat code edit-menu-item-classes" name="menu-item-classes[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->classes ); ?>" />
    126128                                        </label>
    127129                                </p>
    128                                 <p class="description">
     130                                <p class="field-xfn description description-thin">
    129131                                        <label for="edit-menu-item-xfn-<?php echo $item_id; ?>">
    130                                                 <?php _e( 'Link Relationship (XFN) (optional)' ); ?><br />
     132                                                <?php _e( 'Link Relationship (XFN)' ); ?><br />
    131133                                                <input type="text" id="edit-menu-item-xfn-<?php echo $item_id; ?>" class="widefat code edit-menu-item-xfn" name="menu-item-xfn[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->xfn ); ?>" />
    132134                                        </label>
    133135                                </p>
    134                                 <p class="description">
     136                                <p class="field-description description description-wide">
    135137                                        <label for="edit-menu-item-description-<?php echo $item_id; ?>">
    136                                                 <?php _e( 'Description (optional)' ); ?><br />
     138                                                <?php _e( 'Description' ); ?><br />
    137139                                                <textarea id="edit-menu-item-description-<?php echo $item_id; ?>" class="widefat edit-menu-item-description" rows="3" name="menu-item-description[<?php echo $item_id; ?>]"><?php echo esc_html( $item->description ); ?></textarea>
    138140                                                <span class="description"><?php _e('The description will be displayed in the menu if the current theme supports it.'); ?></span>
    139141                                        </label>
    140142                                </p>
    141143                               
     144                                <span class="menu-item-actions description-wide submitbox">
     145                                        <?php if( 'custom' != $item->type ) : ?>
     146                                                <p class="link-to-original"><?php
     147                                                        _e('Original ');
     148                                                        echo esc_html( $item->append );
     149                                                        echo ":"; ?>
     150                                                        <a href="<?php echo esc_attr( $item->url ); ?>">
     151                                                                <?php echo esc_html($original_title); ?>
     152                                                        </a>
     153                                                </p>
     154                                        <?php endif; ?>
     155                                        <a class="item-delete submitdelete deletion" id="delete-<?php echo $item_id; ?>" href="<?php
     156                                        echo wp_nonce_url(
     157                                                add_query_arg(
     158                                                        array(
     159                                                                'action' => 'delete-menu-item',
     160                                                                'menu-item' => $item_id,
     161                                                        ),
     162                                                        remove_query_arg($removed_args, admin_url( 'nav-menus.php' ) )
     163                                                ),
     164                                                'delete-menu_item_' . $item_id
     165                                        ); ?>"><?php _e('Remove'); ?></a> | <a class="item-close submitclose" id="close-<?php echo $item_id; ?>" href=""><?php _e('Close'); ?></a>
     166                                        <input class="button-primary save-menu-item" name="save_menu_item" type="submit" value="<?php esc_attr_e('Save Menu Item'); ?>" />
     167                                </span>
     168                               
    142169                                <input type="hidden" name="menu-item-append[<?php echo $item_id; ?>]" value="<?php echo $item->append; ?>" />
    143170                                <input type="hidden" name="menu-item-db-id[<?php echo $item_id; ?>]" value="<?php echo $item_id; ?>" />
    144171                                <input type="hidden" name="menu-item-object-id[<?php echo $item_id; ?>]" value="<?php echo esc_attr( $item->object_id ); ?>" />
     
    259286}
    260287
    261288/**
    262  * Register nav menu metaboxes
     289 * Register nav menu metaboxes and advanced menu items
    263290 *
    264291 * @since 3.0.0
    265292 **/
    266 function wp_nav_menu_meta_boxes_setup() {
     293function wp_nav_menu_setup() {
     294        // Register meta boxes
    267295        add_meta_box( 'add-custom-links', __('Custom Links'), 'wp_nav_menu_item_link_meta_box', 'nav-menus', 'side', 'default' );
    268296        wp_nav_menu_post_type_meta_boxes();
    269297        wp_nav_menu_taxonomy_meta_boxes();
     298       
     299       
     300        // Register advanced menu items (columns)
     301        add_filter( 'manage_nav-menus_columns', 'wp_nav_menu_manage_columns');
     302       
     303        add_filter( 'columns_prefs_header', create_function( '', "return __('Show advanced menu properties');" ));
     304       
     305       
     306       
     307        // If first time editing, disable advanced items by default.
     308        if( false === get_user_option( 'managenav-menuscolumnshidden' ) ) {
     309                $user = wp_get_current_user();
     310                update_user_option($user->ID, "managenav-menuscolumnshidden",
     311                        array ( 0 => 'link-target', 1 => 'css-classes', 2 => 'xfn', 3 => 'description', ),
     312                        true);
     313        }
    270314}
    271315
    272316/**
     
    373417        ?>
    374418        <div class="customlinkdiv">
    375419                <ul id="customlink-tabs" class="customlink-tabs add-menu-item-tabs">
    376                         <li <?php echo ( 'create' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg('customlink-tab', 'create', remove_query_arg($removed_args)); ?>#tabs-panel-create-custom"><?php _e('Create New'); ?></a></li>
     420                        <li <?php echo ( 'create' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg('customlink-tab', 'create', remove_query_arg($removed_args)); ?>#tabs-panel-create-custom"><?php _e('Create New'); ?></a></li>
    377421                </ul>
    378422
    379423                <div class="tabs-panel <?php
     
    390434                        <p id="menu-item-name-wrap">
    391435                                <label class="howto" for="custom-menu-item-name">
    392436                                        <span><?php _e('Text'); ?></span>
    393                                         <input id="custom-menu-item-name" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-title]" type="text" class="regular-text menu-item-textbox" value="<?php echo esc_attr( __('Menu Item') ); ?>" />
     437                                        <input id="custom-menu-item-name" name="menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-title]" type="text" class="regular-text menu-item-textbox label-with-default-title" title="<?php esc_attr_e('Menu Item'); ?>" />
    394438                                </label>
    395439                        </p>
    396440                </div><!-- /.tabs-panel -->
     
    508552        ?>
    509553        <div id="posttype-<?php echo $post_type_name; ?>" class="posttypediv">
    510554                <ul id="posttype-<?php echo $post_type_name; ?>-tabs" class="posttype-tabs add-menu-item-tabs">
    511                         <li <?php echo ( 'all' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg($post_type_name . '-tab', 'all', remove_query_arg($removed_args)); ?>#<?php echo $post_type_name; ?>-all"><?php _e('View All'); ?></a></li>
    512                         <li <?php echo ( 'search' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg($post_type_name . '-tab', 'search', remove_query_arg($removed_args)); ?>#tabs-panel-posttype-<?php echo $post_type_name; ?>-search"><?php _e('Search'); ?></a></li>
     555                        <li <?php echo ( 'all' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg($post_type_name . '-tab', 'all', remove_query_arg($removed_args)); ?>#<?php echo $post_type_name; ?>-all"><?php _e('View All'); ?></a></li>
     556                        <li <?php echo ( 'search' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg($post_type_name . '-tab', 'search', remove_query_arg($removed_args)); ?>#tabs-panel-posttype-<?php echo $post_type_name; ?>-search"><?php _e('Search'); ?></a></li>
    513557                </ul>
    514558
    515559                <div class="tabs-panel <?php
     
    664708        ?>
    665709        <div id="taxonomy-<?php echo $taxonomy_name; ?>" class="taxonomydiv">
    666710                <ul id="taxonomy-<?php echo $taxonomy_name; ?>-tabs" class="taxonomy-tabs add-menu-item-tabs">
    667                         <li <?php echo ( 'most-used' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'most-used', remove_query_arg($removed_args)); ?>#tabs-panel-<?php echo $taxonomy_name; ?>-pop"><?php _e('Most Used'); ?></a></li>
    668                         <li <?php echo ( 'search' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'search', remove_query_arg($removed_args)); ?>#tabs-panel-search-taxonomy-<?php echo $taxonomy_name; ?>"><?php _e('Search'); ?></a></li>
    669                         <li <?php echo ( 'all' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="menu-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'all', remove_query_arg($removed_args)); ?>#tabs-panel-<?php echo $taxonomy_name; ?>-all"><?php _e('View All'); ?></a></li>
     711                        <li <?php echo ( 'most-used' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'most-used', remove_query_arg($removed_args)); ?>#tabs-panel-<?php echo $taxonomy_name; ?>-pop"><?php _e('Most Used'); ?></a></li>
     712                        <li <?php echo ( 'search' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'search', remove_query_arg($removed_args)); ?>#tabs-panel-search-taxonomy-<?php echo $taxonomy_name; ?>"><?php _e('Search'); ?></a></li>
     713                        <li <?php echo ( 'all' == $current_tab ? ' class="tabs"' : '' ); ?>><a class="nav-tab-link" href="<?php echo add_query_arg($taxonomy_name . '-tab', 'all', remove_query_arg($removed_args)); ?>#tabs-panel-<?php echo $taxonomy_name; ?>-all"><?php _e('View All'); ?></a></li>
    670714                </ul>
    671715
    672716                <div id="tabs-panel-<?php echo $taxonomy_name; ?>-pop" class="tabs-panel <?php
     
    885929
    886930}
    887931
     932/**
     933 * Returns the columns for the nav menus page.
     934 *
     935 * @since 3.0.0
     936 *
     937 * @param string $menu_item_id The ID of the menu item to format.
     938 * @return string|WP_Error $output The menu formatted to edit or error object on failure.
     939 */
     940function wp_nav_menu_manage_columns() {
     941        return array(
     942                'cb' => '<input type="checkbox" />',
     943                'link-target' => __('Link Target'),
     944                'css-classes' => __('CSS Classes'),
     945                'xfn' => __('Link Relationship (XFN)'),
     946                'description' => __('Description'),
     947        );
     948}
     949
    888950?>
  • wp-admin/js/common.dev.js

     
    123123// show/hide/save table columns
    124124columns = {
    125125        init : function() {
     126                var that = this;
    126127                $('.hide-column-tog', '#adv-settings').click( function() {
    127                         var column = $(this).val();
    128                         if ( $(this).attr('checked') )
    129                                 $('.column-' + column).show();
     128                        var $t = $(this), column = $t.val();
     129                        if ( $t.attr('checked') )
     130                                that.checked(column);
    130131                        else
    131                                 $('.column-' + column).hide();
     132                                that.unchecked(column);
    132133
    133                         columns.save_manage_columns_state();
     134                        columns.saveManageColumnsState();
    134135                });
    135136        },
    136137
    137         save_manage_columns_state : function() {
    138                 var hidden = $('.manage-column').filter(':hidden').map(function() { return this.id; }).get().join(',');
     138        saveManageColumnsState : function() {
     139                var hidden = this.hidden();
    139140                $.post(ajaxurl, {
    140141                        action: 'hidden-columns',
    141142                        hidden: hidden,
    142143                        screenoptionnonce: $('#screenoptionnonce').val(),
    143144                        page: pagenow
    144145                });
    145         }
     146        },
     147       
     148        checked : function(column) {
     149                $('.column-' + column).show();
     150        },
     151       
     152        unchecked : function(column) {
     153                $('.column-' + column).hide();
     154        },
     155       
     156        hidden : function() {
     157                return $('.manage-column').filter(':hidden').map(function() { return this.id; }).get().join(',');
     158        },
     159       
     160        useCheckboxesForHidden : function() {
     161                this.hidden = function(){
     162                        return $('.hide-column-tog').not(':checked').map(function() {
     163                                var id = this.id;
     164                                return id.substring( id, id.length - 5 );
     165                        }).get().join(',');
     166                };
     167        },
    146168}
    147169
    148170$(document).ready(function(){columns.init();});
  • wp-admin/js/nav-menu.dev.js

     
    111111                }
    112112        },
    113113
    114         /**
    115          * Get the parent element with the matching class, but go no higher than the form.
    116          *
    117          * @param DOM-element el The descendant element up from which we'll be searching
    118          * @param string parentClass The class name of the desired parent element.
    119          * @return DOM-element The parent element.
    120          */
    121         getParentWrapper = function( el, parentClass ) {
    122                 var form = document.getElementById('nav-menu-meta'),
    123                 i;
    124 
    125                 while (
    126                         el.parentNode &&
    127                         ( ! el.className || -1 == el.className.indexOf(parentClass) ) &&
    128                         el.parentNode != form
    129                 ) {
    130                         el = el.parentNode;
    131                 }
    132 
    133                 return el;
    134         },
    135 
    136114        makeDroppable = function(el) {
    137115                var that = this;
    138116
     
    189167                        // init drag and drop
    190168                        setupListItemsDragAndDrop.call(this, menuList);
    191169
     170                        this.initToggles();
     171                },
     172               
     173                initToggles : function() {
     174                        // init postboxes
    192175                        postboxes.add_postbox_toggles('nav-menus');
     176                       
     177                        // adjust columns functions for menus UI
     178                        columns.useCheckboxesForHidden();
     179                        columns.checked = function(field) {
     180                                $('.field-' + field).removeClass('hidden-field');
     181                        }
     182                        columns.unchecked = function(field) {
     183                                $('.field-' + field).addClass('hidden-field');
     184                        }
     185                        // hide fields
     186                        this.hideAdvancedMenuItemFields();
    193187                },
    194188               
     189                hideAdvancedMenuItemFields : function(container) {
     190                        container = container || '.menu';
     191                        $('.hide-column-tog').not(':checked').each(function(){
     192                                $(container).find('.field-' + $(this).val() ).addClass('hidden-field');
     193                        });
     194                },
     195               
    195196                attachMenuEditListeners : function() {
    196197                        var that = this;
    197198                        $('#update-nav-menu').bind('click', function(e) {
     
    202203                                                return that.eventOnClickMenuDelete(e.target);
    203204                                        } else if ( -1 != e.target.className.indexOf('item-delete') ) {
    204205                                                return that.eventOnClickMenuItemDelete(e.target);
     206                                        } else if ( -1 != e.target.className.indexOf('item-close') ) {
     207                                                return that.eventOnClickCloseLink(e.target);
    205208                                        }
    206209                                }
    207210                        });
     
    211214                        if ( ! formEL )
    212215                                return;
    213216
    214                         var that = this;
     217                        var that = this, lwd = 'label-with-default-title';
     218                       
     219                        $('.'+lwd).each(function(){
     220                                var $t = $(this), title = $t.attr('title'), val = $t.val();
     221                                $t.data(lwd, title);
     222                                if( '' == val ) $t.val(title);
     223                                else if ( title == val ) return;
     224                                else $t.removeClass(lwd);
     225                        }).focus(function(){
     226                                var $t = $(this);
     227                                if( $t.val() == $t.data(lwd) )
     228                                        $t.val('').removeClass(lwd);
     229                        }).blur(function(){
     230                                var $t = $(this);
     231                                if( '' == $t.val() )
     232                                        $t.val( $t.data(lwd) ).addClass(lwd);
     233                        });
    215234
    216                         // set default value for custom link name
    217                         customLinkNameInput = document.getElementById('custom-menu-item-name');
    218                         customLinkURLInput = document.getElementById('custom-menu-item-url');
    219 
    220                         if ( customLinkNameInput ) {
    221                                 customLinkNameDefault = 'undefined' != typeof customLinkNameInput.defaultValue ? customLinkNameInput.defaultValue : customLinkNameInput.getAttribute('value');
    222                                 customLinkURLDefault = 'undefined' != typeof customLinkURLInput.defaultValue ? customLinkURLInput.defaultValue : customLinkURLInput.getAttribute('value');
    223                                 $(customLinkNameInput).bind('focus', function(e) {
    224                                         this.value = customLinkNameDefault == this.value ? '' : this.value;
    225                                 });
    226                                
    227                                 $(customLinkNameInput).bind('blur', function(e) {
    228                                         this.value = '' == this.value ? customLinkNameDefault : this.value;
    229                                 });
    230                         }
    231 
    232235                        // auto-suggest for the quick-search boxes
    233236                        $('input.quick-search').each(function(i, el) {
    234237                                that.setupQuickSearchEventListeners(el);
     
    241244
    242245                attachTabsPanelListeners : function() {
    243246                        $('#menu-settings-column').bind('click', function(e) {
    244                                 if ( e.target && e.target.className && -1 != e.target.className.indexOf('menu-tab-link') ) {
     247                                if ( e.target && e.target.className && -1 != e.target.className.indexOf('nav-tab-link') ) {
    245248                                        var activePanel,
    246249                                        panelIdMatch = /#(.*)$/.exec(e.target.href),
    247250                                        tabPanels,
     
    330333                        var activeEdit,
    331334                        matchedSection = /#(.*)$/.exec(clickedEl.href);
    332335                        if ( matchedSection && matchedSection[1] ) {
    333                                 activeEdit = document.getElementById(matchedSection[1]);
    334                                 if ( activeEdit ) {
    335                                         if ( -1 != activeEdit.className.indexOf('menu-item-edit-inactive') ) {
    336                                                 activeEdit.className = activeEdit.className.replace('menu-item-edit-inactive', 'menu-item-edit-active');
    337                                         } else {
    338                                                 activeEdit.className = activeEdit.className.replace('menu-item-edit-active', 'menu-item-edit-inactive');
     336                                activeEdit = $('#'+matchedSection[1]);
     337                                if( 0 != activeEdit.length ) {
     338                                        if( activeEdit.hasClass('menu-item-edit-inactive') ) {
     339                                                activeEdit.slideDown('fast')
     340                                                        .siblings('dl').andSelf()
     341                                                        .removeClass('menu-item-edit-inactive')
     342                                                        .addClass('menu-item-edit-active');
     343                                        } else {
     344                                                activeEdit.slideUp('fast')
     345                                                        .siblings('dl').andSelf()
     346                                                        .removeClass('menu-item-edit-active')
     347                                                        .addClass('menu-item-edit-inactive');
    339348                                        }
    340349                                        return false;
    341350                                }
    342351                        }
    343352                },
    344353               
     354                eventOnClickCloseLink : function(clickedEl) {
     355                        $(clickedEl).closest('.menu-item-settings').siblings('dl').find('.item-edit').click();
     356                        return false;
     357                },
     358               
    345359                eventOnClickMenuDelete : function(clickedEl) {
    346360                        // Delete warning AYS
    347361                        if ( confirm( navMenuL10n.warnDeleteMenu ) ) {
     
    460474                 * @param object e The event object.
    461475                 */
    462476                eventSubmitMetaForm : function(thisForm, e) {
    463                         var ancestor,
    464                         inputs = thisForm.getElementsByTagName('input'),
     477                        var inputs = thisForm.getElementsByTagName('input'),
    465478                        i = inputs.length,
    466479                        j,
    467480                        listItemData,
     
    471484                        processMethod = function(){},
    472485                        re = new RegExp('menu-item\\[(\[^\\]\]*)');
    473486
     487                        thisForm.className = thisForm.className + ' processing',
    474488                        that = this;
    475489
    476490                        params['action'] = '';
     
    498512                                                params['menu-item[' + listItemDBID + '][' + j + ']'] = listItemData[j];
    499513                                        }
    500514
    501                                         ancestor = getParentWrapper(inputs[i], 'inside');
    502515                                        inputs[i].checked = false;
    503516
    504517                                // we're submitting a search term
     
    508521                                        inputs[i].className &&
    509522                                        -1 != inputs[i].className.search(/quick-search\b[^-]/)
    510523                                ) {
    511                                         ancestor = getParentWrapper(inputs[i], 'inside');
    512524                                        params['action'] = 'menu-quick-search';
    513525                                        params['q'] = inputs[i].value;
    514526                                        params['response-format'] = 'markup';
     
    516528                                        processMethod = that.processQuickSearchQueryResponse;
    517529                                }
    518530                        }
    519 
    520                         if ( ancestor )
    521                                 ancestor.className = ancestor.className + ' processing',
    522 
    523531                        params['menu'] = thisForm.elements['menu'].value;
    524532                        params['menu-settings-column-nonce'] = thisForm.elements['menu-settings-column-nonce'].value;
    525533
    526534                        $.post( ajaxurl, params, function(menuMarkup) {
    527535                                processMethod.call(that, menuMarkup, params);   
    528                                 ancestor.className = ancestor.className.replace(/processing/g, '');
     536                                thisForm.className = thisForm.className.replace(/processing/g, '');
    529537                        });
    530538
    531539                        return false;
     
    592600                        }
    593601
    594602                        this.recalculateSortOrder(menuList);
     603                        this.hideAdvancedMenuItemFields(menuList);
    595604
    596605                        /* set custom link form back to defaults */
    597                         if ( customLinkNameInput && customLinkURLInput ) {
    598                                 customLinkNameInput.value = customLinkNameDefault;
    599                                 customLinkURLInput.value = customLinkURLDefault;
    600                         }
     606                        $('#custom-menu-item-name').val('').blur();
     607                        $('#custom-menu-item-url').val('http://');
    601608                },
    602609
    603610                /**
     
    639646                        if ( items[0] && req.object_type ) {
    640647                                resultList = document.getElementById(req.object_type + '-search-checklist');
    641648                                if ( resultList ) {
    642                                         resultList.innerHTML = '';
    643649                                        resultList.appendChild(items[0]);
    644650                                }
    645651                        } else if ( req.type ) {
     
    647653                                if ( matched && matched[2] ) {
    648654                                        resultList = document.getElementById(matched[2] + '-search-checklist');
    649655                                        if ( resultList ) {
    650                                                 resultList.innerHTML = '';
    651656                                                i = items.length;
    652657                                                if ( ! i ) {
    653658                                                        message = document.createElement('li');
  • wp-admin/nav-menus.php

     
    316316
    317317// The theme supports menus
    318318if ( current_theme_supports('nav-menus') ) {
    319         // Register nav menu metaboxes
    320         wp_nav_menu_meta_boxes_setup();
     319        // Set up nav menu
     320        wp_nav_menu_setup();
    321321
    322322// The theme does not support menus but supports widgets
    323323} elseif ( current_theme_supports('widgets') ) {
    324         // Register nav menu metaboxes
    325         wp_nav_menu_meta_boxes_setup();
     324        // Set up nav menu
     325        wp_nav_menu_setup();
    326326        $messages_div = '<div id="message" class="error"><p>' . __('The current theme does not natively support menus, but you can use the &#8220;Navigation Menu&#8221; widget to add any menus you create here to the theme&#8217;s sidebar.') . '</p></div>';
    327327
    328328// The theme supports neither menus nor widgets.
     
    340340        <?php echo $messages_div; ?>
    341341       
    342342        <?php if ( current_theme_supports('nav-menus') || current_theme_supports('widgets') ) : ?>
     343        <div id="nav-menus-frame">
    343344        <div id="menu-settings-column" class="metabox-holder">
    344345
    345346                <form id="nav-menu-meta" action="<?php echo admin_url( 'nav-menus.php' ); ?>" class="nav-menu-meta" method="post" enctype="multipart/form-data">
     
    350351                </form>
    351352
    352353        </div><!-- /#menu-settings-column -->
    353        
    354354        <div id="menu-management-liquid">
    355                 <div id="menu-management" class="">
    356                         <h2>
     355                <div id="menu-management">
     356                        <div class="nav-tabs">
    357357                                <?php
    358358                                foreach( (array) $nav_menus as $_nav_menu ) :
    359                                
    360                                         ?>
    361                                         <a href="<?php
     359                       
     360                                        ?><a href="<?php
    362361                                                echo add_query_arg(
    363362                                                        array(
    364363                                                                'action' => 'edit',
     
    366365                                                        ),
    367366                                                        admin_url( 'nav-menus.php' )
    368367                                                );
    369                                         ?>" class="menu-tabs<?php
    370                                                 if ( $nav_menu_selected_id != $_nav_menu->term_id )
    371                                                         echo ' menu-tab-inactive';
    372                                         ?>"><?php echo esc_html( $_nav_menu->name ); ?></a>
    373 
    374                                         <?php
     368                                        ?>" class="nav-tab<?php
     369                                                if ( $nav_menu_selected_id == $_nav_menu->term_id )
     370                                                        echo ' nav-tab-active';
     371                                        ?>"><?php echo esc_html( $_nav_menu->name ); ?></a><?php
    375372                                endforeach;
    376                                 ?>
    377                                 <a href="<?php
     373                                ?><a href="<?php
    378374                                        echo add_query_arg(
    379375                                                array(
    380376                                                        'action' => 'edit',
     
    382378                                                ),
    383379                                                admin_url( 'nav-menus.php' )
    384380                                        );
    385                                 ?>" class="menu-tabs menu-add-new<?php
    386                                         if ( 0 != $nav_menu_selected_id )
    387                                                 echo ' menu-tab-inactive';
     381                                ?>" class="nav-tab menu-add-new<?php
     382                                        if ( 0 == $nav_menu_selected_id )
     383                                                echo ' nav-tab-active';
    388384                                ?>"><?php printf( '<abbr title="%s">+</abbr>', esc_html__( 'Add menu' ) ); ?></a>
    389                         </h2>
     385                        </div>
    390386                        <div class="menu-edit">
    391387                                <form id="update-nav-menu" action="<?php echo admin_url( 'nav-menus.php' ); ?>" method="post" enctype="multipart/form-data">
    392                                         <div id="submitpost" class="submitbox">
    393                                                 <div id="minor-publishing">
    394                                                         <div class="misc-pub-section misc-pub-section-last">
    395                                                                 <label class="howto" for="menu-name">
    396                                                                         <span><?php _e('Name'); ?></span>
    397                                                                         <input id="menu-name" name="menu-name" type="text" class="regular-text menu-item-textbox" value="<?php echo esc_attr( $nav_menu_selected_title  ); ?>" />
     388                                        <div id="nav-menu-header">
     389                                                <div id="submitpost" class="submitbox">
     390                                                        <div class="major-publishing-actions">
     391                                                                <label class="menu-name-label howto open-label" for="menu-name">
     392                                                                        <span><?php _e('Menu Name'); ?></span>
     393                                                                        <input name="menu-name" type="text" class="menu-name regular-text menu-item-textbox label-with-default-title" title="Enter menu name here." value="<?php echo esc_attr( $nav_menu_selected_title  ); ?>" />
    398394                                                                        <br class="clear" />
    399395                                                                </label>
    400                                                         </div><!--END .misc-pub-section misc-pub-section-last-->
    401                                                         <br class="clear" />
    402                                                 </div><!--END #misc-publishing-actions-->
    403                                                 <div id="major-publishing-actions">
    404 
    405                                                         <?php if ( ! empty( $nav_menu_selected_id ) ) : ?>
    406                                                         <div id="delete-action">
    407                                                                 <a class="submitdelete deletion menu-delete" href="<?php echo wp_nonce_url( admin_url('nav-menus.php?action=delete&amp;menu=' . $nav_menu_selected_id), 'delete-nav_menu-' . $nav_menu_selected_id ); ?>"><?php _e('Delete Menu'); ?></a>
    408                                                         </div><!--END #delete-action-->
    409                                                         <?php endif; ?>
    410 
    411                                                         <div id="publishing-action">
    412                                                                 <input class="button-primary" name="save_menu" type="submit" value="<?php esc_attr_e('Save Menu'); ?>" />
    413                                                         </div><!--END #publishing-action-->
    414                                                         <br class="clear" />
    415                                                 </div><!--END #major-publishing-actions-->
    416                                         </div><!--END #submitpost .submitbox-->
    417                                         <?php wp_nonce_field( 'closedpostboxes', 'closedpostboxesnonce', false ); ?>
    418                                         <?php wp_nonce_field( 'meta-box-order', 'meta-box-order-nonce', false ); ?>
    419                                         <?php wp_nonce_field( 'update-nav_menu', 'update-nav-menu-nonce' ); ?>
    420                                         <input type="hidden" name="action" value="update" />
    421                                         <input type="hidden" name="menu" id="menu" value="<?php echo esc_attr( $nav_menu_selected_id ); ?>" />
    422                                         <input type="hidden" id="hidden-metaboxes" value="<?php echo wp_initial_nav_menu_meta_boxes(); ?>" />
     396                                                       
     397                                                                <div class="publishing-action">
     398                                                                        <input class="button-primary" name="save_menu" type="submit" value="<?php esc_attr_e('Save Menu'); ?>" />
     399                                                                </div><!--END .publishing-action-->
     400                                                       
     401                                                                <?php if ( ! empty( $nav_menu_selected_id ) ) : ?>
     402                                                                <div class="delete-action">
     403                                                                        <a class="submitdelete deletion menu-delete" href="<?php echo wp_nonce_url( admin_url('nav-menus.php?action=delete&amp;menu=' . $nav_menu_selected_id), 'delete-nav_menu-' . $nav_menu_selected_id ); ?>"><?php _e('Delete Menu'); ?></a>
     404                                                                </div><!--END .delete-action-->
     405                                                                <?php endif; ?>
     406                                                                <br class="clear" />
     407                                                        </div><!--END .major-publishing-actions-->
     408                                                </div><!--END #submitpost .submitbox-->
     409                                                <?php wp_nonce_field( 'closedpostboxes', 'closedpostboxesnonce', false ); ?>
     410                                                <?php wp_nonce_field( 'meta-box-order', 'meta-box-order-nonce', false ); ?>
     411                                                <?php wp_nonce_field( 'update-nav_menu', 'update-nav-menu-nonce' ); ?>
     412                                                <input type="hidden" name="action" value="update" />
     413                                                <input type="hidden" name="menu" id="menu" value="<?php echo esc_attr( $nav_menu_selected_id ); ?>" />
     414                                                <input type="hidden" id="hidden-metaboxes" value="<?php echo wp_initial_nav_menu_meta_boxes(); ?>" />
     415                                        </div><!--END #nav-menu-header-->
    423416                                        <div id="post-body">
    424417                                                <div id="post-body-content">
    425418                                                        <?php if ( is_nav_menu( $nav_menu_selected_id ) && ( current_theme_supports('nav-menus') || current_theme_supports('widgets') ) ) : ?>
     
    445438                        </div><!-- /.menu-edit -->
    446439                </div><!-- /#menu-management -->
    447440        </div><!-- /#menu-management-liquid -->
     441        </div><!-- /#nav-menus-frame-->
    448442        <?php endif; // if menus supported in current theme ?>
    449443</div><!-- /.wrap-->
    450444
  • wp-admin/css/wp-admin.dev.css

     
    494494        padding-top: 10px;
    495495}
    496496
     497.nav-menus-php #wpbody-content .metabox-holder {
     498        padding-top: 24px;
     499}
     500
    497501#content {
    498502        margin: 0;
    499503        width: 100%;
     
    37203724
    37213725/* Tab Interface */
    37223726
    3723 .menu-tabs {
    3724         border-width: 1px 1px 2px;
     3727.nav-tab {
    37253728        border-style: solid;
    37263729        border-color: #ccc #ccc #f9f9f9;
    3727         color: #464646;
    3728         padding: 4px 20px 6px;
     3730        border-width: 1px 1px 0;
     3731        color: #c1c1c1;
     3732        text-shadow: rgba(255,255,255,1) 0 1px 0;
     3733        font-size: 12px;
     3734        line-height: 16px;
     3735        display: inline-block;
     3736        padding: 4px 14px 6px;
    37293737        text-decoration: none;
    37303738        background-color: #fafafa;
    3731         margin: 0 6px 0 0;
     3739        margin: 0 6px -1px 0;
    37323740        -moz-border-radius: 5px 5px 0 0;
    37333741        -webkit-border-top-left-radius: 5px;
    37343742        -webkit-border-top-right-radius: 5px;
     
    37383746        border-top-right-radius: 5px;
    37393747}
    37403748
     3749.nav-tab-active {
     3750        border-width: 1px;
     3751        color: #464646;
     3752}
     3753
    37413754.themes-php .wrap h2, .theme-install-php .wrap h2 {
    37423755        border-bottom: 1px solid #ccc;
     3756        padding-bottom: 0;
    37433757}
    37443758
    3745 .menu-tab-inactive {
    3746         border-width: 1px 1px 0;
    3747         background-color: #fafafa;
    3748         color: #c1c1c1;
     3759h2 .nav-tab {
     3760        padding: 4px 20px 6px;
     3761        font: italic normal normal 24px/35px Georgia, "Times New Roman", "Bitstream Charter", Times, serif;
    37493762}
  • wp-admin/css/nav-menu.dev.css

     
    88 * @subpackage Administration
    99 */
    1010
     11#nav-menus-frame {
     12        margin-left: 300px;
     13}
     14
    1115#menu-settings-column {
    1216        display:block;
    13         float:left;
    1417        width:281px;
     18        margin-left: -300px;
     19        clear: both;
     20        float: left;
    1521}
    1622
    1723#menu-settings-column .inside {
     
    2228        background: url("../images/menu-bits.gif") no-repeat scroll 0 -110px;
    2329}
    2430
     31#wpbody {
     32        position: relative;
     33}
     34
    2535/* Menu Container */
    26 #menu-management-liquid {
    27         float:right;
    28         margin-left:-300px;
    29         width: 100%;
     36#menu-management-liquid {
     37        float: left;
     38        min-width: 100%;
    3039}
    3140#menu-management {
    32         margin-left:300px;
    33         max-width: 600px;
     41        position: relative;
     42        margin-right: 20px;
     43        margin-top: -3px;
     44        width: 100%;
    3445}
    3546        #menu-management .menu-edit {
    36                 background-color:#fff;
    37                 border-color: #dfdfdf;
    38                 border-width: 1px;
     47                margin-bottom: 20px;
     48        }
     49       
     50        #nav-menu-header, #post-body {
     51                border-color: #ccc;
    3952                border-style: solid;
    40                 margin-bottom: 20px;
    41                 padding:0 10px 10px;
     53        }
     54       
     55        #nav-menu-header {
     56                background: url("../images/gray-grad.png") repeat-x scroll left top #dfdfdf;
     57                border-width: 1px 1px 0 1px;
     58                -moz-border-radius-topleft: 6px;
     59                -webkit-border-top-left-radius: 6px;
     60                -khtml-border-top-left-radius: 6px;
     61                border-top-left-radius: 6px;
     62                -moz-border-radius-topright: 6px;
     63                -webkit-border-top-right-radius: 6px;
     64                -khtml-border-top-right-radius: 6px;
     65                border-top-right-radius: 6px;
     66        }
     67       
     68        #post-body {
     69                background: #fff;
     70                padding:0 0 10px 10px;
     71                border-width: 0 1px 1px 1px;
    4272                -moz-border-radius-bottomleft: 6px;
    4373                -webkit-border-bottom-left-radius: 6px;
    4474                -khtml-border-bottom-left-radius: 6px;
     
    4777                -webkit-border-bottom-right-radius: 6px;
    4878                -khtml-border-bottom-right-radius: 6px;
    4979                border-bottom-right-radius: 6px;
    50                 -moz-border-radius-topright: 6px;
    51                 -webkit-border-top-right-radius: 6px;
    52                 -khtml-border-top-right-radius: 6px;
    53                 border-top-right-radius: 6px;
    5480        }
    5581
    5682        #menu-management .menu-add-new abbr {
    5783                font-weight:bold;
    5884        }
     85       
     86        #menu-management .nav-tabs {
     87                padding-left: 30px;
     88        }
    5989
    60         #menu-management .menu-tabs {
    61                 background-color:#fff;
    62                 border-color:#dfdfdf;
    63                 border-bottom-color:#fff;
     90        #menu-management .nav-tab {
     91                background: #f4f4f4;
     92                font-weight: bold;
     93                border-color: #dfdfdf;
    6494        }
    6595       
    66         #menu-management .menu-tab-inactive {
    67                 background-color:#fafafa;
    68                 border-bottom-color:#fafafa;
     96        #menu-management .nav-tab-active {
     97                background: #ececec;
     98                border-color:#ccc;
     99                border-bottom-color: #ececec;
    69100        }
     101       
     102        #menu-management #major-publishing-actions #delete-action {
     103                float: right;
     104                margin-right: 10px;
     105        }
     106       
     107        #menu-name-label {
     108                margin-top: -2px;
     109        }
     110       
     111        #wpbody .open-label {
     112                display: inline-block;
     113        }
     114        #wpbody .open-label span {
     115                padding-right: 10px;
     116        }
     117       
     118        .js .label-with-default-title {
     119                color: #aaa;
     120                font-style: italic;
     121        }
    70122
    71123#menu-management .inside { padding: 0 10px; }
    72124
     125/* Add Menu Item Boxes */
     126.tabs-panel .howto input {
     127        width: 180px;
     128        float: right;
     129}
     130
    73131/* Button Primary Actions */
    74132#menu-container .submit { margin: 0px 0px 10px; padding: 0px; }
    75133
    76 .submitdelete { font-size: 11px; }
     134.submitdelete, .submitclose { font-size: 11px; }
    77135#cancel-save { color: #ff0000; text-decoration: underline; font-size: 11px; margin-left: 20px; margin-top: 5px; }
    78136#cancel-save:hover { background-color: #FF0000; color: #fff; }
    79137
     
    83141        float: right;
    84142}
    85143
    86 .processing .add-to-menu {
     144form.processing .add-to-menu {
    87145        background: url("../images/wpspin_light.gif") no-repeat top center;
    88146        display:block;
    89147        height:20px;
     
    105163#available-links dt { display: block; }
    106164#add-custom-link .howto { font-size: 11px; }
    107165#add-custom-link label span { display: block; float: left; margin-top: 5px; padding-right: 5px; }
    108 .menu-item-textbox { float: right; width: 220px; }
     166.menu-item-textbox { width: 180px; }
    109167.howto span { margin-top: 4px; display: block; float: left; }
    110168
    111169/* Menu item types */
     
    120178.list li .menu-item-title { cursor: pointer; display: block; }
    121179.list li .menu-item-title input { margin-right: 3px; margin-top: -3px; }
    122180
    123 .list li ul li .menu-item-title  { margin-left: 14px; }
    124 .list li ul li ul li .menu-item-title  { margin-left: 28px; }
    125 .list li ul li ul li ul li .menu-item-title  { margin-left: 42px; }
    126 .list li ul li ul li ul li ul li .menu-item-title  { margin-left: 56px; }
    127 .list li ul li ul li ul li ul li ul li .menu-item-title  { margin-left: 70px; }
    128 .list li ul li ul li ul li ul li ul li ul li .menu-item-title  { margin-left: 84px; }
    129 .list li ul li ul li ul li ul li ul li ul li ul li .menu-item-title  { margin-left: 98px; }
    130 .list li ul li ul li ul li ul li ul li ul li ul li ul li .menu-item-title  { margin-left: 112px; }
     181.list li li .menu-item-title  { margin-left: 14px; }
     182.list li li li .menu-item-title  { margin-left: 28px; }
     183.list li li li li .menu-item-title  { margin-left: 42px; }
     184.list li li li li li .menu-item-title  { margin-left: 56px; }
     185.list li li li li li li .menu-item-title  { margin-left: 70px; }
     186.list li li li li li li li .menu-item-title  { margin-left: 84px; }
     187.list li li li li li li li li .menu-item-title  { margin-left: 98px; }
     188.list li li li li li li li li li .menu-item-title  { margin-left: 112px; }
    131189
    132190/* Nav Menu */
    133191#menu-container .inside { padding-bottom: 10px; }
     
    148206        position:relative;
    149207}
    150208.menu li dl dt {
    151         -webkit-border-radius: 6px;
    152         border-radius: 6px;
    153         -moz-border-radius: 6px;
     209        background: url("../images/gray-grad.png") repeat-x scroll left top #DFDFDF;
    154210        border: 1px solid #E6E6E6;
    155211        clear:both;
    156212        position: relative;
    157         padding-left: 10px; 
    158         background-color: #f1f1f1;
    159         height: 35px;
     213        padding-left: 10px;
     214        height: auto;
     215        width: 400px;
    160216        line-height: 35px;
     217        text-shadow: 0 1px 0 #FFFFFF;
     218        font-weight:bold;
     219        overflow: hidden;
    161220}
     221.menu li dl.menu-item-edit-inactive dt {
     222        border-radius: 6px;
     223        -webkit-border-radius: 6px;
     224        -moz-border-radius: 6px;
     225        -khtml-border-radius: 6px;
     226}
     227.menu li dl.menu-item-edit-active dt {
     228        -moz-border-radius: 6px 6px 0 0;
     229        -webkit-border-top-right-radius: 6px;
     230        -webkit-border-top-left-radius: 6px;
     231        -khtml-border-top-right-radius: 6px;
     232        -khtml-border-top-left-radius: 6px;
     233        border-top-right-radius: 6px;
     234        border-top-left-radius: 6px;
     235}
    162236.js .menu li dl dt {
    163237        cursor: move;
    164238}
     
    172246}
    173247
    174248.menu li .item-title {
     249        padding: 7px 0;
     250        line-height: 20px;
    175251        display:block;
    176         height:1em;
    177         margin-right:18em;
     252        margin-right:13em;
    178253}
    179254
     255.menu li .sortable-placeholder {
     256        width: 430px;
     257}
    180258.menu li div.sortable-placeholder {
    181259        background: #f5f5f5;
    182260        border: 1px dashed #bbb;
    183         margin: 10px 0px;
     261        margin: 10px 0;
    184262        padding-top:40px;
    185263}
    186264
     
    189267        padding-bottom:40px;
    190268}
    191269
    192 .menu li ul li { margin-left: 20px; opacity: .7; }
    193 .menu li ul li ul li { opacity: .9; }
    194 .menu li ul li ul li ul li { opacity: .9; }
    195 .menu li ul li ul li ul li ul li { opacity: .95; }
     270.menu li li { margin-left: 20px; }
    196271
    197272/* Drag and Drop */
    198273.dropzone { height: 7px; margin: 3px 0 3px 0; }
    199 .ui-draggable-dragging  { width: 600px; }
    200274
    201275/* Menu item controls */
    202276.item-type { text-transform: uppercase; font-size: 11px; color: #999999; padding-right: 10px; }
    203 .item-controls { font-size: 11px; position: absolute; right: 15px; top: -1px; }
     277.item-controls { font-size: 11px; position: absolute; right: 20px; top: -1px; }
    204278.item-controls a { text-decoration: none; }
    205279.item-controls a:hover { cursor: pointer; }
     280.item-controls .item-order { padding-right: 10px;}
    206281.item-controls .item-order a {
    207282        font-weight:bold;
    208283}
     
    213288
    214289.item-controls .menu-item-delete:hover { color: #ff0000; }
    215290
     291.item-edit {
     292        background: url("../images/menu-bits.gif") no-repeat scroll 0 -105px;
     293        position: absolute;
     294        right: -20px;
     295        top: 0;
     296        display: block;
     297        width: 23px;
     298        height: 36px;
     299        overflow: hidden;
     300        text-indent:-999em;
     301        border-bottom: 1px solid #eee;
     302        -moz-border-radius-bottomleft: 3px;
     303        -webkit-border-bottom-left-radius: 3px;
     304        -khtml-border-bottom-left-radius: 3px;
     305        border-bottom-left-radius: 3px;
     306}
     307
    216308/* Menu editing */
    217 .menu-item-edit-active {
     309.menu-item-settings {
     310        background: #F9F9F9;
     311        width: 400px;
     312        padding: 10px 0 10px 10px;
     313        border: solid #E6E6E6;
     314        border-width: 0 1px 1px 1px;
     315        -moz-border-radius: 0 0 6px 6px;
     316        -webkit-border-bottom-right-radius: 6px;
     317        -webkit-border-bottom-left-radius: 6px;
     318        -khtml-border-bottom-right-radius: 6px;
     319        -khtml-border-bottom-left-radius: 6px;
     320}
     321.menu-item-settings.menu-item-edit-active {
    218322        display:block;
    219323}
    220324
    221 .menu-item-edit-inactive {
     325.menu-item-settings.menu-item-edit-inactive {
    222326        display:none;
    223327}
    224328
     
    227331        text-align:center;
    228332}
    229333
     334.link-to-original {
     335        display: block;
     336        margin: 0 0 10px;
     337        padding: 3px 5px 5px;
     338        font-size: 11px;
     339        color: #777;
     340        font-style: italic;
     341        border: 1px solid #dfdfdf;     
     342        border-radius: 6px;
     343        -webkit-border-radius: 6px;
     344        -moz-border-radius: 6px;
     345        -khtml-border-radius: 6px;
     346}
     347        .link-to-original a {
     348                padding-left: 4px;
     349                font-style: normal;
     350        }
     351
     352.hidden-field {
     353        display: none;
     354}
     355
     356.menu-item-settings .description-thin,
     357.menu-item-settings .description-wide {
     358        margin-right: 10px;
     359        float: left;
     360}
     361.description-thin {
     362        width: 190px;
     363        height: 40px;
     364}
     365.description-wide {
     366        width: 390px;
     367}
     368
     369.menu-item-actions {
     370        padding-top: 15px;
     371        line-height: 25px;
     372}
     373.save-menu-item {
     374        padding-left: 10px;
     375        float: right;
     376}
     377
    230378#cancel-save { cursor: pointer; }
    231379#cancel-save:hover { color: #fff !important; }
    232380#update-menu-item { color: #fff !important; }
     
    234382#update-menu-item:active,
    235383#update-menu-item:focus { color: #eaf2fa !important; border-color: #13455b !important; }
    236384
     385/* Major/minor publishing actions (classes) */
     386.major-publishing-actions {
     387        padding: 5px 10px;
     388        border-bottom: 1px solid #eee;
     389}
     390.major-publishing-actions .publishing-action {
     391        text-align: right;
     392        float: right;
     393        line-height: 23px;
     394}
     395.major-publishing-actions .delete-action {
     396        line-height: 25px;
     397        vertical-align: middle;
     398        text-align: left;
     399        float: right;
     400        padding-right: 15px;
     401}
     402.menu-name-label span {
     403        font-size: 11px;
     404        font-style: normal;
     405}
     406.submitbox .submitclose {
     407        color: #21759B;
     408        border-bottom: 1px solid #21759B;
     409        padding: 1px 2px;
     410        text-decoration: none;
     411}
     412.submitbox .submitclose:hover {
     413        background: #21759B;
     414        color: #fff;
     415}
     416
     417
    237418/* Clearfix */
    238419.button-controls:after, #menu-item-url-wrap:after, #menu-item-name-wrap:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
    239420.button-controls, #menu-item-url-wrap, #menu-item-name-wrap { display: block; }
  • wp-admin/theme-install.php

     
    5959?>
    6060<div class="wrap">
    6161<?php screen_icon(); ?>
    62 <h2><a href="themes.php" class="menu-tabs menu-tab-inactive"><?php echo esc_html_x('Manage Themes', 'theme'); ?></a><a href="theme-install.php" class="menu-tabs"><?php echo esc_html( $title ); ?></a></h2>
     62<h2><a href="themes.php" class="nav-tab"><?php echo esc_html_x('Manage Themes', 'theme'); ?></a><a href="theme-install.php" class="nav-tab nav-tab-active"><?php echo esc_html( $title ); ?></a></h2>
    6363
    6464        <ul class="subsubsub">
    6565<?php
  • wp-admin/themes.php

     
    134134
    135135<div class="wrap">
    136136<?php screen_icon(); ?>
    137 <h2><a href="themes.php" class="menu-tabs"><?php echo esc_html( $title ); ?></a><?php if ( current_user_can('install_themes') ) { ?><a href="theme-install.php" class="menu-tabs menu-tab-inactive"><?php echo esc_html_x('Install Themes', 'theme'); ?></a><?php } ?></h2>
     137<h2><a href="themes.php" class="nav-tab nav-tab-active"><?php echo esc_html( $title ); ?></a><?php if ( current_user_can('install_themes') ) { ?><a href="theme-install.php" class="nav-tab"><?php echo esc_html_x('Install Themes', 'theme'); ?></a><?php } ?></h2>
    138138
    139139<h3><?php _e('Current Theme'); ?></h3>
    140140<div id="current-theme">