Skip to content

feat(oauth): show saved accounts on login cards and clarify multi-account sign-in - #400

Closed
Roomen wants to merge 0 commit into
router-for-me:devfrom
Roomen:feat/oauth-multi-account-ux
Closed

Roomen wants to merge 0 commit into
router-for-me:devfrom
Roomen:feat/oauth-multi-account-ux

Conversation

@Roomen

@Roomen Roomen commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Summary

OAuth sign-in already supports adding any number of accounts per provider, and every successful sign-in is saved as a new credential file. The login page did not show this: every card always offered "Start Sign-In" and only showed a session-scoped "Completed" pill, so users often assumed earlier sign-ins had failed or been lost.

  • Add an intro banner explaining that every sign-in adds a new account without replacing existing ones, with a shortcut to the Authentication Files tab.
  • Show the saved accounts on each built-in provider card: an account count chip plus up to three account labels (disabled accounts are struck through, the rest collapse into "+N more").
  • Clicking the count chip opens Authentication Files already filtered to that provider.
  • The primary action reads "Sign In" when the provider has no accounts and "Add Account" when it does; while polling it reads "Waiting for Authorization…".
  • Replace the "Completed" pill with inline status messages for waiting, success ("New account added and saved to Authentication Files.") and failure (the error plus "Existing accounts are not affected.").
  • Refresh the account summary after a successful sign-in and when the page Refresh button is used. If the core is unavailable the summary is hidden and sign-in still works.
  • Add groupOAuthAccountsByProvider in services/authFiles.ts, reusing the existing dedupe and OAuth-file filters, so runtime-only and API key entries are excluded.
  • Add zh-CN, en and ja strings; zh-TW is derived from zh-CN as before.

Screenshots

Login page Waiting for authorization
OAuth login page Codex card waiting for authorization
Dark theme Count chip opens filtered Authentication Files
OAuth login page in dark theme Authentication Files filtered to Codex

Captured with the browser mock (?mock=running).

Validation

  • bun run check
  • bun test tests/authFiles.test.ts tests/oauthLoginState.test.ts, including a new test for the account grouping helper
  • tests/meta-oauth-ui.cjs passes once the stale card count is corrected (see note below)
  • tests/devin-ui.cjs passes all OAuth login steps; it then stops at the existing devin-test.json strict-mode assertion in the Authentication Files view, which fails the same way on current dev
  • Manually checked the login page in light and dark themes, the waiting state and the filtered Authentication Files shortcut in the browser mock

Note: on current dev, meta-oauth-ui.cjs, devin-ui.cjs and plugin-oauth-providers-ui.cjs already fail their .oauth-card count assertions because of the Vertex card. This PR leaves those assertions alone, since #384 addresses them; it only updates the button and status labels these tests look for.

@Roomen Roomen closed this Oct 12, 2026
@Roomen
Roomen force-pushed the feat/oauth-multi-account-ux branch from b42b8ab to d2063de Compare October 12, 2026 05:51
@Roomen
Roomen deleted the feat/oauth-multi-account-ux branch October 14, 2026 07:31
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