cozy-search 2.2.24 → 2.2.25

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.
@@ -46,6 +46,7 @@ var EmailSourceItem = function EmailSourceItem(_ref) {
46
46
  hash: "/bridge/dashboard/".concat(emailId)
47
47
  });
48
48
  var emailDate = email['datetime'] ? new Date(email['datetime']).toISOString().slice(0, 10) : '';
49
+ var primary = [emailDate, email['email.subject']].filter(Boolean).join(' - ');
49
50
  return /*#__PURE__*/_react.default.createElement(_ListItem.default, {
50
51
  className: styles['sourcesItem'],
51
52
  component: "a",
@@ -57,8 +58,8 @@ var EmailSourceItem = function EmailSourceItem(_ref) {
57
58
  icon: _twakeIcons.Mail,
58
59
  size: 32
59
60
  })), /*#__PURE__*/_react.default.createElement(_ListItemText.default, {
60
- primary: "".concat(emailDate, " - ").concat(email['email.subject']),
61
- secondary: "".concat(email['email.preview'])
61
+ primary: primary || undefined,
62
+ secondary: email['email.preview'] || undefined
62
63
  }));
63
64
  };
64
65
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cozy-search",
3
3
  "description": "UI components about search bar and IA assistant",
4
- "version": "2.2.24",
4
+ "version": "2.2.25",
5
5
  "author": {
6
6
  "name": "Cozy Cloud",
7
7
  "url": "https://github.com/cozy"
@@ -96,5 +96,5 @@
96
96
  "lint": "cd .. && yarn eslint --ext js,jsx,ts packages/cozy-search"
97
97
  },
98
98
  "types": "dist/index.d.ts",
99
- "gitHead": "b2aab0bdbb30a76de65ee2f6663e9c205a20d9e0"
99
+ "gitHead": "87cb526b6d89c520adeeb719dd138fae65d24121"
100
100
  }