Draft: Fix: AI Panel Navigation display
What does this MR do and why?
This MR fixes the following Navigation Issues in the Side Panel:
- Going from History back to Active Chat does not restore the Active Chat Session
- Sessions title is restored when going from Active Chat back to Sessions
References
Related GitLab Issues: 1 - https://gitlab.com/gitlab-org/gitlab/-/issues/577821 2 - #575840
Screenshots or screen recordings
| Before | After |
|---|---|
| Screen_Recording_2025-11-04_at_1.20.08_PM | Screen_Recording_2025-11-04_at_12.47.40_PM |
How to set up and validate locally
- To test this locally, make sure you have the following FFs enabled:
duo_workflow,duo_workflow_in_ci,ai_flow_triggers,paneled_view,global_topbar,tailwind_container_queries. After you can toggleNew UIon in user's setting under the user's profile dropdown - Open the side panel and open Sessions.
- Test navigation (see below for test cases)
- If you see no Sessions then run the following query
bundle exec rake "gitlab:duo_workflow:populate[50,20,1,<<YOUR_TEST_GROUP_PATH/PROJECT_HERE>>]"to create new agent sessions. Refresh the page.
Navigation Testing
1) Side Panel - History
- In your side panel, navigate to the
Historytab and select an item in the list. - Notice it loads in the active chat tab at the top of the side panel navigation.
- Immediately navigate to the
Sessionstab (typically the last one). - Validate title says
Sessions. - Navigate back to
History, validate title saysHistory. - Navigate back to the active chat tab at the top, validate the title has been retained.
2) Side Panel - New
- After the above, navigate to the
Newchat tab. Validate title containsNew. - Navigate back to the active chat tab, validate title says
GitLab Duo Chatand shows the new chat view. - Navigate to
Historytab, click a history session item, notice it loads active chat with session title. - Navigate back to
Newchat, and then back to the active chat - see that it loads only the new chat.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Related to #577821
Edited by Lindsey Shelton