mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-12 19:59:02 +08:00
Merge pull request #28027 from iRoachie/rn-keyboard
feat(react-native): Add enabled prop to KeyboardAvoidingView
This commit is contained in:
7
types/react-native/index.d.ts
vendored
7
types/react-native/index.d.ts
vendored
@@ -2102,6 +2102,13 @@ export interface KeyboardAvoidingViewProps extends ViewProps {
|
||||
* may be non-zero in some use cases.
|
||||
*/
|
||||
keyboardVerticalOffset?: number;
|
||||
|
||||
/**
|
||||
* Enables or disables the KeyboardAvoidingView.
|
||||
*
|
||||
* Default is true
|
||||
*/
|
||||
enabled?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -68,6 +68,7 @@ import {
|
||||
TextInputEndEditingEventData,
|
||||
TextInputSubmitEditingEventData,
|
||||
WebView,
|
||||
KeyboardAvoidingView,
|
||||
} from "react-native";
|
||||
|
||||
declare module "react-native" {
|
||||
@@ -724,3 +725,8 @@ class AccessibilityTest extends React.Component {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
const KeyboardAvoidingViewTest = () => (
|
||||
<KeyboardAvoidingView enabled />
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user