Skip to main content

Name card

Username#

Show username using username prop.

<>
<NameCard {"user":{"username":"james"}} />
</>

Full name#

Show full name using fullName prop.

<>
<NameCard {"user":{"details":{"fullName":"James Smith"}}} />
</>

Avatar size#

You can change avatar size with avatarSize prop.

<>
<NameCard {"user":{"details":{"fullName":"James Smith"}},"avatarSize":50} />
</>

User E-mail#

Show user e-mail using email prop.

<>
<NameCard {"user":{"details":{"fullName":"James Smith"},"email":"[email protected]"}} />
</>

Second line#

Show second line using secondLine prop.

J.S
<>
<NameCard {"user":{"details":{"fullName":"James Smith"}},"secondLine":"Intern"} />
</>

API#

import Namecard from "erxes-ui/lib/components/namecard/Namecard";
NameTypeDescription
userdetailsfullNamestringFullname object of user. If you have details and username, it will only show detail
emailstringEmail object of user
secondLinestringLine below the username or full name. You can write anything in the second line
avatarSizenumberAvatar size of your name card
Last updated on by zulaann