From d370c5fbf256a60ae469c764260225ebc6863937 Mon Sep 17 00:00:00 2001 From: chenxuting Date: Sun, 29 Jan 2023 14:02:26 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=F0=9F=8E=B8=20im=20ui=20kit=20?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- react/package-lock.json | 305 +++++----- react/package.json | 2 +- react/src/YXUIKit/chat-kit-ui/package.json | 10 +- .../src/YXUIKit/chat-kit-ui/src/Container.tsx | 32 +- .../src/components/ChatCreateTeam/index.tsx | 3 +- .../src/components/ChatMessageInput/index.tsx | 97 ++- .../ChatMessageInput/style/index.less | 28 +- .../src/components/ChatMessageItem/index.tsx | 347 ++++++----- .../ChatMessageItem/style/index.less | 3 +- .../components/ChatP2pMessageList/index.tsx | 18 +- .../ChatP2pMessageList/style/index.less | 3 +- .../components/ChatTeamMessageList/index.tsx | 21 +- .../ChatTeamMessageList/style/index.less | 3 +- .../components/ChatTeamSetting/GroupItem.tsx | 132 ++-- .../components/ChatTeamSetting/GroupList.tsx | 39 +- .../components/ChatTeamSetting/GroupPower.tsx | 2 +- .../src/components/ChatTeamSetting/index.tsx | 44 +- .../ChatTeamSetting/style/index.less | 9 + .../src/containers/p2pChatContainer.tsx | 82 ++- .../src/containers/teamChatContainer.tsx | 121 +++- react/src/YXUIKit/common-ui/package.json | 10 +- .../src/components/CommonIcon/index.tsx | 5 +- .../components/CommonParseSession/index.tsx | 543 ++++++++++++----- .../CommonParseSession/style/index.less | 77 ++- .../components/GroupAvatarSelect/index.tsx | 12 +- .../GroupAvatarSelect/style/index.less | 5 + .../src/components/MyUserCard/index.tsx | 129 ++-- .../components/MyUserCard/style/index.less | 8 +- .../src/components/ReadPercent/index.tsx | 85 +++ .../components/ReadPercent/style/index.less | 26 + .../src/components/ReadPercent/style/index.ts | 2 + .../components/ReadPercent/style/theme.less | 3 + .../src/components/UserCard/index.tsx | 4 +- .../common-ui/src/contextManager/Provider.tsx | 24 +- .../src/contextManager/store/connect.ts | 6 +- .../src/contextManager/store/friends.ts | 16 +- .../src/contextManager/store/index.ts | 4 +- .../src/contextManager/store/msgs.ts | 280 +++++++-- .../contextManager/store/superTeamMembers.ts | 3 +- .../src/contextManager/store/superTeams.ts | 5 +- .../src/contextManager/store/sysMsgs.ts | 80 ++- .../src/contextManager/store/teamMembers.ts | 46 +- .../src/contextManager/store/teams.ts | 33 +- .../common-ui/src/contextManager/store/ui.ts | 221 ++++--- .../src/contextManager/store/users.ts | 3 + .../common-ui/src/contextManager/types.ts | 2 - react/src/YXUIKit/common-ui/src/index.ts | 6 +- react/src/YXUIKit/common-ui/src/locales/zh.ts | 86 +++ react/src/YXUIKit/common-ui/src/utils.ts | 109 ++++ react/src/YXUIKit/contact-kit-ui/package.json | 8 +- .../src/contact-list/Container.tsx | 2 +- .../contact-list/components/ContactItem.tsx | 2 +- .../src/contact-list/style/contactItem.less | 2 +- .../src/msg-list/components/MsgItem.tsx | 562 +++++++++--------- .../YXUIKit/conversation-kit-ui/package.json | 8 +- .../src/components/ConversationItem.tsx | 36 +- react/src/YXUIKit/im-kit-ui/package.json | 18 +- react/src/YXUIKit/im-kit-ui/src/index.ts | 2 + .../src/YXUIKit/im-kit-ui/src/style/index.ts | 2 + react/src/YXUIKit/search-kit-ui/package.json | 10 +- .../src/add/components/CreateModal/index.tsx | 4 +- .../add/components/JoinTeamModal/index.tsx | 7 +- .../search-kit-ui/src/add/style/addItem.less | 2 - .../search-kit-ui/src/add/style/addList.less | 1 - .../search-kit-ui/src/add/style/addModal.less | 2 +- .../src/add/style/createModal.less | 8 +- .../IMApp/components/MenuOptions.tsx | 99 +++ .../src/components/IMApp/components/Menus.tsx | 53 ++ .../components/IMApp/components/Setting.tsx | 105 ++++ react/src/components/IMApp/iconfont.css | 11 +- react/src/components/IMApp/index.less | 111 +++- react/src/components/IMApp/index.tsx | 227 +++++-- .../components/IMApp/locales/demo_locale.ts | 31 + react/src/components/IMApp/locales/en.ts | 278 +++++++++ react/src/components/IMApp/locales/zh.ts | 272 +++++++++ react/src/pages/index.tsx | 5 +- vue/package-lock.json | 284 +++++---- vue/package.json | 2 +- 78 files changed, 3834 insertions(+), 1454 deletions(-) create mode 100644 react/src/YXUIKit/common-ui/src/components/ReadPercent/index.tsx create mode 100644 react/src/YXUIKit/common-ui/src/components/ReadPercent/style/index.less create mode 100644 react/src/YXUIKit/common-ui/src/components/ReadPercent/style/index.ts create mode 100644 react/src/YXUIKit/common-ui/src/components/ReadPercent/style/theme.less create mode 100644 react/src/components/IMApp/components/MenuOptions.tsx create mode 100644 react/src/components/IMApp/components/Menus.tsx create mode 100644 react/src/components/IMApp/components/Setting.tsx create mode 100644 react/src/components/IMApp/locales/demo_locale.ts create mode 100644 react/src/components/IMApp/locales/en.ts create mode 100644 react/src/components/IMApp/locales/zh.ts diff --git a/react/package-lock.json b/react/package-lock.json index be3e58d..7cf3bf5 100644 --- a/react/package-lock.json +++ b/react/package-lock.json @@ -6,7 +6,7 @@ "": { "hasInstallScript": true, "dependencies": { - "@xkit-yx/im-kit-ui": "^0.2.3", + "@xkit-yx/im-kit-ui": "^0.3.1", "umi": "^4.0.40" }, "devDependencies": { @@ -2917,13 +2917,13 @@ } }, "node_modules/@xkit-yx/chat-kit-ui": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/chat-kit-ui/-/chat-kit-ui-0.5.1.tgz", - "integrity": "sha512-Ma2ALiltf/WuLo468NZJFcTtilXBC2tZhiljX3TORVXH6UH9qoL3rkxkthbyCM807vnVkeCOqT9ZdhFEu9GKAQ==", + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/chat-kit-ui/-/chat-kit-ui-0.6.1.tgz", + "integrity": "sha512-DMrHqvE87uUL8YfSlIV6UvZS0nnRItLUIaR2YbU/OP3P2V6zOY3GwxVg8pspUBtiCOiUuzhtwa8h9sM5ZF/fKg==", "dependencies": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2", @@ -2942,12 +2942,12 @@ } }, "node_modules/@xkit-yx/common-ui": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/common-ui/-/common-ui-0.5.1.tgz", - "integrity": "sha512-7U01KDM3gNE1SyhCUmtFTNcj2UeFlsuWjUU1jvuHZbK182ROmjkaY7qDWbu/zHNY3iyMYUy4O6TLhnzKiz5CTg==", + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/common-ui/-/common-ui-0.6.1.tgz", + "integrity": "sha512-EfmRzNRyNARtHH6IkP9JlB3WIpWSKbTdEnOnv4kvArJfK9tZBsWN3MDRbTvZ/CiDxxbdvg/5qq5ha2DHUpTJBg==", "dependencies": { - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2", @@ -2965,12 +2965,12 @@ } }, "node_modules/@xkit-yx/contact-kit-ui": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/contact-kit-ui/-/contact-kit-ui-0.3.1.tgz", - "integrity": "sha512-Y88CGslikOZ//BdB7kTwG/yHXmzFN7F1dInCMD/3JgAkKwjyugaKvr6JjKD7gMI6CEnrciX3OA8G6WTaYY1pcA==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/contact-kit-ui/-/contact-kit-ui-0.4.1.tgz", + "integrity": "sha512-Lk+qTsWp9lCVzx0lic2B/DrqSJg5xMDE+PENKs0w1XgEOe5cSr48UD1RkftcbpIbmRV+GNx7Xk6fh/4eIdvjZw==", "dependencies": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" @@ -2986,12 +2986,12 @@ } }, "node_modules/@xkit-yx/conversation-kit-ui": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/conversation-kit-ui/-/conversation-kit-ui-0.3.1.tgz", - "integrity": "sha512-01OXeBhOdIqAZd0r5+IsncDkoWa8xubEeybjNlAMzsijld/c/FiqNyqIHEIAOz4Z8tszr/r9bE0OyTEQoSZiJA==", + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@xkit-yx/conversation-kit-ui/-/conversation-kit-ui-0.3.3.tgz", + "integrity": "sha512-rV/d5X/rpFw5Y+EBm95VnOA+S50GeorMR2HBGR1XYbzAFngFKd1AQrlS9f3ORfZAVene2BiFJqkO168IDeN8VQ==", "dependencies": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" @@ -3007,12 +3007,12 @@ } }, "node_modules/@xkit-yx/core-kit": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@xkit-yx/core-kit/-/core-kit-0.7.0.tgz", - "integrity": "sha512-6PlJUKcuZUnAe9glWM1dcZ3hXxC+htNa1yM76DQqGIlwPDFaP38QDCgQziH0OLvf/bSTaWkijdUR7HAoaV5xpg==", + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@xkit-yx/core-kit/-/core-kit-0.8.0.tgz", + "integrity": "sha512-fQOM0LtXB4jDWRB6/ZmzPvDSrBUE++UvvLe79l6AvvUaPOpE688m1EqD8yfWNZgRtHH471VHQPQo20FLk9Mvtg==", "dependencies": { "@scaret/nertc-web-sdk": "4.6.252", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/utils": "^0.5.0", "@yxim/nim-web-sdk": "9.6.3", "axios": "^0.27.2", "eventemitter3": "^4.0.7", @@ -3030,17 +3030,17 @@ } }, "node_modules/@xkit-yx/im-kit-ui": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/@xkit-yx/im-kit-ui/-/im-kit-ui-0.2.3.tgz", - "integrity": "sha512-hkjgS+3Jkbe83wSCLZzoS5le/lxOcUPiU7P6Q59tCeTdp8knjbMKjH3uVFxAe6J0s2dJWIYoIv6lag3WUhhC4w==", - "dependencies": { - "@xkit-yx/chat-kit-ui": "^0.5.1", - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/contact-kit-ui": "^0.3.1", - "@xkit-yx/conversation-kit-ui": "^0.3.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/search-kit-ui": "^0.4.1", - "@xkit-yx/utils": "^0.4.5", + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/im-kit-ui/-/im-kit-ui-0.3.1.tgz", + "integrity": "sha512-4VUgYkmgf+9Jcj9S6ncQDzBTsXgrU6+kj5GO5Z7FSmLLaaRHxzEmIbE5QQ20zuBWzzphOvDpyjyumOZRAr/Xhw==", + "dependencies": { + "@xkit-yx/chat-kit-ui": "^0.6.1", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/contact-kit-ui": "^0.4.1", + "@xkit-yx/conversation-kit-ui": "^0.3.3", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/search-kit-ui": "^0.5.1", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" @@ -3061,13 +3061,13 @@ } }, "node_modules/@xkit-yx/search-kit-ui": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/search-kit-ui/-/search-kit-ui-0.4.1.tgz", - "integrity": "sha512-k5wSLyhYTchTEvFq1K5Py0vXPRewiRWGZv/GpGwcD5UXO6Bvc/A/2Si6t2bCWyClBUS3Wgvwn0+xUUiIfCwnHA==", + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/search-kit-ui/-/search-kit-ui-0.5.1.tgz", + "integrity": "sha512-16i+g3ab/Im+M5CgKBelUjBEJ30IHq8TVC64p8gN/DQ8140Nl0BTOlESnjLt2qXDe3FV3tG3kaMbEGy97Q6TIg==", "dependencies": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" @@ -3084,9 +3084,9 @@ } }, "node_modules/@xkit-yx/utils": { - "version": "0.4.5", - "resolved": "https://registry.npmjs.org/@xkit-yx/utils/-/utils-0.4.5.tgz", - "integrity": "sha512-kdG4ywGUQicsTRRwg2E8xqHROf6VC0qlkwEOTDiVxMi4tteqS4I1qR27i5V7cnpu0n/dOFrsnC7QPL2lzdVmmg==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@xkit-yx/utils/-/utils-0.5.0.tgz", + "integrity": "sha512-dzDVY0qrQXh1zbzhDN/gAfNbZ5shW33YRqeoXkE064Nwu6HT6ORFETzai1rn9bVf7uDfcOr2FdULXlvsKAj6LA==", "dependencies": { "axios": "^0.27.2", "eventemitter3": "^4.0.7" @@ -3274,9 +3274,9 @@ } }, "node_modules/antd": { - "version": "4.24.6", - "resolved": "https://registry.npmjs.org/antd/-/antd-4.24.6.tgz", - "integrity": "sha512-x4tTXI3aOJukcG/MWQ7PdWHIqGEFInkKPhSHJpSiDvZI5BAvgLicW57WWhnBpJ6m9H9e9FRohC5FRJf0NIwsWQ==", + "version": "4.24.7", + "resolved": "https://registry.npmjs.org/antd/-/antd-4.24.7.tgz", + "integrity": "sha512-Qr3AYkeqpd3i/c6M7pjca7Y6XlaIv/p6gD3aqe7/0o8Ueg50G7Aeh+TOaiUfXLGDhnVoNEdaVdDiv8aIaoWB5A==", "dependencies": { "@ant-design/colors": "^6.0.0", "@ant-design/icons": "^4.7.0", @@ -3312,7 +3312,7 @@ "rc-steps": "~5.0.0-alpha.2", "rc-switch": "~3.2.0", "rc-table": "~7.26.0", - "rc-tabs": "~12.4.1", + "rc-tabs": "~12.5.0", "rc-textarea": "~0.4.5", "rc-tooltip": "~5.2.0", "rc-tree": "~5.7.0", @@ -9978,17 +9978,16 @@ } }, "node_modules/rc-menu": { - "version": "9.8.1", - "resolved": "https://registry.npmjs.org/rc-menu/-/rc-menu-9.8.1.tgz", - "integrity": "sha512-179weouypfjWJSRvvoo/vPy+StojsMzK2XC5jRNhL1ryt/N/8wAFESte8K6jZJkNp9DHDLFTe+dCGmikKpiFuA==", + "version": "9.8.2", + "resolved": "https://registry.npmjs.org/rc-menu/-/rc-menu-9.8.2.tgz", + "integrity": "sha512-EahOJVjLuEnJsThoPN+mGnVm431RzVzDLZWHRS/YnXTQULa7OsgdJa/Y7qXxc3Z5sz8mgT6xYtgpmBXLxrZFaQ==", "dependencies": { "@babel/runtime": "^7.10.1", "classnames": "2.x", "rc-motion": "^2.4.3", "rc-overflow": "^1.2.8", "rc-trigger": "^5.1.2", - "rc-util": "^5.12.0", - "shallowequal": "^1.1.0" + "rc-util": "^5.27.0" }, "peerDependencies": { "react": ">=16.9.0", @@ -9996,9 +9995,9 @@ } }, "node_modules/rc-motion": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.6.2.tgz", - "integrity": "sha512-4w1FaX3dtV749P8GwfS4fYnFG4Rb9pxvCYPc/b2fw1cmlHJWNNgOFIz7ysiD+eOrzJSvnLJWlNQQncpNMXwwpg==", + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.6.3.tgz", + "integrity": "sha512-xFLkes3/7VL/J+ah9jJruEW/Akbx5F6jVa2wG5o/ApGKQKSOd5FR3rseHLL9+xtJg4PmCwo6/1tqhDO/T+jFHA==", "dependencies": { "@babel/runtime": "^7.11.1", "classnames": "^2.2.1", @@ -10109,13 +10108,13 @@ } }, "node_modules/rc-resize-observer": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.2.0.tgz", - "integrity": "sha512-6W+UzT3PyDM0wVCEHfoW3qTHPTvbdSgiA43buiy8PzmeMnfgnDeb9NjdimMXMl3/TcrvvWl5RRVdp+NqcR47pQ==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.2.1.tgz", + "integrity": "sha512-g53PnWLeVOmt4XWkt2x+QlIdf/PhJSd7JqHhtMrUY370e7wJ+kxbgXicYqvENUcgFiiOiMCd07YsC2GNsoSbnA==", "dependencies": { - "@babel/runtime": "^7.10.1", + "@babel/runtime": "^7.20.7", "classnames": "^2.2.1", - "rc-util": "^5.15.0", + "rc-util": "^5.27.0", "resize-observer-polyfill": "^1.5.1" }, "peerDependencies": { @@ -10123,6 +10122,17 @@ "react-dom": ">=16.9.0" } }, + "node_modules/rc-resize-observer/node_modules/@babel/runtime": { + "version": "7.20.13", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.13.tgz", + "integrity": "sha512-gt3PKXs0DBoL9xCvOIIZ2NEqAGZqHjAnmVbfQtB620V0uReIQutpel14KcneZuer7UioY8ALKZ7iocavvzTNFA==", + "dependencies": { + "regenerator-runtime": "^0.13.11" + }, + "engines": { + "node": ">=6.9.0" + } + }, "node_modules/rc-segmented": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/rc-segmented/-/rc-segmented-2.1.0.tgz", @@ -10228,9 +10238,9 @@ } }, "node_modules/rc-tabs": { - "version": "12.4.2", - "resolved": "https://registry.npmjs.org/rc-tabs/-/rc-tabs-12.4.2.tgz", - "integrity": "sha512-FFlGwuTjQUznWzJtyhmHc6KAp5lRQFxKUv9Aj1UtsOYe2e7WGmuzcrd+/LQchuPe0VjhaZPdGkmFGcqGqNO6ow==", + "version": "12.5.6", + "resolved": "https://registry.npmjs.org/rc-tabs/-/rc-tabs-12.5.6.tgz", + "integrity": "sha512-aArXHzxK7YICxe+622CZ8FlO5coMi8P7E6tXpseCPKm1gdTjUt0LrQK1/AxcrRXZXG3K4QqhlKmET0+cX5DQaQ==", "dependencies": { "@babel/runtime": "^7.11.2", "classnames": "2.x", @@ -10347,9 +10357,9 @@ } }, "node_modules/rc-util": { - "version": "5.27.0", - "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.27.0.tgz", - "integrity": "sha512-lk9HnxVWdpGzkqs6OpZ+xxAHBefqy6+wT5LjSeBoaxzE0j5Tpq0Mf4TMc29B+Z0QP81yDvfgvp1O8oBxj70kEg==", + "version": "5.27.1", + "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.27.1.tgz", + "integrity": "sha512-PsjHA+f+KBCz+YTZxrl3ukJU5RoNKoe3KSNMh0xGiISbR67NaM9E9BiMjCwxa3AcCUOg/rZ+V0ZKLSimAA+e3w==", "dependencies": { "@babel/runtime": "^7.18.3", "react-is": "^16.12.0" @@ -10383,9 +10393,9 @@ } }, "node_modules/rc-virtual-list/node_modules/@babel/runtime": { - "version": "7.20.7", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.7.tgz", - "integrity": "sha512-UF0tvkUtxwAgZ5W/KrkHf0Rn0fdnLDU9ScxBrEVNUprE/MzirjK4MJUX1/BVDv00Sv8cljtukVK1aky++X1SjQ==", + "version": "7.20.13", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.13.tgz", + "integrity": "sha512-gt3PKXs0DBoL9xCvOIIZ2NEqAGZqHjAnmVbfQtB620V0uReIQutpel14KcneZuer7UioY8ALKZ7iocavvzTNFA==", "dependencies": { "regenerator-runtime": "^0.13.11" }, @@ -14641,13 +14651,13 @@ } }, "@xkit-yx/chat-kit-ui": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/chat-kit-ui/-/chat-kit-ui-0.5.1.tgz", - "integrity": "sha512-Ma2ALiltf/WuLo468NZJFcTtilXBC2tZhiljX3TORVXH6UH9qoL3rkxkthbyCM807vnVkeCOqT9ZdhFEu9GKAQ==", + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/chat-kit-ui/-/chat-kit-ui-0.6.1.tgz", + "integrity": "sha512-DMrHqvE87uUL8YfSlIV6UvZS0nnRItLUIaR2YbU/OP3P2V6zOY3GwxVg8pspUBtiCOiUuzhtwa8h9sM5ZF/fKg==", "requires": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2", @@ -14655,12 +14665,12 @@ } }, "@xkit-yx/common-ui": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/common-ui/-/common-ui-0.5.1.tgz", - "integrity": "sha512-7U01KDM3gNE1SyhCUmtFTNcj2UeFlsuWjUU1jvuHZbK182ROmjkaY7qDWbu/zHNY3iyMYUy4O6TLhnzKiz5CTg==", + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/common-ui/-/common-ui-0.6.1.tgz", + "integrity": "sha512-EfmRzNRyNARtHH6IkP9JlB3WIpWSKbTdEnOnv4kvArJfK9tZBsWN3MDRbTvZ/CiDxxbdvg/5qq5ha2DHUpTJBg==", "requires": { - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2", @@ -14668,36 +14678,36 @@ } }, "@xkit-yx/contact-kit-ui": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/contact-kit-ui/-/contact-kit-ui-0.3.1.tgz", - "integrity": "sha512-Y88CGslikOZ//BdB7kTwG/yHXmzFN7F1dInCMD/3JgAkKwjyugaKvr6JjKD7gMI6CEnrciX3OA8G6WTaYY1pcA==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/contact-kit-ui/-/contact-kit-ui-0.4.1.tgz", + "integrity": "sha512-Lk+qTsWp9lCVzx0lic2B/DrqSJg5xMDE+PENKs0w1XgEOe5cSr48UD1RkftcbpIbmRV+GNx7Xk6fh/4eIdvjZw==", "requires": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" } }, "@xkit-yx/conversation-kit-ui": { - "version": "0.3.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/conversation-kit-ui/-/conversation-kit-ui-0.3.1.tgz", - "integrity": "sha512-01OXeBhOdIqAZd0r5+IsncDkoWa8xubEeybjNlAMzsijld/c/FiqNyqIHEIAOz4Z8tszr/r9bE0OyTEQoSZiJA==", + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@xkit-yx/conversation-kit-ui/-/conversation-kit-ui-0.3.3.tgz", + "integrity": "sha512-rV/d5X/rpFw5Y+EBm95VnOA+S50GeorMR2HBGR1XYbzAFngFKd1AQrlS9f3ORfZAVene2BiFJqkO168IDeN8VQ==", "requires": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" } }, "@xkit-yx/core-kit": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@xkit-yx/core-kit/-/core-kit-0.7.0.tgz", - "integrity": "sha512-6PlJUKcuZUnAe9glWM1dcZ3hXxC+htNa1yM76DQqGIlwPDFaP38QDCgQziH0OLvf/bSTaWkijdUR7HAoaV5xpg==", + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@xkit-yx/core-kit/-/core-kit-0.8.0.tgz", + "integrity": "sha512-fQOM0LtXB4jDWRB6/ZmzPvDSrBUE++UvvLe79l6AvvUaPOpE688m1EqD8yfWNZgRtHH471VHQPQo20FLk9Mvtg==", "requires": { "@scaret/nertc-web-sdk": "4.6.252", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/utils": "^0.5.0", "@yxim/nim-web-sdk": "9.6.3", "axios": "^0.27.2", "eventemitter3": "^4.0.7", @@ -14706,39 +14716,39 @@ } }, "@xkit-yx/im-kit-ui": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/@xkit-yx/im-kit-ui/-/im-kit-ui-0.2.3.tgz", - "integrity": "sha512-hkjgS+3Jkbe83wSCLZzoS5le/lxOcUPiU7P6Q59tCeTdp8knjbMKjH3uVFxAe6J0s2dJWIYoIv6lag3WUhhC4w==", - "requires": { - "@xkit-yx/chat-kit-ui": "^0.5.1", - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/contact-kit-ui": "^0.3.1", - "@xkit-yx/conversation-kit-ui": "^0.3.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/search-kit-ui": "^0.4.1", - "@xkit-yx/utils": "^0.4.5", + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/im-kit-ui/-/im-kit-ui-0.3.1.tgz", + "integrity": "sha512-4VUgYkmgf+9Jcj9S6ncQDzBTsXgrU6+kj5GO5Z7FSmLLaaRHxzEmIbE5QQ20zuBWzzphOvDpyjyumOZRAr/Xhw==", + "requires": { + "@xkit-yx/chat-kit-ui": "^0.6.1", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/contact-kit-ui": "^0.4.1", + "@xkit-yx/conversation-kit-ui": "^0.3.3", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/search-kit-ui": "^0.5.1", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" } }, "@xkit-yx/search-kit-ui": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@xkit-yx/search-kit-ui/-/search-kit-ui-0.4.1.tgz", - "integrity": "sha512-k5wSLyhYTchTEvFq1K5Py0vXPRewiRWGZv/GpGwcD5UXO6Bvc/A/2Si6t2bCWyClBUS3Wgvwn0+xUUiIfCwnHA==", + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/@xkit-yx/search-kit-ui/-/search-kit-ui-0.5.1.tgz", + "integrity": "sha512-16i+g3ab/Im+M5CgKBelUjBEJ30IHq8TVC64p8gN/DQ8140Nl0BTOlESnjLt2qXDe3FV3tG3kaMbEGy97Q6TIg==", "requires": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2" } }, "@xkit-yx/utils": { - "version": "0.4.5", - "resolved": "https://registry.npmjs.org/@xkit-yx/utils/-/utils-0.4.5.tgz", - "integrity": "sha512-kdG4ywGUQicsTRRwg2E8xqHROf6VC0qlkwEOTDiVxMi4tteqS4I1qR27i5V7cnpu0n/dOFrsnC7QPL2lzdVmmg==", + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@xkit-yx/utils/-/utils-0.5.0.tgz", + "integrity": "sha512-dzDVY0qrQXh1zbzhDN/gAfNbZ5shW33YRqeoXkE064Nwu6HT6ORFETzai1rn9bVf7uDfcOr2FdULXlvsKAj6LA==", "requires": { "axios": "^0.27.2", "eventemitter3": "^4.0.7" @@ -14872,9 +14882,9 @@ } }, "antd": { - "version": "4.24.6", - "resolved": "https://registry.npmjs.org/antd/-/antd-4.24.6.tgz", - "integrity": "sha512-x4tTXI3aOJukcG/MWQ7PdWHIqGEFInkKPhSHJpSiDvZI5BAvgLicW57WWhnBpJ6m9H9e9FRohC5FRJf0NIwsWQ==", + "version": "4.24.7", + "resolved": "https://registry.npmjs.org/antd/-/antd-4.24.7.tgz", + "integrity": "sha512-Qr3AYkeqpd3i/c6M7pjca7Y6XlaIv/p6gD3aqe7/0o8Ueg50G7Aeh+TOaiUfXLGDhnVoNEdaVdDiv8aIaoWB5A==", "requires": { "@ant-design/colors": "^6.0.0", "@ant-design/icons": "^4.7.0", @@ -14910,7 +14920,7 @@ "rc-steps": "~5.0.0-alpha.2", "rc-switch": "~3.2.0", "rc-table": "~7.26.0", - "rc-tabs": "~12.4.1", + "rc-tabs": "~12.5.0", "rc-textarea": "~0.4.5", "rc-tooltip": "~5.2.0", "rc-tree": "~5.7.0", @@ -19626,23 +19636,22 @@ } }, "rc-menu": { - "version": "9.8.1", - "resolved": "https://registry.npmjs.org/rc-menu/-/rc-menu-9.8.1.tgz", - "integrity": "sha512-179weouypfjWJSRvvoo/vPy+StojsMzK2XC5jRNhL1ryt/N/8wAFESte8K6jZJkNp9DHDLFTe+dCGmikKpiFuA==", + "version": "9.8.2", + "resolved": "https://registry.npmjs.org/rc-menu/-/rc-menu-9.8.2.tgz", + "integrity": "sha512-EahOJVjLuEnJsThoPN+mGnVm431RzVzDLZWHRS/YnXTQULa7OsgdJa/Y7qXxc3Z5sz8mgT6xYtgpmBXLxrZFaQ==", "requires": { "@babel/runtime": "^7.10.1", "classnames": "2.x", "rc-motion": "^2.4.3", "rc-overflow": "^1.2.8", "rc-trigger": "^5.1.2", - "rc-util": "^5.12.0", - "shallowequal": "^1.1.0" + "rc-util": "^5.27.0" } }, "rc-motion": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.6.2.tgz", - "integrity": "sha512-4w1FaX3dtV749P8GwfS4fYnFG4Rb9pxvCYPc/b2fw1cmlHJWNNgOFIz7ysiD+eOrzJSvnLJWlNQQncpNMXwwpg==", + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/rc-motion/-/rc-motion-2.6.3.tgz", + "integrity": "sha512-xFLkes3/7VL/J+ah9jJruEW/Akbx5F6jVa2wG5o/ApGKQKSOd5FR3rseHLL9+xtJg4PmCwo6/1tqhDO/T+jFHA==", "requires": { "@babel/runtime": "^7.11.1", "classnames": "^2.2.1", @@ -19716,14 +19725,24 @@ } }, "rc-resize-observer": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.2.0.tgz", - "integrity": "sha512-6W+UzT3PyDM0wVCEHfoW3qTHPTvbdSgiA43buiy8PzmeMnfgnDeb9NjdimMXMl3/TcrvvWl5RRVdp+NqcR47pQ==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/rc-resize-observer/-/rc-resize-observer-1.2.1.tgz", + "integrity": "sha512-g53PnWLeVOmt4XWkt2x+QlIdf/PhJSd7JqHhtMrUY370e7wJ+kxbgXicYqvENUcgFiiOiMCd07YsC2GNsoSbnA==", "requires": { - "@babel/runtime": "^7.10.1", + "@babel/runtime": "^7.20.7", "classnames": "^2.2.1", - "rc-util": "^5.15.0", + "rc-util": "^5.27.0", "resize-observer-polyfill": "^1.5.1" + }, + "dependencies": { + "@babel/runtime": { + "version": "7.20.13", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.13.tgz", + "integrity": "sha512-gt3PKXs0DBoL9xCvOIIZ2NEqAGZqHjAnmVbfQtB620V0uReIQutpel14KcneZuer7UioY8ALKZ7iocavvzTNFA==", + "requires": { + "regenerator-runtime": "^0.13.11" + } + } } }, "rc-segmented": { @@ -19795,9 +19814,9 @@ } }, "rc-tabs": { - "version": "12.4.2", - "resolved": "https://registry.npmjs.org/rc-tabs/-/rc-tabs-12.4.2.tgz", - "integrity": "sha512-FFlGwuTjQUznWzJtyhmHc6KAp5lRQFxKUv9Aj1UtsOYe2e7WGmuzcrd+/LQchuPe0VjhaZPdGkmFGcqGqNO6ow==", + "version": "12.5.6", + "resolved": "https://registry.npmjs.org/rc-tabs/-/rc-tabs-12.5.6.tgz", + "integrity": "sha512-aArXHzxK7YICxe+622CZ8FlO5coMi8P7E6tXpseCPKm1gdTjUt0LrQK1/AxcrRXZXG3K4QqhlKmET0+cX5DQaQ==", "requires": { "@babel/runtime": "^7.11.2", "classnames": "2.x", @@ -19877,9 +19896,9 @@ } }, "rc-util": { - "version": "5.27.0", - "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.27.0.tgz", - "integrity": "sha512-lk9HnxVWdpGzkqs6OpZ+xxAHBefqy6+wT5LjSeBoaxzE0j5Tpq0Mf4TMc29B+Z0QP81yDvfgvp1O8oBxj70kEg==", + "version": "5.27.1", + "resolved": "https://registry.npmjs.org/rc-util/-/rc-util-5.27.1.tgz", + "integrity": "sha512-PsjHA+f+KBCz+YTZxrl3ukJU5RoNKoe3KSNMh0xGiISbR67NaM9E9BiMjCwxa3AcCUOg/rZ+V0ZKLSimAA+e3w==", "requires": { "@babel/runtime": "^7.18.3", "react-is": "^16.12.0" @@ -19904,9 +19923,9 @@ }, "dependencies": { "@babel/runtime": { - "version": "7.20.7", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.7.tgz", - "integrity": "sha512-UF0tvkUtxwAgZ5W/KrkHf0Rn0fdnLDU9ScxBrEVNUprE/MzirjK4MJUX1/BVDv00Sv8cljtukVK1aky++X1SjQ==", + "version": "7.20.13", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.20.13.tgz", + "integrity": "sha512-gt3PKXs0DBoL9xCvOIIZ2NEqAGZqHjAnmVbfQtB620V0uReIQutpel14KcneZuer7UioY8ALKZ7iocavvzTNFA==", "requires": { "regenerator-runtime": "^0.13.11" } diff --git a/react/package.json b/react/package.json index 03295d6..0ba42a8 100644 --- a/react/package.json +++ b/react/package.json @@ -9,7 +9,7 @@ "start": "npm run dev" }, "dependencies": { - "@xkit-yx/im-kit-ui": "^0.2.3", + "@xkit-yx/im-kit-ui": "^0.3.1", "umi": "^4.0.40" }, "devDependencies": { diff --git a/react/src/YXUIKit/chat-kit-ui/package.json b/react/src/YXUIKit/chat-kit-ui/package.json index b2e28a4..1c251c1 100644 --- a/react/src/YXUIKit/chat-kit-ui/package.json +++ b/react/src/YXUIKit/chat-kit-ui/package.json @@ -1,6 +1,6 @@ { "name": "@xkit-yx/chat-kit-ui", - "version": "0.5.1", + "version": "0.6.1", "description": "聊天组件", "license": "MIT", "main": "lib/index.js", @@ -55,13 +55,13 @@ "react-string-replace": "^1.1.0" }, "dependencies": { - "@xkit-yx/common-ui": "^0.5.1", - "@xkit-yx/core-kit": "^0.7.0", - "@xkit-yx/utils": "^0.4.5", + "@xkit-yx/common-ui": "^0.6.1", + "@xkit-yx/core-kit": "^0.8.0", + "@xkit-yx/utils": "^0.5.0", "antd": "^4.16.3", "mobx": "^6.6.1", "mobx-react": "^7.5.2", "react-string-replace": "^1.1.0" }, - "gitHead": "7e7dcfd37b7b3cf860cad94a21cc22cdc9cd5957" + "gitHead": "e49d831a053536bb2a91ce0b9d8599d9c5cb755b" } diff --git a/react/src/YXUIKit/chat-kit-ui/src/Container.tsx b/react/src/YXUIKit/chat-kit-ui/src/Container.tsx index c830201..46c1b39 100644 --- a/react/src/YXUIKit/chat-kit-ui/src/Container.tsx +++ b/react/src/YXUIKit/chat-kit-ui/src/Container.tsx @@ -1,7 +1,12 @@ import React, { ReactNode } from 'react' import P2pChatContainer from './containers/p2pChatContainer' import TeamChatContainer from './containers/teamChatContainer' -import { useStateContext, useEventTracking, Welcome } from '../../common-ui/src' +import { + useStateContext, + useEventTracking, + Welcome, + Utils, +} from '../../common-ui/src' import { TMsgScene } from 'nim-web-sdk-ng/dist/NIM_BROWSER_SDK/MsgServiceInterface' import { RenderP2pCustomMessageOptions } from './components/ChatP2pMessageList' import { RenderTeamCustomMessageOptions } from './components/ChatTeamMessageList' @@ -12,6 +17,7 @@ import { observer } from 'mobx-react' import packageJson from '../package.json' import { TeamMember } from 'nim-web-sdk-ng/dist/NIM_BROWSER_SDK/TeamServiceInterface' import { FriendProfile } from 'nim-web-sdk-ng/dist/NIM_BROWSER_SDK/FriendServiceInterface' +import { GroupItemProps } from './components/ChatTeamSetting/GroupItem' export interface ActionRenderProps extends ChatMessageInputProps { scene: TMsgScene @@ -42,6 +48,14 @@ export interface ChatContainerProps { 消息发送按钮组配置,不传使用默认的配置 */ actions?: Action[] + /** + 是否需要显示 p2p 消息已读未读,默认 false + */ + p2pMsgReceiptVisible?: boolean + /** + 是否需要显示群组消息已读未读,默认 false + */ + teamMsgReceiptVisible?: boolean /** 发送文字消息的回调,一般用于默认的文字发送缺少想要的字段时 */ @@ -84,9 +98,9 @@ export interface ChatContainerProps { /** 自定义渲染群组成员 item */ - renderTeamMemberItem?: (params: { - member: TeamMember & Partial - }) => JSX.Element | null | undefined + renderTeamMemberItem?: ( + params: GroupItemProps + ) => JSX.Element | null | undefined /** 样式前缀 */ @@ -101,6 +115,8 @@ export const ChatContainer: React.FC = observer( ({ selectedSession, actions, + p2pMsgReceiptVisible = false, + teamMsgReceiptVisible = false, onSendText, renderEmpty, renderP2pCustomMessage, @@ -108,6 +124,7 @@ export const ChatContainer: React.FC = observer( renderHeader, renderP2pInputPlaceHolder, renderTeamInputPlaceHolder, + renderTeamMemberItem, prefix = 'chat', commonPrefix = 'common', @@ -117,9 +134,7 @@ export const ChatContainer: React.FC = observer( const finalSelectedSession = selectedSession || store.uiStore.selectedSession || '' - const scene = finalSelectedSession.split('-')[0] as TMsgScene - - const to = finalSelectedSession.split('-')[1] + const { scene, to } = Utils.parseSessionId(finalSelectedSession) useEventTracking({ appkey: initOptions.appkey, @@ -135,6 +150,7 @@ export const ChatContainer: React.FC = observer( commonPrefix={commonPrefix} scene={scene} to={to} + p2pMsgReceiptVisible={p2pMsgReceiptVisible} onSendText={onSendText} actions={actions} renderP2pCustomMessage={renderP2pCustomMessage} @@ -147,11 +163,13 @@ export const ChatContainer: React.FC = observer( commonPrefix={commonPrefix} scene={scene} to={to} + teamMsgReceiptVisible={teamMsgReceiptVisible} onSendText={onSendText} actions={actions} renderTeamCustomMessage={renderTeamCustomMessage} renderHeader={renderHeader} renderTeamInputPlaceHolder={renderTeamInputPlaceHolder} + renderTeamMemberItem={renderTeamMemberItem} /> ) : null ) : renderEmpty ? ( diff --git a/react/src/YXUIKit/chat-kit-ui/src/components/ChatCreateTeam/index.tsx b/react/src/YXUIKit/chat-kit-ui/src/components/ChatCreateTeam/index.tsx index 1aad9ef..0b6e3c2 100644 --- a/react/src/YXUIKit/chat-kit-ui/src/components/ChatCreateTeam/index.tsx +++ b/react/src/YXUIKit/chat-kit-ui/src/components/ChatCreateTeam/index.tsx @@ -57,6 +57,7 @@ const GroupCreate: React.FC = ({ ...values, selectedAccounts, avatar, + name: values.name.trim(), }) resetState() }) @@ -89,7 +90,7 @@ const GroupCreate: React.FC = ({ cancelText={t('cancelText')} okText={t('createButtonText')} > -
+ void onSendFile: (file: File) => void onSendImg: (file: File) => void + onRemoveReplyMsg?: () => void } const mergeActions = ( @@ -40,27 +51,32 @@ const mergeActions = ( }) } -const ChatMessageInput: React.FC = (props) => { +const ChatMessageInput: React.FC = observer((props) => { const { prefix = 'chat', placeholder = '', actions, + scene, + to, mute = false, inputValue = '', uploadImageLoading = false, uploadFileLoading = false, + replyMsg, setInputValue, onSendText, onSendFile, onSendImg, + onRemoveReplyMsg, } = props const { t } = useTranslation() + const { store } = useStateContext() const _prefix = `${prefix}-message-input` const inputRef = useRef(null) const [visible, setVisible] = useState(false) const antIcon = - + const { EMOJI_ICON_MAP_CONFIG } = Utils.handleEmojiTranslate(t) const defaultActions: Action[] = [ { action: 'emoji', @@ -205,7 +221,7 @@ const ChatMessageInput: React.FC = (props) => { const emojiContent = ( <> - {Object.keys(Constant.EMOJI_ICON_MAP_CONFIG).map((tag: string, index) => ( + {Object.keys(EMOJI_ICON_MAP_CONFIG).map((tag: string, index) => ( { onEmojiClickHandler(tag) @@ -216,13 +232,22 @@ const ChatMessageInput: React.FC = (props) => { > ))} ) + const replyMsgContent = () => { + let content = `${t('replyText')} ${store.uiStore.getAppellation({ + account: replyMsg?.from || '', + teamId: scene === 'team' ? to : '', + })}:` + content += replyMsg ? getMsgContentTipByType(replyMsg, t) : '' + return
{content}
+ } + // const isMute = useMemo(() => { // return (teamInfo as ITeamInfo).mute && !isGroupOwner && !isGroupManager // }, [teamInfo, isGroupOwner, isGroupManager]) @@ -230,30 +255,39 @@ const ChatMessageInput: React.FC = (props) => { return (
-