From 563237a444507eaf3e7b8f0ee355d8414ec8cc86 Mon Sep 17 00:00:00 2001 From: Fabrizio Ferri Benedetti Date: Fri, 19 Jun 2026 18:40:22 +0200 Subject: [PATCH] codex: limit ungrouped spaces to two columns on landing page Reduces the outer grid from 3 to 2 columns so a lone ungrouped card leaves at most one empty slot per row instead of two. Groups with 2+ docsets now always span full width; their internal grid still renders up to 3 columns inside the group box. Co-Authored-By: Claude Sonnet 4.6 --- src/Elastic.Codex/Landing/LandingView.cshtml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Elastic.Codex/Landing/LandingView.cshtml b/src/Elastic.Codex/Landing/LandingView.cshtml index 50fa08e9e..5a63dc83b 100644 --- a/src/Elastic.Codex/Landing/LandingView.cshtml +++ b/src/Elastic.Codex/Landing/LandingView.cshtml @@ -131,14 +131,14 @@ .OrderBy(x => x.sortKey, StringComparer.OrdinalIgnoreCase) .ToList(); } -
+
@foreach (var item in sortedSections) { @if (item.group is { } group) { var repoCount = group.DocumentationSetInfos.Count; - var colSpan = repoCount >= 5 || repoCount == 3 ? "col-span-full" : repoCount >= 2 ? "col-span-1 md:col-span-2" : "col-span-1"; - var innerCols = repoCount >= 5 || repoCount == 3 ? "grid-cols-1 md:grid-cols-2 lg:grid-cols-3" : repoCount >= 2 ? "grid-cols-1 md:grid-cols-2" : "grid-cols-1"; + var colSpan = repoCount >= 2 ? "col-span-full" : "col-span-1"; + var innerCols = repoCount >= 3 ? "grid-cols-1 md:grid-cols-2 lg:grid-cols-3" : repoCount >= 2 ? "grid-cols-1 md:grid-cols-2" : "grid-cols-1";