我通过动态判断添加的图片 在ios上不显示
app.globalData.tabbar.list = [
{
pagePath: "/pages/record/record",
text: "考勤记录",
iconPath: "star.png",
selectedIconPath: "score.png",
selected: true
},
{
pagePath: "/pages/statistics/statistics",
text: "考勤统计",
iconPath: "star.png",
selectedIconPath: "score.png",
selected: false
},
{
pagePath: "/pages/personalCenter/index/index",
text: "个人中心",
iconPath: "star.png",
selectedIconPath: "score.png",
selected: false
}
]
<cover-view class="tabbar_box" style="z-index:1000;background-color:{{tabbar[0].backgroundColor}}; {{tabbar[0].position == 'top' ? 'top:0' : 'bottom:0'}}">
<cover-view wx:for="{{tabbar[0].list}}" wx:for-item="item" wx:key="index" class='box box_row_center' style="width:{{1/tabbar[0].list.length*100}}%;background-color:#fff">
<cover-view class=" tabbar_nav " data-pagepath='{{item.pagePath}}' bindtap='goToTabber' style="width:100%; color:{{item.selected ? tabbar.selectedColor : tabbar.color}} " open-type="redirect ">
<cover-image class="tabbar_icon " src="/public/img/{{item.selected ? item.selectedIconPath : item.iconPath}} "></cover-image>
<cover-view>{{item.text}}</cover-view>
</cover-view>
</cover-view>
</cover-view>
因为会根据进来的人显示不同的tabber 动态渲染cover-image ios上不显示
关注,通遇到类似问题
ios下cover-image图片经常渲染不出来。加了wx:if还是解决不了
我放弃这种写法了 让设计改了页面
哦哦,感谢回复。
目前也是遇到这种情况,不过我的cover-image是嵌套在map组件。怎么整都不行。
我们也碰到这个问题了
你好,没有数据没有错误信息提醒的吗?