Make WordPress Core

Ticket #38671: 38671.2.patch

File 38671.2.patch, 2.5 KB (added by Cheffheid, 8 years ago)

Markup update, full styles update

  • wp-admin/async-upload.php

     
    9191$id = media_handle_upload( 'async-upload', $post_id );
    9292if ( is_wp_error($id) ) {
    9393        echo '<div class="error-div error">
    94         <a class="dismiss" href="#" onclick="jQuery(this).parents(\'div.media-item\').slideUp(200, function(){jQuery(this).remove();});">' . __('Dismiss') . '</a>
     94        <button class="dismiss button-link" href="#" onclick="jQuery(this).parents(\'div.media-item\').slideUp(200, function(){jQuery(this).remove();});">' . __('Dismiss') . '</button>
    9595        <strong>' . sprintf(__('&#8220;%s&#8221; has failed to upload.'), esc_html($_FILES['async-upload']['name']) ) . '</strong><br />' .
    9696        esc_html($id->get_error_message()) . '</div>';
    9797        exit;
    9898}
    9999
     100echo '<div class="error-div error">
     101<button class="dismiss button-link" href="#" onclick="jQuery(this).parents(\'div.media-item\').slideUp(200, function(){jQuery(this).remove();});">' . __('Dismiss') . '</button>
     102<strong>' . sprintf(__('&#8220;%s&#8221; has failed to upload.'), esc_html($_FILES['async-upload']['name']) ) . '</strong><br />Test Message</div>';
     103exit;
     104
    100105if ( $_REQUEST['short'] ) {
    101106        // Short form response - attachment ID only.
    102107        echo $id;
  • wp-admin/css/media.css

     
    216216        padding: 10px 0 10px 14px;
    217217}
    218218
    219 .media-item .error-div a.dismiss {
     219.media-item .error-div button.dismiss {
     220        color:  #0073aa;
    220221        display: block;
    221222        float: right;
    222223        margin: 0 10px 0 15px;
     224        outline: 0;
     225        text-decoration:  underline;
     226        -webkit-transition-property: border, background, color;
     227        transition-property: border, background, color;
     228        -webkit-transition-duration: .05s;
     229        transition-duration: .05s;
     230        -webkit-transition-timing-function: ease-in-out;
     231        transition-timing-function: ease-in-out;
    223232}
    224233
     234.media-item .error-div button.dismiss:hover,
     235.media-item .error-div button.dismiss:active {
     236        color: #00a0d2;
     237}
     238
     239.media-item .error-div button.dismiss:focus {
     240        color: #124964;
     241        -webkit-box-shadow:
     242                0 0 0 1px #5b9dd9,
     243                0 0 2px 1px rgba(30, 140, 190, .8);
     244        box-shadow:
     245                0 0 0 1px #5b9dd9,
     246                0 0 2px 1px rgba(30, 140, 190, .8);
     247}
     248
    225249/*------------------------------------------------------------------------------
    226250  14.1 - Media Library
    227251------------------------------------------------------------------------------*/