Skip to content

fix(web): polish login, onboarding gate, setup CTA, and dashboard routes - #751

Open
oldwinter53 wants to merge 1 commit into
mainfrom
oldwinter53/fix-ux-auth-onboarding
Open

oldwinter53 wants to merge 1 commit into
mainfrom
oldwinter53/fix-ux-auth-onboarding

Conversation

@oldwinter53

Copy link
Copy Markdown

Summary

Fixes high-impact first-impression authentication, Local Computer onboarding gate, Another Me connect-accounts card, and Work Item Dashboard routing/focus defects in @linger/web.

Changes

  1. Clean first-visit login, single error surface, and deep-link return

    • Treat /v0/tenants as an entry discovery path in teamhub-api.ts and skip reason=session-expired when redirecting from root /, so anonymous first visits land cleanly on /login without an expired-session alert.
    • Preserve return_to (pathname + search) on /t/:tenantId 401 redirects and allow safe same-origin /t/:tenantId/... paths in safeAuthenticationReturnTo.
    • Dismiss the session-expired alert on credential edit or submit so two danger alerts never stack, map INVALID_CREDENTIALS to clear sentence-case copy, align the submit button's visible text and accessible name (Sign in), focus Email on initial mount when no desktop local account button is active, and add a subtle workspace-admin help line.
  2. Local Computer onboarding gate and /connect-computer dead-end

    • Wrap CommandLine commands (whitespace-pre-wrap break-all) so curl ... | bash stays completely readable on desktop and mobile viewports.
    • Replace the native OS <select> in ComputerPlatformSelector with an accessible radiogroup segmented control (macOS | Windows | Linux) supporting arrow-key navigation.
    • Upgrade LocalComputerGate to <ModalDialog>, surface query load errors with Retry, add a 30-second fallback Retry if creating Another Me stalls, expose inline Language switching and a Settings link in the footer, and block Cmd/Ctrl+K global search (useGlobalSearchShortcut(..., { enabled: !inert })) while gated.
    • Add the Linger brand mark and a primary Back to Linger link to InvalidConnectionRequest, internationalize fallback strings, and show actionable retry guidance on enrollment failure.
  3. Another Me onboarding card CTA and mobile layout

    • In ProfileSetupApps, hide the misleading solid Connected primary CTA when 0 accounts are connected (showing only Skip for now), and enable a clear Continue ({count} connected) primary CTA once at least one account is connected.
    • Refine SetupAppRow spacing, icon sizing, button sizing, and label wrapping so app names such as Google Calendar and Outlook Mail never truncate on 375px mobile viewports.
  4. Dashboard bare route, URL sync, focus management, and 404/loading states

    • Support /t/:tenantId/dashboard/:workItemId? in router.tsx and route-layout-key.ts so bare /dashboard loads the board instead of 404.
    • Navigate to /t/:tenantId/dashboard (preserving ?room=...) when closing WorkItemDetailDrawer, move keyboard focus into the drawer on open, restore focus to the triggering card on close, mark the background board inert on narrow viewports while the overlay drawer is open, default the Closed column to collapsed, and support Cmd/Ctrl+Enter to submit comments.
    • Distinguish 404 Not Found on invalid Work Item IDs with a friendly message and Back to Dashboard / Back to Messages links instead of raw error prose and a futile Retry button.
    • Show Go to Log in on signed-out 404 pages, add HydrateFallback across top-level lazy/loader routes to eliminate React Router hydration warnings, and update InitialAppLoading copy to Loading Linger….

Verification

  • Unit & contract tests: pnpm --filter @linger/web typecheck, pnpm --filter @linger/web lint (--max-warnings=0), pnpm react:doctor, pnpm --filter @linger/web run build:assets, and 14 targeted Vitest suites (171/171 passed, including catalog.test.ts and voice-risk-markers.test.ts).
  • Rendered visual verification: Verified in headless Chromium via Playwright against the production Vite preview build across 1440x900 desktop and 375x812 mobile viewports (scrollWidth <= clientWidth, zero clipping, zero HydrateFallback warnings, zero page errors).

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