mirror of
https://github.com/bitwarden/browser
synced 2025-12-19 09:43:23 +00:00
* Added billing account profile state service
* Update usages after removing state service functions
* Added migrator
* Updated bw.ts and main.background.ts
* Removed comment
* Updated state service dependencies to include billing service
* Added missing mv3 factory and updated MainContextMenuHandler
* updated autofill service and tests
* Updated the remaining extensions usages
* Updated desktop
* Removed subjects where they weren't needed
* Refactored billing service to have a single setter to avoid unecessary emissions
* Refactored has premium guard to return an observable
* Renamed services to match ADR
f633f2cdd8/docs/architecture/clients/presentation/angular.md (abstract--default-implementations)
* Updated property names to be a smidgen more descriptive and added jsdocs
* Updated setting of canAccessPremium to automatically update when the underlying observable emits
* Fixed build error after merge conflicts
* Another build error from conflict
* Removed autofill unit test changes from conflict
* Updated login strategy to not set premium field using state service
* Updated CLI to use billing state provider
* Shortened names a bit
* Fixed build
59 lines
2.2 KiB
TypeScript
59 lines
2.2 KiB
TypeScript
import { Component } from "@angular/core";
|
|
|
|
import { AttachmentsComponent as BaseAttachmentsComponent } from "@bitwarden/angular/vault/components/attachments.component";
|
|
import { ApiService } from "@bitwarden/common/abstractions/api.service";
|
|
import { BillingAccountProfileStateService } from "@bitwarden/common/billing/abstractions/account/billing-account-profile-state.service";
|
|
import { CryptoService } from "@bitwarden/common/platform/abstractions/crypto.service";
|
|
import { FileDownloadService } from "@bitwarden/common/platform/abstractions/file-download/file-download.service";
|
|
import { I18nService } from "@bitwarden/common/platform/abstractions/i18n.service";
|
|
import { LogService } from "@bitwarden/common/platform/abstractions/log.service";
|
|
import { PlatformUtilsService } from "@bitwarden/common/platform/abstractions/platform-utils.service";
|
|
import { StateService } from "@bitwarden/common/platform/abstractions/state.service";
|
|
import { CipherService } from "@bitwarden/common/vault/abstractions/cipher.service";
|
|
import { AttachmentView } from "@bitwarden/common/vault/models/view/attachment.view";
|
|
import { DialogService } from "@bitwarden/components";
|
|
|
|
@Component({
|
|
selector: "emergency-access-attachments",
|
|
templateUrl: "../../../../vault/individual-vault/attachments.component.html",
|
|
})
|
|
export class EmergencyAccessAttachmentsComponent extends BaseAttachmentsComponent {
|
|
viewOnly = true;
|
|
canAccessAttachments = true;
|
|
|
|
constructor(
|
|
cipherService: CipherService,
|
|
i18nService: I18nService,
|
|
cryptoService: CryptoService,
|
|
stateService: StateService,
|
|
platformUtilsService: PlatformUtilsService,
|
|
apiService: ApiService,
|
|
logService: LogService,
|
|
fileDownloadService: FileDownloadService,
|
|
dialogService: DialogService,
|
|
billingAccountProfileStateService: BillingAccountProfileStateService,
|
|
) {
|
|
super(
|
|
cipherService,
|
|
i18nService,
|
|
cryptoService,
|
|
platformUtilsService,
|
|
apiService,
|
|
window,
|
|
logService,
|
|
stateService,
|
|
fileDownloadService,
|
|
dialogService,
|
|
billingAccountProfileStateService,
|
|
);
|
|
}
|
|
|
|
protected async init() {
|
|
// Do nothing since cipher is already decoded
|
|
}
|
|
|
|
protected showFixOldAttachments(attachment: AttachmentView) {
|
|
return false;
|
|
}
|
|
}
|