@blueprintjs-formik/datetime
Version:
Bindings for using Formik and Blueprint.js
17 lines (16 loc) • 748 B
TypeScript
/// <reference types="react" />
import { FieldConfig, FieldProps } from 'formik';
import { DateInputProps as BPDateInputProps } from '@blueprintjs/datetime';
export interface DateInputProps extends Omit<FieldConfig, 'children' | 'component' | 'as'>, Omit<BPDateInputProps, 'value' | 'name'> {
name: string;
formFormatDate?: (date: Date, locale?: string) => string;
formParseDate?: (str: string, locale?: string) => Date | false | null;
}
export interface FieldToDateInput extends FieldProps, Omit<DateInputProps, 'form'> {
}
/**
* Date input Blueprint component binded with Formik.
* @param {DateInputProps}
* @returns {JSX.Element}
*/
export declare function DateInput({ ...props }: DateInputProps): JSX.Element;