From 01de6272f3e73df0caa1dead3eb01be8db42d8f7 Mon Sep 17 00:00:00 2001 From: Zaldimmar Date: Wed, 30 Sep 2026 22:28:42 -0500 Subject: [PATCH 001/135] People tiles: a whole list shares one row when it fits When every group (a team's leads and members alike) fits side by side with tiles at three quarters of full width or wider, 10 at most, they share one line, each group's width following its head count; a board of 7 is one row rather than 5 and 2. Co-Authored-By: Claude Opus 5.5 --- src/components/PeopleTiles.css | 10 ++++++++++ src/components/PeopleTiles.tsx | 35 ++++++++++++++++++++++++++++++---- 2 files changed, 41 insertions(+), 4 deletions(-) diff --git a/src/components/PeopleTiles.css b/src/components/PeopleTiles.css index c75f990..d60f9b1 100644 --- a/src/components/PeopleTiles.css +++ b/src/components/PeopleTiles.css @@ -66,6 +66,16 @@ border-left: 1px solid var(--pl-rule); } +/* Everyone on one line (fitsOneRow in PeopleTiles.tsx): the groups + share it by head count, and the tiles narrow to fit. */ +.pl__groups[data-row="one"] { + flex-wrap: nowrap; +} + +.pl__groups[data-row="one"] .pl__group { + flex: var(--pl-share) 1 0; +} + .pl__group-head { display: flex; flex-direction: column; diff --git a/src/components/PeopleTiles.tsx b/src/components/PeopleTiles.tsx index 400ec9e..2f8e1bf 100644 --- a/src/components/PeopleTiles.tsx +++ b/src/components/PeopleTiles.tsx @@ -56,7 +56,10 @@ import "./PeopleTiles.css"; * Rows fill (balancedColumns): as many tiles across as fit, never * fewer than 2 or more than 10, one fewer when that would leave a * lone tile on the last row. When 2 don't fit at full size they - * shrink. + * shrink. And when everyone (every group, leads and members alike) + * fits on one line with tiles at ONE_ROW_SHRINK of full width or + * wider, they all share that one line instead (fitsOneRow): a + * board of 7 reads as one row, not 5 and 2. * * Details open in a panel right under the tile, over what follows * (flipped to end at the tile's right edge when it would run off @@ -484,6 +487,9 @@ export function PeopleTilesView({ } const open = openKey ? findByKey(resolvedGroups, openKey) : null; + const oneRow = + room !== null && overflow !== "scroll" && + fitsOneRow(resolvedGroups.map((group) => group.people.length), room.width, room.tile, room.gap); const anchored = overflow !== "scroll"; const closePanel = () => { setOpenKey(null); @@ -537,13 +543,17 @@ export function PeopleTilesView({ {...rest} >