Subject: [PATCH 2/5] gitweb: prevent project search bar from overflowing on mobile

From: "Rito Rhymes via GitGitGadget" <[email-masked]>
Date: Mon, 09 Feb 2026 23:17:15 +0000

From: Rito Rhymes <[email-masked]>

On narrow screens, the project search input can exceed the available width
and force page-wide horizontal scrolling.

Add side padding to the search container and cap the input to its container
width with border-box sizing, so the form stays within the viewport.

Signed-off-by: Rito Rhymes <[email-masked]>
---
 gitweb/static/gitweb.css | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/gitweb/static/gitweb.css b/gitweb/static/gitweb.css
index 48d2e51015..1fe120cd95 100644
--- a/gitweb/static/gitweb.css
+++ b/gitweb/static/gitweb.css
@@ -537,6 +537,13 @@ div.search {
 div.projsearch {
 	text-align: center;
 	margin: 20px 0px;
+	padding: 0 8px;
+	box-sizing: border-box;
+}
+
+div.projsearch input[type="text"] {
+	max-width: 100%;
+	box-sizing: border-box;
 }
 
 div.projsearch form {
-- 
gitgitgadget