Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mayi-mp-shop
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
程默
mayi-mp-shop
Commits
58ba58b7
Commit
58ba58b7
authored
Jan 25, 2024
by
侯体倬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商品列表布局样式优化(高度一致)
parent
303302ae
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
6 deletions
+10
-6
static/nativeComponents/GoodsList/GoodsItem/index.wxml
+1
-1
static/nativeComponents/GoodsList/GoodsItem/index.wxss
+1
-0
static/nativeComponents/GoodsList/index.wxml
+4
-4
static/nativeComponents/GoodsList/index.wxss
+4
-1
No files found.
static/nativeComponents/GoodsList/GoodsItem/index.wxml
View file @
58ba58b7
<!-- 商品列表item -->
<view
class="goodsItem {{datas.componentData.style==='rowList'?'goodsRowList':''}} {{datas.componentData.style==='heap'?'goodsRowList goodsHeapItem':''}}"
style="--proGap2:{{datas.componentData.proGap*2}}rpx;"
style="--proGap2:{{datas.componentData.proGap*2}}rpx;
width: 100%;
"
bindtap="onclickProduct"
>
<view class="goods-item-child {{datas.componentData['borderColorShow']?'goods-item-child-bd':''}}" style="border-radius:{{datas.componentData.borderRadius*2}}rpx;--border_color:{{datas.componentData['borderColor']}};box-shadow:{{datas.componentData['cardShadow']?'0rpx 0rpx 10rpx '+datas.componentData['cardShadowSize']*2+'rpx #ccc':''}};">
...
...
static/nativeComponents/GoodsList/GoodsItem/index.wxss
View file @
58ba58b7
...
...
@@ -17,6 +17,7 @@ image{
position: relative;
overflow: hidden;
background: #fff;
height: 100%;
}
.goodsRowList .goods-item-child{
display: flex;
...
...
static/nativeComponents/GoodsList/index.wxml
View file @
58ba58b7
...
...
@@ -67,7 +67,7 @@
wx:for="{{pageGoodsList[datasIndex]}}"
wx:key="index"
class="goods-item {{'goodsItemIndex'+index}}"
style="width:{{100/datas.componentData.columnNum}}%;padding-left:{{datas.componentData.proGap*2}}rpx"
style="width:{{100/datas.componentData.columnNum}}%;padding-left:{{datas.componentData.proGap*2}}rpx
;display:flex;
"
>
<!-- <goods-item
datas="{{datas}}"
...
...
@@ -97,7 +97,7 @@
wx:for="{{datas.componentData.goodsList}}"
wx:key="index"
class="goods-item"
style="width:{{100/datas.componentData.columnNum}}%;margin-right:{{datas.componentData.proGap*2}}rpx"
style="width:{{100/datas.componentData.columnNum}}%;margin-right:{{datas.componentData.proGap*2}}rpx
;display:flex;
"
>
<goods-item
datas="{{datas}}"
...
...
@@ -131,7 +131,7 @@
wx:for="{{pageGoodsList[datasIndex]}}"
wx:key="index"
class="goods-item"
style="width:{{100/datas.componentData.columnNum}}%;padding-left:{{datas.componentData.proGap*2}}rpx"
style="width:{{100/datas.componentData.columnNum}}%;padding-left:{{datas.componentData.proGap*2}}rpx
;display:flex;
"
>
<goods-item
datas="{{datas}}"
...
...
@@ -155,7 +155,7 @@
<block wx:for="{{swipeInfo}}">
<swiper-item>
<view class="goods-item" style="display: grid;gap:{{datas.componentData.proGap*2}}rpx;grid-template-columns:repeat({{datas.componentData.columnNum}}, 1fr)">
<view wx:for="{{item}}" wx:for-index="indey">
<view wx:for="{{item}}" wx:for-index="indey"
style="display:flex;"
>
<goods-item
datas="{{datas}}"
items="{{datas.componentData.goodsList[index * datas.componentData.columnNum + indey]}}"
...
...
static/nativeComponents/GoodsList/index.wxss
View file @
58ba58b7
...
...
@@ -5,6 +5,10 @@
image{
width: 100%;
}
goods-item {
display: flex;
flex: 1;
}
.goodsList{
font-size: 32rpx;
position: relative;
...
...
@@ -169,7 +173,6 @@ image{
white-space: nowrap;
padding-bottom: 10rpx;
display: flex;
align-items: flex-start;
}
.goods-across .prev-btn,.goods-across .next-btn{
position: absolute;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment