getAllBarHeight 获取所有Bar的高度,状态栏高度、导航条高度、TabBar高度、底部弧形高度

getAllBarHeight ^7.10

获取所有Bar的高度,状态栏高度、导航条高度、TabBar高度、底部弧形高度

#请求参数

N/A

#接口调用示例

this.$bridge
  .getAllBarHeight()
  .then(res => {
    this.$alert(res)
  })
  .catch(err => {
    this.$toast(err)
  })

#接口返回示例

{
  statusBar: 20,//状态栏高度,如果隐藏状态栏则高度为0,
  navigatorBar: 44,//ios叫导航条高度,安卓叫标题栏,如果导航条隐藏则高度为0,
  tabBar:44, //底部首页-场景-发现-商城-我的组成的高度,如果隐藏则高度为0,
  bottomArc:34, // 刘海屏底部弧度高度,如果非刘海屏则为0,安卓没有
  bottomNavigator:30, // 安卓屏幕底部导航栏高度,安卓独有,ios没有
}
posted on 2024-12-12 09:20  AtlasLapetos  阅读(124)  评论(0)    收藏  举报