Fix session ID dropdown never appearing during active agentic chat

What does this MR do and why?

Fixes the session ID copy dropdown never appearing during active agentic chat.

content_container.vue's showSessionId computed property checked activeTab.props?.mode === 'active', but ai_panel.vue constructs activeTabObject as { title: this.currentTabTitle } — no props field. The condition was permanently false, so the "Copy Chat Session ID" ellipsis dropdown never rendered.

Fix: Replace the broken activeTab.props?.mode guard with a direct $route?.name === AGENTIC_CHAT_SHOW_ROUTE check. This is reactive (navigating away hides the dropdown, navigating back shows it), requires no changes to ai_panel.vue or the state manager, and follows the same pattern used by isShowingAgentSession in ai_panel.vue.

References

  • The activeTab.props?.mode pattern was never wired up — activeTabObject has never included a props key.
  • content_container.vue already watches $route.path, so $route access is established.

Screenshots or screen recordings

session-id-copy-option

How to set up and validate locally

  1. Open any project page (e.g., http://gdk.test:3000/gitlab-duo/test)
  2. Click "Active GitLab Duo Chat" to open the AI panel
  3. Send a message and wait for the agentic workflow to start streaming
  4. Before fix: No ellipsis button appears in the chat header
  5. After fix: An ellipsis (⋮) "More options" button appears in the header. Clicking it shows "Copy Chat Session ID: <id>"
  6. Navigate to history tab → dropdown disappears
  7. Navigate back to active chat → dropdown reappears

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.

Edited by Andrew Fontaine

Merge request reports

Loading