@spicy-ui/core
Version:
A themable and extensible React UI library, ready to use out of the box
22 lines (21 loc) • 1.02 kB
TypeScript
import * as React from 'react';
import { SxProp } from '../../system';
import { AsProp, ChildrenProp, LiteralUnion } from '../../types';
declare type InputSizes = 'xs' | 'sm' | 'md' | 'lg';
declare type InputVariants = 'outlined' | 'filled' | 'underlined' | 'unstyled';
export interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'width' | 'height' | 'size'>, AsProp, ChildrenProp, SxProp {
/** If `true`, the input will be disabled. */
isDisabled?: boolean;
/** If `true`, the input will be marked as invalid. */
isInvalid?: boolean;
/** If `true`, the input will be read only. */
isReadOnly?: boolean;
/** If `true`, the input will be required. */
isRequired?: boolean;
/** Size of the input. */
size?: LiteralUnion<InputSizes>;
/** Variant of the input. */
variant?: LiteralUnion<InputVariants>;
}
export declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
export {};