Ticket #43382: 43382.diff
File 43382.diff, 2.2 KB (added by , 7 years ago) |
---|
-
src/wp-admin/includes/class-wp-terms-list-table.php
455 455 __( 'Edit' ) 456 456 ); 457 457 $actions['inline hide-if-no-js'] = sprintf( 458 '< a href="#" class="editinline aria-button-if-js" aria-label="%s">%s</a>',458 '<button type="button" class="button-link editinline" aria-label="%s" aria-expanded="false">%s</button>', 459 459 /* translators: %s: taxonomy term name */ 460 460 esc_attr( sprintf( __( 'Quick edit “%s” inline' ), $tag->name ) ), 461 461 __( 'Quick Edit' ) -
src/wp-admin/js/inline-edit-tax.js
36 36 t.type = $('#the-list').attr('data-wp-lists').substr(5); 37 37 t.what = '#'+t.type+'-'; 38 38 39 $( '#the-list').on('click', 'a.editinline', function(){40 inlineEditTax.edit(this);41 return false;39 $( '#the-list' ).on( 'click', '.editinline', function() { 40 $( this ).attr( 'aria-expanded', 'true' ); 41 inlineEditTax.edit( this ); 42 42 }); 43 43 44 44 /** … … 219 219 $( '#parent' ).find( 'option[value=' + option_value + ']' ).text( row.find( '.row-title' ).text() ); 220 220 221 221 row.hide().fadeIn( 400, function() { 222 // Move focus back to the Quick Edit link. 223 row.find( '.editinline' ).focus(); 222 // Move focus back to the Quick Edit button. 223 row.find( '.editinline' ) 224 .attr( 'aria-expanded', 'false' ) 225 .focus(); 224 226 wp.a11y.speak( inlineEditL10n.saved ); 225 227 }); 226 228 … … 262 264 $('#'+id).siblings('tr.hidden').addBack().remove(); 263 265 id = id.substr( id.lastIndexOf('-') + 1 ); 264 266 265 // Show the taxonomy row and move focus back to the Quick Edit link. 266 $( this.what + id ).show().find( '.editinline' ).focus(); 267 // Show the taxonomy row and move focus back to the Quick Edit button. 268 $( this.what + id ).show().find( '.editinline' ) 269 .attr( 'aria-expanded', 'false' ) 270 .focus(); 267 271 } 268 272 }, 269 273