react-native-chating-ui-kit
Version:
CometChat React Native UI Kit is a collection of custom UI Components designed to build text , chat and calling features in your application. The UI Kit is developed to keep developers in mind and aims to reduce development efforts significantly
42 lines (41 loc) • 1.09 kB
TypeScript
import React from 'react';
import { DateStyle, DateStyleInterface } from './DateStyle';
/**
* CometChatDate is a component useful for displaying date/time
* This component displays the date/time based on pattern parameter.
*
* @Version 1.0.0
* @author CometChat
*
*/
export interface CometChatDateInterface {
/**
* Unix epoch time.
*/
timeStamp: number;
/**
* Pattern for Date.
* one of
* 1. timeFormat: "hh:mm a".
* 2. dayDateFormat: Today, Yesterday, week-day or "d MMM, yyyy".
* 3. dayDateTimeFormat: Today, Yesterday, week-day or "dd/mm/yyyy".
*/
pattern: 'timeFormat' | 'dayDateFormat' | 'dayDateTimeFormat';
/**
* A string for custom date reprasentation.
*/
customDateString?: string;
/**
* object of DateStyle class.
*/
style?: DateStyleInterface;
}
export declare const CometChatDate: {
(props: CometChatDateInterface): React.JSX.Element;
defaultProps: {
timeStamp: number;
pattern: string;
customDateString: any;
style: DateStyle;
};
};