Commit ff263a9e by 李嘉林

修改

parent c869e65c
<!--static/nativeComponents/CubeNav/index.wxml--> <!--static/nativeComponents/CubeNav/index.wxml-->
<view class="cube-nav" style="padding-top:{{datas.componentData.verticalMargin * 2}}rpx;padding-bottom:{{datas.componentData.verticalMargin * 2}}rpx;padding-left:{{datas.componentData.levelMargin * 2}}rpx;padding-right:{{datas.componentData.levelMargin * 2}}rpx"> <view class="cube-nav" style="background-color:{{datas.componentData.backgroundColor || ''}};padding-top:{{datas.componentData.verticalMargin * 2}}rpx;padding-bottom:{{datas.componentData.verticalMargin * 2}}rpx;padding-left:{{datas.componentData.levelMargin * 2}}rpx;padding-right:{{datas.componentData.levelMargin * 2}}rpx">
<view class="cube1 clearfix" wx:if="{{datas.componentData.layoutType == 0}}" style="background-color:{{datas.componentData.backgroundColor || ''}};border-radius:{{datas.componentData.moduleRadius * 2}}rpx"> <view class="cube1 clearfix" wx:if="{{datas.componentData.layoutType == 0}}" style="margin-left:{{-datas.componentData.singleVerticalMargin*2}}rpx;border-radius:{{datas.componentData.moduleRadius * 2}}rpx">
<view class="cube-item" wx:for="{{imgList}}" style="padding-top:{{datas.componentData.lineHeight * 2}}rpx;padding-bottom:{{datas.componentData.lineHeight * 2}}rpx;width:{{getColumnWidth}};position:relative" bindtap="onclickHandle" data-item="{{item}}"> <view class="cube-bg" wx:for="{{imgList}}" data-item="{{item}}" style="padding-left:{{datas.componentData.singleVerticalMargin*2}}rpx;width:{{getColumnWidth}};">
<view class="cube-item" style="padding-top:{{datas.componentData.singleLevelMargin * 2}}rpx;padding-bottom:{{datas.componentData.singleLevelMargin * 2}}rpx;position:relative;background:{{datas.componentData.singleBackground}};border-radius:{{datas.componentData.singleRadius}}rpx;margin-top:{{datas.componentData.lineHeight}}rpx" bindtap="onclickHandle">
<view style="padding-left:{{getImgSize}}%;padding-right:{{getImgSize}}%"> <view style="padding-left:{{getImgSize}}%;padding-right:{{getImgSize}}%">
<view class="item-img {{item.imageUrl == '' ? 'item-bg' : ''}}"> <view class="item-img {{item.imageUrl == '' ? 'item-bg' : ''}}">
<image wx:if="{{item.imageUrl}}" src="{{item.imageUrl}}"></image> <image wx:if="{{item.imageUrl}}" src="{{item.imageUrl}}"></image>
...@@ -10,6 +11,7 @@ ...@@ -10,6 +11,7 @@
<view class="item-title" style="font-size:{{datas.componentData.textSize * 2}}rpx;color:{{datas.componentData.fontColor}};height:{{datas.componentData.textSize / 12}}em;line-height:{{datas.componentData.textSize / 12}}em">{{ item.title }}</view> <view class="item-title" style="font-size:{{datas.componentData.textSize * 2}}rpx;color:{{datas.componentData.fontColor}};height:{{datas.componentData.textSize / 12}}em;line-height:{{datas.componentData.textSize / 12}}em">{{ item.title }}</view>
</view> </view>
</view> </view>
</view>
<view wx:if="{{datas.componentData.layoutType == 1}}" style="position:relative;background-color:{{datas.componentData.backgroundColor || ''}};border-radius:{{datas.componentData.moduleRadius}}px;padding-bottom:{{navShow ? '10px' : '0'}}"> <view wx:if="{{datas.componentData.layoutType == 1}}" style="position:relative;background-color:{{datas.componentData.backgroundColor || ''}};border-radius:{{datas.componentData.moduleRadius}}px;padding-bottom:{{navShow ? '10px' : '0'}}">
<view class="cube2 clearfix" style="overflow-x:auto;overflow-y:hidden" bindtouchend="touchmove"> <view class="cube2 clearfix" style="overflow-x:auto;overflow-y:hidden" bindtouchend="touchmove">
......
...@@ -16,14 +16,22 @@ ...@@ -16,14 +16,22 @@
box-sizing: border-box; box-sizing: border-box;
font-size: 16rpx; font-size: 16rpx;
} }
.cube-bg{
float: left;
box-sizing: border-box;
}
.cube1,.cube2,.cube3{ .cube1,.cube2,.cube3{
width: 100%;
height: 100%; height: 100%;
box-sizing: border-box; box-sizing: border-box;
overflow: hidden; overflow: hidden;
position: relative; position: relative;
} }
.cube-item{ .cube-item {
width: 100%;
box-sizing: border-box;
}
.cube2 .cube-item,.cube3 .cube-item{
width: 100%;
float: left; float: left;
} }
.cube-item .item-img{ .cube-item .item-img{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment