@conecli/cone-render 0.8.19 → 0.8.20-beta.2

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 (183) hide show
  1. package/README.md +7 -1
  2. package/dist/api/index.ts +1 -1
  3. package/dist/assets/icon_blue_info.svg +1 -0
  4. package/dist/common/const.ts +1 -1
  5. package/dist/common/environmentType.ts +1 -0
  6. package/dist/common/index.h5.ts +1 -1
  7. package/dist/common/index.jd.ts +1 -1
  8. package/dist/common/index.ts +1 -1
  9. package/dist/common/index.weapp.ts +1 -1
  10. package/dist/common/isvStorage/index.h5.ts +1 -0
  11. package/dist/common/isvStorage/index.ts +1 -0
  12. package/dist/common/jdplayerSdk.ts +1 -0
  13. package/dist/common/jssdk.ts +1 -0
  14. package/dist/common/pageType.ts +1 -0
  15. package/dist/common/sgmCustomCode.ts +1 -0
  16. package/dist/common/token/const.ts +1 -0
  17. package/dist/common/token/index.h5.ts +1 -0
  18. package/dist/common/token/index.ts +1 -0
  19. package/dist/common/token/token.jd.ts +1 -0
  20. package/dist/common/token/token.ts +1 -0
  21. package/dist/common/token/token.wxapp.ts +1 -0
  22. package/dist/common/wxappApi.jd.ts +1 -0
  23. package/dist/common/wxappApi.ts +1 -1
  24. package/dist/components/ErrorBoundary.tsx +1 -1
  25. package/dist/components/base/CommonFloorHead/index.module.scss +126 -111
  26. package/dist/components/base/CommonFloorHead/index.tsx +1 -1
  27. package/dist/components/base/CountDown/index.module.scss +49 -44
  28. package/dist/components/base/CountDown/index.tsx +1 -1
  29. package/dist/components/base/CustomScrollView/index.jd.tsx +1 -0
  30. package/dist/components/base/CustomScrollView/index.module.scss +7 -0
  31. package/dist/components/base/CustomScrollView/index.tsx +1 -1
  32. package/dist/components/base/CustomVideo/common.ts +1 -0
  33. package/dist/components/base/CustomVideo/const.ts +1 -0
  34. package/dist/components/base/CustomVideo/index.module.scss +40 -64
  35. package/dist/components/base/CustomVideo/index.tsx +1 -1
  36. package/dist/components/base/Dialog/index.module.scss +22 -2
  37. package/dist/components/base/Dialog/index.tsx +1 -1
  38. package/dist/components/base/Exposure/index.h5.tsx +1 -1
  39. package/dist/components/base/ExposureSmart/const.ts +1 -0
  40. package/dist/components/base/ExposureSmart/index.h5.module.scss +30 -6
  41. package/dist/components/base/ExposureSmart/index.h5.tsx +1 -1
  42. package/dist/components/base/ExposureSmart/index.module.scss +20 -9
  43. package/dist/components/base/ExposureSmart/index.tsx +1 -1
  44. package/dist/components/base/ExposureSmart/reporter.tsx +1 -1
  45. package/dist/components/base/InOrOutViewObserver/index.tsx +1 -1
  46. package/dist/components/base/InViewRender/index.tsx +1 -1
  47. package/dist/components/base/InViewRender/index.weapp.tsx +1 -1
  48. package/dist/components/base/ItemViewExposureSmart/index.module.scss +8 -0
  49. package/dist/components/base/ItemViewExposureSmart/index.tsx +1 -0
  50. package/dist/components/base/LazyLayoutLoad/index.tsx +1 -1
  51. package/dist/components/base/LazyLayoutLoad/index.weapp.tsx +1 -1
  52. package/dist/components/base/LazyLoadImage/const.ts +1 -1
  53. package/dist/components/base/LazyLoadImage/index.h5.module.scss +24 -20
  54. package/dist/components/base/LazyLoadImage/index.h5.tsx +1 -1
  55. package/dist/components/base/MobileCommonHeader/index.module.scss +17 -0
  56. package/dist/components/base/MobileCommonHeader/index.tsx +1 -0
  57. package/dist/components/base/NetworkDataError/const.ts +1 -1
  58. package/dist/components/base/NetworkDataError/index.module.scss +128 -69
  59. package/dist/components/base/NetworkDataError/index.tsx +1 -1
  60. package/dist/components/base/Price/{const.ts → Base/const.ts} +0 -0
  61. package/dist/components/base/Price/Base/index.module.scss +148 -0
  62. package/dist/components/base/Price/Base/index.tsx +1 -0
  63. package/dist/components/base/Price/Double/index.module.scss +190 -0
  64. package/dist/components/base/Price/Double/index.tsx +1 -0
  65. package/dist/components/base/Price/index.tsx +1 -1
  66. package/dist/components/base/ShopLeGaoTag/index.h5.module.scss +35 -0
  67. package/dist/components/base/ShopLeGaoTag/index.h5.tsx +1 -0
  68. package/dist/components/base/ShopLeGaoTag/index.module.scss +33 -0
  69. package/dist/components/base/ShopLeGaoTag/index.tsx +1 -0
  70. package/dist/components/base/Skeleton/index.tsx +1 -1
  71. package/dist/components/debug/DebugLayout/index.module.scss +67 -0
  72. package/dist/components/debug/DebugLayout/index.tsx +1 -0
  73. package/dist/components/debug/DebugLayout/utils.ts +1 -0
  74. package/dist/components/decorate/DecorateFloorModule/index.module.scss +32 -2
  75. package/dist/components/decorate/DecorateFloorModule/index.tsx +1 -1
  76. package/dist/components/decorate/EmptyFloorModule/index.tsx +1 -1
  77. package/dist/components/decorate/PlaceHolder/index.tsx +1 -1
  78. package/dist/components/floorItem.jd.tsx +1 -0
  79. package/dist/components/floorItem.tsx +1 -1
  80. package/dist/components/floorItem.weapp.tsx +1 -1
  81. package/dist/components/isv/Floor/index.tsx +1 -1
  82. package/dist/components/remoteFloorItem.tsx +1 -0
  83. package/dist/interface/common.ts +1 -1
  84. package/dist/interface/component.ts +1 -1
  85. package/dist/interface/jumpEventReport.ts +1 -1
  86. package/dist/interface/service.ts +1 -1
  87. package/dist/interface/utils.ts +1 -1
  88. package/dist/jumpEventReport/base.ts +1 -1
  89. package/dist/jumpEventReport/const.ts +1 -1
  90. package/dist/jumpEventReport/createReportFloorData.ts +1 -1
  91. package/dist/jumpEventReport/index.h5.ts +1 -1
  92. package/dist/jumpEventReport/index.jd.ts +1 -1
  93. package/dist/jumpEventReport/index.ts +1 -1
  94. package/dist/jumpEventReport/index.weapp.ts +1 -1
  95. package/dist/jumpEventReport/jdJumpJdApp.ts +1 -1
  96. package/dist/jumpEventReport/jumpUrlConfig/base.ts +1 -1
  97. package/dist/jumpEventReport/logEventConfig.ts +1 -1
  98. package/dist/jumpEventReport/web/report.ts +1 -1
  99. package/dist/jumpEventReport/web.base.ts +1 -1
  100. package/dist/jumpEventReport/web.jd.ts +1 -1
  101. package/dist/jumpEventReport/web.jdb.ts +1 -0
  102. package/dist/jumpEventReport/web.jdjch.ts +1 -0
  103. package/dist/jumpEventReport/web.jxwxapp.ts +1 -0
  104. package/dist/jumpEventReport/web.pc.ts +1 -0
  105. package/dist/jumpEventReport/web.tjapp.ts +1 -0
  106. package/dist/jumpEventReport/web.tjm.ts +1 -0
  107. package/dist/jumpEventReport/web.wxapp.ts +1 -1
  108. package/dist/language/en_US.json +231 -0
  109. package/dist/language/zh_CN.json +231 -0
  110. package/dist/language/zh_HK.json +231 -0
  111. package/dist/libs/taroAppReport.js +2 -2
  112. package/dist/modules/ContainerFloorList/index.h5.module.scss +66 -27
  113. package/dist/modules/ContainerFloorList/index.h5.tsx +1 -1
  114. package/dist/modules/ContainerFloorList/index.tsx +1 -1
  115. package/dist/open/api/device.ts +1 -1
  116. package/dist/open/api/environment.ts +1 -1
  117. package/dist/open/api/index.ts +1 -1
  118. package/dist/open/api/jump/business.ts +1 -0
  119. package/dist/open/api/jump/index.ts +1 -0
  120. package/dist/open/api/jump/minPath.ts +1 -0
  121. package/dist/open/api/jump/side.ts +1 -0
  122. package/dist/open/api/jump/webUrl.ts +1 -0
  123. package/dist/open/api/jump copy.ts +1 -0
  124. package/dist/open/api/moduleUtil.ts +1 -1
  125. package/dist/open/api/request.ts +1 -0
  126. package/dist/open/api/shopMember.ts +1 -0
  127. package/dist/open/api/track.ts +1 -1
  128. package/dist/open/api/userToken.ts +1 -0
  129. package/dist/open/api/util.ts +1 -1
  130. package/dist/open/components/index.ts +1 -1
  131. package/dist/sass/app.h5.scss +294 -212
  132. package/dist/sass/base.scss +195 -137
  133. package/dist/service/bMallConst.ts +1 -0
  134. package/dist/service/bMallConst.weapp.ts +1 -0
  135. package/dist/service/fetchGateway.ts +1 -0
  136. package/dist/service/fetchGateway.weapp.ts +1 -0
  137. package/dist/service/fetchJsonp.ts +1 -0
  138. package/dist/service/http/colorSign.ts +1 -0
  139. package/dist/service/http/colorSign.weapp.ts +1 -0
  140. package/dist/service/http/const.ts +1 -0
  141. package/dist/service/http/h5Http.ts +1 -0
  142. package/dist/service/http/http.ts +1 -0
  143. package/dist/service/http/httpInterceptors.jd.ts +1 -0
  144. package/dist/service/http/httpInterceptors.ts +1 -0
  145. package/dist/service/http/index.h5.ts +1 -0
  146. package/dist/service/http/index.ts +1 -0
  147. package/dist/service/requestServer.h5.ts +1 -0
  148. package/dist/service/requestServer.ts +1 -0
  149. package/dist/service/requestServer.weapp.ts +1 -0
  150. package/dist/utils/connectNativeJsBridge.ts +1 -1
  151. package/dist/utils/connectNativeJsBridge.weapp.ts +1 -1
  152. package/dist/utils/draExceptionAndProfile.ts +1 -1
  153. package/dist/utils/h5Utils.ts +1 -1
  154. package/dist/utils/index.h5.ts +1 -1
  155. package/dist/utils/index.ts +1 -1
  156. package/dist/utils/index.weapp.ts +1 -1
  157. package/dist/utils/intersectionObserver.ts +1 -1
  158. package/dist/utils/jm-common.js +1 -1
  159. package/dist/utils/jumpExtMapUtil.h5.ts +1 -0
  160. package/dist/utils/jumpExtMapUtil.ts +1 -0
  161. package/dist/utils/priceUtils.js +1 -0
  162. package/dist/utils/ready.ts +1 -0
  163. package/dist/utils/sColor.js +1 -0
  164. package/dist/utils/sgmCodeUtils.ts +1 -0
  165. package/dist/utils/taroRenderUtil.ts +1 -0
  166. package/dist/utils/utils.ts +1 -1
  167. package/dist/wxapp/api/helper.js +1 -0
  168. package/dist/wxapp/common/address_api/address_api_v2.js +1 -0
  169. package/dist/wxapp/common/user_info.js +1 -1
  170. package/dist/wxapp/components/launch-app/index.js +1 -0
  171. package/dist/wxapp/components/launch-app/index.json +5 -0
  172. package/dist/wxapp/components/launch-app/index.wxml +0 -0
  173. package/dist/wxapp/components/launch-app/index.wxss +0 -0
  174. package/dist/wxapp/components/subscribe-guider/helper.js +1 -0
  175. package/dist/wxapp/components/subscribe-guider/index.js +1 -0
  176. package/dist/wxapp/components/subscribe-guider/index.json +5 -0
  177. package/dist/wxapp/components/subscribe-guider/index.wxml +0 -0
  178. package/dist/wxapp/components/subscribe-guider/index.wxss +0 -0
  179. package/package.json +145 -114
  180. package/dist/components/base/Price/index.module.scss +0 -136
  181. package/dist/components/base/Skeleton/old.tsx +0 -1
  182. package/dist/customHooks/useDocumentVisibilitychange.ts +0 -1
  183. package/dist/open/api/jump.ts +0 -1
@@ -1 +1 @@
1
- import {
2
1
  isH5AndJingGouMini,
3
2
  urlCookie,
3
+ import {
4
4
  isJdApp,
5
5
  isWxApp,
6
6
  isIosDevice,
7
7
  isAndroidDevice,
8
8
  isJdAndIosDevice,
9
9
  isJdAndAndroidDevice,
10
10
  isWxMin,
11
11
  isMin,
12
12
  isJdMinAndHarmony,
13
13
  isWxMinAndWxapp,
14
14
  isJdMin,
15
15
  isH5,
16
16
  isH5AndJdShopView,
17
17
  isChartH5,
18
18
  isH5AndJdShopViewNativeScroll,
19
19
  isH5AndJdShopViewH5Scroll,
20
20
  isH5AndJdShopH5CustomScrollView,
21
21
  isWxMiniH5View,
22
22
  sliceArrToChunkList,
23
23
  dealAddress,
24
24
  objectToUrlEncode,
25
25
  setLowSmallPicUrl,
26
26
  parseQueryUrlString,
27
27
  countStringify,
28
28
  setTaroStorage,
29
29
  getTaroStorageKeyValue,
30
30
  removeTaroStorageKey,
31
31
  clearTaroStorageKey,
32
32
  getQualityImage,
33
33
  getSystemInfos,
34
34
  getWxAppCookieStr,
35
35
  pxTransformFromData,
36
36
  dealShopContentData,
37
37
  dateFormat,
38
38
  throttle,
39
39
  lodashThrottle,
40
40
  debounce,
41
41
  addHttps,
42
42
  showSuccessToast,
43
43
  showFailToast,
44
44
  showNormalToast,
45
45
  showShopLoading,
46
46
  hideShopLoading,
47
47
  getAppChannelType,
48
48
  formatTabActiveMenuType,
49
49
  getAvifSupport,
50
50
  getWebpSupport,
51
51
  filterUrlQueryData,
52
52
  isMemberPage,
53
53
  sgmCustomReport,
54
54
  draCustomReport,
55
55
  remoteCustomReport,
56
56
  draInterfaceCustomReport,
57
57
  draBusinessCustomReport,
58
58
  draBusinessCustomLogReport,
59
59
  isOpenJdAppUrl,
60
60
  jdOpenAppParams,
61
61
  createJdOpenAppUrl,
62
62
  isEmpty,
63
63
  getJdAppReportPageSource,
64
64
  isAppClassifyPage,
65
65
  isPc,
66
66
  ipLoc_djd,
67
67
  dealJdOpenAppData,
68
68
  jdAppVersionCompare,
69
69
  dealNativePixelToCssPixel,
70
70
  isAppStowShop,
71
71
  isImageOptimizeEnable,
72
72
  isIpadDevice,
73
73
  getBorderStyle,
74
74
  isLanguageForEn,
75
75
  sColor,
76
76
  draInterfaceDSMCustomReport,
77
77
  isTabletDevice,
78
78
  isLanguageForHk,
79
79
  languageNowType,
80
80
  console.warn('暂未实现', code);
81
81
  console.warn('暂未实现', code);
82
82
  console.warn('暂未实现');
83
83
  console.warn('🚗 ~~ file: index.ts:93 ~~ 通用的isInGrayscale还没有实现,不应该被调用!');
84
84
  return false;
85
85
  isJdApp,
86
86
  isWxApp,
87
87
  isIosDevice,
88
88
  isAndroidDevice,
89
89
  isHarmonyDevice,
90
90
  isJdAndIosDevice,
91
91
  isJdAndAndroidDevice,
92
92
  isJdAndHarmonyDevice,
93
93
  isJdAndroidX5Core,
94
94
  isWxMin,
95
95
  isMin,
96
96
  isJdMinAndHarmony,
97
97
  isWxMinAndWxapp,
98
98
  isJdMin,
99
99
  isH5,
100
100
  isH5AndJdShopView,
101
101
  isChartH5,
102
102
  isH5AndJdShopViewNativeScroll,
103
103
  isH5AndJdShopViewH5Scroll,
104
104
  isH5AndJdShopH5CustomScrollView,
105
105
  isH5AndJingGouMini,
106
106
  isWxMiniH5View,
107
107
  urlCookie,
108
108
  sliceArrToChunkList,
109
109
  dealAddress,
110
110
  objectToUrlEncode,
111
111
  parseQueryUrlString,
112
112
  setLowSmallPicUrl,
113
113
  countStringify,
114
114
  setTaroStorage,
115
115
  getTaroStorageKeyValue,
116
116
  removeTaroStorageKey,
117
117
  clearTaroStorageKey,
118
118
  getQualityImage,
119
119
  getSystemInfos,
120
120
  getWxAppCookieStr,
121
121
  pxTransformFromData,
122
122
  dealShopContentData,
123
123
  dateFormat,
124
124
  throttle,
125
125
  lodashThrottle,
126
126
  debounce,
127
127
  addHttps,
128
128
  showSuccessToast,
129
129
  showFailToast,
130
130
  showNormalToast,
131
131
  showShopLoading,
132
132
  hideShopLoading,
133
133
  stopNativeScrollEvent,
134
134
  getAppChannelType,
135
135
  formatTabActiveMenuType,
136
136
  getAvifSupport,
137
137
  getWebpSupport,
138
138
  filterUrlQueryData,
139
139
  isMemberPage,
140
140
  getFloorDataToDataDefines,
141
141
  sgmCustomReport,
142
142
  draCustomReport,
143
143
  remoteCustomReport,
144
144
  draInterfaceCustomReport,
145
145
  draBusinessCustomReport,
146
146
  draBusinessCustomLogReport,
147
147
  isOpenJdAppUrl,
148
148
  jdOpenAppParams,
149
149
  createJdOpenAppUrl,
150
150
  isEmpty,
151
151
  isAppClassifyPage,
152
152
  isAppHomeForMarketPage,
153
153
  getJdAppReportPageSource,
154
154
  isImageOptimizeEnable,
155
155
  isPc,
156
156
  ipLoc_djd,
157
157
  isTjM,
158
158
  isTjJxM,
159
159
  isTjScence,
160
160
  isH5AdnJxMini,
161
161
  isTJApp,
162
162
  isH5AdnHaoWuJie,
163
163
  tjChannel,
164
164
  dealJdOpenAppData,
165
165
  jdAppVersionCompare,
166
166
  dealNativePixelToCssPixel,
167
167
  isAppStowShop,
168
168
  getSgmCustomCode,
169
169
  handleSgmCodeTaroVersion,
170
170
  isInGrayscale,
171
171
  isIpadDevice,
172
172
  getBorderStyle,
173
173
  isLanguageForEn,
174
174
  sColor,
175
175
  draInterfaceDSMCustomReport,
176
176
  isTabletDevice,
177
177
  updateContainerWidth,
178
178
  isInJdShopView,
179
179
  isDongWebView,
180
180
  isLanguageForHk,
181
181
  languageNowType,
@@ -1 +1 @@
1
- import {
2
1
  isH5AndJingGouMini,
3
2
  urlCookie,
3
+ import {
4
4
  isJdApp,
5
5
  isWxApp,
6
6
  isIosDevice,
7
7
  isAndroidDevice,
8
8
  isJdAndIosDevice,
9
9
  isJdAndAndroidDevice,
10
10
  isWxMin,
11
11
  isWxMinAndWxapp,
12
12
  isJdMin,
13
13
  isJdMinAndHarmony,
14
14
  isH5,
15
15
  isH5AndJdShopView,
16
16
  isChartH5,
17
17
  isH5AndJdShopViewNativeScroll,
18
18
  isH5AndJdShopViewH5Scroll,
19
19
  isH5AndJdShopH5CustomScrollView,
20
20
  isWxMiniH5View,
21
21
  sliceArrToChunkList,
22
22
  dealAddress,
23
23
  objectToUrlEncode,
24
24
  parseQueryUrlString,
25
25
  setLowSmallPicUrl,
26
26
  setTaroStorage,
27
27
  getTaroStorageKeyValue,
28
28
  removeTaroStorageKey,
29
29
  clearTaroStorageKey,
30
30
  getQualityImage,
31
31
  countStringify,
32
32
  getSystemInfos,
33
33
  getWxAppCookieStr,
34
34
  pxTransformFromData,
35
35
  dealShopContentData,
36
36
  dateFormat,
37
37
  throttle,
38
38
  lodashThrottle,
39
39
  debounce,
40
40
  addHttps,
41
41
  showSuccessToast,
42
42
  showFailToast,
43
43
  showNormalToast,
44
44
  showShopLoading,
45
45
  hideShopLoading,
46
46
  getAppChannelType,
47
47
  formatTabActiveMenuType,
48
48
  getAvifSupport,
49
49
  getWebpSupport,
50
50
  filterUrlQueryData,
51
51
  sgmCustomReport,
52
52
  draCustomReport,
53
53
  remoteCustomReport,
54
54
  draInterfaceCustomReport,
55
55
  draBusinessCustomReport,
56
56
  draBusinessCustomLogReport,
57
57
  isOpenJdAppUrl,
58
58
  jdOpenAppParams,
59
59
  createJdOpenAppUrl,
60
60
  isEmpty,
61
61
  getJdAppReportPageSource,
62
62
  isMemberPage,
63
63
  isAppClassifyPage,
64
64
  dealJdOpenAppData,
65
65
  jdAppVersionCompare,
66
66
  dealNativePixelToCssPixel,
67
67
  isImageOptimizeEnable,
68
68
  isIpadDevice,
69
69
  getBorderStyle,
70
70
  isLanguageForEn,
71
71
  sColor,
72
72
  draInterfaceDSMCustomReport,
73
73
  isTabletDevice,
74
74
  isLanguageForHk,
75
75
  languageNowType,
76
76
  console.warn('暂未实现', code);
77
77
  console.warn('暂未实现', code);
78
78
  console.warn('🚗 ~~ file: index.ts:93 ~~ wxapp的isInGrayscale还没有实现,不应该被调用!');
79
79
  return false;
80
80
  console.warn('暂未实现');
81
81
  isJdApp,
82
82
  isWxApp,
83
83
  isIosDevice,
84
84
  isAndroidDevice,
85
85
  isHarmonyDevice,
86
86
  isJdAndIosDevice,
87
87
  isJdAndAndroidDevice,
88
88
  isJdAndHarmonyDevice,
89
89
  isJdAndroidX5Core,
90
90
  isWxMin,
91
91
  isWxMinAndWxapp,
92
92
  isJdMin,
93
93
  isMin,
94
94
  isJdMinAndHarmony,
95
95
  isH5,
96
96
  isH5AndJdShopView,
97
97
  isChartH5,
98
98
  isH5AndJdShopViewNativeScroll,
99
99
  isH5AndJdShopViewH5Scroll,
100
100
  isH5AndJdShopH5CustomScrollView,
101
101
  isH5AndJingGouMini,
102
102
  isWxMiniH5View,
103
103
  urlCookie,
104
104
  sliceArrToChunkList,
105
105
  dealAddress,
106
106
  objectToUrlEncode,
107
107
  parseQueryUrlString,
108
108
  setLowSmallPicUrl,
109
109
  setTaroStorage,
110
110
  getTaroStorageKeyValue,
111
111
  removeTaroStorageKey,
112
112
  clearTaroStorageKey,
113
113
  getQualityImage,
114
114
  countStringify,
115
115
  getSystemInfos,
116
116
  getWxAppCookieStr,
117
117
  pxTransformFromData,
118
118
  dealShopContentData,
119
119
  dateFormat,
120
120
  throttle,
121
121
  lodashThrottle,
122
122
  debounce,
123
123
  addHttps,
124
124
  showSuccessToast,
125
125
  showFailToast,
126
126
  showNormalToast,
127
127
  showShopLoading,
128
128
  hideShopLoading,
129
129
  stopNativeScrollEvent,
130
130
  getAppChannelType,
131
131
  formatTabActiveMenuType,
132
132
  getAvifSupport,
133
133
  getWebpSupport,
134
134
  filterUrlQueryData,
135
135
  getFloorDataToDataDefines,
136
136
  sgmCustomReport,
137
137
  draCustomReport,
138
138
  remoteCustomReport,
139
139
  draInterfaceCustomReport,
140
140
  draBusinessCustomReport,
141
141
  draBusinessCustomLogReport,
142
142
  isOpenJdAppUrl,
143
143
  jdOpenAppParams,
144
144
  createJdOpenAppUrl,
145
145
  isEmpty,
146
146
  getJdAppReportPageSource,
147
147
  isMemberPage,
148
148
  isAppClassifyPage,
149
149
  isAppHomeForMarketPage,
150
150
  isImageOptimizeEnable,
151
151
  isPc,
152
152
  ipLoc_djd,
153
153
  isTjM,
154
154
  isTjJxM,
155
155
  isTjScence,
156
156
  isH5AdnJxMini,
157
157
  isTJApp,
158
158
  isH5AdnHaoWuJie,
159
159
  tjChannel,
160
160
  dealJdOpenAppData,
161
161
  jdAppVersionCompare,
162
162
  dealNativePixelToCssPixel,
163
163
  getSgmCustomCode,
164
164
  handleSgmCodeTaroVersion,
165
165
  isInGrayscale,
166
166
  isIpadDevice,
167
167
  getBorderStyle,
168
168
  isLanguageForEn,
169
169
  sColor,
170
170
  draInterfaceDSMCustomReport,
171
171
  isTabletDevice,
172
172
  updateContainerWidth,
173
173
  isInJdShopView,
174
174
  isDongWebView,
175
175
  isLanguageForHk,
176
176
  languageNowType,
@@ -1 +1 @@
1
- import Taro from '@tarojs/taro'
1
+ import Taro from '@tarojs/taro'
@@ -1 +1 @@
1
- var splitOnFirst = function splitOnFirst(string, separator) {
2
1
  return Object.prototype.toString.call(obj);
3
2
  return typeof obj === 'function';
4
3
  return '[object Object]' === getType(obj);
5
4
  return '[object Array]' == getType(obj);
6
5
  return '[object Undefined]' === getType(obj);
7
6
  return '[object Null]' == getType(obj);
8
7
  return typeof obj === 'string';
9
8
  return typeof obj === 'boolean';
10
9
  return '[object Number]' === getType(num);
11
10
  ua = ua || navigator.userAgent;
12
11
  if (name === 'wx') return (/micromessenger/i.test(ua)
13
12
  );
14
13
  if (name === 'qq') return (/qq\//i.test(ua)
15
14
  );
16
15
  if (name === 'weibo') return (/weibo/i.test(ua)
17
16
  );
18
17
  if (name === 'jd') return (/^jdapp/i.test(ua)
19
18
  );
20
19
  if (name === 'jdlittle') return (/^jdltapp/i.test(ua)
21
20
  );
22
21
  if (name === 'mp') return navigator.userAgent.match(/micromessenger/i) && navigator.userAgent.match(/miniprogram/i) || window.__wxjs_environment === 'miniprogram';
23
22
  return false;
24
23
  ua = ua || navigator.userAgent;
25
24
  return (/android/i.test(ua) && !isIOS()
26
25
  );
27
26
  ua = ua || navigator.userAgent;
28
27
  return (/ip(hone|od)|ipad/i.test(ua)
29
28
  );
30
29
  ua = ua || navigator.userAgent;
31
30
  return (/ipad/i.test(ua) || /android/i.test(ua) && !/mobi|mini|fennec/i.test(ua)
32
31
  );
33
32
  ua = ua || navigator.userAgent;
34
33
  return !!ua.match(/ip(hone|od)|android.+mobile|windows (ce|phone)|blackberry|bb10|symbian|webos|firefox.+fennec|opera m(ob|in)i|polaris|iemobile|lgtelecom|nokia|sonyericsson|dolfin|uzard|natebrowser|ktf;|skt;/i);
35
34
  ua = ua || navigator.userAgent;
36
35
  return !!ua.match(/iphone/i);
37
36
  ua = ua || navigator.userAgent;
38
37
  return !!ua.match(/ipad/i);
39
38
  ua = ua || navigator.userAgent;
40
39
  if (name === 'xview') return typeof window.XView !== 'undefined';
41
40
  if (name === 'wk') return !!ua.match(/supportjdshwk/i) || window._is_jdsh_wkwebview == 1;
42
41
  return false;
43
42
  ua = ua || navigator.userAgent;
44
43
  var re = /nettype\/([\S]*)/i;
45
44
  if (isApp('jd', ua)) re = /network\/([^;]*)/i;
46
45
  return re.test(ua) ? RegExp.$1.toLowerCase() : 'unknown';
47
46
  ua = ua || navigator.userAgent;
48
47
  if (!isApp('jd', ua)) return null;
49
48
  return ua.split(';')[4];
50
49
  ua = ua || navigator.userAgent;
51
50
  if (appName === 'jd') return ua.split(';')[2] || null;
52
51
  if (appName === 'wx') return (/micromessenger\/([\S]*)/i.test(ua) ? RegExp.$1 : null
53
52
  );
54
53
  if (appName === 'qq') return (/qq\/([\S]*)/i.test(ua) ? RegExp.$1 : null
55
54
  );
56
55
  return null;
57
56
  ua = ua || navigator.userAgent;
58
57
  var match = ua.match(/android\s([0-9\.]*)/i);
59
58
  return match ? match[1] : 'unknown';
60
59
  ua = ua || navigator.userAgent;
61
60
  var match = ua.match(/OS ((\d+_?){2,3})\s/i);
62
61
  return match ? match[1].replace(/_/g, '.') : 'unknown';
62
+ var splitOnFirst = function splitOnFirst(string, separator) {
63
63
  return Object.prototype.toString.call(obj);
64
64
  return typeof obj === 'function';
65
65
  return '[object Object]' === getType(obj);
66
66
  return '[object Array]' == getType(obj);
67
67
  return '[object Undefined]' === getType(obj);
68
68
  return '[object Null]' == getType(obj);
69
69
  return typeof obj === 'string';
70
70
  return typeof obj === 'boolean';
71
71
  return '[object Number]' === getType(num);
72
72
  ua = ua || navigator.userAgent;
73
73
  if (name === 'wx') return (/micromessenger/i.test(ua)
74
74
  );
75
75
  if (name === 'qq') return (/qq\//i.test(ua)
76
76
  );
77
77
  if (name === 'weibo') return (/weibo/i.test(ua)
78
78
  );
79
79
  if (name === 'jd') return (/^jdapp/i.test(ua)
80
80
  );
81
81
  if (name === 'jdharmony') return (/^jdapp;harmony/i.test(ua)
82
82
  );
83
83
  if (name === 'jdlittle') return (/^jdltapp/i.test(ua)
84
84
  );
85
85
  if (name === 'mp') return navigator.userAgent.match(/micromessenger/i) && navigator.userAgent.match(/miniprogram/i) || window.__wxjs_environment === 'miniprogram';
86
86
  if (name === 'jdb') return (/JDBmall/i.test(ua) && /shop\.m\.jd\.com\/shop\/bhome/i.test(window.location.href));
87
87
  if(name === 'jdjch') return (/jdjchshopapp/i.test(ua) || (/shop\.m\.jd\.com\/shop\/bhome/i.test(window.location.href)) && window.location.href.includes('channel')) ;
88
88
  if(name == 'tjapp') return /jdltapp;/.test(ua);
89
89
  return false;
90
90
  ua = ua || navigator.userAgent;
91
91
  return (/android/i.test(ua) && !isIOS()
92
92
  );
93
93
  ua = ua || navigator.userAgent;
94
94
  return (/ip(hone|od)|ipad/i.test(ua)
95
95
  );
96
96
  ua = ua || navigator.userAgent;
97
97
  return (/ipad/i.test(ua) || /android/i.test(ua) && !/mobi|mini|fennec/i.test(ua)
98
98
  );
99
99
  ua = ua || navigator.userAgent;
100
100
  return !!ua.match(/ip(hone|od)|android.+mobile|windows (ce|phone)|blackberry|bb10|symbian|webos|firefox.+fennec|opera m(ob|in)i|polaris|iemobile|lgtelecom|nokia|sonyericsson|dolfin|uzard|natebrowser|ktf;|skt;/i);
101
101
  ua = ua || navigator.userAgent;
102
102
  return !!ua.match(/iphone/i);
103
103
  ua = ua || navigator.userAgent;
104
104
  return !!ua.match(/ipad/i);
105
105
  ua = ua || navigator.userAgent;
106
106
  if (name === 'xview') return typeof window.XView !== 'undefined';
107
107
  if (name === 'wk') return !!ua.match(/supportjdshwk/i) || window._is_jdsh_wkwebview == 1;
108
108
  return false;
109
109
  ua = ua || navigator.userAgent;
110
110
  var re = /nettype\/([\S]*)/i;
111
111
  if (isApp('jd', ua)) re = /network\/([^;]*)/i;
112
112
  return re.test(ua) ? RegExp.$1.toLowerCase() : 'unknown';
113
113
  ua = ua || navigator.userAgent;
114
114
  if (!isApp('jd', ua)) return null;
115
115
  return ua.split(';')[4];
116
116
  ua = ua || navigator.userAgent;
117
117
  if (appName === 'jd') return ua.split(';')[2] || null;
118
118
  if (appName === 'wx') return (/micromessenger\/([\S]*)/i.test(ua) ? RegExp.$1 : null
119
119
  );
120
120
  if (appName === 'qq') return (/qq\/([\S]*)/i.test(ua) ? RegExp.$1 : null
121
121
  );
122
122
  return null;
123
123
  ua = ua || navigator.userAgent;
124
124
  var match = ua.match(/android\s([0-9\.]*)/i);
125
125
  return match ? match[1] : 'unknown';
126
126
  ua = ua || navigator.userAgent;
127
127
  var match = ua.match(/OS ((\d+_?){2,3})\s/i);
128
128
  return match ? match[1].replace(/_/g, '.') : 'unknown';
@@ -0,0 +1 @@
1
+ import { isH5, isJdAndIosDevice, isJdAndAndroidDevice } from './index';
2
  'The current environment does not support the getEnterShopJumpExtMap method call!';
1
3
  const routerURL = 'router://JDShopModule/getHomeEntranceObj';
2
4
  const callBackName = `nativeGetHomeEntranceObj${Date.now()}`;
3
5
  const params = {
4
6
  routerURL,
5
7
  routerParam: null,
6
8
  callBackName,
7
9
  };
8
10
  return new Promise((resolve) => {
9
11
  window[callBackName] = (res) => {
10
12
  const data = typeof res === 'string' ? JSON.parse(res) : res;
11
13
  const tempVal = data?.data?.jumpExtMap ?? {};
12
14
  const entranceObj = typeof tempVal === 'string' ? JSON.parse(tempVal) : tempVal;
13
15
  resolve(entranceObj);
14
16
  };
15
17
  if (isH5 && isJdAndAndroidDevice) {
16
18
  callRouterAndroid(params);
17
19
  } else if (isH5 && isJdAndIosDevice) {
18
20
  callRouterIOS(params);
19
21
  } else {
20
22
  console.warn(errorTip);
21
23
  resolve({});
22
24
  }
23
25
  });
24
26
  getEnterShopJumpExtMap()
25
27
  .then((data) => {
26
28
  hasResult = true;
27
29
  entranceObj = data;
28
30
  })
29
31
  .catch((e) => {
30
32
  console.error('requestServer.getEnterShopJumpExtMap() ~~ error:', e);
31
33
  });
32
34
  hasResult = true;
33
35
  console.warn(errorTip);
34
36
  return entranceObj;
35
37
  const { smartCouponInfo = [] } = entranceObj;
36
38
  const info = smartCouponInfo.find((item) => item.skuId === skuId + '');
37
39
  return info ? info.adInfos : null;
38
40
  return new Promise((resolve) => {
39
41
  if (hasResult) {
40
42
  resolve(entranceObj.smartCouponInfo);
41
43
  } else {
42
44
  setTimeout(() => {
43
45
  resolve(entranceObj.smartCouponInfo || null);
44
46
  }, 16);
45
47
  }
46
48
  });
@@ -0,0 +1 @@
1
+ function getEnterShopExtInfo() {
2
  console.warn("~~ getEnterShopExtInfo() ~~ 暂不支持")
1
3
  return {};
2
4
  console.warn("~~ getAdInfoBySkuId() ~~ 暂不支持")
3
5
  return null;
4
6
  console.warn("~~ getSmartCouponInfo() ~~ 暂不支持")
5
7
  return new Promise((resolve) => {
6
8
  resolve(null);
7
9
  });
@@ -0,0 +1 @@
1
+ const reg = /([\d|\.]+)/;
2
  const newPrice = (price + '').match(reg);
1
3
  if (Array.isArray(newPrice) && newPrice.length > 0) {
2
4
  return newPrice[0];
3
5
  }
4
6
  return '0';
5
7
  const tmpPrice = parseFloat(price);
6
8
  return tmpPrice.toFixed(2);
7
9
  const tmpPrice = formatPrice(price);
8
10
  const priceArray = tmpPrice.split('.');
9
11
  let decPart;
10
12
  if (tmpPrice.length > 1) {
11
13
  decPart = priceArray[1];
12
14
  } else {
13
15
  decPart = '00';
14
16
  }
15
17
  return {
16
18
  intPart: priceArray[0],
17
19
  decPart
18
20
  }
@@ -0,0 +1 @@
1
+ function checkExpression(expression: any, context: any = window) {
2
  let isExist = false
1
3
  const isFunction = typeof expression === 'function'
2
4
  if (isFunction) {
3
5
  if (expression()) {
4
6
  isExist = true
5
7
  }
6
8
  } else {
7
9
  if (context[expression] !== undefined) {
8
10
  isExist = true
9
11
  }
10
12
  }
11
13
  return isExist
12
14
  expression: any,
13
15
  timeout: number = 1000,
14
16
  context: any = window,
15
17
  return new Promise((resolve, reject) => {
16
18
  const interval = 16 * 5
17
19
  const endTime = Date.now() + timeout
18
20
  function checkReady() {
19
21
  if (checkExpression(expression, context)) {
20
22
  resolve()
21
23
  } else if (Date.now() < endTime) {
22
24
  setTimeout(checkReady, interval)
23
25
  } else {
24
26
  reject('ready check timeout')
25
27
  }
26
28
  }
27
29
  checkReady()
28
30
  })
@@ -0,0 +1 @@
1
+ const colorDSM = 'https://api.m.jd.com/client.action?functionId=';
2
  [
1
3
  colorDSM + 'op_getGoodListByCatesIds',
2
4
  ['dsm.jshop.operations.api.inner.service.ProductJsfService.getGoodListByCatesIds', true],
3
5
  ,
4
6
  ],
5
7
  console.log('getSColorPara ~ url is:', url);
6
8
  url = colorDSM + url;
7
9
  if (isDowngradeSDM(url)) {
8
10
  return {};
9
11
  }
10
12
  return getDSMValue(url)
11
13
  ? {
12
14
  url: '/api?v=1.0&appId=IEAFE4HKEFPYCKVAUVBR&api=' + getDSMValue(url)[0],
13
15
  }
14
16
  : {};
15
17
  url = colorDSM + url;
16
18
  try {
17
19
  if (isDowngradeSDM(url)) {
18
20
  return false;
19
21
  }
20
22
  console.log('is DSM', !!getDSMValue(url));
21
23
  return !!getDSMValue(url);
22
24
  } catch (error) {
23
25
  console.log('🚀 ~ checkIsDSM ~ error:', error);
24
26
  return false;
25
27
  }
26
28
  url = colorDSM + url;
27
29
  if (isDowngradeSDM(url)) {
28
30
  return false;
29
31
  }
30
32
  console.log('is need deconstruction', getDSMValue(url) ? getDSMValue(url)[1] : false);
31
33
  return getDSMValue(url) ? getDSMValue(url)[1] : false;
32
34
  for (let [key, value] of DSM) {
33
35
  if (url.startsWith(key) && url.includes('?')) {
34
36
  return value;
35
37
  }
36
38
  if (key === url) {
37
39
  return value;
38
40
  }
39
41
  }
40
42
  return '';
41
43
  try {
42
44
  const { nodePageData } = window;
43
45
  const { DSMDowngradeList = null, routeBlackList = null } = nodePageData;
44
46
  if (
45
47
  nodePageData &&
46
48
  routeBlackList &&
47
49
  Array.isArray(routeBlackList) &&
48
50
  ((routeBlackList.length > 0 &&
49
51
  routeBlackList.some((prefix) => url.startsWith(prefix)) &&
50
52
  url.includes('?')) ||
51
53
  routeBlackList.includes(url))
52
54
  ) {
53
55
  return true;
54
56
  }
55
57
  if (DSMDowngradeList === null) return true;
56
58
  if (
57
59
  !Array.isArray(DSMDowngradeList) ||
58
60
  (DSMDowngradeList.length > 0 &&
59
61
  DSMDowngradeList.some((prefix) => url.startsWith(prefix)) &&
60
62
  url.includes('?')) ||
61
63
  DSMDowngradeList.includes(url)
62
64
  ) {
63
65
  return true;
64
66
  }
65
67
  return false;
66
68
  } catch (error) {
67
69
  console.log('🚀 ~ isDowngradeSDM ~ error:', error)
68
70
  return false;
69
71
  }
70
72
  getSColorPara: (url) => getSColorPara(url),
71
73
  checkIsNeedDeconstruction: (url) => checkIsNeedDeconstruction(url),
72
74
  checkIsDSM: (url) => checkIsDSM(url),