@conecli/cone-render 0.8.20 → 0.8.21-shop-beta.3

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 (117) 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.jd.ts +1 -1
  5. package/dist/common/index.ts +1 -1
  6. package/dist/common/index.weapp.ts +1 -1
  7. package/dist/common/isvStorage/index.h5.ts +1 -0
  8. package/dist/common/isvStorage/index.ts +1 -0
  9. package/dist/common/token/const.ts +1 -0
  10. package/dist/common/token/index.h5.ts +1 -0
  11. package/dist/common/token/index.ts +1 -0
  12. package/dist/common/token/token.jd.ts +1 -0
  13. package/dist/common/token/token.ts +1 -0
  14. package/dist/common/token/token.wxapp.ts +1 -0
  15. package/dist/components/ErrorBoundary.tsx +1 -1
  16. package/dist/components/base/CommonFloorHead/index.module.scss +1 -1
  17. package/dist/components/base/CommonFloorHead/index.tsx +1 -1
  18. package/dist/components/base/CustomScrollView/index.tsx +1 -1
  19. package/dist/components/base/CustomVideo/const.ts +1 -0
  20. package/dist/components/base/CustomVideo/index.module.scss +40 -64
  21. package/dist/components/base/CustomVideo/index.tsx +1 -1
  22. package/dist/components/base/Dialog/index.module.scss +6 -2
  23. package/dist/components/base/Dialog/index.tsx +1 -1
  24. package/dist/components/base/ExposureSmart/const.ts +1 -0
  25. package/dist/components/base/ExposureSmart/index.h5.module.scss +18 -4
  26. package/dist/components/base/ExposureSmart/index.h5.tsx +1 -1
  27. package/dist/components/base/ExposureSmart/index.module.scss +20 -9
  28. package/dist/components/base/ExposureSmart/index.tsx +1 -1
  29. package/dist/components/base/ExposureSmart/reporter.tsx +1 -1
  30. package/dist/components/base/InOrOutViewObserver/index.tsx +1 -1
  31. package/dist/components/base/InViewRender/index.tsx +1 -1
  32. package/dist/components/base/InViewRender/index.weapp.tsx +1 -1
  33. package/dist/components/base/ItemViewExposureSmart/index.module.scss +8 -0
  34. package/dist/components/base/ItemViewExposureSmart/index.tsx +1 -0
  35. package/dist/components/base/LazyLayoutLoad/index.tsx +1 -1
  36. package/dist/components/base/LazyLoadImage/index.h5.tsx +1 -1
  37. package/dist/components/base/NetworkDataError/const.ts +1 -1
  38. package/dist/components/base/NetworkDataError/index.module.scss +7 -1
  39. package/dist/components/base/NetworkDataError/index.tsx +1 -1
  40. package/dist/components/base/Price/{const.ts → Base/const.ts} +0 -0
  41. package/dist/components/base/Price/Base/index.module.scss +136 -0
  42. package/dist/components/base/Price/Base/index.tsx +1 -0
  43. package/dist/components/base/Price/Double/index.module.scss +158 -0
  44. package/dist/components/base/Price/Double/index.tsx +1 -0
  45. package/dist/components/base/Price/index.tsx +1 -1
  46. package/dist/components/decorate/DecorateFloorModule/index.tsx +1 -1
  47. package/dist/components/decorate/EmptyFloorModule/index.tsx +1 -1
  48. package/dist/components/decorate/PlaceHolder/index.tsx +1 -1
  49. package/dist/components/floorItem.jd.tsx +1 -0
  50. package/dist/components/floorItem.tsx +1 -1
  51. package/dist/components/isv/Floor/index.tsx +1 -1
  52. package/dist/components/remoteFloorItem.tsx +1 -0
  53. package/dist/interface/common.ts +1 -1
  54. package/dist/interface/component.ts +1 -1
  55. package/dist/interface/jumpEventReport.ts +1 -1
  56. package/dist/interface/service.ts +1 -1
  57. package/dist/jumpEventReport/base.ts +1 -1
  58. package/dist/jumpEventReport/const.ts +1 -1
  59. package/dist/jumpEventReport/createReportFloorData.ts +1 -1
  60. package/dist/jumpEventReport/index.h5.ts +1 -1
  61. package/dist/jumpEventReport/index.ts +1 -1
  62. package/dist/jumpEventReport/index.weapp.ts +1 -1
  63. package/dist/jumpEventReport/jdJumpJdApp.ts +1 -1
  64. package/dist/jumpEventReport/jumpUrlConfig/base.ts +1 -1
  65. package/dist/jumpEventReport/logEventConfig.ts +1 -1
  66. package/dist/jumpEventReport/web/report.ts +1 -1
  67. package/dist/jumpEventReport/web.base.ts +1 -1
  68. package/dist/jumpEventReport/web.jd.ts +1 -1
  69. package/dist/jumpEventReport/web.jdb.ts +1 -0
  70. package/dist/jumpEventReport/web.jdjch.ts +1 -0
  71. package/dist/jumpEventReport/web.wxapp.ts +1 -1
  72. package/dist/libs/taroAppReport.js +2 -2
  73. package/dist/modules/ContainerFloorList/index.h5.module.scss +10 -1
  74. package/dist/modules/ContainerFloorList/index.h5.tsx +1 -1
  75. package/dist/modules/ContainerFloorList/index.tsx +1 -1
  76. package/dist/open/api/device.ts +1 -1
  77. package/dist/open/api/index.ts +1 -1
  78. package/dist/open/api/jump/business.ts +1 -0
  79. package/dist/open/api/jump/index.ts +1 -0
  80. package/dist/open/api/jump/minPath.ts +1 -0
  81. package/dist/open/api/jump/side.ts +1 -0
  82. package/dist/open/api/jump/webUrl.ts +1 -0
  83. package/dist/open/api/jump copy.ts +1 -0
  84. package/dist/open/api/moduleUtil.ts +1 -1
  85. package/dist/open/api/request.ts +1 -0
  86. package/dist/open/api/shopMember.ts +1 -0
  87. package/dist/open/api/track.ts +1 -1
  88. package/dist/open/api/userToken.ts +1 -0
  89. package/dist/open/api/util.ts +1 -1
  90. package/dist/open/components/index.ts +1 -1
  91. package/dist/service/bMallConst.ts +1 -0
  92. package/dist/service/bMallConst.weapp.ts +1 -0
  93. package/dist/service/fetchGateway.ts +1 -0
  94. package/dist/service/fetchJsonp.ts +1 -0
  95. package/dist/service/http/colorSign.ts +1 -0
  96. package/dist/service/http/colorSign.weapp.ts +1 -0
  97. package/dist/service/http/const.ts +1 -0
  98. package/dist/service/http/http.ts +1 -0
  99. package/dist/service/http/httpInterceptors.jd.ts +1 -0
  100. package/dist/service/http/httpInterceptors.ts +1 -0
  101. package/dist/service/http/index.ts +1 -0
  102. package/dist/service/requestServer.ts +1 -0
  103. package/dist/utils/connectNativeJsBridge.ts +1 -1
  104. package/dist/utils/connectNativeJsBridge.weapp.ts +1 -1
  105. package/dist/utils/h5Utils.ts +1 -1
  106. package/dist/utils/index.h5.ts +1 -1
  107. package/dist/utils/index.ts +1 -1
  108. package/dist/utils/index.weapp.ts +1 -1
  109. package/dist/utils/intersectionObserver.ts +1 -1
  110. package/dist/utils/jm-common.js +1 -1
  111. package/dist/utils/memberFormatUtils.js +1 -0
  112. package/dist/utils/priceUtils.js +1 -0
  113. package/dist/utils/ready.ts +1 -0
  114. package/dist/utils/utils.ts +1 -1
  115. package/package.json +9 -5
  116. package/dist/components/base/Price/index.module.scss +0 -136
  117. package/dist/open/api/jump.ts +0 -1
@@ -1 +1 @@
1
- import { View, Text } from '@tarojs/components'
1
+ import { View, Text } from '@tarojs/components'
2
2
  '//img11.360buyimg.com/imagetools/jfs/t1/141506/22/31698/7923/637b6db9E2af80265/10e76e2c31e0e356.png'
3
3
  const newModuleFloorTypeList = [100, 101, 100000, 99999]
4
4
  const isNewFloorState = newModuleFloorTypeList.includes(moduleType)
5
5
  if ((moduleType == 99999 || moduleType == 101) && !previewUri) {
@@ -1 +1 @@
1
- import { View, Text } from '@tarojs/components'
1
+ import { View, Text } from '@tarojs/components'
@@ -0,0 +1 @@
1
+ import { ComponentInterFace } from '../interface/component'
2
  const { floorData, builtInComponents = {} } = props
1
3
  const floorModuleType = floorData?.floorExtInfo?.moduleFlag
2
4
  const FloorContentItem =
3
5
  (floorModuleType && builtInComponents[floorModuleType]) || null
4
6
  const dataDefines = getFloorDataToDataDefines(floorData)
5
7
  return FloorContentItem ? (
6
8
  <ErrorBoundary {...props}>
7
9
  <FloorContentItem {...props} dataDefines={dataDefines} />
8
10
  </ErrorBoundary>
9
11
  ) : null
10
12
  renderSourceType: BUSINESS_TYPE.ONLINE,
11
13
  switch (moduleId) {
12
14
  case 83158:
13
15
  return 'freeLayout'
14
16
  case 99654:
15
17
  return 'activeText'
16
18
  case 100382:
17
19
  return 'superGoods'
18
20
  }
19
21
  floorList.map((item) => {
20
22
  if (!item.floorExtInfo) {
21
23
  return null
22
24
  }
23
25
  const moduleFlag = item.floorExtInfo.moduleFlag
24
26
  if (!moduleFlag) {
25
27
  const newModuleFlag = moduleId2ModuleFlag(item.moduleId)
26
28
  if (newModuleFlag) {
27
29
  item.floorExtInfo.moduleFlag = newModuleFlag
28
30
  }
29
31
  }
30
32
  })
@@ -1 +1 @@
1
- import React, { Suspense, lazy } from 'react'
2
1
  style={{
2
+ import React from 'react'
3
3
  const { floorData, renderSourceType, builtInComponents = {} } = props
4
4
  const isDevMode = renderSourceType === BUSINESS_TYPE.DECORATE
5
5
  const floorModuleType: any = floorData?.floorExtInfo?.moduleFlag
6
6
  const FloorContentItem =
7
7
  (floorModuleType && builtInComponents[floorModuleType]) || null
8
8
  const dataDefines = getFloorDataToDataDefines(floorData)
9
9
 
10
10
  const renderDecorateDefaultModule = () => {
11
11
  return (
12
12
  <View
13
13
  style={{
14
14
  lineHeight: '120px',
15
15
  textAlign: 'center',
16
16
  }}
17
17
  >
18
18
  当前模块是{floorData.moduleName}
19
19
  </View>
20
20
  )
21
21
  }
22
22
  if (floorModuleType && RemoteLoadFloorList.includes(floorModuleType)) {
23
23
  return (
24
24
  <RemoteFloorItem {...props} dataDefines={dataDefines}></RemoteFloorItem>
25
25
  )
26
26
  } else {
27
27
  return FloorContentItem ? (
28
28
  <ErrorBoundary {...props}>
29
29
  <FloorContentItem {...props} dataDefines={dataDefines} />
30
30
  </ErrorBoundary>
31
31
  ) : isDevMode ? (
32
32
  renderDecorateDefaultModule()
33
33
  ) : null
34
34
  }
35
35
  renderSourceType: BUSINESS_TYPE.ONLINE,
36
36
  switch (moduleId) {
37
37
  case 83158:
38
38
  return 'freeLayout'
39
39
  case 99654:
40
40
  return 'activeText'
41
41
  case 100382:
42
42
  return 'superGoods'
43
43
  }
44
44
  floorList.map((item) => {
45
45
  if (!item.floorExtInfo) {
46
46
  return null
47
47
  }
48
48
  const moduleFlag = item.floorExtInfo.moduleFlag
49
49
  if (!moduleFlag) {
50
50
  const newModuleFlag = moduleId2ModuleFlag(item.moduleId)
51
51
  if (newModuleFlag) {
52
52
  item.floorExtInfo.moduleFlag = newModuleFlag
53
53
  }
54
54
  }
55
55
  })
@@ -1 +1 @@
1
- import React, { useCallback } from 'react'
1
+ import React, { useCallback } from 'react'
2
2
  {floorData?.showCommonFloorHead === false ? null : (
3
3
  <CommonFloorHead dataDefines={dataDefines} floorData={floorData} />
4
4
  )}
@@ -0,0 +1 @@
1
+ import React, { Suspense, lazy } from 'react'
2
  const { floorData, renderSourceType, updateContainerFloorListDataFn } = props
1
3
  const dataDefines = getFloorDataToDataDefines(floorData)
2
4
 
3
5
  const getFloorSetHeight = (item) => {
4
6
  const getHeight = item?.floorExtInfo?.floorHeight
5
7
  ? Number(item?.floorExtInfo?.floorHeight)
6
8
  : 200
7
9
  return getHeight > 0 ? getHeight : 200
8
10
  }
9
11
  console.log(
10
12
  '>>>>>>>>>> floorModuleType === FloorModuleType.ISVDESIGNERH5MODULE >>>>>>>>>>',
11
13
  )
12
14
  const renderResult = (() => {
13
15
  try {
14
16
  console.log('>>>>>>>>>> 开始渲染1个isv模块 >>>>>>>>>>')
15
17
  console.log(
16
18
  '==========当前业务类型renderSourceType、楼层floorId: ',
17
19
  renderSourceType,
18
20
  floorData.uid,
19
21
  )
20
22
  const modularPackResult = floorData?.floorExtInfo?.modularPackResult
21
23
  const modularPackResultObj =
22
24
  typeof modularPackResult === 'string'
23
25
  ? JSON.parse(modularPackResult)
24
26
  : modularPackResult
25
27
  const opt = {
26
28
  msg: `店铺首页isv h5楼层隐藏不显示。原因:modularPackResult数据不完备。页面类型-buildType: ${buildType}。楼层顺序-floorIdx: ${floorData?.floorIdx}`,
27
29
  buildType,
28
30
  uid: floorData?.uid,
29
31
  floorIdx: floorData?.floorIdx,
30
32
  shopId: floorData?.floorExtInfo?.shopId,
31
33
  moduleId: floorData?.moduleId,
32
34
  moduleName: floorData?.moduleName,
33
35
  middleTemplateId: floorData?.middleTemplateId,
34
36
  modularPackResult: modularPackResult,
35
37
  }
36
38
  if (modularPackResultObj) {
37
39
  const { bundleUrl, bundleFileName } = modularPackResultObj
38
40
  if (bundleUrl && bundleFileName) {
39
41
  let ISVModule =
40
42
  taroJdBaseInfo?.renderedIsvComponents[
41
43
  `${floorData.uid}_${bundleFileName}`
42
44
  ] || null
43
45
  if (!ISVModule) {
44
46
  ISVModule = lazy(
45
47
  () => import(bundleFileName + '@@@@@@' + bundleUrl),
46
48
  )
47
49
  console.log(
48
50
  '1|加载isv模块==========走lazy import生成新的isv模块react组件',
49
51
  bundleFileName,
50
52
  )
51
53
  taroJdBaseInfo.renderedIsvComponents[
52
54
  `${floorData.uid}_${bundleFileName}`
53
55
  ] = ISVModule
54
56
  console.log(
55
57
  '2|渲染isv模块的react组件==========,window.taroJshopH5WebpackJsonp上的组件是否已就绪: ',
56
58
  bundleFileName,
57
59
  window['taroJshopH5WebpackJsonp'].find(
58
60
  (item) => item[0][0] == bundleFileName,
59
61
  ),
60
62
  )
61
63
  } else {
62
64
  console.log(
63
65
  '1|加载isv模块==========不走lazy import生成新的isv模块react组件,从已加载中获取,taroJdBaseInfo: ',
64
66
  taroJdBaseInfo,
65
67
  )
66
68
  console.log(
67
69
  '2|渲染isv模块的react组件==========,taroJdBaseInfo.renderedIsvComponents上的组件是否已就绪: ',
68
70
  taroJdBaseInfo.renderedIsvComponents[
69
71
  `${floorData.uid}_${bundleFileName}`
70
72
  ],
71
73
  )
72
74
  }
73
75
  const _floorHeight = getFloorSetHeight(floorData)
74
76
  return (
75
77
  <ErrorBoundary {...props}>
76
78
  <Suspense
77
79
  fallback={
78
80
  <View
79
81
  style={{
80
82
  position: 'relative',
81
83
  background: `#ffffff url('${JD_PLACEHOLDER_IMG}') center center no-repeat`,
82
84
  height: `${_floorHeight}px`,
83
85
  }}
84
86
  ></View>
85
87
  }
86
88
  >
87
89
  <ISVFloor {...props} dataDefines={dataDefines}>
88
90
  <ISVModule {...props} dataDefines={dataDefines}></ISVModule>
89
91
  </ISVFloor>
90
92
  </Suspense>
91
93
  </ErrorBoundary>
92
94
  )
93
95
  } else {
94
96
  console.log(
95
97
  '3|isv模块渲染异常,modularPackResult中缺少bundleUrl或bundleFileName==========modularPackResult: ',
96
98
  modularPackResultObj,
97
99
  )
98
100
  sgmCustomReport({
99
101
  code: 'isvModuleError',
100
102
  msg: opt,
101
103
  })
102
104
  return null
103
105
  }
104
106
  } else {
105
107
  console.log(
106
108
  '3|isv模块渲染异常,缺少modularPackResult==========modularPackResult: ',
107
109
  modularPackResultObj,
108
110
  )
109
111
  sgmCustomReport({
110
112
  code: 'isvModuleError',
111
113
  msg: opt,
112
114
  })
113
115
  return null
114
116
  }
115
117
  } catch (err) {
116
118
  console.log('3|isv模块渲染异常,floorItem逻辑错误==========err: ', err)
117
119
  sgmCustomReport({
118
120
  code: 'isvModuleError',
119
121
  msg: {
120
122
  msg: 'remoteFloorItem try catch 异常',
121
123
  err
122
124
  },
123
125
  })
124
126
  return null
125
127
  }
126
128
  })()
127
129
  if (renderResult === null) {
128
130
  updateContainerFloorListDataFn &&
129
131
  updateContainerFloorListDataFn({
130
132
  type: 'filter',
131
133
  containerId: floorData?.uid,
132
134
  })
133
135
  console.log('renderResult === null: 命中了!')
134
136
  taroEventSendPageScrollInfo()
135
137
  } else {
136
138
  console.log('renderResult !== null: 没命中', renderResult)
137
139
  }
138
140
  return renderResult
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
1
+ import Taro from '@tarojs/taro'
@@ -1 +1 @@
1
- import React from 'react'
2
1
  subMessage?: string
3
2
  customErrorIsvFloorModule?: React.ReactElement | undefined
4
3
  containerIndex?: number
5
4
  containerData?: any
6
5
  shopTotalInfo?: any
7
6
  selectContainerFn?: Function
8
7
  selectContainerId?: string
9
8
  placeHolderPreContainerId?: string
10
9
  children?: any
11
10
  style?: {
12
11
  [key: string]: any
13
12
  };
14
13
  layoutLeftRightMargin?: number
15
14
  }
15
+ import React from 'react'
16
16
  subMessage?: string
17
17
  showCommonFloorHead?: boolean
18
18
  customErrorIsvFloorModule?: React.ReactElement | undefined
19
19
  containerIndex?: number
20
20
  containerData?: any
21
21
  shopTotalInfo?: any
22
22
  selectContainerFn?: Function
23
23
  selectContainerId?: string
24
24
  placeHolderPreContainerId?: string
25
25
  children?: any
26
26
  style?: {
27
27
  [key: string]: any
28
28
  };
29
29
  layoutLeftRightMargin?: number
30
30
  }
31
31
  onFormSubmit?: Function
32
32
  onFormReset?: Function
33
33
  isFormDialog?: boolean
34
34
  forbiddenBgScrollState?: boolean
@@ -1 +1 @@
1
- export declare namespace JumpEventReportInterFace {
1
+ export declare namespace JumpEventReportInterFace {
2
2
  export interface ShopIdsInfo {
3
3
  shopId?: number | string
4
4
  venderId?: number | string
5
5
  logEventInfo?: object
6
6
  type?: string
7
7
  }
8
8
  export interface RouterInfo {
9
9
  params: any
10
10
  pageParamStr?: string
11
11
  [key: string]: any
12
12
  }
13
13
  export interface JumpMiniPath {
14
14
  shop: string
15
15
  shopx: string
16
16
  detail: string
17
17
  searchCoupon: string
18
18
  h5: string
19
19
  jingGouHome: string
20
20
  shopFans: string
21
21
  shopLight: string
22
22
  couponSearch: string
23
23
  shopSearch: string
24
24
  }
25
25
  export interface jumpWebUrl {
26
26
  mshop: string
27
27
  pages: string
28
28
  couponSearch: string
29
29
  shopSecondActivity: string
30
30
  shopLight: string
31
31
  detail: string
32
32
  mobileHome: string
33
33
  rank: string
34
34
  wqShopMember: string
35
35
  wqShopDetail: string
36
36
  wqShopSearch: string
37
37
  shopMember: string
38
38
  shopMemberPointDetail: string
39
39
  shopMemberBenefit: string
40
40
  shopMemberRule: string
41
41
  shopMemberCloseAccount: string
42
42
  shopMemberPointExchange: string
43
43
  shopMemberBonusPurchase: string
44
44
  shopMemberGood: string
45
45
  beanDetail: string
46
46
  totalPromotion: string
47
47
  mLive: string
48
48
  shopHome: string
49
49
  shopIntroduce: string
50
50
  shopSearch: string
51
51
  shopLottery: string
52
52
  shopCoupon: string
53
53
  shopWares: string
54
54
  shopFastShopping: string
55
55
  shopSpeciSeckill: string
56
56
  shopVideos: string
57
57
  shopUseShareOrderUgcContent: string
58
58
  dongDongChat: string
59
59
  samCenter: string
60
60
  samCard: string
61
61
  shopH5MemberCardAPP: string
62
62
  shopH5MemberCardM: string
63
63
  }
64
64
  export interface EventReportConfig {
65
65
  routerInfo: RouterInfo
66
66
  nativeEvent: any
67
67
  }
68
68
  export interface OptEventLogParams {
69
69
  eventId?: string
70
70
  eventParam?: string | object
71
71
  pTag?: string
72
72
  jsonParam?: {
73
73
  [key: string]: any
74
74
  }
75
75
  skuId?: string | number
76
76
  eventLevel?: string
77
77
  exposureState?: boolean
78
78
  otherParams?: object
79
79
  }
80
80
 
81
81
  export interface JumpH5ReportConfig {
82
82
  shopId?: number | string
83
83
  venderId?: number | string
84
84
  sourceValue?: string
85
85
  sourceType?: string
86
86
  }
87
87
  export interface JumpEventReportInit extends EventReportConfig {
88
88
  getConfig(opt): EventReportConfig
89
89
  updateInfo(routerInfo, logPname): void
90
90
  }
91
91
  export interface CouponUrlParams {
92
92
  batchId: number
93
93
  bindType: number
94
94
  startTime?: number
95
95
  endTime?: number
96
96
  quangoufrom?: number
97
97
  sceneId?: number
98
98
  }
99
99
  export interface JdMiniJumpParams {
100
100
  param: string | object
101
101
  sourceValue: string
102
102
  sourceType: string
103
103
  des?: any
104
104
  logEventInfo?: object
105
105
  }
106
106
  export interface LinkMiniParams {
107
107
  param?: {
108
108
  pageType?: string
109
109
  }
110
110
  appId?: string | number
111
111
  path?: string
112
112
  }
113
113
  export interface JdJumpWxappReportConfig {
114
114
  wxApiVersion: string
115
115
  wxApiUrl: string
116
116
  wqReportUrl: string
117
117
  }
@@ -1 +1 @@
1
- import { ComponentInterFace } from './component'
2
1
  mobileLogin: string
2
+ import { ComponentInterFace } from './component'
3
3
  mobileLogin: string
4
4
  isLogin: string