react-intl 7.1.14 → 8.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/index.d.ts +15 -15
  2. package/index.js +21 -46
  3. package/package.json +10 -8
  4. package/react-intl.iife.js +113 -111
  5. package/src/components/createFormattedComponent.d.ts +1 -1
  6. package/src/components/createFormattedComponent.js +17 -24
  7. package/src/components/createIntl.d.ts +1 -1
  8. package/src/components/createIntl.js +12 -16
  9. package/src/components/dateTimeRange.js +6 -8
  10. package/src/components/injectIntl.d.ts +1 -1
  11. package/src/components/injectIntl.js +14 -16
  12. package/src/components/message.js +10 -12
  13. package/src/components/plural.js +4 -7
  14. package/src/components/provider.d.ts +2 -2
  15. package/src/components/provider.js +15 -17
  16. package/src/components/relative.js +10 -12
  17. package/src/components/useIntl.d.ts +1 -1
  18. package/src/components/useIntl.js +6 -10
  19. package/src/types.d.ts +1 -1
  20. package/src/types.js +1 -2
  21. package/src/utils.d.ts +2 -1
  22. package/src/utils.js +21 -29
  23. package/lib/index.d.ts +0 -46
  24. package/lib/index.js +0 -26
  25. package/lib/src/components/createFormattedComponent.d.ts +0 -27
  26. package/lib/src/components/createFormattedComponent.js +0 -62
  27. package/lib/src/components/createIntl.d.ts +0 -9
  28. package/lib/src/components/createIntl.js +0 -58
  29. package/lib/src/components/dateTimeRange.d.ts +0 -9
  30. package/lib/src/components/dateTimeRange.js +0 -15
  31. package/lib/src/components/injectIntl.d.ts +0 -39
  32. package/lib/src/components/injectIntl.js +0 -35
  33. package/lib/src/components/message.d.ts +0 -11
  34. package/lib/src/components/message.js +0 -35
  35. package/lib/src/components/plural.d.ts +0 -14
  36. package/lib/src/components/plural.js +0 -23
  37. package/lib/src/components/provider.d.ts +0 -29
  38. package/lib/src/components/provider.js +0 -59
  39. package/lib/src/components/relative.d.ts +0 -10
  40. package/lib/src/components/relative.js +0 -125
  41. package/lib/src/components/useIntl.d.ts +0 -2
  42. package/lib/src/components/useIntl.js +0 -8
  43. package/lib/src/types.d.ts +0 -14
  44. package/lib/src/types.js +0 -1
  45. package/lib/src/utils.d.ts +0 -25
  46. package/lib/src/utils.js +0 -69
@@ -365,7 +365,7 @@ var ReactIntl = (() => {
365
365
  // packages/react-intl/src/components/useIntl.ts
366
366
  var React3 = __toESM(window.React);
367
367
 
368
- // packages/react-intl/src/utils.ts
368
+ // packages/react-intl/src/utils.tsx
369
369
  var React = __toESM(window.React);
370
370
 
371
371
  // node_modules/.aspect_rules_js/tslib@2.8.1/node_modules/tslib/tslib.es6.mjs
@@ -424,7 +424,7 @@ var ReactIntl = (() => {
424
424
  return to.concat(ar || Array.prototype.slice.call(from));
425
425
  }
426
426
 
427
- // node_modules/.aspect_rules_js/@formatjs+fast-memoize@0.0.0/node_modules/@formatjs/fast-memoize/lib/index.js
427
+ // node_modules/.aspect_rules_js/@formatjs+fast-memoize@0.0.0/node_modules/@formatjs/fast-memoize/index.js
428
428
  function memoize(fn, options) {
429
429
  var cache = options && options.cache ? options.cache : cacheDefault;
430
430
  var serializer = options && options.serializer ? options.serializer : serializerDefault;
@@ -497,7 +497,7 @@ var ReactIntl = (() => {
497
497
  monadic: strategyMonadic
498
498
  };
499
499
 
500
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/error.js
500
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/error.js
501
501
  var ErrorKind;
502
502
  (function(ErrorKind2) {
503
503
  ErrorKind2[ErrorKind2["EXPECT_ARGUMENT_CLOSING_BRACE"] = 1] = "EXPECT_ARGUMENT_CLOSING_BRACE";
@@ -528,7 +528,7 @@ var ReactIntl = (() => {
528
528
  ErrorKind2[ErrorKind2["UNCLOSED_TAG"] = 27] = "UNCLOSED_TAG";
529
529
  })(ErrorKind || (ErrorKind = {}));
530
530
 
531
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/types.js
531
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/types.js
532
532
  var TYPE;
533
533
  (function(TYPE2) {
534
534
  TYPE2[TYPE2["literal"] = 0] = "literal";
@@ -580,10 +580,10 @@ var ReactIntl = (() => {
580
580
  return !!(el && typeof el === "object" && el.type === SKELETON_TYPE.dateTime);
581
581
  }
582
582
 
583
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/regex.generated.js
583
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/regex.generated.js
584
584
  var SPACE_SEPARATOR_REGEX = /[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/;
585
585
 
586
- // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/lib/date-time.js
586
+ // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/date-time.js
587
587
  var DATE_TIME_REGEX = /(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;
588
588
  function parseDateTimeSkeleton(skeleton) {
589
589
  var result = {};
@@ -684,10 +684,10 @@ var ReactIntl = (() => {
684
684
  return result;
685
685
  }
686
686
 
687
- // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/lib/regex.generated.js
687
+ // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/regex.generated.js
688
688
  var WHITE_SPACE_REGEX = /[\t-\r \x85\u200E\u200F\u2028\u2029]/i;
689
689
 
690
- // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/lib/number.js
690
+ // node_modules/.aspect_rules_js/@formatjs+icu-skeleton-parser@0.0.0/node_modules/@formatjs/icu-skeleton-parser/number.js
691
691
  function parseNumberSkeletonFromString(skeleton) {
692
692
  if (skeleton.length === 0) {
693
693
  throw new Error("Number skeleton cannot be empty");
@@ -703,8 +703,8 @@ var ReactIntl = (() => {
703
703
  throw new Error("Invalid number skeleton");
704
704
  }
705
705
  var stem = stemAndOptions[0], options = stemAndOptions.slice(1);
706
- for (var _a2 = 0, options_1 = options; _a2 < options_1.length; _a2++) {
707
- var option = options_1[_a2];
706
+ for (var _a3 = 0, options_1 = options; _a3 < options_1.length; _a3++) {
707
+ var option = options_1[_a3];
708
708
  if (option.length === 0) {
709
709
  throw new Error("Invalid number skeleton");
710
710
  }
@@ -974,7 +974,7 @@ var ReactIntl = (() => {
974
974
  return result;
975
975
  }
976
976
 
977
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/time-data.generated.js
977
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/time-data.generated.js
978
978
  var timeData = {
979
979
  "001": [
980
980
  "H",
@@ -2391,7 +2391,7 @@ var ReactIntl = (() => {
2391
2391
  ]
2392
2392
  };
2393
2393
 
2394
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/date-time-pattern-generator.js
2394
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/date-time-pattern-generator.js
2395
2395
  function getBestPattern(skeleton, locale) {
2396
2396
  var skeletonCopy = "";
2397
2397
  for (var patternPos = 0; patternPos < skeleton.length; patternPos++) {
@@ -2453,7 +2453,7 @@ var ReactIntl = (() => {
2453
2453
  return hourCycles[0];
2454
2454
  }
2455
2455
 
2456
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/parser.js
2456
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/parser.js
2457
2457
  var _a;
2458
2458
  var SPACE_SEPARATOR_START_REGEX = new RegExp("^".concat(SPACE_SEPARATOR_REGEX.source, "*"));
2459
2459
  var SPACE_SEPARATOR_END_REGEX = new RegExp("".concat(SPACE_SEPARATOR_REGEX.source, "*$"));
@@ -2474,7 +2474,7 @@ var ReactIntl = (() => {
2474
2474
  try {
2475
2475
  re = RE("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
2476
2476
  REGEX_SUPPORTS_U_AND_Y = ((_a = re.exec("a")) === null || _a === void 0 ? void 0 : _a[0]) === "a";
2477
- } catch (_) {
2477
+ } catch (_b) {
2478
2478
  REGEX_SUPPORTS_U_AND_Y = false;
2479
2479
  }
2480
2480
  var re;
@@ -2516,7 +2516,7 @@ var ReactIntl = (() => {
2516
2516
  function fromEntries2(entries) {
2517
2517
  var obj = {};
2518
2518
  for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) {
2519
- var _a2 = entries_1[_i], k = _a2[0], v = _a2[1];
2519
+ var _a3 = entries_1[_i], k = _a3[0], v = _a3[1];
2520
2520
  obj[k] = v;
2521
2521
  }
2522
2522
  return obj;
@@ -2569,10 +2569,10 @@ var ReactIntl = (() => {
2569
2569
  if (REGEX_SUPPORTS_U_AND_Y) {
2570
2570
  IDENTIFIER_PREFIX_RE_1 = RE("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
2571
2571
  matchIdentifierAtIndex = function matchIdentifierAtIndex2(s, index) {
2572
- var _a2;
2572
+ var _a3;
2573
2573
  IDENTIFIER_PREFIX_RE_1.lastIndex = index;
2574
2574
  var match = IDENTIFIER_PREFIX_RE_1.exec(s);
2575
- return (_a2 = match[1]) !== null && _a2 !== void 0 ? _a2 : "";
2575
+ return (_a3 = match[1]) !== null && _a3 !== void 0 ? _a3 : "";
2576
2576
  };
2577
2577
  } else {
2578
2578
  matchIdentifierAtIndex = function matchIdentifierAtIndex2(s, index) {
@@ -2852,7 +2852,7 @@ var ReactIntl = (() => {
2852
2852
  return { value, location };
2853
2853
  };
2854
2854
  Parser2.prototype.parseArgumentOptions = function(nestingLevel, expectingCloseTag, value, openingBracePosition) {
2855
- var _a2;
2855
+ var _a3;
2856
2856
  var typeStartPosition = this.clonePosition();
2857
2857
  var argType = this.parseIdentifierIfPossible().value;
2858
2858
  var typeEndPosition = this.clonePosition();
@@ -2920,7 +2920,7 @@ var ReactIntl = (() => {
2920
2920
  type: argType === "number" ? TYPE.number : argType === "date" ? TYPE.date : TYPE.time,
2921
2921
  value,
2922
2922
  location: location_1,
2923
- style: (_a2 = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a2 !== void 0 ? _a2 : null
2923
+ style: (_a3 = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a3 !== void 0 ? _a3 : null
2924
2924
  },
2925
2925
  err: null
2926
2926
  };
@@ -3038,7 +3038,7 @@ var ReactIntl = (() => {
3038
3038
  var tokens = [];
3039
3039
  try {
3040
3040
  tokens = parseNumberSkeletonFromString(skeleton);
3041
- } catch (e) {
3041
+ } catch (_a3) {
3042
3042
  return this.error(ErrorKind.INVALID_NUMBER_SKELETON, location);
3043
3043
  }
3044
3044
  return {
@@ -3052,7 +3052,7 @@ var ReactIntl = (() => {
3052
3052
  };
3053
3053
  };
3054
3054
  Parser2.prototype.tryParsePluralOrSelectOptions = function(nestingLevel, parentArgType, expectCloseTag, parsedFirstIdentifier) {
3055
- var _a2;
3055
+ var _a3;
3056
3056
  var hasOtherClause = false;
3057
3057
  var options = [];
3058
3058
  var parsedSelectors = /* @__PURE__ */ new Set();
@@ -3099,7 +3099,7 @@ var ReactIntl = (() => {
3099
3099
  ]);
3100
3100
  parsedSelectors.add(selector);
3101
3101
  this.bumpSpace();
3102
- _a2 = this.parseIdentifierIfPossible(), selector = _a2.value, selectorLocation = _a2.location;
3102
+ _a3 = this.parseIdentifierIfPossible(), selector = _a3.value, selectorLocation = _a3.location;
3103
3103
  }
3104
3104
  if (options.length === 0) {
3105
3105
  return this.error(parentArgType === "select" ? ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR : ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, createLocation(this.clonePosition(), this.clonePosition()));
@@ -3258,7 +3258,7 @@ var ReactIntl = (() => {
3258
3258
  return c >= 33 && c <= 35 || c === 36 || c >= 37 && c <= 39 || c === 40 || c === 41 || c === 42 || c === 43 || c === 44 || c === 45 || c >= 46 && c <= 47 || c >= 58 && c <= 59 || c >= 60 && c <= 62 || c >= 63 && c <= 64 || c === 91 || c === 92 || c === 93 || c === 94 || c === 96 || c === 123 || c === 124 || c === 125 || c === 126 || c === 161 || c >= 162 && c <= 165 || c === 166 || c === 167 || c === 169 || c === 171 || c === 172 || c === 174 || c === 176 || c === 177 || c === 182 || c === 187 || c === 191 || c === 215 || c === 247 || c >= 8208 && c <= 8213 || c >= 8214 && c <= 8215 || c === 8216 || c === 8217 || c === 8218 || c >= 8219 && c <= 8220 || c === 8221 || c === 8222 || c === 8223 || c >= 8224 && c <= 8231 || c >= 8240 && c <= 8248 || c === 8249 || c === 8250 || c >= 8251 && c <= 8254 || c >= 8257 && c <= 8259 || c === 8260 || c === 8261 || c === 8262 || c >= 8263 && c <= 8273 || c === 8274 || c === 8275 || c >= 8277 && c <= 8286 || c >= 8592 && c <= 8596 || c >= 8597 && c <= 8601 || c >= 8602 && c <= 8603 || c >= 8604 && c <= 8607 || c === 8608 || c >= 8609 && c <= 8610 || c === 8611 || c >= 8612 && c <= 8613 || c === 8614 || c >= 8615 && c <= 8621 || c === 8622 || c >= 8623 && c <= 8653 || c >= 8654 && c <= 8655 || c >= 8656 && c <= 8657 || c === 8658 || c === 8659 || c === 8660 || c >= 8661 && c <= 8691 || c >= 8692 && c <= 8959 || c >= 8960 && c <= 8967 || c === 8968 || c === 8969 || c === 8970 || c === 8971 || c >= 8972 && c <= 8991 || c >= 8992 && c <= 8993 || c >= 8994 && c <= 9e3 || c === 9001 || c === 9002 || c >= 9003 && c <= 9083 || c === 9084 || c >= 9085 && c <= 9114 || c >= 9115 && c <= 9139 || c >= 9140 && c <= 9179 || c >= 9180 && c <= 9185 || c >= 9186 && c <= 9254 || c >= 9255 && c <= 9279 || c >= 9280 && c <= 9290 || c >= 9291 && c <= 9311 || c >= 9472 && c <= 9654 || c === 9655 || c >= 9656 && c <= 9664 || c === 9665 || c >= 9666 && c <= 9719 || c >= 9720 && c <= 9727 || c >= 9728 && c <= 9838 || c === 9839 || c >= 9840 && c <= 10087 || c === 10088 || c === 10089 || c === 10090 || c === 10091 || c === 10092 || c === 10093 || c === 10094 || c === 10095 || c === 10096 || c === 10097 || c === 10098 || c === 10099 || c === 10100 || c === 10101 || c >= 10132 && c <= 10175 || c >= 10176 && c <= 10180 || c === 10181 || c === 10182 || c >= 10183 && c <= 10213 || c === 10214 || c === 10215 || c === 10216 || c === 10217 || c === 10218 || c === 10219 || c === 10220 || c === 10221 || c === 10222 || c === 10223 || c >= 10224 && c <= 10239 || c >= 10240 && c <= 10495 || c >= 10496 && c <= 10626 || c === 10627 || c === 10628 || c === 10629 || c === 10630 || c === 10631 || c === 10632 || c === 10633 || c === 10634 || c === 10635 || c === 10636 || c === 10637 || c === 10638 || c === 10639 || c === 10640 || c === 10641 || c === 10642 || c === 10643 || c === 10644 || c === 10645 || c === 10646 || c === 10647 || c === 10648 || c >= 10649 && c <= 10711 || c === 10712 || c === 10713 || c === 10714 || c === 10715 || c >= 10716 && c <= 10747 || c === 10748 || c === 10749 || c >= 10750 && c <= 11007 || c >= 11008 && c <= 11055 || c >= 11056 && c <= 11076 || c >= 11077 && c <= 11078 || c >= 11079 && c <= 11084 || c >= 11085 && c <= 11123 || c >= 11124 && c <= 11125 || c >= 11126 && c <= 11157 || c === 11158 || c >= 11159 && c <= 11263 || c >= 11776 && c <= 11777 || c === 11778 || c === 11779 || c === 11780 || c === 11781 || c >= 11782 && c <= 11784 || c === 11785 || c === 11786 || c === 11787 || c === 11788 || c === 11789 || c >= 11790 && c <= 11798 || c === 11799 || c >= 11800 && c <= 11801 || c === 11802 || c === 11803 || c === 11804 || c === 11805 || c >= 11806 && c <= 11807 || c === 11808 || c === 11809 || c === 11810 || c === 11811 || c === 11812 || c === 11813 || c === 11814 || c === 11815 || c === 11816 || c === 11817 || c >= 11818 && c <= 11822 || c === 11823 || c >= 11824 && c <= 11833 || c >= 11834 && c <= 11835 || c >= 11836 && c <= 11839 || c === 11840 || c === 11841 || c === 11842 || c >= 11843 && c <= 11855 || c >= 11856 && c <= 11857 || c === 11858 || c >= 11859 && c <= 11903 || c >= 12289 && c <= 12291 || c === 12296 || c === 12297 || c === 12298 || c === 12299 || c === 12300 || c === 12301 || c === 12302 || c === 12303 || c === 12304 || c === 12305 || c >= 12306 && c <= 12307 || c === 12308 || c === 12309 || c === 12310 || c === 12311 || c === 12312 || c === 12313 || c === 12314 || c === 12315 || c === 12316 || c === 12317 || c >= 12318 && c <= 12319 || c === 12320 || c === 12336 || c === 64830 || c === 64831 || c >= 65093 && c <= 65094;
3259
3259
  }
3260
3260
 
3261
- // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/lib/index.js
3261
+ // node_modules/.aspect_rules_js/@formatjs+icu-messageformat-parser@0.0.0/node_modules/@formatjs/icu-messageformat-parser/index.js
3262
3262
  function pruneLocation(els) {
3263
3263
  els.forEach(function(el) {
3264
3264
  delete el.location;
@@ -3294,7 +3294,7 @@ var ReactIntl = (() => {
3294
3294
  return result.val;
3295
3295
  }
3296
3296
 
3297
- // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/lib/src/error.js
3297
+ // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/src/error.js
3298
3298
  var ErrorCode;
3299
3299
  (function(ErrorCode2) {
3300
3300
  ErrorCode2["MISSING_VALUE"] = "MISSING_VALUE";
@@ -3348,7 +3348,7 @@ var ReactIntl = (() => {
3348
3348
  }(FormatError)
3349
3349
  );
3350
3350
 
3351
- // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/lib/src/formatters.js
3351
+ // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/src/formatters.js
3352
3352
  var PART_TYPE;
3353
3353
  (function(PART_TYPE2) {
3354
3354
  PART_TYPE2[PART_TYPE2["literal"] = 0] = "literal";
@@ -3488,13 +3488,13 @@ var ReactIntl = (() => {
3488
3488
  return mergeLiteral(result);
3489
3489
  }
3490
3490
 
3491
- // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/lib/src/core.js
3491
+ // node_modules/.aspect_rules_js/intl-messageformat@0.0.0/node_modules/intl-messageformat/src/core.js
3492
3492
  function mergeConfig(c1, c2) {
3493
3493
  if (!c2) {
3494
3494
  return c1;
3495
3495
  }
3496
- return __assign(__assign(__assign({}, c1 || {}), c2 || {}), Object.keys(c1).reduce(function(all, k) {
3497
- all[k] = __assign(__assign({}, c1[k]), c2[k] || {});
3496
+ return __assign(__assign(__assign({}, c1), c2), Object.keys(c1).reduce(function(all, k) {
3497
+ all[k] = __assign(__assign({}, c1[k]), c2[k]);
3498
3498
  return all;
3499
3499
  }, {}));
3500
3500
  }
@@ -3531,34 +3531,34 @@ var ReactIntl = (() => {
3531
3531
  }
3532
3532
  return {
3533
3533
  getNumberFormat: memoize(function() {
3534
- var _a2;
3534
+ var _a3;
3535
3535
  var args = [];
3536
3536
  for (var _i = 0; _i < arguments.length; _i++) {
3537
3537
  args[_i] = arguments[_i];
3538
3538
  }
3539
- return new ((_a2 = Intl.NumberFormat).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3539
+ return new ((_a3 = Intl.NumberFormat).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3540
3540
  }, {
3541
3541
  cache: createFastMemoizeCache(cache.number),
3542
3542
  strategy: strategies.variadic
3543
3543
  }),
3544
3544
  getDateTimeFormat: memoize(function() {
3545
- var _a2;
3545
+ var _a3;
3546
3546
  var args = [];
3547
3547
  for (var _i = 0; _i < arguments.length; _i++) {
3548
3548
  args[_i] = arguments[_i];
3549
3549
  }
3550
- return new ((_a2 = Intl.DateTimeFormat).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3550
+ return new ((_a3 = Intl.DateTimeFormat).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3551
3551
  }, {
3552
3552
  cache: createFastMemoizeCache(cache.dateTime),
3553
3553
  strategy: strategies.variadic
3554
3554
  }),
3555
3555
  getPluralRules: memoize(function() {
3556
- var _a2;
3556
+ var _a3;
3557
3557
  var args = [];
3558
3558
  for (var _i = 0; _i < arguments.length; _i++) {
3559
3559
  args[_i] = arguments[_i];
3560
3560
  }
3561
- return new ((_a2 = Intl.PluralRules).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3561
+ return new ((_a3 = Intl.PluralRules).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3562
3562
  }, {
3563
3563
  cache: createFastMemoizeCache(cache.pluralRules),
3564
3564
  strategy: strategies.variadic
@@ -3615,7 +3615,10 @@ var ReactIntl = (() => {
3615
3615
  if (!IntlMessageFormat2.__parse) {
3616
3616
  throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");
3617
3617
  }
3618
- var _a2 = opts || {}, formatters = _a2.formatters, parseOpts = __rest(_a2, ["formatters"]);
3618
+ var parseOpts = __rest(
3619
+ opts || {},
3620
+ []
3621
+ );
3619
3622
  this.ast = IntlMessageFormat2.__parse(message, __assign(__assign({}, parseOpts), { locale: this.resolvedLocale }));
3620
3623
  } else {
3621
3624
  this.ast = message;
@@ -3711,7 +3714,7 @@ var ReactIntl = (() => {
3711
3714
  }()
3712
3715
  );
3713
3716
 
3714
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/error.js
3717
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/error.js
3715
3718
  var IntlErrorCode;
3716
3719
  (function(IntlErrorCode2) {
3717
3720
  IntlErrorCode2["FORMAT_ERROR"] = "FORMAT_ERROR";
@@ -3798,8 +3801,8 @@ var ReactIntl = (() => {
3798
3801
  __extends(MissingTranslationError2, _super);
3799
3802
  function MissingTranslationError2(descriptor, locale) {
3800
3803
  var _this = _super.call(this, IntlErrorCode.MISSING_TRANSLATION, 'Missing message: "'.concat(descriptor.id, '" for locale "').concat(locale, '", using ').concat(descriptor.defaultMessage ? "default message (".concat(typeof descriptor.defaultMessage === "string" ? descriptor.defaultMessage : descriptor.defaultMessage.map(function(e) {
3801
- var _a2;
3802
- return (_a2 = e.value) !== null && _a2 !== void 0 ? _a2 : JSON.stringify(e);
3804
+ var _a3;
3805
+ return (_a3 = e.value) !== null && _a3 !== void 0 ? _a3 : JSON.stringify(e);
3803
3806
  }).join(), ")") : "id", " as fallback.")) || this;
3804
3807
  _this.descriptor = descriptor;
3805
3808
  return _this;
@@ -3808,7 +3811,7 @@ var ReactIntl = (() => {
3808
3811
  }(IntlError)
3809
3812
  );
3810
3813
 
3811
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/utils.js
3814
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/utils.js
3812
3815
  function invariant(condition, message, Err) {
3813
3816
  if (Err === void 0) {
3814
3817
  Err = Error;
@@ -3883,34 +3886,34 @@ var ReactIntl = (() => {
3883
3886
  var ListFormat = Intl.ListFormat;
3884
3887
  var DisplayNames = Intl.DisplayNames;
3885
3888
  var getDateTimeFormat = memoize(function() {
3886
- var _a2;
3889
+ var _a3;
3887
3890
  var args = [];
3888
3891
  for (var _i = 0; _i < arguments.length; _i++) {
3889
3892
  args[_i] = arguments[_i];
3890
3893
  }
3891
- return new ((_a2 = Intl.DateTimeFormat).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3894
+ return new ((_a3 = Intl.DateTimeFormat).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3892
3895
  }, {
3893
3896
  cache: createFastMemoizeCache2(cache.dateTime),
3894
3897
  strategy: strategies.variadic
3895
3898
  });
3896
3899
  var getNumberFormat = memoize(function() {
3897
- var _a2;
3900
+ var _a3;
3898
3901
  var args = [];
3899
3902
  for (var _i = 0; _i < arguments.length; _i++) {
3900
3903
  args[_i] = arguments[_i];
3901
3904
  }
3902
- return new ((_a2 = Intl.NumberFormat).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3905
+ return new ((_a3 = Intl.NumberFormat).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3903
3906
  }, {
3904
3907
  cache: createFastMemoizeCache2(cache.number),
3905
3908
  strategy: strategies.variadic
3906
3909
  });
3907
3910
  var getPluralRules = memoize(function() {
3908
- var _a2;
3911
+ var _a3;
3909
3912
  var args = [];
3910
3913
  for (var _i = 0; _i < arguments.length; _i++) {
3911
3914
  args[_i] = arguments[_i];
3912
3915
  }
3913
- return new ((_a2 = Intl.PluralRules).bind.apply(_a2, __spreadArray([void 0], args, false)))();
3916
+ return new ((_a3 = Intl.PluralRules).bind.apply(_a3, __spreadArray([void 0], args, false)))();
3914
3917
  }, {
3915
3918
  cache: createFastMemoizeCache2(cache.pluralRules),
3916
3919
  strategy: strategies.variadic
@@ -3923,7 +3926,7 @@ var ReactIntl = (() => {
3923
3926
  getNumberFormat,
3924
3927
  getDateTimeFormat,
3925
3928
  getPluralRules
3926
- } }, opts || {}));
3929
+ } }, opts));
3927
3930
  }, {
3928
3931
  cache: createFastMemoizeCache2(cache.message),
3929
3932
  strategy: strategies.variadic
@@ -3973,7 +3976,7 @@ var ReactIntl = (() => {
3973
3976
  onError(new UnsupportedFormatterError("No ".concat(type, " format named: ").concat(name)));
3974
3977
  }
3975
3978
 
3976
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/message.js
3979
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/message.js
3977
3980
  function setTimeZoneInOptions(opts, timeZone) {
3978
3981
  return Object.keys(opts).reduce(function(all, k) {
3979
3982
  all[k] = __assign({ timeZone }, opts[k]);
@@ -3983,7 +3986,7 @@ var ReactIntl = (() => {
3983
3986
  function deepMergeOptions(opts1, opts2) {
3984
3987
  var keys = Object.keys(__assign(__assign({}, opts1), opts2));
3985
3988
  return keys.reduce(function(all, k) {
3986
- all[k] = __assign(__assign({}, opts1[k] || {}), opts2[k] || {});
3989
+ all[k] = __assign(__assign({}, opts1[k]), opts2[k]);
3987
3990
  return all;
3988
3991
  }, {});
3989
3992
  }
@@ -3994,8 +3997,8 @@ var ReactIntl = (() => {
3994
3997
  var mfFormats = IntlMessageFormat.formats;
3995
3998
  return __assign(__assign(__assign({}, mfFormats), f1), { date: deepMergeOptions(setTimeZoneInOptions(mfFormats.date, timeZone), setTimeZoneInOptions(f1.date || {}, timeZone)), time: deepMergeOptions(setTimeZoneInOptions(mfFormats.time, timeZone), setTimeZoneInOptions(f1.time || {}, timeZone)) });
3996
3999
  }
3997
- var formatMessage = function(_a2, state, messageDescriptor, values, opts) {
3998
- var locale = _a2.locale, formats = _a2.formats, messages = _a2.messages, defaultLocale = _a2.defaultLocale, defaultFormats = _a2.defaultFormats, fallbackOnEmptyString = _a2.fallbackOnEmptyString, onError = _a2.onError, timeZone = _a2.timeZone, defaultRichTextElements = _a2.defaultRichTextElements;
4000
+ var formatMessage = function(_a3, state, messageDescriptor, values, opts) {
4001
+ var locale = _a3.locale, formats = _a3.formats, messages = _a3.messages, defaultLocale = _a3.defaultLocale, defaultFormats = _a3.defaultFormats, fallbackOnEmptyString = _a3.fallbackOnEmptyString, onError = _a3.onError, timeZone = _a3.timeZone, defaultRichTextElements = _a3.defaultRichTextElements;
3999
4002
  if (messageDescriptor === void 0) {
4000
4003
  messageDescriptor = { id: "" };
4001
4004
  }
@@ -4014,7 +4017,7 @@ var ReactIntl = (() => {
4014
4017
  if (!values && message && typeof message === "string" && !defaultRichTextElements) {
4015
4018
  return message.replace(/'\{(.*?)\}'/gi, "{$1}");
4016
4019
  }
4017
- values = __assign(__assign({}, defaultRichTextElements), values || {});
4020
+ values = __assign(__assign({}, defaultRichTextElements), values);
4018
4021
  formats = deepMergeFormatsAndSetTimeZone(formats, timeZone);
4019
4022
  defaultFormats = deepMergeFormatsAndSetTimeZone(defaultFormats, timeZone);
4020
4023
  if (!message) {
@@ -4036,7 +4039,7 @@ var ReactIntl = (() => {
4036
4039
  return id;
4037
4040
  }
4038
4041
  try {
4039
- var formatter = state.getMessageFormat(message, locale, formats, __assign({ formatters: state }, opts || {}));
4042
+ var formatter = state.getMessageFormat(message, locale, formats, __assign({ formatters: state }, opts));
4040
4043
  return formatter.format(values);
4041
4044
  } catch (e) {
4042
4045
  onError(new MessageFormatError('Error formatting message: "'.concat(id, '", using ').concat(defaultMessage ? "default message" : "id", " as fallback."), locale, messageDescriptor, e));
@@ -4058,7 +4061,7 @@ var ReactIntl = (() => {
4058
4061
  return id;
4059
4062
  };
4060
4063
 
4061
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/dateTime.js
4064
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/dateTime.js
4062
4065
  var DATE_TIME_FORMAT_OPTIONS = [
4063
4066
  "formatMatcher",
4064
4067
  "timeZone",
@@ -4080,8 +4083,8 @@ var ReactIntl = (() => {
4080
4083
  "numberingSystem",
4081
4084
  "fractionalSecondDigits"
4082
4085
  ];
4083
- function getFormatter(_a2, type, getDateTimeFormat, options) {
4084
- var locale = _a2.locale, formats = _a2.formats, onError = _a2.onError, timeZone = _a2.timeZone;
4086
+ function getFormatter(_a3, type, getDateTimeFormat, options) {
4087
+ var locale = _a3.locale, formats = _a3.formats, onError = _a3.onError, timeZone = _a3.timeZone;
4085
4088
  if (options === void 0) {
4086
4089
  options = {};
4087
4090
  }
@@ -4094,11 +4097,11 @@ var ReactIntl = (() => {
4094
4097
  return getDateTimeFormat(locale, filteredOptions);
4095
4098
  }
4096
4099
  function formatDate(config, getDateTimeFormat) {
4097
- var _a2 = [];
4100
+ var _a3 = [];
4098
4101
  for (var _i = 2; _i < arguments.length; _i++) {
4099
- _a2[_i - 2] = arguments[_i];
4102
+ _a3[_i - 2] = arguments[_i];
4100
4103
  }
4101
- var value = _a2[0], _b = _a2[1], options = _b === void 0 ? {} : _b;
4104
+ var value = _a3[0], _b = _a3[1], options = _b === void 0 ? {} : _b;
4102
4105
  var date = typeof value === "string" ? new Date(value || 0) : value;
4103
4106
  try {
4104
4107
  return getFormatter(config, "date", getDateTimeFormat, options).format(date);
@@ -4108,11 +4111,11 @@ var ReactIntl = (() => {
4108
4111
  return String(date);
4109
4112
  }
4110
4113
  function formatTime(config, getDateTimeFormat) {
4111
- var _a2 = [];
4114
+ var _a3 = [];
4112
4115
  for (var _i = 2; _i < arguments.length; _i++) {
4113
- _a2[_i - 2] = arguments[_i];
4116
+ _a3[_i - 2] = arguments[_i];
4114
4117
  }
4115
- var value = _a2[0], _b = _a2[1], options = _b === void 0 ? {} : _b;
4118
+ var value = _a3[0], _b = _a3[1], options = _b === void 0 ? {} : _b;
4116
4119
  var date = typeof value === "string" ? new Date(value || 0) : value;
4117
4120
  try {
4118
4121
  return getFormatter(config, "time", getDateTimeFormat, options).format(date);
@@ -4122,11 +4125,11 @@ var ReactIntl = (() => {
4122
4125
  return String(date);
4123
4126
  }
4124
4127
  function formatDateTimeRange(config, getDateTimeFormat) {
4125
- var _a2 = [];
4128
+ var _a3 = [];
4126
4129
  for (var _i = 2; _i < arguments.length; _i++) {
4127
- _a2[_i - 2] = arguments[_i];
4130
+ _a3[_i - 2] = arguments[_i];
4128
4131
  }
4129
- var from = _a2[0], to = _a2[1], _b = _a2[2], options = _b === void 0 ? {} : _b;
4132
+ var from = _a3[0], to = _a3[1], _b = _a3[2], options = _b === void 0 ? {} : _b;
4130
4133
  var fromDate = typeof from === "string" ? new Date(from || 0) : from;
4131
4134
  var toDate = typeof to === "string" ? new Date(to || 0) : to;
4132
4135
  try {
@@ -4137,11 +4140,11 @@ var ReactIntl = (() => {
4137
4140
  return String(fromDate);
4138
4141
  }
4139
4142
  function formatDateToParts(config, getDateTimeFormat) {
4140
- var _a2 = [];
4143
+ var _a3 = [];
4141
4144
  for (var _i = 2; _i < arguments.length; _i++) {
4142
- _a2[_i - 2] = arguments[_i];
4145
+ _a3[_i - 2] = arguments[_i];
4143
4146
  }
4144
- var value = _a2[0], _b = _a2[1], options = _b === void 0 ? {} : _b;
4147
+ var value = _a3[0], _b = _a3[1], options = _b === void 0 ? {} : _b;
4145
4148
  var date = typeof value === "string" ? new Date(value || 0) : value;
4146
4149
  try {
4147
4150
  return getFormatter(config, "date", getDateTimeFormat, options).formatToParts(date);
@@ -4151,11 +4154,11 @@ var ReactIntl = (() => {
4151
4154
  return [];
4152
4155
  }
4153
4156
  function formatTimeToParts(config, getDateTimeFormat) {
4154
- var _a2 = [];
4157
+ var _a3 = [];
4155
4158
  for (var _i = 2; _i < arguments.length; _i++) {
4156
- _a2[_i - 2] = arguments[_i];
4159
+ _a3[_i - 2] = arguments[_i];
4157
4160
  }
4158
- var value = _a2[0], _b = _a2[1], options = _b === void 0 ? {} : _b;
4161
+ var value = _a3[0], _b = _a3[1], options = _b === void 0 ? {} : _b;
4159
4162
  var date = typeof value === "string" ? new Date(value || 0) : value;
4160
4163
  try {
4161
4164
  return getFormatter(config, "time", getDateTimeFormat, options).formatToParts(date);
@@ -4165,15 +4168,15 @@ var ReactIntl = (() => {
4165
4168
  return [];
4166
4169
  }
4167
4170
 
4168
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/displayName.js
4171
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/displayName.js
4169
4172
  var DISPLAY_NAMES_OPTONS = [
4170
4173
  "style",
4171
4174
  "type",
4172
4175
  "fallback",
4173
4176
  "languageDisplay"
4174
4177
  ];
4175
- function formatDisplayName(_a2, getDisplayNames, value, options) {
4176
- var locale = _a2.locale, onError = _a2.onError;
4178
+ function formatDisplayName(_a3, getDisplayNames, value, options) {
4179
+ var locale = _a3.locale, onError = _a3.onError;
4177
4180
  var DisplayNames = Intl.DisplayNames;
4178
4181
  if (!DisplayNames) {
4179
4182
  onError(new FormatError('Intl.DisplayNames is not available in this environment.\nTry polyfilling it using "@formatjs/intl-displaynames"\n', ErrorCode.MISSING_INTL_API));
@@ -4186,7 +4189,7 @@ var ReactIntl = (() => {
4186
4189
  }
4187
4190
  }
4188
4191
 
4189
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/list.js
4192
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/list.js
4190
4193
  var LIST_FORMAT_OPTIONS = [
4191
4194
  "type",
4192
4195
  "style"
@@ -4212,8 +4215,8 @@ var ReactIntl = (() => {
4212
4215
  }, []);
4213
4216
  return results.length === 1 ? results[0] : results.length === 0 ? "" : results;
4214
4217
  }
4215
- function formatListToParts(_a2, getListFormat, values, options) {
4216
- var locale = _a2.locale, onError = _a2.onError;
4218
+ function formatListToParts(_a3, getListFormat, values, options) {
4219
+ var locale = _a3.locale, onError = _a3.onError;
4217
4220
  if (options === void 0) {
4218
4221
  options = {};
4219
4222
  }
@@ -4241,10 +4244,10 @@ var ReactIntl = (() => {
4241
4244
  return values;
4242
4245
  }
4243
4246
 
4244
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/plural.js
4247
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/plural.js
4245
4248
  var PLURAL_FORMAT_OPTIONS = ["type"];
4246
- function formatPlural(_a2, getPluralRules, value, options) {
4247
- var locale = _a2.locale, onError = _a2.onError;
4249
+ function formatPlural(_a3, getPluralRules, value, options) {
4250
+ var locale = _a3.locale, onError = _a3.onError;
4248
4251
  if (options === void 0) {
4249
4252
  options = {};
4250
4253
  }
@@ -4260,10 +4263,10 @@ var ReactIntl = (() => {
4260
4263
  return "other";
4261
4264
  }
4262
4265
 
4263
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/relativeTime.js
4266
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/relativeTime.js
4264
4267
  var RELATIVE_TIME_FORMAT_OPTIONS = ["numeric", "style"];
4265
- function getFormatter2(_a2, getRelativeTimeFormat, options) {
4266
- var locale = _a2.locale, formats = _a2.formats, onError = _a2.onError;
4268
+ function getFormatter2(_a3, getRelativeTimeFormat, options) {
4269
+ var locale = _a3.locale, formats = _a3.formats, onError = _a3.onError;
4267
4270
  if (options === void 0) {
4268
4271
  options = {};
4269
4272
  }
@@ -4291,7 +4294,7 @@ var ReactIntl = (() => {
4291
4294
  return String(value);
4292
4295
  }
4293
4296
 
4294
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/number.js
4297
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/number.js
4295
4298
  var NUMBER_FORMAT_OPTIONS = [
4296
4299
  "style",
4297
4300
  "currency",
@@ -4318,8 +4321,8 @@ var ReactIntl = (() => {
4318
4321
  "roundingIncrement",
4319
4322
  "roundingMode"
4320
4323
  ];
4321
- function getFormatter3(_a2, getNumberFormat, options) {
4322
- var locale = _a2.locale, formats = _a2.formats, onError = _a2.onError;
4324
+ function getFormatter3(_a3, getNumberFormat, options) {
4325
+ var locale = _a3.locale, formats = _a3.formats, onError = _a3.onError;
4323
4326
  if (options === void 0) {
4324
4327
  options = {};
4325
4328
  }
@@ -4351,7 +4354,7 @@ var ReactIntl = (() => {
4351
4354
  return [];
4352
4355
  }
4353
4356
 
4354
- // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/lib/src/create-intl.js
4357
+ // node_modules/.aspect_rules_js/@formatjs+intl@0.0.0/node_modules/@formatjs/intl/src/create-intl.js
4355
4358
  function messagesContainString(messages) {
4356
4359
  var firstMessage = messages ? messages[Object.keys(messages)[0]] : void 0;
4357
4360
  return typeof firstMessage === "string";
@@ -4379,7 +4382,7 @@ var ReactIntl = (() => {
4379
4382
  return __assign(__assign({}, resolvedConfig), { formatters, formatNumber: formatNumber.bind(null, resolvedConfig, formatters.getNumberFormat), formatNumberToParts: formatNumberToParts.bind(null, resolvedConfig, formatters.getNumberFormat), formatRelativeTime: formatRelativeTime.bind(null, resolvedConfig, formatters.getRelativeTimeFormat), formatDate: formatDate.bind(null, resolvedConfig, formatters.getDateTimeFormat), formatDateToParts: formatDateToParts.bind(null, resolvedConfig, formatters.getDateTimeFormat), formatTime: formatTime.bind(null, resolvedConfig, formatters.getDateTimeFormat), formatDateTimeRange: formatDateTimeRange.bind(null, resolvedConfig, formatters.getDateTimeFormat), formatTimeToParts: formatTimeToParts.bind(null, resolvedConfig, formatters.getDateTimeFormat), formatPlural: formatPlural.bind(null, resolvedConfig, formatters.getPluralRules), formatMessage: formatMessage.bind(null, resolvedConfig, formatters), $t: formatMessage.bind(null, resolvedConfig, formatters), formatList: formatList.bind(null, resolvedConfig, formatters.getListFormat), formatListToParts: formatListToParts.bind(null, resolvedConfig, formatters.getListFormat), formatDisplayName: formatDisplayName.bind(null, resolvedConfig, formatters.getDisplayNames) });
4380
4383
  }
4381
4384
 
4382
- // packages/react-intl/src/utils.ts
4385
+ // packages/react-intl/src/utils.tsx
4383
4386
  function invariant2(condition, message, Err = Error) {
4384
4387
  if (!condition) {
4385
4388
  throw new Err(message);
@@ -4394,17 +4397,14 @@ var ReactIntl = (() => {
4394
4397
  var DEFAULT_INTL_CONFIG2 = __spreadProps(__spreadValues({}, DEFAULT_INTL_CONFIG), {
4395
4398
  textComponent: React.Fragment
4396
4399
  });
4397
- var toKeyedReactNode = (reactNode, key) => React.isValidElement(reactNode) ? React.cloneElement(reactNode, { key }) : reactNode;
4398
4400
  var toKeyedReactNodeArray = (children) => {
4399
- var _a2;
4400
- return (
4401
- /**
4402
- * Note: {@link React.Children.map} will add its own index-based prefix to
4403
- * every key anyway, so the auto-injected one doesn't even have to be unique.
4404
- * This basically just tells React that it's explicit/intentional.
4405
- */
4406
- (_a2 = React.Children.map(children, toKeyedReactNode)) != null ? _a2 : []
4407
- );
4401
+ const childrenArray = React.Children.toArray(children);
4402
+ return childrenArray.map((child, index) => {
4403
+ if (React.isValidElement(child)) {
4404
+ return React.createElement(React.Fragment, { key: index }, child);
4405
+ }
4406
+ return child;
4407
+ });
4408
4408
  };
4409
4409
  function assignUniqueKeysToParts(formatXMLElementFn) {
4410
4410
  return function(parts) {
@@ -4434,8 +4434,10 @@ var ReactIntl = (() => {
4434
4434
  }
4435
4435
 
4436
4436
  // packages/react-intl/src/components/injectIntl.tsx
4437
- var import_hoist_non_react_statics = __toESM(require_hoist_non_react_statics_cjs());
4437
+ var hoistNonReactStaticsNs = __toESM(require_hoist_non_react_statics_cjs());
4438
4438
  var React2 = __toESM(window.React);
4439
+ var _a2;
4440
+ var hoistNonReactStatics = (_a2 = hoistNonReactStaticsNs.default) != null ? _a2 : hoistNonReactStaticsNs;
4439
4441
  function getDisplayName(Component) {
4440
4442
  return Component.displayName || Component.name || "Component";
4441
4443
  }
@@ -4466,13 +4468,13 @@ var ReactIntl = (() => {
4466
4468
  WithIntl.displayName = `injectIntl(${getDisplayName(WrappedComponent)})`;
4467
4469
  WithIntl.WrappedComponent = WrappedComponent;
4468
4470
  if (forwardRef2) {
4469
- return (0, import_hoist_non_react_statics.default)(
4471
+ return hoistNonReactStatics(
4470
4472
  // @ts-expect-error
4471
4473
  React2.forwardRef((props, ref) => React2.createElement(WithIntl, __spreadProps(__spreadValues({}, props), { forwardedRef: ref }))),
4472
4474
  WrappedComponent
4473
4475
  );
4474
4476
  }
4475
- return (0, import_hoist_non_react_statics.default)(WithIntl, WrappedComponent);
4477
+ return hoistNonReactStatics(WithIntl, WrappedComponent);
4476
4478
  }
4477
4479
 
4478
4480
  // packages/react-intl/src/components/useIntl.ts
@@ -4500,20 +4502,20 @@ var ReactIntl = (() => {
4500
4502
  })(DisplayNameParts || {});
4501
4503
  var FormattedNumberParts = (props) => {
4502
4504
  const intl = useIntl();
4503
- const _a2 = props, { value, children } = _a2, formatProps = __objRest(_a2, ["value", "children"]);
4505
+ const _a3 = props, { value, children } = _a3, formatProps = __objRest(_a3, ["value", "children"]);
4504
4506
  return children(intl.formatNumberToParts(value, formatProps));
4505
4507
  };
4506
4508
  FormattedNumberParts.displayName = "FormattedNumberParts";
4507
4509
  var FormattedListParts = (props) => {
4508
4510
  const intl = useIntl();
4509
- const _a2 = props, { value, children } = _a2, formatProps = __objRest(_a2, ["value", "children"]);
4511
+ const _a3 = props, { value, children } = _a3, formatProps = __objRest(_a3, ["value", "children"]);
4510
4512
  return children(intl.formatListToParts(value, formatProps));
4511
4513
  };
4512
4514
  FormattedNumberParts.displayName = "FormattedNumberParts";
4513
4515
  function createFormattedDateTimePartsComponent(name) {
4514
4516
  const ComponentParts = (props) => {
4515
4517
  const intl = useIntl();
4516
- const _a2 = props, { value, children } = _a2, formatProps = __objRest(_a2, ["value", "children"]);
4518
+ const _a3 = props, { value, children } = _a3, formatProps = __objRest(_a3, ["value", "children"]);
4517
4519
  const date = typeof value === "string" ? new Date(value || 0) : value;
4518
4520
  const formattedParts = name === "formatDate" ? intl.formatDateToParts(date, formatProps) : intl.formatTimeToParts(date, formatProps);
4519
4521
  return children(formattedParts);
@@ -4524,7 +4526,7 @@ var ReactIntl = (() => {
4524
4526
  function createFormattedComponent(name) {
4525
4527
  const Component = (props) => {
4526
4528
  const intl = useIntl();
4527
- const _a2 = props, { value, children } = _a2, formatProps = __objRest(_a2, ["value", "children"]);
4529
+ const _a3 = props, { value, children } = _a3, formatProps = __objRest(_a3, ["value", "children"]);
4528
4530
  const formattedValue = intl[name](value, formatProps);
4529
4531
  if (typeof children === "function") {
4530
4532
  return children(formattedValue);
@@ -4561,8 +4563,8 @@ var ReactIntl = (() => {
4561
4563
  }
4562
4564
  return chunks;
4563
4565
  };
4564
- var createIntl2 = (_a2, cache) => {
4565
- var _b = _a2, { defaultRichTextElements: rawDefaultRichTextElements } = _b, config = __objRest(_b, ["defaultRichTextElements"]);
4566
+ var createIntl2 = (_a3, cache) => {
4567
+ var _b = _a3, { defaultRichTextElements: rawDefaultRichTextElements } = _b, config = __objRest(_b, ["defaultRichTextElements"]);
4566
4568
  const defaultRichTextElements = assignUniqueKeysToFormatXMLElementFnArgument(
4567
4569
  rawDefaultRichTextElements
4568
4570
  );
@@ -4597,7 +4599,7 @@ var ReactIntl = (() => {
4597
4599
  var React5 = __toESM(window.React);
4598
4600
  var FormattedDateTimeRange = (props) => {
4599
4601
  const intl = useIntl();
4600
- const _a2 = props, { from, to, children } = _a2, formatProps = __objRest(_a2, ["from", "to", "children"]);
4602
+ const _a3 = props, { from, to, children } = _a3, formatProps = __objRest(_a3, ["from", "to", "children"]);
4601
4603
  const formattedValue = intl.formatDateTimeRange(from, to, formatProps);
4602
4604
  if (typeof children === "function") {
4603
4605
  return children(formattedValue);
@@ -4611,7 +4613,7 @@ var ReactIntl = (() => {
4611
4613
  // packages/react-intl/src/components/message.tsx
4612
4614
  var React6 = __toESM(window.React);
4613
4615
  function areEqual(prevProps, nextProps) {
4614
- const _a2 = prevProps, { values } = _a2, otherProps = __objRest(_a2, ["values"]);
4616
+ const _a3 = prevProps, { values } = _a3, otherProps = __objRest(_a3, ["values"]);
4615
4617
  const _b = nextProps, { values: nextValues } = _b, nextOtherProps = __objRest(_b, ["values"]);
4616
4618
  return shallowEqual(nextValues, values) && shallowEqual(otherProps, nextOtherProps);
4617
4619
  }
@@ -4764,7 +4766,7 @@ var ReactIntl = (() => {
4764
4766
  }
4765
4767
  var SimpleFormattedRelativeTime = (props) => {
4766
4768
  const { formatRelativeTime: formatRelativeTime2, textComponent: Text } = useIntl();
4767
- const _a2 = props, { children, value, unit } = _a2, otherProps = __objRest(_a2, ["children", "value", "unit"]);
4769
+ const _a3 = props, { children, value, unit } = _a3, otherProps = __objRest(_a3, ["children", "value", "unit"]);
4768
4770
  const formattedRelativeTime = formatRelativeTime2(value || 0, unit, otherProps);
4769
4771
  if (typeof children === "function") {
4770
4772
  return children(formattedRelativeTime);
@@ -4774,8 +4776,8 @@ var ReactIntl = (() => {
4774
4776
  }
4775
4777
  return React9.createElement(React9.Fragment, null, formattedRelativeTime);
4776
4778
  };
4777
- var FormattedRelativeTime = (_a2) => {
4778
- var _b = _a2, {
4779
+ var FormattedRelativeTime = (_a3) => {
4780
+ var _b = _a3, {
4779
4781
  value = 0,
4780
4782
  unit = "second",
4781
4783
  updateIntervalInSeconds