Skip to content

New chat button on chat view #100

Closed

Description

@AnthonyRonning

We need a new chat button available on mobile while the user is already in the chat view. Right now they have to hit the sidebar and then hit new chat. Maybe, on mobile view, we can put it in the top right of the chat title bar.

Activity

  1. AnthonyRonning commented on Jun 8, 2025

    @AnthonyRonning
    ContributorAuthor

    @claude can you handle this?

  2. claude commented on Jun 8, 2025

    @claude
    Contributor

    Claude finished @AnthonyRonning's task in 4m 19s —— View job • claude/issue-100-20250608_002831 • Create PR ➔


    New chat button for mobile view - Complete! ✅

    Todo List:

    • Read project guidelines from CLAUDE.md
    • Explore codebase structure to understand chat UI components
    • Locate mobile chat view and title bar implementation
    • Implement new chat button for mobile view in top right of title bar
    • Test formatting, linting, and build
    • Commit changes and provide PR link

    Implementation Summary

    Successfully added a mobile-only new chat button to the chat title bar that addresses the issue requirements:

    • Mobile-only visibility: Uses useIsMobile() hook to show only on mobile devices
    • Perfect positioning: Located in top right corner of chat title bar using absolute right-4
    • Consistent design: Uses SquarePenIcon matching the sidebar's new chat button
    • Proper functionality: Navigates to home page and focuses message input when tapped
    • Accessibility: Includes aria-label="New chat" for screen readers
    • Clean code: Follows project guidelines with TypeScript, proper imports, and formatting

    Technical Details

    Modified file: frontend/src/routes/_auth.chat.$chatId.tsx

    • Added imports for SquarePenIcon and useIsMobile
    • Added mobile new chat handler function with navigation logic
    • Modified chat title bar to include conditionally rendered mobile button

    Tests passed: ✅ Format, ✅ Lint (2 warnings, 0 errors), ✅ Build successful


  3. added a commit that references this issue on Jun 8, 2025
    fc325fa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions