mirror of
https://github.com/bitwarden/browser
synced 2025-12-06 00:13:28 +00:00
* add premium badge to web filter when the user does not have access to premium * remove feature flag pass through in favor of showing/hiding archive vault observable * refactor archive observable to be more generic * add archive premium badge for the web * show premium badge inline for archive filter * show premium subscription ended message when user has archived ciphers * fix missing refactor * remove unneeded can archive check * reference observable directly * reduce the number of firstValueFroms by combining observables into a single stream * fix failing tests * add import to storybook * update variable naming for premium filters * pass event to `promptForPremium` * remove check for organization * fix footer variable reference * refactor back to `hasArchiveFlagEnabled$` - more straight forward to the underlying logic * update archive service test with new feature flag format
105 lines
3.4 KiB
HTML
105 lines
3.4 KiB
HTML
<app-vault-banners [organizations]="organizations$ | async"></app-vault-banners>
|
|
|
|
<app-vault-header
|
|
[filter]="filter"
|
|
[loading]="refreshing && !performingInitialLoad"
|
|
[organizations]="allOrganizations"
|
|
[canCreateCollections]="canCreateCollections"
|
|
[collection]="selectedCollection"
|
|
(onAddCipher)="addCipher($event)"
|
|
(onAddCollection)="addCollection()"
|
|
(onAddFolder)="addFolder()"
|
|
(onEditCollection)="editCollection(selectedCollection.node, $event.tab)"
|
|
(onDeleteCollection)="deleteCollection(selectedCollection.node)"
|
|
></app-vault-header>
|
|
|
|
<app-vault-onboarding
|
|
[ciphers]="ciphers"
|
|
[orgs]="allOrganizations"
|
|
(onAddCipher)="addCipher($event)"
|
|
>
|
|
</app-vault-onboarding>
|
|
|
|
<div class="tw-flex tw-flex-row -tw-mx-2.5">
|
|
<div class="tw-basis-1/4 tw-max-w-1/4 tw-px-2.5">
|
|
<app-vault-filter
|
|
#vaultFilter
|
|
[activeFilter]="activeFilter"
|
|
[searchText]="currentSearchText$ | async"
|
|
(searchTextChanged)="filterSearchText($event)"
|
|
(onEditFolder)="editFolder($event)"
|
|
></app-vault-filter>
|
|
</div>
|
|
<div class="tw-basis-3/4 tw-max-w-3/4 tw-px-2.5">
|
|
<bit-callout type="warning" *ngIf="activeFilter.isDeleted">
|
|
{{ trashCleanupWarning }}
|
|
</bit-callout>
|
|
<bit-callout
|
|
type="info"
|
|
[title]="'premiumSubscriptionEnded' | i18n"
|
|
*ngIf="showSubscriptionEndedMessaging$ | async"
|
|
>
|
|
<p>{{ "premiumSubscriptionEndedDesc" | i18n }}</p>
|
|
<a routerLink="/settings/subscription/premium" bitButton buttonType="primary">{{
|
|
"restartPremium" | i18n
|
|
}}</a>
|
|
</bit-callout>
|
|
<app-vault-items
|
|
#vaultItems
|
|
[ciphers]="ciphers"
|
|
[collections]="collections"
|
|
[allCollections]="allCollections"
|
|
[allOrganizations]="allOrganizations"
|
|
[disabled]="refreshing"
|
|
[showOwner]="true"
|
|
[showCollections]="false"
|
|
[showGroups]="false"
|
|
[showPremiumFeatures]="canAccessPremium"
|
|
[showBulkMove]="showBulkMove"
|
|
[showBulkTrashOptions]="filter.type === 'trash'"
|
|
[useEvents]="false"
|
|
[showAdminActions]="false"
|
|
[showBulkAddToCollections]="true"
|
|
[userCanArchive]="userCanArchive$ | async"
|
|
[enforceOrgDataOwnershipPolicy]="enforceOrgDataOwnershipPolicy$ | async"
|
|
(onEvent)="onVaultItemsEvent($event)"
|
|
>
|
|
</app-vault-items>
|
|
<div
|
|
*ngIf="performingInitialLoad"
|
|
class="tw-mt-6 tw-flex tw-h-full tw-flex-col tw-items-center tw-justify-start"
|
|
>
|
|
<i
|
|
class="bwi bwi-spinner bwi-spin tw-text-muted"
|
|
title="{{ 'loading' | i18n }}"
|
|
aria-hidden="true"
|
|
></i>
|
|
<span class="tw-sr-only">{{ "loading" | i18n }}</span>
|
|
</div>
|
|
<div
|
|
class="tw-mt-6 tw-flex tw-h-full tw-flex-col tw-items-center tw-justify-start"
|
|
*ngIf="isEmpty && !performingInitialLoad"
|
|
>
|
|
<bit-no-items [icon]="(emptyState$ | async)?.icon">
|
|
<div slot="title">
|
|
{{ (emptyState$ | async)?.title | i18n }}
|
|
</div>
|
|
<p slot="description" bitTypography="body2" class="tw-max-w-md tw-text-center">
|
|
{{ (emptyState$ | async)?.description | i18n }}
|
|
</p>
|
|
<button
|
|
type="button"
|
|
buttonType="primary"
|
|
bitButton
|
|
(click)="addCipher()"
|
|
slot="button"
|
|
*ngIf="showAddCipherBtn"
|
|
>
|
|
<i class="bwi bwi-plus bwi-fw" aria-hidden="true"></i>
|
|
{{ "newItem" | i18n }}
|
|
</button>
|
|
</bit-no-items>
|
|
</div>
|
|
</div>
|
|
</div>
|