Skip to content

Commit 9b348d0

Browse files
mpstatonclaude
andcommitted
fix(org-workbench, layout): narrow panes — roster auto-hides with a toggle, card contents actually contain
Tiled next to Search & Add the workbench misbehaved twice: the roster kept its 300px in a pane that couldn't afford it, and the org card's long link URLs and people rows ran past the card's right border — the flex/grid min-width:auto trap (.ow-url had ellipsis styling that could never engage because the item refused to shrink). min-width:0 lands down the chain (card, lists-grid items, entry rows, .ow-url with flex:1, person name/row), and the roster auto-hides below 860px with an always-available ◀/▶ orgs toggle overriding auto in either direction. Browser-drive verified at 720px on the Sterling card: 0px card overflow, 0px link spill, no horizontal scroll, toggle round-trips. Closes #38. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UvYzx7vDWeafnkAi2nEQeb
1 parent 7335ede commit 9b348d0

3 files changed

Lines changed: 33 additions & 8 deletions

File tree

apps/org-workbench/src/App.svelte

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,16 @@
7272
let creating = $state(false);
7373
let searchQuery = $state('');
7474
75+
// Roster responsiveness (gh #38): in a narrow tiling pane the roster's
76+
// 300px is unaffordable — auto-hide below the threshold, with a manual
77+
// ◀/▶ toggle that overrides the auto behavior in either direction.
78+
const ROSTER_AUTO_HIDE_PX = 860;
79+
let columnsWidth = $state(0);
80+
let rosterManual = $state<boolean | null>(null);
81+
const rosterVisible = $derived(
82+
rosterManual ?? !(columnsWidth > 0 && columnsWidth < ROSTER_AUTO_HIDE_PX),
83+
);
84+
7585
function onCreateOpen(org_slug: string) {
7686
creating = false;
7787
void loadOrg(org_slug);
@@ -135,6 +145,14 @@
135145
<span class="ow-ws status-{status}">{status}</span>
136146
</div>
137147
<div class="ow-search-row">
148+
<button
149+
type="button"
150+
class="ow-add-go"
151+
title={rosterVisible ? 'Hide the org roster' : 'Show the org roster'}
152+
onclick={() => (rosterManual = !rosterVisible)}
153+
>
154+
{rosterVisible ? '◀ orgs' : '▶ orgs'}
155+
</button>
138156
<OrgSearch {client} onpick={onPick} onquery={(q) => (searchQuery = q)} />
139157
<button
140158
type="button"
@@ -156,8 +174,8 @@
156174
{/if}
157175
</header>
158176

159-
<div class="ow-columns">
160-
{#if status === 'open'}
177+
<div class="ow-columns" bind:clientWidth={columnsWidth}>
178+
{#if status === 'open' && rosterVisible}
161179
<OrgRoster {client} activeSlug={org?.slug ?? null} onpick={(slug) => void loadOrg(slug)} />
162180
{/if}
163181
<main class="ow-body">

apps/org-workbench/src/app.css

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
.ow-roster-counts { font-size: 0.72rem; color: var(--color-text-muted, #9aa0aa); }
7272
.ow-roster-corpus.zero { color: var(--color-error-text, #f3a3a3); font-weight: 600; }
7373
.ow-loading, .ow-empty-state { color: var(--color-text-muted, #9aa0aa); }
74-
.ow-card { border: 1px solid var(--color-border, #2a2c33); border-radius: 8px; background: var(--color-surface, #1c1e25); padding: 1rem 1.25rem; }
74+
.ow-card { border: 1px solid var(--color-border, #2a2c33); border-radius: 8px; background: var(--color-surface, #1c1e25); padding: 1rem 1.25rem; min-width: 0; overflow: hidden; }
7575
.ow-card-head { display: flex; align-items: baseline; gap: 0.75rem; flex-wrap: wrap; }
7676
.ow-card-name { margin: 0; font-size: 1.15rem; }
7777
.ow-card-slug { color: var(--color-text-muted, #9aa0aa); font-size: 0.8rem; }
@@ -81,6 +81,10 @@
8181

8282
/* additive lists */
8383
.ow-lists { display: grid; gap: 1rem; margin-top: 1.1rem; }
84+
/* Flex/grid items default to min-width:auto and refuse to shrink — the
85+
root of the narrow-pane spill (gh #38). Zero it down the chain so
86+
ellipsis/wrapping can actually engage. */
87+
.ow-lists > * { min-width: 0; }
8488
.ow-list { border-top: 1px solid var(--color-border, #2a2c33); padding-top: 0.75rem; }
8589
.ow-list-head { display: flex; align-items: center; justify-content: space-between; }
8690
.ow-list-title { margin: 0; font-size: 0.9rem; }
@@ -97,9 +101,9 @@
97101
.ow-add-go:disabled { opacity: 0.6; cursor: default; }
98102

99103
.ow-entries { list-style: none; margin: 0.5rem 0 0; padding: 0; display: grid; gap: 0.3rem; }
100-
.ow-entry { display: flex; align-items: baseline; gap: 0.6rem; font-size: 0.85rem; }
104+
.ow-entry { display: flex; align-items: baseline; gap: 0.6rem; font-size: 0.85rem; min-width: 0; }
101105
.ow-kind { flex-shrink: 0; font-size: 0.7rem; padding: 1px 6px; border-radius: 3px; background: var(--color-border, #2a2c33); color: var(--color-text-muted, #cfd3da); }
102-
.ow-url { color: var(--color-link, #8ab4f8); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
106+
.ow-url { color: var(--color-link, #8ab4f8); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1 1 auto; }
103107
.ow-url:hover { text-decoration: underline; }
104108
.ow-date { margin-left: auto; flex-shrink: 0; color: var(--color-text-muted, #9aa0aa); font-size: 0.72rem; font-variant-numeric: tabular-nums; }
105109
.ow-entry-action { flex-shrink: 0; font-size: 0.7rem; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--color-border, #2a2c33); background: var(--color-bg, #14151a); color: var(--color-text-muted, #cfd3da); font-family: inherit; cursor: pointer; }
@@ -114,7 +118,8 @@
114118
.ow-people-list { list-style: none; margin: 0.5rem 0 0.75rem; padding: 0; display: grid; gap: 0.35rem; }
115119
.ow-person-row { display: flex; align-items: baseline; gap: 0.6rem; width: 100%; text-align: left; background: var(--color-bg, #14151a); border: 1px solid var(--color-border, #2a2c33); border-radius: 6px; color: inherit; font: inherit; padding: 0.45rem 0.7rem; cursor: pointer; }
116120
.ow-person-row:hover { background: var(--color-border, #2a2c33); }
117-
.ow-person-name { font-size: 0.88rem; }
121+
.ow-person-row { min-width: 0; }
122+
.ow-person-name { font-size: 0.88rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
118123
.ow-person-role { color: var(--color-text-muted, #9aa0aa); font-size: 0.75rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
119124
.ow-person-relevance { flex-shrink: 0; font-size: 0.7rem; padding: 1px 6px; border-radius: 3px; background: var(--color-ok-bg, #173a26); color: var(--color-ok-text, #6ee7a8); font-variant-numeric: tabular-nums; }
120125
.ow-person-meta { margin-left: auto; flex-shrink: 0; color: var(--color-text-muted, #9aa0aa); font-size: 0.72rem; }

context-v/issues/Org-Workbench-Narrow-Layout-Roster-Doesnt-Collapse-Card-Contents-Spill.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,17 @@ authors:
77
- Michael Staton
88
augmented_with:
99
- Claude Code on Claude Fable 5
10-
semantic_version: 0.0.0.1
10+
semantic_version: 0.0.0.2
1111
tags:
1212
- Issue
1313
- Usability
1414
- Augment-It
1515
- Org-Workbench
1616
- Layout
1717
- CSS
18-
status: Open
18+
status: Shipped
19+
date_first_published: 2026-07-24
20+
post_ship_note: "Shipped 2026-07-24 — min-width:0 down the card's flex/grid chain (+ .ow-url flex:1 so ellipsis engages), roster auto-hides under 860px with the ◀/▶ orgs toggle. Browser-drive verified at 720px on the Sterling card: 0px card overflow, 0px link spill, toggle round-trips. gh #38 closed."
1921
---
2022

2123
# Narrow-pane workbench: roster hogs, card spills

0 commit comments

Comments
 (0)