微信小程序右上角胶囊的信息
右上角胶囊的信息,包含width、height、top等
let rect= wx.getMenuButtonBoundingClientRect();
机型信息
let info=wx.getSystemInfoSync();
胶囊底部到手机最上面的距离
rect.bottom
胶囊三个点到屏幕右边的距离
info.screenWidth-rect.right+ rect.width*3/4+5
- 上一篇 »python打印各种三角形
- 下一篇 »两行css代码实现居中元素