Skip to content

feat(ui): design system, /research and /docs routes, layout fixes - #16

Merged
md-abid-hussain merged 1 commit into
mainfrom
ui-update
Aug 29, 2026
Merged

md-abid-hussain merged 1 commit into
mainfrom
ui-update

Conversation

@md-abid-hussain

Copy link
Copy Markdown
Owner

Applies the Claude Design import across the app and fixes the layout bugs
it exposed.

Design

  • Pine-green tokens on cool neutrals, Geist and Geist Mono.
  • Landing page argued in four numbered sections instead of one block of copy.
  • Hackathon sections carry a mono micro-label and close with a rule; titled
    lists are a bordered grid rather than cards; tracks are one full-width
    column with the prize beside the name.
  • A light/dark toggle in every header. Which icon shows is decided by CSS
    rather than by reading the theme during render: next-themes cannot resolve
    the theme on the server, so rendering from it means a hydration mismatch,
    and the usual mounted flag is a setState inside an effect this config
    rejects.

Bugs found on the way

  • A prize chip was shrink-0 with no cap. Prizes are not all "Mac Mini" — one
    is a 74-character sentence — so that chip measured 145px wider than its own
    card and overlapped the next column.
  • The hackathon tab strip carried a 15px vertical scrollbar. overflow-x: auto
    computes the other axis to auto too, and the tabs' -1px border overlap left
    exactly one pixel of vertical overflow for Chrome to hang a scrollbar off.
  • TitledList used sm:grid-cols-2, and sm: is a viewport query, so the run
    panel's narrow column was being split in two on a wide window.
  • The site header was 128px wider than the page it sat above. Containers now
    agree at max-w-6xl / 2xl:max-w-7xl.

Naming and routes

  • "Teach it" named the wrong actor — you hand it a URL and it does the
    research — so the label, the headings and the routes all say Research now.
    /ui/run and /ui/docs move to /research and /docs.
  • /docs drops the SDK's sidebar preset for a layout of ours. The presets mount
    ShellActions, a theme toggle and a settings gear, and it is not an
    overridable slot. Both were wrong here: the theme is controlled from
    next-themes, so the SDK's toggle fought the app's own, and the settings panel
    configures models, connectors and the sandbox.
  • The record panel beside the chat widens at 2xl. The chat cannot use extra
    width — the SDK caps its thread at 704px and the rail is 224px — so past
    928px every pixel it gains is empty gutter. At 1920 the panel goes 512 to
    704 and the waste drops from 479 to 288. Only 2xl, because below it the chat
    is already under its own cap.

@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Refresh design system, routes, and responsive layouts

✨ Enhancement 🐞 Bug fix 📝 Documentation ⚙️ Configuration changes 🕐 40+ Minutes

Grey Divider

AI Description

• Applies a pine-green Geist design system across landing and hackathon surfaces.
• Promotes research and docs workflows to top-level routes with consistent theme controls.
• Fixes prize overflow, tab scrollbars, narrow-panel grids, and widescreen spacing.
Diagram

graph TD
  D["Design system"] --> H["Shared header"] --> R["App routes"] --> L["Landing page"]
  R --> A["Research workspace"] --> S["Chat SDK"]
  R --> C["Docs chat"] --> S
  R --> K["Hackathon views"]
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Retain legacy route redirects
  • ➕ Preserves bookmarks and previously published /ui/run and /ui/docs links.
  • ➕ Allows route naming to change without breaking external consumers.
  • ➖ Keeps legacy terminology alive in routing configuration.
  • ➖ Adds redirect behavior and compatibility paths to maintain.
2. Keep the SDK sidebar preset
  • ➕ Inherits future layout behavior directly from the SDK.
  • ➕ Requires less app-owned chat layout code.
  • ➖ Cannot remove the preset's conflicting theme and settings actions through supported slots.
  • ➖ CSS-hiding preset controls would be brittle and accessibility-prone.

Recommendation: The app-owned chat layouts and shared presentation components are the right approach because they remove conflicting SDK controls and centralize responsive fixes. Add redirects from the former /ui/* URLs only if those routes have already been shared externally; otherwise the clean top-level routes are preferable.

Files changed (18) +679 / -245

Enhancement (10) +484 / -159
page.tsxAdd research navigation and theme control to docs +10/-6

Add research navigation and theme control to docs

• Replaces the legacy Teach link with top-level Research navigation. Adds the app-owned theme toggle to the docs header.

app/docs/page.tsx

globals.cssIntroduce pine-green tokens and unified typography +77/-59

Introduce pine-green tokens and unified typography

• Replaces warm theme values with cool-neutral and pine-green light/dark tokens, including readable chart ramps. Aliases heading typography to Geist sans and differentiates headings through weight, tracking, and text wrapping.

app/globals.css

page.tsxAlign hackathon index width and research terminology +2/-2

Align hackathon index width and research terminology

• Expands the page container at 2xl to match the shared header and renames the empty-state action from Teach to Research.

app/hackathons/page.tsx

layout.tsxStandardize application fonts on Geist +13/-20

Standardize application fonts on Geist

• Replaces DM Sans and Noto Serif with Geist and Geist Mono. Simplifies root font variables while preserving existing heading utility compatibility.

app/layout.tsx

page.tsxRestructure landing page into a numbered narrative +29/-58

Restructure landing page into a numbered narrative

• Replaces the compact feature-card block with four dedicated explanatory sections and updates calls to action for '/research'. Aligns the landing container with shared widths and clarifies dynamic tool counts.

app/page.tsx

page.tsxRename research workflow and add theme control +12/-8

Rename research workflow and add theme control

• Changes page metadata and headings from Teach to Research. Adds the shared light/dark toggle alongside hackathon navigation.

app/research/page.tsx

chat-theme.tsMatch embedded chat typography to Geist +1/-1

Match embedded chat typography to Geist

• Changes the TrueForge UI font token from DM Sans to Geist so embedded chat matches the application design system.

components/chat-theme.ts

landing-sections.tsxAdd long-form landing page sections +273/-0

Add long-form landing page sections

• Adds reusable numbered headings and four sections covering the problem, product workflow, MCP API, and TrueForge harness. Structured lists present stacks, tools, resources, and harness capabilities.

components/landing-sections.tsx

site-header.tsxExpand shared navigation and branding +34/-5

Expand shared navigation and branding

• Updates navigation to the top-level research and docs routes, adds a sprout mark, GitHub link, theme toggle, and knowledge call to action. Aligns header widths with page containers at standard and 2xl breakpoints.

components/site-header.tsx

theme-toggle.tsxAdd hydration-safe light and dark toggle +33/-0

Add hydration-safe light and dark toggle

• Adds a next-themes control whose icon visibility is selected by CSS from the root theme class. Stable server and client markup avoids hydration mismatches and effect-driven mounted state.

components/theme-toggle.tsx

Bug fix (6) +188 / -82
page.tsxAdopt shared track layout on hackathon details +3/-23

Adopt shared track layout on hackathon details

• Uses the shared TrackList for full-width tracks and safely wrapped prizes while retaining judging criteria. Improves overview copy width and contrast.

app/hackathons/[slug]/page.tsx

sub-nav.tsxSuppress erroneous vertical tab scrollbar +5/-1

Suppress erroneous vertical tab scrollbar

• Explicitly hides vertical overflow while retaining horizontal scrolling, preventing Chrome from rendering a scrollbar caused by the tab border overlap.

app/hackathons/[slug]/sub-nav.tsx

chat-panel-impl.tsxReplace SDK presets with app-owned chat layouts +53/-24

Replace SDK presets with app-owned chat layouts

• Introduces dedicated split and full-page layouts composed from SDK thread primitives. This removes unconfigurable SDK theme and settings actions while preserving session reporting only for research.

components/chat-panel-impl.tsx

research-split.tsxWiden research records on 2xl screens +7/-1

Widen research records on 2xl screens

• Allocates additional 2xl width to the record panel after the chat reaches its effective content cap, reducing wasted gutter without constraining smaller breakpoints.

components/research-split.tsx

run-subject.tsxUse panel-safe lists in research records +7/-20

Use panel-safe lists in research records

• Reuses TrackList and explicitly stacks titled items in the narrow record panel, avoiding viewport-based two-column splits. Removes a duplicate divider above coverage statistics.

components/run-subject.tsx

section.tsxRedesign record sections and harden track rendering +113/-13

Redesign record sections and harden track rendering

• Adds mono section labels, ruled grid and stacked TitledList modes, and a reusable TrackList. Caps and wraps long prize chips to prevent cross-column overlap while supporting optional criteria.

components/section.tsx

Documentation (1) +4 / -4
README.mdDocument renamed research and docs routes +4/-4

Document renamed research and docs routes

• Updates the product wording from teaching to research and replaces '/ui/run' and '/ui/docs' references with '/research' and '/docs'. Session persistence documentation now points to the renamed research route.

README.md

Other (1) +3 / -0
eslint.config.mjsExclude local design references from linting +3/-0

Exclude local design references from linting

• Adds the ignored local design-export and reference directory to ESLint exclusions because it is scratch material rather than maintained source.

eslint.config.mjs

@qodo-code-review

qodo-code-review Bot commented Aug 29, 2026 •

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📜 Skill insights (0)

Grey Divider


Action required

1. Mobile chat history disappears ✗ Dismissed 🐞 Bug ≡ Correctness
Description
DocsLayout hides ThreadListContainer below the md breakpoint without providing a drawer or
other trigger, so mobile /docs users cannot open or switch prior conversations. The only remaining
mobile child is Thread, which exposes no replacement session navigation in this layout.
Code

components/chat-panel-impl.tsx[R68-69]

+      <div className="hidden w-64 shrink-0 flex-col overflow-y-auto border-r md:flex">
+        <ThreadListContainer />
Evidence
The new full-page layout renders the session list only inside a hidden ... md:flex container and
otherwise renders only Thread. /docs selects this newly introduced layout through
variant="full".

components/chat-panel-impl.tsx[64-75]
components/chat-panel-impl.tsx[104-115]
app/docs/page.tsx[44-46]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The custom docs layout permanently hides conversation history on mobile and offers no alternate way to reach it.

## Issue Context
Keep the custom layout that omits SDK shell actions, but provide a responsive drawer or explicit mobile thread-list control.

## Fix Focus Areas
- components/chat-panel-impl.tsx[64-75]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Remediation recommended

2. Mobile header overflows ✗ Dismissed 🐞 Bug ≡ Correctness
Description
The expanded shared SiteHeader keeps the brand, three navigation links, always-visible theme
toggle, and non-shrinking “What it knows” CTA in a single non-wrapping row whose minimum width
exceeds common phone viewports, pushing navigation and actions off-screen. Because this header is
shared, the overflow affects the landing page, hackathons index, and hackathon detail layout.
Code

components/site-header.tsx[R48-53]

+          <ThemeToggle />
+          <Link
+            href="/hackathons"
+            className={cn(buttonVariants({ size: "sm" }), "rounded-full")}
+          >
+            What it knows
Evidence
The header root is a single-line flex row, the full three-link navigation, theme toggle, and CTA
remain visible at narrow widths, and only the GitHub link is hidden below sm; moreover, the CTA’s
shared button variant explicitly uses shrink-0. Since flex containers are single-line by default
and the PR adds these fixed-width controls without responsive behavior for them or the navigation,
the items can overflow when they do not fit, and the cited component mounts show that the issue
affects the landing page, hackathons index, and hackathon detail layout.

components/site-header.tsx[20-55]
components/ui/button.tsx[6-7]
app/page.tsx[34-38]
app/hackathons/page.tsx[18-22]
app/hackathons/[slug]/layout.tsx[48-52]
🌐 flex-wrap defaults to nowrap, so flex items are laid out on one line and may overflow their container.

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The shared header now includes a fixed-size theme toggle and a `shrink-0` “What it knows” CTA alongside the brand and three navigation links. Because these controls remain in one non-wrapping flex row, they exceed the available width on narrow viewports and push navigation or actions off-screen.

## Issue Context
Keep the theme control and every navigation destination accessible while introducing a deliberate compact/mobile navigation treatment before the available width is exhausted. For example, hide desktop-only controls such as the CTA at small breakpoints and collapse navigation/actions behind a menu.

## Fix Focus Areas
- components/site-header.tsx[20-55]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


3. Moved routes lose redirects ✗ Dismissed 🐞 Bug ☼ Reliability
Description
The migration changes public links from /ui/run and /ui/docs to /research and /docs, but no
redirect preserves the previously documented URLs, so existing bookmarks and external links now
return 404. Add permanent redirects from both old paths to their replacements.
Code

components/site-header.tsx[R9-10]

+  { href: "/research", label: "Research" },
+  { href: "/docs", label: "Ask the docs" },
Evidence
The app now contains only app/research and app/docs, all shared navigation points at those new
paths, and next.config.ts has no redirect configuration. The README diff confirms /ui/run and
/ui/docs were previously published routes.

components/site-header.tsx[7-11]
app/research/page.tsx[16-18]
app/docs/page.tsx[18-20]
next.config.ts[1-5]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Previously published `/ui/run` and `/ui/docs` URLs now return 404 after the route move.

## Issue Context
Configure permanent redirects to preserve bookmarks and inbound links while keeping the new canonical routes.

## Fix Focus Areas
- next.config.ts[1-5]
- components/site-header.tsx[7-11]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

Context sources
✅ Web pages:
  +26 more
Review mode: 🧠 Deep: This is a broad UI and routing change spanning 18 files with 39 edit sites, new layout and theme logic, SDK composition changes, and multiple independent paths where subtle regressions could be missed in one pass.

Grey Divider

Tip of the day
💡 Did you know, you can group findings by type and pick your Finding display, from Minimal to Full

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

Comment thread components/chat-panel-impl.tsx Resolved
Comment thread components/site-header.tsx Resolved
Comment thread components/site-header.tsx Resolved
@md-abid-hussain
md-abid-hussain merged commit fc41e56 into main Aug 29, 2026
1 check passed
@md-abid-hussain
md-abid-hussain deleted the ui-update branch August 29, 2026 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant