+ extends Component
{
- state = {
- submitting: false
- };
+ _mounted: boolean;
/**
* Initializes a new {@code AbstractDialog} instance.
@@ -47,7 +38,7 @@ export default class AbstractDialog
* @param {Object} props - The read-only React {@code Component} props with
* which the new instance is to be initialized.
*/
- constructor(props: Object) {
+ constructor(props: P) {
super(props);
// Bind event handlers so they are only bound once per instance.
diff --git a/react/features/base/dialog/components/Dialog.native.js b/react/features/base/dialog/components/Dialog.native.js
index 1ecc0312b..501396d46 100644
--- a/react/features/base/dialog/components/Dialog.native.js
+++ b/react/features/base/dialog/components/Dialog.native.js
@@ -1,3 +1,6 @@
+// @flow
+
+import _ from 'lodash';
import React from 'react';
import { Modal, StyleSheet, TextInput } from 'react-native';
import Prompt from 'react-native-prompt';
@@ -7,7 +10,11 @@ import { translate } from '../../i18n';
import { LoadingIndicator } from '../../react';
import { set } from '../../redux';
-import AbstractDialog, { AbstractDialogPropTypes } from './AbstractDialog';
+import AbstractDialog from './AbstractDialog';
+import type {
+ Props as AbstractDialogProps,
+ State as AbstractDialogState
+} from './AbstractDialog';
import { dialog as styles } from './styles';
/**
@@ -27,21 +34,24 @@ const _SUBMIT_TEXT_TAG_VALUE = '_SUBMIT_TEXT_TAG_VALUE';
const _TAG_KEY = '_TAG_KEY';
/**
- * {@code Dialog}'s React {@code Component} prop types.
+ * The type of the React {@code Component} props of {@link Dialog}.
*/
-type DialogPropTypes = {
- ...AbstractDialogPropTypes,
+type Props = {
+ ...AbstractDialogProps,
/**
* I18n key to put as body title.
*/
- bodyKey: String
-}
+ bodyKey: String,
+
+ textInputProps: Object
+};
/**
- * Defines {@code Dialog}'s state.
+ * The type of the React {@code Component} state of {@link Dialog}.
*/
-type DialogState = {
+type State = {
+ ...AbstractDialogState,
/**
* The text of the {@link TextInput} rendered by {@link Prompt} in
@@ -50,18 +60,13 @@ type DialogState = {
* functionality of {@code Prompt} because this {@code Dialog} does not
* really render the (whole) {@code Prompt}.
*/
- text: String
-}
+ text: string
+};
/**
* Implements {@code AbstractDialog} on react-native using {@code Prompt}.
*/
-class Dialog extends AbstractDialog