Skip to content

Commit 58720fc

Browse files
committed
Fix bottom height with env(safe-area-inset-bottom)
1 parent edf302a commit 58720fc

File tree

5 files changed

+4
-6
lines changed

5 files changed

+4
-6
lines changed

src/components/templates.wxml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@
217217

218218
<!--toobar-->
219219
<template name="toolbar">
220-
<view class="toolbar" style="padding-bottom: {{bottomHeight}}rpx;">
220+
<view class="toolbar" style="padding-bottom: env(safe-area-inset-bottom);">
221221
<view class="flex_item" catchtap="reply">
222222
<image src="/assets/reply.svg" class="size30" animation="{{replyPop}}" />
223223
</view>
@@ -235,7 +235,7 @@
235235

236236
<!--toobar-->
237237
<template name="toolbar_msg">
238-
<view class="toolbar" style="padding-bottom: {{bottomHeight}}rpx;">
238+
<view class="toolbar" style="padding-bottom: env(safe-area-inset-bottom);">
239239
<view class="flex_item" catchtap="reply">
240240
<image src="/assets/reply.svg" class="size30" animation="{{replyPop}}" />
241241
</view>

src/pages/feed/feed.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ Page(
1111
extend({}, tap, post, {
1212
data: {
1313
statusBarHeight: wx.getSystemInfoSync().statusBarHeight,
14-
bottomHeight: wx.getSystemInfoSync().statusBarHeight,
1514
hide: false,
1615
},
1716
onLoad(event) {

src/pages/feed/feed.wxml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<view class="aboveToolbar" style="padding-top: {{param ? 235: 0}}px;">
55
<template is="feeds_context" data="{{feed, feeds_arr, imageFadeIn, userAvatarFadeIn, hide}}" />
66
</view>
7-
<template wx:if="{{!hide}}" is="toolbar" data="{{feed, replyPop, repostPop, starPop, deletePop, bottomHeight}}" />
7+
<template wx:if="{{!hide}}" is="toolbar" data="{{feed, replyPop, repostPop, starPop, deletePop}}" />
88
</block>
99
<block wx:if="{{param}}">
1010
<view class="mask">

src/pages/message/message.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ Page(
1212
id: null,
1313
data: {
1414
statusBarHeight: wx.getSystemInfoSync().statusBarHeight,
15-
bottomHeight: wx.getSystemInfoSync().statusBarHeight,
1615
},
1716
onLoad(event) {
1817
this.setData({i18n})

src/pages/message/message.wxml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<template is="message_arr" data="{{message_arr: feeds_arr}}" />
55
</view>
66
<template data="{{showLoader}}" is="loader" />
7-
<template is="toolbar_msg" data="{{feed, replyPop, bottomHeight}}" />
7+
<template is="toolbar_msg" data="{{feed, replyPop}}" />
88
<block wx:if="{{param}}">
99
<view class="mask">
1010
<template is="post" data="{{param, posting, autoFocus: true, noPhoto: true, length, i18n, resetPop, sendPop, statusBarHeight}}" />

0 commit comments

Comments
 (0)