1
0
mirror of https://github.com/sismics/docs.git synced 2025-12-13 09:46:17 +00:00

clickable labels

This commit is contained in:
Benjamin Gamard
2018-03-12 11:43:11 +01:00
parent 647ad841df
commit 9d8034e010
6 changed files with 7 additions and 46 deletions

View File

@@ -13,6 +13,7 @@ angular.module('docs').controller('Document', function ($scope, $rootScope, $tim
$scope.currentPage = 1;
$scope.limit = _.isUndefined(localStorage.documentsPageSize) ? '10' : localStorage.documentsPageSize;
$scope.search = $state.params.search ? $state.params.search : '';
$scope.setSearch = function (search) { $scope.search = search };
$scope.searchOpened = false;
$scope.searchDropdownAnchor = angular.element(document.querySelector('.search-dropdown-anchor'));
$scope.paginationShown = true;

View File

@@ -63,7 +63,7 @@
<ul class="list-inline">
<li ng-repeat="tag in document.tags">
<span class="label label-info" ng-style="{ 'background': tag.color }">{{ tag.name }}</span>
<span class="label label-info pointer" ng-click="setSearch('tag:' + tag.name)" ng-style="{ 'background': tag.color }">{{ tag.name }}</span>
</li>
</ul>
</div>