feat: S/M/L height drives mode-select row vs column layout
When height is set to S, mode-select collapses to a row (mode button + compact tools toggle side by side). M and L keep the vertical column layout where each control gets its own full-width row. Driven by data-size attribute set in JS so the switch is instant on click, not reliant on a viewport media query. Removed the redundant max-height landscape query. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -156,12 +156,16 @@
|
||||
inputEl.style.height = Math.max(Math.min(sh, maxHeight), minH) + 'px';
|
||||
}
|
||||
|
||||
const modeSelectEl = document.getElementById('mode-select');
|
||||
|
||||
function updateHeightUI() {
|
||||
if (!heightCycleBtn) return;
|
||||
const idx = HEIGHT_SIZES.indexOf(maxHeight);
|
||||
const i = idx >= 0 ? idx : 0;
|
||||
heightCycleBtn.textContent = HEIGHT_LABELS[i];
|
||||
heightCycleBtn.title = HEIGHT_TITLES[i];
|
||||
// Drive row/column layout via data attribute
|
||||
if (modeSelectEl) modeSelectEl.dataset.size = HEIGHT_LABELS[i].toLowerCase();
|
||||
}
|
||||
|
||||
if (heightCycleBtn) {
|
||||
|
||||
Reference in New Issue
Block a user