@100mslive/roomkit-react 0.3.3-alpha.2 → 0.3.3-alpha.4
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.
- package/dist/Accordion/Accordion.d.ts +0 -1
- package/dist/Accordion/index.d.ts +0 -1
- package/dist/{HLSView-GI5NXBYN.js → HLSView-VUANLYLS.js} +2 -2
- package/dist/Prebuilt/components/RaiseHand.d.ts +1 -1
- package/dist/{chunk-KUFQ5ONV.js → chunk-5WTUTVRO.js} +381 -414
- package/dist/chunk-5WTUTVRO.js.map +7 -0
- package/dist/index.cjs.js +813 -849
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.js +1 -1
- package/dist/meta.cjs.json +63 -58
- package/dist/meta.esbuild.json +68 -63
- package/package.json +7 -7
- package/src/Accordion/Accordion.tsx +4 -4
- package/src/Prebuilt/components/Chat/ChatBody.tsx +0 -10
- package/src/Prebuilt/components/Chat/ChatFooter.tsx +4 -2
- package/src/Prebuilt/components/ConferenceScreen.tsx +4 -1
- package/src/Prebuilt/components/Footer/Footer.tsx +4 -1
- package/src/Prebuilt/components/Footer/ParticipantList.tsx +1 -4
- package/src/Prebuilt/components/Footer/RoleAccordion.tsx +6 -6
- package/src/Prebuilt/components/MoreSettings/SplitComponents/DesktopOptions.tsx +1 -0
- package/src/Prebuilt/components/MoreSettings/SplitComponents/MwebOptions.tsx +5 -1
- package/src/Prebuilt/components/PreviousRoleInMetadata.tsx +1 -0
- package/src/Prebuilt/components/RaiseHand.tsx +1 -7
- package/src/Prebuilt/components/RoleChangeRequest/RoleChangeRequestModal.tsx +1 -0
- package/src/Prebuilt/components/hooks/{useMetadata.tsx → useMetadata.jsx} +8 -2
- package/dist/Prebuilt/components/hooks/useMetadata.d.ts +0 -8
- package/dist/chunk-KUFQ5ONV.js.map +0 -7
- /package/dist/{HLSView-GI5NXBYN.js.map → HLSView-VUANLYLS.js.map} +0 -0
@@ -93,7 +93,6 @@ export const RoleAccordion = ({
|
|
93
93
|
return (
|
94
94
|
<Accordion.Item value={roleName} css={{ '&:hover .role_actions': { visibility: 'visible' }, mb: '$8' }} ref={ref}>
|
95
95
|
<Accordion.Header
|
96
|
-
chevronID={`role_accordion_btn_${roleName}`}
|
97
96
|
iconStyles={{ c: '$on_surface_high' }}
|
98
97
|
css={{
|
99
98
|
textTransform: 'capitalize',
|
@@ -149,17 +148,18 @@ export const RoleAccordion = ({
|
|
149
148
|
<ChevronRightIcon />
|
150
149
|
</Flex>
|
151
150
|
) : null}
|
152
|
-
{isHandRaisedAccordion &&
|
151
|
+
{isHandRaisedAccordion && (
|
153
152
|
<>
|
154
153
|
<HorizontalDivider />
|
155
154
|
<Flex css={{ w: '100%', p: '$6', gap: '$4' }} justify="center">
|
156
155
|
<Button variant="standard" onClick={lowerAllHands} icon css={{ pl: '$2' }}>
|
157
156
|
<CrossIcon /> Lower all hands
|
158
157
|
</Button>
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
158
|
+
{canBringToStage && (
|
159
|
+
<Button onClick={bringAllToStage} icon css={{ pl: '$2' }}>
|
160
|
+
<AddIcon /> {bring_to_stage_label}
|
161
|
+
</Button>
|
162
|
+
)}
|
163
163
|
</Flex>
|
164
164
|
</>
|
165
165
|
)}
|
@@ -29,6 +29,7 @@ import { FullScreenItem } from '../FullScreenItem';
|
|
29
29
|
import { MuteAllModal } from '../MuteAllModal';
|
30
30
|
// @ts-ignore: No implicit any
|
31
31
|
import { useDropdownList } from '../../hooks/useDropdownList';
|
32
|
+
// @ts-ignore: No implicit any
|
32
33
|
import { useMyMetadata } from '../../hooks/useMetadata';
|
33
34
|
// @ts-ignore: No implicit any
|
34
35
|
import { APP_DATA, isMacOS } from '../../../common/constants';
|
@@ -6,6 +6,7 @@ import {
|
|
6
6
|
selectIsConnectedToRoom,
|
7
7
|
selectPeerCount,
|
8
8
|
selectPermissions,
|
9
|
+
useAVToggle,
|
9
10
|
useHMSActions,
|
10
11
|
useHMSStore,
|
11
12
|
useRecordingStreaming,
|
@@ -50,6 +51,7 @@ import { usePollViewToggle, useSidepaneToggle } from '../../AppData/useSidepane'
|
|
50
51
|
import { useShowPolls } from '../../AppData/useUISettings';
|
51
52
|
// @ts-ignore: No implicit any
|
52
53
|
import { useDropdownList } from '../../hooks/useDropdownList';
|
54
|
+
// @ts-ignore: No implicit any
|
53
55
|
import { useMyMetadata } from '../../hooks/useMetadata';
|
54
56
|
import { useUnreadPollQuizPresent } from '../../hooks/useUnreadPollQuizPresent';
|
55
57
|
import { useLandscapeHLSStream, useMobileHLSStream } from '../../../common/hooks';
|
@@ -93,6 +95,8 @@ export const MwebOptions = ({
|
|
93
95
|
const peerCount = useHMSStore(selectPeerCount);
|
94
96
|
const emojiCardRef = useRef(null);
|
95
97
|
const { isBRBOn, toggleBRB, isHandRaised, toggleHandRaise } = useMyMetadata();
|
98
|
+
const { toggleAudio, toggleVideo } = useAVToggle();
|
99
|
+
const noAVPermissions = !(toggleAudio || toggleVideo);
|
96
100
|
const { unreadPollQuiz, setUnreadPollQuiz } = useUnreadPollQuizPresent();
|
97
101
|
const { title, description } = useRoomLayoutHeader();
|
98
102
|
const toggleDetailsSheet = useSheetToggle(SHEET_OPTIONS.ROOM_DETAILS);
|
@@ -171,7 +175,7 @@ export const MwebOptions = ({
|
|
171
175
|
</ActionTile.Root>
|
172
176
|
)}
|
173
177
|
|
174
|
-
{
|
178
|
+
{!noAVPermissions ? (
|
175
179
|
<ActionTile.Root
|
176
180
|
active={isHandRaised}
|
177
181
|
onClick={() => {
|
@@ -4,17 +4,11 @@ import { CSS } from '../../Theme';
|
|
4
4
|
import { Tooltip } from '../../Tooltip';
|
5
5
|
// @ts-ignore: No implicit Any
|
6
6
|
import IconButton from '../IconButton';
|
7
|
-
|
7
|
+
// @ts-ignore: No implicit Any
|
8
8
|
import { useMyMetadata } from './hooks/useMetadata';
|
9
9
|
|
10
10
|
export const RaiseHand = ({ css }: { css?: CSS }) => {
|
11
11
|
const { isHandRaised, toggleHandRaise } = useMyMetadata();
|
12
|
-
const { elements } = useRoomLayoutConferencingScreen();
|
13
|
-
|
14
|
-
if (!elements.hand_raise) {
|
15
|
-
return null;
|
16
|
-
}
|
17
|
-
|
18
12
|
return (
|
19
13
|
<Tooltip title={isHandRaised ? 'Lower hand' : 'Raise hand'}>
|
20
14
|
<IconButton
|
@@ -13,6 +13,7 @@ import { Flex, Text } from '../../..';
|
|
13
13
|
import { PreviewControls, PreviewTile } from '../Preview/PreviewJoin';
|
14
14
|
import { RequestPrompt } from './RequestPrompt';
|
15
15
|
import { useRoomLayoutPreviewScreen } from '../../provider/roomLayoutProvider/hooks/useRoomLayoutScreen';
|
16
|
+
// @ts-ignore: No implicit Any
|
16
17
|
import { useMyMetadata } from '../hooks/useMetadata';
|
17
18
|
// @ts-ignore: No implicit Any
|
18
19
|
import { ROLE_CHANGE_DECLINED } from '../../common/constants';
|
@@ -15,7 +15,7 @@ export const useMyMetadata = () => {
|
|
15
15
|
const metaData = useHMSStore(selectPeerMetadata(localPeerId));
|
16
16
|
const isHandRaised = useHMSStore(selectHasPeerHandRaised(localPeerId));
|
17
17
|
|
18
|
-
const update = async
|
18
|
+
const update = async updatedFields => {
|
19
19
|
try {
|
20
20
|
// get current state from store and merge updated fields
|
21
21
|
const currentMetadata = vanillaStore.getState(selectPeerMetadata(localPeerId));
|
@@ -24,7 +24,6 @@ export const useMyMetadata = () => {
|
|
24
24
|
} catch (error) {
|
25
25
|
console.error('failed to update metadata ', updatedFields);
|
26
26
|
}
|
27
|
-
return false;
|
28
27
|
};
|
29
28
|
|
30
29
|
const toggleHandRaise = useCallback(async () => {
|
@@ -44,6 +43,12 @@ export const useMyMetadata = () => {
|
|
44
43
|
}
|
45
44
|
}, [metaData?.isBRBOn]); //eslint-disable-line
|
46
45
|
|
46
|
+
const setPrevRole = async role => {
|
47
|
+
await update({
|
48
|
+
prevRole: role,
|
49
|
+
});
|
50
|
+
};
|
51
|
+
|
47
52
|
return {
|
48
53
|
isHandRaised,
|
49
54
|
isBRBOn: !!metaData?.isBRBOn,
|
@@ -51,5 +56,6 @@ export const useMyMetadata = () => {
|
|
51
56
|
updateMetaData: update,
|
52
57
|
toggleHandRaise,
|
53
58
|
toggleBRB,
|
59
|
+
setPrevRole,
|
54
60
|
};
|
55
61
|
};
|