@titaui/pc 1.16.42 → 1.16.43-beta.10
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/lib/components/communication/index.js +98 -54
- package/lib/components/date-picker/BodyItem.js +3 -3
- package/lib/components/date-picker/CalendarHeader.js +3 -3
- package/lib/components/delete-confirm-pop/ConfirmPop.js +3 -3
- package/lib/components/eReport/eReportLists/reportList.js +3 -3
- package/lib/components/emotions-selector/selector-pop.js +3 -3
- package/lib/components/ereport-list/index.js +3 -3
- package/lib/components/mblog/components/MblogAction.js +3 -3
- package/lib/components/mblog/components/MblogContent.js +2 -0
- package/lib/components/mblog/index.js +3 -1
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/edit-pop.js +3 -3
- package/lib/components/okr-review/components/confirm-pop/ConfirmPop.js +3 -3
- package/lib/components/picker/components/panels/date-panel/date-body.js +27 -101
- package/lib/components/picker/components/panels/date-panel/date-head.js +8 -16
- package/lib/components/picker/components/panels/date-panel/date-rows.js +145 -0
- package/lib/components/picker/components/panels/date-panel/index.css +26 -7
- package/lib/components/picker/components/panels/date-panel/index.js +46 -11
- package/lib/components/picker/components/panels/date-panel/useRowsData.js +77 -0
- package/lib/components/picker/components/panels/month-panel/index.css +19 -9
- package/lib/components/picker/components/panels/month-panel/month-body.js +14 -56
- package/lib/components/picker/components/panels/month-panel/month-head.js +19 -2
- package/lib/components/picker/components/panels/month-panel/useRowsData.js +61 -0
- package/lib/components/picker/components/panels/panel-head/index.js +4 -0
- package/lib/components/picker/components/panels/week-panel/index.css +1 -1
- package/lib/components/picker/components/panels/year-panel/index.css +28 -6
- package/lib/components/picker/components/panels/year-panel/useRowsData.js +63 -0
- package/lib/components/picker/components/panels/year-panel/year-body.js +19 -48
- package/lib/components/picker/components/panels/year-panel/year-head.js +20 -1
- package/lib/components/picker/components/picker-trigger/index.js +1 -1
- package/lib/components/picker/context.js +19 -9
- package/lib/components/picker/index.css +16 -2
- package/lib/components/picker/picker-panels.js +14 -26
- package/lib/components/picker/picker.js +27 -28
- package/lib/components/picker/range-picker/components/picker-trigger/index.js +3 -3
- package/lib/components/picker/range-picker/components/select-input/index.js +3 -9
- package/lib/components/picker/range-picker/index.js +13 -18
- package/lib/components/picker/utils.js +11 -5
- package/lib/components/range-selector-pop/RangeSelectorPop.js +3 -3
- package/lib/components/rich-editor/models/schema.js +6 -6
- package/lib/components/rich-editor/plugins/block/block-quote/index.js +8 -8
- package/lib/components/rich-editor/plugins/block/heading/index.js +8 -8
- package/lib/components/rich-editor/plugins/block/lists/index.js +14 -14
- package/lib/components/rich-editor/plugins/block/paragraph/index.js +5 -5
- package/lib/components/rich-editor/plugins/core/index.js +4 -4
- package/lib/components/rich-editor/plugins/extension/alignment/index.js +5 -5
- package/lib/components/rich-editor/plugins/extension/placeholder/index.js +4 -4
- package/lib/components/rich-editor/plugins/inline/color/index.js +11 -11
- package/lib/components/rich-editor/plugins/inline/delete-line/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/em/index.js +5 -5
- package/lib/components/rich-editor/plugins/inline/link/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/strong/index.js +8 -8
- package/lib/components/rich-editor/plugins/inline/under-line/index.js +8 -8
- package/lib/components/rich-editor/react/uiProvider.js +3 -3
- package/lib/components/rich-editor/ui/Popup/index.js +3 -3
- package/lib/components/select/Option.js +3 -3
- package/lib/components/tita-chart/errorBoundary/index.js +3 -3
- package/lib/components-v1/animate/AnimateChild.js +3 -3
- package/lib/components-v1/avatar/index.js +3 -3
- package/lib/components-v1/dropDownSelector/StatelessDropdown.js +3 -3
- package/lib/components-v1/progress/CircleProgress.js +3 -3
- package/lib/components-v1/select/Option.js +3 -3
- package/lib/components-v1/userSelector/UserSelectorPop.js +3 -3
- package/lib/components-v1/userSelector/components/MultiMode/index.js +3 -3
- package/lib/components-v1/userSelector/components/UserItem.js +3 -3
- package/lib/utils/editor.js +7 -4
- package/package.json +2 -1
|
@@ -228,18 +228,62 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
228
228
|
isShowAllCommunicationRecord ? _this.getFeedInfo(feedId, communicationTrackTotal) : _this.getFeedInfo(feedId, commentCount);
|
|
229
229
|
};
|
|
230
230
|
|
|
231
|
-
_this.
|
|
231
|
+
_this.customSubmitCallback = function (res) {
|
|
232
|
+
var _this$state3 = _this.state,
|
|
233
|
+
communicationTrackList = _this$state3.communicationTrackList,
|
|
234
|
+
isShowAllCommunicationRecord = _this$state3.isShowAllCommunicationRecord,
|
|
235
|
+
communicationTrackTotal = _this$state3.communicationTrackTotal;
|
|
232
236
|
var _this$props4 = _this.props,
|
|
233
237
|
feedId = _this$props4.feedId,
|
|
234
|
-
commentCount = _this$props4.commentCount
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
isShowReplyToUser
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
238
|
+
commentCount = _this$props4.commentCount;
|
|
239
|
+
|
|
240
|
+
if (res.Code === 1) {
|
|
241
|
+
_this.setState({
|
|
242
|
+
submitStatus: 1,
|
|
243
|
+
isShowReplyToUser: false,
|
|
244
|
+
isShowDefaultInput: true
|
|
245
|
+
});
|
|
246
|
+
|
|
247
|
+
if (!feedId) {
|
|
248
|
+
_this.setState({
|
|
249
|
+
communicationTrackList: [].concat(_toConsumableArray(communicationTrackList), [res.Data])
|
|
250
|
+
});
|
|
251
|
+
|
|
252
|
+
return;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
if (isShowAllCommunicationRecord) _this.getFeedInfo(feedId, communicationTrackTotal + 1);else _this.getFeedInfo(feedId, commentCount);
|
|
256
|
+
} else {
|
|
257
|
+
_this.setState({
|
|
258
|
+
submitStatus: 0
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
};
|
|
262
|
+
|
|
263
|
+
_this.handlerReply = function (submitType, sentData) {
|
|
264
|
+
var _this$state4 = _this.state,
|
|
265
|
+
isShowReplyToUser = _this$state4.isShowReplyToUser,
|
|
266
|
+
replyUserCommentId = _this$state4.replyUserCommentId,
|
|
267
|
+
communicationTrackTotal = _this$state4.communicationTrackTotal,
|
|
268
|
+
isShowAllCommunicationRecord = _this$state4.isShowAllCommunicationRecord;
|
|
269
|
+
var _this$props5 = _this.props,
|
|
270
|
+
feedId = _this$props5.feedId,
|
|
271
|
+
commentCount = _this$props5.commentCount,
|
|
272
|
+
commentType = _this$props5.commentType,
|
|
273
|
+
okrFeedParams = _this$props5.okrFeedParams,
|
|
274
|
+
onReplyChange = _this$props5.onReplyChange,
|
|
275
|
+
customSubmitHandlerSync = _this$props5.customSubmitHandlerSync,
|
|
276
|
+
customSubmitHandler = _this$props5.customSubmitHandler;
|
|
277
|
+
|
|
278
|
+
if (submitType === 'submit' && customSubmitHandlerSync) {
|
|
279
|
+
customSubmitHandlerSync(sentData).then(_this.customSubmitCallback);
|
|
280
|
+
return;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
if (submitType === 'submit' && customSubmitHandler) {
|
|
284
|
+
customSubmitHandler(sentData, _this.customSubmitCallback);
|
|
285
|
+
return;
|
|
286
|
+
}
|
|
243
287
|
|
|
244
288
|
if (submitType === 'submit') {
|
|
245
289
|
// 发送
|
|
@@ -333,11 +377,11 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
333
377
|
_createClass(Communication, [{
|
|
334
378
|
key: "componentDidMount",
|
|
335
379
|
value: function componentDidMount() {
|
|
336
|
-
var _this$
|
|
337
|
-
feedId = _this$
|
|
338
|
-
commentCount = _this$
|
|
339
|
-
commentType = _this$
|
|
340
|
-
usePropsComment = _this$
|
|
380
|
+
var _this$props6 = this.props,
|
|
381
|
+
feedId = _this$props6.feedId,
|
|
382
|
+
commentCount = _this$props6.commentCount,
|
|
383
|
+
commentType = _this$props6.commentType,
|
|
384
|
+
usePropsComment = _this$props6.usePropsComment;
|
|
341
385
|
|
|
342
386
|
if ((feedId || commentType === 2) && !usePropsComment) {
|
|
343
387
|
this.getFeedInfo(feedId, commentCount);
|
|
@@ -347,9 +391,9 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
347
391
|
key: "componentDidUpdate",
|
|
348
392
|
value: function componentDidUpdate(prevProps, prevState) {
|
|
349
393
|
if (prevProps.feedId !== this.props.feedId || prevProps.okrFeedParams !== this.props.okrFeedParams || prevProps.usePropsComment !== this.props.usePropsComment) {
|
|
350
|
-
var _this$
|
|
351
|
-
feedId = _this$
|
|
352
|
-
commentCount = _this$
|
|
394
|
+
var _this$props7 = this.props,
|
|
395
|
+
feedId = _this$props7.feedId,
|
|
396
|
+
commentCount = _this$props7.commentCount;
|
|
353
397
|
this.getFeedInfo(feedId, commentCount);
|
|
354
398
|
}
|
|
355
399
|
}
|
|
@@ -365,42 +409,42 @@ var Communication = /*#__PURE__*/function (_PureComponent) {
|
|
|
365
409
|
value: function render() {
|
|
366
410
|
var _this2 = this;
|
|
367
411
|
|
|
368
|
-
var _this$
|
|
369
|
-
communicationTrackList = _this$
|
|
370
|
-
communicationTrackTotal = _this$
|
|
371
|
-
isShowAllCommunicationRecord = _this$
|
|
372
|
-
replyUser = _this$
|
|
373
|
-
replyUserId = _this$
|
|
374
|
-
isShowReplyToUser = _this$
|
|
375
|
-
submitStatus = _this$
|
|
376
|
-
isShowPraiseRecordPop = _this$
|
|
377
|
-
praiseObjId = _this$
|
|
378
|
-
isShowDefaultInput = _this$
|
|
379
|
-
needAutoFocus = _this$
|
|
380
|
-
var _this$
|
|
381
|
-
feedId = _this$
|
|
382
|
-
className = _this$
|
|
383
|
-
isShowSendSms = _this$
|
|
384
|
-
confirmPopAlign = _this$
|
|
385
|
-
setTextareaRef = _this$
|
|
386
|
-
userSelectorPopAlign = _this$
|
|
387
|
-
emotionsSelectorPopAlign = _this$
|
|
388
|
-
showAtAll = _this$
|
|
389
|
-
atAllTipText = _this$
|
|
390
|
-
atAllValue = _this$
|
|
391
|
-
atAllText = _this$
|
|
392
|
-
commentCount = _this$
|
|
393
|
-
useCustomMblog = _this$
|
|
394
|
-
_this$
|
|
395
|
-
submitText = _this$
|
|
396
|
-
_this$
|
|
397
|
-
highLightKeyWord = _this$
|
|
398
|
-
_this$
|
|
399
|
-
autoFocus = _this$
|
|
400
|
-
_this$
|
|
401
|
-
showUser = _this$
|
|
402
|
-
_this$
|
|
403
|
-
attachemntCanSubmit = _this$
|
|
412
|
+
var _this$state5 = this.state,
|
|
413
|
+
communicationTrackList = _this$state5.communicationTrackList,
|
|
414
|
+
communicationTrackTotal = _this$state5.communicationTrackTotal,
|
|
415
|
+
isShowAllCommunicationRecord = _this$state5.isShowAllCommunicationRecord,
|
|
416
|
+
replyUser = _this$state5.replyUser,
|
|
417
|
+
replyUserId = _this$state5.replyUserId,
|
|
418
|
+
isShowReplyToUser = _this$state5.isShowReplyToUser,
|
|
419
|
+
submitStatus = _this$state5.submitStatus,
|
|
420
|
+
isShowPraiseRecordPop = _this$state5.isShowPraiseRecordPop,
|
|
421
|
+
praiseObjId = _this$state5.praiseObjId,
|
|
422
|
+
isShowDefaultInput = _this$state5.isShowDefaultInput,
|
|
423
|
+
needAutoFocus = _this$state5.needAutoFocus;
|
|
424
|
+
var _this$props8 = this.props,
|
|
425
|
+
feedId = _this$props8.feedId,
|
|
426
|
+
className = _this$props8.className,
|
|
427
|
+
isShowSendSms = _this$props8.isShowSendSms,
|
|
428
|
+
confirmPopAlign = _this$props8.confirmPopAlign,
|
|
429
|
+
setTextareaRef = _this$props8.setTextareaRef,
|
|
430
|
+
userSelectorPopAlign = _this$props8.userSelectorPopAlign,
|
|
431
|
+
emotionsSelectorPopAlign = _this$props8.emotionsSelectorPopAlign,
|
|
432
|
+
showAtAll = _this$props8.showAtAll,
|
|
433
|
+
atAllTipText = _this$props8.atAllTipText,
|
|
434
|
+
atAllValue = _this$props8.atAllValue,
|
|
435
|
+
atAllText = _this$props8.atAllText,
|
|
436
|
+
commentCount = _this$props8.commentCount,
|
|
437
|
+
useCustomMblog = _this$props8.useCustomMblog,
|
|
438
|
+
_this$props8$submitTe = _this$props8.submitText,
|
|
439
|
+
submitText = _this$props8$submitTe === void 0 ? (0, _getLocale.getLocale)('Mod_Reply') : _this$props8$submitTe,
|
|
440
|
+
_this$props8$highLigh = _this$props8.highLightKeyWord,
|
|
441
|
+
highLightKeyWord = _this$props8$highLigh === void 0 ? '' : _this$props8$highLigh,
|
|
442
|
+
_this$props8$autoFocu = _this$props8.autoFocus,
|
|
443
|
+
autoFocus = _this$props8$autoFocu === void 0 ? false : _this$props8$autoFocu,
|
|
444
|
+
_this$props8$showUser = _this$props8.showUser,
|
|
445
|
+
showUser = _this$props8$showUser === void 0 ? false : _this$props8$showUser,
|
|
446
|
+
_this$props8$attachem = _this$props8.attachemntCanSubmit,
|
|
447
|
+
attachemntCanSubmit = _this$props8$attachem === void 0 ? true : _this$props8$attachem;
|
|
404
448
|
var user = (0, _bsGlobal.getUserInfo)();
|
|
405
449
|
return /*#__PURE__*/_react["default"].createElement(_style.CommunicationWrapper, {
|
|
406
450
|
className: "communcation-wrapper ".concat(className)
|
|
@@ -47,7 +47,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
47
47
|
var _super = _createSuper(BodyItem);
|
|
48
48
|
|
|
49
49
|
function BodyItem() {
|
|
50
|
-
var _this;
|
|
50
|
+
var _temp, _this;
|
|
51
51
|
|
|
52
52
|
_classCallCheck(this, BodyItem);
|
|
53
53
|
|
|
@@ -55,7 +55,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
55
55
|
args[_key] = arguments[_key];
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.getClass = function () {
|
|
58
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.getClass = function () {
|
|
59
59
|
var _this$props = _this.props,
|
|
60
60
|
isAllowSelect = _this$props.isAllowSelect,
|
|
61
61
|
date = _this$props.date,
|
|
@@ -86,7 +86,7 @@ var BodyItem = /*#__PURE__*/function (_Component) {
|
|
|
86
86
|
if (_this.disabled) return;
|
|
87
87
|
|
|
88
88
|
_this.props.onSelectDate((0, _moment["default"])(date.format("YYYY/MM/DD")));
|
|
89
|
-
},
|
|
89
|
+
}, _temp));
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
_createClass(BodyItem, [{
|
|
@@ -87,7 +87,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
87
87
|
var _super = _createSuper(CalendarHeader);
|
|
88
88
|
|
|
89
89
|
function CalendarHeader() {
|
|
90
|
-
var _this;
|
|
90
|
+
var _temp, _this;
|
|
91
91
|
|
|
92
92
|
_classCallCheck(this, CalendarHeader);
|
|
93
93
|
|
|
@@ -95,7 +95,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
95
95
|
args[_key] = arguments[_key];
|
|
96
96
|
}
|
|
97
97
|
|
|
98
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.setDate = function (func) {
|
|
98
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.setDate = function (func) {
|
|
99
99
|
var date = (0, _moment["default"])(_this.props.date);
|
|
100
100
|
|
|
101
101
|
for (var _len2 = arguments.length, rest = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
@@ -113,7 +113,7 @@ var CalendarHeader = /*#__PURE__*/function (_Component) {
|
|
|
113
113
|
}
|
|
114
114
|
|
|
115
115
|
return years;
|
|
116
|
-
},
|
|
116
|
+
}, _temp));
|
|
117
117
|
}
|
|
118
118
|
|
|
119
119
|
_createClass(CalendarHeader, [{
|
|
@@ -49,7 +49,7 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
49
49
|
var _super = _createSuper(ConfirmPop);
|
|
50
50
|
|
|
51
51
|
function ConfirmPop() {
|
|
52
|
-
var _this;
|
|
52
|
+
var _temp, _this;
|
|
53
53
|
|
|
54
54
|
_classCallCheck(this, ConfirmPop);
|
|
55
55
|
|
|
@@ -57,13 +57,13 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
57
57
|
args[_key] = arguments[_key];
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
60
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
61
61
|
// @ts-ignore
|
|
62
62
|
_this.refs.pop.show(_this.refs.trigger);
|
|
63
63
|
}, _this.handleHide = function () {
|
|
64
64
|
// @ts-ignore
|
|
65
65
|
_this.refs.pop.hide();
|
|
66
|
-
},
|
|
66
|
+
}, _temp));
|
|
67
67
|
}
|
|
68
68
|
|
|
69
69
|
_createClass(ConfirmPop, [{
|
|
@@ -55,7 +55,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
55
55
|
var _super = _createSuper(EReportList);
|
|
56
56
|
|
|
57
57
|
function EReportList() {
|
|
58
|
-
var _this;
|
|
58
|
+
var _temp, _this;
|
|
59
59
|
|
|
60
60
|
_classCallCheck(this, EReportList);
|
|
61
61
|
|
|
@@ -63,7 +63,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
63
63
|
args[_key] = arguments[_key];
|
|
64
64
|
}
|
|
65
65
|
|
|
66
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
66
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
67
67
|
selectedPeriodValue: '',
|
|
68
68
|
showDatePick: false,
|
|
69
69
|
eReportWeekList: [],
|
|
@@ -178,7 +178,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
178
178
|
return _this.handlerEReportShareSubmit(submitStatus);
|
|
179
179
|
}
|
|
180
180
|
})));
|
|
181
|
-
},
|
|
181
|
+
}, _temp));
|
|
182
182
|
}
|
|
183
183
|
|
|
184
184
|
_createClass(EReportList, [{
|
|
@@ -47,7 +47,7 @@ var EmotionsSelectorPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
47
47
|
var _super = _createSuper(EmotionsSelectorPop);
|
|
48
48
|
|
|
49
49
|
function EmotionsSelectorPop() {
|
|
50
|
-
var _this;
|
|
50
|
+
var _temp, _this;
|
|
51
51
|
|
|
52
52
|
_classCallCheck(this, EmotionsSelectorPop);
|
|
53
53
|
|
|
@@ -55,7 +55,7 @@ var EmotionsSelectorPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
55
55
|
args[_key] = arguments[_key];
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
58
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
59
59
|
setTimeout(function () {
|
|
60
60
|
// @ts-ignore
|
|
61
61
|
_this.refs.pop.show(_this.refs.trigger);
|
|
@@ -63,7 +63,7 @@ var EmotionsSelectorPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
63
63
|
}, _this.handleHide = function () {
|
|
64
64
|
// @ts-ignore
|
|
65
65
|
_this.refs.pop.hide();
|
|
66
|
-
},
|
|
66
|
+
}, _temp));
|
|
67
67
|
}
|
|
68
68
|
|
|
69
69
|
_createClass(EmotionsSelectorPop, [{
|
|
@@ -57,7 +57,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
57
57
|
var _super = _createSuper(EReportList);
|
|
58
58
|
|
|
59
59
|
function EReportList() {
|
|
60
|
-
var _this;
|
|
60
|
+
var _temp, _this;
|
|
61
61
|
|
|
62
62
|
_classCallCheck(this, EReportList);
|
|
63
63
|
|
|
@@ -65,7 +65,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
65
65
|
args[_key] = arguments[_key];
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
68
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
69
69
|
selectedPeriodValue: "",
|
|
70
70
|
showDatePick: false,
|
|
71
71
|
eReportWeekList: [],
|
|
@@ -178,7 +178,7 @@ var EReportList = /*#__PURE__*/function (_React$Component) {
|
|
|
178
178
|
return _this.handlerEReportShareSubmit(submitStatus);
|
|
179
179
|
}
|
|
180
180
|
})));
|
|
181
|
-
},
|
|
181
|
+
}, _temp));
|
|
182
182
|
}
|
|
183
183
|
|
|
184
184
|
_createClass(EReportList, [{
|
|
@@ -83,7 +83,7 @@ var MblogAction = /*#__PURE__*/function (_PureComponent) {
|
|
|
83
83
|
var _super = _createSuper(MblogAction);
|
|
84
84
|
|
|
85
85
|
function MblogAction() {
|
|
86
|
-
var _this;
|
|
86
|
+
var _temp, _this;
|
|
87
87
|
|
|
88
88
|
_classCallCheck(this, MblogAction);
|
|
89
89
|
|
|
@@ -91,7 +91,7 @@ var MblogAction = /*#__PURE__*/function (_PureComponent) {
|
|
|
91
91
|
args[_key] = arguments[_key];
|
|
92
92
|
}
|
|
93
93
|
|
|
94
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
94
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
95
95
|
isSendSms: false,
|
|
96
96
|
// 是否短信通知
|
|
97
97
|
isShowConfirmPop: false
|
|
@@ -121,7 +121,7 @@ var MblogAction = /*#__PURE__*/function (_PureComponent) {
|
|
|
121
121
|
isSendSms: false
|
|
122
122
|
});
|
|
123
123
|
}
|
|
124
|
-
},
|
|
124
|
+
}, _temp));
|
|
125
125
|
}
|
|
126
126
|
|
|
127
127
|
_createClass(MblogAction, [{
|
|
@@ -217,6 +217,8 @@ var MblogContent = /*#__PURE__*/function (_PureComponent) {
|
|
|
217
217
|
editable: true,
|
|
218
218
|
showToolbar: false,
|
|
219
219
|
withMentions: true,
|
|
220
|
+
onKeyUp: this._handlerKeyUp,
|
|
221
|
+
onKeyDown: this._handlerKeyDown,
|
|
220
222
|
initialState: {},
|
|
221
223
|
onDocChange: this.onChangeEditor,
|
|
222
224
|
placeholder: placeholderText
|
|
@@ -224,7 +224,9 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
|
|
|
224
224
|
visibility = _this$state.visibility,
|
|
225
225
|
mentionUsers = _this$state.mentionUsers,
|
|
226
226
|
richText = _this$state.richText,
|
|
227
|
-
pureText = _this$state.pureText
|
|
227
|
+
pureText = _this$state.pureText,
|
|
228
|
+
isAllowSubmit = _this$state.isAllowSubmit;
|
|
229
|
+
if (!isAllowSubmit) return;
|
|
228
230
|
var _this$props2 = _this.props,
|
|
229
231
|
isShowAttachment = _this$props2.isShowAttachment,
|
|
230
232
|
isShowSendSms = _this$props2.isShowSendSms,
|
package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/kr-score-editor/edit-pop.js
CHANGED
|
@@ -81,7 +81,7 @@ var EditPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
81
81
|
var _super = _createSuper(EditPop);
|
|
82
82
|
|
|
83
83
|
function EditPop() {
|
|
84
|
-
var _this;
|
|
84
|
+
var _temp, _this;
|
|
85
85
|
|
|
86
86
|
_classCallCheck(this, EditPop);
|
|
87
87
|
|
|
@@ -89,7 +89,7 @@ var EditPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
89
89
|
args[_key] = arguments[_key];
|
|
90
90
|
}
|
|
91
91
|
|
|
92
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
92
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.state = {
|
|
93
93
|
value: _this.props.value,
|
|
94
94
|
showError: false,
|
|
95
95
|
errMsg: "",
|
|
@@ -152,7 +152,7 @@ var EditPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
152
152
|
errMsg: (0, _i18nFrontTranslate.inputWordTrans)(value.length, maxLength),
|
|
153
153
|
disable: !!(maxLength && value.length > maxLength && disable)
|
|
154
154
|
});
|
|
155
|
-
},
|
|
155
|
+
}, _temp));
|
|
156
156
|
}
|
|
157
157
|
|
|
158
158
|
_createClass(EditPop, [{
|
|
@@ -49,7 +49,7 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
49
49
|
var _super = _createSuper(ConfirmPop);
|
|
50
50
|
|
|
51
51
|
function ConfirmPop() {
|
|
52
|
-
var _this;
|
|
52
|
+
var _temp, _this;
|
|
53
53
|
|
|
54
54
|
_classCallCheck(this, ConfirmPop);
|
|
55
55
|
|
|
@@ -57,13 +57,13 @@ var ConfirmPop = /*#__PURE__*/function (_PureComponent) {
|
|
|
57
57
|
args[_key] = arguments[_key];
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
return _possibleConstructorReturn(_this, (_this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
60
|
+
return _possibleConstructorReturn(_this, (_temp = _this = _super.call.apply(_super, [this].concat(args)), _this.handleShowPop = function () {
|
|
61
61
|
// @ts-ignore
|
|
62
62
|
_this.refs.pop.show(_this.refs.trigger);
|
|
63
63
|
}, _this.handleHide = function () {
|
|
64
64
|
// @ts-ignore
|
|
65
65
|
_this.refs.pop.hide();
|
|
66
|
-
},
|
|
66
|
+
}, _temp));
|
|
67
67
|
}
|
|
68
68
|
|
|
69
69
|
_createClass(ConfirmPop, [{
|
|
@@ -1,130 +1,56 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
3
|
Object.defineProperty(exports, "__esModule", {
|
|
6
4
|
value: true
|
|
7
5
|
});
|
|
8
6
|
exports["default"] = void 0;
|
|
9
7
|
|
|
10
|
-
var _react =
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
11
9
|
|
|
12
10
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
11
|
|
|
14
|
-
var _moment = _interopRequireDefault(require("moment"));
|
|
15
|
-
|
|
16
12
|
var _getLocale = require("../../../../../utils/getLocale");
|
|
17
13
|
|
|
18
14
|
var _utils = require("../../../utils");
|
|
19
15
|
|
|
20
|
-
var
|
|
16
|
+
var _dateRows = _interopRequireDefault(require("./date-rows"));
|
|
21
17
|
|
|
22
18
|
require("./index.css");
|
|
23
19
|
|
|
24
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
21
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
31
|
-
|
|
32
|
-
// const ROWS_HEIGHT = 32;
|
|
33
|
-
var DATE_ROW_NUM = 6;
|
|
22
|
+
var getWeekDayData = function getWeekDayData() {
|
|
23
|
+
return [(0, _getLocale.getLocale)('Mod_Sun'), (0, _getLocale.getLocale)('Mod_Mon'), (0, _getLocale.getLocale)('Mod_Tues'), (0, _getLocale.getLocale)('Mod_Wed'), (0, _getLocale.getLocale)('Mod_Thur'), (0, _getLocale.getLocale)('Mod_Fri'), (0, _getLocale.getLocale)('Mod_Sat')];
|
|
24
|
+
};
|
|
34
25
|
|
|
35
26
|
var DatePanelBody = function DatePanelBody(props) {
|
|
36
|
-
var
|
|
27
|
+
var mergeDate = props.mergeDate,
|
|
28
|
+
onSelect = props.onSelect,
|
|
29
|
+
setMergeDate = props.setMergeDate,
|
|
37
30
|
_props$weekStartDay = props.weekStartDay,
|
|
38
|
-
weekStartDay = _props$weekStartDay === void 0 ? 'SUNDAY' : _props$weekStartDay
|
|
39
|
-
onSelect = props.onSelect;
|
|
40
|
-
|
|
41
|
-
var _useContext = (0, _react.useContext)(_context["default"]),
|
|
42
|
-
format = _useContext.format,
|
|
43
|
-
value = _useContext.value;
|
|
44
|
-
|
|
31
|
+
weekStartDay = _props$weekStartDay === void 0 ? 'SUNDAY' : _props$weekStartDay;
|
|
45
32
|
var weekStartDaySun = weekStartDay === 'SUNDAY';
|
|
46
|
-
|
|
47
|
-
var getCells = function getCells(sunday, currentMonth) {
|
|
48
|
-
var dates = [];
|
|
49
|
-
|
|
50
|
-
var _loop = function _loop(day) {
|
|
51
|
-
var _classNames;
|
|
52
|
-
|
|
53
|
-
var date = (0, _moment["default"])(sunday).add(day, 'd');
|
|
54
|
-
|
|
55
|
-
var _isCurrentDateInRange = (0, _utils.isCurrentDateInRanges)({
|
|
56
|
-
nowDate: date,
|
|
57
|
-
values: value
|
|
58
|
-
}),
|
|
59
|
-
inRanges = _isCurrentDateInRange.inRanges,
|
|
60
|
-
rangeStart = _isCurrentDateInRange.rangeStart,
|
|
61
|
-
rangeEnd = _isCurrentDateInRange.rangeEnd;
|
|
62
|
-
|
|
63
|
-
var classes = (0, _classnames["default"])(_utils.PickerCellClass, (_classNames = {}, _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--today"), date.isSame((0, _moment["default"])(), 'date')), _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--in-view"), date.format('YYYY/MM') === currentMonth), _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--in-ranges"), inRanges), _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--in-ranges--start"), rangeStart), _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--in-ranges--end"), rangeEnd), _defineProperty(_classNames, "".concat(_utils.PickerCellClass, "--selected"), value === null || value === void 0 ? void 0 : value.some(function (v) {
|
|
64
|
-
return date.isSame((0, _moment["default"])(v).format('YYYY/MM/DD'), 'date');
|
|
65
|
-
})), _classNames));
|
|
66
|
-
dates.push( /*#__PURE__*/_react["default"].createElement("td", {
|
|
67
|
-
className: classes,
|
|
68
|
-
key: date.format('YYYY/MM/DD')
|
|
69
|
-
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
70
|
-
className: (0, _classnames["default"])("".concat(_utils.PickerCellClass, "__inner")),
|
|
71
|
-
title: date.format('YYYY-MM-DD'),
|
|
72
|
-
onClick: function onClick() {
|
|
73
|
-
return onSelect && onSelect(date, 'date');
|
|
74
|
-
}
|
|
75
|
-
}, date.date())));
|
|
76
|
-
};
|
|
77
|
-
|
|
78
|
-
for (var day = 0; day < _utils.WEEK_DAYS_COUNT; day += 1) {
|
|
79
|
-
_loop(day);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
return dates;
|
|
83
|
-
};
|
|
84
|
-
|
|
85
|
-
var getRows = function getRows(date) {
|
|
86
|
-
var currentDate = (0, _moment["default"])(date);
|
|
87
|
-
var monthFirstDay = currentDate.date(1);
|
|
88
|
-
var currentMonth = monthFirstDay.format('YYYY/MM');
|
|
89
|
-
var daysDiff = weekStartDaySun ? 0 : 1;
|
|
90
|
-
var weekStartDay = monthFirstDay.subtract(monthFirstDay.day() - daysDiff, 'days');
|
|
91
|
-
var rows = [];
|
|
92
|
-
|
|
93
|
-
for (var row = 0; row < DATE_ROW_NUM; row += 1) {
|
|
94
|
-
rows.push( /*#__PURE__*/_react["default"].createElement("tr", {
|
|
95
|
-
key: row
|
|
96
|
-
}, getCells(weekStartDay, currentMonth)));
|
|
97
|
-
weekStartDay = weekStartDay.add(1, 'w');
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
return rows;
|
|
101
|
-
};
|
|
102
|
-
|
|
103
33
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
104
34
|
className: (0, _classnames["default"])(_utils.PickerBodyClass)
|
|
105
|
-
}, /*#__PURE__*/_react["default"].createElement("
|
|
106
|
-
className: (0, _classnames["default"])("".concat(_utils.
|
|
107
|
-
},
|
|
108
|
-
className: _utils.PickerCellClass
|
|
109
|
-
}, (0, _getLocale.getLocale)('Mod_Sun')),
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
}, (0, _getLocale.getLocale)('Mod_Sun')))), /*#__PURE__*/_react["default"].createElement("tbody", null, getRows((0, _moment["default"])(viewDate)))));
|
|
35
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
36
|
+
className: (0, _classnames["default"])("".concat(_utils.PickerBodyClass, "__cell-container"))
|
|
37
|
+
}, weekStartDaySun && /*#__PURE__*/_react["default"].createElement("div", {
|
|
38
|
+
className: _utils.PickerCellClass
|
|
39
|
+
}, (0, _getLocale.getLocale)('Mod_Sun')), getWeekDayData().slice(1).map(function (day) {
|
|
40
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
41
|
+
className: _utils.PickerCellClass,
|
|
42
|
+
key: day
|
|
43
|
+
}, day);
|
|
44
|
+
}), !weekStartDaySun && /*#__PURE__*/_react["default"].createElement("div", {
|
|
45
|
+
className: _utils.PickerCellClass
|
|
46
|
+
}, (0, _getLocale.getLocale)('Mod_Sun'))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
47
|
+
className: (0, _classnames["default"])("".concat(_utils.PickerBodyClass, "__calendar"))
|
|
48
|
+
}, /*#__PURE__*/_react["default"].createElement(_dateRows["default"], {
|
|
49
|
+
mergeDate: mergeDate,
|
|
50
|
+
onSelect: onSelect,
|
|
51
|
+
setMergeDate: setMergeDate
|
|
52
|
+
})));
|
|
124
53
|
};
|
|
125
54
|
|
|
126
|
-
DatePanelBody.defaultProps = {
|
|
127
|
-
weekStartDay: 'SUNDAY'
|
|
128
|
-
};
|
|
129
55
|
var _default = DatePanelBody;
|
|
130
56
|
exports["default"] = _default;
|