All Downloads are FREE. Search and download functionalities are using the official Maven repository.

package.src.components.Avatar.Avatar.tsx Maven / Gradle / Ivy

Go to download

This library provides a set of common React components for use with the PatternFly reference implementation.

The newest version!
import * as React from 'react';
import styles from '@patternfly/react-styles/css/components/Avatar/avatar';
import { css } from '@patternfly/react-styles';

export interface AvatarProps
  extends React.DetailedHTMLProps, HTMLImageElement> {
  /** Additional classes added to the Avatar. */
  className?: string;
  /** Attribute that specifies the URL of the image for the Avatar. */
  src?: string;
  /** Attribute that specifies the alternate text of the image for the Avatar. */
  alt: string;
  /** Border to add */
  border?: 'light' | 'dark';
  /** Size variant of avatar. */
  size?: 'sm' | 'md' | 'lg' | 'xl';
}

export const Avatar: React.FunctionComponent = ({
  className = '',
  src = '',
  alt,
  border,
  size,
  ...props
}: AvatarProps) => (
  {alt}
);
Avatar.displayName = 'Avatar';




© 2015 - 2024 Weber Informatics LLC | Privacy Policy