Socket
Socket
Sign inDemoInstall

@commercetools-uikit/avatar

Package Overview
Dependencies
76
Maintainers
3
Versions
699
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @commercetools-uikit/avatar

A component for rendering profile images


Version published
Weekly downloads
8.7K
increased by42.18%
Maintainers
3
Created
Weekly downloads
 

Readme

Source

Avatar

Description

A component for rendering profile images

Installation

yarn add @commercetools-uikit/avatar
npm --save install @commercetools-uikit/avatar

Additionally install the peer dependencies (if not present)

yarn add react
npm --save install react

Usage

import Avatar from '@commercetools-uikit/avatar';

const Example = () => (
  <Avatar
    gravatarHash="20c9c1b252b46ab49d6f7a4cee9c3e68"
    firstName="John"
    lastName="Doe"
    size="s"
  />
);

export default Example;

Properties

PropsTypeRequiredDefaultDescription
firstNamestring''The first name of the user.
lastNamestring''The last name of the user.
gravatarHashstringThe hashed string of the user gravatar.
isHighlightedbooleanfalseEnhances the appearance of the avatar.
sizeunion
Possible values:
's' , 'm' , 'l'
's'The size of the rendered avatar.
colorunion
Possible values:
'accent' , 'purple' , 'turquoise' , 'brown'
'accent'The color of the avatar.
iconReactElementan component

Keywords

FAQs

Last updated on 17 Apr 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc