diff --git a/packages/react-native/React/CoreModules/RCTLogBoxView.mm b/packages/react-native/React/CoreModules/RCTLogBoxView.mm index 3b003a28a5d..79f9aa288a4 100644 --- a/packages/react-native/React/CoreModules/RCTLogBoxView.mm +++ b/packages/react-native/React/CoreModules/RCTLogBoxView.mm @@ -20,7 +20,9 @@ - (instancetype)initWithFrame:(CGRect)frame { if ((self = [super initWithFrame:frame]) != nullptr) { +#if !TARGET_OS_TV self.windowLevel = UIWindowLevelStatusBar - 1; +#endif self.backgroundColor = [UIColor clearColor]; } return self; @@ -40,7 +42,9 @@ { self = [super initWithWindowScene:window.windowScene]; +#if !TARGET_OS_TV self.windowLevel = UIWindowLevelStatusBar - 1; +#endif self.backgroundColor = [UIColor clearColor]; _surface = [[RCTSurface alloc] initWithBridge:bridge moduleName:@"LogBox" initialProperties:@{}]; diff --git a/packages/react-native/React/CoreModules/RCTRedBox.mm b/packages/react-native/React/CoreModules/RCTRedBox.mm index fb057b96921..f0dbb32bad1 100644 --- a/packages/react-native/React/CoreModules/RCTRedBox.mm +++ b/packages/react-native/React/CoreModules/RCTRedBox.mm @@ -108,8 +108,10 @@ _stackTraceTableView.delegate = self; _stackTraceTableView.dataSource = self; _stackTraceTableView.backgroundColor = [UIColor clearColor]; +#if !TARGET_OS_TV _stackTraceTableView.separatorColor = [UIColor colorWithWhite:1 alpha:0.3]; _stackTraceTableView.separatorStyle = UITableViewCellSeparatorStyleNone; +#endif _stackTraceTableView.indicatorStyle = UIScrollViewIndicatorStyleWhite; [self.view addSubview:_stackTraceTableView]; @@ -308,8 +310,10 @@ RCT_NOT_IMPLEMENTED(-(instancetype)initWithCoder : (NSCoder *)aDecoder) [fullStackTrace appendFormat:@" %@\n", [self formatFrameSource:stackFrame]]; } } +#if !TARGET_OS_TV UIPasteboard *pb = [UIPasteboard generalPasteboard]; [pb setString:fullStackTrace]; +#endif } - (NSString *)formatFrameSource:(RCTJSStackFrame *)stackFrame diff --git a/packages/react-native/React/Modules/RCTRedBoxExtraDataViewController.m b/packages/react-native/React/Modules/RCTRedBoxExtraDataViewController.m index 6afd630eac2..c3c089d8598 100644 --- a/packages/react-native/React/Modules/RCTRedBoxExtraDataViewController.m +++ b/packages/react-native/React/Modules/RCTRedBoxExtraDataViewController.m @@ -108,7 +108,9 @@ _tableView.delegate = self; _tableView.dataSource = self; _tableView.backgroundColor = [UIColor colorWithRed:0.8 green:0 blue:0 alpha:1]; +#if !TARGET_OS_TV _tableView.separatorStyle = UITableViewCellSeparatorStyleNone; +#endif _tableView.indicatorStyle = UIScrollViewIndicatorStyleWhite; _tableView.allowsSelection = NO; [self.view addSubview:_tableView];