Changeset 30374
- Timestamp:
- 11/18/2014 03:33:11 AM (10 years ago)
- Location:
- trunk/src/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/css/media-views.css
r30359 r30374 926 926 927 927 .attachment .close { 928 display: none;928 display: block; 929 929 position: absolute; 930 930 top: 5px; … … 945 945 -webkit-box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.3 ); 946 946 box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.3 ); 947 } 948 949 .attachment .close:hover { 947 transition-duration: none; 948 transition-property: none; 949 } 950 951 .attachment a.close:hover, 952 .attachment a.close:focus { 950 953 -webkit-box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.6 ); 951 954 box-shadow: 0 0 0 1px rgba( 0, 0, 0, 0.6 ); 952 } 953 954 .attachment:hover .close { 955 display: block; 955 background-position: -36px 4px; 956 956 957 } 957 958 -
trunk/src/wp-includes/js/media-views.js
r30245 r30374 3017 3017 // Browse our library of attachments. 3018 3018 this.content.set( view ); 3019 3020 // Trigger the controller to set focus 3021 view.controller.trigger( 'edit:selection', this ); 3019 3022 }, 3020 3023 … … 5097 5100 'click .check': 'checkClickHandler', 5098 5101 'click a': 'preventDefault', 5102 'keydown .close': 'removeFromLibrary', 5099 5103 'keydown': 'toggleSelectionHandler' 5100 5104 }, … … 5538 5542 */ 5539 5543 removeFromLibrary: function( event ) { 5544 // Catch enter and space events 5545 if ( 'keydown' === event.type && 13 !== event.keyCode && 32 !== event.keyCode ) { 5546 return; 5547 } 5548 5540 5549 // Stop propagation so the model isn't selected. 5541 5550 event.stopPropagation(); … … 6237 6246 6238 6247 this.listenTo( this.controller, 'toggle:upload:attachment', _.bind( this.toggleUploader, this ) ); 6239 6248 this.controller.on( 'edit:selection', this.editSelection ); 6240 6249 this.createToolbar(); 6241 6250 if ( this.options.sidebar ) { … … 6256 6265 this.collection.on( 'add remove reset', this.updateContent, this ); 6257 6266 }, 6267 6268 editSelection: function( modal ) { 6269 modal.$el.find( '.media-button-backToLibrary' ).focus(); 6270 }, 6271 6258 6272 /** 6259 6273 * @returns {wp.media.view.AttachmentsBrowser} Returns itself to allow chaining
Note: See TracChangeset
for help on using the changeset viewer.