Update custom.html
parent
434c6a16d9
commit
091e67b26b
|
|
@ -16,8 +16,9 @@
|
||||||
<body>
|
<body>
|
||||||
<h1> Select Fonts to upload:</h1>
|
<h1> Select Fonts to upload:</h1>
|
||||||
<form>
|
<form>
|
||||||
|
<script src="../../core/lib/customize.js"></script>
|
||||||
<script>
|
<script>
|
||||||
FontList = ["BarlowCond", "BebasNeue", "Dekko", "DinAlternate",
|
const FontList = ["LuckiestGuy", "Bangers", "RubikOne", "Oswald", "Anton", "TitanOne", "BarlowCond", "BebasNeue", "Dekko", "DinAlternate",
|
||||||
"Impact", "Nunito", "OpenSansEC", "Phosphate", "Quicksand", "SairaEC",
|
"Impact", "Nunito", "OpenSansEC", "Phosphate", "Quicksand", "SairaEC",
|
||||||
"Yumaro", "YuseiMagic"];
|
"Yumaro", "YuseiMagic"];
|
||||||
for (fontName of FontList) {
|
for (fontName of FontList) {
|
||||||
|
|
@ -37,15 +38,10 @@
|
||||||
document.forms[0].appendChild(lb);
|
document.forms[0].appendChild(lb);
|
||||||
document.forms[0].appendChild(document.createElement('br'));
|
document.forms[0].appendChild(document.createElement('br'));
|
||||||
}
|
}
|
||||||
</script>
|
btn=document.createElement('button');
|
||||||
<p><button id="upload" class="btn btn-primary">Upload selected Fonts</button></p>
|
btn.id="upload";
|
||||||
<script src="../../core/lib/customize.js"></script>
|
btn.innerHTML="Upload selected Fonts";
|
||||||
<script>
|
btn.addEventListener("click", function() {
|
||||||
FontList = ["BarlowCond", "BebasNeue", "Dekko", "DinAlternate",
|
|
||||||
"Impact", "Nunito", "OpenSansEC", "Phosphate", "Quicksand", "SairaEC",
|
|
||||||
"Yumaro", "YuseiMagic"];
|
|
||||||
// When the 'upload' button is clicked...
|
|
||||||
document.getElementById("upload").addEventListener("click", function() {
|
|
||||||
var n=0;
|
var n=0;
|
||||||
var fonts = [];
|
var fonts = [];
|
||||||
for (fontElement of document.getElementsByName("font")) {
|
for (fontElement of document.getElementsByName("font")) {
|
||||||
|
|
@ -63,6 +59,7 @@
|
||||||
else
|
else
|
||||||
alert("Please select at least one Font!");
|
alert("Please select at least one Font!");
|
||||||
});
|
});
|
||||||
|
document.forms[0].appendChild(btn);
|
||||||
</script>
|
</script>
|
||||||
</form>
|
</form>
|
||||||
</body>
|
</body>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue