mirror of
https://github.com/sismics/docs.git
synced 2025-12-22 14:11:39 +00:00
#241: search suggestions
This commit is contained in:
@@ -38,6 +38,7 @@ angular.module('docs').controller('Document', function ($scope, $rootScope, $tim
|
||||
.then(function (data) {
|
||||
$scope.documents = data.documents;
|
||||
$scope.totalDocuments = data.total;
|
||||
$scope.suggestions = data.suggestions;
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
@@ -19,7 +19,10 @@
|
||||
<!-- Search (simple and advanced) -->
|
||||
<div class="row search-dropdown-anchor">
|
||||
<div class="col-xs-12 input-group">
|
||||
<input type="search" class="form-control" ng-attr-placeholder="{{ 'document.search' | translate }}" ng-model="search" />
|
||||
<input type="search" class="form-control"
|
||||
uib-typeahead="suggestion for suggestion in suggestions"
|
||||
typeahead-focus-first="false"
|
||||
ng-attr-placeholder="{{ 'document.search' | translate }}" ng-model="search" />
|
||||
<span class="input-group-addon btn" ng-click="openSearch()">
|
||||
<div uib-dropdown
|
||||
auto-close="disabled" is-open="searchOpened" dropdown-append-to="searchDropdownAnchor">
|
||||
|
||||
Reference in New Issue
Block a user