From 1d77645a53d4caf294bc003be6fb1a8454ca1590 Mon Sep 17 00:00:00 2001 From: Kushal Dave Date: Fri, 2 Oct 2015 10:14:41 -0700 Subject: [PATCH] Set scrollsToTop = NO for UITextViews MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Summary: Complete the work from 853d5b2221a692110607ef12916263078141e107 by also fixing the placeholder view. Closes https://github.com/facebook/react-native/pull/3129 Reviewed By: @​svcscm Differential Revision: D2499753 Pulled By: @vjeux --- Libraries/Text/RCTTextView.m | 1 + 1 file changed, 1 insertion(+) diff --git a/Libraries/Text/RCTTextView.m b/Libraries/Text/RCTTextView.m index d21360ed26..5e24e3a1c0 100644 --- a/Libraries/Text/RCTTextView.m +++ b/Libraries/Text/RCTTextView.m @@ -78,6 +78,7 @@ RCT_NOT_IMPLEMENTED(- (instancetype)initWithCoder:(NSCoder *)aDecoder) _placeholderView = [[UITextView alloc] initWithFrame:self.bounds]; _placeholderView.backgroundColor = [UIColor clearColor]; _placeholderView.scrollEnabled = false; + _placeholderView.scrollsToTop = NO; _placeholderView.attributedText = [[NSAttributedString alloc] initWithString:_placeholder attributes:@{ NSFontAttributeName : (_textView.font ? _textView.font : [self defaultPlaceholderFont]),