@titaui/pc 1.10.6 → 1.10.7-2.beta-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (288) hide show
  1. package/.eslintrc.js +2 -2
  2. package/.prettierignore +4 -4
  3. package/lib/components/book-demo/utils.js +4 -0
  4. package/lib/components/button/default-button/index.css +10 -4
  5. package/lib/components/button/default-button/index.js +13 -2
  6. package/lib/components/change-okr-modal/index.js +6 -2
  7. package/lib/components/checkbox/index.css +1 -0
  8. package/lib/components/communication/CommunicationRecord.js +16 -16
  9. package/lib/components/communication/index.css +16 -15
  10. package/lib/components/communication/index.js +23 -6
  11. package/lib/components/communication/style.js +4 -4
  12. package/lib/components/create-okr-modal/fields/o-new-name.js +31 -21
  13. package/lib/components/create-okr-modal/fields/okr-parent.js +1 -5
  14. package/lib/components/create-okr-modal/kr-items/krDatas.js +16 -16
  15. package/lib/components/{dynamic/components/dangerous-html → dangerous-html}/index.js +0 -0
  16. package/lib/components/dialog/index.css +4 -1
  17. package/lib/components/dialog/index.js +1 -1
  18. package/lib/components/dialog-confirm/index.css +1 -1
  19. package/lib/components/drawer-manager/index.js +6 -1
  20. package/lib/components/dynamic/components/first-level-tabs/index.css +12 -2
  21. package/lib/components/dynamic/components/first-level-tabs/index.js +19 -6
  22. package/lib/components/dynamic/components/obj-status/index.css +1 -0
  23. package/lib/components/dynamic/components/obj-status/utils.js +1 -1
  24. package/lib/components/dynamic/constant.js +12 -2
  25. package/lib/components/dynamic/dynamic-item/components/feed-operate/index.css +71 -0
  26. package/lib/components/dynamic/dynamic-item/components/feed-operate/index.js +112 -0
  27. package/lib/components/dynamic/dynamic-item/components/header/index.css +2 -1
  28. package/lib/components/dynamic/dynamic-item/components/header/index.js +2 -2
  29. package/lib/components/dynamic/dynamic-item/dynamic-ai-dialy/index.js +31 -0
  30. package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +13 -7
  31. package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +10 -4
  32. package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +1 -1
  33. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +1 -1
  34. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +5 -3
  35. package/lib/components/dynamic/dynamic-item/dynamic-chart/index.css +4 -0
  36. package/lib/components/dynamic/dynamic-item/dynamic-chart/index.js +102 -0
  37. package/lib/components/dynamic/dynamic-item/dynamic-chart/utils.js +61 -0
  38. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +12 -11
  39. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +8 -5
  40. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +2 -2
  41. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +5 -3
  42. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/dynamic-share-course.png +0 -0
  43. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/jiantou-right@3x.png +0 -0
  44. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/user-photo.png +0 -0
  45. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.css +2 -2
  46. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.js +6 -5
  47. package/lib/components/dynamic/dynamic-item/dynamic-milestone/constant.js +9 -2
  48. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +2 -2
  49. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +4 -2
  50. package/lib/components/dynamic/dynamic-item/dynamic-okrs-communication/index.css +1 -1
  51. package/lib/components/dynamic/dynamic-item/dynamic-plan-communication/index.css +1 -1
  52. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +2 -6
  53. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +8 -6
  54. package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +2 -2
  55. package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +3 -1
  56. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +13 -7
  57. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +42 -6
  58. package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.css +14 -30
  59. package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.js +1 -1
  60. package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +1 -1
  61. package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +12 -3
  62. package/lib/components/dynamic/dynamic-item/dynamic-reward/img/reward.png +0 -0
  63. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +6 -1
  64. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +18 -51
  65. package/lib/components/dynamic/dynamic-item/dynamic-reward/utils.js +28 -0
  66. package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +6 -2
  67. package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +55 -2
  68. package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +2 -2
  69. package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +1 -1
  70. package/lib/components/dynamic/dynamic-item/index.css +58 -3
  71. package/lib/components/dynamic/dynamic-item/index.js +124 -23
  72. package/lib/components/dynamic/dynamic-like-ranking/item.js +1 -1
  73. package/lib/components/dynamic/dynamic-list/index.js +11 -2
  74. package/lib/components/dynamic/dynamic-topping/item.js +8 -4
  75. package/lib/components/dynamic/dynamic.js +5 -2
  76. package/lib/components/dynamic/img/dynamic-operate.png +0 -0
  77. package/lib/components/dynamic/img/dynamic-point.svg +13 -0
  78. package/lib/components/dynamic/img/dynamic-reward-hover.svg +1 -0
  79. package/lib/components/dynamic/img/dynamic-reward-normal.svg +1 -0
  80. package/lib/components/dynamic/online-broadcast/data.js +13 -1
  81. package/lib/components/e-status-dropdown/index.css +3 -0
  82. package/lib/components/e-status-dropdown/index.js +94 -0
  83. package/lib/components/edit-kr-wight/style/index.js +2 -2
  84. package/lib/components/file-list/components/single-file/index.css +6 -5
  85. package/lib/components/file-list/components/single-file/index.js +1 -1
  86. package/lib/components/file-list/index.css +1 -0
  87. package/lib/components/follower-visitor/index.js +6 -4
  88. package/lib/components/grid-layout/okr-progress/index.js +20 -30
  89. package/lib/components/help-card/image/not-try.png +0 -0
  90. package/lib/components/help-card/image/try.png +0 -0
  91. package/lib/components/help-card/index.css +31 -2
  92. package/lib/components/help-card/index.js +54 -17
  93. package/lib/components/invite-people/img/invite-people.svg +62 -0
  94. package/lib/components/invite-people/index.css +1 -1
  95. package/lib/components/mblog/index.js +14 -5
  96. package/lib/components/menus/export-modules/demo-menus/index.js +2 -2
  97. package/lib/components/menus/export-modules/demo-menus/menu-highlight.js +25 -1
  98. package/lib/components/menus/export-modules/demo-menus/menus.js +60 -11
  99. package/lib/components/menus/export-modules/manage-menus/constant.js +1 -1
  100. package/lib/components/menus/export-modules/manage-menus/index.css +3 -0
  101. package/lib/components/menus/images/okr-gongsi.svg +17 -0
  102. package/lib/components/nav-top/components/menu/index.css +24 -0
  103. package/lib/components/nav-top/components/menu/index.js +9 -1
  104. package/lib/components/nav-top/components/user-message/components/reply/index.js +9 -8
  105. package/lib/components/nav-top/components/user-message/components/reply/reply-item.js +15 -5
  106. package/lib/components/nav-top/components/user-message/index.css +4 -3
  107. package/lib/components/nav-top/components/user-message/index.js +33 -6
  108. package/lib/components/nav-top/request.apis.js +22 -8
  109. package/lib/components/nav-top/useGlobalValue.js +14 -0
  110. package/lib/components/okr-detail/components/header/o-score.js +4 -6
  111. package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.css +26 -12
  112. package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +10 -4
  113. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-project.js +20 -7
  114. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-task-level2.js +3 -1
  115. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-task.js +27 -6
  116. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/index.css +29 -10
  117. package/lib/components/okr-detail/components/okr-tree/tree-node/kr-node/index.js +1 -1
  118. package/lib/components/okr-detail/e-list/index.js +70 -24
  119. package/lib/components/okr-detail/e-list/util.js +11 -2
  120. package/lib/components/okr-detail/index.js +2 -0
  121. package/lib/components/okr-detail/okr-list/index.js +1 -5
  122. package/lib/components/okr-flow/export-modal/index.js +3 -3
  123. package/lib/components/okr-flow/root-node/index.js +14 -1
  124. package/lib/components/okr-progress-detail/index.css +11 -10
  125. package/lib/components/okr-progress-detail/index.js +5 -1
  126. package/lib/components/okr-progress-detail/utils.js +4 -4
  127. package/lib/components/okr-progress-modal/helper.js +20 -27
  128. package/lib/components/okr-share/common-painter/openDataPainter.js +34 -27
  129. package/lib/components/okrcase-library/okrcases-components/submitOkr-dialog.js +40 -36
  130. package/lib/components/open-data-painter/index.js +5 -1
  131. package/lib/components/progress/circle-progress/index.js +1 -1
  132. package/lib/components/rich-editor/basic/schema.js +47 -0
  133. package/lib/components/rich-editor/consts/events.js +12 -0
  134. package/lib/components/rich-editor/enums.js +42 -0
  135. package/lib/components/rich-editor/index.js +58 -0
  136. package/lib/components/rich-editor/keymap.js +119 -0
  137. package/lib/components/rich-editor/keymaps/index.js +241 -0
  138. package/lib/components/rich-editor/models/controller.js +18 -0
  139. package/lib/components/rich-editor/models/editor.js +47 -0
  140. package/lib/components/rich-editor/models/plugin.js +20 -0
  141. package/lib/components/rich-editor/models/schema.js +121 -0
  142. package/lib/components/rich-editor/plugins/block/block-quote/commond.js +27 -0
  143. package/lib/components/rich-editor/plugins/block/block-quote/index.js +128 -0
  144. package/lib/components/rich-editor/plugins/block/heading/commonds.js +31 -0
  145. package/lib/components/rich-editor/plugins/block/heading/index.js +190 -0
  146. package/lib/components/rich-editor/plugins/block/index.js +57 -0
  147. package/lib/components/rich-editor/plugins/block/lists/actions/conversions.js +172 -0
  148. package/lib/components/rich-editor/plugins/block/lists/actions/indent-list-items-selected.js +163 -0
  149. package/lib/components/rich-editor/plugins/block/lists/actions/indent-list.js +59 -0
  150. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-forward.js +74 -0
  151. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/index.js +45 -0
  152. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-paragraph.js +104 -0
  153. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-parent-nested-list.js +92 -0
  154. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-nested-list-with-parent-list-item.js +89 -0
  155. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-paragraph-with-list.js +48 -0
  156. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-sibling-list-items.js +61 -0
  157. package/lib/components/rich-editor/plugins/block/lists/actions/merge-lists.js +34 -0
  158. package/lib/components/rich-editor/plugins/block/lists/actions/outdent-list-items-selected.js +289 -0
  159. package/lib/components/rich-editor/plugins/block/lists/actions/wrap-and-join-lists.js +180 -0
  160. package/lib/components/rich-editor/plugins/block/lists/baseCommand.js +328 -0
  161. package/lib/components/rich-editor/plugins/block/lists/commond/indent-list.js +60 -0
  162. package/lib/components/rich-editor/plugins/block/lists/commond/index.js +396 -0
  163. package/lib/components/rich-editor/plugins/block/lists/commond/join-list-item-forward.js +45 -0
  164. package/lib/components/rich-editor/plugins/block/lists/commond/listBackspace.js +302 -0
  165. package/lib/components/rich-editor/plugins/block/lists/commond/outdent-list.js +43 -0
  166. package/lib/components/rich-editor/plugins/block/lists/index.js +224 -0
  167. package/lib/components/rich-editor/plugins/block/lists/messages.js +38 -0
  168. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/input-rule.js +152 -0
  169. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/keymap.js +33 -0
  170. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/main.js +94 -0
  171. package/lib/components/rich-editor/plugins/block/lists/styles.js +15 -0
  172. package/lib/components/rich-editor/plugins/block/lists/transforms.js +347 -0
  173. package/lib/components/rich-editor/plugins/block/lists/utils/analytics.js +48 -0
  174. package/lib/components/rich-editor/plugins/block/lists/utils/find.js +126 -0
  175. package/lib/components/rich-editor/plugins/block/lists/utils/indentation.js +87 -0
  176. package/lib/components/rich-editor/plugins/block/lists/utils/node.js +144 -0
  177. package/lib/components/rich-editor/plugins/block/lists/utils/replace-content.js +31 -0
  178. package/lib/components/rich-editor/plugins/block/lists/utils/selection.js +201 -0
  179. package/lib/components/rich-editor/plugins/block/lists/utils.js +52 -0
  180. package/lib/components/rich-editor/plugins/block/paragraph/index.js +91 -0
  181. package/lib/components/rich-editor/plugins/core/index.js +90 -0
  182. package/lib/components/rich-editor/plugins/core/pm-plugins/focus-handler.js +67 -0
  183. package/lib/components/rich-editor/plugins/core/pm-plugins/keymap.js +29 -0
  184. package/lib/components/rich-editor/plugins/core/pm-plugins/reactNodeView.js +80 -0
  185. package/lib/components/rich-editor/plugins/extension/alignment/commond.js +24 -0
  186. package/lib/components/rich-editor/plugins/extension/alignment/index.js +113 -0
  187. package/lib/components/rich-editor/plugins/extension/alignment/utils.js +19 -0
  188. package/lib/components/rich-editor/plugins/extension/index.js +18 -0
  189. package/lib/components/rich-editor/plugins/extension/placeholder/index.js +126 -0
  190. package/lib/components/rich-editor/plugins/extension/placeholder/styles.js +19 -0
  191. package/lib/components/rich-editor/plugins/index.js +44 -0
  192. package/lib/components/rich-editor/plugins/inline/color/commond.js +128 -0
  193. package/lib/components/rich-editor/plugins/inline/color/consts.js +43 -0
  194. package/lib/components/rich-editor/plugins/inline/color/index.css +61 -0
  195. package/lib/components/rich-editor/plugins/inline/color/index.js +217 -0
  196. package/lib/components/rich-editor/plugins/inline/color/selector.js +252 -0
  197. package/lib/components/rich-editor/plugins/inline/color/util.js +25 -0
  198. package/lib/components/rich-editor/plugins/inline/delete-line/index.js +149 -0
  199. package/lib/components/rich-editor/plugins/inline/em/index.js +93 -0
  200. package/lib/components/rich-editor/plugins/inline/index.js +83 -0
  201. package/lib/components/rich-editor/plugins/inline/link/commands.js +256 -0
  202. package/lib/components/rich-editor/plugins/inline/link/index.js +149 -0
  203. package/lib/components/rich-editor/plugins/inline/link/pm-plugins/fake-cursor-for-toolbar.js +77 -0
  204. package/lib/components/rich-editor/plugins/inline/link/pm-plugins/main.js +293 -0
  205. package/lib/components/rich-editor/plugins/inline/link/ui/index.css +84 -0
  206. package/lib/components/rich-editor/plugins/inline/link/ui/linkEditor.js +150 -0
  207. package/lib/components/rich-editor/plugins/inline/link/ui/linkToolbar.js +101 -0
  208. package/lib/components/rich-editor/plugins/inline/link/ui/toolbarBtn.js +117 -0
  209. package/lib/components/rich-editor/plugins/inline/link/utils.js +33 -0
  210. package/lib/components/rich-editor/plugins/inline/strong/index.js +139 -0
  211. package/lib/components/rich-editor/plugins/inline/under-line/index.js +147 -0
  212. package/lib/components/rich-editor/plugins/util.js +284 -0
  213. package/lib/components/rich-editor/react/reactNodeView.js +383 -0
  214. package/lib/components/rich-editor/react/uiProvider.js +185 -0
  215. package/lib/components/rich-editor/schemas/basic.js +309 -0
  216. package/lib/components/rich-editor/schemas/index.js +19 -0
  217. package/lib/components/rich-editor/schemas/list.js +342 -0
  218. package/lib/components/rich-editor/types/commond.js +5 -0
  219. package/lib/components/rich-editor/types/index.js +18 -0
  220. package/lib/components/rich-editor/ui/Popup/index.js +247 -0
  221. package/lib/components/rich-editor/ui/Popup/utils.js +399 -0
  222. package/lib/components/rich-editor/ui/editor/index.css +178 -0
  223. package/lib/components/rich-editor/ui/editor/index.js +153 -0
  224. package/lib/components/rich-editor/ui/normal-toolbar/index.css +34 -0
  225. package/lib/components/rich-editor/ui/normal-toolbar/index.js +109 -0
  226. package/lib/components/rich-editor/utils/browser.js +35 -0
  227. package/lib/components/rich-editor/utils/commands.js +266 -0
  228. package/lib/components/rich-editor/utils/document.js +211 -0
  229. package/lib/components/rich-editor/utils/event.js +79 -0
  230. package/lib/components/rich-editor/utils/helpers.js +16 -0
  231. package/lib/components/rich-editor/utils/mark.js +168 -0
  232. package/lib/components/rich-editor/utils/slice.js +85 -0
  233. package/lib/components/rich-editor/utils/toolbar.js +228 -0
  234. package/lib/components/superset-charts/components/chart/index.js +54 -0
  235. package/lib/components/superset-charts/fetch-assets-and-append/append-assets.js +106 -0
  236. package/lib/components/superset-charts/fetch-assets-and-append/get-assets-with-cache.js +131 -0
  237. package/lib/components/superset-charts/fetch-assets-and-append/index.js +79 -0
  238. package/lib/components/superset-charts/index.js +13 -0
  239. package/lib/components/superset-charts/interface.js +5 -0
  240. package/lib/components/superset-charts/utils/axios.js +102 -0
  241. package/lib/components/toast/index.js +5 -17
  242. package/lib/components/tree/index.css +3 -2
  243. package/lib/components/upload/index.js +4 -2
  244. package/lib/components/upload/util.js +2 -0
  245. package/lib/components/upload-photo-modal/request-api.js +1 -17
  246. package/lib/components/user-selector/empty/index.css +6 -6
  247. package/lib/components/user-selector/selected-panel/index.css +3 -3
  248. package/lib/components/{float-fixed-video-modal → video-modal/components/video-box}/index.css +118 -121
  249. package/lib/components/{float-fixed-video-modal → video-modal/components/video-box}/index.js +182 -182
  250. package/lib/components/{float-fixed-video-modal → video-modal}/img/close.png +0 -0
  251. package/lib/components/{float-fixed-video-modal → video-modal}/img/full.svg +0 -0
  252. package/lib/components/video-modal/img/muted.svg +8 -10
  253. package/lib/components/video-modal/img/not-muted.svg +17 -11
  254. package/lib/components/video-modal/img/pause.svg +7 -11
  255. package/lib/components/video-modal/img/play.svg +13 -11
  256. package/lib/components/video-modal/index.css +38 -168
  257. package/lib/components/video-modal/index.js +104 -244
  258. package/lib/components/video-modal/utils.js +2 -2
  259. package/lib/components/weekly-report/common-painter/openDataPainter.js +5 -1
  260. package/lib/hooks/useGlobalState.js +63 -0
  261. package/lib/index.js +31 -7
  262. package/lib/pages/aha2021/img/canceled.svg +13 -0
  263. package/lib/pages/aha2021/img/not-try.png +0 -0
  264. package/lib/pages/aha2021/img/try.png +0 -0
  265. package/lib/pages/aha2021/index.css +52 -0
  266. package/lib/pages/aha2021/index.js +73 -14
  267. package/lib/pages/new-okr-list/header/index.js +2 -1
  268. package/lib/pages/new-okr-list/index.js +3 -3
  269. package/lib/pages/okr-map/export-modules/share-okr-page/header/index.js +0 -5
  270. package/lib/pages/pay/image/success.png +0 -0
  271. package/lib/pages/pay/index.css +79 -0
  272. package/lib/pages/pay/index.js +66 -0
  273. package/lib/pages/personal-info/request-api.js +1 -1
  274. package/lib/utils/auth.js +15 -5
  275. package/lib/utils/bs-global.js +8 -8
  276. package/lib/utils/helpers.js +7 -1
  277. package/lib/utils/open-data.js +82 -2
  278. package/lib/utils/tools.js +11 -2
  279. package/package.json +120 -101
  280. package/lib/components/float-fixed-video-modal/img/muted.svg +0 -21
  281. package/lib/components/float-fixed-video-modal/img/pause.svg +0 -21
  282. package/lib/components/float-fixed-video-modal/img/play.svg +0 -22
  283. package/lib/components/float-fixed-video-modal/img/small.svg +0 -22
  284. package/lib/components/float-fixed-video-modal/img/smallFaQi.png +0 -0
  285. package/lib/components/float-fixed-video-modal/img/volume.svg +0 -21
  286. package/lib/components/float-fixed-video-modal/utils.js +0 -25
  287. package/lib/components/invite-people/img/invite-people.png +0 -0
  288. package/lib/components/video-modal/img/play.png +0 -0
@@ -13,6 +13,7 @@
13
13
  font-weight: 600;
14
14
  cursor: pointer;
15
15
  color: #ffffff;
16
+ position: relative;
16
17
  }
17
18
 
18
19
  .titaui-nav-top-menu__menu-show:hover {
@@ -38,6 +39,29 @@
38
39
  transform: translate(-50%, 0);
39
40
  }
40
41
 
42
+ .titaui-nav-top-menu__menu--hasNum {
43
+ position: absolute;
44
+ right: 4px;
45
+ top: 1px;
46
+ background: #fe5042;
47
+ border-radius: 18px;
48
+ height: 16px;
49
+ font-size: 12px;
50
+ color: #ffffff;
51
+ line-height: 18px;
52
+ padding: 0 4px;
53
+ display: flex;
54
+ align-items: center;
55
+ justify-content: center;
56
+ min-width: 8px;
57
+ font-weight: 400;
58
+ }
59
+
60
+ .titaui-nav-top-menu__menu--hasNum-active {
61
+ right: 5px;
62
+ top: 3px;
63
+ }
64
+
41
65
  .titaui-nav-top-menu__hide-menus {
42
66
  display: flex;
43
67
  flex-direction: column;
@@ -19,6 +19,8 @@ var _popup = _interopRequireDefault(require("../../../popup"));
19
19
 
20
20
  var _conditionRender = _interopRequireDefault(require("../../../../components/condition-render"));
21
21
 
22
+ var _useGlobalValue3 = _interopRequireDefault(require("../../useGlobalValue"));
23
+
22
24
  require("./index.css");
23
25
 
24
26
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -60,6 +62,10 @@ var Menu = function Menu(_ref) {
60
62
  popupVisible = _useState2[0],
61
63
  setPopupVisible = _useState2[1];
62
64
 
65
+ var _useGlobalValue = (0, _useGlobalValue3["default"])(),
66
+ _useGlobalValue2 = _slicedToArray(_useGlobalValue, 1),
67
+ feedNum = _useGlobalValue2[0];
68
+
63
69
  var containerRef = (0, _react.useRef)();
64
70
  var apiPath = (0, _bsGlobal.getBSGlobal)("apiPath");
65
71
  var userId = (0, _bsGlobal.getUserInfo)().Id;
@@ -94,7 +100,9 @@ var Menu = function Menu(_ref) {
94
100
  onClick: function onClick() {
95
101
  return handleTracker(menu);
96
102
  }
97
- }, menu.title)), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
103
+ }, menu.title, menu.href === "#dynamic" && feedNum > 0 && /*#__PURE__*/_react["default"].createElement("div", {
104
+ className: (0, _classnames["default"])("".concat(prefix, "__menu--hasNum"), _defineProperty({}, "".concat(prefix, "__menu--hasNum-active"), activeMenuId === menu.id && menu.href === "#dynamic"))
105
+ }, feedNum > 100 ? "99+" : feedNum))), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
98
106
  condition: menu.title === "Learning"
99
107
  }, /*#__PURE__*/_react["default"].createElement("span", {
100
108
  className: (0, _classnames["default"])("".concat(prefix, "__menu-show"), _defineProperty({}, "".concat(prefix, "__menu-show--active"), activeMenuId === menu.id)),
@@ -56,8 +56,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
56
56
  var preCls = "titaui-user-message-msg-reply";
57
57
 
58
58
  function Reply(props) {
59
- var onItemClick = props.onItemClick,
60
- handleIntervalRequestMessageInfo = props.handleIntervalRequestMessageInfo;
59
+ var onItemClick = props.onItemClick;
61
60
 
62
61
  var _useState = (0, _react.useState)([]),
63
62
  _useState2 = _slicedToArray(_useState, 2),
@@ -108,6 +107,10 @@ function Reply(props) {
108
107
  }
109
108
  };
110
109
 
110
+ var handleDeleteReply = function handleDeleteReply(msgId) {
111
+ (0, _request.deleteReply)(msgId);
112
+ };
113
+
111
114
  (0, _react.useEffect)(function () {
112
115
  setTimeout(function () {
113
116
  (0, _request.getReplys)(1).then(function (res) {
@@ -118,17 +121,14 @@ function Reply(props) {
118
121
 
119
122
  setIsLoading(false);
120
123
  });
121
- (0, _request.clearReplys)().then(function () {
122
- return handleIntervalRequestMessageInfo();
123
- });
124
124
  }, 300);
125
125
  }, []);
126
- console.log(replys);
127
126
  return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
128
127
  condition: isLoading
129
128
  }, /*#__PURE__*/_react["default"].createElement("img", {
130
129
  src: _loading["default"],
131
- className: (0, _classnames["default"])("".concat(preCls, "__loading"))
130
+ className: (0, _classnames["default"])("".concat(preCls, "__loading")),
131
+ alt: "\u6B63\u5728\u8BF7\u6C42"
132
132
  })), /*#__PURE__*/_react["default"].createElement(_conditionRender["default"], {
133
133
  condition: replys.length !== 0
134
134
  }, /*#__PURE__*/_react["default"].createElement("ul", {
@@ -144,7 +144,8 @@ function Reply(props) {
144
144
  return /*#__PURE__*/_react["default"].createElement(_replyItem["default"], {
145
145
  item: item,
146
146
  onItemClick: onItemClick,
147
- replys: replys
147
+ replys: replys,
148
+ handleDeleteReply: handleDeleteReply
148
149
  });
149
150
  })), /*#__PURE__*/_react["default"].createElement("div", {
150
151
  className: (0, _classnames["default"])("".concat(preCls, "__footer"))
@@ -30,14 +30,17 @@ var preCls = "titaui-user-message-msg-reply";
30
30
  function Reply(props) {
31
31
  var item = props.item,
32
32
  onItemClick = props.onItemClick,
33
- replys = props.replys;
33
+ replys = props.replys,
34
+ handleDeleteReply = props.handleDeleteReply;
34
35
 
35
36
  var handleReplyClick = function handleReplyClick() {
36
- onItemClick && onItemClick(false);
37
+ if (onItemClick) {
38
+ onItemClick(false);
39
+ }
37
40
  };
38
41
 
39
42
  var getDescText = function getDescText() {
40
- if (item.content.indexOf("@") != -1) {
43
+ if (item.content.indexOf("@") !== -1) {
41
44
  return "@我";
42
45
  }
43
46
 
@@ -56,8 +59,15 @@ function Reply(props) {
56
59
  return (0, _utils.deleteText)((0, _utils.htmlToText)(item.content));
57
60
  };
58
61
 
59
- return /*#__PURE__*/_react["default"].createElement("li", {
60
- className: (0, _classnames["default"])("".concat(preCls, "__item"), _defineProperty({}, "".concat(preCls, "__item--scroll"), replys.length >= 4))
62
+ var handleReplyItemClick = function handleReplyItemClick(msgId) {
63
+ handleDeleteReply(msgId);
64
+ };
65
+
66
+ return /*#__PURE__*/_react["default"].createElement("div", {
67
+ className: (0, _classnames["default"])("".concat(preCls, "__item"), _defineProperty({}, "".concat(preCls, "__item--scroll"), replys.length >= 4)),
68
+ onClick: function onClick() {
69
+ return handleReplyItemClick(item.msgId);
70
+ }
61
71
  }, /*#__PURE__*/_react["default"].createElement("div", {
62
72
  className: (0, _classnames["default"])("".concat(preCls, "__item-photo"))
63
73
  }, /*#__PURE__*/_react["default"].createElement(_avatar["default"], {
@@ -26,15 +26,16 @@
26
26
 
27
27
  .titaui-user-message__msg-total {
28
28
  position: absolute;
29
- background: #f05e5e;
30
- box-shadow: 0px 2px 4px 0px rgba(240, 94, 94, 0.6), inset 0px 0px 2px 1px rgba(255, 255, 255, 0.4);
31
- border-radius: 8px;
29
+ background: #fe5042;
30
+ border-radius: 18px;
32
31
  font-size: 12px;
33
32
  color: #ffffff;
34
33
  line-height: 16px;
35
34
  padding: 0 4px;
36
35
  top: -4px;
37
36
  left: 12px;
37
+ text-align: center;
38
+ min-width: 8px;
38
39
  }
39
40
 
40
41
  .titaui-user-message__popup-right-top-enter {
@@ -27,6 +27,8 @@ var _request = require("../../request.apis");
27
27
 
28
28
  var _bell3x = _interopRequireDefault(require("./images/bell@3x.png"));
29
29
 
30
+ var _useGlobalValue = _interopRequireDefault(require("../../useGlobalValue"));
31
+
30
32
  require("./index.css");
31
33
 
32
34
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
@@ -82,6 +84,8 @@ function UserMessage() {
82
84
  firstTab = _useState12[0],
83
85
  setFirstTab = _useState12[1];
84
86
 
87
+ var setFeedNum = (0, _useGlobalValue["default"])()[1];
88
+
85
89
  var handleShowInfos = function handleShowInfos() {
86
90
  setPopupVisible(true);
87
91
  };
@@ -137,18 +141,28 @@ function UserMessage() {
137
141
 
138
142
  var enterpriseMedalMsg = indicators.filter(function (item) {
139
143
  return item.messageType === 1 && item.indicatorType === 1969002;
140
- }); // @ts-ignore
144
+ });
141
145
 
142
- enterpriseMedalMsg.length > 0 && window.util.upaasEnterpriseMedal(); // upaas 勋章
146
+ if (enterpriseMedalMsg.length > 0) {
147
+ window.util.upaasEnterpriseMedal();
148
+ } // upaas 勋章
143
149
 
144
- var medalDetail = (0, _bsGlobal.getBSGlobal)("medalDetail"); // @ts-ignore
145
150
 
146
- medalDetail && window.util.upaasMedal()(medalDetail); // 红包
151
+ var medalDetail = (0, _bsGlobal.getBSGlobal)("medalDetail");
152
+
153
+ if (medalDetail) {
154
+ window.util.upaasMedal()(medalDetail);
155
+ } // 红包
156
+
147
157
 
148
158
  var mRedPackIndicator = indicators.filter(function (item) {
149
159
  return item.type === "mRedPackIndicator";
150
160
  });
151
- mRedPackIndicator.length > 0 && setRedPackNum(mRedPackIndicator[0].value); // 祝福,拆礼物
161
+
162
+ if (mRedPackIndicator.length > 0) {
163
+ setRedPackNum(mRedPackIndicator[0].value);
164
+ } // 祝福,拆礼物
165
+
152
166
 
153
167
  var blessIndicator = indicators.filter(function (item) {
154
168
  return item.type === "mZhufu";
@@ -173,6 +187,18 @@ function UserMessage() {
173
187
 
174
188
  (_window = window) === null || _window === void 0 ? void 0 : _window.Talent.app.vent.trigger("open-weekly-report-modal");
175
189
  }
190
+
191
+ var feedInfo = indicators.find(function (item) {
192
+ return item.type === "feedAboutMeIndicator";
193
+ });
194
+
195
+ if (feedInfo) {
196
+ // @ts-ignore
197
+ setFeedNum(feedInfo.value);
198
+ } else {
199
+ // @ts-ignore
200
+ setFeedNum(0);
201
+ }
176
202
  }
177
203
  });
178
204
  };
@@ -203,7 +229,8 @@ function UserMessage() {
203
229
  className: (0, _classnames["default"])("".concat(prefixCls, "__msg-total"))
204
230
  }, infosNum > 100 ? "99+" : infosNum)), /*#__PURE__*/_react["default"].createElement("img", {
205
231
  src: _bell3x["default"],
206
- className: (0, _classnames["default"])(_defineProperty({}, "".concat(prefixCls, "__msg-dot"), infosNum !== preData))
232
+ className: (0, _classnames["default"])(_defineProperty({}, "".concat(prefixCls, "__msg-dot"), infosNum !== preData)),
233
+ alt: ""
207
234
  }))), /*#__PURE__*/_react["default"].createElement(_redPack["default"], {
208
235
  redPackNum: redPackNum
209
236
  }));
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.getTodos = exports.getReplys = exports.getReminds = exports.getMessages = exports.getInforms = exports.getData = exports.clearReplys = exports.clearInforms = exports.changeLang = void 0;
6
+ exports.getTodos = exports.getReplys = exports.getReminds = exports.getMessages = exports.getInforms = exports.getData = exports.deleteReply = exports.clearReplys = exports.clearInforms = exports.changeLang = void 0;
7
7
 
8
8
  var _axios = _interopRequireDefault(require("axios"));
9
9
 
@@ -11,6 +11,7 @@ var _request = require("../../utils/request");
11
11
 
12
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
13
 
14
+ /* eslint-disable default-case */
14
15
  // @ts-ignore
15
16
  var tenantId = window.BSGlobal && window.BSGlobal.tenantInfo.Id || 0; // @ts-ignore
16
17
 
@@ -36,7 +37,7 @@ var getData = function getData(url, saveData) {
36
37
  exports.getData = getData;
37
38
 
38
39
  var getReplys = function getReplys(pageNum) {
39
- return (0, _request.rget)("v1")("comment/messages?page_num=".concat(pageNum, "&page_size=10&status=1"));
40
+ return (0, _request.rget)("v1")("comment/messages?page_num=".concat(pageNum, "&page_size=10&status=1&clear=0"));
40
41
  };
41
42
 
42
43
  exports.getReplys = getReplys;
@@ -65,20 +66,33 @@ var clearReplys = function clearReplys() {
65
66
 
66
67
  exports.clearReplys = clearReplys;
67
68
 
69
+ var deleteReply = function deleteReply(msgId) {
70
+ return (0, _request.rpost)("v1")("messages/clear?msgId=".concat(msgId));
71
+ };
72
+
73
+ exports.deleteReply = deleteReply;
74
+
68
75
  var getMessages = function getMessages() {
69
76
  var nowTime = new Date();
70
77
  var year = nowTime.getFullYear();
71
78
  var month = nowTime.getMonth() + 1;
72
79
  var date = nowTime.getDate();
73
- return _axios["default"].get("".concat(requestDomain(), "/api/v1/").concat(tenantId, "/").concat(userId, "/RemindV2/Get?dateTime=").concat(year, "/").concat(month, "/").concat(date)).then(function (resp) {
74
- if (resp.code === 401) {
75
- window.location.href = "/Account/Logout";
76
- return undefined;
80
+
81
+ _axios["default"].interceptors.response.use(function (response) {
82
+ return response;
83
+ }, function (error) {
84
+ if (error.response) {
85
+ switch (error.response.status) {
86
+ case 401:
87
+ window.location.reload();
88
+ }
77
89
  }
78
90
 
91
+ return Promise.reject(error.response.data);
92
+ });
93
+
94
+ return _axios["default"].get("".concat(requestDomain(), "/api/v1/").concat(tenantId, "/").concat(userId, "/RemindV2/Get?dateTime=").concat(year, "/").concat(month, "/").concat(date)).then(function (resp) {
79
95
  return resp.data;
80
- }).then(function (data) {
81
- return data;
82
96
  });
83
97
  };
84
98
 
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+
8
+ var _useGlobalState = _interopRequireDefault(require("../../hooks/useGlobalState"));
9
+
10
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
11
+
12
+ var useGlobalValue = (0, _useGlobalState["default"])(0);
13
+ var _default = useGlobalValue;
14
+ exports["default"] = _default;
@@ -75,7 +75,7 @@ function OScore(props) {
75
75
  refreshAll = _useContext.refreshAll;
76
76
 
77
77
  var _useState3 = (0, _react.useState)({
78
- score: score == 1 ? "1" : Number(score).toFixed(2) * 1
78
+ score: Number(score) === 1 ? "1" : Number(score).toFixed(2) * 1
79
79
  }),
80
80
  _useState4 = _slicedToArray(_useState3, 2),
81
81
  formFiedlsValue = _useState4[0],
@@ -85,7 +85,7 @@ function OScore(props) {
85
85
  var formRef = (0, _react.useRef)();
86
86
  (0, _react.useEffect)(function () {
87
87
  setFormFiedlsValue({
88
- score: score == 1 ? "1" : Number(score).toFixed(2) * 1
88
+ score: Number(score) === 1 ? "1" : Number(score).toFixed(2) * 1
89
89
  });
90
90
  }, [score]);
91
91
 
@@ -115,9 +115,7 @@ function OScore(props) {
115
115
  } else {
116
116
  _toast["default"].Error(res.Message || "".concat((0, _getLocale.getLocale)("OKR_MyO_Ew_Fail")));
117
117
  }
118
- })["catch"](function (err) {
119
- console.log(err);
120
-
118
+ })["catch"](function () {
121
119
  _toast["default"].Error("".concat((0, _getLocale.getLocale)("OKR_MyO_Ew_Fail")));
122
120
  });
123
121
  };
@@ -133,7 +131,7 @@ function OScore(props) {
133
131
  score: score,
134
132
  onClick: changeOScore
135
133
  }, restProps)), /*#__PURE__*/_react["default"].createElement(_dialog["default"], {
136
- title: "O ".concat((0, _getLocale.getLocale)("Per_Ass_New_Appr_detail_Scor")),
134
+ title: "".concat((0, _getLocale.getLocale)("Mod_Objective")).concat((0, _getLocale.getLocale)("Per_Ass_New_Appr_detail_Scor")),
137
135
  visible: visible,
138
136
  animation: "slide-fade",
139
137
  maskAnimation: "fade",
@@ -5,46 +5,59 @@
5
5
  display: flex;
6
6
  }
7
7
 
8
+ .tita-okrdt-tree__e-kr-node:hover .tita-okrdt-tree__e-kr-node-actions {
9
+ opacity: 1;
10
+ transition: all 0.2s linear;
11
+ }
12
+
13
+ .tita-okrdt-tree__e-kr-node-preicon {
14
+ display: inline-block;
15
+ line-height: 18px;
16
+ color: #2879ff;
17
+ font-size: 16px;
18
+ }
19
+
8
20
  .tita-okrdt-tree__e-kr-node-prefix {
9
21
  display: inline-block;
10
- height: 22px;
11
- font-size: 14px;
22
+ height: 18px;
23
+ font-size: 12px;
12
24
  font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
13
25
  color: #2879ff;
14
- line-height: 22px;
26
+ line-height: 18px;
15
27
  }
16
28
 
17
29
  .tita-okrdt-tree__e-kr-node-title {
18
30
  display: inline-block;
19
31
  margin-left: 4px;
20
- height: 22px;
21
- font-size: 14px;
32
+ height: 18px;
33
+ font-size: 12px;
22
34
  font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
23
35
  color: #89919f;
24
- line-height: 22px;
36
+ line-height: 18px;
25
37
  width: 100%;
26
38
  }
27
39
 
28
40
  .tita-okrdt-tree__e-kr-node-actions {
29
41
  display: inline-block;
42
+ opacity: 0;
30
43
  position: absolute;
31
44
  right: 0;
45
+ transition: all 0.2s linear;
32
46
  }
33
47
 
34
48
  .tita-okrdt-tree__e-kr-node-actions-create {
35
49
  height: 18px;
36
- font-size: 13px;
50
+ font-size: 12px;
37
51
  font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
38
52
  color: #2879ff;
39
53
  line-height: 18px;
40
54
  cursor: pointer;
41
- margin-right: 20px;
42
55
  display: inline-flex;
43
56
  align-items: center;
44
57
  }
45
58
 
46
59
  .tita-okrdt-tree__e-kr-node-actions-create:hover {
47
- color: #5C8EFF;
60
+ color: #5c8eff;
48
61
  }
49
62
 
50
63
  .tita-okrdt-tree__e-kr-node-actions-create .tu-icon-add1 {
@@ -53,21 +66,22 @@
53
66
 
54
67
  .tita-okrdt-tree__e-kr-node-actions-connect {
55
68
  height: 18px;
56
- font-size: 13px;
69
+ font-size: 12px;
57
70
  font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
58
71
  color: #2879ff;
59
72
  line-height: 18px;
60
73
  cursor: pointer;
74
+ margin-left: 20px;
61
75
  display: inline-flex;
62
76
  align-items: center;
63
77
  }
64
78
 
65
79
  .tita-okrdt-tree__e-kr-node-actions-connect:hover {
66
- color: #5C8EFF;
80
+ color: #5c8eff;
67
81
  }
68
82
 
69
83
  .e-kr-node-layer-icon {
70
- color: #89919F;
84
+ color: #89919f;
71
85
  }
72
86
 
73
87
  .e-kr-node__guanlian-icon {
@@ -44,10 +44,14 @@ function _asyncToGenerator(fn) { return function () { var self = this, args = ar
44
44
  var hasProject = (0, _bsGlobal.hasWebHead)("project");
45
45
 
46
46
  var EKrNode = function EKrNode(props) {
47
+ var _okrInfo$authority;
48
+
47
49
  var index = props.index,
48
50
  title = props.title,
49
51
  data = props.data,
50
- isOTask = props.isOTask;
52
+ isOTask = props.isOTask,
53
+ _props$hasRelation = props.hasRelation,
54
+ hasRelation = _props$hasRelation === void 0 ? true : _props$hasRelation;
51
55
  var btnRef = (0, _react.useRef)();
52
56
 
53
57
  var _useContext = (0, _react.useContext)(_context2.CommonContext),
@@ -56,7 +60,7 @@ var EKrNode = function EKrNode(props) {
56
60
  var _useContext2 = (0, _react.useContext)(_context2.EListContext),
57
61
  refreshEList = _useContext2.refreshEList;
58
62
 
59
- var isParticipant = okrInfo.authority.roleRelation && okrInfo.authority.roleRelation.roleType === 2;
63
+ var isParticipant = ((_okrInfo$authority = okrInfo.authority) === null || _okrInfo$authority === void 0 ? void 0 : _okrInfo$authority.roleRelation) && okrInfo.authority.roleRelation.roleType === 2;
60
64
  var hasRelativeAuth;
61
65
 
62
66
  if (isOTask) {
@@ -168,7 +172,9 @@ var EKrNode = function EKrNode(props) {
168
172
  return /*#__PURE__*/_react["default"].createElement("div", {
169
173
  key: index,
170
174
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-kr-node"))
171
- }, isOTask ? null : /*#__PURE__*/_react["default"].createElement("span", {
175
+ }, isOTask ? /*#__PURE__*/_react["default"].createElement("span", {
176
+ className: (0, _classnames["default"])("tu-icon-O ".concat(_precls["default"], "__e-kr-node-preicon"))
177
+ }) : /*#__PURE__*/_react["default"].createElement("span", {
172
178
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-kr-node-prefix"))
173
179
  }, "KR", index + 1), /*#__PURE__*/_react["default"].createElement("span", {
174
180
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-kr-node-title")),
@@ -202,7 +208,7 @@ var EKrNode = function EKrNode(props) {
202
208
  icon: "tu-icon-Add-xiangmu",
203
209
  exIconClass: "e-kr-node-layer-icon",
204
210
  name: "addProject"
205
- }, /*#__PURE__*/_react["default"].createElement("span", null, (0, _getLocale.getLocale)("OKR_MyO_E_Butt_Addproject"))) : /*#__PURE__*/_react["default"].createElement("span", null)), /*#__PURE__*/_react["default"].createElement(_dropSelector["default"], {
211
+ }, /*#__PURE__*/_react["default"].createElement("span", null, (0, _getLocale.getLocale)("OKR_MyO_E_Butt_Addproject"))) : /*#__PURE__*/_react["default"].createElement("span", null)), hasRelation && /*#__PURE__*/_react["default"].createElement(_dropSelector["default"], {
206
212
  popupPlacement: "bottomRight",
207
213
  onChange: openRelatePop,
208
214
  trigger: /*#__PURE__*/_react["default"].createElement("span", {
@@ -62,12 +62,18 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
62
62
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
63
63
 
64
64
  function _default(props) {
65
- var _data$principalUser, _data$principalUser2;
65
+ var _okrInfo$authority, _data$principalUser, _data$principalUser2;
66
66
 
67
67
  var index = props.index,
68
68
  title = props.title,
69
69
  data = props.data,
70
- createUserId = props.createUserId;
70
+ createUserId = props.createUserId,
71
+ _props$hasProgress = props.hasProgress,
72
+ hasProgress = _props$hasProgress === void 0 ? true : _props$hasProgress,
73
+ _props$hasRelation = props.hasRelation,
74
+ hasRelation = _props$hasRelation === void 0 ? true : _props$hasRelation,
75
+ _props$hasPrinciple = props.hasPrinciple,
76
+ hasPrinciple = _props$hasPrinciple === void 0 ? true : _props$hasPrinciple;
71
77
 
72
78
  var _useState = (0, _react.useState)(false),
73
79
  _useState2 = _slicedToArray(_useState, 2),
@@ -84,7 +90,7 @@ function _default(props) {
84
90
  var _useContext2 = (0, _react.useContext)(_context.EListContext),
85
91
  refreshEList = _useContext2.refreshEList;
86
92
 
87
- var isParticipant = okrInfo.authority.roleRelation && okrInfo.authority.roleRelation.roleType === 2;
93
+ var isParticipant = ((_okrInfo$authority = okrInfo.authority) === null || _okrInfo$authority === void 0 ? void 0 : _okrInfo$authority.roleRelation) && okrInfo.authority.roleRelation.roleType === 2;
88
94
  var hasRelativeAuth = new _auth.KRAuth({
89
95
  user: data.user,
90
96
  createUserId: createUserId
@@ -120,6 +126,9 @@ function _default(props) {
120
126
  window.open(window.location.href.replace(location.hash, "#work?iTalentNavCode=tita-work&work_id=".concat(data.id)));
121
127
  };
122
128
 
129
+ var workApplyType = data.workApplyType,
130
+ workApplyStatus = data.workApplyStatus;
131
+ var isCreate = (workApplyStatus === 1 || workApplyStatus === 3 || workApplyStatus === 4) && workApplyType === 48;
123
132
  return /*#__PURE__*/_react["default"].createElement("div", {
124
133
  key: index,
125
134
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node"))
@@ -130,12 +139,16 @@ function _default(props) {
130
139
  })), /*#__PURE__*/_react["default"].createElement("span", {
131
140
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-title ")),
132
141
  onClick: openProjectDetail
142
+ }, /*#__PURE__*/_react["default"].createElement("span", {
143
+ className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-title-name "))
133
144
  }, /*#__PURE__*/_react["default"].createElement(_tooltipText["default"], {
134
145
  text: (0, _helpers.escapeHtml)(title),
135
146
  isPercent: true
136
- })), /*#__PURE__*/_react["default"].createElement("div", {
147
+ })), isCreate && /*#__PURE__*/_react["default"].createElement("span", {
148
+ className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-title-approvaling"))
149
+ }, (0, _getLocale.getLocale)('Pro_MyS_Establishment'))), /*#__PURE__*/_react["default"].createElement("div", {
137
150
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-actions"))
138
- }, /*#__PURE__*/_react["default"].createElement("span", {
151
+ }, hasPrinciple && /*#__PURE__*/_react["default"].createElement("span", {
139
152
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-actions-user"))
140
153
  }, /*#__PURE__*/_react["default"].createElement(_avatar["default"].Text, {
141
154
  name: data === null || data === void 0 ? void 0 : (_data$principalUser = data.principalUser) === null || _data$principalUser === void 0 ? void 0 : _data$principalUser.name,
@@ -147,7 +160,7 @@ function _default(props) {
147
160
  }, /*#__PURE__*/_react["default"].createElement(_statusTime["default"], {
148
161
  deadLine: data.deadLine,
149
162
  isComplete: data.status === 2
150
- })), /*#__PURE__*/_react["default"].createElement("span", {
163
+ })), hasProgress && /*#__PURE__*/_react["default"].createElement("span", {
151
164
  className: (0, _classnames["default"])("".concat(_precls["default"], "__e-project-node-actions-progress ").concat(isGray && "".concat(_precls["default"], "__e-project-node-gray")))
152
165
  }, /*#__PURE__*/_react["default"].createElement(_progress["default"].Circle, {
153
166
  size: 22,
@@ -158,7 +171,7 @@ function _default(props) {
158
171
  linearStartColor: (0, _getProcessColor["default"])(data.riskLevel, "linearStartColor", data.status),
159
172
  linearEndColor: (0, _getProcessColor["default"])(data.riskLevel, "linearEndColor", data.status),
160
173
  backgroundColor: (0, _getProcessColor["default"])(data.riskLevel, "backgroundColor", data.status)
161
- })), okrInfo.status === 1 && (hasRelativeAuth || isParticipant) ? /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
174
+ })), okrInfo.status === 1 && hasRelation && (hasRelativeAuth || isParticipant) ? /*#__PURE__*/_react["default"].createElement(_tooltip["default"], {
162
175
  overlay: (0, _getLocale.getLocale)("OKR_MyO_Text_Cancel"),
163
176
  placement: "top"
164
177
  }, /*#__PURE__*/_react["default"].createElement("span", {
@@ -82,6 +82,8 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
82
82
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
83
83
 
84
84
  function _default(props) {
85
+ var _okrInfo$authority;
86
+
85
87
  var index = props.index,
86
88
  title = props.title,
87
89
  data = props.data,
@@ -147,7 +149,7 @@ function _default(props) {
147
149
  principalUser: okrInfo.principalUser,
148
150
  createUserId: okrInfo.createUserId
149
151
  }).hasAuth()) && data.status !== 5;
150
- var isParticipant = okrInfo.authority.roleRelation && okrInfo.authority.roleRelation.roleType === 2;
152
+ var isParticipant = ((_okrInfo$authority = okrInfo.authority) === null || _okrInfo$authority === void 0 ? void 0 : _okrInfo$authority.roleRelation) && okrInfo.authority.roleRelation.roleType === 2;
151
153
  var hasRelativeAuth = new _auth.KRAuth({
152
154
  user: data.user,
153
155
  createUserId: createUserId