Work in progress implementation of #216

This commit is contained in:
Dylan
2024-08-24 18:49:21 +01:00
parent aeab60e059
commit 0db90f556c
7 changed files with 70 additions and 4 deletions

25
static/preferences.html Normal file
View File

@ -0,0 +1,25 @@
<!DOCTYPE html>
<html>
<head>
<title>Preferences</title>
<script>
function savePreference() {
var checkbox = document.getElementById("openLinksCheckbox");
localStorage.setItem("openLinksPreference", checkbox.checked);
}
function loadPreference() {
var checkbox = document.getElementById("openLinksCheckbox");
var preference = localStorage.getItem("openLinksPreference");
checkbox.checked = preference === "true";
}
</script>
</head>
<body onload="loadPreference()">
<h1>Preferences</h1>
<label for="openLinksCheckbox">
<input type="checkbox" id="openLinksCheckbox" onchange="savePreference()">
Open links in app
</label>
</body>
</html>