settings.jade 6.4 KB

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