intl-messageformat 9.6.7 → 9.6.8

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.
@@ -469,7 +469,7 @@ var IntlMessageFormat = (function() {
469
469
  });
470
470
  });
471
471
 
472
- // bazel-out/k8-fastbuild/bin/packages/icu-messageformat-parser/error.js
472
+ // bazel-out/darwin-fastbuild/bin/packages/icu-messageformat-parser/error.js
473
473
  var require_error = __commonJS(function(exports) {
474
474
  "use strict";
475
475
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -505,7 +505,7 @@ var IntlMessageFormat = (function() {
505
505
  })(ErrorKind = exports.ErrorKind || (exports.ErrorKind = {}));
506
506
  });
507
507
 
508
- // bazel-out/k8-fastbuild/bin/packages/icu-messageformat-parser/types.js
508
+ // bazel-out/darwin-fastbuild/bin/packages/icu-messageformat-parser/types.js
509
509
  var require_types = __commonJS(function(exports) {
510
510
  "use strict";
511
511
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -588,7 +588,7 @@ var IntlMessageFormat = (function() {
588
588
  exports.createNumberElement = createNumberElement;
589
589
  });
590
590
 
591
- // bazel-out/k8-fastbuild/bin/packages/icu-messageformat-parser/regex.generated.js
591
+ // bazel-out/darwin-fastbuild/bin/packages/icu-messageformat-parser/regex.generated.js
592
592
  var require_regex_generated = __commonJS(function(exports) {
593
593
  "use strict";
594
594
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -598,7 +598,7 @@ var IntlMessageFormat = (function() {
598
598
  exports.WHITE_SPACE_REGEX = /[\t-\r \x85\u200E\u200F\u2028\u2029]/i;
599
599
  });
600
600
 
601
- // bazel-out/k8-fastbuild/bin/packages/icu-skeleton-parser/date-time.js
601
+ // bazel-out/darwin-fastbuild/bin/packages/icu-skeleton-parser/date-time.js
602
602
  var require_date_time = __commonJS(function(exports) {
603
603
  "use strict";
604
604
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -705,7 +705,7 @@ var IntlMessageFormat = (function() {
705
705
  exports.parseDateTimeSkeleton = parseDateTimeSkeleton;
706
706
  });
707
707
 
708
- // bazel-out/k8-fastbuild/bin/packages/icu-skeleton-parser/regex.generated.js
708
+ // bazel-out/darwin-fastbuild/bin/packages/icu-skeleton-parser/regex.generated.js
709
709
  var require_regex_generated2 = __commonJS(function(exports) {
710
710
  "use strict";
711
711
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -713,7 +713,7 @@ var IntlMessageFormat = (function() {
713
713
  exports.WHITE_SPACE_REGEX = /[\t-\r \x85\u200E\u200F\u2028\u2029]/i;
714
714
  });
715
715
 
716
- // bazel-out/k8-fastbuild/bin/packages/icu-skeleton-parser/number.js
716
+ // bazel-out/darwin-fastbuild/bin/packages/icu-skeleton-parser/number.js
717
717
  var require_number = __commonJS(function(exports) {
718
718
  "use strict";
719
719
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -980,7 +980,7 @@ var IntlMessageFormat = (function() {
980
980
  exports.parseNumberSkeleton = parseNumberSkeleton;
981
981
  });
982
982
 
983
- // bazel-out/k8-fastbuild/bin/packages/icu-skeleton-parser/index.js
983
+ // bazel-out/darwin-fastbuild/bin/packages/icu-skeleton-parser/index.js
984
984
  var require_icu_skeleton_parser = __commonJS(function(exports) {
985
985
  "use strict";
986
986
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -989,9 +989,10 @@ var IntlMessageFormat = (function() {
989
989
  tslib_1.__exportStar(require_number(), exports);
990
990
  });
991
991
 
992
- // bazel-out/k8-fastbuild/bin/packages/icu-messageformat-parser/parser.js
992
+ // bazel-out/darwin-fastbuild/bin/packages/icu-messageformat-parser/parser.js
993
993
  var require_parser = __commonJS(function(exports) {
994
994
  "use strict";
995
+ var _a;
995
996
  Object.defineProperty(exports, "__esModule", {value: true});
996
997
  exports.Parser = void 0;
997
998
  var tslib_1 = require_tslib();
@@ -1014,10 +1015,12 @@ var IntlMessageFormat = (function() {
1014
1015
  };
1015
1016
  var REGEX_SUPPORTS_U_AND_Y = true;
1016
1017
  try {
1017
- RE("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
1018
+ re = RE("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
1019
+ REGEX_SUPPORTS_U_AND_Y = ((_a = re.exec("a")) === null || _a === void 0 ? void 0 : _a[0]) === "a";
1018
1020
  } catch (_) {
1019
1021
  REGEX_SUPPORTS_U_AND_Y = false;
1020
1022
  }
1023
+ var re;
1021
1024
  var startsWith = hasNativeStartsWith ? function startsWith2(s, search, position) {
1022
1025
  return s.startsWith(search, position);
1023
1026
  } : function startsWith2(s, search, position) {
@@ -1043,7 +1046,7 @@ var IntlMessageFormat = (function() {
1043
1046
  var fromEntries = hasNativeFromEntries ? Object.fromEntries : function fromEntries2(entries) {
1044
1047
  var obj = {};
1045
1048
  for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) {
1046
- var _a = entries_1[_i], k = _a[0], v = _a[1];
1049
+ var _a2 = entries_1[_i], k = _a2[0], v = _a2[1];
1047
1050
  obj[k] = v;
1048
1051
  }
1049
1052
  return obj;
@@ -1076,10 +1079,10 @@ var IntlMessageFormat = (function() {
1076
1079
  if (REGEX_SUPPORTS_U_AND_Y) {
1077
1080
  IDENTIFIER_PREFIX_RE_1 = RE("([^\\p{White_Space}\\p{Pattern_Syntax}]*)", "yu");
1078
1081
  matchIdentifierAtIndex = function matchIdentifierAtIndex2(s, index) {
1079
- var _a;
1082
+ var _a2;
1080
1083
  IDENTIFIER_PREFIX_RE_1.lastIndex = index;
1081
1084
  var match = IDENTIFIER_PREFIX_RE_1.exec(s);
1082
- return (_a = match[1]) !== null && _a !== void 0 ? _a : "";
1085
+ return (_a2 = match[1]) !== null && _a2 !== void 0 ? _a2 : "";
1083
1086
  };
1084
1087
  } else {
1085
1088
  matchIdentifierAtIndex = function matchIdentifierAtIndex2(s, index) {
@@ -1354,7 +1357,7 @@ var IntlMessageFormat = (function() {
1354
1357
  return {value: value, location: location};
1355
1358
  };
1356
1359
  Parser2.prototype.parseArgumentOptions = function(nestingLevel, expectingCloseTag, value, openingBracePosition) {
1357
- var _a;
1360
+ var _a2;
1358
1361
  var typeStartPosition = this.clonePosition();
1359
1362
  var argType = this.parseIdentifierIfPossible().value;
1360
1363
  var typeEndPosition = this.clonePosition();
@@ -1418,7 +1421,7 @@ var IntlMessageFormat = (function() {
1418
1421
  type: argType === "number" ? types_1.TYPE.number : argType === "date" ? types_1.TYPE.date : types_1.TYPE.time,
1419
1422
  value: value,
1420
1423
  location: location_1,
1421
- style: (_a = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a !== void 0 ? _a : null
1424
+ style: (_a2 = styleAndLocation === null || styleAndLocation === void 0 ? void 0 : styleAndLocation.style) !== null && _a2 !== void 0 ? _a2 : null
1422
1425
  },
1423
1426
  err: null
1424
1427
  };
@@ -1550,7 +1553,7 @@ var IntlMessageFormat = (function() {
1550
1553
  };
1551
1554
  };
1552
1555
  Parser2.prototype.tryParsePluralOrSelectOptions = function(nestingLevel, parentArgType, expectCloseTag, parsedFirstIdentifier) {
1553
- var _a;
1556
+ var _a2;
1554
1557
  var hasOtherClause = false;
1555
1558
  var options = [];
1556
1559
  var parsedSelectors = new Set();
@@ -1597,7 +1600,7 @@ var IntlMessageFormat = (function() {
1597
1600
  ]);
1598
1601
  parsedSelectors.add(selector);
1599
1602
  this.bumpSpace();
1600
- _a = this.parseIdentifierIfPossible(), selector = _a.value, selectorLocation = _a.location;
1603
+ _a2 = this.parseIdentifierIfPossible(), selector = _a2.value, selectorLocation = _a2.location;
1601
1604
  }
1602
1605
  if (options.length === 0) {
1603
1606
  return this.error(parentArgType === "select" ? error_1.ErrorKind.EXPECT_SELECT_ARGUMENT_SELECTOR : error_1.ErrorKind.EXPECT_PLURAL_ARGUMENT_SELECTOR, createLocation(this.clonePosition(), this.clonePosition()));
@@ -1757,7 +1760,7 @@ var IntlMessageFormat = (function() {
1757
1760
  }
1758
1761
  });
1759
1762
 
1760
- // bazel-out/k8-fastbuild/bin/packages/icu-messageformat-parser/index.js
1763
+ // bazel-out/darwin-fastbuild/bin/packages/icu-messageformat-parser/index.js
1761
1764
  var require_icu_messageformat_parser = __commonJS(function(exports) {
1762
1765
  "use strict";
1763
1766
  Object.defineProperty(exports, "__esModule", {value: true});
@@ -1879,7 +1882,7 @@ var IntlMessageFormat = (function() {
1879
1882
  };
1880
1883
  });
1881
1884
 
1882
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/index.js
1885
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/index.js
1883
1886
  var lib_exports = {};
1884
1887
  __export(lib_exports, {
1885
1888
  ErrorCode: function() {
@@ -1914,15 +1917,15 @@ var IntlMessageFormat = (function() {
1914
1917
  }
1915
1918
  });
1916
1919
 
1917
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/src/core.js
1920
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/src/core.js
1918
1921
  var import_tslib2 = __toModule(require_tslib());
1919
1922
  var import_icu_messageformat_parser2 = __toModule(require_icu_messageformat_parser());
1920
1923
  var memoize = __toModule(require_src());
1921
1924
 
1922
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/src/formatters.js
1925
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/src/formatters.js
1923
1926
  var import_icu_messageformat_parser = __toModule(require_icu_messageformat_parser());
1924
1927
 
1925
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/src/error.js
1928
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/src/error.js
1926
1929
  var import_tslib = __toModule(require_tslib());
1927
1930
  var ErrorCode;
1928
1931
  (function(ErrorCode2) {
@@ -1965,7 +1968,7 @@ var IntlMessageFormat = (function() {
1965
1968
  return MissingValueError2;
1966
1969
  }(FormatError);
1967
1970
 
1968
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/src/formatters.js
1971
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/src/formatters.js
1969
1972
  var PART_TYPE;
1970
1973
  (function(PART_TYPE2) {
1971
1974
  PART_TYPE2[PART_TYPE2["literal"] = 0] = "literal";
@@ -2105,7 +2108,7 @@ var IntlMessageFormat = (function() {
2105
2108
  return mergeLiteral(result);
2106
2109
  }
2107
2110
 
2108
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/src/core.js
2111
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/src/core.js
2109
2112
  function mergeConfig(c1, c2) {
2110
2113
  if (!c2) {
2111
2114
  return c1;
@@ -2316,7 +2319,7 @@ var IntlMessageFormat = (function() {
2316
2319
  return IntlMessageFormat2;
2317
2320
  }();
2318
2321
 
2319
- // bazel-out/k8-fastbuild/bin/packages/intl-messageformat/lib/index.js
2322
+ // bazel-out/darwin-fastbuild/bin/packages/intl-messageformat/lib/index.js
2320
2323
  var lib_default = IntlMessageFormat;
2321
2324
  return lib_exports;
2322
2325
  })();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "intl-messageformat",
3
- "version": "9.6.7",
3
+ "version": "9.6.8",
4
4
  "description": "Formats ICU Message strings with number, date, plural, and select placeholders to create localized messages.",
5
5
  "keywords": [
6
6
  "i18n",
@@ -31,7 +31,7 @@
31
31
  "module": "lib/index.js",
32
32
  "types": "index.d.ts",
33
33
  "dependencies": {
34
- "@formatjs/icu-messageformat-parser": "1.1.5",
34
+ "@formatjs/icu-messageformat-parser": "1.1.6",
35
35
  "fast-memoize": "^2.5.2",
36
36
  "tslib": "^2.1.0"
37
37
  },