mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 06:13:38 +00:00
[PM-26078] Create admin UI for Autotype Desktop Default Setting Policy (#16573)
* PM-26078 add component and copy * add enum * register oss policy * export policy definition * update naming to match policy
This commit is contained in:
@@ -0,0 +1,4 @@
|
|||||||
|
<bit-form-control>
|
||||||
|
<input type="checkbox" bitCheckbox [formControl]="enabled" id="enabled" />
|
||||||
|
<bit-label>{{ "turnOn" | i18n }}</bit-label>
|
||||||
|
</bit-form-control>
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
import { Component } from "@angular/core";
|
||||||
|
|
||||||
|
import { PolicyType } from "@bitwarden/common/admin-console/enums";
|
||||||
|
import { Organization } from "@bitwarden/common/admin-console/models/domain/organization";
|
||||||
|
import { FeatureFlag } from "@bitwarden/common/enums/feature-flag.enum";
|
||||||
|
import { ConfigService } from "@bitwarden/common/platform/abstractions/config/config.service";
|
||||||
|
|
||||||
|
import { SharedModule } from "../../../../shared";
|
||||||
|
import { BasePolicyEditDefinition, BasePolicyEditComponent } from "../base-policy-edit.component";
|
||||||
|
|
||||||
|
export class DesktopAutotypeDefaultSettingPolicy extends BasePolicyEditDefinition {
|
||||||
|
name = "desktopAutotypePolicy";
|
||||||
|
description = "desktopAutotypePolicyDesc";
|
||||||
|
type = PolicyType.AutotypeDefaultSetting;
|
||||||
|
component = DesktopAutotypeDefaultSettingPolicyComponent;
|
||||||
|
|
||||||
|
display$(organization: Organization, configService: ConfigService) {
|
||||||
|
return configService.getFeatureFlag$(FeatureFlag.WindowsDesktopAutotype);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@Component({
|
||||||
|
templateUrl: "autotype-policy.component.html",
|
||||||
|
imports: [SharedModule],
|
||||||
|
})
|
||||||
|
export class DesktopAutotypeDefaultSettingPolicyComponent extends BasePolicyEditComponent {}
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
export { DisableSendPolicy } from "./disable-send.component";
|
export { DisableSendPolicy } from "./disable-send.component";
|
||||||
|
export { DesktopAutotypeDefaultSettingPolicy } from "./autotype-policy.component";
|
||||||
export { MasterPasswordPolicy } from "./master-password.component";
|
export { MasterPasswordPolicy } from "./master-password.component";
|
||||||
export { OrganizationDataOwnershipPolicy } from "./organization-data-ownership.component";
|
export { OrganizationDataOwnershipPolicy } from "./organization-data-ownership.component";
|
||||||
export { PasswordGeneratorPolicy } from "./password-generator.component";
|
export { PasswordGeneratorPolicy } from "./password-generator.component";
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import { BasePolicyEditDefinition } from "./base-policy-edit.component";
|
import { BasePolicyEditDefinition } from "./base-policy-edit.component";
|
||||||
import {
|
import {
|
||||||
|
DesktopAutotypeDefaultSettingPolicy,
|
||||||
DisableSendPolicy,
|
DisableSendPolicy,
|
||||||
MasterPasswordPolicy,
|
MasterPasswordPolicy,
|
||||||
OrganizationDataOwnershipPolicy,
|
OrganizationDataOwnershipPolicy,
|
||||||
@@ -31,4 +32,5 @@ export const ossPolicyEditRegister: BasePolicyEditDefinition[] = [
|
|||||||
new DisableSendPolicy(),
|
new DisableSendPolicy(),
|
||||||
new SendOptionsPolicy(),
|
new SendOptionsPolicy(),
|
||||||
new RestrictedItemTypesPolicy(),
|
new RestrictedItemTypesPolicy(),
|
||||||
|
new DesktopAutotypeDefaultSettingPolicy(),
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -5561,6 +5561,13 @@
|
|||||||
"personalOwnershipSubmitError": {
|
"personalOwnershipSubmitError": {
|
||||||
"message": "Due to an Enterprise policy, you are restricted from saving items to your individual vault. Change the ownership option to an organization and choose from available collections."
|
"message": "Due to an Enterprise policy, you are restricted from saving items to your individual vault. Change the ownership option to an organization and choose from available collections."
|
||||||
},
|
},
|
||||||
|
"desktopAutotypePolicy": {
|
||||||
|
"message": "Desktop Autotype Default Setting"
|
||||||
|
},
|
||||||
|
"desktopAutotypePolicyDesc": {
|
||||||
|
"message": "Turn Desktop Autotype ON by default for members. Members can turn Autotype off manually in the Desktop client.",
|
||||||
|
"description": "This policy will enable Desktop Autotype by default for members on Unlock."
|
||||||
|
},
|
||||||
"disableSend": {
|
"disableSend": {
|
||||||
"message": "Remove Send"
|
"message": "Remove Send"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -17,4 +17,5 @@ export enum PolicyType {
|
|||||||
FreeFamiliesSponsorshipPolicy = 13, // Disables free families plan for organization
|
FreeFamiliesSponsorshipPolicy = 13, // Disables free families plan for organization
|
||||||
RemoveUnlockWithPin = 14, // Do not allow members to unlock their account with a PIN.
|
RemoveUnlockWithPin = 14, // Do not allow members to unlock their account with a PIN.
|
||||||
RestrictedItemTypes = 15, // Restricts item types that can be created within an organization
|
RestrictedItemTypes = 15, // Restricts item types that can be created within an organization
|
||||||
|
AutotypeDefaultSetting = 17, // Sets the default autotype setting for desktop app
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user