Merge pull request #14473 from ramonlsouza/fix-toast-styles

Fix: toast background styles
This commit is contained in:
Anton Georgiev 2022-02-25 15:35:55 -05:00 committed by GitHub
commit 7d9ad10710
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View File

@ -31,7 +31,7 @@ const Toast = ({
}) => (
<Styled.ToastContainer small={small} data-test="toastContainer">
<Styled.Toast type={type}>
<Styled.ToastIcon small={small}>
<Styled.ToastIcon className="toastIcon" small={small}>
<Icon iconName={icon || defaultIcons[type]} />
</Styled.ToastIcon>
<Styled.ToastMessage data-test="toastSmallMsg">

View File

@ -142,35 +142,35 @@ const Toast = styled.div`
display: flex;
${({ type }) => type === 'default' && `
& > i {
& .toastIcon {
color: ${toastDefaultColor};
background-color: ${toastDefaultBg};
}
`}
${({ type }) => type === 'error' && `
& > i {
& .toastIcon {
color: ${toastErrorColor};
background-color: ${toastErrorBg};
}
`}
${({ type }) => type === 'info' && `
& > i {
& .toastIcon {
color: ${toastInfoColor};
background-color: ${toastInfoBg};
}
`}
${({ type }) => type === 'success' && `
& > i {
& .toastIcon {
color: ${toastSuccessColor};
background-color: ${toastSuccessBg};
}
`}
${({ type }) => type === 'warning' && `
& > i {
& .toastIcon {
color: ${toastWarningColor};
background-color: ${toastWarningBg};
}