@titaui/pc 1.5.82 → 1.5.83

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 (319) hide show
  1. package/lib/components/avatar/icon-avatar/index.css +15 -0
  2. package/lib/components/avatar/icon-avatar/index.js +50 -0
  3. package/lib/components/avatar/index.js +9 -1
  4. package/lib/components/avatar/num-avatar/index.css +12 -0
  5. package/lib/components/avatar/num-avatar/index.js +34 -0
  6. package/lib/components/button/admin-button/default.js +35 -0
  7. package/lib/components/button/admin-button/drop-down-arrow.js +93 -0
  8. package/lib/components/button/admin-button/index.css +86 -0
  9. package/lib/components/button/admin-button/index.js +40 -0
  10. package/lib/components/button/admin-button/primary.js +33 -0
  11. package/lib/components/button/admin-button/secondary.js +35 -0
  12. package/lib/components/button/default-button/index.css +49 -0
  13. package/lib/components/button/default-button/index.js +51 -0
  14. package/lib/components/button/export-button/index.css +51 -0
  15. package/lib/components/button/export-button/index.js +81 -0
  16. package/lib/components/button/images/daoru.svg +18 -0
  17. package/lib/components/button/index.js +23 -0
  18. package/lib/components/button/interface.js +5 -0
  19. package/lib/components/change-okr/Filter.js +133 -65
  20. package/lib/components/change-okr/Item.js +6 -0
  21. package/lib/components/change-okr/filterTab.js +2 -0
  22. package/lib/components/change-okr/index.js +2 -2
  23. package/lib/components/checkbox/index.js +4 -3
  24. package/lib/components/communication/CommunicationRecord.js +116 -161
  25. package/lib/components/communication/ConvertUserName.js +1 -1
  26. package/lib/components/communication/index.css +63 -0
  27. package/lib/components/communication/index.js +53 -28
  28. package/lib/components/communication/style.js +21 -25
  29. package/lib/components/create-okr/animation/check-animation.js +2746 -0
  30. package/lib/components/create-okr/constant.js +27 -0
  31. package/lib/components/create-okr/createCycle.js +193 -0
  32. package/lib/components/create-okr/createSuccessCmp.js +233 -0
  33. package/lib/components/create-okr/createSuccessCmpWrapper.js +20 -0
  34. package/lib/components/create-okr/fields/date-cycle.js +98 -0
  35. package/lib/components/create-okr/fields/index.css +346 -0
  36. package/lib/components/create-okr/fields/index.js +17 -0
  37. package/lib/components/create-okr/fields/input-with-err-popup.js +57 -0
  38. package/lib/components/create-okr/fields/o-new-name.js +197 -0
  39. package/lib/components/create-okr/fields/okr-case.js +98 -0
  40. package/lib/components/create-okr/fields/okr-classify.js +51 -0
  41. package/lib/components/create-okr/fields/okr-create-suggest.js +147 -0
  42. package/lib/components/create-okr/fields/okr-new-user-selector.js +106 -0
  43. package/lib/components/create-okr/fields/okr-parent.js +157 -0
  44. package/lib/components/create-okr/fields/okr-type-detail.js +196 -0
  45. package/lib/components/create-okr/fields/okr-type.js +131 -0
  46. package/lib/components/create-okr/fields/okr-visibility-detail.js +224 -0
  47. package/lib/components/create-okr/fields/okr-visibility.js +169 -0
  48. package/lib/components/create-okr/img/check-normal.svg +29 -0
  49. package/lib/components/create-okr/img/check-right.svg +16 -0
  50. package/lib/components/create-okr/img/check-wrong.svg +29 -0
  51. package/lib/components/create-okr/img/create-success-head.png +0 -0
  52. package/lib/components/create-okr/img/create-success-left-quotation.svg +14 -0
  53. package/lib/components/create-okr/img/create-success-message.svg +1 -0
  54. package/lib/components/create-okr/img/create-success-right-quotation.svg +14 -0
  55. package/lib/components/create-okr/img/create-success-shadow.svg +23 -0
  56. package/lib/components/create-okr/img/example.svg +11 -0
  57. package/lib/components/create-okr/img/hand.svg +12 -0
  58. package/lib/components/create-okr/img/kr-add.svg +12 -0
  59. package/lib/components/create-okr/img/left-quotation.svg +12 -0
  60. package/lib/components/create-okr/img/light.svg +1 -0
  61. package/lib/components/create-okr/img/pack-up.js +28 -0
  62. package/lib/components/create-okr/img/qr-code.png +0 -0
  63. package/lib/components/create-okr/img/right-quotation.svg +12 -0
  64. package/lib/components/create-okr/img/shower.png +0 -0
  65. package/lib/components/create-okr/img/target.svg +19 -0
  66. package/lib/components/create-okr/img/teach-okr.svg +17 -0
  67. package/lib/components/create-okr/img/wave.png +0 -0
  68. package/lib/components/create-okr/img/weight.svg +12 -0
  69. package/lib/components/create-okr/index.css +446 -0
  70. package/lib/components/create-okr/index.js +911 -0
  71. package/lib/components/create-okr/interface.js +5 -0
  72. package/lib/components/create-okr/kr-items/index.css +180 -0
  73. package/lib/components/create-okr/kr-items/kr-item-weight.js +194 -0
  74. package/lib/components/create-okr/kr-items/krDatas.js +299 -0
  75. package/lib/components/create-okr/kr-items/krItem.js +167 -0
  76. package/lib/components/create-okr/objectType.js +273 -0
  77. package/lib/components/create-okr/request-api.js +220 -0
  78. package/lib/components/create-okr/style.js +100 -0
  79. package/lib/components/create-okr/utils/getCreateOkrSurpassPercent.js +124 -0
  80. package/lib/components/create-okr/utils/helper.js +99 -0
  81. package/lib/components/create-okr/utils/index.js +23 -0
  82. package/lib/components/dropdown-layer/icon-item.js +5 -3
  83. package/lib/components/dropdown-layer/index.css +16 -0
  84. package/lib/components/dropdown-layer/index.js +21 -14
  85. package/lib/components/dynamic/components/condition-render/index.js +20 -0
  86. package/lib/components/dynamic/components/dangerous-html/index.js +22 -0
  87. package/lib/components/dynamic/components/dynamic-search-input/index.css +78 -0
  88. package/lib/components/dynamic/components/dynamic-search-input/index.js +192 -0
  89. package/lib/components/dynamic/components/obj-status/index.css +22 -0
  90. package/lib/components/dynamic/components/obj-status/index.js +38 -0
  91. package/lib/components/dynamic/components/percent/index.css +21 -0
  92. package/lib/components/dynamic/components/percent/index.js +38 -0
  93. package/lib/components/dynamic/components/title/index.css +35 -0
  94. package/lib/components/dynamic/components/title/index.js +59 -0
  95. package/lib/components/dynamic/constant.js +97 -0
  96. package/lib/components/dynamic/context/index.js +13 -0
  97. package/lib/components/dynamic/dynamic-item/components/header/index.css +101 -0
  98. package/lib/components/dynamic/dynamic-item/components/header/index.js +299 -0
  99. package/lib/components/dynamic/dynamic-item/components/icon/index.css +10 -0
  100. package/lib/components/dynamic/dynamic-item/components/icon/index.js +35 -0
  101. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align.svg +22 -0
  102. package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-relative.svg +22 -0
  103. package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +95 -0
  104. package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +173 -0
  105. package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +59 -0
  106. package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.js +107 -0
  107. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +48 -0
  108. package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +89 -0
  109. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +96 -0
  110. package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +171 -0
  111. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +67 -0
  112. package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +110 -0
  113. package/lib/components/dynamic/dynamic-item/dynamic-milestone/constant.js +16 -0
  114. package/lib/components/dynamic/dynamic-item/dynamic-milestone/img/milestone.png +0 -0
  115. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +111 -0
  116. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +158 -0
  117. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +95 -0
  118. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +215 -0
  119. package/lib/components/dynamic/dynamic-item/dynamic-project/constant.js +16 -0
  120. package/lib/components/dynamic/dynamic-item/dynamic-project/img/project.png +0 -0
  121. package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +91 -0
  122. package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +125 -0
  123. package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-relative.svg +22 -0
  124. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +95 -0
  125. package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +192 -0
  126. package/lib/components/dynamic/dynamic-item/dynamic-replay/index.css +138 -0
  127. package/lib/components/dynamic/dynamic-item/dynamic-replay/index.js +183 -0
  128. package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +153 -0
  129. package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +138 -0
  130. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +97 -0
  131. package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +207 -0
  132. package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +59 -0
  133. package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +107 -0
  134. package/lib/components/dynamic/dynamic-item/dynamic-task/constant.js +50 -0
  135. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-cancel.png +0 -0
  136. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-delay.png +0 -0
  137. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-done.png +0 -0
  138. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-pause.png +0 -0
  139. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-progress.png +0 -0
  140. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unaccept.png +0 -0
  141. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unstart.png +0 -0
  142. package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +111 -0
  143. package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +164 -0
  144. package/lib/components/dynamic/dynamic-item/index.css +128 -0
  145. package/lib/components/dynamic/dynamic-item/index.js +352 -0
  146. package/lib/components/dynamic/dynamic-like-ranking/image/like-ranking.svg +23 -0
  147. package/lib/components/dynamic/dynamic-like-ranking/image/ranking-1.png +0 -0
  148. package/lib/components/dynamic/dynamic-like-ranking/image/ranking-2.png +0 -0
  149. package/lib/components/dynamic/dynamic-like-ranking/image/ranking-3.png +0 -0
  150. package/lib/components/dynamic/dynamic-like-ranking/index.css +126 -0
  151. package/lib/components/dynamic/dynamic-like-ranking/index.js +157 -0
  152. package/lib/components/dynamic/dynamic-like-ranking/item.js +107 -0
  153. package/lib/components/dynamic/dynamic-like-ranking/mock.js +84 -0
  154. package/lib/components/dynamic/dynamic-liking/image/like-dynamic.svg +30 -0
  155. package/lib/components/dynamic/dynamic-liking/index.css +81 -0
  156. package/lib/components/dynamic/dynamic-liking/index.js +76 -0
  157. package/lib/components/dynamic/dynamic-liking/item.js +91 -0
  158. package/lib/components/dynamic/dynamic-liking/mock.js +83 -0
  159. package/lib/components/dynamic/dynamic-list/index.css +36 -0
  160. package/lib/components/dynamic/dynamic-list/index.js +61 -0
  161. package/lib/components/dynamic/dynamic-topping/image/quotationMark.svg +16 -0
  162. package/lib/components/dynamic/dynamic-topping/image/topIcon.svg +30 -0
  163. package/lib/components/dynamic/dynamic-topping/index.css +148 -0
  164. package/lib/components/dynamic/dynamic-topping/index.js +80 -0
  165. package/lib/components/dynamic/dynamic-topping/interface.js +5 -0
  166. package/lib/components/dynamic/dynamic-topping/item.js +140 -0
  167. package/lib/components/dynamic/dynamic-topping/request-api.js +36 -0
  168. package/lib/components/dynamic/dynamic.css +204 -0
  169. package/lib/components/dynamic/dynamic.js +391 -0
  170. package/lib/components/dynamic/export-module/index.js +33 -0
  171. package/lib/components/dynamic/img/dynamic-P1.svg +15 -0
  172. package/lib/components/dynamic/img/dynamic-P2.svg +15 -0
  173. package/lib/components/dynamic/img/dynamic-P3.svg +15 -0
  174. package/lib/components/dynamic/img/dynamic-P4.svg +15 -0
  175. package/lib/components/dynamic/img/dynamic-P5.svg +15 -0
  176. package/lib/components/dynamic/img/dynamic-delay.svg +17 -0
  177. package/lib/components/dynamic/img/dynamic-desire.svg +61 -0
  178. package/lib/components/dynamic/img/dynamic-empty.png +0 -0
  179. package/lib/components/dynamic/img/dynamic-end.svg +17 -0
  180. package/lib/components/dynamic/img/dynamic-left-quoto.svg +13 -0
  181. package/lib/components/dynamic/img/dynamic-loading.gif +0 -0
  182. package/lib/components/dynamic/img/dynamic-normal.svg +17 -0
  183. package/lib/components/dynamic/img/dynamic-promise.svg +61 -0
  184. package/lib/components/dynamic/img/dynamic-reword.svg +24 -0
  185. package/lib/components/dynamic/img/dynamic-right-quoto.svg +13 -0
  186. package/lib/components/dynamic/img/dynamic-risk.svg +17 -0
  187. package/lib/components/dynamic/img/dynamic-submit-delay.svg +16 -0
  188. package/lib/components/dynamic/img/dynamic-submit-normal.svg +18 -0
  189. package/lib/components/dynamic/img/dynamic-top.svg +14 -0
  190. package/lib/components/dynamic/index.js +27 -0
  191. package/lib/components/dynamic/interface.js +5 -0
  192. package/lib/components/dynamic/quick-operation/components/create-announcement/index.css +25 -0
  193. package/lib/components/dynamic/quick-operation/components/create-announcement/index.js +37 -0
  194. package/lib/components/dynamic/quick-operation/components/create-okr/index.css +25 -0
  195. package/lib/components/dynamic/quick-operation/components/create-okr/index.js +37 -0
  196. package/lib/components/dynamic/quick-operation/components/create-share/index.css +25 -0
  197. package/lib/components/dynamic/quick-operation/components/create-share/index.js +37 -0
  198. package/lib/components/dynamic/quick-operation/components/create-task/index.css +25 -0
  199. package/lib/components/dynamic/quick-operation/components/create-task/index.js +42 -0
  200. package/lib/components/dynamic/quick-operation/img/create-announcement.png +0 -0
  201. package/lib/components/dynamic/quick-operation/img/create-okr.png +0 -0
  202. package/lib/components/dynamic/quick-operation/img/create-share.png +0 -0
  203. package/lib/components/dynamic/quick-operation/img/create-task.png +0 -0
  204. package/lib/components/dynamic/quick-operation/index.css +51 -0
  205. package/lib/components/dynamic/quick-operation/index.js +112 -0
  206. package/lib/components/dynamic/request-api.js +92 -0
  207. package/lib/components/dynamic/util.js +140 -0
  208. package/lib/components/emotionsSelector/style.js +1 -1
  209. package/lib/components/file-list/components/single-file/index.css +84 -0
  210. package/lib/components/file-list/components/single-file/index.js +115 -0
  211. package/lib/components/file-list/img/new-file-list-doc.svg +1 -0
  212. package/lib/components/file-list/img/new-file-list-other.svg +1 -0
  213. package/lib/components/file-list/img/new-file-list-pdf.svg +1 -0
  214. package/lib/components/file-list/img/new-file-list-ppt.svg +1 -0
  215. package/lib/components/file-list/img/new-file-list-radio.svg +1 -0
  216. package/lib/components/file-list/img/new-file-list-video.svg +1 -0
  217. package/lib/components/file-list/img/new-file-list-xls.svg +1 -0
  218. package/lib/components/file-list/index.css +5 -0
  219. package/lib/components/file-list/index.js +61 -0
  220. package/lib/components/file-list/interface.js +5 -0
  221. package/lib/components/file-list/util.js +78 -0
  222. package/lib/components/form/form-fields/input/index.css +11 -0
  223. package/lib/components/form/form-fields/input/index.js +3 -1
  224. package/lib/components/grid-page/image/{Assistant.svg → assistant.svg} +0 -0
  225. package/lib/components/grid-page/image/{Boss.svg → boss.svg} +0 -0
  226. package/lib/components/grid-page/image/{Default-background.png → default-background.png} +0 -0
  227. package/lib/components/grid-page/image/{UserManager.svg → userManager.svg} +0 -0
  228. package/lib/components/grid-page/personal-info/index.js +5 -5
  229. package/lib/components/img-viewer/icon/enlarge.js +30 -0
  230. package/lib/components/img-viewer/icon/left-rotate.js +46 -0
  231. package/lib/components/img-viewer/icon/right-rotate.js +44 -0
  232. package/lib/components/img-viewer/icon/shrink.js +37 -0
  233. package/lib/components/img-viewer/image/loading.gif +0 -0
  234. package/lib/components/img-viewer/index.css +155 -0
  235. package/lib/components/img-viewer/index.js +228 -0
  236. package/lib/components/img-viewer/interface.js +5 -0
  237. package/lib/components/img-viewer/util.js +16 -0
  238. package/lib/components/mblog/components/MblogAction.js +10 -6
  239. package/lib/components/mblog/index.js +24 -11
  240. package/lib/components/mblog/style.js +8 -8
  241. package/lib/components/okr-detail/components/header/index.css +4 -0
  242. package/lib/components/okr-detail/components/header/o-cycle.js +2 -2
  243. package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +15 -8
  244. package/lib/components/okr-flow/child-node/work-node.js +7 -1
  245. package/lib/components/okr-period-selector/select-cycle.js +139 -151
  246. package/lib/components/okr-progress-detail/index.css +1 -0
  247. package/lib/components/okr-review/ReviewPop/components/ReviewBody/index.js +5 -5
  248. package/lib/components/okr-review/ReviewPop/index.js +4 -4
  249. package/lib/components/period-selector/common.js +168 -17
  250. package/lib/components/period-selector/components/selector/index.js +103 -38
  251. package/lib/components/period-selector/components/selector/style.js +23 -9
  252. package/lib/components/period-selector/index.js +29 -28
  253. package/lib/components/popup/index.js +3 -1
  254. package/lib/components/publish-dynamic-modal/index.js +13 -0
  255. package/lib/components/publish-dynamic-modal/interface.js +5 -0
  256. package/lib/components/publish-dynamic-modal/publish-dynamic-modal.css +3 -0
  257. package/lib/components/publish-dynamic-modal/publish-dynamic-modal.js +191 -0
  258. package/lib/components/publish-dynamic-modal/requist-api.js +48 -0
  259. package/lib/components/radio/index.css +5 -0
  260. package/lib/components/radio/radio.js +12 -4
  261. package/lib/components/search-key-handle/index.js +39 -0
  262. package/lib/components/table/index.css +0 -1
  263. package/lib/components/upload/components/uploadedPreview.js +62 -54
  264. package/lib/components/upload/img/doc.svg +1 -0
  265. package/lib/components/upload/img/other.svg +1 -0
  266. package/lib/components/upload/img/pdf.svg +1 -0
  267. package/lib/components/upload/img/ppt.svg +1 -0
  268. package/lib/components/upload/img/radio.svg +1 -0
  269. package/lib/components/upload/img/video.svg +1 -0
  270. package/lib/components/upload/img/xls.svg +1 -0
  271. package/lib/components/upload/index.css +26 -0
  272. package/lib/components/upload/index.js +89 -57
  273. package/lib/components/upload/style.js +7 -7
  274. package/lib/components/upload/type.js +15 -15
  275. package/lib/components/upload/util.js +102 -0
  276. package/lib/components/upvote/index.js +37 -14
  277. package/lib/components/user-selector/export-modules/field-tree-selector/index.css +4 -0
  278. package/lib/components/user-selector/export-modules/field-tree-selector/index.js +50 -24
  279. package/lib/components/user-selector/export-modules/field-tree-selector/single-selector/index.js +11 -2
  280. package/lib/components/user-selector/layout/index.css +1 -1
  281. package/lib/components-v1/buttonv2/ButtonLinked.js +35 -0
  282. package/lib/components-v1/buttonv2/ButtonOutlined.js +64 -0
  283. package/lib/components-v1/buttonv2/ButtonRounded.js +101 -0
  284. package/lib/components-v1/buttonv2/DefaultButton.js +86 -0
  285. package/lib/components-v1/buttonv2/index.js +37 -0
  286. package/lib/components-v1/buttonv2/style/style.js +53 -0
  287. package/lib/components-v1/buttonv2/style/theme.css +3 -0
  288. package/lib/components-v1/confirm/index.js +158 -0
  289. package/lib/index.js +49 -5
  290. package/lib/pages/dynamic/index.css +5 -0
  291. package/lib/pages/dynamic/index.js +25 -0
  292. package/lib/pages/home-page/components/data-list/nav-selector/index.js +18 -0
  293. package/lib/pages/home-page/components/data-list/table/utils-function.js +6 -3
  294. package/lib/pages/like-ranking/column.js +141 -0
  295. package/lib/pages/like-ranking/filter-buttons/department.js +44 -0
  296. package/lib/pages/like-ranking/filter-buttons/group.js +34 -0
  297. package/lib/pages/like-ranking/filter-buttons/index.css +19 -0
  298. package/lib/pages/like-ranking/filter-buttons/index.js +40 -0
  299. package/lib/pages/like-ranking/filter-buttons/modular.js +110 -0
  300. package/lib/pages/like-ranking/filter-buttons/name.js +73 -0
  301. package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.css +27 -0
  302. package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.js +38 -0
  303. package/lib/pages/like-ranking/filter-buttons/timer.js +56 -0
  304. package/lib/pages/like-ranking/image/dynamic-empty.png +0 -0
  305. package/lib/pages/like-ranking/image/loading.gif +0 -0
  306. package/lib/pages/like-ranking/image/ranking-1.png +0 -0
  307. package/lib/pages/like-ranking/image/ranking-2.png +0 -0
  308. package/lib/pages/like-ranking/image/ranking-3.png +0 -0
  309. package/lib/pages/like-ranking/index.css +185 -0
  310. package/lib/pages/like-ranking/index.js +252 -0
  311. package/lib/pages/like-ranking/mock.js +366 -0
  312. package/lib/pages/like-ranking/request-api.js +15 -0
  313. package/lib/utils/auth.js +46 -5
  314. package/lib/utils/bs-global.js +26 -2
  315. package/lib/utils/format-time.js +161 -0
  316. package/lib/utils/helpers.js +41 -0
  317. package/lib/utils/roundWeight.js +105 -0
  318. package/lib/utils/tools.js +140 -20
  319. package/package.json +2 -2
@@ -0,0 +1,346 @@
1
+ .okr-create-cases-modal {
2
+ overflow: auto;
3
+ height: 100%;
4
+ width: 100%;
5
+ margin: 0 auto;
6
+ margin-bottom: 30px;
7
+ }
8
+
9
+ .okr-create-cases-modal #tt-modal-container {
10
+ height: 100%;
11
+ }
12
+
13
+ .okr-create-cases-modal #tt-modal-container .tita-show-modal {
14
+ height: 100%;
15
+ width: 100%;
16
+ }
17
+
18
+ .create-okr__okr-case {
19
+ width: 100%;
20
+ height: 100%;
21
+ margin-top: 40px;
22
+ box-sizing: border-box;
23
+ overflow: hidden;
24
+ }
25
+
26
+ .okr-field-visible {
27
+ display: inline-block;
28
+ }
29
+
30
+ .okr-field-visible > div {
31
+ display: none !important;
32
+ }
33
+
34
+ .visibility,
35
+ .okr-type {
36
+ display: inline-block;
37
+ }
38
+
39
+ .visibility > div,
40
+ .okr-type > div {
41
+ display: none !important;
42
+ }
43
+
44
+ .visibility .edit-icon,
45
+ .okr-type .edit-icon {
46
+ display: inline-block;
47
+ visibility: hidden;
48
+ width: 30px;
49
+ height: 30px;
50
+ border-radius: 2px;
51
+ border: 1px solid transparent;
52
+ text-align: center;
53
+ vertical-align: middle;
54
+ font-size: 18px;
55
+ color: #647481;
56
+ cursor: pointer;
57
+ line-height: 30px;
58
+ background-color: white;
59
+ }
60
+
61
+ .visibility .edit-icon:hover,
62
+ .okr-type .edit-icon:hover {
63
+ background-color: #f5f8fa !important;
64
+ box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.2);
65
+ color: #1687d9;
66
+ }
67
+
68
+ .visibility:hover .edit-icon,
69
+ .okr-type:hover .edit-icon {
70
+ visibility: visible;
71
+ }
72
+
73
+ .okr-o-new-name {
74
+ flex: 1;
75
+ height: 48px;
76
+ border-radius: 4px;
77
+ box-shadow: 0 2px 8px 0 rgba(127, 145, 180, 0.15);
78
+ margin-top: 24px;
79
+ margin-bottom: 8px;
80
+ display: flex;
81
+ align-items: center;
82
+ justify-content: space-between;
83
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
84
+ width: 536px;
85
+ }
86
+
87
+ .okr-o-new-name .okr-o-new-name__left-block {
88
+ flex: 1;
89
+ display: flex;
90
+ position: relative;
91
+ }
92
+
93
+ .okr-o-new-name .okr-o-new-name__left-block .left-block__title {
94
+ font-size: 18px;
95
+ line-height: 22px;
96
+ padding-left: 12px;
97
+ padding-right: 10px;
98
+ color: #2879ff;
99
+ font-weight: 600;
100
+ }
101
+
102
+ .okr-o-new-name .okr-o-new-name__left-block .left-block__input {
103
+ border: none;
104
+ outline: none;
105
+ flex: 1;
106
+ color: #141c28;
107
+ font-weight: 600;
108
+ font-size: 16px;
109
+ margin-right: 8px;
110
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
111
+ }
112
+
113
+ .okr-o-new-name .okr-o-new-name__left-block .left-block__input::placeholder {
114
+ color: #bfc7d5;
115
+ font-weight: 400;
116
+ }
117
+
118
+ .okr-o-new-name .okr-o-new-name__left-block .left-block__right-text-mask {
119
+ width: 30px;
120
+ height: 24px;
121
+ background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, #ffffff 100%);
122
+ position: absolute;
123
+ right: 8px;
124
+ }
125
+
126
+ .user-info {
127
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
128
+ display: flex;
129
+ align-items: center;
130
+ justify-content: space-between;
131
+ }
132
+
133
+ .user-info :hover {
134
+ cursor: pointer;
135
+ }
136
+
137
+ .user-info .user__name {
138
+ width: 48px;
139
+ color: #6f7886;
140
+ font-size: 12px;
141
+ line-height: 22px;
142
+ margin-left: 4px;
143
+ overflow: hidden;
144
+ text-overflow: ellipsis;
145
+ margin-right: 10px;
146
+ word-break: keep-all;
147
+ }
148
+
149
+ .user-info .user__name--hidden {
150
+ font-size: 12px;
151
+ visibility: hidden;
152
+ position: absolute;
153
+ }
154
+
155
+ .error-popup-text-wrapper {
156
+ color: #f05e5e;
157
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
158
+ font-size: 12px;
159
+ line-height: 22px;
160
+ display: inline-block;
161
+ background: white;
162
+ padding: 5px 12px;
163
+ box-shadow: 0 4px 12px 0 rgba(127, 145, 180, 0.2);
164
+ position: relative;
165
+ margin-bottom: 5px;
166
+ }
167
+
168
+ .error-popup-text-wrapper::after {
169
+ content: "";
170
+ display: block;
171
+ border: 6px solid transparent;
172
+ position: absolute;
173
+ border-top-color: #ffffff;
174
+ bottom: -11px;
175
+ left: 50%;
176
+ }
177
+
178
+ .create-modal__sub-title {
179
+ font-size: 14px;
180
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
181
+ font-weight: 400;
182
+ color: #89919f;
183
+ line-height: 20px;
184
+ margin-bottom: 6px;
185
+ }
186
+
187
+ .modal-centered .zoom-enter-done {
188
+ overflow: visible !important;
189
+ }
190
+
191
+ .okr-create-suggest {
192
+ width: 262px;
193
+ height: 523px;
194
+ position: absolute;
195
+ left: 100%;
196
+ top: 58px;
197
+ background: linear-gradient(180deg, #ffffff 0%, #fff8e4 100%);
198
+ border: 1px solid #f6bd16;
199
+ padding: 20px 16px;
200
+ box-sizing: border-box;
201
+ border-radius: 4px;
202
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
203
+ }
204
+
205
+ .okr-create-suggest .okr-create-suggest__triangle {
206
+ position: absolute;
207
+ left: -6px;
208
+ top: 40px;
209
+ background: #fffffd;
210
+ }
211
+
212
+ .okr-create-suggest .okr-create-suggest__triangle::after {
213
+ content: "";
214
+ display: block;
215
+ border: 8px solid #fffffd;
216
+ border-top: 8px solid transparent;
217
+ border-left: 8px solid transparent;
218
+ border-bottom: 8px solid transparent;
219
+ position: absolute;
220
+ top: -1px;
221
+ left: -9px;
222
+ }
223
+
224
+ .okr-create-suggest .okr-create-suggest__triangle::before {
225
+ content: "";
226
+ display: block;
227
+ border: 8px solid #f6bd16;
228
+ border-top: 8px solid transparent;
229
+ border-left: 8px solid transparent;
230
+ border-bottom: 8px solid transparent;
231
+ position: absolute;
232
+ top: -1px;
233
+ left: -10px;
234
+ }
235
+
236
+ .okr-create-suggest .okr-create-suggest__descs .okr-create-suggest__desc {
237
+ margin-bottom: 12px;
238
+ }
239
+
240
+ .okr-create-suggest .okr-create-suggest__descs .okr-create-suggest__desc:last-of-type {
241
+ margin-bottom: 0;
242
+ }
243
+
244
+ .okr-create-suggest .okr-create-suggest__triangle--iskr {
245
+ top: 92px;
246
+ }
247
+
248
+ .okr-create-suggest .okr-create-suggest__descs {
249
+ font-size: 16px;
250
+ font-weight: 500;
251
+ color: #f6bd16;
252
+ line-height: 24px;
253
+ padding: 0 16px;
254
+ }
255
+
256
+ .okr-create-suggest .okr-create-suggest__right-quotation {
257
+ display: flex;
258
+ justify-content: flex-end;
259
+ margin-bottom: 14px;
260
+ }
261
+
262
+ .okr-create-suggest .okr-create-suggest__block {
263
+ font-size: 12px;
264
+ color: #6f7886;
265
+ line-height: 18px;
266
+ margin-bottom: 24px;
267
+ }
268
+
269
+ .okr-create-suggest .okr-create-suggest__block .okr-create-suggest__block-title {
270
+ font-size: 14px;
271
+ color: #3f4755;
272
+ display: flex;
273
+ align-items: center;
274
+ margin-bottom: 8px;
275
+ }
276
+
277
+ .okr-create-suggest .okr-create-suggest__block .okr-create-suggest__block-title .okr-create-suggest__block-title-icon {
278
+ margin-right: 4px;
279
+ }
280
+
281
+ .okr-create-suggest .okr-create-suggest__check-item {
282
+ margin-left: 16px;
283
+ display: flex;
284
+ align-items: center;
285
+ margin-bottom: 4px;
286
+ }
287
+
288
+ .okr-create-suggest .okr-create-suggest__check-item .okr-create-suggest__check-item-icon {
289
+ margin-right: 8px;
290
+ }
291
+
292
+ .okr-create-suggest .okr-create-suggest__example {
293
+ margin: 0 16px;
294
+ }
295
+
296
+ .okr-create-suggest .okr-create-suggest__pack-up {
297
+ position: absolute;
298
+ bottom: 20px;
299
+ right: 32px;
300
+ font-size: 12px;
301
+ font-weight: normal;
302
+ color: #3f4755;
303
+ line-height: 22px;
304
+ display: flex;
305
+ align-items: center;
306
+ }
307
+
308
+ .okr-create-suggest .okr-create-suggest__pack-up:hover {
309
+ color: #2879ff;
310
+ cursor: pointer;
311
+ }
312
+
313
+ .okr-create-suggest .okr-create-suggest__pack-up .okr-create-suggest__pack-up-text {
314
+ margin-left: 4px;
315
+ }
316
+
317
+ .okr-create-suggest .okr-create-suggest__animation-wrapper {
318
+ position: relative;
319
+ display: flex;
320
+ align-items: center;
321
+ justify-content: center;
322
+ margin-top: 42px;
323
+ margin-bottom: 20px;
324
+ }
325
+
326
+ .okr-create-suggest .okr-create-suggest__animation-wrapper .okr-create-suggest__animation-wave {
327
+ display: flex;
328
+ height: 32px;
329
+ }
330
+
331
+ .okr-create-suggest .okr-create-suggest__animation-wrapper .okr-create-suggest__animation-wave--hidden {
332
+ position: absolute;
333
+ z-index: -1;
334
+ }
335
+
336
+ .okr-create-suggest .okr-create-suggest__animation-wrapper .okr-create-suggest__animation-wave--static {
337
+ height: 32px;
338
+ width: 228px;
339
+ }
340
+
341
+ .okr-create-suggest .okr-create-suggest__animation-wrapper .okr-create-suggest__animation-text {
342
+ position: absolute;
343
+ font-size: 12px;
344
+ color: #f6bd16;
345
+ line-height: 18px;
346
+ }
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.OkrFieldType = exports.OkrFieldVisibility = void 0;
7
+
8
+ var _okrVisibilityDetail = _interopRequireDefault(require("./okr-visibility-detail"));
9
+
10
+ var _okrTypeDetail = _interopRequireDefault(require("./okr-type-detail"));
11
+
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
13
+
14
+ var OkrFieldVisibility = _okrVisibilityDetail["default"];
15
+ exports.OkrFieldVisibility = OkrFieldVisibility;
16
+ var OkrFieldType = _okrTypeDetail["default"];
17
+ exports.OkrFieldType = OkrFieldType;
@@ -0,0 +1,57 @@
1
+ "use strict";
2
+
3
+ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports["default"] = void 0;
9
+
10
+ var _react = _interopRequireWildcard(require("react"));
11
+
12
+ var _popup = _interopRequireDefault(require("../../popup"));
13
+
14
+ require("./index.css");
15
+
16
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
17
+
18
+ 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); }
19
+
20
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
21
+
22
+ var StrLengthOverflowError = function StrLengthOverflowError(_ref) {
23
+ var strLength = _ref.strLength,
24
+ maxLength = _ref.maxLength;
25
+ return /*#__PURE__*/_react["default"].createElement(_react.Fragment, null, strLength > maxLength ? /*#__PURE__*/_react["default"].createElement("span", {
26
+ className: "error-popup-text-wrapper"
27
+ }, "\u5DF2\u8F93\u5165 ".concat(strLength, " \u4E2A\u5B57\uFF0C\u6700\u591A\u53EF\u8F93\u5165 ").concat(maxLength, " \u4E2A\u5B57")) : null);
28
+ };
29
+
30
+ var InputWithErrPopup = function InputWithErrPopup(_ref2) {
31
+ var strLength = _ref2.strLength,
32
+ maxLength = _ref2.maxLength,
33
+ position = _ref2.position,
34
+ _ref2$forceRender = _ref2.forceRender,
35
+ forceRender = _ref2$forceRender === void 0 ? false : _ref2$forceRender,
36
+ _ref2$destroyPopupOnH = _ref2.destroyPopupOnHide,
37
+ destroyPopupOnHide = _ref2$destroyPopupOnH === void 0 ? true : _ref2$destroyPopupOnH,
38
+ children = _ref2.children;
39
+ return (
40
+ /*#__PURE__*/
41
+ // @ts-ignore
42
+ _react["default"].createElement(_popup["default"], {
43
+ popup: /*#__PURE__*/_react["default"].createElement(StrLengthOverflowError, {
44
+ strLength: strLength,
45
+ maxLength: maxLength
46
+ }),
47
+ popupVisible: true,
48
+ popupPlacement: position,
49
+ forceRender: forceRender,
50
+ action: ["focus"],
51
+ destroyPopupOnHide: destroyPopupOnHide
52
+ }, children)
53
+ );
54
+ };
55
+
56
+ var _default = InputWithErrPopup;
57
+ exports["default"] = _default;
@@ -0,0 +1,197 @@
1
+ "use strict";
2
+
3
+ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports["default"] = void 0;
9
+
10
+ var _react = _interopRequireWildcard(require("react"));
11
+
12
+ var _popDownNotification = require("../../pop-down-notification");
13
+
14
+ var _constant = require("../constant");
15
+
16
+ var _inputWithErrPopup = _interopRequireDefault(require("./input-with-err-popup"));
17
+
18
+ var _okrCreateSuggest = require("./okr-create-suggest");
19
+
20
+ var _okrNewUserSelector = _interopRequireDefault(require("./okr-new-user-selector"));
21
+
22
+ var _requestApi = require("../request-api");
23
+
24
+ require("./index.css");
25
+
26
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
27
+
28
+ 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); }
29
+
30
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
31
+
32
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
33
+
34
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
35
+
36
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
37
+
38
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
39
+
40
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
41
+
42
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
43
+
44
+ var initOCheckResult = _constant.OCheckTarget.map(function (item) {
45
+ return {
46
+ text: item,
47
+ result: _okrCreateSuggest.EOkrCreateSuggestResultType.normal
48
+ };
49
+ });
50
+
51
+ var _default = function _default(_ref) {
52
+ var okrName = _ref.okrName,
53
+ setOkrName = _ref.setOkrName,
54
+ container = _ref.container,
55
+ user = _ref.user,
56
+ setUser = _ref.setUser,
57
+ onOInputFocusStateChange = _ref.onOInputFocusStateChange,
58
+ setONameCheckResult = _ref.setONameCheckResult,
59
+ setIsInputContent = _ref.setIsInputContent;
60
+ var oCheckId = 0;
61
+ var timerRef = (0, _react.useRef)();
62
+ var okrNameIsEmpty = (0, _react.useRef)(!okrName);
63
+ var oldONameRef = (0, _react.useRef)("");
64
+ var formatUser = (0, _react.useMemo)(function () {
65
+ var medium = user.avatar ? user.avatar.Medium ? user.avatar.Medium : user.avatar.medium : undefined;
66
+ var color = user.avatar ? user.avatar.Color ? user.avatar.Color : user.avatar.color : undefined;
67
+ return {
68
+ Medium: medium,
69
+ Color: color,
70
+ Name: user.name,
71
+ Id: user.id
72
+ };
73
+ }, [user.avatar, user.avatar, user.name, user.id]);
74
+ var changeUser = (0, _react.useCallback)(function (_ref2) {
75
+ var _ref3 = _slicedToArray(_ref2, 1),
76
+ user = _ref3[0];
77
+
78
+ var avatar = {
79
+ Color: user.UserAvatar.Color,
80
+ Small: user.UserAvatar.Small,
81
+ Medium: user.UserAvatar.Medium
82
+ };
83
+ setUser && setUser({
84
+ name: user.Name,
85
+ id: user.Id,
86
+ avatar: avatar
87
+ });
88
+ }, [setUser]);
89
+ var getOAnalysisInfo = (0, _react.useCallback)(function () {
90
+ oCheckId++;
91
+ var tempCheckId = oCheckId; // @ts-ignore
92
+
93
+ return (0, _requestApi.getOAnalysisInfos)({
94
+ text: okrName
95
+ }) //@ts-ignore
96
+ .then(function (data) {
97
+ if (tempCheckId !== oCheckId) {
98
+ return;
99
+ }
100
+
101
+ var result = _constant.OCheckTarget.map(function (item, index) {
102
+ if (index === 0) {
103
+ return {
104
+ text: item,
105
+ result: data.hasVtWords ? _okrCreateSuggest.EOkrCreateSuggestResultType.correct : _okrCreateSuggest.EOkrCreateSuggestResultType.wrong
106
+ };
107
+ } else {
108
+ return {
109
+ text: item,
110
+ result: data.hasNumWords ? _okrCreateSuggest.EOkrCreateSuggestResultType.wrong : _okrCreateSuggest.EOkrCreateSuggestResultType.correct
111
+ };
112
+ }
113
+ }); // 如果已经清空了okr,则赋给默认值
114
+
115
+
116
+ if (okrNameIsEmpty.current) {
117
+ setONameCheckResult(initOCheckResult);
118
+ } else {
119
+ setONameCheckResult(result);
120
+ }
121
+ })["catch"](function (err) {
122
+ _popDownNotification.Toast.Error(err);
123
+ })["finally"](function () {
124
+ setIsInputContent(false);
125
+ });
126
+ }, [okrName, setIsInputContent]);
127
+ (0, _react.useEffect)(function () {
128
+ // 防抖
129
+ okrNameIsEmpty.current = !okrName;
130
+
131
+ if (!okrName) {
132
+ setONameCheckResult(initOCheckResult);
133
+ setIsInputContent(false);
134
+ return;
135
+ }
136
+
137
+ if (timerRef.current) {
138
+ clearTimeout(timerRef.current);
139
+ timerRef.current = setTimeout(getOAnalysisInfo, 1000);
140
+ return;
141
+ }
142
+
143
+ timerRef.current = setTimeout(getOAnalysisInfo, 1000);
144
+ return function () {
145
+ clearTimeout(timerRef.current);
146
+ };
147
+ }, [okrName]);
148
+ var handleInputFocus = (0, _react.useCallback)(function () {
149
+ onOInputFocusStateChange && onOInputFocusStateChange(true);
150
+ }, []);
151
+ var handleInputBlur = (0, _react.useCallback)(function () {
152
+ onOInputFocusStateChange && onOInputFocusStateChange(false);
153
+ }, []);
154
+ var handleOnKeyDown = (0, _react.useCallback)(function () {
155
+ setIsInputContent(true);
156
+ }, [setIsInputContent]);
157
+ var handleOnKeyUp = (0, _react.useCallback)(function (e) {
158
+ e.persist(); // 解决按功能按钮的时候一直显示检测中
159
+
160
+ if (e.target.value === oldONameRef.current) {
161
+ setIsInputContent(false);
162
+ } else {
163
+ oldONameRef.current = e.target.value;
164
+ }
165
+ }, []);
166
+ return /*#__PURE__*/_react["default"].createElement("div", {
167
+ className: "okr-o-new-name"
168
+ }, /*#__PURE__*/_react["default"].createElement("div", {
169
+ className: "okr-o-new-name__left-block"
170
+ }, /*#__PURE__*/_react["default"].createElement("span", {
171
+ className: "left-block__title"
172
+ }, "O"), /*#__PURE__*/_react["default"].createElement(_inputWithErrPopup["default"], {
173
+ strLength: okrName.length,
174
+ maxLength: 500,
175
+ position: "top"
176
+ }, /*#__PURE__*/_react["default"].createElement("input", {
177
+ onFocus: handleInputFocus,
178
+ onBlur: handleInputBlur,
179
+ className: "left-block__input",
180
+ placeholder: "\u8BF7\u8F93\u5165\u9F13\u821E\u4EBA\u5FC3\u7684\u76EE\u6807",
181
+ type: "text",
182
+ value: okrName,
183
+ onChange: function onChange(e) {
184
+ return setOkrName(e.target.value);
185
+ },
186
+ onKeyDown: handleOnKeyDown,
187
+ onKeyUp: handleOnKeyUp
188
+ })), /*#__PURE__*/_react["default"].createElement("div", {
189
+ className: "left-block__right-text-mask"
190
+ })), /*#__PURE__*/_react["default"].createElement(_okrNewUserSelector["default"], {
191
+ user: formatUser,
192
+ container: container,
193
+ changeUser: changeUser
194
+ }));
195
+ };
196
+
197
+ exports["default"] = _default;