UNPKG

@chief-editor/ui

Version:

UI Component for chief editor

8 lines (7 loc) 1.41 kB
import { InputHTMLAttributes, TextareaHTMLAttributes } from 'react'; export declare const INPUT_COMMON_ATTRS: ["accept", "alt", "autoComplete", "autoFocus", "capture", "crossOrigin", "form", "formAction", "formEncType", "formMethod", "formNoValidate", "formTarget", "height", "list", "max", "maxLength", "min", "minLength", "multiple", "name", "pattern", "placeholder", "readOnly", "required", "src", "step", "width"]; export declare const INPUT_ATTRS: ("max" | "required" | "disabled" | "form" | "pattern" | "size" | "multiple" | "height" | "width" | "src" | "type" | "value" | "accept" | "name" | "min" | "crossOrigin" | "placeholder" | "alt" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "autoComplete" | "capture" | "checked" | "list" | "maxLength" | "minLength" | "readOnly" | "step")[]; export declare const TEXTAREA_COMMON_ATTRS: ["autoComplete", "autoFocus", "cols", "dirName", "form", "maxLength", "minLength", "name", "placeholder", "readOnly", "required", "rows", "wrap"]; export declare type InputCommonAttributes = Pick<InputHTMLAttributes<HTMLInputElement>, (typeof INPUT_COMMON_ATTRS)[number]>; export declare type TextareaCommonAttributes = Pick<TextareaHTMLAttributes<HTMLTextAreaElement>, (typeof TEXTAREA_COMMON_ATTRS)[number]>; export declare type InputAttributes = Pick<InputHTMLAttributes<HTMLInputElement>, (typeof INPUT_ATTRS)[number]>;