@tencentcloud/chat-uikit-react 2.2.3 → 2.2.5

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 (164) hide show
  1. package/.babelrc +2 -2
  2. package/.editorconfig +16 -0
  3. package/.eslintrc.js +225 -48
  4. package/.husky/pre-commit +4 -0
  5. package/.lintstagedrc.json +6 -0
  6. package/.stylelintrc.js +40 -0
  7. package/CHANGELOG.md +14 -0
  8. package/README.md +8 -8
  9. package/dist/cjs/assets/fonts/iconfont.ttf +0 -0
  10. package/dist/cjs/assets/fonts/iconfont.woff +0 -0
  11. package/dist/cjs/assets/fonts/iconfont.woff2 +0 -0
  12. package/dist/cjs/components/ConversationPreview/ConversationPreviewContent.js +1 -1
  13. package/dist/cjs/components/ConversationPreview/utils.js +1 -1
  14. package/dist/cjs/components/DivWithEdit/WithText.js +1 -1
  15. package/dist/cjs/components/Input/Input.js +1 -1
  16. package/dist/cjs/components/Plugins/index.js +1 -1
  17. package/dist/cjs/components/TUIKit/TUIKit.js +1 -1
  18. package/dist/cjs/components/TUIMessage/utils/emojiMap.js +1 -1
  19. package/dist/cjs/components/TUIMessageInput/TUIMessageInputDefault.js +1 -1
  20. package/dist/cjs/components/TUIMessageInput/hooks/useEmojiPicker.js +1 -1
  21. package/dist/cjs/components/TUIMessageInput/hooks/useMessageInputText.js +1 -1
  22. package/dist/cjs/components/TUIMessageList/TUIMessageList.js +1 -1
  23. package/dist/cjs/components/untils.js +1 -1
  24. package/dist/cjs/context/TUIKitContext.js +1 -1
  25. package/dist/cjs/index.css +2 -1
  26. package/dist/cjs/index.d.css +646 -172
  27. package/dist/cjs/index.d.ts +1 -1
  28. package/dist/cjs/index.js +1 -1
  29. package/dist/cjs/locales/en-US/index.js +1 -0
  30. package/dist/cjs/locales/index.js +1 -1
  31. package/dist/cjs/locales/ja-JP/TUIChat.js +1 -0
  32. package/dist/cjs/locales/ja-JP/TUIContact.js +1 -0
  33. package/dist/cjs/locales/ja-JP/TUIConversation.js +1 -0
  34. package/dist/cjs/locales/ja-JP/TUIProfile.js +1 -0
  35. package/dist/cjs/locales/ja-JP/index.js +1 -0
  36. package/dist/cjs/locales/ko-KR/TUIChat.js +1 -0
  37. package/dist/cjs/locales/ko-KR/TUIContact.js +1 -0
  38. package/dist/cjs/locales/ko-KR/TUIConversation.js +1 -0
  39. package/dist/cjs/locales/ko-KR/TUIProfile.js +1 -0
  40. package/dist/cjs/locales/ko-KR/index.js +1 -0
  41. package/dist/cjs/utils/env.d.ts +4 -3
  42. package/dist/cjs/utils/env.js +1 -1
  43. package/dist/esm/assets/fonts/iconfont.ttf +0 -0
  44. package/dist/esm/assets/fonts/iconfont.woff +0 -0
  45. package/dist/esm/assets/fonts/iconfont.woff2 +0 -0
  46. package/dist/esm/components/ConversationPreview/ConversationPreviewContent.js +1 -1
  47. package/dist/esm/components/ConversationPreview/utils.js +1 -1
  48. package/dist/esm/components/DivWithEdit/WithText.js +1 -1
  49. package/dist/esm/components/Input/Input.js +1 -1
  50. package/dist/esm/components/Plugins/index.js +1 -1
  51. package/dist/esm/components/TUIKit/TUIKit.js +1 -1
  52. package/dist/esm/components/TUIMessage/utils/emojiMap.js +1 -1
  53. package/dist/esm/components/TUIMessageInput/TUIMessageInputDefault.js +1 -1
  54. package/dist/esm/components/TUIMessageInput/hooks/useEmojiPicker.js +1 -1
  55. package/dist/esm/components/TUIMessageInput/hooks/useMessageInputText.js +1 -1
  56. package/dist/esm/components/TUIMessageList/TUIMessageList.js +1 -1
  57. package/dist/esm/components/untils.js +1 -1
  58. package/dist/esm/context/TUIKitContext.js +1 -1
  59. package/dist/esm/index.css +2 -1
  60. package/dist/esm/index.d.css +646 -172
  61. package/dist/esm/index.d.ts +1 -1
  62. package/dist/esm/index.js +1 -1
  63. package/dist/esm/locales/en-US/index.js +1 -0
  64. package/dist/esm/locales/index.js +1 -1
  65. package/dist/esm/locales/ja-JP/TUIChat.js +1 -0
  66. package/dist/esm/locales/ja-JP/TUIContact.js +1 -0
  67. package/dist/esm/locales/ja-JP/TUIConversation.js +1 -0
  68. package/dist/esm/locales/ja-JP/TUIProfile.js +1 -0
  69. package/dist/esm/locales/ja-JP/index.js +1 -0
  70. package/dist/esm/locales/ko-KR/TUIChat.js +1 -0
  71. package/dist/esm/locales/ko-KR/TUIContact.js +1 -0
  72. package/dist/esm/locales/ko-KR/TUIConversation.js +1 -0
  73. package/dist/esm/locales/ko-KR/TUIProfile.js +1 -0
  74. package/dist/esm/locales/ko-KR/index.js +1 -0
  75. package/dist/esm/utils/env.d.ts +4 -3
  76. package/dist/esm/utils/env.js +1 -1
  77. package/package.json +22 -16
  78. package/rollup.config.js +40 -25
  79. package/src/assets/fonts/iconfont.ttf +0 -0
  80. package/src/assets/fonts/iconfont.woff +0 -0
  81. package/src/assets/fonts/iconfont.woff2 +0 -0
  82. package/src/components/ConversationCreate/styles/ConversationCreatGroupDetail.scss +16 -7
  83. package/src/components/ConversationCreate/styles/index.scss +23 -13
  84. package/src/components/ConversationPreview/ConversationPreviewContent.tsx +1 -2
  85. package/src/components/ConversationPreview/styles/index.scss +47 -19
  86. package/src/components/ConversationPreview/utils.tsx +37 -29
  87. package/src/components/DivWithEdit/WithText.tsx +4 -2
  88. package/src/components/Input/Input.tsx +3 -1
  89. package/src/components/Input/styles/index.scss +7 -5
  90. package/src/components/Model/styles/layout.scss +3 -3
  91. package/src/components/Plugins/styles/color.scss +17 -3
  92. package/src/components/Popup/styles/layout.scss +2 -1
  93. package/src/components/TUIChatHeader/styles/layout.scss +13 -2
  94. package/src/components/TUIConversationList/index.scss +26 -9
  95. package/src/components/TUIKit/TUIKit.tsx +4 -3
  96. package/src/components/TUIKit/styles/index.scss +27 -7
  97. package/src/components/TUIManage/styles/index.scss +20 -10
  98. package/src/components/TUIMessage/styles/color.scss +20 -9
  99. package/src/components/TUIMessage/styles/layout.scss +44 -11
  100. package/src/components/TUIMessage/utils/emojiMap.ts +1 -1
  101. package/src/components/TUIMessageInput/TUIMessageInputDefault.tsx +3 -1
  102. package/src/components/TUIMessageInput/hooks/useEmojiPicker.tsx +1 -1
  103. package/src/components/TUIMessageInput/hooks/useMessageInputText.tsx +3 -1
  104. package/src/components/TUIMessageInput/styles/color.scss +25 -6
  105. package/src/components/TUIMessageInput/styles/layout.scss +58 -16
  106. package/src/components/TUIMessageList/TUIMessageList.tsx +17 -10
  107. package/src/components/TUIMessageList/styles/layout.scss +16 -2
  108. package/src/components/TUIProfile/styles/layout.scss +33 -16
  109. package/src/components/untils.ts +13 -17
  110. package/src/context/TUIKitContext.tsx +6 -1
  111. package/src/locales/en-US/TUIGlobal.ts +6 -0
  112. package/src/locales/en-US/index.ts +14 -0
  113. package/src/locales/index.ts +15 -7
  114. package/src/locales/ja-JP/TUIChat.ts +27 -0
  115. package/src/locales/ja-JP/TUIContact.ts +30 -0
  116. package/src/locales/ja-JP/TUIConversation.ts +33 -0
  117. package/src/locales/ja-JP/TUIGlobal.ts +6 -0
  118. package/src/locales/ja-JP/TUIProfile.ts +15 -0
  119. package/src/locales/{en → ja-JP}/index.ts +0 -2
  120. package/src/locales/ko-KR/TUIChat.ts +27 -0
  121. package/src/locales/ko-KR/TUIContact.ts +30 -0
  122. package/src/locales/ko-KR/TUIConversation.ts +33 -0
  123. package/src/locales/ko-KR/TUIGlobal.ts +6 -0
  124. package/src/locales/ko-KR/TUIProfile.ts +15 -0
  125. package/src/locales/ko-KR/index.ts +11 -0
  126. package/src/locales/zh-CN/TUIGlobal.ts +6 -0
  127. package/src/styles/colors/_color-dark.scss +35 -0
  128. package/src/styles/colors/_color-light.scss +35 -0
  129. package/src/styles/colors/_color-theme.scss +54 -0
  130. package/src/styles/fonts/icon-font.scss +18 -0
  131. package/src/styles/index.scss +4 -0
  132. package/src/styles/normalize.scss +355 -0
  133. package/src/utils/env.ts +7 -2
  134. package/tsconfig.json +1 -0
  135. package/dist/cjs/locales/en/index.js +0 -1
  136. package/dist/esm/locales/en/index.js +0 -1
  137. package/src/components/TUIKit/styles/reset.scss +0 -67
  138. /package/dist/cjs/locales/{en → en-US}/TUIChat.js +0 -0
  139. /package/dist/cjs/locales/{en → en-US}/TUIContact.js +0 -0
  140. /package/dist/cjs/locales/{en → en-US}/TUIConversation.js +0 -0
  141. /package/dist/cjs/locales/{en → en-US}/TUIProfile.js +0 -0
  142. /package/dist/cjs/locales/{zh_cn → zh-CN}/TUIChat.js +0 -0
  143. /package/dist/cjs/locales/{zh_cn → zh-CN}/TUIContact.js +0 -0
  144. /package/dist/cjs/locales/{zh_cn → zh-CN}/TUIConversation.js +0 -0
  145. /package/dist/cjs/locales/{zh_cn → zh-CN}/TUIProfile.js +0 -0
  146. /package/dist/cjs/locales/{zh_cn → zh-CN}/index.js +0 -0
  147. /package/dist/esm/locales/{en → en-US}/TUIChat.js +0 -0
  148. /package/dist/esm/locales/{en → en-US}/TUIContact.js +0 -0
  149. /package/dist/esm/locales/{en → en-US}/TUIConversation.js +0 -0
  150. /package/dist/esm/locales/{en → en-US}/TUIProfile.js +0 -0
  151. /package/dist/esm/locales/{zh_cn → zh-CN}/TUIChat.js +0 -0
  152. /package/dist/esm/locales/{zh_cn → zh-CN}/TUIContact.js +0 -0
  153. /package/dist/esm/locales/{zh_cn → zh-CN}/TUIConversation.js +0 -0
  154. /package/dist/esm/locales/{zh_cn → zh-CN}/TUIProfile.js +0 -0
  155. /package/dist/esm/locales/{zh_cn → zh-CN}/index.js +0 -0
  156. /package/src/locales/{en → en-US}/TUIChat.ts +0 -0
  157. /package/src/locales/{en → en-US}/TUIContact.ts +0 -0
  158. /package/src/locales/{en → en-US}/TUIConversation.ts +0 -0
  159. /package/src/locales/{en → en-US}/TUIProfile.ts +0 -0
  160. /package/src/locales/{zh_cn → zh-CN}/TUIChat.ts +0 -0
  161. /package/src/locales/{zh_cn → zh-CN}/TUIContact.ts +0 -0
  162. /package/src/locales/{zh_cn → zh-CN}/TUIConversation.ts +0 -0
  163. /package/src/locales/{zh_cn → zh-CN}/TUIProfile.ts +0 -0
  164. /package/src/locales/{zh_cn → zh-CN}/index.ts +0 -0
@@ -46,5 +46,5 @@ export { TUIContact, UnMemoizedTUIContact } from './components/TUIContact/TUICon
46
46
  export { CreateGroupConversationParams, useConversation } from './hooks/useConversation.js';
47
47
  export { useProfile } from './hooks/useProfile.js';
48
48
  export { t } from './locales/index.js';
49
- export { isH5, isPC } from './utils/env.js';
49
+ export { isH5, isPC, setPlatform } from './utils/env.js';
50
50
  export { default as i18next } from 'i18next';
package/dist/esm/index.js CHANGED
@@ -1 +1 @@
1
- import o from"./server.js";export{TUIKit}from"./components/TUIKit/TUIKit.js";export{useTUIKit}from"./components/TUIKit/hooks/useTUIKit.js";export{useCreateTUIKitContext}from"./components/TUIKit/hooks/useCreateTUIKitContext.js";export{TUIConversation,UnMemoizedTUIConversation}from"./components/TUIConversation/TUIConversation.js";export{TUIConversationList,UnMemoTUIConversationList}from"./components/TUIConversationList/TUIConversationList.js";import"react";import"@tencentcloud/chat";import"@tencentcloud/chat-uikit-engine";export{TUIChat}from"./components/TUIChat/TUIChat.js";import"tslib";export{ConversationPreview}from"./components/ConversationPreview/ConversationPreview.js";export{ConversationPreviewContent,unMemoConversationPreviewContent}from"./components/ConversationPreview/ConversationPreviewContent.js";export{TUIChatHeader}from"./components/TUIChatHeader/TUIChatHeader.js";export{TUIChatHeaderDefault}from"./components/TUIChatHeader/TUIChatHeaderDefault.js";export{TUIMessageList}from"./components/TUIMessageList/TUIMessageList.js";export{TUIMessage}from"./components/TUIMessage/TUIMessage.js";export{MessagePlugins}from"./components/TUIMessage/MessagePlugins.js";export{MessageContext}from"./components/TUIMessage/MessageContext.js";export{TUIMessageInput}from"./components/TUIMessageInput/TUIMessageInput.js";export{TUIMessageInputDefault}from"./components/TUIMessageInput/TUIMessageInputDefault.js";export{InputPluginsDefalut}from"./components/TUIMessageInput/InputPluginsDefalut.js";export{TUIProfile}from"./components/TUIProfile/TUIProfile.js";export{TUIProfileDefault}from"./components/TUIProfile/TUIProfileDefault.js";export{Avatar}from"./components/Avatar/Avatar.js";export{defaultGroupAvatarAVChatRoom,defaultGroupAvatarMeeting,defaultGroupAvatarPublic,defaultGroupAvatarWork,defaultUserAvatar}from"./components/Avatar/default.js";export{ConversationSearchInput}from"./components/ConversationSearch/ConversationSearchInput.js";export{ConversationSearchResult}from"./components/ConversationSearch/ConversationSearchResult.js";export{TUIManage}from"./components/TUIManage/TUIManage.js";export{Popup}from"./components/Popup/index.js";export{Checkbox}from"./components/Checkbox/index.js";export{DivWithEdit}from"./components/DivWithEdit/DivWithEdit.js";export{Icon,changeTypeToIconClassName}from"./components/Icon/Icon.js";export{IconTypes}from"./components/Icon/type.js";export{EmptyStateIndicator}from"./components/EmptyStateIndicator/EmptyStateIndicator.js";export{Input}from"./components/Input/Input.js";export{Model}from"./components/Model/index.js";export{Plugins}from"./components/Plugins/index.js";export{Switch}from"./components/Switch/Switch.js";export{Toast}from"./components/Toast/index.js";export{TUIContactList}from"./components/TUIContact/TUIContactList/TUIContactList.js";export{TUIContactInfo,UnMemoizedTUIContactInfo}from"./components/TUIContact/TUIContactInfo/TUIContactInfo.js";export{TUIContact,UnMemoizedTUIContact}from"./components/TUIContact/TUIContact.js";export{TUIKitContext,TUIKitProvider,useTUIKitContext}from"./context/TUIKitContext.js";export{TUIChatStateContext,TUIChatStateContextProvider,useTUIChatStateContext}from"./context/TUIChatStateContext.js";export{TUIChatActionContext,TUIChatActionProvider,useTUIChatActionContext}from"./context/TUIChatActionContext.js";export{TUIMessageContext,TUIMessageContextProvider,messageShowType,useTUIMessageContext}from"./context/TUIMessageContext.js";export{ComponentContext,ComponentProvider,useComponentContext}from"./context/ComponentContext.js";export{TUIMessageInputContext,TUIMessageInputContextProvider,useTUIMessageInputContext}from"./context/TUIMessageInputContext.js";export{TUIContactContext,TUIContactContextProvider,useTUIContactContext}from"./context/TUIContactContext.js";export{useConversation}from"./hooks/useConversation.js";export{useProfile}from"./hooks/useProfile.js";export{t}from"./locales/index.js";export{isH5,isPC}from"./utils/env.js";export{default as i18next}from"i18next";new o;
1
+ import o from"./server.js";export{TUIKit}from"./components/TUIKit/TUIKit.js";export{useTUIKit}from"./components/TUIKit/hooks/useTUIKit.js";export{useCreateTUIKitContext}from"./components/TUIKit/hooks/useCreateTUIKitContext.js";export{TUIConversation,UnMemoizedTUIConversation}from"./components/TUIConversation/TUIConversation.js";export{TUIConversationList,UnMemoTUIConversationList}from"./components/TUIConversationList/TUIConversationList.js";import"react";import"@tencentcloud/chat";import"@tencentcloud/chat-uikit-engine";export{TUIChat}from"./components/TUIChat/TUIChat.js";import"tslib";export{ConversationPreview}from"./components/ConversationPreview/ConversationPreview.js";export{ConversationPreviewContent,unMemoConversationPreviewContent}from"./components/ConversationPreview/ConversationPreviewContent.js";export{TUIChatHeader}from"./components/TUIChatHeader/TUIChatHeader.js";export{TUIChatHeaderDefault}from"./components/TUIChatHeader/TUIChatHeaderDefault.js";export{TUIMessageList}from"./components/TUIMessageList/TUIMessageList.js";export{TUIMessage}from"./components/TUIMessage/TUIMessage.js";export{MessagePlugins}from"./components/TUIMessage/MessagePlugins.js";export{MessageContext}from"./components/TUIMessage/MessageContext.js";export{TUIMessageInput}from"./components/TUIMessageInput/TUIMessageInput.js";export{TUIMessageInputDefault}from"./components/TUIMessageInput/TUIMessageInputDefault.js";export{InputPluginsDefalut}from"./components/TUIMessageInput/InputPluginsDefalut.js";export{TUIProfile}from"./components/TUIProfile/TUIProfile.js";export{TUIProfileDefault}from"./components/TUIProfile/TUIProfileDefault.js";export{Avatar}from"./components/Avatar/Avatar.js";export{defaultGroupAvatarAVChatRoom,defaultGroupAvatarMeeting,defaultGroupAvatarPublic,defaultGroupAvatarWork,defaultUserAvatar}from"./components/Avatar/default.js";export{ConversationSearchInput}from"./components/ConversationSearch/ConversationSearchInput.js";export{ConversationSearchResult}from"./components/ConversationSearch/ConversationSearchResult.js";export{TUIManage}from"./components/TUIManage/TUIManage.js";export{Popup}from"./components/Popup/index.js";export{Checkbox}from"./components/Checkbox/index.js";export{DivWithEdit}from"./components/DivWithEdit/DivWithEdit.js";export{Icon,changeTypeToIconClassName}from"./components/Icon/Icon.js";export{IconTypes}from"./components/Icon/type.js";export{EmptyStateIndicator}from"./components/EmptyStateIndicator/EmptyStateIndicator.js";export{Input}from"./components/Input/Input.js";export{Model}from"./components/Model/index.js";export{Plugins}from"./components/Plugins/index.js";export{Switch}from"./components/Switch/Switch.js";export{Toast}from"./components/Toast/index.js";export{TUIContactList}from"./components/TUIContact/TUIContactList/TUIContactList.js";export{TUIContactInfo,UnMemoizedTUIContactInfo}from"./components/TUIContact/TUIContactInfo/TUIContactInfo.js";export{TUIContact,UnMemoizedTUIContact}from"./components/TUIContact/TUIContact.js";export{TUIKitContext,TUIKitProvider,useTUIKitContext}from"./context/TUIKitContext.js";export{TUIChatStateContext,TUIChatStateContextProvider,useTUIChatStateContext}from"./context/TUIChatStateContext.js";export{TUIChatActionContext,TUIChatActionProvider,useTUIChatActionContext}from"./context/TUIChatActionContext.js";export{TUIMessageContext,TUIMessageContextProvider,messageShowType,useTUIMessageContext}from"./context/TUIMessageContext.js";export{ComponentContext,ComponentProvider,useComponentContext}from"./context/ComponentContext.js";export{TUIMessageInputContext,TUIMessageInputContextProvider,useTUIMessageInputContext}from"./context/TUIMessageInputContext.js";export{TUIContactContext,TUIContactContextProvider,useTUIContactContext}from"./context/TUIContactContext.js";export{useConversation}from"./hooks/useConversation.js";export{useProfile}from"./hooks/useProfile.js";export{t}from"./locales/index.js";export{isH5,isPC,setPlatform}from"./utils/env.js";export{default as i18next}from"i18next";new o;
@@ -0,0 +1 @@
1
+ import o from"./TUIChat.js";import r from"./TUIConversation.js";import t from"./TUIContact.js";import I from"./TUIProfile.js";var T={TUIGlobal:I,TUIChat:o,TUIConversation:r,TUIContact:t,TUIProfile:I};export{T as message};
@@ -1 +1 @@
1
- import e from"i18next";export{default as i18next}from"i18next";import{initReactI18next as t}from"react-i18next";import{message as r}from"./en/index.js";import{message as n}from"./zh_cn/index.js";var i={en:{translation:r},zh:{translation:n}};e.use(t).init({resources:i,lng:"en",interpolation:{escapeValue:!1}});var o=e.t;export{o as t};
1
+ import e from"i18next";export{default as i18next}from"i18next";import{initReactI18next as t}from"react-i18next";import{message as r}from"./en-US/index.js";import{message as a}from"./zh-CN/index.js";import{message as o}from"./ja-JP/index.js";import{message as n}from"./ko-KR/index.js";var i={"en-US":{translation:r},"zh-CN":{translation:a},"ja-JP":{translation:o},"ko-KR":{translation:n}};e.use(t).init({resources:i,lng:"en-US",interpolation:{escapeValue:!1}});var s=e.t;export{s as t};
@@ -0,0 +1 @@
1
+ var e={Recall:"取り消す",Reference:"参照",Forward:"転送",Copy:"コピー",Delete:"削除","Forward to":"転送先","recalled a message":"メッセージを取り消しました","Re-edit":"再編集",Resend:"再送信",You:"あなた","Recent Chats":"最近のチャット","Frequently Contacted":"よく連絡する相手","No Result":"検索結果なし","Search Result":"検索結果",Image:"画像",Video:"ビデオ",File:"ファイル","Enter a message":"メッセージを入力してください","No More":"これ以上なし","Error deleting message":"メッセージの削除エラー","The message recall exceeded the time limit (default 2 minutes)":"メッセージの取り消しは制限時間を超過しました(デフォルトは2分)","Error revoke Message":"メッセージの取り消しエラー","Custom message":"カスタムメッセージ"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Enter a userID":"ユーザーIDを入力して、エンターで検索","Enter the verification info":"認証情報を記入してください","Request to join":"参加申請",Requested:"申請済み",Accept:"受け入れる",Refuse:"拒否",Handled:"処理済み",Friends:"私の友達","Send Message":"メッセージを送信",Signature:"個性的なサイン","Successful application, waiting for the administrator to agree to join the group application":"申請が成功し、管理者のグループ参加同意を待っています","New Contacts":"新しい連絡先","Blocked List":"ブロックリスト","Group List":"私のグループチャット","No Result":"検索結果なし",ID:"ID",User:"連絡先","Add Friend":"友達追加",remark:"備考",block:"ブロック","Delete friend":"友達削除","waiting for verification":"認証待ち","verification info":"認証情報","Send application":"申請を送信",Agree:"賛成"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Start chat":"チャットを開始","New one-to-one chat":"新しい一対一のチャットを開始","New group chat":"新しいグループチャットを開始",Delete:"チャットを削除",Pin:"チャットをトップに固定",Unpin:"トップ固定を解除","Conversation Information":"チャット情報",Search:"検索","Add Participants":"グループチャットを作成","No conversation":"チャットなし",Next:"次へ","Group Name":"グループ名","Group ID":"グループID","Group Type":"グループタイプ",Participants:"参加者",Create:"作成",Details:"詳細",Work:"友達の仕事グループ(Work)",Public:"見知らぬ人の社交グループ(Public)",Meeting:"一時的な会議グループ(Meeting)",AVChatRoom:"ライブチャットルーム(AVChatroom)",Community:"コミュニティ(Community)","Users can join the group only via invitation by existing members. The invitation does not need to be agreed by the invitee or approved by the group owner. See the documentation for details.":"通常のWeChatグループのように、作成後はグループ内の友達のみが招待してグループに参加できます。招待は招待される側の同意やグループオーナーの承認が必要ありません。詳細はドキュメントを参照してください。","After a public group is created, the group owner can designate group admins. To join the group, a user needs to search the group ID and send a request, which needs to be approved by the group owner or an admin before the user can join the group. See the documentation for details.":"QQグループのように、作成後にグループオーナーがグループ管理者を指名できます。ユーザーはグループIDを検索してグループ参加申請を行い、グループオーナーまたは管理者の承認を得た後にグループに参加できます。詳細はドキュメントを参照してください。","After the group is created, a user can join and quit the group freely and can view the messages sent before joining the group. It is suitable for scenarios that integrate Tencent Real-Time Communication (TRTC), such as audio and video conferences and online education. See the documentation for details.":"グループ作成後、ユーザーは自由にグループに参加したり退出したりでき、グループ参加前のメッセージも閲覧できます。これは、音声およびビデオ会議やオンライン教育などの腾讯实时通信(TRTC)を統合するシナリオに適しています。詳細はドキュメントを参照してください。","After a group is created, a user can join and quit the group freely. The group can have an unlimited number of members, but it does not store message history. It can be combined with Live Video Broadcasting (LVB) to support on-screen comment scenarios. See the documentation for details.":"グループ作成後、ユーザーは自由にグループに参加したり退出したりできますが、グループメンバー数に上限はありませんが、メッセージ履歴は保存されません。これはライブビデオ放送(LVB)と組み合わせて、画面上のコメントシナリオをサポートするために使用できます。詳細はドキュメントを参照してください。","After creation, you can enter and leave at will, support up to 100,000 people, support historical message storage, and after users search for group ID and initiate a group application, they can join the group without administrator approval. See product documentation for details.":"作成後は自由に出入りでき、最大10万人をサポートし、歴史的メッセージの保存をサポートしています。ユーザーがグループIDを検索してグループ参加申請を行った後、管理者承認なしにグループに参加できます。詳細は製品ドキュメントを参照してください。","Participant cannot be empty":"参加者は空にできません"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Personal information":"個人情報",Signature:"個性署名",Gender:"性別",Male:"男",Female:"女",AllowType:"友達追加の認証方法",NeedConfirm:"認証が必要",AllowAny:"どのユーザーにも友達追加を許可",DenyAny:"どのユーザーにも友達追加を拒否",Birthday:"誕生日",Unknown:"未設定"};export{e as default};
@@ -0,0 +1 @@
1
+ import o from"./TUIChat.js";import r from"./TUIConversation.js";import t from"./TUIContact.js";import i from"./TUIProfile.js";var m={TUIChat:o,TUIConversation:r,TUIContact:t,TUIProfile:i};export{m as message};
@@ -0,0 +1 @@
1
+ var e={Recall:"회수",Reference:"인용",Forward:"전송",Copy:"복사",Delete:"삭제","Forward to":"전송 대상","recalled a message":"메시지를 회수했습니다","Re-edit":"재편집",Resend:"재전송",You:"당신","Recent Chats":"대화","Frequently Contacted":"자주 연락하는 사람들","No Result":"검색 결과 없음","Search Result":"검색 결과",Image:"이미지",Video:"비디오",File:"파일","Enter a message":"메시지를 입력하세요","No More":"더 이상 없습니다","Error deleting message":"메시지 삭제에 실패했습니다","The message recall exceeded the time limit (default 2 minutes)":"메시지 회수 시간이 제한을 초과했습니다 (기본 2분)","Error revoke Message":"메시지 회수에 실패했습니다","Custom message":"사용자 정의 메시지"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Enter a userID":"사용자 ID를 입력하고 엔터로 검색","Enter the verification info":"확인 정보를 입력하세요","Request to join":"가입 신청",Requested:"신청됨",Accept:"수락",Refuse:"거절",Handled:"처리됨",Friends:"내 친구들","Send Message":"메시지 보내기",Signature:"개성 서명","Successful application, waiting for the administrator to agree to join the group application":"관리자 승인을 기다리는 중","New Contacts":"새 연락처","Blocked List":"블랙리스트","Group List":"내 그룹 채팅","No Result":"검색 결과 없음",ID:"ID",User:"연락처","Add Friend":"친구 추가",remark:"비고",block:"블랙리스트에 추가","Delete friend":"친구 삭제","waiting for verification":"확인 대기 중","verification info":"확인 정보","Send application":"신청 보내기",Agree:"동의"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Start chat":"채팅 시작","New one-to-one chat":"1:1 채팅 시작","New group chat":"그룹 채팅 시작",Delete:"채팅 삭제",Pin:"채팅 고정",Unpin:"채팅 고정 해제","Conversation Information":"채팅 정보",Search:"검색","Add Participants":"그룹 채팅 생성","No conversation":"채팅 없음",Next:"다음","Group Name":"그룹 이름","Group ID":"그룹 ID","Group Type":"그룹 유형",Participants:"멤버",Create:"생성",Details:"상세",Work:"친구 작업 그룹(Work)",Public:"낯선 사람 소셜 그룹(Public)",Meeting:"임시 회의 그룹(Meeting)",AVChatRoom:"라이브 방송 그룹(AVChatroom)",Community:"커뮤니티(Community)","Users can join the group only via invitation by existing members. The invitation does not need to be agreed by the invitee or approved by the group owner. See the documentation for details.":"일반 위챗 그룹과 유사하게, 생성 후에는 이미 그룹에 있는 친구의 초대로만 그룹 가입이 가능하며, 초대자는 수락하지 않아도 되고 그룹 소유자의 승인을 받지 않아도 됩니다. 자세한 내용은 문서를 참조하십시오.","After a public group is created, the group owner can designate group admins. To join the group, a user needs to search the group ID and send a request, which needs to be approved by the group owner or an admin before the user can join the group. See the documentation for details.":"QQ 그룹과 유사하게, 생성 후에는 그룹 소유자가 그룹 관리자를 지정할 수 있습니다. 사용자가 그룹 ID를 검색하여 가입 요청을 보내면, 그룹 소유자 또는 관리자의 승인을 받아야만 그룹에 가입할 수 있습니다. 자세한 내용은 문서를 참조하십시오.","After the group is created, a user can join and quit the group freely and can view the messages sent before joining the group. It is suitable for scenarios that integrate Tencent Real-Time Communication (TRTC), such as audio and video conferences and online education. See the documentation for details.":"그룹을 생성한 후에는 사용자가 그룹에 자유롭게 가입하고 탈퇴할 수 있으며, 가입하기 전에 보낸 메시지를 볼 수 있습니다. 이는 음성 및 비디오 회의, 온라인 교육 등 Tencent 실시간 통신(TRTC)과 통합되는 시나리오에 적합합니다. 자세한 내용은 문서를 참조하십시오.","After a group is created, a user can join and quit the group freely. The group can have an unlimited number of members, but it does not store message history. It can be combined with Live Video Broadcasting (LVB) to support on-screen comment scenarios. See the documentation for details.":"그룹을 생성한 후에는 사용자가 그룹에 자유롭게 가입하고 탈퇴할 수 있으며, 그룹은 무제한의 멤버 수를 가질 수 있지만 메시지 역사를 저장하지는 않습니다. 이는 라이브 비디오 방송(LVB)과 결합하여 화면상 커멘트 시나리오를 지원하는 데 사용할 수 있습니다. 자세한 내용은 문서를 참조하십시오.","After creation, you can enter and leave at will, support up to 100,000 people, support historical message storage, and after users search for group ID and initiate a group application, they can join the group without administrator approval. See product documentation for details.":"생성 후에는 자유롭게 입장하고 탈퇴할 수 있으며, 최대 100,000명을 지원하고, 메시지 역사를 저장하며, 사용자가 그룹 ID를 검색하여 그룹 신청을 시작한 후에는 관리자 승인 없이 그룹에 가입할 수 있습니다. 자세한 내용은 제품 문서를 참조하십시오.","Participant cannot be empty":"참여자는 비워둘 수 없습니다"};export{e as default};
@@ -0,0 +1 @@
1
+ var e={"Personal information":"개인 정보",Signature:"개성 서명",Gender:"성별",Male:"남성",Female:"여성",AllowType:"친구 추가 인증 방법",NeedConfirm:"인증 필요",AllowAny:"모든 사용자에게 친구 추가를 허용",DenyAny:"모든 사용자에게 친구 추가를 거부",Birthday:"생일",Unknown:"미 설정"};export{e as default};
@@ -0,0 +1 @@
1
+ import o from"./TUIChat.js";import r from"./TUIConversation.js";import t from"./TUIContact.js";import i from"./TUIProfile.js";var m={TUIChat:o,TUIConversation:r,TUIContact:t,TUIProfile:i};export{m as message};
@@ -1,4 +1,5 @@
1
- declare const isPC: boolean;
2
- declare const isH5: boolean;
1
+ declare let isPC: boolean;
2
+ declare let isH5: boolean;
3
+ declare const setPlatform: (platform: 'pc' | 'h5') => void;
3
4
 
4
- export { isH5, isPC };
5
+ export { isH5, isPC, setPlatform };
@@ -1 +1 @@
1
- import{getPlatform as r}from"@tencentcloud/universal-api";var e="pc"===r(),o="h5"===r();export{o as isH5,e as isPC};
1
+ import{getPlatform as c}from"@tencentcloud/universal-api";var n="pc"===c(),o="h5"===c(),p=function(c){n="pc"===c,o="h5"===c};export{o as isH5,n as isPC,p as setPlatform};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tencentcloud/chat-uikit-react",
3
- "version": "2.2.3",
3
+ "version": "2.2.5",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
6
6
  "license": "MIT",
@@ -15,9 +15,10 @@
15
15
  "uikit"
16
16
  ],
17
17
  "scripts": {
18
- "build": "yarn clean && yarn run rollup -c",
18
+ "build": "rimraf ./dist && yarn run rollup -c",
19
19
  "start": "yarn run rollup -c -w",
20
- "clean": "rimraf ./dist"
20
+ "clean": "rimraf -g ./dist node_modules examples/*/node_modules",
21
+ "prepare": "husky install"
21
22
  },
22
23
  "homepage": "https://www.tencentcloud.com/document/product/1047/45912",
23
24
  "repository": {
@@ -34,18 +35,19 @@
34
35
  "@rollup/plugin-node-resolve": "^14.1.0",
35
36
  "@rollup/plugin-typescript": "^8.5.0",
36
37
  "@rollup/plugin-url": "^7.0.0",
38
+ "@stylistic/eslint-plugin": "^2.3.0",
39
+ "@stylistic/stylelint-config": "^1.0.1",
37
40
  "@types/node": "^20.10.5",
38
41
  "@types/react": "^18.0.20",
39
42
  "@typescript-eslint/eslint-plugin": "^5.36.2",
40
43
  "@typescript-eslint/parser": "^5.36.2",
41
44
  "autoprefixer": "^10.4.11",
42
- "eslint": "^8.23.0",
43
- "eslint-config-airbnb": "^19.0.4",
45
+ "eslint": "^8.57.0",
46
+ "eslint-config-react-app": "^7.0.1",
44
47
  "eslint-import-resolver-typescript": "^3.5.1",
45
- "eslint-plugin-import": "^2.26.0",
46
- "eslint-plugin-jsx-a11y": "^6.6.1",
47
- "eslint-plugin-react": "^7.31.8",
48
- "eslint-plugin-react-hooks": "^4.6.0",
48
+ "eslint-plugin-react-refresh": "^0.4.9",
49
+ "husky": "^8.0.3",
50
+ "lint-staged": "^15.2.7",
49
51
  "postcss": "^8.4.16",
50
52
  "react": "^18.2.0",
51
53
  "rimraf": "^3.0.2",
@@ -54,19 +56,23 @@
54
56
  "rollup-plugin-peer-deps-external": "^2.2.4",
55
57
  "rollup-plugin-postcss": "^4.0.2",
56
58
  "rollup-plugin-terser": "^7.0.2",
57
- "sass": "^1.54.9",
59
+ "sass": "^1.77.8",
60
+ "stylelint": "^16.7.0",
61
+ "stylelint-config-recommended-scss": "^14.1.0",
62
+ "stylelint-config-standard": "^36.0.1",
58
63
  "tslib": "^2.4.1",
59
- "typescript": "^4.8.3"
64
+ "typescript": "^4.8.3",
65
+ "typescript-eslint": "^7.16.0"
60
66
  },
61
67
  "dependencies": {
62
- "node-sass": "^7.0.3",
68
+ "@tencentcloud/chat": "latest",
69
+ "@tencentcloud/chat-uikit-engine": "latest",
70
+ "@tencentcloud/tui-core": "latest",
71
+ "@tencentcloud/universal-api": "latest",
63
72
  "date-fns": "^2.29.3",
64
73
  "react-date-picker": "^9.0.0",
65
74
  "react-dom": "^18.2.0",
66
- "@tencentcloud/tui-core": "latest",
67
- "@tencentcloud/chat": "latest",
68
- "@tencentcloud/chat-uikit-engine": "latest",
69
- "@tencentcloud/universal-api": "latest"
75
+ "rollup-plugin-copy": "^3.5.0"
70
76
  },
71
77
  "peerDependencies": {
72
78
  "date-fns": "^2.29.3",
package/rollup.config.js CHANGED
@@ -8,30 +8,11 @@ import postcss from 'rollup-plugin-postcss';
8
8
  import autoprefixer from 'autoprefixer';
9
9
  import peerDepsExternal from 'rollup-plugin-peer-deps-external';
10
10
  import url from '@rollup/plugin-url';
11
+ import copy from 'rollup-plugin-copy';
11
12
 
12
- const baseConfig = {
13
- input: [
14
- './src/index.ts',
15
- ],
16
- output: [
17
- {
18
- preserveModules: true,
19
- preserveModulesRoot: './src',
20
- dir: './dist/esm/',
21
- format: 'esm',
22
- },
23
- {
24
- preserveModules: true,
25
- preserveModulesRoot: './src',
26
- dir: './dist/cjs/',
27
- format: 'cjs',
28
- // sourcemap: true,
29
- },
30
- ],
31
- };
32
13
  export default [
33
14
  {
34
- ...baseConfig,
15
+ ...getBaseConfig(),
35
16
  plugins: [
36
17
  url(),
37
18
  postcss({
@@ -41,20 +22,30 @@ export default [
41
22
  autoprefixer(),
42
23
  ],
43
24
  }),
25
+ copy({
26
+ targets: [{
27
+ src: [
28
+ 'src/assets/fonts/iconfont.ttf',
29
+ 'src/assets/fonts/iconfont.woff',
30
+ 'src/assets/fonts/iconfont.woff2',
31
+ ],
32
+ dest: ['dist/cjs/assets/fonts', 'dist/esm/assets/fonts'],
33
+ }],
34
+ }),
44
35
  peerDepsExternal(),
45
36
  resolve(),
46
37
  commonjs(),
38
+ typescript(),
47
39
  babel({
48
- extensions: ['.js', '.jsx', '.es6', '.es', '.mjs', 'ts', 'tsx'],
40
+ extensions: ['.js', '.jsx', '.es6', '.es', '.mjs', '.ts', '.tsx'],
49
41
  }),
50
- typescript(),
51
42
  terser(),
52
43
  ],
53
44
  external: ['react', 'date-fns', 'tslib', 'react-date-picker', 'i18next', 'react-i18next', '@tencentcloud/tui-core',
54
- '@tencentcloud/chat', '@tencentcloud/chat-uikit-engine', '@tencentcloud/universal-api'],
45
+ '@tencentcloud/chat', '@tencentcloud/chat-uikit-engine', '@tencentcloud/universal-api'],
55
46
  },
56
47
  {
57
- ...baseConfig,
48
+ ...getBaseConfig(),
58
49
  plugins: [
59
50
  postcss({
60
51
  extract: true,
@@ -64,3 +55,27 @@ export default [
64
55
  ],
65
56
  },
66
57
  ];
58
+
59
+ function getBaseConfig() {
60
+ return {
61
+ input: [
62
+ './src/index.ts',
63
+ ],
64
+ output: [
65
+ {
66
+ preserveModules: true,
67
+ preserveModulesRoot: './src',
68
+ dir: './dist/esm/',
69
+ format: 'esm',
70
+ },
71
+ {
72
+ preserveModules: true,
73
+ preserveModulesRoot: './src',
74
+ dir: './dist/cjs/',
75
+ format: 'cjs',
76
+ exports: 'auto',
77
+ // sourcemap: true,
78
+ },
79
+ ],
80
+ };
81
+ }
Binary file
Binary file
Binary file
@@ -2,49 +2,57 @@
2
2
  .create-group-box {
3
3
  padding: 10px 0;
4
4
  }
5
+
5
6
  .input-group-text {
6
7
  font-weight: 400;
7
- font-size: 16px;
8
+ font-size: 14px;
8
9
  font-family: PingFangSC-Medium;
9
10
  line-height: 22px;
10
- color: #000000;
11
+ color: #000;
11
12
  }
13
+
12
14
  .create-group-name {
13
15
  .input-group-name {
14
16
  font-weight: 700;
15
- font-size: 16px;
17
+ font-size: 14px;
16
18
  font-family: PingFangSC-Medium;
17
19
  line-height: 19px;
18
- color: #000000;
20
+ color: #000;
19
21
  }
20
22
  }
23
+
21
24
  .input-group-title {
22
- color: rgba(0, 0, 0, 0.4);
25
+ color: rgba(0, 0, 0, 40%);
23
26
  width: 106px;
27
+ font-size: 14px;
24
28
  }
29
+
25
30
  .create-group-illustrate {
26
31
  font-weight: 400;
27
32
  font-size: 12px;
28
33
  font-family: PingFangSC-Medium;
29
34
  line-height: 17px;
30
35
  text-align: justify;
31
- color: rgba(0, 0, 0, 0.4);
36
+ color: rgba(0, 0, 0, 40%);
32
37
  padding-left: 8px;
33
38
  }
39
+
34
40
  .create-group-portrait {
35
41
  .create-group-portrait-title {
36
42
  font-weight: 600;
37
43
  font-size: 14px;
38
44
  font-family: PingFangSC-Medium;
39
45
  line-height: 20px;
40
- color: #000000;
46
+ color: #000;
41
47
  padding: 20px 0 20px 8px;
42
48
  }
49
+
43
50
  .create-group-portrait-info-container {
44
51
  display: flex;
45
52
  flex-wrap: wrap;
46
53
  justify-content: flex-start;
47
54
  margin-bottom: 10px;
55
+
48
56
  .create-group-portrait-info {
49
57
  align-items: center;
50
58
  display: flex;
@@ -52,6 +60,7 @@
52
60
  width: calc((100% - 10px) / 6);
53
61
  padding: 6px;
54
62
  box-sizing: border-box;
63
+
55
64
  &-nick {
56
65
  font-size: 12px;
57
66
  font-family: PingFangSC-Medium;
@@ -1,85 +1,96 @@
1
1
  .tui-conversation-create-header {
2
- background-color: #F9FAFB;
2
+ background-color: #f9fafb;
3
3
  display: flex;
4
4
  flex-direction: row;
5
5
  padding: 16px 20px;
6
6
  align-items: center;
7
7
  text-align: center;
8
+
8
9
  .title {
9
10
  margin-left: 10px;
10
11
  font-weight: 600;
11
- font-size: 20px;
12
+ font-size: 16px;
12
13
  font-family: PingFangSC-Medium;
13
14
  line-height: 32px;
14
15
  letter-spacing: -0.41px;
15
- color: #000000;
16
+ color: #000;
16
17
  }
17
18
  }
19
+
18
20
  .tui-conversation-create-search-input {
19
- margin: 10px 10px 10px;
21
+ margin: 10px;
20
22
  }
23
+
21
24
  .tui-user {
22
- padding: 10px 10px;
25
+ padding: 10px;
23
26
  display: flex;
24
27
  align-items: center;
25
28
  text-align: center;
26
29
  cursor: pointer;
30
+
27
31
  &:hover {
28
- background-color: rgba(0,110,255,.1);
32
+ background-color: rgba(0, 110, 255, 10%);
29
33
  }
34
+
30
35
  .tui-user-name {
31
36
  margin-left: 10px;
32
37
  font-weight: 400;
33
38
  font-size: 14px;
34
39
  font-family: PingFangSC-Medium;
35
40
  line-height: 20px;
36
- color: #000000;
41
+ color: #000;
37
42
  width: 80%;
38
43
  text-align: left;
44
+
39
45
  &.active {
40
46
  font-weight: 600;
41
47
  font-size: 14px;
42
48
  font-family: PingFangSC-Medium;
43
49
  line-height: 20px;
44
- color: rgba(3, 101, 249, 1);
50
+ color: rgba(3, 101, 249, 100%);
45
51
  }
46
52
  }
47
53
  }
54
+
48
55
  .tui-user-checkbox-label {
49
56
  .tui-user-checkbox {
50
57
  margin-left: auto;
51
58
  }
59
+
52
60
  input[type="checkbox"] {
53
61
  cursor: pointer;
54
62
  }
55
63
  }
64
+
56
65
  .tui-conversation-create-next-container {
57
66
  width: 100%;
58
67
  display: flex;
59
68
  justify-content: center;
60
69
  margin: 20px auto 10px;
70
+
61
71
  .tui-conversation-create-next {
62
72
  cursor: pointer;
63
73
  text-align: center;
64
- width: 12%;
65
- background-color: rgba(3, 101, 249, 1);
74
+ background-color: rgba(3, 101, 249, 100%);
66
75
  border-radius: 31px;
67
76
  font-size: 14px;
68
77
  font-family: PingFangSC-Medium;
69
78
  line-height: 20px;
70
- color: #FFFFFF;
79
+ color: #fff;
71
80
  padding: 12px 36px;
72
81
  }
73
82
  }
74
83
 
75
-
76
84
  .tui-conversation-create {
77
85
  overflow-y: auto;
86
+
78
87
  .tui-conversation-create-container {
79
88
  position: relative;
89
+
80
90
  .tui-group-container {
81
91
  width: 100%;
82
92
  }
93
+
83
94
  .tui-group-box {
84
95
  .title {
85
96
  font-weight: 600;
@@ -91,4 +102,3 @@
91
102
  }
92
103
  }
93
104
  }
94
-
@@ -159,8 +159,7 @@ export function unMemoConversationPreviewContent<T extends ConversationPreviewUI
159
159
  {t(!conversation.isPinned ? 'TUIConversation.Pin' : 'TUIConversation.Unpin')}
160
160
  </div>,
161
161
  <div
162
- className="more-handle-item"
163
- style={{ color: '#FF584C' }}
162
+ className="more-handle-item delete"
164
163
  onClick={(e) => {
165
164
  moreHandle(e, 'delete');
166
165
  }}
@@ -1,4 +1,5 @@
1
- $font-color: #7A7A7A;
1
+ @use "../../../styles/colors/color-theme" as *;
2
+
2
3
  .conversation-list-container {
3
4
  overflow-x: hidden;
4
5
  height: 100%;
@@ -7,7 +8,6 @@ $font-color: #7A7A7A;
7
8
  .conversation-preview-container {
8
9
  display: flex;
9
10
  align-items: center;
10
- background-color: #FFFFFF;
11
11
  border: none;
12
12
  width: 100%;
13
13
  height: 64px;
@@ -15,12 +15,15 @@ $font-color: #7A7A7A;
15
15
  line-height: 17px;
16
16
  padding: 0 20px;
17
17
 
18
+ @include theme() {
19
+ background-color: get(bg-primary);
20
+ }
21
+
18
22
  .content {
19
- flex: 1;
23
+ flex: 1 1 auto;
20
24
  text-align: left;
21
- max-width: 58%;
22
- min-width: 58%;
23
25
  margin-left: 10px;
26
+ min-width: 0;
24
27
 
25
28
  .title {
26
29
  font-style: normal;
@@ -30,27 +33,32 @@ $font-color: #7A7A7A;
30
33
  font-family: PingFangSC-Medium;
31
34
  padding: 1px 0;
32
35
  width: 100%;
33
- color: #000;
36
+
37
+ @include theme() {
38
+ color: get(text-primary);
39
+ }
34
40
  }
35
41
 
36
42
  .message {
37
43
  overflow: hidden;
38
44
  text-overflow: ellipsis;
39
45
  white-space: nowrap;
40
- color: $font-color;
41
46
  font-family: PingFangSC-Medium;
42
47
  font-style: normal;
43
48
  font-weight: 400;
44
49
  font-size: 12px;
45
50
  line-height: 14px;
46
51
  padding: 1px 0;
52
+
53
+ @include theme() {
54
+ color: get(text-secondary);
55
+ }
47
56
  }
48
57
  }
49
58
 
50
59
  .external {
51
- min-width: 90px;
52
60
  text-align: right;
53
- flex: 1;
61
+ flex: 0 1 auto;
54
62
  display: flex;
55
63
  flex-direction: column;
56
64
 
@@ -60,13 +68,16 @@ $font-color: #7A7A7A;
60
68
  }
61
69
 
62
70
  .time {
63
- color: $font-color;
64
71
  font-family: PingFangSC-Medium;
65
72
  font-style: normal;
66
73
  font-weight: 400;
67
74
  font-size: 12px;
68
75
  line-height: 14px;
69
76
  padding: 1px 0;
77
+
78
+ @include theme() {
79
+ color: get(text-secondary);
80
+ }
70
81
  }
71
82
 
72
83
  .more--hover {
@@ -98,10 +109,16 @@ $font-color: #7A7A7A;
98
109
  font-weight: 500;
99
110
  box-sizing: border-box;
100
111
 
112
+ &.delete {
113
+ @include theme() {
114
+ color: get(status-danger);
115
+ }
116
+ }
117
+
101
118
  &:hover {
102
- background: #147AFF;
103
- opacity: 0.6;
104
- color: #FFFFFF !important;
119
+ @include theme() {
120
+ background-color: get(bg-active);
121
+ }
105
122
  }
106
123
  }
107
124
  }
@@ -109,18 +126,26 @@ $font-color: #7A7A7A;
109
126
  }
110
127
 
111
128
  &:hover {
112
- background-color: rgba(0, 110, 255, 0.1);
129
+ @include theme() {
130
+ background-color: get(bg-active);
131
+ }
113
132
  }
114
133
 
115
134
  &.conversation-preview-content--pin {
116
- background-color: #F2F2F2D4;
135
+ @include theme() {
136
+ background-color: get(bg-secondary);
137
+ }
117
138
  }
118
139
 
119
140
  &.conversation-preview-content--active {
120
- background-color: rgba(0, 110, 255, 0.1);
141
+ @include theme() {
142
+ background-color: get(bg-active);
143
+ }
121
144
 
122
145
  .title {
123
- color: rgb(20, 122, 255);
146
+ @include theme() {
147
+ color: get(status-info);
148
+ }
124
149
  }
125
150
  }
126
151
 
@@ -128,16 +153,19 @@ $font-color: #7A7A7A;
128
153
  .unread {
129
154
  width: 16px;
130
155
  height: 13px;
131
- background: #FF3742;
132
156
  border-radius: 16px;
133
157
  display: flex;
134
158
  justify-content: center;
135
159
  align-items: center;
136
160
  padding: 2px 5px 1px;
137
- color: #FFFFFF;
138
161
  font-size: 11px;
139
162
  font-weight: 700;
140
163
  margin: 2px 0 2px auto;
164
+ color: #fff;
165
+
166
+ @include theme() {
167
+ background-color: get(status-danger);
168
+ }
141
169
  }
142
170
  }
143
171
  }