From 4567de2aead9676fc819448742d63537ff1e3fa3 Mon Sep 17 00:00:00 2001 From: Brandy Carney Date: Mon, 27 Jun 2016 12:13:26 -0400 Subject: [PATCH] fix(content): adjust footer bottom based on the tabbar without padding --- src/components/content/content.ts | 8 ++++---- src/components/content/test/basic/page2.html | 3 +++ src/components/content/test/fullscreen/page2.html | 3 +++ 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/components/content/content.ts b/src/components/content/content.ts index 63b5736f71..59b526791d 100644 --- a/src/components/content/content.ts +++ b/src/components/content/content.ts @@ -530,14 +530,14 @@ export class Content extends Ion { newVal = this._footerHeight + this._paddingBottom; if (this._tabbarPlacement === 'bottom') { newVal += this._tabbarHeight; + + if (newVal > 0 && this._footerEle) { + this._footerEle.style.bottom = (newVal - this._footerHeight - this._paddingBottom) + 'px'; + } } if (newVal !== this.adjustedBottom) { scrollEle.style.paddingBottom = (newVal > 0 ? newVal + 'px' : ''); this.adjustedBottom = newVal; - - if (newVal > 0 && this._footerEle) { - this._footerEle.style.bottom = (newVal - this._footerHeight) + 'px'; - } } } else { diff --git a/src/components/content/test/basic/page2.html b/src/components/content/test/basic/page2.html index ba3bf875cf..482b24cbd6 100644 --- a/src/components/content/test/basic/page2.html +++ b/src/components/content/test/basic/page2.html @@ -28,6 +28,9 @@ Footer + + Footer 2 +