<div>
  <ul class="unstyled label-list">
    <li ng-repeat="tag in visibleTags | orderBy:'tag.id || tag'"
        class="mouse-pointer"
        ng-click="toggleSelectionFromGroup(selected, tag.id || tag)">
              <span class="badge"
                    ng-class="isInGroup(selected, tag.id || tag, 'badge-success', '')"
                      >{{tag.id || tag}}</span>
              <span class="pull-right"
                    ng-show="tag.count">{{tag.count}}&nbsp;</span>
    </li>
  </ul>
  <div class="mouse-pointer"
       ng-show="selected.length"
       ng-click="clearGroup(selected)">
    <i class="icon-remove" ></i> Clear Tags
  </div>
</div>
