Skip to content

Commit

Permalink
[charts] Fix key generation for the ChartsGrid (#15463)
Browse files Browse the repository at this point in the history
Co-authored-by: Jose C Quintas Jr <[email protected]>
  • Loading branch information
alexfauquette and JCQuintas authored Nov 18, 2024
1 parent d172745 commit e151681
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/x-charts/src/ChartsGrid/ChartsHorizontalGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ export function ChartsGridHorizontal(props: ChartsGridHorizontalProps) {

return (
<React.Fragment>
{yTicks.map(({ formattedValue, offset }) => (
{yTicks.map(({ value, offset }) => (
<GridLine
key={`horizontal-${formattedValue}`}
key={`horizontal-${value}`}
y1={offset}
y2={offset}
x1={drawingArea.left}
Expand Down
4 changes: 2 additions & 2 deletions packages/x-charts/src/ChartsGrid/ChartsVerticalGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ export function ChartsGridVertical(props: ChartsGridVerticalProps) {

return (
<React.Fragment>
{xTicks.map(({ formattedValue, offset }) => (
{xTicks.map(({ value, offset }) => (
<GridLine
key={`vertical-${formattedValue}`}
key={`vertical-${value}`}
y1={drawingArea.top}
y2={drawingArea.top + drawingArea.height}
x1={offset}
Expand Down

0 comments on commit e151681

Please sign in to comment.