From 84f18a1c6e1255e2ab9eff1f7d6fb92bac924391 Mon Sep 17 00:00:00 2001 From: Perry Govier Date: Mon, 6 Oct 2014 14:56:35 -0500 Subject: [PATCH] fix(content): don't resize content on keyboard open if it's inside a modal. Fixes #2212 --- js/views/scrollView.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/views/scrollView.js b/js/views/scrollView.js index f7008e319b..cf23907c4e 100644 --- a/js/views/scrollView.js +++ b/js/views/scrollView.js @@ -629,7 +629,8 @@ ionic.views.Scroll = ionic.views.View.inherit({ if( !self.isScrolledIntoView ) { // shrink scrollview so we can actually scroll if the input is hidden // if it isn't shrink so we can scroll to inputs under the keyboard - if (ionic.Platform.isIOS() || ionic.Platform.isFullScreen){ + if((ionic.Platform.isIOS() || ionic.Platform.isFullScreen) && !container.parentNode.classList.contains('modal')){ + // if there are things below the scroll view account for them and // subtract them from the keyboard height when resizing scrollBottomOffsetToTop = container.getBoundingClientRect().bottom;