Skip to content

fix: responsive polish for Session and Project detail pages#76

Open
GalDayan wants to merge 1 commit intomainfrom
fix/responsive-detail-pages
Open

fix: responsive polish for Session and Project detail pages#76
GalDayan wants to merge 1 commit intomainfrom
fix/responsive-detail-pages

Conversation

@GalDayan
Copy link
Copy Markdown
Contributor

Changes

Responsive polish for the two Clawatch detail pages — Session and Project views.

SessionClient.tsx

  • Stack stats vertically on mobile (cost, tokens, messages, timestamps)
  • Full-width message bubbles on mobile (max-w-fullsm:max-w-[80%])
  • Responsive timeline dots (left-1.5 mobile → left-3.5 desktop)
  • break-words on long titles and message content
  • Smaller padding on mobile (p-3 sm:p-4)
  • Wrap-safe flex layouts for metadata rows

ProjectClient.tsx

  • Hide vertical dividers on mobile (hidden sm:block)
  • Stack stats column on mobile
  • Remove fixed max-w-[500px] on session titles (use natural truncation)
  • Truncate long model names on mobile (max-w-[120px] sm:max-w-none)
  • Hide relative timestamps on mobile for cleaner cards
  • Responsive timeline messages with break-words and smaller padding
  • Touch-friendly toggle buttons (min-h-[28px])

Follows the same responsive pattern as ApprovalQueue, TravelBooking, Employees, and SlackBotConfig pages.

- SessionClient: stack stats on mobile, full-width messages, responsive timeline dots
- ProjectClient: hide dividers on mobile, stack stats, truncate model names, responsive timeline
- Both: sm: breakpoints, break-words for long text, min-h touch targets on buttons
- Pattern matches dashboard tabs (mobile cards, desktop layouts)
Copilot AI review requested due to automatic review settings March 25, 2026 05:05
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Responsive UI polish for the Session and Project detail pages in the dashboard, aligning their mobile behavior with other responsive pages in the app.

Changes:

  • Adjusted header/stats layouts to stack and wrap cleanly on small screens.
  • Updated message/timeline bubbles to be full-width on mobile with safer word-wrapping and smaller padding.
  • Tweaked Project session cards for cleaner mobile presentation (hide dividers/timestamps, truncate long fields).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
frontend/src/app/dashboard/sessions/[id]/SessionClient.tsx Mobile-friendly session header + timeline/message bubble layout adjustments (wrapping, padding, widths).
frontend/src/app/dashboard/projects/[id]/ProjectClient.tsx Mobile-friendly project stats + session cards + unified timeline bubble wrapping/padding updates.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +313 to +315
<div className="relative pl-8 sm:pl-12 flex justify-end">
<div className="absolute left-1.5 sm:left-3.5 top-3 size-3 rounded-full bg-blue-500 ring-4 ring-background z-10" />
<div className={`rounded-lg border border-blue-500/20 bg-blue-500/10 p-3 sm:p-4 max-w-full sm:max-w-[80%] ${isError ? "border-red-500/30 bg-red-500/10" : ""}`}>
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The timeline dot was moved to left-1.5 on mobile, but the vertical timeline line is still positioned at left-5 (see the "Vertical timeline line" div). This will misalign dots vs the line on small screens (desktop still aligns because sm:left-3.5 centers on left-5). Consider making the line responsive (e.g. left-3 sm:left-5) or adjusting the mobile dot position/padding so the dot center stays on the line.

Copilot uses AI. Check for mistakes.
Comment on lines +239 to 241
<span className="font-medium truncate group-hover:text-emerald-400 transition-colors">
{session.title.length > 80 ? session.title.slice(0, 80) + "..." : session.title}
</span>
Copy link

Copilot AI Mar 25, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR description mentions removing the fixed max width on session titles to rely on “natural truncation”, but this card still hard-caps titles via session.title.slice(0, 80) + "...". With the max-width removed, this manual slicing becomes the main limiter (even on wide screens) and can conflict with truncate. Consider removing the manual slice and relying on CSS truncation (or making the slice conditional on viewport) so behavior matches the PR intent.

Copilot uses AI. Check for mistakes.
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.

2 participants