mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-29 18:06:01 +08:00
Add accessibilityLabel and testID on ButtonProperties and ViewProperties
This commit is contained in:
10
types/react-native/index.d.ts
vendored
10
types/react-native/index.d.ts
vendored
@@ -815,6 +815,11 @@ export interface TextPropertiesAndroid {
|
||||
|
||||
// https://facebook.github.io/react-native/docs/text.html#props
|
||||
export interface TextProperties extends TextPropertiesIOS, TextPropertiesAndroid {
|
||||
/**
|
||||
* The text that's read by the screen reader when the user interacts with the text.
|
||||
*/
|
||||
accessibilityLabel?: string;
|
||||
|
||||
/**
|
||||
* When set to `true`, indicates that the view is an accessibility element. The default value
|
||||
* for a `Text` element is `true`.
|
||||
@@ -6540,6 +6545,11 @@ export interface ButtonProperties {
|
||||
color?: string;
|
||||
accessibilityLabel?: string;
|
||||
disabled?: boolean;
|
||||
|
||||
/**
|
||||
* Used to locate this button in end-to-end tests.
|
||||
*/
|
||||
testID?: string;
|
||||
}
|
||||
|
||||
export interface ButtonStatic extends React.ComponentClass<ButtonProperties> {}
|
||||
|
||||
Reference in New Issue
Block a user