--- 
title: Avatar
description: User avatar display
category: components
a1Densities: true
a1Full: true
group: Data Display

module: NxAvatarModule
components:
  - name: NxAvatarComponent
    selector: [nxAvatar]
    inputs:
      - name: disabled
        default: input(false, { transform: booleanAttribute })
        type: "InputSignalWithTransform<boolean, unknown>"
      - name: inverseInput
        desc: "Whether the avatar should use the inverse style for dark backgrounds. When not set, it follows the surface the avatar is placed on (see `nxSurface`)."
        default: input<boolean | undefined, unknown>(undefined, {
      transform: nxOptionalBooleanAttribute,
      alias: 'inverse',
    })
        type: "InputSignalWithTransform<boolean | undefined, unknown>"
      - name: accentColor
        default: input<NxAvatarAccentColor>('default')
        type: "InputSignal<'yellow' | 'orange' | 'red' | 'purple' | 'teal' | 'aqua' | 'blue' | 'green' | 'gray' | 'default'>"
      - name: prominence
        default: input<NxAvatarProminence>('subtle')
        type: "InputSignal<'subtle' | 'attention'>"
      - name: size
        desc: "Sets the size of the avatar. Default: 'medium'."
        type: "'xsmall' | 'small' | 'small-medium' | 'medium' | 'large' | 'xlarge' | 's' | 'm' | 'l' | 'xl'"
  - name: NxAvatarButtonDirective
    selector: button[nxAvatar]
  - name: NxAvatarIndicatorDirective
    selector: [nxAvatarIndicator]
    desc: |
      Marks an element as the avatar's status indicator, projected into the avatar's corner slot.

---
# Overview
Depending on the use case the avatar can be used as a non-clickable element or as a button.
