jufubao-mall 2.0.32-beta8 → 2.0.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/package.json +1 -1
  2. package/src/components/CusCouponChose/CusCouponChose.vue +13 -10
  3. package/src/components/CusEnter/CusEnter.vue +1 -9
  4. package/src/components/CusPoster/CusPoster.vue +62 -17
  5. package/src/components/CusProduct/CusProduct.vue +184 -576
  6. package/src/components/CusShops/CusShops.vue +209 -409
  7. package/src/components/CusTab/CusTab.vue +22 -159
  8. package/src/components/JfbMallProductInfo/cusAttr/content.js +0 -2
  9. package/src/components/JfbMallProductList/Attr.js +0 -1
  10. package/src/components/JfbMallProductList/JfbMallProductList.vue +1 -7
  11. package/src/components/JfbMallProductList/XdCateV1.vue +1 -0
  12. package/src/components/JfbMallShop/JfbMallShop.vue +1 -1
  13. package/src/components/JfbMallShop/cusAttr/content.js +1 -1
  14. package/src/components/SkeProduct/SkeProduct.vue +3 -88
  15. package/src/components/CusListItem/CusListItem.vue +0 -141
  16. package/src/components/CusPrice/CusPrice.vue +0 -391
  17. package/src/components/CusVipList/CusVipList.vue +0 -169
  18. package/src/components/JfbMallNetworkMedia/Api.js +0 -94
  19. package/src/components/JfbMallNetworkMedia/Attr.js +0 -20
  20. package/src/components/JfbMallNetworkMedia/JfbMallNetworkMedia.vue +0 -1167
  21. package/src/components/JfbMallNetworkMedia/JfbMallNetworkMediaLess.less +0 -80
  22. package/src/components/JfbMallNetworkMedia/JfbMallNetworkMediaMixin.js +0 -30
  23. package/src/components/JfbMallNetworkMedia/Mock.js +0 -372
  24. package/src/components/JfbMallNetworkMedia/cusAttr/advanced.js +0 -60
  25. package/src/components/JfbMallNetworkMedia/cusAttr/content.js +0 -230
  26. package/src/components/JfbMallNetworkMedia/cusAttr/font.js +0 -123
  27. package/src/components/JfbMallNetworkMedia/cusAttr/icon.js +0 -257
  28. package/src/components/JfbMallNetworkMedia/cusAttr/style.js +0 -12
@@ -1,20 +1,12 @@
1
1
  <template>
2
- <view
3
- class="product"
4
- :class="{
5
- two: cell >= 2 ,
6
- one: (cell === 1 && columnOneLayout === 'H'),
7
- oneV: (cell === 1 && columnOneLayout === 'V')
8
- }"
9
- @click="handleDetail()"
10
- >
2
+ <view class="product" :class="{two: cell >= 2 , one: cell === 1}" @click="handleDetail()">
11
3
  <view
12
4
  class="product-image"
13
5
  :style="{
14
6
  marginRight: (cell === 1 ? (cellSpacing + 'rpx'):0),
15
- marginBottom: (cell === 1&& columnOneLayout ==='H' ? 0: (cellSpacing + 'rpx')),
16
- width: (cell === 1 ? '240rpx': '100%'),
17
- height: (cell === 1 && columnOneLayout ==='H' ? '240rpx': (height + 'rpx')),
7
+ marginBottom: (cell === 1 ? 0: (cellSpacing + 'rpx')),
8
+ width: (cell === 1 ? '200rpx': '100%'),
9
+ height: (cell === 1 ? '200rpx': (height + 'rpx')),
18
10
  backgroundColor: '#f8f8f8',
19
11
  borderRadius: imageRadius + 'rpx',
20
12
  }"
@@ -22,75 +14,54 @@
22
14
  <image v-if="errorStatus" :src="errorImage" :alt="item['product_name']" ></image>
23
15
  <image v-if="!errorStatus" :src="imageUrl" :alt="item['product_name']" @error="handleError(item)"></image>
24
16
  <xd-product-status :status="item['status']"></xd-product-status>
25
- <view class="tagL" :style="[imgLs.length?imgLs[0]['css']:{},{top:imageRadius + 'rpx'}]" v-if="imgLs.length">{{imgLs[0].label}}</view>
26
- <view class="tagR" :style="[imgRs.length?imgRs[0]['css']:{},{top:imageRadius + 'rpx'}]" v-if="imgRs.length">{{imgRs[0].label}}</view>
27
17
  </view>
28
18
  <view class="product-content">
29
19
  <view class="product-content-info">
20
+
21
+ <view class="name" :style="[nameFont]" v-html="cusName" :class="{showOne: isOne}"></view>
30
22
  <view
31
- v-if="cell === 3"
32
- class="name showThree"
33
- :style="[nameFontComp,cutStringComp]"
34
- >
35
- <view class="nameTags" v-if="beTitles.length > 0">
36
- <view :key="beTitle.label" :style="[beTitle.css,cusTagComp]" v-for="beTitle in beTitles">{{beTitle.label}}</view>
37
- </view>
38
- <view class="nameCont" :style="{fontSize:columnOneLayout !=='H'?'32rpx': '28rpx'}">{{cusName}}</view>
39
- </view>
40
- <view
41
- v-else
42
- class="name"
43
- :style="[nameFontComp,cutStringComp]"
44
- :class="{showOne: isOne}"
45
- >
46
- <view class="nameTags" :style="{verticalAlign:columnOneLayout ==='V'?'middle':'top'}" v-if="beTitles.length > 0">
47
- <view :key="beTitle.label" :style="[beTitle.css,cusTagComp]" v-for="beTitle in beTitles">{{beTitle.label}}</view>
48
- </view>
49
- <view class="nameCont" :style="{fontSize:columnOneLayout !=='H'?'32rpx': '28rpx'}">{{cusName}}</view>
50
- </view>
51
- <view class="brandBox" v-if="productConfig.is_show_brand==='Y' || params.length > 0">
52
- <view
53
- class="brand"
54
- v-if="productConfig.is_show_brand==='Y'"
55
- :style="[brandStyle]"
56
- >{{item['brand_name']}}</view>
57
- <template v-for="(param,pIndex) in params">
58
- <view v-if="productConfig.is_show_brand==='Y' || pIndex >= 1" class="brand" :style="[param.css,{padding: '0 6rpx',fontSize: '20rpx'}]">|</view>
59
- <view class="brand" :style="[param.css]">{{param.label}}</view>
60
- </template>
61
- </view>
62
- <view
63
- v-if="tags.length > 0"
64
- class="tags"
65
- :class="{showTwo:!isOne, showThree: cell === 3}"
66
- :style="[showThreeTagsStyle]"
67
- >
23
+ class="brand"
24
+ v-if="productConfig.is_show_brand==='Y'"
25
+ :style="{color:brandColor}"
26
+ >{{item['brand_name']}}</view>
27
+ <view class="tags" :class="{showTwo:!isOne}">
68
28
  <view
69
- v-for="(tag,index) in tags"
70
- :key="index"
71
- class="_tag"
72
- :style="[tag.css]"
73
- >{{tag.label}}</view>
74
-
29
+ v-for="tag in tagsList"
30
+ :key="tag"
31
+ :style="{background:tagObjColor[tag]}"
32
+ >{{tagObj[tag]}}</view>
75
33
  </view>
34
+ <view class="_tag" v-for="(item,index) in item.postage_tags" :key="index">{{ item }}</view>
76
35
  </view>
77
- <view class="product-content-btn" v-if="isBtn" :class="{twoThree: isBtnHasMarginTop}">
78
- <view :class="{onePrice: onePrice, showThree: isPriceTwoRow }">
79
- <CusPrice v-if="productConfig.isPrice === 'Y'" :type="priceType" :isPlus="isPlus" :key="priceKey" :showPrice="showPriceComp"></CusPrice>
36
+ <view class="product-content-btn" v-if="isBtn">
37
+ <view :class="{onePrice: onePrice }">
38
+ <view v-if="productConfig.isPrice === 'Y'">
39
+ <xd-unit
40
+ :price="(item['promo_price'] || item['sale_price'])"
41
+ :isOld="false"
42
+ :iconSize="cell <= 2?0.3:0.26"
43
+ :fontSize="cell <= 2?36:26"
44
+ />
45
+ </view>
46
+ <view
47
+ v-if="productConfig.isShowDiscount==='Y' && checkDiscountPrice"
48
+ :style="{color:oldPriceColor}" class="oldPrice">
49
+ <xd-unit
50
+ :price="dividePrice"
51
+ :iconSize="0.21"
52
+ :fontSize="cell <= 2?24:22"
53
+ delete-line
54
+ is-gray
55
+ />
56
+ </view>
80
57
  </view>
81
- <view
82
- :class="{'cart-btn-auto': !isIcon}"
83
- :style="{height:cartSize+'rpx', width: cartSize + 'rpx',position:'absolute',right:0,bottom:'4rpx',zIndex: 300}"
84
- v-if="isShowCart && colorComp"
85
- >
86
- <view @click.stop="handleDetail('Y')">
58
+ <view>
59
+ <view @click.stop="handleDetail('Y')" v-if="productConfig.isAddCart === 'Y'">
87
60
  <xd-font-icon
88
- v-if="isIcon"
89
- :icon="cartIcon"
90
- :color="colorComp"
91
- :size="cartSize"
61
+ icon="icongouwuche-01"
62
+ :color="color"
63
+ size="40"
92
64
  ></xd-font-icon>
93
- <view v-else :style="[{color: colorComp},iconStyleComp,cartTextSize]" class="cart-btn">{{productConfig.cartName}}</view>
94
65
  </view>
95
66
  </view>
96
67
  </view>
@@ -103,30 +74,20 @@ import getServiceUrl from "@/common/getServiceUrl";
103
74
  import XdFontIcon from "@/components/XdFontIcon/XdFontIcon.vue";
104
75
  import XdProductStatus from "@/components/XdProductStatus/XdProductStatus";
105
76
  import XdUnit from "@/components/XdUnit/XdUnit.vue";
106
- import Color from "color";
107
- import CusPrice from '@/components/CusPrice/CusPrice.vue'
108
- import {getParentsStyles} from "@/utils/xd.base";
109
- import mpLoadingGVarMixins from "@/mixins/mpLoadingGVarMixins";
77
+
110
78
 
111
79
  export default {
112
80
  name: "CusProduct",
113
81
  components:{
114
82
  XdFontIcon,
115
83
  XdUnit,
116
- XdProductStatus,
117
- CusPrice
84
+ XdProductStatus
118
85
  },
119
- mixins:[mpLoadingGVarMixins],
120
86
  props:{
121
87
  keyword:{
122
88
  type:String,
123
89
  default:''
124
90
  },
125
- //一列(水平/垂直)布局
126
- columnOneLayout:{
127
- type:String,
128
- default:'H'
129
- },
130
91
  nameFont: {
131
92
  type:Object,
132
93
  default(){
@@ -144,12 +105,16 @@ export default {
144
105
  type: Number|String,
145
106
  default: 20
146
107
  },
108
+ rowSpacing: {
109
+ type: Number|String,
110
+ default: 20
111
+ },
147
112
  color:{
148
113
  type:String,
149
- default:'',
114
+ default:'red',
150
115
  },
151
116
  brandColor:{
152
- type: String|Object,
117
+ type: String,
153
118
  default: '#999'
154
119
  },
155
120
  oldPriceColor: {
@@ -168,138 +133,8 @@ export default {
168
133
  type:Object|null,
169
134
  default: null
170
135
  },
171
- isPlus: {
172
- type: Boolean,
173
- default: false
174
- },
175
136
  },
176
137
  computed:{
177
- cutStringComp(){
178
- return this.$root.getCutString(this.cell === 3?1:2, this.columnOneLayout !=='H'?32: 28)
179
- },
180
- nameFontComp(){
181
- if(this.$xdUniHelper.isEmpty(this.nameFont)) return {
182
- color: '#333',
183
- fontWeight: '500',
184
-
185
- };
186
- return {
187
- color: this.nameFont.color || '#333',
188
- fontWeight: this.nameFont.fontWeight || '500',
189
- }
190
- },
191
- isBtnHasMarginTop(){
192
- return !(this.tags.length > 0 || (this.productConfig.is_show_brand === 'Y' || this.params.length > 0));
193
- },
194
- showPriceComp(){
195
- if(this.$configProject['isPreview']) {
196
- if(this.isPlus) return this.item['show_prices'];
197
- else {
198
- return this.item['show_prices'].map(it=>{
199
- if(it.p > 1000000) it.p = Math.floor(this.$xdUniHelper.divisionFloatNumber(it.p, 10));
200
- return it
201
- })
202
- }
203
- }
204
- else return this.item['show_prices']
205
- },
206
- isShowCart(){
207
- if(this.productConfig.isAddCart === 'N') return false;
208
- else if(this.productConfig.isAddCart === 'Y') {
209
- return !(this.cell === 3 && this.isPlus);
210
- }else {
211
- return false
212
- }
213
- },
214
- cusTagComp(){
215
- //debugger
216
- if(this.cell === 1 && this.columnOneLayout !== 'H') {
217
- return {
218
- padding: '0 16rpx',
219
- borderRadius: '12rpx',
220
- fontSize: '28rpx',
221
- }
222
- }
223
- return {
224
- padding: '0 16rpx',
225
- }
226
- },
227
- cartSize(){
228
- let size = '52'
229
- if(this.cell === 1) {
230
- if(this.columnOneLayout === 'H') size = '52'
231
- else size = '64'
232
- }
233
- if(this.cell === 3) size = '40'
234
- return size
235
- },
236
- cartTextSize(){
237
- let size = '24rpx'
238
- let lh = '44rpx'
239
- let padding = '0 16rpx 0rpx';
240
-
241
- if(this.cell === 1) {
242
- if(this.columnOneLayout === 'H'){
243
- lh = '44rpx'
244
- size = '24rpx'
245
- padding = '0 20rpx 0'
246
- }
247
- else {
248
- size = '32rpx'
249
- lh = '64rpx'
250
- padding = '0 32rpx 0'
251
- }
252
- }
253
- return {
254
- fontSize:size,
255
- lineHeight: lh,
256
- padding,
257
- }
258
- },
259
- brandStyle(){
260
- if(typeof this.brandColor === 'string') return {color:this.brandColor}
261
- else {
262
- let isBgColor = true;
263
- let isBorColor = true;
264
-
265
- if(!this.brandColor.bgColor ||
266
- (this.brandColor.bgColor && Color(this.brandColor.bgColor).toString() === 'rgba(0, 0, 0, 0)')
267
- ) isBgColor = false;
268
- if(!this.brandColor.borderColor ||
269
- (this.brandColor.borderColor && Color(this.brandColor.borderColor).toString() === 'rgba(0, 0, 0, 0)')
270
- ) isBorColor = false;
271
-
272
- let padding = '0';
273
- let bgColor = 'rgb(0, 0, 0, 0)';
274
- let border = '0';
275
- let borderRadius = 0
276
- let marginTop = 0;
277
- if(isBgColor || isBorColor){
278
- padding = '0 10rpx';
279
- borderRadius = '10rpx'
280
- if(isBgColor) bgColor = this.brandColor.bgColor;
281
- if(isBorColor){
282
- border = `2rpx solid ${this.brandColor.borderColor}`;
283
- }
284
- }
285
- return {
286
- border: border,
287
- backgroundColor: bgColor,
288
- color: this.brandColor.color,
289
- padding,
290
- borderRadius,
291
- marginTop
292
- }
293
- }
294
- },
295
- isPriceTwoRow(){
296
- if(this.cell === 3) {
297
- if(this.productConfig.isPrice === 'N') return false;
298
- else if(this.productConfig.isShowDiscount === 'N') return false
299
- return true;
300
- }
301
- return false
302
- },
303
138
  onePrice(){
304
139
  if(this.cell === 1) return true;
305
140
  if(this.cell === 3) return false;
@@ -314,7 +149,7 @@ export default {
314
149
  },
315
150
  isOne(){
316
151
  let status = false;
317
- if(this.cell === 1 && this.columnOneLayout ==='H') status = false
152
+ if(this.cell === 1) status = false
318
153
  return status
319
154
  },
320
155
  isBtn(){
@@ -323,74 +158,26 @@ export default {
323
158
  dividePrice() {
324
159
  return this.$xdUniHelper.divisionFloatNumber(this.item.market_price, 100);
325
160
  },
326
- colorComp(){
327
- return this.color || this.mainColor
328
- },
329
- showThreeTagsStyle() {
330
- if(this.cell === 3) {
331
- return {height:'40rpx'}
161
+
162
+ checkDiscountPrice() {
163
+ if(this.productConfig.isPrice === 'N') return false
164
+ if (this.productConfig.isShowDiscount === 'Y') {
165
+ let price = Number(this.item.market_price) - Number(this.item.sale_price);
166
+ return this.$xdUniHelper.divisionFloatNumber(price,100) > Number(this.productConfig.differ);
332
167
  }
333
- return {}
334
- },
335
- priceType(){
336
- if(this.cell === 3) return 'three'
337
- if(this.cell === 2) return 'two'
338
- if(this.cell === 1) return 'one'
339
- },
340
- cartIcon(){
341
- return this.productConfig.cartIcon || 'icongouwuche-01';
342
- },
343
- isIcon(){
344
- return this.cartIcon.indexOf('btn_cart') === -1
168
+ return false
345
169
  },
346
- iconStyleComp(){
347
- if(this.isIcon === false){
348
- let css = this.cartIcon.split('_')[1];
349
- let bgColor ='#fff', border = 0, radius = 0, color = this.color || this.m;
350
- switch (css) {
351
- case 'cartFPlain':
352
- border = `1px solid ${color}`;
353
- break;
354
- case 'cartFFull':
355
- color = '#fff'
356
- bgColor = this.color;
357
- break;
358
- case 'cartCPlain':
359
- border = `1px solid ${color}`;
360
- radius = '22rpx';
361
- if(this.cell === 1 && this.columnOneLayout !== 'H') radius = '32rpx';
362
- break;
363
- case 'cartCFull':
364
- color = '#fff'
365
- bgColor = this.color;
366
- radius = '22rpx';
367
- if(this.cell === 1 && this.columnOneLayout !== 'H') radius = '32rpx';
368
- break;
369
- default:
370
- break;
170
+
171
+ tagsList(){
172
+ return (this.item['market_tags']||[]).filter(tag=>{
173
+ if(tag === 'flashsale') {
174
+ return this.productConfig.showActivityPrice === 'Y'
371
175
  }
372
- return {
373
- color: color,
374
- backgroundColor: bgColor,
375
- border,
376
- borderRadius:radius,
176
+ else {
177
+ return this.productConfig.isShowTag === 'Y'
377
178
  }
378
- }
379
- return {}
380
- },
381
- },
382
- watch:{
383
- item(){
384
- this.tags = [];
385
- this.beTitles = [];
386
- this.imgRs = [];
387
- this.imgLs = [];
388
- this.params = [];
389
- this.handleTagsInit();
179
+ })
390
180
  },
391
- showPriceComp() {
392
- this.priceKey = new Date().getTime();
393
- }
394
181
  },
395
182
  data(){
396
183
  return {
@@ -398,129 +185,20 @@ export default {
398
185
  tagObjColor: null,
399
186
  errorStatus: false,
400
187
  errorImage:'',
401
- tags:[],
402
- beTitles:[],
403
- imgRs:[],
404
- imgLs:[],
405
- params:[],
406
- mainColor: '',
407
- priceKey: 'priceKey'
408
188
  }
409
189
  },
410
- async created() {
411
- let style = await getParentsStyles(this.$parent);
412
- this.mainColor = style.$mainColor;
190
+ created() {
413
191
  this.tagObj = this.$colorConfig.productTags;
414
192
  this.tagObjColor = this.$colorConfig.productTagsColor;
415
- this.errorImage = getServiceUrl('/common/empty/product.png?v1=1','size4');
416
- this.handleTagsInit();
193
+ this.errorImage = getServiceUrl('/common/empty/product.png?v1=1','size4')
417
194
  },
418
195
  methods:{
419
- handleTagsInit(){
420
- if(this.item.tags && this.item.tags.length > 0) {
421
- this.item.tags.map(it=>{
422
- if(it['style']){
423
- let flag = this.$colorConfig['tagStyle'][it['style']];
424
- if(flag.radius) {
425
- it.css = this.btnStyleComp(flag,flag.radius);
426
- }
427
- else it.css = this.btnStyleComp(flag);
428
- }
429
- else {
430
- it.css = this.btnStyleComp(this.$colorConfig['tagStyle']['GR4']);
431
- }
432
- if(it.pos === 'tag') this.tags.push(it);
433
- else if(it.pos === 'beTitle') this.beTitles.push(it);
434
- else if(it.pos === 'imgR') this.imgRs.push(it);
435
- else if(it.pos === 'imgL') this.imgLs.push(it);
436
- else if(it.pos === 'param') this.params.push(it);
437
- else this.tags.push(it);
438
- })
439
- }
440
- },
441
196
  handleError(item){
442
197
  this.errorStatus = true;
443
198
  },
444
199
  handleDetail(type='N'){
445
200
  this.$emit('on-product-detail', {isCart:type,...this.item});
446
- },
447
- btnStyleComp({style, color, bgColor}, cusRadius='8rpx'){
448
- let c = '',bgc = '', border = 0, radius = 0, padding='0 10rpx';
449
- if(style) {
450
- switch (style) {
451
- case 'css1':
452
- c = color || '#999';
453
- padding = 0;
454
- break;
455
- case 'css2':
456
- c = color || '#999';
457
- bgc = bgColor;
458
- radius = cusRadius;
459
- break;
460
- case 'css3':
461
- c = color || '#999';
462
- bgc = bgColor;
463
- break;
464
- case 'css4':
465
- c = color ||'#999';
466
- bgc = bgColor ||'#fff';
467
- radius = cusRadius;
468
- border = `1px solid rgba(${Color(c).alpha(0.3).array().join(',')})`;
469
- break;
470
- case 'css5':
471
- c = color ||'#999';
472
- bgc = bgColor ||'#fff';
473
- radius = '0';
474
- border = `1px solid rgba(${Color(c).alpha(0.3).array().join(',')})`;
475
- break;
476
- case 'css6':
477
- c = color ||'#999';
478
- bgc = bgColor || '#fff';
479
- radius = cusRadius;
480
- border = `1px solid ${c}`
481
- break;
482
- case 'css7':
483
- c = color ||'#999';
484
- bgc = bgColor || '#fff';
485
- radius = '0';
486
- border = `1px solid ${c}`
487
- break;
488
- case 'css8':
489
- c = color||'#fff';
490
- bgc = bgColor;
491
- radius = cusRadius;
492
- break;
493
- case 'css9':
494
- c = color||'#fff';
495
- bgc = bgColor;
496
- break;
497
- case 'cssL':
498
- c = color;
499
- bgc = bgColor;
500
- radius = `0 ${cusRadius} ${cusRadius} 0`;
501
- padding = '0 20rpx 0 10rpx'
502
- break;
503
- case 'cssR':
504
- c = color;
505
- bgc = bgColor;
506
- radius = `${cusRadius} 0 0 ${cusRadius}`;
507
- padding = '0 10rpx 0 20rpx'
508
- break;
509
- default:
510
- c = color ||'#999'
511
- padding = 0;
512
- break;
513
- }
514
- return {
515
- color: c,
516
- backgroundColor: bgc,
517
- border,
518
- borderRadius:radius,
519
- padding
520
- }
521
- }
522
- else return {}
523
- },
201
+ }
524
202
  }
525
203
  }
526
204
  </script>
@@ -528,237 +206,167 @@ export default {
528
206
 
529
207
 
530
208
  <style scoped lang="less">
531
- .product {
532
-
533
- &.oneV {
534
- .product-image {
535
- flex-shrink: 0;
536
- position: relative;
537
- width: 100%!important;
538
- }
209
+ .product {
539
210
 
540
- .product-content {
541
- }
542
- }
211
+ &.one {
212
+ display: flex;
213
+ justify-content: space-between;
214
+ align-items: flex-start;
215
+ min-height: 200rpx;
543
216
 
544
- &.one {
545
- display: flex;
546
- justify-content: space-between;
547
- align-items: flex-start;
217
+ .product-image {
218
+ flex-shrink: 0;
219
+ position: relative;
220
+ }
548
221
 
549
- .product-image {
550
- flex-shrink: 0;
551
- position: relative;
222
+ .product-content {
223
+ flex: 1;
224
+ min-height: 200rpx;
225
+ display: flex;
226
+ justify-content: flex-start;
227
+ flex-flow: wrap;
228
+ align-content: space-between;
229
+ }
552
230
  }
553
231
 
554
- .product-content {
555
- flex: 1;
556
- min-height: 240rpx;
557
- display: flex;
558
- justify-content: flex-start;
559
- flex-flow: wrap;
560
- align-content: space-between;
232
+ &.two {
233
+ .product-image {
234
+ width: 100%;
235
+ display: flex;
236
+ flex-shrink: 0;
237
+ justify-content: center;
238
+ align-items: center;
239
+ position: relative;
240
+ & > image {
241
+ height: 100%;
242
+ width: 100%;
243
+ }
244
+ }
245
+
561
246
  }
562
- }
563
247
 
564
- &.two {
565
- .product-image {
566
- width: 100%;
567
- display: flex;
568
- flex-shrink: 0;
569
- justify-content: center;
570
- align-items: center;
571
- position: relative;
248
+ &-image {
249
+ overflow: hidden;
572
250
  & > image {
573
251
  height: 100%;
574
252
  width: 100%;
575
253
  }
576
254
  }
577
255
 
578
- }
579
-
580
- &-image {
581
- overflow: hidden;
582
- & > image {
583
- height: 100%;
584
- width: 100%;
585
- }
256
+ &-content {
257
+ overflow: hidden;
258
+ &-info {
586
259
 
587
- & .tagL {
588
- position: absolute;
589
- left: 0;
590
- font-size: 20rpx;
591
- line-height: 40rpx;
592
- }
593
-
594
- & .tagR {
595
- position: absolute;
596
- right: 0;
597
- font-size: 20rpx;
598
- line-height: 40rpx;
599
- }
600
- }
601
-
602
- &-content {
603
- overflow: hidden;
604
- &-info {
605
-
606
- }
607
-
608
- &-btn {
609
- width: 100%;
610
- display: flex;
611
- justify-content: space-between;
612
- align-items: center;
613
- position: relative;
614
-
615
- &.twoThree {
616
- margin-top: 18rpx;
617
- }
618
-
619
- & .showThree {
620
- height: 72rpx;
621
- display: flex;
622
- justify-content: flex-start;
623
- align-items: center;
624
- flex-flow: wrap;
625
- & > view {
626
- width: 100%;
627
- flex-shrink: 0;
628
- }
629
260
  }
630
261
 
631
- .onePrice {
262
+ &-btn {
263
+ width: 100%;
632
264
  display: flex;
633
- justify-content: flex-start;
265
+ justify-content: space-between;
634
266
  align-items: center;
635
267
 
636
- & > view:nth-child(2) {
637
- margin-left: 20rpx;
638
- }
639
- }
640
-
641
- & > view:first-child {
642
- flex: 1;
643
- & > view:first-child {
268
+ .onePrice {
644
269
  display: flex;
645
270
  justify-content: flex-start;
646
271
  align-items: center;
647
- overflow: hidden;
648
- }
649
- & > view:nth-child(2) {
650
- line-height: 30rpx;
272
+
273
+ & > view:nth-child(2) {
274
+ margin-left: 20rpx;
275
+ }
651
276
  }
652
- }
653
277
 
278
+ & > view:first-child {
279
+ flex: 1;
280
+ & > view:first-child {
281
+ height: 40rpx;
282
+ display: flex;
283
+ justify-content: flex-start;
284
+ align-items: center;
285
+ overflow: hidden;
286
+ }
287
+ & > view:nth-child(2) {
288
+ line-height: 30rpx;
289
+ }
290
+ }
654
291
 
655
292
 
656
- & > view:nth-child(2) {
657
- flex-shrink: 0;
658
- width: 40rpx;
659
- height: 40rpx;
660
- display: flex;
661
- justify-content: center;
662
- align-items: center;
663
- cursor: pointer;
664
- }
665
293
 
666
- .oldPrice {
667
- margin-left: 6rpx;
668
- }
294
+ & > view:nth-child(2) {
295
+ flex-shrink: 0;
296
+ width: 40rpx;
297
+ height: 40rpx;
298
+ display: flex;
299
+ justify-content: center;
300
+ align-items: center;
301
+ cursor: pointer;
302
+ }
669
303
 
670
- & .cart-btn-auto {
671
- width: auto!important;
304
+ .oldPrice {
305
+ margin-left: 6rpx;
306
+ }
672
307
  }
673
- }
674
-
675
- & .name {
676
- margin-bottom: 10rpx;
677
308
 
678
- & .nameTags {
679
- display: inline-block;
680
- vertical-align: top;
309
+ & .name {
310
+ margin-bottom: 10rpx;
311
+ line-height: 40rpx;
312
+ .uni-max-cut(2,80);
313
+ word-wrap: break-word;
314
+ word-break: break-all;
681
315
 
682
- & > view {
316
+ & > text {
683
317
  display: inline-block;
684
- vertical-align: top;
685
- font-size: 22rpx;
686
- margin-right: 10rpx;
318
+
687
319
  }
688
- }
689
320
 
690
- & .nameCont {
691
- line-height: 1.5;
692
- display: inline;
321
+ &.showOne {
322
+ .uni-max-cut(1,40);
323
+ }
693
324
  }
694
325
 
695
- &.showThree {
696
- .uni-max-cut(1,40);
697
- margin-bottom: 10rpx;
698
- }
699
- &.showOne {
700
- .uni-max-cut(1,40);
326
+ & .brand {
327
+ font-size: 22rpx;
328
+ line-height: 30rpx;
329
+ .uni-max-cut(1,30);
330
+ padding-bottom: 10rpx;
701
331
  }
702
- }
703
-
704
-
705
332
 
706
- & .brandBox {
707
- width: 100%;
708
- margin-bottom: 16rpx;
709
- font-size: 24rpx;
710
- .uni-max-cut(1,40);
711
- box-sizing: border-box;
712
-
713
- & > view {
714
- height: 36rpx;
715
- display: inline-block;
716
- vertical-align: middle;
717
- line-height: 36rpx;
718
- box-sizing: border-box;
719
- overflow: hidden;
720
- }
333
+ .tags {
334
+ display: flex;
335
+ justify-content: flex-start;
336
+ align-content: flex-start;
337
+ flex-flow: wrap;
721
338
 
339
+ &.showTwo {
340
+ & > view{
341
+ margin-bottom: 8rpx;
342
+ }
343
+ }
722
344
 
723
- }
345
+ & > view {
346
+ padding: 0 14rpx;
347
+ height: 32rpx;
348
+ line-height: 31rpx;
349
+ font-size: 20rpx;
350
+ color:#fff;
351
+ border-radius: 16rpx;
352
+ margin-right: 10rpx;
724
353
 
725
- & .tags {
726
- display: flex;
727
- justify-content: flex-start;
728
- align-content: flex-start;
729
- flex-flow: wrap;
730
- width: 100%;
731
-
732
- &.showThree {
733
- overflow: hidden;
734
- max-height: 40rpx;
735
- }
354
+ &:last-child {
355
+ margin-right: 0;
356
+ }
736
357
 
737
- &.showTwo {
738
- & > view{
739
- margin-bottom: 8rpx;
740
358
  }
741
359
  }
742
360
 
743
- & > view {
744
- padding: 0 16rpx;
745
- line-height: 34rpx;
746
- font-size: 20rpx;
747
- color:#fff;
748
- margin-right: 10rpx;
749
-
750
- &:last-child {
751
- margin-right: 0;
752
- }
753
-
754
- }
755
361
  }
756
-
757
- & .cart-btn {
758
- padding: 0 .5rem;
759
- box-sizing: border-box;
362
+ ._tag{
363
+ color: #FF661A;
364
+ border: 1px solid #FF661A;
365
+ border-radius: 8rpx;
366
+ font-size: 24rpx;
367
+ margin-right: 24rpx;
368
+ padding: 0rpx 10rpx;
369
+ margin-bottom: 20rpx
760
370
  }
761
-
762
371
  }
763
- }
764
372
  </style>