Created
September 6, 2021 04:35
-
-
Save chand1012/9b12dbbdff96da6e527929e6a3942c37 to your computer and use it in GitHub Desktop.
Simple profile card written with Geist UI React. License: https://chand1012.mit-license.org/
This file contains hidden or 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
import React from "react"; | |
import { Card, Grid, Link, Text, Avatar } from "@geist-ui/react"; | |
const ProfileCard = ({ | |
displayName, | |
username, | |
imageUrl, | |
description, | |
profileLink, | |
size, | |
}) => { | |
return ( | |
<Card hoverable> | |
<Grid.Container justify="center"> | |
<Grid> | |
<Avatar height={size + "px"} width={size + "px"} src={imageUrl} /> | |
</Grid> | |
</Grid.Container> | |
<Grid.Container justify="center"> | |
<Grid> | |
<Text b>{displayName}</Text> | |
</Grid> | |
</Grid.Container> | |
<Grid.Container justify="center"> | |
<Grid> | |
<Text small>{description}</Text> | |
</Grid> | |
</Grid.Container> | |
<Card.Footer> | |
<Grid.Container justify="center"> | |
<Grid> | |
<Link target="_blank" block href={profileLink}> | |
@{username} | |
</Link> | |
</Grid> | |
</Grid.Container> | |
</Card.Footer> | |
</Card> | |
); | |
}; | |
export default ProfileCard; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment