Distinguish between locked and protected notes

This commit is contained in:
Mo Bitar
2018-12-13 13:03:25 -06:00
parent bc634ca7da
commit 0e4a6d718b
14 changed files with 59 additions and 23 deletions

View File

@@ -24,8 +24,8 @@
%input{"type" => "checkbox", "ng-disabled" => "!credentialDisplayInfo[credential].availability", "ng-checked" => "isCredentialRequiredForAction(action, credential)", "ng-click" => "checkboxValueChanged(action, credential)"}
.sk-panel-section{"ng-if" => "sessionExpirey && !sessionExpired"}
.sk-p You will not be asked to authenticate until {{sessionExpirey}}.
%a.sk-a {"ng-click" => "clearSession()"} Clear Session
.sk-p.sk-panel-row You will not be asked to authenticate until {{sessionExpirey}}.
%a.sk-a.sk-panel-row.info{"ng-click" => "clearSession()"} Clear Session
.sk-panel-footer
.sk-h2 About Privileges
.sk-panel-section.no-bottom-pad

View File

@@ -34,6 +34,7 @@
%menu-row{"label" => "ctrl.note.pinned ? 'Unpin' : 'Pin'", "action" => "ctrl.selectedMenuItem(true); ctrl.togglePin()", "desc" => "'Pin or unpin a note from the top of your list'"}
%menu-row{"label" => "ctrl.note.archived ? 'Unarchive' : 'Archive'", "action" => "ctrl.selectedMenuItem(true); ctrl.toggleArchiveNote()", "desc" => "'Archive or unarchive a note from your Archived system tag'"}
%menu-row{"label" => "ctrl.note.locked ? 'Unlock' : 'Lock'", "action" => "ctrl.selectedMenuItem(true); ctrl.toggleLockNote()", "desc" => "'Locking notes prevents unintentional editing'"}
%menu-row{"label" => "ctrl.note.content.protected ? 'Unprotect' : 'Protect'", "action" => "ctrl.selectedMenuItem(true); ctrl.toggleProtectNote()", "desc" => "'Protecting a note will require credentials to view it (Manage Privileges via Account menu)'"}
%menu-row{"label" => "'Preview'", "circle" => "ctrl.note.content.hidePreview ? 'danger' : 'success'", "circle-align" => "'right'", "action" => "ctrl.selectedMenuItem(true); ctrl.toggleNotePreview()", "desc" => "'Hide or unhide the note preview from the list of notes'"}
%menu-row{"label" => "'Delete'", "action" => "ctrl.selectedMenuItem(); ctrl.deleteNote()", "desc" => "'Delete this note permanently from all your devices'"}

View File

@@ -50,11 +50,11 @@
%strong.red.medium-text{"ng-if" => "note.errorDecrypting"} Unable to Decrypt
.note-flags
.pinned{"ng-if" => "note.pinned"}
.pinned.note-flag{"ng-if" => "note.pinned"}
%i.icon.ion-bookmark
%strong.medium-text Pinned
.archived{"ng-if" => "note.archived && !ctrl.tag.isSmartTag()"}
.archived.note-flag{"ng-if" => "note.archived && !ctrl.tag.isSmartTag()"}
%i.icon.ion-ios-box
%strong.medium-text Archived
@@ -62,8 +62,10 @@
.faded {{note.savedTagsString || note.tagsString()}}
.name{"ng-if" => "note.title"}
%span.locked.tinted{"ng-if" => "note.locked", "ng-class" => "{'tinted-selected' : ctrl.selectedNote == note}"}
%span.note-flag{"ng-show" => "note.locked"}
%i.icon.ion-locked.medium-text
%span.note-flag{"ng-show" => "note.content.protected"}
%i.icon.ion-eye-disabled
{{note.title}}
.note-preview{"ng-if" => "!ctrl.hideNotePreview && !note.content.hidePreview && !note.locked"}