@formatjs/intl-datetimeformat 6.3.1 → 6.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/add-all-tz.js +1 -1
- package/add-golden-tz.js +1 -1
- package/lib/src/abstract/FormatDateTime.d.ts +2 -1
- package/lib/src/abstract/FormatDateTime.d.ts.map +1 -1
- package/lib/src/abstract/FormatDateTimePattern.d.ts +3 -3
- package/lib/src/abstract/FormatDateTimePattern.d.ts.map +1 -1
- package/lib/src/abstract/FormatDateTimePattern.js +0 -1
- package/lib/src/abstract/InitializeDateTimeFormat.d.ts +2 -2
- package/lib/src/abstract/InitializeDateTimeFormat.d.ts.map +1 -1
- package/lib/src/abstract/PartitionDateTimePattern.d.ts +2 -2
- package/lib/src/abstract/PartitionDateTimePattern.d.ts.map +1 -1
- package/lib/src/data/all-tz.js +295 -295
- package/lib/src/data/links.d.ts +171 -51
- package/lib/src/data/links.d.ts.map +1 -1
- package/lib/src/data/links.js +172 -52
- package/lib/src/types.d.ts +4 -4
- package/lib/src/types.d.ts.map +1 -1
- package/package.json +3 -3
- package/polyfill.iife.js +220 -100
- package/src/abstract/FormatDateTime.d.ts +2 -1
- package/src/abstract/FormatDateTime.d.ts.map +1 -1
- package/src/abstract/FormatDateTimePattern.d.ts +3 -3
- package/src/abstract/FormatDateTimePattern.d.ts.map +1 -1
- package/src/abstract/FormatDateTimePattern.js +0 -1
- package/src/abstract/InitializeDateTimeFormat.d.ts +2 -2
- package/src/abstract/InitializeDateTimeFormat.d.ts.map +1 -1
- package/src/abstract/PartitionDateTimePattern.d.ts +2 -2
- package/src/abstract/PartitionDateTimePattern.d.ts.map +1 -1
- package/src/data/all-tz.js +295 -295
- package/src/data/links.d.ts +171 -51
- package/src/data/links.d.ts.map +1 -1
- package/src/data/links.js +172 -52
- package/src/types.d.ts +4 -4
- package/src/types.d.ts.map +1 -1
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { DateTimeFormat } from '@formatjs/ecma402-abstract';
|
|
1
2
|
import { PartitionDateTimePattern } from './PartitionDateTimePattern';
|
|
2
3
|
/**
|
|
3
4
|
* https://tc39.es/ecma402/#sec-formatdatetime
|
|
4
5
|
* @param dtf DateTimeFormat
|
|
5
6
|
* @param x
|
|
6
7
|
*/
|
|
7
|
-
export declare function FormatDateTime(dtf: Intl.DateTimeFormat, x: number, implDetails: Parameters<typeof PartitionDateTimePattern>[2]): string;
|
|
8
|
+
export declare function FormatDateTime(dtf: Intl.DateTimeFormat | DateTimeFormat, x: number, implDetails: Parameters<typeof PartitionDateTimePattern>[2]): string;
|
|
8
9
|
//# sourceMappingURL=FormatDateTime.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormatDateTime.d.ts","sourceRoot":"","sources":["FormatDateTime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,wBAAwB,EAAC,MAAM,4BAA4B,CAAA;AAEnE;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,IAAI,CAAC,cAAc,
|
|
1
|
+
{"version":3,"file":"FormatDateTime.d.ts","sourceRoot":"","sources":["FormatDateTime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,cAAc,EAAC,MAAM,4BAA4B,CAAA;AACzD,OAAO,EAAC,wBAAwB,EAAC,MAAM,4BAA4B,CAAA;AAEnE;;;;GAIG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,IAAI,CAAC,cAAc,GAAG,cAAc,EACzC,CAAC,EAAE,MAAM,EACT,WAAW,EAAE,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC,CAAC,CAAC,UAQ5D"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { IntlDateTimeFormatInternal, DateTimeFormatLocaleInternalData, IntlDateTimeFormatPart } from '@formatjs/ecma402-abstract';
|
|
1
|
+
import { IntlDateTimeFormatInternal, DateTimeFormatLocaleInternalData, IntlDateTimeFormatPart, DateTimeFormat } from '@formatjs/ecma402-abstract';
|
|
2
2
|
import { ToLocalTimeImplDetails } from './ToLocalTime';
|
|
3
3
|
export interface FormatDateTimePatternImplDetails {
|
|
4
|
-
getInternalSlots(dtf: Intl.DateTimeFormat): IntlDateTimeFormatInternal;
|
|
4
|
+
getInternalSlots(dtf: Intl.DateTimeFormat | DateTimeFormat): IntlDateTimeFormatInternal;
|
|
5
5
|
localeData: Record<string, DateTimeFormatLocaleInternalData>;
|
|
6
6
|
getDefaultTimeZone(): string;
|
|
7
7
|
}
|
|
@@ -10,5 +10,5 @@ export interface FormatDateTimePatternImplDetails {
|
|
|
10
10
|
* @param dtf
|
|
11
11
|
* @param x
|
|
12
12
|
*/
|
|
13
|
-
export declare function FormatDateTimePattern(dtf: Intl.DateTimeFormat, patternParts: IntlDateTimeFormatPart[], x: number, { getInternalSlots, localeData, getDefaultTimeZone, tzData, }: FormatDateTimePatternImplDetails & ToLocalTimeImplDetails): IntlDateTimeFormatPart[];
|
|
13
|
+
export declare function FormatDateTimePattern(dtf: Intl.DateTimeFormat | DateTimeFormat, patternParts: IntlDateTimeFormatPart[], x: number, { getInternalSlots, localeData, getDefaultTimeZone, tzData, }: FormatDateTimePatternImplDetails & ToLocalTimeImplDetails): IntlDateTimeFormatPart[];
|
|
14
14
|
//# sourceMappingURL=FormatDateTimePattern.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormatDateTimePattern.d.ts","sourceRoot":"","sources":["FormatDateTimePattern.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAC1B,gCAAgC,EAChC,sBAAsB,
|
|
1
|
+
{"version":3,"file":"FormatDateTimePattern.d.ts","sourceRoot":"","sources":["FormatDateTimePattern.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAC1B,gCAAgC,EAChC,sBAAsB,EAEtB,cAAc,EACf,MAAM,4BAA4B,CAAA;AAGnC,OAAO,EAAc,sBAAsB,EAAC,MAAM,eAAe,CAAA;AAsCjE,MAAM,WAAW,gCAAgC;IAC/C,gBAAgB,CACd,GAAG,EAAE,IAAI,CAAC,cAAc,GAAG,cAAc,GACxC,0BAA0B,CAAA;IAC7B,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,gCAAgC,CAAC,CAAA;IAC5D,kBAAkB,IAAI,MAAM,CAAA;CAC7B;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,IAAI,CAAC,cAAc,GAAG,cAAc,EACzC,YAAY,EAAE,sBAAsB,EAAE,EACtC,CAAC,EAAE,MAAM,EACT,EACE,gBAAgB,EAChB,UAAU,EACV,kBAAkB,EAClB,MAAM,GACP,EAAE,gCAAgC,GAAG,sBAAsB,GAC3D,sBAAsB,EAAE,CAyJ1B"}
|
|
@@ -77,7 +77,6 @@ function FormatDateTimePattern(dtf, patternParts, x, _a) {
|
|
|
77
77
|
else if (p === 'fractionalSecondDigits') {
|
|
78
78
|
var v = Math.floor(tm.millisecond * Math.pow(10, ((fractionalSecondDigits || 0) - 3)));
|
|
79
79
|
result.push({
|
|
80
|
-
// @ts-expect-error Spec is not there yet
|
|
81
80
|
type: 'fractionalSecond',
|
|
82
81
|
value: nf3.format(v),
|
|
83
82
|
});
|
|
@@ -5,8 +5,8 @@ import { IntlDateTimeFormatInternal, DateTimeFormatLocaleInternalData, DateTimeF
|
|
|
5
5
|
* @param locales locales
|
|
6
6
|
* @param opts options
|
|
7
7
|
*/
|
|
8
|
-
export declare function InitializeDateTimeFormat(dtf: DateTimeFormat, locales: string | string[] | undefined, opts: Intl.DateTimeFormatOptions | undefined, { getInternalSlots, availableLocales, localeData, getDefaultLocale, getDefaultTimeZone, relevantExtensionKeys, tzData, uppercaseLinks, }: {
|
|
9
|
-
getInternalSlots(dtf: DateTimeFormat): IntlDateTimeFormatInternal;
|
|
8
|
+
export declare function InitializeDateTimeFormat(dtf: Intl.DateTimeFormat | DateTimeFormat, locales: string | string[] | undefined, opts: Intl.DateTimeFormatOptions | undefined, { getInternalSlots, availableLocales, localeData, getDefaultLocale, getDefaultTimeZone, relevantExtensionKeys, tzData, uppercaseLinks, }: {
|
|
9
|
+
getInternalSlots(dtf: DateTimeFormat | Intl.DateTimeFormat): IntlDateTimeFormatInternal;
|
|
10
10
|
availableLocales: Set<string>;
|
|
11
11
|
getDefaultLocale(): string;
|
|
12
12
|
getDefaultTimeZone(): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InitializeDateTimeFormat.d.ts","sourceRoot":"","sources":["InitializeDateTimeFormat.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,0BAA0B,EAC1B,gCAAgC,EAOhC,cAAc,IAAI,cAAc,EACjC,MAAM,4BAA4B,CAAA;AAkDnC;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,cAAc,
|
|
1
|
+
{"version":3,"file":"InitializeDateTimeFormat.d.ts","sourceRoot":"","sources":["InitializeDateTimeFormat.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,0BAA0B,EAC1B,gCAAgC,EAOhC,cAAc,IAAI,cAAc,EACjC,MAAM,4BAA4B,CAAA;AAkDnC;;;;;GAKG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,IAAI,CAAC,cAAc,GAAG,cAAc,EACzC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG,SAAS,EACtC,IAAI,EAAE,IAAI,CAAC,qBAAqB,GAAG,SAAS,EAC5C,EACE,gBAAgB,EAChB,gBAAgB,EAChB,UAAU,EACV,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,MAAM,EACN,cAAc,GACf,EAAE;IACD,gBAAgB,CACd,GAAG,EAAE,cAAc,GAAG,IAAI,CAAC,cAAc,GACxC,0BAA0B,CAAA;IAC7B,gBAAgB,EAAE,GAAG,CAAC,MAAM,CAAC,CAAA;IAC7B,gBAAgB,IAAI,MAAM,CAAA;IAC1B,kBAAkB,IAAI,MAAM,CAAA;IAC5B,qBAAqB,EAAE,MAAM,EAAE,CAAA;IAC/B,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,gCAAgC,GAAG,SAAS,CAAC,CAAA;IACxE,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC/B,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CACvC,GACA,IAAI,CAAC,cAAc,CA2PrB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IntlDateTimeFormatPart } from '@formatjs/ecma402-abstract';
|
|
1
|
+
import { DateTimeFormat, IntlDateTimeFormatPart } from '@formatjs/ecma402-abstract';
|
|
2
2
|
import { ToLocalTimeImplDetails } from './ToLocalTime';
|
|
3
3
|
import { FormatDateTimePatternImplDetails } from './FormatDateTimePattern';
|
|
4
4
|
/**
|
|
@@ -6,5 +6,5 @@ import { FormatDateTimePatternImplDetails } from './FormatDateTimePattern';
|
|
|
6
6
|
* @param dtf
|
|
7
7
|
* @param x
|
|
8
8
|
*/
|
|
9
|
-
export declare function PartitionDateTimePattern(dtf: Intl.DateTimeFormat, x: number, implDetails: ToLocalTimeImplDetails & FormatDateTimePatternImplDetails): IntlDateTimeFormatPart[];
|
|
9
|
+
export declare function PartitionDateTimePattern(dtf: Intl.DateTimeFormat | DateTimeFormat, x: number, implDetails: ToLocalTimeImplDetails & FormatDateTimePatternImplDetails): IntlDateTimeFormatPart[];
|
|
10
10
|
//# sourceMappingURL=PartitionDateTimePattern.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PartitionDateTimePattern.d.ts","sourceRoot":"","sources":["PartitionDateTimePattern.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,sBAAsB,EAIvB,MAAM,4BAA4B,CAAA;AACnC,OAAO,EAAC,sBAAsB,EAAC,MAAM,eAAe,CAAA;AACpD,OAAO,EAEL,gCAAgC,EACjC,MAAM,yBAAyB,CAAA;AAEhC;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,IAAI,CAAC,cAAc,
|
|
1
|
+
{"version":3,"file":"PartitionDateTimePattern.d.ts","sourceRoot":"","sources":["PartitionDateTimePattern.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,sBAAsB,EAIvB,MAAM,4BAA4B,CAAA;AACnC,OAAO,EAAC,sBAAsB,EAAC,MAAM,eAAe,CAAA;AACpD,OAAO,EAEL,gCAAgC,EACjC,MAAM,yBAAyB,CAAA;AAEhC;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,IAAI,CAAC,cAAc,GAAG,cAAc,EACzC,CAAC,EAAE,MAAM,EACT,WAAW,EAAE,sBAAsB,GAAG,gCAAgC,GACrE,sBAAsB,EAAE,CAkB1B"}
|