@formatjs/intl-supportedvaluesof 2.4.0 → 3.0.0
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/index.d.ts +1 -15
- package/index.js +18 -37
- package/index.js.map +1 -1
- package/package.json +1 -1
- package/polyfill-force.js +17 -35
- package/polyfill-force.js.map +1 -1
- package/polyfill.iife.js +20 -41
- package/polyfill.js +19 -39
- package/polyfill.js.map +1 -1
- package/should-polyfill.d.ts +0 -2
- package/should-polyfill.js +1 -2
package/index.d.ts
CHANGED
|
@@ -1,27 +1,14 @@
|
|
|
1
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/calendars.d.ts
|
|
2
1
|
declare const calendars: readonly ["buddhist", "chinese", "coptic", "dangi", "ethioaa", "ethiopic", "gregory", "hebrew", "indian", "islamic", "islamic-civil", "islamic-rgsa", "islamic-tbla", "islamic-umalqura", "islamicc", "iso8601", "japanese", "persian", "roc"];
|
|
3
2
|
type Calendar = typeof calendars[number];
|
|
4
|
-
//#endregion
|
|
5
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/collations.d.ts
|
|
6
3
|
declare const collations: readonly ["big5han", "compat", "dict", "direct", "ducet", "emoji", "eor", "gb2312", "phonebk", "phonetic", "pinyin", "reformed", "search", "searchjl", "standard", "stroke", "trad", "unihan", "zhuyin"];
|
|
7
4
|
type Collation = typeof collations[number];
|
|
8
|
-
|
|
9
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/currencies.d.ts
|
|
10
|
-
declare const currencies: readonly ["ADP", "AED", "AFA", "AFN", "ALK", "ALL", "AMD", "ANG", "AOA", "AOK", "AON", "AOR", "ARA", "ARL", "ARM", "ARP", "ARS", "ATS", "AUD", "AWG", "AZM", "AZN", "BAD", "BAM", "BAN", "BBD", "BDT", "BEC", "BEF", "BEL", "BGL", "BGM", "BGN", "BGO", "BHD", "BIF", "BMD", "BND", "BOB", "BOL", "BOP", "BOV", "BRB", "BRC", "BRE", "BRL", "BRN", "BRR", "BRZ", "BSD", "BTN", "BUK", "BWP", "BYB", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLE", "CLF", "CLP", "CNH", "CNX", "CNY", "COP", "COU", "CRC", "CSD", "CSK", "CUC", "CUP", "CVE", "CYP", "CZK", "DDM", "DEM", "DJF", "DKK", "DOP", "DZD", "ECS", "ECV", "EEK", "EGP", "ERN", "ESA", "ESB", "ESP", "ETB", "EUR", "FIM", "FJD", "FKP", "FRF", "GBP", "GEK", "GEL", "GHC", "GHS", "GIP", "GMD", "GNF", "GNS", "GQE", "GRD", "GTQ", "GWE", "GWP", "GYD", "HKD", "HNL", "HRD", "HRK", "HTG", "HUF", "IDR", "IEP", "ILP", "ILR", "ILS", "INR", "IQD", "IRR", "ISJ", "ISK", "ITL", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRH", "KRO", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LTT", "LUC", "LUF", "LUL", "LVL", "LVR", "LYD", "MAD", "MAF", "MCF", "MDC", "MDL", "MGA", "MGF", "MKD", "MKN", "MLF", "MMK", "MNT", "MOP", "MRO", "MRU", "MTL", "MTP", "MUR", "MVP", "MVR", "MWK", "MXN", "MXP", "MXV", "MYR", "MZE", "MZM", "MZN", "NAD", "NGN", "NIC", "NIO", "NLG", "NOK", "NPR", "NZD", "OMR", "PAB", "PEI", "PEN", "PES", "PGK", "PHP", "PKR", "PLN", "PLZ", "PTE", "PYG", "QAR", "RHD", "ROL", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDD", "SDG", "SDP", "SEK", "SGD", "SHP", "SIT", "SKK", "SLE", "SLL", "SOS", "SRD", "SRG", "SSP", "STD", "STN", "SUR", "SVC", "SYP", "SZL", "THB", "TJR", "TJS", "TMM", "TMT", "TND", "TOP", "TPE", "TRL", "TRY", "TTD", "TWD", "TZS", "UAH", "UAK", "UGS", "UGX", "USD", "USN", "USS", "UYI", "UYP", "UYU", "UYW", "UZS", "VEB", "VED", "VEF", "VES", "VND", "VNN", "VUV", "WST", "XAF", "XAG", "XAU", "XBA", "XBB", "XBC", "XBD", "XCD", "XCG", "XDR", "XEU", "XFO", "XFU", "XOF", "XPD", "XPF", "XPT", "XRE", "XSU", "XTS", "XUA", "XXX", "YDD", "YER", "YUD", "YUM", "YUN", "YUR", "ZAL", "ZAR", "ZMK", "ZMW", "ZRN", "ZRZ", "ZWD", "ZWG", "ZWL", "ZWR"];
|
|
5
|
+
declare const currencies: readonly ["ADP", "AED", "AFA", "AFN", "ALK", "ALL", "AMD", "ANG", "AOA", "AOK", "AON", "AOR", "ARA", "ARL", "ARM", "ARP", "ARS", "ATS", "AUD", "AWG", "AZM", "AZN", "BAD", "BAM", "BAN", "BBD", "BDT", "BEC", "BEF", "BEL", "BGL", "BGM", "BGN", "BGO", "BHD", "BIF", "BMD", "BND", "BOB", "BOL", "BOP", "BOV", "BRB", "BRC", "BRE", "BRL", "BRN", "BRR", "BRZ", "BSD", "BTN", "BUK", "BWP", "BYB", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLE", "CLF", "CLP", "CNH", "CNY", "COP", "COU", "CRC", "CSD", "CSK", "CUC", "CUP", "CVE", "CYP", "CZK", "DDM", "DEM", "DJF", "DKK", "DOP", "DZD", "ECS", "ECV", "EEK", "EGP", "ERN", "ESA", "ESB", "ESP", "ETB", "EUR", "FIM", "FJD", "FKP", "FRF", "GBP", "GEK", "GEL", "GHC", "GHS", "GIP", "GMD", "GNF", "GNS", "GQE", "GRD", "GTQ", "GWE", "GWP", "GYD", "HKD", "HNL", "HRD", "HRK", "HTG", "HUF", "IDR", "IEP", "ILP", "ILR", "ILS", "INR", "IQD", "IRR", "ISJ", "ISK", "ITL", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRH", "KRO", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LTT", "LUC", "LUF", "LUL", "LVL", "LVR", "LYD", "MAD", "MAF", "MCF", "MDC", "MDL", "MGA", "MGF", "MKD", "MKN", "MLF", "MMK", "MNT", "MOP", "MRO", "MRU", "MTL", "MTP", "MUR", "MVP", "MVR", "MWK", "MXN", "MXP", "MXV", "MYR", "MZE", "MZM", "MZN", "NAD", "NGN", "NIC", "NIO", "NLG", "NOK", "NPR", "NZD", "OMR", "PAB", "PEI", "PEN", "PES", "PGK", "PHP", "PKR", "PLN", "PLZ", "PTE", "PYG", "QAR", "RHD", "ROL", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDD", "SDG", "SDP", "SEK", "SGD", "SHP", "SIT", "SKK", "SLE", "SLL", "SOS", "SRD", "SRG", "SSP", "STD", "STN", "SUR", "SVC", "SYP", "SZL", "THB", "TJR", "TJS", "TMM", "TMT", "TND", "TOP", "TPE", "TRL", "TRY", "TTD", "TWD", "TZS", "UAH", "UAK", "UGS", "UGX", "USD", "USN", "USS", "UYI", "UYP", "UYU", "UYW", "UZS", "VEB", "VED", "VEF", "VES", "VND", "VNN", "VUV", "WST", "XAF", "XAG", "XAU", "XBA", "XBB", "XBC", "XBD", "XCD", "XCG", "XDR", "XEU", "XFO", "XFU", "XOF", "XPD", "XPF", "XPT", "XRE", "XSU", "XTS", "XUA", "XXX", "YDD", "YER", "YUD", "YUM", "YUN", "YUR", "ZAL", "ZAR", "ZMK", "ZMW", "ZRN", "ZRZ", "ZWD", "ZWG", "ZWL", "ZWR"];
|
|
11
6
|
type Currency = typeof currencies[number];
|
|
12
|
-
//#endregion
|
|
13
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/timezones.d.ts
|
|
14
7
|
declare const timezones: readonly ["Africa/Abidjan", "Africa/Accra", "Africa/Addis_Ababa", "Africa/Algiers", "Africa/Asmara", "Africa/Bamako", "Africa/Bangui", "Africa/Banjul", "Africa/Bissau", "Africa/Blantyre", "Africa/Brazzaville", "Africa/Bujumbura", "Africa/Cairo", "Africa/Casablanca", "Africa/Ceuta", "Africa/Conakry", "Africa/Dakar", "Africa/Dar_es_Salaam", "Africa/Djibouti", "Africa/Douala", "Africa/El_Aaiun", "Africa/Freetown", "Africa/Gaborone", "Africa/Harare", "Africa/Johannesburg", "Africa/Juba", "Africa/Kampala", "Africa/Khartoum", "Africa/Kigali", "Africa/Kinshasa", "Africa/Lagos", "Africa/Libreville", "Africa/Lome", "Africa/Luanda", "Africa/Lubumbashi", "Africa/Lusaka", "Africa/Malabo", "Africa/Maputo", "Africa/Maseru", "Africa/Mbabane", "Africa/Mogadishu", "Africa/Monrovia", "Africa/Nairobi", "Africa/Ndjamena", "Africa/Niamey", "Africa/Nouakchott", "Africa/Ouagadougou", "Africa/Porto-Novo", "Africa/Sao_Tome", "Africa/Tripoli", "Africa/Tunis", "Africa/Windhoek", "America/Adak", "America/Anchorage", "America/Anguilla", "America/Antigua", "America/Araguaina", "America/Argentina/Buenos_Aires", "America/Argentina/Catamarca", "America/Argentina/Cordoba", "America/Argentina/Jujuy", "America/Argentina/La_Rioja", "America/Argentina/Mendoza", "America/Argentina/Rio_Gallegos", "America/Argentina/Salta", "America/Argentina/San_Juan", "America/Argentina/San_Luis", "America/Argentina/Tucuman", "America/Argentina/Ushuaia", "America/Aruba", "America/Asuncion", "America/Atikokan", "America/Bahia", "America/Bahia_Banderas", "America/Barbados", "America/Belem", "America/Belize", "America/Blanc-Sablon", "America/Boa_Vista", "America/Bogota", "America/Boise", "America/Cambridge_Bay", "America/Campo_Grande", "America/Cancun", "America/Caracas", "America/Cayenne", "America/Cayman", "America/Chicago", "America/Chihuahua", "America/Ciudad_Juarez", "America/Costa_Rica", "America/Coyhaique", "America/Creston", "America/Cuiaba", "America/Curacao", "America/Danmarkshavn", "America/Dawson", "America/Dawson_Creek", "America/Denver", "America/Detroit", "America/Dominica", "America/Edmonton", "America/Eirunepe", "America/El_Salvador", "America/Fort_Nelson", "America/Fortaleza", "America/Glace_Bay", "America/Goose_Bay", "America/Grand_Turk", "America/Grenada", "America/Guadeloupe", "America/Guatemala", "America/Guayaquil", "America/Guyana", "America/Halifax", "America/Havana", "America/Hermosillo", "America/Indiana/Indianapolis", "America/Indiana/Knox", "America/Indiana/Marengo", "America/Indiana/Petersburg", "America/Indiana/Tell_City", "America/Indiana/Vevay", "America/Indiana/Vincennes", "America/Indiana/Winamac", "America/Inuvik", "America/Iqaluit", "America/Jamaica", "America/Juneau", "America/Kentucky/Louisville", "America/Kentucky/Monticello", "America/Kralendijk", "America/La_Paz", "America/Lima", "America/Los_Angeles", "America/Lower_Princes", "America/Maceio", "America/Managua", "America/Manaus", "America/Marigot", "America/Martinique", "America/Matamoros", "America/Mazatlan", "America/Menominee", "America/Merida", "America/Metlakatla", "America/Mexico_City", "America/Miquelon", "America/Moncton", "America/Monterrey", "America/Montevideo", "America/Montserrat", "America/Nassau", "America/New_York", "America/Nipigon", "America/Nome", "America/Noronha", "America/North_Dakota/Beulah", "America/North_Dakota/Center", "America/North_Dakota/New_Salem", "America/Nuuk", "America/Ojinaga", "America/Panama", "America/Pangnirtung", "America/Paramaribo", "America/Phoenix", "America/Port-au-Prince", "America/Port_of_Spain", "America/Porto_Velho", "America/Puerto_Rico", "America/Punta_Arenas", "America/Rainy_River", "America/Rankin_Inlet", "America/Recife", "America/Regina", "America/Resolute", "America/Rio_Branco", "America/Santarem", "America/Santiago", "America/Santo_Domingo", "America/Sao_Paulo", "America/Scoresbysund", "America/Sitka", "America/St_Barthelemy", "America/St_Johns", "America/St_Kitts", "America/St_Lucia", "America/St_Thomas", "America/St_Vincent", "America/Swift_Current", "America/Tegucigalpa", "America/Thule", "America/Thunder_Bay", "America/Tijuana", "America/Toronto", "America/Tortola", "America/Vancouver", "America/Whitehorse", "America/Winnipeg", "America/Yakutat", "America/Yellowknife", "Antarctica/Casey", "Antarctica/Davis", "Antarctica/DumontDUrville", "Antarctica/Macquarie", "Antarctica/Mawson", "Antarctica/McMurdo", "Antarctica/Palmer", "Antarctica/Rothera", "Antarctica/Syowa", "Antarctica/Troll", "Antarctica/Vostok", "Arctic/Longyearbyen", "Asia/Aden", "Asia/Almaty", "Asia/Amman", "Asia/Anadyr", "Asia/Aqtau", "Asia/Aqtobe", "Asia/Ashgabat", "Asia/Atyrau", "Asia/Baghdad", "Asia/Bahrain", "Asia/Baku", "Asia/Bangkok", "Asia/Barnaul", "Asia/Beirut", "Asia/Bishkek", "Asia/Brunei", "Asia/Chita", "Asia/Choibalsan", "Asia/Colombo", "Asia/Damascus", "Asia/Dhaka", "Asia/Dili", "Asia/Dubai", "Asia/Dushanbe", "Asia/Famagusta", "Asia/Gaza", "Asia/Hebron", "Asia/Ho_Chi_Minh", "Asia/Hong_Kong", "Asia/Hovd", "Asia/Irkutsk", "Asia/Jakarta", "Asia/Jayapura", "Asia/Jerusalem", "Asia/Kabul", "Asia/Kamchatka", "Asia/Karachi", "Asia/Kathmandu", "Asia/Khandyga", "Asia/Kolkata", "Asia/Krasnoyarsk", "Asia/Kuala_Lumpur", "Asia/Kuching", "Asia/Kuwait", "Asia/Macau", "Asia/Magadan", "Asia/Makassar", "Asia/Manila", "Asia/Muscat", "Asia/Nicosia", "Asia/Novokuznetsk", "Asia/Novosibirsk", "Asia/Omsk", "Asia/Oral", "Asia/Phnom_Penh", "Asia/Pontianak", "Asia/Pyongyang", "Asia/Qatar", "Asia/Qostanay", "Asia/Qyzylorda", "Asia/Riyadh", "Asia/Sakhalin", "Asia/Samarkand", "Asia/Seoul", "Asia/Shanghai", "Asia/Singapore", "Asia/Srednekolymsk", "Asia/Taipei", "Asia/Tashkent", "Asia/Tbilisi", "Asia/Tehran", "Asia/Thimphu", "Asia/Tokyo", "Asia/Tomsk", "Asia/Ulaanbaatar", "Asia/Urumqi", "Asia/Ust-Nera", "Asia/Vientiane", "Asia/Vladivostok", "Asia/Yakutsk", "Asia/Yangon", "Asia/Yekaterinburg", "Asia/Yerevan", "Atlantic/Azores", "Atlantic/Bermuda", "Atlantic/Canary", "Atlantic/Cape_Verde", "Atlantic/Faroe", "Atlantic/Madeira", "Atlantic/Reykjavik", "Atlantic/South_Georgia", "Atlantic/St_Helena", "Atlantic/Stanley", "Australia/Adelaide", "Australia/Brisbane", "Australia/Broken_Hill", "Australia/Currie", "Australia/Darwin", "Australia/Eucla", "Australia/Hobart", "Australia/Lindeman", "Australia/Lord_Howe", "Australia/Melbourne", "Australia/Perth", "Australia/Sydney", "CST6CDT", "EST5EDT", "Etc/GMT+1", "Etc/GMT+10", "Etc/GMT+11", "Etc/GMT+12", "Etc/GMT+2", "Etc/GMT+3", "Etc/GMT+4", "Etc/GMT+5", "Etc/GMT+6", "Etc/GMT+7", "Etc/GMT+8", "Etc/GMT+9", "Etc/GMT-1", "Etc/GMT-10", "Etc/GMT-11", "Etc/GMT-12", "Etc/GMT-13", "Etc/GMT-14", "Etc/GMT-2", "Etc/GMT-3", "Etc/GMT-4", "Etc/GMT-5", "Etc/GMT-6", "Etc/GMT-7", "Etc/GMT-8", "Etc/GMT-9", "Europe/Amsterdam", "Europe/Andorra", "Europe/Astrakhan", "Europe/Athens", "Europe/Belgrade", "Europe/Berlin", "Europe/Bratislava", "Europe/Brussels", "Europe/Bucharest", "Europe/Budapest", "Europe/Busingen", "Europe/Chisinau", "Europe/Copenhagen", "Europe/Dublin", "Europe/Gibraltar", "Europe/Guernsey", "Europe/Helsinki", "Europe/Isle_of_Man", "Europe/Istanbul", "Europe/Jersey", "Europe/Kaliningrad", "Europe/Kirov", "Europe/Kyiv", "Europe/Lisbon", "Europe/Ljubljana", "Europe/London", "Europe/Luxembourg", "Europe/Madrid", "Europe/Malta", "Europe/Mariehamn", "Europe/Minsk", "Europe/Monaco", "Europe/Moscow", "Europe/Oslo", "Europe/Paris", "Europe/Podgorica", "Europe/Prague", "Europe/Riga", "Europe/Rome", "Europe/Samara", "Europe/San_Marino", "Europe/Sarajevo", "Europe/Saratov", "Europe/Simferopol", "Europe/Skopje", "Europe/Sofia", "Europe/Stockholm", "Europe/Tallinn", "Europe/Tirane", "Europe/Ulyanovsk", "Europe/Uzhgorod", "Europe/Vaduz", "Europe/Vatican", "Europe/Vienna", "Europe/Vilnius", "Europe/Volgograd", "Europe/Warsaw", "Europe/Zagreb", "Europe/Zaporozhye", "Europe/Zurich", "Indian/Antananarivo", "Indian/Chagos", "Indian/Christmas", "Indian/Cocos", "Indian/Comoro", "Indian/Kerguelen", "Indian/Mahe", "Indian/Maldives", "Indian/Mauritius", "Indian/Mayotte", "Indian/Reunion", "MST7MDT", "PST8PDT", "Pacific/Apia", "Pacific/Auckland", "Pacific/Bougainville", "Pacific/Chatham", "Pacific/Chuuk", "Pacific/Easter", "Pacific/Efate", "Pacific/Fakaofo", "Pacific/Fiji", "Pacific/Funafuti", "Pacific/Galapagos", "Pacific/Gambier", "Pacific/Guadalcanal", "Pacific/Guam", "Pacific/Honolulu", "Pacific/Kanton", "Pacific/Kiritimati", "Pacific/Kosrae", "Pacific/Kwajalein", "Pacific/Majuro", "Pacific/Marquesas", "Pacific/Midway", "Pacific/Nauru", "Pacific/Niue", "Pacific/Norfolk", "Pacific/Noumea", "Pacific/Pago_Pago", "Pacific/Palau", "Pacific/Pitcairn", "Pacific/Pohnpei", "Pacific/Port_Moresby", "Pacific/Rarotonga", "Pacific/Saipan", "Pacific/Tahiti", "Pacific/Tarawa", "Pacific/Tongatapu", "Pacific/Wake", "Pacific/Wallis", "UTC"];
|
|
15
8
|
type Timezone = typeof timezones[number];
|
|
16
|
-
//#endregion
|
|
17
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/units.d.ts
|
|
18
9
|
declare const units: readonly ["degree", "acre", "hectare", "percent", "bit", "byte", "gigabit", "gigabyte", "kilobit", "kilobyte", "megabit", "megabyte", "petabyte", "terabit", "terabyte", "day", "hour", "microsecond", "millisecond", "minute", "month", "nanosecond", "second", "week", "year", "centimeter", "foot", "inch", "kilometer", "meter", "mile-scandinavian", "mile", "millimeter", "yard", "gram", "kilogram", "ounce", "pound", "stone", "celsius", "fahrenheit", "fluid-ounce", "gallon", "liter", "milliliter"];
|
|
19
10
|
type Unit = typeof units[number];
|
|
20
|
-
//#endregion
|
|
21
|
-
//#region packages/intl-supportedvaluesof/should-polyfill.d.ts
|
|
22
11
|
export declare function shouldPolyfill(): boolean;
|
|
23
|
-
//#endregion
|
|
24
|
-
//#region packages/intl-supportedvaluesof/index.d.ts
|
|
25
12
|
/**
|
|
26
13
|
* ECMA-402 Spec: Intl.supportedValuesOf
|
|
27
14
|
* ECMA-402 §8.3.2 Intl.supportedValuesOf, step 1.
|
|
@@ -59,6 +46,5 @@ export type SupportedValuesOf = "calendar" | "collation" | "currency" | "numberi
|
|
|
59
46
|
* @returns A sorted array of unique string values
|
|
60
47
|
*/
|
|
61
48
|
export declare const supportedValuesOf: (key: SupportedValuesOf) => string[];
|
|
62
|
-
//#endregion
|
|
63
49
|
export type { Calendar, Collation, Currency, Timezone, Unit };
|
|
64
50
|
//# sourceMappingURL=index.d.ts.map
|
package/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { memoize, strategies } from "@formatjs/fast-memoize";
|
|
2
|
-
|
|
2
|
+
// packages/ecma262-abstract/ToString.js
|
|
3
3
|
/**
|
|
4
4
|
* https://tc39.es/ecma262/#sec-tostring
|
|
5
5
|
*/
|
|
@@ -7,8 +7,7 @@ function ToString(o) {
|
|
|
7
7
|
if (typeof o === "symbol") throw TypeError("Cannot convert a Symbol value to a string");
|
|
8
8
|
return String(o);
|
|
9
9
|
}
|
|
10
|
-
|
|
11
|
-
//#region packages/intl-supportedvaluesof/memoize.ts
|
|
10
|
+
// packages/intl-supportedvaluesof/memoize.ts
|
|
12
11
|
/**
|
|
13
12
|
* Implementation: Memoized factory for Intl.DateTimeFormat instances
|
|
14
13
|
*
|
|
@@ -18,8 +17,7 @@ function ToString(o) {
|
|
|
18
17
|
* Uses variadic memoization strategy to handle varying numbers of constructor arguments.
|
|
19
18
|
*/
|
|
20
19
|
const createMemoizedDateTimeFormat = memoize((...args) => new Intl.DateTimeFormat(...args), { strategy: strategies.variadic });
|
|
21
|
-
|
|
22
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/calendars.js
|
|
20
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/calendars.js
|
|
23
21
|
const calendars = [
|
|
24
22
|
"buddhist",
|
|
25
23
|
"chinese",
|
|
@@ -41,8 +39,7 @@ const calendars = [
|
|
|
41
39
|
"persian",
|
|
42
40
|
"roc"
|
|
43
41
|
];
|
|
44
|
-
|
|
45
|
-
//#region packages/intl-supportedvaluesof/get-supported-calendars.ts
|
|
42
|
+
// packages/intl-supportedvaluesof/get-supported-calendars.ts
|
|
46
43
|
/**
|
|
47
44
|
* Implementation: Tests if a calendar is supported by attempting to create
|
|
48
45
|
* a DateTimeFormat with that calendar and verifying it was accepted.
|
|
@@ -64,8 +61,7 @@ function isSupportedCalendar(item) {
|
|
|
64
61
|
function getSupportedCalendars() {
|
|
65
62
|
return calendars.filter(isSupportedCalendar).sort();
|
|
66
63
|
}
|
|
67
|
-
|
|
68
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/collations.js
|
|
64
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/collations.js
|
|
69
65
|
const collations = [
|
|
70
66
|
"big5han",
|
|
71
67
|
"compat",
|
|
@@ -87,8 +83,7 @@ const collations = [
|
|
|
87
83
|
"unihan",
|
|
88
84
|
"zhuyin"
|
|
89
85
|
];
|
|
90
|
-
|
|
91
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.collation@0.0.0/node_modules/@formatjs_generated/cldr.collation/locale-data.js
|
|
86
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.collation@0.0.0/node_modules/@formatjs_generated/cldr.collation/locale-data.js
|
|
92
87
|
const collationCandidateLocales = {
|
|
93
88
|
"emoji": [
|
|
94
89
|
"aa",
|
|
@@ -387,8 +382,7 @@ const collationCandidateLocales = {
|
|
|
387
382
|
"stroke": ["zh", "zh-Hant"],
|
|
388
383
|
"zhuyin": ["zh", "zh-Hant"]
|
|
389
384
|
};
|
|
390
|
-
|
|
391
|
-
//#region packages/intl-supportedvaluesof/get-supported-collations.ts
|
|
385
|
+
// packages/intl-supportedvaluesof/get-supported-collations.ts
|
|
392
386
|
function isSupportedCollation(collation) {
|
|
393
387
|
const candidates = collationCandidateLocales[collation] || ["en"];
|
|
394
388
|
for (const locale of candidates) try {
|
|
@@ -399,13 +393,11 @@ function isSupportedCollation(collation) {
|
|
|
399
393
|
function getSupportedCollations() {
|
|
400
394
|
return collations.filter(isSupportedCollation).sort();
|
|
401
395
|
}
|
|
402
|
-
|
|
403
|
-
//#region packages/ecma402-abstract/utils.js
|
|
396
|
+
// packages/ecma402-abstract/utils.js
|
|
404
397
|
const createMemoizedNumberFormat = memoize((...args) => new Intl.NumberFormat(...args), { strategy: strategies.variadic });
|
|
405
398
|
memoize((...args) => new Intl.PluralRules(...args), { strategy: strategies.variadic });
|
|
406
399
|
memoize((...args) => new Intl.ListFormat(...args), { strategy: strategies.variadic });
|
|
407
|
-
|
|
408
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/currencies.js
|
|
400
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/currencies.js
|
|
409
401
|
const currencies = [
|
|
410
402
|
"ADP",
|
|
411
403
|
"AED",
|
|
@@ -473,7 +465,6 @@ const currencies = [
|
|
|
473
465
|
"CLF",
|
|
474
466
|
"CLP",
|
|
475
467
|
"CNH",
|
|
476
|
-
"CNX",
|
|
477
468
|
"CNY",
|
|
478
469
|
"COP",
|
|
479
470
|
"COU",
|
|
@@ -715,8 +706,7 @@ const currencies = [
|
|
|
715
706
|
"ZWL",
|
|
716
707
|
"ZWR"
|
|
717
708
|
];
|
|
718
|
-
|
|
719
|
-
//#region packages/intl-supportedvaluesof/get-supported-currencies.ts
|
|
709
|
+
// packages/intl-supportedvaluesof/get-supported-currencies.ts
|
|
720
710
|
/**
|
|
721
711
|
* Implementation: Tests if a currency is supported by attempting to create
|
|
722
712
|
* a NumberFormat with that currency and verifying it was accepted.
|
|
@@ -755,8 +745,7 @@ function getSupportedCurrencies() {
|
|
|
755
745
|
}
|
|
756
746
|
return supportedCurrencies.sort();
|
|
757
747
|
}
|
|
758
|
-
|
|
759
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.number@0.0.0/node_modules/@formatjs_generated/cldr.number/numbering-systems.js
|
|
748
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.number@0.0.0/node_modules/@formatjs_generated/cldr.number/numbering-systems.js
|
|
760
749
|
const numberingSystemNames = [
|
|
761
750
|
"adlm",
|
|
762
751
|
"ahom",
|
|
@@ -856,8 +845,7 @@ const numberingSystemNames = [
|
|
|
856
845
|
"wara",
|
|
857
846
|
"wcho"
|
|
858
847
|
];
|
|
859
|
-
|
|
860
|
-
//#region packages/intl-supportedvaluesof/get-supported-numbering-systems.ts
|
|
848
|
+
// packages/intl-supportedvaluesof/get-supported-numbering-systems.ts
|
|
861
849
|
/**
|
|
862
850
|
* Implementation: Tests if a numbering system is supported by attempting to create
|
|
863
851
|
* a NumberFormat with that numbering system and verifying it was accepted.
|
|
@@ -880,8 +868,7 @@ function isSupportedNumberingSystem(system) {
|
|
|
880
868
|
function getSupportedNumberingSystems() {
|
|
881
869
|
return numberingSystemNames.filter(isSupportedNumberingSystem).sort();
|
|
882
870
|
}
|
|
883
|
-
|
|
884
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/timezones.js
|
|
871
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/timezones.js
|
|
885
872
|
const timezones = [
|
|
886
873
|
"Africa/Abidjan",
|
|
887
874
|
"Africa/Accra",
|
|
@@ -1342,8 +1329,7 @@ const timezones = [
|
|
|
1342
1329
|
"Pacific/Wallis",
|
|
1343
1330
|
"UTC"
|
|
1344
1331
|
];
|
|
1345
|
-
|
|
1346
|
-
//#region packages/intl-supportedvaluesof/get-supported-timezones.ts
|
|
1332
|
+
// packages/intl-supportedvaluesof/get-supported-timezones.ts
|
|
1347
1333
|
/**
|
|
1348
1334
|
* Implementation: Tests if a timezone is supported by attempting to create
|
|
1349
1335
|
* a DateTimeFormat with that timezone and verifying it was accepted.
|
|
@@ -1365,8 +1351,7 @@ function isSupportedTimeZone(timeZone) {
|
|
|
1365
1351
|
function getSupportedTimeZones() {
|
|
1366
1352
|
return timezones.filter(isSupportedTimeZone).sort();
|
|
1367
1353
|
}
|
|
1368
|
-
|
|
1369
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/units.js
|
|
1354
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-values@0.0.0/node_modules/@formatjs_generated/cldr.supported-values/units.js
|
|
1370
1355
|
const units = [
|
|
1371
1356
|
"degree",
|
|
1372
1357
|
"acre",
|
|
@@ -1414,8 +1399,7 @@ const units = [
|
|
|
1414
1399
|
"liter",
|
|
1415
1400
|
"milliliter"
|
|
1416
1401
|
];
|
|
1417
|
-
|
|
1418
|
-
//#region packages/intl-supportedvaluesof/get-supported-units.ts
|
|
1402
|
+
// packages/intl-supportedvaluesof/get-supported-units.ts
|
|
1419
1403
|
/**
|
|
1420
1404
|
* Implementation: Tests if a unit is supported by attempting to create
|
|
1421
1405
|
* a NumberFormat with that unit and verifying it was accepted.
|
|
@@ -1440,13 +1424,11 @@ function isSupportedUnit(unit) {
|
|
|
1440
1424
|
function getSupportedUnits() {
|
|
1441
1425
|
return units.filter(isSupportedUnit).sort();
|
|
1442
1426
|
}
|
|
1443
|
-
|
|
1444
|
-
//#region packages/intl-supportedvaluesof/should-polyfill.ts
|
|
1427
|
+
// packages/intl-supportedvaluesof/should-polyfill.ts
|
|
1445
1428
|
function shouldPolyfill() {
|
|
1446
1429
|
return typeof Intl === "undefined" || !("supportedValuesOf" in Intl);
|
|
1447
1430
|
}
|
|
1448
|
-
|
|
1449
|
-
//#region packages/intl-supportedvaluesof/index.ts
|
|
1431
|
+
// packages/intl-supportedvaluesof/index.ts
|
|
1450
1432
|
/**
|
|
1451
1433
|
* ECMA-402 Spec: Intl.supportedValuesOf(key)
|
|
1452
1434
|
* ECMA-402 §8.3.2 Intl.supportedValuesOf, step 1.
|
|
@@ -1475,7 +1457,6 @@ const supportedValuesOf = { supportedValuesOf(key) {
|
|
|
1475
1457
|
default: throw RangeError("Invalid key: " + key);
|
|
1476
1458
|
}
|
|
1477
1459
|
} }.supportedValuesOf;
|
|
1478
|
-
//#endregion
|
|
1479
1460
|
export { shouldPolyfill, supportedValuesOf };
|
|
1480
1461
|
|
|
1481
1462
|
//# sourceMappingURL=index.js.map
|