@cloudbase/weda-ui 2.0.26 → 3.1.0

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 (411) hide show
  1. package/package.json +12 -13
  2. package/src/configs/actions/showModal.json +0 -48
  3. package/src/configs/actions/showToast.json +0 -41
  4. package/src/configs/components/auth.json +0 -16
  5. package/src/configs/components/button.json +0 -239
  6. package/src/configs/components/calendar.json +0 -81
  7. package/src/configs/components/carousel.json +0 -292
  8. package/src/configs/components/chart/bar.json +0 -721
  9. package/src/configs/components/chart/line.json +0 -674
  10. package/src/configs/components/chart/pie.json +0 -494
  11. package/src/configs/components/chart/statisticsCard.json +0 -376
  12. package/src/configs/components/container.json +0 -50
  13. package/src/configs/components/dataView.json +0 -151
  14. package/src/configs/components/drawer.json +0 -115
  15. package/src/configs/components/form/checkbox.json +0 -173
  16. package/src/configs/components/form/form.json +0 -45
  17. package/src/configs/components/form/input.json +0 -154
  18. package/src/configs/components/form/label.json +0 -22
  19. package/src/configs/components/form/location.json +0 -155
  20. package/src/configs/components/form/radio.json +0 -203
  21. package/src/configs/components/form/richText.json +0 -125
  22. package/src/configs/components/form/select.json +0 -411
  23. package/src/configs/components/form/switch.json +0 -58
  24. package/src/configs/components/form/textarea.json +0 -116
  25. package/src/configs/components/form/tips.json +0 -34
  26. package/src/configs/components/form/uploader.json +0 -169
  27. package/src/configs/components/form/uploaderFile.json +0 -158
  28. package/src/configs/components/graphicCard.json +0 -413
  29. package/src/configs/components/image.json +0 -179
  30. package/src/configs/components/link.json +0 -79
  31. package/src/configs/components/listView.json +0 -281
  32. package/src/configs/components/lottery.json +0 -157
  33. package/src/configs/components/modal.json +0 -83
  34. package/src/configs/components/navLayout.json +0 -368
  35. package/src/configs/components/navigationBar.json +0 -62
  36. package/src/configs/components/picker/datePicker.json +0 -33
  37. package/src/configs/components/picker/picker.json +0 -18
  38. package/src/configs/components/picker/timePicker.json +0 -23
  39. package/src/configs/components/richtextview.json +0 -26
  40. package/src/configs/components/scrollVeiw.json +0 -253
  41. package/src/configs/components/slot.json +0 -17
  42. package/src/configs/components/swiper.json +0 -90
  43. package/src/configs/components/tabs.json +0 -121
  44. package/src/configs/components/text.json +0 -95
  45. package/src/configs/components/wedaVideo.json +0 -89
  46. package/src/configs/components/wxOpenApi/phone.json +0 -127
  47. package/src/configs/components/wxOpenApi/phoneCode.json +0 -109
  48. package/src/configs/components/wxOpenApi/share.json +0 -157
  49. package/src/configs/components/wxOpenApi/userInfo.json +0 -156
  50. package/src/configs/index.js +0 -111
  51. package/src/index.js +0 -4
  52. package/src/mp/README.md +0 -1
  53. package/src/mp/actions/showModal/index.js +0 -3
  54. package/src/mp/actions/showToast/index.js +0 -3
  55. package/src/mp/components/button/index.js +0 -91
  56. package/src/mp/components/button/index.json +0 -4
  57. package/src/mp/components/button/index.wxml +0 -22
  58. package/src/mp/components/button/index.wxss +0 -13
  59. package/src/mp/components/calendar/arrowright--line.svg +0 -11
  60. package/src/mp/components/calendar/index.js +0 -268
  61. package/src/mp/components/calendar/index.json +0 -5
  62. package/src/mp/components/calendar/index.wxml +0 -35
  63. package/src/mp/components/calendar/index.wxss +0 -179
  64. package/src/mp/components/carousel/index.js +0 -88
  65. package/src/mp/components/carousel/index.json +0 -7
  66. package/src/mp/components/carousel/index.wxml +0 -6
  67. package/src/mp/components/chart/bar/index.js +0 -257
  68. package/src/mp/components/chart/bar/index.json +0 -6
  69. package/src/mp/components/chart/bar/index.wxml +0 -3
  70. package/src/mp/components/chart/bar/index.wxss +0 -9
  71. package/src/mp/components/chart/common/config/bar.js +0 -50
  72. package/src/mp/components/chart/common/config/global.js +0 -16
  73. package/src/mp/components/chart/common/config/line.js +0 -48
  74. package/src/mp/components/chart/common/config/pie.js +0 -36
  75. package/src/mp/components/chart/common/core/eChartBar.js +0 -258
  76. package/src/mp/components/chart/common/core/eChartBase.js +0 -389
  77. package/src/mp/components/chart/common/core/eChartLine.js +0 -223
  78. package/src/mp/components/chart/common/core/eChartPie.js +0 -169
  79. package/src/mp/components/chart/common/lib/echarts.min.js +0 -18
  80. package/src/mp/components/chart/ec-canvas/ec-canvas.js +0 -277
  81. package/src/mp/components/chart/ec-canvas/ec-canvas.json +0 -4
  82. package/src/mp/components/chart/ec-canvas/ec-canvas.wxml +0 -4
  83. package/src/mp/components/chart/ec-canvas/ec-canvas.wxss +0 -4
  84. package/src/mp/components/chart/ec-canvas/wx-canvas.js +0 -109
  85. package/src/mp/components/chart/line/index.js +0 -247
  86. package/src/mp/components/chart/line/index.json +0 -6
  87. package/src/mp/components/chart/line/index.wxml +0 -3
  88. package/src/mp/components/chart/line/index.wxss +0 -9
  89. package/src/mp/components/chart/pie/index.js +0 -182
  90. package/src/mp/components/chart/pie/index.json +0 -6
  91. package/src/mp/components/chart/pie/index.wxml +0 -3
  92. package/src/mp/components/chart/pie/index.wxss +0 -9
  93. package/src/mp/components/chart/statisticsCard/index.js +0 -253
  94. package/src/mp/components/chart/statisticsCard/index.json +0 -4
  95. package/src/mp/components/chart/statisticsCard/index.wxml +0 -9
  96. package/src/mp/components/chart/statisticsCard/index.wxss +0 -42
  97. package/src/mp/components/container/index.js +0 -20
  98. package/src/mp/components/container/index.json +0 -4
  99. package/src/mp/components/container/index.wxml +0 -3
  100. package/src/mp/components/dataView/index.js +0 -34
  101. package/src/mp/components/dataView/index.json +0 -7
  102. package/src/mp/components/dataView/index.wxml +0 -3
  103. package/src/mp/components/dataView/index.wxss +0 -0
  104. package/src/mp/components/form/checkbox/index.js +0 -124
  105. package/src/mp/components/form/checkbox/index.json +0 -7
  106. package/src/mp/components/form/checkbox/index.wxml +0 -13
  107. package/src/mp/components/form/checkbox/index.wxss +0 -1
  108. package/src/mp/components/form/form/index.js +0 -18
  109. package/src/mp/components/form/form/index.json +0 -4
  110. package/src/mp/components/form/form/index.wxml +0 -5
  111. package/src/mp/components/form/form/index.wxss +0 -1
  112. package/src/mp/components/form/formcell/index.js +0 -54
  113. package/src/mp/components/form/formcell/index.json +0 -4
  114. package/src/mp/components/form/formcell/index.wxml +0 -11
  115. package/src/mp/components/form/formcell/index.wxss +0 -31
  116. package/src/mp/components/form/input/index.js +0 -110
  117. package/src/mp/components/form/input/index.json +0 -7
  118. package/src/mp/components/form/input/index.wxml +0 -24
  119. package/src/mp/components/form/input/index.wxss +0 -22
  120. package/src/mp/components/form/location/components/mapChoose/index.js +0 -201
  121. package/src/mp/components/form/location/components/mapChoose/index.json +0 -4
  122. package/src/mp/components/form/location/components/mapChoose/index.wxml +0 -42
  123. package/src/mp/components/form/location/components/mapChoose/index.wxss +0 -188
  124. package/src/mp/components/form/location/index.js +0 -388
  125. package/src/mp/components/form/location/index.json +0 -6
  126. package/src/mp/components/form/location/index.wxml +0 -21
  127. package/src/mp/components/form/location/index.wxss +0 -89
  128. package/src/mp/components/form/radio/index.js +0 -124
  129. package/src/mp/components/form/radio/index.json +0 -7
  130. package/src/mp/components/form/radio/index.wxml +0 -13
  131. package/src/mp/components/form/radio/index.wxss +0 -1
  132. package/src/mp/components/form/select/index.js +0 -677
  133. package/src/mp/components/form/select/index.json +0 -7
  134. package/src/mp/components/form/select/index.wxml +0 -12
  135. package/src/mp/components/form/select/index.wxss +0 -16
  136. package/src/mp/components/form/select/region/index.js +0 -107
  137. package/src/mp/components/form/switch/index.js +0 -75
  138. package/src/mp/components/form/switch/index.json +0 -7
  139. package/src/mp/components/form/switch/index.wxml +0 -11
  140. package/src/mp/components/form/switch/index.wxss +0 -1
  141. package/src/mp/components/form/textarea/index.js +0 -90
  142. package/src/mp/components/form/textarea/index.json +0 -7
  143. package/src/mp/components/form/textarea/index.wxml +0 -8
  144. package/src/mp/components/form/textarea/index.wxss +0 -10
  145. package/src/mp/components/form/tips/index.js +0 -41
  146. package/src/mp/components/form/tips/index.json +0 -4
  147. package/src/mp/components/form/tips/index.wxml +0 -1
  148. package/src/mp/components/form/tips/index.wxss +0 -1
  149. package/src/mp/components/form/uploader/index.js +0 -158
  150. package/src/mp/components/form/uploader/index.json +0 -10
  151. package/src/mp/components/form/uploader/index.wxml +0 -14
  152. package/src/mp/components/form/uploader/index.wxss +0 -36
  153. package/src/mp/components/form/uploader/weui-uploader.js +0 -219
  154. package/src/mp/components/form/uploader/weui-uploader.json +0 -7
  155. package/src/mp/components/form/uploader/weui-uploader.wxml +0 -45
  156. package/src/mp/components/form/uploader/weui-uploader.wxss +0 -1
  157. package/src/mp/components/form/uploaderFile/index.js +0 -313
  158. package/src/mp/components/form/uploaderFile/index.json +0 -9
  159. package/src/mp/components/form/uploaderFile/index.wxml +0 -45
  160. package/src/mp/components/form/uploaderFile/index.wxss +0 -105
  161. package/src/mp/components/graphicCard/chevron-right.svg +0 -3
  162. package/src/mp/components/graphicCard/index.js +0 -203
  163. package/src/mp/components/graphicCard/index.json +0 -4
  164. package/src/mp/components/graphicCard/index.wxml +0 -25
  165. package/src/mp/components/graphicCard/index.wxss +0 -157
  166. package/src/mp/components/image/index.js +0 -182
  167. package/src/mp/components/image/index.json +0 -7
  168. package/src/mp/components/image/index.wxml +0 -9
  169. package/src/mp/components/image/index.wxss +0 -49
  170. package/src/mp/components/listView/arrow-right-line.svg +0 -3
  171. package/src/mp/components/listView/index.js +0 -274
  172. package/src/mp/components/listView/index.json +0 -4
  173. package/src/mp/components/listView/index.wxml +0 -38
  174. package/src/mp/components/listView/index.wxss +0 -155
  175. package/src/mp/components/listView/more-line.svg +0 -3
  176. package/src/mp/components/lottery/index.js +0 -270
  177. package/src/mp/components/lottery/index.json +0 -4
  178. package/src/mp/components/lottery/index.wxml +0 -41
  179. package/src/mp/components/lottery/index.wxss +0 -323
  180. package/src/mp/components/modal/index.js +0 -39
  181. package/src/mp/components/modal/index.json +0 -4
  182. package/src/mp/components/modal/index.wxml +0 -1
  183. package/src/mp/components/navLayout/index.js +0 -120
  184. package/src/mp/components/navLayout/index.json +0 -7
  185. package/src/mp/components/navLayout/index.wxml +0 -23
  186. package/src/mp/components/navLayout/index.wxss +0 -1193
  187. package/src/mp/components/navigationBar/index.js +0 -193
  188. package/src/mp/components/navigationBar/index.json +0 -5
  189. package/src/mp/components/navigationBar/index.wxml +0 -80
  190. package/src/mp/components/navigationBar/index.wxss +0 -1257
  191. package/src/mp/components/richText/index.js +0 -67
  192. package/src/mp/components/richText/index.json +0 -4
  193. package/src/mp/components/richText/index.wxml +0 -3
  194. package/src/mp/components/richText/index.wxss +0 -27
  195. package/src/mp/components/scrollView/index.js +0 -119
  196. package/src/mp/components/scrollView/index.json +0 -4
  197. package/src/mp/components/scrollView/index.wxml +0 -38
  198. package/src/mp/components/slot/index.js +0 -20
  199. package/src/mp/components/slot/index.json +0 -4
  200. package/src/mp/components/slot/index.wxml +0 -3
  201. package/src/mp/components/swiper/index.js +0 -65
  202. package/src/mp/components/swiper/index.json +0 -4
  203. package/src/mp/components/swiper/index.wxml +0 -3
  204. package/src/mp/components/tabs/index.js +0 -59
  205. package/src/mp/components/tabs/index.json +0 -4
  206. package/src/mp/components/tabs/index.wxml +0 -12
  207. package/src/mp/components/tabs/index.wxss +0 -57
  208. package/src/mp/components/text/index.js +0 -40
  209. package/src/mp/components/text/index.json +0 -4
  210. package/src/mp/components/text/index.wxml +0 -1
  211. package/src/mp/components/text/index.wxss +0 -26
  212. package/src/mp/components/wedaVideo/index.js +0 -86
  213. package/src/mp/components/wedaVideo/index.json +0 -4
  214. package/src/mp/components/wedaVideo/index.wxml +0 -4
  215. package/src/mp/components/wedaVideo/index.wxss +0 -20
  216. package/src/mp/components/wxOpenApi/phone/index.js +0 -109
  217. package/src/mp/components/wxOpenApi/phone/index.json +0 -4
  218. package/src/mp/components/wxOpenApi/phone/index.wxml +0 -4
  219. package/src/mp/components/wxOpenApi/phone/index.wxss +0 -22
  220. package/src/mp/components/wxOpenApi/phoneCode/index.js +0 -89
  221. package/src/mp/components/wxOpenApi/phoneCode/index.json +0 -4
  222. package/src/mp/components/wxOpenApi/phoneCode/index.wxml +0 -4
  223. package/src/mp/components/wxOpenApi/phoneCode/index.wxss +0 -22
  224. package/src/mp/components/wxOpenApi/share/index.js +0 -117
  225. package/src/mp/components/wxOpenApi/share/index.json +0 -4
  226. package/src/mp/components/wxOpenApi/share/index.wxml +0 -4
  227. package/src/mp/components/wxOpenApi/share/index.wxss +0 -22
  228. package/src/mp/components/wxOpenApi/userInfo/index.js +0 -88
  229. package/src/mp/components/wxOpenApi/userInfo/index.json +0 -4
  230. package/src/mp/components/wxOpenApi/userInfo/index.wxml +0 -4
  231. package/src/mp/components/wxOpenApi/userInfo/index.wxss +0 -22
  232. package/src/mp/index.json +0 -52
  233. package/src/mp/package.json +0 -6
  234. package/src/mp/style/weda-ui.wxss +0 -71
  235. package/src/mp/utils/classnames.js +0 -39
  236. package/src/mp/utils/constant.js +0 -20
  237. package/src/mp/utils/dayjs.min.js +0 -1
  238. package/src/mp/utils/debounce.js +0 -133
  239. package/src/mp/utils/deepEqual.js +0 -42
  240. package/src/mp/utils/destr.js +0 -49
  241. package/src/mp/utils/dr_square_point.js +0 -29
  242. package/src/mp/utils/handleEvents.js +0 -32
  243. package/src/mp/utils/lodash.js +0 -2
  244. package/src/mp/utils/platform.js +0 -45
  245. package/src/mp/utils/qqmap-wx-jssdk1.2/qqmap-wx-jssdk.js +0 -1336
  246. package/src/mp/utils/spark-md5.js +0 -776
  247. package/src/mp/utils/tcb.js +0 -76
  248. package/src/setupTests.js +0 -14
  249. package/src/web/actions/index.js +0 -2
  250. package/src/web/actions/showModal/index.tsx +0 -118
  251. package/src/web/actions/showToast/index.js +0 -3
  252. package/src/web/components/auth/index.css +0 -0
  253. package/src/web/components/auth/index.js +0 -66
  254. package/src/web/components/button/index.css +0 -27
  255. package/src/web/components/button/index.tsx +0 -119
  256. package/src/web/components/calendar/index.css +0 -416
  257. package/src/web/components/calendar/index.jsx +0 -312
  258. package/src/web/components/calendar/util.js +0 -90
  259. package/src/web/components/carousel/index.css +0 -119
  260. package/src/web/components/carousel/index.tsx +0 -417
  261. package/src/web/components/chart/bar/index.tsx +0 -140
  262. package/src/web/components/chart/common/config/bar.js +0 -49
  263. package/src/web/components/chart/common/config/global.js +0 -16
  264. package/src/web/components/chart/common/config/line.js +0 -50
  265. package/src/web/components/chart/common/config/pie.js +0 -37
  266. package/src/web/components/chart/common/core/eChartBar.js +0 -259
  267. package/src/web/components/chart/common/core/eChartBase.ts +0 -396
  268. package/src/web/components/chart/common/core/eChartLine.js +0 -225
  269. package/src/web/components/chart/common/core/eChartPie.js +0 -173
  270. package/src/web/components/chart/common/core/type.ts +0 -34
  271. package/src/web/components/chart/common/echart.css +0 -106
  272. package/src/web/components/chart/common/echarts.ts +0 -31
  273. package/src/web/components/chart/common/useChart.tsx +0 -87
  274. package/src/web/components/chart/line/index.tsx +0 -136
  275. package/src/web/components/chart/pie/index.tsx +0 -99
  276. package/src/web/components/chart/statisticsCard/index.css +0 -63
  277. package/src/web/components/chart/statisticsCard/index.tsx +0 -307
  278. package/src/web/components/chart/statisticsCard/interface.ts +0 -14
  279. package/src/web/components/container/index.tsx +0 -34
  280. package/src/web/components/dataView/index.tsx +0 -20
  281. package/src/web/components/dataView/interface.ts +0 -6
  282. package/src/web/components/drawer/index.tsx +0 -68
  283. package/src/web/components/form/checkbox/index.tsx +0 -210
  284. package/src/web/components/form/enumSelect/MultipleSelect.jsx +0 -89
  285. package/src/web/components/form/enumSelect/NormalSelect.tsx +0 -92
  286. package/src/web/components/form/enumSelect/SelectContainer.jsx +0 -43
  287. package/src/web/components/form/enumSelect/index.jsx +0 -9
  288. package/src/web/components/form/enumSelect/props/defaultProps.js +0 -39
  289. package/src/web/components/form/enumSelect/props/propsTypes.js +0 -50
  290. package/src/web/components/form/form/index.css +0 -9
  291. package/src/web/components/form/form/index.tsx +0 -51
  292. package/src/web/components/form/formcell/index.css +0 -85
  293. package/src/web/components/form/formcell/index.tsx +0 -85
  294. package/src/web/components/form/input/index.css +0 -40
  295. package/src/web/components/form/input/index.tsx +0 -166
  296. package/src/web/components/form/location/common/mapChoose.css +0 -180
  297. package/src/web/components/form/location/common/mapChoose.jsx +0 -343
  298. package/src/web/components/form/location/common/mapView.jsx +0 -190
  299. package/src/web/components/form/location/common/propsConfig.js +0 -54
  300. package/src/web/components/form/location/common/selectModal.css +0 -44
  301. package/src/web/components/form/location/common/selectModal.jsx +0 -73
  302. package/src/web/components/form/location/common/useLocationInfo.js +0 -104
  303. package/src/web/components/form/location/components/LocationH5/index.css +0 -239
  304. package/src/web/components/form/location/components/LocationH5/location.h5.jsx +0 -413
  305. package/src/web/components/form/location/components/LocationPC/Header.jsx +0 -96
  306. package/src/web/components/form/location/components/LocationPC/index.css +0 -44
  307. package/src/web/components/form/location/components/LocationPC/location.PC.jsx +0 -332
  308. package/src/web/components/form/location/constants.js +0 -4
  309. package/src/web/components/form/location/index.css +0 -0
  310. package/src/web/components/form/location/index.jsx +0 -25
  311. package/src/web/components/form/radio/index.css +0 -12
  312. package/src/web/components/form/radio/index.tsx +0 -179
  313. package/src/web/components/form/renderDecorator.tsx +0 -28
  314. package/src/web/components/form/select/h5.tsx +0 -602
  315. package/src/web/components/form/select/index.css +0 -27
  316. package/src/web/components/form/select/index.tsx +0 -510
  317. package/src/web/components/form/select/region/index.ts +0 -152
  318. package/src/web/components/form/select/time.jsx +0 -145
  319. package/src/web/components/form/select/year.tsx +0 -172
  320. package/src/web/components/form/switch/index.tsx +0 -100
  321. package/src/web/components/form/textarea/index.css +0 -11
  322. package/src/web/components/form/textarea/index.tsx +0 -127
  323. package/src/web/components/form/tips/index.css +0 -4
  324. package/src/web/components/form/tips/index.tsx +0 -34
  325. package/src/web/components/form/types.d.ts +0 -12
  326. package/src/web/components/form/uploader/index.css +0 -118
  327. package/src/web/components/form/uploader/index.tsx +0 -65
  328. package/src/web/components/form/uploader/uploader.h5.tsx +0 -290
  329. package/src/web/components/form/uploader/uploader.pc.tsx +0 -287
  330. package/src/web/components/form/uploaderFile/fail.svg +0 -12
  331. package/src/web/components/form/uploaderFile/index.css +0 -422
  332. package/src/web/components/form/uploaderFile/index.jsx +0 -25
  333. package/src/web/components/form/uploaderFile/pending.svg +0 -18
  334. package/src/web/components/form/uploaderFile/success.svg +0 -12
  335. package/src/web/components/form/uploaderFile/uploadFile.h5.tsx +0 -606
  336. package/src/web/components/form/uploaderFile/uploadFile.pc.tsx +0 -520
  337. package/src/web/components/graphicCard/index.css +0 -159
  338. package/src/web/components/graphicCard/index.tsx +0 -310
  339. package/src/web/components/image/image.tsx +0 -187
  340. package/src/web/components/image/index.css +0 -54
  341. package/src/web/components/image/index.tsx +0 -121
  342. package/src/web/components/index.js +0 -95
  343. package/src/web/components/link/index.css +0 -8
  344. package/src/web/components/link/index.tsx +0 -119
  345. package/src/web/components/listView/arrow-right-line.svg +0 -3
  346. package/src/web/components/listView/index.css +0 -143
  347. package/src/web/components/listView/index.tsx +0 -346
  348. package/src/web/components/listView/interface.ts +0 -98
  349. package/src/web/components/lottery/index.css +0 -333
  350. package/src/web/components/lottery/index.tsx +0 -567
  351. package/src/web/components/lottery/lotteryUtil.ts +0 -130
  352. package/src/web/components/modal/index.tsx +0 -60
  353. package/src/web/components/navLayout/index.css +0 -332
  354. package/src/web/components/navLayout/index.tsx +0 -247
  355. package/src/web/components/navigationBar/chevron-right--double.svg +0 -3
  356. package/src/web/components/navigationBar/common.tsx +0 -198
  357. package/src/web/components/navigationBar/h5Menu.tsx +0 -179
  358. package/src/web/components/navigationBar/horizontalMenu.tsx +0 -200
  359. package/src/web/components/navigationBar/index.css +0 -762
  360. package/src/web/components/navigationBar/index.tsx +0 -230
  361. package/src/web/components/navigationBar/type.d.ts +0 -111
  362. package/src/web/components/navigationBar/verticalMenu.tsx +0 -81
  363. package/src/web/components/phone/index.css +0 -0
  364. package/src/web/components/phone/index.tsx +0 -22
  365. package/src/web/components/phoneCode/index.css +0 -0
  366. package/src/web/components/phoneCode/index.tsx +0 -22
  367. package/src/web/components/picker/datePicker.tsx +0 -48
  368. package/src/web/components/picker/picker.tsx +0 -59
  369. package/src/web/components/picker/timePicker.tsx +0 -56
  370. package/src/web/components/richText/const.ts +0 -3
  371. package/src/web/components/richText/index.css +0 -93
  372. package/src/web/components/richText/index.jsx +0 -473
  373. package/src/web/components/richTextView/index.css +0 -63
  374. package/src/web/components/richTextView/index.tsx +0 -63
  375. package/src/web/components/scrollView/index.tsx +0 -148
  376. package/src/web/components/share/index.css +0 -0
  377. package/src/web/components/share/index.tsx +0 -38
  378. package/src/web/components/slot/index.tsx +0 -19
  379. package/src/web/components/swiper/index.css +0 -106
  380. package/src/web/components/swiper/index.tsx +0 -291
  381. package/src/web/components/tabs/index.css +0 -64
  382. package/src/web/components/tabs/index.tsx +0 -35
  383. package/src/web/components/tabs/tabs.h5.tsx +0 -84
  384. package/src/web/components/tabs/tabs.pc.tsx +0 -74
  385. package/src/web/components/text/index.css +0 -26
  386. package/src/web/components/text/index.tsx +0 -60
  387. package/src/web/components/uploaderFileView/index.css +0 -11
  388. package/src/web/components/uploaderFileView/index.jsx +0 -84
  389. package/src/web/components/uploaderView/index.css +0 -31
  390. package/src/web/components/uploaderView/index.tsx +0 -92
  391. package/src/web/components/userInfo/index.css +0 -0
  392. package/src/web/components/userInfo/index.tsx +0 -30
  393. package/src/web/components/wedaVideo/index.css +0 -42
  394. package/src/web/components/wedaVideo/index.tsx +0 -208
  395. package/src/web/index.js +0 -4
  396. package/src/web/types.d.ts +0 -21
  397. package/src/web/utils/classnames.js +0 -39
  398. package/src/web/utils/constant.ts +0 -23
  399. package/src/web/utils/debounce.js +0 -98
  400. package/src/web/utils/events.js +0 -2
  401. package/src/web/utils/getLocalCounter.js +0 -5
  402. package/src/web/utils/isObjectEqual.js +0 -15
  403. package/src/web/utils/loading-fallback.tsx +0 -2
  404. package/src/web/utils/lodash.ts +0 -2
  405. package/src/web/utils/platform.js +0 -156
  406. package/src/web/utils/tcb.js +0 -86
  407. package/src/web/utils/tmap.js +0 -4
  408. package/src/web/utils/useSetState.ts +0 -18
  409. package/src/web/utils/useSyncValue.ts +0 -17
  410. package/src/web/utils/weui.js +0 -3
  411. package/src/web/weda-ui.css +0 -86
@@ -1,107 +0,0 @@
1
- import { callWedaApi } from '../../../../utils/tcb';
2
-
3
- export let provinces = [];
4
- export let cities = [];
5
- export let regions = [];
6
- export let regionData = [];
7
- /**
8
- * 获取运行态地区数据
9
- * 查询所有的省市区数据https://iwiki.woa.com/pages/viewpage.action?pageId=1582408865
10
- */
11
- export async function getAreaCode() {
12
- try {
13
- const res = await callWedaApi({
14
- action: 'QueryRuntimeAreaCode',
15
- data: { Mask: '11100' },
16
- });
17
- return res?.AreaCodeList;
18
- } catch (error) {
19
- console.error('错误', error);
20
- return {};
21
- }
22
- }
23
- export const getRegionTree = async function (defaultValue) {
24
- regionData = await getAreaCode();
25
- splitAreaData(regionData, regionData);
26
- return changeResult(defaultValue, regionData);
27
- };
28
- export const splitAreaData = (areaData) => {
29
- provinces = [];
30
- cities = [];
31
- regions = [];
32
- areaData.forEach((item) => {
33
- if (!item.Deprecated) {
34
- if (item?.Type == 1) {
35
- provinces.push(item);
36
- }
37
- if (item?.Type == 2 || (item?.Type == 1 && item.CentralCity)) {
38
- cities.push(item);
39
- } else if (item?.Type == 3) {
40
- regions.push(item);
41
- }
42
- }
43
- });
44
- };
45
- /***
46
- * 用于构建change事件result返回值
47
- */
48
- export const changeResult = (regionValue, areaData) => {
49
- const defaultValue = regionValue ? regionValue.split(',') : null;
50
- const changeValue = [];
51
- const defaultIndex = [];
52
- if (defaultValue && defaultValue.length > 0) {
53
- defaultValue.forEach((element, index) => {
54
- areaData.map((item, id) => {
55
- //区级判重
56
- if (
57
- (item?.Value == element && index != 2) ||
58
- (item?.Value == element &&
59
- item.Code.substr(0, 2) == changeValue[0].code.substr(0, 2) &&
60
- index == 2)
61
- ) {
62
- changeValue.push({
63
- value: item?.Value,
64
- code: item?.Code,
65
- });
66
- defaultIndex.push(id);
67
- }
68
- });
69
- });
70
- }
71
- return { value: regionValue, result: changeValue };
72
- };
73
- /**
74
- * 拼接地区选择默认值显示规则
75
- */
76
- export const buildDisplayValue = (data, indexList, type) => {
77
- let provinceItem = [];
78
- let cityItem;
79
- let regionItem;
80
- switch (type) {
81
- case 'levelOne': {
82
- provinceItem = data[0][indexList[0]];
83
- return {
84
- value: provinceItem.value,
85
- result: [provinceItem],
86
- };
87
- }
88
- case 'levelTwo': {
89
- provinceItem = data[0][indexList[0]];
90
- cityItem = data[1][indexList[1]];
91
- return {
92
- value: provinceItem.value + ',' + cityItem.value,
93
- result: [provinceItem, cityItem],
94
- };
95
- }
96
- case 'levelThree': {
97
- provinceItem = data[0][indexList[0]];
98
- cityItem = data[1][indexList[1]];
99
- regionItem = data[2][indexList[2]];
100
- return {
101
- value:
102
- provinceItem.value + ',' + cityItem.value + ',' + regionItem.value,
103
- result: [provinceItem, cityItem, regionItem],
104
- };
105
- }
106
- }
107
- };
@@ -1,75 +0,0 @@
1
- import classNames from '../../../utils/classnames';
2
- import handleEvents from '../../../utils/handleEvents';
3
-
4
- Component({
5
- options: {
6
- virtualHost: true,
7
- },
8
- properties: {
9
- className: {
10
- type: String,
11
- value: '',
12
- },
13
- style: {
14
- type: String,
15
- value: '',
16
- },
17
- label: {
18
- type: String,
19
- value: '标题',
20
- },
21
- labelVisible: {
22
- type: Boolean,
23
- value: true,
24
- },
25
- checked: {
26
- type: Boolean,
27
- value: false,
28
- },
29
- layout: {
30
- type: String,
31
- value: 'horizontal',
32
- },
33
- disabled: {
34
- type: Boolean,
35
- value: false,
36
- },
37
- requiredFlag: {
38
- type: Boolean,
39
- value: false,
40
- },
41
- },
42
- data: {
43
- cls: '',
44
- subCls: '',
45
- isFlex: true,
46
- },
47
- lifetimes: {
48
- attached() {
49
- const { className, layout, disabled } = this.properties;
50
- const isFlex = layout !== 'vertical';
51
- const cls = classNames({
52
- 'weda-ui': true,
53
- 'weda-switch': true,
54
- [className]: className,
55
- });
56
- const subCls = classNames({
57
- 'weui-cell': true,
58
- 'weui-cell_active': true,
59
- 'weui-cell_switch': true,
60
- 'weui-flex__item': isFlex,
61
- 'weui-cell_disabled': disabled,
62
- });
63
-
64
- this.setData({ cls, subCls, isFlex });
65
- },
66
- },
67
- methods: {
68
- ...handleEvents([
69
- {
70
- name: 'change',
71
- title: '选中状态改变',
72
- },
73
- ]),
74
- },
75
- });
@@ -1,7 +0,0 @@
1
- {
2
- "component": true,
3
- "styleIsolation": "shared",
4
- "usingComponents": {
5
- "formcell": "../formcell"
6
- }
7
- }
@@ -1,11 +0,0 @@
1
- <formcell className="{{cls}}" style="{{style}}" label="{{labelVisible ? label : null}}" layout="{{layout}}" multiCell="{{false}}" requiredFlag="{{requiredFlag}}">
2
- <view class="{{subCls}}">
3
- <view wx:if="{{isFlex}}" class="weui-cell__bd" />
4
- <view class="{{ isFlex? 'weui-cell__ft' : 'weui-cell__bd'}}">
5
- <label class="weui-switch-cp">
6
- <switch class="weui-switch-cp__input" checked="{{checked}}" bindchange="change" />
7
- <view class="weui-switch-cp__box" />
8
- </label>
9
- </view>
10
- </view>
11
- </formcell>
@@ -1 +0,0 @@
1
- @import '../../../style/weda-ui.wxss';
@@ -1,90 +0,0 @@
1
- import classNames from '../../../utils/classnames';
2
-
3
- Component({
4
- options: {
5
- virtualHost: true,
6
- },
7
- properties: {
8
- className: {
9
- type: String,
10
- value: '',
11
- },
12
- style: {
13
- type: String,
14
- value: '',
15
- },
16
- label: {
17
- type: String,
18
- value: '标题',
19
- },
20
- labelVisible: {
21
- type: Boolean,
22
- value: true,
23
- },
24
- defaultValue: {
25
- type: String,
26
- value: '',
27
- },
28
- placeholder: {
29
- type: String,
30
- value: '请输入',
31
- },
32
- maxLength: {
33
- type: Number,
34
- value: 140,
35
- },
36
- disabled: {
37
- type: Boolean,
38
- value: false,
39
- },
40
- focus: {
41
- type: Boolean,
42
- value: false,
43
- },
44
- layout: {
45
- type: String,
46
- value: 'horizontal',
47
- },
48
- requiredFlag: {
49
- type: Boolean,
50
- value: false,
51
- },
52
- counterVisible: {
53
- type: Boolean,
54
- value: true,
55
- },
56
- },
57
- data: {
58
- cls: '',
59
- value: '',
60
- },
61
- lifetimes: {
62
- attached() {
63
- const { className } = this.properties;
64
- this.setData({
65
- cls: classNames({
66
- 'weda-ui': true,
67
- 'weda-textarea': true,
68
- [className]: className,
69
- }),
70
- });
71
- },
72
- },
73
- observers: {
74
- defaultValue: function (defaultValue) {
75
- this.setData({ value: defaultValue });
76
- },
77
- },
78
- methods: {
79
- handleChange: function (e) {
80
- this.setData({ value: e.detail.value });
81
- this.triggerEvent('change', e.detail);
82
- },
83
- handleFocus: function (e) {
84
- this.triggerEvent('focus', e.detail);
85
- },
86
- handleBlur: function (e) {
87
- this.triggerEvent('blur', e.detail);
88
- },
89
- },
90
- });
@@ -1,7 +0,0 @@
1
- {
2
- "component": true,
3
- "styleIsolation": "shared",
4
- "usingComponents": {
5
- "formcell": "../formcell"
6
- }
7
- }
@@ -1,8 +0,0 @@
1
- <formcell className="{{cls}}" style="{{style}}" label="{{labelVisible ? label : null}}" layout="{{layout}}" multiCell="{{true}}" requiredFlag="{{requiredFlag}}">
2
- <view class="weui-cell weui-cell_active weui-cell_form}} {{disabled ? 'weui-cell_disabled' : ''}}">
3
- <view class="weui-cell__bd">
4
- <textarea class="weui-textarea" placeholder="{{placeholder}}" placeholder-class="weui-input__placeholder" bindinput="handleChange" value="{{value}}" disable="{{disabled}}" maxlength="{{maxLength}}" bindfocus="handleFocus" bindblur="handleBlur"></textarea>
5
- <view wx:if="{{counterVisible}}" class="weui-textarea-counter"><span>{{!!value ? value.length : 0}}</span>/{{maxLength}}</view>
6
- </view>
7
- </view>
8
- </formcell>
@@ -1,10 +0,0 @@
1
- @import '../../../style/weda-ui.wxss';
2
-
3
- .weda-ui .weda-textarea .weui-cell_form {
4
- padding: 16px;
5
- }
6
-
7
- .weda-ui .weda-textarea .weui-flex__item .weui-cell_form {
8
- padding: 16px;
9
- padding-left: 0;
10
- }
@@ -1,41 +0,0 @@
1
- import classNames from '../../../utils/classnames';
2
-
3
- Component({
4
- options: {
5
- virtualHost: true,
6
- },
7
- properties: {
8
- className: {
9
- type: String,
10
- value: '',
11
- },
12
- style: {
13
- type: String,
14
- value: '',
15
- },
16
- tips: {
17
- type: String,
18
- value: '表单提示',
19
- },
20
- type: {
21
- type: String,
22
- value: 'normal',
23
- },
24
- },
25
- data: {
26
- cls: '',
27
- },
28
- lifetimes: {
29
- attached() {
30
- const { className, type, tips } = this.properties;
31
- const cls = classNames('weda-ui', {
32
- 'weda-tips': true,
33
- 'weui-cells__tips': !!tips,
34
- 'weui-cells__tips_warn': !!tips && type === 'warn',
35
- [className]: className,
36
- });
37
-
38
- this.setData({ cls });
39
- },
40
- },
41
- });
@@ -1,4 +0,0 @@
1
- {
2
- "component": true,
3
- "styleIsolation": "shared"
4
- }
@@ -1 +0,0 @@
1
- <view class="{{cls}}"> {{tips}} </view>
@@ -1 +0,0 @@
1
- @import '../../../style/weda-ui.wxss';
@@ -1,158 +0,0 @@
1
- import { getCloudInstance, getTempFileURL } from '../../../utils/tcb';
2
- import SparkMD5 from '../../../utils/spark-md5';
3
-
4
- Component({
5
- options: {
6
- virtualHost: true,
7
- },
8
-
9
- properties: {
10
- maxUploadCount: {
11
- type: Number,
12
- value: 5,
13
- },
14
- title: {
15
- type: String,
16
- value: '图片上传',
17
- },
18
- tips: {
19
- type: String,
20
- value: '图片上传提示',
21
- },
22
- layout: {
23
- type: String,
24
- value: 'horizontal',
25
- },
26
- defaultValue: {
27
- type: null,
28
- },
29
- single: {
30
- type: Boolean,
31
- value: false,
32
- },
33
- maxSize: {
34
- type: Number,
35
- value: 10,
36
- },
37
- },
38
- data: {
39
- maxCount: 0,
40
- cloudFile: [],
41
- files: [],
42
- urls: [],
43
- singleFlag: false,
44
- uploadFile: async function (files) {
45
- try {
46
- // 文件上传的函数,返回一个promise
47
- const uploadPath = 'weda-uploader';
48
- const tcb = await getCloudInstance();
49
- const uploadPromise = files.tempFilePaths.map(
50
- async (tempFilePath, index) => {
51
- var spark = new SparkMD5.ArrayBuffer();
52
- spark.append(files.contents[index]);
53
- var md5Path = spark.end(false);
54
- const fileType = tempFilePath.split('.')[1];
55
- const cloudPath = `${uploadPath}/${md5Path}-${Date.now()}.${fileType}`;
56
- const uploadRes = await tcb.uploadFile({
57
- cloudPath,
58
- filePath: tempFilePath,
59
- });
60
- return { fileID: uploadRes.fileID };
61
- }
62
- );
63
- const uploadFileList = await Promise.all(uploadPromise);
64
- const cloudUrls = uploadFileList.map((file) => file.fileID);
65
- // 这里返回的东西会在uploadSuccess回调函数中获取到
66
- // https://github.com/wechat-miniprogram/weui-miniprogram/blob/a3630575910302e3b94e69fcef266d2b509de650/src/components/uploader/uploader.ts#L149
67
- // 写死的从返回值的 .urls 获取展示用的url来用。一定要将tempFilePaths透传下去,否则会重新加载然后出现闪白
68
- return { urls: files.tempFilePaths, cloudUrls };
69
- } catch (e) {
70
- wx.showToast({
71
- title: `${e}` || '上传失败',
72
- icon: 'none',
73
- duration: 2000,
74
- });
75
- }
76
- },
77
- },
78
- methods: {
79
- uploadError: function (e) {
80
- this.triggerEvent('error', e.detail);
81
- },
82
- uploadSuccess: async function (e) {
83
- const urls = e.detail.cloudUrls; // uploadFile 获取返回值
84
- // 小程序自带tempURL 不需要调用 tcb.getTempFileURL 获取
85
- this.triggerEvent('success', {
86
- value: urls,
87
- });
88
- this.setData({
89
- files: this.data.files.concat(e.detail.urls.map((url) => ({ url }))),
90
- urls: [...this.data.cloudFile, ...urls],
91
- });
92
- },
93
- onDelete: function (e) {
94
- if (this.data.urls.length == 0) {
95
- var storgeUrls = [];
96
- this.data.cloudFile.forEach((v, index) => {
97
- if (e.detail.index != index) {
98
- storgeUrls.push(v);
99
- }
100
- });
101
- this.setData({
102
- files: this.data.files.filter((v, index) => e.detail.index !== index),
103
- urls: storgeUrls,
104
- });
105
- } else {
106
- this.setData({
107
- files: this.data.files.filter((v, index) => e.detail.index !== index),
108
- urls: this.data.urls.filter((v, index) => e.detail.index !== index),
109
- });
110
- }
111
- },
112
- },
113
- observers: {
114
- defaultValue: async function (value) {
115
- //当单图片上传且默认值为空数组时,初次渲染更新value,以避免空串提交类型不匹配问题
116
- if (Array.isArray(value) && !this.data.singleFlag) {
117
- this.setData({
118
- urls: value,
119
- });
120
- this.data.singleFlag = true;
121
- }
122
- if (value) {
123
- let httpFiles = [];
124
- for (let f of value) {
125
- const hf = await getTempFileURL(f);
126
- const httpFile = { url: hf };
127
- httpFiles.push(httpFile);
128
- }
129
- this.setData({
130
- files: httpFiles,
131
- cloudFile:
132
- JSON.stringify(value) != JSON.stringify(this.data.cloudFile)
133
- ? value
134
- : [],
135
- });
136
- } else {
137
- this.setData({
138
- files: [],
139
- cloudFile: [],
140
- });
141
- }
142
- },
143
-
144
- 'maxUploadCount, single': function (maxUploadCount, single) {
145
- const maxCount = single ? 1 : maxUploadCount;
146
- this.setData({
147
- maxCount,
148
- });
149
- },
150
- urls: function (urls) {
151
- let value = urls;
152
- if (this.properties.single) {
153
- value = urls[0] ?? '';
154
- }
155
- this.triggerEvent('change', { value });
156
- },
157
- },
158
- });
@@ -1,10 +0,0 @@
1
- {
2
- "component": true,
3
- "styleIsolation": "shared",
4
- "usingComponents": {
5
- "mp-uploader": "./weui-uploader",
6
- "mp-cells": "weui-miniprogram/cells/cells",
7
- "mp-cell": "weui-miniprogram/cell/cell",
8
- "formcell": "../formcell"
9
- }
10
- }
@@ -1,14 +0,0 @@
1
- <view class="weda-ui weui-cells weui-cells_form {{className}}" id="{{id}}" style="{{style}}">
2
- <mp-uploader max-size="{{maxSize * 1024 * 1024}}" files="{{files}}" title="{{title}}" showDelete="{{true}}" ext-class="{{layout}}" bindfail="uploadError" bindsuccess="uploadSuccess" layout="{{layout}}" select="{{selectFile}}" upload="{{uploadFile}}" maxCount="{{maxCount}}" binddelete="onDelete"> </mp-uploader>
3
- </view>
4
-
5
- <!-- uploader delete 实际代码接受 showDelete
6
- https://developers.weixin.qq.com/community/develop/doc/000a4e7b9cc158c110aa3961056400
7
- -->
8
-
9
- <!-- bind开头的是事件handler,wxml模版中不能带 `{{}}`
10
- ```
11
- <mp-uploader files="{{files}}" showDelete="{{true}}" ext-class="{{layout}}" bindfail="uploadError" bindsuccess="uploadSuccess" select="{{selectFile}}" upload="{{uploadFile}}" maxCount="{{maxUploadCount}}" title="{{title}}" binddelete="onDelete"></mp-uploader>
12
- ```
13
- upload 是函数带{{}}, bindtelete直接传函数名字符串
14
- -->
@@ -1,36 +0,0 @@
1
- @import '../../../style/weda-ui.wxss';
2
- .weui-uploader.horizontal {
3
- display: flex;
4
- }
5
-
6
- .weui-uploader.horizontal .weui-uploader__hd {
7
- display: inline-block;
8
- align-self: center;
9
- }
10
-
11
- .weda-uploader-pc.horizontal {
12
- display: flex;
13
- justify-content: space-between;
14
- }
15
-
16
- .weui-uploader.horizontal .weda-formcells__label {
17
- width: 130px;
18
- }
19
-
20
- .weui-uploader__label {
21
- display: flex;
22
- flex: 1;
23
- }
24
-
25
- .weui-uploader__title {
26
- flex: unset;
27
- }
28
- .weda-ui .weui-uploader.horizontal .weui-uploader__bd {
29
- padding: 16px 0;
30
- }
31
- .weda-ui .weui-uploader.vertical .weui-uploader__bd {
32
- padding: 16px;
33
- }
34
- .weui-uploader__hd.vertical {
35
- padding-bottom: 0;
36
- }