bitwarden-estensione-browser/src/popup2/vault/groupings.component.html

141 lines
6.9 KiB
HTML
Raw Normal View History

2018-04-05 16:29:11 +02:00
<header>
<div class="left">
<app-pop-out></app-pop-out>
2018-04-05 16:29:11 +02:00
</div>
2018-04-09 16:50:28 +02:00
<div class="search">
<input type="search" placeholder="{{'searchVault' | i18n}}" id="search"
[(ngModel)]="searchText" appAutofocus>
<i class="fa fa-search"></i>
2018-04-05 16:29:11 +02:00
</div>
<div class="right">
2018-04-05 23:27:31 +02:00
<button appBlurClick (click)="addCipher()" title="{{'addItem' | i18n}}">
<i class="fa fa-plus fa-lg"></i>
</button>
2018-04-05 16:29:11 +02:00
</div>
</header>
<content>
2018-04-09 16:50:28 +02:00
<div class="no-items" *ngIf="!ciphers || !ciphers.length">
<i class="fa fa-spinner fa-spin fa-3x" *ngIf="!loaded"></i>
<ng-container *ngIf="loaded">
<i class="fa fa-frown-o fa-4x"></i>
<p>{{'noItemsInList' | i18n}}</p>
<button (click)="addCipher()" class="btn block primary link">{{'addItem' | i18n}}</button>
</ng-container>
</div>
<ng-container *ngIf="ciphers && ciphers.length && (!searchText || searchText.length < 2)">
2018-04-05 23:27:31 +02:00
<div class="box list" *ngIf="favoriteCiphers">
2018-04-05 16:29:11 +02:00
<div class="box-header">
2018-04-05 23:27:31 +02:00
{{'favorites' | i18n}}
<span class="flex-right">{{favoriteCiphers.length}}</span>
2018-04-05 16:29:11 +02:00
</div>
<div class="box-content">
2018-04-06 05:49:04 +02:00
<app-ciphers-list [ciphers]="favoriteCiphers" title="{{'viewItem' | i18n}}"
(onSelected)="selectCipher($event)"></app-ciphers-list>
2018-04-05 23:27:31 +02:00
</div>
</div>
<div class="box list">
<div class="box-header">
{{'types' | i18n}}
<span class="flex-right">4</span>
</div>
<div class="box-content single-line">
2018-04-10 04:25:03 +02:00
<a href="#" class="box-content-row" appStopClick appBlurClick
(click)="selectType(cipherType.Login)">
<div class="row-main">
<div class="icon"><i class="fa fa-fw fa-lg fa-globe"></i></div>
<span class="text">{{'typeLogin' | i18n}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{typeCounts.get(cipherType.Login) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 23:27:31 +02:00
</a>
2018-04-10 04:25:03 +02:00
<a href="#" class="box-content-row" appStopClick appBlurClick
(click)="selectType(cipherType.Card)">
<div class="row-main">
<div class="icon"><i class="fa fa-fw fa-lg fa-credit-card"></i></div>
<span class="text">{{'typeCard' | i18n}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{typeCounts.get(cipherType.Card) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 23:27:31 +02:00
</a>
2018-04-10 04:25:03 +02:00
<a href="#" class="box-content-row" appStopClick appBlurClick
(click)="selectType(cipherType.Identity)">
<div class="row-main">
<div class="icon"><i class="fa fa-fw fa-lg fa-id-card-o"></i></div>
<span class="text">{{'typeIdentity' | i18n}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{typeCounts.get(cipherType.Identity) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 23:27:31 +02:00
</a>
2018-04-10 04:25:03 +02:00
<a href="#" class="box-content-row" appStopClick appBlurClick
(click)="selectType(cipherType.SecureNote)">
<div class="row-main">
<div class="icon"><i class="fa fa-fw fa-lg fa-sticky-note-o"></i></div>
<span class="text">{{'typeSecureNote' | i18n}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{typeCounts.get(cipherType.SecureNote) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 23:27:31 +02:00
</a>
</div>
</div>
<div class="box list">
<div class="box-header">
{{'folders' | i18n}}
<span class="flex-right">{{folderCount}}</span>
</div>
<div class="box-content single-line">
2018-04-10 04:25:03 +02:00
<a *ngFor="let f of folders" href="#" class="box-content-row"
appStopClick appBlurClick (click)="selectFolder(f)">
<div class="row-main">
<div class="icon">
<i class="fa fa-fw fa-lg"
[ngClass]="{'fa-folder-open': f.id, 'fa-folder-open-o': !f.id}"></i>
</div>
<span class="text">{{f.name}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{folderCounts.get(f.id) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 16:29:11 +02:00
</a>
</div>
</div>
2018-04-05 23:27:31 +02:00
<div class="box list">
2018-04-05 16:29:11 +02:00
<div class="box-header">
{{'collections' | i18n}}
2018-04-05 23:27:31 +02:00
<span class="flex-right">{{collections.length}}</span>
2018-04-05 16:29:11 +02:00
</div>
2018-04-05 23:27:31 +02:00
<div class="box-content single-line">
2018-04-10 04:25:03 +02:00
<a *ngFor="let c of collections" href="#" class="box-content-row"
appStopClick appBlurClick (click)="selectCollection(c)">
<div class="row-main">
<div class="icon"><i class="fa fa-fw fa-lg fa-cube"></i></div>
<span class="text">{{c.name}}</span>
2018-04-05 23:27:31 +02:00
</div>
2018-04-10 04:25:03 +02:00
<span class="row-sub-label">{{collectionCounts.get(c.id) || 0}}</span>
<span><i class="fa fa-chevron-right fa-lg row-sub-icon"></i></span>
2018-04-05 16:29:11 +02:00
</a>
</div>
</div>
2018-04-05 23:27:31 +02:00
<div class="box list" *ngIf="showNoFolderCiphers">
<div class="box-header">
{{'noneFolder' | i18n}}
<div class="flex-right">{{noFolderCiphers.length}}</div>
</div>
<div class="box-content">
2018-04-06 05:49:04 +02:00
<app-ciphers-list [ciphers]="noFolderCiphers" title="{{'viewItem' | i18n}}"
(onSelected)="selectCipher($event)"></app-ciphers-list>
2018-04-05 23:27:31 +02:00
</div>
</div>
2018-04-05 16:29:11 +02:00
</ng-container>
2018-04-09 16:50:28 +02:00
<ng-container *ngIf="ciphers && ciphers.length && searchText && searchText.length > 1 &&
(ciphers | searchCiphers: searchText) as searchedCiphers">
<div class="no-items" *ngIf="!searchedCiphers.length">
<p>{{'noItemsInList' | i18n}}</p>
</div>
2018-04-09 23:35:16 +02:00
<div class="box list full-list" *ngIf="searchedCiphers.length > 0">
2018-04-09 16:50:28 +02:00
<div class="box-content">
<app-ciphers-list [ciphers]="searchedCiphers" title="{{'viewItem' | i18n}}"
(onSelected)="selectCipher($event)"></app-ciphers-list>
</div>
</div>
</ng-container>
2018-04-05 16:29:11 +02:00
</content>