Skip to content

Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.

Go

fix(views): roomier Work panel inbox rows and a 280px default panel width (MUL-9334) (#10671)

Jiayuan Zhangb60441fb360d
diff --git a/docs/theming.md b/docs/theming.md
index 35162e9e88..0e207bdef0 100644
--- a/docs/theming.md
+++ b/docs/theming.md
@@ -795,7 +795,7 @@ and dark differ, both defaults are given.
| `--space-lg` | `1.5rem` | Spacing step: an object page's side padding, the issue page's top padding on phones. |
| `--space-xl` | `2rem` | Spacing step: an object page's top padding, the issue page's padding. |
| `--page-padding-x` | `var(--space-md, 1rem)` | Side padding of page headers, the toolbars under them and full-width lists. |
-| `--sidebar-panel-width` | `240px` | Starting width of the navigation panel, kept between 200px and 320px. Once the person drags its edge, their width wins. |
+| `--sidebar-panel-width` | `280px` | Starting width of the navigation panel, kept between 200px and 320px. Once the person drags its edge, their width wins. |
| `--content-max-width` | `clamp(56rem, 70cqi, 70rem)` | Widest the reading column gets on an issue page and in chat. |
| `--object-page-max-width` | `760px` | Widest the body of a project, agent, squad, runtime or other object page gets. |
diff --git a/packages/core/appearance/theme-variables.ts b/packages/core/appearance/theme-variables.ts
index efbb09a1e7..1bb9cac4fa 100644
--- a/packages/core/appearance/theme-variables.ts
+++ b/packages/core/appearance/theme-variables.ts
@@ -283,7 +283,7 @@ const LAYOUT: Entry[] = [
["space-lg", "Spacing step: an object page's side padding, the issue page's top padding on phones.", "1.5rem"],
["space-xl", "Spacing step: an object page's top padding, the issue page's padding.", "2rem"],
["page-padding-x", "Side padding of page headers, the toolbars under them and full-width lists.", "var(--space-md, 1rem)"],
- ["sidebar-panel-width", "Starting width of the navigation panel, kept between 200px and 320px. Once the person drags its edge, their width wins.", "240px"],
+ ["sidebar-panel-width", "Starting width of the navigation panel, kept between 200px and 320px. Once the person drags its edge, their width wins.", "280px"],
["content-max-width", "Widest the reading column gets on an issue page and in chat.", "clamp(56rem, 70cqi, 70rem)"],
["object-page-max-width", "Widest the body of a project, agent, squad, runtime or other object page gets.", "760px"],
];
diff --git a/packages/ui/components/ui/sidebar.tsx b/packages/ui/components/ui/sidebar.tsx
index e9db976a5c..577f657e42 100644
--- a/packages/ui/components/ui/sidebar.tsx
+++ b/packages/ui/components/ui/sidebar.tsx
@@ -26,13 +26,13 @@ import {
} from "@multica/ui/components/ui/tooltip"
import { PanelLeftIcon } from "@multica/ui/icons"
-const SIDEBAR_WIDTH_DEFAULT = 240
+const SIDEBAR_WIDTH_DEFAULT = 280
const SIDEBAR_WIDTH_MIN = 200
const SIDEBAR_WIDTH_MAX = 320
const SIDEBAR_WIDTH_STORAGE_KEY = "sidebar_width"
// Until the person drags the edge, a theme picks the width (docs/theming.md).
// Keep the bounds and default in step with the three constants above.
-const SIDEBAR_WIDTH_THEMED = "clamp(200px, var(--sidebar-panel-width, 240px), 320px)"
+const SIDEBAR_WIDTH_THEMED = "clamp(200px, var(--sidebar-panel-width, 280px), 320px)"
// List columns (Inbox, Chat) hold two-line rows with an avatar, so they get
// their own width instead of the nav's: one shared value is either too narrow
// for the rows or too wide for the nav's short labels.
diff --git a/packages/views/layout/list-column.test.tsx b/packages/views/layout/list-column.test.tsx
index 5793a85087..5a17daf013 100644
--- a/packages/views/layout/list-column.test.tsx
+++ b/packages/views/layout/list-column.test.tsx
@@ -15,8 +15,8 @@ function Reader() {
return null;
}
-/** No stored width: the theme's, or 240px when it sets none. */
-const UNSTORED_SIDEBAR_WIDTH = "clamp(200px, var(--sidebar-panel-width, 240px), 320px)";
+/** No stored width: the theme's, or 280px when it sets none. */
+const UNSTORED_SIDEBAR_WIDTH = "clamp(200px, var(--sidebar-panel-width, 280px), 320px)";
describe("ListColumn", () => {
it("collapses the list column from its edge, like the space panel", () => {
diff --git a/packages/views/layout/panels/inbox-section.tsx b/packages/views/layout/panels/inbox-section.tsx
index 831a5161d1..a1c99e4692 100644
--- a/packages/views/layout/panels/inbox-section.tsx
+++ b/packages/views/layout/panels/inbox-section.tsx
@@ -175,7 +175,7 @@ export function InboxSection({
}
>
{displayed.length > 0 ? (
- <PanelList data-sidebar-list={INBOX_LIST}>
+ <PanelList data-sidebar-list={INBOX_LIST} className={compact ? undefined : "space-y-0.5"}>
{displayed.map((item) => (
<InboxRow
key={item.id}
@@ -417,7 +417,7 @@ function InboxRow({
if (event.key === "Enter") setCardOpen(false);
}}
{...panelRowAnchor(active)}
- className={cn(PANEL_ROW_CLASS, panelRowStateClass(active), "relative", !compact && "items-start py-[5px]")}
+ className={cn(PANEL_ROW_CLASS, panelRowStateClass(active), "relative", !compact && "items-start py-2")}
>
{statusIcon ||
(compact ? (
@@ -451,7 +451,7 @@ function InboxRow({
{statusText}
{agentBadge || time}
</span>
- <span className="flex min-w-0 items-center gap-2 text-caption leading-4 text-muted-foreground">
+ <span className="mt-0.5 flex min-w-0 items-center gap-2 text-caption leading-4 text-muted-foreground">
<span className="flex min-w-0 flex-1 items-center gap-1.5">
{/* The status took the avatar's column; it stays with the name. */}
{statusIcon && <InboxActorAvatar item={item} size="xs" />}
@@ -493,7 +493,7 @@ function InboxRow({
className={cn(
"absolute right-1.5 z-10 hidden size-5 items-center justify-center rounded-md text-muted-foreground group-hover/inbox:flex group-focus-within/inbox:flex hover:bg-surface-selected hover:text-foreground",
// On the title's line, where the time was.
- compact ? "top-1/2 -translate-y-1/2" : "top-[5px]",
+ compact ? "top-1/2 -translate-y-1/2" : "top-2",
)}
onClick={(event) => {
event.preventDefault();
diff --git a/packages/views/layout/sidebar-resize.test.tsx b/packages/views/layout/sidebar-resize.test.tsx
index 4877fce4b1..c8827d5457 100644
--- a/packages/views/layout/sidebar-resize.test.tsx
+++ b/packages/views/layout/sidebar-resize.test.tsx
@@ -9,8 +9,8 @@ import {
} from "@multica/ui/components/ui/sidebar";
import { renderWithI18n } from "../test/i18n";
-/** No stored width: the theme's, or 240px when it sets none. */
-const UNSTORED_SIDEBAR_WIDTH = "clamp(200px, var(--sidebar-panel-width, 240px), 320px)";
+/** No stored width: the theme's, or 280px when it sets none. */
+const UNSTORED_SIDEBAR_WIDTH = "clamp(200px, var(--sidebar-panel-width, 280px), 320px)";
describe("left sidebar resizing", () => {
beforeEach(() => {