WordPress.org

Make WordPress Core

Ticket #6178: 6178.diff

File 6178.diff, 1.9 KB (added by iammattthomas, 10 years ago)

Tidy up display of color scheme switcher

  • wp-admin/wp-admin.css

     
    812812        border-style: solid;
    813813}
    814814
    815 #profile-page .form-table input {
    816         width: 200px;
     815.form-table label.color-option {
     816        display: block;
     817        clear: both;
    817818}
    818819
     820.form-table input.tog {
     821        margin-top: 2px;
     822        margin-right: 2px;
     823        float: left;
     824}
     825
     826.form-table table.color-palette {
     827        vertical-align: bottom;
     828        float: left;
     829        margin: -3px 3px 8px;
     830}
     831
     832.form-table .color-palette td {
     833        border-bottom: none;
     834        border: 1px solid #fff;
     835}
     836
    819837#profile-page .form-table textarea {
    820838        width: 500px;
    821         height: 150px;
    822839        margin-bottom: 6px;
    823840}
    824841
  • wp-admin/user-edit.php

     
    158158<td>
    159159<?php
    160160foreach ( $_wp_admin_css_colors as $color => $color_info ): ?>
    161 <p><label>
    162 <input name="admin_color" type="radio" value="<?php echo $color ?>" class="tog" <?php checked($color, get_user_option('admin_color')); ?> />
    163 <?php echo $color_info->name ?>
    164 </label></p>
    165 <table>
    166 <tr>
    167 <?php
    168 foreach ( $color_info->colors as $color ): ?>
    169 <td style="background-color: <?php echo $color ?>" title="<?php echo $color ?>"></td>
     161<label class="color-option"><input name="admin_color" type="radio" value="<?php echo $color ?>" class="tog" <?php checked($color, get_user_option('admin_color')); ?> />
     162        <table class="color-palette">
     163        <tr>
     164        <?php
     165        foreach ( $color_info->colors as $color ): ?>
     166        <td style="background-color: <?php echo $color ?>" title="<?php echo $color ?>"></td>
     167        <?php endforeach; ?>
     168        </tr>
     169        </table>
     170       
     171        <?php echo $color_info->name ?>
     172</label>
    170173<?php endforeach; ?>
    171 </tr>
    172 </table>
    173 <?php endforeach; ?>
    174174</td>
    175175</tr>
    176176</table>
    177177
    178 
    179178<?php
    180179        if ( $is_profile_page ) {
    181180                do_action('profile_personal_options');