Skip to content
This repository was archived by the owner on Mar 1, 2024. It is now read-only.

Commit 7407cac

Browse files
committed
feat(Profile): add bio prop, used instead of/before children
1 parent fc20a8c commit 7407cac

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/components/Profile/Profile.react.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ export type Props = {|
1414
+avatarURL?: string,
1515
+twitterURL?: string,
1616
+backgroundURL?: string,
17+
+bio?: string,
1718
|};
1819

1920
function Profile({
@@ -23,6 +24,7 @@ function Profile({
2324
avatarURL = "",
2425
twitterURL = "",
2526
backgroundURL = "",
27+
bio,
2628
}: Props): React.Node {
2729
const classes = cn("card card-profile", className);
2830
return (
@@ -31,7 +33,7 @@ function Profile({
3133
<Card.Body className="text-center">
3234
<ProfileImage avatarURL={avatarURL} />
3335
<Header.H3 className="mb-3">{name}</Header.H3>
34-
<p className="mb-4">{children}</p>
36+
<p className="mb-4">{bio || children}</p>
3537
<Button outline color="primary" size="sm">
3638
<Icon name="twitter" prefix="fa" /> Follow
3739
</Button>

0 commit comments

Comments
 (0)