Abstract out the display of entities (users, robot accounts, and teams) into a nice directive to ensure that we always display the correctly formatted entity information (icon and name)
This commit is contained in:
parent
72acc8769b
commit
d5c0f768c2
8 changed files with 63 additions and 35 deletions
7
static/directives/entity-reference.html
Normal file
7
static/directives/entity-reference.html
Normal file
|
@ -0,0 +1,7 @@
|
|||
<span class="entity-reference-element">
|
||||
<i class="fa fa-user" ng-show="!team && !isrobot" title="User" bs-tooltip="tooltip.title" data-container="body"></i>
|
||||
<i class="fa fa-wrench" ng-show="!team && isrobot" title="Robot Account" bs-tooltip="tooltip.title" data-container="body"></i>
|
||||
<i class="fa fa-group" ng-show="team" title="Team" bs-tooltip="tooltip.title" data-container="body"></i>
|
||||
<span ng-show="team"><a href="/organization/{{ orgname }}/teams/{{ team }}">{{team}}</a></span>
|
||||
<span ng-show="isrobot" class="prefix">{{getPrefix(name)}}</span><span>{{getShortenedName(name)}}</span>
|
||||
</span>
|
Reference in a new issue