1
0
mirror of https://github.com/bitwarden/browser synced 2026-01-03 17:13:47 +00:00
Files
browser/apps/web/src/app/billing/trial-initiation/secrets-manager/secrets-manager-trial.component.ts
Conner Turnbull 26a0594056 [PM-17655] Billing Code Ownership Updates (#13105)
* Moved has-premium.guard under billing

* Moved free-trial.ts to billing

* Moved premium directives to billing

* Moved families-policy.service.ts to billing

* Moved trial initiation from auth to billing
2025-01-28 13:17:00 -05:00

33 lines
937 B
TypeScript

// FIXME: Update this file to be type safe and remove this and next line
// @ts-strict-ignore
import { Component, OnDestroy, OnInit } from "@angular/core";
import { ActivatedRoute } from "@angular/router";
import { Subject, takeUntil } from "rxjs";
@Component({
selector: "app-secrets-manager-trial",
templateUrl: "secrets-manager-trial.component.html",
})
export class SecretsManagerTrialComponent implements OnInit, OnDestroy {
organizationTypeQueryParameter: string;
private destroy$ = new Subject<void>();
constructor(private route: ActivatedRoute) {}
ngOnInit(): void {
this.route.queryParams.pipe(takeUntil(this.destroy$)).subscribe((queryParameters) => {
this.organizationTypeQueryParameter = queryParameters.org;
});
}
ngOnDestroy(): void {
this.destroy$.next();
this.destroy$.complete();
}
get freeOrganization() {
return this.organizationTypeQueryParameter === "free";
}
}