diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/js/_enqueues/wp/theme.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/js/_enqueues/wp/theme.js b/src/js/_enqueues/wp/theme.js index 65b5b4cf1c..7e1d2550cd 100644 --- a/src/js/_enqueues/wp/theme.js +++ b/src/js/_enqueues/wp/theme.js @@ -96,7 +96,7 @@ themes.view.Appearance = wp.Backbone.View.extend({ }, // Defines search element container. - searchContainer: $( '.search-form .search-box' ), + searchContainer: $( '.search-form' ), // Search input and view // for current theme collection. @@ -118,11 +118,13 @@ themes.view.Appearance = wp.Backbone.View.extend({ // Render and append after screen title. view.render(); this.searchContainer + .find( '.search-box' ) .append( $.parseHTML( '<label for="wp-filter-search-input">' + l10n.search + '</label>' ) ) - .append( view.el ) - .on( 'submit', function( event ) { - event.preventDefault(); - }); + .append( view.el ); + + this.searchContainer.on( 'submit', function( event ) { + event.preventDefault(); + }); }, // Checks when the user gets close to the bottom |