Skip to content

Conversation

ewilliams-cloudera
Copy link
Collaborator

There are a few breaking changes to the API for charts, so a couple of modifications to the props as well.

@Copilot Copilot AI review requested due to automatic review settings June 12, 2025 18:34
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates MUI package versions and adapts chart component props to the new @mui/x-charts API.

  • Bumps @mui/material and @mui/x-charts to latest minor versions.
  • Replaces the removed bottomAxis prop with the new xAxis array syntax and adds an explicit width for the y-axis.
  • Adjusts the line-chart valueFormatter to guard against nullish values.
Files not reviewed (1)
  • ui/pnpm-lock.yaml: Language not supported
Comments suppressed due to low confidence (2)

ui/src/pages/Analytics/Metrics.tsx:217

  • Verify that the chart API accepts null from valueFormatter. If it expects undefined or an empty string for missing values, adjust the return accordingly or update the type annotation to match.
valueFormatter: (value) =>

ui/src/pages/Analytics/Metrics.tsx:218

  • Add a unit or integration test to cover the new conditional branch in valueFormatter, ensuring that both numeric and null/undefined inputs render as expected.
value ? value.y.toFixed(2).toString() : null,

Copy link
Collaborator

@jkwatson jkwatson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@ewilliams-cloudera ewilliams-cloudera merged commit f96c664 into main Jun 12, 2025
3 of 5 checks passed
@ewilliams-cloudera ewilliams-cloudera deleted the mob/bump-mui-charts branch June 12, 2025 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants