fix: update default background color and adjust layout for ToastInner component
This commit is contained in:
parent
3eb5b4ff1e
commit
1f6f34ba1a
1 changed files with 14 additions and 7 deletions
|
@ -65,7 +65,7 @@ interface ToastInnerProps {
|
|||
|
||||
const variantConfig = {
|
||||
default: {
|
||||
bgColor: 'bg-green-150',
|
||||
bgColor: 'bg-neutral-150',
|
||||
defaultIcon: 'Info',
|
||||
},
|
||||
success: {
|
||||
|
@ -118,11 +118,18 @@ export const ToastInner: React.FC<ToastInnerProps> = ({
|
|||
<X className='h-4 w-4 text-neutral-600' />
|
||||
</button>
|
||||
|
||||
<div className='grid grid-cols-[40px_auto_auto] gap-4 items-center'>
|
||||
{/* Icon */}
|
||||
<div className='flex items-center justify-center'>
|
||||
<Icon size={40} />
|
||||
</div>
|
||||
<div
|
||||
className={`grid ${
|
||||
variant === 'default'
|
||||
? 'grid-cols-[auto_130px] max-sm:grid-cols-[auto_90px]'
|
||||
: 'grid-cols-[40px_auto_130px] max-sm:grid-cols-[40px_auto_90px]'
|
||||
} gap-4 items-center`}
|
||||
>
|
||||
{variant !== 'default' && (
|
||||
<div className='flex items-center justify-center'>
|
||||
<Icon size={40} />
|
||||
</div>
|
||||
)}
|
||||
|
||||
{/* Text Content */}
|
||||
<div className='grid gap-1'>
|
||||
|
@ -135,7 +142,7 @@ export const ToastInner: React.FC<ToastInnerProps> = ({
|
|||
{onAction && buttonText && (
|
||||
<Button
|
||||
variant={'secondary'}
|
||||
className='w-100px w-full mr-2'
|
||||
className='w-full mr-2'
|
||||
onClick={() => {
|
||||
onAction();
|
||||
if (closeOnAction) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue