Remove AI Catalog breadcrumb from Duo Agents Platform pages

What this does

Breadcrumbs on the Duo Agents Platform pages showed an AI Catalog crumb between the namespace and the current page, for example GitLab Duo / AI Catalog / Sessions. Those pages are not part of the AI Catalog, and that crumb linked to the Sessions index rather than to the catalog.

The Duo Agents Platform app reuses AiCatalogBreadcrumbs, which always appended the crumb. This adds a showCatalogRootCrumb inject that defaults to true, and sets it to false in the Duo Agents Platform app. Group and project pages now show the namespace and the current page only. Explore keeps its AI Catalog crumb through the default, so the Explore app needs no change.

rootRouteName had a single consumer, the Duo Agents Platform app, and nothing provides it once the crumb is gone. This removes it and uses AI_CATALOG_INDEX_ROUTE directly.

Introduced by !248144 (merged).

Before and after

Before After
Group Flows: GitLab Duo / AI Catalog / Flows GitLab Duo / Flows
group-flows-before group-flows-after
Project Sessions: GitLab Duo / Test / AI Catalog / Sessions GitLab Duo / Test / Sessions
project-sessions-before project-sessions-after
Project Flows: GitLab Duo / Test / AI Catalog / Flows GitLab Duo / Test / Flows
project-flows-before project-flows-after
Explore Flows: Explore / AI Catalog / Flows Explore / AI Catalog / Flows, unchanged
explore-flows-before explore-flows-after

Every Automate page at both scopes, checked on the GitLab Duo group and the GitLab Duo / Test project:

Page Before After
Group Sessions GitLab Duo / AI Catalog / Sessions GitLab Duo / Sessions
Group Agents GitLab Duo / AI Catalog / Agents GitLab Duo / Agents
Group Flows GitLab Duo / AI Catalog / Flows GitLab Duo / Flows
Group MCP servers GitLab Duo / AI Catalog / MCP servers GitLab Duo / MCP servers
Group Triggers GitLab Duo / AI Catalog / Triggers GitLab Duo / Triggers
Project Sessions GitLab Duo / Test / AI Catalog / Sessions GitLab Duo / Test / Sessions
Project Agents GitLab Duo / Test / AI Catalog / Agents GitLab Duo / Test / Agents
Project Flows GitLab Duo / Test / AI Catalog / Flows GitLab Duo / Test / Flows
Project MCP servers GitLab Duo / Test / AI Catalog / MCP servers GitLab Duo / Test / MCP servers
Project Triggers GitLab Duo / Test / AI Catalog / Triggers GitLab Duo / Test / Triggers
Explore Agents Explore / AI Catalog / Agents unchanged
Explore Flows Explore / AI Catalog / Flows unchanged

How to set up and validate locally

  1. Open a group and a project with Duo enabled.
  2. Visit /-/automate/agent-sessions, /agents, /flows, /triggers and /mcp-servers at both group and project scope. The breadcrumb should read <namespace> / <page> with no AI Catalog crumb.
  3. Visit /explore/ai-catalog/agents and /explore/ai-catalog/flows. The AI Catalog crumb should still be present and should link to /explore/ai-catalog/.
  4. Open a flow detail page such as /-/automate/flows/:id. The trail should read <namespace> / Flows / <flow name>.

Also checked: breadcrumb clicks at every scope, bare /-/automate, trailing slashes, and unknown subroutes.

mcp-servers needs the ai_catalog_mcp_servers flag, instance beta features, and duo_workflow_mcp_enabled on the root namespace before the page is reachable.

Out of scope

Making the URLs match the breadcrumbs, discussed in #629100 (closed), is a separate change.

The last crumb on a detail page links to the unexpanded route pattern, for example /-/automate/flows/:id(\d+). That comes from the to = { path: route.path } fallback in crumbs(), which this MR does not touch. It is tracked in #627334.

Closes #629100 (closed)

Edited by Angus Ryer

Merge request reports

Loading
Loading