Added a warning if javascript is disabled on login/signin pages

This commit is contained in:
Kenneth Skovhede
2025-09-29 11:04:44 +02:00
parent a676a07944
commit 94ea0bbd35
6 changed files with 57 additions and 12 deletions
+12 -6
View File
@@ -39,12 +39,18 @@
<p><input type="submit" id="login-button" value="Sign In" /></p>
</fieldset>
</form>
<a
href="https://docs.duplicati.com/detailed-descriptions/duplicati-access-password"
target="_blank"
class="helplink"
>Password missing or lost?</a
>
<div>
<a
href="https://docs.duplicati.com/detailed-descriptions/duplicati-access-password"
target="_blank"
class="helplink"
>Password missing or lost?</a
>
</div>
<div id="no-js-warning" class="nojs">
You need Javascript enabled to use this page, or copy in the token from
the URL
</div>
</div>
</body>
</html>
+15
View File
@@ -83,3 +83,18 @@ input {
margin-left: 16px;
color: #777;
}
#login div.nojs {
margin-top: 16px;
margin-left: 16px;
color: red;
opacity: 0;
animation: showafter2s 0s forwards;
animation-delay: 2s;
}
@keyframes showafter2s {
to {
opacity: 1;
}
}
+2
View File
@@ -1,5 +1,7 @@
$(document).ready(function() {
var processing = false;
document.getElementById('no-js-warning').style.display = 'none';
$('#login-form').on('submit', function() {
+12 -6
View File
@@ -29,12 +29,18 @@
<p><input type="submit" id="login-button" value="Sign In" /></p>
</fieldset>
</form>
<a
href="https://docs.duplicati.com/detailed-descriptions/duplicati-access-password#temporary-signin-token"
target="_blank"
class="helplink"
>Need help locating the signin token?</a
>
<div>
<a
href="https://docs.duplicati.com/detailed-descriptions/duplicati-access-password#temporary-signin-token"
target="_blank"
class="helplink"
>Need help locating the signin token?</a
>
</div>
<div id="no-js-warning" class="nojs">
You need Javascript enabled to use this page, or copy in the token from
the URL
</div>
</div>
</body>
</html>
@@ -82,4 +82,18 @@ input {
margin-top: 16px;
margin-left: 16px;
color: #777;
}
#signin div.nojs {
margin-top: 16px;
margin-left: 16px;
color: red;
opacity: 0;
animation: showafter2s 0s forwards;
animation-delay: 2s;
}
@keyframes showafter2s {
to {
opacity: 1;
}
}
@@ -1,5 +1,7 @@
$(document).ready(function() {
var processing = false;
document.getElementById('no-js-warning').style.display = 'none';
function getQueryParam(name) {
var regex = new RegExp("[\\?&]" + name + "=([^&#]*)"), results = regex.exec(location.search);