1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-22 11:13:46 +00:00

Update UI

This commit is contained in:
Thomas Rittson
2021-04-07 10:45:12 +10:00
parent 4956cf9d8d
commit 89dd393c32
5 changed files with 52 additions and 15 deletions

View File

@@ -77,6 +77,21 @@
@include themify($themes) {
color: themed('mutedColor');
}
.sub-option {
margin-right: 5px;
margin-top: 10px;
display: flex;
justify-content: space-between;
select {
border: 1px solid #000000;
border-radius: $border-radius;
@include themify($themes) {
border-color: themed('boxBackgroundColor');
}
}
}
}
&.list {

View File

@@ -22,6 +22,13 @@
<div class="box-footer">
{{'enableAutoFillOnPageLoadDesc' | i18n}}
<b>{{'warning' | i18n}}</b>: {{'experimentalFeature' | i18n}}
<div class="sub-option">
<label for="defaultAutofill">{{'defaultAutoFillOnPageLoad' | i18n}}</label>
<select id="defaultAutofill" name="DefaultAutofill" [(ngModel)]="autoFillOnPageLoadDefault"
[disabled]="!enableAutoFillOnPageLoad">
<option *ngFor="let o of autoFillOnPageLoadOptions" [ngValue]="o.value">{{o.name}}</option>
</select>
</div>
</div>
</div>
<div class="box">

View File

@@ -23,6 +23,8 @@ import { ConstantsService } from 'jslib/services/constants.service';
export class OptionsComponent implements OnInit {
disableFavicon = false;
enableAutoFillOnPageLoad = false;
autoFillOnPageLoadDefault = false;
autoFillOnPageLoadOptions: any[];
disableAutoTotpCopy = false;
disableContextMenuItem = false;
disableAddLoginNotification = false;
@@ -64,6 +66,10 @@ export class OptionsComponent implements OnInit {
{ name: i18nService.t('twoMinutes'), value: 120 },
{ name: i18nService.t('fiveMinutes'), value: 300 },
];
this.autoFillOnPageLoadOptions = [
{ name: i18nService.t('globalAutoFillOnPageLoadAlways'), value: true },
{ name: i18nService.t('globalAutoFillOnPageLoadNever'), value: false },
]
}
async ngOnInit() {

View File

@@ -259,18 +259,15 @@
</a>
</div>
</div>
<div class="box">
<div class="box" *ngIf="cipher.type === cipherType.Login">
<div class="box-content">
<div class="box-content-row" appBoxRow>
<label for="autofillOnPageLoad">{{'enableAutoFillOnPageLoad' | i18n}} </label>
<label for="autofillOnPageLoad">{{'itemAutoFillOnPageLoad' | i18n}} </label>
<select id="autofillOnPageLoad" name="AutofillOnPageLoad" [(ngModel)]="cipher.login.autofillOnPageLoad">
<option *ngFor="let o of autofillOnPageLoadOptions" [ngValue]="o.value">{{o.name}}</option>
</select>
</div>
</div>
<div class="box-footer">
<b>{{'warning' | i18n}}</b>: {{'experimentalFeature' | i18n}}
</div>
</div>
<div class="box">
<div class="box-content">