Skip to content

Use border instead of box-shadow for <Card> component #12

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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 11 additions & 16 deletions components/Card.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@
}

.children {
box-shadow:
inset 2px 0 0 0 var(--theme-text),
inset -2px 0 0 0 var(--theme-text),
inset 0 -2px 0 0 var(--theme-text);
border-left: 2px solid var(--theme-text);
border-right: 2px solid var(--theme-text);
border-bottom: 2px solid var(--theme-text);
display: block;
padding-top: calc(var(--theme-line-height-base) * 0.5rem);
padding-left: 2ch;
Expand All @@ -37,34 +36,30 @@
.left {
min-width: 10%;
width: 100%;
box-shadow:
inset 2px 0 0 0 var(--theme-text),
inset 0 2px 0 0 var(--theme-text);
border-left: 2px solid var(--theme-text);
border-top: 2px solid var(--theme-text);
padding: calc((var(--font-size) * 0.5) * var(--theme-line-height-base)) 2ch 0px 1ch;
}

.leftCorner {
flex-shrink: 0;
box-shadow:
inset 2px 0 0 0 var(--theme-text),
inset 0 2px 0 0 var(--theme-text);
border-left: 2px solid var(--theme-text);
border-top: 2px solid var(--theme-text);
padding: calc((var(--font-size) * 0.5) * var(--theme-line-height-base)) 1ch 0px 1ch;
}

.right {
min-width: 10%;
width: 100%;
box-shadow:
inset -2px 0 0 0 var(--theme-text),
inset 0 2px 0 0 var(--theme-text);
border-right: 2px solid var(--theme-text);
border-top: 2px solid var(--theme-text);
padding: calc((var(--font-size) * 0.5) * var(--theme-line-height-base)) 2ch 0px 1ch;
}

.rightCorner {
flex-shrink: 0;
box-shadow:
inset -2px 0 0 0 var(--theme-text),
inset 0 2px 0 0 var(--theme-text);
border-right: 2px solid var(--theme-text);
border-top: 2px solid var(--theme-text);
padding: calc((var(--font-size) * 0.5) * var(--theme-line-height-base)) 1ch 0px 1ch;
}

Expand Down