Input

Use and Import

import Input from 'nes-design/es/Input';   OR   import { Input } from 'nes-design';
Copy

Tips

Input / Textarea share a common component, which needs to be distinguished by inputType

输入框和文本框共用一个组件,需要使用 inputType 参数进行区分

Case

Input / TextArea

Input Value:

Status

Suffix

Before Suffix
After Suffix

Input Type

text
time
checkbox
password
date
email

theme

Props

Prop / 参数Description / 描述Type / 类型Default / 默认值
inputTypeinput type / 输入框的类型'input' | 'textarea'input
themetheme / 输入框的主题'dark'-
statusinput status / 输入框的状态'success' | 'warning' | 'error' | 'disabled'-
addonBeforebefore suffix / 前缀React.ReactNode-
addonAfterafter suffix / 后缀React.ReactNode-
disableddisabled / 禁止boolean-
spanPropsspan label props / span 外层容器属性React.HTMLAttributes<HTMLSpanElement>-
Prop / 参数Description / 描述Type / 类型Default / 默认值
...restmore attrs(Example: onChange, onFocus) / 更多属性(Example: onChange)React.InputHTMLAttributes<HTMLTextAreaElement>-
Prop / 参数Description / 描述Type / 类型Default / 默认值
...restmore attrs(Example: onChange, onFocus) / 更多属性(Example: onChange)React.TextareaHTMLAttributes<HTMLInputElement>-