fix: design review fixes and a couple of other minor fixes

This commit is contained in:
jongomez 2023-10-09 12:13:25 +01:00 committed by Jon
parent 1f249490ce
commit a535cfaa61
2 changed files with 15 additions and 4 deletions

View File

@ -53,7 +53,6 @@ export const ToastStyles = css`
.${toastClasses.title} { .${toastClasses.title} {
position: relative; position: relative;
font-weight: bold;
} }
.${toastClasses.information} { .${toastClasses.information} {
@ -83,7 +82,7 @@ export const ToastStyles = css`
.${toastClasses.errorIcon} { .${toastClasses.errorIcon} {
position: absolute; position: absolute;
top: 5px; top: 3px;
left: -26px; left: -26px;
} }
@ -144,5 +143,9 @@ export const ToastStyles = css`
.${toastClasses.textContainer} { .${toastClasses.textContainer} {
min-width: 144px; min-width: 144px;
} }
.${toastClasses.errorIcon} {
top: 0px;
}
} }
` `

View File

@ -126,7 +126,11 @@ export const Toast: React.FC<ToastProps> & {
> >
<div className={clsx(toastClasses.textContainer)}> <div className={clsx(toastClasses.textContainer)}>
{!!title && ( {!!title && (
<Typography className={toastClasses.title} component="div"> <Typography
className={toastClasses.title}
component="div"
variant={size === 'small' ? 'label2' : 'label1'}
>
<ErrorIcon <ErrorIcon
color="primary" color="primary"
className={toastClasses.errorIcon} className={toastClasses.errorIcon}
@ -137,7 +141,11 @@ export const Toast: React.FC<ToastProps> & {
)} )}
{!!information && ( {!!information && (
<Typography className={toastClasses.information} component="div"> <Typography
className={toastClasses.information}
component="div"
variant={size === 'small' ? 'label2' : 'label1'}
>
{information} {information}
</Typography> </Typography>
)} )}