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(base/modal): renamed prop and fixed scroll inside webview

Calin-Teodorccba7e8f757d
diff --git a/react/features/base/modal/components/JitsiKeyboardAvoidingView.js b/react/features/base/modal/components/JitsiKeyboardAvoidingView.js
index 483c0ea753..b0bfb98c0e 100644
--- a/react/features/base/modal/components/JitsiKeyboardAvoidingView.js
+++ b/react/features/base/modal/components/JitsiKeyboardAvoidingView.js
@@ -24,6 +24,11 @@ type Props = {
*/
contentContainerStyle?: StyleType,
+ /**
+ * Disable forced keyboard dismiss?
+ */
+ disableForcedKeyboardDismiss?: boolean,
+
/**
* Is a text input rendered at the bottom of the screen?
*/
@@ -34,11 +39,6 @@ type Props = {
*/
hasTabNavigator: boolean,
- /**
- * Is the keyboard already dismissible?
- */
- keyboardAlreadyDismissible?: boolean,
-
/**
* Additional style to be appended to the KeyboardAvoidingView.
*/
@@ -51,7 +51,7 @@ const JitsiKeyboardAvoidingView = (
contentContainerStyle,
hasTabNavigator,
hasBottomTextInput,
- keyboardAlreadyDismissible,
+ disableForcedKeyboardDismiss,
style
}: Props) => {
const headerHeight = useHeaderHeight();
@@ -74,7 +74,7 @@ const JitsiKeyboardAvoidingView = (
? headerHeight + StatusBar.currentHeight : headerHeight;
// Tells the view what to do with taps
- const shouldSetResponse = useCallback(() => !keyboardAlreadyDismissible);
+ const shouldSetResponse = useCallback(() => !disableForcedKeyboardDismiss);
const onRelease = useCallback(() => Keyboard.dismiss());
return (
diff --git a/react/features/base/modal/components/JitsiScreen.js b/react/features/base/modal/components/JitsiScreen.js
index d273bb8723..0fbffed2dd 100644
--- a/react/features/base/modal/components/JitsiScreen.js
+++ b/react/features/base/modal/components/JitsiScreen.js
@@ -22,6 +22,11 @@ type Props = {
*/
children: React$Node,
+ /**
+ * Disabled forced keyboard dismiss?
+ */
+ disableForcedKeyboardDismiss?: boolean,
+
/**
* Optional function that renders a footer component, if needed.
*/
@@ -37,11 +42,6 @@ type Props = {
*/
hasTabNavigator?: boolean,
- /**
- * Is the keyboard already dismissible?
- */
- keyboardAlreadyDismissible?: boolean,
-
/**
* Insets for the SafeAreaView.
*/
@@ -59,7 +59,7 @@ const JitsiScreen = ({
footerComponent,
hasTabNavigator = false,
hasBottomTextInput = false,
- keyboardAlreadyDismissible = false,
+ disableForcedKeyboardDismiss = false,
safeAreaInsets = [ 'left', 'right' ],
style
}: Props) => (
@@ -67,9 +67,9 @@ const JitsiScreen = ({
style = { styles.jitsiScreenContainer }>
<JitsiKeyboardAvoidingView
contentContainerStyle = { contentContainerStyle }
+ disableForcedKeyboardDismiss = { disableForcedKeyboardDismiss }
hasBottomTextInput = { hasBottomTextInput }
hasTabNavigator = { hasTabNavigator }
- keyboardAlreadyDismissible = { keyboardAlreadyDismissible }
style = { style }>
<SafeAreaView
edges = { safeAreaInsets }
diff --git a/react/features/base/modal/components/JitsiScreenWebView.js b/react/features/base/modal/components/JitsiScreenWebView.js
index 1c0166249c..cb6241c156 100644
--- a/react/features/base/modal/components/JitsiScreenWebView.js
+++ b/react/features/base/modal/components/JitsiScreenWebView.js
@@ -20,6 +20,7 @@ type Props = {
const JitsiScreenWebView = ({ source, style }: Props) => (
<JitsiScreen
+ disableForcedKeyboardDismiss = { true }
style = { style }>
<WebView source = {{ uri: source }} />
</JitsiScreen>
diff --git a/react/features/chat/components/native/Chat.js b/react/features/chat/components/native/Chat.js
index 563260328b..6746346f04 100644
--- a/react/features/chat/components/native/Chat.js
+++ b/react/features/chat/components/native/Chat.js
@@ -53,9 +53,9 @@ class Chat extends AbstractChat<Props> {
return (
<JitsiScreen
+ disableForcedKeyboardDismiss = { true }
hasBottomTextInput = { true }
hasTabNavigator = { true }
- keyboardAlreadyDismissible = { true }
style = { styles.chatContainer }>
<MessageContainer messages = { _messages } />
<MessageRecipient privateMessageRecipient = { privateMessageRecipient } />