@titaui/pc 1.11.27 → 1.11.30
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/avatar/text-avatar/index.css +7 -0
- package/lib/components/avatar/text-avatar/index.js +32 -7
- package/lib/components/button/icon-btn/index.js +17 -8
- package/lib/components/button/rect-btn/index.js +7 -7
- package/lib/components/change-okr-modal/Item.js +14 -14
- package/lib/components/drawer/index.js +4 -4
- package/lib/components/drop-selector/index.js +25 -10
- package/lib/components/dynamic/constant.js +33 -32
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/dynamic-footer.js +9 -9
- package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/index.js +1 -1
- package/lib/components/dynamic/dynamic-item/dynamic-interview/img/wifi.svg +24 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.css +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/index.js +50 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview/interview-content.js +65 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/img/wifi.svg +24 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/index.css +61 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/index.js +61 -0
- package/lib/components/dynamic/dynamic-item/dynamic-interview-share/interview-content.js +69 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +5 -5
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +6 -6
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +10 -10
- package/lib/components/dynamic/dynamic-item/dynamic-reply/index.js +13 -13
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +9 -9
- package/lib/components/dynamic/dynamic-item/index.js +50 -32
- package/lib/components/dynamic/dynamic-list/index.js +4 -4
- package/lib/components/e-priority/index.js +8 -8
- package/lib/components/eReport/eReportShare/index.js +11 -11
- package/lib/components/form/form-fields/date/index.css +24 -0
- package/lib/components/form/form-fields/date/index.js +102 -0
- package/lib/components/form/form-fields/input/index.js +10 -10
- package/lib/components/form/form-fields/user/index.css +23 -3
- package/lib/components/form/form-fields/user/index.js +18 -8
- package/lib/components/form/form-fields/user/user-input.js +15 -6
- package/lib/components/form/index.js +10 -3
- package/lib/components/grid-layout/sub-employee-okr/person-okr.js +5 -5
- package/lib/components/icon-button-list/index.js +3 -3
- package/lib/components/img-viewer/index.css +3 -3
- package/lib/components/img-viewer/index.js +11 -11
- package/lib/components/menus/components/menu-tree/images/interview-menu/my-interview.svg +16 -0
- package/lib/components/menus/components/menu-tree/images/interview-menu/template.svg +16 -0
- package/lib/components/menus/components/menu-tree/images/interview-menu/todo.svg +16 -0
- package/lib/components/menus/components/menu-tree/index.css +4 -2
- package/lib/components/menus/components/menu-tree/tree-node/index.css +85 -1
- package/lib/components/menus/export-modules/interview-menus/constant.js +30 -0
- package/lib/components/menus/export-modules/interview-menus/handle-highlight.js +63 -0
- package/lib/components/menus/export-modules/interview-menus/index.css +7 -0
- package/lib/components/menus/export-modules/interview-menus/index.js +128 -0
- package/lib/components/menus/index.js +11 -5
- package/lib/components/nav-top/components/menu/index.js +14 -14
- package/lib/components/nav-top/components/user-message/components/inform/inform-item.js +25 -19
- package/lib/components/nav-top/components/user-message/components/remind/remind-item.js +48 -10
- package/lib/components/nav-top/components/user-message/constant.js +1 -0
- package/lib/components/nav-top/components/user-message/hrMessage.js +22 -19
- package/lib/components/nav-top/components/user-message/index.js +23 -20
- package/lib/components/nav-top/request.apis.js +3 -1
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-priority-dropdown.js +7 -7
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +3 -2
- package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/range-picker-pop.js +10 -0
- package/lib/components/okr-detail/detail-header/actions.js +23 -23
- package/lib/components/okr-detail/index.js +19 -19
- package/lib/components/okr-detail/okr-list/index.js +5 -3
- package/lib/components/okr-flow/child-node/index.css +6 -6
- package/lib/components/okr-flow/child-node/work-node.js +21 -21
- package/lib/components/okr-flow/export-modal/index.js +37 -19
- package/lib/components/okr-flow/export-modules/okr-search-panel/index.js +14 -14
- package/lib/components/okr-flow/okr-map/index.js +5 -5
- package/lib/components/okr-flow/request-apis.js +4 -4
- package/lib/components/okr-flow/root-node/index.js +25 -24
- package/lib/components/okr-flow/utils/index.js +5 -5
- package/lib/components/okr-flow/utils/tree-handler.js +17 -17
- package/lib/components/okrcase-library/okrcases-components/submitOkr-dialog.js +30 -30
- package/lib/components/pagination/index.css +3 -3
- package/lib/components/pagination/select.css +58 -23
- package/lib/components/period-selector/index.css +3 -3
- package/lib/components/period-selector/index.js +11 -11
- package/lib/components/picker/components/panels/date-panel/date-body.js +118 -0
- package/lib/components/picker/components/panels/date-panel/date-head.js +87 -0
- package/lib/components/picker/components/panels/date-panel/index.css +14 -0
- package/lib/components/picker/components/panels/date-panel/index.js +49 -0
- package/lib/components/picker/components/panels/month-panel/index.css +27 -0
- package/lib/components/picker/components/panels/month-panel/index.js +63 -0
- package/lib/components/picker/components/panels/month-panel/month-body.js +89 -0
- package/lib/components/picker/components/panels/month-panel/month-head.js +47 -0
- package/lib/components/picker/components/panels/panel-body/index.js +53 -0
- package/lib/components/picker/components/panels/panel-head/index.js +48 -0
- package/lib/components/picker/components/panels/year-panel/index.css +23 -0
- package/lib/components/picker/components/panels/year-panel/index.js +65 -0
- package/lib/components/picker/components/panels/year-panel/year-body.js +92 -0
- package/lib/components/picker/components/panels/year-panel/year-head.js +35 -0
- package/lib/components/picker/components/picker-trigger/index.css +57 -0
- package/lib/components/picker/components/picker-trigger/index.js +94 -0
- package/lib/components/picker/context.js +15 -0
- package/lib/components/picker/index.css +121 -0
- package/lib/components/picker/index.js +13 -0
- package/lib/components/picker/picker-panels.js +182 -0
- package/lib/components/picker/picker.js +132 -0
- package/lib/components/picker/type.js +5 -0
- package/lib/components/picker/utils.js +28 -0
- package/lib/components/popup/index.js +4 -4
- package/lib/components/radio/index.css +9 -9
- package/lib/components/scrollbar/scroll-mask/index.js +1 -1
- package/lib/components/superset-charts/utils/axios.js +5 -5
- package/lib/components/survey-model/index.css +18 -18
- package/lib/components/survey-model/instance.js +1 -1
- package/lib/components/task-tree/helper.js +61 -0
- package/lib/components/task-tree/images/P1.svg +15 -0
- package/lib/components/task-tree/images/P2.svg +15 -0
- package/lib/components/task-tree/images/P3.svg +15 -0
- package/lib/components/task-tree/images/P4.svg +15 -0
- package/lib/components/task-tree/images/P5.svg +15 -0
- package/lib/components/task-tree/images/arrow.svg +9 -0
- package/lib/components/task-tree/images/empty-131.png +0 -0
- package/lib/components/task-tree/images/followed.svg +33 -0
- package/lib/components/task-tree/images/nice.svg +108 -0
- package/lib/components/task-tree/images/struc12.png +0 -0
- package/lib/components/task-tree/images/struc2.png +0 -0
- package/lib/components/task-tree/images/xialat-s.svg +13 -0
- package/lib/components/task-tree/index.js +22 -0
- package/lib/components/task-tree/mock.js +944 -0
- package/lib/components/task-tree/precls.js +8 -0
- package/lib/components/task-tree/request-apis.js +88 -0
- package/lib/components/task-tree/task-item-node/constant.js +45 -0
- package/lib/components/task-tree/task-item-node/e-empty.js +29 -0
- package/lib/components/task-tree/task-item-node/e-project.js +212 -0
- package/lib/components/task-tree/task-item-node/e-status-dropdown.js +94 -0
- package/lib/components/task-tree/task-item-node/e-task.js +426 -0
- package/lib/components/task-tree/task-item-node/get-process-color.js +62 -0
- package/lib/components/task-tree/task-item-node/index.css +289 -0
- package/lib/components/task-tree/task-item-node/task-node-render.js +43 -0
- package/lib/components/task-tree/task-tree.css +16 -0
- package/lib/components/task-tree/task-tree.js +49 -0
- package/lib/components/time-picker/index.css +123 -0
- package/lib/components/time-picker/index.js +13 -0
- package/lib/components/time-picker/time-picker-selector.js +138 -0
- package/lib/components/time-picker/time-picker.js +336 -0
- package/lib/components/time-picker/timer-picker-input.js +96 -0
- package/lib/components/time-picker/utils.js +52 -0
- package/lib/components/user-selector/select-tree/tree-nodes/tree-person-node/index.css +1 -0
- package/lib/components-v1/radio/radio.js +3 -3
- package/lib/components-v1/radio/style/index.css +8 -8
- package/lib/pages/aha2021/index.js +5 -1
- package/lib/pages/okr-map/export-modules/okr-map/header/index.js +24 -24
- package/lib/pages/okr-map/export-modules/okr-map/okr-map.js +31 -31
- package/lib/pages/okr-map/export-modules/share-okr-page/header/index.css +2 -2
- package/lib/pages/okr-map/export-modules/share-okr-page/header/index.js +11 -11
- package/lib/pages/okr-map/export-modules/share-okr-page/share-okr-map.js +8 -8
- package/lib/pages/okr-map/number-select/index.js +2 -2
- package/lib/utils/auth.js +6 -6
- package/lib/utils/bs-global.js +12 -12
- package/lib/utils/hooks.js +72 -0
- package/lib/utils/open-data.js +26 -26
- package/package.json +5 -2
- package/.eslintignore +0 -3
- package/.eslintrc.js +0 -223
- package/.husky/pre-commit +0 -4
- package/.prettierignore +0 -31
- package/.prettierrc.js +0 -90
- package/.vscode/settings.json +0 -5
|
@@ -45,7 +45,7 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
45
45
|
|
|
46
46
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
47
47
|
|
|
48
|
-
var prefix =
|
|
48
|
+
var prefix = 'titaui-dynamic-task-item';
|
|
49
49
|
|
|
50
50
|
var DynamicTask = function DynamicTask(_ref) {
|
|
51
51
|
var data = _ref.data,
|
|
@@ -63,7 +63,7 @@ var DynamicTask = function DynamicTask(_ref) {
|
|
|
63
63
|
searchKeyWord = _useContext.searchKeyWord;
|
|
64
64
|
|
|
65
65
|
var handleClickTaskTitle = function handleClickTaskTitle() {
|
|
66
|
-
window.Talent.app.vent.trigger(
|
|
66
|
+
window.Talent.app.vent.trigger('global-pull-screen', data.taskId, 'task');
|
|
67
67
|
};
|
|
68
68
|
|
|
69
69
|
var handleClickTitle = function handleClickTitle() {
|
|
@@ -71,13 +71,13 @@ var DynamicTask = function DynamicTask(_ref) {
|
|
|
71
71
|
objId = obj.objId;
|
|
72
72
|
|
|
73
73
|
if (objType === _constant2.EObjType.Kr) {
|
|
74
|
-
_drawerManager["default"].open(
|
|
74
|
+
_drawerManager["default"].open('krDetail', {
|
|
75
75
|
krId: objId
|
|
76
76
|
});
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
if (objType === _constant2.EObjType.O) {
|
|
80
|
-
_drawerManager["default"].open(
|
|
80
|
+
_drawerManager["default"].open('okrDetail', {
|
|
81
81
|
okrId: objId
|
|
82
82
|
});
|
|
83
83
|
}
|
|
@@ -110,17 +110,17 @@ var DynamicTask = function DynamicTask(_ref) {
|
|
|
110
110
|
var dom;
|
|
111
111
|
|
|
112
112
|
if (obj === null || !obj.objName) {
|
|
113
|
-
dom = "".concat((0, _getLocale.getLocale)(
|
|
113
|
+
dom = "".concat((0, _getLocale.getLocale)('Mod_InChargeof')).concat((0, _getLocale.getLocale)('Mod_Tasks'));
|
|
114
114
|
} else {
|
|
115
115
|
dom = /*#__PURE__*/_react["default"].createElement("span", {
|
|
116
116
|
className: "".concat(prefix, "__operate-desc-wrapper")
|
|
117
|
-
}, (0, _getLocale.getLocale)(
|
|
117
|
+
}, (0, _getLocale.getLocale)('Mod_InChargeof'), (0, _constant2.getObjTypeMapText)(obj.objType), /*#__PURE__*/_react["default"].createElement("span", {
|
|
118
118
|
className: "".concat(prefix, "__object-name"),
|
|
119
119
|
onClick: handleClickTitle
|
|
120
120
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"].Text, {
|
|
121
121
|
text: (0, _mblog.htmlDecodeByRegExp)(obj.objName),
|
|
122
122
|
isPercent: true
|
|
123
|
-
})), (0, _getLocale.getLocale)(
|
|
123
|
+
})), (0, _getLocale.getLocale)('Mod_stask'));
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -142,7 +142,7 @@ var DynamicTask = function DynamicTask(_ref) {
|
|
|
142
142
|
className: "".concat(prefix, "__content-title")
|
|
143
143
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
144
144
|
className: "".concat(prefix, "__content-title-type")
|
|
145
|
-
}, (0, _getLocale.getLocale)(
|
|
145
|
+
}, (0, _getLocale.getLocale)('Feed_Tab_Title_Task')), /*#__PURE__*/_react["default"].createElement("span", {
|
|
146
146
|
className: "".concat(prefix, "__content-title-text")
|
|
147
147
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"].Text, {
|
|
148
148
|
isPercent: true,
|
|
@@ -155,7 +155,7 @@ var DynamicTask = function DynamicTask(_ref) {
|
|
|
155
155
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
156
156
|
className: "".concat(prefix, "__content-status-text")
|
|
157
157
|
}, (0, _constant.getEStatusClass2StatusTypeText)()[status]), /*#__PURE__*/_react["default"].createElement("i", {
|
|
158
|
-
className: (0, _classnames["default"])(
|
|
158
|
+
className: (0, _classnames["default"])('tu-icon-deferred', "".concat(prefix, "__content-status-icon"))
|
|
159
159
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
160
160
|
className: "".concat(prefix, "__content-time-range")
|
|
161
161
|
}, startDate, "-", deadline)))));
|
|
@@ -71,6 +71,10 @@ var _feedOperate = _interopRequireDefault(require("./components/feed-operate"));
|
|
|
71
71
|
|
|
72
72
|
require("./index.css");
|
|
73
73
|
|
|
74
|
+
var _dynamicInterview = _interopRequireDefault(require("./dynamic-interview"));
|
|
75
|
+
|
|
76
|
+
var _dynamicInterviewShare = _interopRequireDefault(require("./dynamic-interview-share"));
|
|
77
|
+
|
|
74
78
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
75
79
|
|
|
76
80
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -103,7 +107,7 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
103
107
|
|
|
104
108
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
105
109
|
|
|
106
|
-
var prefix =
|
|
110
|
+
var prefix = 'titaui-dynamic-item';
|
|
107
111
|
|
|
108
112
|
var DynamicItem = function DynamicItem(_ref) {
|
|
109
113
|
var _getBSGlobal, _JSON$parse;
|
|
@@ -153,8 +157,8 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
153
157
|
searchKeyWord = _useContext.searchKeyWord;
|
|
154
158
|
|
|
155
159
|
var hasDynamicOpereateAuth = new _auth.DynamicManagerAuth().hasAuth();
|
|
156
|
-
var hasRewardBtn = !!((_getBSGlobal = (0, _bsGlobal.getBSGlobal)(
|
|
157
|
-
return item.AppId ===
|
|
160
|
+
var hasRewardBtn = !!((_getBSGlobal = (0, _bsGlobal.getBSGlobal)('WebHead')) !== null && _getBSGlobal !== void 0 && _getBSGlobal.AppHead.find(function (item) {
|
|
161
|
+
return item.AppId === '950';
|
|
158
162
|
}));
|
|
159
163
|
var isBiShare = data.shareType === _constant.EShareType.BiShare && data.biId;
|
|
160
164
|
|
|
@@ -174,10 +178,10 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
174
178
|
|
|
175
179
|
var handleShowMore = function handleShowMore() {
|
|
176
180
|
if (data.feedType === _constant.EFeedType.Report && window.titaTracker) {
|
|
177
|
-
window.titaTracker(
|
|
178
|
-
actionName:
|
|
179
|
-
actionGroup:
|
|
180
|
-
productName:
|
|
181
|
+
window.titaTracker('planAction').record({
|
|
182
|
+
actionName: '查看日报',
|
|
183
|
+
actionGroup: '动态-查看更多',
|
|
184
|
+
productName: '动态',
|
|
181
185
|
feedId: feedId
|
|
182
186
|
});
|
|
183
187
|
}
|
|
@@ -186,18 +190,18 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
186
190
|
};
|
|
187
191
|
|
|
188
192
|
var onChangeParse = function onChangeParse(type) {
|
|
189
|
-
var _getBSGlobal2 = (0, _bsGlobal.getBSGlobal)(
|
|
193
|
+
var _getBSGlobal2 = (0, _bsGlobal.getBSGlobal)('loginUserInfo'),
|
|
190
194
|
Id = _getBSGlobal2.Id;
|
|
191
195
|
|
|
192
196
|
var data = _toConsumableArray(praiseData).filter(function (item) {
|
|
193
197
|
return Number("".concat(item.userId)) !== Number("".concat(Id));
|
|
194
198
|
});
|
|
195
199
|
|
|
196
|
-
var actionName =
|
|
200
|
+
var actionName = '';
|
|
197
201
|
|
|
198
202
|
if (type) {
|
|
199
|
-
var avatar = (0, _bsGlobal.getBSGlobal)(
|
|
200
|
-
var name = (0, _bsGlobal.getBSGlobal)(
|
|
203
|
+
var avatar = (0, _bsGlobal.getBSGlobal)('loginUserInfo').UserAvatar;
|
|
204
|
+
var name = (0, _bsGlobal.getBSGlobal)('loginUserInfo').Name;
|
|
201
205
|
avatar.color = avatar.Color;
|
|
202
206
|
avatar.medium = avatar.Medium;
|
|
203
207
|
var parseUser = {
|
|
@@ -207,17 +211,17 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
207
211
|
praiseType: type
|
|
208
212
|
};
|
|
209
213
|
setPraiseData([parseUser].concat(_toConsumableArray(data)));
|
|
210
|
-
actionName =
|
|
214
|
+
actionName = '点赞日报';
|
|
211
215
|
} else {
|
|
212
216
|
setPraiseData(data);
|
|
213
|
-
actionName =
|
|
217
|
+
actionName = '取消日报点赞';
|
|
214
218
|
}
|
|
215
219
|
|
|
216
220
|
if (feedType === _constant.EFeedType.Report && window.titaTracker) {
|
|
217
|
-
window.titaTracker(
|
|
221
|
+
window.titaTracker('planAction').record({
|
|
218
222
|
actionName: actionName,
|
|
219
|
-
actionGroup:
|
|
220
|
-
productName:
|
|
223
|
+
actionGroup: '动态-日报',
|
|
224
|
+
productName: '动态',
|
|
221
225
|
feedId: feedId
|
|
222
226
|
});
|
|
223
227
|
}
|
|
@@ -304,6 +308,14 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
304
308
|
});
|
|
305
309
|
}
|
|
306
310
|
|
|
311
|
+
if (data.shareType === _constant.EShareType.InterviewShare) {
|
|
312
|
+
return /*#__PURE__*/_react["default"].createElement(_dynamicInterviewShare["default"], {
|
|
313
|
+
data: data,
|
|
314
|
+
onDeleteFeed: onDeleteFeed,
|
|
315
|
+
hasDynamicOpereateAuth: hasDynamicOpereateAuth
|
|
316
|
+
});
|
|
317
|
+
}
|
|
318
|
+
|
|
307
319
|
return /*#__PURE__*/_react["default"].createElement(_dynamicLearning["default"], {
|
|
308
320
|
data: data
|
|
309
321
|
});
|
|
@@ -333,6 +345,12 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
333
345
|
onDeleteFeed: onDeleteFeed
|
|
334
346
|
});
|
|
335
347
|
|
|
348
|
+
case _constant.EFeedType.Interview:
|
|
349
|
+
return /*#__PURE__*/_react["default"].createElement(_dynamicInterview["default"], {
|
|
350
|
+
data: data,
|
|
351
|
+
onDeleteFeed: onDeleteFeed
|
|
352
|
+
});
|
|
353
|
+
|
|
336
354
|
default:
|
|
337
355
|
return null;
|
|
338
356
|
}
|
|
@@ -340,7 +358,7 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
340
358
|
|
|
341
359
|
var renderUpvoteCount = function renderUpvoteCount(type, count) {
|
|
342
360
|
if (count === 0) {
|
|
343
|
-
return
|
|
361
|
+
return '';
|
|
344
362
|
}
|
|
345
363
|
|
|
346
364
|
return count || type;
|
|
@@ -358,10 +376,10 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
358
376
|
|
|
359
377
|
if (window.util) {
|
|
360
378
|
if (feedType === _constant.EFeedType.Report && window.titaTracker) {
|
|
361
|
-
window.titaTracker(
|
|
362
|
-
actionName:
|
|
363
|
-
actionGroup:
|
|
364
|
-
productName:
|
|
379
|
+
window.titaTracker('planAction').record({
|
|
380
|
+
actionName: '打开打赏弹层',
|
|
381
|
+
actionGroup: '动态-日报',
|
|
382
|
+
productName: '动态',
|
|
365
383
|
feedId: feedId
|
|
366
384
|
});
|
|
367
385
|
}
|
|
@@ -375,13 +393,13 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
375
393
|
var handleReply = function handleReply(_ref2) {
|
|
376
394
|
var submitType = _ref2.submitType;
|
|
377
395
|
if (feedType !== _constant.EFeedType.Report) return;
|
|
378
|
-
var actionName = submitType ===
|
|
396
|
+
var actionName = submitType === 'delete' ? '删除日报评论' : '评论日报';
|
|
379
397
|
|
|
380
398
|
if (window.titaTracker) {
|
|
381
|
-
window.titaTracker(
|
|
399
|
+
window.titaTracker('planAction').record({
|
|
382
400
|
actionName: actionName,
|
|
383
|
-
actionGroup:
|
|
384
|
-
productName:
|
|
401
|
+
actionGroup: '动态-日报',
|
|
402
|
+
productName: '动态',
|
|
385
403
|
feedId: feedId
|
|
386
404
|
});
|
|
387
405
|
}
|
|
@@ -409,15 +427,15 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
409
427
|
className: "".concat(prefix, "__content"),
|
|
410
428
|
ref: dynamicContentRef,
|
|
411
429
|
style: {
|
|
412
|
-
height: contentIsOverflow && isFold ?
|
|
430
|
+
height: contentIsOverflow && isFold ? '288px' : 'auto'
|
|
413
431
|
}
|
|
414
432
|
}, renderContent, /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
|
|
415
433
|
condition: contentIsOverflow && isFold
|
|
416
434
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
417
435
|
className: "".concat(prefix, "__content-show-more"),
|
|
418
436
|
onClick: handleShowMore
|
|
419
|
-
}, (0, _getLocale.getLocale)(
|
|
420
|
-
className: (0, _classnames["default"])(
|
|
437
|
+
}, (0, _getLocale.getLocale)('Tasks_Tab_MyS_Butt_Seemoral'), /*#__PURE__*/_react["default"].createElement("i", {
|
|
438
|
+
className: (0, _classnames["default"])('tu-icon-arrow-down', "".concat(prefix, "__icon"))
|
|
421
439
|
})))), feedOperations.total > 0 && /*#__PURE__*/_react["default"].createElement(_feedOperate["default"], {
|
|
422
440
|
feedOperations: feedOperations,
|
|
423
441
|
data: data
|
|
@@ -455,12 +473,12 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
455
473
|
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
456
474
|
className: "".concat(prefix, "__footer-fold"),
|
|
457
475
|
onClick: handleFold
|
|
458
|
-
}, (0, _getLocale.getLocale)(
|
|
459
|
-
className: (0, _classnames["default"])(
|
|
476
|
+
}, (0, _getLocale.getLocale)('Mod_Fold'), /*#__PURE__*/_react["default"].createElement("i", {
|
|
477
|
+
className: (0, _classnames["default"])('tu-icon-arrow-down', "".concat(prefix, "__icon"), "".concat(prefix, "__icon-up"))
|
|
460
478
|
}))), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
|
|
461
479
|
condition: hasRewardBtn
|
|
462
480
|
}, /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
|
|
463
|
-
overlay: (0, _getLocale.getLocale)(
|
|
481
|
+
overlay: (0, _getLocale.getLocale)('Feed_Approval'),
|
|
464
482
|
align: {
|
|
465
483
|
offset: [0, 0]
|
|
466
484
|
},
|
|
@@ -470,7 +488,7 @@ var DynamicItem = function DynamicItem(_ref) {
|
|
|
470
488
|
className: (0, _classnames["default"])("".concat(prefix, "__footer-icon"), "".concat(prefix, "__footer-icon-redenvelopes"))
|
|
471
489
|
}))), /*#__PURE__*/_react["default"].createElement("span", {
|
|
472
490
|
onClick: handleCommentClick,
|
|
473
|
-
className: (0, _classnames["default"])(
|
|
491
|
+
className: (0, _classnames["default"])('tu-icon-pinglun-m', "".concat(prefix, "__footer-icon"))
|
|
474
492
|
}, /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
|
|
475
493
|
condition: feedComments.total > 0
|
|
476
494
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -22,7 +22,7 @@ require("./index.css");
|
|
|
22
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
23
|
|
|
24
24
|
// @ts-ignore
|
|
25
|
-
var prefix =
|
|
25
|
+
var prefix = 'titaui-dynamic-list';
|
|
26
26
|
|
|
27
27
|
var DynamicList = function DynamicList(_ref) {
|
|
28
28
|
var data = _ref.data,
|
|
@@ -40,7 +40,7 @@ var DynamicList = function DynamicList(_ref) {
|
|
|
40
40
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
41
41
|
className: prefix,
|
|
42
42
|
style: {
|
|
43
|
-
minHeight: height === -1 ?
|
|
43
|
+
minHeight: height === -1 ? 'auto' : height
|
|
44
44
|
}
|
|
45
45
|
}, /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
|
|
46
46
|
condition: data.length === 0
|
|
@@ -52,7 +52,7 @@ var DynamicList = function DynamicList(_ref) {
|
|
|
52
52
|
alt: ""
|
|
53
53
|
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
54
54
|
className: "".concat(prefix, "__empty-text")
|
|
55
|
-
}, (0, _getLocale.getLocale)(
|
|
55
|
+
}, (0, _getLocale.getLocale)('OKR_Noinformation')))), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
|
|
56
56
|
condition: data.length !== 0
|
|
57
57
|
}, /*#__PURE__*/_react["default"].createElement(_rcQueueAnim["default"], {
|
|
58
58
|
type: "bottom",
|
|
@@ -61,7 +61,7 @@ var DynamicList = function DynamicList(_ref) {
|
|
|
61
61
|
animConfig: [{
|
|
62
62
|
opacity: [1, 0]
|
|
63
63
|
}, {
|
|
64
|
-
display:
|
|
64
|
+
display: 'none'
|
|
65
65
|
}]
|
|
66
66
|
}, data.map(function (item) {
|
|
67
67
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
@@ -35,7 +35,7 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
35
35
|
|
|
36
36
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
37
37
|
|
|
38
|
-
var preCls =
|
|
38
|
+
var preCls = 'tita-okrdt-tree';
|
|
39
39
|
|
|
40
40
|
var EPriority = function EPriority(props) {
|
|
41
41
|
var onChange = props.onChange,
|
|
@@ -43,7 +43,7 @@ var EPriority = function EPriority(props) {
|
|
|
43
43
|
hasAuth = props.hasAuth,
|
|
44
44
|
status = props.status;
|
|
45
45
|
|
|
46
|
-
var _useState = (0, _react.useState)(
|
|
46
|
+
var _useState = (0, _react.useState)('1'),
|
|
47
47
|
_useState2 = _slicedToArray(_useState, 2),
|
|
48
48
|
level = _useState2[0],
|
|
49
49
|
setLevel = _useState2[1];
|
|
@@ -62,7 +62,7 @@ var EPriority = function EPriority(props) {
|
|
|
62
62
|
return /*#__PURE__*/_react["default"].createElement(_dropSelector["default"], {
|
|
63
63
|
onChange: onMenuClickHandler,
|
|
64
64
|
checked: level,
|
|
65
|
-
canEdit: hasAuth && status !==
|
|
65
|
+
canEdit: hasAuth && status !== '5',
|
|
66
66
|
limitHeight: false,
|
|
67
67
|
trigger: /*#__PURE__*/_react["default"].createElement("span", {
|
|
68
68
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p").concat(level))
|
|
@@ -71,23 +71,23 @@ var EPriority = function EPriority(props) {
|
|
|
71
71
|
name: "1"
|
|
72
72
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
73
73
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p1 ").concat(preCls, "__e-task-node-select-priority"))
|
|
74
|
-
}), (0, _getLocale.getLocale)(
|
|
74
|
+
}), (0, _getLocale.getLocale)('OKR_MyO_E_Butt_Highest')), /*#__PURE__*/_react["default"].createElement(_dropSelector["default"].IconItem, {
|
|
75
75
|
name: "2"
|
|
76
76
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
77
77
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p2 ").concat(preCls, "__e-task-node-select-priority"))
|
|
78
|
-
}), (0, _getLocale.getLocale)(
|
|
78
|
+
}), (0, _getLocale.getLocale)('OKR_MyO_E_Butt_High')), /*#__PURE__*/_react["default"].createElement(_dropSelector["default"].IconItem, {
|
|
79
79
|
name: "3"
|
|
80
80
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
81
81
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p3 ").concat(preCls, "__e-task-node-select-priority"))
|
|
82
|
-
}), (0, _getLocale.getLocale)(
|
|
82
|
+
}), (0, _getLocale.getLocale)('OKR_MyO_E_Butt_Middle')), /*#__PURE__*/_react["default"].createElement(_dropSelector["default"].IconItem, {
|
|
83
83
|
name: "4"
|
|
84
84
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
85
85
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p4 ").concat(preCls, "__e-task-node-select-priority"))
|
|
86
|
-
}), (0, _getLocale.getLocale)(
|
|
86
|
+
}), (0, _getLocale.getLocale)('OKR_MyO_E_Butt_Low')), /*#__PURE__*/_react["default"].createElement(_dropSelector["default"].IconItem, {
|
|
87
87
|
name: "5"
|
|
88
88
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
89
89
|
className: (0, _classnames["default"])("".concat(preCls, "__e-task-node-priority-p5 ").concat(preCls, "__e-task-node-select-priority"))
|
|
90
|
-
}), (0, _getLocale.getLocale)(
|
|
90
|
+
}), (0, _getLocale.getLocale)('OKR_MyO_E_Butt_Verylow')));
|
|
91
91
|
};
|
|
92
92
|
|
|
93
93
|
var _default = EPriority;
|
|
@@ -67,25 +67,25 @@ var EReportShare = /*#__PURE__*/function (_PureComponent) {
|
|
|
67
67
|
sentData.ObjType = 62;
|
|
68
68
|
sentData.ObjId = workId;
|
|
69
69
|
|
|
70
|
-
if (submitType ===
|
|
70
|
+
if (submitType === 'submit') {
|
|
71
71
|
_this.setState({
|
|
72
72
|
submitStatus: 2
|
|
73
73
|
});
|
|
74
74
|
|
|
75
|
-
var url = (0, _requestV.getApiUrl2)(
|
|
76
|
-
(0, _requestV.taker)(url,
|
|
75
|
+
var url = (0, _requestV.getApiUrl2)('user/feed/AddShare');
|
|
76
|
+
(0, _requestV.taker)(url, 'POST', sentData).then(function (res) {
|
|
77
77
|
if (res.Code == 1) {
|
|
78
78
|
_this.setState({
|
|
79
79
|
submitStatus: 1
|
|
80
80
|
});
|
|
81
81
|
|
|
82
|
-
onSubmit(
|
|
82
|
+
onSubmit('success');
|
|
83
83
|
} else {
|
|
84
84
|
_this.setState({
|
|
85
85
|
submitStatus: 0
|
|
86
86
|
});
|
|
87
87
|
|
|
88
|
-
onSubmit(
|
|
88
|
+
onSubmit('failed');
|
|
89
89
|
}
|
|
90
90
|
});
|
|
91
91
|
} else {
|
|
@@ -93,7 +93,7 @@ var EReportShare = /*#__PURE__*/function (_PureComponent) {
|
|
|
93
93
|
submitStatus: 0
|
|
94
94
|
});
|
|
95
95
|
|
|
96
|
-
onSubmit(
|
|
96
|
+
onSubmit('cancel');
|
|
97
97
|
}
|
|
98
98
|
};
|
|
99
99
|
|
|
@@ -122,12 +122,12 @@ var EReportShare = /*#__PURE__*/function (_PureComponent) {
|
|
|
122
122
|
submitStatus = _this$state.submitStatus,
|
|
123
123
|
popContainer = _this$state.popContainer; // let eReportURL = `${location.origin}${location.pathname}#okr/eReport?okrId=${eReportId}&back=#okr%2Fmanage%3Fwork_id%3D${workId}%26detail_type%3Detask`
|
|
124
124
|
|
|
125
|
-
var eReportURL = "".concat(location.origin).concat(location.pathname, "#okr/eReport?okrId=").concat(eReportId, "&
|
|
126
|
-
var defaultContent = this.isManager ? "@[\u6240\u6709\u540C\u4E8B:all_members] ".concat((0, _getLocale.getLocale)(
|
|
125
|
+
var eReportURL = "".concat(location.origin).concat(location.pathname, "#okr/eReport?okrId=").concat(eReportId, "&work_id=").concat(workId);
|
|
126
|
+
var defaultContent = this.isManager ? "@[\u6240\u6709\u540C\u4E8B:all_members] ".concat((0, _getLocale.getLocale)('Mod_Objective'), "\uFF1A").concat(workName, "\uFF08").concat(eReportDate, "\uFF09E\u5468\u62A5").concat(eReportURL, "\uFF0C\u70B9\u51FB\u94FE\u63A5\u5373\u53EF\u67E5\u770B\uFF5E") : "".concat((0, _getLocale.getLocale)('Mod_Objective'), "\uFF1A").concat(workName, "\uFF08").concat(eReportDate, "\uFF09E\u5468\u62A5").concat(eReportURL, "\uFF0C\u70B9\u51FB\u94FE\u63A5\u5373\u53EF\u67E5\u770B\uFF5E");
|
|
127
127
|
return /*#__PURE__*/_react["default"].createElement(_style.ModalWrapper, {
|
|
128
128
|
className: "".concat(className, " document-mouse-event-ignore"),
|
|
129
129
|
onClick: function onClick() {
|
|
130
|
-
return onSubmit(
|
|
130
|
+
return onSubmit('cancel');
|
|
131
131
|
}
|
|
132
132
|
}, /*#__PURE__*/_react["default"].createElement(_style.ModalContainer, {
|
|
133
133
|
width: "800px",
|
|
@@ -140,7 +140,7 @@ var EReportShare = /*#__PURE__*/function (_PureComponent) {
|
|
|
140
140
|
}, /*#__PURE__*/_react["default"].createElement("span", null, "\u53D1\u5206\u4EAB\uFF08@Ta\uFF09"), /*#__PURE__*/_react["default"].createElement(_style.PraiseRecordClose, {
|
|
141
141
|
className: "tu-icon-close",
|
|
142
142
|
onMouseDown: function onMouseDown() {
|
|
143
|
-
return onSubmit(
|
|
143
|
+
return onSubmit('cancel');
|
|
144
144
|
}
|
|
145
145
|
})), /*#__PURE__*/_react["default"].createElement(_context["default"].Provider, {
|
|
146
146
|
value: {
|
|
@@ -152,7 +152,7 @@ var EReportShare = /*#__PURE__*/function (_PureComponent) {
|
|
|
152
152
|
isShowRangeDropDown: false,
|
|
153
153
|
isShowSendSms: false,
|
|
154
154
|
isShowBtnCancel: false,
|
|
155
|
-
submitText: (0, _getLocale.getLocale)(
|
|
155
|
+
submitText: (0, _getLocale.getLocale)('OKR_MyO_KRP_Butt_Release'),
|
|
156
156
|
initialTextHeight: 96,
|
|
157
157
|
autoResizing: false,
|
|
158
158
|
privateValue: isVisible,
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
.form-field-date__label {
|
|
2
|
+
height: 22px;
|
|
3
|
+
margin-bottom: 5px;
|
|
4
|
+
font-size: 14px;
|
|
5
|
+
font-weight: 400;
|
|
6
|
+
line-height: 22px;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.form-field-date__label-text {
|
|
10
|
+
color: #3f4755;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.form-field-date__label-symbol {
|
|
14
|
+
color: red;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.form-field-date__pickers {
|
|
18
|
+
display: flex;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.form-field-date__pickers .tita-ui__picker-trigger {
|
|
22
|
+
flex: 1;
|
|
23
|
+
margin-right: 10px;
|
|
24
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
11
|
+
|
|
12
|
+
var _moment = _interopRequireDefault(require("moment"));
|
|
13
|
+
|
|
14
|
+
var _picker = _interopRequireDefault(require("../../../picker"));
|
|
15
|
+
|
|
16
|
+
var _timePicker = _interopRequireDefault(require("../../../time-picker"));
|
|
17
|
+
|
|
18
|
+
require("./index.css");
|
|
19
|
+
|
|
20
|
+
var _excluded = ["label", "layout", "require", "value", "onChange", "datePopupAlign", "timePopupAlign"];
|
|
21
|
+
|
|
22
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
+
|
|
24
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25
|
+
|
|
26
|
+
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; }
|
|
27
|
+
|
|
28
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
29
|
+
|
|
30
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
31
|
+
|
|
32
|
+
var prefixCls = 'form-field-date';
|
|
33
|
+
|
|
34
|
+
var Date = function Date(props) {
|
|
35
|
+
var label = props.label,
|
|
36
|
+
layout = props.layout,
|
|
37
|
+
require = props.require,
|
|
38
|
+
_props$value = props.value,
|
|
39
|
+
value = _props$value === void 0 ? (0, _moment["default"])() : _props$value,
|
|
40
|
+
onChange = props.onChange,
|
|
41
|
+
datePopupAlign = props.datePopupAlign,
|
|
42
|
+
timePopupAlign = props.timePopupAlign,
|
|
43
|
+
restProps = _objectWithoutProperties(props, _excluded);
|
|
44
|
+
|
|
45
|
+
var onDateChange = function onDateChange(date, type) {
|
|
46
|
+
var newDate;
|
|
47
|
+
|
|
48
|
+
switch (type) {
|
|
49
|
+
case 'date':
|
|
50
|
+
newDate = (0, _moment["default"])(value || (0, _moment["default"])()).set({
|
|
51
|
+
year: (0, _moment["default"])(date).year(),
|
|
52
|
+
month: (0, _moment["default"])(date).month(),
|
|
53
|
+
date: (0, _moment["default"])(date).date()
|
|
54
|
+
});
|
|
55
|
+
break;
|
|
56
|
+
|
|
57
|
+
case 'time':
|
|
58
|
+
newDate = (0, _moment["default"])(value || (0, _moment["default"])()).set({
|
|
59
|
+
hour: (0, _moment["default"])(date, 'HH:mm').hour(),
|
|
60
|
+
minute: (0, _moment["default"])(date, 'HH:mm').minute()
|
|
61
|
+
});
|
|
62
|
+
break;
|
|
63
|
+
|
|
64
|
+
default:
|
|
65
|
+
break;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
onChange(newDate);
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
72
|
+
className: (0, _classnames["default"])(prefixCls, _defineProperty({}, "".concat(prefixCls, "-row"), layout === 'row'))
|
|
73
|
+
}, !!label && /*#__PURE__*/_react["default"].createElement("div", {
|
|
74
|
+
className: "".concat(prefixCls, "__label")
|
|
75
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
76
|
+
className: "".concat(prefixCls, "__label-text")
|
|
77
|
+
}, label), require && /*#__PURE__*/_react["default"].createElement("span", {
|
|
78
|
+
className: "".concat(prefixCls, "__label-symbol")
|
|
79
|
+
}, "*")), /*#__PURE__*/_react["default"].createElement("div", {
|
|
80
|
+
className: (0, _classnames["default"])("".concat(prefixCls, "__pickers"))
|
|
81
|
+
}, /*#__PURE__*/_react["default"].createElement(_picker["default"], _extends({
|
|
82
|
+
value: value,
|
|
83
|
+
onChange: function onChange(date) {
|
|
84
|
+
return onDateChange(date, 'date');
|
|
85
|
+
},
|
|
86
|
+
popupAlign: datePopupAlign
|
|
87
|
+
}, restProps)), /*#__PURE__*/_react["default"].createElement(_timePicker["default"], _extends({
|
|
88
|
+
value: value,
|
|
89
|
+
popupAlign: timePopupAlign,
|
|
90
|
+
onChange: function onChange(time) {
|
|
91
|
+
return onDateChange(time, 'time');
|
|
92
|
+
}
|
|
93
|
+
}, restProps))));
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
Date.defaultProps = {
|
|
97
|
+
disabled: false,
|
|
98
|
+
layout: 'column',
|
|
99
|
+
require: false
|
|
100
|
+
};
|
|
101
|
+
var _default = Date;
|
|
102
|
+
exports["default"] = _default;
|
|
@@ -43,7 +43,7 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
43
43
|
|
|
44
44
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
45
45
|
|
|
46
|
-
var preCls =
|
|
46
|
+
var preCls = 'form-field-input';
|
|
47
47
|
|
|
48
48
|
function OverlayInner(_ref) {
|
|
49
49
|
var hasError = _ref.hasError,
|
|
@@ -52,12 +52,12 @@ function OverlayInner(_ref) {
|
|
|
52
52
|
activeTips = _ref.activeTips;
|
|
53
53
|
if (hasActive) return /*#__PURE__*/_react["default"].createElement("span", {
|
|
54
54
|
style: {
|
|
55
|
-
color:
|
|
55
|
+
color: '#3F4755'
|
|
56
56
|
}
|
|
57
57
|
}, activeTips);
|
|
58
58
|
if (hasError) return /*#__PURE__*/_react["default"].createElement("span", {
|
|
59
59
|
style: {
|
|
60
|
-
color:
|
|
60
|
+
color: '#F05E5E'
|
|
61
61
|
}
|
|
62
62
|
}, tip);
|
|
63
63
|
return /*#__PURE__*/_react["default"].createElement("span", null);
|
|
@@ -79,7 +79,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
79
79
|
layout = props.layout,
|
|
80
80
|
onCheckSuccess = props.onCheckSuccess,
|
|
81
81
|
_props$className = props.className,
|
|
82
|
-
className = _props$className === void 0 ?
|
|
82
|
+
className = _props$className === void 0 ? '' : _props$className,
|
|
83
83
|
tail = props.tail,
|
|
84
84
|
restProps = _objectWithoutProperties(props, _excluded);
|
|
85
85
|
|
|
@@ -95,12 +95,12 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
95
95
|
hasActive = _useState4[0],
|
|
96
96
|
setHasActive = _useState4[1];
|
|
97
97
|
|
|
98
|
-
var _useState5 = (0, _react.useState)(
|
|
98
|
+
var _useState5 = (0, _react.useState)(''),
|
|
99
99
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
100
100
|
tip = _useState6[0],
|
|
101
101
|
setTip = _useState6[1];
|
|
102
102
|
|
|
103
|
-
var _useState7 = (0, _react.useState)(props.value ||
|
|
103
|
+
var _useState7 = (0, _react.useState)(props.value || ''),
|
|
104
104
|
_useState8 = _slicedToArray(_useState7, 2),
|
|
105
105
|
value = _useState8[0],
|
|
106
106
|
setValue = _useState8[1];
|
|
@@ -133,7 +133,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
133
133
|
|
|
134
134
|
var onInputFocusHandler = function onInputFocusHandler() {
|
|
135
135
|
setHasActive(true);
|
|
136
|
-
if (type && type ==
|
|
136
|
+
if (type && type == 'number') return;
|
|
137
137
|
inputRef.current.setSelectionRange(9999999, 9999999);
|
|
138
138
|
};
|
|
139
139
|
|
|
@@ -147,7 +147,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
147
147
|
setTip(errors[0].tip);
|
|
148
148
|
} else {
|
|
149
149
|
setHasError(false);
|
|
150
|
-
setTip(
|
|
150
|
+
setTip('');
|
|
151
151
|
}
|
|
152
152
|
};
|
|
153
153
|
|
|
@@ -196,7 +196,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
196
196
|
};
|
|
197
197
|
});
|
|
198
198
|
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
199
|
-
className: (0, _classnames["default"])(preCls, _defineProperty({}, "".concat(preCls, "-row"), layout ===
|
|
199
|
+
className: (0, _classnames["default"])(preCls, _defineProperty({}, "".concat(preCls, "-row"), layout === 'row'), className)
|
|
200
200
|
}, !!label && /*#__PURE__*/_react["default"].createElement("div", {
|
|
201
201
|
className: (0, _classnames["default"])("".concat(preCls, "__label"))
|
|
202
202
|
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
@@ -227,7 +227,7 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
|
227
227
|
onBlur: onBlurHandler,
|
|
228
228
|
onChange: onChangeHandler,
|
|
229
229
|
autoComplete: "off"
|
|
230
|
-
}, restProps))), typeof tail ===
|
|
230
|
+
}, restProps))), typeof tail === 'string' ? /*#__PURE__*/_react["default"].createElement("span", {
|
|
231
231
|
className: (0, _classnames["default"])("".concat(preCls, "__tail"))
|
|
232
232
|
}, tail) : tail));
|
|
233
233
|
});
|