@titaui/pc 1.10.52-beta.1 → 1.10.54-beta.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.
@@ -67,7 +67,16 @@ var DynamicReply = function DynamicReply(_ref) {
67
67
  searchKeyWord = _useContext.searchKeyWord;
68
68
 
69
69
  var handleClickTitle = function handleClickTitle() {
70
- // @ts-ignore
70
+ if (window.titaTracker) {
71
+ window.titaTracker("planAction").record({
72
+ actionName: "查看日报",
73
+ actionGroup: "动态-推屏",
74
+ productName: "动态",
75
+ planId: data.dailyId
76
+ });
77
+ } // @ts-ignore
78
+
79
+
71
80
  window.Talent.app.vent.trigger("global-daily-detail-pull-screen", feedId);
72
81
  };
73
82
 
@@ -164,6 +164,17 @@ var DynamicItem = function DynamicItem(_ref) {
164
164
  };
165
165
 
166
166
  var handleShowMore = function handleShowMore() {
167
+ if (data.feedType === _constant.EFeedType.Report) {
168
+ if (window.titaTracker) {
169
+ window.titaTracker("planAction").record({
170
+ actionName: "查看日报",
171
+ actionGroup: "动态-查看更多",
172
+ productName: "动态",
173
+ planId: data.dailyId
174
+ });
175
+ }
176
+ }
177
+
167
178
  setIsFold(false);
168
179
  };
169
180
 
@@ -34,7 +34,7 @@
34
34
  height: 476px;
35
35
  border-radius: 24px;
36
36
  background: #ffffff;
37
- box-shadow: 0px 0px 16px 0px rgba(127, 145, 180, 0.1);
37
+ box-shadow: 0px 8px 24px 0px rgba(127, 145, 180, 0.16);
38
38
  }
39
39
 
40
40
  .help-card__header {
@@ -56,8 +56,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
56
56
  var preCls = "titaui-user-message-msg-reply";
57
57
 
58
58
  function Reply(props) {
59
- var onItemClick = props.onItemClick,
60
- handleIntervalRequestMessageInfo = props.handleIntervalRequestMessageInfo;
59
+ var onItemClick = props.onItemClick;
61
60
 
62
61
  var _useState = (0, _react.useState)([]),
63
62
  _useState2 = _slicedToArray(_useState, 2),
@@ -108,6 +107,10 @@ function Reply(props) {
108
107
  }
109
108
  };
110
109
 
110
+ var handleDeleteReply = function handleDeleteReply(msgId) {
111
+ (0, _request.deleteReply)(msgId);
112
+ };
113
+
111
114
  (0, _react.useEffect)(function () {
112
115
  setTimeout(function () {
113
116
  (0, _request.getReplys)(1).then(function (res) {
@@ -118,17 +121,14 @@ function Reply(props) {
118
121
 
119
122
  setIsLoading(false);
120
123
  });
121
- (0, _request.clearReplys)().then(function () {
122
- return handleIntervalRequestMessageInfo();
123
- });
124
124
  }, 300);
125
125
  }, []);
126
- console.log(replys);
127
126
  return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
128
127
  condition: isLoading
129
128
  }, /*#__PURE__*/_react["default"].createElement("img", {
130
129
  src: _loading["default"],
131
- className: (0, _classnames["default"])("".concat(preCls, "__loading"))
130
+ className: (0, _classnames["default"])("".concat(preCls, "__loading")),
131
+ alt: "\u6B63\u5728\u8BF7\u6C42"
132
132
  })), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
133
133
  condition: replys.length !== 0
134
134
  }, /*#__PURE__*/_react["default"].createElement("ul", {
@@ -144,7 +144,8 @@ function Reply(props) {
144
144
  return /*#__PURE__*/_react["default"].createElement(_replyItem["default"], {
145
145
  item: item,
146
146
  onItemClick: onItemClick,
147
- replys: replys
147
+ replys: replys,
148
+ handleDeleteReply: handleDeleteReply
148
149
  });
149
150
  })), /*#__PURE__*/_react["default"].createElement("div", {
150
151
  className: (0, _classnames["default"])("".concat(preCls, "__footer"))
@@ -30,14 +30,17 @@ var preCls = "titaui-user-message-msg-reply";
30
30
  function Reply(props) {
31
31
  var item = props.item,
32
32
  onItemClick = props.onItemClick,
33
- replys = props.replys;
33
+ replys = props.replys,
34
+ handleDeleteReply = props.handleDeleteReply;
34
35
 
35
36
  var handleReplyClick = function handleReplyClick() {
36
- onItemClick && onItemClick(false);
37
+ if (onItemClick) {
38
+ onItemClick(false);
39
+ }
37
40
  };
38
41
 
39
42
  var getDescText = function getDescText() {
40
- if (item.content.indexOf("@") != -1) {
43
+ if (item.content.indexOf("@") !== -1) {
41
44
  return "@我";
42
45
  }
43
46
 
@@ -56,8 +59,15 @@ function Reply(props) {
56
59
  return (0, _utils.deleteText)((0, _utils.htmlToText)(item.content));
57
60
  };
58
61
 
59
- return /*#__PURE__*/_react["default"].createElement("li", {
60
- className: (0, _classnames["default"])("".concat(preCls, "__item"), _defineProperty({}, "".concat(preCls, "__item--scroll"), replys.length >= 4))
62
+ var handleReplyItemClick = function handleReplyItemClick(msgId) {
63
+ handleDeleteReply(msgId);
64
+ };
65
+
66
+ return /*#__PURE__*/_react["default"].createElement("div", {
67
+ className: (0, _classnames["default"])("".concat(preCls, "__item"), _defineProperty({}, "".concat(preCls, "__item--scroll"), replys.length >= 4)),
68
+ onClick: function onClick() {
69
+ return handleReplyItemClick(item.msgId);
70
+ }
61
71
  }, /*#__PURE__*/_react["default"].createElement("div", {
62
72
  className: (0, _classnames["default"])("".concat(preCls, "__item-photo"))
63
73
  }, /*#__PURE__*/_react["default"].createElement(_avatar["default"], {
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.getTodos = exports.getReplys = exports.getReminds = exports.getMessages = exports.getInforms = exports.getData = exports.clearReplys = exports.clearInforms = exports.changeLang = void 0;
6
+ exports.getTodos = exports.getReplys = exports.getReminds = exports.getMessages = exports.getInforms = exports.getData = exports.deleteReply = exports.clearReplys = exports.clearInforms = exports.changeLang = void 0;
7
7
 
8
8
  var _axios = _interopRequireDefault(require("axios"));
9
9
 
@@ -65,6 +65,12 @@ var clearReplys = function clearReplys() {
65
65
 
66
66
  exports.clearReplys = clearReplys;
67
67
 
68
+ var deleteReply = function deleteReply(msgId) {
69
+ return (0, _request.rpost)("v1")("messages/clear?msgId=".concat(msgId));
70
+ };
71
+
72
+ exports.deleteReply = deleteReply;
73
+
68
74
  var getMessages = function getMessages() {
69
75
  var nowTime = new Date();
70
76
  var year = nowTime.getFullYear();
@@ -104,7 +104,7 @@
104
104
  justify-content: center;
105
105
  align-items: center;
106
106
  background: #ffffff;
107
- box-shadow: 0px 0px 16px 0px rgba(127, 145, 180, 0.1);
107
+ box-shadow: 0px 8px 24px 0px rgba(127, 145, 180, 0.16);
108
108
  border-radius: 24px;
109
109
  }
110
110
 
@@ -150,7 +150,7 @@ function PageLayout(props) {
150
150
  }
151
151
  }, children), !isTencentHr && /*#__PURE__*/_react["default"].createElement("div", {
152
152
  className: (0, _classnames["default"])("".concat(preCls, "__help"))
153
- }, /*#__PURE__*/_react["default"].createElement(_helpCard["default"], null)), !isTrial && !isTencentHr && !(0, _helpers.isDingDing)() && /*#__PURE__*/_react["default"].createElement(_popup["default"], {
153
+ }, /*#__PURE__*/_react["default"].createElement(_helpCard["default"], null)), !isTencentHr && !(0, _helpers.isDingDing)() && !(0, _helpers.isFeishu)() && /*#__PURE__*/_react["default"].createElement(_popup["default"], {
154
154
  popup: popup,
155
155
  popupTransitionName: "tita-popup-zoom-left-bottom",
156
156
  placement: "topLeft",
@@ -8,7 +8,7 @@ exports.escapeHtml = escapeHtml;
8
8
  exports.getLoginUserInfo = void 0;
9
9
  exports.getTenantInfo = getTenantInfo;
10
10
  exports.getUploadMaxSize = getUploadMaxSize;
11
- exports.isTencentHr = exports.isLocal = exports.isDingDing = void 0;
11
+ exports.isTencentHr = exports.isLocal = exports.isFeishu = exports.isDingDing = void 0;
12
12
 
13
13
  var _bsGlobal = require("./bs-global");
14
14
 
@@ -43,6 +43,12 @@ var isDingDing = function isDingDing() {
43
43
 
44
44
  exports.isDingDing = isDingDing;
45
45
 
46
+ var isFeishu = function isFeishu() {
47
+ return getTenantInfo().Source === 862;
48
+ };
49
+
50
+ exports.isFeishu = isFeishu;
51
+
46
52
  var isLocal = function isLocal() {
47
53
  return !!getTenantInfo().isLocal;
48
54
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@titaui/pc",
3
- "version": "1.10.52-beta.1",
3
+ "version": "1.10.54-beta.1",
4
4
  "nameCN": "",
5
5
  "description": "",
6
6
  "main": "lib/index.js",