97 lines
5.1 KiB
HTML
97 lines
5.1 KiB
HTML
<div class="content">
|
|
<div class="inner-content">
|
|
<ul>
|
|
<li [ngClass]="{active: selectedAll}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectAll()">
|
|
<i class="fa fa-fw fa-th"></i> {{'allItems' | i18n}}
|
|
</a>
|
|
</li>
|
|
<li [ngClass]="{active: selectedFavorites}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectFavorites()">
|
|
<i class="fa fa-fw fa-star"></i> {{'favorites' | i18n}}
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<h2>{{'types' | i18n}}</h2>
|
|
<ul>
|
|
<li [ngClass]="{active: selectedType === cipherType.Login}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectType(cipherType.Login)">
|
|
<i class="fa fa-fw fa-globe"></i> {{'typeLogin' | i18n}}
|
|
</a>
|
|
</li>
|
|
<li [ngClass]="{active: selectedType === cipherType.Card}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectType(cipherType.Card)">
|
|
<i class="fa fa-fw fa-credit-card"></i> {{'typeCard' | i18n}}
|
|
</a>
|
|
</li>
|
|
<li [ngClass]="{active: selectedType === cipherType.Identity}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectType(cipherType.Identity)">
|
|
<i class="fa fa-fw fa-id-card-o"></i> {{'typeIdentity' | i18n}}
|
|
</a>
|
|
</li>
|
|
<li [ngClass]="{active: selectedType === cipherType.SecureNote}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectType(cipherType.SecureNote)">
|
|
<i class="fa fa-fw fa-sticky-note-o"></i> {{'typeSecureNote' | i18n}}
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<p *ngIf="!loaded" class="text-muted">{{'loading' | i18n}}</p>
|
|
<ng-container *ngIf="loaded">
|
|
<h2>
|
|
{{'folders' | i18n}}
|
|
<button appBlurClick (click)="addFolder()" title="{{'addFolder' | i18n}}">
|
|
<i class="fa fa-plus fa-fw"></i>
|
|
</button>
|
|
</h2>
|
|
<ul class="fa-ul">
|
|
<ng-template #recursiveFolders let-folders>
|
|
<li *ngFor="let f of folders"
|
|
[ngClass]="{active: selectedFolder && f.node.id === selectedFolderId}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectFolder(f.node)">
|
|
<i class="fa-li fa" title="{{'toggleCollapse' | i18n}}"
|
|
[ngClass]="{'fa-caret-right': isCollapsed(f.node),
|
|
'fa-caret-down': !isCollapsed(f.node)}"
|
|
(click)="collapse(f.node)" appStopProp></i>
|
|
{{f.node.name}}
|
|
<span appStopProp appStopClick (click)="editFolder(f.node)" title="{{'editFolder' | i18n}}"
|
|
*ngIf="f.node.id">
|
|
<i class="fa fa-pencil fa-fw"></i>
|
|
</span>
|
|
</a>
|
|
<ul class="fa-ul" *ngIf="f.children.length && !isCollapsed(f.node)">
|
|
<ng-container
|
|
*ngTemplateOutlet="recursiveFolders; context:{ $implicit: f.children }"></ng-container>
|
|
</ul>
|
|
</li>
|
|
</ng-template>
|
|
<ng-container
|
|
*ngTemplateOutlet="recursiveFolders; context:{ $implicit: nestedFolders }"></ng-container>
|
|
</ul>
|
|
<div *ngIf="collections && collections.length">
|
|
<h2>{{'collections' | i18n}}</h2>
|
|
<ul class="fa-ul">
|
|
<ng-template #recursiveCollections let-collections>
|
|
<li *ngFor="let c of collections" [ngClass]="{active: c.node.id === selectedCollectionId}">
|
|
<a href="#" appStopClick appBlurClick (click)="selectCollection(c.node)">
|
|
<i class="fa-li fa" title="{{'toggleCollapse' | i18n}}"
|
|
[ngClass]="{'fa-caret-right': isCollapsed(c.node),
|
|
'fa-caret-down': !isCollapsed(c.node)}"
|
|
(click)="collapse(c.node)" appStopProp></i>
|
|
{{c.node.name}}
|
|
</a>
|
|
<ul class="fa-ul" *ngIf="c.children.length && !isCollapsed(c.node)">
|
|
<ng-container
|
|
*ngTemplateOutlet="recursiveCollections; context:{ $implicit: c.children }">
|
|
</ng-container>
|
|
</ul>
|
|
</li>
|
|
</ng-template>
|
|
<ng-container
|
|
*ngTemplateOutlet="recursiveCollections; context:{ $implicit: nestedCollections }">
|
|
</ng-container>
|
|
</ul>
|
|
</div>
|
|
</ng-container>
|
|
</div>
|
|
</div>
|