Fix Firefox undo bug on Sauce and Advanced setting tabs. #946
This commit is contained in:
parent
6168fd5229
commit
959db8158e
@ -454,7 +454,8 @@ Settings =
|
|||||||
$('.warning', section).hidden = Conf['Sauce']
|
$('.warning', section).hidden = Conf['Sauce']
|
||||||
ta = $ 'textarea', section
|
ta = $ 'textarea', section
|
||||||
$.get 'sauces', Conf['sauces'], (item) ->
|
$.get 'sauces', Conf['sauces'], (item) ->
|
||||||
(ta.value = item['sauces'])
|
ta.value = item['sauces']
|
||||||
|
(ta.hidden = false) # XXX prevent Firefox from adding initialization to undo queue
|
||||||
$.on ta, 'change', $.cb.value
|
$.on ta, 'change', $.cb.value
|
||||||
|
|
||||||
advanced: (section) ->
|
advanced: (section) ->
|
||||||
@ -482,6 +483,7 @@ Settings =
|
|||||||
for key, val of items
|
for key, val of items
|
||||||
input = inputs[key]
|
input = inputs[key]
|
||||||
input[if input.type is 'checkbox' then 'checked' else 'value'] = val
|
input[if input.type is 'checkbox' then 'checked' else 'value'] = val
|
||||||
|
input.hidden = false # XXX prevent Firefox from adding initialization to undo queue
|
||||||
if key of Settings
|
if key of Settings
|
||||||
Settings[key].call input
|
Settings[key].call input
|
||||||
return
|
return
|
||||||
|
|||||||
@ -15,7 +15,7 @@
|
|||||||
<b>Archive Lists</b>: Each line below should be an archive list in <a href="https://github.com/MayhemYDG/archives.json/blob/gh-pages/CONTRIBUTING.md" target="_blank">this format</a> or a URL to load an archive list from.<br>
|
<b>Archive Lists</b>: Each line below should be an archive list in <a href="https://github.com/MayhemYDG/archives.json/blob/gh-pages/CONTRIBUTING.md" target="_blank">this format</a> or a URL to load an archive list from.<br>
|
||||||
Archive properties can be overriden by another item with the same <code>uid</code> (or if absent, its <code>name</code>).
|
Archive properties can be overriden by another item with the same <code>uid</code> (or if absent, its <code>name</code>).
|
||||||
</div>
|
</div>
|
||||||
<textarea name="archiveLists" class="field" spellcheck="false"></textarea>
|
<textarea hidden name="archiveLists" class="field" spellcheck="false"></textarea>
|
||||||
<button id="update-archives">Update now</button> Last updated: <time id="lastarchivecheck"></time> <label><input type="checkbox" name="archiveAutoUpdate"> Auto-update</label>
|
<button id="update-archives">Update now</button> Last updated: <time id="lastarchivecheck"></time> <label><input type="checkbox" name="archiveAutoUpdate"> Auto-update</label>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
@ -27,7 +27,7 @@
|
|||||||
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend>Custom Board Navigation</legend>
|
<legend>Custom Board Navigation</legend>
|
||||||
<div><textarea name="boardnav" class="field" spellcheck="false"></textarea></div>
|
<div><textarea hidden name="boardnav" class="field" spellcheck="false"></textarea></div>
|
||||||
<span class="note">New lines will be converted into spaces.</span><br><br>
|
<span class="note">New lines will be converted into spaces.</span><br><br>
|
||||||
<div class="note">In the following examples for /g/, <code>g</code> can be changed to a different board ID (<code>a</code>, <code>b</code>, etc...), the current board (<code>current</code>), or the Twitter link (<code>@</code>).</div>
|
<div class="note">In the following examples for /g/, <code>g</code> can be changed to a different board ID (<code>a</code>, <code>b</code>, etc...), the current board (<code>current</code>), or the Twitter link (<code>@</code>).</div>
|
||||||
<div>Board link: <code>g</code></div>
|
<div>Board link: <code>g</code></div>
|
||||||
@ -87,7 +87,7 @@
|
|||||||
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend>Quick Reply Personas</legend>
|
<legend>Quick Reply Personas</legend>
|
||||||
<textarea class="personafield field" name="QR.personas" spellcheck="false"></textarea>
|
<textarea hidden class="personafield field" name="QR.personas" spellcheck="false"></textarea>
|
||||||
<p>
|
<p>
|
||||||
One item per line.<br>
|
One item per line.<br>
|
||||||
Items will be added in the relevant input's auto-completion list.<br>
|
Items will be added in the relevant input's auto-completion list.<br>
|
||||||
@ -140,7 +140,7 @@
|
|||||||
</legend>
|
</legend>
|
||||||
<div>For more information about customizing 4chan X's CSS, see the <a href="<%= meta.cssGuide %>" target="_blank">styling guide</a>.</div>
|
<div>For more information about customizing 4chan X's CSS, see the <a href="<%= meta.cssGuide %>" target="_blank">styling guide</a>.</div>
|
||||||
<button id="apply-css">Apply CSS</button>
|
<button id="apply-css">Apply CSS</button>
|
||||||
<textarea name="usercss" class="field" spellcheck="false"></textarea>
|
<textarea hidden name="usercss" class="field" spellcheck="false"></textarea>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
@ -149,5 +149,5 @@
|
|||||||
Sources from which Javascript is allowed to be loaded by <a href="http://content-security-policy.com/#source_list" target="_blank">Content Security Policy</a>.<br>
|
Sources from which Javascript is allowed to be loaded by <a href="http://content-security-policy.com/#source_list" target="_blank">Content Security Policy</a>.<br>
|
||||||
Lines starting with a <code>#</code> will be ignored.
|
Lines starting with a <code>#</code> will be ignored.
|
||||||
</div>
|
</div>
|
||||||
<textarea name="jsWhitelist" class="field" spellcheck="false"></textarea>
|
<textarea hidden name="jsWhitelist" class="field" spellcheck="false"></textarea>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|||||||
@ -14,4 +14,4 @@
|
|||||||
<li><code>%board</code>: Current board.</li>
|
<li><code>%board</code>: Current board.</li>
|
||||||
<li><code>%%</code>, <code>%semi</code>: Literal <code>%</code> and <code>;</code>.</li>
|
<li><code>%%</code>, <code>%semi</code>: Literal <code>%</code> and <code>;</code>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<textarea name="sauces" class="field" spellcheck="false"></textarea>
|
<textarea hidden name="sauces" class="field" spellcheck="false"></textarea>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user