Changeset 58279
- Timestamp:
- 06/02/2024 08:35:30 AM (4 months ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/js/_enqueues/vendor/plupload/handlers.js
r57524 r58279 17 17 .attr( 'id', 'media-item-' + fileObj.id ) 18 18 .addClass( 'child-of-' + postid ) 19 .append( '<div class="progress"><div class="percent">0%</div><div class="bar"></div></div>',20 jQuery( '<div class="filename original">' ).text( ' ' + fileObj.name ))19 .append( jQuery( '<div class="filename original">' ).text( ' ' + fileObj.name ), 20 '<div class="progress"><div class="percent">0%</div><div class="bar"></div></div>' ) 21 21 .appendTo( jQuery( '#media-items' ) ); 22 22 -
trunk/src/wp-admin/async-upload.php
r58210 r58279 66 66 <span class="media-list-title"><strong><?php echo esc_html( wp_html_excerpt( $title, 60, '…' ) ); ?></strong></span> 67 67 <span class="media-list-subtitle"><?php echo esc_html( wp_basename( $file ) ); ?></span> 68 <div class="attachment-tools"> 69 <?php 70 if ( current_user_can( 'edit_post', $id ) ) { 71 echo '<a class="edit-attachment" href="' . esc_url( get_edit_post_link( $id ) ) . '">' . _x( 'Edit', 'media item' ) . '</a>'; 72 } else { 73 echo '<span class="edit-attachment">' . _x( 'Success', 'media item' ) . '</span>'; 74 } 75 ?> 76 <span class="media-item-copy-container copy-to-clipboard-container edit-attachment"> 77 <button type="button" class="button button-small copy-attachment-url" data-clipboard-text="<?php echo $file_url; ?>"><?php _e( 'Copy URL to clipboard' ); ?></button> 78 <span class="success hidden" aria-hidden="true"><?php _e( 'Copied!' ); ?></span> 79 </span> 80 </div> 68 81 </div> 69 </div>70 <div class="attachment-tools">71 <span class="media-item-copy-container copy-to-clipboard-container edit-attachment">72 <button type="button" class="button button-small copy-attachment-url" data-clipboard-text="<?php echo esc_url( $file_url ); ?>"><?php _e( 'Copy URL to clipboard' ); ?></button>73 <span class="success hidden" aria-hidden="true"><?php _e( 'Copied!' ); ?></span>74 </span>75 <?php76 if ( current_user_can( 'edit_post', $id ) ) {77 echo '<a class="edit-attachment" href="' . esc_url( get_edit_post_link( $id ) ) . '">' . _x( 'Edit', 'media item' ) . '</a>';78 } else {79 echo '<span class="edit-attachment">' . _x( 'Success', 'media item' ) . '</span>';80 }81 ?>82 82 </div> 83 83 </div> -
trunk/src/wp-admin/css/media.css
r58214 r58279 113 113 } 114 114 115 .media-item-wrapper {116 display: grid;117 grid-template-columns: 1fr 1fr;118 }119 120 115 .media-item .attachment-tools { 121 116 display: flex; 122 justify-content: flex-end;123 117 align-items: center; 124 118 } … … 191 185 } 192 186 193 .media-item .original {194 position: relative;195 min-height: 34px;196 }197 198 187 .media-item .progress { 199 float: right;188 display: inline-block; 200 189 height: 22px; 201 margin: 7px 6px;190 margin: 0 6px 7px; 202 191 width: 200px; 203 192 line-height: 2em; … … 1437 1426 } 1438 1427 } 1428 1429 @media only screen and (max-width: 375px) { 1430 .media-item .attachment-tools { 1431 align-items: baseline; 1432 } 1433 .media-item .edit-attachment.copy-to-clipboard-container { 1434 flex-direction: column; 1435 } 1436 1437 .copy-to-clipboard-container .success { 1438 line-height: normal; 1439 margin-top: 10px; 1440 } 1441 }
Note: See TracChangeset
for help on using the changeset viewer.