Skip to content

Commit

Permalink
refactor(snackbar): add clearTimemout to close animation
Browse files Browse the repository at this point in the history
  • Loading branch information
evilamaior committed May 17, 2022
1 parent d6ec419 commit 41315fc
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ const SnackbarAnimationWrapper = forwardRef(
if (shouldCloseOnTimer) {
timeoutRef.current = setTimeout(() => {
closeAnimation();
clearTimeout(timeoutRef.current);
}, timeoutDuration);
}
};
Expand Down

0 comments on commit 41315fc

Please sign in to comment.