From 0673550d5810fd9d17589465c6540cd6e26e7cb3 Mon Sep 17 00:00:00 2001 From: John O'Keefe Date: Mon, 2 Nov 2026 09:46:58 -0500 Subject: [PATCH] =?UTF-8?q?fix(admin):=20library=20rows=20collapse=20on=20?= =?UTF-8?q?phones=20=E2=80=94=20chips=20hid=20the=20name?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Visual review of the first flex-wrap attempt: with the name block at flex-1 (0 basis), the row never registered as overfull, so wrap never fired and the shrink-0 chips still overprinted Scan/Manage. Dropping flex-1 lets wrap trigger — but then the chips starved the name down to 'P…'. The type/folders chips are the least-important content in the row: hidden below sm, so phones show icon + full name/description with Scan/Manage on a second row; desktop keeps the single-line layout with chips (>=640px unchanged). --- templates/admin_library.templ | 13 ++++-- templates/admin_library_templ.go | 78 ++++++++++++++++---------------- 2 files changed, 48 insertions(+), 43 deletions(-) diff --git a/templates/admin_library.templ b/templates/admin_library.templ index 1962b2e0..100b0b27 100644 --- a/templates/admin_library.templ +++ b/templates/admin_library.templ @@ -200,8 +200,13 @@ templ LibraryList(user User, libraries []LibraryData, users []User) {
for _, library := range libraries {
-
-
+
+ +
@Icon("library", "h-5 w-5") @@ -211,12 +216,12 @@ templ LibraryList(user User, libraries []LibraryData, users []User) {

{ library.Description }

}
- + if library.FolderCount > 0 { - + diff --git a/templates/admin_library_templ.go b/templates/admin_library_templ.go index 05744977..7224e531 100644 --- a/templates/admin_library_templ.go +++ b/templates/admin_library_templ.go @@ -288,7 +288,7 @@ func LibraryList(user User, libraries []LibraryData, users []User) templ.Compone return templ_7745c5c3_Err } for _, library := range libraries { - templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 26, "
") + templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 26, "
") if templ_7745c5c3_Err != nil { return templ_7745c5c3_Err } @@ -303,7 +303,7 @@ func LibraryList(user User, libraries []LibraryData, users []User) templ.Compone var templ_7745c5c3_Var9 string templ_7745c5c3_Var9, templ_7745c5c3_Err = templ.JoinStringErrs(library.Name) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `admin_library.templ`, Line: 209, Col: 92} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `admin_library.templ`, Line: 214, Col: 92} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var9)) if templ_7745c5c3_Err != nil { @@ -321,7 +321,7 @@ func LibraryList(user User, libraries []LibraryData, users []User) templ.Compone var templ_7745c5c3_Var10 string templ_7745c5c3_Var10, templ_7745c5c3_Err = templ.JoinStringErrs(library.Description) if templ_7745c5c3_Err != nil { - return templ.Error{Err: templ_7745c5c3_Err, FileName: `admin_library.templ`, Line: 211, Col: 95} + return templ.Error{Err: templ_7745c5c3_Err, FileName: `admin_library.templ`, Line: 216, Col: 95} } _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString(templ.EscapeString(templ_7745c5c3_Var10)) if templ_7745c5c3_Err != nil { @@ -332,7 +332,7 @@ func LibraryList(user User, libraries []LibraryData, users []User) templ.Compone return templ_7745c5c3_Err } } - templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 31, "
") + templ_7745c5c3_Err = templruntime.WriteString(templ_7745c5c3_Buffer, 31, "