-
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
339d96c
commit 43d20e5
Showing
11 changed files
with
197 additions
and
34 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
import { css } from "@styled-system/css"; | ||
|
||
import { MySupportedTteokguk } from "@/types/myActivity"; | ||
|
||
import TteokgukImage from "@/components/common/TteokgukImage"; | ||
import { Link } from "@/routes/Link"; | ||
|
||
interface Props { | ||
tteokguks: MySupportedTteokguk[]; | ||
} | ||
|
||
const MySupportedTteokgukCardList = ({ tteokguks }: Props) => { | ||
return ( | ||
<ul className={styles.container}> | ||
{tteokguks.map( | ||
({ | ||
tteokgukId, | ||
receiverNickname, | ||
completion, | ||
backgroundColor, | ||
frontGarnish, | ||
backGarnish, | ||
}) => ( | ||
<li key={tteokgukId} className={styles.cardContainer}> | ||
<Link to={`/tteokguks/${tteokgukId}`}> | ||
<div> | ||
<div className={styles.imageContainer}> | ||
<TteokgukImage | ||
completion={completion} | ||
backgroundColor={backgroundColor} | ||
frontGarnish={frontGarnish} | ||
backGarnish={backGarnish} | ||
/> | ||
</div> | ||
<div className={styles.cardContent}> | ||
<div className={styles.cardTitle}>{tteokgukId}번째 소원떡국</div> | ||
<div className={styles.cardNickname}>@ {receiverNickname}</div> | ||
</div> | ||
</div> | ||
</Link> | ||
</li> | ||
), | ||
)} | ||
</ul> | ||
); | ||
}; | ||
|
||
export default MySupportedTteokgukCardList; | ||
|
||
const styles = { | ||
container: css({ | ||
display: "flex", | ||
flexFlow: "row wrap", | ||
gap: "1.6rem", | ||
}), | ||
cardContainer: css({ | ||
position: "relative", | ||
maxWidth: "calc(50% - 1.6rem)", | ||
width: "100%", | ||
height: "20.5rem", | ||
boxSizing: "border-box", | ||
borderRadius: "1rem", | ||
overflow: "hidden", | ||
paddingBottom: "5.3rem", | ||
}), | ||
imageContainer: css({ | ||
position: "relative", | ||
display: "flex", | ||
justifyContent: "center", | ||
height: "15.2rem", | ||
backgroundColor: "white", | ||
overflow: "hidden", | ||
}), | ||
cardContent: css({ | ||
width: "100%", | ||
height: "5.3rem", | ||
backgroundColor: "primary.80", | ||
padding: "0.8rem 1rem 0", | ||
}), | ||
cardTitle: css({ | ||
fontSize: "1.4rem", | ||
fontWeight: 700, | ||
}), | ||
cardNickname: css({ | ||
fontSize: "1.2rem", | ||
}), | ||
}; |
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
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
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