UNPKG

decentraland-ui

Version:

Decentraland's UI components and styles

35 lines (34 loc) 1.33 kB
import * as React from 'react'; import 'react-semantic-ui-datepickers/dist/react-semantic-ui-datepickers.css'; import { InputProps } from 'semantic-ui-react/dist/commonjs/elements/Input/Input'; import './Field.css'; export declare type FieldProps = InputProps & { /** Input label*/ label?: string; /** Boolean flag to show an error, default on false*/ error?: boolean; /** Message to display below the input */ message?: React.ReactNode; /** Button text to display before input to dispatch an action*/ action?: string; /** On action function*/ onAction?: (event: React.MouseEvent<HTMLButtonElement>) => void; /** Style of input, default on simple*/ kind?: 'simple' | 'full'; /** Boolean flag to determine if it is resizable, default on false*/ fitContent?: boolean; /** Boolean flag to determine if datepicker can be cleared, default on true */ isClearable?: boolean; /** Defines the maximum number of characters the user can enter into the input */ maxLength?: number; }; export declare class Field extends React.PureComponent<FieldProps> { static defaultProps: { kind: string; fitContent: boolean; }; hasAction(): boolean; isAddress(): boolean; onChangeDatePicker: (e: any, data: any) => void; render(): JSX.Element; }