@100mslive/roomkit-react 0.1.6-alpha.1 → 0.1.6-alpha.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{HLSView-HNVYG5VE.js → HLSView-QMU5JK7U.js} +3 -3
- package/dist/Prebuilt/components/Footer/ChatToggle.d.ts +1 -3
- package/dist/Prebuilt/components/SidePaneTabs.d.ts +7 -0
- package/dist/{VirtualBackground-UM2FOUHQ.js → VirtualBackground-37FXUPYO.js} +6 -6
- package/dist/VirtualBackground-37FXUPYO.js.map +7 -0
- package/dist/{chunk-POE7H4IE.js → chunk-KBVIZGYW.js} +2 -2
- package/dist/{chunk-POE7H4IE.js.map → chunk-KBVIZGYW.js.map} +1 -1
- package/dist/{chunk-LYSAET4G.js → chunk-WVGGQZK4.js} +100 -106
- package/dist/{chunk-LYSAET4G.js.map → chunk-WVGGQZK4.js.map} +3 -3
- package/dist/{chunk-364HP22I.js → chunk-ZKE2N5LH.js} +2 -2
- package/dist/{conference-UWLJHMB2.js → conference-FJJQ4TXX.js} +419 -384
- package/dist/conference-FJJQ4TXX.js.map +7 -0
- package/dist/index.cjs.js +594 -570
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.js +2 -2
- package/dist/meta.cjs.json +127 -127
- package/dist/meta.esbuild.json +161 -160
- package/package.json +6 -6
- package/src/Prebuilt/components/Chat/Chat.jsx +2 -6
- package/src/Prebuilt/components/Footer/ChatToggle.tsx +2 -9
- package/src/Prebuilt/components/Footer/Footer.tsx +22 -6
- package/src/Prebuilt/components/Footer/ParticipantList.jsx +0 -2
- package/src/Prebuilt/components/Header/HeaderComponents.jsx +8 -1
- package/src/Prebuilt/components/InsetTile.tsx +1 -0
- package/src/Prebuilt/components/MoreSettings/SplitComponents/MwebOptions.tsx +1 -1
- package/src/Prebuilt/components/Notifications/Notifications.jsx +14 -7
- package/src/Prebuilt/components/Preview/PreviewJoin.tsx +2 -3
- package/src/Prebuilt/components/RoleChangeRequestModal.tsx +6 -4
- package/src/Prebuilt/components/SidePaneTabs.tsx +120 -0
- package/src/Prebuilt/components/hooks/useMetadata.jsx +7 -25
- package/src/Prebuilt/layouts/SidePane.tsx +12 -10
- package/src/Prebuilt/plugins/VirtualBackground/VirtualBackground.jsx +3 -3
- package/src/Prebuilt/provider/roomLayoutProvider/hooks/useFetchRoomLayout.ts +2 -2
- package/dist/VirtualBackground-UM2FOUHQ.js.map +0 -7
- package/dist/conference-UWLJHMB2.js.map +0 -7
- package/src/Prebuilt/components/Chat/ChatParticipantHeader.jsx +0 -84
- /package/dist/{HLSView-HNVYG5VE.js.map → HLSView-QMU5JK7U.js.map} +0 -0
- /package/dist/{chunk-364HP22I.js.map → chunk-ZKE2N5LH.js.map} +0 -0
@@ -1,84 +0,0 @@
|
|
1
|
-
import React, { useState } from 'react';
|
2
|
-
import { selectPeerCount, useHMSStore } from '@100mslive/react-sdk';
|
3
|
-
import { CrossIcon } from '@100mslive/react-icons';
|
4
|
-
import { Flex, IconButton, Tabs, Text } from '../../..';
|
5
|
-
import { useRoomLayoutConferencingScreen } from '../../provider/roomLayoutProvider/hooks/useRoomLayoutScreen';
|
6
|
-
import { useSidepaneToggle } from '../AppData/useSidepane';
|
7
|
-
import { SIDE_PANE_OPTIONS } from '../../common/constants';
|
8
|
-
|
9
|
-
const tabTriggerCSS = {
|
10
|
-
color: '$on_surface_high',
|
11
|
-
p: '$4',
|
12
|
-
fontWeight: '$semiBold',
|
13
|
-
fontSize: '$sm',
|
14
|
-
w: '100%',
|
15
|
-
justifyContent: 'center',
|
16
|
-
};
|
17
|
-
|
18
|
-
export const ChatParticipantHeader = React.memo(({ activeTabValue = SIDE_PANE_OPTIONS.CHAT }) => {
|
19
|
-
const toggleChat = useSidepaneToggle(SIDE_PANE_OPTIONS.CHAT);
|
20
|
-
const toggleParticipants = useSidepaneToggle(SIDE_PANE_OPTIONS.PARTICIPANTS);
|
21
|
-
const [activeTab, setActiveTab] = useState(activeTabValue);
|
22
|
-
const peerCount = useHMSStore(selectPeerCount);
|
23
|
-
const { elements } = useRoomLayoutConferencingScreen();
|
24
|
-
const showChat = !!elements?.chat;
|
25
|
-
const showParticipants = !!elements?.participant_list;
|
26
|
-
const hideTabs = !(showChat && showParticipants);
|
27
|
-
|
28
|
-
return (
|
29
|
-
<Flex
|
30
|
-
align="center"
|
31
|
-
css={{
|
32
|
-
color: '$on_primary_high',
|
33
|
-
h: '$16',
|
34
|
-
}}
|
35
|
-
>
|
36
|
-
{hideTabs ? (
|
37
|
-
<Text variant="sm" css={{ fontWeight: '$semiBold', c: '$on_surface_high' }}>
|
38
|
-
{showChat ? 'Chat' : `Participants (${peerCount})`}
|
39
|
-
</Text>
|
40
|
-
) : (
|
41
|
-
<Flex css={{ w: '100%', bg: '$surface_default', borderRadius: '$2' }}>
|
42
|
-
<Tabs.Root value={activeTab} onValueChange={setActiveTab} css={{ w: '100%' }}>
|
43
|
-
<Tabs.List css={{ w: '100%', p: '$2' }}>
|
44
|
-
<Tabs.Trigger
|
45
|
-
value={SIDE_PANE_OPTIONS.CHAT}
|
46
|
-
onClick={toggleChat}
|
47
|
-
css={{
|
48
|
-
...tabTriggerCSS,
|
49
|
-
color: activeTab !== SIDE_PANE_OPTIONS.CHAT ? '$on_surface_low' : '$on_surface_high',
|
50
|
-
}}
|
51
|
-
>
|
52
|
-
Chat
|
53
|
-
</Tabs.Trigger>
|
54
|
-
<Tabs.Trigger
|
55
|
-
value={SIDE_PANE_OPTIONS.PARTICIPANTS}
|
56
|
-
onClick={toggleParticipants}
|
57
|
-
css={{
|
58
|
-
...tabTriggerCSS,
|
59
|
-
color: activeTab !== SIDE_PANE_OPTIONS.PARTICIPANTS ? '$on_surface_low' : '$on_surface_high',
|
60
|
-
}}
|
61
|
-
>
|
62
|
-
Participants ({peerCount})
|
63
|
-
</Tabs.Trigger>
|
64
|
-
</Tabs.List>
|
65
|
-
</Tabs.Root>
|
66
|
-
</Flex>
|
67
|
-
)}
|
68
|
-
<IconButton
|
69
|
-
css={{ ml: 'auto' }}
|
70
|
-
onClick={e => {
|
71
|
-
e.stopPropagation();
|
72
|
-
if (activeTab === SIDE_PANE_OPTIONS.CHAT) {
|
73
|
-
toggleChat();
|
74
|
-
} else {
|
75
|
-
toggleParticipants();
|
76
|
-
}
|
77
|
-
}}
|
78
|
-
data-testid="close_chat"
|
79
|
-
>
|
80
|
-
<CrossIcon />
|
81
|
-
</IconButton>
|
82
|
-
</Flex>
|
83
|
-
);
|
84
|
-
});
|
File without changes
|
File without changes
|