@tarojs/components 3.8.0-canary.0 → 4.0.0-beta.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 (457) hide show
  1. package/dist/cjs/helper-ad6306f6.js +31 -0
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/taro-ad-core.cjs.entry.js +1 -1
  4. package/dist/cjs/taro-ad-custom-core.cjs.entry.js +1 -1
  5. package/dist/cjs/taro-animation-video-core.cjs.entry.js +1 -1
  6. package/dist/cjs/taro-animation-view-core.cjs.entry.js +1 -1
  7. package/dist/cjs/taro-ar-camera-core.cjs.entry.js +1 -1
  8. package/dist/cjs/taro-aweme-data-core.cjs.entry.js +1 -1
  9. package/dist/cjs/taro-camera-core.cjs.entry.js +1 -1
  10. package/dist/cjs/taro-canvas-core.cjs.entry.js +13 -1
  11. package/dist/cjs/taro-channel-live-core.cjs.entry.js +1 -1
  12. package/dist/cjs/taro-channel-video-core.cjs.entry.js +1 -1
  13. package/dist/cjs/taro-comment-detail-core.cjs.entry.js +1 -1
  14. package/dist/cjs/taro-comment-list-core.cjs.entry.js +1 -1
  15. package/dist/cjs/taro-components.cjs.js +1 -1
  16. package/dist/cjs/taro-contact-button-core.cjs.entry.js +1 -1
  17. package/dist/cjs/taro-editor-core.cjs.entry.js +1 -1
  18. package/dist/cjs/taro-follow-swan-core.cjs.entry.js +1 -1
  19. package/dist/cjs/taro-functional-page-navigator-core.cjs.entry.js +1 -1
  20. package/dist/cjs/taro-grid-view-core.cjs.entry.js +1 -1
  21. package/dist/cjs/taro-image-core.cjs.entry.js +1 -1
  22. package/dist/cjs/taro-inline-payment-panel-core.cjs.entry.js +1 -1
  23. package/dist/cjs/taro-keyboard-accessory-core.cjs.entry.js +1 -1
  24. package/dist/cjs/taro-lifestyle-core.cjs.entry.js +1 -1
  25. package/dist/cjs/taro-like-core.cjs.entry.js +1 -1
  26. package/dist/cjs/taro-list-view-core.cjs.entry.js +1 -1
  27. package/dist/cjs/taro-live-player-core.cjs.entry.js +1 -1
  28. package/dist/cjs/taro-live-pusher-core.cjs.entry.js +1 -1
  29. package/dist/cjs/taro-login-core.cjs.entry.js +1 -1
  30. package/dist/cjs/taro-lottie-core.cjs.entry.js +1 -1
  31. package/dist/cjs/taro-map-core.cjs.entry.js +1 -1
  32. package/dist/cjs/taro-match-media-core.cjs.entry.js +1 -1
  33. package/dist/cjs/taro-native-slot-core.cjs.entry.js +1 -1
  34. package/dist/cjs/taro-navigation-bar-core.cjs.entry.js +1 -1
  35. package/dist/cjs/taro-official-account-core.cjs.entry.js +1 -1
  36. package/dist/cjs/taro-open-data-core.cjs.entry.js +1 -1
  37. package/dist/cjs/taro-page-container-core.cjs.entry.js +1 -1
  38. package/dist/cjs/taro-page-meta-core.cjs.entry.js +1 -1
  39. package/dist/cjs/taro-picker-core_2.cjs.entry.js +31 -30
  40. package/dist/cjs/taro-picker-view-column-core_2.cjs.entry.js +35 -35
  41. package/dist/cjs/{taro-pull-to-refresh.cjs.entry.js → taro-pull-to-refresh-core.cjs.entry.js} +15 -13
  42. package/dist/cjs/taro-root-portal-core.cjs.entry.js +1 -1
  43. package/dist/cjs/taro-rtc-room-core.cjs.entry.js +1 -1
  44. package/dist/cjs/taro-rtc-room-item-core.cjs.entry.js +1 -1
  45. package/dist/cjs/taro-scroll-view-core.cjs.entry.js +12 -0
  46. package/dist/cjs/taro-share-element-core.cjs.entry.js +1 -1
  47. package/dist/cjs/taro-slot-core.cjs.entry.js +1 -1
  48. package/dist/cjs/taro-snapshot-core.cjs.entry.js +21 -0
  49. package/dist/cjs/taro-sticky-header-core.cjs.entry.js +1 -1
  50. package/dist/cjs/taro-sticky-section-core.cjs.entry.js +1 -1
  51. package/dist/cjs/taro-swiper-core_2.cjs.entry.js +90 -58
  52. package/dist/cjs/taro-tab-item-core.cjs.entry.js +1 -1
  53. package/dist/cjs/taro-tabbar.cjs.entry.js +9 -21
  54. package/dist/cjs/taro-tabs-core.cjs.entry.js +1 -1
  55. package/dist/cjs/taro-video-control_3.cjs.entry.js +7 -3
  56. package/dist/cjs/taro-view-core.cjs.entry.js +3 -9
  57. package/dist/cjs/taro-voip-room-core.cjs.entry.js +1 -1
  58. package/dist/collection/collection-manifest.json +1 -0
  59. package/dist/collection/components/canvas/canvas.js +48 -2
  60. package/dist/collection/components/image/style/index.css +2 -2
  61. package/dist/collection/components/picker/picker.js +31 -30
  62. package/dist/collection/components/picker-view/picker-view-column.js +27 -55
  63. package/dist/collection/components/picker-view/picker-view.js +14 -2
  64. package/dist/collection/components/pull-to-refresh/pull-to-refresh.js +14 -12
  65. package/dist/collection/components/pull-to-refresh/style/index.css +1 -1
  66. package/dist/collection/components/scroll-view/scroll-view.js +18 -2
  67. package/dist/collection/components/snapshot/snapshot.js +11 -0
  68. package/dist/collection/components/swiper/swiper-item.js +54 -33
  69. package/dist/collection/components/swiper/swiper.js +53 -24
  70. package/dist/collection/components/tabbar/style/index.css +5 -1
  71. package/dist/collection/components/tabbar/tabbar-item.js +1 -1
  72. package/dist/collection/components/tabbar/tabbar.js +4 -4
  73. package/dist/collection/components/video/style/index.css +1 -0
  74. package/dist/collection/components/video/video.js +6 -2
  75. package/dist/collection/components/view/view.js +2 -9
  76. package/dist/collection/utils/helper.js +11 -0
  77. package/dist/components/helper.js +12 -1
  78. package/dist/components/index.d.ts +2 -1
  79. package/dist/components/index.js +2 -1
  80. package/dist/components/taro-canvas-core.js +16 -2
  81. package/dist/components/taro-image-core.js +1 -1
  82. package/dist/components/taro-picker-core.js +31 -30
  83. package/dist/components/taro-picker-view-column-core.js +26 -36
  84. package/dist/components/taro-picker-view-core.js +11 -2
  85. package/dist/components/taro-pull-to-refresh-core.d.ts +11 -0
  86. package/dist/components/{taro-pull-to-refresh.js → taro-pull-to-refresh-core.js} +19 -17
  87. package/dist/components/taro-scroll-view-core.js +12 -1
  88. package/dist/components/{taro-pull-to-refresh.d.ts → taro-snapshot-core.d.ts} +4 -4
  89. package/dist/components/taro-snapshot-core.js +33 -0
  90. package/dist/components/taro-swiper-core.js +53 -24
  91. package/dist/components/taro-swiper-item-core.js +40 -36
  92. package/dist/components/taro-tabbar.js +2 -14
  93. package/dist/components/taro-video-core.js +7 -3
  94. package/dist/components/taro-view-core.js +2 -9
  95. package/dist/esm/helper-8a85bb65.js +24 -0
  96. package/dist/esm/loader.js +1 -1
  97. package/dist/esm/taro-ad-core.entry.js +1 -1
  98. package/dist/esm/taro-ad-custom-core.entry.js +1 -1
  99. package/dist/esm/taro-animation-video-core.entry.js +1 -1
  100. package/dist/esm/taro-animation-view-core.entry.js +1 -1
  101. package/dist/esm/taro-ar-camera-core.entry.js +1 -1
  102. package/dist/esm/taro-aweme-data-core.entry.js +1 -1
  103. package/dist/esm/taro-camera-core.entry.js +1 -1
  104. package/dist/esm/taro-canvas-core.entry.js +13 -1
  105. package/dist/esm/taro-channel-live-core.entry.js +1 -1
  106. package/dist/esm/taro-channel-video-core.entry.js +1 -1
  107. package/dist/esm/taro-comment-detail-core.entry.js +1 -1
  108. package/dist/esm/taro-comment-list-core.entry.js +1 -1
  109. package/dist/esm/taro-components.js +1 -1
  110. package/dist/esm/taro-contact-button-core.entry.js +1 -1
  111. package/dist/esm/taro-editor-core.entry.js +1 -1
  112. package/dist/esm/taro-follow-swan-core.entry.js +1 -1
  113. package/dist/esm/taro-functional-page-navigator-core.entry.js +1 -1
  114. package/dist/esm/taro-grid-view-core.entry.js +1 -1
  115. package/dist/esm/taro-image-core.entry.js +1 -1
  116. package/dist/esm/taro-inline-payment-panel-core.entry.js +1 -1
  117. package/dist/esm/taro-keyboard-accessory-core.entry.js +1 -1
  118. package/dist/esm/taro-lifestyle-core.entry.js +1 -1
  119. package/dist/esm/taro-like-core.entry.js +1 -1
  120. package/dist/esm/taro-list-view-core.entry.js +1 -1
  121. package/dist/esm/taro-live-player-core.entry.js +1 -1
  122. package/dist/esm/taro-live-pusher-core.entry.js +1 -1
  123. package/dist/esm/taro-login-core.entry.js +1 -1
  124. package/dist/esm/taro-lottie-core.entry.js +1 -1
  125. package/dist/esm/taro-map-core.entry.js +1 -1
  126. package/dist/esm/taro-match-media-core.entry.js +1 -1
  127. package/dist/esm/taro-native-slot-core.entry.js +1 -1
  128. package/dist/esm/taro-navigation-bar-core.entry.js +1 -1
  129. package/dist/esm/taro-official-account-core.entry.js +1 -1
  130. package/dist/esm/taro-open-data-core.entry.js +1 -1
  131. package/dist/esm/taro-page-container-core.entry.js +1 -1
  132. package/dist/esm/taro-page-meta-core.entry.js +1 -1
  133. package/dist/esm/taro-picker-core_2.entry.js +31 -30
  134. package/dist/esm/taro-picker-view-column-core_2.entry.js +35 -35
  135. package/dist/esm/{taro-pull-to-refresh.entry.js → taro-pull-to-refresh-core.entry.js} +15 -13
  136. package/dist/esm/taro-root-portal-core.entry.js +1 -1
  137. package/dist/esm/taro-rtc-room-core.entry.js +1 -1
  138. package/dist/esm/taro-rtc-room-item-core.entry.js +1 -1
  139. package/dist/esm/taro-scroll-view-core.entry.js +12 -0
  140. package/dist/esm/taro-share-element-core.entry.js +1 -1
  141. package/dist/esm/taro-slot-core.entry.js +1 -1
  142. package/dist/esm/taro-snapshot-core.entry.js +17 -0
  143. package/dist/esm/taro-sticky-header-core.entry.js +1 -1
  144. package/dist/esm/taro-sticky-section-core.entry.js +1 -1
  145. package/dist/esm/taro-swiper-core_2.entry.js +90 -58
  146. package/dist/esm/taro-tab-item-core.entry.js +1 -1
  147. package/dist/esm/taro-tabbar.entry.js +2 -14
  148. package/dist/esm/taro-tabs-core.entry.js +1 -1
  149. package/dist/esm/taro-video-control_3.entry.js +7 -3
  150. package/dist/esm/taro-view-core.entry.js +3 -9
  151. package/dist/esm/taro-voip-room-core.entry.js +1 -1
  152. package/dist/esm-es5/helper-8a85bb65.js +1 -0
  153. package/dist/esm-es5/loader.js +1 -1
  154. package/dist/esm-es5/taro-ad-core.entry.js +1 -1
  155. package/dist/esm-es5/taro-ad-custom-core.entry.js +1 -1
  156. package/dist/esm-es5/taro-animation-video-core.entry.js +1 -1
  157. package/dist/esm-es5/taro-animation-view-core.entry.js +1 -1
  158. package/dist/esm-es5/taro-ar-camera-core.entry.js +1 -1
  159. package/dist/esm-es5/taro-aweme-data-core.entry.js +1 -1
  160. package/dist/esm-es5/taro-camera-core.entry.js +1 -1
  161. package/dist/esm-es5/taro-canvas-core.entry.js +1 -1
  162. package/dist/esm-es5/taro-channel-live-core.entry.js +1 -1
  163. package/dist/esm-es5/taro-channel-video-core.entry.js +1 -1
  164. package/dist/esm-es5/taro-comment-detail-core.entry.js +1 -1
  165. package/dist/esm-es5/taro-comment-list-core.entry.js +1 -1
  166. package/dist/esm-es5/taro-components.js +1 -1
  167. package/dist/esm-es5/taro-contact-button-core.entry.js +1 -1
  168. package/dist/esm-es5/taro-editor-core.entry.js +1 -1
  169. package/dist/esm-es5/taro-follow-swan-core.entry.js +1 -1
  170. package/dist/esm-es5/taro-functional-page-navigator-core.entry.js +1 -1
  171. package/dist/esm-es5/taro-grid-view-core.entry.js +1 -1
  172. package/dist/esm-es5/taro-image-core.entry.js +1 -1
  173. package/dist/esm-es5/taro-inline-payment-panel-core.entry.js +1 -1
  174. package/dist/esm-es5/taro-keyboard-accessory-core.entry.js +1 -1
  175. package/dist/esm-es5/taro-lifestyle-core.entry.js +1 -1
  176. package/dist/esm-es5/taro-like-core.entry.js +1 -1
  177. package/dist/esm-es5/taro-list-view-core.entry.js +1 -1
  178. package/dist/esm-es5/taro-live-player-core.entry.js +1 -1
  179. package/dist/esm-es5/taro-live-pusher-core.entry.js +1 -1
  180. package/dist/esm-es5/taro-login-core.entry.js +1 -1
  181. package/dist/esm-es5/taro-lottie-core.entry.js +1 -1
  182. package/dist/esm-es5/taro-map-core.entry.js +1 -1
  183. package/dist/esm-es5/taro-match-media-core.entry.js +1 -1
  184. package/dist/esm-es5/taro-native-slot-core.entry.js +1 -1
  185. package/dist/esm-es5/taro-navigation-bar-core.entry.js +1 -1
  186. package/dist/esm-es5/taro-official-account-core.entry.js +1 -1
  187. package/dist/esm-es5/taro-open-data-core.entry.js +1 -1
  188. package/dist/esm-es5/taro-page-container-core.entry.js +1 -1
  189. package/dist/esm-es5/taro-page-meta-core.entry.js +1 -1
  190. package/dist/esm-es5/taro-picker-core_2.entry.js +1 -1
  191. package/dist/esm-es5/taro-picker-view-column-core_2.entry.js +1 -1
  192. package/dist/esm-es5/taro-pull-to-refresh-core.entry.js +1 -0
  193. package/dist/esm-es5/taro-root-portal-core.entry.js +1 -1
  194. package/dist/esm-es5/taro-rtc-room-core.entry.js +1 -1
  195. package/dist/esm-es5/taro-rtc-room-item-core.entry.js +1 -1
  196. package/dist/esm-es5/taro-scroll-view-core.entry.js +1 -1
  197. package/dist/esm-es5/taro-share-element-core.entry.js +1 -1
  198. package/dist/esm-es5/taro-slot-core.entry.js +1 -1
  199. package/dist/esm-es5/taro-snapshot-core.entry.js +1 -0
  200. package/dist/esm-es5/taro-sticky-header-core.entry.js +1 -1
  201. package/dist/esm-es5/taro-sticky-section-core.entry.js +1 -1
  202. package/dist/esm-es5/taro-swiper-core_2.entry.js +1 -1
  203. package/dist/esm-es5/taro-tab-item-core.entry.js +1 -1
  204. package/dist/esm-es5/taro-tabbar.entry.js +1 -1
  205. package/dist/esm-es5/taro-tabs-core.entry.js +1 -1
  206. package/dist/esm-es5/taro-video-control_3.entry.js +1 -1
  207. package/dist/esm-es5/taro-view-core.entry.js +1 -1
  208. package/dist/esm-es5/taro-voip-room-core.entry.js +1 -1
  209. package/dist/taro-components/p-00ed4bbb.entry.js +1 -0
  210. package/dist/taro-components/{p-9b6550fc.entry.js → p-065a10d7.entry.js} +1 -1
  211. package/dist/taro-components/p-06671eee.entry.js +1 -0
  212. package/dist/taro-components/p-08b7ecd7.system.entry.js +1 -0
  213. package/dist/taro-components/p-0a250d71.system.entry.js +1 -0
  214. package/dist/taro-components/{p-c39a46ca.system.entry.js → p-0cedad18.system.entry.js} +1 -1
  215. package/dist/taro-components/{p-b235e43c.entry.js → p-0e3b37e9.entry.js} +1 -1
  216. package/dist/taro-components/p-0e8199b7.entry.js +1 -0
  217. package/dist/taro-components/{p-cc164fa3.entry.js → p-0ec2e88a.entry.js} +1 -1
  218. package/dist/taro-components/{p-968b7c1d.entry.js → p-124ac21f.entry.js} +1 -1
  219. package/dist/taro-components/p-15624788.system.entry.js +1 -0
  220. package/dist/taro-components/p-1b789738.system.entry.js +1 -0
  221. package/dist/taro-components/p-1cf16dfa.entry.js +1 -0
  222. package/dist/taro-components/p-1f118969.system.entry.js +1 -0
  223. package/dist/taro-components/{p-898db637.system.entry.js → p-21c07cb3.system.entry.js} +1 -1
  224. package/dist/taro-components/{p-af9ef8b4.entry.js → p-22bf7daf.entry.js} +1 -1
  225. package/dist/taro-components/p-24d9836e.entry.js +1 -0
  226. package/dist/taro-components/p-29638de3.entry.js +1 -0
  227. package/dist/taro-components/p-2da9c8fd.entry.js +1 -0
  228. package/dist/taro-components/{p-5640e9f4.system.entry.js → p-3004e71a.system.entry.js} +1 -1
  229. package/dist/taro-components/{p-1974e52e.system.entry.js → p-32e9981a.system.entry.js} +1 -1
  230. package/dist/taro-components/{p-f534057e.system.entry.js → p-36d4407e.system.entry.js} +1 -1
  231. package/dist/taro-components/p-3f3abe55.system.entry.js +1 -0
  232. package/dist/taro-components/p-4cedbe5e.system.entry.js +1 -0
  233. package/dist/taro-components/{p-355e4dbc.entry.js → p-4fc40739.entry.js} +1 -1
  234. package/dist/taro-components/{p-6d4b7e5c.system.entry.js → p-519fbe84.system.entry.js} +1 -1
  235. package/dist/taro-components/{p-90333d0a.system.entry.js → p-5756cf00.system.entry.js} +1 -1
  236. package/dist/taro-components/{p-88d2b41b.system.entry.js → p-5870248f.system.entry.js} +1 -1
  237. package/dist/taro-components/{p-81f2ad70.system.entry.js → p-58cc2e6d.system.entry.js} +1 -1
  238. package/dist/taro-components/{p-9ac947ac.system.entry.js → p-5994d9f2.system.entry.js} +1 -1
  239. package/dist/taro-components/p-5e91398a.system.entry.js +1 -0
  240. package/dist/taro-components/{p-2d1b4dcc.system.entry.js → p-5ebc7010.system.entry.js} +1 -1
  241. package/dist/taro-components/p-600e89cc.system.entry.js +1 -0
  242. package/dist/taro-components/p-64eb91f7.entry.js +1 -0
  243. package/dist/taro-components/{p-137531b6.entry.js → p-69c43a81.entry.js} +1 -1
  244. package/dist/taro-components/p-6aa2ac6a.system.entry.js +1 -0
  245. package/dist/taro-components/{p-982bb5bf.entry.js → p-6b454506.entry.js} +1 -1
  246. package/dist/taro-components/{p-ebdd350f.system.entry.js → p-6cde54e5.system.entry.js} +1 -1
  247. package/dist/taro-components/{p-407ca16e.entry.js → p-76996fcb.entry.js} +1 -1
  248. package/dist/taro-components/p-7726b789.system.entry.js +1 -0
  249. package/dist/taro-components/{p-bdc30301.entry.js → p-7bfc5f3d.entry.js} +1 -1
  250. package/dist/taro-components/p-84958ace.entry.js +1 -0
  251. package/dist/taro-components/p-862b38b9.entry.js +1 -0
  252. package/dist/taro-components/p-8c3b906c.system.js +1 -0
  253. package/dist/taro-components/p-8ca82a56.entry.js +1 -0
  254. package/dist/taro-components/p-8ccaf5e8.entry.js +1 -0
  255. package/dist/taro-components/{p-0517f107.system.entry.js → p-8d990f1c.system.entry.js} +1 -1
  256. package/dist/taro-components/{p-07302165.system.entry.js → p-92d04741.system.entry.js} +1 -1
  257. package/dist/taro-components/p-99e16df8.entry.js +1 -0
  258. package/dist/taro-components/p-9b0298bf.entry.js +1 -0
  259. package/dist/taro-components/{p-fa0f6dab.system.entry.js → p-9d76d7a9.system.entry.js} +1 -1
  260. package/dist/taro-components/p-9dcba4a7.system.entry.js +1 -0
  261. package/dist/taro-components/p-9e03bc7a.system.entry.js +1 -0
  262. package/dist/taro-components/p-9ea4f297.entry.js +1 -0
  263. package/dist/taro-components/p-9eeba192.entry.js +1 -0
  264. package/dist/taro-components/p-9feff958.system.entry.js +1 -0
  265. package/dist/taro-components/p-a2141e85.system.entry.js +1 -0
  266. package/dist/taro-components/p-a2d590ad.entry.js +1 -0
  267. package/dist/taro-components/{p-204bd245.entry.js → p-a4951dd6.entry.js} +1 -1
  268. package/dist/taro-components/{p-46b8f89b.entry.js → p-a5a51112.entry.js} +1 -1
  269. package/dist/taro-components/p-a6e2dd48.entry.js +1 -0
  270. package/dist/taro-components/{p-66b0b419.system.entry.js → p-a74c970c.system.entry.js} +1 -1
  271. package/dist/taro-components/{p-e53508c1.system.entry.js → p-a7d31b01.system.entry.js} +1 -1
  272. package/dist/taro-components/p-a90221ab.system.entry.js +1 -0
  273. package/dist/taro-components/p-a94e3347.system.entry.js +1 -0
  274. package/dist/taro-components/p-aa04f605.entry.js +1 -0
  275. package/dist/taro-components/p-ad9b04e0.entry.js +1 -0
  276. package/dist/taro-components/{p-f11c9c37.system.entry.js → p-b07cd197.system.entry.js} +1 -1
  277. package/dist/taro-components/p-b0fc8752.entry.js +1 -0
  278. package/dist/taro-components/{p-139e6251.entry.js → p-b201ff38.entry.js} +1 -1
  279. package/dist/taro-components/p-bc541cd8.entry.js +1 -0
  280. package/dist/taro-components/{p-af8e521a.entry.js → p-bd4ed8b1.entry.js} +1 -1
  281. package/dist/taro-components/p-be96eb59.system.entry.js +1 -0
  282. package/dist/taro-components/{p-da239b8b.system.entry.js → p-bf0c8449.system.entry.js} +1 -1
  283. package/dist/taro-components/p-c0080d83.entry.js +1 -0
  284. package/dist/taro-components/p-c1a3fecf.system.entry.js +1 -0
  285. package/dist/taro-components/{p-8201ee31.system.entry.js → p-c913b635.system.entry.js} +1 -1
  286. package/dist/taro-components/{p-ce33f1f3.entry.js → p-c99e14b5.entry.js} +1 -1
  287. package/dist/taro-components/p-cb406f85.system.entry.js +1 -0
  288. package/dist/taro-components/p-cbcaad0e.system.entry.js +1 -0
  289. package/dist/taro-components/p-ccc64042.system.entry.js +1 -0
  290. package/dist/taro-components/p-ce303d12.system.entry.js +1 -0
  291. package/dist/taro-components/{p-7e998213.system.entry.js → p-d025a415.system.entry.js} +1 -1
  292. package/dist/taro-components/{p-6db97374.entry.js → p-d1756770.entry.js} +1 -1
  293. package/dist/taro-components/p-d2e0b15c.entry.js +1 -0
  294. package/dist/taro-components/p-d550aea9.system.entry.js +1 -0
  295. package/dist/taro-components/p-d5c8380d.system.entry.js +1 -0
  296. package/dist/taro-components/{p-5dab46cd.system.entry.js → p-d867e333.system.entry.js} +1 -1
  297. package/dist/taro-components/{p-50902cd0.entry.js → p-d9dcc6c6.entry.js} +1 -1
  298. package/dist/taro-components/p-da3db323.entry.js +1 -0
  299. package/dist/taro-components/{p-0114a2e4.entry.js → p-dadd02ca.entry.js} +1 -1
  300. package/dist/taro-components/p-dbdb9de9.js +1 -0
  301. package/dist/taro-components/{p-cc70bb7a.system.entry.js → p-dc5d65a0.system.entry.js} +1 -1
  302. package/dist/taro-components/{p-ab726c20.system.entry.js → p-de96861c.system.entry.js} +1 -1
  303. package/dist/taro-components/{p-907d9d01.system.entry.js → p-e2cd5dd3.system.entry.js} +1 -1
  304. package/dist/taro-components/{p-1404c119.entry.js → p-e598f47b.entry.js} +1 -1
  305. package/dist/taro-components/p-e740320c.entry.js +1 -0
  306. package/dist/taro-components/p-e976c6c9.system.entry.js +1 -0
  307. package/dist/taro-components/p-ea0d5d4f.system.entry.js +1 -0
  308. package/dist/taro-components/p-ed331c06.system.js +1 -1
  309. package/dist/taro-components/p-eee6e075.system.entry.js +1 -0
  310. package/dist/taro-components/p-ef322936.entry.js +1 -0
  311. package/dist/taro-components/p-f1304456.entry.js +1 -0
  312. package/dist/taro-components/{p-3d8c9dfb.entry.js → p-f2235cbb.entry.js} +1 -1
  313. package/dist/taro-components/{p-2af69b72.entry.js → p-f23cfdc8.entry.js} +1 -1
  314. package/dist/taro-components/p-f2c86846.entry.js +1 -0
  315. package/dist/taro-components/p-f4d86882.entry.js +1 -0
  316. package/dist/taro-components/{p-8c0b740e.entry.js → p-f658de2e.entry.js} +1 -1
  317. package/dist/taro-components/p-f78823a1.entry.js +1 -0
  318. package/dist/taro-components/{p-227e33fc.system.entry.js → p-fac4ce6f.system.entry.js} +1 -1
  319. package/dist/taro-components/p-fbb2446e.entry.js +1 -0
  320. package/dist/taro-components/taro-components.css +1 -1
  321. package/dist/taro-components/taro-components.esm.js +1 -1
  322. package/dist/types/components/canvas/canvas.d.ts +5 -2
  323. package/dist/types/components/picker-view/picker-view-column.d.ts +3 -3
  324. package/dist/types/components/picker-view/picker-view.d.ts +2 -0
  325. package/dist/types/components/scroll-view/scroll-view.d.ts +2 -0
  326. package/dist/types/components/snapshot/snapshot.d.ts +5 -0
  327. package/dist/types/components/swiper/swiper-item.d.ts +3 -0
  328. package/dist/types/components/swiper/swiper.d.ts +4 -3
  329. package/dist/types/components/tabbar/tabbar-item.d.ts +4 -4
  330. package/dist/types/components/tabbar/tabbar.d.ts +17 -16
  331. package/dist/types/components.d.ts +33 -15
  332. package/dist/types/utils/helper.d.ts +1 -0
  333. package/lib/react/component-lib/reactify-wc.js +1 -1
  334. package/lib/react/component-lib/reactify-wc.js.map +1 -1
  335. package/lib/react/components.d.ts +3 -2
  336. package/lib/react/components.js +4 -3
  337. package/lib/react/components.js.map +1 -1
  338. package/lib/react/index.js +1 -1
  339. package/lib/react/react-component-lib/createOverlayComponent.js.map +1 -1
  340. package/lib/react/react-component-lib/utils/attachProps.js +20 -1
  341. package/lib/react/react-component-lib/utils/attachProps.js.map +1 -1
  342. package/lib/vue2/components.d.ts +6 -2
  343. package/lib/vue2/components.js +10 -4
  344. package/lib/vue2/components.js.map +1 -1
  345. package/lib/vue2/index.js +1 -1
  346. package/lib/vue2/vue-component-lib/utils.js.map +1 -1
  347. package/lib/vue3/components.d.ts +6 -3
  348. package/lib/vue3/components.js +8 -4
  349. package/lib/vue3/components.js.map +1 -1
  350. package/lib/vue3/index.js +1 -1
  351. package/lib/vue3/vue-component-lib/utils.js.map +1 -1
  352. package/package.json +7 -7
  353. package/types/Button.d.ts +39 -8
  354. package/types/Camera.d.ts +1 -1
  355. package/types/Canvas.d.ts +12 -12
  356. package/types/ChannelVideo.d.ts +2 -2
  357. package/types/Checkbox.d.ts +10 -5
  358. package/types/CoverImage.d.ts +1 -1
  359. package/types/Form.d.ts +2 -2
  360. package/types/GridView.d.ts +1 -1
  361. package/types/Icon.d.ts +3 -3
  362. package/types/Image.d.ts +3 -2
  363. package/types/Input.d.ts +15 -15
  364. package/types/Label.d.ts +1 -1
  365. package/types/ListView.d.ts +1 -1
  366. package/types/LivePlayer.d.ts +11 -4
  367. package/types/Map.d.ts +46 -3
  368. package/types/NativeSlot.d.ts +5 -3
  369. package/types/NavigationBar.d.ts +7 -1
  370. package/types/Navigator.d.ts +1 -1
  371. package/types/PageMeta.d.ts +40 -0
  372. package/types/Picker.d.ts +20 -20
  373. package/types/PickerView.d.ts +1 -1
  374. package/types/PickerViewColumn.d.ts +1 -1
  375. package/types/Progress.d.ts +1 -1
  376. package/types/Radio.d.ts +10 -5
  377. package/types/RadioGroup.d.ts +1 -1
  378. package/types/ScrollView.d.ts +83 -5
  379. package/types/ShareElement.d.ts +1 -1
  380. package/types/Slider.d.ts +14 -14
  381. package/types/Slot.d.ts +5 -3
  382. package/types/Snapshot.d.ts +16 -0
  383. package/types/StickyHeader.d.ts +1 -1
  384. package/types/StickySection.d.ts +1 -1
  385. package/types/Swiper.d.ts +13 -9
  386. package/types/SwiperItem.d.ts +6 -1
  387. package/types/Switch.d.ts +5 -5
  388. package/types/Text.d.ts +2 -2
  389. package/types/Textarea.d.ts +8 -8
  390. package/types/Video.d.ts +28 -19
  391. package/types/common.d.ts +2 -1
  392. package/types/index.d.ts +8 -5
  393. package/types/index.vue3.d.ts +21 -7
  394. package/dist/cjs/helper-db78e01a.js +0 -19
  395. package/dist/esm/helper-3d0ecf0f.js +0 -13
  396. package/dist/esm-es5/helper-3d0ecf0f.js +0 -1
  397. package/dist/esm-es5/taro-pull-to-refresh.entry.js +0 -1
  398. package/dist/taro-components/p-052da7f0.system.entry.js +0 -1
  399. package/dist/taro-components/p-15e45ed6.system.js +0 -1
  400. package/dist/taro-components/p-1991cc1a.system.entry.js +0 -1
  401. package/dist/taro-components/p-1b3d41d3.system.entry.js +0 -1
  402. package/dist/taro-components/p-1c4e3899.entry.js +0 -1
  403. package/dist/taro-components/p-1f39576a.system.entry.js +0 -1
  404. package/dist/taro-components/p-2de2a3fd.system.entry.js +0 -1
  405. package/dist/taro-components/p-3094bda6.system.entry.js +0 -1
  406. package/dist/taro-components/p-416cc4dd.system.entry.js +0 -1
  407. package/dist/taro-components/p-469ee343.entry.js +0 -1
  408. package/dist/taro-components/p-478deb81.entry.js +0 -1
  409. package/dist/taro-components/p-486d0ec7.entry.js +0 -1
  410. package/dist/taro-components/p-53ef8a6c.system.entry.js +0 -1
  411. package/dist/taro-components/p-5613907c.entry.js +0 -1
  412. package/dist/taro-components/p-57b9943c.system.entry.js +0 -1
  413. package/dist/taro-components/p-5c1e6b1c.system.entry.js +0 -1
  414. package/dist/taro-components/p-6127b1b6.system.entry.js +0 -1
  415. package/dist/taro-components/p-66f7eea6.entry.js +0 -1
  416. package/dist/taro-components/p-69cd1f2a.system.entry.js +0 -1
  417. package/dist/taro-components/p-6a96da58.js +0 -1
  418. package/dist/taro-components/p-6cde180b.entry.js +0 -1
  419. package/dist/taro-components/p-6e115968.entry.js +0 -1
  420. package/dist/taro-components/p-6f84e936.entry.js +0 -1
  421. package/dist/taro-components/p-71b54f06.entry.js +0 -1
  422. package/dist/taro-components/p-79c3fde3.system.entry.js +0 -1
  423. package/dist/taro-components/p-7b3b8057.entry.js +0 -1
  424. package/dist/taro-components/p-7d635413.entry.js +0 -1
  425. package/dist/taro-components/p-801f09b8.entry.js +0 -1
  426. package/dist/taro-components/p-85a7daeb.system.entry.js +0 -1
  427. package/dist/taro-components/p-86280254.entry.js +0 -1
  428. package/dist/taro-components/p-9046110a.entry.js +0 -1
  429. package/dist/taro-components/p-904df510.entry.js +0 -1
  430. package/dist/taro-components/p-98f9f50f.system.entry.js +0 -1
  431. package/dist/taro-components/p-9aeb7995.entry.js +0 -1
  432. package/dist/taro-components/p-9d9ede17.system.entry.js +0 -1
  433. package/dist/taro-components/p-a20ecd3b.entry.js +0 -1
  434. package/dist/taro-components/p-a3a1a779.entry.js +0 -1
  435. package/dist/taro-components/p-a4882902.system.entry.js +0 -1
  436. package/dist/taro-components/p-a8565231.entry.js +0 -1
  437. package/dist/taro-components/p-a8925584.system.entry.js +0 -1
  438. package/dist/taro-components/p-a8e7cf87.entry.js +0 -1
  439. package/dist/taro-components/p-af3fa859.system.entry.js +0 -1
  440. package/dist/taro-components/p-afb3895c.system.entry.js +0 -1
  441. package/dist/taro-components/p-b027181b.entry.js +0 -1
  442. package/dist/taro-components/p-b4ea72ea.entry.js +0 -1
  443. package/dist/taro-components/p-b4f3d0ab.entry.js +0 -1
  444. package/dist/taro-components/p-b6d4634f.system.entry.js +0 -1
  445. package/dist/taro-components/p-ba3b2aa5.system.entry.js +0 -1
  446. package/dist/taro-components/p-bcf80126.system.entry.js +0 -1
  447. package/dist/taro-components/p-c1073ed6.system.entry.js +0 -1
  448. package/dist/taro-components/p-c11a42e0.entry.js +0 -1
  449. package/dist/taro-components/p-c4b8851b.entry.js +0 -1
  450. package/dist/taro-components/p-d34a6c04.entry.js +0 -1
  451. package/dist/taro-components/p-e33f3592.entry.js +0 -1
  452. package/dist/taro-components/p-e3480c4c.entry.js +0 -1
  453. package/dist/taro-components/p-eaa370a9.system.entry.js +0 -1
  454. package/dist/taro-components/p-f7927285.system.entry.js +0 -1
  455. package/dist/taro-components/p-f7b32c6b.entry.js +0 -1
  456. package/dist/taro-components/p-fa6c022a.system.entry.js +0 -1
  457. package/dist/taro-components/p-fb983850.entry.js +0 -1
@@ -1 +1 @@
1
- import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-3d0ecf0f.js";import"@tarojs/taro";var TabItem=function(){function t(t){registerInstance(this,t)}t.prototype.componentDidLoad=function(){notSupport("TabItem",this)};t.prototype.render=function(){return h(Host,null)};return t}();export{TabItem as taro_tab_item_core};
1
+ import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-8a85bb65.js";import"@tarojs/taro";var TabItem=function(){function t(t){registerInstance(this,t)}t.prototype.componentDidLoad=function(){notSupport("TabItem",this)};t.prototype.render=function(){return h(Host,null)};return t}();export{TabItem as taro_tab_item_core};
@@ -1 +1 @@
1
- var __spreadArray=this&&this.__spreadArray||function(e,t,a){if(a||arguments.length===2)for(var r=0,o=t.length,n;r<o;r++){if(n||!(r in t)){if(!n)n=Array.prototype.slice.call(t,0,r);n[r]=t[r]}}return e.concat(n||Array.prototype.slice.call(t))};import{h,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-980f930f.js";import Taro from"@tarojs/taro";import{c as classnames}from"./index-c3e4004b.js";import{i as isVisible}from"./index-d1b03e47.js";var splitUrl=function(e){var t=e||"";var a;var r={path:null,query:null,fragment:null};a=t.indexOf("#");if(a>-1){r.fragment=t.substring(a+1);t=t.substring(0,a)}a=t.indexOf("?");if(a>-1){r.query=t.substring(a+1);t=t.substring(0,a)}r.path=t;return r};var addLeadingSlash=function(e){if(e===void 0){e=""}return e.charAt(0)==="/"?e:"/"+e};var hasBasename=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return new RegExp("^"+t+"(\\/|\\?|#|$)","i").test(e)||e===t};var stripBasename=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return hasBasename(e,t)?e.substring(t.length):e};var stripSuffix=function(e,t){if(e===void 0){e=""}if(t===void 0){t=""}return e.includes(t)?e.substring(0,e.length-t.length):e};var getCurrentPage=function(e,t){if(e===void 0){e="hash"}if(t===void 0){t="/"}var a=e==="hash"?location.hash.slice(1).split("?")[0]:location.pathname;return addLeadingSlash(stripBasename(a,t))};function isAbsolute(e){return e.charAt(0)==="/"}function spliceOne(e,t){for(var a=t,r=a+1,o=e.length;r<o;a+=1,r+=1){e[a]=e[r]}e.pop()}function resolvePathname(e,t){if(t===undefined)t="";var a=e&&e.split("/")||[];var r=t&&t.split("/")||[];var o=e&&isAbsolute(e);var n=t&&isAbsolute(t);var i=o||n;if(e&&isAbsolute(e)){r=a}else if(a.length){r.pop();r=r.concat(a)}if(!r.length)return"/";var s;if(r.length){var l=r[r.length-1];s=l==="."||l===".."||l===""}else{s=false}var d=0;for(var b=r.length;b>=0;b--){var h=r[b];if(h==="."){spliceOne(r,b)}else if(h===".."){spliceOne(r,b);d++}else if(d){spliceOne(r,b);d--}}if(!i)for(;d--;d)r.unshift("..");if(i&&r[0]!==""&&(!r[0]||!isAbsolute(r[0])))r.unshift("");var c=r.join("/");if(s&&c.substr(-1)!=="/")c+="/";return c}var TabbarItem=function(e){var t=e.index,a=e.isSelected,r=a===void 0?false:a,o=e.textColor,n=e.iconPath,i=e.badgeText,s=e.showRedDot,l=s===void 0?false:s,d=e.pagePath,b=e.text,c=e.onSelect;var f=classnames("weui-tabbar__item",{"weui-bar__item_on":r});var u={position:"absolute",top:"-2px",right:"-13px"};var v={position:"absolute",top:"0",right:"-6px"};function g(){var e=Taro.getCurrentPages().shift();if(typeof(e===null||e===void 0?void 0:e.onTabItemTap)==="function"&&isVisible(this)){e.onTabItemTap({index:t,pagePath:d,text:b})}c(t)}return h("a",{key:t,href:"javascript:;",class:f,onClick:g},h("span",{style:{display:"inline-block",position:"relative"}},h("img",{src:n,alt:"",class:"weui-tabbar__icon"}),!!i&&h("span",{class:"weui-badge taro-tabbar-badge",style:u},i),l&&h("span",{class:"weui-badge weui-badge_dot",style:v})),h("p",{class:"weui-tabbar__label",style:{color:o}},b))};var indexCss="html,body{height:100%}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:50px;-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var STATUS_SHOW=0;var STATUS_HIDE=1;var STATUS_SLIDEOUT=2;var basicTabBarClassName="taro-tabbar__tabbar";var hideTabBarClassName="taro-tabbar__tabbar-hide";var hideTabBarWithAnimationClassName="taro-tabbar__tabbar-slideout";var Tabbar=function(){function e(e){var t=this;registerInstance(this,e);this.onLongPress=createEvent(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=function(e){var a=t.customRoutes.filter((function(t){var a=t[1];var r=splitUrl(a).path;var o=splitUrl(e).path;return r===o}));return stripSuffix(a.length?a[0][0]:e,".html")};this.getSelectedIndex=function(e){var a=-1;t.list.forEach((function(t,r){var o=t.pagePath;var n=splitUrl(e).path;var i=splitUrl(o).path;if(n===i){a=r}}));return a};this.switchTab=function(e){t.selectedIndex=e;Taro.switchTab({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var a=e.url,r=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=resolvePathname(a,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);r({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'.concat(i,'" is not found')})}};this.routerChangeHandler=function(e){var a;var r=(a=e===null||e===void 0?void 0:e.toLocation)===null||a===void 0?void 0:a.path;var o;if(typeof r==="string"){var n=t.conf.basename||"/";o=stripBasename(addLeadingSlash(r||t.homePage),n)||"/"}else{o=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(o))};this.setTabBarBadgeHandler=function(e){var a=e.index,r=e.text,o=e.successHandler,n=e.errorHandler;var i=__spreadArray([],t.list,true);if(a in i){i[a].showRedDot=false;i[a].badgeText=r;o({errMsg:"setTabBarBadge:ok"})}else{n({errMsg:"setTabBarBadge:fail tabbar item not found"})}t.list=i};this.removeTabBarBadgeHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].badgeText=null;r({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}t.list=n};this.showTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].showRedDot=true;r({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}t.list=n};this.hideTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].showRedDot=false;r({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}t.list=n};this.showTabBarHandler=function(e){var a=e.successHandler;t.status=STATUS_SHOW;a({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var a=e.animation,r=e.successHandler;t.status=a?STATUS_SLIDEOUT:STATUS_HIDE;r({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=function(e){var a=e.color,r=e.selectedColor,o=e.backgroundColor,n=e.borderStyle,i=e.successHandler;if(o)t.backgroundColor=o;if(n)t.borderStyle=n;if(a)t.color=a;if(r)t.selectedColor=r;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=function(e){var a=e.index,r=e.iconPath,o=e.selectedIconPath,n=e.text,i=e.successHandler,s=e.errorHandler;var l=__spreadArray([],t.list,true);if(a in l){if(r)l[a].iconPath=r;if(o)l[a].selectedIconPath=o;if(n)l[a].text=n;i({errMsg:"setTabBarItem:ok"})}else{s({errMsg:"setTabBarItem:fail tabbar item not found"})}t.list=l};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=STATUS_SHOW}e.prototype.componentWillLoad=function(){var e,t;var a=((e=this.conf)===null||e===void 0?void 0:e.list)||[];var r=((t=this.conf)===null||t===void 0?void 0:t.customRoutes)||{};if(Object.prototype.toString.call(a)!=="[object Array]"||a.length<2||a.length>5){throw new Error("tabBar 配置错误")}this.homePage=addLeadingSlash(this.conf.homePage);var o=function(e){var t;var a=r[e];e=addLeadingSlash(e);if(typeof a==="string"){n.customRoutes.push([e,addLeadingSlash(a)])}else if((a===null||a===void 0?void 0:a.length)>0){(t=n.customRoutes).push.apply(t,a.map((function(t){return[e,addLeadingSlash(t)]})))}};var n=this;for(var i in r){o(i)}a.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=a;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor};e.prototype.getCurrentUrl=function(){var e=getCurrentPage(this.conf.mode,this.conf.basename);return decodeURI(e==="/"?this.homePage:e)};e.prototype.bindEvent=function(){Taro.eventCenter.on("__taroRouterChange",this.routerChangeHandler);Taro.eventCenter.on("__taroSwitchTab",this.switchTabHandler);Taro.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);Taro.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);Taro.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);Taro.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);Taro.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);Taro.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);Taro.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);Taro.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.removeEvent=function(){Taro.eventCenter.off("__taroRouterChange",this.routerChangeHandler);Taro.eventCenter.off("__taroSwitchTab",this.switchTabHandler);Taro.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);Taro.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);Taro.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);Taro.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);Taro.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);Taro.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);Taro.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);Taro.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,t;var a=this;var r=this.tabbarPos,o=r===void 0?"bottom":r;var n=this.status;var i=classnames("weui-tabbar",(e={},e["taro-tabbar__border-".concat(this.borderStyle||"black")]=true,e));var s=this.selectedIndex===-1||n===STATUS_HIDE;var l=n===STATUS_SLIDEOUT;return h(Host,{class:classnames(basicTabBarClassName,"".concat(basicTabBarClassName,"-").concat(o),(t={},t[hideTabBarClassName]=s,t[hideTabBarWithAnimationClassName]=l,t))},h("div",{class:i,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map((function(e,t){var r=a.selectedIndex===t;var o;var n;if(r){o=a.selectedColor||"";n=e.selectedIconPath}else{o=a.color||"";n=e.iconPath}return h(TabbarItem,{index:t,onSelect:a.switchTab.bind(a),isSelected:r,textColor:o,iconPath:n,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();Tabbar.style=indexCss;export{Tabbar as taro_tabbar};
1
+ var __spreadArray=this&&this.__spreadArray||function(e,t,a){if(a||arguments.length===2)for(var r=0,o=t.length,n;r<o;r++){if(n||!(r in t)){if(!n)n=Array.prototype.slice.call(t,0,r);n[r]=t[r]}}return e.concat(n||Array.prototype.slice.call(t))};import{h,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-980f930f.js";import Taro from"@tarojs/taro";import{stripSuffix,stripBasename,addLeadingSlash,getCurrentPage}from"@tarojs/router/dist/utils";import{c as classnames}from"./index-c3e4004b.js";import{i as isVisible}from"./index-d1b03e47.js";var splitUrl=function(e){var t=e||"";var a;var r={path:null,query:null,fragment:null};a=t.indexOf("#");if(a>-1){r.fragment=t.substring(a+1);t=t.substring(0,a)}a=t.indexOf("?");if(a>-1){r.query=t.substring(a+1);t=t.substring(0,a)}r.path=t;return r};function isAbsolute(e){return e.charAt(0)==="/"}function spliceOne(e,t){for(var a=t,r=a+1,o=e.length;r<o;a+=1,r+=1){e[a]=e[r]}e.pop()}function resolvePathname(e,t){if(t===undefined)t="";var a=e&&e.split("/")||[];var r=t&&t.split("/")||[];var o=e&&isAbsolute(e);var n=t&&isAbsolute(t);var i=o||n;if(e&&isAbsolute(e)){r=a}else if(a.length){r.pop();r=r.concat(a)}if(!r.length)return"/";var s;if(r.length){var l=r[r.length-1];s=l==="."||l===".."||l===""}else{s=false}var d=0;for(var b=r.length;b>=0;b--){var h=r[b];if(h==="."){spliceOne(r,b)}else if(h===".."){spliceOne(r,b);d++}else if(d){spliceOne(r,b);d--}}if(!i)for(;d--;d)r.unshift("..");if(i&&r[0]!==""&&(!r[0]||!isAbsolute(r[0])))r.unshift("");var c=r.join("/");if(s&&c.substr(-1)!=="/")c+="/";return c}var TabbarItem=function(e){var t=e.index,a=e.isSelected,r=a===void 0?false:a,o=e.textColor,n=e.iconPath,i=e.badgeText,s=e.showRedDot,l=s===void 0?false:s,d=e.pagePath,b=e.text,c=e.onSelect;var f=classnames("weui-tabbar__item",{"weui-bar__item_on":r});var u={position:"absolute",top:"-2px",right:"-13px"};var v={position:"absolute",top:"0",right:"-6px"};function g(){var e=Taro.getCurrentPages().shift();if(typeof(e===null||e===void 0?void 0:e.onTabItemTap)==="function"&&isVisible(this)){e.onTabItemTap({index:t,pagePath:d,text:b})}c(t)}return h("a",{key:t,href:"javascript:;",class:f,onClick:g},h("span",{style:{display:"inline-block",position:"relative"}},h("img",{src:n,alt:"",class:"weui-tabbar__icon"}),!!i&&h("span",{class:"weui-badge taro-tabbar-badge",style:u},i),l&&h("span",{class:"weui-badge weui-badge_dot",style:v})),h("p",{class:"weui-tabbar__label",style:{color:o}},b))};var indexCss="html,body{height:100%}:root{--taro-tabbar-height:50px}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:var(--taro-tabbar-height);-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var STATUS_SHOW=0;var STATUS_HIDE=1;var STATUS_SLIDEOUT=2;var basicTabBarClassName="taro-tabbar__tabbar";var hideTabBarClassName="taro-tabbar__tabbar-hide";var hideTabBarWithAnimationClassName="taro-tabbar__tabbar-slideout";var Tabbar=function(){function e(e){var t=this;registerInstance(this,e);this.onLongPress=createEvent(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=function(e){var a=t.customRoutes.filter((function(t){var a=t[1];var r=splitUrl(a).path;var o=splitUrl(e).path;return r===o}));return stripSuffix(a.length?a[0][0]:e,".html")};this.getSelectedIndex=function(e){var a=-1;t.list.forEach((function(t,r){var o=t.pagePath;var n=splitUrl(e).path;var i=splitUrl(o).path;if(n===i){a=r}}));return a};this.switchTab=function(e){t.selectedIndex=e;Taro.switchTab({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var a=e.url,r=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=resolvePathname(a,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);r({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'.concat(i,'" is not found')})}};this.routerChangeHandler=function(e){var a;var r=(a=e===null||e===void 0?void 0:e.toLocation)===null||a===void 0?void 0:a.path;var o;if(typeof r==="string"){var n=t.conf.basename||"/";o=stripBasename(addLeadingSlash(r||t.homePage),n)||"/"}else{o=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(o))};this.setTabBarBadgeHandler=function(e){var a=e.index,r=e.text,o=e.successHandler,n=e.errorHandler;var i=__spreadArray([],t.list,true);if(a in i){i[a].showRedDot=false;i[a].badgeText=r;o({errMsg:"setTabBarBadge:ok"})}else{n({errMsg:"setTabBarBadge:fail tabbar item not found"})}t.list=i};this.removeTabBarBadgeHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].badgeText=null;r({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}t.list=n};this.showTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].showRedDot=true;r({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}t.list=n};this.hideTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].showRedDot=false;r({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}t.list=n};this.showTabBarHandler=function(e){var a=e.successHandler;t.status=STATUS_SHOW;a({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var a=e.animation,r=e.successHandler;t.status=a?STATUS_SLIDEOUT:STATUS_HIDE;r({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=function(e){var a=e.color,r=e.selectedColor,o=e.backgroundColor,n=e.borderStyle,i=e.successHandler;if(o)t.backgroundColor=o;if(n)t.borderStyle=n;if(a)t.color=a;if(r)t.selectedColor=r;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=function(e){var a=e.index,r=e.iconPath,o=e.selectedIconPath,n=e.text,i=e.successHandler,s=e.errorHandler;var l=__spreadArray([],t.list,true);if(a in l){if(r)l[a].iconPath=r;if(o)l[a].selectedIconPath=o;if(n)l[a].text=n;i({errMsg:"setTabBarItem:ok"})}else{s({errMsg:"setTabBarItem:fail tabbar item not found"})}t.list=l};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=STATUS_SHOW}e.prototype.componentWillLoad=function(){var e,t;var a=((e=this.conf)===null||e===void 0?void 0:e.list)||[];var r=((t=this.conf)===null||t===void 0?void 0:t.customRoutes)||{};if(Object.prototype.toString.call(a)!=="[object Array]"||a.length<2||a.length>5){throw new Error("tabBar 配置错误")}this.homePage=addLeadingSlash(this.conf.homePage);var o=function(e){var t;var a=r[e];e=addLeadingSlash(e);if(typeof a==="string"){n.customRoutes.push([e,addLeadingSlash(a)])}else if((a===null||a===void 0?void 0:a.length)>0){(t=n.customRoutes).push.apply(t,a.map((function(t){return[e,addLeadingSlash(t)]})))}};var n=this;for(var i in r){o(i)}a.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=a;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor};e.prototype.getCurrentUrl=function(){var e=getCurrentPage(this.conf.mode,this.conf.basename);return decodeURI(e==="/"?this.homePage:e)};e.prototype.bindEvent=function(){Taro.eventCenter.on("__taroRouterChange",this.routerChangeHandler);Taro.eventCenter.on("__taroSwitchTab",this.switchTabHandler);Taro.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);Taro.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);Taro.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);Taro.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);Taro.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);Taro.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);Taro.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);Taro.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.removeEvent=function(){Taro.eventCenter.off("__taroRouterChange",this.routerChangeHandler);Taro.eventCenter.off("__taroSwitchTab",this.switchTabHandler);Taro.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);Taro.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);Taro.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);Taro.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);Taro.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);Taro.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);Taro.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);Taro.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,t;var a=this;var r=this.tabbarPos,o=r===void 0?"bottom":r;var n=this.status;var i=classnames("weui-tabbar",(e={},e["taro-tabbar__border-".concat(this.borderStyle||"black")]=true,e));var s=this.selectedIndex===-1||n===STATUS_HIDE;var l=n===STATUS_SLIDEOUT;return h(Host,{class:classnames(basicTabBarClassName,"".concat(basicTabBarClassName,"-").concat(o),(t={},t[hideTabBarClassName]=s,t[hideTabBarWithAnimationClassName]=l,t))},h("div",{class:i,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map((function(e,t){var r=a.selectedIndex===t;var o;var n;if(r){o=a.selectedColor||"";n=e.selectedIconPath}else{o=a.color||"";n=e.iconPath}return h(TabbarItem,{index:t,onSelect:a.switchTab.bind(a),isSelected:r,textColor:o,iconPath:n,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();Tabbar.style=indexCss;export{Tabbar as taro_tabbar};
@@ -1 +1 @@
1
- import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-3d0ecf0f.js";import"@tarojs/taro";var Tabs=function(){function t(t){registerInstance(this,t)}t.prototype.componentDidLoad=function(){notSupport("Tabs",this)};t.prototype.render=function(){return h(Host,null)};return t}();export{Tabs as taro_tabs_core};
1
+ import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-8a85bb65.js";import"@tarojs/taro";var Tabs=function(){function t(t){registerInstance(this,t)}t.prototype.componentDidLoad=function(){notSupport("Tabs",this)};t.prototype.render=function(){return h(Host,null)};return t}();export{Tabs as taro_tabs_core};
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,i,r){function n(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,o){function s(e){try{l(r.next(e))}catch(e){o(e)}}function a(e){try{l(r["throw"](e))}catch(e){o(e)}}function l(e){e.done?i(e.value):n(e.value).then(s,a)}l((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,n,o,s;return s={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(e){return function(t){return l([e,t])}}function l(a){if(r)throw new TypeError("Generator is already executing.");while(s&&(s=0,a[0]&&(i=0)),i)try{if(r=1,n&&(o=a[0]&2?n["return"]:a[0]?n["throw"]||((o=n["return"])&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;if(n=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;n=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(o=i.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){i.label=a[1];break}if(a[0]===6&&i.label<o[1]){i.label=o[1];o=a;break}if(o&&i.label<o[2]){i.label=o[2];i.ops.push(a);break}if(o[2])i.ops.pop();i.trys.pop();continue}a=t.call(e,i)}catch(e){a=[6,e];n=0}finally{r=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var r=0,n=t.length,o;r<n;r++){if(o||!(r in t)){if(!o)o=Array.prototype.slice.call(t,0,r);o[r]=t[r]}}return e.concat(o||Array.prototype.slice.call(t))};import{r as registerInstance,h,H as Host,g as getElement,c as createEvent}from"./index-980f930f.js";import{c as classnames}from"./index-c3e4004b.js";import{t as throttle}from"./index-d1b03e47.js";var formatTime=function(e){if(!e)return"";var t=Math.round(e%60);var i=Math.round((e-t)/60);return"".concat(i<10?"0".concat(i):i,":").concat(t<10?"0".concat(t):t)};var calcDist=function(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))};var normalizeNumber=function(e){return Math.max(-1,Math.min(e,1))};var scene="default";var screenFn=function(){var e;var t=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];var i=["webkitEnterFullscreen","webkitExitFullscreen","webkitCurrentFullScreenElement","webkitSupportsFullscreen","fullscreenchange","fullscreenerror"];var r=0;var n=t.length;var o={};for(;r<n;r++){e=t[r];if(e&&e[1]in document){for(r=0;r<e.length;r++){o[t[0][r]]=e[r]}return o}}if(!o[t[0][0]]){scene="iOS";for(r=0;r<i.length;r++){o[t[0][r]]=i[r]}}return o}();var isHls=function(e){return/\.(m3u8)($|\?)/i.test(e)};var VideoControl=function(){function e(e){var t=this;registerInstance(this,e);this.visible=false;this.isDraggingProgressBall=false;this.percentage=0;this.progressDimensions={left:0,width:0};this.calcPercentage=function(e){var i=e-t.progressDimensions.left;i=Math.max(i,0);i=Math.min(i,t.progressDimensions.width);return i/t.progressDimensions.width};this.onDragProgressBallStart=function(){t.isDraggingProgressBall=true;t.hideControlsTimer&&clearTimeout(t.hideControlsTimer)};this.onClickProgress=function(e){e.stopPropagation();var i=t.calcPercentage(e.pageX);t.seekFunc(i*t.duration);t.toggleVisibility(true)};this.controls=undefined;this.currentTime=undefined;this.duration=undefined;this.isPlaying=undefined;this.pauseFunc=undefined;this.playFunc=undefined;this.seekFunc=undefined;this.showPlayBtn=undefined;this.showProgress=undefined}e.prototype.onDocumentTouchMove=function(e){if(!this.isDraggingProgressBall)return;var t=e.touches[0].pageX;this.percentage=this.calcPercentage(t);this.setProgressBall(this.percentage);this.setCurrentTime(this.percentage*this.duration)};e.prototype.onDocumentTouchEnd=function(){if(!this.isDraggingProgressBall)return;this.isDraggingProgressBall=false;this.seekFunc(this.percentage*this.duration);this.toggleVisibility(true)};e.prototype.setProgressBall=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){if(this.progressBallRef){this.progressBallRef.style.left="".concat(e*100,"%")}return[2]}))}))};e.prototype.toggleVisibility=function(e){return __awaiter(this,void 0,void 0,(function(){var t;var i=this;return __generator(this,(function(r){t=e===undefined?!this.visible:e;if(t){this.hideControlsTimer&&clearTimeout(this.hideControlsTimer);if(this.isPlaying){this.hideControlsTimer=setTimeout((function(){i.toggleVisibility(false)}),2e3)}this.el.style.visibility="visible"}else{this.el.style.visibility="hidden"}this.visible=!!t;return[2]}))}))};e.prototype.getIsDraggingProgressBall=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.isDraggingProgressBall]}))}))};e.prototype.setCurrentTime=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.currentTimeRef.innerHTML=formatTime(e);return[2]}))}))};e.prototype.render=function(){var e=this;var t=this,i=t.controls,r=t.currentTime,n=t.duration,o=t.isPlaying,s=t.pauseFunc,a=t.playFunc,l=t.showPlayBtn,u=t.showProgress;var c=formatTime(n);var d;if(!l){d=null}else if(o){d=h("div",{class:"taro-video-control-button taro-video-control-button-pause",onClick:s})}else{d=h("div",{class:"taro-video-control-button taro-video-control-button-play",onClick:a})}return h(Host,{class:"taro-video-bar taro-video-bar-full"},i&&h("div",{class:"taro-video-controls"},d,u&&h("div",{class:"taro-video-current-time",ref:function(t){return e.currentTimeRef=t}},formatTime(r)),u&&h("div",{class:"taro-video-progress-container",onClick:this.onClickProgress},h("div",{class:"taro-video-progress",ref:function(t){if(!t)return;var i=t.getBoundingClientRect();e.progressDimensions.left=i.left;e.progressDimensions.width=i.width}},h("div",{class:"taro-video-progress-buffered",style:{width:"100%"}}),h("div",{class:"taro-video-ball",ref:function(t){return e.progressBallRef=t},onTouchStart:this.onDragProgressBallStart,style:{left:"".concat(c?this.currentTime/n*100:0,"%")}},h("div",{class:"taro-video-inner"})))),u&&h("div",{class:"taro-video-duration"},c)),h("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();var indexCss='.taro-video{display:inline-block;overflow:hidden;position:relative;width:100%;height:225px;line-height:0}.taro-video[hidden]{display:none}.taro-video-container{display:inline-block;position:absolute;left:0;top:0;width:100%;height:100%;background-color:#000;-o-object-position:inherit;object-position:inherit}.taro-video-container.taro-video-type-fullscreen{position:fixed;left:0;right:0;top:0;bottom:0;z-index:999}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-left{-webkit-transform:translate(-50%, -50%) rotate(-90deg);transform:translate(-50%, -50%) rotate(-90deg)}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-right{-webkit-transform:translate(-50%, -50%) rotate(90deg);transform:translate(-50%, -50%) rotate(90deg)}.taro-video-video{width:100%;height:100%;-o-object-position:inherit;object-position:inherit}.taro-video-cover{display:-ms-flexbox;display:flex;position:absolute;left:0;top:0;bottom:0;z-index:1;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;width:100%;background-color:rgba(1, 1, 1, 0.5);-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-box-pack:center;-webkit-box-align:center}.taro-video-cover-play-button{width:40px;height:40px;background-repeat:no-repeat;background-position:50% 50%;background-size:50%}.taro-video-cover-duration{margin-top:10px;line-height:1;font-size:16px;color:#fff}.taro-video-bar{display:-ms-flexbox;display:flex;visibility:hidden;overflow:hidden;position:absolute;right:0;bottom:0;z-index:1;-ms-flex-align:center;align-items:center;padding:0 10px;height:44px;background-color:rgba(0, 0, 0, 0.5);-webkit-box-align:center}.taro-video-bar.taro-video-bar-full{left:0}.taro-video-controls{display:-ms-flexbox;display:flex;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:0 8.5px}.taro-video-control-button{-webkit-box-sizing:content-box;box-sizing:content-box;margin-left:-8.5px;padding:14.5px 12.5px;width:13px;height:15px}.taro-video-control-button::after{display:block;width:100%;height:100%;background-repeat:no-repeat;background-position:50% 50%;background-size:100%;content:""}.taro-video-control-button.taro-video-control-button-play::after,.taro-video-cover-play-button{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAeCAYAAAAy2w7YAAAAAXNSR0IArs4c6QAAAWhJREFUSA1j+P///0cgBoHjQGzCQCsAtgJB/AMy5wCxGNXtQ9iBwvoA5BUCMQvVLEQxHpNzDSjkRhXLMM3GKrIeKKpEkYVYjcUu+AMo3ALE3GRZiN1MvKKPgbIRJFuG10j8koeA0gZEW4jfLIKyf4EqpgOxMEELCRpFnIJ3QGU5QMyM00LizCFa1SWgSkeslhFtBGkKVwGVy6FYSJp+klR/A6quB2JOkIWMIK0oNlOf8xBoZDE9LAI7nYn6HsBq4l96WHQEaLUpAyiOaASeAM2NgvuPBpaACt82IEYtfKls0UagecpwXyAzqGTRdaA57sjmYrAptAjUsCkGYlYMg9EFyLQI1IiZB8Ti6Obh5JNh0QmgHlOcBuKSIMGi50C18UDMiMssvOJEWPQLqKYbiHnxGkRIkoBF24DyaoTMIEoeh0W3geI+RBlArCI0iz4D+RVAzEasfqLVAQ19AcSg5LoYiKWI1kiiQgCMBLnEEcfDSgAAAABJRU5ErkJggg==")}.taro-video-control-button.taro-video-control-button-pause::after{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAAgCAYAAAAffCjxAAAAAXNSR0IArs4c6QAAAFlJREFUSA3tksEKACAIQ7X//5zq98wOgQayum8QaGweHhMzG/6OujzKAymn+0LMqivu1XznWmX8/echTIyMyAgTwA72iIwwAexgj8gIE8CO3aMRbDPMaEy5BRGaKcZv8YxRAAAAAElFTkSuQmCC")}.taro-video-current-time,.taro-video-duration{margin-top:15px;margin-bottom:14.5px;height:14.5px;line-height:14.5px;font-size:12px;color:#cbcbcb}.taro-video-progress-container{position:relative;-ms-flex-positive:2;flex-grow:2;-webkit-box-flex:2}.taro-video-progress{position:relative;margin:21px 12px;height:2px;background-color:rgba(255, 255, 255, 0.4)}.taro-video-progress-buffered{position:absolute;left:0;top:0;width:0;height:100%;background-color:rgba(255, 255, 255, 0.8);-webkit-transition:width 0.1s;transition:width 0.1s}.taro-video-ball{position:absolute;left:0;top:-21px;-webkit-box-sizing:content-box;box-sizing:content-box;margin-left:-22px;padding:14px;width:16px;height:16px}.taro-video-inner{border-radius:50%;width:100%;height:100%;background-color:#fff}.taro-video-danmu-button{margin:0 8.5px;padding:2px 10px;border:1px solid #fff;border-radius:5px;line-height:1;font-size:13px;color:#fff;white-space:nowrap}.taro-video-danmu-button.taro-video-danmu-button-active{border-color:#48c23d;color:#48c23d}.taro-video-fullscreen,.taro-video-mute{-webkit-box-sizing:content-box;box-sizing:content-box;padding:8.5px;width:17px;height:17px;background-repeat:no-repeat;background-position:50% 50%;background-size:50%}.taro-video-fullscreen{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAhUlEQVRYR+2WSwrAMAhEnZO3PfmULLooGEFTiIXJ2s/kRY2wzQeb85sE9CRA8jSzY1YfAFzhJBnU1AVgxH2dSiArCnD9QgGzRNnOech48SRABHoSyFb5in3PSbhyo6yvCPQkEM3u7BsPe/0FIvBfAh/vhKmVbO9SWun1qk/PSVi9TcVPBG6R1YIhgWwNpQAAAABJRU5ErkJggg==")}.taro-video-fullscreen.taro-video-type-fullscreen{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAABPUlEQVRYR+2Xu0pDURBF1/ZLxNcHKNiIlfhA7C0UBSEE8RNEBNFPUEQEEbGxFiSSSrCwEH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1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5PmxYVAAACLklEQVRYhc2XP2sVQRRHz40hKoqaQgVBCy1EozFlGiVFxMLGh4piYWEh+hkEP4YKAVFEEFTyughaCH6DqIVpAhYWEgIxoJE8cywyi5tNHu/tJmvyg2WZO3dmzt47/zZUtoJ6Nhsg09YDiYhKDzACTAFNYH9lEpUq80TdrT5wpV5n/ZV9KoGoo+pXV2uyKkipOaLuUceAt8DhUvQd1FsCYhR4ChzaSIBMHSOi7lOfsByFWiCgEBH1GHAF2JlMPcBt4GC3HUYEaj9wF3gVEVPtfNVTwAXgWX7CDKq/1piAZTSZBmim8qJ6sQ3EgDqb/L7kU3MH2NHtl3dQX3r3Ak21UYAYAj4A/cl0JB+RF+uMRj4iQ+p8zt7KYFLdXKHuRi0gacBhV6a6pd5bA6KRNagFJPU9qv5u47toLmW1HnoR8Q5oAK1CVQu4FBHj/wUkaXsb+4pzpVaQFPqXrN7Be4Fx9VztIOr1BLEtmX4A94E/qdwHTKjDWYM6lu81dSlnn3V570BtuLxaMs2rZ/IgYxsBovaoPwsQA4VoFWEm8ql5DiysNyURsQTMpOIMcDYiPhd8xoGr/FtNC2G6FKXD6ihwGdiVHMoeeh8jYlA9ANwE3kTEp3bO6vE03qOONzR1r/q4RGrquaFFxFxE3ALOA9+6jExpdb180y55AhirhaRTatq0GXEzL8+ZIuI9cBJ4WKiartJf9nWV/mty7UfUafW7erpqRGI9EBuprffvu9n6C1KOmsqwI5A1AAAAAElFTkSuQmCC")}.taro-video-danmu{overflow:visible;position:absolute;left:0;top:0;bottom:0;margin-top:14px;margin-bottom:44px;width:100%;line-height:14px;font-size:14px}.taro-video-danmu-item{position:absolute;left:100%;line-height:1;color:#fff;white-space:nowrap;-webkit-transform:translateX(0);transform:translateX(0);-webkit-transition-property:left, -webkit-transform;transition-property:left, -webkit-transform;transition-property:left, transform;transition-property:left, transform, -webkit-transform;-webkit-transition-duration:3s;transition-duration:3s;-webkit-transition-timing-function:linear;transition-timing-function:linear}.taro-video-toast{display:block;visibility:hidden;position:absolute;left:50%;top:50%;border-radius:5px;background-color:rgba(255, 255, 255, 0.8);pointer-events:none;color:#000;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.taro-video-toast.taro-video-toast-volume{display:block;width:100px;height:100px}.taro-video-toast-volume .taro-video-toast-title{display:block;margin-top:10px;width:100%;line-height:16px;text-align:center;font-size:12px}.taro-video-toast-volume .taro-video-toast-icon{display:block;margin-left:25%;width:50%;height:50%;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAFhklEQVR4Xu2aeaxfQxTHP1VBES0NIQitWtpaaxeCUkQtaYVa0tiClAq1ExIiQTVppaWxt8RWSa2tWkJQRGgtQaSIpUKEpG0ssbbk28yV2+mZO/e9e3vvu/e98897mZnfzPl+75mZs0wvurn06ub46SGgxwLqZaA3sB/wO/A+8G/V6tS5BU4BJgJbO9DvAMOB36okoQ4CNgAeBEYbQK8Bbm4zAdsBc4EdAyA/APZoKwHHAA8DG2UA/AnYrG0ErAVcD1yXA9gfQJ8c40obsqbPgH7AY8CROTVuFQFD3X7fJid4DWsNAWOAGZ0w58YTsDZwKzChA189PbTRBGwKzAYO6iT4srbAMHfTfAksjulS1iG4JzAH2Dy2YKS/qAVcCdzi1vgZOBZ4PWvNGAG6wgYCW0IwctzNmf06BcEXtYABwOeA4otEfgEOdnGGqV6IAAUopwM6zDYuAVjeKYpYwCjgCWOhH513+b2lhE+Avrj89NPyalzyuCIE6EN9BfQ1dHoPOAD40+9LE6D/5aoqSqtLsgiQC60DTiHzfGCFoaSsQAexZdlTgEuyCDgLuK8u5G7dEAHyKN8CBrtxLwDHAX8Z+l4N3GS0L3db4aN0X5opmc+2XZQAfb2LPd2eciG1lUSRJZ9qYHkZONwiYAjwSc3gs24BXWWWfzEVuMjQez13HljX8v7A28lvEgsInaBVcxLaAvr6sgJLtBWeNTrOB+4w2p8DRvoEnAPcXTVaY70QA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XWZ/nQQkOJTAUJZGIav19q9MvKvN1RUIWKMAY5P3EBBjqO393d4C/gMVHwRQlpx21QAAAABJRU5ErkJggg==");background-repeat:no-repeat;background-position:50% 50%;background-size:50%;fill:#000}.taro-video-toast-volume .taro-video-toast-value{margin-left:10px;margin-top:5px;width:80px;height:5px}.taro-video-toast-volume .taro-video-toast-value>.taro-video-toast-value-content{overflow:hidden}.taro-video-toast-volume-grids{width:80px;height:5px}.taro-video-toast-volume-grids-item{float:left;width:7.1px;height:5px;background-color:#000}.taro-video-toast-volume-grids-item:not(:first-child){margin-left:1px}.taro-video-toast.taro-video-toast-progress{padding:6px;background-color:rgba(0, 0, 0, 0.8);line-height:18px;font-size:14px;color:#fff}';var Video=function(){function e(e){var t=this;registerInstance(this,e);this.onPlay=createEvent(this,"play",7);this.onPause=createEvent(this,"pause",7);this.onEnded=createEvent(this,"ended",7);this.onTimeUpdate=createEvent(this,"timeupdate",7);this.onError=createEvent(this,"error",7);this.onFullScreenChange=createEvent(this,"fullscreenchange",7);this.onProgress=createEvent(this,"progress",7);this.onLoadedMetaData=createEvent(this,"loadedmetadata",7);this.currentTime=0;this.isDraggingProgress=false;this.gestureType="none";this.analyzeGesture=function(e){var i;var r={type:"none"};var n=e.touches[0].screenX;var o=e.touches[0].screenY;var s=n-t.lastTouchScreenX;var a=o-t.lastTouchScreenY;var l=t.isFullScreen?t.vslideGestureInFullscreen:t.vslideGesture;if(t.gestureType==="none"){var u=calcDist(s,a);if(u<10)return r;if(Math.abs(a)>=Math.abs(s)){if(l){t.gestureType="adjustVolume";t.lastVolume=t.videoRef.volume}else{return r}}else if(Math.abs(a)<Math.abs(s)){if(t.enableProgressGesture){t.gestureType="adjustProgress";t.lastPercentage=t.currentTime/((i=t.duration)!==null&&i!==void 0?i:t._duration)}else{return r}}}r.type=t.gestureType;r.dataX=normalizeNumber(s/200);r.dataY=normalizeNumber(a/200);return r};this.loadNativePlayer=function(){var e,i;if(t.videoRef){t.videoRef.src=t.src;(i=(e=t.videoRef).load)===null||i===void 0?void 0:i.call(e)}};this.init=function(){var e=t,i=e.src,r=e.videoRef;if(isHls(i)){import("./hls-4018c7ea.js").then((function(e){var n=e.default;t.HLS=n;if(n.isSupported()){if(t.hls){t.hls.destroy()}t.hls=new n;t.hls.loadSource(i);t.hls.attachMedia(r);t.hls.on(n.Events.MANIFEST_PARSED,(function(){t.autoplay&&t.play()}));t.hls.on(n.Events.ERROR,(function(e,i){t.handleError(i)}))}else if(r.canPlayType("application/vnd.apple.mpegurl")){t.loadNativePlayer()}else{console.error("该浏览器不支持 HLS 播放")}}))}else{t.loadNativePlayer()}};this.handlePlay=function(){t.isPlaying=true;t.isFirst=false;t.controlsRef.toggleVisibility(true);t.onPlay.emit()};this.handlePause=function(){t.isPlaying=false;t.controlsRef.toggleVisibility(true);t.onPause.emit()};this.handleEnded=function(){t.isFirst=true;t.pause();t.controlsRef.toggleVisibility();t.onEnded.emit()};this.handleTimeUpdate=throttle((function(e){return __awaiter(t,void 0,void 0,(function(){var t,i,r,n;return __generator(this,(function(o){switch(o.label){case 0:this.currentTime=this.videoRef.currentTime;r=this.duration||this._duration;return[4,this.controlsRef.getIsDraggingProgressBall()];case 1:n=o.sent();if(this.controls&&this.showProgress){if(!n&&!this.isDraggingProgress){this.controlsRef.setProgressBall(this.currentTime/r);this.controlsRef.setCurrentTime(this.currentTime)}}this.danmuRef.tick(this.currentTime);this.onTimeUpdate.emit({duration:(t=e.target)===null||t===void 0?void 0:t.duration,currentTime:(i=e.target)===null||i===void 0?void 0:i.currentTime});if(this.duration){if(this.currentTime>=this.duration){this.seek(0);this.handleEnded()}}return[2]}}))}))}),250);this.handleError=function(e){var i,r;if(t.hls){switch(e.type){case t.HLS.ErrorTypes.NETWORK_ERROR:t.onError.emit({errMsg:e.response});t.hls.startLoad();break;case t.HLS.ErrorTypes.MEDIA_ERROR:t.onError.emit({errMsg:e.reason||"媒体错误,请重试"});t.hls.recoverMediaError();break}}else{t.onError.emit({errMsg:(r=(i=e.target)===null||i===void 0?void 0:i.error)===null||r===void 0?void 0:r.message})}};this.handleDurationChange=function(){t._duration=t.videoRef.duration};this.handleProgress=function(){t.onProgress.emit()};this.handleLoadedMetaData=function(e){var i=e.target;t.onLoadedMetaData.emit({width:i.videoWidth,height:i.videoHeight,duration:i.duration})};this._play=function(){return t.videoRef.play()};this._pause=function(){return t.videoRef.pause()};this._stop=function(){t.videoRef.pause();t._seek(0)};this._seek=function(e){t.videoRef.currentTime=e};this.onTouchStartContainer=function(e){t.lastTouchScreenX=e.touches[0].screenX;t.lastTouchScreenY=e.touches[0].screenY};this.onClickContainer=function(){if(t.enablePlayGesture){var e=Date.now();if(e-t.lastClickedTime<300){t.isPlaying?t.pause():t.play()}t.lastClickedTime=e}t.controlsRef.toggleVisibility()};this.onClickFullScreenBtn=function(e){e.stopPropagation();t.toggleFullScreen()};this.handleFullScreenChange=function(e){var i=(new Date).getTime();if(!e.detail&&t.isFullScreen&&!document[screenFn.fullscreenElement]&&i-t.fullScreenTimestamp>100){t.toggleFullScreen(false)}};this.toggleFullScreen=function(e){if(e===void 0){e=!t.isFullScreen}t.isFullScreen=e;t.controlsRef.toggleVisibility(true);t.fullScreenTimestamp=(new Date).getTime();t.onFullScreenChange.emit({fullScreen:t.isFullScreen,direction:"vertical"});if(t.isFullScreen&&!document[screenFn.fullscreenElement]){setTimeout((function(){t.videoRef[screenFn.requestFullscreen]({navigationUI:"auto"})}),0)}};this.toggleMute=function(e){e.stopPropagation();t.videoRef.muted=!t.isMute;t.controlsRef.toggleVisibility(true);t.isMute=!t.isMute};this.toggleDanmu=function(e){e.stopPropagation();t.controlsRef.toggleVisibility(true);t._enableDanmu=!t._enableDanmu};this.src=undefined;this.duration=undefined;this.controls=true;this.autoplay=false;this.loop=false;this.muted=false;this.initialTime=0;this.poster=undefined;this.objectFit="contain";this.showProgress=true;this.showFullscreenBtn=true;this.showPlayBtn=true;this.showCenterPlayBtn=true;this.showMuteBtn=false;this.danmuList=undefined;this.danmuBtn=false;this.enableDanmu=false;this.enablePlayGesture=false;this.enableProgressGesture=true;this.vslideGesture=false;this.vslideGestureInFullscreen=true;this.nativeProps={};this._duration=undefined;this._enableDanmu=false;this.isPlaying=false;this.isFirst=true;this.isFullScreen=false;this.fullScreenTimestamp=(new Date).getTime();this.isMute=false}e.prototype.componentWillLoad=function(){this._enableDanmu=this.enableDanmu};e.prototype.componentDidLoad=function(){var e,t;this.init();if(this.initialTime){this.videoRef.currentTime=this.initialTime}(t=(e=this.danmuRef).sendDanmu)===null||t===void 0?void 0:t.call(e,this.danmuList);if(document.addEventListener){document.addEventListener(screenFn.fullscreenchange,this.handleFullScreenChange)}if(this.videoRef&&scene==="iOS"){this.videoRef.addEventListener("webkitendfullscreen",this.handleFullScreenChange)}};e.prototype.componentDidRender=function(){};e.prototype.disconnectedCallback=function(){if(document.removeEventListener){document.removeEventListener(screenFn.fullscreenchange,this.handleFullScreenChange)}if(this.videoRef&&scene==="iOS"){this.videoRef.removeEventListener("webkitendfullscreen",this.handleFullScreenChange)}};e.prototype.watchEnableDanmu=function(e){this._enableDanmu=e};e.prototype.watchSrc=function(){this.init()};e.prototype.onDocumentTouchMove=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,r;return __generator(this,(function(n){switch(n.label){case 0:if(this.lastTouchScreenX===undefined||this.lastTouchScreenY===undefined)return[2];return[4,this.controlsRef.getIsDraggingProgressBall()];case 1:if(n.sent())return[2];t=this.analyzeGesture(e);if(t.type==="adjustVolume"){this.toastVolumeRef.style.visibility="visible";i=Math.max(Math.min(this.lastVolume-t.dataY,1),0);this.videoRef.volume=i;this.toastVolumeBarRef.style.width="".concat(i*100,"%")}else if(t.type==="adjustProgress"){this.isDraggingProgress=true;this.nextPercentage=Math.max(Math.min(this.lastPercentage+(t.dataX||0),1),0);if(this.controls&&this.showProgress){this.controlsRef.setProgressBall(this.nextPercentage);this.controlsRef.toggleVisibility(true)}r=this.duration||this._duration;this.toastProgressTitleRef.innerHTML="".concat(formatTime(this.nextPercentage*r)," / ").concat(formatTime(r));this.toastProgressRef.style.visibility="visible"}return[2]}}))}))};e.prototype.onDocumentTouchEnd=function(){var e;if(this.gestureType==="adjustVolume"){this.toastVolumeRef.style.visibility="hidden"}else if(this.gestureType==="adjustProgress"){this.toastProgressRef.style.visibility="hidden"}if(this.isDraggingProgress){this.isDraggingProgress=false;this.seek(this.nextPercentage*((e=this.duration)!==null&&e!==void 0?e:this._duration))}this.gestureType="none";this.lastTouchScreenX=undefined;this.lastTouchScreenY=undefined};e.prototype.getHlsObject=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.hls]}))}))};e.prototype.play=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._play();return[2]}))}))};e.prototype.pause=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._pause();return[2]}))}))};e.prototype.stop=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._stop();return[2]}))}))};e.prototype.seek=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this._seek(e);return[2]}))}))};e.prototype.requestFullScreen=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.toggleFullScreen(true);return[2]}))}))};e.prototype.exitFullScreen=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.toggleFullScreen(false);return[2]}))}))};e.prototype.render=function(){var e=this;var t=this,i=t.controls,r=t.autoplay,n=t.loop,o=t.muted,s=t.poster,a=t.objectFit,l=t.isFirst,u=t.isMute,c=t.isFullScreen,d=t.showCenterPlayBtn,g=t.isPlaying,f=t._enableDanmu,p=t.showMuteBtn,A=t.danmuBtn,v=t.showFullscreenBtn,m=t.nativeProps;var b=this.duration||this._duration;var y=formatTime(b);return h(Host,{class:classnames("taro-video-container",{"taro-video-type-fullscreen":c}),onTouchStart:this.onTouchStartContainer,onClick:this.onClickContainer},h("video",Object.assign({class:"taro-video-video",style:{"object-fit":a},ref:function(t){if(t){e.videoRef=t}},autoplay:r,loop:n,muted:o,poster:i?s:undefined,playsinline:true,"webkit-playsinline":true,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onTimeUpdate:this.handleTimeUpdate,onError:this.handleError,onDurationChange:this.handleDurationChange,onProgress:this.handleProgress,onLoadedMetaData:this.handleLoadedMetaData},m),"暂时不支持播放该视频"),h("taro-video-danmu",{ref:function(t){if(t){e.danmuRef=t}},enable:f}),l&&d&&!g&&h("div",{class:"taro-video-cover"},h("div",{class:"taro-video-cover-play-button",onClick:function(){return e.play()}}),h("p",{class:"taro-video-cover-duration"},y)),h("taro-video-control",{ref:function(t){if(t){e.controlsRef=t}},controls:i,currentTime:this.currentTime,duration:b,isPlaying:this.isPlaying,pauseFunc:this._pause,playFunc:this._play,seekFunc:this._seek,showPlayBtn:this.showPlayBtn,showProgress:this.showProgress},p&&h("div",{class:classnames("taro-video-mute",{"taro-video-type-mute":u}),onClick:this.toggleMute}),A&&h("div",{class:classnames("taro-video-danmu-button",{"taro-video-danmu-button-active":f}),onClick:this.toggleDanmu},"弹幕"),v&&h("div",{class:classnames("taro-video-fullscreen",{"taro-video-type-fullscreen":c}),onClick:this.onClickFullScreenBtn})),h("div",{class:"taro-video-toast taro-video-toast-volume",ref:function(t){if(t){e.toastVolumeRef=t}}},h("div",{class:"taro-video-toast-title"},"音量"),h("div",{class:"taro-video-toast-icon"}),h("div",{class:"taro-video-toast-value"},h("div",{class:"taro-video-toast-value-content",ref:function(t){if(t){e.toastVolumeBarRef=t}}},h("div",{class:"taro-video-toast-volume-grids"},Array(10).fill(1).map((function(){return h("div",{class:"taro-video-toast-volume-grids-item"})})))))),h("div",{class:"taro-video-toast taro-video-toast-progress",ref:function(t){if(t){e.toastProgressRef=t}}},h("div",{class:"taro-video-toast-title",ref:function(t){if(t){e.toastProgressTitleRef=t}}})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{enableDanmu:["watchEnableDanmu"],src:["watchSrc"]}},enumerable:false,configurable:true});return e}();Video.style=indexCss;var VideoDanmu=function(){function e(e){registerInstance(this,e);this.list=[];this.danmuElList=[];this.currentTime=0;this.enable=false;this.danmuList=[]}e.prototype.ensureProperties=function(e){var t=Object.assign({},e);if(!("time"in e)){t.time=this.currentTime}t.key=Math.random();t.bottom="".concat(Math.random()*90+5,"%");return t};e.prototype.sendDanmu=function(e){if(e===void 0){e=[]}return __awaiter(this,void 0,void 0,(function(){var t;var i=this;return __generator(this,(function(r){if(Array.isArray(e)){this.list=__spreadArray(__spreadArray([],this.list,true),e.map((function(e){return i.ensureProperties(e)})),true)}else{t=e;this.list=__spreadArray(__spreadArray([],this.list,true),[Object.assign({},this.ensureProperties(t))],false)}return[2]}))}))};e.prototype.tick=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,r,n;return __generator(this,(function(o){this.currentTime=e;if(!this.enable)return[2];t=this.list;i=t.filter((function(t){var i=t.time;return e-i<4&&e>i}));r=false;n=this.danmuList;if(i.length!==n.length){r=true}else{r=i.some((function(e){var t=e.key;return n.every((function(e){return t!==e.key}))}))}if(r){this.danmuList=i}return[2]}))}))};e.prototype.componentDidUpdate=function(){var e=this;requestAnimationFrame((function(){setTimeout((function(){var t=e.danmuElList.splice(0);t.forEach((function(e){e.style.left="0";e.style.webkitTransform="translateX(-100%)";e.style.transform="translateX(-100%)"}))}))}))};e.prototype.render=function(){var e=this;if(!this.enable)return"";return h(Host,{class:"taro-video-danmu"},this.danmuList.map((function(t){var i=t.text,r=t.color,n=t.bottom,o=t.key;return h("p",{class:"taro-video-danmu-item",key:o,style:{color:r,bottom:n},ref:function(t){if(t){e.danmuElList.push(t)}}},i)})))};return e}();export{VideoControl as taro_video_control,Video as taro_video_core,VideoDanmu as taro_video_danmu};
1
+ var __awaiter=this&&this.__awaiter||function(e,t,i,r){function n(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,o){function s(e){try{l(r.next(e))}catch(e){o(e)}}function a(e){try{l(r["throw"](e))}catch(e){o(e)}}function l(e){e.done?i(e.value):n(e.value).then(s,a)}l((r=r.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},r,n,o,s;return s={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(e){return function(t){return l([e,t])}}function l(a){if(r)throw new TypeError("Generator is already executing.");while(s&&(s=0,a[0]&&(i=0)),i)try{if(r=1,n&&(o=a[0]&2?n["return"]:a[0]?n["throw"]||((o=n["return"])&&o.call(n),0):n.next)&&!(o=o.call(n,a[1])).done)return o;if(n=0,o)a=[a[0]&2,o.value];switch(a[0]){case 0:case 1:o=a;break;case 4:i.label++;return{value:a[1],done:false};case 5:i.label++;n=a[1];a=[0];continue;case 7:a=i.ops.pop();i.trys.pop();continue;default:if(!(o=i.trys,o=o.length>0&&o[o.length-1])&&(a[0]===6||a[0]===2)){i=0;continue}if(a[0]===3&&(!o||a[1]>o[0]&&a[1]<o[3])){i.label=a[1];break}if(a[0]===6&&i.label<o[1]){i.label=o[1];o=a;break}if(o&&i.label<o[2]){i.label=o[2];i.ops.push(a);break}if(o[2])i.ops.pop();i.trys.pop();continue}a=t.call(e,i)}catch(e){a=[6,e];n=0}finally{r=o=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var r=0,n=t.length,o;r<n;r++){if(o||!(r in t)){if(!o)o=Array.prototype.slice.call(t,0,r);o[r]=t[r]}}return e.concat(o||Array.prototype.slice.call(t))};import{r as registerInstance,h,H as Host,g as getElement,c as createEvent}from"./index-980f930f.js";import{c as classnames}from"./index-c3e4004b.js";import{t as throttle}from"./index-d1b03e47.js";var formatTime=function(e){if(!e)return"";var t=Math.round(e%60);var i=Math.round((e-t)/60);return"".concat(i<10?"0".concat(i):i,":").concat(t<10?"0".concat(t):t)};var calcDist=function(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))};var normalizeNumber=function(e){return Math.max(-1,Math.min(e,1))};var scene="default";var screenFn=function(){var e;var t=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];var i=["webkitEnterFullscreen","webkitExitFullscreen","webkitCurrentFullScreenElement","webkitSupportsFullscreen","fullscreenchange","fullscreenerror"];var r=0;var n=t.length;var o={};for(;r<n;r++){e=t[r];if(e&&e[1]in document){for(r=0;r<e.length;r++){o[t[0][r]]=e[r]}return o}}if(!o[t[0][0]]){scene="iOS";for(r=0;r<i.length;r++){o[t[0][r]]=i[r]}}return o}();var isHls=function(e){return/\.(m3u8)($|\?)/i.test(e)};var VideoControl=function(){function e(e){var t=this;registerInstance(this,e);this.visible=false;this.isDraggingProgressBall=false;this.percentage=0;this.progressDimensions={left:0,width:0};this.calcPercentage=function(e){var i=e-t.progressDimensions.left;i=Math.max(i,0);i=Math.min(i,t.progressDimensions.width);return i/t.progressDimensions.width};this.onDragProgressBallStart=function(){t.isDraggingProgressBall=true;t.hideControlsTimer&&clearTimeout(t.hideControlsTimer)};this.onClickProgress=function(e){e.stopPropagation();var i=t.calcPercentage(e.pageX);t.seekFunc(i*t.duration);t.toggleVisibility(true)};this.controls=undefined;this.currentTime=undefined;this.duration=undefined;this.isPlaying=undefined;this.pauseFunc=undefined;this.playFunc=undefined;this.seekFunc=undefined;this.showPlayBtn=undefined;this.showProgress=undefined}e.prototype.onDocumentTouchMove=function(e){if(!this.isDraggingProgressBall)return;var t=e.touches[0].pageX;this.percentage=this.calcPercentage(t);this.setProgressBall(this.percentage);this.setCurrentTime(this.percentage*this.duration)};e.prototype.onDocumentTouchEnd=function(){if(!this.isDraggingProgressBall)return;this.isDraggingProgressBall=false;this.seekFunc(this.percentage*this.duration);this.toggleVisibility(true)};e.prototype.setProgressBall=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){if(this.progressBallRef){this.progressBallRef.style.left="".concat(e*100,"%")}return[2]}))}))};e.prototype.toggleVisibility=function(e){return __awaiter(this,void 0,void 0,(function(){var t;var i=this;return __generator(this,(function(r){t=e===undefined?!this.visible:e;if(t){this.hideControlsTimer&&clearTimeout(this.hideControlsTimer);if(this.isPlaying){this.hideControlsTimer=setTimeout((function(){i.toggleVisibility(false)}),2e3)}this.el.style.visibility="visible"}else{this.el.style.visibility="hidden"}this.visible=!!t;return[2]}))}))};e.prototype.getIsDraggingProgressBall=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.isDraggingProgressBall]}))}))};e.prototype.setCurrentTime=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.currentTimeRef.innerHTML=formatTime(e);return[2]}))}))};e.prototype.render=function(){var e=this;var t=this,i=t.controls,r=t.currentTime,n=t.duration,o=t.isPlaying,s=t.pauseFunc,a=t.playFunc,l=t.showPlayBtn,u=t.showProgress;var c=formatTime(n);var d;if(!l){d=null}else if(o){d=h("div",{class:"taro-video-control-button taro-video-control-button-pause",onClick:s})}else{d=h("div",{class:"taro-video-control-button taro-video-control-button-play",onClick:a})}return h(Host,{class:"taro-video-bar taro-video-bar-full"},i&&h("div",{class:"taro-video-controls"},d,u&&h("div",{class:"taro-video-current-time",ref:function(t){return e.currentTimeRef=t}},formatTime(r)),u&&h("div",{class:"taro-video-progress-container",onClick:this.onClickProgress},h("div",{class:"taro-video-progress",ref:function(t){if(!t)return;var i=t.getBoundingClientRect();e.progressDimensions.left=i.left;e.progressDimensions.width=i.width}},h("div",{class:"taro-video-progress-buffered",style:{width:"100%"}}),h("div",{class:"taro-video-ball",ref:function(t){return e.progressBallRef=t},onTouchStart:this.onDragProgressBallStart,style:{left:"".concat(c?this.currentTime/n*100:0,"%")}},h("div",{class:"taro-video-inner"})))),u&&h("div",{class:"taro-video-duration"},c)),h("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();var indexCss='.taro-video{display:inline-block;overflow:hidden;position:relative;width:100%;height:225px;line-height:0}.taro-video[hidden]{display:none}.taro-video-container{display:inline-block;position:absolute;left:0;top:0;width:100%;height:100%;background-color:#000;-o-object-position:inherit;object-position:inherit}.taro-video-container.taro-video-type-fullscreen{position:fixed;left:0;right:0;top:0;bottom:0;z-index:999}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-left{-webkit-transform:translate(-50%, -50%) rotate(-90deg);transform:translate(-50%, -50%) rotate(-90deg)}.taro-video-container.taro-video-type-fullscreen.taro-video-type-rotate-right{-webkit-transform:translate(-50%, -50%) rotate(90deg);transform:translate(-50%, -50%) rotate(90deg)}.taro-video-video{width:100%;height:100%;-o-object-position:inherit;object-position:inherit;display:block}.taro-video-cover{display:-ms-flexbox;display:flex;position:absolute;left:0;top:0;bottom:0;z-index:1;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;width:100%;background-color:rgba(1, 1, 1, 0.5);-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-box-pack:center;-webkit-box-align:center}.taro-video-cover-play-button{width:40px;height:40px;background-repeat:no-repeat;background-position:50% 50%;background-size:50%}.taro-video-cover-duration{margin-top:10px;line-height:1;font-size:16px;color:#fff}.taro-video-bar{display:-ms-flexbox;display:flex;visibility:hidden;overflow:hidden;position:absolute;right:0;bottom:0;z-index:1;-ms-flex-align:center;align-items:center;padding:0 10px;height:44px;background-color:rgba(0, 0, 0, 0.5);-webkit-box-align:center}.taro-video-bar.taro-video-bar-full{left:0}.taro-video-controls{display:-ms-flexbox;display:flex;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:0 8.5px}.taro-video-control-button{-webkit-box-sizing:content-box;box-sizing:content-box;margin-left:-8.5px;padding:14.5px 12.5px;width:13px;height:15px}.taro-video-control-button::after{display:block;width:100%;height:100%;background-repeat:no-repeat;background-position:50% 50%;background-size:100%;content:""}.taro-video-control-button.taro-video-control-button-play::after,.taro-video-cover-play-button{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAeCAYAAAAy2w7YAAAAAXNSR0IArs4c6QAAAWhJREFUSA1j+P///0cgBoHjQGzCQCsAtgJB/AMy5wCxGNXtQ9iBwvoA5BUCMQvVLEQxHpNzDSjkRhXLMM3GKrIeKKpEkYVYjcUu+AMo3ALE3GRZiN1MvKKPgbIRJFuG10j8koeA0gZEW4jfLIKyf4EqpgOxMEELCRpFnIJ3QGU5QMyM00LizCFa1SWgSkeslhFtBGkKVwGVy6FYSJp+klR/A6quB2JOkIWMIK0oNlOf8xBoZDE9LAI7nYn6HsBq4l96WHQEaLUpAyiOaASeAM2NgvuPBpaACt82IEYtfKls0UagecpwXyAzqGTRdaA57sjmYrAptAjUsCkGYlYMg9EFyLQI1IiZB8Ti6Obh5JNh0QmgHlOcBuKSIMGi50C18UDMiMssvOJEWPQLqKYbiHnxGkRIkoBF24DyaoTMIEoeh0W3geI+RBlArCI0iz4D+RVAzEasfqLVAQ19AcSg5LoYiKWI1kiiQgCMBLnEEcfDSgAAAABJRU5ErkJggg==")}.taro-video-control-button.taro-video-control-button-pause::after{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAAgCAYAAAAffCjxAAAAAXNSR0IArs4c6QAAAFlJREFUSA3tksEKACAIQ7X//5zq98wOgQayum8QaGweHhMzG/6OujzKAymn+0LMqivu1XznWmX8/echTIyMyAgTwA72iIwwAexgj8gIE8CO3aMRbDPMaEy5BRGaKcZv8YxRAAAAAElFTkSuQmCC")}.taro-video-current-time,.taro-video-duration{margin-top:15px;margin-bottom:14.5px;height:14.5px;line-height:14.5px;font-size:12px;color:#cbcbcb}.taro-video-progress-container{position:relative;-ms-flex-positive:2;flex-grow:2;-webkit-box-flex:2}.taro-video-progress{position:relative;margin:21px 12px;height:2px;background-color:rgba(255, 255, 255, 0.4)}.taro-video-progress-buffered{position:absolute;left:0;top:0;width:0;height:100%;background-color:rgba(255, 255, 255, 0.8);-webkit-transition:width 0.1s;transition:width 0.1s}.taro-video-ball{position:absolute;left:0;top:-21px;-webkit-box-sizing:content-box;box-sizing:content-box;margin-left:-22px;padding:14px;width:16px;height:16px}.taro-video-inner{border-radius:50%;width:100%;height:100%;background-color:#fff}.taro-video-danmu-button{margin:0 8.5px;padding:2px 10px;border:1px solid #fff;border-radius:5px;line-height:1;font-size:13px;color:#fff;white-space:nowrap}.taro-video-danmu-button.taro-video-danmu-button-active{border-color:#48c23d;color:#48c23d}.taro-video-fullscreen,.taro-video-mute{-webkit-box-sizing:content-box;box-sizing:content-box;padding:8.5px;width:17px;height:17px;background-repeat:no-repeat;background-position:50% 50%;background-size:50%}.taro-video-fullscreen{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAhUlEQVRYR+2WSwrAMAhEnZO3PfmULLooGEFTiIXJ2s/kRY2wzQeb85sE9CRA8jSzY1YfAFzhJBnU1AVgxH2dSiArCnD9QgGzRNnOech48SRABHoSyFb5in3PSbhyo6yvCPQkEM3u7BsPe/0FIvBfAh/vhKmVbO9SWun1qk/PSVi9TcVPBG6R1YIhgWwNpQAAAABJRU5ErkJggg==")}.taro-video-fullscreen.taro-video-type-fullscreen{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAABPUlEQ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veG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz5PmxYVAAACLklEQVRYhc2XP2sVQRRHz40hKoqaQgVBCy1EozFlGiVFxMLGh4piYWEh+hkEP4YKAVFEEFTyughaCH6DqIVpAhYWEgIxoJE8cywyi5tNHu/tJmvyg2WZO3dmzt47/zZUtoJ6Nhsg09YDiYhKDzACTAFNYH9lEpUq80TdrT5wpV5n/ZV9KoGoo+pXV2uyKkipOaLuUceAt8DhUvQd1FsCYhR4ChzaSIBMHSOi7lOfsByFWiCgEBH1GHAF2JlMPcBt4GC3HUYEaj9wF3gVEVPtfNVTwAXgWX7CDKq/1piAZTSZBmim8qJ6sQ3EgDqb/L7kU3MH2NHtl3dQX3r3Ak21UYAYAj4A/cl0JB+RF+uMRj4iQ+p8zt7KYFLdXKHuRi0gacBhV6a6pd5bA6KRNagFJPU9qv5u47toLmW1HnoR8Q5oAK1CVQu4FBHj/wUkaXsb+4pzpVaQFPqXrN7Be4Fx9VztIOr1BLEtmX4A94E/qdwHTKjDWYM6lu81dSlnn3V570BtuLxaMs2rZ/IgYxsBovaoPwsQA4VoFWEm8ql5DiysNyURsQTMpOIMcDYiPhd8xoGr/FtNC2G6FKXD6ihwGdiVHMoeeh8jYlA9ANwE3kTEp3bO6vE03qOONzR1r/q4RGrquaFFxFxE3ALOA9+6jExpdb180y55AhirhaRTatq0GXEzL8+ZIuI9cBJ4WKiartJf9nWV/mty7UfUafW7erpqRGI9EBuprffvu9n6C1KOmsqwI5A1AAAAAElFTkSuQmCC")}.taro-video-danmu{overflow:visible;position:absolute;left:0;top:0;bottom:0;margin-top:14px;margin-bottom:44px;width:100%;line-height:14px;font-size:14px}.taro-video-danmu-item{position:absolute;left:100%;line-height:1;color:#fff;white-space:nowrap;-webkit-transform:translateX(0);transform:translateX(0);-webkit-transition-property:left, -webkit-transform;transition-property:left, -webkit-transform;transition-property:left, transform;transition-property:left, transform, -webkit-transform;-webkit-transition-duration:3s;transition-duration:3s;-webkit-transition-timing-function:linear;transition-timing-function:linear}.taro-video-toast{display:block;visibility:hidden;position:absolute;left:50%;top:50%;border-radius:5px;background-color:rgba(255, 255, 255, 0.8);pointer-events:none;color:#000;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.taro-video-toast.taro-video-toast-volume{display:block;width:100px;height:100px}.taro-video-toast-volume .taro-video-toast-title{display:block;margin-top:10px;width:100%;line-height:16px;text-align:center;font-size:12px}.taro-video-toast-volume .taro-video-toast-icon{display:block;margin-left:25%;width:50%;height:50%;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAFhklEQVR4Xu2aeaxfQxTHP1VBES0NIQitWtpaaxeCUkQtaYVa0tiClAq1ExIiQTVppaWxt8RWSa2tWkJQRGgtQaSIpUKEpG0ssbbk28yV2+mZO/e9e3vvu/e98897mZnfzPl+75mZs0wvurn06ub46SGgxwLqZaA3sB/wO/A+8G/V6tS5BU4BJgJbO9DvAMOB36okoQ4CNgAeBEYbQK8Bbm4zAdsBc4EdAyA/APZoKwHHAA8DG2UA/AnYrG0ErAVcD1yXA9gfQJ8c40obsqbPgH7AY8CROTVuFQFD3X7fJid4DWsNAWOAGZ0w58YTsDZwKzChA189PbTRBGwKzAYO6iT4srbAMHfTfAksjulS1iG4JzAH2Dy2YKS/qAVcCdzi1vgZOBZ4PWvNGAG6wgYCW0IwctzNmf06BcEXtYABwOeA4otEfgEOdnGGqV6IAAUopwM6zDYuAVjeKYpYwCjgCWOhH513+b2lhE+Avrj89NPyalzyuCIE6EN9BfQ1dHoPOAD40+9LE6D/5aoqSqtLsgiQC60DTiHzfGCFoaSsQAexZdlTgEuyCDgLuK8u5G7dEAHyKN8CBrtxLwDHAX8Z+l4N3GS0L3db4aN0X5opmc+2XZQAfb2LPd2eciG1lUSRJZ9qYHkZONwiYAjwSc3gs24BXWWWfzEVu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vdkPF0Xu/8dohNUmZ/1QQkuitXr+d4fryuFx3jywQYm6suAqSX8vLTXKJDt4QqO6rtLYspXWZ/nQQkOJTAUJZGIav19q9MvKvN1RUIWKMAY5P3EBBjqO393d4C/gMVHwRQlpx21QAAAABJRU5ErkJggg==");background-repeat:no-repeat;background-position:50% 50%;background-size:50%;fill:#000}.taro-video-toast-volume .taro-video-toast-value{margin-left:10px;margin-top:5px;width:80px;height:5px}.taro-video-toast-volume .taro-video-toast-value>.taro-video-toast-value-content{overflow:hidden}.taro-video-toast-volume-grids{width:80px;height:5px}.taro-video-toast-volume-grids-item{float:left;width:7.1px;height:5px;background-color:#000}.taro-video-toast-volume-grids-item:not(:first-child){margin-left:1px}.taro-video-toast.taro-video-toast-progress{padding:6px;background-color:rgba(0, 0, 0, 0.8);line-height:18px;font-size:14px;color:#fff}';var Video=function(){function e(e){var t=this;registerInstance(this,e);this.onPlay=createEvent(this,"play",7);this.onPause=createEvent(this,"pause",7);this.onEnded=createEvent(this,"ended",7);this.onTimeUpdate=createEvent(this,"timeupdate",7);this.onError=createEvent(this,"error",7);this.onFullScreenChange=createEvent(this,"fullscreenchange",7);this.onProgress=createEvent(this,"progress",7);this.onLoadedMetaData=createEvent(this,"loadedmetadata",7);this.currentTime=0;this.isDraggingProgress=false;this.gestureType="none";this.analyzeGesture=function(e){var i;var r={type:"none"};var n=e.touches[0].screenX;var o=e.touches[0].screenY;var s=n-t.lastTouchScreenX;var a=o-t.lastTouchScreenY;var l=t.isFullScreen?t.vslideGestureInFullscreen:t.vslideGesture;if(t.gestureType==="none"){var u=calcDist(s,a);if(u<10)return r;if(Math.abs(a)>=Math.abs(s)){if(l){t.gestureType="adjustVolume";t.lastVolume=t.videoRef.volume}else{return r}}else if(Math.abs(a)<Math.abs(s)){if(t.enableProgressGesture){t.gestureType="adjustProgress";t.lastPercentage=t.currentTime/((i=t.duration)!==null&&i!==void 0?i:t._duration)}else{return r}}}r.type=t.gestureType;r.dataX=normalizeNumber(s/200);r.dataY=normalizeNumber(a/200);return r};this.loadNativePlayer=function(){var e,i;if(t.videoRef){t.videoRef.src=t.src;(i=(e=t.videoRef).load)===null||i===void 0?void 0:i.call(e)}};this.init=function(){var e=t,i=e.src,r=e.videoRef;if(isHls(i)){import("./hls-4018c7ea.js").then((function(e){var n=e.default;t.HLS=n;if(n.isSupported()){if(t.hls){t.hls.destroy()}t.hls=new n;t.hls.loadSource(i);t.hls.attachMedia(r);t.hls.on(n.Events.MANIFEST_PARSED,(function(){t.autoplay&&t.play()}));t.hls.on(n.Events.ERROR,(function(e,i){t.handleError(i)}))}else if(r.canPlayType("application/vnd.apple.mpegurl")){t.loadNativePlayer()}else{console.error("该浏览器不支持 HLS 播放")}}))}else{t.loadNativePlayer()}};this.handlePlay=function(){t.isPlaying=true;t.isFirst=false;t.controlsRef.toggleVisibility(true);t.onPlay.emit()};this.handlePause=function(){t.isPlaying=false;t.controlsRef.toggleVisibility(true);t.onPause.emit()};this.handleEnded=function(){t.isFirst=true;t.pause();t.controlsRef.toggleVisibility();t.onEnded.emit()};this.handleTimeUpdate=throttle((function(e){return __awaiter(t,void 0,void 0,(function(){var t,i,r,n;return __generator(this,(function(o){switch(o.label){case 0:this.currentTime=this.videoRef.currentTime;r=this.duration||this._duration;return[4,this.controlsRef.getIsDraggingProgressBall()];case 1:n=o.sent();if(this.controls&&this.showProgress){if(!n&&!this.isDraggingProgress){this.controlsRef.setProgressBall(this.currentTime/r);this.controlsRef.setCurrentTime(this.currentTime)}}this.danmuRef.tick(this.currentTime);this.onTimeUpdate.emit({duration:(t=e.target)===null||t===void 0?void 0:t.duration,currentTime:(i=e.target)===null||i===void 0?void 0:i.currentTime});if(this.duration){if(this.currentTime>=this.duration){this.seek(0);this.handleEnded()}}return[2]}}))}))}),250);this.handleError=function(e){var i,r;if(t.hls){switch(e.type){case t.HLS.ErrorTypes.NETWORK_ERROR:t.onError.emit({errMsg:e.response});t.hls.startLoad();break;case t.HLS.ErrorTypes.MEDIA_ERROR:t.onError.emit({errMsg:e.reason||"媒体错误,请重试"});t.hls.recoverMediaError();break}}else{t.onError.emit({errMsg:(r=(i=e.target)===null||i===void 0?void 0:i.error)===null||r===void 0?void 0:r.message})}};this.handleDurationChange=function(){t._duration=t.videoRef.duration};this.handleProgress=function(){t.onProgress.emit()};this.handleLoadedMetaData=function(e){var i=e.target;t.onLoadedMetaData.emit({width:i.videoWidth,height:i.videoHeight,duration:i.duration})};this._play=function(){return t.videoRef.play()};this._pause=function(){return t.videoRef.pause()};this._stop=function(){t.videoRef.pause();t._seek(0)};this._seek=function(e){t.videoRef.currentTime=e};this.onTouchStartContainer=function(e){t.lastTouchScreenX=e.touches[0].screenX;t.lastTouchScreenY=e.touches[0].screenY};this.onClickContainer=function(){if(t.enablePlayGesture){var e=Date.now();if(e-t.lastClickedTime<300){t.isPlaying?t.pause():t.play()}t.lastClickedTime=e}t.controlsRef.toggleVisibility()};this.onClickFullScreenBtn=function(e){e.stopPropagation();t.toggleFullScreen()};this.handleFullScreenChange=function(e){var i=(new Date).getTime();if(!e.detail&&t.isFullScreen&&!document[screenFn.fullscreenElement]&&i-t.fullScreenTimestamp>100){t.toggleFullScreen(false,true)}};this.toggleFullScreen=function(e,i){if(e===void 0){e=!t.isFullScreen}if(i===void 0){i=false}t.isFullScreen=e;t.controlsRef.toggleVisibility(true);t.fullScreenTimestamp=(new Date).getTime();t.onFullScreenChange.emit({fullScreen:t.isFullScreen,direction:"vertical"});if(t.isFullScreen&&!document[screenFn.fullscreenElement]){setTimeout((function(){t.videoRef[screenFn.requestFullscreen]({navigationUI:"auto"})}),0)}else if(!i){document[screenFn.exitFullscreen]()}};this.toggleMute=function(e){e.stopPropagation();t.videoRef.muted=!t.isMute;t.controlsRef.toggleVisibility(true);t.isMute=!t.isMute};this.toggleDanmu=function(e){e.stopPropagation();t.controlsRef.toggleVisibility(true);t._enableDanmu=!t._enableDanmu};this.src=undefined;this.duration=undefined;this.controls=true;this.autoplay=false;this.loop=false;this.muted=false;this.initialTime=0;this.poster=undefined;this.objectFit="contain";this.showProgress=true;this.showFullscreenBtn=true;this.showPlayBtn=true;this.showCenterPlayBtn=true;this.showMuteBtn=false;this.danmuList=undefined;this.danmuBtn=false;this.enableDanmu=false;this.enablePlayGesture=false;this.enableProgressGesture=true;this.vslideGesture=false;this.vslideGestureInFullscreen=true;this.nativeProps={};this._duration=undefined;this._enableDanmu=false;this.isPlaying=false;this.isFirst=true;this.isFullScreen=false;this.fullScreenTimestamp=(new Date).getTime();this.isMute=false}e.prototype.componentWillLoad=function(){this._enableDanmu=this.enableDanmu};e.prototype.componentDidLoad=function(){var e,t;this.init();if(this.initialTime){this.videoRef.currentTime=this.initialTime}(t=(e=this.danmuRef).sendDanmu)===null||t===void 0?void 0:t.call(e,this.danmuList);if(document.addEventListener){document.addEventListener(screenFn.fullscreenchange,this.handleFullScreenChange)}if(this.videoRef&&scene==="iOS"){this.videoRef.addEventListener("webkitendfullscreen",this.handleFullScreenChange)}};e.prototype.componentDidRender=function(){};e.prototype.disconnectedCallback=function(){if(document.removeEventListener){document.removeEventListener(screenFn.fullscreenchange,this.handleFullScreenChange)}if(this.videoRef&&scene==="iOS"){this.videoRef.removeEventListener("webkitendfullscreen",this.handleFullScreenChange)}};e.prototype.watchEnableDanmu=function(e){this._enableDanmu=e};e.prototype.watchSrc=function(){this.init()};e.prototype.onDocumentTouchMove=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,r;return __generator(this,(function(n){switch(n.label){case 0:if(this.lastTouchScreenX===undefined||this.lastTouchScreenY===undefined)return[2];return[4,this.controlsRef.getIsDraggingProgressBall()];case 1:if(n.sent())return[2];t=this.analyzeGesture(e);if(t.type==="adjustVolume"){this.toastVolumeRef.style.visibility="visible";i=Math.max(Math.min(this.lastVolume-t.dataY,1),0);this.videoRef.volume=i;this.toastVolumeBarRef.style.width="".concat(i*100,"%")}else if(t.type==="adjustProgress"){this.isDraggingProgress=true;this.nextPercentage=Math.max(Math.min(this.lastPercentage+(t.dataX||0),1),0);if(this.controls&&this.showProgress){this.controlsRef.setProgressBall(this.nextPercentage);this.controlsRef.toggleVisibility(true)}r=this.duration||this._duration;this.toastProgressTitleRef.innerHTML="".concat(formatTime(this.nextPercentage*r)," / ").concat(formatTime(r));this.toastProgressRef.style.visibility="visible"}return[2]}}))}))};e.prototype.onDocumentTouchEnd=function(){var e;if(this.gestureType==="adjustVolume"){this.toastVolumeRef.style.visibility="hidden"}else if(this.gestureType==="adjustProgress"){this.toastProgressRef.style.visibility="hidden"}if(this.isDraggingProgress){this.isDraggingProgress=false;this.seek(this.nextPercentage*((e=this.duration)!==null&&e!==void 0?e:this._duration))}this.gestureType="none";this.lastTouchScreenX=undefined;this.lastTouchScreenY=undefined};e.prototype.getHlsObject=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.hls]}))}))};e.prototype.play=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._play();return[2]}))}))};e.prototype.pause=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._pause();return[2]}))}))};e.prototype.stop=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this._stop();return[2]}))}))};e.prototype.seek=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this._seek(e);return[2]}))}))};e.prototype.requestFullScreen=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.toggleFullScreen(true);return[2]}))}))};e.prototype.exitFullScreen=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.toggleFullScreen(false);return[2]}))}))};e.prototype.render=function(){var e=this;var t=this,i=t.controls,r=t.autoplay,n=t.loop,o=t.muted,s=t.poster,a=t.objectFit,l=t.isFirst,u=t.isMute,c=t.isFullScreen,d=t.showCenterPlayBtn,g=t.isPlaying,f=t._enableDanmu,p=t.showMuteBtn,A=t.danmuBtn,v=t.showFullscreenBtn,m=t.nativeProps;var b=this.duration||this._duration;var y=formatTime(b);return h(Host,{class:classnames("taro-video-container",{"taro-video-type-fullscreen":c}),onTouchStart:this.onTouchStartContainer,onClick:this.onClickContainer},h("video",Object.assign({class:"taro-video-video",style:{"object-fit":a},ref:function(t){if(t){e.videoRef=t}},autoplay:r,loop:n,muted:o,poster:i?s:undefined,playsinline:true,"webkit-playsinline":true,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onTimeUpdate:this.handleTimeUpdate,onError:this.handleError,onDurationChange:this.handleDurationChange,onProgress:this.handleProgress,onLoadedMetaData:this.handleLoadedMetaData},m),"暂时不支持播放该视频"),h("taro-video-danmu",{ref:function(t){if(t){e.danmuRef=t}},enable:f}),l&&d&&!g&&h("div",{class:"taro-video-cover"},h("div",{class:"taro-video-cover-play-button",onClick:function(){return e.play()}}),h("p",{class:"taro-video-cover-duration"},y)),h("taro-video-control",{ref:function(t){if(t){e.controlsRef=t}},controls:i,currentTime:this.currentTime,duration:b,isPlaying:this.isPlaying,pauseFunc:this._pause,playFunc:this._play,seekFunc:this._seek,showPlayBtn:this.showPlayBtn,showProgress:this.showProgress},p&&h("div",{class:classnames("taro-video-mute",{"taro-video-type-mute":u}),onClick:this.toggleMute}),A&&h("div",{class:classnames("taro-video-danmu-button",{"taro-video-danmu-button-active":f}),onClick:this.toggleDanmu},"弹幕"),v&&h("div",{class:classnames("taro-video-fullscreen",{"taro-video-type-fullscreen":c}),onClick:this.onClickFullScreenBtn})),h("div",{class:"taro-video-toast taro-video-toast-volume",ref:function(t){if(t){e.toastVolumeRef=t}}},h("div",{class:"taro-video-toast-title"},"音量"),h("div",{class:"taro-video-toast-icon"}),h("div",{class:"taro-video-toast-value"},h("div",{class:"taro-video-toast-value-content",ref:function(t){if(t){e.toastVolumeBarRef=t}}},h("div",{class:"taro-video-toast-volume-grids"},Array(10).fill(1).map((function(){return h("div",{class:"taro-video-toast-volume-grids-item"})})))))),h("div",{class:"taro-video-toast taro-video-toast-progress",ref:function(t){if(t){e.toastProgressRef=t}}},h("div",{class:"taro-video-toast-title",ref:function(t){if(t){e.toastProgressTitleRef=t}}})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{enableDanmu:["watchEnableDanmu"],src:["watchSrc"]}},enumerable:false,configurable:true});return e}();Video.style=indexCss;var VideoDanmu=function(){function e(e){registerInstance(this,e);this.list=[];this.danmuElList=[];this.currentTime=0;this.enable=false;this.danmuList=[]}e.prototype.ensureProperties=function(e){var t=Object.assign({},e);if(!("time"in e)){t.time=this.currentTime}t.key=Math.random();t.bottom="".concat(Math.random()*90+5,"%");return t};e.prototype.sendDanmu=function(e){if(e===void 0){e=[]}return __awaiter(this,void 0,void 0,(function(){var t;var i=this;return __generator(this,(function(r){if(Array.isArray(e)){this.list=__spreadArray(__spreadArray([],this.list,true),e.map((function(e){return i.ensureProperties(e)})),true)}else{t=e;this.list=__spreadArray(__spreadArray([],this.list,true),[Object.assign({},this.ensureProperties(t))],false)}return[2]}))}))};e.prototype.tick=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,r,n;return __generator(this,(function(o){this.currentTime=e;if(!this.enable)return[2];t=this.list;i=t.filter((function(t){var i=t.time;return e-i<4&&e>i}));r=false;n=this.danmuList;if(i.length!==n.length){r=true}else{r=i.some((function(e){var t=e.key;return n.every((function(e){return t!==e.key}))}))}if(r){this.danmuList=i}return[2]}))}))};e.prototype.componentDidUpdate=function(){var e=this;requestAnimationFrame((function(){setTimeout((function(){var t=e.danmuElList.splice(0);t.forEach((function(e){e.style.left="0";e.style.webkitTransform="translateX(-100%)";e.style.transform="translateX(-100%)"}))}))}))};e.prototype.render=function(){var e=this;if(!this.enable)return"";return h(Host,{class:"taro-video-danmu"},this.danmuList.map((function(t){var i=t.text,r=t.color,n=t.bottom,o=t.key;return h("p",{class:"taro-video-danmu-item",key:o,style:{color:r,bottom:n},ref:function(t){if(t){e.danmuElList.push(t)}}},i)})))};return e}();export{VideoControl as taro_video_control,Video as taro_video_core,VideoDanmu as taro_video_danmu};
@@ -1 +1 @@
1
- import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-980f930f.js";import{c as classnames}from"./index-c3e4004b.js";var indexCss="body,html{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}taro-view-core{display:block}";var View=function(){function t(t){registerInstance(this,t);this.onLongPress=createEvent(this,"longpress",7);this.startTime=0;this.animation=undefined;this.hoverClass=undefined;this.hoverStartTime=50;this.hoverStayTime=400;this.hover=false;this.touch=false}t.prototype.onTouchStart=function(){var t=this;if(this.hoverClass){this.touch=true;setTimeout((function(){if(t.touch){t.hover=true}}),this.hoverStartTime)}this.timeoutEvent=setTimeout((function(){t.onLongPress.emit()}),350);this.startTime=Date.now()};t.prototype.onTouchMove=function(){clearTimeout(this.timeoutEvent)};t.prototype.onTouchEnd=function(){var t=this;var e=Date.now()-this.startTime;if(e<350){clearTimeout(this.timeoutEvent)}if(this.hoverClass){this.touch=false;setTimeout((function(){if(!t.touch){t.hover=false}}),this.hoverStayTime)}};t.prototype.componentDidRender=function(){var t=this.el;t.childNodes.forEach((function(t){if(t.nodeType===document.COMMENT_NODE&&t["s-cn"])t["s-cn"]=false;if(t.nodeType!==document.COMMENT_NODE&&t["s-sr"])t["s-sr"]=false}))};t.prototype.render=function(){var t;var e=classnames((t={},t["".concat(this.hoverClass)]=this.hover,t));var s={};if(!!this.animation){s["animation"]=this.animation;s["data-animation"]=this.animation}return h(Host,Object.assign({class:e},s),h("slot",null))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();View.style=indexCss;export{View as taro_view_core};
1
+ import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-980f930f.js";import{c as classnames}from"./index-c3e4004b.js";import{h as handleStencilNodes}from"./helper-8a85bb65.js";import"@tarojs/taro";var indexCss="body,html{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}taro-view-core{display:block}";var View=function(){function t(t){registerInstance(this,t);this.onLongPress=createEvent(this,"longpress",7);this.startTime=0;this.animation=undefined;this.hoverClass=undefined;this.hoverStartTime=50;this.hoverStayTime=400;this.hover=false;this.touch=false}t.prototype.onTouchStart=function(){var t=this;if(this.hoverClass){this.touch=true;setTimeout((function(){if(t.touch){t.hover=true}}),this.hoverStartTime)}this.timeoutEvent=setTimeout((function(){t.onLongPress.emit()}),350);this.startTime=Date.now()};t.prototype.onTouchMove=function(){clearTimeout(this.timeoutEvent)};t.prototype.onTouchEnd=function(){var t=this;var e=Date.now()-this.startTime;if(e<350){clearTimeout(this.timeoutEvent)}if(this.hoverClass){this.touch=false;setTimeout((function(){if(!t.touch){t.hover=false}}),this.hoverStayTime)}};t.prototype.componentDidRender=function(){handleStencilNodes(this.el)};t.prototype.render=function(){var t;var e=classnames((t={},t["".concat(this.hoverClass)]=this.hover,t));var i={};if(!!this.animation){i["animation"]=this.animation;i["data-animation"]=this.animation}return h(Host,Object.assign({class:e},i),h("slot",null))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();View.style=indexCss;export{View as taro_view_core};
@@ -1 +1 @@
1
- import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-3d0ecf0f.js";import"@tarojs/taro";var VoipRoom=function(){function o(o){registerInstance(this,o)}o.prototype.componentDidLoad=function(){notSupport("VoipRoom",this)};o.prototype.render=function(){return h(Host,null)};return o}();export{VoipRoom as taro_voip_room_core};
1
+ import{r as registerInstance,h,H as Host}from"./index-980f930f.js";import{n as notSupport}from"./helper-8a85bb65.js";import"@tarojs/taro";var VoipRoom=function(){function o(o){registerInstance(this,o)}o.prototype.componentDidLoad=function(){notSupport("VoipRoom",this)};o.prototype.render=function(){return h(Host,null)};return o}();export{VoipRoom as taro_voip_room_core};
@@ -0,0 +1 @@
1
+ import{r,h as o,H as a}from"./p-9137dcab.js";import{n as t}from"./p-dbdb9de9.js";import"@tarojs/taro";const s=class{constructor(o){r(this,o)}componentDidLoad(){t("Camera",this)}render(){return o(a,null)}};export{s as taro_camera_core}
@@ -1 +1 @@
1
- import{r as o,h as t,H as r}from"./p-9137dcab.js";import{n as s}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(t){o(this,t)}componentDidLoad(){s("Lottie",this)}render(){return t(r,null)}};export{a as taro_lottie_core}
1
+ import{r as o,h as t,H as r}from"./p-9137dcab.js";import{n as s}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(t){o(this,t)}componentDidLoad(){s("Lottie",this)}render(){return t(r,null)}};export{a as taro_lottie_core}
@@ -0,0 +1 @@
1
+ import{r as t,c as i,h as e,g as o,H as s}from"./p-9137dcab.js";import{d as r}from"./p-d3c7f87d.js";import{c as n}from"./p-de951a46.js";function a(t){if(t){const i=/([\w-]*)\s*:\s*([^;]*)/g,e={};let o;for(;o=i.exec(t);)e[`${o[1]}`]=o[2].trim();return e}}const c=class{constructor(e){t(this,e),this.onChange=i(this,"onselect",7),this.onSelectStart=i(this,"onselectstart",7),this.onSelectEnd=i(this,"onselectend",7),this.handleSelected=r((()=>{const t=this.el.childNodes;let i=0,e="0";for(const o in t){const s=t[o].offsetHeight;if(i+s/2>this.el.scrollTop){e=o;break}i+=s}this.el.scrollTo({top:i,behavior:"smooth"}),this.onChange.emit({curIndex:this.col,selectedIndex:e}),this.onSelectEnd.emit()}),500),this.col=void 0,this.initialPosition="0",this.paddingVertical=0,this.isInit=!1}onTouchStart(){this.onSelectStart.emit()}onTouchEnd(){this.handleSelected()}componentDidLoad(){this.handleChange()}componentDidUpdate(){this.handleChange()}handleChange(){const t=this.el.childNodes;let i=0,e=0;for(const o in t){const s=t[o];if(this.initialPosition===o||!s||"number"!=typeof s.offsetHeight)break;e+=s.offsetHeight,i++}this.el.scrollTo({top:e}),i>=t.length&&this.onChange.emit({curIndex:this.col,selectedIndex:i-1})}render(){const{paddingVertical:t=0}=this;return e(s,{class:"taro-picker-view-column-container",style:{"padding-top":`${t}px`,"padding-bottom":`${t}px`}})}get el(){return o(this)}};c.style=".taro-picker-view-column-container{display:-ms-flexbox;display:flex;overflow:scroll;overflow-x:hidden;position:relative;-ms-flex-direction:column;flex-direction:column;-ms-flex:1;flex:1;text-align:center}.taro-picker-view-column-container::-webkit-scrollbar{display:none}";const l=class{constructor(e){t(this,e),this.onChange=i(this,"change",7),this.onPickStart=i(this,"pickstart",7),this.onPickEnd=i(this,"pickend",7),this.indicatorStyle=void 0,this.indicatorClass=void 0,this.value=void 0,this.maskStyle=void 0,this.maskClass=void 0}onPropsChange(){this.handleValueChange()}onSelect(t){t.stopPropagation(),"TARO-PICKER-VIEW-COLUMN-CORE"===t.target.tagName&&(this.value[+t.detail.curIndex]=+t.detail.selectedIndex,this.onChange.emit({value:this.value}))}onSelectStart(t){t.stopPropagation(),"TARO-PICKER-VIEW-COLUMN-CORE"===t.target.tagName&&this.onPickStart.emit()}onPickerColEnd(t){t.stopPropagation(),"TARO-PICKER-VIEW-COLUMN-CORE"===t.target.tagName&&this.onPickEnd.emit()}componentDidLoad(){this.handleValueChange()}handleValueChange(){this.el.querySelectorAll("taro-picker-view-column-core").forEach(((t,i)=>{var e;t.setAttribute("col",`${i}`);let o=0;this.value&&this.value.length>i&&(o=this.value[i]);const s=(this.el.getBoundingClientRect().height-((null===(e=this.indicator)||void 0===e?void 0:e.offsetHeight)||0))/2;t.setAttribute("initial-position",`${o}`),t.setAttribute("padding-vertical",`${s}`)}))}componentDidRender(){this.el.childNodes.forEach((t=>{"TARO-PICKER-VIEW-COLUMN-CORE"!==t.tagName&&"taro-picker-view-mask-container"!==t.className&&this.el.removeChild(t)}))}render(){const t=n("taro-picker-view-mask-indicator",this.indicatorClass),i=n("taro-picker-view-mask-top",this.maskClass),o=n("taro-picker-view-mask-bottom",this.maskClass),r=a(this.indicatorStyle),c=a(this.maskStyle),l=a(this.maskStyle);return e(s,{class:"taro-picker-view-container"},e("slot",null),e("div",{class:"taro-picker-view-mask-container"},e("div",{class:i,style:c}),e("div",{class:t,style:r,ref:t=>this.indicator=t}),e("div",{class:o,style:l})))}get el(){return o(this)}static get watchers(){return{value:["onPropsChange"]}}};l.style=".taro-picker-view-container{display:-ms-flexbox;display:flex;position:relative}.taro-picker-view-mask-container{display:-ms-flexbox;display:flex;position:absolute;left:0;right:0;top:0;bottom:0;-ms-flex-direction:column;flex-direction:column;pointer-events:none}.taro-picker-view-mask-indicator{display:-ms-flexbox;display:flex;border-top:1px solid #ddd;border-bottom:1px solid #ddd;height:50px}.taro-picker-view-mask-top{-ms-flex:1;flex:1;background-image:-webkit-gradient(linear, left top, left bottom, from(rgba(255, 255, 255, 0.95)), to(rgba(255, 255, 255, 0.6)));background-image:linear-gradient(to bottom, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6))}.taro-picker-view-mask-bottom{-ms-flex:1;flex:1;background:-webkit-gradient(linear, left bottom, left top, from(rgba(255, 255, 255, 0.95)), to(rgba(255, 255, 255, 0.6)));background:linear-gradient(to top, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.6))}";export{c as taro_picker_view_column_core,l as taro_picker_view_core}
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,o,e,r;return{setters:[function(t){n=t.r;o=t.h;e=t.H},function(t){r=t.n},function(){}],execute:function(){var c=t("taro_ad_custom_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("AdCustom",this)};t.prototype.render=function(){return o(e,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_keyboard_accessory_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("KeyboardAccessory",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,i,n){function r(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,a){function o(e){try{s(n.next(e))}catch(e){a(e)}}function u(e){try{s(n["throw"](e))}catch(e){a(e)}}function s(e){e.done?i(e.value):r(e.value).then(o,u)}s((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,r,a,o;return o={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function u(e){return function(t){return s([e,t])}}function s(u){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,u[0]&&(i=0)),i)try{if(n=1,r&&(a=u[0]&2?r["return"]:u[0]?r["throw"]||((a=r["return"])&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;if(r=0,a)u=[u[0]&2,a.value];switch(u[0]){case 0:case 1:a=u;break;case 4:i.label++;return{value:u[1],done:false};case 5:i.label++;r=u[1];u=[0];continue;case 7:u=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){i=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(u[0]===6&&i.label<a[1]){i.label=a[1];a=u;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(u);break}if(a[2])i.ops.pop();i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e];r=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var n=0,r=t.length,a;n<r;n++){if(a||!(n in t)){if(!a)a=Array.prototype.slice.call(t,0,n);a[n]=t[n]}}return e.concat(a||Array.prototype.slice.call(t))};System.register(["./p-7e6b54cb.system.js","./p-2ec68968.system.js"],(function(e){"use strict";var t,i,n,r,a,o;return{setters:[function(e){t=e.r;i=e.c;n=e.h;r=e.H;a=e.g},function(e){o=e.c}],execute:function(){function u(e,t){var i=[];for(var n=e;n<=t;n++){i.push("".concat(n<10?"0":"").concat(n))}return i}var s=__spreadArray(__spreadArray(["20","21","22","23"],u(0,23),true),["00","01","02","03"],false);var h=__spreadArray(__spreadArray(["56","57","58","59"],u(0,59),true),["00","01","02","03"],false);function l(e,t){if(!isNaN(+e)&&e>=0&&e<t.length)return true;return false}function c(e){if(!/^\d{1,2}:\d{1,2}$/.test(e))return false;var t=e.split(":").map((function(e){return+e}));if(t[0]<0||t[0]>23)return false;if(t[1]<0||t[1]>59)return false;return true}function d(e,t){var i=e.split(":").map((function(e){return+e}));var n=t.split(":").map((function(e){return+e}));if(i[0]<n[0])return true;if(i[0]===n[0]&&i[1]<=n[1])return true;return false}function f(e){if(!e)return false;var t=new Date(e.replace(/-/g,"/"));return isNaN(t.getMonth())?false:t}function p(e,t){if(t===4||t===6||t===9||t===11)return 30;if(t===2){if(e%4===0&&e%100!==0||e%400===0)return 29;else return 28}return 31}function v(e){var t;if(Array.isArray(e)){t=e.map((function(e){return String(e)}))}else{t=e}return t}function g(e,t){var i=[];for(var n=e;n<=t;n++){i.push(n)}return i}function m(e,t){return g(e,t)}function y(e,t,i){var n=1;var r=12;if(e.getFullYear()===i){n=e.getMonth()+1}if(t.getFullYear()===i){r=t.getMonth()+1}return g(n,r)}function _(e,t,i,n){var r=1;var a=p(i,n);if(e.getFullYear()===i&&e.getMonth()+1===n){r=e.getDate()}if(t.getFullYear()===i&&t.getMonth()+1===n){a=t.getDate()}return g(r,a)}var k=102;var w=34;var C=w*7;var x=".weui-picker,.weui-picker__hd{font-size:12px}";var M=e("taro_picker_core",function(){function e(e){var r=this;t(this,e);this.onChange=i(this,"change",7);this.onColumnChange=i(this,"columnchange",7);this.onCancel=i(this,"cancel",7);this.index=[];this.showPicker=function(){if(r.disabled)return;r.height=r.getHeightByIndex();r.hidden=false};this.getHeightByIndex=function(){var e=r.index.map((function(e){var t=0;if(r.mode==="time"){t=w*4}return k-w*e-t}));return e};this.hidePicker=function(){r.fadeOut=true;setTimeout((function(){r.hidden=true;r.fadeOut=false}),350)};this.handleChange=function(){r.hidePicker();r.index=r.height.map((function(e){return(k-e)/w}));var e=r.index.length&&r.mode!=="selector"?r.index:r.index[0];if(r.mode==="time"){var t=[s.slice(),h.slice()];var i=r.index.map((function(e,i){return t[i][e]}));r.index=i.map((function(e){return parseInt(e)}));e=i.join(":")}if(r.mode==="date"){var n=r.pickerDate,a=n._start,o=n._end,u=n._updateValue;var l=u[0];var c=u[1];var d=m(a.getFullYear(),o.getFullYear());var f=y(a,o,l);var p=_(a,o,l,c);var v=d[r.index[0]];var g=f[r.index[1]];var C=p[r.index[2]];if(r.fields==="year"){e=[v]}else if(r.fields==="month"){e=[v,g]}else{e=[v,g,C]}e=e.map((function(e){return e<10?"0".concat(e):e})).join("-")}r.value=e;r.pickerValue=r.value;r.onChange.emit({value:e})};this.handleColumnChange=function(e){var t=e.detail,i=t.columnId,n=t.height;r.onColumnChange.emit({column:Number(i),value:(k-n)/w})};this.handleCancel=function(){r.hidePicker();r.onCancel.emit()};this.updateHeight=function(e,t,i){if(i===void 0){i=false}var n=__spreadArray([],r.height,true);n[t]=e;r.height=n;if(i){var a=r,o=a.start,u=a.end;if(!c(o))o="00:00";if(!c(u))u="23:59";if(!d(o,u))return;var l=[s.slice(),h.slice()];var f=r.height.map((function(e){return(k-e)/w}));var p=f.map((function(e,t){return l[t][e]})).join(":");if(!d(o,p)){var v=o.split(":").map((function(e){return k-w*(+e+4)}));requestAnimationFrame((function(){return r.height=v}))}else if(!d(p,u)){var g=u.split(":").map((function(e){return k-w*(+e+4)}));requestAnimationFrame((function(){return r.height=g}))}}};this.updateDay=function(e,t){var i=r.pickerDate,n=i._start,a=i._end,o=i._updateValue;o[t]=e;var u=o[0];var s=o[1];var h=o[2];if(t===0){var l=y(n,a,u);var c=l[l.length-1];var d=l[0];if(s>c)o[1]=c;if(s<d)o[1]=d;var f=l.indexOf(o[1]);var p=k-w*f;r.updateDay(o[1],1);r.updateHeight(p,"1")}else if(t===1){var v=_(n,a,u,s);var c=v[v.length-1];var d=v[0];if(h>c)o[2]=c;if(h<d)o[2]=d;var f=v.indexOf(o[2]);var p=k-w*f;r.updateDay(o[2],2);r.updateHeight(p,"2")}};this.getSelector=function(){return n("taro-picker-group",{range:r.range,rangeKey:r.rangeKey,height:r.height[0],updateHeight:r.updateHeight,columnId:"0"})};this.getMultiSelector=function(){return r.range.map((function(e,t){return n("taro-picker-group",{range:e,rangeKey:r.rangeKey,height:r.height[t],updateHeight:r.updateHeight,onColumnChange:r.handleColumnChange,columnId:String(t)})}))};this.getTimeSelector=function(){var e=s.slice();var t=h.slice();return[n("taro-picker-group",{mode:"time",range:e,height:r.height[0],updateHeight:r.updateHeight,columnId:"0"}),n("taro-picker-group",{mode:"time",range:t,height:r.height[1],updateHeight:r.updateHeight,columnId:"1"})]};this.getDateSelector=function(){var e=r,t=e.fields,i=e.height;var a=r.pickerDate,o=a._start,u=a._end,s=a._updateValue;var h=s[0];var l=s[1];var c=m(o.getFullYear(),u.getFullYear()).map((function(e){return"".concat(e,"年")}));var d=y(o,u,h).map((function(e){return"".concat(e<10?"0".concat(e):e,"月")}));var f=_(o,u,h,l).map((function(e){return"".concat(e<10?"0".concat(e):e,"日")}));var p=[n("taro-picker-group",{mode:"date",range:c,height:i[0],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"0"})];if(t==="month"||t==="day"){p.push(n("taro-picker-group",{mode:"date",range:d,height:i[1],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"1"}))}if(t==="day"){p.push(n("taro-picker-group",{mode:"date",range:f,height:i[2],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"2"}))}return p};this.mode="selector";this.disabled=false;this.range=[];this.rangeKey=undefined;this.value=undefined;this.start="";this.end="";this.fields="day";this.name="";this.textProps={};this.pickerValue=[];this.height=[];this.hidden=true;this.fadeOut=false;this.isWillLoadCalled=false}e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true;this.handleProps()};e.prototype.componentDidLoad=function(){if(this.overlay){document.body.appendChild(this.overlay)}};e.prototype.disconnectedCallback=function(){var e;if(this.overlay){(e=this.overlay.parentNode)===null||e===void 0?void 0:e.removeChild(this.overlay)}};e.prototype.onPropsChange=function(){if(!this.isWillLoadCalled)return;this.handleProps()};e.prototype.handleProps=function(){var e=this;var t=this,i=t.mode,n=t.start,r=t.end;if(i==="selector"){var a=this.value;this.index=[l(a,this.range)?Math.floor(a):0]}else if(i==="multiSelector"){var o=this.value;this.index=[];this.range.forEach((function(t,i){var n=o===null||o===void 0?void 0:o[i];var r=l(n,t)?Math.floor(n):0;e.index.push(r)}))}else if(i==="time"){var a=this.value;if(!c(a)){console.warn("time picker value illegal");a="0:0"}var u=a.split(":").map((function(e){return+e}));this.index=u}else if(i==="date"){var a=this.value;var s=f(a)||new Date((new Date).setHours(0,0,0,0));var h=f(n)||new Date("1970/01/01");var d=f(r)||new Date("2999/01/01");if(s>=h&&s<=d){var p=s.getFullYear();var v=s.getMonth()+1;var g=s.getDate();var k=m(h.getFullYear(),d.getFullYear());var w=y(h,d,p);var C=_(h,d,p,v);this.index=[k.indexOf(p),w.indexOf(v),C.indexOf(g)];if(!this.pickerDate||this.pickerDate._value.getTime()!==s.getTime()||this.pickerDate._start.getTime()!==h.getTime()||this.pickerDate._end.getTime()!==d.getTime()){this.pickerDate={_value:s,_start:h,_end:d,_updateValue:[p,v,g]}}}else{throw new Error("Date Interval Error")}}else{throw new Error('Picker not support "'.concat(i,'" mode.'))}this.height=this.getHeightByIndex();this.pickerValue=this.value;if(i==="date"){var x=this.pickerValue;if(this.fields==="month"){this.pickerValue=x.split("-").slice(0,2).join("-")}else if(this.fields==="year"){this.pickerValue=x.split("-")[0]}}};e.prototype.render=function(){var e=this;var t,i;var a=this,u=a.name,s=a.mode,h=a.fadeOut,l=a.hidden;var c;switch(s){case"multiSelector":c=this.getMultiSelector();break;case"time":c=this.getTimeSelector();break;case"date":c=this.getDateSelector();break;default:c=this.getSelector()}var d=o("weui-mask","weui-animate-fade-in",{"weui-animate-fade-out":h});var f=o("weui-picker","weui-animate-slide-up",{"weui-animate-slide-down":h});var p=l?{display:"none"}:{};return n(r,null,n("div",{onClick:this.showPicker},n("slot",null),n("input",{type:"hidden",name:u,value:v(this.pickerValue)})),n("div",{class:"weui-picker__overlay",style:p,ref:function(t){e.overlay=t}},n("div",{class:d,onClick:this.handleCancel}),n("div",{class:f},n("div",{class:"weui-picker__hd"},n("div",{class:"weui-picker__action",onClick:this.handleCancel},(t=this.textProps.cancelText)!==null&&t!==void 0?t:"取消"),n("div",{class:"weui-picker__action",onClick:this.handleChange},(i=this.textProps.okText)!==null&&i!==void 0?i:"确定")),n("div",{class:"weui-picker__bd"},c),n("input",{type:"hidden",name:u,value:v(this.pickerValue)}))))};Object.defineProperty(e.prototype,"el",{get:function(){return a(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{mode:["onPropsChange"],value:["onPropsChange"],range:["onPropsChange"],start:["onPropsChange"],end:["onPropsChange"]}},enumerable:false,configurable:true});return e}());M.style=x;var D=e("taro_picker_group",function(){function e(e){t(this,e);this.onColumnChange=i(this,"columnChange",7);this.mode=undefined;this.range=[];this.rangeKey=undefined;this.height=undefined;this.columnId=undefined;this.updateHeight=undefined;this.updateDay=undefined;this.startY=undefined;this.preY=undefined;this.hadMove=undefined;this.touchEnd=undefined;this.isMove=undefined}e.prototype.getPosition=function(){var e=this.touchEnd?.3:0;var t="translate3d(0, ".concat(this.height,"px, 0)");var i="transform ".concat(e,"s");return{transform:t,"-webkit-transform":t,transition:i,"-webkit-transition":i}};e.prototype.formulaUnlimitedScroll=function(e,t,i){var n=this;var r=this,a=r.height,o=r.updateHeight,u=r.columnId;var s=i==="up"?1:-1;this.touchEnd=false;o(-e*s*w+a,u);requestAnimationFrame((function(){n.touchEnd=true;var i=Math.round(t/-w)+e*s;var r=k-w*i;o(r,u,true)}))};e.prototype.handleMoveStart=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.startY=e;this.preY=e;this.hadMove=false;return[2]}))}))};e.prototype.handleMoving=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n;return __generator(this,(function(r){t=e;i=t-this.preY;this.preY=t;this.touchEnd=false;if(Math.abs(t-this.startY)>10)this.hadMove=true;n=this.height+i;if(this.mode==="time"){if(this.columnId==="0"){if(n>k-w*3){n=k-w*27+i}if(n<k-w*28){n=k-w*4+i}}else if(this.columnId==="1"){if(n>k-w*3){n=k-w*63+i}if(n<k-w*64){n=k-w*4+i}}}this.updateHeight(n,this.columnId);return[2]}))}))};e.prototype.handleMoveEnd=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n,r,a,o,u,s,h,l,c,d,f,p;return __generator(this,(function(v){t=this,i=t.mode,n=t.range,r=t.height,a=t.updateHeight,o=t.columnId;u=0;s=-w*(n.length-1);h=e;this.touchEnd=true;if(!this.hadMove){c=window.innerHeight;d=c-C/2;l=r-k-(h-d);if(i==="time"){if(o==="0"){if(l>-w*2.5){return[2,this.formulaUnlimitedScroll(24,l,"up")]}if(l<-w*28.5){return[2,this.formulaUnlimitedScroll(24,l,"down")]}}else if(o==="1"){if(l>-w*2.5){return[2,this.formulaUnlimitedScroll(60,l,"up")]}if(l<-w*64.5){return[2,this.formulaUnlimitedScroll(60,l,"down")]}}}}else{l=r-k}if(l>u)l=0;if(l<s)l=s;f=Math.round(l/-w);p=k-w*f;if(this.mode==="date"&&typeof this.updateDay==="function"){if(this.columnId==="0"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),0)}if(this.columnId==="1"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),1)}if(this.columnId==="2"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),2)}}a(p,o,i==="time");this.onColumnChange.emit({columnId:o,height:p});return[2]}))}))};e.prototype.onMouseDown=function(e){this.isMove=true;this.handleMoveStart(e.clientY)};e.prototype.onMouseMove=function(e){if(!this.isMove)return;this.handleMoving(e.clientY)};e.prototype.onMouseMoveEnd=function(e){if(!this.isMove)return;this.isMove=false;this.handleMoveEnd(e.clientY)};e.prototype.onTouchStart=function(e){this.handleMoveStart(e.changedTouches[0].clientY)};e.prototype.onTouchMove=function(e){this.handleMoving(e.changedTouches[0].clientY)};e.prototype.onTouchEnd=function(e){this.handleMoveEnd(e.changedTouches[0].clientY)};e.prototype.render=function(){var e=this,t=e.range,i=e.rangeKey;var a=t.map((function(e){var t=i?e[i]:e;return n("div",{class:"weui-picker__item"},t)}));return n(r,{class:"weui-picker__group"},n("div",{class:"weui-picker__mask"}),n("div",{class:"weui-picker__indicator"}),n("div",{class:"weui-picker__content",style:this.getPosition()},a))};return e}())}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,t,i,n){function r(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,a){function o(e){try{s(n.next(e))}catch(e){a(e)}}function u(e){try{s(n["throw"](e))}catch(e){a(e)}}function s(e){e.done?i(e.value):r(e.value).then(o,u)}s((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,r,a,o;return o={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function u(e){return function(t){return s([e,t])}}function s(u){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,u[0]&&(i=0)),i)try{if(n=1,r&&(a=u[0]&2?r["return"]:u[0]?r["throw"]||((a=r["return"])&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;if(r=0,a)u=[u[0]&2,a.value];switch(u[0]){case 0:case 1:a=u;break;case 4:i.label++;return{value:u[1],done:false};case 5:i.label++;r=u[1];u=[0];continue;case 7:u=i.ops.pop();i.trys.pop();continue;default:if(!(a=i.trys,a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){i=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(u[0]===6&&i.label<a[1]){i.label=a[1];a=u;break}if(a&&i.label<a[2]){i.label=a[2];i.ops.push(u);break}if(a[2])i.ops.pop();i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e];r=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,i){if(i||arguments.length===2)for(var n=0,r=t.length,a;n<r;n++){if(a||!(n in t)){if(!a)a=Array.prototype.slice.call(t,0,n);a[n]=t[n]}}return e.concat(a||Array.prototype.slice.call(t))};System.register(["./p-7e6b54cb.system.js","./p-2ec68968.system.js"],(function(e){"use strict";var t,i,n,r,a,o;return{setters:[function(e){t=e.r;i=e.c;n=e.h;r=e.H;a=e.g},function(e){o=e.c}],execute:function(){function u(e,t){var i=[];for(var n=e;n<=t;n++){i.push("".concat(n<10?"0":"").concat(n))}return i}var s=__spreadArray(__spreadArray(["20","21","22","23"],u(0,23),true),["00","01","02","03"],false);var h=__spreadArray(__spreadArray(["56","57","58","59"],u(0,59),true),["00","01","02","03"],false);function l(e,t){if(!isNaN(+e)&&e>=0&&e<t.length)return true;return false}function c(e){if(!/^\d{1,2}:\d{1,2}$/.test(e))return false;var t=e.split(":").map((function(e){return+e}));if(t[0]<0||t[0]>23)return false;if(t[1]<0||t[1]>59)return false;return true}function d(e,t){var i=e.split(":").map((function(e){return+e}));var n=t.split(":").map((function(e){return+e}));if(i[0]<n[0])return true;if(i[0]===n[0]&&i[1]<=n[1])return true;return false}function f(e){if(!e)return false;var t=new Date(e.replace(/-/g,"/"));return isNaN(t.getMonth())?false:t}function p(e,t){if(t===4||t===6||t===9||t===11)return 30;if(t===2){if(e%4===0&&e%100!==0||e%400===0)return 29;else return 28}return 31}function v(e){var t;if(Array.isArray(e)){t=e.map((function(e){return String(e)}))}else{t=e}return t}function g(e,t){var i=[];for(var n=e;n<=t;n++){i.push(n)}return i}function m(e,t){return g(e,t)}function y(e,t,i){var n=1;var r=12;if(e.getFullYear()===i){n=e.getMonth()+1}if(t.getFullYear()===i){r=t.getMonth()+1}return g(n,r)}function _(e,t,i,n){var r=1;var a=p(i,n);if(e.getFullYear()===i&&e.getMonth()+1===n){r=e.getDate()}if(t.getFullYear()===i&&t.getMonth()+1===n){a=t.getDate()}return g(r,a)}var k=102;var w=34;var C=w*7;var x=".weui-picker,.weui-picker__hd{font-size:12px}";var M=e("taro_picker_core",function(){function e(e){var r=this;t(this,e);this.onChange=i(this,"change",7);this.onColumnChange=i(this,"columnchange",7);this.onCancel=i(this,"cancel",7);this.index=[];this.showPicker=function(){if(r.disabled)return;r.height=r.getHeightByIndex();r.hidden=false};this.getHeightByIndex=function(){var e=r.index.map((function(e){var t=0;if(r.mode==="time"){t=w*4}return k-w*e-t}));return e};this.hidePicker=function(){r.fadeOut=true;setTimeout((function(){r.hidden=true;r.fadeOut=false}),350)};this.handleChange=function(){r.hidePicker();r.index=r.height.map((function(e){return(k-e)/w}));var e=r.index.length&&r.mode!=="selector"?r.index:r.index[0];if(r.mode==="time"){var t=[s.slice(),h.slice()];var i=r.index.map((function(e,i){return t[i][e]}));r.index=i.map((function(e){return parseInt(e)}));e=i.join(":")}if(r.mode==="date"){var n=r.pickerDate,a=n._start,o=n._end,u=n._updateValue;var l=u[0];var c=u[1];var d=m(a.getFullYear(),o.getFullYear());var f=y(a,o,l);var p=_(a,o,l,c);var v=d[r.index[0]];var g=f[r.index[1]];var C=p[r.index[2]];if(r.fields==="year"){e=[v]}else if(r.fields==="month"){e=[v,g]}else{e=[v,g,C]}e=e.map((function(e){return e<10?"0".concat(e):e})).join("-")}r.value=e;r.pickerValue=r.value;r.onChange.emit({value:e})};this.handleColumnChange=function(e){var t=e.detail,i=t.columnId,n=t.height;r.onColumnChange.emit({column:Number(i),value:(k-n)/w})};this.handleCancel=function(){r.hidePicker();r.onCancel.emit()};this.updateHeight=function(e,t,i){if(i===void 0){i=false}var n=__spreadArray([],r.height,true);n[t]=e;r.height=n;if(i){var a=r,o=a.start,u=a.end;if(!c(o))o="00:00";if(!c(u))u="23:59";if(!d(o,u))return;var l=[s.slice(),h.slice()];var f=r.height.map((function(e){return(k-e)/w}));var p=f.map((function(e,t){return l[t][e]})).join(":");if(!d(o,p)){var v=o.split(":").map((function(e){return k-w*(+e+4)}));requestAnimationFrame((function(){return r.height=v}))}else if(!d(p,u)){var g=u.split(":").map((function(e){return k-w*(+e+4)}));requestAnimationFrame((function(){return r.height=g}))}}};this.updateDay=function(e,t){var i=r.pickerDate,n=i._start,a=i._end,o=i._updateValue;o[t]=e;var u=o[0];var s=o[1];var h=o[2];if(t===0){var l=y(n,a,u);var c=l[l.length-1];var d=l[0];if(s>c)o[1]=c;if(s<d)o[1]=d;var f=l.indexOf(o[1]);var p=k-w*f;r.updateDay(o[1],1);r.updateHeight(p,"1")}else if(t===1){var v=_(n,a,u,s);var c=v[v.length-1];var d=v[0];if(h>c)o[2]=c;if(h<d)o[2]=d;var f=v.indexOf(o[2]);var p=k-w*f;r.updateDay(o[2],2);r.updateHeight(p,"2")}};this.getSelector=function(){return n("taro-picker-group",{range:r.range,rangeKey:r.rangeKey,height:r.height[0],updateHeight:r.updateHeight,columnId:"0"})};this.getMultiSelector=function(){return r.range.map((function(e,t){return n("taro-picker-group",{range:e,rangeKey:r.rangeKey,height:r.height[t],updateHeight:r.updateHeight,onColumnChange:r.handleColumnChange,columnId:String(t)})}))};this.getTimeSelector=function(){var e=s.slice();var t=h.slice();return[n("taro-picker-group",{mode:"time",range:e,height:r.height[0],updateHeight:r.updateHeight,columnId:"0"}),n("taro-picker-group",{mode:"time",range:t,height:r.height[1],updateHeight:r.updateHeight,columnId:"1"})]};this.getDateSelector=function(){var e=r,t=e.fields,i=e.height;var a=r.pickerDate,o=a._start,u=a._end,s=a._updateValue;var h=s[0];var l=s[1];var c=m(o.getFullYear(),u.getFullYear()).map((function(e){return"".concat(e,"年")}));var d=y(o,u,h).map((function(e){return"".concat(e<10?"0".concat(e):e,"月")}));var f=_(o,u,h,l).map((function(e){return"".concat(e<10?"0".concat(e):e,"日")}));var p=[n("taro-picker-group",{mode:"date",range:c,height:i[0],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"0"})];if(t==="month"||t==="day"){p.push(n("taro-picker-group",{mode:"date",range:d,height:i[1],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"1"}))}if(t==="day"){p.push(n("taro-picker-group",{mode:"date",range:f,height:i[2],updateDay:r.updateDay,updateHeight:r.updateHeight,columnId:"2"}))}return p};this.mode="selector";this.disabled=false;this.range=[];this.rangeKey=undefined;this.value=undefined;this.start="";this.end="";this.fields="day";this.name="";this.textProps={};this.pickerValue=[];this.height=[];this.hidden=true;this.fadeOut=false;this.isWillLoadCalled=false}e.prototype.componentWillLoad=function(){this.isWillLoadCalled=true;this.handleProps()};e.prototype.componentDidLoad=function(){if(this.overlay){document.body.appendChild(this.overlay)}};e.prototype.disconnectedCallback=function(){var e;if(this.overlay){(e=this.overlay.parentNode)===null||e===void 0?void 0:e.removeChild(this.overlay)}};e.prototype.onPropsChange=function(){if(!this.isWillLoadCalled)return;this.handleProps()};e.prototype.handleProps=function(){var e=this;var t=this,i=t.mode,n=t.start,r=t.end;if(i==="selector"){var a=this.value;this.index=[l(a,this.range)?Math.floor(a):0]}else if(i==="multiSelector"){var o=this.value;this.index=[];this.range.forEach((function(t,i){var n=o===null||o===void 0?void 0:o[i];var r=l(n,t)?Math.floor(n):0;e.index.push(r)}))}else if(i==="time"){var a=this.value;if(!c(a)){console.warn("time picker value illegal");a="0:0"}var u=a.split(":").map((function(e){return+e}));this.index=u}else if(i==="date"){var a=this.value;var s=f(a)||new Date((new Date).setHours(0,0,0,0));var h=f(n)||new Date("1970/01/01");var d=f(r)||new Date("2999/01/01");if(!(h<=d)){throw new Error("Picker start time must be less than end time.")}if(!(s>=h&&s<=d)){s=h}var p=s.getFullYear();var v=s.getMonth()+1;var g=s.getDate();var k=m(h.getFullYear(),d.getFullYear());var w=y(h,d,p);var C=_(h,d,p,v);this.index=[k.indexOf(p),w.indexOf(v),C.indexOf(g)];if(!this.pickerDate||this.pickerDate._value.getTime()!==s.getTime()||this.pickerDate._start.getTime()!==h.getTime()||this.pickerDate._end.getTime()!==d.getTime()){this.pickerDate={_value:s,_start:h,_end:d,_updateValue:[p,v,g]}}}else{throw new Error('Picker not support "'.concat(i,'" mode.'))}this.height=this.getHeightByIndex();this.pickerValue=this.value;if(i==="date"){var x=this.pickerValue;if(this.fields==="month"){this.pickerValue=x.split("-").slice(0,2).join("-")}else if(this.fields==="year"){this.pickerValue=x.split("-")[0]}}};e.prototype.render=function(){var e=this;var t,i;var a=this,u=a.name,s=a.mode,h=a.fadeOut,l=a.hidden;var c;switch(s){case"multiSelector":c=this.getMultiSelector();break;case"time":c=this.getTimeSelector();break;case"date":c=this.getDateSelector();break;default:c=this.getSelector()}var d=o("weui-mask","weui-animate-fade-in",{"weui-animate-fade-out":h});var f=o("weui-picker","weui-animate-slide-up",{"weui-animate-slide-down":h});var p=l?{display:"none"}:{};return n(r,null,n("div",{onClick:this.showPicker},n("slot",null),n("input",{type:"hidden",name:u,value:v(this.pickerValue)})),n("div",{class:"weui-picker__overlay",style:p,ref:function(t){e.overlay=t}},n("div",{class:d,onClick:this.handleCancel}),n("div",{class:f},n("div",{class:"weui-picker__hd"},n("div",{class:"weui-picker__action",onClick:this.handleCancel},(t=this.textProps.cancelText)!==null&&t!==void 0?t:"取消"),n("div",{class:"weui-picker__action",onClick:this.handleChange},(i=this.textProps.okText)!==null&&i!==void 0?i:"确定")),n("div",{class:"weui-picker__bd"},c),n("input",{type:"hidden",name:u,value:v(this.pickerValue)}))))};Object.defineProperty(e.prototype,"el",{get:function(){return a(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{mode:["onPropsChange"],value:["onPropsChange"],range:["onPropsChange"],start:["onPropsChange"],end:["onPropsChange"]}},enumerable:false,configurable:true});return e}());M.style=x;var b=e("taro_picker_group",function(){function e(e){t(this,e);this.onColumnChange=i(this,"columnChange",7);this.mode=undefined;this.range=[];this.rangeKey=undefined;this.height=undefined;this.columnId=undefined;this.updateHeight=undefined;this.updateDay=undefined;this.startY=undefined;this.preY=undefined;this.hadMove=undefined;this.touchEnd=undefined;this.isMove=undefined}e.prototype.getPosition=function(){var e=this.touchEnd?.3:0;var t="translate3d(0, ".concat(this.height,"px, 0)");var i="transform ".concat(e,"s");return{transform:t,"-webkit-transform":t,transition:i,"-webkit-transition":i}};e.prototype.formulaUnlimitedScroll=function(e,t,i){var n=this;var r=this,a=r.height,o=r.updateHeight,u=r.columnId;var s=i==="up"?1:-1;this.touchEnd=false;o(-e*s*w+a,u);requestAnimationFrame((function(){n.touchEnd=true;var i=Math.round(t/-w)+e*s;var r=k-w*i;o(r,u,true)}))};e.prototype.handleMoveStart=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.startY=e;this.preY=e;this.hadMove=false;return[2]}))}))};e.prototype.handleMoving=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n;return __generator(this,(function(r){t=e;i=t-this.preY;this.preY=t;this.touchEnd=false;if(Math.abs(t-this.startY)>10)this.hadMove=true;n=this.height+i;if(this.mode==="time"){if(this.columnId==="0"){if(n>k-w*3){n=k-w*27+i}if(n<k-w*28){n=k-w*4+i}}else if(this.columnId==="1"){if(n>k-w*3){n=k-w*63+i}if(n<k-w*64){n=k-w*4+i}}}this.updateHeight(n,this.columnId);return[2]}))}))};e.prototype.handleMoveEnd=function(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n,r,a,o,u,s,h,l,c,d,f,p;return __generator(this,(function(v){t=this,i=t.mode,n=t.range,r=t.height,a=t.updateHeight,o=t.columnId;u=0;s=-w*(n.length-1);h=e;this.touchEnd=true;if(!this.hadMove){c=window.innerHeight;d=c-C/2;l=r-k-(h-d);if(i==="time"){if(o==="0"){if(l>-w*2.5){return[2,this.formulaUnlimitedScroll(24,l,"up")]}if(l<-w*28.5){return[2,this.formulaUnlimitedScroll(24,l,"down")]}}else if(o==="1"){if(l>-w*2.5){return[2,this.formulaUnlimitedScroll(60,l,"up")]}if(l<-w*64.5){return[2,this.formulaUnlimitedScroll(60,l,"down")]}}}}else{l=r-k}if(l>u)l=0;if(l<s)l=s;f=Math.round(l/-w);p=k-w*f;if(this.mode==="date"&&typeof this.updateDay==="function"){if(this.columnId==="0"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),0)}if(this.columnId==="1"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),1)}if(this.columnId==="2"){this.updateDay(+this.range[f].replace(/[^0-9]/gi,""),2)}}a(p,o,i==="time");this.onColumnChange.emit({columnId:o,height:p});return[2]}))}))};e.prototype.onMouseDown=function(e){this.isMove=true;this.handleMoveStart(e.clientY)};e.prototype.onMouseMove=function(e){if(!this.isMove)return;this.handleMoving(e.clientY)};e.prototype.onMouseMoveEnd=function(e){if(!this.isMove)return;this.isMove=false;this.handleMoveEnd(e.clientY)};e.prototype.onTouchStart=function(e){this.handleMoveStart(e.changedTouches[0].clientY)};e.prototype.onTouchMove=function(e){this.handleMoving(e.changedTouches[0].clientY)};e.prototype.onTouchEnd=function(e){this.handleMoveEnd(e.changedTouches[0].clientY)};e.prototype.render=function(){var e=this,t=e.range,i=e.rangeKey;var a=t.map((function(e){var t=i?e[i]:e;return n("div",{class:"weui-picker__item"},t)}));return n(r,{class:"weui-picker__group"},n("div",{class:"weui-picker__mask"}),n("div",{class:"weui-picker__indicator"}),n("div",{class:"weui-picker__content",style:this.getPosition()},a))};return e}())}}}));
@@ -1 +1 @@
1
- import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("RtcRoom",this)}render(){return r(t,null)}};export{a as taro_rtc_room_core}
1
+ import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("RtcRoom",this)}render(){return r(t,null)}};export{a as taro_rtc_room_core}
@@ -0,0 +1 @@
1
+ import{r,h as o,H as t}from"./p-9137dcab.js";import{n as a}from"./p-dbdb9de9.js";import"@tarojs/taro";const s=class{constructor(o){r(this,o)}componentDidLoad(){a("PageMeta",this)}render(){return o(t,null)}};export{s as taro_page_meta_core}
@@ -1 +1 @@
1
- import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("Slot",this)}render(){return r(t,null)}};export{a as taro_slot_core}
1
+ import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("Slot",this)}render(){return r(t,null)}};export{a as taro_slot_core}
@@ -1 +1 @@
1
- import{r,h as o,H as s}from"./p-9137dcab.js";import{n as t}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(o){r(this,o)}componentDidLoad(){t("Tabs",this)}render(){return o(s,null)}};export{a as taro_tabs_core}
1
+ import{r,h as o,H as s}from"./p-9137dcab.js";import{n as t}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(o){r(this,o)}componentDidLoad(){t("Tabs",this)}render(){return o(s,null)}};export{a as taro_tabs_core}
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,r,e,o;return{setters:[function(t){n=t.r;r=t.h;e=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_ar_camera_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("ArCamera",this)};t.prototype.render=function(){return r(e,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,o,r,e;return{setters:[function(t){n=t.r;o=t.h;r=t.H},function(t){e=t.n},function(){}],execute:function(){var c=t("taro_voip_room_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){e("VoipRoom",this)};t.prototype.render=function(){return o(r,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ import{r,h as o,H as t}from"./p-9137dcab.js";import{n as a}from"./p-dbdb9de9.js";import"@tarojs/taro";const s=class{constructor(o){r(this,o)}componentDidLoad(){a("PageContainer",this)}render(){return o(t,null)}};export{s as taro_page_container_core}
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,r,e,o;return{setters:[function(t){n=t.r;r=t.h;e=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_editor_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Editor",this)};t.prototype.render=function(){return r(e,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var i=t("taro_tab_item_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("TabItem",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_tab_item_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("TabItem",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -1 +1 @@
1
- import{r,h as o,H as s}from"./p-9137dcab.js";import{n as t}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(o){r(this,o)}componentDidLoad(){t("LivePusher",this)}render(){return o(s,null)}};export{a as taro_live_pusher_core}
1
+ import{r,h as o,H as s}from"./p-9137dcab.js";import{n as t}from"./p-dbdb9de9.js";import"@tarojs/taro";const e=class{constructor(o){r(this,o)}componentDidLoad(){t("LivePusher",this)}render(){return o(s,null)}};export{e as taro_live_pusher_core}
@@ -0,0 +1 @@
1
+ import{r,h as o,H as t}from"./p-9137dcab.js";import{n as e}from"./p-dbdb9de9.js";import"@tarojs/taro";const s=class{constructor(o){r(this,o)}componentDidLoad(){e("ShareElement",this)}render(){return o(t,null)}};export{s as taro_share_element_core}
@@ -0,0 +1 @@
1
+ import{r as o,h as r,H as s}from"./p-9137dcab.js";import{n as t}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){t("FollowSwan",this)}render(){return r(s,null)}};export{a as taro_follow_swan_core}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as i,g as h}from"./p-9137dcab.js";const o=class{constructor(i){t(this,i),this.onLongTap=s(this,"longtap",7),this.onTouchStart=()=>{this.timer=setTimeout((()=>{this.onLongTap.emit()}),500)},this.onTouchMove=()=>{clearTimeout(this.timer)},this.onTouchEnd=()=>{clearTimeout(this.timer)},this.canvasId=void 0,this.height=void 0,this.width=void 0,this.nativeProps={}}componentDidRender(){const[t]=this.el.children;if(!this.height||!this.width){let s=window.getComputedStyle(t);this.height||(this.height=s.height),this.width||(this.width=s.width)}t.height=parseInt(this.height),t.width=parseInt(this.width)}render(){const{canvasId:t,nativeProps:s}=this;return i("canvas",Object.assign({"canvas-id":t,style:{width:"100%",height:"100%"},onTouchStart:this.onTouchStart,onTouchMove:this.onTouchMove,onTouchCancel:this.onTouchEnd,onTouchEnd:this.onTouchEnd},s))}get el(){return h(this)}};o.style="taro-canvas-core{display:block;position:relative;width:300px;height:150px}";export{o as taro_canvas_core}
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var i=t("taro_animation_view_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("AnimationView",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var i=t("taro_animation_view_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("AnimationView",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var e,n,r,o;return{setters:[function(t){e=t.r;n=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var s=t("taro_share_element_core",function(){function t(t){e(this,t)}t.prototype.componentDidLoad=function(){o("ShareElement",this)};t.prototype.render=function(){return n(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var e,n,r,o;return{setters:[function(t){e=t.r;n=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_share_element_core",function(){function t(t){e(this,t)}t.prototype.componentDidLoad=function(){o("ShareElement",this)};t.prototype.render=function(){return n(r,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_match_media_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("MatchMedia",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_match_media_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("MatchMedia",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,o,e,r;return{setters:[function(t){n=t.r;o=t.h;e=t.H},function(t){r=t.n},function(){}],execute:function(){var c=t("taro_login_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("Login",this)};t.prototype.render=function(){return o(e,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,o,e,r;return{setters:[function(t){n=t.r;o=t.h;e=t.H},function(t){r=t.n},function(){}],execute:function(){var c=t("taro_slot_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("Slot",this)};t.prototype.render=function(){return o(e,null)};return t}())}}}));
@@ -1 +1 @@
1
- import{r,h as o,H as t}from"./p-9137dcab.js";import{n as s}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(o){r(this,o)}componentDidLoad(){s("ListView",this)}render(){return o(t,null)}};export{a as taro_list_view_core}
1
+ import{r,h as o,H as t}from"./p-9137dcab.js";import{n as s}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(o){r(this,o)}componentDidLoad(){s("ListView",this)}render(){return o(t,null)}};export{a as taro_list_view_core}
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var i=t("taro_lottie_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("Lottie",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var c=t("taro_lottie_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("Lottie",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var s=t("taro_tabs_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Tabs",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var s=t("taro_tabs_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Tabs",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var i=t("taro_channel_live_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("ChannelLive",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_channel_live_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("ChannelLive",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var s=t("taro_open_data_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("OpenData",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,o,r;return{setters:[function(t){n=t.r;e=t.h;o=t.H},function(t){r=t.n},function(){}],execute:function(){var c=t("taro_open_data_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){r("OpenData",this)};t.prototype.render=function(){return e(o,null)};return t}())}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var i=t("taro_page_container_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("PageContainer",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_page_container_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("PageContainer",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js"],(function(t){"use strict";var i,e,n,h;return{setters:[function(t){i=t.r;e=t.c;n=t.h;h=t.g}],execute:function(){var o="taro-canvas-core{display:block;position:relative;width:300px;height:150px}";var s=500;var r=t("taro_canvas_core",function(){function t(t){var n=this;i(this,t);this.onLongTap=e(this,"longtap",7);this.onTouchStart=function(){n.timer=setTimeout((function(){n.onLongTap.emit()}),s)};this.onTouchMove=function(){clearTimeout(n.timer)};this.onTouchEnd=function(){clearTimeout(n.timer)};this.canvasId=undefined;this.height=undefined;this.width=undefined;this.nativeProps={}}t.prototype.componentDidRender=function(){var t=this.el.children[0];if(!this.height||!this.width){var i=window.getComputedStyle(t);this.height||(this.height=i.height);this.width||(this.width=i.width)}t.height=parseInt(this.height);t.width=parseInt(this.width)};t.prototype.render=function(){var t=this,i=t.canvasId,e=t.nativeProps;return n("canvas",Object.assign({"canvas-id":i,style:{width:"100%",height:"100%"},onTouchStart:this.onTouchStart,onTouchMove:this.onTouchMove,onTouchCancel:this.onTouchEnd,onTouchEnd:this.onTouchEnd},e))};Object.defineProperty(t.prototype,"el",{get:function(){return h(this)},enumerable:false,configurable:true});return t}());r.style=o}}}));
@@ -1 +1 @@
1
- System.register(["./p-7e6b54cb.system.js","./p-15e45ed6.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var s=t("taro_ad_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Ad",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var c=t("taro_ad_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Ad",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ System.register(["./p-7e6b54cb.system.js","./p-8c3b906c.system.js","@tarojs/taro"],(function(t){"use strict";var n,e,r,o;return{setters:[function(t){n=t.r;e=t.h;r=t.H},function(t){o=t.n},function(){}],execute:function(){var s=t("taro_lifestyle_core",function(){function t(t){n(this,t)}t.prototype.componentDidLoad=function(){o("Lifestyle",this)};t.prototype.render=function(){return e(r,null)};return t}())}}}));
@@ -0,0 +1 @@
1
+ import{r as o,h as r,H as a}from"./p-9137dcab.js";import{n as t}from"./p-dbdb9de9.js";import"@tarojs/taro";const n=class{constructor(r){o(this,r)}componentDidLoad(){t("FunctionalPageNavigator",this)}render(){return r(a,null)}};export{n as taro_functional_page_navigator_core}
@@ -1 +1 @@
1
- import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-6a96da58.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("VoipRoom",this)}render(){return r(t,null)}};export{a as taro_voip_room_core}
1
+ import{r as o,h as r,H as t}from"./p-9137dcab.js";import{n as s}from"./p-dbdb9de9.js";import"@tarojs/taro";const a=class{constructor(r){o(this,r)}componentDidLoad(){s("VoipRoom",this)}render(){return r(t,null)}};export{a as taro_voip_room_core}
@@ -0,0 +1 @@
1
+ var __spreadArray=this&&this.__spreadArray||function(e,t,a){if(a||arguments.length===2)for(var r=0,o=t.length,n;r<o;r++){if(n||!(r in t)){if(!n)n=Array.prototype.slice.call(t,0,r);n[r]=t[r]}}return e.concat(n||Array.prototype.slice.call(t))};System.register(["./p-7e6b54cb.system.js","@tarojs/taro","@tarojs/router/dist/utils","./p-2ec68968.system.js","./p-bd5177d3.system.js"],(function(e){"use strict";var t,a,r,o,n,i,s,l,d,b,h,c;return{setters:[function(e){t=e.h;a=e.r;r=e.c;o=e.H;n=e.g},function(e){i=e.default},function(e){s=e.stripSuffix;l=e.stripBasename;d=e.addLeadingSlash;b=e.getCurrentPage},function(e){h=e.c},function(e){c=e.i}],execute:function(){var f=function(e){var t=e||"";var a;var r={path:null,query:null,fragment:null};a=t.indexOf("#");if(a>-1){r.fragment=t.substring(a+1);t=t.substring(0,a)}a=t.indexOf("?");if(a>-1){r.query=t.substring(a+1);t=t.substring(0,a)}r.path=t;return r};function u(e){return e.charAt(0)==="/"}function v(e,t){for(var a=t,r=a+1,o=e.length;r<o;a+=1,r+=1){e[a]=e[r]}e.pop()}function g(e,t){if(t===undefined)t="";var a=e&&e.split("/")||[];var r=t&&t.split("/")||[];var o=e&&u(e);var n=t&&u(t);var i=o||n;if(e&&u(e)){r=a}else if(a.length){r.pop();r=r.concat(a)}if(!r.length)return"/";var s;if(r.length){var l=r[r.length-1];s=l==="."||l===".."||l===""}else{s=false}var d=0;for(var b=r.length;b>=0;b--){var h=r[b];if(h==="."){v(r,b)}else if(h===".."){v(r,b);d++}else if(d){v(r,b);d--}}if(!i)for(;d--;d)r.unshift("..");if(i&&r[0]!==""&&(!r[0]||!u(r[0])))r.unshift("");var c=r.join("/");if(s&&c.substr(-1)!=="/")c+="/";return c}var p=function(e){var a=e.index,r=e.isSelected,o=r===void 0?false:r,n=e.textColor,s=e.iconPath,l=e.badgeText,d=e.showRedDot,b=d===void 0?false:d,f=e.pagePath,u=e.text,v=e.onSelect;var g=h("weui-tabbar__item",{"weui-bar__item_on":o});var p={position:"absolute",top:"-2px",right:"-13px"};var _={position:"absolute",top:"0",right:"-6px"};function m(){var e=i.getCurrentPages().shift();if(typeof(e===null||e===void 0?void 0:e.onTabItemTap)==="function"&&c(this)){e.onTabItemTap({index:a,pagePath:f,text:u})}v(a)}return t("a",{key:a,href:"javascript:;",class:g,onClick:m},t("span",{style:{display:"inline-block",position:"relative"}},t("img",{src:s,alt:"",class:"weui-tabbar__icon"}),!!l&&t("span",{class:"weui-badge taro-tabbar-badge",style:p},l),b&&t("span",{class:"weui-badge weui-badge_dot",style:_})),t("p",{class:"weui-tabbar__label",style:{color:n}},u))};var _="html,body{height:100%}:root{--taro-tabbar-height:50px}#app{height:100%}.taro-tabbar__border-white::before{border-top-color:#fff !important}.taro-tabbar__container{display:-ms-flexbox;display:flex;overflow:hidden;-ms-flex-direction:column;flex-direction:column;height:100%}.taro-tabbar__panel{overflow:auto;position:relative;-ms-flex:1;flex:1;-webkit-overflow-scrolling:auto}.taro-tabbar__tabbar{position:relative;width:100%;height:var(--taro-tabbar-height);-webkit-transition:bottom 0.2s, top 0.2s;transition:bottom 0.2s, top 0.2s}.taro-tabbar__tabbar-top{top:0}.taro-tabbar__tabbar-bottom{bottom:0;margin-bottom:constant(safe-area-inset-bottom);margin-bottom:env(safe-area-inset-bottom)}.taro-tabbar__tabbar-hide{display:none}.taro-tabbar__tabbar-slideout{top:-52px;-ms-flex:0 0;flex:0 0}.taro-tabbar__panel+.taro-tabbar__tabbar-slideout{top:auto;bottom:-52px}";var m=0;var T=1;var B=2;var y="taro-tabbar__tabbar";var H="taro-tabbar__tabbar-hide";var x="taro-tabbar__tabbar-slideout";var C=e("taro_tabbar",function(){function e(e){var t=this;a(this,e);this.onLongPress=r(this,"longpress",7);this.homePage="";this.customRoutes=[];this.tabbarPos="bottom";this.getOriginUrl=function(e){var a=t.customRoutes.filter((function(t){var a=t[1];var r=f(a).path;var o=f(e).path;return r===o}));return s(a.length?a[0][0]:e,".html")};this.getSelectedIndex=function(e){var a=-1;t.list.forEach((function(t,r){var o=t.pagePath;var n=f(e).path;var i=f(o).path;if(n===i){a=r}}));return a};this.switchTab=function(e){t.selectedIndex=e;i.switchTab({url:t.list[e].pagePath})};this.switchTabHandler=function(e){var a=e.url,r=e.successHandler,o=e.errorHandler;var n=t.getOriginUrl(t.getCurrentUrl()||t.homePage);var i=g(a,n);var s=t.getSelectedIndex(i);if(s>-1){t.switchTab(s);r({errMsg:"switchTab:ok"})}else{o({errMsg:'switchTab:fail page "'.concat(i,'" is not found')})}};this.routerChangeHandler=function(e){var a;var r=(a=e===null||e===void 0?void 0:e.toLocation)===null||a===void 0?void 0:a.path;var o;if(typeof r==="string"){var n=t.conf.basename||"/";o=l(d(r||t.homePage),n)||"/"}else{o=t.getCurrentUrl()}t.selectedIndex=t.getSelectedIndex(t.getOriginUrl(o))};this.setTabBarBadgeHandler=function(e){var a=e.index,r=e.text,o=e.successHandler,n=e.errorHandler;var i=__spreadArray([],t.list,true);if(a in i){i[a].showRedDot=false;i[a].badgeText=r;o({errMsg:"setTabBarBadge:ok"})}else{n({errMsg:"setTabBarBadge:fail tabbar item not found"})}t.list=i};this.removeTabBarBadgeHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].badgeText=null;r({errMsg:"removeTabBarBadge:ok"})}else{o({errMsg:"removeTabBarBadge:fail tabbar item not found"})}t.list=n};this.showTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].badgeText=null;n[a].showRedDot=true;r({errMsg:"showTabBarRedDot:ok"})}else{o({errMsg:"showTabBarRedDot:fail tabbar item not found"})}t.list=n};this.hideTabBarRedDotHandler=function(e){var a=e.index,r=e.successHandler,o=e.errorHandler;var n=__spreadArray([],t.list,true);if(a in n){n[a].showRedDot=false;r({errMsg:"hideTabBarRedDot:ok"})}else{o({errMsg:"hideTabBarRedDot:fail tabbar item not found"})}t.list=n};this.showTabBarHandler=function(e){var a=e.successHandler;t.status=m;a({errMsg:"showTabBar:ok"})};this.hideTabBarHandler=function(e){var a=e.animation,r=e.successHandler;t.status=a?B:T;r({errMsg:"hideTabBar:ok"})};this.setTabBarStyleHandler=function(e){var a=e.color,r=e.selectedColor,o=e.backgroundColor,n=e.borderStyle,i=e.successHandler;if(o)t.backgroundColor=o;if(n)t.borderStyle=n;if(a)t.color=a;if(r)t.selectedColor=r;i({errMsg:"setTabBarStyle:ok"})};this.setTabBarItemHandler=function(e){var a=e.index,r=e.iconPath,o=e.selectedIconPath,n=e.text,i=e.successHandler,s=e.errorHandler;var l=__spreadArray([],t.list,true);if(a in l){if(r)l[a].iconPath=r;if(o)l[a].selectedIconPath=o;if(n)l[a].text=n;i({errMsg:"setTabBarItem:ok"})}else{s({errMsg:"setTabBarItem:fail tabbar item not found"})}t.list=l};this.conf=undefined;this.list=undefined;this.borderStyle=undefined;this.backgroundColor=undefined;this.color=undefined;this.selectedColor=undefined;this.selectedIndex=-1;this.status=m}e.prototype.componentWillLoad=function(){var e,t;var a=((e=this.conf)===null||e===void 0?void 0:e.list)||[];var r=((t=this.conf)===null||t===void 0?void 0:t.customRoutes)||{};if(Object.prototype.toString.call(a)!=="[object Array]"||a.length<2||a.length>5){throw new Error("tabBar 配置错误")}this.homePage=d(this.conf.homePage);var o=function(e){var t;var a=r[e];e=d(e);if(typeof a==="string"){n.customRoutes.push([e,d(a)])}else if((a===null||a===void 0?void 0:a.length)>0){(t=n.customRoutes).push.apply(t,a.map((function(t){return[e,d(t)]})))}};var n=this;for(var i in r){o(i)}a.forEach((function(e){if(e.pagePath.indexOf("/")!==0){e.pagePath="/"+e.pagePath}}));this.list=a;this.borderStyle=this.conf.borderStyle;this.backgroundColor=this.conf.backgroundColor;this.color=this.conf.color;this.selectedColor=this.conf.selectedColor};e.prototype.getCurrentUrl=function(){var e=b(this.conf.mode,this.conf.basename);return decodeURI(e==="/"?this.homePage:e)};e.prototype.bindEvent=function(){i.eventCenter.on("__taroRouterChange",this.routerChangeHandler);i.eventCenter.on("__taroSwitchTab",this.switchTabHandler);i.eventCenter.on("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.on("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.on("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.on("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.on("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.on("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.on("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.on("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.removeEvent=function(){i.eventCenter.off("__taroRouterChange",this.routerChangeHandler);i.eventCenter.off("__taroSwitchTab",this.switchTabHandler);i.eventCenter.off("__taroSetTabBarBadge",this.setTabBarBadgeHandler);i.eventCenter.off("__taroRemoveTabBarBadge",this.removeTabBarBadgeHandler);i.eventCenter.off("__taroShowTabBarRedDotHandler",this.showTabBarRedDotHandler);i.eventCenter.off("__taroHideTabBarRedDotHandler",this.hideTabBarRedDotHandler);i.eventCenter.off("__taroShowTabBar",this.showTabBarHandler);i.eventCenter.off("__taroHideTabBar",this.hideTabBarHandler);i.eventCenter.off("__taroSetTabBarStyle",this.setTabBarStyleHandler);i.eventCenter.off("__taroSetTabBarItem",this.setTabBarItemHandler)};e.prototype.componentDidLoad=function(){this.tabbarPos=this.tabbar.nextElementSibling?"top":"bottom";this.bindEvent();this.routerChangeHandler()};e.prototype.disconnectedCallback=function(){this.removeEvent()};e.prototype.render=function(){var e,a;var r=this;var n=this.tabbarPos,i=n===void 0?"bottom":n;var s=this.status;var l=h("weui-tabbar",(e={},e["taro-tabbar__border-".concat(this.borderStyle||"black")]=true,e));var d=this.selectedIndex===-1||s===T;var b=s===B;return t(o,{class:h(y,"".concat(y,"-").concat(i),(a={},a[H]=d,a[x]=b,a))},t("div",{class:l,style:{backgroundColor:this.backgroundColor||"",height:"inherit"}},this.list.map((function(e,a){var o=r.selectedIndex===a;var n;var i;if(o){n=r.selectedColor||"";i=e.selectedIconPath}else{n=r.color||"";i=e.iconPath}return t(p,{index:a,onSelect:r.switchTab.bind(r),isSelected:o,textColor:n,iconPath:i,pagePath:e.pagePath,text:e.text,badgeText:e.badgeText,showRedDot:e.showRedDot})}))))};Object.defineProperty(e.prototype,"tabbar",{get:function(){return n(this)},enumerable:false,configurable:true});return e}());C.style=_}}}));
@@ -1 +1 @@
1
- import{r as t,c as i,h as o,H as e}from"./p-9137dcab.js";import{c as a}from"./p-de951a46.js";import("./p-72f327e1.js");const h=class{constructor(o){t(this,o),this.onLoad=i(this,"load",7),this.onError=i(this,"error",7),this.src=void 0,this.mode="scaleToFill",this.lazyLoad=!1,this.nativeProps={},this.aspectFillMode="width",this.didLoad=!1}componentDidLoad(){if(!this.lazyLoad)return;const t=new IntersectionObserver((i=>{i[i.length-1].isIntersecting&&(t.unobserve(this.imgRef),this.didLoad=!0)}),{rootMargin:"300px 0px"});t.observe(this.imgRef)}imageOnLoad(){const{width:t,height:i,naturalWidth:o,naturalHeight:e}=this.imgRef;this.onLoad.emit({width:t,height:i}),this.aspectFillMode=o>e?"width":"height"}imageOnError(t){this.onError.emit(t)}render(){const{src:t,mode:i="scaleToFill",lazyLoad:h=!1,aspectFillMode:s="width",imageOnLoad:r,imageOnError:m,nativeProps:d,didLoad:g}=this,l=a({"taro-img__widthfix":"widthFix"===i}),n=a(`taro-img__mode-${i.toLowerCase().replace(/\s/g,"")}`,{[`taro-img__mode-aspectfill--${s}`]:"aspectFill"===i});return o(e,{class:l},o("img",Object.assign({ref:t=>this.imgRef=t,class:n,src:h&&!g?void 0:t,onLoad:r.bind(this),onError:m.bind(this)},d)))}};h.style='img[src=""]{opacity:0}taro-image-core{display:inline-block;overflow:hidden;position:relative;width:auto;height:auto;font-size:0}.taro-img.taro-img__widthfix{height:100%}.taro-img__mode-scaletofill{width:100%;height:100%}.taro-img__mode-aspectfit{max-width:100%;max-height:100%}.taro-img__mode-aspectfill{position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.taro-img__mode-aspectfill--width{min-width:100%;height:100%}.taro-img__mode-aspectfill--height{width:100%;min-height:100%}.taro-img__mode-widthfix{width:100%}.taro-img__mode-heightfix{height:100%}.taro-img__mode-top{width:100%}.taro-img__mode-bottom{position:absolute;bottom:0;width:100%}.taro-img__mode-left{height:100%}.taro-img__mode-right{position:absolute;right:0;height:100%}.taro-img__mode-topright{position:absolute;right:0}.taro-img__mode-bottomleft{position:absolute;bottom:0}.taro-img__mode-bottomright{position:absolute;right:0;bottom:0}';export{h as taro_image_core}
1
+ import{r as t,c as i,h as o,H as e}from"./p-9137dcab.js";import{c as a}from"./p-de951a46.js";import("./p-72f327e1.js");const h=class{constructor(o){t(this,o),this.onLoad=i(this,"load",7),this.onError=i(this,"error",7),this.src=void 0,this.mode="scaleToFill",this.lazyLoad=!1,this.nativeProps={},this.aspectFillMode="width",this.didLoad=!1}componentDidLoad(){if(!this.lazyLoad)return;const t=new IntersectionObserver((i=>{i[i.length-1].isIntersecting&&(t.unobserve(this.imgRef),this.didLoad=!0)}),{rootMargin:"300px 0px"});t.observe(this.imgRef)}imageOnLoad(){const{width:t,height:i,naturalWidth:o,naturalHeight:e}=this.imgRef;this.onLoad.emit({width:t,height:i}),this.aspectFillMode=o>e?"width":"height"}imageOnError(t){this.onError.emit(t)}render(){const{src:t,mode:i="scaleToFill",lazyLoad:h=!1,aspectFillMode:s="width",imageOnLoad:r,imageOnError:m,nativeProps:d,didLoad:g}=this,l=a({"taro-img__widthfix":"widthFix"===i}),n=a(`taro-img__mode-${i.toLowerCase().replace(/\s/g,"")}`,{[`taro-img__mode-aspectfill--${s}`]:"aspectFill"===i});return o(e,{class:l},o("img",Object.assign({ref:t=>this.imgRef=t,class:n,src:h&&!g?void 0:t,onLoad:r.bind(this),onError:m.bind(this)},d)))}};h.style='img[src=""]{opacity:0}taro-image-core{display:inline-block;overflow:hidden;position:relative;width:320px;height:240px;font-size:0}.taro-img.taro-img__widthfix{height:100%}.taro-img__mode-scaletofill{width:100%;height:100%}.taro-img__mode-aspectfit{max-width:100%;max-height:100%}.taro-img__mode-aspectfill{position:absolute;left:50%;top:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.taro-img__mode-aspectfill--width{min-width:100%;height:100%}.taro-img__mode-aspectfill--height{width:100%;min-height:100%}.taro-img__mode-widthfix{width:100%}.taro-img__mode-heightfix{height:100%}.taro-img__mode-top{width:100%}.taro-img__mode-bottom{position:absolute;bottom:0;width:100%}.taro-img__mode-left{height:100%}.taro-img__mode-right{position:absolute;right:0;height:100%}.taro-img__mode-topright{position:absolute;right:0}.taro-img__mode-bottomleft{position:absolute;bottom:0}.taro-img__mode-bottomright{position:absolute;right:0;bottom:0}';export{h as taro_image_core}