settings.jade 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. extends ../layout
  2. block content
  3. include ../general/sidebar
  4. .content-with-navigation-sidebar
  5. .box
  6. .row-fluid
  7. .span12
  8. .page-header
  9. h1 Settings
  10. .messageArea
  11. .tabbable
  12. ul.nav.nav-tabs
  13. li.active
  14. a(href='#personalSettings', data-toggle="tab") Personal
  15. li
  16. a(href='#editorSettings', data-toggle="tab") Editor
  17. li
  18. a(href='#passwordReset', data-toggle="tab") Password
  19. li
  20. a(href='#newsletter', data-toggle="tab") Newsletter
  21. li
  22. a(href='#dropboxSettings', data-toggle="tab") Dropbox
  23. span.label.label-warning beta
  24. li
  25. a(href='#deleteAccount', data-toggle="tab") Delete Account
  26. form#userSettings.tab-content.form-horizontal
  27. input(type="hidden", name="_csrf", value=csrfToken)
  28. .tab-pane#personalSettings.active
  29. .control-group
  30. label(for='firstName').control-label First Name
  31. .controls
  32. input#firstName(type='text', name='first_name', value=user.first_name)
  33. .control-group
  34. label(for='lastName').control-label Last Name
  35. .controls
  36. input#lastName(type='text', name='last_name', value=user.last_name)
  37. .form-actions
  38. button.btn.btn-primary.large(type='submit') Update
  39. .tab-pane#dropboxSettings
  40. .alert.alert-info
  41. a(href='/help/kb/dropbox-2') Read how dropbox works
  42. - if(!userHasDropboxFeature)
  43. .alert.alert-info Dropbox sync is a premium feature    
  44. a.btn.btn-info(href='/user/subscription/plans') Upgrade
  45. - else if(userIsRegisteredWithDropbox)
  46. .alert.alert-success Account is linked!
  47. row
  48. a(href='/dropbox/unlink').btn Unlink Dropbox
  49. - else
  50. a.btn.btn-info(href='/dropbox/beginAuth') Link to dropbox
  51. .tab-pane#editorSettings
  52. .control-group
  53. label(for='theme').control-label Theme  
  54. a(href='/themes') (preview)
  55. .controls
  56. select(name='theme')#theme
  57. each theme in themes
  58. if(theme.name == user.ace.theme)
  59. option(value=theme.name, selected='selected')= theme.name
  60. else
  61. option(value=theme.name)= theme.name
  62. .control-group
  63. label(for='mode').control-label Key Binding
  64. .controls
  65. select(name='mode')#mode
  66. each mode in editors
  67. if(mode == user.ace.mode)
  68. option(value=mode, selected='selected')= mode
  69. else
  70. option(value=mode)= mode
  71. .control-group
  72. label(for='fontSize').control-label Font Size
  73. .controls
  74. select(name='fontSize')#fontSize
  75. each fontSize in fontSizes
  76. if(fontSize == user.ace.fontSize)
  77. option(value=fontSize, selected='selected')= fontSize
  78. else
  79. option(value=fontSize)= fontSize
  80. .control-group
  81. label(for='autoComplete').control-label
  82. | Auto complete
  83. .controls
  84. if (user.ace.autoComplete)
  85. label.radio.inline
  86. input(type='radio', name='autoComplete', value='true', checked)
  87. | On
  88. label.radio.inline
  89. input(type='radio', name='autoComplete', value='false')
  90. | Off
  91. else
  92. label.radio.inline
  93. input(type='radio', name='autoComplete', value='true')
  94. | On
  95. label.radio.inline
  96. input(type='radio', name='autoComplete', value='false', checked)
  97. | Off
  98. .control-group
  99. label(for='spellCheck').control-label
  100. | Default Spell check language
  101. .controls
  102. select(name="spellCheckLanguage")
  103. option(value="",selected=(user.ace.spellCheckLanguage == "")) Off
  104. optgroup(label="Language")
  105. for language in languages
  106. option(
  107. value=language.code,
  108. selected=(language.code == user.ace.spellCheckLanguage)
  109. )= language.name
  110. .control-group
  111. label(for="pdfViewer").control-label
  112. | PDF Viewer
  113. .controls
  114. if (user.ace.pdfViewer == "native")
  115. label.radio.inline
  116. input(type='radio', name='pdfViewer', value='native', checked)
  117. | Native (Best image quality)
  118. br
  119. label.radio.inline
  120. input(type='radio', name='pdfViewer', value='pdfjs')
  121. | Built in (Pdf page stays the same after recompile)
  122. else
  123. label.radio.inline
  124. input(type='radio', name='pdfViewer', value='native')
  125. | Native (Best image quality)
  126. br
  127. label.radio.inline
  128. input(type='radio', name='pdfViewer', value='pdfjs', checked)
  129. | Built in (Pdf page stays the same after recompile)
  130. .form-actions
  131. button.btn.btn-primary.large(type='submit') Update
  132. .tab-pane#passwordReset
  133. a#changePassword.btn Change Password
  134. .tab-pane#deleteAccount
  135. a#deleteUserAccount.btn.btn-danger(data-csrf=csrfToken) Delete your account
  136. .tab-pane#newsletter
  137. p Every few months we send a news letter out summarizing the new features available, if you would prefer to not receive this email then you are free to unsubscribe below at any time
  138. a#unsubscribeFromNewsletter.btn.btn-danger(data-csrf=csrfToken) Unsubscribe
  139. include ../general/small-footer
  140. #changePasswordModal(style='display: none')
  141. .modal
  142. form#changePasswordForm(method="post", action="/user/password/update")
  143. .modal-header
  144. h3 Change Password
  145. .modal-body
  146. input(type="hidden", name="_csrf", value=csrfToken)
  147. .clearfix
  148. label(for='xlinput.inputmodal') Current Password
  149. .input.inputmodal
  150. input.inputmodal.span5#currentPassword(type='password', name='currentPassword', placeholder='*********')
  151. .clearfix
  152. label(for='xlinput.inputmodal') New Password
  153. .input.inputmodal
  154. input.inputmodal.span5#newPassword1(type='password', name='newPassword1', placeholder='************')
  155. .clearfix
  156. label(for='xlinput.inputmodal') New Password
  157. .input.inputmodal
  158. input.inputmodal.span5#newPassword2(type='password', name='newPassword2', placeholder='************')
  159. .modal-footer
  160. button(type="submit").btn.btn-primary#confirmPasswordChange Change
  161. button.btn.cancel Cancel