@lingui/macro 4.5.0 → 4.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -280,15 +280,11 @@ class MacroJs {
280
280
  if (currExp) {
281
281
  argTokens = this.types.isCallExpression(currExp) ? this.tokenizeNode(currExp) : [this.tokenizeExpression(currExp)];
282
282
  }
283
- return [
284
- ...value ? [
285
- {
286
- type: "text",
287
- value: this.clearBackslashes(value)
288
- }
289
- ] : [],
290
- ...argTokens
291
- ];
283
+ const textToken = {
284
+ type: "text",
285
+ value: this.clearBackslashes(value)
286
+ };
287
+ return [...value ? [textToken] : [], ...argTokens];
292
288
  });
293
289
  }
294
290
  tokenizeChoiceComponent(node) {
package/dist/index.mjs CHANGED
@@ -278,15 +278,11 @@ class MacroJs {
278
278
  if (currExp) {
279
279
  argTokens = this.types.isCallExpression(currExp) ? this.tokenizeNode(currExp) : [this.tokenizeExpression(currExp)];
280
280
  }
281
- return [
282
- ...value ? [
283
- {
284
- type: "text",
285
- value: this.clearBackslashes(value)
286
- }
287
- ] : [],
288
- ...argTokens
289
- ];
281
+ const textToken = {
282
+ type: "text",
283
+ value: this.clearBackslashes(value)
284
+ };
285
+ return [...value ? [textToken] : [], ...argTokens];
290
286
  });
291
287
  }
292
288
  tokenizeChoiceComponent(node) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lingui/macro",
3
- "version": "4.5.0",
3
+ "version": "4.6.0",
4
4
  "description": "Macro for generating messages in ICU MessageFormat syntax",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
@@ -65,9 +65,9 @@
65
65
  "dependencies": {
66
66
  "@babel/runtime": "^7.20.13",
67
67
  "@babel/types": "^7.20.7",
68
- "@lingui/conf": "4.5.0",
69
- "@lingui/core": "4.5.0",
70
- "@lingui/message-utils": "4.5.0"
68
+ "@lingui/conf": "4.6.0",
69
+ "@lingui/core": "4.6.0",
70
+ "@lingui/message-utils": "4.6.0"
71
71
  },
72
72
  "peerDependencies": {
73
73
  "@lingui/react": "^4.0.0",
@@ -82,5 +82,5 @@
82
82
  "tsd": "^0.26.1",
83
83
  "unbuild": "2.0.0"
84
84
  },
85
- "gitHead": "62c92d1f8c60b3890bdda870f307fa780d423080"
85
+ "gitHead": "2afa0efb2d0cd1d47adc76e1eec9f5e57e34ae18"
86
86
  }