mirror of
https://github.com/bitwarden/browser
synced 2025-12-22 03:03:43 +00:00
[deps] Autofill: Update prettier to v3 (#7014)
* [deps] Autofill: Update prettier to v3 * prettier formatting updates --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Jonathan Prusik <jprusik@classynemesis.com>
This commit is contained in:
@@ -4,5 +4,8 @@ export class AdminAuthRequestUpdateRequest {
|
||||
* @param requestApproved - Whether the request was approved/denied. If true, the key must be provided.
|
||||
* @param encryptedUserKey The user key that has been encrypted with a device public key if the request was approved.
|
||||
*/
|
||||
constructor(public requestApproved: boolean, public encryptedUserKey?: string) {}
|
||||
constructor(
|
||||
public requestApproved: boolean,
|
||||
public encryptedUserKey?: string,
|
||||
) {}
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ export class OrganizationAuthRequestService {
|
||||
`/organizations/${organizationId}/auth-requests`,
|
||||
null,
|
||||
true,
|
||||
true
|
||||
true,
|
||||
);
|
||||
|
||||
const listResponse = new ListResponse(r, PendingOrganizationAuthRequestResponse);
|
||||
@@ -34,21 +34,21 @@ export class OrganizationAuthRequestService {
|
||||
`/organizations/${organizationId}/auth-requests/deny`,
|
||||
new BulkDenyAuthRequestsRequest(requestIds),
|
||||
true,
|
||||
false
|
||||
false,
|
||||
);
|
||||
}
|
||||
|
||||
async approvePendingRequest(
|
||||
organizationId: string,
|
||||
requestId: string,
|
||||
encryptedKey: EncString
|
||||
encryptedKey: EncString,
|
||||
): Promise<void> {
|
||||
await this.apiService.send(
|
||||
"POST",
|
||||
`/organizations/${organizationId}/auth-requests/${requestId}`,
|
||||
new AdminAuthRequestUpdateRequest(true, encryptedKey.encryptedString),
|
||||
true,
|
||||
false
|
||||
false,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,14 +46,14 @@
|
||||
<tr bitRow alignContent="top" *ngFor="let r of rows$ | async">
|
||||
<td bitCell class="tw-flex-col">
|
||||
<div>{{ r.email }}</div>
|
||||
<code class="tw-text-sm">{{ r.publicKey | fingerprint : r.email | async }}</code>
|
||||
<code class="tw-text-sm">{{ r.publicKey | fingerprint: r.email | async }}</code>
|
||||
</td>
|
||||
<td bitCell class="tw-flex-col">
|
||||
<div>{{ r.requestDeviceType }}</div>
|
||||
<div class="tw-text-sm">{{ r.requestIpAddress }}</div>
|
||||
</td>
|
||||
<td bitCell class="tw-flex-col tw-text-muted">
|
||||
{{ r.creationDate | date : "medium" }}
|
||||
{{ r.creationDate | date: "medium" }}
|
||||
</td>
|
||||
<td bitCell class="tw-align-middle">
|
||||
<button
|
||||
|
||||
@@ -41,7 +41,7 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
private platformUtilsService: PlatformUtilsService,
|
||||
private i18nService: I18nService,
|
||||
private logService: LogService,
|
||||
private validationService: ValidationService
|
||||
private validationService: ValidationService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
@@ -52,11 +52,11 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
this.refresh$.pipe(
|
||||
tap(() => (this.loading = true)),
|
||||
switchMap(() =>
|
||||
this.organizationAuthRequestService.listPendingRequests(this.organizationId)
|
||||
)
|
||||
)
|
||||
this.organizationAuthRequestService.listPendingRequests(this.organizationId),
|
||||
),
|
||||
),
|
||||
),
|
||||
takeUntil(this.destroy$)
|
||||
takeUntil(this.destroy$),
|
||||
)
|
||||
.subscribe((r) => {
|
||||
this.tableDataSource.data = r;
|
||||
@@ -72,7 +72,7 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
*/
|
||||
private async getEncryptedUserKey(
|
||||
devicePublicKey: string,
|
||||
resetPasswordDetails: OrganizationUserResetPasswordDetailsResponse
|
||||
resetPasswordDetails: OrganizationUserResetPasswordDetailsResponse,
|
||||
): Promise<EncString> {
|
||||
const encryptedUserKey = resetPasswordDetails.resetPasswordKey;
|
||||
const encryptedOrgPrivateKey = resetPasswordDetails.encryptedPrivateKey;
|
||||
@@ -82,7 +82,7 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
const orgSymKey = await this.cryptoService.getOrgKey(this.organizationId);
|
||||
const decOrgPrivateKey = await this.cryptoService.decryptToBytes(
|
||||
new EncString(encryptedOrgPrivateKey),
|
||||
orgSymKey
|
||||
orgSymKey,
|
||||
);
|
||||
|
||||
// Decrypt user key with decrypted org private key
|
||||
@@ -97,7 +97,7 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
await this.performAsyncAction(async () => {
|
||||
const details = await this.organizationUserService.getOrganizationUserResetPasswordDetails(
|
||||
this.organizationId,
|
||||
authRequest.organizationUserId
|
||||
authRequest.organizationUserId,
|
||||
);
|
||||
|
||||
// The user must be enrolled in account recovery (password reset) in order for the request to be approved.
|
||||
@@ -105,7 +105,7 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
this.platformUtilsService.showToast(
|
||||
"error",
|
||||
null,
|
||||
this.i18nService.t("resetPasswordDetailsError")
|
||||
this.i18nService.t("resetPasswordDetailsError"),
|
||||
);
|
||||
return;
|
||||
}
|
||||
@@ -115,13 +115,13 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
await this.organizationAuthRequestService.approvePendingRequest(
|
||||
this.organizationId,
|
||||
authRequest.id,
|
||||
encryptedKey
|
||||
encryptedKey,
|
||||
);
|
||||
|
||||
this.platformUtilsService.showToast(
|
||||
"success",
|
||||
null,
|
||||
this.i18nService.t("loginRequestApproved")
|
||||
this.i18nService.t("loginRequestApproved"),
|
||||
);
|
||||
});
|
||||
}
|
||||
@@ -141,12 +141,12 @@ export class DeviceApprovalsComponent implements OnInit, OnDestroy {
|
||||
await this.performAsyncAction(async () => {
|
||||
await this.organizationAuthRequestService.denyPendingRequests(
|
||||
this.organizationId,
|
||||
...this.tableDataSource.data.map((r) => r.id)
|
||||
...this.tableDataSource.data.map((r) => r.id),
|
||||
);
|
||||
this.platformUtilsService.showToast(
|
||||
"error",
|
||||
null,
|
||||
this.i18nService.t("allLoginRequestsDenied")
|
||||
this.i18nService.t("allLoginRequestsDenied"),
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
domainNameValidator(this.i18nService.t("invalidDomainNameMessage")),
|
||||
uniqueInArrayValidator(
|
||||
this.data.existingDomainNames,
|
||||
this.i18nService.t("duplicateDomainError")
|
||||
this.i18nService.t("duplicateDomainError"),
|
||||
),
|
||||
],
|
||||
],
|
||||
@@ -66,7 +66,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
private orgDomainApiService: OrgDomainApiServiceAbstraction,
|
||||
private orgDomainService: OrgDomainServiceAbstraction,
|
||||
private validationService: ValidationService,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
) {}
|
||||
|
||||
// Angular Method Implementations
|
||||
@@ -98,7 +98,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
// Google uses 43 chars for their TXT record value: https://support.google.com/a/answer/2716802
|
||||
// So, chose a magic # of 33 bytes to achieve at least that once converted to base 64 (47 char length).
|
||||
const generatedTxt = `bw=${Utils.fromBufferToB64(
|
||||
await this.cryptoFunctionService.randomBytes(33)
|
||||
await this.cryptoFunctionService.randomBytes(33),
|
||||
)}`;
|
||||
this.txtCtrl.setValue(generatedTxt);
|
||||
}
|
||||
@@ -131,7 +131,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
|
||||
const request: OrganizationDomainRequest = new OrganizationDomainRequest(
|
||||
this.txtCtrl.value,
|
||||
this.domainNameCtrl.value
|
||||
this.domainNameCtrl.value,
|
||||
);
|
||||
|
||||
try {
|
||||
@@ -162,7 +162,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
|
||||
this.rejectedDomainNameValidator = uniqueInArrayValidator(
|
||||
this.rejectedDomainNames,
|
||||
this.i18nService.t("domainNotAvailable", this.domainNameCtrl.value)
|
||||
this.i18nService.t("domainNotAvailable", this.domainNameCtrl.value),
|
||||
);
|
||||
|
||||
this.domainNameCtrl.addValidators(this.rejectedDomainNameValidator);
|
||||
@@ -195,7 +195,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
try {
|
||||
this.data.orgDomain = await this.orgDomainApiService.verify(
|
||||
this.data.organizationId,
|
||||
this.data.orgDomain.id
|
||||
this.data.orgDomain.id,
|
||||
);
|
||||
|
||||
if (this.data.orgDomain.verifiedDate) {
|
||||
@@ -245,7 +245,7 @@ export class DomainAddEditDialogComponent implements OnInit, OnDestroy {
|
||||
// Update this item so the last checked date gets updated.
|
||||
await this.orgDomainApiService.getByOrgIdAndOrgDomainId(
|
||||
this.data.organizationId,
|
||||
this.data.orgDomain.id
|
||||
this.data.orgDomain.id,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
}}</span>
|
||||
</td>
|
||||
<td bitCell class="tw-text-muted">
|
||||
{{ orgDomain.lastCheckedDate | date : "medium" }}
|
||||
{{ orgDomain.lastCheckedDate | date: "medium" }}
|
||||
</td>
|
||||
|
||||
<td bitCell class="table-list-options tw-text-right">
|
||||
|
||||
@@ -36,7 +36,7 @@ export class DomainVerificationComponent implements OnInit, OnDestroy {
|
||||
private orgDomainApiService: OrgDomainApiServiceAbstraction,
|
||||
private orgDomainService: OrgDomainServiceAbstraction,
|
||||
private dialogService: DialogService,
|
||||
private validationService: ValidationService
|
||||
private validationService: ValidationService,
|
||||
) {}
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
||||
@@ -52,7 +52,7 @@ export class DomainVerificationComponent implements OnInit, OnDestroy {
|
||||
this.organizationId = params.organizationId;
|
||||
await this.load();
|
||||
}),
|
||||
takeUntil(this.componentDestroyed$)
|
||||
takeUntil(this.componentDestroyed$),
|
||||
)
|
||||
.subscribe();
|
||||
}
|
||||
@@ -106,7 +106,7 @@ export class DomainVerificationComponent implements OnInit, OnDestroy {
|
||||
try {
|
||||
const orgDomain: OrganizationDomainResponse = await this.orgDomainApiService.verify(
|
||||
this.organizationId,
|
||||
orgDomainId
|
||||
orgDomainId,
|
||||
);
|
||||
|
||||
if (orgDomain.verifiedDate) {
|
||||
@@ -115,7 +115,7 @@ export class DomainVerificationComponent implements OnInit, OnDestroy {
|
||||
this.platformUtilsService.showToast(
|
||||
"error",
|
||||
null,
|
||||
this.i18nService.t("domainNotVerified", domainName)
|
||||
this.i18nService.t("domainNotVerified", domainName),
|
||||
);
|
||||
// Update this item so the last checked date gets updated.
|
||||
await this.updateOrgDomain(orgDomainId);
|
||||
@@ -141,7 +141,7 @@ export class DomainVerificationComponent implements OnInit, OnDestroy {
|
||||
this.platformUtilsService.showToast(
|
||||
"error",
|
||||
null,
|
||||
this.i18nService.t("domainNotAvailable", domainName)
|
||||
this.i18nService.t("domainNotAvailable", domainName),
|
||||
);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -47,7 +47,7 @@ export class ScimComponent implements OnInit {
|
||||
private i18nService: I18nService,
|
||||
private environmentService: EnvironmentService,
|
||||
private organizationApiService: OrganizationApiServiceAbstraction,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
@@ -62,7 +62,7 @@ export class ScimComponent implements OnInit {
|
||||
const connection = await this.apiService.getOrganizationConnection(
|
||||
this.organizationId,
|
||||
OrganizationConnectionType.Scim,
|
||||
ScimConfigApi
|
||||
ScimConfigApi,
|
||||
);
|
||||
await this.setConnectionFormValues(connection);
|
||||
}
|
||||
@@ -73,7 +73,7 @@ export class ScimComponent implements OnInit {
|
||||
apiKeyRequest.masterPasswordHash = "N/A";
|
||||
const apiKeyResponse = await this.organizationApiService.getOrCreateApiKey(
|
||||
this.organizationId,
|
||||
apiKeyRequest
|
||||
apiKeyRequest,
|
||||
);
|
||||
this.formData.setValue({
|
||||
endpointUrl: this.getScimEndpointUrl(),
|
||||
@@ -127,7 +127,7 @@ export class ScimComponent implements OnInit {
|
||||
this.organizationId,
|
||||
OrganizationConnectionType.Scim,
|
||||
true,
|
||||
new ScimConfigRequest(this.enabled.value)
|
||||
new ScimConfigRequest(this.enabled.value),
|
||||
);
|
||||
if (this.existingConnectionId == null) {
|
||||
this.formPromise = this.apiService.createOrganizationConnection(request, ScimConfigApi);
|
||||
@@ -135,7 +135,7 @@ export class ScimComponent implements OnInit {
|
||||
this.formPromise = this.apiService.updateOrganizationConnection(
|
||||
request,
|
||||
ScimConfigApi,
|
||||
this.existingConnectionId
|
||||
this.existingConnectionId,
|
||||
);
|
||||
}
|
||||
const response = (await this.formPromise) as OrganizationConnectionResponse<ScimConfigApi>;
|
||||
|
||||
@@ -29,7 +29,10 @@ export class MaximumVaultTimeoutPolicyComponent extends BasePolicyComponent {
|
||||
action: new FormControl<string>(null),
|
||||
});
|
||||
|
||||
constructor(private formBuilder: FormBuilder, private i18nService: I18nService) {
|
||||
constructor(
|
||||
private formBuilder: FormBuilder,
|
||||
private i18nService: I18nService,
|
||||
) {
|
||||
super();
|
||||
this.vaultTimeoutActionOptions = [
|
||||
{ name: i18nService.t("userPreference"), value: null },
|
||||
|
||||
@@ -31,7 +31,7 @@ export class AddOrganizationComponent implements OnInit {
|
||||
private i18nService: I18nService,
|
||||
private platformUtilsService: PlatformUtilsService,
|
||||
private validationService: ValidationService,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
@@ -66,7 +66,7 @@ export class AddOrganizationComponent implements OnInit {
|
||||
try {
|
||||
await this.webProviderService.addOrganizationToProvider(
|
||||
this.data.providerId,
|
||||
organization.id
|
||||
organization.id,
|
||||
);
|
||||
} catch (e) {
|
||||
this.validationService.showError(e);
|
||||
@@ -76,7 +76,7 @@ export class AddOrganizationComponent implements OnInit {
|
||||
this.platformUtilsService.showToast(
|
||||
"success",
|
||||
null,
|
||||
this.i18nService.t("organizationJoinedProvider")
|
||||
this.i18nService.t("organizationJoinedProvider"),
|
||||
);
|
||||
|
||||
this.dialogRef.close(true);
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
</ng-container>
|
||||
|
||||
<ng-container
|
||||
*ngIf="!loading && (clients | search : searchText : 'organizationName' : 'id') as searchedClients"
|
||||
*ngIf="!loading && (clients | search: searchText : 'organizationName' : 'id') as searchedClients"
|
||||
>
|
||||
<p *ngIf="!searchedClients.length">{{ "noClientsInList" | i18n }}</p>
|
||||
<ng-container *ngIf="searchedClients.length">
|
||||
|
||||
@@ -63,7 +63,7 @@ export class ClientsComponent implements OnInit {
|
||||
private modalService: ModalService,
|
||||
private organizationService: OrganizationService,
|
||||
private organizationApiService: OrganizationApiServiceAbstraction,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
@@ -86,12 +86,12 @@ export class ClientsComponent implements OnInit {
|
||||
this.manageOrganizations =
|
||||
(await this.providerService.get(this.providerId)).type === ProviderUserType.ProviderAdmin;
|
||||
const candidateOrgs = (await this.organizationService.getAll()).filter(
|
||||
(o) => o.isOwner && o.providerId == null
|
||||
(o) => o.isOwner && o.providerId == null,
|
||||
);
|
||||
const allowedOrgsIds = await Promise.all(
|
||||
candidateOrgs.map((o) => this.organizationApiService.get(o.id))
|
||||
candidateOrgs.map((o) => this.organizationApiService.get(o.id)),
|
||||
).then((orgs) =>
|
||||
orgs.filter((o) => !DisallowedPlanTypes.includes(o.planType)).map((o) => o.id)
|
||||
orgs.filter((o) => !DisallowedPlanTypes.includes(o.planType)).map((o) => o.id),
|
||||
);
|
||||
this.addableOrganizations = candidateOrgs.filter((o) => allowedOrgsIds.includes(o.id));
|
||||
|
||||
@@ -127,7 +127,7 @@ export class ClientsComponent implements OnInit {
|
||||
}
|
||||
if (this.clients.length > pagedLength) {
|
||||
this.pagedClients = this.pagedClients.concat(
|
||||
this.clients.slice(pagedLength, pagedLength + pagedSize)
|
||||
this.clients.slice(pagedLength, pagedLength + pagedSize),
|
||||
);
|
||||
}
|
||||
this.pagedClientsCount = this.pagedClients.length;
|
||||
@@ -158,14 +158,14 @@ export class ClientsComponent implements OnInit {
|
||||
|
||||
this.actionPromise = this.webProviderService.detachOrganization(
|
||||
this.providerId,
|
||||
organization.id
|
||||
organization.id,
|
||||
);
|
||||
try {
|
||||
await this.actionPromise;
|
||||
this.platformUtilsService.showToast(
|
||||
"success",
|
||||
null,
|
||||
this.i18nService.t("detachedOrganization", organization.organizationName)
|
||||
this.i18nService.t("detachedOrganization", organization.organizationName),
|
||||
);
|
||||
await this.load();
|
||||
} catch (e) {
|
||||
|
||||
@@ -17,7 +17,7 @@ const providerFactory = (props: Partial<Provider> = {}) =>
|
||||
enabled: true,
|
||||
type: ProviderUserType.ServiceUser,
|
||||
},
|
||||
props
|
||||
props,
|
||||
);
|
||||
|
||||
describe("Provider Permissions Guard", () => {
|
||||
@@ -43,7 +43,7 @@ describe("Provider Permissions Guard", () => {
|
||||
providerService,
|
||||
router,
|
||||
mock<PlatformUtilsService>(),
|
||||
mock<I18nService>()
|
||||
mock<I18nService>(),
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ export class ProviderPermissionsGuard implements CanActivate {
|
||||
private providerService: ProviderService,
|
||||
private router: Router,
|
||||
private platformUtilsService: PlatformUtilsService,
|
||||
private i18nService: I18nService
|
||||
private i18nService: I18nService,
|
||||
) {}
|
||||
|
||||
async canActivate(route: ActivatedRouteSnapshot) {
|
||||
|
||||
@@ -25,7 +25,7 @@ export class AcceptProviderComponent extends BaseAcceptComponent {
|
||||
route: ActivatedRoute,
|
||||
stateService: StateService,
|
||||
private apiService: ApiService,
|
||||
platformUtilService: PlatformUtilsService
|
||||
platformUtilService: PlatformUtilsService,
|
||||
) {
|
||||
super(router, platformUtilService, i18nService, route, stateService);
|
||||
}
|
||||
@@ -37,13 +37,13 @@ export class AcceptProviderComponent extends BaseAcceptComponent {
|
||||
await this.apiService.postProviderUserAccept(
|
||||
qParams.providerId,
|
||||
qParams.providerUserId,
|
||||
request
|
||||
request,
|
||||
);
|
||||
this.platformUtilService.showToast(
|
||||
"success",
|
||||
this.i18nService.t("inviteAccepted"),
|
||||
this.i18nService.t("providerInviteAcceptedDesc"),
|
||||
{ timeout: 10000 }
|
||||
{ timeout: 10000 },
|
||||
);
|
||||
this.router.navigate(["/vault"]);
|
||||
}
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr *ngFor="let e of events">
|
||||
<td>{{ e.date | date : "medium" }}</td>
|
||||
<td>{{ e.date | date: "medium" }}</td>
|
||||
<td>
|
||||
<i
|
||||
class="text-muted bwi bwi-lg {{ e.appIcon }}"
|
||||
|
||||
@@ -36,7 +36,7 @@ export class EventsComponent extends BaseEventsComponent implements OnInit {
|
||||
private router: Router,
|
||||
logService: LogService,
|
||||
private userNamePipe: UserNamePipe,
|
||||
fileDownloadService: FileDownloadService
|
||||
fileDownloadService: FileDownloadService,
|
||||
) {
|
||||
super(
|
||||
eventService,
|
||||
@@ -44,7 +44,7 @@ export class EventsComponent extends BaseEventsComponent implements OnInit {
|
||||
exportService,
|
||||
platformUtilsService,
|
||||
logService,
|
||||
fileDownloadService
|
||||
fileDownloadService,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@ export class EventsComponent extends BaseEventsComponent implements OnInit {
|
||||
this.providerId,
|
||||
startDate,
|
||||
endDate,
|
||||
continuationToken
|
||||
continuationToken,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,10 @@ export class ManageComponent implements OnInit {
|
||||
provider: Provider;
|
||||
accessEvents = false;
|
||||
|
||||
constructor(private route: ActivatedRoute, private providerService: ProviderService) {}
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private providerService: ProviderService,
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
// eslint-disable-next-line rxjs-angular/prefer-takeuntil, rxjs/no-async-subscribe
|
||||
|
||||
@@ -90,7 +90,7 @@
|
||||
!loading &&
|
||||
(isPaging()
|
||||
? pagedUsers
|
||||
: (users | search : searchText : 'name' : 'email' : 'id')) as searchedUsers
|
||||
: (users | search: searchText : 'name' : 'email' : 'id')) as searchedUsers
|
||||
"
|
||||
>
|
||||
<p *ngIf="!searchedUsers.length">{{ "noUsersInList" | i18n }}</p>
|
||||
|
||||
@@ -69,7 +69,7 @@ export class PeopleComponent
|
||||
userNamePipe: UserNamePipe,
|
||||
stateService: StateService,
|
||||
private providerService: ProviderService,
|
||||
dialogService: DialogService
|
||||
dialogService: DialogService,
|
||||
) {
|
||||
super(
|
||||
apiService,
|
||||
@@ -83,7 +83,7 @@ export class PeopleComponent
|
||||
searchPipe,
|
||||
userNamePipe,
|
||||
stateService,
|
||||
dialogService
|
||||
dialogService,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -161,7 +161,7 @@ export class PeopleComponent
|
||||
modal.close();
|
||||
this.removeUser(user);
|
||||
});
|
||||
}
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
@@ -188,7 +188,7 @@ export class PeopleComponent
|
||||
(comp) => {
|
||||
comp.providerId = this.providerId;
|
||||
comp.users = this.getCheckedUsers();
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
await modal.onClosedPromise();
|
||||
@@ -207,7 +207,7 @@ export class PeopleComponent
|
||||
this.platformUtilsService.showToast(
|
||||
"error",
|
||||
this.i18nService.t("errorOccurred"),
|
||||
this.i18nService.t("noSelectedUsersApplicable")
|
||||
this.i18nService.t("noSelectedUsersApplicable"),
|
||||
);
|
||||
return;
|
||||
}
|
||||
@@ -219,7 +219,7 @@ export class PeopleComponent
|
||||
users,
|
||||
filteredUsers,
|
||||
response,
|
||||
this.i18nService.t("bulkReinviteMessage")
|
||||
this.i18nService.t("bulkReinviteMessage"),
|
||||
);
|
||||
} catch (e) {
|
||||
this.validationService.showError(e);
|
||||
@@ -238,7 +238,7 @@ export class PeopleComponent
|
||||
(comp) => {
|
||||
comp.providerId = this.providerId;
|
||||
comp.users = this.getCheckedUsers();
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
await modal.onClosedPromise();
|
||||
@@ -249,14 +249,14 @@ export class PeopleComponent
|
||||
users: ProviderUserUserDetailsResponse[],
|
||||
filteredUsers: ProviderUserUserDetailsResponse[],
|
||||
request: Promise<ListResponse<ProviderUserBulkResponse>>,
|
||||
successfullMessage: string
|
||||
successfullMessage: string,
|
||||
) {
|
||||
const [modal, childComponent] = await this.modalService.openViewRef(
|
||||
BulkStatusComponent,
|
||||
this.bulkStatusModalRef,
|
||||
(comp) => {
|
||||
comp.loading = true;
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
// Workaround to handle closing the modal shortly after it has been opened
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
required
|
||||
appAutoFocus
|
||||
/>
|
||||
<small class="text-muted">{{ "inviteMultipleEmailDesc" | i18n : "20" }}</small>
|
||||
<small class="text-muted">{{ "inviteMultipleEmailDesc" | i18n: "20" }}</small>
|
||||
</div>
|
||||
</ng-container>
|
||||
<h3>
|
||||
|
||||
@@ -38,7 +38,7 @@ export class UserAddEditComponent implements OnInit {
|
||||
private i18nService: I18nService,
|
||||
private platformUtilsService: PlatformUtilsService,
|
||||
private logService: LogService,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
@@ -68,7 +68,7 @@ export class UserAddEditComponent implements OnInit {
|
||||
this.formPromise = this.apiService.putProviderUser(
|
||||
this.providerId,
|
||||
this.providerUserId,
|
||||
request
|
||||
request,
|
||||
);
|
||||
} else {
|
||||
const request = new ProviderUserInviteRequest();
|
||||
@@ -80,7 +80,7 @@ export class UserAddEditComponent implements OnInit {
|
||||
this.platformUtilsService.showToast(
|
||||
"success",
|
||||
null,
|
||||
this.i18nService.t(this.editMode ? "editedUserId" : "invitedUsers", this.name)
|
||||
this.i18nService.t(this.editMode ? "editedUserId" : "invitedUsers", this.name),
|
||||
);
|
||||
this.onSavedUser.emit();
|
||||
} catch (e) {
|
||||
@@ -109,7 +109,7 @@ export class UserAddEditComponent implements OnInit {
|
||||
this.platformUtilsService.showToast(
|
||||
"success",
|
||||
null,
|
||||
this.i18nService.t("removedUserId", this.name)
|
||||
this.i18nService.t("removedUserId", this.name),
|
||||
);
|
||||
this.onDeletedUser.emit();
|
||||
} catch (e) {
|
||||
|
||||
@@ -13,7 +13,10 @@ export class ProvidersLayoutComponent {
|
||||
provider: Provider;
|
||||
private providerId: string;
|
||||
|
||||
constructor(private route: ActivatedRoute, private providerService: ProviderService) {}
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private providerService: ProviderService,
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
document.body.classList.remove("layout_frontend");
|
||||
|
||||
@@ -10,7 +10,7 @@ export class WebProviderService {
|
||||
constructor(
|
||||
private cryptoService: CryptoService,
|
||||
private syncService: SyncService,
|
||||
private apiService: ApiService
|
||||
private apiService: ApiService,
|
||||
) {}
|
||||
|
||||
async addOrganizationToProvider(providerId: string, organizationId: string) {
|
||||
|
||||
@@ -29,7 +29,7 @@ export class AccountComponent {
|
||||
private route: ActivatedRoute,
|
||||
private syncService: SyncService,
|
||||
private platformUtilsService: PlatformUtilsService,
|
||||
private logService: LogService
|
||||
private logService: LogService,
|
||||
) {}
|
||||
|
||||
async ngOnInit() {
|
||||
|
||||
@@ -9,7 +9,10 @@ import { ProviderService } from "@bitwarden/common/admin-console/abstractions/pr
|
||||
})
|
||||
// eslint-disable-next-line rxjs-angular/prefer-takeuntil
|
||||
export class SettingsComponent {
|
||||
constructor(private route: ActivatedRoute, private providerService: ProviderService) {}
|
||||
constructor(
|
||||
private route: ActivatedRoute,
|
||||
private providerService: ProviderService,
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
// eslint-disable-next-line rxjs-angular/prefer-takeuntil, rxjs/no-async-subscribe
|
||||
|
||||
@@ -35,7 +35,7 @@ export class SetupComponent implements OnInit {
|
||||
private cryptoService: CryptoService,
|
||||
private apiService: ApiService,
|
||||
private syncService: SyncService,
|
||||
private validationService: ValidationService
|
||||
private validationService: ValidationService,
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
@@ -49,7 +49,7 @@ export class SetupComponent implements OnInit {
|
||||
"error",
|
||||
null,
|
||||
this.i18nService.t("emergencyInviteAcceptFailed"),
|
||||
{ timeout: 10000 }
|
||||
{ timeout: 10000 },
|
||||
);
|
||||
this.router.navigate(["/"]);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user