Skip to content

Commit 51039bc

Browse files
committed
style: remove redundant content heading on Connections page
The Connections page displayed the page title three times (top bar, content h1, and section label). Removed the content-area h1 heading and its subtitle to match the pattern used by other pages like Board and Brain.
1 parent 63d8f4f commit 51039bc

File tree

2 files changed

+53
-14
lines changed

2 files changed

+53
-14
lines changed

apps/desktop/src/features/connections/components/ConnectionsWorkspace.tsx

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -131,20 +131,6 @@ export function ConnectionsWorkspace({
131131

132132
return (
133133
<div className="mx-auto flex w-full max-w-4xl flex-1 flex-col gap-4">
134-
<div className="flex items-start gap-4">
135-
<div className="flex size-12 shrink-0 items-center justify-center rounded-xl bg-primary/10 shadow-sm ring-1 ring-primary/15">
136-
<Link2Icon className="size-6 text-primary" />
137-
</div>
138-
<div>
139-
<h1 className="font-display text-[26px] font-bold tracking-[-0.02em] text-foreground">
140-
Connections
141-
</h1>
142-
<p className="mt-1 text-[13px] leading-relaxed text-muted-foreground">
143-
Manage AI providers and messaging channels.
144-
</p>
145-
</div>
146-
</div>
147-
148134
{errorMessage ? (
149135
<MessageBanner tone="error">{errorMessage}</MessageBanner>
150136
) : null}
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
import assert from "node:assert/strict";
2+
import test from "node:test";
3+
import { readFileSync } from "node:fs";
4+
import { resolve } from "node:path";
5+
6+
const src = readFileSync(
7+
resolve(import.meta.dirname, "ConnectionsWorkspace.tsx"),
8+
"utf-8",
9+
);
10+
11+
// ---------------------------------------------------------------------------
12+
// AC1: No redundant h1 "Connections" heading in content area
13+
// ---------------------------------------------------------------------------
14+
15+
void test("ConnectionsWorkspace does not render a standalone h1 heading", () => {
16+
assert.ok(
17+
!src.includes("<h1"),
18+
"Must NOT have an h1 heading — the top bar already provides the page title",
19+
);
20+
});
21+
22+
// ---------------------------------------------------------------------------
23+
// AC2: No orphaned subtitle text
24+
// ---------------------------------------------------------------------------
25+
26+
void test("ConnectionsWorkspace does not render the subtitle paragraph", () => {
27+
assert.ok(
28+
!src.includes("Manage AI providers and messaging channels"),
29+
"Must NOT include the subtitle 'Manage AI providers and messaging channels' — it is redundant",
30+
);
31+
});
32+
33+
// ---------------------------------------------------------------------------
34+
// AC3: Section label h2 still present
35+
// ---------------------------------------------------------------------------
36+
37+
void test("ConnectionsWorkspace still has section-label h2", () => {
38+
assert.ok(
39+
src.includes("section-label"),
40+
"Must keep the section-label h2 for the Connections section",
41+
);
42+
});
43+
44+
// ---------------------------------------------------------------------------
45+
// AC4: Section content (table, empty state) still present
46+
// ---------------------------------------------------------------------------
47+
48+
void test("ConnectionsWorkspace still renders connection table or empty state", () => {
49+
assert.ok(
50+
src.includes("<Table") || src.includes("No connections yet"),
51+
"Must still render the connections table or empty state",
52+
);
53+
});

0 commit comments

Comments
 (0)