--- 
title: Price
description: Formatted price display with locale-aware currency formatting
category: components
a1Full: true
group: Data Display

module: NxPriceModule
components:
  - name: NxPriceComponent
    selector: nx-price
    inputs:
      - name: value
        desc: "The numeric price value to display."
        default: input<number>(0)
        type: "InputSignal<number>"
      - name: currency
        desc: "The ISO 4217 currency code (e.g., 'USD', 'EUR')."
        default: input<string>('USD')
        type: "InputSignal<string>"
      - name: locale
        desc: "The locale to use for formatting (e.g., 'en-US', 'de-DE'). If not provided, uses the application's LOCALE_ID."
        default: input<string>()
        type: "InputSignal<string | undefined>"
      - name: size
        desc: "The size of the price display. Default is 'm' (medium).  A wrapping component providing `NX_PRICE_CONTEXT` (e.g. a comparison table header cell) owns the size and overrides this input, so that its prices stay consistent."
        default: input<NxPriceSize>('m')
        type: "InputSignal<'s' | 'm' | 'l' | 'xl' | '2xl' | '3xl' | '4xl' | '5xl' | '6xl'>"
      - name: inverseInput
        desc: "Whether to apply inverse styling, suitable for dark backgrounds. When not set, it follows the surface the price is placed on (see `nxSurface`)."
        default: input<boolean | undefined, unknown>(undefined, {
      transform: nxOptionalBooleanAttribute,
      alias: 'inverse',
    })
        type: "InputSignalWithTransform<boolean | undefined, unknown>"
      - name: vertical
        desc: "Whether to stack the prefix, price and suffix vertically."
        default: input(false, { transform: booleanAttribute })
        type: "InputSignalWithTransform<boolean, unknown>"
      - name: colorSchemeInput
        desc: "The color scheme of the price. Only relevant for the A1 Design. When not set, it follows the surface the price is placed on (see `nxSurface`)."
        default: input<NxPriceColorScheme | undefined>(undefined, {
      alias: 'colorScheme',
    })
        type: "InputSignal<'default' | 'on-accent-attention' | undefined>"
      - name: superscript
        desc: "Whether to render the currency symbol and decimals as superscript."
        default: input(false, { transform: booleanAttribute })
        type: "InputSignalWithTransform<boolean, unknown>"
      - name: prefix
        desc: "Optional prefix text displayed before the price (e.g., 'from')."
        default: input<string>()
        type: "InputSignal<string | undefined>"
      - name: suffix
        desc: "Optional suffix text displayed after the price (e.g., 'monthly')."
        default: input<string>()
        type: "InputSignal<string | undefined>"

---