Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(react-card): :first-child/:last-child margin was removed #444

Merged
merged 1 commit into from
May 1, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
22 changes: 3 additions & 19 deletions packages/react/src/card/card.styles.ts
Expand Up @@ -13,13 +13,7 @@ export const StyledCardBody = styled('div', {
p: '$sm $lg',
oy: 'auto',
position: 'relative',
ta: 'left',
'*:first-child': {
mt: 0
},
'*:last-child': {
mb: 0
}
ta: 'left'
});

export const StyledCard = styled('div', {
Expand Down Expand Up @@ -144,7 +138,7 @@ export const StyledCard = styled('div', {
true: {
'&:hover': {
transform: 'translateY(-2px)',
boxShadow: '$lg'
boxShadow: '$md'
}
}
},
Expand Down Expand Up @@ -196,13 +190,7 @@ export const StyledCardHeader = styled('div', {
overflow: 'hidden',
color: 'inherit',
fontSize: '$xs',
p: '$sm',
'*:first-child': {
mt: 0
},
'*:last-child': {
mb: 0
}
p: '$sm'
});

export const StyledCardFooter = styled('div', {
Expand All @@ -216,10 +204,6 @@ export const StyledCardFooter = styled('div', {
fontSize: '$xs',
bblr: '$lg',
bbrr: '$lg',
'*': {
mt: 0,
mb: 0
},
variants: {
blur: {
true: {
Expand Down
2 changes: 1 addition & 1 deletion packages/react/src/theme/common.ts
Expand Up @@ -116,7 +116,7 @@ export const defaultTokens = {
'background 0.25s ease 0s, color 0.25s ease 0s, border-color 0.25s ease 0s, box-shadow 0.25s ease 0s, transform 0.25s ease 0s, opacity 0.25s ease 0s',
avatar: 'box-shadow 0.25s ease 0s, opacity 0.25s ease 0s',
link: 'opacity 0.25s ease 0s, background 0.25s ease 0s',
card: 'transform 0.25s ease 0s'
card: 'transform 0.25s ease 0s, box-shadow 0.25s ease 0s'
},
breakpoints: {
xs: '650px',
Expand Down