Skip to content

Conversation

@tyler-dane
Copy link
Contributor

@tyler-dane tyler-dane commented Feb 3, 2026

  • Introduced the MobileGate component to inform users that the application isn't optimized for mobile yet, featuring a waitlist button.
  • Implemented comprehensive tests for the MobileGate component, covering rendering, button behavior, and accessibility.
  • Updated RootView to conditionally render MobileGate for mobile users, enhancing user experience across devices.

Closes #1430


Note

Medium Risk
Introduces a new top-level gating path that prevents the entire app from rendering on mobile; mistakes could inadvertently block non-mobile users or affect initial render behavior due to the updated useIsMobile initialization.

Overview
Mobile view now blocks the main app: RootView detects small viewports via useIsMobile() and renders a new MobileGate screen instead of mounting UserProvider/SocketProvider/AuthenticatedLayout.

Adds the MobileGate component (copy + “Join Mobile Waitlist” button opening an external URL) with unit tests for rendering, click behavior, and basic accessibility. Updates useIsMobile to compute the initial state synchronously via matchMedia (SSR-safe) to avoid first-render mounting work, and adjusts OAuth overlay Playwright suites to test.skip on mobile since the gate prevents the overlay from rendering.

Written by Cursor Bugbot for commit 4b17060. This will update automatically on new commits. Configure here.

- Introduced the MobileGate component to inform users that the application isn't optimized for mobile yet, featuring a waitlist button.
- Implemented comprehensive tests for the MobileGate component, covering rendering, button behavior, and accessibility.
- Updated RootView to conditionally render MobileGate for mobile users, enhancing user experience across devices.
Copilot AI review requested due to automatic review settings February 3, 2026 02:47
@tyler-dane tyler-dane changed the title feat(web): warn if user visit on mobile feat(web): warn if user visits site on mobile Feb 3, 2026
@tyler-dane tyler-dane changed the title feat(web): warn if user visits site on mobile feat(web): warn mobile users and present waitlist Feb 3, 2026
Copy link
Contributor

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

This PR introduces a mobile-only gate view to inform users that the app is not yet optimized for mobile and to direct them to a waitlist, while wiring it into the root view and adding focused component tests.

Changes:

  • Updated RootView to use the useIsMobile hook and conditionally render MobileGate instead of the authenticated layout on mobile.
  • Added a new MobileGate component with full-screen layout, explanatory copy, and a “Join Mobile Waitlist” CTA opening an external waitlist URL in a new tab.
  • Added unit tests for MobileGate covering rendering, button behavior (window opening), and basic accessibility semantics.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
packages/web/src/views/Root.tsx Adds mobile detection via useIsMobile and short-circuits rendering to MobileGate when on mobile instead of the authenticated layout.
packages/web/src/components/MobileGate/MobileGate.tsx Implements the mobile gate UI with themed styling, explanatory text, and a waitlist button wired to window.open.
packages/web/src/components/MobileGate/MobileGate.test.tsx Provides tests to verify MobileGate’s title, message, button presence, click behavior, and heading/button accessibility roles.
Comments suppressed due to low confidence (1)

packages/web/src/views/Root.tsx:18

  • The new conditional rendering in RootView that swaps between MobileGate and the authenticated layout based on useIsMobile isn’t covered by tests, even though other views and mobile onboarding components (e.g. DayView, MobileWarning) have dedicated tests. To keep behavior stable and aligned with the project’s testing guidelines, add tests that mock useIsMobile to return both true and false and assert that MobileGate is rendered for mobile and AuthenticatedLayout (with its providers) is rendered for non-mobile.
export const RootView = () => {
  const isMobile = useIsMobile();

  if (isMobile) {
    return <MobileGate />;
  }

  return (
    <UserProvider>
      <SocketProvider>
        <AuthenticatedLayout />
      </SocketProvider>

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on March 3

Details

You are on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

- Introduced a synchronous method to determine the initial mobile state, preventing unnecessary API calls during the first render on mobile devices.
- Updated the useState hook to initialize with the new method, ensuring consistent mobile state detection.
Copy link
Contributor Author

@tyler-dane tyler-dane left a comment

Choose a reason for hiding this comment

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

@copilot please update

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@copilot update this component to use tailwind, not styled-components

Copy link
Contributor

Copilot AI commented Feb 3, 2026

@tyler-dane I've opened a new pull request, #1435, to work on those changes. Once the pull request is ready, I'll request review from you.

Copy link
Contributor

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

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

…ference

- Updated OAuth overlay tests to skip execution on mobile devices, as the MobileGate component prevents the overlay from rendering.
- Simplified the test for blurring the active element by removing mobile-specific conditions, ensuring consistent behavior across devices.
- Enhanced MobileGate component styling using Tailwind CSS for improved responsiveness and visual consistency.
@tyler-dane tyler-dane merged commit b6dc17d into main Feb 3, 2026
6 checks passed
@tyler-dane tyler-dane deleted the fix/1430-mobile branch February 3, 2026 03:21
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.

App doesn't render well on mobile

2 participants