getMenuButtonBoundingClientRect()模拟器返回值错误?
const MenuRect = wx.getMenuButtonBoundingClientRect() const statusBarHeight = wx.getSystemInfoSync().statusBarHeight; console.log(MenuRect, statusBarHeight); |
//{width: 87, height: 32, left: 278, top: 6, right: 365, …} 20 |
状态栏高度没理由会比胶囊的top值要大。
真机测试没这个问题。
开发工具版本1.02.1912062 for MAC.