小(xiǎo)程序開(kāi)發引用了vant weapp,發現actionsheet組件彈出時會被小(xiǎo)程序原生(shēng)tabbar擋住,設置了actionsheet z-index也不行。
解決辦法
小(xiǎo)程序原生(shēng)tabbar層級是最高的,所以無解,改用小(xiǎo)程序原生(shēng)actionsheet。
wx.showActionSheet({
itemList: ['從相冊中(zhōng)選擇', '拍照'],
itemColor: "#f7982a",
success: function (res) {
if (!res.cancel) {
if (res.tapIndex == 0) {
_this.chooseWxImage('album', '')
} else if (res.tapIndex == 1) {
_this.chooseWxImage('camera', '')
}
}
}
})
- 版權所有:奇站網絡 轉載請注明出處
- 廈門市中資源網絡服務有限公司,專業提供網站建設,響應式網站建設,小(xiǎo)程序開(kāi)發,系統定制開(kāi)發。
- 軟件開(kāi)發咨詢熱線:吳小(xiǎo)姐 13313868605