7bf5fab1fa2fa07cc012c0570781aea23343ae05 | bcca862eaaeeb4e5a739a9107f8ae073ef6a37b3 | ||
---|---|---|---|
17 | ## the Original Code is CondeNet, Inc. | 17 | ## the Original Code is CondeNet, Inc. |
18 | ## | 18 | ## |
19 | ## All portions of the code written by CondeNet are Copyright (c) 2006-2008 | 19 | ## All portions of the code written by CondeNet are Copyright (c) 2006-2008 |
20 | ## CondeNet, Inc. All Rights Reserved. | 20 | ## CondeNet, Inc. All Rights Reserved." |
21 | ################################################################################ | 21 | ################################################################################ |
22 | 22 | ||
23 | <%namespace file="utils.html" import="language_tool, language_checkboxes"/> | 23 | <%namespace file="utils.html" import="language_tool, language_checkboxes"/> |
... | ... | ||
34 | <%def name="link_options()"> | 34 | <%def name="link_options()"> |
35 | <select name="numsites" style="margin: 0 .5em 0 .5em"> | 35 | <select name="numsites" style="margin: 0 .5em 0 .5em"> |
36 | %for x in [10, 25, 50, 100]: | 36 | %for x in [10, 25, 50, 100]: |
37 | <option ${x == c.user.pref_numsites and "selected='selected'" or ""}>${x}</option> | 37 | <option ${x == c.user.pref_numsites and "selected='selected'" or ""}> |
38 | ${x} | ||
39 | </option> | ||
38 | %endfor | 40 | %endfor |
39 | </select> | 41 | </select> |
40 | </%def> | 42 | </%def> |
41 | 43 | ||
44 | <%def name="media_radio(val, label)"> | ||
45 | <input id="media_${val}" class="nomargin" | ||
46 | type="radio" value="${val}" name="media" | ||
47 | ${"checked='checked'" if c.user.pref_media == val else ''} /> | ||
48 | <label for="media_${val}">${label}</label> | ||
49 | <br/> | ||
50 | </%def> | ||
42 | 51 | ||
43 | <%def name="num_input(s, name)"> | 52 | <%def name="num_input(s, name)"> |
44 | <input type="text" size="4" maxlength="4" | 53 | <input type="text" size="4" maxlength="4" |
... | ... | ||
54 | <input type="hidden" name="uh" value="${c.modhash}" /> | 63 | <input type="hidden" name="uh" value="${c.modhash}" /> |
55 | 64 | ||
56 | <table class="content preftable"> | 65 | <table class="content preftable"> |
57 | <tr class="prefrow"> | 66 | <tr> |
58 | <td class="prefleft">${_("interface language")}</td> | 67 | <th>${_("interface language")}</th> |
59 | <td class="prefright"> | 68 | <td class="prefright"> |
60 | ${language_tool(allow_blank = False, show_regions = True, | 69 | ${language_tool(allow_blank = False, show_regions = True, |
61 | default_lang = c.user.pref_lang)} | 70 | default_lang = c.user.pref_lang)} |
... | ... | ||
63 |  <a href="/feedback">${_("volunteer to translate")}</a></span> | 72 |  <a href="/feedback">${_("volunteer to translate")}</a></span> |
64 | </td> | 73 | </td> |
65 | </tr> | 74 | </tr> |
66 | <tr class="prefrow"> | 75 | <tr> |
67 | <td class="prefleft">${_("content language")}</td> | 76 | <th>${_("content language")}</th> |
68 | <td class="prefright"> | 77 | <td class="prefright"> |
69 | ${language_checkboxes(default = c.user.pref_content_langs)} | 78 | ${language_checkboxes(default = c.user.pref_content_langs)} |
70 | </td> | 79 | </td> |
71 | </tr> | 80 | </tr> |
72 | %if c.user_is_loggedin: | 81 | %if c.user_is_loggedin: |
73 | <tr class="prefrow"> | 82 | <tr> |
74 | <td class="prefleft">${_("clicking options")}</td> | 83 | <th>${_("clicking options")}</th> |
75 | <td class="prefright"> | 84 | <td class="prefright"> |
76 | ${checkbox(_("display links with a reddit toolbar"), "frame")} | 85 | ${checkbox(_("display links with a reddit toolbar"), "frame")} |
77 | <br/> | 86 | <br/> |
78 | ${checkbox(_("open links in a new window"), "newwindow")} | 87 | ${checkbox(_("open links in a new window"), "newwindow")} |
79 | </td> | 88 | </td> |
80 | </tr> | 89 | </tr> |
81 | <tr class="prefrow"> | 90 | <tr> |
82 | <td class="prefleft">${_("link options")}</td> | 91 | <th>${_("media")}</th> |
92 | <td class="prefright"> | ||
93 | %if not c.user.pref_compress: | ||
94 | ${media_radio("on", _("show thumbnails next to links"))} | ||
95 | ${media_radio("off", _("don't show thumbnails next to links"))} | ||
96 | ${media_radio("subreddit", _("show thumbnails based on that reddit's media preferences"))} | ||
97 | %else: | ||
98 | <p class="error">${_("to enable thumbnails, disable compressed link display")}</p> | ||
99 | <input type="hidden" name="media" value="${c.user.pref_media}"/> | ||
100 | %endif | ||
101 | </td> | ||
102 | </tr> | ||
103 | <tr> | ||
104 | <th>${_("link options")}</th> | ||
83 | <td class="prefright"> | 105 | <td class="prefright"> |
84 | ${checkbox(_("show me new links on the front page"), "organic")} | 106 | ${checkbox(_("show me new links on the front page"), "organic")} |
85 | <br/> | 107 | <br/> |
... | ... | ||
108 |  <span class="little gray">${_("(blank for none)")}</span> | 130 |  <span class="little gray">${_("(blank for none)")}</span> |
109 | </td> | 131 | </td> |
110 | </tr> | 132 | </tr> |
111 | <tr class="prefrow"> | 133 | <tr> |
112 | <td class="prefleft">${_("comment options")}</td> | 134 | <th>${_("comment options")}</th> |
113 | <td class="prefright"> | 135 | <td class="prefright"> |
114 | <% | 136 | <% |
115 | input = capture(num_input, c.user.pref_min_comment_score, | 137 | input = capture(num_input, c.user.pref_min_comment_score, |
... | ... | ||
129 | </td> | 151 | </td> |
130 | </tr> | 152 | </tr> |
131 | 153 | ||
132 | <tr class="prefrow"> | 154 | <tr> |
133 | <td class="prefleft">${_("privacy options")}</td> | 155 | <th>${_("privacy options")}</th> |
134 | <td class="prefright"> | 156 | <td class="prefright"> |
135 | ${checkbox(_("make my votes public"), "public_votes")} | 157 | ${checkbox(_("make my votes public"), "public_votes")} |
136 | <br/> | 158 | <br/> |