From 73c9495a9602e8a19d6955f9595b1ee6d3f816d8 Mon Sep 17 00:00:00 2001 From: wenil Date: Mon, 25 May 2026 13:01:50 +0300 Subject: [PATCH] holder: fix scad editor panel hidden bug + smaller default height The CSS rule `.scad-panel { display: flex }` was overriding the HTML `hidden` attribute (CSS specificity beats the user-agent rule on the attribute). Effect: the Close button set hidden=true but the panel stayed visible, and the panel was visible on first load too. - Explicit `.scad-panel[hidden] { display: none }` rule restores the intended behaviour: Close hides, initial load is hidden. - Default height 45% -> 30%, with min-height 180px so the editor isn't cramped even on small viewports. --- static/holder.css | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/static/holder.css b/static/holder.css index 6e0fc4c..7047afc 100644 --- a/static/holder.css +++ b/static/holder.css @@ -178,12 +178,19 @@ .scad-panel { position: absolute; left: 0; right: 0; bottom: 0; - height: 45%; + height: 30%; + min-height: 180px; background: var(--bg, #11141a); border-top: 1px solid var(--border, #2a2f3a); display: flex; flex-direction: column; z-index: 2; + overflow: hidden; +} +/* The [hidden] attribute alone is overridden by display:flex above — + * make the hide explicit so the Close button actually closes the panel. */ +.scad-panel[hidden] { + display: none; } .scad-panel-bar { display: flex;