@formatjs/intl-pluralrules 6.4.0 → 7.0.1
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 +0 -8
- package/index.js +50 -157
- package/index.js.map +1 -1
- package/locale-data/af.js +24 -2
- package/locale-data/bg.js +32 -2
- package/locale-data/es.js +6 -2
- package/locale-data/fr.js +2 -2
- package/locale-data/gl.js +24 -2
- package/locale-data/tg.d.ts +1 -0
- package/locale-data/tg.js +35 -0
- package/locale-data/vi.js +10 -4
- package/package.json +3 -3
- package/polyfill-force.js +50 -157
- package/polyfill-force.js.map +1 -1
- package/polyfill.iife.js +113 -190
- package/polyfill.js +54 -163
- package/polyfill.js.map +1 -1
- package/should-polyfill.d.ts +0 -2
- package/should-polyfill.js +3 -4
- package/should-polyfill.js.map +1 -1
package/polyfill.iife.js
CHANGED
|
@@ -1,64 +1,44 @@
|
|
|
1
|
-
|
|
1
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-locales@0.0.0/node_modules/@formatjs_generated/cldr.supported-locales/default-content.js
|
|
2
2
|
const defaultContent = {
|
|
3
|
-
"
|
|
4
|
-
"ab": ["ab-GE"],
|
|
3
|
+
"ady": ["ady-RU"],
|
|
5
4
|
"af": ["af-ZA"],
|
|
6
5
|
"agq": ["agq-CM"],
|
|
7
6
|
"ak": ["ak-GH"],
|
|
8
7
|
"am": ["am-ET"],
|
|
9
|
-
"an": ["an-ES"],
|
|
10
|
-
"ann": ["ann-NG"],
|
|
11
|
-
"apc": ["apc-SY"],
|
|
12
8
|
"ar": ["ar-001"],
|
|
13
|
-
"arn": ["arn-CL"],
|
|
14
9
|
"as": ["as-IN"],
|
|
15
10
|
"asa": ["asa-TZ"],
|
|
16
11
|
"ast": ["ast-ES"],
|
|
17
|
-
"az-Arab": ["az-Arab-IR"],
|
|
18
12
|
"az-Cyrl": ["az-Cyrl-AZ"],
|
|
19
13
|
"az-Latn": ["az-Latn-AZ"],
|
|
20
14
|
"ba": ["ba-RU"],
|
|
21
|
-
"bal-Arab": ["bal-Arab-PK"],
|
|
22
15
|
"bal-Latn": ["bal-Latn-PK"],
|
|
23
16
|
"bas": ["bas-CM"],
|
|
24
17
|
"be": ["be-BY"],
|
|
25
18
|
"bem": ["bem-ZM"],
|
|
26
|
-
"bew": ["bew-ID"],
|
|
27
19
|
"bez": ["bez-TZ"],
|
|
28
20
|
"bg": ["bg-BG"],
|
|
29
21
|
"bgc": ["bgc-IN"],
|
|
30
|
-
"bgn": ["bgn-PK"],
|
|
31
22
|
"bho": ["bho-IN"],
|
|
32
23
|
"blo": ["blo-BJ"],
|
|
33
|
-
"blt": ["blt-VN"],
|
|
34
24
|
"bm": ["bm-ML"],
|
|
35
|
-
"bm-Nkoo": ["bm-Nkoo-ML"],
|
|
36
25
|
"bn": ["bn-BD"],
|
|
37
26
|
"bo": ["bo-CN"],
|
|
38
|
-
"bqi": ["bqi-IR"],
|
|
39
27
|
"br": ["br-FR"],
|
|
40
28
|
"brx": ["brx-IN"],
|
|
41
29
|
"bs-Cyrl": ["bs-Cyrl-BA"],
|
|
42
30
|
"bs-Latn": ["bs-Latn-BA"],
|
|
43
|
-
"bss": ["bss-CM"],
|
|
44
31
|
"bua": ["bua-RU"],
|
|
45
|
-
"byn": ["byn-ER"],
|
|
46
32
|
"ca": ["ca-ES"],
|
|
47
|
-
"cad": ["cad-US"],
|
|
48
|
-
"cch": ["cch-NG"],
|
|
49
33
|
"ccp": ["ccp-BD"],
|
|
50
34
|
"ce": ["ce-RU"],
|
|
51
35
|
"ceb": ["ceb-PH"],
|
|
52
36
|
"cgg": ["cgg-UG"],
|
|
53
|
-
"cho": ["cho-US"],
|
|
54
37
|
"chr": ["chr-US"],
|
|
55
|
-
"cic": ["cic-US"],
|
|
56
38
|
"ckb": ["ckb-IQ"],
|
|
57
|
-
"co": ["co-FR"],
|
|
58
39
|
"cop": ["cop-EG"],
|
|
59
40
|
"cs": ["cs-CZ"],
|
|
60
41
|
"csw": ["csw-CA"],
|
|
61
|
-
"cu": ["cu-RU"],
|
|
62
42
|
"cv": ["cv-RU"],
|
|
63
43
|
"cy": ["cy-GB"],
|
|
64
44
|
"da": ["da-DK"],
|
|
@@ -68,14 +48,11 @@ const defaultContent = {
|
|
|
68
48
|
"doi": ["doi-IN"],
|
|
69
49
|
"dsb": ["dsb-DE"],
|
|
70
50
|
"dua": ["dua-CM"],
|
|
71
|
-
"dv": ["dv-MV"],
|
|
72
51
|
"dyo": ["dyo-SN"],
|
|
73
52
|
"dz": ["dz-BT"],
|
|
74
53
|
"ebu": ["ebu-KE"],
|
|
75
54
|
"ee": ["ee-GH"],
|
|
76
55
|
"el": ["el-GR"],
|
|
77
|
-
"en-Dsrt": ["en-Dsrt-US"],
|
|
78
|
-
"en-Shaw": ["en-Shaw-GB"],
|
|
79
56
|
"en": ["en-US"],
|
|
80
57
|
"eo": ["eo-001"],
|
|
81
58
|
"es": ["es-ES"],
|
|
@@ -89,29 +66,23 @@ const defaultContent = {
|
|
|
89
66
|
"fil": ["fil-PH"],
|
|
90
67
|
"fo": ["fo-FO"],
|
|
91
68
|
"fr": ["fr-FR"],
|
|
92
|
-
"frr": ["frr-DE"],
|
|
93
69
|
"fur": ["fur-IT"],
|
|
94
70
|
"fy": ["fy-NL"],
|
|
95
71
|
"ga": ["ga-IE"],
|
|
96
72
|
"gaa": ["gaa-GH"],
|
|
97
73
|
"gd": ["gd-GB"],
|
|
98
|
-
"gez": ["gez-ET"],
|
|
99
74
|
"gl": ["gl-ES"],
|
|
100
|
-
"gn": ["gn-PY"],
|
|
101
75
|
"gsw": ["gsw-CH"],
|
|
102
76
|
"gu": ["gu-IN"],
|
|
103
77
|
"guz": ["guz-KE"],
|
|
104
78
|
"gv": ["gv-IM"],
|
|
105
|
-
"ha-Arab": ["ha-Arab-NG"],
|
|
106
79
|
"ha": ["ha-NG"],
|
|
107
80
|
"haw": ["haw-US"],
|
|
108
81
|
"he": ["he-IL"],
|
|
109
82
|
"hi": ["hi-IN"],
|
|
110
83
|
"hi-Latn": ["hi-Latn-IN"],
|
|
111
|
-
"hnj-Hmnp": ["hnj-Hmnp-US"],
|
|
112
84
|
"hr": ["hr-HR"],
|
|
113
85
|
"hsb": ["hsb-DE"],
|
|
114
|
-
"ht": ["ht-HT"],
|
|
115
86
|
"hu": ["hu-HU"],
|
|
116
87
|
"hy": ["hy-AM"],
|
|
117
88
|
"ia": ["ia-001"],
|
|
@@ -119,27 +90,19 @@ const defaultContent = {
|
|
|
119
90
|
"ie": ["ie-EE"],
|
|
120
91
|
"ig": ["ig-NG"],
|
|
121
92
|
"ii": ["ii-CN"],
|
|
122
|
-
"io": ["io-001"],
|
|
123
93
|
"is": ["is-IS"],
|
|
124
94
|
"it": ["it-IT"],
|
|
125
|
-
"iu": ["iu-CA"],
|
|
126
|
-
"iu-Latn": ["iu-Latn-CA"],
|
|
127
95
|
"ja": ["ja-JP"],
|
|
128
|
-
"jbo": ["jbo-001"],
|
|
129
96
|
"jgo": ["jgo-CM"],
|
|
130
97
|
"jmc": ["jmc-TZ"],
|
|
131
98
|
"jv": ["jv-ID"],
|
|
132
99
|
"ka": ["ka-GE"],
|
|
133
|
-
"kaa-Cyrl": ["kaa-Cyrl-UZ"],
|
|
134
|
-
"kaa-Latn": ["kaa-Latn-UZ"],
|
|
135
100
|
"kab": ["kab-DZ"],
|
|
136
|
-
"kaj": ["kaj-NG"],
|
|
137
101
|
"kam": ["kam-KE"],
|
|
138
|
-
"
|
|
102
|
+
"kbd": ["kbd-RU"],
|
|
139
103
|
"kde": ["kde-TZ"],
|
|
140
104
|
"kea": ["kea-CV"],
|
|
141
105
|
"kek": ["kek-GT"],
|
|
142
|
-
"ken": ["ken-CM"],
|
|
143
106
|
"kgp": ["kgp-BR"],
|
|
144
107
|
"khq": ["khq-ML"],
|
|
145
108
|
"ki": ["ki-KE"],
|
|
@@ -153,13 +116,11 @@ const defaultContent = {
|
|
|
153
116
|
"ko": ["ko-KR"],
|
|
154
117
|
"kok-Deva": ["kok-Deva-IN"],
|
|
155
118
|
"kok-Latn": ["kok-Latn-IN"],
|
|
156
|
-
"kpe": ["kpe-LR"],
|
|
157
119
|
"ks-Arab": ["ks-Arab-IN"],
|
|
158
120
|
"ks-Deva": ["ks-Deva-IN"],
|
|
159
121
|
"ksb": ["ksb-TZ"],
|
|
160
122
|
"ksf": ["ksf-CM"],
|
|
161
123
|
"ksh": ["ksh-DE"],
|
|
162
|
-
"ku-Arab": ["ku-Arab-IQ"],
|
|
163
124
|
"ku-Latn": ["ku-Latn-TR"],
|
|
164
125
|
"kw": ["kw-GB"],
|
|
165
126
|
"kxv-Deva": ["kxv-Deva-IN"],
|
|
@@ -167,7 +128,6 @@ const defaultContent = {
|
|
|
167
128
|
"kxv-Orya": ["kxv-Orya-IN"],
|
|
168
129
|
"kxv-Telu": ["kxv-Telu-IN"],
|
|
169
130
|
"ky": ["ky-KG"],
|
|
170
|
-
"la": ["la-VA"],
|
|
171
131
|
"lag": ["lag-TZ"],
|
|
172
132
|
"lb": ["lb-LU"],
|
|
173
133
|
"lg": ["lg-UG"],
|
|
@@ -179,39 +139,27 @@ const defaultContent = {
|
|
|
179
139
|
"lo": ["lo-LA"],
|
|
180
140
|
"lrc": ["lrc-IR"],
|
|
181
141
|
"lt": ["lt-LT"],
|
|
182
|
-
"ltg": ["ltg-LV"],
|
|
183
142
|
"lu": ["lu-CD"],
|
|
184
143
|
"luo": ["luo-KE"],
|
|
185
144
|
"luy": ["luy-KE"],
|
|
186
145
|
"lv": ["lv-LV"],
|
|
187
|
-
"lzz": ["lzz-TR"],
|
|
188
146
|
"mai": ["mai-IN"],
|
|
189
147
|
"mas": ["mas-KE"],
|
|
190
|
-
"mdf": ["mdf-RU"],
|
|
191
148
|
"mer": ["mer-KE"],
|
|
192
149
|
"mfe": ["mfe-MU"],
|
|
193
150
|
"mg": ["mg-MG"],
|
|
194
151
|
"mgh": ["mgh-MZ"],
|
|
195
152
|
"mgo": ["mgo-CM"],
|
|
196
|
-
"mhn": ["mhn-IT"],
|
|
197
153
|
"mi": ["mi-NZ"],
|
|
198
|
-
"mic": ["mic-CA"],
|
|
199
154
|
"mk": ["mk-MK"],
|
|
200
155
|
"ml": ["ml-IN"],
|
|
201
156
|
"mn": ["mn-MN"],
|
|
202
|
-
"mn-Mong": ["mn-Mong-CN"],
|
|
203
157
|
"mni-Beng": ["mni-Beng-IN"],
|
|
204
|
-
"mni-Mtei": ["mni-Mtei-IN"],
|
|
205
|
-
"moh": ["moh-CA"],
|
|
206
158
|
"mr": ["mr-IN"],
|
|
207
|
-
"ms-Arab": ["ms-Arab-MY"],
|
|
208
159
|
"ms": ["ms-MY"],
|
|
209
160
|
"mt": ["mt-MT"],
|
|
210
161
|
"mua": ["mua-CM"],
|
|
211
|
-
"mus": ["mus-US"],
|
|
212
|
-
"mww-Hmnp": ["mww-Hmnp-US"],
|
|
213
162
|
"my": ["my-MM"],
|
|
214
|
-
"myv": ["myv-RU"],
|
|
215
163
|
"mzn": ["mzn-IR"],
|
|
216
164
|
"naq": ["naq-NA"],
|
|
217
165
|
"nb": ["nb-NO"],
|
|
@@ -223,24 +171,16 @@ const defaultContent = {
|
|
|
223
171
|
"nn": ["nn-NO"],
|
|
224
172
|
"nnh": ["nnh-CM"],
|
|
225
173
|
"nqo": ["nqo-GN"],
|
|
226
|
-
"nr": ["nr-ZA"],
|
|
227
174
|
"nso": ["nso-ZA"],
|
|
228
175
|
"nus": ["nus-SS"],
|
|
229
|
-
"nv": ["nv-US"],
|
|
230
|
-
"ny": ["ny-MW"],
|
|
231
176
|
"nyn": ["nyn-UG"],
|
|
232
177
|
"oc": ["oc-FR"],
|
|
233
|
-
"oka": ["oka-CA"],
|
|
234
178
|
"om": ["om-ET"],
|
|
235
179
|
"or": ["or-IN"],
|
|
236
180
|
"os": ["os-GE"],
|
|
237
|
-
"osa": ["osa-US"],
|
|
238
181
|
"pa-Arab": ["pa-Arab-PK"],
|
|
239
182
|
"pa-Guru": ["pa-Guru-IN"],
|
|
240
|
-
"pap": ["pap-CW"],
|
|
241
183
|
"pcm": ["pcm-NG"],
|
|
242
|
-
"pi-Latn": ["pi-Latn-GB"],
|
|
243
|
-
"pis": ["pis-SB"],
|
|
244
184
|
"pl": ["pl-PL"],
|
|
245
185
|
"pms": ["pms-IT"],
|
|
246
186
|
"prg": ["prg-PL"],
|
|
@@ -249,8 +189,6 @@ const defaultContent = {
|
|
|
249
189
|
"qu": ["qu-PE"],
|
|
250
190
|
"quc": ["quc-GT"],
|
|
251
191
|
"raj": ["raj-IN"],
|
|
252
|
-
"rhg-Rohg": ["rhg-Rohg-MM"],
|
|
253
|
-
"rif": ["rif-MA"],
|
|
254
192
|
"rm": ["rm-CH"],
|
|
255
193
|
"rn": ["rn-BI"],
|
|
256
194
|
"ro": ["ro-RO"],
|
|
@@ -261,41 +199,30 @@ const defaultContent = {
|
|
|
261
199
|
"sa": ["sa-IN"],
|
|
262
200
|
"sah": ["sah-RU"],
|
|
263
201
|
"saq": ["saq-KE"],
|
|
264
|
-
"sat-Deva": ["sat-Deva-IN"],
|
|
265
202
|
"sat-Olck": ["sat-Olck-IN"],
|
|
266
203
|
"sbp": ["sbp-TZ"],
|
|
267
204
|
"sc": ["sc-IT"],
|
|
268
205
|
"scn": ["scn-IT"],
|
|
269
206
|
"sd-Arab": ["sd-Arab-PK"],
|
|
270
207
|
"sd-Deva": ["sd-Deva-IN"],
|
|
271
|
-
"sdh": ["sdh-IR"],
|
|
272
208
|
"se": ["se-NO"],
|
|
273
209
|
"seh": ["seh-MZ"],
|
|
274
210
|
"ses": ["ses-ML"],
|
|
275
211
|
"sg": ["sg-CF"],
|
|
276
|
-
"sgs": ["sgs-LT"],
|
|
277
212
|
"shi-Latn": ["shi-Latn-MA"],
|
|
278
213
|
"shi-Tfng": ["shi-Tfng-MA"],
|
|
279
214
|
"shn": ["shn-MM"],
|
|
280
215
|
"si": ["si-LK"],
|
|
281
|
-
"sid": ["sid-ET"],
|
|
282
216
|
"sk": ["sk-SK"],
|
|
283
|
-
"skr": ["skr-PK"],
|
|
284
217
|
"sl": ["sl-SI"],
|
|
285
|
-
"sma": ["sma-SE"],
|
|
286
|
-
"smj": ["smj-SE"],
|
|
287
218
|
"smn": ["smn-FI"],
|
|
288
|
-
"sms": ["sms-FI"],
|
|
289
219
|
"sn": ["sn-ZW"],
|
|
290
220
|
"so": ["so-SO"],
|
|
291
221
|
"sq": ["sq-AL"],
|
|
292
222
|
"sr-Cyrl": ["sr-Cyrl-RS"],
|
|
293
223
|
"sr-Latn": ["sr-Latn-RS"],
|
|
294
|
-
"ss": ["ss-ZA"],
|
|
295
|
-
"ssy": ["ssy-ER"],
|
|
296
224
|
"st": ["st-ZA"],
|
|
297
225
|
"su-Latn": ["su-Latn-ID"],
|
|
298
|
-
"suz-Deva": ["suz-Deva-NP"],
|
|
299
226
|
"suz-Sunu": ["suz-Sunu-NP"],
|
|
300
227
|
"sv": ["sv-SE"],
|
|
301
228
|
"sw": ["sw-TZ"],
|
|
@@ -307,16 +234,11 @@ const defaultContent = {
|
|
|
307
234
|
"tg": ["tg-TJ"],
|
|
308
235
|
"th": ["th-TH"],
|
|
309
236
|
"ti": ["ti-ET"],
|
|
310
|
-
"tig": ["tig-ER"],
|
|
311
237
|
"tk": ["tk-TM"],
|
|
312
238
|
"tn": ["tn-ZA"],
|
|
313
239
|
"to": ["to-TO"],
|
|
314
240
|
"tok": ["tok-001"],
|
|
315
|
-
"tpi": ["tpi-PG"],
|
|
316
241
|
"tr": ["tr-TR"],
|
|
317
|
-
"trv": ["trv-TW"],
|
|
318
|
-
"trw": ["trw-PK"],
|
|
319
|
-
"ts": ["ts-ZA"],
|
|
320
242
|
"tt": ["tt-RU"],
|
|
321
243
|
"twq": ["twq-NE"],
|
|
322
244
|
"tyv": ["tyv-RU"],
|
|
@@ -329,16 +251,11 @@ const defaultContent = {
|
|
|
329
251
|
"uz-Latn": ["uz-Latn-UZ"],
|
|
330
252
|
"vai-Latn": ["vai-Latn-LR"],
|
|
331
253
|
"vai-Vaii": ["vai-Vaii-LR"],
|
|
332
|
-
"ve": ["ve-ZA"],
|
|
333
254
|
"vec": ["vec-IT"],
|
|
334
255
|
"vi": ["vi-VN"],
|
|
335
256
|
"vmw": ["vmw-MZ"],
|
|
336
|
-
"vo": ["vo-001"],
|
|
337
257
|
"vun": ["vun-TZ"],
|
|
338
|
-
"wa": ["wa-BE"],
|
|
339
258
|
"wae": ["wae-CH"],
|
|
340
|
-
"wal": ["wal-ET"],
|
|
341
|
-
"wbp": ["wbp-AU"],
|
|
342
259
|
"wo": ["wo-SN"],
|
|
343
260
|
"xh": ["xh-ZA"],
|
|
344
261
|
"xnr": ["xnr-IN"],
|
|
@@ -353,11 +270,9 @@ const defaultContent = {
|
|
|
353
270
|
"zgh": ["zgh-MA"],
|
|
354
271
|
"zh-Hans": ["zh-Hans-CN"],
|
|
355
272
|
"zh-Hant": ["zh-Hant-TW"],
|
|
356
|
-
"zh-Latn": ["zh-Latn-CN"],
|
|
357
273
|
"zu": ["zu-ZA"]
|
|
358
274
|
};
|
|
359
|
-
|
|
360
|
-
//#region packages/ecma402-abstract/registerLocaleData.js
|
|
275
|
+
// packages/ecma402-abstract/registerLocaleData.js
|
|
361
276
|
const explicitLocales = /* @__PURE__ */ new WeakMap();
|
|
362
277
|
function registerLocaleData(locale, data, localeData, availableLocales) {
|
|
363
278
|
let loaded = explicitLocales.get(localeData);
|
|
@@ -385,8 +300,7 @@ function registerLocaleData(locale, data, localeData, availableLocales) {
|
|
|
385
300
|
}
|
|
386
301
|
}
|
|
387
302
|
}
|
|
388
|
-
|
|
389
|
-
//#region packages/ecma402-abstract/CanonicalizeLocaleList.js
|
|
303
|
+
// packages/ecma402-abstract/CanonicalizeLocaleList.js
|
|
390
304
|
/**
|
|
391
305
|
* http://ecma-international.org/ecma-402/7.0/index.html#sec-canonicalizelocalelist
|
|
392
306
|
* @param locales
|
|
@@ -394,8 +308,7 @@ function registerLocaleData(locale, data, localeData, availableLocales) {
|
|
|
394
308
|
function CanonicalizeLocaleList$1(locales) {
|
|
395
309
|
return Intl.getCanonicalLocales(locales);
|
|
396
310
|
}
|
|
397
|
-
|
|
398
|
-
//#region node_modules/.aspect_rules_js/@formatjs+fast-memoize@0.0.0/node_modules/@formatjs/fast-memoize/index.js
|
|
311
|
+
// node_modules/.aspect_rules_js/@formatjs+fast-memoize@0.0.0/node_modules/@formatjs/fast-memoize/index.js
|
|
399
312
|
function memoize(fn, options) {
|
|
400
313
|
const cache = options && options.cache ? options.cache : cacheDefault;
|
|
401
314
|
const serializer = options && options.serializer ? options.serializer : serializerDefault;
|
|
@@ -460,8 +373,7 @@ const strategies = {
|
|
|
460
373
|
variadic: strategyVariadic,
|
|
461
374
|
monadic: strategyMonadic
|
|
462
375
|
};
|
|
463
|
-
|
|
464
|
-
//#region node_modules/.aspect_rules_js/@formatjs+intl-localematcher@0.0.0/node_modules/@formatjs/intl-localematcher/index.js
|
|
376
|
+
// node_modules/.aspect_rules_js/@formatjs+intl-localematcher@0.0.0/node_modules/@formatjs/intl-localematcher/index.js
|
|
465
377
|
/**
|
|
466
378
|
* http://ecma-international.org/ecma-402/7.0/index.html#sec-canonicalizelocalelist
|
|
467
379
|
* @param locales
|
|
@@ -571,8 +483,12 @@ const matchingData = {
|
|
|
571
483
|
"ps|en": 30,
|
|
572
484
|
"qu|es": 30,
|
|
573
485
|
"rm|de": 20,
|
|
574
|
-
"rn|
|
|
575
|
-
"rw|
|
|
486
|
+
"rn|rw": 10,
|
|
487
|
+
"rw|rn": 10,
|
|
488
|
+
"rn|fr": 30,
|
|
489
|
+
"rn|en": 35,
|
|
490
|
+
"rw|en": 30,
|
|
491
|
+
"rw|fr": 35,
|
|
576
492
|
"sa|hi": 30,
|
|
577
493
|
"scn|it": 20,
|
|
578
494
|
"sd|en": 30,
|
|
@@ -1429,7 +1345,7 @@ const matchingData = {
|
|
|
1429
1345
|
"pt-BR",
|
|
1430
1346
|
"pt-PT"
|
|
1431
1347
|
],
|
|
1432
|
-
"cldrVersion": "
|
|
1348
|
+
"cldrVersion": "49",
|
|
1433
1349
|
"macroRegions": ["419"],
|
|
1434
1350
|
"canonicalAliases": {
|
|
1435
1351
|
"language": [
|
|
@@ -1543,7 +1459,6 @@ const matchingData = {
|
|
|
1543
1459
|
"ewe",
|
|
1544
1460
|
"fao",
|
|
1545
1461
|
"fas",
|
|
1546
|
-
"fat",
|
|
1547
1462
|
"fij",
|
|
1548
1463
|
"fin",
|
|
1549
1464
|
"fra",
|
|
@@ -1683,6 +1598,7 @@ const matchingData = {
|
|
|
1683
1598
|
"mof",
|
|
1684
1599
|
"mol",
|
|
1685
1600
|
"mon",
|
|
1601
|
+
"mrd",
|
|
1686
1602
|
"mri",
|
|
1687
1603
|
"msa",
|
|
1688
1604
|
"mst",
|
|
@@ -1764,6 +1680,7 @@ const matchingData = {
|
|
|
1764
1680
|
"sgl",
|
|
1765
1681
|
"sgn",
|
|
1766
1682
|
"sh",
|
|
1683
|
+
"shl",
|
|
1767
1684
|
"sin",
|
|
1768
1685
|
"skk",
|
|
1769
1686
|
"slk",
|
|
@@ -1858,6 +1775,7 @@ const matchingData = {
|
|
|
1858
1775
|
"yiy",
|
|
1859
1776
|
"yma",
|
|
1860
1777
|
"ymt",
|
|
1778
|
+
"yol",
|
|
1861
1779
|
"yor",
|
|
1862
1780
|
"yos",
|
|
1863
1781
|
"yuu",
|
|
@@ -2414,16 +2332,23 @@ function distance(desired, supported) {
|
|
|
2414
2332
|
/** ICU language/script/region distance, including fractional explicit-subtag ties. */
|
|
2415
2333
|
const findMatchingDistance = memoize((desired, supported) => distance(maximal(canonicalize(desired)), maximal(canonicalize(supported))), { serializer: (args) => `${args[0]}|${args[1]}` });
|
|
2416
2334
|
const supportedCache = /* @__PURE__ */ new WeakMap();
|
|
2335
|
+
const immutableLocaleLists = /* @__PURE__ */ new WeakSet();
|
|
2417
2336
|
let paradigms;
|
|
2337
|
+
function createLocaleListSnapshot(locales) {
|
|
2338
|
+
const snapshot = Object.freeze(Array.from(locales));
|
|
2339
|
+
immutableLocaleLists.add(snapshot);
|
|
2340
|
+
return snapshot;
|
|
2341
|
+
}
|
|
2418
2342
|
function equivalentKey(lsr) {
|
|
2419
2343
|
return `${lsr.language}|${lsr.script}|${lsr.region}`;
|
|
2420
2344
|
}
|
|
2421
2345
|
function prepare(locales) {
|
|
2346
|
+
const immutable = immutableLocaleLists.has(locales);
|
|
2422
2347
|
let result = supportedCache.get(locales);
|
|
2423
|
-
if (result && (result.original.length !== locales.length || result.original.some((tag, index) => tag !== locales[index]))) result = void 0;
|
|
2348
|
+
if (result && !immutable && (result.original.length !== locales.length || result.original.some((tag, index) => tag !== locales[index]))) result = void 0;
|
|
2424
2349
|
if (!result) {
|
|
2425
2350
|
result = {
|
|
2426
|
-
original: Array.from(locales),
|
|
2351
|
+
original: immutable ? locales : Array.from(locales),
|
|
2427
2352
|
tags: [],
|
|
2428
2353
|
raw: /* @__PURE__ */ new Map(),
|
|
2429
2354
|
orders: /* @__PURE__ */ new Map(),
|
|
@@ -2780,13 +2705,11 @@ const extensionAlias = {
|
|
|
2780
2705
|
"cnckg": "cnsha",
|
|
2781
2706
|
"cnhrb": "cnsha",
|
|
2782
2707
|
"cnkhg": "cnurc",
|
|
2783
|
-
"cst6cdt": "uschi",
|
|
2784
2708
|
"cuba": "cuhav",
|
|
2785
2709
|
"eet": "grath",
|
|
2786
2710
|
"egypt": "egcai",
|
|
2787
2711
|
"eire": "iedub",
|
|
2788
2712
|
"est": "papty",
|
|
2789
|
-
"est5edt": "usnyc",
|
|
2790
2713
|
"factory": "unk",
|
|
2791
2714
|
"gaza": "gazastrp",
|
|
2792
2715
|
"gmt0": "gmt",
|
|
@@ -2801,13 +2724,11 @@ const extensionAlias = {
|
|
|
2801
2724
|
"met": "bebru",
|
|
2802
2725
|
"mncoq": "mnuln",
|
|
2803
2726
|
"mst": "usphx",
|
|
2804
|
-
"mst7mdt": "usden",
|
|
2805
2727
|
"mxstis": "mxtij",
|
|
2806
2728
|
"navajo": "usden",
|
|
2807
2729
|
"poland": "plwaw",
|
|
2808
2730
|
"portugal": "ptlis",
|
|
2809
2731
|
"prc": "cnsha",
|
|
2810
|
-
"pst8pdt": "uslax",
|
|
2811
2732
|
"roc": "twtpe",
|
|
2812
2733
|
"rok": "krsel",
|
|
2813
2734
|
"turkey": "trist",
|
|
@@ -2933,22 +2854,28 @@ function UnicodeExtensionComponents(extension) {
|
|
|
2933
2854
|
};
|
|
2934
2855
|
}
|
|
2935
2856
|
const availableLocaleArrays = /* @__PURE__ */ new WeakMap();
|
|
2936
|
-
function localeArray(locales) {
|
|
2857
|
+
function localeArray(locales, bestFit) {
|
|
2937
2858
|
if (Array.isArray(locales)) return locales;
|
|
2938
2859
|
const available = locales;
|
|
2939
|
-
|
|
2940
|
-
if (cached?.length
|
|
2860
|
+
let cached = availableLocaleArrays.get(available);
|
|
2861
|
+
if (cached?.original.length !== available.size) cached = void 0;
|
|
2862
|
+
if (cached) {
|
|
2863
|
+
const original = cached.original;
|
|
2941
2864
|
let index = 0;
|
|
2942
|
-
for (const locale of available) if (
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
return result;
|
|
2865
|
+
for (const locale of available) if (original[index++] !== locale) {
|
|
2866
|
+
cached = void 0;
|
|
2867
|
+
break;
|
|
2946
2868
|
}
|
|
2947
|
-
return cached;
|
|
2948
2869
|
}
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2870
|
+
if (!cached) {
|
|
2871
|
+
cached = {
|
|
2872
|
+
original: Array.from(available),
|
|
2873
|
+
snapshot: void 0
|
|
2874
|
+
};
|
|
2875
|
+
availableLocaleArrays.set(available, cached);
|
|
2876
|
+
}
|
|
2877
|
+
if (!bestFit) return cached.original;
|
|
2878
|
+
return cached.snapshot ??= createLocaleListSnapshot(cached.original);
|
|
2952
2879
|
}
|
|
2953
2880
|
/**
|
|
2954
2881
|
* https://tc39.es/ecma402/#sec-resolvelocale
|
|
@@ -2956,8 +2883,8 @@ function localeArray(locales) {
|
|
|
2956
2883
|
function ResolveLocale(availableLocales, requestedLocales, options, relevantExtensionKeys, localeData, getDefaultLocale) {
|
|
2957
2884
|
const matcher = options.localeMatcher;
|
|
2958
2885
|
let r;
|
|
2959
|
-
if (matcher === "lookup") r = LookupMatcher(localeArray(availableLocales), requestedLocales, getDefaultLocale);
|
|
2960
|
-
else r = BestFitMatcher(localeArray(availableLocales), requestedLocales, getDefaultLocale);
|
|
2886
|
+
if (matcher === "lookup") r = LookupMatcher(localeArray(availableLocales, false), requestedLocales, getDefaultLocale);
|
|
2887
|
+
else r = BestFitMatcher(localeArray(availableLocales, true), requestedLocales, getDefaultLocale);
|
|
2961
2888
|
if (r == null) r = {
|
|
2962
2889
|
locale: getDefaultLocale(),
|
|
2963
2890
|
extension: ""
|
|
@@ -3036,8 +2963,7 @@ function LookupSupportedLocales(availableLocales, requestedLocales) {
|
|
|
3036
2963
|
function match(requestedLocales, availableLocales, defaultLocale, opts) {
|
|
3037
2964
|
return ResolveLocale(availableLocales, CanonicalizeLocaleList(requestedLocales), { localeMatcher: opts?.algorithm || "best fit" }, [], {}, () => defaultLocale).locale;
|
|
3038
2965
|
}
|
|
3039
|
-
|
|
3040
|
-
//#region packages/ecma262-abstract/ToObject.js
|
|
2966
|
+
// packages/ecma262-abstract/ToObject.js
|
|
3041
2967
|
/**
|
|
3042
2968
|
* https://tc39.es/ecma262/#sec-toobject
|
|
3043
2969
|
*/
|
|
@@ -3045,8 +2971,7 @@ function ToObject(arg) {
|
|
|
3045
2971
|
if (arg == null) throw new TypeError("undefined/null cannot be converted to object");
|
|
3046
2972
|
return Object(arg);
|
|
3047
2973
|
}
|
|
3048
|
-
|
|
3049
|
-
//#region packages/ecma262-abstract/ToString.js
|
|
2974
|
+
// packages/ecma262-abstract/ToString.js
|
|
3050
2975
|
/**
|
|
3051
2976
|
* https://tc39.es/ecma262/#sec-tostring
|
|
3052
2977
|
*/
|
|
@@ -3054,8 +2979,7 @@ function ToString(o) {
|
|
|
3054
2979
|
if (typeof o === "symbol") throw TypeError("Cannot convert a Symbol value to a string");
|
|
3055
2980
|
return String(o);
|
|
3056
2981
|
}
|
|
3057
|
-
|
|
3058
|
-
//#region packages/ecma402-abstract/GetOption.js
|
|
2982
|
+
// packages/ecma402-abstract/GetOption.js
|
|
3059
2983
|
/**
|
|
3060
2984
|
* https://tc39.es/ecma402/#sec-getoption
|
|
3061
2985
|
* @param opts
|
|
@@ -3076,8 +3000,7 @@ function GetOption(opts, prop, type, values, fallback) {
|
|
|
3076
3000
|
}
|
|
3077
3001
|
return fallback;
|
|
3078
3002
|
}
|
|
3079
|
-
|
|
3080
|
-
//#region packages/ecma402-abstract/SupportedLocales.js
|
|
3003
|
+
// packages/ecma402-abstract/SupportedLocales.js
|
|
3081
3004
|
/**
|
|
3082
3005
|
* https://tc39.es/ecma402/#sec-supportedlocales
|
|
3083
3006
|
* @param availableLocales
|
|
@@ -3093,11 +3016,15 @@ function SupportedLocales(availableLocales, requestedLocales, options) {
|
|
|
3093
3016
|
if (matcher === "best fit") return LookupSupportedLocales(Array.from(availableLocales), requestedLocales);
|
|
3094
3017
|
return LookupSupportedLocales(Array.from(availableLocales), requestedLocales);
|
|
3095
3018
|
}
|
|
3096
|
-
|
|
3097
|
-
//#region node_modules/.aspect_rules_js/@formatjs+bigdecimal@0.0.0/node_modules/@formatjs/bigdecimal/index.js
|
|
3019
|
+
// node_modules/.aspect_rules_js/@formatjs+bigdecimal@0.0.0/node_modules/@formatjs/bigdecimal/index.js
|
|
3098
3020
|
const DIV_PRECISION = 40;
|
|
3099
3021
|
function removeTrailingZeros(mantissa, exponent) {
|
|
3100
3022
|
if (mantissa === 0n) return [0n, 0];
|
|
3023
|
+
if (mantissa % 10n !== 0n) return [mantissa, exponent];
|
|
3024
|
+
while (mantissa % 100000000n === 0n && Number.isSafeInteger(exponent) && Number.isSafeInteger(exponent + 8)) {
|
|
3025
|
+
mantissa /= 100000000n;
|
|
3026
|
+
exponent += 8;
|
|
3027
|
+
}
|
|
3101
3028
|
while (mantissa % 10n === 0n) {
|
|
3102
3029
|
mantissa /= 10n;
|
|
3103
3030
|
exponent++;
|
|
@@ -3124,8 +3051,13 @@ function digitCount(n) {
|
|
|
3124
3051
|
return count;
|
|
3125
3052
|
}
|
|
3126
3053
|
const TEN_BIGINT = 10n;
|
|
3054
|
+
const SMALL_POWERS_OF_TEN = [1n];
|
|
3127
3055
|
function bigintPow10(n) {
|
|
3128
3056
|
if (n <= 0) return 1n;
|
|
3057
|
+
if (n <= 64 && Number.isInteger(n)) {
|
|
3058
|
+
for (let i = SMALL_POWERS_OF_TEN.length; i <= n; i++) SMALL_POWERS_OF_TEN.push(SMALL_POWERS_OF_TEN[i - 1] * TEN_BIGINT);
|
|
3059
|
+
return SMALL_POWERS_OF_TEN[n];
|
|
3060
|
+
}
|
|
3129
3061
|
let result = 1n;
|
|
3130
3062
|
let base = TEN_BIGINT;
|
|
3131
3063
|
let exp = n;
|
|
@@ -3237,6 +3169,14 @@ var BigDecimal = class BigDecimal {
|
|
|
3237
3169
|
this._negativeZero = Object.is(value, -0);
|
|
3238
3170
|
return;
|
|
3239
3171
|
}
|
|
3172
|
+
if (Number.isSafeInteger(value)) {
|
|
3173
|
+
const [m, e] = removeTrailingZeros(BigInt(value), 0);
|
|
3174
|
+
this._mantissa = m;
|
|
3175
|
+
this._exponent = e;
|
|
3176
|
+
this._special = 0;
|
|
3177
|
+
this._negativeZero = false;
|
|
3178
|
+
return;
|
|
3179
|
+
}
|
|
3240
3180
|
value = String(value);
|
|
3241
3181
|
}
|
|
3242
3182
|
const parsed = parseDecimalString(value);
|
|
@@ -3481,6 +3421,7 @@ var BigDecimal = class BigDecimal {
|
|
|
3481
3421
|
if (this._special === 2) return Infinity;
|
|
3482
3422
|
if (this._special === 3) return -Infinity;
|
|
3483
3423
|
if (this._mantissa === 0n) return this._negativeZero ? -0 : 0;
|
|
3424
|
+
if (this._exponent === 0) return Number(this._mantissa);
|
|
3484
3425
|
return Number(this.toString());
|
|
3485
3426
|
}
|
|
3486
3427
|
toString() {
|
|
@@ -3552,8 +3493,7 @@ var BigDecimal = class BigDecimal {
|
|
|
3552
3493
|
return BigDecimal._create(0n, 0, 1, false);
|
|
3553
3494
|
}
|
|
3554
3495
|
};
|
|
3555
|
-
|
|
3556
|
-
//#region packages/ecma262-abstract/ToPrimitive.js
|
|
3496
|
+
// packages/ecma262-abstract/ToPrimitive.js
|
|
3557
3497
|
function invariant$1(condition, message, Err = Error) {
|
|
3558
3498
|
if (!condition) throw new Err(message);
|
|
3559
3499
|
}
|
|
@@ -3596,8 +3536,7 @@ function ToPrimitive(input, preferredType) {
|
|
|
3596
3536
|
}
|
|
3597
3537
|
return input;
|
|
3598
3538
|
}
|
|
3599
|
-
|
|
3600
|
-
//#region packages/ecma402-abstract/ToIntlMathematicalValue.js
|
|
3539
|
+
// packages/ecma402-abstract/ToIntlMathematicalValue.js
|
|
3601
3540
|
/**
|
|
3602
3541
|
* https://tc39.es/ecma402/#sec-tointlmathematicalvalue
|
|
3603
3542
|
* Converts input to a mathematical value, supporting BigInt
|
|
@@ -3623,8 +3562,7 @@ function ToIntlMathematicalValue(input) {
|
|
|
3623
3562
|
return new BigDecimal(NaN);
|
|
3624
3563
|
}
|
|
3625
3564
|
}
|
|
3626
|
-
|
|
3627
|
-
//#region packages/ecma402-abstract/CoerceOptionsToObject.js
|
|
3565
|
+
// packages/ecma402-abstract/CoerceOptionsToObject.js
|
|
3628
3566
|
/**
|
|
3629
3567
|
* https://tc39.es/ecma402/#sec-coerceoptionstoobject
|
|
3630
3568
|
* @param options
|
|
@@ -3634,8 +3572,7 @@ function CoerceOptionsToObject(options) {
|
|
|
3634
3572
|
if (typeof options === "undefined") return Object.create(null);
|
|
3635
3573
|
return ToObject(options);
|
|
3636
3574
|
}
|
|
3637
|
-
|
|
3638
|
-
//#region packages/ecma402-abstract/DefaultNumberOption.js
|
|
3575
|
+
// packages/ecma402-abstract/DefaultNumberOption.js
|
|
3639
3576
|
/**
|
|
3640
3577
|
* ECMA-402 §9.2.13 DefaultNumberOption, step 2.
|
|
3641
3578
|
* https://tc39.es/ecma402/#sec-defaultnumberoption
|
|
@@ -3651,8 +3588,7 @@ function DefaultNumberOption(inputVal, min, max, fallback) {
|
|
|
3651
3588
|
if (isNaN(val) || val < min || val > max) throw new RangeError(`${val} is outside of range [${min}, ${max}]`);
|
|
3652
3589
|
return Math.floor(val);
|
|
3653
3590
|
}
|
|
3654
|
-
|
|
3655
|
-
//#region packages/ecma402-abstract/GetNumberOption.js
|
|
3591
|
+
// packages/ecma402-abstract/GetNumberOption.js
|
|
3656
3592
|
/**
|
|
3657
3593
|
* https://tc39.es/ecma402/#sec-getnumberoption
|
|
3658
3594
|
* @param options
|
|
@@ -3665,8 +3601,7 @@ function GetNumberOption(options, property, minimum, maximum, fallback) {
|
|
|
3665
3601
|
const val = options[property];
|
|
3666
3602
|
return DefaultNumberOption(val, minimum, maximum, fallback);
|
|
3667
3603
|
}
|
|
3668
|
-
|
|
3669
|
-
//#region packages/ecma402-abstract/utils.js
|
|
3604
|
+
// packages/ecma402-abstract/utils.js
|
|
3670
3605
|
function repeat(s, times) {
|
|
3671
3606
|
if (typeof s.repeat === "function") return s.repeat(times);
|
|
3672
3607
|
const arr = Array.from({ length: times });
|
|
@@ -3696,8 +3631,7 @@ function invariant(condition, message, Err = Error) {
|
|
|
3696
3631
|
memoize((...args) => new Intl.NumberFormat(...args), { strategy: strategies.variadic });
|
|
3697
3632
|
memoize((...args) => new Intl.PluralRules(...args), { strategy: strategies.variadic });
|
|
3698
3633
|
memoize((...args) => new Intl.ListFormat(...args), { strategy: strategies.variadic });
|
|
3699
|
-
|
|
3700
|
-
//#region packages/ecma402-abstract/NumberFormat/SetNumberFormatDigitOptions.js
|
|
3634
|
+
// packages/ecma402-abstract/NumberFormat/SetNumberFormatDigitOptions.js
|
|
3701
3635
|
const VALID_ROUNDING_INCREMENTS = /* @__PURE__ */ new Set([
|
|
3702
3636
|
1,
|
|
3703
3637
|
2,
|
|
@@ -3807,8 +3741,7 @@ Valid values are ${Array.from(VALID_ROUNDING_INCREMENTS).join(", ")}.`, RangeErr
|
|
|
3807
3741
|
invariant(internalSlots.maximumFractionDigits === internalSlots.minimumFractionDigits, "With roundingIncrement > 1, maximumFractionDigits and minimumFractionDigits must be equal.", RangeError);
|
|
3808
3742
|
}
|
|
3809
3743
|
}
|
|
3810
|
-
|
|
3811
|
-
//#region packages/ecma402-abstract/PluralRules/InitializePluralRules.js
|
|
3744
|
+
// packages/ecma402-abstract/PluralRules/InitializePluralRules.js
|
|
3812
3745
|
function InitializePluralRules(pl, locales, options, { availableLocales, relevantExtensionKeys, localeData, getDefaultLocale, getInternalSlots }) {
|
|
3813
3746
|
const requestedLocales = CanonicalizeLocaleList$1(locales);
|
|
3814
3747
|
const opt = Object.create(null);
|
|
@@ -3834,8 +3767,7 @@ function InitializePluralRules(pl, locales, options, { availableLocales, relevan
|
|
|
3834
3767
|
SetNumberFormatDigitOptions(internalSlots, opts, 0, 3, notation);
|
|
3835
3768
|
return pl;
|
|
3836
3769
|
}
|
|
3837
|
-
|
|
3838
|
-
//#region packages/ecma262-abstract/Type.js
|
|
3770
|
+
// packages/ecma262-abstract/Type.js
|
|
3839
3771
|
/**
|
|
3840
3772
|
* https://www.ecma-international.org/ecma-262/11.0/index.html#sec-type
|
|
3841
3773
|
*/
|
|
@@ -3849,12 +3781,10 @@ function Type(x) {
|
|
|
3849
3781
|
if (typeof x === "symbol") return "Symbol";
|
|
3850
3782
|
if (typeof x === "bigint") return "BigInt";
|
|
3851
3783
|
}
|
|
3852
|
-
|
|
3853
|
-
//#region packages/ecma402-abstract/constants.js
|
|
3784
|
+
// packages/ecma402-abstract/constants.js
|
|
3854
3785
|
const ZERO = new BigDecimal(0);
|
|
3855
3786
|
const NEGATIVE_ZERO = new BigDecimal(-0);
|
|
3856
|
-
|
|
3857
|
-
//#region packages/ecma402-abstract/NumberFormat/GetUnsignedRoundingMode.js
|
|
3787
|
+
// packages/ecma402-abstract/NumberFormat/GetUnsignedRoundingMode.js
|
|
3858
3788
|
const negativeMapping = {
|
|
3859
3789
|
ceil: "zero",
|
|
3860
3790
|
floor: "infinity",
|
|
@@ -3881,8 +3811,7 @@ function GetUnsignedRoundingMode(roundingMode, isNegative) {
|
|
|
3881
3811
|
if (isNegative) return negativeMapping[roundingMode];
|
|
3882
3812
|
return positiveMapping[roundingMode];
|
|
3883
3813
|
}
|
|
3884
|
-
|
|
3885
|
-
//#region packages/ecma402-abstract/NumberFormat/ApplyUnsignedRoundingMode.js
|
|
3814
|
+
// packages/ecma402-abstract/NumberFormat/ApplyUnsignedRoundingMode.js
|
|
3886
3815
|
function ApplyUnsignedRoundingMode(x, r1, r2, unsignedRoundingMode) {
|
|
3887
3816
|
if (x.eq(r1) || r1.eq(r2)) return r1;
|
|
3888
3817
|
if (x.eq(r2)) return r2;
|
|
@@ -3900,23 +3829,17 @@ function ApplyUnsignedRoundingMode(x, r1, r2, unsignedRoundingMode) {
|
|
|
3900
3829
|
if (r1.div(r2.minus(r1)).mod(2).isZero()) return r1;
|
|
3901
3830
|
return r2;
|
|
3902
3831
|
}
|
|
3903
|
-
|
|
3904
|
-
|
|
3905
|
-
|
|
3906
|
-
|
|
3907
|
-
|
|
3908
|
-
|
|
3909
|
-
|
|
3910
|
-
|
|
3911
|
-
|
|
3912
|
-
|
|
3913
|
-
|
|
3914
|
-
*/
|
|
3915
|
-
const getPowerOf10 = memoize((exponent) => {
|
|
3916
|
-
return BigDecimal.pow(10, exponent);
|
|
3917
|
-
});
|
|
3918
|
-
//#endregion
|
|
3919
|
-
//#region packages/ecma402-abstract/NumberFormat/ToRawFixed.js
|
|
3832
|
+
// packages/ecma402-abstract/NumberFormat/decimal-cache.js
|
|
3833
|
+
const powersOfTen = /* @__PURE__ */ new Map();
|
|
3834
|
+
function getPowerOf10(exponent) {
|
|
3835
|
+
const n = typeof exponent === "number" ? exponent : exponent.toNumber();
|
|
3836
|
+
const cached = powersOfTen.get(n);
|
|
3837
|
+
if (cached !== void 0) return cached;
|
|
3838
|
+
const power = BigDecimal.pow(10, n);
|
|
3839
|
+
if (Number.isInteger(n) && n >= -324 && n <= 324) powersOfTen.set(n, power);
|
|
3840
|
+
return power;
|
|
3841
|
+
}
|
|
3842
|
+
// packages/ecma402-abstract/NumberFormat/ToRawFixed.js
|
|
3920
3843
|
function ToRawFixedFn(n, f) {
|
|
3921
3844
|
return n.times(getPowerOf10(-f));
|
|
3922
3845
|
}
|
|
@@ -3937,10 +3860,19 @@ function findN2R2(x, f, roundingIncrement) {
|
|
|
3937
3860
|
/**
|
|
3938
3861
|
* https://tc39.es/ecma402/#sec-torawfixed
|
|
3939
3862
|
* @param x a finite non-negative Number or BigInt
|
|
3940
|
-
* @param minFraction an integer between 0 and
|
|
3941
|
-
* @param maxFraction an integer between 0 and
|
|
3863
|
+
* @param minFraction an integer between 0 and 100
|
|
3864
|
+
* @param maxFraction an integer between 0 and 100
|
|
3942
3865
|
*/
|
|
3943
3866
|
function ToRawFixed(x, minFraction, maxFraction, roundingIncrement, unsignedRoundingMode) {
|
|
3867
|
+
if (roundingIncrement === 1 && x.isInteger()) {
|
|
3868
|
+
const integer = x.toString();
|
|
3869
|
+
return {
|
|
3870
|
+
formattedString: integer + (minFraction === 0 ? "" : "." + repeat("0", minFraction)),
|
|
3871
|
+
roundedNumber: x,
|
|
3872
|
+
integerDigitsCount: integer.length,
|
|
3873
|
+
roundingMagnitude: -maxFraction
|
|
3874
|
+
};
|
|
3875
|
+
}
|
|
3944
3876
|
const f = maxFraction;
|
|
3945
3877
|
const { n1, r1 } = findN1R1(x, f, roundingIncrement);
|
|
3946
3878
|
const { n2, r2 } = findN2R2(x, f, roundingIncrement);
|
|
@@ -3981,8 +3913,7 @@ function ToRawFixed(x, minFraction, maxFraction, roundingIncrement, unsignedRoun
|
|
|
3981
3913
|
roundingMagnitude: -f
|
|
3982
3914
|
};
|
|
3983
3915
|
}
|
|
3984
|
-
|
|
3985
|
-
//#region packages/ecma402-abstract/NumberFormat/ToRawPrecision.js
|
|
3916
|
+
// packages/ecma402-abstract/NumberFormat/ToRawPrecision.js
|
|
3986
3917
|
function findN1E1R1(x, p) {
|
|
3987
3918
|
const maxN1 = getPowerOf10(p);
|
|
3988
3919
|
const minN1 = getPowerOf10(p - 1);
|
|
@@ -4117,8 +4048,7 @@ function ToRawPrecision(x, minPrecision, maxPrecision, unsignedRoundingMode) {
|
|
|
4117
4048
|
roundingMagnitude: e - p + 1
|
|
4118
4049
|
};
|
|
4119
4050
|
}
|
|
4120
|
-
|
|
4121
|
-
//#region packages/ecma402-abstract/NumberFormat/FormatNumericToString.js
|
|
4051
|
+
// packages/ecma402-abstract/NumberFormat/FormatNumericToString.js
|
|
4122
4052
|
/**
|
|
4123
4053
|
* https://tc39.es/ecma402/#sec-formatnumberstring
|
|
4124
4054
|
*/
|
|
@@ -4174,8 +4104,7 @@ function FormatNumericToString(intlObject, _x) {
|
|
|
4174
4104
|
formattedString: string
|
|
4175
4105
|
};
|
|
4176
4106
|
}
|
|
4177
|
-
|
|
4178
|
-
//#region packages/ecma402-abstract/PluralRules/ResolvePlural.js
|
|
4107
|
+
// packages/ecma402-abstract/PluralRules/ResolvePlural.js
|
|
4179
4108
|
/**
|
|
4180
4109
|
* ResolvePluralInternal ( pluralRules, n )
|
|
4181
4110
|
*
|
|
@@ -4234,8 +4163,7 @@ function ResolvePlural(pl, n, { getInternalSlots, PluralRuleSelect }) {
|
|
|
4234
4163
|
PluralRuleSelect
|
|
4235
4164
|
}).pluralCategory;
|
|
4236
4165
|
}
|
|
4237
|
-
|
|
4238
|
-
//#region packages/ecma402-abstract/PluralRules/ResolvePluralRange.js
|
|
4166
|
+
// packages/ecma402-abstract/PluralRules/ResolvePluralRange.js
|
|
4239
4167
|
/**
|
|
4240
4168
|
* ResolvePluralRange ( pluralRules, x, y )
|
|
4241
4169
|
*
|
|
@@ -4270,8 +4198,7 @@ function ResolvePluralRange(pluralRules, x, y, { getInternalSlots, PluralRuleSel
|
|
|
4270
4198
|
const { locale, type } = internalSlots;
|
|
4271
4199
|
return PluralRuleSelectRange(locale, type, xp.pluralCategory, yp.pluralCategory);
|
|
4272
4200
|
}
|
|
4273
|
-
|
|
4274
|
-
//#region packages/intl-pluralrules/get_internal_slots.ts
|
|
4201
|
+
// packages/intl-pluralrules/get_internal_slots.ts
|
|
4275
4202
|
const internalSlotMap = /* @__PURE__ */ new WeakMap();
|
|
4276
4203
|
function getInternalSlots(x) {
|
|
4277
4204
|
let internalSlots = internalSlotMap.get(x);
|
|
@@ -4281,8 +4208,7 @@ function getInternalSlots(x) {
|
|
|
4281
4208
|
}
|
|
4282
4209
|
return internalSlots;
|
|
4283
4210
|
}
|
|
4284
|
-
|
|
4285
|
-
//#region packages/intl-pluralrules/index.ts
|
|
4211
|
+
// packages/intl-pluralrules/index.ts
|
|
4286
4212
|
function validateInstance(instance, method) {
|
|
4287
4213
|
if (!(instance instanceof PluralRules)) throw new TypeError(`Method Intl.PluralRules.prototype.${method} called on incompatible receiver ${String(instance)}`);
|
|
4288
4214
|
}
|
|
@@ -4484,8 +4410,7 @@ try {
|
|
|
4484
4410
|
configurable: true
|
|
4485
4411
|
});
|
|
4486
4412
|
} catch {}
|
|
4487
|
-
|
|
4488
|
-
//#region node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-locales@0.0.0/node_modules/@formatjs_generated/cldr.supported-locales/intl-pluralrules.js
|
|
4413
|
+
// node_modules/.aspect_rules_js/@formatjs_generated+cldr.supported-locales@0.0.0/node_modules/@formatjs_generated/cldr.supported-locales/intl-pluralrules.js
|
|
4489
4414
|
const supportedLocales = [
|
|
4490
4415
|
"af",
|
|
4491
4416
|
"ak",
|
|
@@ -4680,6 +4605,7 @@ const supportedLocales = [
|
|
|
4680
4605
|
"ta",
|
|
4681
4606
|
"te",
|
|
4682
4607
|
"teo",
|
|
4608
|
+
"tg",
|
|
4683
4609
|
"th",
|
|
4684
4610
|
"ti",
|
|
4685
4611
|
"tig",
|
|
@@ -4712,8 +4638,7 @@ const supportedLocales = [
|
|
|
4712
4638
|
"zh",
|
|
4713
4639
|
"zu"
|
|
4714
4640
|
];
|
|
4715
|
-
|
|
4716
|
-
//#region packages/intl-pluralrules/should-polyfill.ts
|
|
4641
|
+
// packages/intl-pluralrules/should-polyfill.ts
|
|
4717
4642
|
function supportedLocalesOf(locale) {
|
|
4718
4643
|
if (!locale) return true;
|
|
4719
4644
|
const locales = Array.isArray(locale) ? locale : [locale];
|
|
@@ -4722,8 +4647,7 @@ function supportedLocalesOf(locale) {
|
|
|
4722
4647
|
function shouldPolyfill(locale = "en") {
|
|
4723
4648
|
if (typeof Intl === "undefined" || !("PluralRules" in Intl) || new Intl.PluralRules("en", { minimumFractionDigits: 2 }).select(1) === "one" || !supportedLocalesOf(locale)) return locale ? match([locale], supportedLocales, "en") : void 0;
|
|
4724
4649
|
}
|
|
4725
|
-
|
|
4726
|
-
//#region packages/intl-pluralrules/polyfill.ts
|
|
4650
|
+
// packages/intl-pluralrules/polyfill.ts
|
|
4727
4651
|
const intl = ensureIntl();
|
|
4728
4652
|
if (shouldPolyfill()) {
|
|
4729
4653
|
defineProperty(intl, "PluralRules", { value: PluralRules });
|
|
@@ -4733,6 +4657,5 @@ if (shouldPolyfill()) {
|
|
|
4733
4657
|
delete globalThis.__FORMATJS_PLURALRULES_DATA__;
|
|
4734
4658
|
}
|
|
4735
4659
|
}
|
|
4736
|
-
//#endregion
|
|
4737
4660
|
|
|
4738
4661
|
//# sourceMappingURL=polyfill.iife.js.map
|