@tencentcloud/chat-uikit-react 3.0.3 → 3.4.2

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 (113) hide show
  1. package/.eslintrc.cjs +5 -4
  2. package/CHANGELOG.md +9 -0
  3. package/dist/components/Chat/Chat.d.ts +1 -1
  4. package/dist/components/Chat/Chat.js +18 -23
  5. package/dist/components/ChatHeader/AudioCallPicker/AudioCallPicker.d.ts +30 -0
  6. package/dist/components/ChatHeader/AudioCallPicker/AudioCallPicker.js +135 -0
  7. package/dist/components/ChatHeader/AudioCallPicker/index.d.ts +1 -0
  8. package/dist/components/ChatHeader/AudioCallPicker/index.js +4 -0
  9. package/dist/components/ChatHeader/ChatHeader.d.ts +6 -0
  10. package/dist/components/ChatHeader/ChatHeader.js +43 -41
  11. package/dist/components/ChatHeader/ChatHeaderUI/ChatHeaderUI.d.ts +12 -7
  12. package/dist/components/ChatHeader/ChatHeaderUI/ChatHeaderUI.js +47 -65
  13. package/dist/components/ChatHeader/VideoCallPicker/VideoCallPicker.d.ts +30 -0
  14. package/dist/components/ChatHeader/VideoCallPicker/VideoCallPicker.js +135 -0
  15. package/dist/components/ChatHeader/VideoCallPicker/index.d.ts +1 -0
  16. package/dist/components/ChatHeader/VideoCallPicker/index.js +4 -0
  17. package/dist/components/ChatHeader/index.d.ts +2 -1
  18. package/dist/components/ChatHeader/index.js +4 -2
  19. package/dist/components/Checkbox/index.js +1 -1
  20. package/dist/components/Modal/Modal.js +1 -1
  21. package/dist/components/Model/index.js +1 -1
  22. package/dist/components/Plugins/index.js +1 -1
  23. package/dist/components/Popup/index.js +1 -1
  24. package/dist/components/PopupNew/Popup.js +1 -1
  25. package/dist/components/Profile/Profile.js +20 -22
  26. package/dist/components/Profile/ProfileDefault.d.ts +3 -2
  27. package/dist/components/Profile/ProfileDefault.js +55 -56
  28. package/dist/components/Profile/hooks/useMyProfile.d.ts +2 -3
  29. package/dist/components/Profile/hooks/useMyProfile.js +1 -1
  30. package/dist/components/Profile/myProfile/MyProfile.d.ts +1 -1
  31. package/dist/components/Profile/myProfile/MyProfile.js +12 -16
  32. package/dist/components/index.js +27 -25
  33. package/dist/context/ChatContext.d.ts +1 -1
  34. package/dist/context/ChatContext.js +11 -16
  35. package/dist/context/ContactContext.d.ts +1 -1
  36. package/dist/external_modules/mui-BhvHeL5-.js +2253 -0
  37. package/dist/hooks/index.d.ts +2 -2
  38. package/dist/hooks/index.js +2 -2
  39. package/dist/{states/ChatHeaderState.d.ts → hooks/useChatHeader.d.ts} +6 -6
  40. package/dist/hooks/useChatHeader.js +41 -0
  41. package/dist/index-UBuvRM8r-DTXQB6zV.js +34000 -0
  42. package/dist/index.d.ts +3 -1
  43. package/dist/index.js +93 -4133
  44. package/dist/server/mainServer.js +2 -2
  45. package/dist/states/UIManagerState.d.ts +5 -5
  46. package/dist/states/UIManagerState.js +2 -2
  47. package/dist/states/index.d.ts +0 -1
  48. package/dist/states/index.js +2 -4
  49. package/dist/styles/AudioCallPicker.css +1 -0
  50. package/dist/styles/ChatHeaderUI.css +1 -1
  51. package/dist/styles/VideoCallPicker.css +1 -0
  52. package/dist/styles/index-UBuvRM8r.css +1 -0
  53. package/dist/styles/index.css +1 -1
  54. package/dist/styles/index2.css +1 -1
  55. package/dist/styles/index3.css +1 -1
  56. package/dist/styles/index4.css +1 -1
  57. package/dist/styles/index5.css +1 -1
  58. package/dist/types/message.d.ts +1 -1
  59. package/dist/types/user.d.ts +4 -4
  60. package/package.json +12 -20
  61. package/src/components/ChatHeader/AudioCallPicker/AudioCallPicker.module.scss +57 -0
  62. package/src/components/ChatHeader/AudioCallPicker/AudioCallPicker.tsx +234 -0
  63. package/src/components/ChatHeader/AudioCallPicker/index.ts +1 -0
  64. package/src/components/ChatHeader/ChatHeader.tsx +15 -3
  65. package/src/components/ChatHeader/ChatHeaderUI/ChatHeaderUI.tsx +29 -36
  66. package/src/components/ChatHeader/VideoCallPicker/VideoCallPicker.module.scss +57 -0
  67. package/src/components/ChatHeader/VideoCallPicker/VideoCallPicker.tsx +233 -0
  68. package/src/components/ChatHeader/VideoCallPicker/index.ts +1 -0
  69. package/src/components/ChatHeader/index.ts +2 -1
  70. package/src/components/Profile/Profile.tsx +7 -6
  71. package/src/components/Profile/ProfileDefault.tsx +8 -8
  72. package/src/components/Profile/hooks/useMyProfile.tsx +2 -3
  73. package/src/components/Profile/myProfile/MyProfile.tsx +1 -1
  74. package/src/context/ChatContext.tsx +1 -1
  75. package/src/context/ContactContext.tsx +1 -1
  76. package/src/hooks/index.ts +2 -2
  77. package/src/{states/ChatHeaderState.ts → hooks/useChatHeader.ts} +15 -17
  78. package/src/index.ts +3 -5
  79. package/src/server/mainServer.ts +2 -2
  80. package/src/states/UIManagerState.ts +9 -9
  81. package/src/states/index.ts +0 -2
  82. package/src/styles/index.scss +0 -1
  83. package/src/types/message.ts +1 -1
  84. package/src/types/user.ts +4 -4
  85. package/vite.config.ts +4 -25
  86. package/dist/ChatSetting-LYkP2NWu.js +0 -29890
  87. package/dist/assets/fonts/iconfont.ttf +0 -0
  88. package/dist/assets/fonts/iconfont.woff +0 -0
  89. package/dist/assets/fonts/iconfont.woff2 +0 -0
  90. package/dist/components/ChatHeader/ChatHeaderActions/ChatHeaderActions.d.ts +0 -11
  91. package/dist/components/ChatHeader/ChatHeaderActions/ChatHeaderActions.js +0 -79
  92. package/dist/components/ChatHeader/ChatHeaderActions/index.d.ts +0 -1
  93. package/dist/components/ChatHeader/ChatHeaderActions/index.js +0 -4
  94. package/dist/components/IconFont/Icon.d.ts +0 -21
  95. package/dist/components/IconFont/Icon.js +0 -47
  96. package/dist/components/IconFont/index.d.ts +0 -2
  97. package/dist/components/IconFont/index.js +0 -4
  98. package/dist/external_modules/lodash-vwDjcXxQ.js +0 -0
  99. package/dist/external_modules/mui-BcA3SBHM.js +0 -2473
  100. package/dist/states/ChatHeaderState.js +0 -46
  101. package/dist/styles/ChatHeaderActions.css +0 -1
  102. package/dist/styles/ChatSetting.css +0 -1
  103. package/dist/styles/Icon2.css +0 -1
  104. package/src/assets/fonts/iconfont.ttf +0 -0
  105. package/src/assets/fonts/iconfont.woff +0 -0
  106. package/src/assets/fonts/iconfont.woff2 +0 -0
  107. package/src/components/ChatHeader/ChatHeaderActions/ChatHeaderActions.module.scss +0 -44
  108. package/src/components/ChatHeader/ChatHeaderActions/ChatHeaderActions.tsx +0 -105
  109. package/src/components/ChatHeader/ChatHeaderActions/index.ts +0 -1
  110. package/src/components/IconFont/Icon.module.scss +0 -42
  111. package/src/components/IconFont/Icon.tsx +0 -68
  112. package/src/components/IconFont/index.ts +0 -3
  113. package/src/styles/fonts/icon-font.scss +0 -18
@@ -1,31 +1,33 @@
1
1
  import { ChatHeader as e } from "./ChatHeader/ChatHeader.js";
2
- import { ChatHeaderActions as p } from "./ChatHeader/ChatHeaderActions/ChatHeaderActions.js";
3
- import { Chat as m } from "./Chat/Chat.js";
4
- import { Checkbox as a } from "./Checkbox/index.js";
5
- import { DivWithEdit as c } from "./DivWithEdit/DivWithEdit.js";
2
+ import { AudioCallPicker as p } from "./ChatHeader/AudioCallPicker/AudioCallPicker.js";
3
+ import { VideoCallPicker as m } from "./ChatHeader/VideoCallPicker/VideoCallPicker.js";
4
+ import { Chat as i } from "./Chat/Chat.js";
5
+ import { Checkbox as l } from "./Checkbox/index.js";
6
+ import { DivWithEdit as d } from "./DivWithEdit/DivWithEdit.js";
6
7
  import { EmptyStateIndicator as n } from "./EmptyStateIndicator/EmptyStateIndicator.js";
7
- import { Icon as d, changeTypeToIconClassName as s } from "./Icon/Icon.js";
8
- import { IconTypes as I } from "./Icon/type.js";
9
- import { Model as T } from "./Model/index.js";
10
- import { Plugins as y } from "./Plugins/index.js";
11
- import { Popup as D } from "./Popup/index.js";
12
- import { Profile as H } from "./Profile/Profile.js";
13
- import { TUIProfileDefault as b } from "./Profile/ProfileDefault.js";
14
- import { Switch as v } from "./Switch/Switch.js";
8
+ import { Icon as P, changeTypeToIconClassName as I } from "./Icon/Icon.js";
9
+ import { IconTypes as u } from "./Icon/type.js";
10
+ import { Model as k } from "./Model/index.js";
11
+ import { Plugins as g } from "./Plugins/index.js";
12
+ import { Popup as E } from "./Popup/index.js";
13
+ import { Profile as b } from "./Profile/Profile.js";
14
+ import { TUIProfileDefault as w } from "./Profile/ProfileDefault.js";
15
+ import { Switch as H } from "./Switch/Switch.js";
15
16
  export {
16
- m as Chat,
17
+ p as AudioCallPicker,
18
+ i as Chat,
17
19
  e as ChatHeader,
18
- p as ChatHeaderActions,
19
- a as Checkbox,
20
- c as DivWithEdit,
20
+ l as Checkbox,
21
+ d as DivWithEdit,
21
22
  n as EmptyStateIndicator,
22
- d as Icon,
23
- I as IconTypes,
24
- T as Model,
25
- y as Plugins,
26
- D as Popup,
27
- H as Profile,
28
- v as Switch,
29
- b as TUIProfileDefault,
30
- s as changeTypeToIconClassName
23
+ P as Icon,
24
+ u as IconTypes,
25
+ k as Model,
26
+ g as Plugins,
27
+ E as Popup,
28
+ b as Profile,
29
+ H as Switch,
30
+ w as TUIProfileDefault,
31
+ m as VideoCallPicker,
32
+ I as changeTypeToIconClassName
31
33
  };
@@ -1,4 +1,4 @@
1
- import { IConversationModel } from '@tencentcloud/chat-uikit-engine';
1
+ import { IConversationModel } from '@tencentcloud/chat-uikit-engine-lite';
2
2
  interface IChatProps {
3
3
  children?: React.ReactNode;
4
4
  }
@@ -1,27 +1,22 @@
1
1
  import { jsx as n } from "react/jsx-runtime";
2
2
  import { createContext as i, useMemo as s, useContext as u } from "react";
3
3
  import { useUIManagerState as a } from "../states/UIManagerState.js";
4
- import "@tencentcloud/chat-uikit-engine";
5
- import "../ChatSetting-LYkP2NWu.js";
6
- import "@tencentcloud/uikit-base-component-react";
7
- import "@tencentcloud/tui-core";
8
- import "@tencentcloud/chat";
9
- const r = i(null);
10
- function v(t) {
4
+ const o = i(null);
5
+ function m(t) {
11
6
  const {
12
- conversation: o
13
- } = a(), e = s(() => ({
14
- currentConversation: o
15
- }), [o]);
16
- return /* @__PURE__ */ n(r.Provider, { value: e, children: t.children });
7
+ conversation: e
8
+ } = a(), r = s(() => ({
9
+ currentConversation: e
10
+ }), [e]);
11
+ return /* @__PURE__ */ n(o.Provider, { value: r, children: t.children });
17
12
  }
18
- function l() {
19
- const t = u(r);
13
+ function x() {
14
+ const t = u(o);
20
15
  if (!t)
21
16
  throw new Error("useChatContext must be used within a ChatProvider");
22
17
  return t;
23
18
  }
24
19
  export {
25
- v as ChatProvider,
26
- l as useChatContext
20
+ m as ChatProvider,
21
+ x as useChatContext
27
22
  };
@@ -1,5 +1,5 @@
1
1
  import { default as React, PropsWithChildren } from 'react';
2
- import { Friend, Profile, FriendApplication } from '@tencentcloud/chat';
2
+ import { Friend, Profile, FriendApplication } from '@tencentcloud/lite-chat';
3
3
  export interface TUIContactContextValue {
4
4
  friendList?: Friend[];
5
5
  blocklistProfile?: Profile[];