@sap-ux/ui-components
Version:
SAP UI Components Library
50 lines • 1.41 kB
TypeScript
import React from 'react';
import type { ITextField } from '../UIInput';
import './UIDatePicker.scss';
export type UIDatePickerProps = {
componentRef?: React.RefObject<ITextField>;
errorMessage?: string | JSX.Element;
defaultValue?: string;
dateOnly?: boolean;
onChange?: (event: React.FormEvent<HTMLInputElement | HTMLTextAreaElement>, newValue: string) => void;
onKeyDown?: (event: React.KeyboardEvent) => void;
onClick?: (event: React.MouseEvent) => void;
};
/**
* UIDatePicker component.
*
* @exports
* @class {UIDatePicker}
* @extends {React.Component<UIDatePickerProps>}
*/
export declare class UIDatePicker extends React.Component<UIDatePickerProps> {
state: {
value: string;
};
private readonly dateRegex;
private readonly dateTimeRegex;
/**
* Initializes component properties.
*
* @param {UIDatePickerProps} props
*/
constructor(props: UIDatePickerProps);
/**
* On input change event.
*
* @param {React.FormEvent<HTMLInputElement | HTMLTextAreaElement>} e
* @param {string} newValue
*/
private onInputChange;
/**
* On Date picker change.
*
* @param {React.FormEvent<HTMLInputElement | HTMLTextAreaElement>} e
*/
private onPickerChange;
/**
* @returns {JSX.Element}
*/
render(): JSX.Element;
}
//# sourceMappingURL=UIDatePicker.d.ts.map