Skip to content

Commit

Permalink
Change uuid prop to key to work with Notistack 0.9.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Jskobos committed Jan 3, 2020
1 parent be94196 commit 84f8ef2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/manager/src/components/SnackBar/CloseSnackbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import IconButton from 'src/components/IconButton';
type ClassNames = 'icon';

interface Props {
uuid: string;
key: string;
text: string;
}

Expand All @@ -31,7 +31,7 @@ const CloseSnackbar: React.FC<CombinedProps> = props => {
const { closeSnackbar } = useSnackbar();

const handleClose = () => {
closeSnackbar(props.uuid);
closeSnackbar(props.key);
};

return (
Expand Down
2 changes: 1 addition & 1 deletion packages/manager/src/components/SnackBar/SnackBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class SnackBar extends React.Component<CombinedProps> {
variantWarning: classes.warning,
variantInfo: classes.info
}}
action={<CloseSnackbar uuid={v4()} text="Dismiss Notification" />}
action={<CloseSnackbar key={v4()} text="Dismiss Notification" />}
>
{children}
</SnackbarProvider>
Expand Down

0 comments on commit 84f8ef2

Please sign in to comment.