mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 16:23:44 +00:00
Add sponsorship pre validate to families redeem page (#1315)
* Add sponsorship pre validate to families redeem page * Update messaging * update jslib
This commit is contained in:
2
jslib
2
jslib
Submodule jslib updated: b4f475251a...d02fcd082e
@@ -6,7 +6,10 @@
|
|||||||
<i class="fa fa-spinner fa-spin fa-2x text-muted" title="{{'loading' | i18n}}" aria-hidden="true"></i>
|
<i class="fa fa-spinner fa-spin fa-2x text-muted" title="{{'loading' | i18n}}" aria-hidden="true"></i>
|
||||||
<span class="sr-only">{{'loading' | i18n}}</span>
|
<span class="sr-only">{{'loading' | i18n}}</span>
|
||||||
</div>
|
</div>
|
||||||
<form #form (ngSubmit)="submit()" [appApiAction]="formPromise" ngNativeValidate *ngIf="!loading">
|
<div *ngIf="!loading && badToken" class="mt-5 d-flex justify-content-center">
|
||||||
|
<span>{{'badToken' | i18n}}</span>
|
||||||
|
</div>
|
||||||
|
<form #form (ngSubmit)="submit()" [appApiAction]="formPromise" ngNativeValidate *ngIf="!loading && !badToken">
|
||||||
<p>
|
<p>
|
||||||
<span>{{'acceptBitwardenFamiliesHelp' | i18n}}</span>
|
<span>{{'acceptBitwardenFamiliesHelp' | i18n}}</span>
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ export class FamiliesForEnterpriseSetupComponent implements OnInit {
|
|||||||
@ViewChild('deleteOrganizationTemplate', { read: ViewContainerRef, static: true }) deleteModalRef: ViewContainerRef;
|
@ViewChild('deleteOrganizationTemplate', { read: ViewContainerRef, static: true }) deleteModalRef: ViewContainerRef;
|
||||||
|
|
||||||
loading = true;
|
loading = true;
|
||||||
|
badToken = false;
|
||||||
formPromise: Promise<any>;
|
formPromise: Promise<any>;
|
||||||
|
|
||||||
token: string;
|
token: string;
|
||||||
@@ -89,6 +90,7 @@ export class FamiliesForEnterpriseSetupComponent implements OnInit {
|
|||||||
this.token = qParams.token;
|
this.token = qParams.token;
|
||||||
|
|
||||||
await this.syncService.fullSync(true);
|
await this.syncService.fullSync(true);
|
||||||
|
this.badToken = !await this.apiService.postPreValidateSponsorshipToken(this.token);
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
|
||||||
this.existingFamilyOrganizations = (await this.userService.getAllOrganizations())
|
this.existingFamilyOrganizations = (await this.userService.getAllOrganizations())
|
||||||
|
|||||||
@@ -4506,6 +4506,9 @@
|
|||||||
"sponsoredFamiliesSharedCollections": {
|
"sponsoredFamiliesSharedCollections": {
|
||||||
"message": "Shared collections for Family secrets"
|
"message": "Shared collections for Family secrets"
|
||||||
},
|
},
|
||||||
|
"badToken": {
|
||||||
|
"message": "The link is no longer valid. Please have the sponsor resend the offer."
|
||||||
|
},
|
||||||
"reclaimedFreePlan": {
|
"reclaimedFreePlan": {
|
||||||
"message": "Reclaimed free plan"
|
"message": "Reclaimed free plan"
|
||||||
},
|
},
|
||||||
@@ -4540,7 +4543,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"sponsoredFamiliesOffer": {
|
"sponsoredFamiliesOffer": {
|
||||||
"message": "Redeem Free Bitwarden Families Organization Offer"
|
"message": "Accept Free Bitwarden Families"
|
||||||
},
|
},
|
||||||
"sponsoredFamiliesOfferRedeemed": {
|
"sponsoredFamiliesOfferRedeemed": {
|
||||||
"message": "Free Bitwarden Families offer successfully redeemed"
|
"message": "Free Bitwarden Families offer successfully redeemed"
|
||||||
@@ -4702,7 +4705,7 @@
|
|||||||
"message": "Please provide a payment method to associate with the organization. Don't worry, we won't charge you anything unless you select additional features or your sponsorship expires. "
|
"message": "Please provide a payment method to associate with the organization. Don't worry, we won't charge you anything unless you select additional features or your sponsorship expires. "
|
||||||
},
|
},
|
||||||
"orgCreatedSponsorshipInvalid": {
|
"orgCreatedSponsorshipInvalid": {
|
||||||
"message": "The sponsorship offer has expired you may delete the organization you created to avoid a charge at the end of your 7 day trial. Otherwise you may close this prompt to keep the organization and assume billing responsibility."
|
"message": "The sponsorship offer has expired. You may delete the organization you created to avoid a charge at the end of your 7 day trial. Otherwise you may close this prompt to keep the organization and assume billing responsibility."
|
||||||
},
|
},
|
||||||
"newFamiliesOrganization": {
|
"newFamiliesOrganization": {
|
||||||
"message": "New Families Organization"
|
"message": "New Families Organization"
|
||||||
|
|||||||
Reference in New Issue
Block a user