1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-16 08:13:42 +00:00

[PM-7901] added new card view (#10321)

* added new card view
This commit is contained in:
Jason Ng
2024-07-30 15:54:45 -04:00
committed by GitHub
parent cbac5fde11
commit 80af356fd1
6 changed files with 186 additions and 62 deletions

View File

@@ -19,6 +19,7 @@ import { PopupPageComponent } from "../../../../apps/browser/src/platform/popup/
import { AdditionalOptionsComponent } from "./additional-options/additional-options.component";
import { AttachmentsV2ViewComponent } from "./attachments/attachments-v2-view.component";
import { CardDetailsComponent } from "./card-details/card-details-view.component";
import { CustomFieldV2Component } from "./custom-fields/custom-fields-v2.component";
import { ItemDetailsV2Component } from "./item-details/item-details-v2.component";
import { ItemHistoryV2Component } from "./item-history/item-history-v2.component";
@@ -40,6 +41,7 @@ import { ViewIdentitySectionsComponent } from "./view-identity-sections/view-ide
AttachmentsV2ViewComponent,
ItemHistoryV2Component,
CustomFieldV2Component,
CardDetailsComponent,
ViewIdentitySectionsComponent,
],
})
@@ -64,6 +66,11 @@ export class CipherViewComponent implements OnInit {
this.destroyed$.complete();
}
get hasCard() {
const { cardholderName, code, expMonth, expYear, brand, number } = this.cipher.card;
return cardholderName || code || expMonth || expYear || brand || number;
}
async loadCipherData() {
if (this.cipher.collectionIds.length > 0) {
this.collections$ = this.collectionService