summaryrefslogtreecommitdiff
path: root/scripts/globalElements.js
diff options
context:
space:
mode:
authoraltaf-creator <dev@altafcreator.com>2024-07-18 10:39:11 +0700
committeraltaf-creator <dev@altafcreator.com>2024-07-18 10:39:11 +0700
commit599e5bb3b9cf774d4c3680644cf4bd0596fd34c0 (patch)
treeaa697860db979d4b3f82fbbf80141153aa89db26 /scripts/globalElements.js
parent5905c9767d071532c90aaf703108eb6fe6d5971f (diff)
Start migrating (and rewriting) lessons, NEW FEATURE: quizzes (unfinished)
Diffstat (limited to 'scripts/globalElements.js')
-rw-r--r--scripts/globalElements.js12
1 files changed, 10 insertions, 2 deletions
diff --git a/scripts/globalElements.js b/scripts/globalElements.js
index 381f564..05b2f71 100644
--- a/scripts/globalElements.js
+++ b/scripts/globalElements.js
@@ -3,13 +3,21 @@
// * /scripts/sidebar.js
function updateGlobalElements() {
if (isLangIndonesia()) {
- document.getElementById("lang-switcher-text").innerHTML = "Baca dalam Bahasa Inggris";
+ try {
+ document.getElementById("lang-switcher-text").innerHTML = "Read in Indonesia";
+ } catch {
+ console.log("lang switcher button not found, moving on...")
+ }
document.getElementById("link-author").innerHTML = "Tentang Penulis";
document.getElementById("link-school").innerHTML = "Tentang Sekolah";
document.getElementById("link-lessons").innerHTML = "Mata Pelajaran";
document.getElementById("toc-title").innerHTML = "Daftar Isi"
} else {
- document.getElementById("lang-switcher-text").innerHTML = "Read in Indonesia";
+ try {
+ document.getElementById("lang-switcher-text").innerHTML = "Read in Indonesia";
+ } catch {
+ console.log("lang switcher button not found, moving on...")
+ }
}
if (isSidebarOpen() && document.body.clientWidth >= 1000) {