Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit c0659cc

Browse files
author
Robert Messerle
committed
fix(autocomplete): changing windows while typing (with no results) no longer breaks scrolling
Closes #3546
1 parent 5edca0e commit c0659cc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/autocomplete/js/autocompleteController.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ function MdAutocompleteCtrl ($scope, $element, $mdUtil, $mdConstant, $timeout, $
434434
* @returns {boolean}
435435
*/
436436
function shouldHide () {
437-
if (!isMinLengthMet()) return true;
437+
if (!isMinLengthMet() || !ctrl.matches.length) return true;
438438
}
439439

440440
/**

0 commit comments

Comments
 (0)