Updates
This commit is contained in:
@@ -95,6 +95,9 @@ module.exports = function(grunt) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
css: {
|
css: {
|
||||||
|
options: {
|
||||||
|
separator: '',
|
||||||
|
},
|
||||||
src: [
|
src: [
|
||||||
'vendor/assets/stylesheets/app.css',
|
'vendor/assets/stylesheets/app.css',
|
||||||
'node_modules/sn-stylekit/dist/stylekit.css'
|
'node_modules/sn-stylekit/dist/stylekit.css'
|
||||||
|
|||||||
@@ -45,27 +45,18 @@ angular.module('app.frontend')
|
|||||||
this.showAccountMenu = false;
|
this.showAccountMenu = false;
|
||||||
}.bind(this)
|
}.bind(this)
|
||||||
|
|
||||||
|
this.closeAccountMenu = () => {
|
||||||
|
this.showAccountMenu = false;
|
||||||
|
}
|
||||||
|
|
||||||
this.accountMenuPressed = function() {
|
this.accountMenuPressed = function() {
|
||||||
this.serverData = {};
|
|
||||||
this.showAccountMenu = !this.showAccountMenu;
|
this.showAccountMenu = !this.showAccountMenu;
|
||||||
this.showFaq = false;
|
|
||||||
this.showNewPasswordForm = false;
|
|
||||||
this.showExtensionsMenu = false;
|
|
||||||
this.showIOMenu = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this.toggleExtensions = function() {
|
this.toggleExtensions = function() {
|
||||||
this.showAccountMenu = false;
|
|
||||||
this.showIOMenu = false;
|
|
||||||
this.showExtensionsMenu = !this.showExtensionsMenu;
|
this.showExtensionsMenu = !this.showExtensionsMenu;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.toggleIO = function() {
|
|
||||||
this.showIOMenu = !this.showIOMenu;
|
|
||||||
this.showExtensionsMenu = false;
|
|
||||||
this.showAccountMenu = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.hasPasscode = function() {
|
this.hasPasscode = function() {
|
||||||
return passcodeManager.hasPasscode();
|
return passcodeManager.hasPasscode();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -64,9 +64,9 @@ angular.module('app.frontend')
|
|||||||
|
|
||||||
syncManager.sync(null);
|
syncManager.sync(null);
|
||||||
// refresh every 30s
|
// refresh every 30s
|
||||||
// setInterval(function () {
|
setInterval(function () {
|
||||||
// syncManager.sync(null);
|
syncManager.sync(null);
|
||||||
// }, 30000);
|
}, 30000);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,8 @@ class AccountMenu {
|
|||||||
this.restrict = "E";
|
this.restrict = "E";
|
||||||
this.templateUrl = "frontend/directives/account-menu.html";
|
this.templateUrl = "frontend/directives/account-menu.html";
|
||||||
this.scope = {
|
this.scope = {
|
||||||
"onSuccessfulAuth" : "&"
|
"onSuccessfulAuth" : "&",
|
||||||
|
"closeFunction" : "&"
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -15,28 +16,15 @@ class AccountMenu {
|
|||||||
$scope.user = authManager.user;
|
$scope.user = authManager.user;
|
||||||
$scope.server = syncManager.serverURL;
|
$scope.server = syncManager.serverURL;
|
||||||
|
|
||||||
|
$scope.close = function() {
|
||||||
|
$scope.closeFunction()();
|
||||||
|
}
|
||||||
|
|
||||||
$scope.encryptedBackupsAvailable = function() {
|
$scope.encryptedBackupsAvailable = function() {
|
||||||
return authManager.user || passcodeManager.hasPasscode();
|
return authManager.user || passcodeManager.hasPasscode();
|
||||||
}
|
}
|
||||||
|
|
||||||
$scope.syncStatus = syncManager.syncStatus;
|
$scope.syncStatus = syncManager.syncStatus;
|
||||||
|
|
||||||
$scope.encryptionKey = function() {
|
|
||||||
return authManager.keys().mk;
|
|
||||||
}
|
|
||||||
|
|
||||||
$scope.authKey = function() {
|
|
||||||
return authManager.keys().ak;
|
|
||||||
}
|
|
||||||
|
|
||||||
$scope.serverPassword = function() {
|
|
||||||
return syncManager.serverPassword;
|
|
||||||
}
|
|
||||||
|
|
||||||
$scope.dashboardURL = function() {
|
|
||||||
return `${$scope.server}/dashboard/#server=${$scope.server}&id=${encodeURIComponent($scope.user.email)}&pw=${$scope.serverPassword()}`;
|
|
||||||
}
|
|
||||||
|
|
||||||
$scope.newPasswordData = {};
|
$scope.newPasswordData = {};
|
||||||
|
|
||||||
$scope.showPasswordChangeForm = function() {
|
$scope.showPasswordChangeForm = function() {
|
||||||
|
|||||||
@@ -21,10 +21,6 @@ class SyncManager {
|
|||||||
return this.storageManager.getItem("mk");
|
return this.storageManager.getItem("mk");
|
||||||
}
|
}
|
||||||
|
|
||||||
get serverPassword() {
|
|
||||||
return this.storageManager.getItem("pw");
|
|
||||||
}
|
|
||||||
|
|
||||||
writeItemsToLocalStorage(items, offlineOnly, callback) {
|
writeItemsToLocalStorage(items, offlineOnly, callback) {
|
||||||
if(items.length == 0) {
|
if(items.length == 0) {
|
||||||
callback && callback();
|
callback && callback();
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
.panel#account-panel
|
.panel#account-panel
|
||||||
.header
|
.header
|
||||||
%h1.title Account
|
%h1.title Account
|
||||||
%a.close-button Close
|
%a.close-button{"ng-click" => "close()"} Close
|
||||||
.content
|
.content
|
||||||
|
|
||||||
.panel-section.hero{"ng-if" => "!user && !formData.showLogin && !formData.showRegister && !formData.mfa"}
|
.panel-section.hero{"ng-if" => "!user && !formData.showLogin && !formData.showRegister && !formData.mfa"}
|
||||||
@@ -67,8 +67,9 @@
|
|||||||
|
|
||||||
.subtitle.danger.panel-row{"ng-if" => "syncStatus.error"} Error syncing: {{syncStatus.error.message}}
|
.subtitle.danger.panel-row{"ng-if" => "syncStatus.error"} Error syncing: {{syncStatus.error.message}}
|
||||||
|
|
||||||
.subtitle.subtle.panel-row {{server}}
|
.subtitle.subtle.normal {{server}}
|
||||||
|
|
||||||
|
.panel-row
|
||||||
|
|
||||||
%a.panel-row.condensed{"ng-click" => "newPasswordData.changePassword = !newPasswordData.changePassword"} Change Password
|
%a.panel-row.condensed{"ng-click" => "newPasswordData.changePassword = !newPasswordData.changePassword"} Change Password
|
||||||
.notification.default{"ng-if" => "newPasswordData.changePassword"}
|
.notification.default{"ng-if" => "newPasswordData.changePassword"}
|
||||||
@@ -94,8 +95,7 @@
|
|||||||
|
|
||||||
%a.panel-row.condensed{"ng-click" => "showAdvanced = !showAdvanced"} Advanced
|
%a.panel-row.condensed{"ng-click" => "showAdvanced = !showAdvanced"} Advanced
|
||||||
%div{"ng-if" => "showAdvanced"}
|
%div{"ng-if" => "showAdvanced"}
|
||||||
%a.panel-row{"href" => "{{dashboardURL()}}", "target" => "_blank"} Data Dashboard
|
%a.panel-row{"ng-click" => "reencryptPressed()"} Resync All Items
|
||||||
%a.panel-row{"ng-click" => "reencryptPressed()"} Re-encrypt All Items
|
|
||||||
|
|
||||||
|
|
||||||
%div{"ng-if" => "securityUpdateAvailable()"}
|
%div{"ng-if" => "securityUpdateAvailable()"}
|
||||||
|
|||||||
@@ -3,10 +3,10 @@
|
|||||||
.left
|
.left
|
||||||
.item{"click-outside" => "ctrl.showAccountMenu = false;", "is-open" => "ctrl.showAccountMenu"}
|
.item{"click-outside" => "ctrl.showAccountMenu = false;", "is-open" => "ctrl.showAccountMenu"}
|
||||||
.column
|
.column
|
||||||
.circle.small.info
|
.circle.small{"ng-class" => "ctrl.error ? 'danger' : (ctrl.user ? 'info' : 'default')"}
|
||||||
.column{"ng-click" => "ctrl.accountMenuPressed()"}
|
.column{"ng-click" => "ctrl.accountMenuPressed()"}
|
||||||
.label.title{"ng-class" => "{red: ctrl.error}"} Account
|
.label.title{"ng-class" => "{red: ctrl.error}"} Account
|
||||||
%account-menu{"ng-if" => "ctrl.showAccountMenu", "on-successful-auth" => "ctrl.onAuthSuccess"}
|
%account-menu{"ng-if" => "ctrl.showAccountMenu", "on-successful-auth" => "ctrl.onAuthSuccess", "close-function" => "ctrl.closeAccountMenu"}
|
||||||
|
|
||||||
.item{"click-outside" => "ctrl.showExtensionsMenu = false;", "is-open" => "ctrl.showExtensionsMenu"}
|
.item{"click-outside" => "ctrl.showExtensionsMenu = false;", "is-open" => "ctrl.showExtensionsMenu"}
|
||||||
.column{"ng-click" => "ctrl.toggleExtensions()"}
|
.column{"ng-click" => "ctrl.toggleExtensions()"}
|
||||||
|
|||||||
Reference in New Issue
Block a user