We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4dcc14c commit eeb7d1aCopy full SHA for eeb7d1a
src/js/_enqueues/admin/tags.js
@@ -49,6 +49,16 @@ jQuery( function($) {
49
var message;
50
if ( '1' == r ) {
51
$('#ajax-response').empty();
52
+ let nextFocus = tr.next( 'tr' ).find( 'a.row-title' );
53
+ let prevFocus = tr.prev( 'tr' ).find( 'a.row-title' );
54
+ // If there is neither a next row or a previous row, focus the tag input field.
55
+ if ( nextFocus.length < 1 && prevFocus.length < 1 ) {
56
+ nextFocus = $( '#tag-name' ).trigger( 'focus' );
57
+ } else {
58
+ if ( nextFocus.length < 1 ) {
59
+ nextFocus = prevFocus;
60
+ }
61
62
tr.fadeOut('normal', function() {
63
tr.remove();
64
0 commit comments