Askr documentation
Generated API snapshot

@askrjs/themes/avatar

Exports from the declarations published in @askrjs/themes. Signatures reflect the published artifact.

Exports

This entrypoint publishes 12 exports. Use the anchored symbol rows for direct links. Type-only exports are labeled separately from runtime values.

Avatartype

Avatar: { (props: AvatarProps): JSX.Element; (props: AvatarAsChildProps): JSX.Element; }

Renders the avatar part of avatar. Supports polymorphic rendering via asChild.

AvatarAsChildPropstype

AvatarAsChildProps: BoxAsChildProps & AvatarOwnProps

Props for the asChild (polymorphic) rendering of Avatar.

asChild
asChild: true;
children
children: JSXElement;
id
id?: string | undefined;
ref
ref?: Ref<Element>;

AvatarFallbacktype

AvatarFallback: { (props: AvatarFallbackProps): JSX.Element | null; (props: AvatarFallbackAsChildProps): JSX.Element | null; }

Renders the avatar-fallback part of avatar. Supports polymorphic rendering via asChild.

AvatarFallbackAsChildPropstype

AvatarFallbackAsChildProps: BoxAsChildProps & AvatarFallbackOwnProps

Props for the asChild (polymorphic) rendering of Avatar Fallback.

asChild
asChild: true;
children
children: JSXElement;
ref
ref?: Ref<Element>;

AvatarFallbackOwnPropstype

AvatarFallbackOwnProps: {
  children?: unknown;
}

Own props for Avatar Fallback, before merging with native element attributes.

children
children?: unknown;

AvatarFallbackPropstype

AvatarFallbackProps: BoxProps<'span', HTMLSpanElement> & AvatarFallbackOwnProps

Props for Avatar Fallback.

asChild
asChild?: false | undefined;
children
children?: unknown;
ref
ref?: Ref<HTMLSpanElement>;

AvatarImagetype

AvatarImage: (props: AvatarImageProps) => JSX.Element

Renders the avatar-image part of avatar.

AvatarImageOwnPropstype

AvatarImageOwnProps: {
  src?: string;
  alt: string;
  onLoadingStatusChange?: (status: AvatarLoadingStatus) => void;
}

Own props for Avatar Image, before merging with native element attributes.

alt
alt: string;
onLoadingStatusChange
onLoadingStatusChange?: ((status: AvatarLoadingStatus) => void) | undefined;
src
src?: string | undefined;

AvatarImagePropstype

AvatarImageProps: Omit<JSX.IntrinsicElements['img'], 'children' | 'ref' | 'onLoad' | 'onError' | 'alt' | 'src'> & AvatarImageOwnProps & {
  ref?: Ref<HTMLImageElement>;
}

Props for Avatar Image.

alt
alt: string;
onLoadingStatusChange
onLoadingStatusChange?: ((status: AvatarLoadingStatus) => void) | undefined;
ref
ref?: Ref<HTMLImageElement>;
src
src?: string | undefined;

AvatarLoadingStatustype

AvatarLoadingStatus: 'idle' | 'loading' | 'loaded' | 'error'

Avatar Loading Status.

AvatarOwnPropstype

AvatarOwnProps: {
  children?: unknown;
  id?: string;
}

Own props for Avatar, before merging with native element attributes.

children
children?: unknown;
id
id?: string | undefined;

AvatarPropstype

AvatarProps: BoxProps<'span', HTMLSpanElement> & AvatarOwnProps

Props for Avatar.

asChild
asChild?: false | undefined;
children
children?: unknown;
id
id?: string | undefined;
ref
ref?: Ref<HTMLSpanElement>;