纸通宝小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

33 lines
2.4 KiB

<view wx:if="{{listed && column > 0}}">
<view wx:for="{{imageList}}" wx:key="index" data-index="{{index}}" bindtap="viewImage" style="margin-top:{{index>0?16:0}}rpx">
<wux-image width="{{windowWidth}}" height="{{heightList[index] || windowWidth}}" ship="normal" src="{{item}}" mode="aspectFill" data-index="{{index}}" bind:load="onImageLoad">
<!-- <image class="image-load" slot="loading" style="border-radius: 0rpx;width{{windowWidth}}px;" src="/assets/image/def_image.png"></image> -->
</wux-image>
</view>
</view>
<view wx:elif="{{column == 1 && !square}}">
<wux-image width="{{width}}" height="{{height}}" src="{{imageList[0]}}" mode="aspectFill" bind:load="onImageLoad" bind:click="viewImage">
<image class="image-load" style="border-radius: 0rpx;width:{{width}}px;height:{{height}}px;" slot="loading" src="/assets/image/def_image.png"></image>
</wux-image>
</view>
<view wx:elif="{{column == 1}}" class="grid flex-sub padding-lr col-2 grid-square">
<view class="col2" style="border-radius: 0rpx;margin-right: 12rpx;margin-bottom: 12rpx;padding-bottom: 0prx;height: 115px;width: 115px" wx:for="{{imageList}}" wx:key="index" data-index="{{index}}" bindtap="viewImage">
<wux-image width="{{115}}" height="{{115}}" ship="normal" src="{{item}}" mode="aspectFill">
<image class="image-load" slot="loading" style="border-radius: 0rpx" src="/assets/image/def_image.png"></image>
</wux-image>
</view>
</view>
<view wx:elif="{{column == 2}}" class="grid flex-sub padding-lr col-2 grid-square">
<view class="col2" style="border-radius: 0rpx;margin-right: 12rpx;margin-bottom: 12rpx;padding-bottom: 0prx;height: 115px;width: 115px" wx:for="{{imageList}}" wx:key="index" data-index="{{index}}" bindtap="viewImage">
<wux-image width="{{115}}" height="{{115}}" ship="normal" src="{{item}}" mode="aspectFill">
<image class="image-load" slot="loading" style="border-radius: 0rpx" src="/assets/image/def_image.png"></image>
</wux-image>
</view>
</view>
<view wx:elif="{{column == 3}}" class="grid flex-sub padding-lr col-3 grid-square">
<view style="border-radius: 0rpx;margin-right: 12rpx;margin-bottom: 12rpx" wx:for="{{imageList}}" wx:key="index" data-index="{{index}}" bindtap="viewImage">
<wux-image width="{{115}}" height="{{115}}" ship="normal" src="{{item}}" mode="aspectFill">
<image class="image-load" slot="loading" style="border-radius: 0rpx" src="/assets/image/def_image.png"></image>
</wux-image>
</view>
</view>