Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions ios/RNSScreen.mm
Original file line number Diff line number Diff line change
Expand Up @@ -1725,6 +1725,19 @@ - (void)viewDidLayoutSubviews
}
#endif
}

if (self.screenView.isPresentedAsNativeModal) {
UIView *superview = self.view.superview;
if (superview != nil) {
// UIKit presents modals inside a UITransitionView. In RTL that container can be mirrored and
// report a negative origin. Copying the frame directly would offset the React view, so align
// it with the container's bounds to stay centered.
CGRect targetFrame = superview.bounds;
if (!CGRectEqualToRect(self.view.frame, targetFrame)) {
self.view.frame = targetFrame;
}
}
}
}

- (BOOL)isModalWithHeader
Expand Down