Skip to content

Commit 2425ce4

Browse files
committed
Media: Fix button focus visibility in media uploads.
Following [r58279], the focus outline on the Edit button after uploading media was partially cut off. Adjust margin and padding to ensure the outline is visible, while also supporting appropriate word wrapping on long file names. Props dilipbheda, karthikeya01, sabernhardt, narenin, zunaid321, Marius84, ankitkumarshah, riddhidave, dilip2615, SirLouen, Presskopp, joedolson. Fixes #63239. git-svn-id: https://develop.svn.wordpress.org/trunk@60637 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 2ac95fc commit 2425ce4

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/wp-admin/async-upload.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@
6060
$title = $post->post_title ? $post->post_title : wp_basename( $file );
6161
?>
6262
<div class="filename new">
63-
<span class="media-list-title"><strong><?php echo esc_html( wp_html_excerpt( $title, 60, '&hellip;' ) ); ?></strong></span>
64-
<span class="media-list-subtitle"><?php echo esc_html( wp_basename( $file ) ); ?></span>
63+
<span class="media-list-title word-wrap-break-word"><strong><?php echo esc_html( wp_html_excerpt( $title, 60, '&hellip;' ) ); ?></strong></span>
64+
<span class="media-list-subtitle word-wrap-break-word"><?php echo esc_html( wp_basename( $file ) ); ?></span>
6565
<div class="attachment-tools">
6666
<?php
6767
if ( current_user_can( 'edit_post', $id ) ) {

src/wp-admin/css/media.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,9 +167,9 @@
167167
}
168168

169169
.media-item .filename {
170-
padding: 14px 0;
170+
padding: 14px 2px;
171171
overflow: hidden;
172-
margin-left: 6px;
172+
margin-left: 4px;
173173
}
174174

175175
.media-item .pinkynail {

0 commit comments

Comments
 (0)