@titaui/pc 1.10.5 → 1.10.6-3.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 (297) hide show
  1. package/.eslintrc.js +2 -2
  2. package/.prettierignore +1 -1
  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 +22 -16
  9. package/lib/components/communication/index.css +50 -10
  10. package/lib/components/communication/index.js +86 -30
  11. package/lib/components/communication/style.js +8 -6
  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 +3 -19
  23. package/lib/components/dynamic/components/obj-status/index.js +7 -8
  24. package/lib/components/dynamic/components/obj-status/utils.js +37 -0
  25. package/lib/components/dynamic/components/percent/index.css +1 -1
  26. package/lib/components/dynamic/components/title/index.css +21 -22
  27. package/lib/components/dynamic/components/title/index.js +20 -8
  28. package/lib/components/dynamic/constant.js +12 -2
  29. package/lib/components/dynamic/dynamic-item/components/feed-operate/index.css +71 -0
  30. package/lib/components/dynamic/dynamic-item/components/feed-operate/index.js +112 -0
  31. package/lib/components/dynamic/dynamic-item/components/header/index.css +8 -7
  32. package/lib/components/dynamic/dynamic-item/components/header/index.js +13 -7
  33. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align-kr.png +0 -0
  34. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align-o.png +0 -0
  35. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align.png +0 -0
  36. package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +44 -27
  37. package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +43 -31
  38. package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +5 -33
  39. package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.js +6 -32
  40. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +58 -18
  41. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +31 -21
  42. package/lib/components/dynamic/dynamic-item/dynamic-chart/index.css +4 -0
  43. package/lib/components/dynamic/dynamic-item/dynamic-chart/index.js +102 -0
  44. package/lib/components/dynamic/dynamic-item/dynamic-chart/utils.js +61 -0
  45. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +56 -44
  46. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +52 -44
  47. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +39 -27
  48. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +25 -29
  49. package/lib/components/dynamic/dynamic-item/dynamic-learning/img/dynamic-share-course.png +0 -0
  50. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/jiantou-right@3x.png +0 -0
  51. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/img/user-photo.png +0 -0
  52. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.css +10 -18
  53. package/lib/components/dynamic/dynamic-item/{dynamic-share-to-dynamic → dynamic-learning}/index.js +15 -30
  54. package/lib/components/dynamic/dynamic-item/dynamic-milestone/constant.js +9 -2
  55. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +31 -14
  56. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +14 -25
  57. package/lib/components/dynamic/dynamic-item/dynamic-okrs-communication/index.css +25 -40
  58. package/lib/components/dynamic/dynamic-item/dynamic-okrs-communication/index.js +10 -29
  59. package/lib/components/dynamic/dynamic-item/dynamic-plan-communication/index.css +25 -40
  60. package/lib/components/dynamic/dynamic-item/dynamic-plan-communication/index.js +13 -30
  61. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +13 -55
  62. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +33 -80
  63. package/lib/components/dynamic/dynamic-item/dynamic-progress/utils.js +72 -0
  64. package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +35 -28
  65. package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +13 -24
  66. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-rela-kr.png +0 -0
  67. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-rela-o.png +0 -0
  68. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-rela-project.png +0 -0
  69. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-rela-task.png +0 -0
  70. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-rela.svg +23 -0
  71. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +56 -31
  72. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +78 -34
  73. package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.css +29 -32
  74. package/lib/components/dynamic/dynamic-item/{dynamic-replay → dynamic-reply}/index.js +12 -18
  75. package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +20 -22
  76. package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +42 -29
  77. package/lib/components/dynamic/dynamic-item/dynamic-reward/img/reward.png +0 -0
  78. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +8 -3
  79. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +23 -66
  80. package/lib/components/dynamic/dynamic-item/dynamic-reward/utils.js +28 -0
  81. package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +8 -19
  82. package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +59 -36
  83. package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +32 -28
  84. package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +11 -25
  85. package/lib/components/dynamic/dynamic-item/index.css +59 -4
  86. package/lib/components/dynamic/dynamic-item/index.js +148 -17
  87. package/lib/components/dynamic/dynamic-like-ranking/item.js +1 -1
  88. package/lib/components/dynamic/dynamic-list/index.js +2 -1
  89. package/lib/components/dynamic/dynamic-topping/item.js +8 -4
  90. package/lib/components/dynamic/dynamic.js +1 -1
  91. package/lib/components/dynamic/img/dynamic-operate.png +0 -0
  92. package/lib/components/dynamic/img/dynamic-point.svg +13 -0
  93. package/lib/components/dynamic/img/dynamic-reward-hover.svg +1 -0
  94. package/lib/components/dynamic/img/dynamic-reward-normal.svg +1 -0
  95. package/lib/components/dynamic/util.js +41 -81
  96. package/lib/components/e-status-dropdown/index.css +3 -0
  97. package/lib/components/e-status-dropdown/index.js +94 -0
  98. package/lib/components/file-list/components/single-file/index.css +14 -12
  99. package/lib/components/file-list/components/single-file/index.js +1 -1
  100. package/lib/components/file-list/index.css +1 -0
  101. package/lib/components/follower-visitor/index.js +6 -4
  102. package/lib/components/grid-layout/okr-progress/index.js +20 -30
  103. package/lib/components/help-card/image/not-try.png +0 -0
  104. package/lib/components/help-card/image/try.png +0 -0
  105. package/lib/components/help-card/index.css +31 -2
  106. package/lib/components/help-card/index.js +54 -17
  107. package/lib/components/invite-people/img/invite-people.svg +62 -0
  108. package/lib/components/invite-people/index.css +1 -1
  109. package/lib/components/mblog/context.js +3 -1
  110. package/lib/components/mblog/index.css +7 -0
  111. package/lib/components/mblog/index.js +45 -9
  112. package/lib/components/mblog/style.js +4 -4
  113. package/lib/components/menus/export-modules/demo-menus/index.js +2 -2
  114. package/lib/components/menus/export-modules/demo-menus/menu-highlight.js +25 -1
  115. package/lib/components/menus/export-modules/demo-menus/menus.js +60 -11
  116. package/lib/components/menus/export-modules/manage-menus/constant.js +1 -1
  117. package/lib/components/menus/export-modules/manage-menus/index.css +3 -0
  118. package/lib/components/menus/images/okr-gongsi.svg +17 -0
  119. package/lib/components/nav-top/components/menu/index.css +24 -0
  120. package/lib/components/nav-top/components/menu/index.js +9 -1
  121. package/lib/components/nav-top/components/user-message/components/reply/index.js +9 -8
  122. package/lib/components/nav-top/components/user-message/components/reply/reply-item.js +15 -5
  123. package/lib/components/nav-top/components/user-message/index.css +4 -3
  124. package/lib/components/nav-top/components/user-message/index.js +33 -6
  125. package/lib/components/nav-top/request.apis.js +8 -2
  126. package/lib/components/nav-top/useGlobalValue.js +14 -0
  127. package/lib/components/okr-detail/components/header/o-score.js +4 -6
  128. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-empty.js +7 -4
  129. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/e-project.js +8 -1
  130. package/lib/components/okr-detail/components/okr-tree/tree-node/e-node/index.css +20 -1
  131. package/lib/components/okr-detail/e-list/index.js +1 -0
  132. package/lib/components/okr-detail/index.js +2 -0
  133. package/lib/components/okr-detail/okr-list/index.js +1 -5
  134. package/lib/components/okr-flow/export-modal/index.js +3 -3
  135. package/lib/components/okr-progress-modal/helper.js +20 -27
  136. package/lib/components/okr-share/common-painter/openDataPainter.js +34 -27
  137. package/lib/components/okrcase-library/okrcases-components/submitOkr-dialog.js +40 -36
  138. package/lib/components/open-data-painter/index.js +5 -1
  139. package/lib/components/progress/circle-progress/index.css +1 -0
  140. package/lib/components/progress/circle-progress/index.js +8 -3
  141. package/lib/components/rich-editor/basic/schema.js +47 -0
  142. package/lib/components/rich-editor/consts/events.js +12 -0
  143. package/lib/components/rich-editor/enums.js +42 -0
  144. package/lib/components/rich-editor/index.js +58 -0
  145. package/lib/components/rich-editor/keymap.js +119 -0
  146. package/lib/components/rich-editor/keymaps/index.js +241 -0
  147. package/lib/components/rich-editor/models/controller.js +18 -0
  148. package/lib/components/rich-editor/models/editor.js +47 -0
  149. package/lib/components/rich-editor/models/plugin.js +20 -0
  150. package/lib/components/rich-editor/models/schema.js +121 -0
  151. package/lib/components/rich-editor/plugins/block/block-quote/commond.js +27 -0
  152. package/lib/components/rich-editor/plugins/block/block-quote/index.js +128 -0
  153. package/lib/components/rich-editor/plugins/block/heading/commonds.js +31 -0
  154. package/lib/components/rich-editor/plugins/block/heading/index.js +190 -0
  155. package/lib/components/rich-editor/plugins/block/index.js +57 -0
  156. package/lib/components/rich-editor/plugins/block/lists/actions/conversions.js +172 -0
  157. package/lib/components/rich-editor/plugins/block/lists/actions/indent-list-items-selected.js +163 -0
  158. package/lib/components/rich-editor/plugins/block/lists/actions/indent-list.js +59 -0
  159. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-forward.js +74 -0
  160. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/index.js +45 -0
  161. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-paragraph.js +104 -0
  162. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-list-item-with-parent-nested-list.js +92 -0
  163. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-nested-list-with-parent-list-item.js +89 -0
  164. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-paragraph-with-list.js +48 -0
  165. package/lib/components/rich-editor/plugins/block/lists/actions/join-list-items-scenarios/join-sibling-list-items.js +61 -0
  166. package/lib/components/rich-editor/plugins/block/lists/actions/merge-lists.js +34 -0
  167. package/lib/components/rich-editor/plugins/block/lists/actions/outdent-list-items-selected.js +289 -0
  168. package/lib/components/rich-editor/plugins/block/lists/actions/wrap-and-join-lists.js +180 -0
  169. package/lib/components/rich-editor/plugins/block/lists/baseCommand.js +328 -0
  170. package/lib/components/rich-editor/plugins/block/lists/commond/indent-list.js +60 -0
  171. package/lib/components/rich-editor/plugins/block/lists/commond/index.js +396 -0
  172. package/lib/components/rich-editor/plugins/block/lists/commond/join-list-item-forward.js +45 -0
  173. package/lib/components/rich-editor/plugins/block/lists/commond/listBackspace.js +302 -0
  174. package/lib/components/rich-editor/plugins/block/lists/commond/outdent-list.js +43 -0
  175. package/lib/components/rich-editor/plugins/block/lists/index.js +224 -0
  176. package/lib/components/rich-editor/plugins/block/lists/messages.js +38 -0
  177. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/input-rule.js +152 -0
  178. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/keymap.js +33 -0
  179. package/lib/components/rich-editor/plugins/block/lists/pm-plugins/main.js +94 -0
  180. package/lib/components/rich-editor/plugins/block/lists/styles.js +15 -0
  181. package/lib/components/rich-editor/plugins/block/lists/transforms.js +347 -0
  182. package/lib/components/rich-editor/plugins/block/lists/utils/analytics.js +48 -0
  183. package/lib/components/rich-editor/plugins/block/lists/utils/find.js +126 -0
  184. package/lib/components/rich-editor/plugins/block/lists/utils/indentation.js +87 -0
  185. package/lib/components/rich-editor/plugins/block/lists/utils/node.js +144 -0
  186. package/lib/components/rich-editor/plugins/block/lists/utils/replace-content.js +31 -0
  187. package/lib/components/rich-editor/plugins/block/lists/utils/selection.js +201 -0
  188. package/lib/components/rich-editor/plugins/block/lists/utils.js +52 -0
  189. package/lib/components/rich-editor/plugins/block/paragraph/index.js +91 -0
  190. package/lib/components/rich-editor/plugins/core/index.js +90 -0
  191. package/lib/components/rich-editor/plugins/core/pm-plugins/focus-handler.js +67 -0
  192. package/lib/components/rich-editor/plugins/core/pm-plugins/keymap.js +29 -0
  193. package/lib/components/rich-editor/plugins/core/pm-plugins/reactNodeView.js +80 -0
  194. package/lib/components/rich-editor/plugins/extension/alignment/commond.js +24 -0
  195. package/lib/components/rich-editor/plugins/extension/alignment/index.js +113 -0
  196. package/lib/components/rich-editor/plugins/extension/alignment/utils.js +19 -0
  197. package/lib/components/rich-editor/plugins/extension/index.js +18 -0
  198. package/lib/components/rich-editor/plugins/extension/placeholder/index.js +126 -0
  199. package/lib/components/rich-editor/plugins/extension/placeholder/styles.js +19 -0
  200. package/lib/components/rich-editor/plugins/index.js +44 -0
  201. package/lib/components/rich-editor/plugins/inline/color/commond.js +128 -0
  202. package/lib/components/rich-editor/plugins/inline/color/consts.js +43 -0
  203. package/lib/components/rich-editor/plugins/inline/color/index.css +61 -0
  204. package/lib/components/rich-editor/plugins/inline/color/index.js +217 -0
  205. package/lib/components/rich-editor/plugins/inline/color/selector.js +252 -0
  206. package/lib/components/rich-editor/plugins/inline/color/util.js +25 -0
  207. package/lib/components/rich-editor/plugins/inline/delete-line/index.js +149 -0
  208. package/lib/components/rich-editor/plugins/inline/em/index.js +93 -0
  209. package/lib/components/rich-editor/plugins/inline/index.js +83 -0
  210. package/lib/components/rich-editor/plugins/inline/link/commands.js +256 -0
  211. package/lib/components/rich-editor/plugins/inline/link/index.js +149 -0
  212. package/lib/components/rich-editor/plugins/inline/link/pm-plugins/fake-cursor-for-toolbar.js +77 -0
  213. package/lib/components/rich-editor/plugins/inline/link/pm-plugins/main.js +293 -0
  214. package/lib/components/rich-editor/plugins/inline/link/ui/index.css +84 -0
  215. package/lib/components/rich-editor/plugins/inline/link/ui/linkEditor.js +150 -0
  216. package/lib/components/rich-editor/plugins/inline/link/ui/linkToolbar.js +101 -0
  217. package/lib/components/rich-editor/plugins/inline/link/ui/toolbarBtn.js +117 -0
  218. package/lib/components/rich-editor/plugins/inline/link/utils.js +33 -0
  219. package/lib/components/rich-editor/plugins/inline/strong/index.js +139 -0
  220. package/lib/components/rich-editor/plugins/inline/under-line/index.js +147 -0
  221. package/lib/components/rich-editor/plugins/util.js +284 -0
  222. package/lib/components/rich-editor/react/reactNodeView.js +383 -0
  223. package/lib/components/rich-editor/react/uiProvider.js +185 -0
  224. package/lib/components/rich-editor/schemas/basic.js +309 -0
  225. package/lib/components/rich-editor/schemas/index.js +19 -0
  226. package/lib/components/rich-editor/schemas/list.js +342 -0
  227. package/lib/components/rich-editor/types/commond.js +5 -0
  228. package/lib/components/rich-editor/types/index.js +18 -0
  229. package/lib/components/rich-editor/ui/Popup/index.js +247 -0
  230. package/lib/components/rich-editor/ui/Popup/utils.js +399 -0
  231. package/lib/components/rich-editor/ui/editor/index.css +178 -0
  232. package/lib/components/rich-editor/ui/editor/index.js +153 -0
  233. package/lib/components/rich-editor/ui/normal-toolbar/index.css +34 -0
  234. package/lib/components/rich-editor/ui/normal-toolbar/index.js +109 -0
  235. package/lib/components/rich-editor/utils/browser.js +35 -0
  236. package/lib/components/rich-editor/utils/commands.js +266 -0
  237. package/lib/components/rich-editor/utils/document.js +211 -0
  238. package/lib/components/rich-editor/utils/event.js +79 -0
  239. package/lib/components/rich-editor/utils/helpers.js +16 -0
  240. package/lib/components/rich-editor/utils/mark.js +168 -0
  241. package/lib/components/rich-editor/utils/slice.js +85 -0
  242. package/lib/components/rich-editor/utils/toolbar.js +228 -0
  243. package/lib/components/search-key-handle/index.js +7 -2
  244. package/lib/components/superset-charts/components/chart/index.js +54 -0
  245. package/lib/components/superset-charts/fetch-assets-and-append/append-assets.js +106 -0
  246. package/lib/components/superset-charts/fetch-assets-and-append/get-assets-with-cache.js +131 -0
  247. package/lib/components/superset-charts/fetch-assets-and-append/index.js +79 -0
  248. package/lib/components/superset-charts/index.js +13 -0
  249. package/lib/components/superset-charts/interface.js +5 -0
  250. package/lib/components/superset-charts/utils/axios.js +94 -0
  251. package/lib/components/toast/index.js +5 -17
  252. package/lib/components/upload/index.js +4 -2
  253. package/lib/components/upload/util.js +2 -0
  254. package/lib/components/user-selector/empty/index.css +6 -6
  255. package/lib/components/user-selector/selected-panel/index.css +3 -3
  256. package/lib/components/video-modal/components/video-box/index.css +240 -0
  257. package/lib/components/video-modal/components/video-box/index.js +334 -0
  258. package/lib/components/video-modal/img/bigFaqi.png +0 -0
  259. package/lib/components/video-modal/img/close.png +0 -0
  260. package/lib/components/video-modal/img/full.svg +21 -0
  261. package/lib/components/video-modal/img/muted.svg +14 -0
  262. package/lib/components/video-modal/img/not-muted.svg +22 -0
  263. package/lib/components/video-modal/img/pause.svg +13 -0
  264. package/lib/components/video-modal/img/play.svg +18 -0
  265. package/lib/components/video-modal/img/small.svg +22 -0
  266. package/lib/components/video-modal/index.css +83 -0
  267. package/lib/components/video-modal/index.js +182 -0
  268. package/lib/components/video-modal/utils.js +25 -0
  269. package/lib/components/weekly-report/common-painter/openDataPainter.js +5 -1
  270. package/lib/hooks/useGlobalState.js +63 -0
  271. package/lib/index.js +40 -0
  272. package/lib/pages/aha2021/img/canceled.svg +13 -0
  273. package/lib/pages/aha2021/img/not-try.png +0 -0
  274. package/lib/pages/aha2021/img/try.png +0 -0
  275. package/lib/pages/aha2021/index.css +52 -0
  276. package/lib/pages/aha2021/index.js +73 -14
  277. package/lib/pages/new-okr-list/header/index.js +2 -1
  278. package/lib/pages/new-okr-list/index.js +3 -3
  279. package/lib/pages/okr-map/export-modules/share-okr-page/header/index.js +0 -5
  280. package/lib/pages/pay/image/success.png +0 -0
  281. package/lib/pages/pay/index.css +79 -0
  282. package/lib/pages/pay/index.js +66 -0
  283. package/lib/utils/bs-global.js +8 -8
  284. package/lib/utils/helpers.js +7 -1
  285. package/lib/utils/open-data.js +2 -1
  286. package/lib/utils/tools.js +11 -2
  287. package/package.json +120 -101
  288. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align.svg +0 -22
  289. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-relative.svg +0 -22
  290. package/lib/components/dynamic/dynamic-item/dynamic-milestone/img/dynamic-milestone.png +0 -0
  291. package/lib/components/dynamic/dynamic-item/dynamic-okrs-communication/img/okrs-icon.png +0 -0
  292. package/lib/components/dynamic/dynamic-item/dynamic-plan-communication/img/plan-icon.png +0 -0
  293. package/lib/components/dynamic/dynamic-item/dynamic-project/img/dynamic-project.png +0 -0
  294. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-relative.svg +0 -22
  295. package/lib/components/dynamic/dynamic-item/dynamic-share-to-dynamic/img/guanlian.png +0 -0
  296. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-icon.png +0 -0
  297. package/lib/components/invite-people/img/invite-people.png +0 -0
@@ -15,6 +15,8 @@ var _MblogContent = _interopRequireDefault(require("./components/MblogContent"))
15
15
 
16
16
  var _MblogAction = _interopRequireDefault(require("./components/MblogAction"));
17
17
 
18
+ var _avatar = _interopRequireDefault(require("../avatar"));
19
+
18
20
  var _bsGlobal = require("../../utils/bs-global");
19
21
 
20
22
  var _index = require("./common/index");
@@ -25,6 +27,8 @@ var _platform = require("../../utils/platform");
25
27
 
26
28
  var _getLocale = require("../../utils/getLocale");
27
29
 
30
+ require("./index.css");
31
+
28
32
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
29
33
 
30
34
  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); }
@@ -51,6 +55,8 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
51
55
 
52
56
  function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
53
57
 
58
+ var prefix = 'titaui-mblog';
59
+
54
60
  var MBlog = /*#__PURE__*/function (_PureComponent) {
55
61
  _inherits(MBlog, _PureComponent);
56
62
 
@@ -163,17 +169,23 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
163
169
  };
164
170
 
165
171
  _this.handlerDealAttachemntData = function (uploadSuccessFilesPath) {
172
+ var _this$refs$textEditor2;
173
+
166
174
  var successFilesPath = uploadSuccessFilesPath.filter(function (item) {
167
175
  return item !== "";
168
176
  });
169
177
  var successFilesPathLen = successFilesPath.length; // @ts-ignore
170
178
 
171
- var textareaInput = _this.refs.textEditor.refs.textareaInput;
179
+ var _this$refs$textEditor = (_this$refs$textEditor2 = _this.refs.textEditor) === null || _this$refs$textEditor2 === void 0 ? void 0 : _this$refs$textEditor2.refs,
180
+ textareaInput = _this$refs$textEditor.textareaInput;
181
+
172
182
  var textareaValue = _this.state.textareaValue; // textareaValue = dealWithLoadedFileTips(textareaValue, successFilesPathLen); // 更新输入框内容
173
183
 
174
184
  localStorage.setItem(_this.state.localStroageKey, textareaValue); // 将输入框内容进行本地缓存
175
185
 
176
- textareaInput.focus();
186
+ if (textareaInput) {
187
+ textareaInput.focus();
188
+ }
177
189
 
178
190
  _this.setState({
179
191
  textareaValue: textareaValue,
@@ -186,9 +198,12 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
186
198
  _this.focus = function () {
187
199
  // @ts-ignore
188
200
  var textareaInput = _this.refs.textEditor.refs.textareaInput;
189
- setTimeout(function () {
190
- textareaInput.focus();
191
- }, 300);
201
+
202
+ if (textareaInput) {
203
+ setTimeout(function () {
204
+ textareaInput.focus();
205
+ }, 300);
206
+ }
192
207
  };
193
208
 
194
209
  _this.allowSubmit = function (content) {
@@ -235,6 +250,11 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
235
250
  // 取消
236
251
  _this.props.onMblogSubmit(submitType);
237
252
  }
253
+
254
+ _this.setState({
255
+ textareaValue: '',
256
+ uploadSuccessFilesPath: []
257
+ });
238
258
  };
239
259
 
240
260
  _this._dropHandler = function (event) {
@@ -398,7 +418,8 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
398
418
  _this$props3$submitTe = _this$props3.submitText,
399
419
  submitText = _this$props3$submitTe === void 0 ? (0, _getLocale.getLocale)("Mod_Publish") : _this$props3$submitTe,
400
420
  setTextareaRef = _this$props3.setTextareaRef,
401
- disableRangeSelect = _this$props3.disableRangeSelect;
421
+ disableRangeSelect = _this$props3.disableRangeSelect,
422
+ showUser = _this$props3.showUser;
402
423
  var _this$state2 = this.state,
403
424
  localStroageKey = _this$state2.localStroageKey,
404
425
  visibility = _this$state2.visibility,
@@ -411,7 +432,21 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
411
432
  isAtAll = _this$state2.isAtAll;
412
433
  var fSize = (0, _bsGlobal.getUploadMaxSize)();
413
434
  var fTip = attachmentTipText || (0, _getLocale.getLocale)("OKR_MyO_KRP_Draganddropu").replace("50MB", "".concat(fSize, "MB"));
414
- return /*#__PURE__*/_react["default"].createElement(_style.MBlogBox, {
435
+ var user = (0, _bsGlobal.getUserInfo)();
436
+ return /*#__PURE__*/_react["default"].createElement("div", {
437
+ className: prefix
438
+ }, showUser && /*#__PURE__*/_react["default"].createElement("div", {
439
+ className: "".concat(prefix, "__avatar")
440
+ }, /*#__PURE__*/_react["default"].createElement(_avatar["default"], {
441
+ size: {
442
+ width: 28,
443
+ textNum: 1,
444
+ fontSize: 14
445
+ },
446
+ name: user.Name,
447
+ color: user.UserAvatar.Color,
448
+ src: user.UserAvatar.Medium
449
+ })), /*#__PURE__*/_react["default"].createElement(_style.MBlogBox, {
415
450
  className: className,
416
451
  ref: "mblogbox",
417
452
  onDrop: this._dropHandler,
@@ -490,7 +525,7 @@ var MBlog = /*#__PURE__*/function (_PureComponent) {
490
525
  id: this.previewid
491
526
  }), !(0, _platform.isPlatform)("wx") && isShowDragMask && /*#__PURE__*/_react["default"].createElement(_style.DragEffect, {
492
527
  className: "tu-icon-inbox-upload"
493
- }));
528
+ })));
494
529
  }
495
530
  }]);
496
531
 
@@ -531,5 +566,6 @@ MBlog.defaultProps = {
531
566
  // 1公开,2私密 3部门
532
567
  isShowRangeDropDown: true,
533
568
  isShowBtnCancel: true,
534
- submitStatus: 0
569
+ submitStatus: 0,
570
+ showUser: false
535
571
  };
@@ -13,12 +13,12 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
13
13
 
14
14
  function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
15
15
 
16
- var MBlogBox = _styledComponents["default"].div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n position: relative;\n\n .uploadFile__preview__list {\n padding-bottom: 10px;\n background: #ffffff;\n display: flex;\n flex-wrap: wrap;\n max-height: 300px;\n overflow-y: auto;\n\n .preview__content {\n margin-top: 10px;\n margin-right: 10px;\n border-radius: 8px;\n }\n }\n"]))); // MblogContent
16
+ var MBlogBox = _styledComponents["default"].div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n position: relative;\n flex: 1;\n\n .uploadFile__preview__list {\n padding-bottom: 10px;\n background: #ffffff;\n display: flex;\n flex-wrap: wrap;\n max-height: 300px;\n overflow-y: auto;\n\n .preview__content {\n margin-top: 10px;\n margin-right: 10px;\n border-radius: 8px;\n }\n }\n"]))); // MblogContent
17
17
 
18
18
 
19
19
  exports.MBlogBox = MBlogBox;
20
20
 
21
- var DivMblogContent = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n padding: 8px 10px 6px;\n border: 1px solid #DFE3EA;\n border-radius: 8px;\n background-color: #fff;\n position: relative;\n transition: all .2s ease-in-out;\n height: 120px;\n box-sizing: border-box;\n\n &.input_default-active {\n box-shadow: inset 0px 0px 4px 0px rgba(40, 121, 255, 0.3);\n border-color: #2879ff;\n }\n"])));
21
+ var DivMblogContent = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n padding: 8px 10px 6px;\n border: 1px solid #DFE3EA;\n border-radius: 12px;\n background-color: #fff;\n position: relative;\n transition: all .2s ease-in-out;\n height: 120px;\n box-sizing: border-box;\n\n &.input_default-active {\n box-shadow: inset 0px 0px 4px 0px rgba(40, 121, 255, 0.3);\n border-color: #2879ff;\n }\n"])));
22
22
 
23
23
  exports.DivMblogContent = DivMblogContent;
24
24
 
@@ -47,7 +47,7 @@ var Tips = _styledComponents["default"].div(_templateObject7 || (_templateObject
47
47
 
48
48
  exports.Tips = Tips;
49
49
 
50
- var MblogActionWrapper = _styledComponents["default"].div(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n height: 30px;\n padding: 28px 0 2px 0;\n font-size: 13px;\n line-height: 20px;\n color: #565E66;\n background-color: #ffffff;\n display: flex;\n align-items: center;\n justify-content: space-between;\n"]))); // 左侧按钮
50
+ var MblogActionWrapper = _styledComponents["default"].div(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n height: 30px;\n padding: 16px 0 2px 0;\n font-size: 13px;\n line-height: 20px;\n color: #565E66;\n background-color: #ffffff;\n display: flex;\n align-items: center;\n justify-content: space-between;\n"]))); // 左侧按钮
51
51
 
52
52
 
53
53
  exports.MblogActionWrapper = MblogActionWrapper;
@@ -66,7 +66,7 @@ var IconSpan = _styledComponents["default"].span(_templateObject11 || (_template
66
66
 
67
67
  exports.IconSpan = IconSpan;
68
68
 
69
- var RightBtnGroupWrapper = _styledComponents["default"].div(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n height: 100%;\n display: flex;\n align-items: center;\n\n button {\n min-width: 90px;\n height: 32px;\n box-sizing: border-box;\n border-radius: 18px;\n border: none;\n }\n"])));
69
+ var RightBtnGroupWrapper = _styledComponents["default"].div(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n height: 100%;\n display: flex;\n align-items: center;\n\n button {\n min-width: 80px;\n height: 32px;\n box-sizing: border-box;\n border-radius: 18px;\n border: none;\n }\n"])));
70
70
 
71
71
  exports.RightBtnGroupWrapper = RightBtnGroupWrapper;
72
72
 
@@ -64,7 +64,7 @@ var DemoMenus = function DemoMenus(props) {
64
64
  setExpandedKeys = _useState4[1];
65
65
 
66
66
  var _useState5 = (0, _react.useState)(function () {
67
- okrMenusData.current = new _menus["default"]();
67
+ okrMenusData.current = new _menus["default"](isManager);
68
68
  return okrMenusData.current.getMenus();
69
69
  }),
70
70
  _useState6 = _slicedToArray(_useState5, 2),
@@ -72,7 +72,7 @@ var DemoMenus = function DemoMenus(props) {
72
72
  setMenus = _useState6[1];
73
73
 
74
74
  (0, _react.useEffect)(function () {
75
- okrMenusData.current = new _menus["default"](isManager === 1);
75
+ okrMenusData.current = new _menus["default"](isManager);
76
76
  setMenus(okrMenusData.current.getMenus());
77
77
  setExpandedKeys(["demofree"]);
78
78
  }, [isManager]);
@@ -25,7 +25,7 @@ var _default = /*#__PURE__*/function () {
25
25
  _createClass(_default, [{
26
26
  key: "highlight",
27
27
  value: function highlight(cb) {
28
- if (this.isUnAssigned()) cb(_menus.PAGE_UNASSIGNED_DEMOFREE);else if (this.isAssigned()) cb(_menus.PAGE_ASSIGNED_DEMOFREE);else if (this.isReserved()) cb(_menus.PAGE_RESERVED_DEMOFREE);else if (this.isDone()) cb(_menus.PAGE_DONE_DEMOFREE);else if (this.isIgnore()) cb(_menus.PAGE_IGNORED_DEMOFREE);else if (this.isChart()) cb(_menus.PAGE_CHARTS_DEMOFREE);
28
+ if (this.isUnAssigned()) cb(_menus.PAGE_UNASSIGNED_DEMOFREE);else if (this.isAssigned()) cb(_menus.PAGE_ASSIGNED_DEMOFREE);else if (this.isReserved()) cb(_menus.PAGE_RESERVED_DEMOFREE);else if (this.isDone()) cb(_menus.PAGE_DONE_DEMOFREE);else if (this.isIgnore()) cb(_menus.PAGE_IGNORED_DEMOFREE);else if (this.isChart()) cb(_menus.PAGE_CHARTS_DEMOFREE);else if (this.isRechargeList()) cb(_menus.PAGE_RECHARGE_LIST);else if (this.isRechargeStatistics()) cb(_menus.PAGE_RECHARGE_STATISTICS);else if (this.isRechargeStatus()) cb(_menus.PAGE_RECHARGE_STATUS);else if (this.isDueDateOrder()) cb(_menus.PAGE_DUEDATE_ORDER);
29
29
  }
30
30
  }, {
31
31
  key: "isChart",
@@ -33,6 +33,30 @@ var _default = /*#__PURE__*/function () {
33
33
  var pathname = this.history.location.pathname;
34
34
  return pathname.match(/demofree\/charts/);
35
35
  }
36
+ }, {
37
+ key: "isRechargeStatus",
38
+ value: function isRechargeStatus() {
39
+ var pathname = this.history.location.pathname;
40
+ return pathname.match(/demofree\/recharge\/status/);
41
+ }
42
+ }, {
43
+ key: "isDueDateOrder",
44
+ value: function isDueDateOrder() {
45
+ var pathname = this.history.location.pathname;
46
+ return pathname.match(/demofree\/recharge\/order/);
47
+ }
48
+ }, {
49
+ key: "isRechargeList",
50
+ value: function isRechargeList() {
51
+ var pathname = this.history.location.pathname;
52
+ return pathname.match(/demofree\/recharge\/list/);
53
+ }
54
+ }, {
55
+ key: "isRechargeStatistics",
56
+ value: function isRechargeStatistics() {
57
+ var pathname = this.history.location.pathname;
58
+ return pathname.match(/demofree\/recharge\/statistics/);
59
+ }
36
60
  }, {
37
61
  key: "isUnAssigned",
38
62
  value: function isUnAssigned() {
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.defaultRefObject = exports["default"] = exports.PAGE_UNASSIGNED_DEMOFREE = exports.PAGE_RESERVED_DEMOFREE = exports.PAGE_IGNORED_DEMOFREE = exports.PAGE_DONE_DEMOFREE = exports.PAGE_CHARTS_DEMOFREE = exports.PAGE_ASSIGNED_DEMOFREE = void 0;
6
+ exports.defaultRefObject = exports["default"] = exports.PAGE_UNASSIGNED_DEMOFREE = exports.PAGE_RESERVED_DEMOFREE = exports.PAGE_RECHARGE_STATUS = exports.PAGE_RECHARGE_STATISTICS = exports.PAGE_RECHARGE_LIST = exports.PAGE_IGNORED_DEMOFREE = exports.PAGE_DUEDATE_ORDER = exports.PAGE_DONE_DEMOFREE = exports.PAGE_CHARTS_DEMOFREE = exports.PAGE_ASSIGNED_DEMOFREE = void 0;
7
7
 
8
8
  var _index = require("../../components/menu-tree/tree-node/index");
9
9
 
@@ -13,6 +13,16 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
13
13
 
14
14
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
15
15
 
16
+ var EManagerType;
17
+
18
+ (function (EManagerType) {
19
+ EManagerType[EManagerType["Sales"] = 0] = "Sales";
20
+ EManagerType[EManagerType["Manager"] = 1] = "Manager";
21
+ EManagerType[EManagerType["Supervisor"] = 2] = "Supervisor";
22
+ EManagerType[EManagerType["ReCharge"] = 3] = "ReCharge";
23
+ EManagerType[EManagerType["DemoFreeReadOnly"] = 4] = "DemoFreeReadOnly";
24
+ })(EManagerType || (EManagerType = {}));
25
+
16
26
  var defaultRefObject = {
17
27
  menus: [],
18
28
  getMenus: function getMenus() {}
@@ -30,11 +40,17 @@ var PAGE_IGNORED_DEMOFREE = "ignore";
30
40
  exports.PAGE_IGNORED_DEMOFREE = PAGE_IGNORED_DEMOFREE;
31
41
  var PAGE_CHARTS_DEMOFREE = "charts";
32
42
  exports.PAGE_CHARTS_DEMOFREE = PAGE_CHARTS_DEMOFREE;
43
+ var PAGE_RECHARGE_LIST = "rechargeList";
44
+ exports.PAGE_RECHARGE_LIST = PAGE_RECHARGE_LIST;
45
+ var PAGE_DUEDATE_ORDER = "dueDateOrder";
46
+ exports.PAGE_DUEDATE_ORDER = PAGE_DUEDATE_ORDER;
47
+ var PAGE_RECHARGE_STATISTICS = "rechargeStatistics";
48
+ exports.PAGE_RECHARGE_STATISTICS = PAGE_RECHARGE_STATISTICS;
49
+ var PAGE_RECHARGE_STATUS = "rechargeStatus";
50
+ exports.PAGE_RECHARGE_STATUS = PAGE_RECHARGE_STATUS;
33
51
 
34
52
  var DemoMenuData = /*#__PURE__*/function () {
35
- function DemoMenuData() {
36
- var isManager = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
37
-
53
+ function DemoMenuData(isManager) {
38
54
  _classCallCheck(this, DemoMenuData);
39
55
 
40
56
  this.isManager = isManager;
@@ -43,44 +59,77 @@ var DemoMenuData = /*#__PURE__*/function () {
43
59
  label: "任务状态",
44
60
  key: "demofree",
45
61
  href: this.isManager ? "#/demofree/list?selected=unassigned" : "#/demofree/list?selected=assigned",
46
- isShow: true,
62
+ isShow: this.isManager !== EManagerType.ReCharge,
47
63
  children: [{
48
64
  icon: "",
49
65
  label: "未分配",
50
66
  key: "unassigned",
51
67
  href: "#/demofree/list?selected=unassigned",
52
- isShow: this.isManager
68
+ isShow: this.isManager === EManagerType.Manager
53
69
  }, {
54
70
  icon: "",
55
71
  label: "已分配",
56
72
  key: "assigned",
57
73
  href: "#/demofree/list?selected=assigned",
58
- isShow: true
74
+ isShow: this.isManager !== EManagerType.ReCharge
59
75
  }, {
60
76
  icon: "",
61
77
  label: "已预约",
62
78
  key: "reserved",
63
79
  href: "#/demofree/list?selected=reserved",
64
- isShow: true
80
+ isShow: this.isManager !== EManagerType.ReCharge
65
81
  }, {
66
82
  icon: "",
67
83
  label: "已完成",
68
84
  key: "done",
69
85
  href: "#/demofree/list?selected=done",
70
- isShow: true
86
+ isShow: this.isManager !== EManagerType.ReCharge
71
87
  }, {
72
88
  icon: "",
73
89
  label: "已忽略",
74
90
  key: "ignore",
75
91
  href: "#/demofree/list?selected=ignore",
76
- isShow: this.isManager
92
+ isShow: this.isManager === EManagerType.Manager
77
93
  }]
94
+ }, {
95
+ icon: "KH-help",
96
+ label: "客户续费",
97
+ key: "recharge",
98
+ href: "#/demofree/recharge",
99
+ isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager,
100
+ children: [{
101
+ icon: "",
102
+ label: "客户",
103
+ key: PAGE_RECHARGE_LIST,
104
+ href: "#/demofree/recharge/list",
105
+ isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager
106
+ }, {
107
+ icon: "",
108
+ label: "到期订单",
109
+ key: PAGE_DUEDATE_ORDER,
110
+ href: "#/demofree/recharge/order",
111
+ isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager
112
+ } // {
113
+ // icon: "",
114
+ // label: "续费状态",
115
+ // key: PAGE_RECHARGE_STATUS,
116
+ // href: "#/demofree/recharge/status",
117
+ // isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager,
118
+ // },
119
+ // {
120
+ // icon: "",
121
+ // label: "数据统计",
122
+ // key: PAGE_RECHARGE_STATISTICS,
123
+ // href: "#/demofree/recharge/statistics",
124
+ // isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager,
125
+ // },
126
+ ]
78
127
  }, {
79
128
  icon: "KH-help",
80
129
  label: "预约演示报表",
81
130
  key: "charts",
82
131
  href: "#/demofree/charts",
83
- isShow: this.isManager,
132
+ isShow: this.isManager === EManagerType.Manager,
84
133
  children: [],
85
134
  type: _index.MENU_ITEM_NOE
86
135
  }];
@@ -8,7 +8,7 @@ exports.menus = void 0;
8
8
  var _i18n = require("../../i18n");
9
9
 
10
10
  var menus = [{
11
- icon: "okr",
11
+ icon: "enterprise",
12
12
  label: _i18n.locale.menu_regulation_enterprise,
13
13
  key: "enterprise",
14
14
  href: "",
@@ -0,0 +1,3 @@
1
+ .titaui-menus-tree__parent-menu-node-icon.enterprise {
2
+ background-image: url("../../images/okr-gongsi.svg");
3
+ }
@@ -0,0 +1,17 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <svg width="18px" height="18px" viewBox="0 0 18 18" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
+ <title>OKR-gongsi</title>
4
+ <g id="新" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
5
+ <g id="OKR-gongsi">
6
+ <rect id="矩形" fill-opacity="0" fill="#FFFFFF" x="0" y="0" width="18" height="18"></rect>
7
+ <g id="编组" transform="translate(3.000000, 1.875000)" fill="#141C28">
8
+ <path d="M4.10139571,0.207109154 C5.30548811,-0.332079068 6.71387503,0.21781894 7.24711594,1.43534073 C7.38177811,1.74280798 7.45134383,2.07535848 7.45134383,2.41162737 L7.45134383,2.41162737 L7.45134383,4.57179909 L8.31469627,5.11190194 C8.50972555,5.210975 8.64355884,5.41510258 8.64355884,5.65083722 C8.64355884,5.98373015 8.37667242,6.25359319 8.04745134,6.25359319 C7.93433435,6.25359319 7.82857621,6.22173481 7.73847398,6.16640762 L7.737,6.169 L6.54112363,5.41956638 C6.39501401,5.32796807 6.29659069,5.17813983 6.26784152,5.01002569 L6.25912882,4.90728246 L6.25912882,2.41162737 C6.25912882,2.24349293 6.22434596,2.07721768 6.15701487,1.92348405 L6.15701487,1.92348405 L6.14681255,1.9008124 C5.87280554,1.30793451 5.17867538,1.04314408 4.58415476,1.30936826 L4.58415476,1.30936826 L1.90167098,2.5105748 C1.47035103,2.70371832 1.19221501,3.13584938 1.19221501,3.61283391 L1.19221501,3.61283391 L1.19221501,11.8389761 C1.19221501,12.504762 1.72598786,13.0445078 2.38443003,13.0445078 L2.38443003,13.0445078 L7.995,13.044 L8.04745134,14.2401098 L9.74192999,14.2409586 C9.68587029,14.2458533 9.62924586,14.2488023 9.57212243,14.249738 L9.57212243,14.249738 L9.5377201,14.25 L2.38443003,14.25 C1.06754569,14.25 0,13.1705478 0,11.8389761 L0,11.8389761 L0,3.61283391 C0,2.65886485 0.556272039,1.79460272 1.41891194,1.4083157 L1.41891194,1.4083157 Z" id="形状结合" fill-rule="nonzero"></path>
9
+ <rect id="矩形" x="3.15" y="3.26067444" width="1.2" height="4.8" rx="0.6"></rect>
10
+ </g>
11
+ <g id="编组" transform="translate(7.275000, 8.775000)">
12
+ <path d="M2.65951382,0.134116403 L1.38451382,0.868914715 C0.643634524,1.29589264 0.1875,2.08321551 0.1875,2.93505159 L0.1875,4.41494841 C0.1875,5.26678449 0.643634524,6.05410736 1.38451382,6.48108529 L2.65951382,7.2158836 C3.40359267,7.64470547 4.32140733,7.64470547 5.06548618,7.2158836 L6.34048618,6.48108529 C7.08136548,6.05410736 7.5375,5.26678449 7.5375,4.41494841 L7.5375,2.93505159 C7.5375,2.08321551 7.08136548,1.29589264 6.34048618,0.868914715 L5.06548618,0.134116403 C4.32140733,-0.294705468 3.40359267,-0.294705468 2.65951382,0.134116403 Z M4.46399309,1.16718484 L5.73899309,1.90198315 C6.10943274,2.11547211 6.3375,2.50913355 6.3375,2.93505159 L6.3375,4.41494841 C6.3375,4.84086645 6.10943274,5.23452789 5.73899309,5.44801685 L4.46399309,6.18281516 C4.09195366,6.3972261 3.63304634,6.3972261 3.26100691,6.18281516 L1.98600691,5.44801685 C1.61556726,5.23452789 1.3875,4.84086645 1.3875,4.41494841 L1.3875,2.93505159 C1.3875,2.50913355 1.61556726,2.11547211 1.98600691,1.90198315 L3.26100691,1.16718484 C3.63304634,0.952773904 4.09195366,0.952773904 4.46399309,1.16718484 Z" id="多边形" fill="#141C28" fill-rule="nonzero" transform="translate(3.862500, 3.675000) rotate(-90.000000) translate(-3.862500, -3.675000) "></path>
13
+ <circle id="椭圆形" stroke="#2879FF" stroke-width="1.05" cx="3.8625" cy="3.675" r="1.0875"></circle>
14
+ </g>
15
+ </g>
16
+ </g>
17
+ </svg>
@@ -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
  }));