Create custom.html

pull/1415/head
xxDUxx 2022-02-10 11:39:58 +01:00 committed by GitHub
parent a737e7f772
commit b343726dd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 31 additions and 0 deletions

View File

@ -0,0 +1,31 @@
<html>
<head>
<link rel="stylesheet" href="../../css/spectre.min.css">
</head>
<body>
<form>
<input type="checkbox" id="Impact" name="Impact" value="0">
<label for="Impact">Impact</label><br>
<input type="checkbox" id="Phosphate" name="Phosphate" value="1">
<label for="Phosphate">Phosphate</label><br>
<p>Click <button id="upload" class="btn btn-primary">Upload</button></p>
<script src="../../core/lib/customize.js"></script>
<script>
// When the 'upload' button is clicked...
document.getElementById("upload").addEventListener("click", function() {
Fonts = {"Impact", "Phosphate"};
var n=0;
for (fontName in Fonts) {
if (document.getElementById(fontName).value==true) {
sendCustomizedApp({
storage:[
{name:"contourclock-"+n+".js", url:"app.js", content:"font-"+fontName+".json"},
]
});
}
}
});
</script>
</form>
</body>
</html>