[Search] Search icon
Search icon now is not visible when text is entered in the search bar, even when the bar is not in focus.
This commit is contained in:
@@ -30,7 +30,8 @@
|
||||
ng-model="ngModel.input"
|
||||
ng-keyup="controller.search()"
|
||||
id="searchInput" />
|
||||
<div class="ui-symbol search-icon">
|
||||
<div class="ui-symbol search-icon"
|
||||
ng-class="{content: controller.hasInput()}">
|
||||
M
|
||||
</div>
|
||||
<!--mct-control key="textfield"
|
||||
|
||||
@@ -110,6 +110,14 @@ define(function () {
|
||||
} else {
|
||||
$scope.results = fullResults.hits.slice(0, numResults);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Determines if the search bar has any text inputted into it.
|
||||
* Used as a helper for CSS styling.
|
||||
*/
|
||||
hasInput: function () {
|
||||
return !($scope.ngModel.input === "" || $scope.ngModel.input === undefined);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user