Skip to content

Commit

Permalink
[material-ui][docs] Fix ESLint error in Stepper demo (#42559)
Browse files Browse the repository at this point in the history
  • Loading branch information
aarongarciah authored Jun 7, 2024
1 parent f0a50e1 commit 5a9fc4d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,10 @@ export default function HorizontalNonLinearStepper() {
};

const handleComplete = () => {
const newCompleted = completed;
newCompleted[activeStep] = true;
setCompleted(newCompleted);
setCompleted({
...completed,
[activeStep]: true,
});
handleNext();
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ export default function HorizontalNonLinearStepper() {
};

const handleComplete = () => {
const newCompleted = completed;
newCompleted[activeStep] = true;
setCompleted(newCompleted);
setCompleted({
...completed,
[activeStep]: true,
});
handleNext();
};

Expand Down

0 comments on commit 5a9fc4d

Please sign in to comment.