Browse Source

feat(native-participants-pane) fixed mute all content styles and added doInvitePeople action

master
Calin Chitu 4 years ago
parent
commit
ee101f8947

+ 10
- 1
react/features/participants-pane/components/native/MeetingParticipantList.js View File

@@ -1,17 +1,25 @@
1 1
 // @flow
2 2
 
3
-import React from 'react';
3
+import React, { useCallback } from 'react';
4 4
 import { useTranslation } from 'react-i18next';
5 5
 import { Text, View } from 'react-native';
6 6
 import { Button } from 'react-native-paper';
7
+import { useDispatch } from 'react-redux';
7 8
 
9
+import { createToolbarEvent, sendAnalytics } from '../../../analytics';
8 10
 import { Icon, IconInviteMore } from '../../../base/icons';
11
+import { doInvitePeople } from '../../../invite/actions.native';
9 12
 
10 13
 import { MeetingParticipantItem } from './MeetingParticipantItem';
11 14
 import { participants } from './participants';
12 15
 import styles from './styles';
13 16
 
14 17
 export const MeetingParticipantList = () => {
18
+    const dispatch = useDispatch();
19
+    const onInvite = useCallback(() => {
20
+        sendAnalytics(createToolbarEvent('invite'));
21
+        dispatch(doInvitePeople());
22
+    }, [ dispatch ]);
15 23
     const { t } = useTranslation();
16 24
 
17 25
     return (
@@ -30,6 +38,7 @@ export const MeetingParticipantList = () => {
30 38
                 }
31 39
                 labelStyle = { styles.inviteLabel }
32 40
                 mode = 'contained'
41
+                onPress = { onInvite }
33 42
                 style = { styles.inviteButton } />
34 43
             { participants.map(p => (
35 44
                 <MeetingParticipantItem

+ 2
- 0
react/features/participants-pane/components/native/ParticipantsPane.js View File

@@ -54,7 +54,9 @@ export function ParticipantsPane() {
54 54
             <View style = { styles.footer }>
55 55
                 <Button
56 56
                     children = { t('participantsPane.actions.muteAll') }
57
+                    contentStyle = { styles.muteAllContent }
57 58
                     labelStyle = { styles.muteAllLabel }
59
+                    mode = 'contained'
58 60
                     onPress = { muteAll }
59 61
                     style = { styles.muteAllButton } />
60 62
                 <Button

+ 4
- 0
react/features/participants-pane/components/native/styles.js View File

@@ -268,6 +268,10 @@ export default {
268 268
         left: BaseTheme.spacing[10] + BaseTheme.spacing[2]
269 269
     },
270 270
 
271
+    muteAllContent: {
272
+        ...buttonContent
273
+    },
274
+
271 275
     muteAllLabel: {
272 276
         color: BaseTheme.palette.text01,
273 277
         textTransform: 'capitalize'

Loading…
Cancel
Save