Socket
Socket
Sign inDemoInstall

@highlight-ui/avatar

Package Overview
Dependencies
30
Maintainers
10
Versions
151
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @highlight-ui/avatar

Avatar UI component for the Personio UI Library


Version published
Weekly downloads
1.7K
decreased by-19.14%
Maintainers
10
Install size
5.81 MB
Created
Weekly downloads
 

Readme

Source

npm personio.design storybook.personio.design

@highlight-ui/avatar

Using npm:

npm install @highlight-ui/avatar

Using yarn:

yarn add @highlight-ui/avatar

Using pnpm:

pnpm install @highlight-ui/avatar

In your (S)CSS file:

@import url('@highlight-ui/avatar');

Once the package is installed, you can import the library:

import { Avatar } from '@highlight-ui/avatar';

Usage

import React, { useState } from 'react';
import { Avatar } from '@highlight-ui/avatar';

export default function AlertExample() {
  return <Avatar name="Test Name" src="/img.png" url="/url" />;
}

Props 📜

PropTypeRequiredDefaultDescription
animatebooleanNofalseIf true, then Avatar will be animated on mouse hover
containerClassnamestringNoA CSS class applied on component container
imageClassnamestringNoA CSS class to be applied on the image element
namestringNoName of the Avatar. If the image is not available, use first letters of the name
avatarSizenumberNoThe width and height attributes for the container element
iconSizenumberNoThe size attribute for the Icon element
typographyFontSize (deprecated)TokenisedTypographyProps['fontSize']NoThe fontSize attribute for the Typography element
srcstringNoImage source for the Avatar
urlstringNoUrl to go to on click
imageAltTextstringNoAlternative text for an image element
imageLoadingReact.ImgHTMLAttributes<HTMLImageElement>['loading']NoOptional property to indicate how the browser should load images on img tags

Contributing 🖌️

Please visit personio.design for usage guidelines and visual examples.

If you're interested in contributing, please visit our contribution page.

FAQs

Last updated on 23 Feb 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