You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/dates.d.ts
+19-18Lines changed: 19 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -1,16 +1,17 @@
1
1
import{DateFormatNameOptions}from'./cldr';
2
2
3
3
/**
4
-
* Settings for the formatDate and parseDate functions.
4
+
* Settings for the `formatDate` and `parseDate` functions.
5
5
*/
6
6
exportinterfaceDateFormatOptions{
7
7
/**
8
-
* Defines the skeleton format used to get the pattern from the locale calendar [`availableFormats`](http://www.unicode.org/reports/tr35/tr35-dates.html#availableFormats_appendItems).
8
+
* Defines the skeleton format that is used to get the pattern from the
9
+
* [`availableFormats`](http://www.unicode.org/reports/tr35/tr35-dates.html#availableFormats_appendItems) of the locale calendar.
9
10
*/
10
11
skeleton?: string;
11
12
12
13
/**
13
-
* Defines the exact pattern to be used to format the date.
14
+
* Defines the exact pattern that will be used to format the date.
* Converts a string to a `Date` object based on the specified format and locale.
95
96
*
96
-
* @param value Defines the string to be parsed.
97
-
* @param format Defines a string representing a predefined or custom date format, a configuration object, or an array of formats that should be used to parse the value.
98
-
* @param locale The optional locale id. If not specified, the `"en"` locale id is used.
99
-
* @returns The parsed date.
97
+
* @param value - Defines the string that will be parsed.
98
+
* @param format - Defines a string that represents a predefined or custom date format, a configuration object, or an array of formats that should be used to parse the value.
99
+
* @param locale - The optional locale `id`. If not specified, the `id` of the `"en"` locale is used.
* Defines the minimum number of integer digits to be used in the formatting.
28
+
* Defines the minimum number of integer digits that will be used in the formatting.
28
29
*/
29
30
minimumIntegerDigits?: number;
30
31
31
32
/**
32
-
* Defines the minimum number of fraction digits to use.
33
-
* The default value for the decimal and percent formatting is 0 (zero).
34
-
* The default value of the currency formatting is the number of digits for the currency from the supplemental `currencyData` or 2 if no info is provided for the currency.
33
+
* Defines the minimum number of fraction digits that will be used.
34
+
* The default value of the decimal and percent formatting is `0` (zero).
35
+
* The default value of the currency formatting is the number of digits for the currency from the supplemental `currencyData`.
36
+
* If no information about the currency is provided, the default value of the currency formatting is `2`.
35
37
*/
36
38
minimumFractionDigits?: number;
37
39
38
40
/**
39
-
* Defines the maximum number of fraction digits to be used.
40
-
* The default value of the decimal formatting is the greater one between `minimumFractionDigits` and 3.
41
-
* The default value of the currency formatting is the greater one between `minimumFractionDigits` and the number of digits for the currency from the supplemental `currencyData` or 2 if no info is provided for the currency.
42
-
* The default value of the percent formatting is the greater one between `minimumFractionDigits` and 0 (zero).
41
+
* Defines the maximum number of fraction digits that will be used.
42
+
* The default value of the decimal formatting is the greater one between `minimumFractionDigits` and `3`.
43
+
* The default value of the currency formatting is the greater one between `minimumFractionDigits` and the number of digits for the currency from the supplemental `currencyData`.
44
+
* If no information about the currency is provided, the default value of the currency formatting is the greater one between `minimumFractionDigits` and `2`.
45
+
* The default value of the percent formatting is the greater one between `minimumFractionDigits` and `0` (zero).
43
46
*/
44
47
maximumFractionDigits?: number;
45
48
}
46
49
47
50
/**
48
51
* Converts a string to a `Number` based on the specified locale.
49
52
*
50
-
* @param value The string to be parsed.
51
-
* @param locale The locale id defining the locale which information should be used to parse the string.
52
-
* @param format The format used to parse the string. Usefull if parsing non-default currencies.
53
-
* @returns The parsed number.
53
+
* @param value - The string that will be parsed.
54
+
* @param locale - The locale `id` that defines the locale whose information should be used to parse the string.
55
+
* @param format - The format that is used to parse the string. Useful when non-default currencies are parsed.
0 commit comments