aboutsummaryrefslogtreecommitdiff
path: root/src/App.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/App.tsx')
-rw-r--r--src/App.tsx10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/App.tsx b/src/App.tsx
index 217f0627..8d823e1f 100644
--- a/src/App.tsx
+++ b/src/App.tsx
@@ -2,6 +2,7 @@ import {NavigationContainer} from '@react-navigation/native';
import React, {useState} from 'react';
import {Provider} from 'react-redux';
import {StreamChat} from 'stream-chat';
+import {OverlayProvider} from 'stream-chat-react-native';
import {STREAM_CHAT_API} from './constants';
import {navigationRef} from './RootNavigation';
import Routes from './routes';
@@ -17,6 +18,7 @@ import {
LocalResponseType,
LocalUserType,
} from './types';
+import {isIPhoneX} from './utils';
export const ChatContext = React.createContext({} as ChatContextType);
@@ -37,9 +39,11 @@ const App = () => {
*/
<Provider store={store}>
<NavigationContainer ref={navigationRef}>
- <ChatContext.Provider value={{channel, setChannel, chatClient}}>
- <Routes />
- </ChatContext.Provider>
+ <OverlayProvider bottomInset={isIPhoneX() ? 80 : 50}>
+ <ChatContext.Provider value={{channel, setChannel, chatClient}}>
+ <Routes />
+ </ChatContext.Provider>
+ </OverlayProvider>
</NavigationContainer>
</Provider>
);