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; margin: 0 0 20px 0;
} }
div.noscript { div#noscript {
border: 1px solid #e55454; border: 1px solid #e55454;
text-align: left; text-align: left;
color: #e55454; color: #e55454;
@ -202,3 +202,7 @@ div.noscript {
max-width: 700px; max-width: 700px;
margin: 100px 2em 0 2em; 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 form = document.getElementById('send');
var fileSelect = document.getElementById('file-select'); var fileSelect = document.getElementById('file-select');
var uploadButton = document.getElementById('send-button'); var uploadButton = document.getElementById('send-button');

View file

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