intl-messageformat 10.3.3 → 10.3.5

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.
@@ -1,499 +1,23 @@
1
- var __create = Object.create;
2
1
  var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
2
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __commonJS = (cb, mod) => function __require() {
9
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
10
- };
11
- var __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from === "object" || typeof from === "function") {
13
- for (let key of __getOwnPropNames(from))
14
- if (!__hasOwnProp.call(to, key) && key !== except)
15
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
- }
17
- return to;
18
- };
19
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
- mod
22
- ));
23
3
  var __publicField = (obj, key, value) => {
24
4
  __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
25
5
  return value;
26
6
  };
27
7
 
28
- // ../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/tslib@2.4.0/node_modules/tslib/tslib.js
29
- var require_tslib = __commonJS({
30
- "../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/tslib@2.4.0/node_modules/tslib/tslib.js"(exports, module) {
31
- var __extends2;
32
- var __assign2;
33
- var __rest2;
34
- var __decorate2;
35
- var __param2;
36
- var __metadata2;
37
- var __awaiter2;
38
- var __generator2;
39
- var __exportStar2;
40
- var __values2;
41
- var __read2;
42
- var __spread2;
43
- var __spreadArrays2;
44
- var __spreadArray2;
45
- var __await2;
46
- var __asyncGenerator2;
47
- var __asyncDelegator2;
48
- var __asyncValues2;
49
- var __makeTemplateObject2;
50
- var __importStar2;
51
- var __importDefault2;
52
- var __classPrivateFieldGet2;
53
- var __classPrivateFieldSet2;
54
- var __classPrivateFieldIn2;
55
- var __createBinding2;
56
- (function(factory) {
57
- var root = typeof global === "object" ? global : typeof self === "object" ? self : typeof this === "object" ? this : {};
58
- if (typeof define === "function" && define.amd) {
59
- define("tslib", ["exports"], function(exports2) {
60
- factory(createExporter(root, createExporter(exports2)));
61
- });
62
- } else if (typeof module === "object" && typeof module.exports === "object") {
63
- factory(createExporter(root, createExporter(module.exports)));
64
- } else {
65
- factory(createExporter(root));
66
- }
67
- function createExporter(exports2, previous) {
68
- if (exports2 !== root) {
69
- if (typeof Object.create === "function") {
70
- Object.defineProperty(exports2, "__esModule", { value: true });
71
- } else {
72
- exports2.__esModule = true;
73
- }
74
- }
75
- return function(id, v) {
76
- return exports2[id] = previous ? previous(id, v) : v;
77
- };
78
- }
79
- })(function(exporter) {
80
- var extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d, b) {
81
- d.__proto__ = b;
82
- } || function(d, b) {
83
- for (var p in b)
84
- if (Object.prototype.hasOwnProperty.call(b, p))
85
- d[p] = b[p];
86
- };
87
- __extends2 = function(d, b) {
88
- if (typeof b !== "function" && b !== null)
89
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
90
- extendStatics(d, b);
91
- function __() {
92
- this.constructor = d;
93
- }
94
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
95
- };
96
- __assign2 = Object.assign || function(t) {
97
- for (var s, i = 1, n = arguments.length; i < n; i++) {
98
- s = arguments[i];
99
- for (var p in s)
100
- if (Object.prototype.hasOwnProperty.call(s, p))
101
- t[p] = s[p];
102
- }
103
- return t;
104
- };
105
- __rest2 = function(s, e) {
106
- var t = {};
107
- for (var p in s)
108
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
109
- t[p] = s[p];
110
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
111
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
112
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
113
- t[p[i]] = s[p[i]];
114
- }
115
- return t;
116
- };
117
- __decorate2 = function(decorators, target, key, desc) {
118
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
119
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
120
- r = Reflect.decorate(decorators, target, key, desc);
121
- else
122
- for (var i = decorators.length - 1; i >= 0; i--)
123
- if (d = decorators[i])
124
- r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
125
- return c > 3 && r && Object.defineProperty(target, key, r), r;
126
- };
127
- __param2 = function(paramIndex, decorator) {
128
- return function(target, key) {
129
- decorator(target, key, paramIndex);
130
- };
131
- };
132
- __metadata2 = function(metadataKey, metadataValue) {
133
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
134
- return Reflect.metadata(metadataKey, metadataValue);
135
- };
136
- __awaiter2 = function(thisArg, _arguments, P, generator) {
137
- function adopt(value) {
138
- return value instanceof P ? value : new P(function(resolve) {
139
- resolve(value);
140
- });
141
- }
142
- return new (P || (P = Promise))(function(resolve, reject) {
143
- function fulfilled(value) {
144
- try {
145
- step(generator.next(value));
146
- } catch (e) {
147
- reject(e);
148
- }
149
- }
150
- function rejected(value) {
151
- try {
152
- step(generator["throw"](value));
153
- } catch (e) {
154
- reject(e);
155
- }
156
- }
157
- function step(result) {
158
- result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
159
- }
160
- step((generator = generator.apply(thisArg, _arguments || [])).next());
161
- });
162
- };
163
- __generator2 = function(thisArg, body) {
164
- var _ = { label: 0, sent: function() {
165
- if (t[0] & 1)
166
- throw t[1];
167
- return t[1];
168
- }, trys: [], ops: [] }, f, y, t, g;
169
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
170
- return this;
171
- }), g;
172
- function verb(n) {
173
- return function(v) {
174
- return step([n, v]);
175
- };
176
- }
177
- function step(op) {
178
- if (f)
179
- throw new TypeError("Generator is already executing.");
180
- while (_)
181
- try {
182
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
183
- return t;
184
- if (y = 0, t)
185
- op = [op[0] & 2, t.value];
186
- switch (op[0]) {
187
- case 0:
188
- case 1:
189
- t = op;
190
- break;
191
- case 4:
192
- _.label++;
193
- return { value: op[1], done: false };
194
- case 5:
195
- _.label++;
196
- y = op[1];
197
- op = [0];
198
- continue;
199
- case 7:
200
- op = _.ops.pop();
201
- _.trys.pop();
202
- continue;
203
- default:
204
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
205
- _ = 0;
206
- continue;
207
- }
208
- if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
209
- _.label = op[1];
210
- break;
211
- }
212
- if (op[0] === 6 && _.label < t[1]) {
213
- _.label = t[1];
214
- t = op;
215
- break;
216
- }
217
- if (t && _.label < t[2]) {
218
- _.label = t[2];
219
- _.ops.push(op);
220
- break;
221
- }
222
- if (t[2])
223
- _.ops.pop();
224
- _.trys.pop();
225
- continue;
226
- }
227
- op = body.call(thisArg, _);
228
- } catch (e) {
229
- op = [6, e];
230
- y = 0;
231
- } finally {
232
- f = t = 0;
233
- }
234
- if (op[0] & 5)
235
- throw op[1];
236
- return { value: op[0] ? op[1] : void 0, done: true };
237
- }
238
- };
239
- __exportStar2 = function(m, o) {
240
- for (var p in m)
241
- if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
242
- __createBinding2(o, m, p);
243
- };
244
- __createBinding2 = Object.create ? function(o, m, k, k2) {
245
- if (k2 === void 0)
246
- k2 = k;
247
- var desc = Object.getOwnPropertyDescriptor(m, k);
248
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
249
- desc = { enumerable: true, get: function() {
250
- return m[k];
251
- } };
252
- }
253
- Object.defineProperty(o, k2, desc);
254
- } : function(o, m, k, k2) {
255
- if (k2 === void 0)
256
- k2 = k;
257
- o[k2] = m[k];
258
- };
259
- __values2 = function(o) {
260
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
261
- if (m)
262
- return m.call(o);
263
- if (o && typeof o.length === "number")
264
- return {
265
- next: function() {
266
- if (o && i >= o.length)
267
- o = void 0;
268
- return { value: o && o[i++], done: !o };
269
- }
270
- };
271
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
272
- };
273
- __read2 = function(o, n) {
274
- var m = typeof Symbol === "function" && o[Symbol.iterator];
275
- if (!m)
276
- return o;
277
- var i = m.call(o), r, ar = [], e;
278
- try {
279
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
280
- ar.push(r.value);
281
- } catch (error) {
282
- e = { error };
283
- } finally {
284
- try {
285
- if (r && !r.done && (m = i["return"]))
286
- m.call(i);
287
- } finally {
288
- if (e)
289
- throw e.error;
290
- }
291
- }
292
- return ar;
293
- };
294
- __spread2 = function() {
295
- for (var ar = [], i = 0; i < arguments.length; i++)
296
- ar = ar.concat(__read2(arguments[i]));
297
- return ar;
298
- };
299
- __spreadArrays2 = function() {
300
- for (var s = 0, i = 0, il = arguments.length; i < il; i++)
301
- s += arguments[i].length;
302
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
303
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
304
- r[k] = a[j];
305
- return r;
306
- };
307
- __spreadArray2 = function(to, from, pack) {
308
- if (pack || arguments.length === 2)
309
- for (var i = 0, l = from.length, ar; i < l; i++) {
310
- if (ar || !(i in from)) {
311
- if (!ar)
312
- ar = Array.prototype.slice.call(from, 0, i);
313
- ar[i] = from[i];
314
- }
315
- }
316
- return to.concat(ar || Array.prototype.slice.call(from));
317
- };
318
- __await2 = function(v) {
319
- return this instanceof __await2 ? (this.v = v, this) : new __await2(v);
320
- };
321
- __asyncGenerator2 = function(thisArg, _arguments, generator) {
322
- if (!Symbol.asyncIterator)
323
- throw new TypeError("Symbol.asyncIterator is not defined.");
324
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
325
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() {
326
- return this;
327
- }, i;
328
- function verb(n) {
329
- if (g[n])
330
- i[n] = function(v) {
331
- return new Promise(function(a, b) {
332
- q.push([n, v, a, b]) > 1 || resume(n, v);
333
- });
334
- };
335
- }
336
- function resume(n, v) {
337
- try {
338
- step(g[n](v));
339
- } catch (e) {
340
- settle(q[0][3], e);
341
- }
342
- }
343
- function step(r) {
344
- r.value instanceof __await2 ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r);
345
- }
346
- function fulfill(value) {
347
- resume("next", value);
348
- }
349
- function reject(value) {
350
- resume("throw", value);
351
- }
352
- function settle(f, v) {
353
- if (f(v), q.shift(), q.length)
354
- resume(q[0][0], q[0][1]);
355
- }
356
- };
357
- __asyncDelegator2 = function(o) {
358
- var i, p;
359
- return i = {}, verb("next"), verb("throw", function(e) {
360
- throw e;
361
- }), verb("return"), i[Symbol.iterator] = function() {
362
- return this;
363
- }, i;
364
- function verb(n, f) {
365
- i[n] = o[n] ? function(v) {
366
- return (p = !p) ? { value: __await2(o[n](v)), done: n === "return" } : f ? f(v) : v;
367
- } : f;
368
- }
369
- };
370
- __asyncValues2 = function(o) {
371
- if (!Symbol.asyncIterator)
372
- throw new TypeError("Symbol.asyncIterator is not defined.");
373
- var m = o[Symbol.asyncIterator], i;
374
- return m ? m.call(o) : (o = typeof __values2 === "function" ? __values2(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() {
375
- return this;
376
- }, i);
377
- function verb(n) {
378
- i[n] = o[n] && function(v) {
379
- return new Promise(function(resolve, reject) {
380
- v = o[n](v), settle(resolve, reject, v.done, v.value);
381
- });
382
- };
383
- }
384
- function settle(resolve, reject, d, v) {
385
- Promise.resolve(v).then(function(v2) {
386
- resolve({ value: v2, done: d });
387
- }, reject);
388
- }
389
- };
390
- __makeTemplateObject2 = function(cooked, raw) {
391
- if (Object.defineProperty) {
392
- Object.defineProperty(cooked, "raw", { value: raw });
393
- } else {
394
- cooked.raw = raw;
395
- }
396
- return cooked;
397
- };
398
- var __setModuleDefault = Object.create ? function(o, v) {
399
- Object.defineProperty(o, "default", { enumerable: true, value: v });
400
- } : function(o, v) {
401
- o["default"] = v;
402
- };
403
- __importStar2 = function(mod) {
404
- if (mod && mod.__esModule)
405
- return mod;
406
- var result = {};
407
- if (mod != null) {
408
- for (var k in mod)
409
- if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
410
- __createBinding2(result, mod, k);
411
- }
412
- __setModuleDefault(result, mod);
413
- return result;
414
- };
415
- __importDefault2 = function(mod) {
416
- return mod && mod.__esModule ? mod : { "default": mod };
417
- };
418
- __classPrivateFieldGet2 = function(receiver, state, kind, f) {
419
- if (kind === "a" && !f)
420
- throw new TypeError("Private accessor was defined without a getter");
421
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
422
- throw new TypeError("Cannot read private member from an object whose class did not declare it");
423
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
424
- };
425
- __classPrivateFieldSet2 = function(receiver, state, value, kind, f) {
426
- if (kind === "m")
427
- throw new TypeError("Private method is not writable");
428
- if (kind === "a" && !f)
429
- throw new TypeError("Private accessor was defined without a setter");
430
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
431
- throw new TypeError("Cannot write private member to an object whose class did not declare it");
432
- return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
433
- };
434
- __classPrivateFieldIn2 = function(state, receiver) {
435
- if (receiver === null || typeof receiver !== "object" && typeof receiver !== "function")
436
- throw new TypeError("Cannot use 'in' operator on non-object");
437
- return typeof state === "function" ? receiver === state : state.has(receiver);
438
- };
439
- exporter("__extends", __extends2);
440
- exporter("__assign", __assign2);
441
- exporter("__rest", __rest2);
442
- exporter("__decorate", __decorate2);
443
- exporter("__param", __param2);
444
- exporter("__metadata", __metadata2);
445
- exporter("__awaiter", __awaiter2);
446
- exporter("__generator", __generator2);
447
- exporter("__exportStar", __exportStar2);
448
- exporter("__createBinding", __createBinding2);
449
- exporter("__values", __values2);
450
- exporter("__read", __read2);
451
- exporter("__spread", __spread2);
452
- exporter("__spreadArrays", __spreadArrays2);
453
- exporter("__spreadArray", __spreadArray2);
454
- exporter("__await", __await2);
455
- exporter("__asyncGenerator", __asyncGenerator2);
456
- exporter("__asyncDelegator", __asyncDelegator2);
457
- exporter("__asyncValues", __asyncValues2);
458
- exporter("__makeTemplateObject", __makeTemplateObject2);
459
- exporter("__importStar", __importStar2);
460
- exporter("__importDefault", __importDefault2);
461
- exporter("__classPrivateFieldGet", __classPrivateFieldGet2);
462
- exporter("__classPrivateFieldSet", __classPrivateFieldSet2);
463
- exporter("__classPrivateFieldIn", __classPrivateFieldIn2);
464
- });
465
- }
466
- });
467
-
468
- // ../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/tslib@2.4.0/node_modules/tslib/modules/index.js
469
- var import_tslib = __toESM(require_tslib(), 1);
470
- var {
471
- __extends,
472
- __assign,
473
- __rest,
474
- __decorate,
475
- __param,
476
- __metadata,
477
- __awaiter,
478
- __generator,
479
- __exportStar,
480
- __createBinding,
481
- __values,
482
- __read,
483
- __spread,
484
- __spreadArrays,
485
- __spreadArray,
486
- __await,
487
- __asyncGenerator,
488
- __asyncDelegator,
489
- __asyncValues,
490
- __makeTemplateObject,
491
- __importStar,
492
- __importDefault,
493
- __classPrivateFieldGet,
494
- __classPrivateFieldSet,
495
- __classPrivateFieldIn
496
- } = import_tslib.default;
8
+ // ../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/tslib@2.4.0/node_modules/tslib/tslib.es6.js
9
+ var __assign = function() {
10
+ __assign = Object.assign || function __assign2(t) {
11
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
12
+ s = arguments[i];
13
+ for (var p in s)
14
+ if (Object.prototype.hasOwnProperty.call(s, p))
15
+ t[p] = s[p];
16
+ }
17
+ return t;
18
+ };
19
+ return __assign.apply(this, arguments);
20
+ };
497
21
 
498
22
  // ../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/error.js
499
23
  var ErrorKind;
@@ -953,747 +477,875 @@ function parseNumberSkeleton(tokens) {
953
477
 
954
478
  // ../../../../../../../../execroot/formatjs/bazel-out/darwin_arm64-fastbuild/bin/node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/time-data.generated.js
955
479
  var timeData = {
956
- "AX": [
957
- "H"
958
- ],
959
- "BQ": [
960
- "H"
961
- ],
962
- "CP": [
963
- "H"
964
- ],
965
- "CZ": [
966
- "H"
967
- ],
968
- "DK": [
969
- "H"
970
- ],
971
- "FI": [
972
- "H"
973
- ],
974
- "ID": [
975
- "H"
976
- ],
977
- "IS": [
978
- "H"
979
- ],
980
- "ML": [
981
- "H"
982
- ],
983
- "NE": [
984
- "H"
985
- ],
986
- "RU": [
987
- "H"
988
- ],
989
- "SE": [
990
- "H"
480
+ "001": [
481
+ "H",
482
+ "h"
991
483
  ],
992
- "SJ": [
993
- "H"
484
+ "AC": [
485
+ "H",
486
+ "h",
487
+ "hb",
488
+ "hB"
994
489
  ],
995
- "SK": [
996
- "H"
490
+ "AD": [
491
+ "H",
492
+ "hB"
997
493
  ],
998
- "AS": [
494
+ "AE": [
999
495
  "h",
496
+ "hB",
497
+ "hb",
1000
498
  "H"
1001
499
  ],
1002
- "BT": [
1003
- "h",
1004
- "H"
500
+ "AF": [
501
+ "H",
502
+ "hb",
503
+ "hB",
504
+ "h"
1005
505
  ],
1006
- "DJ": [
506
+ "AG": [
1007
507
  "h",
1008
- "H"
508
+ "hb",
509
+ "H",
510
+ "hB"
1009
511
  ],
1010
- "ER": [
512
+ "AI": [
513
+ "H",
1011
514
  "h",
1012
- "H"
515
+ "hb",
516
+ "hB"
1013
517
  ],
1014
- "GH": [
518
+ "AL": [
1015
519
  "h",
1016
- "H"
520
+ "H",
521
+ "hB"
1017
522
  ],
1018
- "IN": [
1019
- "h",
1020
- "H"
523
+ "AM": [
524
+ "H",
525
+ "hB"
1021
526
  ],
1022
- "LS": [
1023
- "h",
1024
- "H"
527
+ "AO": [
528
+ "H",
529
+ "hB"
1025
530
  ],
1026
- "PG": [
531
+ "AR": [
532
+ "H",
1027
533
  "h",
1028
- "H"
534
+ "hB",
535
+ "hb"
1029
536
  ],
1030
- "PW": [
537
+ "AS": [
1031
538
  "h",
1032
539
  "H"
1033
540
  ],
1034
- "SO": [
1035
- "h",
1036
- "H"
541
+ "AT": [
542
+ "H",
543
+ "hB"
1037
544
  ],
1038
- "TO": [
545
+ "AU": [
1039
546
  "h",
1040
- "H"
547
+ "hb",
548
+ "H",
549
+ "hB"
1041
550
  ],
1042
- "VU": [
1043
- "h",
1044
- "H"
551
+ "AW": [
552
+ "H",
553
+ "hB"
1045
554
  ],
1046
- "WS": [
1047
- "h",
555
+ "AX": [
1048
556
  "H"
1049
557
  ],
1050
- "001": [
558
+ "AZ": [
1051
559
  "H",
560
+ "hB",
1052
561
  "h"
1053
562
  ],
1054
- "AL": [
1055
- "h",
563
+ "BA": [
1056
564
  "H",
1057
- "hB"
565
+ "hB",
566
+ "h"
1058
567
  ],
1059
- "TD": [
568
+ "BB": [
1060
569
  "h",
570
+ "hb",
1061
571
  "H",
1062
572
  "hB"
1063
573
  ],
1064
- "ca-ES": [
1065
- "H",
574
+ "BD": [
1066
575
  "h",
1067
- "hB"
576
+ "hB",
577
+ "H"
1068
578
  ],
1069
- "CF": [
579
+ "BE": [
1070
580
  "H",
1071
- "h",
1072
581
  "hB"
1073
582
  ],
1074
- "CM": [
583
+ "BF": [
1075
584
  "H",
1076
- "h",
1077
585
  "hB"
1078
586
  ],
1079
- "fr-CA": [
587
+ "BG": [
1080
588
  "H",
1081
- "h",
1082
- "hB"
589
+ "hB",
590
+ "h"
1083
591
  ],
1084
- "gl-ES": [
1085
- "H",
592
+ "BH": [
1086
593
  "h",
1087
- "hB"
594
+ "hB",
595
+ "hb",
596
+ "H"
1088
597
  ],
1089
- "it-CH": [
598
+ "BJ": [
1090
599
  "H",
1091
- "h",
1092
600
  "hB"
1093
601
  ],
1094
- "it-IT": [
602
+ "BL": [
1095
603
  "H",
1096
- "h",
1097
604
  "hB"
1098
605
  ],
1099
- "LU": [
1100
- "H",
606
+ "BM": [
1101
607
  "h",
1102
- "hB"
1103
- ],
1104
- "NP": [
608
+ "hb",
1105
609
  "H",
1106
- "h",
1107
610
  "hB"
1108
611
  ],
1109
- "PF": [
1110
- "H",
612
+ "BN": [
613
+ "hb",
614
+ "hB",
1111
615
  "h",
1112
- "hB"
616
+ "H"
1113
617
  ],
1114
- "SC": [
618
+ "BO": [
1115
619
  "H",
620
+ "hB",
1116
621
  "h",
1117
- "hB"
622
+ "hb"
1118
623
  ],
1119
- "SM": [
624
+ "BQ": [
625
+ "H"
626
+ ],
627
+ "BR": [
1120
628
  "H",
1121
- "h",
1122
629
  "hB"
1123
630
  ],
1124
- "SN": [
1125
- "H",
631
+ "BS": [
1126
632
  "h",
633
+ "hb",
634
+ "H",
1127
635
  "hB"
1128
636
  ],
1129
- "TF": [
637
+ "BT": [
638
+ "h",
639
+ "H"
640
+ ],
641
+ "BW": [
1130
642
  "H",
1131
643
  "h",
644
+ "hb",
1132
645
  "hB"
1133
646
  ],
1134
- "VA": [
647
+ "BZ": [
1135
648
  "H",
1136
649
  "h",
650
+ "hb",
1137
651
  "hB"
1138
652
  ],
1139
- "CY": [
653
+ "CA": [
1140
654
  "h",
1141
- "H",
1142
655
  "hb",
656
+ "H",
1143
657
  "hB"
1144
658
  ],
1145
- "GR": [
1146
- "h",
659
+ "CC": [
1147
660
  "H",
661
+ "h",
1148
662
  "hb",
1149
663
  "hB"
1150
664
  ],
1151
- "CO": [
1152
- "h",
1153
- "H",
665
+ "CD": [
1154
666
  "hB",
1155
- "hb"
667
+ "H"
1156
668
  ],
1157
- "DO": [
669
+ "CF": [
670
+ "H",
1158
671
  "h",
672
+ "hB"
673
+ ],
674
+ "CG": [
1159
675
  "H",
1160
- "hB",
1161
- "hb"
676
+ "hB"
1162
677
  ],
1163
- "KP": [
1164
- "h",
678
+ "CH": [
1165
679
  "H",
1166
680
  "hB",
1167
- "hb"
681
+ "h"
1168
682
  ],
1169
- "KR": [
683
+ "CI": [
684
+ "H",
685
+ "hB"
686
+ ],
687
+ "CK": [
688
+ "H",
1170
689
  "h",
690
+ "hb",
691
+ "hB"
692
+ ],
693
+ "CL": [
1171
694
  "H",
695
+ "h",
1172
696
  "hB",
1173
697
  "hb"
1174
698
  ],
1175
- "NA": [
699
+ "CM": [
700
+ "H",
1176
701
  "h",
702
+ "hB"
703
+ ],
704
+ "CN": [
1177
705
  "H",
1178
706
  "hB",
1179
- "hb"
707
+ "hb",
708
+ "h"
1180
709
  ],
1181
- "PA": [
710
+ "CO": [
1182
711
  "h",
1183
712
  "H",
1184
713
  "hB",
1185
714
  "hb"
1186
715
  ],
1187
- "PR": [
1188
- "h",
716
+ "CP": [
717
+ "H"
718
+ ],
719
+ "CR": [
1189
720
  "H",
721
+ "h",
1190
722
  "hB",
1191
723
  "hb"
1192
724
  ],
1193
- "VE": [
1194
- "h",
725
+ "CU": [
1195
726
  "H",
727
+ "h",
1196
728
  "hB",
1197
729
  "hb"
1198
730
  ],
1199
- "AC": [
731
+ "CV": [
1200
732
  "H",
1201
- "h",
1202
- "hb",
1203
733
  "hB"
1204
734
  ],
1205
- "AI": [
735
+ "CX": [
1206
736
  "H",
1207
737
  "h",
1208
738
  "hb",
1209
739
  "hB"
1210
740
  ],
1211
- "BW": [
1212
- "H",
741
+ "CY": [
1213
742
  "h",
743
+ "H",
1214
744
  "hb",
1215
745
  "hB"
1216
746
  ],
1217
- "BZ": [
747
+ "CZ": [
748
+ "H"
749
+ ],
750
+ "DE": [
1218
751
  "H",
1219
- "h",
1220
- "hb",
1221
752
  "hB"
1222
753
  ],
1223
- "CC": [
754
+ "DG": [
1224
755
  "H",
1225
756
  "h",
1226
757
  "hb",
1227
758
  "hB"
1228
759
  ],
1229
- "CK": [
1230
- "H",
760
+ "DJ": [
1231
761
  "h",
1232
- "hb",
1233
- "hB"
762
+ "H"
1234
763
  ],
1235
- "CX": [
1236
- "H",
764
+ "DK": [
765
+ "H"
766
+ ],
767
+ "DM": [
1237
768
  "h",
1238
769
  "hb",
770
+ "H",
1239
771
  "hB"
1240
772
  ],
1241
- "DG": [
773
+ "DO": [
774
+ "h",
1242
775
  "H",
776
+ "hB",
777
+ "hb"
778
+ ],
779
+ "DZ": [
1243
780
  "h",
781
+ "hB",
1244
782
  "hb",
1245
- "hB"
783
+ "H"
1246
784
  ],
1247
- "FK": [
785
+ "EA": [
1248
786
  "H",
1249
787
  "h",
1250
- "hb",
1251
- "hB"
788
+ "hB",
789
+ "hb"
1252
790
  ],
1253
- "GB": [
791
+ "EC": [
1254
792
  "H",
793
+ "hB",
1255
794
  "h",
1256
- "hb",
1257
- "hB"
795
+ "hb"
1258
796
  ],
1259
- "GG": [
797
+ "EE": [
1260
798
  "H",
1261
- "h",
1262
- "hb",
1263
799
  "hB"
1264
800
  ],
1265
- "GI": [
1266
- "H",
801
+ "EG": [
1267
802
  "h",
803
+ "hB",
1268
804
  "hb",
1269
- "hB"
805
+ "H"
1270
806
  ],
1271
- "IE": [
1272
- "H",
807
+ "EH": [
1273
808
  "h",
809
+ "hB",
1274
810
  "hb",
1275
- "hB"
811
+ "H"
1276
812
  ],
1277
- "IM": [
1278
- "H",
813
+ "ER": [
1279
814
  "h",
1280
- "hb",
1281
- "hB"
815
+ "H"
1282
816
  ],
1283
- "IO": [
817
+ "ES": [
1284
818
  "H",
819
+ "hB",
1285
820
  "h",
821
+ "hb"
822
+ ],
823
+ "ET": [
824
+ "hB",
1286
825
  "hb",
1287
- "hB"
826
+ "h",
827
+ "H"
1288
828
  ],
1289
- "JE": [
1290
- "H",
829
+ "FI": [
830
+ "H"
831
+ ],
832
+ "FJ": [
1291
833
  "h",
1292
834
  "hb",
835
+ "H",
1293
836
  "hB"
1294
837
  ],
1295
- "LT": [
838
+ "FK": [
1296
839
  "H",
1297
840
  "h",
1298
841
  "hb",
1299
842
  "hB"
1300
843
  ],
1301
- "MK": [
1302
- "H",
844
+ "FM": [
1303
845
  "h",
1304
846
  "hb",
847
+ "H",
1305
848
  "hB"
1306
849
  ],
1307
- "MN": [
850
+ "FR": [
1308
851
  "H",
1309
- "h",
1310
- "hb",
1311
852
  "hB"
1312
853
  ],
1313
- "MS": [
854
+ "GA": [
1314
855
  "H",
1315
- "h",
1316
- "hb",
1317
856
  "hB"
1318
857
  ],
1319
- "NF": [
858
+ "GB": [
1320
859
  "H",
1321
860
  "h",
1322
861
  "hb",
1323
862
  "hB"
1324
863
  ],
1325
- "NG": [
1326
- "H",
864
+ "GD": [
1327
865
  "h",
1328
866
  "hb",
867
+ "H",
1329
868
  "hB"
1330
869
  ],
1331
- "NR": [
870
+ "GE": [
1332
871
  "H",
1333
- "h",
1334
- "hb",
1335
- "hB"
872
+ "hB",
873
+ "h"
1336
874
  ],
1337
- "NU": [
875
+ "GF": [
1338
876
  "H",
1339
- "h",
1340
- "hb",
1341
877
  "hB"
1342
878
  ],
1343
- "PN": [
879
+ "GG": [
1344
880
  "H",
1345
881
  "h",
1346
882
  "hb",
1347
883
  "hB"
1348
884
  ],
1349
- "SH": [
1350
- "H",
885
+ "GH": [
1351
886
  "h",
1352
- "hb",
1353
- "hB"
887
+ "H"
1354
888
  ],
1355
- "SX": [
889
+ "GI": [
1356
890
  "H",
1357
891
  "h",
1358
892
  "hb",
1359
893
  "hB"
1360
894
  ],
1361
- "TA": [
1362
- "H",
895
+ "GM": [
1363
896
  "h",
1364
897
  "hb",
898
+ "H",
1365
899
  "hB"
1366
900
  ],
1367
- "ZA": [
901
+ "GN": [
1368
902
  "H",
1369
- "h",
1370
- "hb",
1371
903
  "hB"
1372
904
  ],
1373
- "af-ZA": [
905
+ "GP": [
1374
906
  "H",
1375
- "h",
1376
- "hB",
1377
- "hb"
907
+ "hB"
1378
908
  ],
1379
- "AR": [
909
+ "GQ": [
1380
910
  "H",
1381
- "h",
1382
911
  "hB",
912
+ "h",
1383
913
  "hb"
1384
914
  ],
1385
- "CL": [
1386
- "H",
915
+ "GR": [
1387
916
  "h",
1388
- "hB",
1389
- "hb"
917
+ "H",
918
+ "hb",
919
+ "hB"
1390
920
  ],
1391
- "CR": [
921
+ "GT": [
1392
922
  "H",
1393
923
  "h",
1394
924
  "hB",
1395
925
  "hb"
1396
926
  ],
1397
- "CU": [
1398
- "H",
927
+ "GU": [
1399
928
  "h",
1400
- "hB",
1401
- "hb"
929
+ "hb",
930
+ "H",
931
+ "hB"
1402
932
  ],
1403
- "EA": [
933
+ "GW": [
1404
934
  "H",
1405
- "h",
1406
- "hB",
1407
- "hb"
935
+ "hB"
1408
936
  ],
1409
- "es-BO": [
937
+ "GY": [
938
+ "h",
939
+ "hb",
1410
940
  "H",
941
+ "hB"
942
+ ],
943
+ "HK": [
1411
944
  "h",
1412
945
  "hB",
1413
- "hb"
946
+ "hb",
947
+ "H"
1414
948
  ],
1415
- "es-BR": [
949
+ "HN": [
1416
950
  "H",
1417
951
  "h",
1418
952
  "hB",
1419
953
  "hb"
1420
954
  ],
1421
- "es-EC": [
955
+ "HR": [
1422
956
  "H",
1423
- "h",
1424
- "hB",
1425
- "hb"
957
+ "hB"
1426
958
  ],
1427
- "es-ES": [
959
+ "IC": [
1428
960
  "H",
1429
961
  "h",
1430
962
  "hB",
1431
963
  "hb"
1432
964
  ],
1433
- "es-GQ": [
965
+ "ID": [
966
+ "H"
967
+ ],
968
+ "IE": [
1434
969
  "H",
1435
970
  "h",
1436
- "hB",
1437
- "hb"
971
+ "hb",
972
+ "hB"
1438
973
  ],
1439
- "es-PE": [
974
+ "IL": [
1440
975
  "H",
1441
- "h",
1442
- "hB",
1443
- "hb"
976
+ "hB"
1444
977
  ],
1445
- "GT": [
978
+ "IM": [
1446
979
  "H",
1447
980
  "h",
1448
- "hB",
1449
- "hb"
981
+ "hb",
982
+ "hB"
1450
983
  ],
1451
- "HN": [
1452
- "H",
984
+ "IN": [
1453
985
  "h",
1454
- "hB",
1455
- "hb"
986
+ "H"
1456
987
  ],
1457
- "IC": [
988
+ "IO": [
1458
989
  "H",
1459
990
  "h",
1460
- "hB",
1461
- "hb"
991
+ "hb",
992
+ "hB"
1462
993
  ],
1463
- "KG": [
1464
- "H",
994
+ "IQ": [
1465
995
  "h",
1466
996
  "hB",
1467
- "hb"
997
+ "hb",
998
+ "H"
1468
999
  ],
1469
- "KM": [
1000
+ "IR": [
1001
+ "hB",
1002
+ "H"
1003
+ ],
1004
+ "IS": [
1005
+ "H"
1006
+ ],
1007
+ "IT": [
1008
+ "H",
1009
+ "hB"
1010
+ ],
1011
+ "JE": [
1470
1012
  "H",
1471
1013
  "h",
1472
- "hB",
1473
- "hb"
1014
+ "hb",
1015
+ "hB"
1474
1016
  ],
1475
- "LK": [
1017
+ "JM": [
1018
+ "h",
1019
+ "hb",
1476
1020
  "H",
1021
+ "hB"
1022
+ ],
1023
+ "JO": [
1477
1024
  "h",
1478
1025
  "hB",
1479
- "hb"
1026
+ "hb",
1027
+ "H"
1480
1028
  ],
1481
- "MA": [
1029
+ "JP": [
1482
1030
  "H",
1483
1031
  "h",
1032
+ "K"
1033
+ ],
1034
+ "KE": [
1484
1035
  "hB",
1485
- "hb"
1036
+ "hb",
1037
+ "H",
1038
+ "h"
1486
1039
  ],
1487
- "MX": [
1040
+ "KG": [
1488
1041
  "H",
1489
1042
  "h",
1490
1043
  "hB",
1491
1044
  "hb"
1492
1045
  ],
1493
- "NI": [
1494
- "H",
1495
- "h",
1046
+ "KH": [
1496
1047
  "hB",
1048
+ "h",
1049
+ "H",
1497
1050
  "hb"
1498
1051
  ],
1499
- "PY": [
1052
+ "KI": [
1053
+ "h",
1054
+ "hb",
1055
+ "H",
1056
+ "hB"
1057
+ ],
1058
+ "KM": [
1500
1059
  "H",
1501
1060
  "h",
1502
1061
  "hB",
1503
1062
  "hb"
1504
1063
  ],
1505
- "SV": [
1064
+ "KN": [
1065
+ "h",
1066
+ "hb",
1506
1067
  "H",
1068
+ "hB"
1069
+ ],
1070
+ "KP": [
1507
1071
  "h",
1072
+ "H",
1508
1073
  "hB",
1509
1074
  "hb"
1510
1075
  ],
1511
- "UY": [
1512
- "H",
1076
+ "KR": [
1513
1077
  "h",
1078
+ "H",
1514
1079
  "hB",
1515
1080
  "hb"
1516
1081
  ],
1517
- "JP": [
1518
- "H",
1082
+ "KW": [
1519
1083
  "h",
1520
- "K"
1084
+ "hB",
1085
+ "hb",
1086
+ "H"
1521
1087
  ],
1522
- "AD": [
1088
+ "KY": [
1089
+ "h",
1090
+ "hb",
1523
1091
  "H",
1524
1092
  "hB"
1525
1093
  ],
1526
- "AM": [
1094
+ "KZ": [
1527
1095
  "H",
1528
1096
  "hB"
1529
1097
  ],
1530
- "AO": [
1098
+ "LA": [
1531
1099
  "H",
1532
- "hB"
1100
+ "hb",
1101
+ "hB",
1102
+ "h"
1533
1103
  ],
1534
- "AT": [
1535
- "H",
1536
- "hB"
1104
+ "LB": [
1105
+ "h",
1106
+ "hB",
1107
+ "hb",
1108
+ "H"
1537
1109
  ],
1538
- "AW": [
1110
+ "LC": [
1111
+ "h",
1112
+ "hb",
1539
1113
  "H",
1540
1114
  "hB"
1541
1115
  ],
1542
- "BE": [
1116
+ "LI": [
1543
1117
  "H",
1544
- "hB"
1118
+ "hB",
1119
+ "h"
1545
1120
  ],
1546
- "BF": [
1121
+ "LK": [
1547
1122
  "H",
1548
- "hB"
1123
+ "h",
1124
+ "hB",
1125
+ "hb"
1549
1126
  ],
1550
- "BJ": [
1127
+ "LR": [
1128
+ "h",
1129
+ "hb",
1551
1130
  "H",
1552
1131
  "hB"
1553
1132
  ],
1554
- "BL": [
1133
+ "LS": [
1134
+ "h",
1135
+ "H"
1136
+ ],
1137
+ "LT": [
1555
1138
  "H",
1139
+ "h",
1140
+ "hb",
1556
1141
  "hB"
1557
1142
  ],
1558
- "BR": [
1143
+ "LU": [
1559
1144
  "H",
1145
+ "h",
1560
1146
  "hB"
1561
1147
  ],
1562
- "CG": [
1148
+ "LV": [
1563
1149
  "H",
1564
- "hB"
1150
+ "hB",
1151
+ "hb",
1152
+ "h"
1565
1153
  ],
1566
- "CI": [
1154
+ "LY": [
1155
+ "h",
1156
+ "hB",
1157
+ "hb",
1158
+ "H"
1159
+ ],
1160
+ "MA": [
1567
1161
  "H",
1568
- "hB"
1162
+ "h",
1163
+ "hB",
1164
+ "hb"
1569
1165
  ],
1570
- "CV": [
1166
+ "MC": [
1571
1167
  "H",
1572
1168
  "hB"
1573
1169
  ],
1574
- "DE": [
1170
+ "MD": [
1575
1171
  "H",
1576
1172
  "hB"
1577
1173
  ],
1578
- "EE": [
1174
+ "ME": [
1579
1175
  "H",
1580
- "hB"
1176
+ "hB",
1177
+ "h"
1581
1178
  ],
1582
- "FR": [
1179
+ "MF": [
1583
1180
  "H",
1584
1181
  "hB"
1585
1182
  ],
1586
- "GA": [
1183
+ "MH": [
1184
+ "h",
1185
+ "hb",
1587
1186
  "H",
1588
1187
  "hB"
1589
1188
  ],
1590
- "GF": [
1189
+ "MK": [
1591
1190
  "H",
1191
+ "h",
1192
+ "hb",
1592
1193
  "hB"
1593
1194
  ],
1594
- "GN": [
1195
+ "ML": [
1196
+ "H"
1197
+ ],
1198
+ "MM": [
1199
+ "hB",
1200
+ "hb",
1595
1201
  "H",
1596
- "hB"
1202
+ "h"
1597
1203
  ],
1598
- "GP": [
1204
+ "MN": [
1599
1205
  "H",
1206
+ "h",
1207
+ "hb",
1600
1208
  "hB"
1601
1209
  ],
1602
- "GW": [
1210
+ "MO": [
1211
+ "h",
1212
+ "hB",
1213
+ "hb",
1214
+ "H"
1215
+ ],
1216
+ "MP": [
1217
+ "h",
1218
+ "hb",
1603
1219
  "H",
1604
1220
  "hB"
1605
1221
  ],
1606
- "HR": [
1222
+ "MQ": [
1607
1223
  "H",
1608
1224
  "hB"
1609
1225
  ],
1610
- "IL": [
1611
- "H",
1612
- "hB"
1613
- ],
1614
- "IT": [
1615
- "H",
1616
- "hB"
1226
+ "MR": [
1227
+ "h",
1228
+ "hB",
1229
+ "hb",
1230
+ "H"
1617
1231
  ],
1618
- "KZ": [
1232
+ "MS": [
1619
1233
  "H",
1234
+ "h",
1235
+ "hb",
1620
1236
  "hB"
1621
1237
  ],
1622
- "MC": [
1238
+ "MW": [
1239
+ "h",
1240
+ "hb",
1623
1241
  "H",
1624
1242
  "hB"
1625
1243
  ],
1626
- "MD": [
1244
+ "MX": [
1627
1245
  "H",
1628
- "hB"
1246
+ "h",
1247
+ "hB",
1248
+ "hb"
1629
1249
  ],
1630
- "MF": [
1631
- "H",
1632
- "hB"
1250
+ "MY": [
1251
+ "hb",
1252
+ "hB",
1253
+ "h",
1254
+ "H"
1633
1255
  ],
1634
- "MQ": [
1256
+ "MZ": [
1635
1257
  "H",
1636
1258
  "hB"
1637
1259
  ],
1638
- "MZ": [
1260
+ "NA": [
1261
+ "h",
1639
1262
  "H",
1640
- "hB"
1263
+ "hB",
1264
+ "hb"
1641
1265
  ],
1642
1266
  "NC": [
1643
1267
  "H",
1644
1268
  "hB"
1645
1269
  ],
1646
- "NL": [
1647
- "H",
1648
- "hB"
1270
+ "NE": [
1271
+ "H"
1649
1272
  ],
1650
- "PM": [
1273
+ "NF": [
1651
1274
  "H",
1275
+ "h",
1276
+ "hb",
1652
1277
  "hB"
1653
1278
  ],
1654
- "PT": [
1279
+ "NG": [
1655
1280
  "H",
1281
+ "h",
1282
+ "hb",
1656
1283
  "hB"
1657
1284
  ],
1658
- "RE": [
1285
+ "NI": [
1659
1286
  "H",
1660
- "hB"
1287
+ "h",
1288
+ "hB",
1289
+ "hb"
1661
1290
  ],
1662
- "RO": [
1291
+ "NL": [
1663
1292
  "H",
1664
1293
  "hB"
1665
1294
  ],
1666
- "SI": [
1295
+ "NP": [
1667
1296
  "H",
1297
+ "h",
1668
1298
  "hB"
1669
1299
  ],
1670
- "SR": [
1300
+ "NR": [
1671
1301
  "H",
1302
+ "h",
1303
+ "hb",
1672
1304
  "hB"
1673
1305
  ],
1674
- "ST": [
1306
+ "NU": [
1675
1307
  "H",
1308
+ "h",
1309
+ "hb",
1676
1310
  "hB"
1677
1311
  ],
1678
- "TG": [
1312
+ "NZ": [
1313
+ "h",
1314
+ "hb",
1679
1315
  "H",
1680
1316
  "hB"
1681
1317
  ],
1682
- "TR": [
1318
+ "OM": [
1319
+ "h",
1320
+ "hB",
1321
+ "hb",
1322
+ "H"
1323
+ ],
1324
+ "PA": [
1325
+ "h",
1683
1326
  "H",
1684
- "hB"
1327
+ "hB",
1328
+ "hb"
1685
1329
  ],
1686
- "WF": [
1330
+ "PE": [
1687
1331
  "H",
1688
- "hB"
1332
+ "hB",
1333
+ "h",
1334
+ "hb"
1689
1335
  ],
1690
- "YT": [
1336
+ "PF": [
1691
1337
  "H",
1338
+ "h",
1692
1339
  "hB"
1693
1340
  ],
1694
- "BD": [
1341
+ "PG": [
1342
+ "h",
1343
+ "H"
1344
+ ],
1345
+ "PH": [
1695
1346
  "h",
1696
1347
  "hB",
1348
+ "hb",
1697
1349
  "H"
1698
1350
  ],
1699
1351
  "PK": [
@@ -1701,257 +1353,271 @@ var timeData = {
1701
1353
  "hB",
1702
1354
  "H"
1703
1355
  ],
1704
- "AZ": [
1356
+ "PM": [
1705
1357
  "H",
1706
- "hB",
1707
- "h"
1358
+ "hB"
1708
1359
  ],
1709
- "BA": [
1360
+ "PN": [
1710
1361
  "H",
1711
- "hB",
1712
- "h"
1362
+ "h",
1363
+ "hb",
1364
+ "hB"
1713
1365
  ],
1714
- "BG": [
1366
+ "PR": [
1367
+ "h",
1715
1368
  "H",
1716
1369
  "hB",
1717
- "h"
1370
+ "hb"
1718
1371
  ],
1719
- "CH": [
1720
- "H",
1372
+ "PS": [
1373
+ "h",
1721
1374
  "hB",
1722
- "h"
1375
+ "hb",
1376
+ "H"
1723
1377
  ],
1724
- "GE": [
1378
+ "PT": [
1725
1379
  "H",
1726
- "hB",
1727
- "h"
1380
+ "hB"
1728
1381
  ],
1729
- "LI": [
1730
- "H",
1731
- "hB",
1732
- "h"
1382
+ "PW": [
1383
+ "h",
1384
+ "H"
1733
1385
  ],
1734
- "ME": [
1386
+ "PY": [
1735
1387
  "H",
1388
+ "h",
1736
1389
  "hB",
1737
- "h"
1390
+ "hb"
1738
1391
  ],
1739
- "RS": [
1740
- "H",
1392
+ "QA": [
1393
+ "h",
1741
1394
  "hB",
1742
- "h"
1395
+ "hb",
1396
+ "H"
1743
1397
  ],
1744
- "UA": [
1398
+ "RE": [
1745
1399
  "H",
1746
- "hB",
1747
- "h"
1400
+ "hB"
1748
1401
  ],
1749
- "UZ": [
1402
+ "RO": [
1750
1403
  "H",
1751
- "hB",
1752
- "h"
1404
+ "hB"
1753
1405
  ],
1754
- "XK": [
1406
+ "RS": [
1755
1407
  "H",
1756
1408
  "hB",
1757
1409
  "h"
1758
1410
  ],
1759
- "AG": [
1411
+ "RU": [
1412
+ "H"
1413
+ ],
1414
+ "SA": [
1760
1415
  "h",
1416
+ "hB",
1761
1417
  "hb",
1762
- "H",
1763
- "hB"
1418
+ "H"
1764
1419
  ],
1765
- "AU": [
1420
+ "SB": [
1766
1421
  "h",
1767
1422
  "hb",
1768
1423
  "H",
1769
1424
  "hB"
1770
1425
  ],
1771
- "BB": [
1772
- "h",
1773
- "hb",
1426
+ "SC": [
1774
1427
  "H",
1428
+ "h",
1775
1429
  "hB"
1776
1430
  ],
1777
- "BM": [
1431
+ "SD": [
1778
1432
  "h",
1433
+ "hB",
1779
1434
  "hb",
1780
- "H",
1781
- "hB"
1435
+ "H"
1782
1436
  ],
1783
- "BS": [
1437
+ "SE": [
1438
+ "H"
1439
+ ],
1440
+ "SG": [
1784
1441
  "h",
1785
1442
  "hb",
1786
1443
  "H",
1787
1444
  "hB"
1788
1445
  ],
1789
- "CA": [
1446
+ "SH": [
1447
+ "H",
1790
1448
  "h",
1791
1449
  "hb",
1792
- "H",
1793
1450
  "hB"
1794
1451
  ],
1795
- "DM": [
1796
- "h",
1797
- "hb",
1452
+ "SI": [
1798
1453
  "H",
1799
1454
  "hB"
1800
1455
  ],
1801
- "en-001": [
1456
+ "SJ": [
1457
+ "H"
1458
+ ],
1459
+ "SK": [
1460
+ "H"
1461
+ ],
1462
+ "SL": [
1802
1463
  "h",
1803
1464
  "hb",
1804
1465
  "H",
1805
1466
  "hB"
1806
1467
  ],
1807
- "FJ": [
1808
- "h",
1809
- "hb",
1468
+ "SM": [
1810
1469
  "H",
1470
+ "h",
1811
1471
  "hB"
1812
1472
  ],
1813
- "FM": [
1814
- "h",
1815
- "hb",
1473
+ "SN": [
1816
1474
  "H",
1475
+ "h",
1817
1476
  "hB"
1818
1477
  ],
1819
- "GD": [
1478
+ "SO": [
1820
1479
  "h",
1821
- "hb",
1480
+ "H"
1481
+ ],
1482
+ "SR": [
1822
1483
  "H",
1823
1484
  "hB"
1824
1485
  ],
1825
- "GM": [
1486
+ "SS": [
1826
1487
  "h",
1827
1488
  "hb",
1828
1489
  "H",
1829
1490
  "hB"
1830
1491
  ],
1831
- "GU": [
1832
- "h",
1833
- "hb",
1492
+ "ST": [
1834
1493
  "H",
1835
1494
  "hB"
1836
1495
  ],
1837
- "GY": [
1838
- "h",
1839
- "hb",
1496
+ "SV": [
1840
1497
  "H",
1841
- "hB"
1498
+ "h",
1499
+ "hB",
1500
+ "hb"
1842
1501
  ],
1843
- "JM": [
1502
+ "SX": [
1503
+ "H",
1844
1504
  "h",
1845
1505
  "hb",
1846
- "H",
1847
1506
  "hB"
1848
1507
  ],
1849
- "KI": [
1508
+ "SY": [
1850
1509
  "h",
1510
+ "hB",
1851
1511
  "hb",
1852
- "H",
1853
- "hB"
1512
+ "H"
1854
1513
  ],
1855
- "KN": [
1514
+ "SZ": [
1856
1515
  "h",
1857
1516
  "hb",
1858
1517
  "H",
1859
1518
  "hB"
1860
1519
  ],
1861
- "KY": [
1520
+ "TA": [
1521
+ "H",
1862
1522
  "h",
1863
1523
  "hb",
1864
- "H",
1865
1524
  "hB"
1866
1525
  ],
1867
- "LC": [
1526
+ "TC": [
1868
1527
  "h",
1869
1528
  "hb",
1870
1529
  "H",
1871
1530
  "hB"
1872
1531
  ],
1873
- "LR": [
1532
+ "TD": [
1874
1533
  "h",
1875
- "hb",
1876
1534
  "H",
1877
1535
  "hB"
1878
1536
  ],
1879
- "MH": [
1880
- "h",
1881
- "hb",
1537
+ "TF": [
1882
1538
  "H",
1539
+ "h",
1883
1540
  "hB"
1884
1541
  ],
1885
- "MP": [
1886
- "h",
1887
- "hb",
1542
+ "TG": [
1888
1543
  "H",
1889
1544
  "hB"
1890
1545
  ],
1891
- "MW": [
1892
- "h",
1893
- "hb",
1546
+ "TL": [
1894
1547
  "H",
1895
- "hB"
1548
+ "hB",
1549
+ "hb",
1550
+ "h"
1896
1551
  ],
1897
- "NZ": [
1552
+ "TN": [
1898
1553
  "h",
1554
+ "hB",
1899
1555
  "hb",
1900
- "H",
1901
- "hB"
1556
+ "H"
1902
1557
  ],
1903
- "SB": [
1558
+ "TO": [
1904
1559
  "h",
1905
- "hb",
1560
+ "H"
1561
+ ],
1562
+ "TR": [
1906
1563
  "H",
1907
1564
  "hB"
1908
1565
  ],
1909
- "SG": [
1566
+ "TT": [
1910
1567
  "h",
1911
1568
  "hb",
1912
1569
  "H",
1913
1570
  "hB"
1914
1571
  ],
1915
- "SL": [
1572
+ "TW": [
1573
+ "hB",
1574
+ "hb",
1916
1575
  "h",
1576
+ "H"
1577
+ ],
1578
+ "TZ": [
1579
+ "hB",
1917
1580
  "hb",
1918
1581
  "H",
1919
- "hB"
1582
+ "h"
1920
1583
  ],
1921
- "SS": [
1922
- "h",
1923
- "hb",
1584
+ "UA": [
1924
1585
  "H",
1925
- "hB"
1586
+ "hB",
1587
+ "h"
1926
1588
  ],
1927
- "SZ": [
1928
- "h",
1589
+ "UG": [
1590
+ "hB",
1929
1591
  "hb",
1930
1592
  "H",
1931
- "hB"
1593
+ "h"
1932
1594
  ],
1933
- "TC": [
1595
+ "UM": [
1934
1596
  "h",
1935
1597
  "hb",
1936
1598
  "H",
1937
1599
  "hB"
1938
1600
  ],
1939
- "TT": [
1601
+ "US": [
1940
1602
  "h",
1941
1603
  "hb",
1942
1604
  "H",
1943
1605
  "hB"
1944
1606
  ],
1945
- "UM": [
1607
+ "UY": [
1608
+ "H",
1946
1609
  "h",
1947
- "hb",
1610
+ "hB",
1611
+ "hb"
1612
+ ],
1613
+ "UZ": [
1948
1614
  "H",
1949
- "hB"
1615
+ "hB",
1616
+ "h"
1950
1617
  ],
1951
- "US": [
1952
- "h",
1953
- "hb",
1618
+ "VA": [
1954
1619
  "H",
1620
+ "h",
1955
1621
  "hB"
1956
1622
  ],
1957
1623
  "VC": [
@@ -1960,332 +1626,190 @@ var timeData = {
1960
1626
  "H",
1961
1627
  "hB"
1962
1628
  ],
1963
- "VG": [
1629
+ "VE": [
1964
1630
  "h",
1965
- "hb",
1966
1631
  "H",
1967
- "hB"
1632
+ "hB",
1633
+ "hb"
1968
1634
  ],
1969
- "VI": [
1635
+ "VG": [
1970
1636
  "h",
1971
1637
  "hb",
1972
1638
  "H",
1973
1639
  "hB"
1974
1640
  ],
1975
- "ZM": [
1641
+ "VI": [
1976
1642
  "h",
1977
1643
  "hb",
1978
1644
  "H",
1979
1645
  "hB"
1980
1646
  ],
1981
- "BO": [
1982
- "H",
1983
- "hB",
1984
- "h",
1985
- "hb"
1986
- ],
1987
- "EC": [
1988
- "H",
1989
- "hB",
1647
+ "VU": [
1990
1648
  "h",
1991
- "hb"
1649
+ "H"
1992
1650
  ],
1993
- "ES": [
1651
+ "WF": [
1994
1652
  "H",
1995
- "hB",
1996
- "h",
1997
- "hb"
1653
+ "hB"
1998
1654
  ],
1999
- "GQ": [
2000
- "H",
2001
- "hB",
1655
+ "WS": [
2002
1656
  "h",
2003
- "hb"
1657
+ "H"
2004
1658
  ],
2005
- "PE": [
1659
+ "XK": [
2006
1660
  "H",
2007
1661
  "hB",
2008
- "h",
2009
- "hb"
1662
+ "h"
2010
1663
  ],
2011
- "AE": [
1664
+ "YE": [
2012
1665
  "h",
2013
1666
  "hB",
2014
1667
  "hb",
2015
1668
  "H"
2016
1669
  ],
2017
- "ar-001": [
1670
+ "YT": [
1671
+ "H",
1672
+ "hB"
1673
+ ],
1674
+ "ZA": [
1675
+ "H",
2018
1676
  "h",
2019
- "hB",
2020
1677
  "hb",
2021
- "H"
1678
+ "hB"
2022
1679
  ],
2023
- "BH": [
1680
+ "ZM": [
2024
1681
  "h",
2025
- "hB",
2026
1682
  "hb",
2027
- "H"
1683
+ "H",
1684
+ "hB"
2028
1685
  ],
2029
- "DZ": [
1686
+ "af-ZA": [
1687
+ "H",
2030
1688
  "h",
2031
1689
  "hB",
2032
- "hb",
2033
- "H"
1690
+ "hb"
2034
1691
  ],
2035
- "EG": [
1692
+ "ar-001": [
2036
1693
  "h",
2037
1694
  "hB",
2038
1695
  "hb",
2039
1696
  "H"
2040
1697
  ],
2041
- "EH": [
1698
+ "ca-ES": [
1699
+ "H",
2042
1700
  "h",
2043
- "hB",
2044
- "hb",
2045
- "H"
1701
+ "hB"
2046
1702
  ],
2047
- "HK": [
1703
+ "en-001": [
2048
1704
  "h",
2049
- "hB",
2050
1705
  "hb",
2051
- "H"
1706
+ "H",
1707
+ "hB"
2052
1708
  ],
2053
- "IQ": [
1709
+ "es-BO": [
1710
+ "H",
2054
1711
  "h",
2055
1712
  "hB",
2056
- "hb",
2057
- "H"
1713
+ "hb"
2058
1714
  ],
2059
- "JO": [
1715
+ "es-BR": [
1716
+ "H",
2060
1717
  "h",
2061
1718
  "hB",
2062
- "hb",
2063
- "H"
1719
+ "hb"
2064
1720
  ],
2065
- "KW": [
1721
+ "es-EC": [
1722
+ "H",
2066
1723
  "h",
2067
1724
  "hB",
2068
- "hb",
2069
- "H"
1725
+ "hb"
2070
1726
  ],
2071
- "LB": [
1727
+ "es-ES": [
1728
+ "H",
2072
1729
  "h",
2073
1730
  "hB",
2074
- "hb",
2075
- "H"
1731
+ "hb"
2076
1732
  ],
2077
- "LY": [
1733
+ "es-GQ": [
1734
+ "H",
2078
1735
  "h",
2079
1736
  "hB",
2080
- "hb",
2081
- "H"
1737
+ "hb"
2082
1738
  ],
2083
- "MO": [
1739
+ "es-PE": [
1740
+ "H",
2084
1741
  "h",
2085
1742
  "hB",
2086
- "hb",
2087
- "H"
1743
+ "hb"
2088
1744
  ],
2089
- "MR": [
1745
+ "fr-CA": [
1746
+ "H",
2090
1747
  "h",
2091
- "hB",
2092
- "hb",
2093
- "H"
1748
+ "hB"
2094
1749
  ],
2095
- "OM": [
1750
+ "gl-ES": [
1751
+ "H",
2096
1752
  "h",
1753
+ "hB"
1754
+ ],
1755
+ "gu-IN": [
2097
1756
  "hB",
2098
1757
  "hb",
1758
+ "h",
2099
1759
  "H"
2100
1760
  ],
2101
- "PH": [
2102
- "h",
1761
+ "hi-IN": [
2103
1762
  "hB",
2104
- "hb",
1763
+ "h",
2105
1764
  "H"
2106
1765
  ],
2107
- "PS": [
1766
+ "it-CH": [
1767
+ "H",
2108
1768
  "h",
2109
- "hB",
2110
- "hb",
2111
- "H"
1769
+ "hB"
2112
1770
  ],
2113
- "QA": [
1771
+ "it-IT": [
1772
+ "H",
2114
1773
  "h",
1774
+ "hB"
1775
+ ],
1776
+ "kn-IN": [
2115
1777
  "hB",
2116
- "hb",
1778
+ "h",
2117
1779
  "H"
2118
1780
  ],
2119
- "SA": [
2120
- "h",
1781
+ "ml-IN": [
2121
1782
  "hB",
2122
- "hb",
1783
+ "h",
2123
1784
  "H"
2124
1785
  ],
2125
- "SD": [
2126
- "h",
1786
+ "mr-IN": [
2127
1787
  "hB",
2128
1788
  "hb",
1789
+ "h",
2129
1790
  "H"
2130
1791
  ],
2131
- "SY": [
2132
- "h",
1792
+ "pa-IN": [
2133
1793
  "hB",
2134
1794
  "hb",
1795
+ "h",
2135
1796
  "H"
2136
1797
  ],
2137
- "TN": [
2138
- "h",
1798
+ "ta-IN": [
2139
1799
  "hB",
1800
+ "h",
2140
1801
  "hb",
2141
1802
  "H"
2142
1803
  ],
2143
- "YE": [
2144
- "h",
1804
+ "te-IN": [
2145
1805
  "hB",
2146
- "hb",
1806
+ "h",
2147
1807
  "H"
2148
1808
  ],
2149
- "AF": [
1809
+ "zu-ZA": [
2150
1810
  "H",
2151
- "hb",
2152
1811
  "hB",
2153
- "h"
2154
- ],
2155
- "LA": [
2156
- "H",
2157
1812
  "hb",
2158
- "hB",
2159
- "h"
2160
- ],
2161
- "CN": [
2162
- "H",
2163
- "hB",
2164
- "hb",
2165
- "h"
2166
- ],
2167
- "LV": [
2168
- "H",
2169
- "hB",
2170
- "hb",
2171
- "h"
2172
- ],
2173
- "TL": [
2174
- "H",
2175
- "hB",
2176
- "hb",
2177
- "h"
2178
- ],
2179
- "zu-ZA": [
2180
- "H",
2181
- "hB",
2182
- "hb",
2183
- "h"
2184
- ],
2185
- "CD": [
2186
- "hB",
2187
- "H"
2188
- ],
2189
- "IR": [
2190
- "hB",
2191
- "H"
2192
- ],
2193
- "hi-IN": [
2194
- "hB",
2195
- "h",
2196
- "H"
2197
- ],
2198
- "kn-IN": [
2199
- "hB",
2200
- "h",
2201
- "H"
2202
- ],
2203
- "ml-IN": [
2204
- "hB",
2205
- "h",
2206
- "H"
2207
- ],
2208
- "te-IN": [
2209
- "hB",
2210
- "h",
2211
- "H"
2212
- ],
2213
- "KH": [
2214
- "hB",
2215
- "h",
2216
- "H",
2217
- "hb"
2218
- ],
2219
- "ta-IN": [
2220
- "hB",
2221
- "h",
2222
- "hb",
2223
- "H"
2224
- ],
2225
- "BN": [
2226
- "hb",
2227
- "hB",
2228
- "h",
2229
- "H"
2230
- ],
2231
- "MY": [
2232
- "hb",
2233
- "hB",
2234
- "h",
2235
- "H"
2236
- ],
2237
- "ET": [
2238
- "hB",
2239
- "hb",
2240
- "h",
2241
- "H"
2242
- ],
2243
- "gu-IN": [
2244
- "hB",
2245
- "hb",
2246
- "h",
2247
- "H"
2248
- ],
2249
- "mr-IN": [
2250
- "hB",
2251
- "hb",
2252
- "h",
2253
- "H"
2254
- ],
2255
- "pa-IN": [
2256
- "hB",
2257
- "hb",
2258
- "h",
2259
- "H"
2260
- ],
2261
- "TW": [
2262
- "hB",
2263
- "hb",
2264
- "h",
2265
- "H"
2266
- ],
2267
- "KE": [
2268
- "hB",
2269
- "hb",
2270
- "H",
2271
- "h"
2272
- ],
2273
- "MM": [
2274
- "hB",
2275
- "hb",
2276
- "H",
2277
- "h"
2278
- ],
2279
- "TZ": [
2280
- "hB",
2281
- "hb",
2282
- "H",
2283
- "h"
2284
- ],
2285
- "UG": [
2286
- "hB",
2287
- "hb",
2288
- "H",
2289
1813
  "h"
2290
1814
  ]
2291
1815
  };
@@ -2324,7 +1848,9 @@ function getBestPattern(skeleton, locale) {
2324
1848
  }
2325
1849
  function getDefaultHourSymbolFromLocale(locale) {
2326
1850
  var hourCycle = locale.hourCycle;
2327
- if (hourCycle === void 0 && locale.hourCycles && locale.hourCycles.length) {
1851
+ if (hourCycle === void 0 && // @ts-ignore hourCycle(s) is not identified yet
1852
+ locale.hourCycles && // @ts-ignore
1853
+ locale.hourCycles.length) {
2328
1854
  hourCycle = locale.hourCycles[0];
2329
1855
  }
2330
1856
  if (hourCycle) {
@@ -2375,57 +1901,90 @@ try {
2375
1901
  REGEX_SUPPORTS_U_AND_Y = false;
2376
1902
  }
2377
1903
  var re;
2378
- var startsWith = hasNativeStartsWith ? function startsWith2(s, search, position) {
2379
- return s.startsWith(search, position);
2380
- } : function startsWith3(s, search, position) {
2381
- return s.slice(position, position + search.length) === search;
2382
- };
2383
- var fromCodePoint = hasNativeFromCodePoint ? String.fromCodePoint : function fromCodePoint2() {
2384
- var codePoints = [];
2385
- for (var _i = 0; _i < arguments.length; _i++) {
2386
- codePoints[_i] = arguments[_i];
1904
+ var startsWith = hasNativeStartsWith ? (
1905
+ // Native
1906
+ function startsWith2(s, search, position) {
1907
+ return s.startsWith(search, position);
2387
1908
  }
2388
- var elements = "";
2389
- var length = codePoints.length;
2390
- var i = 0;
2391
- var code;
2392
- while (length > i) {
2393
- code = codePoints[i++];
2394
- if (code > 1114111)
2395
- throw RangeError(code + " is not a valid code point");
2396
- elements += code < 65536 ? String.fromCharCode(code) : String.fromCharCode(((code -= 65536) >> 10) + 55296, code % 1024 + 56320);
1909
+ ) : (
1910
+ // For IE11
1911
+ function startsWith3(s, search, position) {
1912
+ return s.slice(position, position + search.length) === search;
2397
1913
  }
2398
- return elements;
2399
- };
2400
- var fromEntries = hasNativeFromEntries ? Object.fromEntries : function fromEntries2(entries) {
2401
- var obj = {};
2402
- for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) {
2403
- var _a2 = entries_1[_i], k = _a2[0], v = _a2[1];
2404
- obj[k] = v;
1914
+ );
1915
+ var fromCodePoint = hasNativeFromCodePoint ? String.fromCodePoint : (
1916
+ // IE11
1917
+ function fromCodePoint2() {
1918
+ var codePoints = [];
1919
+ for (var _i = 0; _i < arguments.length; _i++) {
1920
+ codePoints[_i] = arguments[_i];
1921
+ }
1922
+ var elements = "";
1923
+ var length = codePoints.length;
1924
+ var i = 0;
1925
+ var code;
1926
+ while (length > i) {
1927
+ code = codePoints[i++];
1928
+ if (code > 1114111)
1929
+ throw RangeError(code + " is not a valid code point");
1930
+ elements += code < 65536 ? String.fromCharCode(code) : String.fromCharCode(((code -= 65536) >> 10) + 55296, code % 1024 + 56320);
1931
+ }
1932
+ return elements;
2405
1933
  }
2406
- return obj;
2407
- };
2408
- var codePointAt = hasNativeCodePointAt ? function codePointAt2(s, index) {
2409
- return s.codePointAt(index);
2410
- } : function codePointAt3(s, index) {
2411
- var size = s.length;
2412
- if (index < 0 || index >= size) {
2413
- return void 0;
1934
+ );
1935
+ var fromEntries = (
1936
+ // native
1937
+ hasNativeFromEntries ? Object.fromEntries : (
1938
+ // Ponyfill
1939
+ function fromEntries2(entries) {
1940
+ var obj = {};
1941
+ for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) {
1942
+ var _a2 = entries_1[_i], k = _a2[0], v = _a2[1];
1943
+ obj[k] = v;
1944
+ }
1945
+ return obj;
1946
+ }
1947
+ )
1948
+ );
1949
+ var codePointAt = hasNativeCodePointAt ? (
1950
+ // Native
1951
+ function codePointAt2(s, index) {
1952
+ return s.codePointAt(index);
2414
1953
  }
2415
- var first = s.charCodeAt(index);
2416
- var second;
2417
- return first < 55296 || first > 56319 || index + 1 === size || (second = s.charCodeAt(index + 1)) < 56320 || second > 57343 ? first : (first - 55296 << 10) + (second - 56320) + 65536;
2418
- };
2419
- var trimStart = hasTrimStart ? function trimStart2(s) {
2420
- return s.trimStart();
2421
- } : function trimStart3(s) {
2422
- return s.replace(SPACE_SEPARATOR_START_REGEX, "");
2423
- };
2424
- var trimEnd = hasTrimEnd ? function trimEnd2(s) {
2425
- return s.trimEnd();
2426
- } : function trimEnd3(s) {
2427
- return s.replace(SPACE_SEPARATOR_END_REGEX, "");
2428
- };
1954
+ ) : (
1955
+ // IE 11
1956
+ function codePointAt3(s, index) {
1957
+ var size = s.length;
1958
+ if (index < 0 || index >= size) {
1959
+ return void 0;
1960
+ }
1961
+ var first = s.charCodeAt(index);
1962
+ var second;
1963
+ return first < 55296 || first > 56319 || index + 1 === size || (second = s.charCodeAt(index + 1)) < 56320 || second > 57343 ? first : (first - 55296 << 10) + (second - 56320) + 65536;
1964
+ }
1965
+ );
1966
+ var trimStart = hasTrimStart ? (
1967
+ // Native
1968
+ function trimStart2(s) {
1969
+ return s.trimStart();
1970
+ }
1971
+ ) : (
1972
+ // Ponyfill
1973
+ function trimStart3(s) {
1974
+ return s.replace(SPACE_SEPARATOR_START_REGEX, "");
1975
+ }
1976
+ );
1977
+ var trimEnd = hasTrimEnd ? (
1978
+ // Native
1979
+ function trimEnd2(s) {
1980
+ return s.trimEnd();
1981
+ }
1982
+ ) : (
1983
+ // Ponyfill
1984
+ function trimEnd3(s) {
1985
+ return s.replace(SPACE_SEPARATOR_END_REGEX, "");
1986
+ }
1987
+ );
2429
1988
  function RE(s, flag) {
2430
1989
  return new RegExp(s, flag);
2431
1990
  }
@@ -2453,654 +2012,659 @@ if (REGEX_SUPPORTS_U_AND_Y) {
2453
2012
  };
2454
2013
  }
2455
2014
  var IDENTIFIER_PREFIX_RE_1;
2456
- var Parser = function() {
2457
- function Parser2(message, options) {
2458
- if (options === void 0) {
2459
- options = {};
2460
- }
2461
- this.message = message;
2462
- this.position = { offset: 0, line: 1, column: 1 };
2463
- this.ignoreTag = !!options.ignoreTag;
2464
- this.locale = options.locale;
2465
- this.requiresOtherClause = !!options.requiresOtherClause;
2466
- this.shouldParseSkeletons = !!options.shouldParseSkeletons;
2467
- }
2468
- Parser2.prototype.parse = function() {
2469
- if (this.offset() !== 0) {
2470
- throw Error("parser can only be used once");
2471
- }
2472
- return this.parseMessage(0, "", false);
2473
- };
2474
- Parser2.prototype.parseMessage = function(nestingLevel, parentArgType, expectingCloseTag) {
2475
- var elements = [];
2476
- while (!this.isEOF()) {
2477
- var char = this.char();
2478
- if (char === 123) {
2479
- var result = this.parseArgument(nestingLevel, expectingCloseTag);
2480
- if (result.err) {
2481
- return result;
2482
- }
2483
- elements.push(result.val);
2484
- } else if (char === 125 && nestingLevel > 0) {
2485
- break;
2486
- } else if (char === 35 && (parentArgType === "plural" || parentArgType === "selectordinal")) {
2487
- var position = this.clonePosition();
2488
- this.bump();
2489
- elements.push({
2490
- type: TYPE.pound,
2491
- location: createLocation(position, this.clonePosition())
2492
- });
2493
- } else if (char === 60 && !this.ignoreTag && this.peek() === 47) {
2494
- if (expectingCloseTag) {
2015
+ var Parser = (
2016
+ /** @class */
2017
+ function() {
2018
+ function Parser2(message, options) {
2019
+ if (options === void 0) {
2020
+ options = {};
2021
+ }
2022
+ this.message = message;
2023
+ this.position = { offset: 0, line: 1, column: 1 };
2024
+ this.ignoreTag = !!options.ignoreTag;
2025
+ this.locale = options.locale;
2026
+ this.requiresOtherClause = !!options.requiresOtherClause;
2027
+ this.shouldParseSkeletons = !!options.shouldParseSkeletons;
2028
+ }
2029
+ Parser2.prototype.parse = function() {
2030
+ if (this.offset() !== 0) {
2031
+ throw Error("parser can only be used once");
2032
+ }
2033
+ return this.parseMessage(0, "", false);
2034
+ };
2035
+ Parser2.prototype.parseMessage = function(nestingLevel, parentArgType, expectingCloseTag) {
2036
+ var elements = [];
2037
+ while (!this.isEOF()) {
2038
+ var char = this.char();
2039
+ if (char === 123) {
2040
+ var result = this.parseArgument(nestingLevel, expectingCloseTag);
2041
+ if (result.err) {
2042
+ return result;
2043
+ }
2044
+ elements.push(result.val);
2045
+ } else if (char === 125 && nestingLevel > 0) {
2495
2046
  break;
2047
+ } else if (char === 35 && (parentArgType === "plural" || parentArgType === "selectordinal")) {
2048
+ var position = this.clonePosition();
2049
+ this.bump();
2050
+ elements.push({
2051
+ type: TYPE.pound,
2052
+ location: createLocation(position, this.clonePosition())
2053
+ });
2054
+ } else if (char === 60 && !this.ignoreTag && this.peek() === 47) {
2055
+ if (expectingCloseTag) {
2056
+ break;
2057
+ } else {
2058
+ return this.error(ErrorKind.UNMATCHED_CLOSING_TAG, createLocation(this.clonePosition(), this.clonePosition()));
2059
+ }
2060
+ } else if (char === 60 && !this.ignoreTag && _isAlpha(this.peek() || 0)) {
2061
+ var result = this.parseTag(nestingLevel, parentArgType);
2062
+ if (result.err) {
2063
+ return result;
2064
+ }
2065
+ elements.push(result.val);
2496
2066
  } else {
2497
- return this.error(ErrorKind.UNMATCHED_CLOSING_TAG, createLocation(this.clonePosition(), this.clonePosition()));
2498
- }
2499
- } else if (char === 60 && !this.ignoreTag && _isAlpha(this.peek() || 0)) {
2500
- var result = this.parseTag(nestingLevel, parentArgType);
2501
- if (result.err) {
2502
- return result;
2503
- }
2504
- elements.push(result.val);
2505
- } else {
2506
- var result = this.parseLiteral(nestingLevel, parentArgType);
2507
- if (result.err) {
2508
- return result;
2067
+ var result = this.parseLiteral(nestingLevel, parentArgType);
2068
+ if (result.err) {
2069
+ return result;
2070
+ }
2071
+ elements.push(result.val);
2509
2072
  }
2510
- elements.push(result.val);
2511
- }
2512
- }
2513
- return { val: elements, err: null };
2514
- };
2515
- Parser2.prototype.parseTag = function(nestingLevel, parentArgType) {
2516
- var startPosition = this.clonePosition();
2517
- this.bump();
2518
- var tagName = this.parseTagName();
2519
- this.bumpSpace();
2520
- if (this.bumpIf("/>")) {
2521
- return {
2522
- val: {
2523
- type: TYPE.literal,
2524
- value: "<".concat(tagName, "/>"),
2525
- location: createLocation(startPosition, this.clonePosition())
2526
- },
2527
- err: null
2528
- };
2529
- } else if (this.bumpIf(">")) {
2530
- var childrenResult = this.parseMessage(nestingLevel + 1, parentArgType, true);
2531
- if (childrenResult.err) {
2532
- return childrenResult;
2533
2073
  }
2534
- var children = childrenResult.val;
2535
- var endTagStartPosition = this.clonePosition();
2536
- if (this.bumpIf("</")) {
2537
- if (this.isEOF() || !_isAlpha(this.char())) {
2538
- return this.error(ErrorKind.INVALID_TAG, createLocation(endTagStartPosition, this.clonePosition()));
2539
- }
2540
- var closingTagNameStartPosition = this.clonePosition();
2541
- var closingTagName = this.parseTagName();
2542
- if (tagName !== closingTagName) {
2543
- return this.error(ErrorKind.UNMATCHED_CLOSING_TAG, createLocation(closingTagNameStartPosition, this.clonePosition()));
2544
- }
2545
- this.bumpSpace();
2546
- if (!this.bumpIf(">")) {
2547
- return this.error(ErrorKind.INVALID_TAG, createLocation(endTagStartPosition, this.clonePosition()));
2548
- }
2074
+ return { val: elements, err: null };
2075
+ };
2076
+ Parser2.prototype.parseTag = function(nestingLevel, parentArgType) {
2077
+ var startPosition = this.clonePosition();
2078
+ this.bump();
2079
+ var tagName = this.parseTagName();
2080
+ this.bumpSpace();
2081
+ if (this.bumpIf("/>")) {
2549
2082
  return {
2550
2083
  val: {
2551
- type: TYPE.tag,
2552
- value: tagName,
2553
- children,
2084
+ type: TYPE.literal,
2085
+ value: "<".concat(tagName, "/>"),
2554
2086
  location: createLocation(startPosition, this.clonePosition())
2555
2087
  },
2556
2088
  err: null
2557
2089
  };
2090
+ } else if (this.bumpIf(">")) {
2091
+ var childrenResult = this.parseMessage(nestingLevel + 1, parentArgType, true);
2092
+ if (childrenResult.err) {
2093
+ return childrenResult;
2094
+ }
2095
+ var children = childrenResult.val;
2096
+ var endTagStartPosition = this.clonePosition();
2097
+ if (this.bumpIf("</")) {
2098
+ if (this.isEOF() || !_isAlpha(this.char())) {
2099
+ return this.error(ErrorKind.INVALID_TAG, createLocation(endTagStartPosition, this.clonePosition()));
2100
+ }
2101
+ var closingTagNameStartPosition = this.clonePosition();
2102
+ var closingTagName = this.parseTagName();
2103
+ if (tagName !== closingTagName) {
2104
+ return this.error(ErrorKind.UNMATCHED_CLOSING_TAG, createLocation(closingTagNameStartPosition, this.clonePosition()));
2105
+ }
2106
+ this.bumpSpace();
2107
+ if (!this.bumpIf(">")) {
2108
+ return this.error(ErrorKind.INVALID_TAG, createLocation(endTagStartPosition, this.clonePosition()));
2109
+ }
2110
+ return {
2111
+ val: {
2112
+ type: TYPE.tag,
2113
+ value: tagName,
2114
+ children,
2115
+ location: createLocation(startPosition, this.clonePosition())
2116
+ },
2117
+ err: null
2118
+ };
2119
+ } else {
2120
+ return this.error(ErrorKind.UNCLOSED_TAG, createLocation(startPosition, this.clonePosition()));
2121
+ }
2558
2122
  } else {
2559
- return this.error(ErrorKind.UNCLOSED_TAG, createLocation(startPosition, this.clonePosition()));
2123
+ return this.error(ErrorKind.INVALID_TAG, createLocation(startPosition, this.clonePosition()));
2560
2124
  }
2561
- } else {
2562
- return this.error(ErrorKind.INVALID_TAG, createLocation(startPosition, this.clonePosition()));
2563
- }
2564
- };
2565
- Parser2.prototype.parseTagName = function() {
2566
- var startOffset = this.offset();
2567
- this.bump();
2568
- while (!this.isEOF() && _isPotentialElementNameChar(this.char())) {
2125
+ };
2126
+ Parser2.prototype.parseTagName = function() {
2127
+ var startOffset = this.offset();
2569
2128
  this.bump();
2570
- }
2571
- return this.message.slice(startOffset, this.offset());
2572
- };
2573
- Parser2.prototype.parseLiteral = function(nestingLevel, parentArgType) {
2574
- var start = this.clonePosition();
2575
- var value = "";
2576
- while (true) {
2577
- var parseQuoteResult = this.tryParseQuote(parentArgType);
2578
- if (parseQuoteResult) {
2579
- value += parseQuoteResult;
2580
- continue;
2581
- }
2582
- var parseUnquotedResult = this.tryParseUnquoted(nestingLevel, parentArgType);
2583
- if (parseUnquotedResult) {
2584
- value += parseUnquotedResult;
2585
- continue;
2129
+ while (!this.isEOF() && _isPotentialElementNameChar(this.char())) {
2130
+ this.bump();
2586
2131
  }
2587
- var parseLeftAngleResult = this.tryParseLeftAngleBracket();
2588
- if (parseLeftAngleResult) {
2589
- value += parseLeftAngleResult;
2590
- continue;
2132
+ return this.message.slice(startOffset, this.offset());
2133
+ };
2134
+ Parser2.prototype.parseLiteral = function(nestingLevel, parentArgType) {
2135
+ var start = this.clonePosition();
2136
+ var value = "";
2137
+ while (true) {
2138
+ var parseQuoteResult = this.tryParseQuote(parentArgType);
2139
+ if (parseQuoteResult) {
2140
+ value += parseQuoteResult;
2141
+ continue;
2142
+ }
2143
+ var parseUnquotedResult = this.tryParseUnquoted(nestingLevel, parentArgType);
2144
+ if (parseUnquotedResult) {
2145
+ value += parseUnquotedResult;
2146
+ continue;
2147
+ }
2148
+ var parseLeftAngleResult = this.tryParseLeftAngleBracket();
2149
+ if (parseLeftAngleResult) {
2150
+ value += parseLeftAngleResult;
2151
+ continue;
2152
+ }
2153
+ break;
2591
2154
  }
2592
- break;
2593
- }
2594
- var location = createLocation(start, this.clonePosition());
2595
- return {
2596
- val: { type: TYPE.literal, value, location },
2597
- err: null
2155
+ var location = createLocation(start, this.clonePosition());
2156
+ return {
2157
+ val: { type: TYPE.literal, value, location },
2158
+ err: null
2159
+ };
2598
2160
  };
2599
- };
2600
- Parser2.prototype.tryParseLeftAngleBracket = function() {
2601
- if (!this.isEOF() && this.char() === 60 && (this.ignoreTag || !_isAlphaOrSlash(this.peek() || 0))) {
2602
- this.bump();
2603
- return "<";
2604
- }
2605
- return null;
2606
- };
2607
- Parser2.prototype.tryParseQuote = function(parentArgType) {
2608
- if (this.isEOF() || this.char() !== 39) {
2609
- return null;
2610
- }
2611
- switch (this.peek()) {
2612
- case 39:
2613
- this.bump();
2161
+ Parser2.prototype.tryParseLeftAngleBracket = function() {
2162
+ if (!this.isEOF() && this.char() === 60 && (this.ignoreTag || // If at the opening tag or closing tag position, bail.
2163
+ !_isAlphaOrSlash(this.peek() || 0))) {
2614
2164
  this.bump();
2615
- return "'";
2616
- case 123:
2617
- case 60:
2618
- case 62:
2619
- case 125:
2620
- break;
2621
- case 35:
2622
- if (parentArgType === "plural" || parentArgType === "selectordinal") {
2623
- break;
2624
- }
2625
- return null;
2626
- default:
2165
+ return "<";
2166
+ }
2167
+ return null;
2168
+ };
2169
+ Parser2.prototype.tryParseQuote = function(parentArgType) {
2170
+ if (this.isEOF() || this.char() !== 39) {
2627
2171
  return null;
2628
- }
2629
- this.bump();
2630
- var codePoints = [this.char()];
2631
- this.bump();
2632
- while (!this.isEOF()) {
2633
- var ch = this.char();
2634
- if (ch === 39) {
2635
- if (this.peek() === 39) {
2636
- codePoints.push(39);
2172
+ }
2173
+ switch (this.peek()) {
2174
+ case 39:
2637
2175
  this.bump();
2638
- } else {
2639
2176
  this.bump();
2177
+ return "'";
2178
+ case 123:
2179
+ case 60:
2180
+ case 62:
2181
+ case 125:
2640
2182
  break;
2183
+ case 35:
2184
+ if (parentArgType === "plural" || parentArgType === "selectordinal") {
2185
+ break;
2186
+ }
2187
+ return null;
2188
+ default:
2189
+ return null;
2190
+ }
2191
+ this.bump();
2192
+ var codePoints = [this.char()];
2193
+ this.bump();
2194
+ while (!this.isEOF()) {
2195
+ var ch = this.char();
2196
+ if (ch === 39) {
2197
+ if (this.peek() === 39) {
2198
+ codePoints.push(39);
2199
+ this.bump();
2200
+ } else {
2201
+ this.bump();
2202
+ break;
2203
+ }
2204
+ } else {
2205
+ codePoints.push(ch);
2641
2206
  }
2207
+ this.bump();
2208
+ }
2209
+ return fromCodePoint.apply(void 0, codePoints);
2210
+ };
2211
+ Parser2.prototype.tryParseUnquoted = function(nestingLevel, parentArgType) {
2212
+ if (this.isEOF()) {
2213
+ return null;
2214
+ }
2215
+ var ch = this.char();
2216
+ if (ch === 60 || ch === 123 || ch === 35 && (parentArgType === "plural" || parentArgType === "selectordinal") || ch === 125 && nestingLevel > 0) {
2217
+ return null;
2642
2218
  } else {
2643
- codePoints.push(ch);
2219
+ this.bump();
2220
+ return fromCodePoint(ch);
2644
2221
  }
2222
+ };
2223
+ Parser2.prototype.parseArgument = function(nestingLevel, expectingCloseTag) {
2224
+ var openingBracePosition = this.clonePosition();
2645
2225
  this.bump();
2646
- }
2647
- return fromCodePoint.apply(void 0, codePoints);
2648
- };
2649
- Parser2.prototype.tryParseUnquoted = function(nestingLevel, parentArgType) {
2650
- if (this.isEOF()) {
2651
- return null;
2652
- }
2653
- var ch = this.char();
2654
- if (ch === 60 || ch === 123 || ch === 35 && (parentArgType === "plural" || parentArgType === "selectordinal") || ch === 125 && nestingLevel > 0) {
2655
- return null;
2656
- } else {
2657
- this.bump();
2658
- return fromCodePoint(ch);
2659
- }
2660
- };
2661
- Parser2.prototype.parseArgument = function(nestingLevel, expectingCloseTag) {
2662
- var openingBracePosition = this.clonePosition();
2663
- this.bump();
2664
- this.bumpSpace();
2665
- if (this.isEOF()) {
2666
- return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2667
- }
2668
- if (this.char() === 125) {
2669
- this.bump();
2670
- return this.error(ErrorKind.EMPTY_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
2671
- }
2672
- var value = this.parseIdentifierIfPossible().value;
2673
- if (!value) {
2674
- return this.error(ErrorKind.MALFORMED_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
2675
- }
2676
- this.bumpSpace();
2677
- if (this.isEOF()) {
2678
- return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2679
- }
2680
- switch (this.char()) {
2681
- case 125: {
2682
- this.bump();
2683
- return {
2684
- val: {
2685
- type: TYPE.argument,
2686
- value,
2687
- location: createLocation(openingBracePosition, this.clonePosition())
2688
- },
2689
- err: null
2690
- };
2226
+ this.bumpSpace();
2227
+ if (this.isEOF()) {
2228
+ return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2691
2229
  }
2692
- case 44: {
2230
+ if (this.char() === 125) {
2693
2231
  this.bump();
2694
- this.bumpSpace();
2695
- if (this.isEOF()) {
2696
- return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2697
- }
2698
- return this.parseArgumentOptions(nestingLevel, expectingCloseTag, value, openingBracePosition);
2232
+ return this.error(ErrorKind.EMPTY_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
2699
2233
  }
2700
- default:
2234
+ var value = this.parseIdentifierIfPossible().value;
2235
+ if (!value) {
2701
2236
  return this.error(ErrorKind.MALFORMED_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
2702
- }
2703
- };
2704
- Parser2.prototype.parseIdentifierIfPossible = function() {
2705
- var startingPosition = this.clonePosition();
2706
- var startOffset = this.offset();
2707
- var value = matchIdentifierAtIndex(this.message, startOffset);
2708
- var endOffset = startOffset + value.length;
2709
- this.bumpTo(endOffset);
2710
- var endPosition = this.clonePosition();
2711
- var location = createLocation(startingPosition, endPosition);
2712
- return { value, location };
2713
- };
2714
- Parser2.prototype.parseArgumentOptions = function(nestingLevel, expectingCloseTag, value, openingBracePosition) {
2715
- var _a2;
2716
- var typeStartPosition = this.clonePosition();
2717
- var argType = this.parseIdentifierIfPossible().value;
2718
- var typeEndPosition = this.clonePosition();
2719
- switch (argType) {
2720
- case "":
2721
- return this.error(ErrorKind.EXPECT_ARGUMENT_TYPE, createLocation(typeStartPosition, typeEndPosition));
2722
- case "number":
2723
- case "date":
2724
- case "time": {
2725
- this.bumpSpace();
2726
- var styleAndLocation = null;
2727
- if (this.bumpIf(",")) {
2237
+ }
2238
+ this.bumpSpace();
2239
+ if (this.isEOF()) {
2240
+ return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2241
+ }
2242
+ switch (this.char()) {
2243
+ case 125: {
2244
+ this.bump();
2245
+ return {
2246
+ val: {
2247
+ type: TYPE.argument,
2248
+ // value does not include the opening and closing braces.
2249
+ value,
2250
+ location: createLocation(openingBracePosition, this.clonePosition())
2251
+ },
2252
+ err: null
2253
+ };
2254
+ }
2255
+ case 44: {
2256
+ this.bump();
2728
2257
  this.bumpSpace();
2729
- var styleStartPosition = this.clonePosition();
2730
- var result = this.parseSimpleArgStyleIfPossible();
2731
- if (result.err) {
2732
- return result;
2258
+ if (this.isEOF()) {
2259
+ return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2733
2260
  }
2734
- var style = trimEnd(result.val);
2735
- if (style.length === 0) {
2736
- return this.error(ErrorKind.EXPECT_ARGUMENT_STYLE, createLocation(this.clonePosition(), this.clonePosition()));
2737
- }
2738
- var styleLocation = createLocation(styleStartPosition, this.clonePosition());
2739
- styleAndLocation = { style, styleLocation };
2740
- }
2741
- var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2742
- if (argCloseResult.err) {
2743
- return argCloseResult;
2261
+ return this.parseArgumentOptions(nestingLevel, expectingCloseTag, value, openingBracePosition);
2744
2262
  }
2745
- var location_1 = createLocation(openingBracePosition, this.clonePosition());
2746
- if (styleAndLocation && startsWith(styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style, "::", 0)) {
2747
- var skeleton = trimStart(styleAndLocation.style.slice(2));
2748
- if (argType === "number") {
2749
- var result = this.parseNumberSkeletonFromString(skeleton, styleAndLocation.styleLocation);
2263
+ default:
2264
+ return this.error(ErrorKind.MALFORMED_ARGUMENT, createLocation(openingBracePosition, this.clonePosition()));
2265
+ }
2266
+ };
2267
+ Parser2.prototype.parseIdentifierIfPossible = function() {
2268
+ var startingPosition = this.clonePosition();
2269
+ var startOffset = this.offset();
2270
+ var value = matchIdentifierAtIndex(this.message, startOffset);
2271
+ var endOffset = startOffset + value.length;
2272
+ this.bumpTo(endOffset);
2273
+ var endPosition = this.clonePosition();
2274
+ var location = createLocation(startingPosition, endPosition);
2275
+ return { value, location };
2276
+ };
2277
+ Parser2.prototype.parseArgumentOptions = function(nestingLevel, expectingCloseTag, value, openingBracePosition) {
2278
+ var _a2;
2279
+ var typeStartPosition = this.clonePosition();
2280
+ var argType = this.parseIdentifierIfPossible().value;
2281
+ var typeEndPosition = this.clonePosition();
2282
+ switch (argType) {
2283
+ case "":
2284
+ return this.error(ErrorKind.EXPECT_ARGUMENT_TYPE, createLocation(typeStartPosition, typeEndPosition));
2285
+ case "number":
2286
+ case "date":
2287
+ case "time": {
2288
+ this.bumpSpace();
2289
+ var styleAndLocation = null;
2290
+ if (this.bumpIf(",")) {
2291
+ this.bumpSpace();
2292
+ var styleStartPosition = this.clonePosition();
2293
+ var result = this.parseSimpleArgStyleIfPossible();
2750
2294
  if (result.err) {
2751
2295
  return result;
2752
2296
  }
2753
- return {
2754
- val: { type: TYPE.number, value, location: location_1, style: result.val },
2755
- err: null
2756
- };
2757
- } else {
2758
- if (skeleton.length === 0) {
2759
- return this.error(ErrorKind.EXPECT_DATE_TIME_SKELETON, location_1);
2297
+ var style = trimEnd(result.val);
2298
+ if (style.length === 0) {
2299
+ return this.error(ErrorKind.EXPECT_ARGUMENT_STYLE, createLocation(this.clonePosition(), this.clonePosition()));
2760
2300
  }
2761
- var dateTimePattern = skeleton;
2762
- if (this.locale) {
2763
- dateTimePattern = getBestPattern(skeleton, this.locale);
2764
- }
2765
- var style = {
2766
- type: SKELETON_TYPE.dateTime,
2767
- pattern: dateTimePattern,
2768
- location: styleAndLocation.styleLocation,
2769
- parsedOptions: this.shouldParseSkeletons ? parseDateTimeSkeleton(dateTimePattern) : {}
2770
- };
2771
- var type = argType === "date" ? TYPE.date : TYPE.time;
2772
- return {
2773
- val: { type, value, location: location_1, style },
2774
- err: null
2775
- };
2301
+ var styleLocation = createLocation(styleStartPosition, this.clonePosition());
2302
+ styleAndLocation = { style, styleLocation };
2776
2303
  }
2777
- }
2778
- return {
2779
- val: {
2780
- type: argType === "number" ? TYPE.number : argType === "date" ? TYPE.date : TYPE.time,
2781
- value,
2782
- location: location_1,
2783
- style: (_a2 = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a2 !== void 0 ? _a2 : null
2784
- },
2785
- err: null
2786
- };
2787
- }
2788
- case "plural":
2789
- case "selectordinal":
2790
- case "select": {
2791
- var typeEndPosition_1 = this.clonePosition();
2792
- this.bumpSpace();
2793
- if (!this.bumpIf(",")) {
2794
- return this.error(ErrorKind.EXPECT_SELECT_ARGUMENT_OPTIONS, createLocation(typeEndPosition_1, __assign({}, typeEndPosition_1)));
2795
- }
2796
- this.bumpSpace();
2797
- var identifierAndLocation = this.parseIdentifierIfPossible();
2798
- var pluralOffset = 0;
2799
- if (argType !== "select" && identifierAndLocation.value === "offset") {
2800
- if (!this.bumpIf(":")) {
2801
- return this.error(ErrorKind.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, createLocation(this.clonePosition(), this.clonePosition()));
2304
+ var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2305
+ if (argCloseResult.err) {
2306
+ return argCloseResult;
2802
2307
  }
2803
- this.bumpSpace();
2804
- var result = this.tryParseDecimalInteger(ErrorKind.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, ErrorKind.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);
2805
- if (result.err) {
2806
- return result;
2308
+ var location_1 = createLocation(openingBracePosition, this.clonePosition());
2309
+ if (styleAndLocation && startsWith(styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style, "::", 0)) {
2310
+ var skeleton = trimStart(styleAndLocation.style.slice(2));
2311
+ if (argType === "number") {
2312
+ var result = this.parseNumberSkeletonFromString(skeleton, styleAndLocation.styleLocation);
2313
+ if (result.err) {
2314
+ return result;
2315
+ }
2316
+ return {
2317
+ val: { type: TYPE.number, value, location: location_1, style: result.val },
2318
+ err: null
2319
+ };
2320
+ } else {
2321
+ if (skeleton.length === 0) {
2322
+ return this.error(ErrorKind.EXPECT_DATE_TIME_SKELETON, location_1);
2323
+ }
2324
+ var dateTimePattern = skeleton;
2325
+ if (this.locale) {
2326
+ dateTimePattern = getBestPattern(skeleton, this.locale);
2327
+ }
2328
+ var style = {
2329
+ type: SKELETON_TYPE.dateTime,
2330
+ pattern: dateTimePattern,
2331
+ location: styleAndLocation.styleLocation,
2332
+ parsedOptions: this.shouldParseSkeletons ? parseDateTimeSkeleton(dateTimePattern) : {}
2333
+ };
2334
+ var type = argType === "date" ? TYPE.date : TYPE.time;
2335
+ return {
2336
+ val: { type, value, location: location_1, style },
2337
+ err: null
2338
+ };
2339
+ }
2807
2340
  }
2808
- this.bumpSpace();
2809
- identifierAndLocation = this.parseIdentifierIfPossible();
2810
- pluralOffset = result.val;
2811
- }
2812
- var optionsResult = this.tryParsePluralOrSelectOptions(nestingLevel, argType, expectingCloseTag, identifierAndLocation);
2813
- if (optionsResult.err) {
2814
- return optionsResult;
2815
- }
2816
- var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2817
- if (argCloseResult.err) {
2818
- return argCloseResult;
2819
- }
2820
- var location_2 = createLocation(openingBracePosition, this.clonePosition());
2821
- if (argType === "select") {
2822
- return {
2823
- val: {
2824
- type: TYPE.select,
2825
- value,
2826
- options: fromEntries(optionsResult.val),
2827
- location: location_2
2828
- },
2829
- err: null
2830
- };
2831
- } else {
2832
2341
  return {
2833
2342
  val: {
2834
- type: TYPE.plural,
2343
+ type: argType === "number" ? TYPE.number : argType === "date" ? TYPE.date : TYPE.time,
2835
2344
  value,
2836
- options: fromEntries(optionsResult.val),
2837
- offset: pluralOffset,
2838
- pluralType: argType === "plural" ? "cardinal" : "ordinal",
2839
- location: location_2
2345
+ location: location_1,
2346
+ style: (_a2 = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a2 !== void 0 ? _a2 : null
2840
2347
  },
2841
2348
  err: null
2842
2349
  };
2843
2350
  }
2844
- }
2845
- default:
2846
- return this.error(ErrorKind.INVALID_ARGUMENT_TYPE, createLocation(typeStartPosition, typeEndPosition));
2847
- }
2848
- };
2849
- Parser2.prototype.tryParseArgumentClose = function(openingBracePosition) {
2850
- if (this.isEOF() || this.char() !== 125) {
2851
- return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2852
- }
2853
- this.bump();
2854
- return { val: true, err: null };
2855
- };
2856
- Parser2.prototype.parseSimpleArgStyleIfPossible = function() {
2857
- var nestedBraces = 0;
2858
- var startPosition = this.clonePosition();
2859
- while (!this.isEOF()) {
2860
- var ch = this.char();
2861
- switch (ch) {
2862
- case 39: {
2863
- this.bump();
2864
- var apostrophePosition = this.clonePosition();
2865
- if (!this.bumpUntil("'")) {
2866
- return this.error(ErrorKind.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE, createLocation(apostrophePosition, this.clonePosition()));
2351
+ case "plural":
2352
+ case "selectordinal":
2353
+ case "select": {
2354
+ var typeEndPosition_1 = this.clonePosition();
2355
+ this.bumpSpace();
2356
+ if (!this.bumpIf(",")) {
2357
+ return this.error(ErrorKind.EXPECT_SELECT_ARGUMENT_OPTIONS, createLocation(typeEndPosition_1, __assign({}, typeEndPosition_1)));
2867
2358
  }
2868
- this.bump();
2869
- break;
2870
- }
2871
- case 123: {
2872
- nestedBraces += 1;
2873
- this.bump();
2874
- break;
2875
- }
2876
- case 125: {
2877
- if (nestedBraces > 0) {
2878
- nestedBraces -= 1;
2359
+ this.bumpSpace();
2360
+ var identifierAndLocation = this.parseIdentifierIfPossible();
2361
+ var pluralOffset = 0;
2362
+ if (argType !== "select" && identifierAndLocation.value === "offset") {
2363
+ if (!this.bumpIf(":")) {
2364
+ return this.error(ErrorKind.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, createLocation(this.clonePosition(), this.clonePosition()));
2365
+ }
2366
+ this.bumpSpace();
2367
+ var result = this.tryParseDecimalInteger(ErrorKind.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE, ErrorKind.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);
2368
+ if (result.err) {
2369
+ return result;
2370
+ }
2371
+ this.bumpSpace();
2372
+ identifierAndLocation = this.parseIdentifierIfPossible();
2373
+ pluralOffset = result.val;
2374
+ }
2375
+ var optionsResult = this.tryParsePluralOrSelectOptions(nestingLevel, argType, expectingCloseTag, identifierAndLocation);
2376
+ if (optionsResult.err) {
2377
+ return optionsResult;
2378
+ }
2379
+ var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2380
+ if (argCloseResult.err) {
2381
+ return argCloseResult;
2382
+ }
2383
+ var location_2 = createLocation(openingBracePosition, this.clonePosition());
2384
+ if (argType === "select") {
2385
+ return {
2386
+ val: {
2387
+ type: TYPE.select,
2388
+ value,
2389
+ options: fromEntries(optionsResult.val),
2390
+ location: location_2
2391
+ },
2392
+ err: null
2393
+ };
2879
2394
  } else {
2880
2395
  return {
2881
- val: this.message.slice(startPosition.offset, this.offset()),
2396
+ val: {
2397
+ type: TYPE.plural,
2398
+ value,
2399
+ options: fromEntries(optionsResult.val),
2400
+ offset: pluralOffset,
2401
+ pluralType: argType === "plural" ? "cardinal" : "ordinal",
2402
+ location: location_2
2403
+ },
2882
2404
  err: null
2883
2405
  };
2884
2406
  }
2885
- break;
2886
2407
  }
2887
2408
  default:
2888
- this.bump();
2889
- break;
2409
+ return this.error(ErrorKind.INVALID_ARGUMENT_TYPE, createLocation(typeStartPosition, typeEndPosition));
2890
2410
  }
2891
- }
2892
- return {
2893
- val: this.message.slice(startPosition.offset, this.offset()),
2894
- err: null
2895
2411
  };
2896
- };
2897
- Parser2.prototype.parseNumberSkeletonFromString = function(skeleton, location) {
2898
- var tokens = [];
2899
- try {
2900
- tokens = parseNumberSkeletonFromString(skeleton);
2901
- } catch (e) {
2902
- return this.error(ErrorKind.INVALID_NUMBER_SKELETON, location);
2903
- }
2904
- return {
2905
- val: {
2906
- type: SKELETON_TYPE.number,
2907
- tokens,
2908
- location,
2909
- parsedOptions: this.shouldParseSkeletons ? parseNumberSkeleton(tokens) : {}
2910
- },
2911
- err: null
2412
+ Parser2.prototype.tryParseArgumentClose = function(openingBracePosition) {
2413
+ if (this.isEOF() || this.char() !== 125) {
2414
+ return this.error(ErrorKind.EXPECT_ARGUMENT_CLOSING_BRACE, createLocation(openingBracePosition, this.clonePosition()));
2415
+ }
2416
+ this.bump();
2417
+ return { val: true, err: null };
2912
2418
  };
2913
- };
2914
- Parser2.prototype.tryParsePluralOrSelectOptions = function(nestingLevel, parentArgType, expectCloseTag, parsedFirstIdentifier) {
2915
- var _a2;
2916
- var hasOtherClause = false;
2917
- var options = [];
2918
- var parsedSelectors = /* @__PURE__ */ new Set();
2919
- var selector = parsedFirstIdentifier.value, selectorLocation = parsedFirstIdentifier.location;
2920
- while (true) {
2921
- if (selector.length === 0) {
2922
- var startPosition = this.clonePosition();
2923
- if (parentArgType !== "select" && this.bumpIf("=")) {
2924
- var result = this.tryParseDecimalInteger(ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, ErrorKind.INVALID_PLURAL_ARGUMENT_SELECTOR);
2925
- if (result.err) {
2926
- return result;
2419
+ Parser2.prototype.parseSimpleArgStyleIfPossible = function() {
2420
+ var nestedBraces = 0;
2421
+ var startPosition = this.clonePosition();
2422
+ while (!this.isEOF()) {
2423
+ var ch = this.char();
2424
+ switch (ch) {
2425
+ case 39: {
2426
+ this.bump();
2427
+ var apostrophePosition = this.clonePosition();
2428
+ if (!this.bumpUntil("'")) {
2429
+ return this.error(ErrorKind.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE, createLocation(apostrophePosition, this.clonePosition()));
2430
+ }
2431
+ this.bump();
2432
+ break;
2433
+ }
2434
+ case 123: {
2435
+ nestedBraces += 1;
2436
+ this.bump();
2437
+ break;
2438
+ }
2439
+ case 125: {
2440
+ if (nestedBraces > 0) {
2441
+ nestedBraces -= 1;
2442
+ } else {
2443
+ return {
2444
+ val: this.message.slice(startPosition.offset, this.offset()),
2445
+ err: null
2446
+ };
2447
+ }
2448
+ break;
2449
+ }
2450
+ default:
2451
+ this.bump();
2452
+ break;
2453
+ }
2454
+ }
2455
+ return {
2456
+ val: this.message.slice(startPosition.offset, this.offset()),
2457
+ err: null
2458
+ };
2459
+ };
2460
+ Parser2.prototype.parseNumberSkeletonFromString = function(skeleton, location) {
2461
+ var tokens = [];
2462
+ try {
2463
+ tokens = parseNumberSkeletonFromString(skeleton);
2464
+ } catch (e) {
2465
+ return this.error(ErrorKind.INVALID_NUMBER_SKELETON, location);
2466
+ }
2467
+ return {
2468
+ val: {
2469
+ type: SKELETON_TYPE.number,
2470
+ tokens,
2471
+ location,
2472
+ parsedOptions: this.shouldParseSkeletons ? parseNumberSkeleton(tokens) : {}
2473
+ },
2474
+ err: null
2475
+ };
2476
+ };
2477
+ Parser2.prototype.tryParsePluralOrSelectOptions = function(nestingLevel, parentArgType, expectCloseTag, parsedFirstIdentifier) {
2478
+ var _a2;
2479
+ var hasOtherClause = false;
2480
+ var options = [];
2481
+ var parsedSelectors = /* @__PURE__ */ new Set();
2482
+ var selector = parsedFirstIdentifier.value, selectorLocation = parsedFirstIdentifier.location;
2483
+ while (true) {
2484
+ if (selector.length === 0) {
2485
+ var startPosition = this.clonePosition();
2486
+ if (parentArgType !== "select" && this.bumpIf("=")) {
2487
+ var result = this.tryParseDecimalInteger(ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, ErrorKind.INVALID_PLURAL_ARGUMENT_SELECTOR);
2488
+ if (result.err) {
2489
+ return result;
2490
+ }
2491
+ selectorLocation = createLocation(startPosition, this.clonePosition());
2492
+ selector = this.message.slice(startPosition.offset, this.offset());
2493
+ } else {
2494
+ break;
2495
+ }
2496
+ }
2497
+ if (parsedSelectors.has(selector)) {
2498
+ return this.error(parentArgType === "select" ? ErrorKind.DUPLICATE_SELECT_ARGUMENT_SELECTOR : ErrorKind.DUPLICATE_PLURAL_ARGUMENT_SELECTOR, selectorLocation);
2499
+ }
2500
+ if (selector === "other") {
2501
+ hasOtherClause = true;
2502
+ }
2503
+ this.bumpSpace();
2504
+ var openingBracePosition = this.clonePosition();
2505
+ if (!this.bumpIf("{")) {
2506
+ return this.error(parentArgType === "select" ? ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT : ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT, createLocation(this.clonePosition(), this.clonePosition()));
2507
+ }
2508
+ var fragmentResult = this.parseMessage(nestingLevel + 1, parentArgType, expectCloseTag);
2509
+ if (fragmentResult.err) {
2510
+ return fragmentResult;
2511
+ }
2512
+ var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2513
+ if (argCloseResult.err) {
2514
+ return argCloseResult;
2515
+ }
2516
+ options.push([
2517
+ selector,
2518
+ {
2519
+ value: fragmentResult.val,
2520
+ location: createLocation(openingBracePosition, this.clonePosition())
2927
2521
  }
2928
- selectorLocation = createLocation(startPosition, this.clonePosition());
2929
- selector = this.message.slice(startPosition.offset, this.offset());
2522
+ ]);
2523
+ parsedSelectors.add(selector);
2524
+ this.bumpSpace();
2525
+ _a2 = this.parseIdentifierIfPossible(), selector = _a2.value, selectorLocation = _a2.location;
2526
+ }
2527
+ if (options.length === 0) {
2528
+ return this.error(parentArgType === "select" ? ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR : ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, createLocation(this.clonePosition(), this.clonePosition()));
2529
+ }
2530
+ if (this.requiresOtherClause && !hasOtherClause) {
2531
+ return this.error(ErrorKind.MISSING_OTHER_CLAUSE, createLocation(this.clonePosition(), this.clonePosition()));
2532
+ }
2533
+ return { val: options, err: null };
2534
+ };
2535
+ Parser2.prototype.tryParseDecimalInteger = function(expectNumberError, invalidNumberError) {
2536
+ var sign = 1;
2537
+ var startingPosition = this.clonePosition();
2538
+ if (this.bumpIf("+")) {
2539
+ } else if (this.bumpIf("-")) {
2540
+ sign = -1;
2541
+ }
2542
+ var hasDigits = false;
2543
+ var decimal = 0;
2544
+ while (!this.isEOF()) {
2545
+ var ch = this.char();
2546
+ if (ch >= 48 && ch <= 57) {
2547
+ hasDigits = true;
2548
+ decimal = decimal * 10 + (ch - 48);
2549
+ this.bump();
2930
2550
  } else {
2931
2551
  break;
2932
2552
  }
2933
2553
  }
2934
- if (parsedSelectors.has(selector)) {
2935
- return this.error(parentArgType === "select" ? ErrorKind.DUPLICATE_SELECT_ARGUMENT_SELECTOR : ErrorKind.DUPLICATE_PLURAL_ARGUMENT_SELECTOR, selectorLocation);
2936
- }
2937
- if (selector === "other") {
2938
- hasOtherClause = true;
2554
+ var location = createLocation(startingPosition, this.clonePosition());
2555
+ if (!hasDigits) {
2556
+ return this.error(expectNumberError, location);
2939
2557
  }
2940
- this.bumpSpace();
2941
- var openingBracePosition = this.clonePosition();
2942
- if (!this.bumpIf("{")) {
2943
- return this.error(parentArgType === "select" ? ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT : ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT, createLocation(this.clonePosition(), this.clonePosition()));
2558
+ decimal *= sign;
2559
+ if (!isSafeInteger(decimal)) {
2560
+ return this.error(invalidNumberError, location);
2944
2561
  }
2945
- var fragmentResult = this.parseMessage(nestingLevel + 1, parentArgType, expectCloseTag);
2946
- if (fragmentResult.err) {
2947
- return fragmentResult;
2562
+ return { val: decimal, err: null };
2563
+ };
2564
+ Parser2.prototype.offset = function() {
2565
+ return this.position.offset;
2566
+ };
2567
+ Parser2.prototype.isEOF = function() {
2568
+ return this.offset() === this.message.length;
2569
+ };
2570
+ Parser2.prototype.clonePosition = function() {
2571
+ return {
2572
+ offset: this.position.offset,
2573
+ line: this.position.line,
2574
+ column: this.position.column
2575
+ };
2576
+ };
2577
+ Parser2.prototype.char = function() {
2578
+ var offset = this.position.offset;
2579
+ if (offset >= this.message.length) {
2580
+ throw Error("out of bound");
2948
2581
  }
2949
- var argCloseResult = this.tryParseArgumentClose(openingBracePosition);
2950
- if (argCloseResult.err) {
2951
- return argCloseResult;
2582
+ var code = codePointAt(this.message, offset);
2583
+ if (code === void 0) {
2584
+ throw Error("Offset ".concat(offset, " is at invalid UTF-16 code unit boundary"));
2952
2585
  }
2953
- options.push([
2954
- selector,
2955
- {
2956
- value: fragmentResult.val,
2957
- location: createLocation(openingBracePosition, this.clonePosition())
2586
+ return code;
2587
+ };
2588
+ Parser2.prototype.error = function(kind, location) {
2589
+ return {
2590
+ val: null,
2591
+ err: {
2592
+ kind,
2593
+ message: this.message,
2594
+ location
2958
2595
  }
2959
- ]);
2960
- parsedSelectors.add(selector);
2961
- this.bumpSpace();
2962
- _a2 = this.parseIdentifierIfPossible(), selector = _a2.value, selectorLocation = _a2.location;
2963
- }
2964
- if (options.length === 0) {
2965
- return this.error(parentArgType === "select" ? ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR : ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, createLocation(this.clonePosition(), this.clonePosition()));
2966
- }
2967
- if (this.requiresOtherClause && !hasOtherClause) {
2968
- return this.error(ErrorKind.MISSING_OTHER_CLAUSE, createLocation(this.clonePosition(), this.clonePosition()));
2969
- }
2970
- return { val: options, err: null };
2971
- };
2972
- Parser2.prototype.tryParseDecimalInteger = function(expectNumberError, invalidNumberError) {
2973
- var sign = 1;
2974
- var startingPosition = this.clonePosition();
2975
- if (this.bumpIf("+")) {
2976
- } else if (this.bumpIf("-")) {
2977
- sign = -1;
2978
- }
2979
- var hasDigits = false;
2980
- var decimal = 0;
2981
- while (!this.isEOF()) {
2982
- var ch = this.char();
2983
- if (ch >= 48 && ch <= 57) {
2984
- hasDigits = true;
2985
- decimal = decimal * 10 + (ch - 48);
2986
- this.bump();
2596
+ };
2597
+ };
2598
+ Parser2.prototype.bump = function() {
2599
+ if (this.isEOF()) {
2600
+ return;
2601
+ }
2602
+ var code = this.char();
2603
+ if (code === 10) {
2604
+ this.position.line += 1;
2605
+ this.position.column = 1;
2606
+ this.position.offset += 1;
2987
2607
  } else {
2988
- break;
2608
+ this.position.column += 1;
2609
+ this.position.offset += code < 65536 ? 1 : 2;
2989
2610
  }
2990
- }
2991
- var location = createLocation(startingPosition, this.clonePosition());
2992
- if (!hasDigits) {
2993
- return this.error(expectNumberError, location);
2994
- }
2995
- decimal *= sign;
2996
- if (!isSafeInteger(decimal)) {
2997
- return this.error(invalidNumberError, location);
2998
- }
2999
- return { val: decimal, err: null };
3000
- };
3001
- Parser2.prototype.offset = function() {
3002
- return this.position.offset;
3003
- };
3004
- Parser2.prototype.isEOF = function() {
3005
- return this.offset() === this.message.length;
3006
- };
3007
- Parser2.prototype.clonePosition = function() {
3008
- return {
3009
- offset: this.position.offset,
3010
- line: this.position.line,
3011
- column: this.position.column
3012
2611
  };
3013
- };
3014
- Parser2.prototype.char = function() {
3015
- var offset = this.position.offset;
3016
- if (offset >= this.message.length) {
3017
- throw Error("out of bound");
3018
- }
3019
- var code = codePointAt(this.message, offset);
3020
- if (code === void 0) {
3021
- throw Error("Offset ".concat(offset, " is at invalid UTF-16 code unit boundary"));
3022
- }
3023
- return code;
3024
- };
3025
- Parser2.prototype.error = function(kind, location) {
3026
- return {
3027
- val: null,
3028
- err: {
3029
- kind,
3030
- message: this.message,
3031
- location
2612
+ Parser2.prototype.bumpIf = function(prefix) {
2613
+ if (startsWith(this.message, prefix, this.offset())) {
2614
+ for (var i = 0; i < prefix.length; i++) {
2615
+ this.bump();
2616
+ }
2617
+ return true;
3032
2618
  }
2619
+ return false;
3033
2620
  };
3034
- };
3035
- Parser2.prototype.bump = function() {
3036
- if (this.isEOF()) {
3037
- return;
3038
- }
3039
- var code = this.char();
3040
- if (code === 10) {
3041
- this.position.line += 1;
3042
- this.position.column = 1;
3043
- this.position.offset += 1;
3044
- } else {
3045
- this.position.column += 1;
3046
- this.position.offset += code < 65536 ? 1 : 2;
3047
- }
3048
- };
3049
- Parser2.prototype.bumpIf = function(prefix) {
3050
- if (startsWith(this.message, prefix, this.offset())) {
3051
- for (var i = 0; i < prefix.length; i++) {
3052
- this.bump();
2621
+ Parser2.prototype.bumpUntil = function(pattern) {
2622
+ var currentOffset = this.offset();
2623
+ var index = this.message.indexOf(pattern, currentOffset);
2624
+ if (index >= 0) {
2625
+ this.bumpTo(index);
2626
+ return true;
2627
+ } else {
2628
+ this.bumpTo(this.message.length);
2629
+ return false;
3053
2630
  }
3054
- return true;
3055
- }
3056
- return false;
3057
- };
3058
- Parser2.prototype.bumpUntil = function(pattern) {
3059
- var currentOffset = this.offset();
3060
- var index = this.message.indexOf(pattern, currentOffset);
3061
- if (index >= 0) {
3062
- this.bumpTo(index);
3063
- return true;
3064
- } else {
3065
- this.bumpTo(this.message.length);
3066
- return false;
3067
- }
3068
- };
3069
- Parser2.prototype.bumpTo = function(targetOffset) {
3070
- if (this.offset() > targetOffset) {
3071
- throw Error("targetOffset ".concat(targetOffset, " must be greater than or equal to the current offset ").concat(this.offset()));
3072
- }
3073
- targetOffset = Math.min(targetOffset, this.message.length);
3074
- while (true) {
3075
- var offset = this.offset();
3076
- if (offset === targetOffset) {
3077
- break;
2631
+ };
2632
+ Parser2.prototype.bumpTo = function(targetOffset) {
2633
+ if (this.offset() > targetOffset) {
2634
+ throw Error("targetOffset ".concat(targetOffset, " must be greater than or equal to the current offset ").concat(this.offset()));
3078
2635
  }
3079
- if (offset > targetOffset) {
3080
- throw Error("targetOffset ".concat(targetOffset, " is at invalid UTF-16 code unit boundary"));
2636
+ targetOffset = Math.min(targetOffset, this.message.length);
2637
+ while (true) {
2638
+ var offset = this.offset();
2639
+ if (offset === targetOffset) {
2640
+ break;
2641
+ }
2642
+ if (offset > targetOffset) {
2643
+ throw Error("targetOffset ".concat(targetOffset, " is at invalid UTF-16 code unit boundary"));
2644
+ }
2645
+ this.bump();
2646
+ if (this.isEOF()) {
2647
+ break;
2648
+ }
3081
2649
  }
3082
- this.bump();
2650
+ };
2651
+ Parser2.prototype.bumpSpace = function() {
2652
+ while (!this.isEOF() && _isWhiteSpace(this.char())) {
2653
+ this.bump();
2654
+ }
2655
+ };
2656
+ Parser2.prototype.peek = function() {
3083
2657
  if (this.isEOF()) {
3084
- break;
2658
+ return null;
3085
2659
  }
3086
- }
3087
- };
3088
- Parser2.prototype.bumpSpace = function() {
3089
- while (!this.isEOF() && _isWhiteSpace(this.char())) {
3090
- this.bump();
3091
- }
3092
- };
3093
- Parser2.prototype.peek = function() {
3094
- if (this.isEOF()) {
3095
- return null;
3096
- }
3097
- var code = this.char();
3098
- var offset = this.offset();
3099
- var nextCode = this.message.charCodeAt(offset + (code >= 65536 ? 2 : 1));
3100
- return nextCode !== null && nextCode !== void 0 ? nextCode : null;
3101
- };
3102
- return Parser2;
3103
- }();
2660
+ var code = this.char();
2661
+ var offset = this.offset();
2662
+ var nextCode = this.message.charCodeAt(offset + (code >= 65536 ? 2 : 1));
2663
+ return nextCode !== null && nextCode !== void 0 ? nextCode : null;
2664
+ };
2665
+ return Parser2;
2666
+ }()
2667
+ );
3104
2668
  function _isAlpha(codepoint) {
3105
2669
  return codepoint >= 97 && codepoint <= 122 || codepoint >= 65 && codepoint <= 90;
3106
2670
  }
@@ -3229,6 +2793,13 @@ var ErrorCode;
3229
2793
  })(ErrorCode || (ErrorCode = {}));
3230
2794
  var FormatError = class extends Error {
3231
2795
  code;
2796
+ /**
2797
+ * Original message we're trying to format
2798
+ * `undefined` if we're only dealing w/ AST
2799
+ *
2800
+ * @type {(string | undefined)}
2801
+ * @memberof FormatError
2802
+ */
3232
2803
  originalMessage;
3233
2804
  constructor(msg, code, originalMessage) {
3234
2805
  super(msg);
@@ -3531,6 +3102,9 @@ __publicField(IntlMessageFormat, "resolveLocale", (locales) => {
3531
3102
  return new Intl.Locale(typeof locales === "string" ? locales : locales[0]);
3532
3103
  });
3533
3104
  __publicField(IntlMessageFormat, "__parse", parse);
3105
+ // Default format options used as the prototype of the `formats` provided to the
3106
+ // constructor. These are used when constructing the internal Intl.NumberFormat
3107
+ // and Intl.DateTimeFormat instances.
3534
3108
  __publicField(IntlMessageFormat, "formats", {
3535
3109
  number: {
3536
3110
  integer: {