@conecli/cone-render 0.10.1-beta.4 → 0.10.1-beta.5

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 (50) hide show
  1. package/dist/api/index.ts +1 -1
  2. package/dist/common/const.ts +1 -1
  3. package/dist/common/index.h5.ts +1 -1
  4. package/dist/common/index.weapp.ts +1 -1
  5. package/dist/common/sgmCustomCode.ts +1 -1
  6. package/dist/components/ErrorBoundary.tsx +1 -1
  7. package/dist/components/base/CustomScrollView/index.tsx +1 -1
  8. package/dist/components/base/CustomVideo/index.tsx +1 -1
  9. package/dist/components/base/InOrOutViewObserver/index.tsx +1 -1
  10. package/dist/components/base/InViewRender/index.weapp.tsx +1 -1
  11. package/dist/components/base/LazyLayoutLoad/index.tsx +1 -1
  12. package/dist/components/base/LazyLayoutLoad/index.weapp.tsx +1 -1
  13. package/dist/components/base/LazyLoadImage/index.h5.module.scss +3 -0
  14. package/dist/components/base/LazyLoadImage/index.h5.tsx +1 -1
  15. package/dist/components/base/MobileCommonHeader/index.tsx +1 -1
  16. package/dist/components/base/NetworkDataError/index.module.scss +3 -0
  17. package/dist/components/base/NetworkDataError/index.tsx +1 -1
  18. package/dist/components/decorate/DecorateFloorModule/index.module.scss +11 -0
  19. package/dist/components/decorate/DecorateFloorModule/index.tsx +1 -1
  20. package/dist/components/decorate/EmptyFloorModule/index.tsx +1 -1
  21. package/dist/components/decorate/PlaceHolder/index.tsx +1 -1
  22. package/dist/components/floorItem.tsx +1 -1
  23. package/dist/components/remoteFloorItem.tsx +1 -1
  24. package/dist/interface/common.ts +1 -1
  25. package/dist/interface/component.ts +1 -1
  26. package/dist/interface/service.ts +1 -1
  27. package/dist/jumpEventReport/base.ts +1 -1
  28. package/dist/jumpEventReport/const.ts +1 -1
  29. package/dist/jumpEventReport/jdJumpJdApp.ts +1 -1
  30. package/dist/jumpEventReport/web.base.ts +1 -1
  31. package/dist/jumpEventReport/web.jd.ts +1 -1
  32. package/dist/modules/ContainerFloorList/index.h5.module.scss +1 -0
  33. package/dist/modules/ContainerFloorList/index.h5.tsx +1 -1
  34. package/dist/open/api/device.ts +1 -1
  35. package/dist/open/api/request.ts +1 -1
  36. package/dist/open/api/shopMember.ts +1 -1
  37. package/dist/open/api/util.ts +1 -1
  38. package/dist/open/components/index.ts +1 -1
  39. package/dist/sass/app.h5.scss +5 -0
  40. package/dist/sass/base.scss +45 -0
  41. package/dist/service/requestServer.ts +1 -1
  42. package/dist/utils/connectNativeJsBridge.ts +1 -1
  43. package/dist/utils/h5Utils.ts +1 -1
  44. package/dist/utils/index.h5.ts +1 -1
  45. package/dist/utils/index.ts +1 -1
  46. package/dist/utils/index.weapp.ts +1 -1
  47. package/dist/utils/sgmCodeUtils.ts +1 -1
  48. package/dist/utils/taroRenderUtil.ts +1 -1
  49. package/dist/utils/utils.ts +1 -1
  50. package/package.json +24 -23
@@ -52,6 +52,7 @@
52
52
  width: 100%;
53
53
  z-index: 999;
54
54
  background: black;
55
+ margin-bottom: 16px;
55
56
  }
56
57
  .d-container-list-no-data {
57
58
  min-height: 400px;
@@ -1 +1 @@
1
- import React from 'react'
2
1
  isJdApp,
3
2
  isChartH5,
4
3
  NETWORK_DATA_TYPE,
5
4
  M_SHOP_DOWNLOAD_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT,
6
5
  APP_SHOP_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT,
7
6
  containerFloorListData: ComponentInterFace.ContainerItemData[]
8
7
  className?: string
9
8
  containerItemClass?: object
10
9
  style?: object
11
10
  hasGoodsFeeds?: boolean
12
11
  builtInComponents?: Object
13
12
  loadingEndComponentFn?: Function
14
13
  sectionType?: string
15
14
  updateShopFloorDataFn?: Function
16
15
  updateContainerFloorListDataFn?: Function
17
16
  customErrorIsvFloorModule?: React.ReactElement
18
17
  componentExtend?: React.ReactElement
19
18
  const { windowHeight } = taroJdBaseInfo.info.sysInfo
20
19
  const {
21
20
  className,
22
21
  style,
23
22
  containerItemClass = null,
24
23
  containerFloorListData,
25
24
  builtInComponents,
26
25
  loadingEndComponentFn,
27
26
  sectionType,
28
27
  updateShopFloorDataFn,
29
28
  updateContainerFloorListDataFn,
30
29
  customErrorIsvFloorModule,
31
30
  } = props
32
31
 
33
32
  const renderFloorItem = (
34
33
  item,
35
34
  floorItem,
36
35
  floorIndex,
37
36
  containerLayoutLeftRightMargin,
38
37
  lazyLoadState = false,
39
38
  ) => {
40
39
  return (
41
40
  <View
42
41
  className={classNames(shopContainerListStyle['d-floor-item'])}
43
42
  data-floor-uid={floorItem?.uid}
44
43
  data-floor-type={floorItem?.floorExtInfo?.moduleFlag || ''}
45
44
  data-lazy-load={lazyLoadState}
46
45
  key={floorItem.uid}
47
46
  id={`J_floor_${floorItem.uid}`}
48
47
  style={{
49
48
  borderRadius: `${item?.borderRadius || 0}px`,
50
49
  }}
51
50
  >
52
51
  {isChartH5 && (
53
52
  <View
54
53
  className={shopContainerListStyle['d-floor-chart-item']}
55
54
  id={`J_chart_floor_${floorItem?.uid}`}
56
55
  data-floor-uid={floorItem?.uid}
57
56
  data-floor-type={floorItem?.floorExtInfo?.moduleFlag || ''}
58
57
  />
59
58
  )}
60
59
  <FloorListItem
61
60
  floorIndex={floorIndex}
62
61
  floorData={floorItem}
63
62
  layoutLeftRightMargin={containerLayoutLeftRightMargin}
64
63
  containerBorderRadius={item?.borderRadius || 0}
65
64
  updateShopFloorDataFn={updateShopFloorDataFn}
66
65
  loadingEndComponentFn={loadingEndComponentFn}
67
66
  key={floorItem.uid}
68
67
  builtInComponents={builtInComponents}
69
68
  updateContainerFloorListDataFn={updateContainerFloorListDataFn}
70
69
  customErrorIsvFloorModule={customErrorIsvFloorModule}
71
70
  />
72
71
  </View>
73
72
  )
74
73
  }
75
74
 
76
75
  const getFloorSetHeight = (item) => {
77
76
  const getHeight = item?.floorExtInfo?.floorHeight
78
77
  ? Number(item?.floorExtInfo?.floorHeight)
79
78
  : 200
80
79
  return getHeight > 0 ? getHeight : 200
81
80
  }
82
81
  return (
83
82
  <View
84
83
  className={classNames(
85
84
  className,
86
85
  shopContainerListStyle['d-shop-container-list'],
87
86
  )}
88
87
  style={style}
89
88
  >
90
89
  <View id='J_shopContainerFloorList'>
91
90
  {containerFloorListData.length > 0 ? (
92
91
  containerFloorListData.map((item, index) => {
93
92
  const containerLayoutLeftRightMargin =
94
93
  (item.marginLeft || 0) + (item.marginRight || 0)
95
94
  const getContainerId = `J_container_${item.containerId}`
96
95
  return (
97
96
  <React.Fragment key={item.containerId + index}>
98
97
  {
99
98
  item.addLuxuryStyle ?
100
99
  <View
101
100
  className={
102
101
  shopContainerListStyle['d-luxury-header']
103
102
  }
104
103
  />
105
104
  : null
106
105
  }
107
106
  {
108
107
  item.addLuxuryBackupStyle ?
109
108
  <View
110
109
  style={{ height: taroJdBaseInfo?.info?.sysInfo?.jdNativeHeaderHeight + 'px' }}
111
110
  className={
112
111
  shopContainerListStyle['d-luxury-header-black']
113
112
  }
114
113
  />
115
114
  : null
116
115
  }
117
116
  {typeof item?.renderExtendComponent === 'function' ? item?.renderExtendComponent(item?.floorExtendData) : null}
118
117
  <View
119
118
  className={classNames(
120
119
  shopContainerListStyle['d-container-item'],
121
120
  containerItemClass,
122
121
  )}
123
122
  id={getContainerId}
124
123
  key={item.containerId}
125
124
  data-container-id={item?.containerId}
126
125
  data-container-type={item?.typeCode}
127
126
  style={{
128
127
  marginBottom: item.marginBottom
129
128
  ? `${item.marginBottom}px`
130
129
  : 0,
131
130
  marginTop: item.marginTop
132
131
  ? `${item.marginTop}px`
133
132
  : 0,
134
133
  marginLeft: item.marginLeft
135
134
  ? `${item.marginLeft}px`
136
135
  : 0,
137
136
  marginRight: item.marginRight
138
137
  ? `${item.marginRight}px`
139
138
  : 0,
140
139
  borderRadius: item.borderRadius
141
140
  ? `${item.borderRadius}px`
142
141
  : 0,
143
142
  }}
144
143
  >
145
144
  {item.floors &&
146
145
  item.floors.length > 0 &&
147
146
  item.floors?.map(
148
147
  (floorItem, floorIndex) => {
149
148
  return index > lazyLoadStartIndex ? (
150
149
  <LazyLayoutLoad
151
150
  key={item.containerId}
152
151
  sectionType={sectionType}
153
152
  containerId={getContainerId}
154
153
  height={getFloorSetHeight(
155
154
  floorItem,
156
155
  )}
157
156
  floorData={floorItem}
158
157
  >
159
158
  {renderFloorItem(
160
159
  item,
161
160
  floorItem,
162
161
  floorIndex,
163
162
  containerLayoutLeftRightMargin,
164
163
  true,
165
164
  )}
166
165
  </LazyLayoutLoad>
167
166
  ) : (
168
167
  renderFloorItem(
169
168
  item,
170
169
  floorItem,
171
170
  floorIndex,
172
171
  containerLayoutLeftRightMargin,
173
172
  )
174
173
  )
175
174
  },
176
175
  )}
177
176
  </View>
178
177
  </React.Fragment>
179
178
  )
180
179
  })
181
180
  ) : (
182
181
  <View
183
182
  className={
184
183
  shopContainerListStyle['d-container-list-no-data']
185
184
  }
186
185
  style={{
187
186
  height: `${
188
187
  windowHeight -
189
188
  (isJdApp
190
189
  ? APP_SHOP_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT
191
190
  : M_SHOP_DOWNLOAD_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT)
192
191
  }px`,
193
192
  }}
194
193
  >
195
194
  <NetworkDataError
196
195
  netWorkShowType={NetWorkShowType.PART}
197
196
  netWorkDataType={NETWORK_DATA_TYPE.DATA_ERROR}
198
197
  />
199
198
  </View>
200
199
  )}
201
200
  </View>
202
201
  </View>
203
202
  )
204
203
  updateShopDataFn: null,
204
+ import React from 'react'
205
205
  NETWORK_DATA_TYPE,
206
206
  M_SHOP_DOWNLOAD_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT,
207
207
  APP_SHOP_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT,
208
208
  containerFloorListData: ComponentInterFace.ContainerItemData[]
209
209
  className?: string
210
210
  containerItemClass?: object
211
211
  style?: object
212
212
  hasGoodsFeeds?: boolean
213
213
  builtInComponents?: Object
214
214
  loadingEndComponentFn?: Function
215
215
  sectionType?: string
216
216
  updateShopFloorDataFn?: Function
217
217
  updateContainerFloorListDataFn?: Function
218
218
  refreshFloorListDataFn?: Function
219
219
  refreshFloorListDataBtnLabel?: string
220
220
  customErrorIsvFloorModule?: React.ReactElement
221
221
  componentExtend?: React.ReactElement
222
222
  luxuryFixedIndex ?: number
223
223
  const { windowHeight } = taroJdBaseInfo.info.sysInfo
224
224
  const {
225
225
  className,
226
226
  style,
227
227
  containerItemClass = null,
228
228
  containerFloorListData,
229
229
  builtInComponents,
230
230
  loadingEndComponentFn,
231
231
  sectionType,
232
232
  updateShopFloorDataFn,
233
233
  updateContainerFloorListDataFn,
234
234
  refreshFloorListDataFn,
235
235
  refreshFloorListDataBtnLabel,
236
236
  customErrorIsvFloorModule,
237
237
  luxuryFixedIndex = -1
238
238
  } = props
239
239
 
240
240
  const renderFloorItem = (
241
241
  item,
242
242
  floorItem,
243
243
  floorIndex,
244
244
  containerLayoutLeftRightMargin,
245
245
  lazyLoadState = false,
246
246
  index
247
247
  ) => {
248
248
  return (
249
249
  <View
250
250
  className={classNames(shopContainerListStyle['d-floor-item'])}
251
251
  data-floor-uid={floorItem?.uid}
252
252
  data-floor-type={floorItem?.floorExtInfo?.moduleFlag || ''}
253
253
  data-lazy-load={lazyLoadState}
254
254
  key={floorItem.uid}
255
255
  id={`J_floor_${floorItem.uid}`}
256
256
  style={{
257
257
  borderRadius: `${item?.borderRadius || 0}px`,
258
258
  }}
259
259
  >
260
260
  {isChartH5 && (
261
261
  <View
262
262
  className={shopContainerListStyle['d-floor-chart-item']}
263
263
  id={`J_chart_floor_${floorItem?.uid}`}
264
264
  data-floor-uid={floorItem?.uid}
265
265
  data-floor-type={floorItem?.floorExtInfo?.moduleFlag || ''}
266
266
  />
267
267
  )}
268
268
  <FloorListItem
269
269
  floorIndex={floorIndex}
270
270
  floorData={floorItem}
271
271
  layoutLeftRightMargin={containerLayoutLeftRightMargin}
272
272
  containerBorderRadius={item?.borderRadius || 0}
273
273
  updateShopFloorDataFn={updateShopFloorDataFn}
274
274
  loadingEndComponentFn={loadingEndComponentFn}
275
275
  key={floorItem.uid}
276
276
  builtInComponents={builtInComponents}
277
277
  updateContainerFloorListDataFn={updateContainerFloorListDataFn}
278
278
  customErrorIsvFloorModule={customErrorIsvFloorModule}
279
279
  />
280
280
  {index === luxuryFixedIndex ? props.children : null}
281
281
  </View>
282
282
  )
283
283
  }
284
284
 
285
285
  const getFloorSetHeight = (item) => {
286
286
  const getHeight = item?.floorExtInfo?.floorHeight
287
287
  ? Number(item?.floorExtInfo?.floorHeight)
288
288
  : 200
289
289
  return getHeight > 0 ? getHeight : 200
290
290
  }
291
291
  return (
292
292
  <View
293
293
  className={classNames(
294
294
  className,
295
295
  shopContainerListStyle['d-shop-container-list'],
296
296
  )}
297
297
  style={style}
298
298
  >
299
299
  <View id="J_shopContainerFloorList">
300
300
  {containerFloorListData.length > 0 ? (
301
301
  containerFloorListData.map((item, index) => {
302
302
  const containerLayoutLeftRightMargin =
303
303
  (item.marginLeft || 0) + (item.marginRight || 0)
304
304
  const getContainerId = `J_container_${item.containerId}`
305
305
  return (
306
306
  <React.Fragment key={item.containerId + index}>
307
307
  {item.addLuxuryStyle ? (
308
308
  <View className={shopContainerListStyle['d-luxury-header']} />
309
309
  ) : null}
310
310
  {item.addLuxuryBackupStyle ? (
311
311
  <View
312
312
  style={{
313
313
  height:
314
314
  taroJdBaseInfo?.info?.sysInfo?.jdNativeHeaderHeight +
315
315
  'px',
316
316
  }}
317
317
  className={shopContainerListStyle['d-luxury-header-black']}
318
318
  />
319
319
  ) : null}
320
320
  {typeof item?.renderExtendComponent === 'function'
321
321
  ? item?.renderExtendComponent(item?.floorExtendData)
322
322
  : null}
323
323
  <View
324
324
  className={classNames(
325
325
  shopContainerListStyle['d-container-item'],
326
326
  containerItemClass,
327
327
  )}
328
328
  id={getContainerId}
329
329
  key={item.containerId}
330
330
  data-container-id={item?.containerId}
331
331
  data-container-type={item?.typeCode}
332
332
  style={{
333
333
  marginBottom: item.marginBottom
334
334
  ? `${item.marginBottom}px`
335
335
  : 0,
336
336
  marginTop: item.marginTop ? `${item.marginTop}px` : 0,
337
337
  marginLeft: item.marginLeft ? `${item.marginLeft}px` : 0,
338
338
  marginRight: item.marginRight ? `${item.marginRight}px` : 0,
339
339
  borderRadius: item.borderRadius
340
340
  ? `${item.borderRadius}px`
341
341
  : 0,
342
342
  }}
343
343
  >
344
344
  {typeof item?.insertContainerStartComponent === 'function'
345
345
  ? item?.insertContainerStartComponent(item)
346
346
  : null}
347
347
  {item.floors &&
348
348
  item.floors.length > 0 &&
349
349
  item.floors?.map(
350
350
  (floorItem, floorIndex) => {
351
351
  return index > lazyLoadStartIndex ? (
352
352
  <LazyLayoutLoad
353
353
  key={item.containerId}
354
354
  sectionType={sectionType}
355
355
  containerId={getContainerId}
356
356
  height={getFloorSetHeight(
357
357
  floorItem,
358
358
  )}
359
359
  floorData={floorItem}
360
360
  >
361
361
  {renderFloorItem(
362
362
  item,
363
363
  floorItem,
364
364
  floorIndex,
365
365
  containerLayoutLeftRightMargin,
366
366
  true,
367
367
  index
368
368
  )}
369
369
  </LazyLayoutLoad>
370
370
  ) : (
371
371
  renderFloorItem(
372
372
  item,
373
373
  floorItem,
374
374
  floorIndex,
375
375
  containerLayoutLeftRightMargin,
376
376
  false,
377
377
  index
378
378
  )
379
379
  )
380
380
  })}
381
381
  </View>
382
382
  </React.Fragment>
383
383
  )
384
384
  })
385
385
  ) : (
386
386
  <View
387
387
  className={shopContainerListStyle['d-container-list-no-data']}
388
388
  style={{
389
389
  height: `${
390
390
  windowHeight -
391
391
  (isJdApp
392
392
  ? APP_SHOP_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT
393
393
  : M_SHOP_DOWNLOAD_HEADER_NAV_BAR_BOTTOM_MENU_HEIGHT)
394
394
  }px`,
395
395
  }}
396
396
  >
397
397
  <NetworkDataError
398
398
  netWorkShowType={NetWorkShowType.PART}
399
399
  netWorkDataType={NETWORK_DATA_TYPE.DATA_ERROR}
400
400
  refreshCallBackFn={
401
401
  refreshFloorListDataFn ? refreshFloorListDataFn : null
402
402
  }
403
403
  btnLabel={refreshFloorListDataBtnLabel || ''}
404
404
  />
405
405
  </View>
406
406
  )}
407
407
  </View>
408
408
  </View>
409
409
  )
@@ -1 +1 @@
1
- import taroJdBaseInfo from '../../common'
1
+ import global from "../../common";
2
2
  return global.info.sysInfo.screenWidth;
3
3
  return global.info.sysInfo.screenHeight;
4
4
  return global.info.sysInfo.headerHeight;
5
5
  return global.info.sysInfo.tabBarHeight;
6
6
  return global.info.sysInfo.safeContentHeight;
7
7
  const result =
8
8
  global.info.sysInfo.screenHeight -
9
9
  global.info.sysInfo.jdBottomBarHeight +
10
10
  8;
11
11
  return result;
12
12
  getScreenWidth,
13
13
  getScreenHeight,
14
14
  getHeaderHeight,
15
15
  getFooterHeight,
16
16
  getSafeContentHeight,
17
17
  getFullscreenCropHeight,
18
18
  TaroEventType,
19
19
  SHOP_NAV_BAR_HEIGHT,
@@ -1 +1 @@
1
- import requestServer from '../../service/requestServer'
2
1
  return requestServer.receiveCoupon(param, clientParams)
3
2
  return requestServer.batchAddCart(skuIdList, num, showToast)
4
3
  return requestServer.bMallGetUserInfo()
5
4
  return requestServer.bMallGetSkuNumApi(needRequest, bMallTag)
6
5
  return requestServer.bMallCartHandle(goodItem, num)
7
6
  receiveCoupon,
8
7
  bMallGetUserInfo,
9
8
  bMallGetSkuNumApi,
10
9
  bMallCartHandle,
11
10
  batchAddCart
11
+ import requestServer from '../../service/requestServer'
12
12
  return requestServer.receiveCoupon(param, clientParams)
13
13
  return requestServer.batchAddCart(skuIdList, num, showToast)
14
14
  return requestServer.bMallGetUserInfo()
15
15
  return requestServer.bMallGetSkuNumApi(needRequest, bMallTag)
16
16
  return requestServer.bMallCartHandle(goodItem, num)
17
17
  receiveCoupon,
18
18
  bMallGetUserInfo,
19
19
  bMallGetSkuNumApi,
20
20
  bMallCartHandle,
21
21
  batchAddCart