mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Customizer: Show all widgets when the search field is cleared.
When clicking the clear button on the widget search field, the search results should refresh to show all widgets. Props Mahesh901122. Fixes #47534. git-svn-id: https://develop.svn.wordpress.org/trunk@45658 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -191,9 +191,10 @@
|
||||
}
|
||||
} );
|
||||
|
||||
// Clear the search results and trigger a `keyup` event to fire a new search.
|
||||
// Clear the search results and trigger a new search.
|
||||
this.$clearResults.on( 'click', function() {
|
||||
self.$search.val( '' ).focus().trigger( 'keyup' );
|
||||
self.$search.val( '' ).focus();
|
||||
self.collection.doSearch( '' );
|
||||
} );
|
||||
|
||||
// Close the panel if the URL in the preview changes
|
||||
|
||||
Reference in New Issue
Block a user