Auto submit passcode form
This commit is contained in:
@@ -512,9 +512,12 @@ class AccountMenu {
|
||||
$scope.formData.showPasscodeForm = false;
|
||||
var offline = authManager.offline();
|
||||
|
||||
var message = "You've succesfully set an app passcode.";
|
||||
if(offline) { message += " Your items will now be encrypted using this passcode."; }
|
||||
alert(message);
|
||||
// Allow UI to update before showing alert
|
||||
setTimeout(function () {
|
||||
var message = "You've succesfully set an app passcode.";
|
||||
if(offline) { message += " Your items will now be encrypted using this passcode."; }
|
||||
alert(message);
|
||||
}, 10);
|
||||
|
||||
if(offline) {
|
||||
syncManager.markAllItemsDirtyAndSaveOffline();
|
||||
|
||||
@@ -124,11 +124,11 @@
|
||||
%p Add an app passcode to lock the app and encrypt on-device key storage.
|
||||
%a.block.mt-5{"ng-click" => "addPasscodeClicked()", "ng-if" => "!formData.showPasscodeForm"} Add Passcode
|
||||
|
||||
.mt-5{"ng-if" => "formData.showPasscodeForm"}
|
||||
%form.mt-5{"ng-if" => "formData.showPasscodeForm", "ng-submit" => "submitPasscodeForm()"}
|
||||
%p.bold Choose a passcode:
|
||||
%input.form-control.mt-10{:type => 'password', "ng-model" => "formData.passcode", "placeholder" => "Passcode", "autofocus" => "true"}
|
||||
%input.form-control.mt-10{:type => 'password', "ng-model" => "formData.confirmPasscode", "placeholder" => "Confirm Passcode"}
|
||||
%button.standard.ui-button.block.tinted.mt-5{"ng-click" => "submitPasscodeForm()"} Set Passcode
|
||||
%button.standard.ui-button.block.tinted.mt-5{"type" => "submit"} Set Passcode
|
||||
%div{"ng-if" => "hasPasscode()"}
|
||||
%p
|
||||
Passcode lock is enabled.
|
||||
|
||||
Reference in New Issue
Block a user