aboutsummaryrefslogtreecommitdiff
path: root/webAO/ui.js
diff options
context:
space:
mode:
authorstonedDiscord <Tukz@gmx.de>2026-01-01 16:01:07 +0100
committerstonedDiscord <Tukz@gmx.de>2026-01-01 16:01:07 +0100
commit94617a2ed8314a12d239a735e3b3cef306887e55 (patch)
treed5aab2110348f09cbd598b49d9c6851ba8c8e8ae /webAO/ui.js
parentcd163b792afcb22668bdd596e39304a53f739096 (diff)
fill space
Diffstat (limited to 'webAO/ui.js')
-rw-r--r--webAO/ui.js16
1 files changed, 3 insertions, 13 deletions
diff --git a/webAO/ui.js b/webAO/ui.js
index 8520c12..cdabd70 100644
--- a/webAO/ui.js
+++ b/webAO/ui.js
@@ -203,8 +203,6 @@ if (isMobileDevice) {
golden.loadLayout(config);
}
-console.log(golden.root.contentItems[0].contentItems[0].contentItems[0]);
-
function adjustSplitter() {
if (isMobileDevice) return; // Skip for mobile layout
const column = golden.root.contentItems[0].contentItems[0];
@@ -222,17 +220,9 @@ function adjustSplitter() {
const percentage = Math.min(90, Math.max(10, (totalHeight / columnHeight) * 100));
icItem.element.style.height = `${totalHeight}px`;
icOptionsItem.element.style.height = `calc(100% - ${totalHeight}px)`;
-
- // Safely access nested child elements with proper checks
- if (icOptionsItem && icOptionsItem.child && icOptionsItem.child[1]) {
- icOptionsItem.child[1].element.style.height = `100%`;
- if (icOptionsItem.child[1].child && icOptionsItem.child[1].child[0]) {
- icOptionsItem.child[1].child[0].element.style.height = `100%`;
- if (icOptionsItem.child[1].child[0].child && icOptionsItem.child[1].child[0].child[0]) {
- icOptionsItem.child[1].child[0].child[0].element.style.height = `100%`;
- }
- }
- }
+ icOptionsItem.element.children[1].style.height = `100%`;
+ icOptionsItem.element.children[1].children[0].style.height = `100%`;
+ icOptionsItem.element.children[1].children[0].children[0].style.height = `100%`;
}
window.addEventListener('resize', () => setTimeout(adjustSplitter, 100));