Skip to content

Commit 8790d7a

Browse files
committed
fix(brand): size large logos by their title, like the empty state
The owner set the reference on the plain empty state: a 6rem logo above its text-3xl title. Large logos now follow their title instead of a fixed 8rem: the home page and the branded empty session use 6rem beside the same text-3xl title, and the narrow session column, whose title shrinks to 1.5rem, shows the logo at 4.8rem, the same 3.2 ratio. The loading screen keeps 8rem beside its larger 2.8rem title. dev-docs/UI_CONVENTIONS.md records the rule so a logo changes with its title and never with the window. Validated by rendering the real home page, branded and plain empty states, the narrow session column and the loading screen in dark and light themes at 1100 x 760: logo/title 96/30 px, 96/30 px, 96/30 px, 76.8/24 px and 128/44.8 px. The owner's installed app shows the same sizes through a temporary override; the UI typecheck passes.
1 parent d71e3c6 commit 8790d7a

4 files changed

Lines changed: 10 additions & 3 deletions

File tree

‎dev-docs/UI_CONVENTIONS.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ Shared renderer rules for dialogs, utility windows, icon toggles, surfaces and s
1111
- Movable utility windows opt into `DismissibleWindow.draggable` and mark their existing top bar with `data-window-drag-handle`; keep drag geometry shared and controls interactive. `--window-visible-height` bounds their height to the visual viewport; native scrolling and a sticky existing top bar keep results, pagination and drag/close controls reachable.
1212
- Appearance mode and the saved light/dark selections are independent (`lib/appearance-preferences.ts`). Message/tool cards use the muted surface; preferences use the same secondary surface as the main panels. Show a subtle local rollover with `--surface-hover-overlay` over the preserved selected background, never by substituting a generic panel or the secondary surface; right-panel canvas button rollover overrides live in `styles/panels/control-hover.css`.
1313
- `index.css` re-anchors `box-sizing: border-box` on every `details > :not(summary)`: the component library resets elements to `box-sizing: inherit`, so folded content would inherit content-box from the browser's own details slot and overflow full-width controls. Keep that rule rather than patching individual disclosures.
14+
- Large brand logos (home page, empty states, loading screen) follow their title, never the window: 3.2 times a `text-3xl` title (6rem), 4.8rem beside the narrow session column's 1.5rem title, and 8rem beside the loading screen's larger title. Resize the logo whenever its title's size changes.
1415
- Keep the global scrollbar-width default at zero specificity (`:where(...)` in `src/index.css`) so component visibility rules win. The timeline shares the transcript's standard native scrollbar (geometry, rail ownership and thumb drags: `dev-docs/SESSION_HISTORY_NAVIGATION.md`); validate with the full stylesheet and real thumb gestures on mixed-height transcripts.

‎packages/ui/src/components/branded-empty-state.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const BrandedEmptyState: Component<BrandedEmptyStateProps> = (props) => {
1717
<div class={`empty-state ${props.class ?? ""}`.trim()}>
1818
<div class="empty-state-content">
1919
<div class="flex flex-col items-center gap-3 mb-6">
20-
<img src={codeNomadLogo} alt={t("messageSection.empty.logoAlt")} class="empty-state-logo h-32 w-auto" loading="lazy" />
20+
<img src={codeNomadLogo} alt={t("messageSection.empty.logoAlt")} class="empty-state-logo h-24 w-auto" loading="lazy" />
2121
<h1 class="empty-state-brand-title text-3xl font-semibold text-primary">{t("messageSection.empty.brandTitle")}</h1>
2222
</div>
2323
{props.title ? <h3>{props.title}</h3> : null}

‎packages/ui/src/styles/components/folder-home.css‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@
1919
margin-bottom: 1.5rem;
2020
}
2121

22-
/* Large logos keep one size (8rem) and never grow with the window. */
22+
/* Brand logos are 3.2 times their title's font size (6rem beside text-3xl) and never
23+
grow with the window. */
2324
.folder-home-logo {
24-
height: 8rem;
25+
height: 6rem;
2526
}
2627

2728
.folder-home-content,

‎packages/ui/src/styles/panels/empty-loading.css‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@
2020
line-height: 2rem;
2121
}
2222

23+
/* The logo follows its title: 3.2 times the narrow title's 1.5rem. */
24+
.session-center-column[data-session-center-width="narrow"] .empty-state-logo {
25+
height: 4.8rem;
26+
}
27+
2328
.empty-state-content h3 {
2429
font-size: var(--font-size-xl);
2530
margin-bottom: 12px;

0 commit comments

Comments
 (0)