开始做充值,,调整了首页
This commit is contained in:
36
components/navigatorWrapper/index.js
Normal file
36
components/navigatorWrapper/index.js
Normal file
@@ -0,0 +1,36 @@
|
||||
// components/navigatorWrapper/index.js
|
||||
Component({
|
||||
|
||||
/**
|
||||
* 组件的属性列表
|
||||
*/
|
||||
properties: {
|
||||
statusBarHeight: 0,
|
||||
},
|
||||
attached: function() {
|
||||
const that = this;
|
||||
wx.getSystemInfo({
|
||||
success: function (res) {
|
||||
that.setData({
|
||||
statusBarHeight : res.statusBarHeight,
|
||||
navBarHeight : res.statusBarHeight , // 顶部导航栏高度为 44px
|
||||
jiaonangheight: wx.getMenuButtonBoundingClientRect().height, // 胶囊高度
|
||||
jiaonangwidth:wx.getMenuButtonBoundingClientRect().width,
|
||||
})
|
||||
},
|
||||
})
|
||||
},
|
||||
/**
|
||||
* 组件的初始数据
|
||||
*/
|
||||
data: {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 组件的方法列表
|
||||
*/
|
||||
methods: {
|
||||
|
||||
}
|
||||
})
|
4
components/navigatorWrapper/index.json
Normal file
4
components/navigatorWrapper/index.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
2
components/navigatorWrapper/index.wxml
Normal file
2
components/navigatorWrapper/index.wxml
Normal file
@@ -0,0 +1,2 @@
|
||||
<!-- 由于自定义navigator,使用了固定定位,所以需要一个同等高度的东西填充这段空白,防止内容被遮挡 -->
|
||||
<view class="wrapper" style="height: {{statusBarHeight + 46}}px"></view>
|
1
components/navigatorWrapper/index.wxss
Normal file
1
components/navigatorWrapper/index.wxss
Normal file
@@ -0,0 +1 @@
|
||||
/* components/navigatorWrapper/index.wxss */
|
Reference in New Issue
Block a user