46 lines
No EOL
1.9 KiB
HTML
46 lines
No EOL
1.9 KiB
HTML
<main>
|
|
<article>
|
|
|
|
<section class="search">
|
|
<input type="search" spellcheck="false" placeholder="Create or find a user" ng-model="search_text" ng-keypress="add($event, search_text)" />
|
|
</section>
|
|
|
|
<div class="blankslate" ng-show="users.length === 1 && !search_text && !waiting">
|
|
<i class="material-icons">control_point_duplicate</i>
|
|
<span>Get started by adding your team members.<br/>Just type the user login (ie octocat) in the text box above.</span>
|
|
</div>
|
|
|
|
<div class="alert alert-create-not-found" ng-show="!!search_text">
|
|
<i class="material-icons" ng-show="!waiting">control_point_duplicate</i>
|
|
<i class="material-icons waiting" ng-show="!!waiting">sync</i>
|
|
<span>Press <enter> to add <em>{{search_text}}</em></span>
|
|
</div>
|
|
|
|
<div class="alert alert-success" ng-show="new_user">
|
|
<span>Successfully added user account <em>{{new_user.login}}</em>.</span>
|
|
</div>
|
|
|
|
<div class="alert alert-error" ng-show="!!error">
|
|
<i class="material-icons">error_outline</i>
|
|
<span>There was an error adding the user account.</span>
|
|
</div>
|
|
|
|
<ul class="list cozy user-list">
|
|
<li class="row row-user" ng-repeat="user in users | orderBy:'login' | filter: search_text">
|
|
<div class="column-avatar">
|
|
<img ng-src="{{ user.avatar || 'https://www.gravatar.com/avatar/00000000000000000000000000000000?d=mm&f=y' }}" />
|
|
</div>
|
|
<div class="column-fill">
|
|
<h2>{{ user.login }} <small ng-if="user.admin" class="label label-success">Admin</small></h2>
|
|
|
|
<menu>
|
|
<button ng-click="toggle(user)" ng-if="!user.admin" class="button success">Grant Admin</button>
|
|
<button ng-click="toggle(user)" ng-if="user.admin" class="button danger">Revoke Admin</button>
|
|
<button ng-click="remove(user)" class="button danger">Delete</button>
|
|
</menu>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
|
|
</article>
|
|
</main> |