History

Add form attribute to settings page inputs

Thibaut Courouble committed 9 years ago

Commit b353d3a1 parent aed1d8e1 file · +5 −5Browse files

Unified · Split

assets/javascripts/templates/pages/settings_tmpl.coffee+5−5
@@ -6,13 +6,13 @@ app.templates.settingsPage = (settings) -> """ · 5 unmodified lines
6 6
7 <div class="_settings-inputs">7 <div class="_settings-inputs">
8 <label class="_settings-label">8 <label class="_settings-label">
9 <input type="checkbox" name="dark" value="1"#{if settings.dark then ' checked' else ''}>Enable dark theme9 <input type="checkbox" form="settings" name="dark" value="1"#{if settings.dark then ' checked' else ''}>Enable dark theme
10 </label>10 </label>
11 <label class="_settings-label _setting-max-width">11 <label class="_settings-label _setting-max-width">
12 <input type="checkbox" name="layout" value="_max-width"#{if settings['_max-width'] then ' checked' else ''}>Enable fixed-width layout12 <input type="checkbox" form="settings" name="layout" value="_max-width"#{if settings['_max-width'] then ' checked' else ''}>Enable fixed-width layout
13 </label>13 </label>
14 <label class="_settings-label _hide-on-mobile">14 <label class="_settings-label _hide-on-mobile">
15 <input type="checkbox" name="layout" value="_sidebar-hidden"#{if settings['_sidebar-hidden'] then ' checked' else ''}>Automatically hide and show the sidebar15 <input type="checkbox" form="settings" name="layout" value="_sidebar-hidden"#{if settings['_sidebar-hidden'] then ' checked' else ''}>Automatically hide and show the sidebar
16 <small>Tip: drag the edge of the sidebar to resize it.</small>16 <small>Tip: drag the edge of the sidebar to resize it.</small>
17 </label>17 </label>
18 </div>18 </div>
@@ -23,10 +23,10 @@ app.templates.settingsPage = (settings) -> """ · 4 unmodified lines
23 23
24 <div class="_settings-inputs">24 <div class="_settings-inputs">
25 <label class="_settings-label">25 <label class="_settings-label">
26 <input type="checkbox" name="smoothScroll" value="1"#{if settings.smoothScroll then ' checked' else ''}>Use smooth scrolling26 <input type="checkbox" form="settings" name="smoothScroll" value="1"#{if settings.smoothScroll then ' checked' else ''}>Use smooth scrolling
27 </label>27 </label>
28 <label class="_settings-label">28 <label class="_settings-label">
29 <input type="checkbox" name="arrowScroll" value="1"#{if settings.arrowScroll then ' checked' else ''}>Use arrow keys to scroll the main content area29 <input type="checkbox" form="settings" name="arrowScroll" value="1"#{if settings.arrowScroll then ' checked' else ''}>Use arrow keys to scroll the main content area
30 <small>With this checked, use <code class="_label">alt</code> + <code class="_label">&uarr;</code><code class="_label">&darr;</code><code class="_label">&larr;</code><code class="_label">&rarr;</code> to navigate the sidebar.</small>30 <small>With this checked, use <code class="_label">alt</code> + <code class="_label">&uarr;</code><code class="_label">&darr;</code><code class="_label">&larr;</code><code class="_label">&rarr;</code> to navigate the sidebar.</small>
31 </label>31 </label>
32 </div>32 </div>