Add doc and examples.
This commit is contained in:
parent
d5b716ac3e
commit
daf0811bb3
1 changed files with 32 additions and 2 deletions
|
|
@ -16,11 +16,41 @@ interface DateFormatter {
|
||||||
}
|
}
|
||||||
|
|
||||||
enum class DateFormatterMode {
|
enum class DateFormatterMode {
|
||||||
|
/**
|
||||||
|
* Full date and time.
|
||||||
|
* Example:
|
||||||
|
* "April 6, 1980 at 6:35 PM"
|
||||||
|
* Format can be shorter when useRelative is true.
|
||||||
|
* Example:
|
||||||
|
* "6:35 PM"
|
||||||
|
*/
|
||||||
Full,
|
Full,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Only month and year.
|
||||||
|
* Example:
|
||||||
|
* "April 1980"
|
||||||
|
* "This month" can be returned when useRelative is true.
|
||||||
|
* Example:
|
||||||
|
* "This month"
|
||||||
|
*/
|
||||||
Month,
|
Month,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Only day.
|
||||||
|
* Example:
|
||||||
|
* "Sunday 6 April"
|
||||||
|
* "Today", "Yesterday" and day of week can be returned when useRelative is true.
|
||||||
|
*/
|
||||||
Day,
|
Day,
|
||||||
// Time if same day, else date
|
|
||||||
|
/**
|
||||||
|
* Time if same day, else date.
|
||||||
|
*/
|
||||||
TimeOrDate,
|
TimeOrDate,
|
||||||
// Only time whatever the day
|
|
||||||
|
/**
|
||||||
|
* Only time whatever the day.
|
||||||
|
*/
|
||||||
TimeOnly,
|
TimeOnly,
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue