Changeset 9430

Show
Ignore:
Timestamp:
10/31/08 06:53:55 (2 months ago)
Author:
markjaquith
Message:

Bring Comment Save postbox up to parity with Post/Page Publish postbox

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-admin/css/colors-fresh.css

    r9419 r9430  
    2828#replyrow #ed_reply_toolbar input { 
    2929    border-color: #ccc; 
     30} 
     31 
     32#poststuff .inside .spam { 
     33    color: red; 
     34} 
     35 
     36#poststuff .inside .waiting { 
     37    color: orange; 
     38} 
     39 
     40#poststuff .inside .approved { 
     41    color: green; 
    3042} 
    3143 
  • trunk/wp-admin/edit-form-comment.php

    r9425 r9430  
    3434<div id="submitdiv" class="stuffbox" > 
    3535<h3><span class='hndle'>Save</span></h3> 
    36  
     36<div class="inside"> 
    3737<div class="submitbox" id="submitcomment"> 
    38 <div class="inside-submitbox"> 
    39  
    40 <div class="insidebox"> 
    41 <div id='comment-status-radio'
    42 <p><strong><?php _e('This comment is') ?></strong></p> 
    43 <label><input type="radio"<?php checked( $comment->comment_approved, '1' ); ?> name="comment_status" value="1" /><?php _e('Approved') ?></label><br /> 
    44 <label><input type="radio"<?php checked( $comment->comment_approved, '0' ); ?> name="comment_status" value="0" /><?php _e('Awaiting Moderation') ?></label><br /> 
    45 <label><input type="radio"<?php checked( $comment->comment_approved, 'spam' ); ?> name="comment_status" value="spam" /><?php _e('Spam') ?></label> 
     38<div id="minor-publishing"> 
     39<div id="misc-publishing-actions"> 
     40<div id="misc-pub-block-1"> 
     41<div class="misc-pub-section" id="comment-status-radio"
     42<p><?php _e('Status:') ?></p> 
     43<label class="approved"><input type="radio"<?php checked( $comment->comment_approved, '1' ); ?> name="comment_status" value="1" /><?php _e('Approved') ?></label><br /> 
     44<label class="waiting"><input type="radio"<?php checked( $comment->comment_approved, '0' ); ?> name="comment_status" value="0" /><?php _e('Awaiting Moderation') ?></label><br /> 
     45<label class="spam"><input type="radio"<?php checked( $comment->comment_approved, 'spam' ); ?> name="comment_status" value="spam" /><?php _e('Spam') ?></label> 
    4646</div> 
    4747</div> 
    48  
    49 <div class="insidebox" id="deletebutton"> 
     48<div id="misc-pub-block-2"> 
     49<div class="misc-pub-section curtime misc-pub-section-2-last"> 
    5050<?php 
    51 echo "<a class='submitdelete' href='" . wp_nonce_url("comment.php?action=deletecomment&amp;c=$comment->comment_ID&amp;_wp_original_http_referer=" . wp_get_referer(), 'delete-comment_' . $comment->comment_ID) . "' onclick=\"if ( confirm('" . js_escape(__("You are about to delete this comment. \n  'Cancel' to stop, 'OK' to delete.")) . "') ) { return true;}return false;\">" . __('Delete comment') . "</a>"; ?> 
     51$datef = _c( 'M j, Y \a\t G:i|Publish box date format'); 
     52$stamp = __('Submitted on:<br />%1$s'); 
     53$date = date_i18n( $datef, strtotime( $comment->comment_date ) ); 
     54?> 
     55<span id="timestamp"><?php printf($stamp, $date); ?></span>&nbsp;<a href="#edit_timestamp" class="edit-timestamp hide-if-no-js" tabindex='4'><?php _e('Edit') ?></a> 
     56<div id='timestampdiv' class='hide-if-js'><?php touch_time(('editcomment' == $action), 0, 5); ?></div> 
    5257</div> 
    53  
    54 <?php 
    55 $stamp = __('%1$s at %2$s'); 
    56 $date = mysql2date(get_option('date_format'), $comment->comment_date); 
    57 $time = mysql2date(get_option('time_format'), $comment->comment_date); 
    58 ?> 
    59 <div class="insidebox curtime"><span id="timestamp"><?php printf($stamp, $date, $time); ?></span>&nbsp;<a href="#edit_timestamp" class="edit-timestamp hide-if-no-js" tabindex='4'><?php _e('Edit') ?></a> 
    60 <div id='timestampdiv' class='hide-if-js'><?php touch_time(('editcomment' == $action), 0, 5); ?></div></div> 
    61  
    6258</div> 
    63  
    64 <p class="submit"> 
    65 <input type="submit" name="save" value="<?php _e('Save'); ?>" tabindex="4" class="button button-highlighted" /> 
     59</div> <!-- misc actions --> 
     60<div id="minor-publishing-actions"> 
    6661<a class="preview button" href="<?php echo get_comment_link(); ?>" target="_blank"><?php _e('View Comment'); ?></a> 
    67 </p> 
    6862</div> 
    69  
     63<div class="clear"></div> 
     64</div> 
     65<div id="major-publishing-actions"> 
     66<div id="delete-action"> 
     67<a class='submitdelete deletion' href='"<?php echo wp_nonce_url("comment.php?action=deletecomment&amp;c=$comment->comment_ID&amp;_wp_original_http_referer=" . wp_get_referer(), 'delete-comment_' . $comment->comment_ID) . "' onclick=\"if ( confirm('" . js_escape(__("You are about to delete this comment. \n  'Cancel' to stop, 'OK' to delete.")) . "') ) { return true;}return false;\">" . __('Delete'); ?></a> 
     68</div> 
     69<div id="publishing-action"> 
     70<input type="submit" name="save" value="<?php _e('Update Comment'); ?>" tabindex="4" class="button-primary" /> 
     71</div> 
     72<div class="clear"></div> 
     73</div> 
     74</div> 
     75</div> 
    7076</div> 
    7177</div> 
  • trunk/wp-admin/js/comment.js

    r9425 r9430  
    3636        $('.edit-timestamp').show(); 
    3737        $('#timestamp').html( 
     38            commentL10n.submittedOn + '<br />' + 
    3839            $( '#mm option[value=' + $('#mm').val() + ']' ).text() + ' ' + 
    3940            $('#jj').val() + ', ' + 
  • trunk/wp-admin/wp-admin.css

    r9426 r9430  
    214214} 
    215215 
    216 #side-sortables #misc-publishing-actions { 
     216#side-info-column #misc-publishing-actions { 
    217217    max-width: 170px; 
    218 } 
    219  
    220 #side-sortable #minor-publishing-actions { 
    221     max-width: 108px; 
    222218} 
    223219 
     
    231227} 
    232228 
    233 #normal-sortables .misc-pub-section-1-last, 
     229#post-body .misc-pub-section-1-last, 
    234230.misc-pub-section-2-last { 
    235231    border-bottom: 0; 
    236232} 
    237233 
    238 #normal-sortables #misc-pub-block-1, 
    239 #normal-sortables #misc-pub-block-2 { 
     234#post-body #misc-pub-block-1, 
     235#post-body #misc-pub-block-2 { 
    240236    float: left; 
    241237    min-height: 70px; 
    242238} 
    243239 
    244 #normal-sortables #misc-pub-block-1 { 
     240#post-body #misc-pub-block-1 { 
    245241    border-right: 1px solid #ddd; 
    246242} 
    247243 
    248 #normal-sortables #misc-pub-block-2 { 
     244#post-body #misc-pub-block-2 { 
    249245    border-left: 1px solid #ddd; 
    250246    margin-left: -1px; 
     
    291287    text-align: left; 
    292288    float: left; 
    293     width: 30%; 
    294289} 
    295290 
     
    297292    text-align: right; 
    298293    float: right; 
    299     width: 70%; 
    300294} 
    301295 
  • trunk/wp-includes/script-loader.php

    r9429 r9430  
    212212        ) ); 
    213213        $scripts->add( 'link', '/wp-admin/js/link.js', array('jquery-ui-tabs', 'wp-lists', 'postbox', 'settings-box'), '20080925' ); 
    214         $scripts->add( 'comment', '/wp-admin/js/comment.js', array('jquery'), '20080219' ); 
     214        $scripts->add( 'comment', '/wp-admin/js/comment.js', array('jquery'), '20081030' ); 
    215215        $scripts->localize( 'comment', 'commentL10n', array( 
    216216            'cancel' => __('Cancel'), 
    217217            'edit' => __('Edit'), 
     218            'submittedOn' => __('Submitted on:') 
    218219        ) ); 
    219220        $scripts->add( 'admin-gallery', '/wp-admin/js/gallery.js', array( 'jquery-ui-sortable' ), '20080709' ); 
     
    328329    $rtl_styles = array( 'global', 'colors', 'dashboard', 'ie', 'install', 'login', 'media', 'theme-editor', 'upload', 'widgets', 'press-this', 'press-this-ie' ); 
    329330 
    330     $styles->add( 'wp-admin', '/wp-admin/wp-admin.css', array(), '20081030' ); 
     331    $styles->add( 'wp-admin', '/wp-admin/wp-admin.css', array(), '20081030b' ); 
    331332    $styles->add_data( 'wp-admin', 'rtl', '/wp-admin/rtl.css' ); 
    332333 
     
    335336 
    336337    $styles->add( 'colors', true ); // Register "meta" stylesheet for admin colors 
    337     $styles->add( 'colors-fresh', '/wp-admin/css/colors-fresh.css', array(), '20081028'); // for login.php.  Is there a better way? 
     338    $styles->add( 'colors-fresh', '/wp-admin/css/colors-fresh.css', array(), '20081030'); // for login.php.  Is there a better way? 
    338339    $styles->add_data( 'colors-fresh', 'rtl', true ); 
    339340