页面组件
<view class="goods-content">
<image class="goods-image" src="" mode="aspectFit"></image>
</view>
css部分
<style lang="scss">
.goods-content{
.goods-image::after{
display: block;
content: '';
position: absolute;
width: 100%;
height: 100%;
left: 0;
top: 0;
background: rgba(234,234,234,.6);
z-index: 9;
}
}
</style>