-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a88db4d
commit ae21e91
Showing
7 changed files
with
94 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import style from "../styles/components/pinned.module.scss"; | ||
|
||
export const Pinned: React.FunctionComponent<{ items }> = ({ items }) => { | ||
return ( | ||
<div className={style["pinned"]}> | ||
{items.map((item) => ( | ||
<a className="unstyled" href={item.url} target="_blank" key={item.url}> | ||
<div className={style["pinned-card"]}> | ||
<span className={style["title"]}>{item.title}</span> | ||
<p className={style["description"]}>{item.description}</p> | ||
<div className={style["link"]}>→</div> | ||
</div> | ||
</a> | ||
))} | ||
</div> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
@import | ||
'../_variables'; | ||
|
||
.pinned { | ||
display: grid; | ||
grid-template-columns: repeat(3, 1fr); | ||
gap: 1em; | ||
padding: 2em 1em 2em 1em; | ||
border-radius: 0.5em; | ||
|
||
@media (max-width: 1200px) { | ||
grid-template-columns: repeat(2, 1fr); | ||
} | ||
|
||
@media (max-width: 768px) { | ||
grid-template-columns: 1fr; | ||
} | ||
} | ||
|
||
.pinned-card { | ||
background-color: map-get($pinned-colors, 'background'); | ||
border: 0.01em solid map-get($pinned-colors, 'border'); | ||
border-radius: 0.3em; | ||
padding: 0.6em 1em 0.2em 1em; | ||
display: flex; | ||
flex-direction: column; | ||
color: map-get($basic-colors, 'base'); | ||
|
||
&:hover { | ||
background-color: map-get($home-colors, 'background'); | ||
} | ||
|
||
p { | ||
margin: 0; | ||
} | ||
|
||
.title { | ||
font-style: italic; | ||
font-size: medium; | ||
|
||
font-size: 1em; | ||
} | ||
|
||
.description { | ||
font-size: 0.7em; | ||
margin-left: 0.3em; | ||
} | ||
|
||
.link { | ||
display: flex; | ||
justify-content: space-between; | ||
font-size: 1em; | ||
align-self: flex-end; | ||
} | ||
} |