@tarojs/taro-h5 3.6.0-beta.2 → 3.6.0-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 (437) hide show
  1. package/dist/api/ad/index.d.ts +3 -2
  2. package/dist/api/ad/index.js +7 -3
  3. package/dist/api/ad/index.js.map +1 -0
  4. package/dist/api/ai/facial.d.ts +4 -3
  5. package/dist/api/ai/facial.js +8 -4
  6. package/dist/api/ai/facial.js.map +1 -0
  7. package/dist/api/ai/index.d.ts +2 -2
  8. package/dist/api/ai/index.js +3 -2
  9. package/dist/api/ai/index.js.map +1 -0
  10. package/dist/api/ai/visual.d.ts +3 -2
  11. package/dist/api/ai/visual.js +7 -3
  12. package/dist/api/ai/visual.js.map +1 -0
  13. package/dist/api/alipay/index.d.ts +2 -1
  14. package/dist/api/alipay/index.js +6 -2
  15. package/dist/api/alipay/index.js.map +1 -0
  16. package/dist/api/base/crypto.d.ts +2 -1
  17. package/dist/api/base/crypto.js +6 -2
  18. package/dist/api/base/crypto.js.map +1 -0
  19. package/dist/api/base/debug.d.ts +4 -3
  20. package/dist/api/base/debug.js +8 -4
  21. package/dist/api/base/debug.js.map +1 -0
  22. package/dist/api/base/index.d.ts +16 -10
  23. package/dist/api/base/index.js +20 -12
  24. package/dist/api/base/index.js.map +1 -0
  25. package/dist/api/base/performance.d.ts +3 -2
  26. package/dist/api/base/performance.js +7 -3
  27. package/dist/api/base/performance.js.map +1 -0
  28. package/dist/api/base/system.d.ts +11 -10
  29. package/dist/api/base/system.js +17 -21
  30. package/dist/api/base/system.js.map +1 -0
  31. package/dist/api/base/update.d.ts +3 -2
  32. package/dist/api/base/update.js +7 -3
  33. package/dist/api/base/update.js.map +1 -0
  34. package/dist/api/base/weapp/app-event.d.ts +17 -16
  35. package/dist/api/base/weapp/app-event.js +22 -18
  36. package/dist/api/base/weapp/app-event.js.map +1 -0
  37. package/dist/api/base/weapp/life-cycle.d.ts +3 -2
  38. package/dist/api/base/weapp/life-cycle.js +6 -2
  39. package/dist/api/base/weapp/life-cycle.js.map +1 -0
  40. package/dist/api/canvas/CanvasContext.d.ts +7 -2
  41. package/dist/api/canvas/CanvasContext.js +6 -10
  42. package/dist/api/canvas/CanvasContext.js.map +1 -0
  43. package/dist/api/canvas/canvasGetImageData.d.ts +2 -1
  44. package/dist/api/canvas/canvasGetImageData.js +7 -3
  45. package/dist/api/canvas/canvasGetImageData.js.map +1 -0
  46. package/dist/api/canvas/canvasPutImageData.d.ts +2 -1
  47. package/dist/api/canvas/canvasPutImageData.js +7 -3
  48. package/dist/api/canvas/canvasPutImageData.js.map +1 -0
  49. package/dist/api/canvas/canvasToTempFilePath.d.ts +2 -1
  50. package/dist/api/canvas/canvasToTempFilePath.js +7 -3
  51. package/dist/api/canvas/canvasToTempFilePath.js.map +1 -0
  52. package/dist/api/canvas/createCanvasContext.d.ts +2 -1
  53. package/dist/api/canvas/createCanvasContext.js +7 -3
  54. package/dist/api/canvas/createCanvasContext.js.map +1 -0
  55. package/dist/api/canvas/index.d.ts +6 -5
  56. package/dist/api/canvas/index.js +10 -10
  57. package/dist/api/canvas/index.js.map +1 -0
  58. package/dist/api/cloud/index.d.ts +2 -1
  59. package/dist/api/cloud/index.js +6 -2
  60. package/dist/api/cloud/index.js.map +1 -0
  61. package/dist/api/data-analysis/index.d.ts +5 -4
  62. package/dist/api/data-analysis/index.js +9 -5
  63. package/dist/api/data-analysis/index.js.map +1 -0
  64. package/dist/api/device/accelerometer.d.ts +5 -4
  65. package/dist/api/device/accelerometer.js +11 -6
  66. package/dist/api/device/accelerometer.js.map +1 -0
  67. package/dist/api/device/accessibility.d.ts +2 -1
  68. package/dist/api/device/accessibility.js +6 -2
  69. package/dist/api/device/accessibility.js.map +1 -0
  70. package/dist/api/device/battery.d.ts +3 -2
  71. package/dist/api/device/battery.js +9 -13
  72. package/dist/api/device/battery.js.map +1 -0
  73. package/dist/api/device/bluetooth-ble.d.ts +17 -16
  74. package/dist/api/device/bluetooth-ble.js +21 -17
  75. package/dist/api/device/bluetooth-ble.js.map +1 -0
  76. package/dist/api/device/bluetooth-peripheral.d.ts +4 -3
  77. package/dist/api/device/bluetooth-peripheral.js +8 -4
  78. package/dist/api/device/bluetooth-peripheral.js.map +1 -0
  79. package/dist/api/device/bluetooth.d.ts +14 -13
  80. package/dist/api/device/bluetooth.js +18 -14
  81. package/dist/api/device/bluetooth.js.map +1 -0
  82. package/dist/api/device/calendar.d.ts +3 -2
  83. package/dist/api/device/calendar.js +7 -3
  84. package/dist/api/device/calendar.js.map +1 -0
  85. package/dist/api/device/clipboard.d.ts +3 -2
  86. package/dist/api/device/clipboard.js +10 -14
  87. package/dist/api/device/clipboard.js.map +1 -0
  88. package/dist/api/device/compass.d.ts +5 -4
  89. package/dist/api/device/compass.js +12 -7
  90. package/dist/api/device/compass.js.map +1 -0
  91. package/dist/api/device/contact.d.ts +3 -2
  92. package/dist/api/device/contact.js +7 -3
  93. package/dist/api/device/contact.js.map +1 -0
  94. package/dist/api/device/crypto.d.ts +2 -1
  95. package/dist/api/device/crypto.js +6 -2
  96. package/dist/api/device/crypto.js.map +1 -0
  97. package/dist/api/device/gyroscope.d.ts +5 -4
  98. package/dist/api/device/gyroscope.js +9 -5
  99. package/dist/api/device/gyroscope.js.map +1 -0
  100. package/dist/api/device/iBeacon.d.ts +8 -7
  101. package/dist/api/device/iBeacon.js +12 -8
  102. package/dist/api/device/iBeacon.js.map +1 -0
  103. package/dist/api/device/index.d.ts +23 -23
  104. package/dist/api/device/index.js +24 -23
  105. package/dist/api/device/index.js.map +1 -0
  106. package/dist/api/device/keyboard.d.ts +5 -4
  107. package/dist/api/device/keyboard.js +9 -5
  108. package/dist/api/device/keyboard.js.map +1 -0
  109. package/dist/api/device/memory.d.ts +3 -2
  110. package/dist/api/device/memory.js +7 -3
  111. package/dist/api/device/memory.js.map +1 -0
  112. package/dist/api/device/motion.d.ts +5 -4
  113. package/dist/api/device/motion.js +11 -6
  114. package/dist/api/device/motion.js.map +1 -0
  115. package/dist/api/device/network.d.ts +7 -6
  116. package/dist/api/device/network.js +13 -17
  117. package/dist/api/device/network.js.map +1 -0
  118. package/dist/api/device/nfc.d.ts +8 -7
  119. package/dist/api/device/nfc.js +12 -8
  120. package/dist/api/device/nfc.js.map +1 -0
  121. package/dist/api/device/phone.d.ts +2 -1
  122. package/dist/api/device/phone.js +7 -3
  123. package/dist/api/device/phone.js.map +1 -0
  124. package/dist/api/device/scan.d.ts +2 -1
  125. package/dist/api/device/scan.js +6 -2
  126. package/dist/api/device/scan.js.map +1 -0
  127. package/dist/api/device/screen.d.ts +7 -6
  128. package/dist/api/device/screen.js +11 -7
  129. package/dist/api/device/screen.js.map +1 -0
  130. package/dist/api/device/vibrate.d.ts +3 -2
  131. package/dist/api/device/vibrate.js +7 -3
  132. package/dist/api/device/vibrate.js.map +1 -0
  133. package/dist/api/device/wifi.d.ts +12 -11
  134. package/dist/api/device/wifi.js +16 -12
  135. package/dist/api/device/wifi.js.map +1 -0
  136. package/dist/api/ext/index.d.ts +3 -2
  137. package/dist/api/ext/index.js +7 -3
  138. package/dist/api/ext/index.js.map +1 -0
  139. package/dist/api/files/index.d.ts +9 -8
  140. package/dist/api/files/index.js +13 -9
  141. package/dist/api/files/index.js.map +1 -0
  142. package/dist/api/framework/index.d.ts +3 -2
  143. package/dist/api/framework/index.js +7 -3
  144. package/dist/api/framework/index.js.map +1 -0
  145. package/dist/api/index.d.ts +24 -24
  146. package/dist/api/index.js +117 -24
  147. package/dist/api/index.js.map +1 -0
  148. package/dist/api/location/chooseLocation.d.ts +2 -2
  149. package/dist/api/location/chooseLocation.js +8 -14
  150. package/dist/api/location/chooseLocation.js.map +1 -0
  151. package/dist/api/location/getLocation.d.ts +2 -1
  152. package/dist/api/location/getLocation.js +7 -3
  153. package/dist/api/location/getLocation.js.map +1 -0
  154. package/dist/api/location/index.d.ts +13 -12
  155. package/dist/api/location/index.js +17 -13
  156. package/dist/api/location/index.js.map +1 -0
  157. package/dist/api/location/style.scss.js +8 -0
  158. package/dist/api/location/style.scss.js.map +1 -0
  159. package/dist/api/media/audio/InnerAudioContext.d.ts +3 -2
  160. package/dist/api/media/audio/InnerAudioContext.js +7 -3
  161. package/dist/api/media/audio/InnerAudioContext.js.map +1 -0
  162. package/dist/api/media/audio/index.d.ts +10 -9
  163. package/dist/api/media/audio/index.js +15 -11
  164. package/dist/api/media/audio/index.js.map +1 -0
  165. package/dist/api/media/background-audio/BackgroundAudioManager.d.ts +3 -2
  166. package/dist/api/media/background-audio/BackgroundAudioManager.js +7 -3
  167. package/dist/api/media/background-audio/BackgroundAudioManager.js.map +1 -0
  168. package/dist/api/media/background-audio/index.d.ts +11 -10
  169. package/dist/api/media/background-audio/index.js +15 -11
  170. package/dist/api/media/background-audio/index.js.map +1 -0
  171. package/dist/api/media/camera.d.ts +2 -1
  172. package/dist/api/media/camera.js +6 -2
  173. package/dist/api/media/camera.js.map +1 -0
  174. package/dist/api/media/image/chooseImage.d.ts +2 -1
  175. package/dist/api/media/image/chooseImage.js +7 -3
  176. package/dist/api/media/image/chooseImage.js.map +1 -0
  177. package/dist/api/media/image/getImageInfo.d.ts +2 -1
  178. package/dist/api/media/image/getImageInfo.js +7 -3
  179. package/dist/api/media/image/getImageInfo.js.map +1 -0
  180. package/dist/api/media/image/index.d.ts +8 -7
  181. package/dist/api/media/image/index.js +12 -8
  182. package/dist/api/media/image/index.js.map +1 -0
  183. package/dist/api/media/image/previewImage.d.ts +2 -1
  184. package/dist/api/media/image/previewImage.js +15 -12
  185. package/dist/api/media/image/previewImage.js.map +1 -0
  186. package/dist/api/media/index.d.ts +12 -12
  187. package/dist/api/media/index.js +13 -12
  188. package/dist/api/media/index.js.map +1 -0
  189. package/dist/api/media/live.d.ts +3 -2
  190. package/dist/api/media/live.js +7 -3
  191. package/dist/api/media/live.js.map +1 -0
  192. package/dist/api/media/map.d.ts +2 -1
  193. package/dist/api/media/map.js +6 -2
  194. package/dist/api/media/map.js.map +1 -0
  195. package/dist/api/media/media-recorder.d.ts +2 -1
  196. package/dist/api/media/media-recorder.js +6 -2
  197. package/dist/api/media/media-recorder.js.map +1 -0
  198. package/dist/api/media/recorder.d.ts +4 -3
  199. package/dist/api/media/recorder.js +8 -4
  200. package/dist/api/media/recorder.js.map +1 -0
  201. package/dist/api/media/video/index.d.ts +8 -7
  202. package/dist/api/media/video/index.js +13 -9
  203. package/dist/api/media/video/index.js.map +1 -0
  204. package/dist/api/media/video-decoder.d.ts +2 -1
  205. package/dist/api/media/video-decoder.js +6 -2
  206. package/dist/api/media/video-decoder.js.map +1 -0
  207. package/dist/api/media/video-processing.d.ts +2 -1
  208. package/dist/api/media/video-processing.js +6 -2
  209. package/dist/api/media/video-processing.js.map +1 -0
  210. package/dist/api/media/voip.d.ts +15 -14
  211. package/dist/api/media/voip.js +19 -15
  212. package/dist/api/media/voip.js.map +1 -0
  213. package/dist/api/navigate/index.d.ts +6 -5
  214. package/dist/api/navigate/index.js +10 -6
  215. package/dist/api/navigate/index.js.map +1 -0
  216. package/dist/api/network/download.d.ts +2 -1
  217. package/dist/api/network/download.js +14 -5
  218. package/dist/api/network/download.js.map +1 -0
  219. package/dist/api/network/index.d.ts +7 -7
  220. package/dist/api/network/index.js +8 -7
  221. package/dist/api/network/index.js.map +1 -0
  222. package/dist/api/network/mdns.d.ts +11 -10
  223. package/dist/api/network/mdns.js +15 -11
  224. package/dist/api/network/mdns.js.map +1 -0
  225. package/dist/api/network/request/index.d.ts +3 -3
  226. package/dist/api/network/request/index.js +8 -4
  227. package/dist/api/network/request/index.js.map +1 -0
  228. package/dist/api/network/tcp.d.ts +2 -1
  229. package/dist/api/network/tcp.js +6 -2
  230. package/dist/api/network/tcp.js.map +1 -0
  231. package/dist/api/network/udp.d.ts +2 -1
  232. package/dist/api/network/udp.js +6 -2
  233. package/dist/api/network/udp.js.map +1 -0
  234. package/dist/api/network/upload.d.ts +2 -1
  235. package/dist/api/network/upload.js +14 -5
  236. package/dist/api/network/upload.js.map +1 -0
  237. package/dist/api/network/utils.d.ts +5 -4
  238. package/dist/api/network/utils.js +7 -4
  239. package/dist/api/network/utils.js.map +1 -0
  240. package/dist/api/network/websocket/index.d.ts +8 -7
  241. package/dist/api/network/websocket/index.js +14 -10
  242. package/dist/api/network/websocket/index.js.map +1 -0
  243. package/dist/api/network/websocket/socketTask.d.ts +2 -1
  244. package/dist/api/network/websocket/socketTask.js +5 -1
  245. package/dist/api/network/websocket/socketTask.js.map +1 -0
  246. package/dist/api/open-api/account.d.ts +2 -1
  247. package/dist/api/open-api/account.js +6 -2
  248. package/dist/api/open-api/account.js.map +1 -0
  249. package/dist/api/open-api/address.d.ts +2 -1
  250. package/dist/api/open-api/address.js +6 -2
  251. package/dist/api/open-api/address.js.map +1 -0
  252. package/dist/api/open-api/authorize.d.ts +3 -2
  253. package/dist/api/open-api/authorize.js +7 -3
  254. package/dist/api/open-api/authorize.js.map +1 -0
  255. package/dist/api/open-api/card.d.ts +3 -2
  256. package/dist/api/open-api/card.js +7 -3
  257. package/dist/api/open-api/card.js.map +1 -0
  258. package/dist/api/open-api/channels-live.d.ts +7 -6
  259. package/dist/api/open-api/channels-live.js +11 -7
  260. package/dist/api/open-api/channels-live.js.map +1 -0
  261. package/dist/api/open-api/customer-service.d.ts +2 -1
  262. package/dist/api/open-api/customer-service.js +6 -2
  263. package/dist/api/open-api/customer-service.js.map +1 -0
  264. package/dist/api/open-api/facial.d.ts +5 -4
  265. package/dist/api/open-api/facial.js +9 -5
  266. package/dist/api/open-api/facial.js.map +1 -0
  267. package/dist/api/open-api/favorites.d.ts +3 -2
  268. package/dist/api/open-api/favorites.js +7 -3
  269. package/dist/api/open-api/favorites.js.map +1 -0
  270. package/dist/api/open-api/group.d.ts +2 -1
  271. package/dist/api/open-api/group.js +6 -2
  272. package/dist/api/open-api/group.js.map +1 -0
  273. package/dist/api/open-api/index.d.ts +18 -18
  274. package/dist/api/open-api/index.js +19 -18
  275. package/dist/api/open-api/index.js.map +1 -0
  276. package/dist/api/open-api/invoice.d.ts +3 -2
  277. package/dist/api/open-api/invoice.js +7 -3
  278. package/dist/api/open-api/invoice.js.map +1 -0
  279. package/dist/api/open-api/license-plate.d.ts +2 -1
  280. package/dist/api/open-api/license-plate.js +6 -2
  281. package/dist/api/open-api/license-plate.js.map +1 -0
  282. package/dist/api/open-api/login.d.ts +4 -3
  283. package/dist/api/open-api/login.js +8 -4
  284. package/dist/api/open-api/login.js.map +1 -0
  285. package/dist/api/open-api/red-package.d.ts +2 -1
  286. package/dist/api/open-api/red-package.js +6 -2
  287. package/dist/api/open-api/red-package.js.map +1 -0
  288. package/dist/api/open-api/settings.d.ts +3 -2
  289. package/dist/api/open-api/settings.js +7 -3
  290. package/dist/api/open-api/settings.js.map +1 -0
  291. package/dist/api/open-api/soter.d.ts +4 -3
  292. package/dist/api/open-api/soter.js +8 -4
  293. package/dist/api/open-api/soter.js.map +1 -0
  294. package/dist/api/open-api/subscribe-message.d.ts +2 -1
  295. package/dist/api/open-api/subscribe-message.js +6 -2
  296. package/dist/api/open-api/subscribe-message.js.map +1 -0
  297. package/dist/api/open-api/user-info.d.ts +3 -2
  298. package/dist/api/open-api/user-info.js +7 -3
  299. package/dist/api/open-api/user-info.js.map +1 -0
  300. package/dist/api/open-api/werun.d.ts +3 -2
  301. package/dist/api/open-api/werun.js +7 -3
  302. package/dist/api/open-api/werun.js.map +1 -0
  303. package/dist/api/payment/index.d.ts +3 -2
  304. package/dist/api/payment/index.js +7 -3
  305. package/dist/api/payment/index.js.map +1 -0
  306. package/dist/api/route/index.js +3 -1
  307. package/dist/api/route/index.js.map +1 -0
  308. package/dist/api/share/index.d.ts +11 -10
  309. package/dist/api/share/index.js +15 -11
  310. package/dist/api/share/index.js.map +1 -0
  311. package/dist/api/storage/background-fetch.d.ts +5 -4
  312. package/dist/api/storage/background-fetch.js +9 -5
  313. package/dist/api/storage/background-fetch.js.map +1 -0
  314. package/dist/api/storage/index.d.ts +14 -13
  315. package/dist/api/storage/index.js +19 -15
  316. package/dist/api/storage/index.js.map +1 -0
  317. package/dist/api/swan/index.d.ts +22 -21
  318. package/dist/api/swan/index.js +26 -22
  319. package/dist/api/swan/index.js.map +1 -0
  320. package/dist/api/taro.d.ts +1 -2
  321. package/dist/api/taro.js +17 -12
  322. package/dist/api/taro.js.map +1 -0
  323. package/dist/api/ui/animation/index.d.ts +2 -1
  324. package/dist/api/ui/animation/index.js +4 -1
  325. package/dist/api/ui/animation/index.js.map +1 -0
  326. package/dist/api/ui/background.d.ts +3 -2
  327. package/dist/api/ui/background.js +7 -3
  328. package/dist/api/ui/background.js.map +1 -0
  329. package/dist/api/ui/custom-component.d.ts +2 -1
  330. package/dist/api/ui/custom-component.js +5 -1
  331. package/dist/api/ui/custom-component.js.map +1 -0
  332. package/dist/api/ui/fonts.d.ts +2 -1
  333. package/dist/api/ui/fonts.js +7 -11
  334. package/dist/api/ui/fonts.js.map +1 -0
  335. package/dist/api/ui/index.d.ts +12 -12
  336. package/dist/api/ui/index.js +13 -12
  337. package/dist/api/ui/index.js.map +1 -0
  338. package/dist/api/ui/interaction/actionSheet.d.ts +2 -1
  339. package/dist/api/ui/interaction/actionSheet.js +6 -2
  340. package/dist/api/ui/interaction/actionSheet.js.map +1 -0
  341. package/dist/api/ui/interaction/index.js +9 -14
  342. package/dist/api/ui/interaction/index.js.map +1 -0
  343. package/dist/api/ui/interaction/modal.d.ts +2 -1
  344. package/dist/api/ui/interaction/modal.js +6 -2
  345. package/dist/api/ui/interaction/modal.js.map +1 -0
  346. package/dist/api/ui/interaction/toast.d.ts +2 -1
  347. package/dist/api/ui/interaction/toast.js +6 -2
  348. package/dist/api/ui/interaction/toast.js.map +1 -0
  349. package/dist/api/ui/menu.d.ts +2 -1
  350. package/dist/api/ui/menu.js +6 -2
  351. package/dist/api/ui/menu.js.map +1 -0
  352. package/dist/api/ui/navigation-bar/index.d.ts +6 -5
  353. package/dist/api/ui/navigation-bar/index.js +11 -7
  354. package/dist/api/ui/navigation-bar/index.js.map +1 -0
  355. package/dist/api/ui/pull-down-refresh.d.ts +3 -2
  356. package/dist/api/ui/pull-down-refresh.js +7 -3
  357. package/dist/api/ui/pull-down-refresh.js.map +1 -0
  358. package/dist/api/ui/scroll/index.d.ts +2 -1
  359. package/dist/api/ui/scroll/index.js +8 -3
  360. package/dist/api/ui/scroll/index.js.map +1 -0
  361. package/dist/api/ui/sticky.d.ts +2 -1
  362. package/dist/api/ui/sticky.js +6 -2
  363. package/dist/api/ui/sticky.js.map +1 -0
  364. package/dist/api/ui/tab-bar.d.ts +12 -10
  365. package/dist/api/ui/tab-bar.js +16 -11
  366. package/dist/api/ui/tab-bar.js.map +1 -0
  367. package/dist/api/ui/window.d.ts +4 -3
  368. package/dist/api/ui/window.js +9 -5
  369. package/dist/api/ui/window.js.map +1 -0
  370. package/dist/api/worker/index.d.ts +2 -1
  371. package/dist/api/worker/index.js +6 -2
  372. package/dist/api/worker/index.js.map +1 -0
  373. package/dist/api/wxml/IntersectionObserver.d.ts +3 -3
  374. package/dist/api/wxml/IntersectionObserver.js +6 -2
  375. package/dist/api/wxml/IntersectionObserver.js.map +1 -0
  376. package/dist/api/wxml/MediaQueryObserver.d.ts +4 -1
  377. package/dist/api/wxml/MediaQueryObserver.js +6 -2
  378. package/dist/api/wxml/MediaQueryObserver.js.map +1 -0
  379. package/dist/api/wxml/index.d.ts +4 -3
  380. package/dist/api/wxml/index.js +10 -6
  381. package/dist/api/wxml/index.js.map +1 -0
  382. package/dist/api/wxml/nodesRef.d.ts +3 -2
  383. package/dist/api/wxml/nodesRef.js +4 -1
  384. package/dist/api/wxml/nodesRef.js.map +1 -0
  385. package/dist/api/wxml/selectorQuery.d.ts +4 -4
  386. package/dist/api/wxml/selectorQuery.js +8 -4
  387. package/dist/api/wxml/selectorQuery.js.map +1 -0
  388. package/dist/index.cjs.d.ts +8 -4
  389. package/dist/index.cjs.js +14280 -78
  390. package/dist/index.cjs.js.map +1 -1
  391. package/dist/index.d.ts +4 -4
  392. package/dist/index.esm.d.ts +8 -4
  393. package/dist/index.esm.js +14279 -78
  394. package/dist/index.esm.js.map +1 -1
  395. package/dist/index.js +113 -4
  396. package/dist/index.js.map +1 -0
  397. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/app-data/index.js +89 -0
  398. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/app-data/index.js.map +1 -0
  399. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/client/index.js +3371 -0
  400. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/client/index.js.map +1 -0
  401. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/client/shadow-css.js +388 -0
  402. package/dist/node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/client/shadow-css.js.map +1 -0
  403. package/dist/node_modules/.pnpm/registry.npmjs.org_style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.js +29 -0
  404. package/dist/node_modules/.pnpm/registry.npmjs.org_style-inject@0.3.0/node_modules/style-inject/dist/style-inject.es.js.map +1 -0
  405. package/dist/node_modules/.pnpm/registry.npmjs.org_tslib@1.14.1/node_modules/tslib/tslib.es6.js +221 -0
  406. package/dist/node_modules/.pnpm/registry.npmjs.org_tslib@1.14.1/node_modules/tslib/tslib.es6.js.map +1 -0
  407. package/dist/packages/taro-components/dist/components/index2.js +77 -0
  408. package/dist/packages/taro-components/dist/components/index2.js.map +1 -0
  409. package/dist/packages/taro-components/dist/components/index3.js +35 -0
  410. package/dist/packages/taro-components/dist/components/index3.js.map +1 -0
  411. package/dist/packages/taro-components/dist/components/taro-swiper-core.js +10171 -0
  412. package/dist/packages/taro-components/dist/components/taro-swiper-core.js.map +1 -0
  413. package/dist/packages/taro-components/dist/components/taro-swiper-item-core.js +69 -0
  414. package/dist/packages/taro-components/dist/components/taro-swiper-item-core.js.map +1 -0
  415. package/dist/utils/animation.d.ts +3 -2
  416. package/dist/utils/animation.js +5 -2
  417. package/dist/utils/animation.js.map +1 -0
  418. package/dist/utils/handler.d.ts +7 -7
  419. package/dist/utils/handler.js +6 -2
  420. package/dist/utils/handler.js.map +1 -0
  421. package/dist/utils/index.d.ts +16 -15
  422. package/dist/utils/index.js +23 -19
  423. package/dist/utils/index.js.map +1 -0
  424. package/dist/utils/lodash.d.ts +3 -2
  425. package/dist/utils/lodash.js +5 -2
  426. package/dist/utils/lodash.js.map +1 -0
  427. package/dist/utils/valid.d.ts +2 -1
  428. package/dist/utils/valid.js +4 -1
  429. package/dist/utils/valid.js.map +1 -0
  430. package/package.json +10 -10
  431. package/types/define.d.ts +2 -0
  432. package/dist/api/location/style.css +0 -79
  433. package/dist/api/media/EditorContext.d.ts +0 -16
  434. package/dist/api/media/EditorContext.js +0 -19
  435. package/dist/taroApis.d.ts +0 -754
  436. package/dist/taroApis.js +0 -2
  437. package/dist/taroApis.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"taro-swiper-core.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,69 @@
1
+ import { proxyCustomElement, H, h, Host } from '../../../../node_modules/.pnpm/registry.npmjs.org_@stencil_core@2.22.2/node_modules/@stencil/core/internal/client/index.js';
2
+
3
+ function isEqualTag(a, b) {
4
+ return typeof a.tagName === 'undefined' ? a.nodeType === b.nodeType : a.tagName === b.tagName;
5
+ }
6
+ function parseChildNodes(items, targets) {
7
+ const list = Array.from(targets.values());
8
+ for (let i = 0, j = 0; i < list.length; i++, j++) {
9
+ const target = list[i];
10
+ let item = items.item(j);
11
+ while (item && !isEqualTag(item, target)) {
12
+ item.remove();
13
+ j++;
14
+ item = items.item(j);
15
+ }
16
+ if (item && !item.isEqualNode(target)) {
17
+ parseChildNodes(item.childNodes, target.childNodes);
18
+ }
19
+ while (i === list.length - 1 && j < items.length) {
20
+ j++;
21
+ item = items.item(j);
22
+ item === null || item === void 0 ? void 0 : item.remove();
23
+ }
24
+ }
25
+ }
26
+ const SwiperItem = /*@__PURE__*/ proxyCustomElement(class extends H {
27
+ constructor() {
28
+ super();
29
+ this.__registerHost();
30
+ this.itemId = undefined;
31
+ }
32
+ componentDidRender() {
33
+ var _a, _b, _c;
34
+ const el = this.el;
35
+ if (el.classList.contains('swiper-slide-duplicate')) {
36
+ const list = Array
37
+ .from(((_b = (_a = el.parentElement) === null || _a === void 0 ? void 0 : _a.childNodes) === null || _b === void 0 ? void 0 : _b.values()) || [])
38
+ .filter((e) => e.tagName === 'TARO-SWIPER-ITEM-CORE');
39
+ if (list.length > 0) {
40
+ parseChildNodes(el.childNodes, (_c = list[list.indexOf(el) === 0 ? list.length - 2 : 1]) === null || _c === void 0 ? void 0 : _c.childNodes);
41
+ }
42
+ }
43
+ }
44
+ render() {
45
+ return (h(Host, { class: 'swiper-slide', "item-id": this.itemId }));
46
+ }
47
+ get el() { return this; }
48
+ }, [0, "taro-swiper-item-core", {
49
+ "itemId": [1, "item-id"]
50
+ }]);
51
+ function defineCustomElement$1() {
52
+ if (typeof customElements === "undefined") {
53
+ return;
54
+ }
55
+ const components = ["taro-swiper-item-core"];
56
+ components.forEach(tagName => { switch (tagName) {
57
+ case "taro-swiper-item-core":
58
+ if (!customElements.get(tagName)) {
59
+ customElements.define(tagName, SwiperItem);
60
+ }
61
+ break;
62
+ } });
63
+ }
64
+
65
+ const TaroSwiperItemCore = SwiperItem;
66
+ const defineCustomElement = defineCustomElement$1;
67
+
68
+ export { TaroSwiperItemCore, defineCustomElement };
69
+ //# sourceMappingURL=taro-swiper-item-core.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"taro-swiper-item-core.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -2,5 +2,6 @@
2
2
  * ease-in-out的函数
3
3
  * @param t 0-1的数字
4
4
  */
5
- export declare const easeInOut: (t: number) => number;
6
- export declare const getTimingFunc: (easeFunc: any, frameCnt: any) => (x: any) => any;
5
+ declare const easeInOut: (t: number) => number;
6
+ declare const getTimingFunc: (easeFunc: any, frameCnt: any) => (x: any) => any;
7
+ export { easeInOut, getTimingFunc };
@@ -2,8 +2,8 @@
2
2
  * ease-in-out的函数
3
3
  * @param t 0-1的数字
4
4
  */
5
- export const easeInOut = (t) => (t < 0.5 ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1);
6
- export const getTimingFunc = (easeFunc, frameCnt) => {
5
+ const easeInOut = (t) => (t < 0.5 ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1);
6
+ const getTimingFunc = (easeFunc, frameCnt) => {
7
7
  return x => {
8
8
  if (frameCnt <= 1) {
9
9
  return easeFunc(1);
@@ -12,3 +12,6 @@ export const getTimingFunc = (easeFunc, frameCnt) => {
12
12
  return easeFunc(t);
13
13
  };
14
14
  };
15
+
16
+ export { easeInOut, getTimingFunc };
17
+ //# sourceMappingURL=animation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"animation.js","sources":["../../src/utils/animation.ts"],"sourcesContent":["/**\n * ease-in-out的函数\n * @param t 0-1的数字\n */\nexport const easeInOut = (t: number) => (t < 0.5 ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1)\n\nexport const getTimingFunc = (easeFunc, frameCnt) => {\n return x => {\n if (frameCnt <= 1) {\n return easeFunc(1)\n }\n const t = x / (frameCnt - 1)\n return easeFunc(t)\n }\n}\n"],"names":[],"mappings":"AAAA;;;AAGG;MACU,SAAS,GAAG,CAAC,CAAS,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,EAAC;MAE9F,aAAa,GAAG,CAAC,QAAQ,EAAE,QAAQ,KAAI;IAClD,OAAO,CAAC,IAAG;QACT,IAAI,QAAQ,IAAI,CAAC,EAAE;AACjB,YAAA,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAA;AACnB,SAAA;QACD,MAAM,CAAC,GAAG,CAAC,IAAI,QAAQ,GAAG,CAAC,CAAC,CAAA;AAC5B,QAAA,OAAO,QAAQ,CAAC,CAAC,CAAC,CAAA;AACpB,KAAC,CAAA;AACH;;;;"}
@@ -1,4 +1,4 @@
1
- declare type TCallback<T = Partial<TaroGeneral.CallbackResult>> = (res: T) => Promise<void> | void;
1
+ type TCallback<T = Partial<TaroGeneral.CallbackResult>> = (res: T) => Promise<void> | void;
2
2
  interface IMethodParam<T = Partial<TaroGeneral.CallbackResult>> {
3
3
  name: string;
4
4
  success?: TCallback<T & TaroGeneral.CallbackResult>;
@@ -9,7 +9,7 @@ interface IMockPromise {
9
9
  resolve?: typeof Promise.resolve | TFunc;
10
10
  reject?: typeof Promise.reject | TFunc;
11
11
  }
12
- export declare class MethodHandler<T = Partial<TaroGeneral.CallbackResult>> {
12
+ declare class MethodHandler<T = Partial<TaroGeneral.CallbackResult>> {
13
13
  methodName: string;
14
14
  protected __success?: TCallback<T>;
15
15
  protected __fail?: TCallback;
@@ -19,15 +19,15 @@ export declare class MethodHandler<T = Partial<TaroGeneral.CallbackResult>> {
19
19
  success<U = Record<string, unknown>>(res?: Partial<T> & Partial<TaroGeneral.CallbackResult>, promise?: IMockPromise): Promise<T & U & TaroGeneral.CallbackResult>;
20
20
  fail<U = Record<string, unknown>>(res?: Partial<T> & Partial<TaroGeneral.CallbackResult>, promise?: IMockPromise): Promise<T & U & TaroGeneral.CallbackResult>;
21
21
  }
22
- declare type TCallbackManagerParam = (...arr: unknown[]) => void;
22
+ type TCallbackManagerParam = (...arr: unknown[]) => void;
23
23
  interface ICallbackManagerOption {
24
24
  callback?: TCallbackManagerParam;
25
25
  ctx?: any;
26
26
  [key: string]: unknown;
27
27
  }
28
- declare type TCallbackManagerListItem = (TCallbackManagerParam | ICallbackManagerOption);
29
- declare type TCallbackManagerList = TCallbackManagerListItem[];
30
- export declare class CallbackManager {
28
+ type TCallbackManagerListItem = (TCallbackManagerParam | ICallbackManagerOption);
29
+ type TCallbackManagerList = TCallbackManagerListItem[];
30
+ declare class CallbackManager {
31
31
  callbacks: TCallbackManagerList;
32
32
  /**
33
33
  * 添加回调
@@ -50,4 +50,4 @@ export declare class CallbackManager {
50
50
  */
51
51
  trigger: (...args: TCallbackManagerList) => void;
52
52
  }
53
- export {};
53
+ export { MethodHandler, CallbackManager };
@@ -1,5 +1,6 @@
1
1
  import { isFunction } from '@tarojs/shared';
2
- export class MethodHandler {
2
+
3
+ class MethodHandler {
3
4
  constructor({ name, success, fail, complete }) {
4
5
  this.isHandlerError = false;
5
6
  this.methodName = name;
@@ -35,7 +36,7 @@ export class MethodHandler {
35
36
  : reject(res);
36
37
  }
37
38
  }
38
- export class CallbackManager {
39
+ class CallbackManager {
39
40
  constructor() {
40
41
  this.callbacks = [];
41
42
  /**
@@ -87,3 +88,6 @@ export class CallbackManager {
87
88
  };
88
89
  }
89
90
  }
91
+
92
+ export { CallbackManager, MethodHandler };
93
+ //# sourceMappingURL=handler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handler.js","sources":["../../src/utils/handler.ts"],"sourcesContent":["import { isFunction } from '@tarojs/shared'\n\ntype TCallback<T = Partial<TaroGeneral.CallbackResult>> = (res: T) => Promise<void> | void\ninterface IMethodParam<T = Partial<TaroGeneral.CallbackResult>> {\n name: string\n success?: TCallback<T & TaroGeneral.CallbackResult>\n fail?: TCallback\n complete?: TCallback\n}\ninterface IMockPromise {\n resolve?: typeof Promise.resolve | TFunc\n reject?: typeof Promise.reject | TFunc\n}\n\nexport class MethodHandler<T = Partial<TaroGeneral.CallbackResult>> {\n methodName: string\n\n protected __success?: TCallback<T>\n protected __fail?: TCallback\n protected __complete?: TCallback\n\n protected isHandlerError = false\n\n constructor ({ name, success, fail, complete }: IMethodParam<T>) {\n this.methodName = name\n this.__success = success\n this.__fail = fail\n this.__complete = complete\n\n this.isHandlerError = isFunction(this.__complete) || isFunction(this.__fail)\n }\n\n success<U = Record<string, unknown>> (res: Partial<T> & Partial<TaroGeneral.CallbackResult> = {}, promise: IMockPromise = {}): Promise<T & U & TaroGeneral.CallbackResult> {\n if (!res.errMsg) {\n res.errMsg = `${this.methodName}:ok`\n }\n isFunction(this.__success) && this.__success(res as T)\n isFunction(this.__complete) && this.__complete(res)\n\n const { resolve = Promise.resolve.bind(Promise) } = promise\n return resolve(res as Required<T & U & TaroGeneral.CallbackResult>)\n }\n\n fail<U = Record<string, unknown>> (res: Partial<T> & Partial<TaroGeneral.CallbackResult> = {}, promise: IMockPromise = {}): Promise<T & U & TaroGeneral.CallbackResult> {\n if (!res.errMsg) {\n res.errMsg = `${this.methodName}:fail`\n } else {\n res.errMsg = `${this.methodName}:fail ${res.errMsg}`\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error(res.errMsg)\n }\n isFunction(this.__fail) && this.__fail(res)\n isFunction(this.__complete) && this.__complete(res)\n\n const {\n resolve = Promise.resolve.bind(Promise),\n reject = Promise.reject.bind(Promise)\n } = promise\n return this.isHandlerError\n ? resolve(res as Required<T & U & TaroGeneral.CallbackResult>)\n : reject(res)\n }\n}\n\ntype TCallbackManagerParam = (...arr: unknown[]) => void\ninterface ICallbackManagerOption {\n callback?: TCallbackManagerParam\n ctx?: any\n [key: string]: unknown\n}\ntype TCallbackManagerListItem = (TCallbackManagerParam | ICallbackManagerOption)\ntype TCallbackManagerList = TCallbackManagerListItem[]\n\nexport class CallbackManager {\n callbacks: TCallbackManagerList = []\n\n /**\n * 添加回调\n * @param {{ callback: function, ctx: any } | function} opt\n */\n add = (opt?: TCallbackManagerListItem) => {\n if (opt) this.callbacks.push(opt)\n }\n\n /**\n * 移除回调\n * @param {{ callback: function, ctx: any } | function} opt\n */\n remove = (opt?: TCallbackManagerListItem) => {\n if (opt) {\n let pos = -1\n this.callbacks.forEach((callback, k) => {\n if (callback === opt) {\n pos = k\n }\n })\n if (pos > -1) {\n this.callbacks.splice(pos, 1)\n }\n }\n }\n\n /**\n * 获取回调函数数量\n * @return {number}\n */\n count = () => {\n return this.callbacks.length\n }\n\n /**\n * 触发回调\n * @param {...any} args 回调的调用参数\n */\n trigger = (...args: TCallbackManagerList) => {\n this.callbacks.forEach(opt => {\n if (isFunction(opt)) {\n opt(...args)\n } else {\n const { callback, ctx } = opt\n isFunction(callback) && callback.call(ctx, ...args)\n }\n })\n }\n}\n"],"names":[],"mappings":";;MAca,aAAa,CAAA;IASxB,WAAa,CAAA,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAmB,EAAA;QAFrD,IAAc,CAAA,cAAA,GAAG,KAAK,CAAA;AAG9B,QAAA,IAAI,CAAC,UAAU,GAAG,IAAI,CAAA;AACtB,QAAA,IAAI,CAAC,SAAS,GAAG,OAAO,CAAA;AACxB,QAAA,IAAI,CAAC,MAAM,GAAG,IAAI,CAAA;AAClB,QAAA,IAAI,CAAC,UAAU,GAAG,QAAQ,CAAA;AAE1B,QAAA,IAAI,CAAC,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,CAAA;KAC7E;AAED,IAAA,OAAO,CAA+B,GAAA,GAAwD,EAAE,EAAE,UAAwB,EAAE,EAAA;AAC1H,QAAA,IAAI,CAAC,GAAG,CAAC,MAAM,EAAE;YACf,GAAG,CAAC,MAAM,GAAG,CAAA,EAAG,IAAI,CAAC,UAAU,KAAK,CAAA;AACrC,SAAA;AACD,QAAA,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,IAAI,CAAC,SAAS,CAAC,GAAQ,CAAC,CAAA;AACtD,QAAA,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAA;AAEnD,Q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AAC,CAAC,CAAA;AACJ,SAAC,CAAA;KACF;AAAA;;;;"}
@@ -1,26 +1,26 @@
1
1
  import { TaroElement } from '@tarojs/runtime';
2
- export declare function shouldBeObject(target: unknown): {
2
+ declare function shouldBeObject(target: unknown): {
3
3
  flag: boolean;
4
4
  msg?: undefined;
5
5
  } | {
6
6
  flag: boolean;
7
7
  msg: string;
8
8
  };
9
- export declare function findDOM(inst?: any): TaroElement | HTMLElement | undefined;
9
+ declare function findDOM(inst?: any): TaroElement | HTMLElement | undefined;
10
10
  interface IParameterErrorParam {
11
11
  name?: string;
12
12
  para?: string;
13
13
  correct?: string;
14
14
  wrong?: unknown;
15
15
  }
16
- export declare function getParameterError({ name, para, correct, wrong }: IParameterErrorParam): string;
17
- export declare const toKebabCase: (string: any) => any;
18
- export declare function inlineStyle(style: any): string;
19
- export declare function setTransform(el: any, val: any): void;
20
- export declare function serializeParams(params: any): string;
21
- export declare function temporarilyNotSupport(name?: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
22
- export declare function weixinCorpSupport(name: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
23
- export declare function permanentlyNotSupport(name?: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
16
+ declare function getParameterError({ name, para, correct, wrong }: IParameterErrorParam): string;
17
+ declare const toKebabCase: (string: any) => any;
18
+ declare function inlineStyle(style: any): string;
19
+ declare function setTransform(el: any, val: any): void;
20
+ declare function serializeParams(params: any): string;
21
+ declare function temporarilyNotSupport(name?: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
22
+ declare function weixinCorpSupport(name: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
23
+ declare function permanentlyNotSupport(name?: string): (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
24
24
  interface IProcessOpenApi<TOptions = Record<string, unknown>, TResult extends TaroGeneral.CallbackResult = any> {
25
25
  name: string;
26
26
  defaultOptions?: TOptions;
@@ -28,12 +28,13 @@ interface IProcessOpenApi<TOptions = Record<string, unknown>, TResult extends Ta
28
28
  formatOptions?: (opts: TOptions) => TOptions;
29
29
  formatResult?: (res: TResult) => TResult;
30
30
  }
31
- export declare function processOpenApi<TOptions = Record<string, unknown>, TResult extends TaroGeneral.CallbackResult = any>({ name, defaultOptions, standardMethod, formatOptions, formatResult }: IProcessOpenApi<TOptions, TResult>): (options?: Partial<TOptions>, ...args: any[]) => Promise<TResult>;
31
+ declare function processOpenApi<TOptions = Record<string, unknown>, TResult extends TaroGeneral.CallbackResult = any>({ name, defaultOptions, standardMethod, formatOptions, formatResult }: IProcessOpenApi<TOptions, TResult>): (options?: Partial<TOptions>, ...args: any[]) => Promise<TResult>;
32
32
  /**
33
33
  * 根据url获取应用的启动页面
34
34
  * @returns
35
35
  */
36
- export declare function getLaunchPage(): string;
37
- export * from './animation';
38
- export * from './lodash';
39
- export * from './valid';
36
+ declare function getLaunchPage(): string;
37
+ export { shouldBeObject, findDOM, getParameterError, toKebabCase, inlineStyle, setTransform, serializeParams, temporarilyNotSupport, weixinCorpSupport, permanentlyNotSupport, processOpenApi, getLaunchPage };
38
+ export * from "./animation";
39
+ export * from "./lodash";
40
+ export * from "./valid";
@@ -1,10 +1,14 @@
1
- /* eslint-disable prefer-promise-reject-errors */
2
1
  import Taro from '@tarojs/api';
3
- import { addLeadingSlash, getHomePage, stripBasename } from '@tarojs/router/dist/utils';
4
- import { Current, hooks } from '@tarojs/runtime';
2
+ import { addLeadingSlash, stripBasename, getHomePage } from '@tarojs/router/dist/utils';
3
+ import { hooks, Current } from '@tarojs/runtime';
5
4
  import { isFunction } from '@tarojs/shared';
6
- import { MethodHandler } from './handler';
7
- export function shouldBeObject(target) {
5
+ import { MethodHandler } from './handler.js';
6
+ export { easeInOut, getTimingFunc } from './animation.js';
7
+ export { debounce, throttle } from './lodash.js';
8
+ export { isValidColor } from './valid.js';
9
+
10
+ /* eslint-disable prefer-promise-reject-errors */
11
+ function shouldBeObject(target) {
8
12
  if (target && typeof target === 'object')
9
13
  return { flag: true };
10
14
  return {
@@ -15,7 +19,7 @@ export function shouldBeObject(target) {
15
19
  })
16
20
  };
17
21
  }
18
- export function findDOM(inst) {
22
+ function findDOM(inst) {
19
23
  if (inst && hooks.isExist('getDOMNode')) {
20
24
  return hooks.call('getDOMNode', inst);
21
25
  }
@@ -31,7 +35,7 @@ export function findDOM(inst) {
31
35
  }
32
36
  return el;
33
37
  }
34
- export function getParameterError({ name = '', para, correct, wrong }) {
38
+ function getParameterError({ name = '', para, correct, wrong }) {
35
39
  const parameter = para ? `parameter.${para}` : 'parameter';
36
40
  const errorType = upperCaseFirstLetter(wrong === null ? 'Null' : typeof wrong);
37
41
  if (name) {
@@ -47,10 +51,10 @@ function upperCaseFirstLetter(string) {
47
51
  string = string.replace(/^./, match => match.toUpperCase());
48
52
  return string;
49
53
  }
50
- export const toKebabCase = function (string) {
54
+ const toKebabCase = function (string) {
51
55
  return string.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();
52
56
  };
53
- export function inlineStyle(style) {
57
+ function inlineStyle(style) {
54
58
  let res = '';
55
59
  for (const attr in style)
56
60
  res += `${attr}: ${style[attr]};`;
@@ -60,11 +64,11 @@ export function inlineStyle(style) {
60
64
  res = res.replace(/flex-direction:(.+?);/g, (s, $1) => `${s}-webkit-flex-direction:${$1};`);
61
65
  return res;
62
66
  }
63
- export function setTransform(el, val) {
67
+ function setTransform(el, val) {
64
68
  el.style.webkitTransform = val;
65
69
  el.style.transform = val;
66
70
  }
67
- export function serializeParams(params) {
71
+ function serializeParams(params) {
68
72
  if (!params) {
69
73
  return '';
70
74
  }
@@ -74,7 +78,7 @@ export function serializeParams(params) {
74
78
  : encodeURIComponent(params[key])}`))
75
79
  .join('&');
76
80
  }
77
- export function temporarilyNotSupport(name = '') {
81
+ function temporarilyNotSupport(name = '') {
78
82
  return (option = {}, ...args) => {
79
83
  const { success, fail, complete } = option;
80
84
  const handle = new MethodHandler({ name, success, fail, complete });
@@ -94,7 +98,7 @@ export function temporarilyNotSupport(name = '') {
94
98
  }
95
99
  };
96
100
  }
97
- export function weixinCorpSupport(name) {
101
+ function weixinCorpSupport(name) {
98
102
  return (option = {}, ...args) => {
99
103
  const { success, fail, complete } = option;
100
104
  const handle = new MethodHandler({ name, success, fail, complete });
@@ -114,7 +118,7 @@ export function weixinCorpSupport(name) {
114
118
  }
115
119
  };
116
120
  }
117
- export function permanentlyNotSupport(name = '') {
121
+ function permanentlyNotSupport(name = '') {
118
122
  return (option = {}, ...args) => {
119
123
  const { success, fail, complete } = option;
120
124
  const handle = new MethodHandler({ name, success, fail, complete });
@@ -134,7 +138,7 @@ export function permanentlyNotSupport(name = '') {
134
138
  }
135
139
  };
136
140
  }
137
- export function processOpenApi({ name, defaultOptions, standardMethod, formatOptions = options => options, formatResult = res => res }) {
141
+ function processOpenApi({ name, defaultOptions, standardMethod, formatOptions = options => options, formatResult = res => res }) {
138
142
  const notSupported = weixinCorpSupport(name);
139
143
  return (options = {}, ...args) => {
140
144
  var _a;
@@ -170,7 +174,7 @@ export function processOpenApi({ name, defaultOptions, standardMethod, formatOpt
170
174
  * 根据url获取应用的启动页面
171
175
  * @returns
172
176
  */
173
- export function getLaunchPage() {
177
+ function getLaunchPage() {
174
178
  var _a, _b, _c, _d, _e, _f, _g;
175
179
  const appConfig = window.__taroAppConfig || {};
176
180
  // createPageConfig时根据stack的长度来设置stamp以保证页面path的唯一,此函数是在createPageConfig之前调用,预先设置stamp=1
@@ -190,6 +194,6 @@ export function getLaunchPage() {
190
194
  }
191
195
  return routePath + stamp;
192
196
  }
193
- export * from './animation';
194
- export * from './lodash';
195
- export * from './valid';
197
+
198
+ export { findDOM, getLaunchPage, getParameterError, inlineStyle, permanentlyNotSupport, processOpenApi, serializeParams, setTransform, shouldBeObject, temporarilyNotSupport, toKebabCase, weixinCorpSupport };
199
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sources":["../../src/utils/index.ts"],"sourcesContent":["/* eslint-disable prefer-promise-reject-errors */\nimport Taro from '@tarojs/api'\nimport { addLeadingSlash, getHomePage, stripBasename } from '@tarojs/router/dist/utils'\nimport { Current, hooks, TaroElement } from '@tarojs/runtime'\nimport { isFunction } from '@tarojs/shared'\n\nimport { MethodHandler } from './handler'\n\nexport function shouldBeObject (target: unknown) {\n if (target && typeof target === 'object') return { flag: true }\n return {\n flag: false,\n msg: getParameterError({\n correct: 'Object',\n wrong: target\n })\n }\n}\n\nexport function findDOM (inst?): TaroElement | HTMLElement | undefined {\n if (inst && hooks.isExist('getDOMNode')) {\n return hooks.call('getDOMNode', inst)\n }\n\n const page = Current.page\n const path = page?.path\n const msg = '没有找到已经加载了的页面,请在页面加载完成后时候此 API。'\n if (path == null) {\n throw new Error(msg)\n }\n\n const el = document.getElementById(path)\n if (el == null) {\n throw new Error('在已加载页面中没有找到对应的容器元素。')\n }\n\n return el\n}\n\ninterface IParameterErrorParam {\n name?: string\n para?: string\n correct?: string\n wrong?: unknown\n}\nexport function getParameterError ({ name = '', para, correct, wrong }: IParameterErrorParam) {\n const parameter = para ? `parameter.${para}` : 'parameter'\n const errorType = upperCaseFirstLetter(wrong === null ? 'Null' : typeof wrong)\n if (name) {\n return `${name}:fail parameter error: ${parameter} should be ${correct} instead of ${errorType}`\n } else {\n return `parameter error: ${parameter} should be ${correct} instead of ${errorType}`\n }\n}\n\nfunction upperCaseFirstLetter (string) {\n if (typeof string !== 'string') return string\n string = string.replace(/^./, match => match.toUpperCase())\n return string\n}\n\nexport const toKebabCase = function (string) {\n return string.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase()\n}\n\n\nexport function inlineStyle (style) {\n let res = ''\n for (const attr in style) res += `${attr}: ${style[attr]};`\n if (res.indexOf('display: flex;') >= 0) res += 'display: -webkit-box;display: -webkit-flex;'\n res = res.replace(/transform:(.+?);/g, (s, $1) => `${s}-webkit-transform:${$1};`)\n res = res.replace(/flex-direction:(.+?);/g, (s, $1) => `${s}-webkit-flex-direction:${$1};`)\n return res\n}\n\nexport function setTransform (el, val) {\n el.style.webkitTransform = val\n el.style.transform = val\n}\n\nexport function serializeParams (params) {\n if (!params) {\n return ''\n }\n return Object.keys(params)\n .map(key => (\n `${encodeURIComponent(key)}=${typeof (params[key]) === 'object'\n ? encodeURIComponent(JSON.stringify(params[key]))\n : encodeURIComponent(params[key])}`))\n .join('&')\n}\n\nexport function temporarilyNotSupport (name = '') {\n return (option = {}, ...args) => {\n const { success, fail, complete } = option as any\n const handle = new MethodHandler({ name, success, fail, complete })\n const errMsg = '暂时不支持 API'\n Taro.eventCenter.trigger('__taroNotSupport', {\n name,\n args: [option, ...args],\n type: 'method',\n category: 'temporarily',\n })\n if (process.env.NODE_ENV === 'production') {\n console.warn(errMsg)\n return handle.success({ errMsg })\n } else {\n return handle.fail({ errMsg })\n }\n }\n}\n\nexport function weixinCorpSupport (name: string) {\n return (option = {}, ...args) => {\n const { success, fail, complete } = option as any\n const handle = new MethodHandler({ name, success, fail, complete })\n const errMsg = 'h5 端当前仅在微信公众号 JS-SDK 环境下支持此 API'\n Taro.eventCenter.trigger('__taroNotSupport', {\n name,\n args: [option, ...args],\n type: 'method',\n category: 'weixin_corp',\n })\n if (process.env.NODE_ENV === 'production') {\n console.warn(errMsg)\n return handle.success({ errMsg })\n } else {\n return handle.fail({ errMsg })\n }\n }\n}\n\nexport function permanentlyNotSupport (name = '') {\n return (option = {}, ...args: any[]) => {\n const { success, fail, complete } = option as any\n const handle = new MethodHandler({ name, success, fail, complete })\n const errMsg = '不支持 API'\n Taro.eventCenter.trigger('__taroNotSupport', {\n name,\n args: [option, ...args],\n type: 'method',\n category: 'permanently',\n })\n if (process.env.NODE_ENV === 'production') {\n console.warn(errMsg)\n return handle.success({ errMsg })\n } else {\n return handle.fail({ errMsg })\n }\n }\n}\n\ninterface IProcessOpenApi<TOptions = Record<string, unknown>, TResult extends TaroGeneral.CallbackResult = any> {\n name: string\n defaultOptions?: TOptions\n standardMethod?: (opts: TOptions) => Promise<TResult>\n formatOptions?: (opts: TOptions) => TOptions\n formatResult?: (res: TResult) => TResult\n}\n\nexport function processOpenApi<TOptions = Record<string, unknown>, TResult extends TaroGeneral.CallbackResult = any> ({\n name,\n defaultOptions,\n standardMethod,\n formatOptions = options => options,\n formatResult = res => res\n}: IProcessOpenApi<TOptions, TResult>) {\n const notSupported = weixinCorpSupport(name)\n return (options: Partial<TOptions> = {}, ...args: any[]): Promise<TResult> => {\n // @ts-ignore\n const targetApi = window?.wx?.[name]\n const opts = formatOptions(Object.assign({}, defaultOptions, options))\n if (isFunction(targetApi)) {\n return new Promise<TResult>((resolve, reject) => {\n ['fail', 'success', 'complete'].forEach(k => {\n opts[k] = preRef => {\n const res = formatResult(preRef)\n options[k] && options[k](res)\n if (k === 'success') {\n resolve(res)\n } else if (k === 'fail') {\n reject(res)\n }\n }\n return targetApi(opts)\n })\n })\n } else if (isFunction(standardMethod)) {\n return standardMethod(opts)\n } else {\n return notSupported(options, ...args) as Promise<TResult>\n }\n }\n}\n\n/**\n * 根据url获取应用的启动页面\n * @returns\n */\nexport function getLaunchPage (): string {\n const appConfig = (window as any).__taroAppConfig || {}\n // createPageConfig时根据stack的长度来设置stamp以保证页面path的唯一,此函数是在createPageConfig之前调用,预先设置stamp=1\n const stamp = '?stamp=1'\n let entryPath = ''\n\n if (appConfig.router?.mode === 'browser' || appConfig.router?.mode === 'multi') {\n entryPath = location.pathname\n } else {\n entryPath = location.hash.slice(1).split('?')[0]\n }\n const routePath = addLeadingSlash(stripBasename(entryPath, appConfig.router?.basename))\n const homePath = addLeadingSlash(getHomePage(appConfig.routes?.[0]?.path, appConfig.router?.basename, appConfig.router?.customRoutes, appConfig.entryPagePath))\n\n // url上没有指定应用的启动页面时使用homePath\n if(routePath === '/') {\n return homePath + stamp\n }\n\n return routePath + stamp\n}\n\nexport * from './animation'\nexport * from './lodash'\nexport * from './valid'\n"],"names":[],"mappings":";;;;;;;;;AAAA;AAQM,SAAU,cAAc,CAAE,MAAe,EAAA;AAC7C,IAAA,IAAI,MAAM,IAAI,OAAO,MAAM,KAAK,QAAQ;AAAE,QAAA,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,CAAA;IAC/D,OAAO;AACL,QAAA,IAAI,EAAE,KAAK;QACX,GAAG,EAAE,iBAAiB,CAAC;AACrB,YAAA,OAAO,EAAE,QAAQ;AACjB,YAAA,KAAK,EAAE,MAAM;SACd,CAAC;KACH,CAAA;AACH,CAAC;AAEK,SAAU,OAAO,CAAE,IAAK,EAAA;IAC5B,IAAI,IAAI,IAAI,KAAK,CAAC,OAAO,CAAC,YAAY,CAAC,EAAE;QACvC,OAAO,KAAK,CAAC,IAAI,CAAC,YAAY,EAAE,IAAI,CAAC,CAAA;AACtC,KAAA;AAED,IAAA,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAA;IACzB,MAAM,IAAI,GAAG,IAAI,KAAA,IAAA,IAAJ,IAAI,KAAJ,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,IAAI,CAAE,IAAI,CAAA;IACvB,MAAM,GAAG,GAAG,gCAAgC,CAAA;IAC5C,IAAI,IAAI,IAAI,IAAI,EAAE;AAChB,QAAA,MAAM,IAAI,KAAK,CAAC,GAAG,CAAC,CAAA;AACrB,KAAA;IAED,MAAM,EAAE,GAAG,QAAQ,CAAC,cAAc,CAAC,IAAI,CAAC,CAAA;IACxC,IAAI,EAAE,IAAI,IAAI,EAAE;AACd,QAAA,MAAM,IAAI,KAAK,CAAC,qBAAqB,CAAC,CAAA;AACvC,KAAA;AAED,IAAA,OAAO,EAAE,CAAA;AAC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AA,CAAA,EAAA,GAAA,SAAS,CAAC,MAAM,MAAG,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAA,CAAC,CAAC,MAAA,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAE,IAAI,EAAE,CAAA,EAAA,GAAA,SAAS,CAAC,MAAM,MAAE,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAA,QAAQ,EAAE,CAAA,EAAA,GAAA,SAAS,CAAC,MAAM,MAAE,IAAA,IAAA,EAAA,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAA,YAAY,EAAE,SAAS,CAAC,aAAa,CAAC,CAAC,CAAA;;IAG/J,IAAG,SAAS,KAAK,GAAG,EAAE;QACpB,OAAO,QAAQ,GAAG,KAAK,CAAA;AACxB,KAAA;IAED,OAAO,SAAS,GAAG,KAAK,CAAA;AAC1B;;;;"}
@@ -1,2 +1,3 @@
1
- export declare function throttle(fn: any, threshold?: number, scope?: any): (...args: any[]) => void;
2
- export declare function debounce(fn: any, ms?: number, scope?: any): (...args: any[]) => void;
1
+ declare function throttle(fn: any, threshold?: number, scope?: any): (...args: any[]) => void;
2
+ declare function debounce(fn: any, ms?: number, scope?: any): (...args: any[]) => void;
3
+ export { throttle, debounce };
@@ -1,4 +1,4 @@
1
- export function throttle(fn, threshold = 250, scope) {
1
+ function throttle(fn, threshold = 250, scope) {
2
2
  let lastTime = 0;
3
3
  let deferTimer;
4
4
  return function (...args) {
@@ -17,7 +17,7 @@ export function throttle(fn, threshold = 250, scope) {
17
17
  }
18
18
  };
19
19
  }
20
- export function debounce(fn, ms = 250, scope) {
20
+ function debounce(fn, ms = 250, scope) {
21
21
  let timer;
22
22
  return function (...args) {
23
23
  const context = scope || this;
@@ -27,3 +27,6 @@ export function debounce(fn, ms = 250, scope) {
27
27
  }, ms);
28
28
  };
29
29
  }
30
+
31
+ export { debounce, throttle };
32
+ //# sourceMappingURL=lodash.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lodash.js","sources":["../../src/utils/lodash.ts"],"sourcesContent":["export function throttle (fn, threshold = 250, scope?) {\n let lastTime = 0\n let deferTimer: ReturnType<typeof setTimeout>\n return function (...args) {\n const context = scope || this\n const now = Date.now()\n if (now - lastTime > threshold) {\n fn.apply(this, args)\n lastTime = now\n } else {\n clearTimeout(deferTimer)\n deferTimer = setTimeout(() => {\n lastTime = now\n fn.apply(context, args)\n }, threshold)\n }\n }\n}\n\nexport function debounce (fn, ms = 250, scope?) {\n let timer: ReturnType<typeof setTimeout>\n\n return function (...args) {\n const context = scope || this\n clearTimeout(timer)\n timer = setTimeout(function () {\n fn.apply(context, args)\n }, ms)\n }\n}\n"],"names":[],"mappings":"AAAM,SAAU,QAAQ,CAAE,EAAE,EAAE,SAAS,GAAG,GAAG,EAAE,KAAM,EAAA;IACnD,IAAI,QAAQ,GAAG,CAAC,CAAA;AAChB,IAAA,IAAI,UAAyC,CAAA;IAC7C,OAAO,UAAU,GAAG,IAAI,EAAA;AACtB,QAAA,MAAM,OAAO,GAAG,KAAK,IAAI,IAAI,CAAA;AAC7B,QAAA,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,EAAE,CAAA;AACtB,QAAA,IAAI,GAAG,GAAG,QAAQ,GAAG,SAAS,EAAE;AAC9B,YAAA,EAAE,CAAC,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC,CAAA;YACpB,QAAQ,GAAG,GAAG,CAAA;AACf,SAAA;AAAM,aAAA;YACL,YAAY,CAAC,UAAU,CAAC,CAAA;AACxB,YAAA,UAAU,GAAG,UAAU,CAAC,MAAK;gBAC3B,QAAQ,GAAG,GAAG,CAAA;AACd,gBAAA,EAAE,CAAC,KAAK,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;aACxB,EAAE,SAAS,CAAC,CAAA;AACd,SAAA;AACH,KAAC,CAAA;AACH,CAAC;AAEK,SAAU,QAAQ,CAAE,EAAE,EAAE,EAAE,GAAG,GAAG,EAAE,KAAM,EAAA;AAC5C,IAAA,IAAI,KAAoC,CAAA;IAExC,OAAO,UAAU,GAAG,IAAI,EAAA;AACtB,QAAA,MAAM,OAAO,GAAG,KAAK,IAAI,IAAI,CAAA;QAC7B,YAAY,CAAC,KAAK,CAAC,CAAA;QACnB,KAAK,GAAG,UAAU,CAAC,YAAA;AACjB,YAAA,EAAE,CAAC,KAAK,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;SACxB,EAAE,EAAE,CAAC,CAAA;AACR,KAAC,CAAA;AACH;;;;"}
@@ -1 +1,2 @@
1
- export declare const isValidColor: (color: string) => boolean;
1
+ declare const isValidColor: (color: string) => boolean;
2
+ export { isValidColor };
@@ -1,4 +1,7 @@
1
1
  const VALID_COLOR_REG = /^#[0-9a-fA-F]{6}$/;
2
- export const isValidColor = (color) => {
2
+ const isValidColor = (color) => {
3
3
  return VALID_COLOR_REG.test(color);
4
4
  };
5
+
6
+ export { isValidColor };
7
+ //# sourceMappingURL=valid.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"valid.js","sources":["../../src/utils/valid.ts"],"sourcesContent":["const VALID_COLOR_REG = /^#[0-9a-fA-F]{6}$/\nexport const isValidColor = (color: string) => {\n return VALID_COLOR_REG.test(color)\n}\n"],"names":[],"mappings":"AAAA,MAAM,eAAe,GAAG,mBAAmB,CAAA;AAC9B,MAAA,YAAY,GAAG,CAAC,KAAa,KAAI;AAC5C,IAAA,OAAO,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC,CAAA;AACpC;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tarojs/taro-h5",
3
- "version": "3.6.0-beta.2",
3
+ "version": "3.6.0-beta.3",
4
4
  "description": "Taro h5 framework",
5
5
  "browser": "dist/index.esm.js",
6
6
  "main:h5": "dist/index.js",
@@ -31,24 +31,24 @@
31
31
  "jsonp-retry": "^1.0.3",
32
32
  "query-string": "^7.1.1",
33
33
  "whatwg-fetch": "^3.4.0",
34
- "@tarojs/api": "3.6.0-beta.2",
35
- "@tarojs/router": "3.6.0-beta.2",
36
- "@tarojs/runtime": "3.6.0-beta.2",
37
- "@tarojs/shared": "3.6.0-beta.2"
34
+ "@tarojs/api": "3.6.0-beta.3",
35
+ "@tarojs/router": "3.6.0-beta.3",
36
+ "@tarojs/runtime": "3.6.0-beta.3",
37
+ "@tarojs/shared": "3.6.0-beta.3"
38
38
  },
39
39
  "devDependencies": {
40
40
  "jest": "^29.3.1",
41
41
  "jest-fetch-mock": "^3.0.3",
42
42
  "jest-localstorage-mock": "^2.4.0",
43
43
  "jest-mock-console": "^1.0.0",
44
+ "lodash": "^4.17.21",
44
45
  "react": "^18.2.0",
45
- "react-test-renderer": "^18.2.0"
46
+ "react-test-renderer": "^18.2.0",
47
+ "@tarojs/components": "3.6.0-beta.3"
46
48
  },
47
49
  "scripts": {
48
- "assets": "cpy 'src/**/*.css' dist",
49
- "build": "rimraf ./dist && tsc && pnpm run assets && rollup -c",
50
- "predev": "pnpm run assets",
51
- "dev": "tsc -w",
50
+ "build": "rimraf ./dist && cross-env NODE_ENV=production rollup -c",
51
+ "dev": "cross-env NODE_ENV=development rollup -c -w",
52
52
  "test": "jest",
53
53
  "test:ci": "jest -i --coverage false",
54
54
  "test:dev": "jest --watch",
package/types/define.d.ts CHANGED
@@ -1,2 +1,4 @@
1
1
  // NOTE: 允许用户自定义的常量
2
2
  declare const LOCATION_APIKEY: string | undefined
3
+ // NOTE: 使用自定义组件库
4
+ declare const USE_HTML_COMPONENTS: boolean
@@ -1,79 +0,0 @@
1
- .taro_choose_location {
2
- position: fixed;
3
- display: flex;
4
- flex-direction: column;
5
- width: 100%;
6
- height: 100%;
7
- top: 100%;
8
- background-color: #fff;
9
- transition: ease top .3s;
10
- z-index: 1;
11
- }
12
-
13
- .taro_choose_location_bar {
14
- display: flex;
15
- flex: 0 95px;
16
- height: 95px;
17
- background-color: #ededed;
18
- color: #090909;
19
- }
20
-
21
- .taro_choose_location_back {
22
- flex: 0 45px;
23
- position: relative;
24
- width: 33px;
25
- height: 30px;
26
- margin-top: 30px;
27
- }
28
-
29
- .taro_choose_location_back::before {
30
- content: '';
31
- position: absolute;
32
- top: 0;
33
- left: 0;
34
- display: block;
35
- width: 0;
36
- height: 0;
37
- border: solid 15px;
38
- border-top-color: transparent;
39
- border-right-color: #090909;
40
- border-bottom-color: transparent;
41
- border-left-color: transparent;
42
- }
43
-
44
- .taro_choose_location_back::after {
45
- content: '';
46
- position: absolute;
47
- display: block;
48
- width: 0;
49
- height: 0;
50
- top: 0;
51
- left: 3px;
52
- border: solid 15px;
53
- border-top-color: transparent;
54
- border-right-color: #ededed;
55
- border-bottom-color: transparent;
56
- border-left-color: transparent;
57
- }
58
-
59
- .taro_choose_location_title {
60
- flex: 1;
61
- line-height: 95px;
62
- padding-left: 30px;
63
- }
64
-
65
- .taro_choose_location_submit {
66
- width: 110px;
67
- height: 60px;
68
- color: #fff;
69
- background-color: #08bf62;
70
- border: none;
71
- font-size: 28px;
72
- line-height: 60px;
73
- padding: 0;
74
- margin: 18px 30px 0 0;
75
- }
76
-
77
- .taro_choose_location_frame {
78
- flex: 1;
79
- }
@@ -1,16 +0,0 @@
1
- import Taro from '@tarojs/api';
2
- export declare class EditorContext implements Taro.EditorContext {
3
- blur: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
4
- clear: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
5
- format: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
6
- getContents: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
7
- getSelectionText: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
8
- insertDivider: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
9
- insertImage: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
10
- insertText: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
11
- redo: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
12
- removeFormat: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
13
- scrollIntoView: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
14
- setContents: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
15
- undo: (option?: {}, ...args: any[]) => Promise<Partial<TaroGeneral.CallbackResult> & Record<string, unknown> & TaroGeneral.CallbackResult>;
16
- }