Skip to content

Conversation

@mrubens
Copy link
Collaborator

@mrubens mrubens commented Sep 24, 2025

Important

Add cloud account switcher and "Create Team Account" option with translations for multiple languages.

  • Behavior:
    • Show CloudAccountSwitcher in ChatTextArea.tsx when cloudUserInfo is available.
    • Add "Create Team Account" option in CloudAccountSwitcher.tsx and OrganizationSwitcher.tsx if no organizations exist.
    • Open billing URL when "Create Team Account" is selected.
  • Components:
    • Modify CloudAccountSwitcher.tsx to always show switcher when authenticated.
    • Update OrganizationSwitcher.tsx to handle organization changes and show "Create Team Account".
    • Adjust CloudView.tsx to include OrganizationSwitcher with cloudApiUrl.
  • Translations:
    • Add "Create Team Account" translation in cloud.json for multiple languages including en, es, fr, de, zh-CN, zh-TW, ja, ko, ru, pt-BR, it, nl, pl, vi, id, hi, ca.

This description was created by Ellipsis for 9af76c0. You can customize this summary. It will automatically update as commits are pushed.

@mrubens mrubens requested review from cte and jr as code owners September 24, 2025 20:16
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. UI/UX UI/UX related or focused labels Sep 24, 2025
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Sep 24, 2025
@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Sep 24, 2025
Copy link
Contributor

@roomote roomote bot left a comment

Choose a reason for hiding this comment

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

PR Review: Show cloud switcher and option to add a team when logged in

Critical (P0/P1)

  • Loading state handling in CloudAccountSwitcher.tsx: isLoading is reset via setTimeout instead of listening for "organizationSwitchResult" like OrganizationSwitcher.tsx. This can leave the control stuck or clear too early under latency/errors. Suggest aligning with OrganizationSwitcher’s message-driven pattern:
    • Add a window message listener for "organizationSwitchResult"
    • Reset isLoading based on success/failure
    • Update selectedOrgId from the result (or revert on error)

High (P1/P2)

const baseUrl = cloudApiUrl ?? 'https://app.roocode.com'
vscode.postMessage({ type: 'openExternal', url: `${baseUrl}/billing` })

Medium (P2)

  • Tests need updates: CloudView.tsx now always renders OrganizationSwitcher when authenticated (regardless of organizations length). Update assertions that previously required organizations.length > 0 and add tests for the new “Create Team Account” flow (verify openExternal to ${cloudApiUrl ?? 'https://app.roocode.com'}/billing).

Low (P3)

  • Redundant lookups in OrganizationSwitcher.tsx: organizations.find(...) repeated multiple times inside JSX. Cache once for clarity:
const selectedOrg = organizations.find(o => o.organization.id === selectedOrgId)
  • Minor UX in CloudAccountSwitcher.tsx: Unconditional SelectSeparator before “Create Team Account”. When there are no organizations this yields “Personal” → separator → “Create Team Account”. Render separator conditionally (only when there are orgs) or introduce labeled sections.

Inline targets (for maintainers who prefer line-context):

@mrubens mrubens merged commit d3d0967 into main Sep 24, 2025
15 checks passed
@mrubens mrubens deleted the show_cloud_switcher branch September 24, 2025 20:42
@github-project-automation github-project-automation bot moved this from New to Done in Roo Code Roadmap Sep 24, 2025
@github-project-automation github-project-automation bot moved this from Triage to Done in Roo Code Roadmap Sep 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files. UI/UX UI/UX related or focused

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants