mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-06-10 11:12:35 -07:00
1c5646b68d
- Add TeamSelectionDialog component for team discovery UX - Intercept startup flow in AppContainer to show team selection if needed - Update DialogManager to orchestrate team selection UI - Add handleTeamSelect and isTeamSelectionActive to UI contexts - Fix pre-existing StyledLine compilation error in TableRenderer - Refactor promptProvider-teams.test.ts to resolve type errors - Add unit tests for TeamSelectionDialog - Fix ESLint warnings for exhaustive-deps in AppContainer - Resolve syntax corruptions in AppContainer.tsx and DialogManager.tsx
1.5 KiB
1.5 KiB
TASK-04: CLI UX: Startup Team Selection Dialog
Objective
Introduce a selection dialog during the CLI startup process to allow users to choose an agent team, browse existing teams, or create new ones.
Implementation Details
1. New UI Component (packages/cli/src/ui/components/TeamSelectionDialog.tsx)
- Create a new React/Ink component that displays a list of available teams.
- Options should include:
- Specific discovered teams (name + description).
- "No Team" (continue as individual agent).
- "Browse Team Marketplace" (placeholder for MVP).
- "Create New Team" (placeholder for MVP).
- Use
SelectInputfrom@inkjs/select-inputfor selection.
2. Startup Flow (packages/cli/src/ui/AppContainer.tsx)
- Add state:
isTeamSelectionActive: boolean. - In
useEffectoruseLayoutEffectthat runs once after initialization:- If multiple teams are available and no active team is set in the
session/config:
- Set
isTeamSelectionActive(true).
- Set
- If multiple teams are available and no active team is set in the
session/config:
- Intercept the render flow:
- If
isTeamSelectionActive, render theTeamSelectionDialog.
- If
- Implement
handleTeamSelect(teamName: string | undefined):- Call
config.setActiveTeam(teamName). - Set
isTeamSelectionActive(false).
- Call
Verification
- Manual verification of the startup screen.
- Test selection of a team and confirm the CLI proceeds to the main chat.
- Test the "No Team" option.
- Verify that if only one team exists, the dialog can be bypassed (optional UX polish).