@@ -231,16 +252,7 @@
diff --git a/static/css/layout.css b/static/css/layout.css
index c6850b9..39743fa 100644
--- a/static/css/layout.css
+++ b/static/css/layout.css
@@ -616,6 +616,28 @@ body.is-dragging-window .ui-tool-title-bar {
}
}
+@media (max-width: 899px) {
+ .ui-tool-window {
+ top: 2.85rem !important;
+ left: 0 !important;
+ right: 0 !important;
+ bottom: 0 !important;
+ width: 100vw !important;
+ height: calc(100dvh - 2.85rem) !important;
+ min-width: 0;
+ min-height: 0;
+ max-width: 100vw;
+ max-height: calc(100dvh - 2.85rem);
+ resize: none;
+ overflow: auto;
+ transform: none !important;
+ }
+
+ .ui-tool-title-bar {
+ cursor: default;
+ }
+}
+
@media (min-width: 2560px), (min-resolution: 2dppx) {
:root {
--ui-scale: 1.24;
diff --git a/static/js/ui-controls.js b/static/js/ui-controls.js
index 0c7ba2d..58bc524 100644
--- a/static/js/ui-controls.js
+++ b/static/js/ui-controls.js
@@ -12,6 +12,10 @@
let floatingWindowZ = 80;
let windowLayouts = {};
+ function isMobileViewport() {
+ return window.matchMedia('(max-width: 899px)').matches;
+ }
+
function applyTheme(theme) {
const normalized = theme || DEFAULT_THEME;
document.documentElement.setAttribute('data-ui-theme', normalized);
@@ -164,6 +168,12 @@
if (!id) {
return;
}
+ if (isMobileViewport()) {
+ windowEl.style.right = 'auto';
+ windowEl.style.bottom = 'auto';
+ windowEl.style.transform = 'none';
+ return;
+ }
const defaults = DEFAULT_WINDOW_LAYOUTS[id];
const saved = windowLayouts[id];
const normalized = normalizeLayout(saved, defaults);
@@ -208,6 +218,9 @@
if (!windowEl || windowEl.classList.contains('hidden')) {
return;
}
+ if (isMobileViewport()) {
+ return;
+ }
bringWindowToFront(windowEl);
const rect = windowEl.getBoundingClientRect();
@@ -269,6 +282,9 @@
if (windowEl.classList.contains('hidden')) {
return;
}
+ if (isMobileViewport()) {
+ return;
+ }
persistWindowLayout(windowEl);
});
});
@@ -285,6 +301,9 @@
});
window.addEventListener('resize', () => {
+ if (isMobileViewport()) {
+ return;
+ }
document.querySelectorAll('.ui-tool-window').forEach((windowEl) => {
const id = windowEl.id;
if (!id) {