WordPress.org

Make WordPress Core

Changeset 46359


Ignore:
Timestamp:
09/30/2019 05:55:07 PM (3 weeks ago)
Author:
antpb
Message:

Media: Prevents clipping of text when scaling image edit screen.

This reapplies [46354] clean as the previous commit had remnants of an unrelated patch.

Props sabernhardt, audrasjb, afercia.
See #47115.

Location:
trunk/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/css/edit.css

    r46356 r46359  
    651651.edit-form-section {
    652652    margin-bottom: 20px;
     653}
     654
     655.wp_attachment_details .attachment-content-description {
     656    margin-top: 0.5385em;
     657    display: inline-block;
     658    min-height: 1.6923em;
    653659}
    654660
  • trunk/src/wp-admin/css/media.css

    r46355 r46359  
    11151115}
    11161116
     1117.imgedit-settings .imgedit-original-dimensions {
     1118    display: inline-block;
     1119}
     1120
    11171121.imgedit-settings .imgedit-scale input[type="text"],
    11181122.imgedit-settings .imgedit-crop-ratio input[type="text"],
    11191123.imgedit-settings .imgedit-crop-sel input[type="text"] {
    1120     width: 50px;
     1124    width: 80px;
    11211125    font-size: 14px;
    11221126    padding: 5px 8px;
     
    11291133    font-size: 13px;
    11301134    color: #444;
     1135}
     1136
     1137.imgedit-settings .imgedit-scale-button-wrapper {
     1138    margin-top: 0.3077em;
     1139    display: block;
    11311140}
    11321141
  • trunk/src/wp-admin/includes/image-edit.php

    r46355 r46359  
    6363                /* translators: %s: Image width and height in pixels. */
    6464                __( 'Original dimensions %s' ),
    65                 $meta['width'] . ' × ' . $meta['height']
     65                '<span class="imgedit-original-dimensions">' . $meta['width'] . ' &times; ' . $meta['height'] . '</span>'
    6666            );
    6767            ?>
     
    7979        <input type="text" id="imgedit-scale-height-<?php echo $post_id; ?>" onkeyup="imageEdit.scaleChanged(<?php echo $post_id; ?>, 0, this)" onblur="imageEdit.scaleChanged(<?php echo $post_id; ?>, 0, this)" value="<?php echo isset( $meta['height'] ) ? $meta['height'] : 0; ?>" />
    8080        <span class="imgedit-scale-warn" id="imgedit-scale-warn-<?php echo $post_id; ?>">!</span>
    81         <input id="imgedit-scale-button" type="button" onclick="imageEdit.action(<?php echo "$post_id, '$nonce'"; ?>, 'scale')" class="button button-primary" value="<?php esc_attr_e( 'Scale' ); ?>" />
     81        <div class="imgedit-scale-button-wrapper"><input id="imgedit-scale-button" type="button" onclick="imageEdit.action(<?php echo "$post_id, '$nonce'"; ?>, 'scale')" class="button button-primary" value="<?php esc_attr_e( 'Scale' ); ?>" /></div>
    8282        </div>
    8383        </fieldset>
  • trunk/src/wp-admin/includes/media.php

    r46355 r46359  
    32083208    ?>
    32093209
    3210     <label for="attachment_content"><strong><?php _e( 'Description' ); ?></strong>
     3210    <label for="attachment_content" class="attachment-content-description"><strong><?php _e( 'Description' ); ?></strong>
    32113211    <?php
    32123212
  • trunk/src/wp-includes/css/editor.css

    r46356 r46359  
    13231323        /* .button-small is normally 11px, but a bit too small for these buttons. */
    13241324        font-size: 12px;
    1325         height: 26px;
     1325        min-height: 26px;
    13261326        line-height: 2;
    13271327    }
Note: See TracChangeset for help on using the changeset viewer.