@titaui/pc 1.5.69-beta.5 → 1.5.69-beta.9
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/icon-avatar/index.js +1 -1
- package/lib/components/avatar/index.js +5 -1
- package/lib/components/avatar/num-avatar/index.css +12 -0
- package/lib/components/avatar/num-avatar/index.js +34 -0
- package/lib/components/communication/CommunicationRecord.js +106 -162
- package/lib/components/communication/index.js +27 -24
- package/lib/components/dynamic/components/condition-render/index.js +20 -0
- package/lib/components/dynamic/components/dynamic-search-input/index.css +6 -0
- package/lib/components/dynamic/components/dynamic-search-input/index.js +2 -1
- package/lib/components/dynamic/components/obj-status/index.css +22 -0
- package/lib/components/dynamic/components/obj-status/index.js +38 -0
- package/lib/components/dynamic/components/percent/index.css +21 -0
- package/lib/components/dynamic/components/percent/index.js +38 -0
- package/lib/components/dynamic/components/title/index.css +35 -0
- package/lib/components/dynamic/{dynamic-item/components/publish-content → components/title}/index.js +27 -31
- package/lib/components/dynamic/constant.js +19 -2
- package/lib/components/dynamic/dynamic-item/components/{dynamic-item-header → header}/index.css +1 -1
- package/lib/components/dynamic/dynamic-item/components/{dynamic-item-header → header}/index.js +23 -16
- package/lib/components/dynamic/dynamic-item/components/icon/index.css +10 -0
- package/lib/components/dynamic/dynamic-item/components/icon/index.js +35 -0
- package/lib/components/dynamic/dynamic-item/{components/align → dynamic-align}/img/dynamic-align.svg +0 -0
- package/lib/components/dynamic/dynamic-item/{components/align → dynamic-align}/img/dynamic-relative.svg +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +161 -0
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.js +92 -0
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +48 -0
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +88 -0
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +94 -0
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +168 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +85 -0
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +140 -0
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +213 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project → dynamic-project}/constant.js +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-project}/img/project.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +91 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +124 -0
- package/lib/components/dynamic/dynamic-item/{components/relative → dynamic-relative}/img/dynamic-relative.svg +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +95 -0
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +180 -0
- package/lib/components/dynamic/dynamic-item/dynamic-replay/index.css +134 -0
- package/lib/components/dynamic/dynamic-item/{components/replay → dynamic-replay}/index.js +73 -11
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +94 -0
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +137 -0
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +97 -0
- package/lib/components/dynamic/dynamic-item/{components/common-dynamic → dynamic-reward}/index.js +91 -37
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +51 -0
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +92 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/constant.js +13 -3
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-cancel.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-delay.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-done.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-pause.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-progress.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-unaccept.png +0 -0
- package/lib/components/dynamic/dynamic-item/{components/task-project-icon → dynamic-task}/img/task-unstart.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +111 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +162 -0
- package/lib/components/dynamic/dynamic-item/index.css +11 -2
- package/lib/components/dynamic/dynamic-item/index.js +125 -76
- package/lib/components/dynamic/dynamic-like-ranking/index.js +65 -19
- package/lib/components/dynamic/dynamic-like-ranking/item.js +20 -38
- package/lib/components/dynamic/dynamic-liking/index.js +10 -4
- package/lib/components/dynamic/dynamic-liking/item.js +37 -12
- package/lib/components/dynamic/dynamic-list/index.js +9 -3
- package/lib/components/dynamic/dynamic-topping/index.js +1 -1
- package/lib/components/dynamic/dynamic-topping/item.js +2 -2
- package/lib/components/dynamic/dynamic.css +1 -1
- package/lib/components/dynamic/dynamic.js +49 -15
- package/lib/components/dynamic/request-api.js +13 -1
- package/lib/components/dynamic/util.js +16 -2
- package/lib/components/grid-page/personal-info/index.js +4 -4
- package/lib/pages/like-ranking/column.js +18 -5
- package/lib/pages/like-ranking/filter-buttons/department.js +19 -12
- package/lib/pages/like-ranking/filter-buttons/index.js +8 -23
- package/lib/pages/like-ranking/filter-buttons/modular.js +27 -25
- package/lib/pages/like-ranking/filter-buttons/name.js +6 -8
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.css +17 -0
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.js +8 -2
- package/lib/pages/like-ranking/filter-buttons/timer.js +10 -11
- package/lib/pages/like-ranking/index.css +14 -2
- package/lib/pages/like-ranking/index.js +64 -89
- package/lib/utils/bs-global.js +2 -1
- package/lib/utils/format-time.js +35 -2
- package/lib/utils/tools.js +50 -25
- package/package.json +1 -1
- package/lib/components/dynamic/components/common-title/index.css +0 -106
- package/lib/components/dynamic/components/common-title/index.js +0 -129
- package/lib/components/dynamic/dynamic-item/components/align/index.css +0 -66
- package/lib/components/dynamic/dynamic-item/components/align/index.js +0 -110
- package/lib/components/dynamic/dynamic-item/components/assessment/index.css +0 -20
- package/lib/components/dynamic/dynamic-item/components/assessment/index.js +0 -48
- package/lib/components/dynamic/dynamic-item/components/common-dynamic/index.css +0 -34
- package/lib/components/dynamic/dynamic-item/components/create-o/index.css +0 -52
- package/lib/components/dynamic/dynamic-item/components/create-o/index.js +0 -104
- package/lib/components/dynamic/dynamic-item/components/dynamic-desc/index.css +0 -62
- package/lib/components/dynamic/dynamic-item/components/dynamic-desc/index.js +0 -257
- package/lib/components/dynamic/dynamic-item/components/publish-content/index.css +0 -22
- package/lib/components/dynamic/dynamic-item/components/relative/index.css +0 -66
- package/lib/components/dynamic/dynamic-item/components/relative/index.js +0 -124
- package/lib/components/dynamic/dynamic-item/components/replay/index.css +0 -93
- package/lib/components/dynamic/dynamic-item/components/report/index.css +0 -32
- package/lib/components/dynamic/dynamic-item/components/report/index.js +0 -82
- package/lib/components/dynamic/dynamic-item/components/task-project/index.css +0 -57
- package/lib/components/dynamic/dynamic-item/components/task-project/index.js +0 -87
- package/lib/components/dynamic/dynamic-item/components/task-project-icon/index.css +0 -20
- package/lib/components/dynamic/dynamic-item/components/task-project-icon/index.js +0 -40
- package/lib/components/dynamic/dynamic-topping/mock.js +0 -1
- package/lib/pages/like-ranking/tab-bar/index.css +0 -22
- package/lib/pages/like-ranking/tab-bar/index.js +0 -65
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
+
|
|
14
|
+
var _dynamicLeftQuoto = _interopRequireDefault(require("../../img/dynamic-left-quoto.svg"));
|
|
15
|
+
|
|
16
|
+
var _dynamicRightQuoto = _interopRequireDefault(require("../../img/dynamic-right-quoto.svg"));
|
|
17
|
+
|
|
18
|
+
var _manager = _interopRequireDefault(require("../../../drawer/manager"));
|
|
19
|
+
|
|
20
|
+
var _context = require("../../context");
|
|
21
|
+
|
|
22
|
+
var _searchKeyHandle = _interopRequireDefault(require("../../../search-key-handle"));
|
|
23
|
+
|
|
24
|
+
var _header = _interopRequireDefault(require("../components/header"));
|
|
25
|
+
|
|
26
|
+
var _title = _interopRequireDefault(require("../../components/title"));
|
|
27
|
+
|
|
28
|
+
var _percent = _interopRequireDefault(require("../../components/percent"));
|
|
29
|
+
|
|
30
|
+
var _objStatus = _interopRequireDefault(require("../../components/obj-status"));
|
|
31
|
+
|
|
32
|
+
var _util = require("../../util");
|
|
33
|
+
|
|
34
|
+
var _constant = require("../../constant");
|
|
35
|
+
|
|
36
|
+
var _tooltip = require("../../../tooltip");
|
|
37
|
+
|
|
38
|
+
require("./index.css");
|
|
39
|
+
|
|
40
|
+
var _excluded = ["data"];
|
|
41
|
+
|
|
42
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
43
|
+
|
|
44
|
+
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); }
|
|
45
|
+
|
|
46
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
47
|
+
|
|
48
|
+
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); }
|
|
49
|
+
|
|
50
|
+
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; }
|
|
51
|
+
|
|
52
|
+
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; }
|
|
53
|
+
|
|
54
|
+
var prefix = "titaui-dynamic-kr-item";
|
|
55
|
+
|
|
56
|
+
var DynamicKr = function DynamicKr(_ref) {
|
|
57
|
+
var data = _ref.data,
|
|
58
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
59
|
+
|
|
60
|
+
var progress = data.progress,
|
|
61
|
+
progressDescription = data.progressDescription,
|
|
62
|
+
progressGrow = data.progressGrow,
|
|
63
|
+
riskLevel = data.riskLevel,
|
|
64
|
+
name = data.name,
|
|
65
|
+
krId = data.krId;
|
|
66
|
+
|
|
67
|
+
var _useContext = (0, _react.useContext)(_context.SearchKeyContext),
|
|
68
|
+
searchKeyWord = _useContext.searchKeyWord;
|
|
69
|
+
|
|
70
|
+
var _getFeedTypeAndTypeCo = (0, _util.getFeedTypeAndTypeColor)(data.feedType),
|
|
71
|
+
feedTypeText = _getFeedTypeAndTypeCo.feedTypeText,
|
|
72
|
+
feedTypeColor = _getFeedTypeAndTypeCo.feedTypeColor;
|
|
73
|
+
|
|
74
|
+
var handleClickKrTitle = function handleClickKrTitle() {
|
|
75
|
+
_manager["default"].open("krDetail", {
|
|
76
|
+
krId: krId
|
|
77
|
+
});
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
var handleClickOTitle = function handleClickOTitle() {
|
|
81
|
+
_manager["default"].open("okrDetail", {
|
|
82
|
+
okrId: data.obj.objId
|
|
83
|
+
});
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
var renderDesc = (0, _react.useMemo)(function () {
|
|
87
|
+
return /*#__PURE__*/_react["default"].createElement(_react.Fragment, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
88
|
+
className: prefix + "__operate-desc"
|
|
89
|
+
}, /*#__PURE__*/_react["default"].createElement("span", {
|
|
90
|
+
className: prefix + "__operate-desc-wrapper"
|
|
91
|
+
}, "\u8D1F\u8D23\u4E86", _constant.ObjTypeMapText[data.obj.objType], /*#__PURE__*/_react["default"].createElement("span", {
|
|
92
|
+
className: prefix + "__object-name",
|
|
93
|
+
onClick: handleClickOTitle
|
|
94
|
+
}, /*#__PURE__*/_react["default"].createElement(_tooltip.TooltipText, {
|
|
95
|
+
text: data.obj.objName,
|
|
96
|
+
isPercent: true
|
|
97
|
+
})), "\u4E0B\u5173\u952E\u6210\u679C")), /*#__PURE__*/_react["default"].createElement("span", {
|
|
98
|
+
className: prefix + "-desc-operate-type",
|
|
99
|
+
style: {
|
|
100
|
+
background: feedTypeColor
|
|
101
|
+
}
|
|
102
|
+
}, feedTypeText));
|
|
103
|
+
}, []);
|
|
104
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
105
|
+
className: prefix
|
|
106
|
+
}, /*#__PURE__*/_react["default"].createElement(_header["default"], _extends({
|
|
107
|
+
data: data
|
|
108
|
+
}, restProps, {
|
|
109
|
+
desc: renderDesc
|
|
110
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
111
|
+
className: prefix + "__content"
|
|
112
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
113
|
+
className: prefix + "__title"
|
|
114
|
+
}, /*#__PURE__*/_react["default"].createElement(_title["default"], {
|
|
115
|
+
content: "KR\uFF1A".concat(name),
|
|
116
|
+
onClickTitle: handleClickKrTitle
|
|
117
|
+
}), /*#__PURE__*/_react["default"].createElement(_objStatus["default"], {
|
|
118
|
+
oStatus: 1,
|
|
119
|
+
riskLevel: riskLevel,
|
|
120
|
+
extraClass: "".concat(prefix, "__status-left")
|
|
121
|
+
}), /*#__PURE__*/_react["default"].createElement(_percent["default"], {
|
|
122
|
+
percent: progress,
|
|
123
|
+
growPercent: progressGrow,
|
|
124
|
+
extraClass: "".concat(prefix, "__percent-left")
|
|
125
|
+
})), progressDescription && /*#__PURE__*/_react["default"].createElement("div", {
|
|
126
|
+
className: prefix + "__description"
|
|
127
|
+
}, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("img", {
|
|
128
|
+
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--left"),
|
|
129
|
+
src: _dynamicLeftQuoto["default"]
|
|
130
|
+
})), /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
131
|
+
str: progressDescription,
|
|
132
|
+
keyWord: searchKeyWord
|
|
133
|
+
}), /*#__PURE__*/_react["default"].createElement("img", {
|
|
134
|
+
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--right"),
|
|
135
|
+
src: _dynamicRightQuoto["default"]
|
|
136
|
+
})))));
|
|
137
|
+
};
|
|
138
|
+
|
|
139
|
+
var _default = DynamicKr;
|
|
140
|
+
exports["default"] = _default;
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
.titaui-dynamic-progress-item {
|
|
2
|
+
font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.titaui-dynamic-progress-item__content {
|
|
6
|
+
margin-left: 69px;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.titaui-dynamic-progress-item__title {
|
|
10
|
+
display: flex;
|
|
11
|
+
align-items: center;
|
|
12
|
+
overflow: hidden;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.titaui-dynamic-progress-item__description {
|
|
16
|
+
font-size: 14px;
|
|
17
|
+
color: #3F4755;
|
|
18
|
+
line-height: 22px;
|
|
19
|
+
display: flex;
|
|
20
|
+
margin-top: 12px;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.titaui-dynamic-progress-item__description-quoto {
|
|
24
|
+
width: 12px;
|
|
25
|
+
height: 12px;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.titaui-dynamic-progress-item__description-quoto--left {
|
|
29
|
+
margin-right: 8px;
|
|
30
|
+
margin-top: -6px;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.titaui-dynamic-progress-item__description-quoto--right {
|
|
34
|
+
margin-left: 8px;
|
|
35
|
+
margin-top: 4px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.titaui-dynamic-progress-item__status-left {
|
|
39
|
+
margin-left: 12px;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.titaui-dynamic-progress-item__percent-left {
|
|
43
|
+
margin-left: 8px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.titaui-dynamic-progress-item__classify {
|
|
47
|
+
display: flex;
|
|
48
|
+
width: 18px;
|
|
49
|
+
margin-left: 8px;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.titaui-dynamic-progress-item__classify--desire {
|
|
53
|
+
background: url("../../img/dynamic-desire.svg") no-repeat;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.titaui-dynamic-progress-item__classify--promise {
|
|
57
|
+
background: url("../../img/dynamic-promise.svg") no-repeat;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.titaui-dynamic-progress-item__object-name {
|
|
61
|
+
font-size: 14px;
|
|
62
|
+
color: #2879ff;
|
|
63
|
+
line-height: 22px;
|
|
64
|
+
margin: 0 4px;
|
|
65
|
+
overflow: hidden;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.titaui-dynamic-progress-item__object-name:hover {
|
|
69
|
+
cursor: pointer;
|
|
70
|
+
color: #5c8eff;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.titaui-dynamic-progress-item__operate-desc {
|
|
74
|
+
font-size: 14px;
|
|
75
|
+
font-weight: 400;
|
|
76
|
+
color: #89919f;
|
|
77
|
+
line-height: 22px;
|
|
78
|
+
margin: 0 8px 0 4px;
|
|
79
|
+
overflow: hidden;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.titaui-dynamic-progress-item-desc-operate-type {
|
|
83
|
+
display: inline-flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
justify-content: center;
|
|
86
|
+
width: 40px;
|
|
87
|
+
height: 18px;
|
|
88
|
+
min-width: 40px;
|
|
89
|
+
clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
90
|
+
-webkit-clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
91
|
+
border-radius: 14px 10px 10px 4px;
|
|
92
|
+
font-size: 12px;
|
|
93
|
+
color: #ffffff;
|
|
94
|
+
line-height: 18px;
|
|
95
|
+
}
|
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
+
|
|
14
|
+
var _dynamicLeftQuoto = _interopRequireDefault(require("../../img/dynamic-left-quoto.svg"));
|
|
15
|
+
|
|
16
|
+
var _dynamicRightQuoto = _interopRequireDefault(require("../../img/dynamic-right-quoto.svg"));
|
|
17
|
+
|
|
18
|
+
var _manager = _interopRequireDefault(require("../../../drawer/manager"));
|
|
19
|
+
|
|
20
|
+
var _context = require("../../context");
|
|
21
|
+
|
|
22
|
+
var _searchKeyHandle = _interopRequireDefault(require("../../../search-key-handle"));
|
|
23
|
+
|
|
24
|
+
var _header = _interopRequireDefault(require("../components/header"));
|
|
25
|
+
|
|
26
|
+
var _title = _interopRequireDefault(require("../../components/title"));
|
|
27
|
+
|
|
28
|
+
var _percent = _interopRequireDefault(require("../../components/percent"));
|
|
29
|
+
|
|
30
|
+
var _objStatus = _interopRequireDefault(require("../../components/obj-status"));
|
|
31
|
+
|
|
32
|
+
var _constant = require("../../constant");
|
|
33
|
+
|
|
34
|
+
var _util = require("../../util");
|
|
35
|
+
|
|
36
|
+
require("./index.css");
|
|
37
|
+
|
|
38
|
+
var _excluded = ["data"];
|
|
39
|
+
|
|
40
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
41
|
+
|
|
42
|
+
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); }
|
|
43
|
+
|
|
44
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
45
|
+
|
|
46
|
+
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); }
|
|
47
|
+
|
|
48
|
+
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; }
|
|
49
|
+
|
|
50
|
+
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; }
|
|
51
|
+
|
|
52
|
+
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; }
|
|
53
|
+
|
|
54
|
+
var prefix = "titaui-dynamic-progress-item";
|
|
55
|
+
|
|
56
|
+
var DynamicProgress = function DynamicProgress(_ref) {
|
|
57
|
+
var data = _ref.data,
|
|
58
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
59
|
+
|
|
60
|
+
var progress = data.progress,
|
|
61
|
+
progressDescription = data.progressDescription,
|
|
62
|
+
progressGrow = data.progressGrow,
|
|
63
|
+
riskLevel = data.riskLevel,
|
|
64
|
+
obj = data.obj,
|
|
65
|
+
classify = data.classify,
|
|
66
|
+
relationParentName = data.relationParentName,
|
|
67
|
+
relationParentId = data.relationParentId;
|
|
68
|
+
|
|
69
|
+
var _useContext = (0, _react.useContext)(_context.SearchKeyContext),
|
|
70
|
+
searchKeyWord = _useContext.searchKeyWord;
|
|
71
|
+
|
|
72
|
+
var _getFeedTypeAndTypeCo = (0, _util.getFeedTypeAndTypeColor)(data.feedType),
|
|
73
|
+
feedTypeText = _getFeedTypeAndTypeCo.feedTypeText,
|
|
74
|
+
feedTypeColor = _getFeedTypeAndTypeCo.feedTypeColor;
|
|
75
|
+
|
|
76
|
+
var handleClickTitle = function handleClickTitle() {
|
|
77
|
+
if (!obj) {
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
var objType = obj.objType,
|
|
82
|
+
objId = obj.objId;
|
|
83
|
+
|
|
84
|
+
if (objType === _constant.EObjType.Kr) {
|
|
85
|
+
_manager["default"].open("krDetail", {
|
|
86
|
+
krId: objId
|
|
87
|
+
});
|
|
88
|
+
} else if (objType === _constant.EObjType.O) {
|
|
89
|
+
_manager["default"].open("okrDetail", {
|
|
90
|
+
okrId: objId
|
|
91
|
+
});
|
|
92
|
+
} else if (objType === _constant.EObjType.Task) {
|
|
93
|
+
window.Talent.app.vent.trigger("global-pull-screen", objId, "task");
|
|
94
|
+
} else if (objType === _constant.EObjType.Project) {
|
|
95
|
+
window.open(window.location.href.replace(location.hash, "#work?iTalentNavCode=tita-work&work_id=" + objId));
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
var handleClickOTitle = function handleClickOTitle() {
|
|
100
|
+
_manager["default"].open("okrDetail", {
|
|
101
|
+
okrId: relationParentId
|
|
102
|
+
});
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
var renderTitle = (0, _react.useMemo)(function () {
|
|
106
|
+
if (!obj) {
|
|
107
|
+
return;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
var objType = obj.objType,
|
|
111
|
+
objName = obj.objName;
|
|
112
|
+
|
|
113
|
+
if (objType === _constant.EObjType.Kr) {
|
|
114
|
+
return "KR:" + objName;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
if (objType === _constant.EObjType.O) {
|
|
118
|
+
return "O:" + objName;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
if (objType === _constant.EObjType.Task) {
|
|
122
|
+
return "任务:" + objName;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
if (objType === _constant.EObjType.Project) {
|
|
126
|
+
return "项目:" + objName;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
return "";
|
|
130
|
+
}, []);
|
|
131
|
+
var Classify = (0, _react.useMemo)(function () {
|
|
132
|
+
var _classNames;
|
|
133
|
+
|
|
134
|
+
if (!classify || Number(classify) == 0) {
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
139
|
+
className: (0, _classnames["default"])("".concat(prefix, "__classify"), (_classNames = {}, _defineProperty(_classNames, "".concat(prefix, "__classify--desire"), classify === 1), _defineProperty(_classNames, "".concat(prefix, "__classify--promise"), classify === 2), _classNames))
|
|
140
|
+
});
|
|
141
|
+
}, [classify]);
|
|
142
|
+
var renderDesc = (0, _react.useMemo)(function () {
|
|
143
|
+
var dom;
|
|
144
|
+
|
|
145
|
+
if (obj && obj.objType === _constant.EObjType.Kr) {
|
|
146
|
+
dom = /*#__PURE__*/_react["default"].createElement("span", null, "\u66F4\u65B0\u4E86\u76EE\u6807", /*#__PURE__*/_react["default"].createElement("span", {
|
|
147
|
+
className: prefix + "__object-name",
|
|
148
|
+
onClick: handleClickOTitle
|
|
149
|
+
}, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
150
|
+
str: relationParentName,
|
|
151
|
+
keyWord: searchKeyWord
|
|
152
|
+
})), "\u4E0B\u5173\u952E\u6210\u679C\u8FDB\u5C55");
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
if (obj && obj.objType === _constant.EObjType.O) {
|
|
156
|
+
dom = "更新了目标进展";
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
if (obj && obj.objType === _constant.EObjType.Task) {
|
|
160
|
+
dom = "更新了任务进展";
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
if (obj && obj.objType === _constant.EObjType.Project) {
|
|
164
|
+
dom = "更新了项目进展";
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
return /*#__PURE__*/_react["default"].createElement(_react.Fragment, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
168
|
+
className: prefix + "__operate-desc"
|
|
169
|
+
}, dom), /*#__PURE__*/_react["default"].createElement("span", {
|
|
170
|
+
className: prefix + "-desc-operate-type",
|
|
171
|
+
style: {
|
|
172
|
+
background: feedTypeColor
|
|
173
|
+
}
|
|
174
|
+
}, feedTypeText));
|
|
175
|
+
}, []);
|
|
176
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
177
|
+
className: prefix
|
|
178
|
+
}, /*#__PURE__*/_react["default"].createElement(_header["default"], _extends({
|
|
179
|
+
data: data
|
|
180
|
+
}, restProps, {
|
|
181
|
+
desc: renderDesc
|
|
182
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
183
|
+
className: prefix + "__content"
|
|
184
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
185
|
+
className: prefix + "__title"
|
|
186
|
+
}, /*#__PURE__*/_react["default"].createElement(_title["default"], {
|
|
187
|
+
content: renderTitle,
|
|
188
|
+
onClickTitle: handleClickTitle,
|
|
189
|
+
suffixContent: Classify
|
|
190
|
+
}), /*#__PURE__*/_react["default"].createElement(_objStatus["default"], {
|
|
191
|
+
oStatus: 1,
|
|
192
|
+
riskLevel: riskLevel,
|
|
193
|
+
extraClass: "".concat(prefix, "__status-left")
|
|
194
|
+
}), /*#__PURE__*/_react["default"].createElement(_percent["default"], {
|
|
195
|
+
percent: progress,
|
|
196
|
+
growPercent: progressGrow,
|
|
197
|
+
extraClass: "".concat(prefix, "__percent-left")
|
|
198
|
+
})), progressDescription && /*#__PURE__*/_react["default"].createElement("div", {
|
|
199
|
+
className: prefix + "__description"
|
|
200
|
+
}, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("img", {
|
|
201
|
+
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--left"),
|
|
202
|
+
src: _dynamicLeftQuoto["default"]
|
|
203
|
+
})), /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
204
|
+
str: progressDescription,
|
|
205
|
+
keyWord: searchKeyWord
|
|
206
|
+
}), /*#__PURE__*/_react["default"].createElement("img", {
|
|
207
|
+
className: (0, _classnames["default"])(prefix + "__description-quoto", prefix + "__description-quoto--right"),
|
|
208
|
+
src: _dynamicRightQuoto["default"]
|
|
209
|
+
})))));
|
|
210
|
+
};
|
|
211
|
+
|
|
212
|
+
var _default = DynamicProgress;
|
|
213
|
+
exports["default"] = _default;
|
package/lib/components/dynamic/dynamic-item/{components/task-project → dynamic-project}/constant.js
RENAMED
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
.titaui-dynamic-project-item {
|
|
2
|
+
border-radius: 12px;
|
|
3
|
+
box-shadow: 0px 0px 8px 0px rgba(127, 145, 180, 0.1);
|
|
4
|
+
background: #ffffff;
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.titaui-dynamic-project-item__content {
|
|
11
|
+
height: 78px;
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
border-radius: 8px;
|
|
15
|
+
background: #f6f7f9;
|
|
16
|
+
padding: 16px 12px 16px 16px;
|
|
17
|
+
box-sizing: border-box;
|
|
18
|
+
margin-left: 69px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.titaui-dynamic-project-item__content-info {
|
|
22
|
+
flex: 1;
|
|
23
|
+
display: flex;
|
|
24
|
+
flex-direction: column;
|
|
25
|
+
margin-left: 16px;
|
|
26
|
+
overflow: hidden;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.titaui-dynamic-project-item__content-status-and-time-range {
|
|
30
|
+
display: flex;
|
|
31
|
+
align-items: center;
|
|
32
|
+
font-size: 12px;
|
|
33
|
+
font-weight: 400;
|
|
34
|
+
color: #89919f;
|
|
35
|
+
line-height: 18px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.titaui-dynamic-project-item__content-status-text {
|
|
39
|
+
margin-left: 4px;
|
|
40
|
+
margin-right: 20px;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.titaui-dynamic-project-item__content-time-range {
|
|
44
|
+
margin-left: 4px;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.titaui-dynamic-project-item__content-title {
|
|
48
|
+
flex: 1;
|
|
49
|
+
word-break: keep-all;
|
|
50
|
+
white-space: nowrap;
|
|
51
|
+
overflow: hidden;
|
|
52
|
+
font-size: 16px;
|
|
53
|
+
font-weight: 600;
|
|
54
|
+
color: #3f4755;
|
|
55
|
+
line-height: 24px;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.titaui-dynamic-project-item__content-title-text:hover {
|
|
59
|
+
cursor: pointer;
|
|
60
|
+
color: #2879ff;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.titaui-dynamic-project-item__content-title-priority {
|
|
64
|
+
width: 18px;
|
|
65
|
+
height: 26px;
|
|
66
|
+
margin-right: 4px;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.titaui-dynamic-project-item__operate-desc {
|
|
70
|
+
font-size: 14px;
|
|
71
|
+
font-weight: 400;
|
|
72
|
+
color: #89919f;
|
|
73
|
+
line-height: 22px;
|
|
74
|
+
margin: 0 8px 0 4px;
|
|
75
|
+
overflow: hidden;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.titaui-dynamic-project-item-desc-operate-type {
|
|
79
|
+
display: inline-flex;
|
|
80
|
+
align-items: center;
|
|
81
|
+
justify-content: center;
|
|
82
|
+
width: 40px;
|
|
83
|
+
height: 18px;
|
|
84
|
+
min-width: 40px;
|
|
85
|
+
clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
86
|
+
-webkit-clip-path: polygon(0 100%, 100% 100%, 100% 0, 15% 0);
|
|
87
|
+
border-radius: 14px 10px 10px 4px;
|
|
88
|
+
font-size: 12px;
|
|
89
|
+
color: #ffffff;
|
|
90
|
+
line-height: 18px;
|
|
91
|
+
}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports["default"] = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
13
|
+
|
|
14
|
+
var _header = _interopRequireDefault(require("../components/header"));
|
|
15
|
+
|
|
16
|
+
var _icon = _interopRequireDefault(require("../components/icon"));
|
|
17
|
+
|
|
18
|
+
var _constant = require("./constant");
|
|
19
|
+
|
|
20
|
+
var _constant2 = require("../../constant");
|
|
21
|
+
|
|
22
|
+
var _context = require("../../context");
|
|
23
|
+
|
|
24
|
+
var _searchKeyHandle = _interopRequireDefault(require("../../../search-key-handle"));
|
|
25
|
+
|
|
26
|
+
var _tooltip = require("../../../tooltip");
|
|
27
|
+
|
|
28
|
+
var _project = _interopRequireDefault(require("./img/project.png"));
|
|
29
|
+
|
|
30
|
+
var _util = require("../../util");
|
|
31
|
+
|
|
32
|
+
require("./index.css");
|
|
33
|
+
|
|
34
|
+
var _excluded = ["data"];
|
|
35
|
+
|
|
36
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
37
|
+
|
|
38
|
+
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); }
|
|
39
|
+
|
|
40
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
41
|
+
|
|
42
|
+
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); }
|
|
43
|
+
|
|
44
|
+
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; }
|
|
45
|
+
|
|
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
|
+
|
|
48
|
+
var prefix = "titaui-dynamic-project-item";
|
|
49
|
+
|
|
50
|
+
var DynamicProject = function DynamicProject(_ref) {
|
|
51
|
+
var data = _ref.data,
|
|
52
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
53
|
+
|
|
54
|
+
var status = data.status,
|
|
55
|
+
workName = data.workName,
|
|
56
|
+
startDate = data.startDate,
|
|
57
|
+
deadline = data.deadline;
|
|
58
|
+
|
|
59
|
+
var _useContext = (0, _react.useContext)(_context.SearchKeyContext),
|
|
60
|
+
searchKeyWord = _useContext.searchKeyWord;
|
|
61
|
+
|
|
62
|
+
var _getFeedTypeAndTypeCo = (0, _util.getFeedTypeAndTypeColor)(data.feedType),
|
|
63
|
+
feedTypeText = _getFeedTypeAndTypeCo.feedTypeText,
|
|
64
|
+
feedTypeColor = _getFeedTypeAndTypeCo.feedTypeColor;
|
|
65
|
+
|
|
66
|
+
var handleClickTitle = function handleClickTitle() {
|
|
67
|
+
window.open(window.location.href.replace(location.hash, "#work?iTalentNavCode=tita-work&work_id=" + data.obj.objId));
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
var renderName = (0, _react.useMemo)(function () {
|
|
71
|
+
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
72
|
+
className: prefix + "__content-title-text",
|
|
73
|
+
onClick: handleClickTitle
|
|
74
|
+
}, /*#__PURE__*/_react["default"].createElement(_searchKeyHandle["default"], {
|
|
75
|
+
str: workName,
|
|
76
|
+
keyWord: searchKeyWord
|
|
77
|
+
}));
|
|
78
|
+
}, [workName]);
|
|
79
|
+
var renderDesc = (0, _react.useMemo)(function () {
|
|
80
|
+
/*#__PURE__*/
|
|
81
|
+
_react["default"].createElement(_react.Fragment, null, /*#__PURE__*/_react["default"].createElement("span", {
|
|
82
|
+
className: prefix + "__operate-desc"
|
|
83
|
+
}, "\u8D1F\u8D23\u4E86\u9879\u76EE"), /*#__PURE__*/_react["default"].createElement("span", {
|
|
84
|
+
className: prefix + "-desc-operate-type",
|
|
85
|
+
style: {
|
|
86
|
+
background: feedTypeColor
|
|
87
|
+
}
|
|
88
|
+
}, feedTypeText));
|
|
89
|
+
}, []);
|
|
90
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
91
|
+
className: prefix
|
|
92
|
+
}, /*#__PURE__*/_react["default"].createElement(_header["default"], _extends({
|
|
93
|
+
data: data
|
|
94
|
+
}, restProps, {
|
|
95
|
+
desc: renderDesc
|
|
96
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
97
|
+
className: "".concat(prefix, "__content")
|
|
98
|
+
}, /*#__PURE__*/_react["default"].createElement(_icon["default"], {
|
|
99
|
+
background: "#5C8EFF",
|
|
100
|
+
boxShadow: "0px 2px 6px 0px rgba(92, 142, 255, 0.4)",
|
|
101
|
+
imgUrl: _project["default"]
|
|
102
|
+
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
103
|
+
className: prefix + "__content-info"
|
|
104
|
+
}, /*#__PURE__*/_react["default"].createElement("div", {
|
|
105
|
+
className: prefix + "__content-title"
|
|
106
|
+
}, /*#__PURE__*/_react["default"].createElement(_tooltip.TooltipText, {
|
|
107
|
+
isPercent: true,
|
|
108
|
+
text: renderName,
|
|
109
|
+
minusWidth: 30
|
|
110
|
+
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
111
|
+
className: prefix + "__content-status-and-time-range"
|
|
112
|
+
}, /*#__PURE__*/_react["default"].createElement("i", {
|
|
113
|
+
className: (0, _classnames["default"])(_constant2.EStatusStatus2ClassType[status])
|
|
114
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
115
|
+
className: prefix + "__content-status-text"
|
|
116
|
+
}, _constant.EStatusClass2StatusTypeText[status]), /*#__PURE__*/_react["default"].createElement("i", {
|
|
117
|
+
className: (0, _classnames["default"])("tu-icon-deferred")
|
|
118
|
+
}), /*#__PURE__*/_react["default"].createElement("span", {
|
|
119
|
+
className: prefix + "__content-time-range"
|
|
120
|
+
}, startDate, "-", deadline)))));
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
var _default = DynamicProject;
|
|
124
|
+
exports["default"] = _default;
|
|
File without changes
|