For AI agents: the complete documentation index is available at https://rickyshin93.github.io/tao-ui/llms.txt, the full documentation bundle is available at https://rickyshin93.github.io/tao-ui/llms-full.txt, and this page is available as Markdown at https://rickyshin93.github.io/tao-ui/components/input-number.md.
v0.0.57
  • English
  • InputNumber

    Data Entry@rockshin/tao-ui

    A styled numeric input built on tao-ui number formatting and validation behavior.

    When to use

    Use InputNumber for numeric values that need min, max, step, precision, or formatted display.

    Recommended

    • Set min and max when the domain is bounded.
    • Use the headless API when custom rendering is required.

    Avoid

    • Do not use a numeric input for identifiers such as account numbers.

    Examples

    Basic usage

    $USD
    TSX

    Currency and percentage

    €
    %
    TSX

    Sizes, variants, and bounds

    TSX

    Currency formatting

    Thousands separators, decimals, and a prefix format display while retaining a usable value.

    €
    actual value: "150000"
    TSX

    Prefix and suffix

    Use affixes for units instead of storing them in the numeric value.

    $USD
    actual value: ""
    TSX

    Three sizes

    Compare three control sizes with the same numeric behavior.

    ¥
    ¥
    ¥
    TSX

    Visual variants

    Keep the same controlled input behavior across visual variants.

    ¥
    ¥
    ¥
    TSX

    Percentages

    Set decimal precision and a percent suffix; this example does not convert between percentages and fractions.

    %
    actual value: ""
    TSX

    Numeric bounds

    Set the accepted range and observe the value during editing and on blur.

    actual value: ""
    TSX

    Regional formatting

    Regional grouping, decimal symbols and digits inherit TaoProvider.locale.numberLocale; set locale="fr-FR" on this component to override it. Explicit separators take precedence. Numeric input keeps canonical ASCII strings and precision while displaying localized digits.

    API

    InputNumber

    PropertyDescriptionTypeDefault Value
    disabledWhether to disableboolean | undefined-
    classNameAdditional css classstring | undefined-
    localeBCP 47 locale. Defaults to the provider's number locale.string | undefined-