@hmiproject/helio-sdk
    Preparing search index...

    Type Alias NumberInputProps

    type NumberInputProps = {
        autoFocus?: boolean;
        defaultValue?: number;
        disabled?: boolean;
        format?: Intl.NumberFormatOptions;
        invalid?: boolean;
        leftItems?: ReactNode;
        placeholder?: string;
        range?: { max?: number; min?: number };
        readOnly?: boolean;
        rightItems?: ReactNode;
        showStepper?: boolean;
        stepSize?: number;
        style?: CSSProperties;
        unit?: string;
        value?: number;
        onBlur?(event: FocusEvent): void;
        onChange(nextValue: number): void;
        onFocus?(event: FocusEvent): void;
    }
    Index

    Properties

    autoFocus?: boolean
    defaultValue?: number

    Default value of the input if using as an "uncontrolled" component.

    If this prop changes over time, the field will not be updated.

    disabled?: boolean
    format?: Intl.NumberFormatOptions

    Formatting options for displaying the value.

    Values will automatically be formatted using the currently active locale.

    invalid?: boolean
    leftItems?: ReactNode
    placeholder?: string

    Placeholder text that will be displayed while the field has no value.

    range?: { max?: number; min?: number }
    readOnly?: boolean
    rightItems?: ReactNode
    showStepper?: boolean

    Whether to show increment/decrement buttons

    stepSize?: number

    Integer step size

    style?: CSSProperties
    unit?: string

    Unit information displayed next to the current value

    value?: number

    Current value of the input if using a "controlled" component

    If this prop changes over time, the field will be updated.

    Methods

    • Called when the input loses focus.

      Parameters

      • event: FocusEvent

      Returns void

    • Called with the new input value when the value is changed by the user.

      Parameters

      • nextValue: number

      Returns void

    • Called when the input receives focus.

      Parameters

      • event: FocusEvent

      Returns void