From 028045535689d2c5f0d100f3fb928a7f11df3c84 Mon Sep 17 00:00:00 2001 From: Giteabot Date: Thu, 23 Apr 2026 03:52:48 +0800 Subject: [PATCH] Fix button layout shift when collapsing file tree in editor (#37363) (#37375) Backport #37363 by @bytedream --- old: https://github.com/user-attachments/assets/136a9ce8-f229-4583-bf19-75258d085513 new: https://github.com/user-attachments/assets/21b7c885-00f4-4295-9191-07b66ca58b64 Signed-off-by: wxiaoguang Co-authored-by: bytedream Co-authored-by: silverwind Co-authored-by: Claude (Opus 4.7) Co-authored-by: wxiaoguang --- web_src/css/modules/breadcrumb.css | 1 + web_src/css/repo.css | 11 ++++++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/web_src/css/modules/breadcrumb.css b/web_src/css/modules/breadcrumb.css index 77e31ef627..39a896e9bb 100644 --- a/web_src/css/modules/breadcrumb.css +++ b/web_src/css/modules/breadcrumb.css @@ -1,6 +1,7 @@ .breadcrumb { display: flex; align-items: center; + flex-wrap: wrap; gap: 3px; overflow-wrap: anywhere; } diff --git a/web_src/css/repo.css b/web_src/css/repo.css index 923aef04ba..d11274abb2 100644 --- a/web_src/css/repo.css +++ b/web_src/css/repo.css @@ -192,18 +192,19 @@ td .commit-summary { } .repo-editor-header { + /* it should match ".repo-button-row" so the tree toggle button stays aligned */ + margin: 8px 0; display: flex; - margin: 1rem 0; - padding: 3px 0; - width: 100%; - gap: 0.5em; align-items: center; + gap: 8px; + width: 100%; } .repo-editor-header input { vertical-align: middle !important; width: auto !important; - padding: 7px 8px !important; + height: 30px !important; + padding: 5px 8px !important; margin-right: 5px !important; }