diff --git a/webroot/js/language.js b/webroot/js/language.js
index bc30ade1..ef3bc9f8 100644
--- a/webroot/js/language.js
+++ b/webroot/js/language.js
@@ -15,11 +15,6 @@ export async function setNewLanguage(locate, initialize) {
translateActionPage(old_translations, new_translations)
translateSettingsPage(new_translations)
-
- /* INFO: error history modal */
- document.getElementById('errorh_modal_title').innerHTML = new_translations.modal.logs.header
- document.getElementById('errorh_panel').placeholder = new_translations.modal.logs.placeholder
-
/* INFO: navbar info */
document.getElementById('nav_home_title').innerHTML = new_translations.page.home.header
document.getElementById('nav_modules_title').innerHTML = new_translations.page.modules.header
@@ -34,6 +29,12 @@ export async function setNewLanguage(locate, initialize) {
document.getElementById('small_panel_theme_dark_option').innerHTML = new_translations.smallPage.theme.dark
document.getElementById('small_panel_theme_light_option').innerHTML = new_translations.smallPage.theme.light
document.getElementById('small_panel_theme_system_option').innerHTML = new_translations.smallPage.theme.system
+
+ /* INFO: Error history small page */
+ document.getElementById('errorh_copy').innerHTML = new_translations.smallPage.errorh.buttons.copy
+ document.getElementById('errorh_clear_all').innerHTML = new_translations.smallPage.errorh.buttons.clear
+ document.getElementById('errorh_modal_title').innerHTML = new_translations.smallPage.errorh.header
+ document.getElementById('errorh_panel').placeholder = new_translations.smallPage.errorh.placeholder
}
export async function getTranslations(locate) {
diff --git a/webroot/js/main.js b/webroot/js/main.js
index 52c7e084..b00243a0 100644
--- a/webroot/js/main.js
+++ b/webroot/js/main.js
@@ -36,6 +36,7 @@ export function setErrorData(errorLog) {
const translations = await getTranslations(sys_lang)
const loading_screen = document.getElementById('loading_screen')
+ const bottom_nav = document.getElementById('navbar_support_div')
const rootCss = document.querySelector(':root')
@@ -204,6 +205,7 @@ export function setErrorData(errorLog) {
/* INFO: This hides the throbber screen */
loading_screen.style.display = 'none'
+ bottom_nav.style.display = 'flex'
all_modules.forEach((module) => {
modules_list.innerHTML +=
diff --git a/webroot/js/modal/errorHistory.js b/webroot/js/modal/errorHistory.js
deleted file mode 100644
index 3c5a6f9b..00000000
--- a/webroot/js/modal/errorHistory.js
+++ /dev/null
@@ -1,50 +0,0 @@
-const button = document.getElementById('rezygisk_errorh')
-const backport = document.getElementById('backport_errorh')
-const copy_button = document.getElementById('errorh_copy')
-const target = document.getElementById('errorh_modal')
-const close_button = document.getElementById('errorh_modal_close')
-const clearall_button = document.getElementById('errorh_clear_all')
-const panel = document.getElementById('errorh_panel')
-const error_history_data_state = document.getElementById('cache-modal-error-history-state')
-
-let sys_module_mode = error_history_data_state.getAttribute('content')
-sys_module_mode = setData('closed', error_history_data_state)
-
-button.addEventListener('click', () => {
- target.style.top = '0%'
-
- sys_module_mode = setData('opened', error_history_data_state)
-})
-
-backport.addEventListener('click', () => {
- if (sys_module_mode == 'opened') {
- target.style.top = '100%'
- sys_module_mode = setData('closed', error_history_data_state)
- return
- }
-
- target.style.top = '0%'
- sys_module_mode = setData('opened', error_history_data_state)
-})
-
-
-close_button.addEventListener('click', () => {
- target.style.top = '100%'
-
- sys_module_mode = setData('closed', error_history_data_state)
-})
-
-copy_button.addEventListener('click', () => {
- navigator.clipboard.writeText(panel.innerHTML)
-})
-
-clearall_button.addEventListener('click', () => {
- panel.innerHTML = ''
- localStorage.setItem('/system/error', '')
-})
-
-function setData(mode, tag) {
- tag.setAttribute('content', mode)
-
- return mode
-}
\ No newline at end of file
diff --git a/webroot/js/smallPage/errorHistory.js b/webroot/js/smallPage/errorHistory.js
new file mode 100644
index 00000000..f22fc8e9
--- /dev/null
+++ b/webroot/js/smallPage/errorHistory.js
@@ -0,0 +1,47 @@
+import { smallPageDisabler } from '../smallPageDesabler.js'
+const panel = document.getElementById('errorh_panel')
+
+/* INFO: Event setup */
+const navbar_data_tag = document.getElementById('cache-navbar-previous')
+const small_panel_data_tag = document.getElementById('cache-page-small-previous')
+const fallback_open = document.getElementById('cache-fallback-open')
+
+document.getElementById('errorh_page_toggle').addEventListener('click', () => {
+ const previous = !navbar_data_tag.getAttribute('content') ? setData('home', small_panel_data_tag) : navbar_data_tag.getAttribute('content')
+ document.getElementById(`panel_${previous}`).classList.remove('show')
+ document.getElementById('small_panel_errorh').classList.toggle('show')
+ small_panel_data_tag.setAttribute('content', 'errorh')
+})
+
+document.getElementById('backport_errorh').addEventListener('click', () => {
+ const previous = !navbar_data_tag.getAttribute('content') ? setData('home', small_panel_data_tag) : navbar_data_tag.getAttribute('content')
+ document.getElementById(`panel_${previous}`).classList.remove('show')
+ document.getElementById('loading_screen').style.display = 'none'
+ document.getElementById('small_panel_errorh').classList.toggle('show')
+ document.getElementById('errorh_panel').style.bottom = '1em'
+ fallback_open.setAttribute('content', 'opened')
+ small_panel_data_tag.setAttribute('content', 'errorh')
+})
+
+document.getElementById('sp_errorh_close').addEventListener('click', () => {
+ const is_fallback = fallback_open.getAttribute('content')
+ if (is_fallback) {
+ document.getElementById('errorh_panel').style.bottom = '1em'
+ document.getElementById('loading_screen').style.display = 'flex'
+ }
+ smallPageDisabler('errorh', is_fallback ? 'home' : 'settings', is_fallback ? 'home' : null)
+})
+document.getElementById('errorh_copy').addEventListener('click', () => {
+ navigator.clipboard.writeText(panel.innerHTML)
+})
+
+document.getElementById('errorh_clear_all').addEventListener('click', () => {
+ panel.innerHTML = ''
+ localStorage.setItem('/system/error', '')
+})
+
+function setData(mode, tag) {
+ tag.setAttribute('content', mode)
+
+ return mode
+}
\ No newline at end of file
diff --git a/webroot/js/smallPageDesabler.js b/webroot/js/smallPageDesabler.js
index d30667a1..a502fae6 100644
--- a/webroot/js/smallPageDesabler.js
+++ b/webroot/js/smallPageDesabler.js
@@ -1,4 +1,4 @@
-export function smallPageDisabler(page_name, new_page) {
+export function smallPageDisabler(page_name, new_page, custom_page) {
const navbar_data_tag = document.getElementById('cache-navbar-previous')
const small_panel_data_tag = document.getElementById('cache-page-small-previous')
@@ -22,5 +22,5 @@ export function smallPageDisabler(page_name, new_page) {
curr_input.setAttribute('checked', '')
i_background.classList.toggle('show')
- navbar_data_tag.setAttribute('content', 'settings')
+ navbar_data_tag.setAttribute('content', custom_page ? custom_page : 'settings')
}
\ No newline at end of file
diff --git a/webroot/js/themes/amoled.js b/webroot/js/themes/amoled.js
index c53f4a67..ef362229 100644
--- a/webroot/js/themes/amoled.js
+++ b/webroot/js/themes/amoled.js
@@ -5,8 +5,6 @@ const rootCss = document.querySelector(':root')
/* INFO: Changes the icons to match the theme */
const close_icons = document.getElementsByClassName('close_icon')
const expand_icons = document.getElementsByClassName('expander')
-const copy_button = document.getElementById('errorh_copy')
-const clearall_button = document.getElementById('errorh_clear_all')
const sp_lang_close = document.getElementById('sp_lang_close')
const sp_theme_close = document.getElementById('sp_theme_close')
@@ -31,8 +29,6 @@ export function setAmoled(chooseSet) {
expand_icon.innerHTML = '
'
}
- copy_button.innerHTML = '
'
- clearall_button.innerHTML = '
'
sp_lang_close.innerHTML = '
'
sp_theme_close.innerHTML = '
'
setDarkNav()
diff --git a/webroot/js/themes/dark.js b/webroot/js/themes/dark.js
index 2e35b00c..db0361df 100644
--- a/webroot/js/themes/dark.js
+++ b/webroot/js/themes/dark.js
@@ -5,8 +5,6 @@ const rootCss = document.querySelector(':root')
/* INFO: Changes the icons to match the theme */
const close_icons = document.getElementsByClassName('close_icon')
const expand_icons = document.getElementsByClassName('expander')
-const copy_button = document.getElementById('errorh_copy')
-const clearall_button = document.getElementById('errorh_clear_all')
const sp_lang_close = document.getElementById('sp_lang_close')
const sp_theme_close = document.getElementById('sp_theme_close')
@@ -31,8 +29,6 @@ export function setDark(chooseSet) {
expand_icon.innerHTML = '
'
}
- copy_button.innerHTML = '
'
- clearall_button.innerHTML = '
'
sp_lang_close.innerHTML = '
'
sp_theme_close.innerHTML = '
'
setDarkNav()
diff --git a/webroot/js/themes/monochrome.js b/webroot/js/themes/monochrome.js
index db89e18d..56d5f3bc 100644
--- a/webroot/js/themes/monochrome.js
+++ b/webroot/js/themes/monochrome.js
@@ -5,8 +5,6 @@ const rootCss = document.querySelector(':root')
/* INFO: Changes the icons to match the theme */
const close_icons = document.getElementsByClassName('close_icon')
const expand_icons = document.getElementsByClassName('expander')
-const copy_button = document.getElementById('errorh_copy')
-const clearall_button = document.getElementById('errorh_clear_all')
const sp_lang_close = document.getElementById('sp_lang_close')
const sp_theme_close = document.getElementById('sp_theme_close')
@@ -31,8 +29,6 @@ export function setMonochrome(chooseSet) {
expand_icon.innerHTML = '
'
}
- copy_button.innerHTML = '
'
- clearall_button.innerHTML = '
'
sp_lang_close.innerHTML = '
'
sp_theme_close.innerHTML = '
'
setDarkNav()
diff --git a/webroot/lang/de_DE.json b/webroot/lang/de_DE.json
index 0c01122f..aa8cbec4 100644
--- a/webroot/lang/de_DE.json
+++ b/webroot/lang/de_DE.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "Unbekannt"
},
- "modal": {
- "logs": {
- "header": "Fehlerhistorie",
- "placeholder": "Es wurde kein Fehler festgestellt!"
- }
- },
"smallPage": {
"language": {
"header": "Neue Sprache wählen"
@@ -18,6 +12,14 @@
"dark": "Dunkel",
"light": "Hell",
"system": "System Basiert"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Fehlerhistorie",
+ "placeholder": "Es wurde kein Fehler festgestellt!"
}
},
"page": {
diff --git a/webroot/lang/en_US.json b/webroot/lang/en_US.json
index 6686ef61..01e1695c 100644
--- a/webroot/lang/en_US.json
+++ b/webroot/lang/en_US.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "Unknown"
},
- "modal": {
- "logs": {
- "header": "Error History",
- "placeholder": "No error log recorded here!"
- }
- },
"smallPage": {
"language": {
"header": "Choose your new language"
@@ -18,6 +12,14 @@
"dark": "Dark",
"light": "Light",
"system": "System Based"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Error History",
+ "placeholder": "No error log recorded here!"
}
},
"page": {
diff --git a/webroot/lang/ja_JP.json b/webroot/lang/ja_JP.json
index d93ef277..3e607080 100644
--- a/webroot/lang/ja_JP.json
+++ b/webroot/lang/ja_JP.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "不明"
},
- "modal": {
- "logs": {
- "header": "Error History",
- "placeholder": "No error log recorded here!"
- }
- },
"smallPage": {
"language": {
"header": "言語を選択してください"
@@ -18,6 +12,14 @@
"dark": "Dark",
"light": "Light",
"system": "System Based"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Error History",
+ "placeholder": "No error log recorded here!"
}
},
"page": {
diff --git a/webroot/lang/pt_BR.json b/webroot/lang/pt_BR.json
index 5522bcd0..f4d97bc6 100644
--- a/webroot/lang/pt_BR.json
+++ b/webroot/lang/pt_BR.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "Desconhecido"
},
- "modal": {
- "logs": {
- "header": "Histórico de erros",
- "placeholder": "Nenhum erro foi salvo aqui!"
- }
- },
"smallPage": {
"language": {
"header": "Escolha sua nova língua"
@@ -18,6 +12,14 @@
"dark": "Escuro",
"light": "Claro",
"system": "Baseado no do sistema"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Histórico de erros",
+ "placeholder": "Nenhum erro foi salvo aqui!"
}
},
"page": {
diff --git a/webroot/lang/ro_RO.json b/webroot/lang/ro_RO.json
index ef4a5786..d2317ba9 100644
--- a/webroot/lang/ro_RO.json
+++ b/webroot/lang/ro_RO.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "Necunoscut"
},
- "modal": {
- "logs": {
- "header": "Jurnal erori",
- "placeholder": "Nu a fost înregistrat niciun jurnal de erori aici!"
- }
- },
"smallPage": {
"language": {
"header": "Alege limba implicită"
@@ -18,6 +12,14 @@
"dark": "Întunecată",
"light": "Luminoasă",
"system": "Bazată pe sistem"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Jurnal erori",
+ "placeholder": "Nu a fost înregistrat niciun jurnal de erori aici!"
}
},
"page": {
diff --git a/webroot/lang/ru_RU.json b/webroot/lang/ru_RU.json
index e939773c..72687414 100644
--- a/webroot/lang/ru_RU.json
+++ b/webroot/lang/ru_RU.json
@@ -18,6 +18,14 @@
"dark": "Темная",
"light": "Светлая",
"system": "Системная тема"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Журнал ошибок",
+ "placeholder": "Журнал ошибок пуст!"
}
},
"page": {
diff --git a/webroot/lang/vi_VN.json b/webroot/lang/vi_VN.json
index 92f53b64..356a01ce 100644
--- a/webroot/lang/vi_VN.json
+++ b/webroot/lang/vi_VN.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "Không xác định"
},
- "modal": {
- "logs": {
- "header": "Lịch sử lỗi",
- "placeholder": "Không có lỗi nào đã được ghi lại ở đây!"
- }
- },
"smallPage": {
"language": {
"header": "Chọn ngôn ngữ mới của bạn"
@@ -18,6 +12,14 @@
"dark": "Tối",
"light": "Sáng",
"system": "Theo hệ thống"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "SAO CHÉP",
+ "clear": "XOÁ TOÀN BỘ LOG"
+ },
+ "header": "Lịch sử lỗi",
+ "placeholder": "Không có lỗi nào đã được ghi lại ở đây!"
}
},
"page": {
diff --git a/webroot/lang/zh_CN.json b/webroot/lang/zh_CN.json
index cb88e7d7..15d65c3d 100644
--- a/webroot/lang/zh_CN.json
+++ b/webroot/lang/zh_CN.json
@@ -3,12 +3,6 @@
"global": {
"unknown": "未知"
},
- "modal": {
- "logs": {
- "header": "错误日志",
- "placeholder": "暂时没有错误日志"
- }
- },
"smallPage": {
"language": {
"header": "选择语言"
@@ -18,6 +12,14 @@
"dark": "暗色",
"light": "浅色",
"system": "跟随系统设置"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "错误日志",
+ "placeholder": "暂时没有错误日志"
}
},
"page": {
diff --git a/webroot/lang/zh_TW.json b/webroot/lang/zh_TW.json
index 2905cb84..3aa7cb57 100644
--- a/webroot/lang/zh_TW.json
+++ b/webroot/lang/zh_TW.json
@@ -18,6 +18,14 @@
"dark": "Dark",
"light": "Light",
"system": "System Based"
+ },
+ "errorh": {
+ "buttons": {
+ "copy": "COPY",
+ "clear": "CLEAR ALL LOGS"
+ },
+ "header": "Error History",
+ "placeholder": "No error log recorded here!"
}
},
"page": {