Skip to content

feat: cookie import profile picker for multi-account browsers#377

Open
red545 wants to merge 1 commit intogarrytan:mainfrom
red545:feature/cookie-import-profile-picker
Open

feat: cookie import profile picker for multi-account browsers#377
red545 wants to merge 1 commit intogarrytan:mainfrom
red545:feature/cookie-import-profile-picker

Conversation

@red545
Copy link

@red545 red545 commented Mar 23, 2026

Summary

  • Problem: Cookie import always reads from the Default Chrome/Arc profile. Users with multiple profiles (e.g. personal, work, different projects) can only import cookies from the default account — there's no way to pick which profile to import from.
  • Fix: Added a profile dropdown to the cookie picker UI that auto-detects all Chrome/Chromium profiles by reading Local State JSON, showing human-readable names (e.g. "Nik (Nik Redl)", "zerolens.com"). The dropdown is hidden for single-profile browsers (Comet, Edge) to keep the UI clean.
  • Scope: 3 files changed, ~165 lines added. No breaking changes — the profile parameter defaults to 'Default' everywhere.

What changed

File Change
cookie-import-browser.ts New listProfiles() function, ProfileEntry type, updated findInstalledBrowsers() to detect any profile
cookie-picker-routes.ts New GET /profiles endpoint, profile param on domains and import endpoints
cookie-picker-ui.ts Profile <select> dropdown, styling, wiring to reload domains on profile change

Test plan

  • Tested with Chrome (5 profiles) and Arc (11 profiles) — all detected with correct display names
  • Verified single-profile browsers (Comet, Edge) don't show the dropdown
  • Confirmed cookie import works from non-default profiles
  • Verified backwards compatibility — omitting profile param defaults to Default

🤖 Generated with Claude Code

Chromium browsers support multiple profiles (accounts), but cookie import
always read from the Default profile. Users with multiple Chrome or Arc
profiles couldn't import cookies from non-default accounts.

Changes:
- Add listProfiles() that reads Local State JSON to discover profiles
  with human-readable display names (account name + gaia name)
- Add GET /cookie-picker/profiles API endpoint
- Pass profile param through domains and import endpoints
- Add profile dropdown in picker UI (auto-hidden for single-profile browsers)
- Update findInstalledBrowsers() to detect browsers with any profile

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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