@brighthr/component-avatar
TypeScript icon, indicating that this package has built-in type declarations

1.1.6 • Public • Published

Avatar

To install, type the following into the command line at the root of your project:

npm i @brighthr/component-avatar

To implement the Avatar component into your project you’ll need to add the import:

import Avatar from '@brighthr/component-avatar';

After adding import into your project you can use it simply like:

<Avatar />

Props

Name Type Default Description
imageHref string Sets the src attribute for the <img />.
name string Sets the initials to be shown if no imageHref is provided. Also sets image alt and tooltip on hover.
presence 'in' 'out' 'absent' Sets a different colored circle at the bottom of the avatar.
size 'xxs' 'xs' 'sm' 'base' 'lg' 'xl' 'xxl' Sets the size of the avatar.

Readme

Keywords

none

Package Sidebar

Install

npm i @brighthr/component-avatar

Weekly Downloads

451

Version

1.1.6

License

MIT

Unpacked Size

21.8 kB

Total Files

8

Last publish

Collaborators

  • bright.hr