mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-22 13:32:54 +08:00
fix(content): adjust footer bottom based on the tabbar without padding
This commit is contained in:
@ -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 {
|
||||
|
@ -28,6 +28,9 @@
|
||||
<ion-toolbar class="opaque">
|
||||
<ion-title>Footer</ion-title>
|
||||
</ion-toolbar>
|
||||
<ion-toolbar class="opaque">
|
||||
<ion-title>Footer 2</ion-title>
|
||||
</ion-toolbar>
|
||||
</ion-footer>
|
||||
|
||||
<style>
|
||||
|
@ -28,6 +28,9 @@
|
||||
<ion-toolbar class="opaque">
|
||||
<ion-title>Footer</ion-title>
|
||||
</ion-toolbar>
|
||||
<ion-toolbar class="opaque">
|
||||
<ion-title>Footer 2</ion-title>
|
||||
</ion-toolbar>
|
||||
</ion-footer>
|
||||
|
||||
<style>
|
||||
|
Reference in New Issue
Block a user