1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-01-22 21:21:35 +01:00

[PS-683] Update negative copy (#2912)

* feat(browser): Update auto biometrics copy

* refactor(common): remove TotpService.isAutoCopyEnabled and use state directly

The TotpService was just taking the value from StateService and forwarding it, making it depend on state service.
All services that depended on the TotpService.isAutoCopyEnable flag also depended on StateService.
This therefore simplifies things by using StateService directly.

* feat(browser): update auto totp copy

* feat(browser): update add login notification copy

* feat(browser): update change password notification copy

* feat(browser): update context menu copy

* feat(browser): update show cards current tab copy

* feat(browser): update show identities current tab copy

* feat(browser): update enable favicon copy

* feat(browser): update badge counter copy

* feat(browser): update auto-fill copy

* feat(desktop): update auto biometrics prompt copy

* feat(desktop): update favicon copy

* feat(desktop): adjust copy

* feat(web): update favicons copy

* feat(web): adjust copy

* feat(web): update preference settings to sentence case

* feat(browser): update settings and options page to sentence case

* feat(desktop): update settings to sentence case

* feat(web): update copy

* feat(desktop): update copy
This commit is contained in:
Andreas Coroiu 2022-06-23 09:53:42 +02:00 committed by GitHub
parent fdc1ecef98
commit fd69e163ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
18 changed files with 206 additions and 220 deletions

View File

@ -146,10 +146,10 @@
"message": "Account"
},
"changeMasterPassword": {
"message": "Change Master Password"
"message": "Change master password"
},
"fingerprintPhrase": {
"message": "Fingerprint Phrase",
"message": "Fingerprint phrase",
"description": "A 'fingerprint phrase' is a unique word phrase (similar to a passphrase) that a user can use to authenticate their public key with another user, for the purposes of sharing."
},
"yourAccountsFingerprint": {
@ -157,10 +157,10 @@
"description": "A 'fingerprint phrase' is a unique word phrase (similar to a passphrase) that a user can use to authenticate their public key with another user, for the purposes of sharing."
},
"twoStepLogin": {
"message": "Two-step Login"
"message": "Two-step login"
},
"logOut": {
"message": "Log Out"
"message": "Log out"
},
"about": {
"message": "About"
@ -193,7 +193,7 @@
"message": "There are no folders to list."
},
"helpFeedback": {
"message": "Help & Feedback"
"message": "Help & feedback"
},
"sync": {
"message": "Sync"
@ -215,10 +215,10 @@
"message": "Automatically generate strong, unique passwords for your logins."
},
"bitWebVault": {
"message": "Bitwarden Web Vault"
"message": "Bitwarden web vault"
},
"importItems": {
"message": "Import Items"
"message": "Import items"
},
"select": {
"message": "Select"
@ -330,7 +330,7 @@
"message": "Other"
},
"rateExtension": {
"message": "Rate the Extension"
"message": "Rate the extension"
},
"rateExtensionDesc": {
"message": "Please consider helping us out with a good review!"
@ -364,10 +364,10 @@
"message": "Invalid master password"
},
"vaultTimeout": {
"message": "Vault Timeout"
"message": "Vault timeout"
},
"lockNow": {
"message": "Lock Now"
"message": "Lock now"
},
"immediately": {
"message": "Immediately"
@ -403,10 +403,10 @@
"message": "4 hours"
},
"onLocked": {
"message": "On System Lock"
"message": "On system lock"
},
"onRestart": {
"message": "On Browser Restart"
"message": "On browser restart"
},
"never": {
"message": "Never"
@ -567,26 +567,26 @@
"message": "No Folder",
"description": "This is the folder for uncategorized items"
},
"disableAddLoginNotification": {
"message": "Disable Add Login Notification"
"enableAddLoginNotification": {
"message": "Ask to add login"
},
"addLoginNotificationDesc": {
"message": "The \"Add Login Notification\" automatically prompts you to save new logins to your vault whenever you log into them for the first time."
"message": "Ask to add an item if one isn't found in your vault."
},
"dontShowCardsCurrentTab": {
"message": "Don't Show Cards on Tab Page"
"showCardsCurrentTab": {
"message": "Show cards on Tab page"
},
"dontShowCardsCurrentTabDesc": {
"message": "Card items from your vault are listed on the 'Current Tab' page for easy auto-fill access."
"showCardsCurrentTabDesc": {
"message": "List card items on the Tab page for easy auto-fill."
},
"dontShowIdentitiesCurrentTab": {
"message": "Don't Show Identities on Tab Page"
"showIdentitiesCurrentTab": {
"message": "Show identities on Tab page"
},
"dontShowIdentitiesCurrentTabDesc": {
"message": "Identity items from your vault are listed on the 'Current Tab' page for easy auto-fill access."
"showIdentitiesCurrentTabDesc": {
"message": "List identity items on the Tab page for easy auto-fill."
},
"clearClipboard": {
"message": "Clear Clipboard",
"message": "Clear clipboard",
"description": "Clipboard is the operating system thing where you copy/paste data to on your device."
},
"clearClipboardDesc": {
@ -599,11 +599,11 @@
"notificationAddSave": {
"message": "Save"
},
"disableChangedPasswordNotification": {
"message": "Disable Changed Password Notification"
"enableChangedPasswordNotification": {
"message": "Ask to update existing login"
},
"disableChangedPasswordNotificationDesc": {
"message": "The \"Changed Password Notification\" automatically prompts you to update a login's password in your vault whenever it detects that you have changed it on a website."
"changedPasswordNotificationDesc": {
"message": "Ask to update a login's password when a change is detected on a website."
},
"notificationChangeDesc": {
"message": "Do you want to update this password in Bitwarden?"
@ -611,14 +611,14 @@
"notificationChangeSave": {
"message": "Update"
},
"disableContextMenuItem": {
"message": "Disable Context Menu Options"
"enableContextMenuItem": {
"message": "Show context menu options"
},
"disableContextMenuItemDesc": {
"message": "Context menu options provide quick access to password generation and logins for the website in your current tab."
"contextMenuItemDesc": {
"message": "Use a secondary click to access password generation and matching logins for the website. "
},
"defaultUriMatchDetection": {
"message": "Default URI Match Detection",
"message": "Default URI match detection",
"description": "Default URI match detection for auto-fill."
},
"defaultUriMatchDetectionDesc": {
@ -639,11 +639,11 @@
"description": "Light color"
},
"solarizedDark": {
"message": "Solarized Dark",
"message": "Solarized dark",
"description": "'Solarized' is a noun and the name of a color scheme. It should not be translated."
},
"exportVault": {
"message": "Export Vault"
"message": "Export vault"
},
"fileFormat": {
"message": "File Format"
@ -671,7 +671,7 @@
"message": "Shared"
},
"learnOrg": {
"message": "Learn about Organizations"
"message": "Learn about organizations"
},
"learnOrgConfirmation": {
"message": "Bitwarden allows you to share your vault items with others by using an organization. Would you like to visit the bitwarden.com website to learn more?"
@ -747,7 +747,7 @@
"message": "You cannot use this feature until you update your encryption key."
},
"premiumMembership": {
"message": "Premium Membership"
"message": "Premium membership"
},
"premiumManage": {
"message": "Manage Membership"
@ -806,14 +806,14 @@
"refreshComplete": {
"message": "Refresh complete"
},
"disableAutoTotpCopy": {
"message": "Disable Automatic TOTP Copy"
"enableAutoTotpCopy": {
"message": "Copy TOTP automatically"
},
"disableAutoTotpCopyDesc": {
"message": "If your login has an authenticator key attached to it, the TOTP verification code is automatically copied to your clipboard whenever you auto-fill the login."
"message": "If a login has an authenticator key, copy the TOTP verification code to your clip-board when you auto-fill the login."
},
"disableAutoBiometricsPrompt": {
"message": "Do not prompt for biometrics on launch"
"enableAutoBiometricsPrompt": {
"message": "Ask for biometrics on launch"
},
"premiumRequired": {
"message": "Premium Required"
@ -951,10 +951,10 @@
"message": "The environment URLs have been saved."
},
"enableAutoFillOnPageLoad": {
"message": "Enable Auto-fill on Page Load"
"message": "Auto-fill on page load"
},
"enableAutoFillOnPageLoadDesc": {
"message": "If a login form is detected, automatically perform an auto-fill when the web page loads."
"message": "If a login form is detected, auto-fill when the web page loads."
},
"experimentalFeature": {
"message": "This is currently an experimental feature. Use at your own risk."
@ -963,10 +963,10 @@
"message": "Default autofill setting for login items"
},
"defaultAutoFillOnPageLoadDesc": {
"message": "After enabling Auto-fill on Page Load, you can enable or disable the feature for individual login items. This is the default setting for login items that are not separately configured."
"message": "You can turn off auto-fill on page load for individual login items from the item's Edit view."
},
"itemAutoFillOnPageLoad": {
"message": "Auto-fill on Page Load (if enabled in Options)"
"message": "Auto-fill on page load (if enabled in Options)"
},
"autoFillOnPageLoadUseDefault": {
"message": "Use default setting"
@ -1033,17 +1033,17 @@
"popupU2fCloseMessage": {
"message": "This browser cannot process U2F requests in this popup window. Do you want to open this popup in a new window so that you can log in using U2F?"
},
"disableFavicon": {
"message": "Disable Website Icons"
"enableFavicon": {
"message": "Show website icons"
},
"disableFaviconDesc": {
"message": "Website Icons provide a recognizable image next to each login item in your vault."
"faviconDesc": {
"message": "Show a recognizable image next to each login."
},
"disableBadgeCounter": {
"message": "Disable Badge Counter"
"enableBadgeCounter": {
"message": "Show badge counter"
},
"disableBadgeCounterDesc": {
"message": "Badge counter indicates how many logins you have for the current page in your vault."
"badgeCounterDesc": {
"message": "Indicate how many logins you have for the current web page."
},
"cardholderName": {
"message": "Cardholder Name"
@ -1249,7 +1249,7 @@
"description": "Domain name. Ex. website.com"
},
"domainName": {
"message": "Domain Name",
"message": "Domain name",
"description": "Domain name. Ex. website.com"
},
"host": {
@ -1386,7 +1386,7 @@
"message": "One or more organization policies are affecting your generator settings."
},
"vaultTimeoutAction": {
"message": "Vault Timeout Action"
"message": "Vault timeout action"
},
"lock": {
"message": "Lock",
@ -1562,7 +1562,7 @@
"message": "An organization policy is affecting your ownership options."
},
"excludedDomains": {
"message": "Excluded Domains"
"message": "Excluded domains"
},
"excludedDomainsDesc": {
"message": "Bitwarden will not ask to save login details for these domains. You must refresh the page for changes to take effect."

View File

@ -366,11 +366,7 @@ export default class MainBackground {
this.policyService,
this.stateService
);
this.totpService = new TotpService(
this.cryptoFunctionService,
this.logService,
this.stateService
);
this.totpService = new TotpService(this.cryptoFunctionService, this.logService);
this.autofillService = new AutofillService(
this.cipherService,
this.stateService,

View File

@ -63,12 +63,12 @@
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="totp">{{ "disableAutoTotpCopy" | i18n }}</label>
<label for="totp">{{ "enableAutoTotpCopy" | i18n }}</label>
<input
id="totp"
type="checkbox"
(change)="updateAutoTotpCopy()"
[(ngModel)]="disableAutoTotpCopy"
[(ngModel)]="enableAutoTotpCopy"
/>
</div>
</div>
@ -77,12 +77,12 @@
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="addlogin-notification-bar">{{ "disableAddLoginNotification" | i18n }}</label>
<label for="addlogin-notification-bar">{{ "enableAddLoginNotification" | i18n }}</label>
<input
id="addlogin-notification-bar"
type="checkbox"
(change)="updateAddLoginNotification()"
[(ngModel)]="disableAddLoginNotification"
[(ngModel)]="enableAddLoginNotification"
/>
</div>
</div>
@ -92,31 +92,31 @@
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="changedpass-notification-bar">{{
"disableChangedPasswordNotification" | i18n
"enableChangedPasswordNotification" | i18n
}}</label>
<input
id="changedpass-notification-bar"
type="checkbox"
(change)="updateChangedPasswordNotification()"
[(ngModel)]="disableChangedPasswordNotification"
[(ngModel)]="enableChangedPasswordNotification"
/>
</div>
</div>
<div class="box-footer">{{ "disableChangedPasswordNotificationDesc" | i18n }}</div>
<div class="box-footer">{{ "changedPasswordNotificationDesc" | i18n }}</div>
</div>
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="context-menu">{{ "disableContextMenuItem" | i18n }}</label>
<label for="context-menu">{{ "enableContextMenuItem" | i18n }}</label>
<input
id="context-menu"
type="checkbox"
(change)="updateDisableContextMenuItem()"
[(ngModel)]="disableContextMenuItem"
(change)="updateContextMenuItem()"
[(ngModel)]="enableContextMenuItem"
/>
</div>
</div>
<div class="box-footer">{{ "disableContextMenuItemDesc" | i18n }}</div>
<div class="box-footer">{{ "contextMenuItemDesc" | i18n }}</div>
</div>
</ng-container>
<div class="box box-section-divider">
@ -137,58 +137,58 @@
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="dontShowCards">{{ "dontShowCardsCurrentTab" | i18n }}</label>
<label for="showCardsCurrentTab">{{ "showCardsCurrentTab" | i18n }}</label>
<input
id="dontShowCards"
id="showCardsCurrentTab"
type="checkbox"
(change)="updateShowCards()"
[(ngModel)]="dontShowCards"
(change)="updateShowCardsCurrentTab()"
[(ngModel)]="showCardsCurrentTab"
/>
</div>
</div>
<div class="box-footer">{{ "dontShowCardsCurrentTabDesc" | i18n }}</div>
<div class="box-footer">{{ "showCardsCurrentTabDesc" | i18n }}</div>
</div>
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="dontShowIdentities">{{ "dontShowIdentitiesCurrentTab" | i18n }}</label>
<label for="showIdentitiesCurrentTab">{{ "showIdentitiesCurrentTab" | i18n }}</label>
<input
id="dontShowIdentities"
id="showIdentitiesCurrentTab"
type="checkbox"
(change)="updateShowIdentities()"
[(ngModel)]="dontShowIdentities"
(change)="updateShowIdentitiesCurrentTab()"
[(ngModel)]="showIdentitiesCurrentTab"
/>
</div>
</div>
<div class="box-footer">{{ "dontShowIdentitiesCurrentTabDesc" | i18n }}</div>
<div class="box-footer">{{ "showIdentitiesCurrentTabDesc" | i18n }}</div>
</div>
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="favicon">{{ "disableFavicon" | i18n }}</label>
<label for="favicon">{{ "enableFavicon" | i18n }}</label>
<input
id="favicon"
type="checkbox"
(change)="updateDisableFavicon()"
[(ngModel)]="disableFavicon"
(change)="updateFavicon()"
[(ngModel)]="enableFavicon"
/>
</div>
</div>
<div class="box-footer">{{ "disableFaviconDesc" | i18n }}</div>
<div class="box-footer">{{ "faviconDesc" | i18n }}</div>
</div>
<div class="box">
<div class="box-content">
<div class="box-content-row box-content-row-checkbox" appBoxRow>
<label for="badge">{{ "disableBadgeCounter" | i18n }}</label>
<label for="badge">{{ "enableBadgeCounter" | i18n }}</label>
<input
id="badge"
type="checkbox"
(change)="updateDisableBadgeCounter()"
[(ngModel)]="disableBadgeCounter"
(change)="updateBadgeCounter()"
[(ngModel)]="enableBadgeCounter"
/>
</div>
</div>
<div class="box-footer">{{ "disableBadgeCounterDesc" | i18n }}</div>
<div class="box-footer">{{ "badgeCounterDesc" | i18n }}</div>
</div>
<div class="box">
<div class="box-content">

View File

@ -12,17 +12,17 @@ import { UriMatchType } from "@bitwarden/common/enums/uriMatchType";
templateUrl: "options.component.html",
})
export class OptionsComponent implements OnInit {
disableFavicon = false;
disableBadgeCounter = false;
enableFavicon = false;
enableBadgeCounter = false;
enableAutoFillOnPageLoad = false;
autoFillOnPageLoadDefault = false;
autoFillOnPageLoadOptions: any[];
disableAutoTotpCopy = false;
disableContextMenuItem = false;
disableAddLoginNotification = false;
disableChangedPasswordNotification = false;
dontShowCards = false;
dontShowIdentities = false;
enableAutoTotpCopy = false; // TODO: Does it matter if this is set to false or true?
enableContextMenuItem = false;
enableAddLoginNotification = false;
enableChangedPasswordNotification = false;
showCardsCurrentTab = false;
showIdentitiesCurrentTab = false;
showClearClipboard = true;
theme: ThemeType;
themeOptions: any[];
@ -76,21 +76,21 @@ export class OptionsComponent implements OnInit {
this.autoFillOnPageLoadDefault =
(await this.stateService.getAutoFillOnPageLoadDefault()) ?? true;
this.disableAddLoginNotification = await this.stateService.getDisableAddLoginNotification();
this.enableAddLoginNotification = !(await this.stateService.getDisableAddLoginNotification());
this.disableChangedPasswordNotification =
await this.stateService.getDisableChangedPasswordNotification();
this.enableChangedPasswordNotification =
!(await this.stateService.getDisableChangedPasswordNotification());
this.disableContextMenuItem = await this.stateService.getDisableContextMenuItem();
this.enableContextMenuItem = !(await this.stateService.getDisableContextMenuItem());
this.dontShowCards = await this.stateService.getDontShowCardsCurrentTab();
this.dontShowIdentities = await this.stateService.getDontShowIdentitiesCurrentTab();
this.showCardsCurrentTab = !(await this.stateService.getDontShowCardsCurrentTab());
this.showIdentitiesCurrentTab = !(await this.stateService.getDontShowIdentitiesCurrentTab());
this.disableAutoTotpCopy = !(await this.totpService.isAutoCopyEnabled());
this.enableAutoTotpCopy = !(await this.stateService.getDisableAutoTotpCopy());
this.disableFavicon = await this.stateService.getDisableFavicon();
this.enableFavicon = !(await this.stateService.getDisableFavicon());
this.disableBadgeCounter = await this.stateService.getDisableBadgeCounter();
this.enableBadgeCounter = !(await this.stateService.getDisableBadgeCounter());
this.theme = await this.stateService.getTheme();
@ -101,22 +101,22 @@ export class OptionsComponent implements OnInit {
}
async updateAddLoginNotification() {
await this.stateService.setDisableAddLoginNotification(this.disableAddLoginNotification);
await this.stateService.setDisableAddLoginNotification(!this.enableAddLoginNotification);
}
async updateChangedPasswordNotification() {
await this.stateService.setDisableChangedPasswordNotification(
this.disableChangedPasswordNotification
!this.enableChangedPasswordNotification
);
}
async updateDisableContextMenuItem() {
await this.stateService.setDisableContextMenuItem(this.disableContextMenuItem);
async updateContextMenuItem() {
await this.stateService.setDisableContextMenuItem(!this.enableContextMenuItem);
this.messagingService.send("bgUpdateContextMenu");
}
async updateAutoTotpCopy() {
await this.stateService.setDisableAutoTotpCopy(this.disableAutoTotpCopy);
await this.stateService.setDisableAutoTotpCopy(!this.enableAutoTotpCopy);
}
async updateAutoFillOnPageLoad() {
@ -127,21 +127,21 @@ export class OptionsComponent implements OnInit {
await this.stateService.setAutoFillOnPageLoadDefault(this.autoFillOnPageLoadDefault);
}
async updateDisableFavicon() {
await this.stateService.setDisableFavicon(this.disableFavicon);
async updateFavicon() {
await this.stateService.setDisableFavicon(!this.enableFavicon);
}
async updateDisableBadgeCounter() {
await this.stateService.setDisableBadgeCounter(this.disableBadgeCounter);
async updateBadgeCounter() {
await this.stateService.setDisableBadgeCounter(!this.enableBadgeCounter);
this.messagingService.send("bgUpdateContextMenu");
}
async updateShowCards() {
await this.stateService.setDontShowCardsCurrentTab(this.dontShowCards);
async updateShowCardsCurrentTab() {
await this.stateService.setDontShowCardsCurrentTab(!this.showCardsCurrentTab);
}
async updateShowIdentities() {
await this.stateService.setDontShowIdentitiesCurrentTab(this.dontShowIdentities);
async updateShowIdentitiesCurrentTab() {
await this.stateService.setDontShowIdentitiesCurrentTab(!this.showIdentitiesCurrentTab);
}
async saveTheme() {

View File

@ -60,13 +60,13 @@
/>
</div>
<div class="box-content-row box-content-row-checkbox" appBoxRow *ngIf="supportsBiometric">
<label for="autoBiometricsPrompt">{{ "disableAutoBiometricsPrompt" | i18n }}</label>
<label for="autoBiometricsPrompt">{{ "enableAutoBiometricsPrompt" | i18n }}</label>
<input
id="autoBiometricsPrompt"
type="checkbox"
(change)="updateAutoBiometricsPrompt()"
[disabled]="!biometric"
[(ngModel)]="disableAutoBiometricsPrompt"
[(ngModel)]="enableAutoBiometricsPrompt"
/>
</div>
<button

View File

@ -46,7 +46,7 @@ export class SettingsComponent implements OnInit {
pin: boolean = null;
supportsBiometric: boolean;
biometric = false;
disableAutoBiometricsPrompt = true;
enableAutoBiometricsPrompt = true;
previousVaultTimeout: number = null;
showChangeMasterPass = true;
@ -114,8 +114,9 @@ export class SettingsComponent implements OnInit {
this.supportsBiometric = await this.platformUtilsService.supportsBiometric();
this.biometric = await this.vaultTimeoutService.isBiometricLockSet();
this.disableAutoBiometricsPrompt =
const disableAutoBiometricsPrompt =
(await this.stateService.getDisableAutoBiometricsPrompt()) ?? true;
this.enableAutoBiometricsPrompt = !disableAutoBiometricsPrompt;
this.showChangeMasterPass = !(await this.keyConnectorService.getUsesKeyConnector());
}
@ -289,7 +290,7 @@ export class SettingsComponent implements OnInit {
}
async updateAutoBiometricsPrompt() {
await this.stateService.setDisableAutoBiometricsPrompt(this.disableAutoBiometricsPrompt);
await this.stateService.setDisableAutoBiometricsPrompt(!this.enableAutoBiometricsPrompt);
}
async lock() {

View File

@ -118,8 +118,8 @@ export default class AutofillService implements AutofillServiceInterface {
return;
}
totpPromise = this.totpService.isAutoCopyEnabled().then((enabled) => {
if (enabled) {
totpPromise = this.stateService.getDisableAutoTotpCopy().then((disabled) => {
if (!disabled) {
return this.totpService.getCode(options.cipher.login.totp);
}
return null;

View File

@ -293,11 +293,7 @@ export class Main {
this.stateService
);
this.totpService = new TotpService(
this.cryptoFunctionService,
this.logService,
this.stateService
);
this.totpService = new TotpService(this.cryptoFunctionService, this.logService);
this.importService = new ImportService(
this.cipherService,

View File

@ -96,16 +96,16 @@
</div>
<div class="form-group" *ngIf="supportsBiometric">
<div class="checkbox">
<label for="noAutoPromptBiometrics">
<label for="autoPromptBiometrics">
<input
id="noAutoPromptBiometrics"
id="autoPromptBiometrics"
type="checkbox"
name="noAutoPromptBiometrics"
[(ngModel)]="noAutoPromptBiometrics"
name="autoPromptBiometrics"
[(ngModel)]="autoPromptBiometrics"
[disabled]="!biometric"
(change)="updateNoAutoPromptBiometrics()"
(change)="updateAutoPromptBiometrics()"
/>
{{ noAutoPromptBiometricsText | i18n }}
{{ autoPromptBiometricsText | i18n }}
</label>
</div>
</div>
@ -166,18 +166,18 @@
</div>
<div class="form-group">
<div class="checkbox">
<label for="disableFavicons">
<label for="enableFavicons">
<input
id="disableFavicons"
id="enableFavicons"
type="checkbox"
name="DisableFavicons"
[(ngModel)]="disableFavicons"
name="enableFavicons"
[(ngModel)]="enableFavicons"
(change)="saveFavicons()"
/>
{{ "disableFavicon" | i18n }}
{{ "enableFavicon" | i18n }}
</label>
</div>
<small class="help-block">{{ "disableFaviconDesc" | i18n }}</small>
<small class="help-block">{{ "faviconDesc" | i18n }}</small>
</div>
</ng-container>
</div>

View File

@ -24,7 +24,7 @@ import { SetPinComponent } from "../components/set-pin.component";
export class SettingsComponent implements OnInit {
vaultTimeoutAction: string;
pin: boolean = null;
disableFavicons = false;
enableFavicons = false;
enableBrowserIntegration = false;
enableBrowserIntegrationFingerprint = false;
enableMinToTray = false;
@ -43,8 +43,8 @@ export class SettingsComponent implements OnInit {
supportsBiometric: boolean;
biometric: boolean;
biometricText: string;
noAutoPromptBiometrics: boolean;
noAutoPromptBiometricsText: string;
autoPromptBiometrics: boolean;
autoPromptBiometricsText: string;
alwaysShowDock: boolean;
showAlwaysShowDock = false;
openAtLogin: boolean;
@ -179,7 +179,7 @@ export class SettingsComponent implements OnInit {
this.pin = pinSet[0] || pinSet[1];
// Account preferences
this.disableFavicons = await this.stateService.getDisableFavicon();
this.enableFavicons = !(await this.stateService.getDisableFavicon());
this.enableBrowserIntegration = await this.stateService.getEnableBrowserIntegration();
this.enableBrowserIntegrationFingerprint =
await this.stateService.getEnableBrowserIntegrationFingerprint();
@ -188,8 +188,8 @@ export class SettingsComponent implements OnInit {
this.supportsBiometric = await this.platformUtilsService.supportsBiometric();
this.biometric = await this.vaultTimeoutService.isBiometricLockSet();
this.biometricText = await this.stateService.getBiometricText();
this.noAutoPromptBiometrics = await this.stateService.getNoAutoPromptBiometrics();
this.noAutoPromptBiometricsText = await this.stateService.getNoAutoPromptBiometricsText();
this.autoPromptBiometrics = !(await this.stateService.getNoAutoPromptBiometrics());
this.autoPromptBiometricsText = await this.stateService.getNoAutoPromptBiometricsText();
}
async saveVaultTimeoutOptions() {
@ -259,27 +259,27 @@ export class SettingsComponent implements OnInit {
} else {
await this.stateService.setBiometricUnlock(null);
await this.stateService.setNoAutoPromptBiometrics(null);
this.noAutoPromptBiometrics = false;
this.autoPromptBiometrics = false;
}
await this.stateService.setBiometricLocked(false);
await this.cryptoService.toggleKey();
}
async updateNoAutoPromptBiometrics() {
async updateAutoPromptBiometrics() {
if (!this.biometric) {
this.noAutoPromptBiometrics = false;
this.autoPromptBiometrics = false;
}
if (this.noAutoPromptBiometrics) {
await this.stateService.setNoAutoPromptBiometrics(true);
} else {
if (this.autoPromptBiometrics) {
await this.stateService.setNoAutoPromptBiometrics(null);
} else {
await this.stateService.setNoAutoPromptBiometrics(true);
}
}
async saveFavicons() {
await this.stateService.setDisableFavicon(this.disableFavicons);
await this.stateService.setDisableFavicon(this.disableFavicons, {
await this.stateService.setDisableFavicon(!this.enableFavicons);
await this.stateService.setDisableFavicon(!this.enableFavicons, {
storageLocation: StorageLocation.Disk,
});
this.messagingService.send("refreshCiphers");

View File

@ -126,7 +126,7 @@
"message": "Minimize when copying to clipboard"
},
"minimizeOnCopyToClipboardDesc": {
"message": "Minimize when copying an item's data to the clipboard."
"message": "Minimize application when copying an item's data to the clipboard."
},
"toggleVisibility": {
"message": "Toggle Visibility"
@ -728,7 +728,7 @@
"message": "Are you sure you want to log out?"
},
"logOut": {
"message": "Log Out"
"message": "Log out"
},
"addNewLogin": {
"message": "Add New Login"
@ -830,10 +830,10 @@
"message": "Two-step Login"
},
"vaultTimeout": {
"message": "Vault Timeout"
"message": "Vault timeout"
},
"vaultTimeoutDesc": {
"message": "Choose when your vault will timeout and perform the selected action."
"message": "Choose when your vault will take the vault timeout action."
},
"immediately": {
"message": "Immediately"
@ -869,16 +869,16 @@
"message": "4 hours"
},
"onIdle": {
"message": "On System Idle"
"message": "On system idle"
},
"onSleep": {
"message": "On System Sleep"
"message": "On system sleep"
},
"onLocked": {
"message": "On System Lock"
"message": "On system lock"
},
"onRestart": {
"message": "On Restart"
"message": "On restart"
},
"never": {
"message": "Never"
@ -887,21 +887,21 @@
"message": "Security"
},
"clearClipboard": {
"message": "Clear Clipboard",
"message": "Clear clipboard",
"description": "Clipboard is the operating system thing where you copy/paste data to on your device."
},
"clearClipboardDesc": {
"message": "Automatically clear copied values from your clipboard.",
"description": "Clipboard is the operating system thing where you copy/paste data to on your device."
},
"disableFavicon": {
"message": "Disable Website Icons"
"enableFavicon": {
"message": "Show website icons"
},
"disableFaviconDesc": {
"message": "Website Icons provide a recognizable image next to each login item in your vault."
"faviconDesc": {
"message": "Show a recognizable image next to each login."
},
"enableMinToTray": {
"message": "Minimize to Tray Icon"
"message": "Minimize to tray icon"
},
"enableMinToTrayDesc": {
"message": "When minimizing the window, show an icon in the system tray instead."
@ -913,7 +913,7 @@
"message": "When minimizing the window, show an icon in the menu bar instead."
},
"enableCloseToTray": {
"message": "Close to Tray Icon"
"message": "Close to tray icon"
},
"enableCloseToTrayDesc": {
"message": "When closing the window, show an icon in the system tray instead."
@ -925,13 +925,13 @@
"message": "When closing the window, show an icon in the menu bar instead."
},
"enableTray": {
"message": "Enable Tray Icon"
"message": "Enable tray icon"
},
"enableTrayDesc": {
"message": "Always show an icon in the system tray."
},
"startToTray": {
"message": "Start To Tray Icon"
"message": "Start To tray icon"
},
"startToTrayDesc": {
"message": "When the application is first started, only show an icon in the system tray."
@ -946,7 +946,7 @@
"message": "Start automatically on login"
},
"openAtLoginDesc": {
"message": "Start the Bitwarden Desktop application automatically on login."
"message": "Start the Bitwarden desktop application automatically on login."
},
"alwaysShowDock": {
"message": "Always show in the Dock"
@ -1381,11 +1381,11 @@
"touchIdConsentMessage": {
"message": "unlock your vault"
},
"noAutoPromptWindowsHello": {
"message": "Do not prompt for Windows Hello on launch."
"autoPromptWindowsHello": {
"message": "Ask for Windows Hello on launch"
},
"noAutoPromptTouchId": {
"message": "Do not prompt for Touch ID on launch."
"autoPromptTouchId": {
"message": "Ask for Touch ID on launch"
},
"lockWithMasterPassOnRestart": {
"message": "Lock with master password on restart"
@ -1394,7 +1394,7 @@
"message": "Preferences"
},
"enableMenuBar": {
"message": "Enable Menu Bar Icon"
"message": "Show menu bar icon"
},
"enableMenuBarDesc": {
"message": "Always show an icon in the menu bar."
@ -1437,13 +1437,13 @@
"message": "One or more organization policies are affecting your generator settings."
},
"vaultTimeoutAction": {
"message": "Vault Timeout Action"
"message": "Vault timeout action"
},
"vaultTimeoutActionLockDesc": {
"message": "A locked vault requires that you re-enter your master password to access it again."
"message": "Master password or other unlock method is required to access your vault again."
},
"vaultTimeoutActionLogOutDesc": {
"message": "A logged out vault requires that you re-authenticate to access it again."
"message": "Re-authentication is required to access your vault again."
},
"lock": {
"message": "Lock",
@ -1547,7 +1547,7 @@
"message": "Terms of Service and Privacy Policy have not been acknowledged."
},
"enableBrowserIntegration": {
"message": "Enable browser integration"
"message": "Allow browser integration"
},
"enableBrowserIntegrationDesc": {
"message": "Browser integration is used for biometrics in browser."
@ -1568,7 +1568,7 @@
"message": "Require verification for browser integration"
},
"enableBrowserIntegrationFingerprintDesc": {
"message": "Enable an additional layer of security by requiring fingerprint phrase validation when establishing a link between your desktop and browser. When enabled, this requires user intervention and verification each time a connection is established."
"message": "Add an additional layer of security by requiring fingerprint phrase confirmation when establishing a link between your desktop and browser. This requires user action and verification each time a connection is created."
},
"approve": {
"message": "Approve"

View File

@ -13,7 +13,7 @@ export default class BiometricDarwinMain implements BiometricMain {
async init() {
await this.stateService.setEnableBiometric(await this.supportsBiometric());
await this.stateService.setBiometricText("unlockWithTouchId");
await this.stateService.setNoAutoPromptBiometricsText("noAutoPromptTouchId");
await this.stateService.setNoAutoPromptBiometricsText("autoPromptTouchId");
// eslint-disable-next-line
ipcMain.on("biometric", async (event: any, message: any) => {

View File

@ -31,7 +31,7 @@ export default class BiometricWindowsMain implements BiometricMain {
}
await this.stateService.setEnableBiometric(supportsBiometric);
await this.stateService.setBiometricText("unlockWithWindowsHello");
await this.stateService.setNoAutoPromptBiometricsText("noAutoPromptWindowsHello");
await this.stateService.setNoAutoPromptBiometricsText("autoPromptWindowsHello");
ipcMain.on("biometric", async (event: any, message: any) => {
event.returnValue = await this.authenticateBiometric();

View File

@ -72,12 +72,12 @@
<input
class="form-check-input"
type="checkbox"
id="disableIcons"
name="DisableIcons"
[(ngModel)]="disableIcons"
id="enableFavicons"
name="enableFavicons"
[(ngModel)]="enableFavicons"
/>
<label class="form-check-label" for="disableIcons">
{{ "disableIcons" | i18n }}
<label class="form-check-label" for="enableFavicons">
{{ "enableFavicon" | i18n }}
</label>
<a
href="https://bitwarden.com/help/website-icons/"
@ -88,7 +88,7 @@
<i class="bwi bwi-question-circle" aria-hidden="true"></i>
</a>
</div>
<small class="form-text text-muted">{{ "disableIconsDesc" | i18n }}</small>
<small class="form-text text-muted">{{ "faviconDesc" | i18n }}</small>
</div>
<div class="form-group">
<div class="form-check">

View File

@ -15,7 +15,7 @@ import { Utils } from "@bitwarden/common/misc/utils";
})
export class PreferencesComponent implements OnInit {
vaultTimeoutAction = "lock";
disableIcons: boolean;
enableFavicons: boolean;
enableGravatars: boolean;
enableFullWidth: boolean;
theme: ThemeType;
@ -70,7 +70,7 @@ export class PreferencesComponent implements OnInit {
async ngOnInit() {
this.vaultTimeout.setValue(await this.vaultTimeoutService.getVaultTimeout());
this.vaultTimeoutAction = await this.stateService.getVaultTimeoutAction();
this.disableIcons = await this.stateService.getDisableFavicon();
this.enableFavicons = !(await this.stateService.getDisableFavicon());
this.enableGravatars = await this.stateService.getEnableGravitars();
this.enableFullWidth = await this.stateService.getEnableFullWidth();
@ -95,7 +95,7 @@ export class PreferencesComponent implements OnInit {
this.vaultTimeout.value,
this.vaultTimeoutAction
);
await this.stateService.setDisableFavicon(this.disableIcons);
await this.stateService.setDisableFavicon(!this.enableFavicons);
await this.stateService.setEnableGravitars(this.enableGravatars);
await this.stateService.setEnableFullWidth(this.enableFullWidth);
this.messagingService.send("setFullWidth");

View File

@ -555,7 +555,7 @@
"message": "Are you sure you want to log out?"
},
"logOut": {
"message": "Log Out"
"message": "Log out"
},
"ok": {
"message": "Ok"
@ -1151,21 +1151,21 @@
"languageDesc": {
"message": "Change the language used by the web vault."
},
"disableIcons": {
"message": "Disable Website Icons"
"enableFavicon": {
"message": "Show website icons"
},
"disableIconsDesc": {
"message": "Website Icons provide a recognizable image next to each login item in your vault."
"faviconDesc": {
"message": "Show a recognizable image next to each login."
},
"enableGravatars": {
"message": "Enable Gravatars",
"description": "'Gravatar' is the name of a service. See www.gravatar.com"
"message": "Show Gravatars",
"description": "Use avatar images loaded from gravatar.com."
},
"enableGravatarsDesc": {
"message": "Use avatar images loaded from gravatar.com."
},
"enableFullWidth": {
"message": "Enable Full Width Layout",
"message": "Display full width layout",
"description": "Allows scaling the web vault UI's width"
},
"enableFullWidthDesc": {
@ -3172,10 +3172,10 @@
"message": "Filters"
},
"vaultTimeout": {
"message": "Vault Timeout"
"message": "Vault timeout"
},
"vaultTimeoutDesc": {
"message": "Choose when your vault will timeout and perform the selected action."
"message": "Choose when your vault will take the vault timeout action."
},
"oneMinute": {
"message": "1 minute"
@ -3196,7 +3196,7 @@
"message": "4 hours"
},
"onRefresh": {
"message": "On Browser Refresh"
"message": "On browser refresh"
},
"dateUpdated": {
"message": "Updated",
@ -3403,13 +3403,13 @@
"message": "User Preference"
},
"vaultTimeoutAction": {
"message": "Vault Timeout Action"
"message": "Vault timeout action"
},
"vaultTimeoutActionLockDesc": {
"message": "A locked vault requires that you re-enter your master password to access it again."
"message": "Master password or other unlock method is required to access your vault again."
},
"vaultTimeoutActionLogOutDesc": {
"message": "A logged out vault requires that you re-authenticate to access it again."
"message": "Re-authentication is required to access your vault again."
},
"lock": {
"message": "Lock",

View File

@ -1,5 +1,4 @@
export abstract class TotpService {
getCode: (key: string) => Promise<string>;
getTimeInterval: (key: string) => number;
isAutoCopyEnabled: () => Promise<boolean>;
}

View File

@ -1,6 +1,5 @@
import { CryptoFunctionService } from "../abstractions/cryptoFunction.service";
import { LogService } from "../abstractions/log.service";
import { StateService } from "../abstractions/state.service";
import { TotpService as TotpServiceAbstraction } from "../abstractions/totp.service";
import { Utils } from "../misc/utils";
@ -10,8 +9,7 @@ const SteamChars = "23456789BCDFGHJKMNPQRTVWXY";
export class TotpService implements TotpServiceAbstraction {
constructor(
private cryptoFunctionService: CryptoFunctionService,
private logService: LogService,
private stateService: StateService
private logService: LogService
) {}
async getCode(key: string): Promise<string> {
@ -113,10 +111,6 @@ export class TotpService implements TotpServiceAbstraction {
return period;
}
async isAutoCopyEnabled(): Promise<boolean> {
return !(await this.stateService.getDisableAutoTotpCopy());
}
// Helpers
private leftPad(s: string, l: number, p: string): string {