functional minimalism
This commit is contained in:
@@ -1,17 +0,0 @@
|
||||
.panel.panel-default.account-panel.panel-right.account-data-menu
|
||||
.panel-body
|
||||
|
||||
%section.gray-bg.medium-padding{"ng-init" => "showSN = true"}
|
||||
%account-new-account-section
|
||||
|
||||
%section.gray-bg.medium-padding
|
||||
%account-sync-section
|
||||
|
||||
%section.gray-bg.medium-padding
|
||||
%account-export-section
|
||||
|
||||
%section.gray-bg.medium-padding
|
||||
%account-keys-section
|
||||
|
||||
%h4
|
||||
%a{"ng-click" => "destroyLocalData()"} Destroy all local data
|
||||
@@ -0,0 +1,61 @@
|
||||
.panel.panel-default.panel-right.account-data-menu
|
||||
.panel-body
|
||||
|
||||
-# If not user
|
||||
%div{"ng-if" => "!user"}
|
||||
%p Enter your <a href="https://standardnotes.org" target="_blank">Standard File</a> account information. You can also register for free using the default server address.
|
||||
.small-v-space
|
||||
|
||||
%form.account-form.mt-5{'name' => "loginForm"}
|
||||
%input.form-control{:name => 'server', :placeholder => 'Server URL', :required => true, :type => 'text', 'ng-model' => 'formData.url'}
|
||||
%input.form-control{:autofocus => 'autofocus', :name => 'email', :placeholder => 'Email', :required => true, :type => 'email', 'ng-model' => 'formData.email'}
|
||||
%input.form-control{:placeholder => 'Password', :name => 'password', :required => true, :type => 'password', 'ng-model' => 'formData.user_password'}
|
||||
|
||||
%div{"ng-if" => "!formData.status"}
|
||||
%button.btn.dark-button.half-button{"ng-click" => "loginSubmitPressed()", "data-style" => "expand-right", "data-size" => "s", "state" => "buttonState"}
|
||||
%span Sign In
|
||||
%button.btn.dark-button.half-button{"ng-click" => "submitRegistrationForm()", "data-style" => "expand-right", "data-size" => "s", "state" => "buttonState"}
|
||||
%span Register
|
||||
%br
|
||||
.block{"style" => "margin-top: 10px; font-size: 14px; font-weight: bold; text-align: center;"}
|
||||
%a.btn{"ng-click" => "showResetForm = !showResetForm"} Passwords cannot be forgotten.
|
||||
|
||||
%em.block.center-align.mt-10{"ng-if" => "formData.status", "style" => "font-size: 14px;"} {{formData.status}}
|
||||
|
||||
%div{"ng-if" => "showResetForm"}
|
||||
%p{"style" => "font-size: 13px; text-align: center;"}
|
||||
Because notes are locally encrypted using a secret key derived from your password, there's no way to decrypt these notes if you forget your password.
|
||||
For this reason, Standard Notes cannot offer a password reset option. You <strong>must</strong> make sure to store or remember your password.
|
||||
-# End if not user
|
||||
|
||||
-# If user
|
||||
%div{"ng-if" => "user"}
|
||||
%label Local Encryption
|
||||
%p Notes are encrypted locally before being sent to the server. Neither the server owner nor an intrusive entity can decrypt your locally encrypted notes.
|
||||
%label Status:
|
||||
{{encryptionStatusForNotes()}}
|
||||
-# End if user
|
||||
|
||||
.mt-5{"ng-if" => "user"}
|
||||
%label{"ng-if" => "user"}
|
||||
%input{"type" => "radio", "ng-model" => "archiveFormData.encrypted", "ng-value" => "true", "ng-change" => "archiveFormData.encrypted = true"}
|
||||
Encrypted
|
||||
%label
|
||||
%input{"type" => "radio", "ng-model" => "archiveFormData.encrypted", "ng-value" => "false", "ng-change" => "archiveFormData.encrypted = false"}
|
||||
Decrypted
|
||||
%a{"ng-click" => "downloadDataArchive()"} Download Data Archive
|
||||
|
||||
%div{"ng-if" => "!importData.loading"}
|
||||
%label#import-archive
|
||||
%input{"type" => "file", "style" => "display: none;", "file-change" => "->", "handler" => "importFileSelected(files)"}
|
||||
%a.disabled
|
||||
%span
|
||||
Import Data from Archive
|
||||
%div{"ng-if" => "importData.requestPassword"}
|
||||
Enter the account password associated with the import file.
|
||||
%input{"type" => "text", "ng-model" => "importData.password"}
|
||||
%button{"ng-click" => "submitImportPassword()"} Decrypt & Import
|
||||
|
||||
.spinner{"ng-if" => "importData.loading"}
|
||||
|
||||
%a{"ng-click" => "destroyLocalData()"} Destroy all local data
|
||||
@@ -1,31 +0,0 @@
|
||||
%h3{"ng-click" => "showSection = !showSection"}
|
||||
%a Import or export data
|
||||
|
||||
%div{"ng-if" => "showSection"}
|
||||
.options{"style" => "font-size: 12px; margin-top: 4px;"}
|
||||
%label{"ng-if" => "user"}
|
||||
%input{"type" => "radio", "ng-model" => "archiveFormData.encryption_type", "ng-value" => "'mk'", "ng-change" => "archiveFormData.encryption_type = 'mk'"}
|
||||
Encrypted with Standard File key
|
||||
%label
|
||||
%input{"type" => "radio", "ng-model" => "archiveFormData.encryption_type", "ng-value" => "'ek'", "ng-change" => "archiveFormData.encryption_type = 'ek'"}
|
||||
{{user ? 'Encrypted with custom key' : 'Encrypted' }}
|
||||
%div{"ng-if" => "!user || (user && archiveFormData.encryption_type == 'ek')"}
|
||||
%input{"ng-model" => "archiveFormData.ek", "placeholder" => "Encryption key"}
|
||||
%label
|
||||
%input{"type" => "radio", "ng-model" => "archiveFormData.encryption_type", "ng-value" => "'none'", "ng-change" => "archiveFormData.encryption_type = 'none'"}
|
||||
Decrypted
|
||||
|
||||
%a{"ng-click" => "downloadDataArchive()"} Download Data Archive
|
||||
|
||||
%div{"ng-if" => "!importData.loading"}
|
||||
%label#import-archive
|
||||
%input{"type" => "file", "style" => "display: none;", "file-change" => "->", "handler" => "importFileSelected(files)"}
|
||||
%a.disabled
|
||||
%span
|
||||
Import Data from Archive
|
||||
%div{"ng-if" => "importData.requestPassword"}
|
||||
Enter the account password associated with the import file.
|
||||
%input{"type" => "text", "ng-model" => "importData.password"}
|
||||
%button{"ng-click" => "submitImportPassword()"} Decrypt & Import
|
||||
|
||||
.spinner{"ng-if" => "importData.loading"}
|
||||
@@ -1,18 +0,0 @@
|
||||
%h3{"ng-click" => "showSection = !showSection"}
|
||||
%a Manage keys
|
||||
|
||||
%div{"ng-if" => "showSection"}
|
||||
%h4 Encryption Keys
|
||||
|
||||
%div{"ng-if" => "showSection"}
|
||||
%p Keys are used to encrypt and decrypt your data.
|
||||
.mt-10
|
||||
%section.white-bg{"ng-repeat" => "key in keys track by key.name"}
|
||||
%label {{key.name}}
|
||||
%p.wrap {{key.key}}
|
||||
|
||||
%a.block.mt-10{"ng-click" => "newKeyData.showForm = !newKeyData.showForm"} Add New Key
|
||||
%form{"ng-if" => "newKeyData.showForm"}
|
||||
%input{"ng-model" => "newKeyData.name", "placeholder" => "Name your key"}
|
||||
%input{"ng-model" => "newKeyData.key", "placeholder" => "Key"}
|
||||
%button.light{"ng-click" => "submitNewKeyForm()"} Add Key
|
||||
@@ -1,35 +0,0 @@
|
||||
%h3{"ng-click" => "showForm = !showForm"}
|
||||
%a Add a sync account
|
||||
%div{"ng-if" => "showForm"}
|
||||
%p Enter your <a href="https://standardnotes.org" target="_blank">Standard File</a> account information.
|
||||
.small-v-space
|
||||
|
||||
%form.account-form{'name' => "loginForm"}
|
||||
%input.form-control{:name => 'server', :placeholder => 'Server URL', :required => true, :type => 'text', 'ng-model' => 'formData.url'}
|
||||
%input.form-control{:autofocus => 'autofocus', :name => 'email', :placeholder => 'Email', :required => true, :type => 'email', 'ng-model' => 'formData.email'}
|
||||
%input.form-control{:placeholder => 'Password', :name => 'password', :required => true, :type => 'password', 'ng-model' => 'formData.user_password'}
|
||||
|
||||
%div{"ng-if" => "!formData.status"}
|
||||
%button.btn.dark-button.half-button{"ng-click" => "loginSubmitPressed()", "data-style" => "expand-right", "data-size" => "s", "state" => "buttonState"}
|
||||
%span Sign In
|
||||
%button.btn.dark-button.half-button{"ng-click" => "submitRegistrationForm()", "data-style" => "expand-right", "data-size" => "s", "state" => "buttonState"}
|
||||
%span Register
|
||||
%br
|
||||
.block{"style" => "margin-top: 10px; font-size: 14px; font-weight: bold; text-align: center;"}
|
||||
%a.btn{"ng-click" => "showResetForm = !showResetForm"} Passwords cannot be forgotten.
|
||||
|
||||
%div{"ng-if" => "!formData.status"}
|
||||
%label.center-align.block.faded — OR —
|
||||
%a.block.center-align.medium-text{"ng-if" => "!formData.showAddLinkForm", "ng-click" => "formData.showAddLinkForm = true"} Add sync using secret link
|
||||
%form{"ng-if" => "formData.showAddLinkForm"}
|
||||
%input.form-control{:autofocus => 'autofocus', :name => 'url', :placeholder => 'Secret URL', :required => true, :type => 'url', 'ng-model' => 'formData.secretUrl'}
|
||||
%button.btn.dark-button.btn-block{"ng-click" => "submitExternalSyncURL()"}
|
||||
Add Sync Account
|
||||
%a.block.center-align.mt-5{"ng-click" => "formData.showAddLinkForm = false"} Cancel
|
||||
|
||||
%em.block.center-align.mt-10{"ng-if" => "formData.status", "style" => "font-size: 14px;"} {{formData.status}}
|
||||
|
||||
%div{"ng-if" => "showResetForm"}
|
||||
%p{"style" => "font-size: 13px; text-align: center;"}
|
||||
Because notes are locally encrypted using a secret key derived from your password, there's no way to decrypt these notes if you forget your password.
|
||||
For this reason, Standard Notes cannot offer a password reset option. You <strong>must</strong> make sure to store or remember your password.
|
||||
@@ -1,30 +0,0 @@
|
||||
%h3{"ng-click" => "showSection = !showSection"}
|
||||
%a Your sync accounts ({{syncProviders.length}})
|
||||
|
||||
%div{"ng-if" => "showSection || syncManager.syncProviders.length > 0"}
|
||||
.small-v-space
|
||||
%section.white-bg.medium-padding{"ng-repeat" => "provider in syncProviders"}
|
||||
%label {{!provider.enabled ? 'Not enabled' : (provider.primary ? 'Main' : 'Secondary')}}
|
||||
%em{"ng-if" => "provider.keyName"} Using key: {{provider.keyName}}
|
||||
%p {{provider.url}}
|
||||
%section.inline-h
|
||||
%div{"ng-if" => "!provider.keyName || provider.showKeyForm"}
|
||||
%p
|
||||
%strong Choose encryption key:
|
||||
%select{"ng-model" => "provider.formData.keyName"}
|
||||
%option{"ng-repeat" => "key in keys", "ng-selected" => "{{key.name == provider.formData.keyName}}", "value" => "{{key.name}}"}
|
||||
{{key.name}}
|
||||
%button{"ng-click" => "saveKey(provider)"} Set
|
||||
|
||||
%button.light{"ng-if" => "!provider.enabled || !provider.primary", "ng-click" => "enableSyncProvider(provider, true)"} Set as Main
|
||||
%button.light{"ng-if" => "syncProviders.length > 1 && !provider.secondary && (!provider.primary || !provider.enabled)", "ng-click" => "enableSyncProvider(provider, false)"} Add as Secondary
|
||||
|
||||
%button.light{"ng-if" => "provider.keyName", "ng-click" => "changeEncryptionKey(provider)"} Change Encryption Key
|
||||
%button.light{"ng-click" => "removeSyncProvider(provider)"} Remove Account
|
||||
|
||||
.mt-15{"ng-if" => "provider.error"}
|
||||
%strong.red Error syncing: {{provider.error.message}}
|
||||
.mt-15{"style" => "height: 15px;", "delay-hide" => "true", "show" => "provider.syncOpInProgress", "delay" => "1000"}
|
||||
.spinner{"style" => "float: left; margin-top: 3px; margin-left: 2px;"}
|
||||
%strong{"style" => "float: left; margin-left: 7px;"} Syncing:
|
||||
{{provider.syncStatus.statusString}}
|
||||
@@ -2,7 +2,7 @@
|
||||
.pull-left
|
||||
.footer-bar-link
|
||||
%a{"ng-click" => "ctrl.accountMenuPressed()", "ng-class" => "{red: ctrl.error}"} Account
|
||||
%account-data-menu{"ng-if" => "ctrl.showAccountMenu"}
|
||||
%account-menu{"ng-if" => "ctrl.showAccountMenu"}
|
||||
|
||||
.footer-bar-link
|
||||
%a{"ng-click" => "ctrl.toggleExtensions()"} Extensions
|
||||
|
||||
Reference in New Issue
Block a user