Fix links in Value Stream Analytics metric tiles and their popovers

What does this MR do and why?

Fixes links in Value Stream Analytics metric tiles and their popovers:

  • Uses URLs sourced from constants.js file instead of backend, thereby fixing click handler for metric tile and links inside popover
  • Fixes alignment of View details link inside popover

Other key updates include:

  • Added namespacePath and isProjectNamespace props to MetricTile component to construct metric URL
  • Created generateMetricLink util to build metric URLs
  • Added metricUrl prop to MetricPopover to receive said url from MetricTile to avoid duplicating business logic
  • Refactored all related specs

References

Screenshots or screen recordings

Before After
Screen Recording 2025-05-28 at 3.04.30 PM.mov Screen Recording 2025-05-28 at 3.06.41 PM.mov

How to set up and validate locally

  1. Please make sure that you're on the GitLab Ultimate plan.
  2. Visit any group/project that has VSA data or follow these steps:
    1. run FILTER=customizable_cycle_analytics SEED_CUSTOMIZABLE_CYCLE_ANALYTICS=1 bundle exec rake db:seed_fu
    2. Visit the group/project value stream. The URL is present in the output of the command above
  3. Click on metrics above overview chart and verify that they drill-down to associated report*
  4. Hover over metrics and verify that View details link is correctly aligned and that Go to docs links are displayed for those that have them*

*At the moment, only New issues and Deploys have drill-down links

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 #541183 (closed)

Edited by Rudy Crespo

Merge request reports

Loading