Use a div that gets hidden, instead of a <noscript> tag, because the <noscript> tag doesn't when the security slider is on Safer

This commit is contained in:
Micah Lee 2019-02-13 17:40:33 -08:00
parent 5755cd625b
commit 1c16b092a3
No known key found for this signature in database
GPG Key ID: 403C2657CD994F73
3 changed files with 19 additions and 9 deletions

View File

@ -193,7 +193,7 @@ li.info {
margin: 0 0 20px 0;
}
div.noscript {
div#noscript {
border: 1px solid #e55454;
text-align: left;
color: #e55454;
@ -202,3 +202,7 @@ div.noscript {
max-width: 700px;
margin: 100px 2em 0 2em;
}
div#noscript a, div#noscript a:visited {
color: #e27f7f;
}

View File

@ -1,3 +1,6 @@
// Hide the noscript div, because our javascript is executing
document.getElementById('noscript').style.display = 'none';
var form = document.getElementById('send');
var fileSelect = document.getElementById('file-select');
var uploadButton = document.getElementById('send-button');

View File

@ -33,14 +33,17 @@
</div>
</form>
<noscript>
<div class="noscript">
<strong>Warning:</strong> Due to a bug in Tor Browser and Firefox, if you want to upload
a file bigger than 50mb, you must set the Tor Browser security slider to
Standard. Otherwise your upload will never finish. If you plan on
only uploading small files, your current settings are fine.
</div>
</noscript>
<!-- We are not using a <noscript> tag because it only works when the security slider
is set to Safest, not Safer. -->
<div id="noscript">
<p>
<strong>Warning:</strong> Due to a bug in Tor Browser and Firefox, if you
want to upload a file bigger than 50mb, you must set the Tor Browser
<a rel="noreferrer" target="_blank" href="https://tb-manual.torproject.org/en-US/security-slider/">security slider</a>
to Standard. Otherwise your upload will never finish.</p>
<p>If you plan on only uploading small files, your current settings are fine.</p>
</div>
</div>
</div>
<script src="/static/js/receive.js"></script>