Skip to content

Commit

Permalink
message styling for themes
Browse files Browse the repository at this point in the history
  • Loading branch information
sebald committed Jul 19, 2023
1 parent ba12cea commit e4e2b51
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 14 deletions.
13 changes: 4 additions & 9 deletions packages/components/src/Message/Message.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,20 +43,15 @@ export const Message = ({
return (
<div
className={cn(
'grid auto-cols-auto auto-rows-min gap-x-1 gap-y-2',
'grid auto-cols-auto auto-rows-min gap-1',
classNames.container
)}
{...props}
>
<div
className={cn(
'col-span-1 row-span-2 h-4 w-4 self-start',
classNames.icon
)}
>
{icon}
<div className={cn('col-span-1 h-6 w-6', classNames.icon)}>{icon}</div>
<div className={cn('col-start-2 row-start-1', classNames.title)}>
{messageTitle}
</div>
<div className={cn('col-start-2', classNames.title)}>{messageTitle}</div>
<div className={cn('col-start-2', classNames.content)}>{children}</div>
</div>
);
Expand Down
6 changes: 3 additions & 3 deletions themes/theme-b2b/src/components/Message.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ export const Message: ThemeComponent<'Message'> = {
},
}
),
content: cva('pt-1 leading-[1.125]'),
icon: cva('flex h-4 w-4', {
title: cva('font-bold'),
content: cva(''),
icon: cva('', {
variants: {
variant: {
warning: 'fill-fill-warning',
Expand All @@ -26,5 +27,4 @@ export const Message: ThemeComponent<'Message'> = {
},
},
}),
title: cva('pl-1 font-bold leading-[1.125]'),
};
4 changes: 2 additions & 2 deletions themes/theme-core/src/components/Message.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export const Message: ThemeComponent<'Message'> = {
},
},
}),
title: cva('col-span-full font-bold leading-8', {
title: cva('font-bold', {
variants: {
variant: {
warning: 'text-text-warning',
Expand All @@ -19,7 +19,7 @@ export const Message: ThemeComponent<'Message'> = {
},
},
}),
icon: cva(''),
icon: cva('hidden'),
content: cva('leading-4', {
variants: {
variant: {
Expand Down

2 comments on commit e4e2b51

@vercel
Copy link

@vercel vercel bot commented on e4e2b51 Jul 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

marigold-storybook – ./

marigold-storybook-marigold.vercel.app
marigold-latest.vercel.app
marigold-storybook-git-main-marigold.vercel.app

@vercel
Copy link

@vercel vercel bot commented on e4e2b51 Jul 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

marigold-docs – ./

marigold-docs.vercel.app
marigold-docs-git-main-marigold.vercel.app
marigold-docs-marigold.vercel.app

Please sign in to comment.