Fix build error warning of Text module (#23586)

Summary:
Throw error warning when build Text module, we can add tvOS available check to remove error.

[iOS] [Fixed] - Fix build error warning of Text module
Pull Request resolved: https://github.com/facebook/react-native/pull/23586

Differential Revision: D14181198

Pulled By: cpojer

fbshipit-source-id: 6a62c831ba119ddcbc6effa0b24f22bd4588b982
This commit is contained in:
zhongwuzw
2019-02-21 23:09:52 -08:00
committed by Facebook Github Bot
parent 4a807761a4
commit d834197746

View File

@@ -235,7 +235,7 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithFrame:(CGRect)frame)
};
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 110000 /* __IPHONE_11_0 */
if (@available(iOS 11.0, *)) {
if (@available(iOS 11.0, tvOS 11.0, *)) {
NSDictionary<NSString *, NSString *> * iOS11extras = @{@"username": UITextContentTypeUsername,
@"password": UITextContentTypePassword};
@@ -247,7 +247,7 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithFrame:(CGRect)frame)
#endif
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 120000 /* __IPHONE_12_0 */
if (@available(iOS 12.0, *)) {
if (@available(iOS 12.0, tvOS 12.0, *)) {
NSDictionary<NSString *, NSString *> * iOS12extras = @{@"newPassword": UITextContentTypeNewPassword,
@"oneTimeCode": UITextContentTypeOneTimeCode};