Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Commit

Permalink
Filterable: When all items match the filter string, show them
Browse files Browse the repository at this point in the history
Fixes gh-7307
  • Loading branch information
Gabriel Schulhof committed Apr 10, 2014
1 parent 0bf1309 commit f2ca4b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion js/widgets/filterable.js
Expand Up @@ -112,7 +112,8 @@ $.widget( "mobile.filterable", {
// If nothing is hidden, then the decision whether to hide or show the items
// is based on the "filterReveal" option.
if ( hide.length === 0 ) {
filterItems[ opts.filterReveal ? "addClass" : "removeClass" ]( "ui-screen-hidden" );
filterItems[ ( opts.filterReveal && val.length === 0 ) ?
"addClass" : "removeClass" ]( "ui-screen-hidden" );
} else {
$( hide ).addClass( "ui-screen-hidden" );
$( show ).removeClass( "ui-screen-hidden" );
Expand Down

0 comments on commit f2ca4b7

Please sign in to comment.