Uncheck 'Report to Archives' and disable details field by default. #1745
This commit is contained in:
parent
2409834dc3
commit
31d6a0aa31
@ -40,6 +40,9 @@ Report =
|
||||
reason = $ '#archive-report-reason', fieldset
|
||||
submit = $ '#archive-report-submit', fieldset
|
||||
|
||||
$.on enabled, 'change', ->
|
||||
reason.disabled = !@checked
|
||||
|
||||
if form and types
|
||||
fieldset.hidden = !$('[value="31"]', types).checked
|
||||
$.on types, 'change', (e) ->
|
||||
@ -54,7 +57,6 @@ Report =
|
||||
@action = '#archiveresults=' + encodeURIComponent JSON.stringify results
|
||||
@submit()
|
||||
else if message
|
||||
enabled.checked = false
|
||||
fieldset.hidden = /Report submitted!/.test(message.textContent)
|
||||
$.on enabled, 'change', ->
|
||||
submit.hidden = !@checked
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
<legend><label><input id="archive-report-enabled" type="checkbox" checked>Report illegal content to archives</label></legend>
|
||||
<legend><label><input id="archive-report-enabled" type="checkbox">Report illegal content to archives</label></legend>
|
||||
<label for="archive-report-reason">Details</label>
|
||||
<textarea id="archive-report-reason">Illegal content</textarea>
|
||||
<textarea id="archive-report-reason" disabled>Illegal content</textarea>
|
||||
<button id="archive-report-submit" hidden>Submit</button>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user