27 lines
643 B
JavaScript
27 lines
643 B
JavaScript
function getSGAStates() {
|
|
if (sessionStorage.getItem("sgaEnabled")) {
|
|
enableSGA();
|
|
}
|
|
}
|
|
|
|
function enableSGA() {
|
|
document.getElementById("body").style.fontFamily =
|
|
"standardGalactic, system-ui";
|
|
sessionStorage.setItem("sgaEnabled", 1);
|
|
console.debug(sessionStorage.getItem("sgaEnabled"));
|
|
}
|
|
|
|
function disableSGA() {
|
|
document.getElementById("body").style.fontFamily =
|
|
"departure-mono, system-ui";
|
|
sessionStorage.removeItem("sgaEnabled");
|
|
console.debug(sessionStorage.getItem("sgaEnabled"));
|
|
}
|
|
|
|
function toggleTheme() {
|
|
if (!sessionStorage.getItem("sgaEnabled")) {
|
|
enableSGA();
|
|
} else {
|
|
disableSGA();
|
|
}
|
|
}
|