Input

A standard text box

Installation

import { Input } from 'uxp/components';

Signature

const Input: React.ForwardRefExoticComponent<React.RefAttributes<IInputInstanceProps> & IInputProps>

Properties

Name
Type
Mandatory
Default Value
Example Value

type

No

-

-

value

string

Yes

-

-

onChange

(value: string) => void

Yes

-

-

onFocus

() => void

No

-

-

onBlur

(vale: string) => void

No

-

-

onKeyDown

(e: React.KeyboardEvent, val: string) => void

No

-

-

className

string

No

-

-

hasIndicator

boolean

No

-

-

indicatorColor

string

No

-

-

isValid

boolean

No

-

-

inputAttr

{ [key: string]: string | boolean }

No

-

-

placeholder

string

No

-

-

inline

boolean

No

-

-

styles

React.CSSProperties

No

-

-

readOnly

boolean

No

-

-

tabIndex

number

No

-

-

spacingMode

No

-

-

Ref Handlers

Available methods through ref:

Method
Type
Description

focus

() => void

focus the input

getElement

() => React.MutableRefObject

this will return the element

Last updated