Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

feat(chat/native): moved ChatAndPollsNavigator to mobile/navigation (#12527)

Calinteodor74cd4862321c
diff --git a/react/features/chat/components/native/index.js b/react/features/chat/components/native/index.js
index 1c87ba6a5a..0e3e81918d 100644
--- a/react/features/chat/components/native/index.js
+++ b/react/features/chat/components/native/index.js
@@ -1,6 +1,5 @@
// @flow
export { default as Chat } from './Chat';
-export { default as ChatAndPolls } from './ChatAndPolls';
export { default as ChatButton } from './ChatButton';
export { default as ChatPrivacyDialog } from './ChatPrivacyDialog';
diff --git a/react/features/chat/components/native/ChatAndPolls.js b/react/features/mobile/navigation/components/chat/components/ChatAndPollsNavigator.tsx
similarity index 70%
rename from react/features/chat/components/native/ChatAndPolls.js
rename to react/features/mobile/navigation/components/chat/components/ChatAndPollsNavigator.tsx
index 65ce50aeb5..9ef3d50d0d 100644
--- a/react/features/chat/components/native/ChatAndPolls.js
+++ b/react/features/mobile/navigation/components/chat/components/ChatAndPollsNavigator.tsx
@@ -1,17 +1,22 @@
-// @flow
+/* eslint-disable lines-around-comment */
import { createMaterialTopTabNavigator } from '@react-navigation/material-top-tabs';
import React from 'react';
import { useSelector } from 'react-redux';
-import { Chat } from '../..';
import {
getClientHeight,
getClientWidth
-} from '../../../base/modal/components/functions.native';
-import { screen } from '../../../mobile/navigation/routes';
-import { chatTabBarOptions } from '../../../mobile/navigation/screenOptions';
-import { PollsPane } from '../../../polls/components';
+ // @ts-ignore
+} from '../../../../../base/modal/components/functions';
+// @ts-ignore
+import { Chat } from '../../../../../chat';
+// @ts-ignore
+import { PollsPane } from '../../../../../polls/components';
+// @ts-ignore
+import { screen } from '../../../routes';
+// @ts-ignore
+import { chatTabBarOptions } from '../../../screenOptions';
const ChatTab = createMaterialTopTabNavigator();
@@ -20,6 +25,7 @@ const ChatAndPolls = () => {
const clientWidth = useSelector(getClientWidth);
return (
+ // @ts-ignore
<ChatTab.Navigator
backBehavior = 'none'
initialLayout = {{
diff --git a/react/features/mobile/navigation/components/conference/components/ConferenceNavigationContainer.tsx b/react/features/mobile/navigation/components/conference/components/ConferenceNavigationContainer.tsx
index 6f3ee3871f..652fc9c02e 100644
--- a/react/features/mobile/navigation/components/conference/components/ConferenceNavigationContainer.tsx
+++ b/react/features/mobile/navigation/components/conference/components/ConferenceNavigationContainer.tsx
@@ -1,4 +1,5 @@
/* eslint-disable lines-around-comment */
+
import { NavigationContainer } from '@react-navigation/native';
import { createStackNavigator } from '@react-navigation/stack';
import React from 'react';
@@ -6,9 +7,10 @@ import { useTranslation } from 'react-i18next';
import { useSelector } from 'react-redux';
// @ts-ignore
-import { Chat, ChatAndPolls } from '../../../../../chat';
+import { Chat } from '../../../../../chat';
// @ts-ignore
import Conference from '../../../../../conference/components/native/Conference';
+// @ts-ignore
import CarMode from '../../../../../conference/components/native/carmode/CarMode';
// @ts-ignore
import { getDisablePolls } from '../../../../../conference/functions';
@@ -55,12 +57,12 @@ import {
speakerStatsScreenOptions
// @ts-ignore
} from '../../../screenOptions';
-import LobbyNavigationContainer
// @ts-ignore
- from '../../lobby/components/LobbyNavigationContainer';
-import SettingsNavigationContainer
+import ChatAndPollsNavigator from '../../chat/components/ChatAndPollsNavigator';
+// @ts-ignore
+import LobbyNavigationContainer from '../../lobby/components/LobbyNavigationContainer';
// @ts-ignore
- from '../../settings/components/SettingsNavigationContainer';
+import SettingsNavigationContainer from '../../settings/components/SettingsNavigationContainer';
import {
conferenceNavigationRef
// @ts-ignore
@@ -80,7 +82,7 @@ const ConferenceNavigationContainer = () => {
chatScreenName = screen.conference.chat;
chatTitleString = 'chat.title';
} else {
- ChatScreen = ChatAndPolls;
+ ChatScreen = ChatAndPollsNavigator;
chatScreenName = screen.conference.chatandpolls.main;
chatTitleString = 'chat.titleWithPolls';
}