vant 4.0.0-alpha.0 → 4.0.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (581) hide show
  1. package/README.md +141 -0
  2. package/changelog.generated.md +198 -0
  3. package/es/address-edit/AddressEdit.d.ts +0 -17
  4. package/es/address-edit/AddressEdit.js +3 -24
  5. package/es/address-edit/index.d.ts +0 -12
  6. package/es/address-edit/types.d.ts +0 -1
  7. package/es/address-list/AddressListItem.d.ts +3 -2
  8. package/es/address-list/AddressListItem.js +1 -1
  9. package/es/badge/Badge.d.ts +4 -3
  10. package/es/badge/index.d.ts +2 -2
  11. package/es/calendar/Calendar.d.ts +4 -0
  12. package/es/calendar/Calendar.js +3 -1
  13. package/es/calendar/CalendarDay.js +4 -0
  14. package/es/calendar/index.css +1 -1
  15. package/es/calendar/index.d.ts +3 -0
  16. package/es/calendar/index.less +3 -0
  17. package/es/calendar/types.d.ts +2 -1
  18. package/es/cascader/types.d.ts +2 -1
  19. package/es/checkbox/Checker.d.ts +2 -1
  20. package/es/collapse/Collapse.d.ts +7 -6
  21. package/es/collapse/index.d.ts +3 -3
  22. package/es/composables/use-touch.js +1 -1
  23. package/es/config-provider/ConfigProvider.d.ts +4 -3
  24. package/es/config-provider/ConfigProvider.js +2 -0
  25. package/es/config-provider/index.d.ts +2 -2
  26. package/es/contact-list/ContactList.d.ts +3 -2
  27. package/es/coupon/Coupon.d.ts +2 -1
  28. package/es/coupon-list/CouponList.d.ts +3 -13
  29. package/es/coupon-list/CouponList.js +9 -7
  30. package/es/coupon-list/index.css +1 -1
  31. package/es/coupon-list/index.d.ts +2 -9
  32. package/es/coupon-list/index.less +4 -16
  33. package/es/coupon-list/style/index.js +1 -0
  34. package/es/coupon-list/style/less.js +1 -0
  35. package/es/date-picker/DatePicker.js +1 -1
  36. package/es/dialog/index.css +1 -1
  37. package/es/dialog/index.less +2 -0
  38. package/es/dialog/types.d.ts +2 -2
  39. package/es/dropdown-item/types.d.ts +2 -1
  40. package/es/empty/Empty.d.ts +8 -7
  41. package/es/empty/Empty.js +12 -15
  42. package/es/empty/Images.d.ts +4 -0
  43. package/es/empty/Images.js +271 -0
  44. package/es/empty/index.d.ts +2 -2
  45. package/es/field/Field.d.ts +4 -0
  46. package/es/field/Field.js +8 -3
  47. package/es/field/index.d.ts +2 -0
  48. package/es/field/types.d.ts +1 -1
  49. package/es/form/Form.d.ts +13 -13
  50. package/es/form/Form.js +7 -3
  51. package/es/form/index.d.ts +9 -9
  52. package/es/form/types.d.ts +1 -0
  53. package/es/icon/index.css +1 -1
  54. package/es/index-bar/IndexBar.d.ts +5 -4
  55. package/es/index-bar/IndexBar.js +25 -4
  56. package/es/index-bar/index.d.ts +3 -3
  57. package/es/index-bar/types.d.ts +2 -1
  58. package/es/index.d.ts +1 -1
  59. package/es/index.js +1 -1
  60. package/es/loading/Loading.js +3 -1
  61. package/es/locale/lang/bn-BD.d.ts +0 -2
  62. package/es/locale/lang/bn-BD.js +0 -2
  63. package/es/locale/lang/da-DK.d.ts +64 -0
  64. package/es/locale/lang/da-DK.js +66 -0
  65. package/es/locale/lang/de-DE-formal.d.ts +0 -2
  66. package/es/locale/lang/de-DE-formal.js +0 -2
  67. package/es/locale/lang/de-DE.d.ts +0 -2
  68. package/es/locale/lang/de-DE.js +0 -2
  69. package/es/locale/lang/en-US.d.ts +0 -2
  70. package/es/locale/lang/en-US.js +0 -2
  71. package/es/locale/lang/es-ES.d.ts +0 -2
  72. package/es/locale/lang/es-ES.js +0 -2
  73. package/es/locale/lang/fr-FR.d.ts +0 -2
  74. package/es/locale/lang/fr-FR.js +0 -2
  75. package/es/locale/lang/hi-IN.d.ts +0 -2
  76. package/es/locale/lang/hi-IN.js +0 -2
  77. package/es/locale/lang/id-ID.d.ts +0 -2
  78. package/es/locale/lang/id-ID.js +0 -2
  79. package/es/locale/lang/is-IS.d.ts +62 -0
  80. package/es/locale/lang/is-IS.js +72 -0
  81. package/es/locale/lang/it-IT.d.ts +0 -2
  82. package/es/locale/lang/it-IT.js +0 -2
  83. package/es/locale/lang/ja-JP.d.ts +0 -2
  84. package/es/locale/lang/ja-JP.js +0 -2
  85. package/es/locale/lang/ko-KR.d.ts +0 -2
  86. package/es/locale/lang/ko-KR.js +0 -2
  87. package/es/locale/lang/la-LA.d.ts +62 -0
  88. package/es/locale/lang/la-LA.js +64 -0
  89. package/es/locale/lang/nb-NO.d.ts +0 -2
  90. package/es/locale/lang/nb-NO.js +0 -2
  91. package/es/locale/lang/pt-BR.d.ts +0 -2
  92. package/es/locale/lang/pt-BR.js +0 -2
  93. package/es/locale/lang/ro-RO.d.ts +0 -2
  94. package/es/locale/lang/ro-RO.js +0 -2
  95. package/es/locale/lang/ru-RU.d.ts +0 -2
  96. package/es/locale/lang/ru-RU.js +0 -2
  97. package/es/locale/lang/sv-SE.d.ts +62 -0
  98. package/es/locale/lang/sv-SE.js +64 -0
  99. package/es/locale/lang/th-TH.d.ts +0 -2
  100. package/es/locale/lang/th-TH.js +0 -2
  101. package/es/locale/lang/tr-TR.d.ts +0 -2
  102. package/es/locale/lang/tr-TR.js +0 -2
  103. package/es/locale/lang/uk-UA.d.ts +0 -2
  104. package/es/locale/lang/uk-UA.js +0 -2
  105. package/es/locale/lang/vi-VN.d.ts +0 -2
  106. package/es/locale/lang/vi-VN.js +0 -2
  107. package/es/locale/lang/zh-CN.d.ts +0 -2
  108. package/es/locale/lang/zh-CN.js +0 -2
  109. package/es/locale/lang/zh-HK.d.ts +0 -2
  110. package/es/locale/lang/zh-HK.js +0 -2
  111. package/es/locale/lang/zh-TW.d.ts +0 -2
  112. package/es/locale/lang/zh-TW.js +0 -2
  113. package/es/nav-bar/NavBar.d.ts +1 -1
  114. package/es/nav-bar/NavBar.js +3 -3
  115. package/es/nav-bar/index.d.ts +1 -1
  116. package/es/notify/types.d.ts +2 -1
  117. package/es/number-keyboard/NumberKeyboard.js +10 -1
  118. package/es/picker/Picker.d.ts +5 -4
  119. package/es/picker/index.css +1 -1
  120. package/es/picker/index.d.ts +3 -3
  121. package/es/picker/index.less +1 -0
  122. package/es/picker/types.d.ts +4 -3
  123. package/es/picker/utils.d.ts +4 -3
  124. package/es/popup/Popup.d.ts +4 -0
  125. package/es/popup/Popup.js +3 -0
  126. package/es/popup/index.css +1 -1
  127. package/es/popup/index.d.ts +3 -0
  128. package/es/progress/Progress.d.ts +4 -3
  129. package/es/progress/index.d.ts +2 -2
  130. package/es/rate/Rate.js +32 -10
  131. package/es/search/Search.d.ts +3 -0
  132. package/es/search/index.css +1 -1
  133. package/es/search/index.d.ts +2 -0
  134. package/es/search/index.less +1 -1
  135. package/es/share-sheet/ShareSheet.js +25 -11
  136. package/es/share-sheet/index.css +1 -1
  137. package/es/share-sheet/index.less +45 -1
  138. package/es/skeleton/Skeleton.d.ts +5 -4
  139. package/es/skeleton/Skeleton.js +6 -4
  140. package/es/skeleton/index.d.ts +3 -3
  141. package/es/slider/index.css +1 -1
  142. package/es/style/animation.css +1 -1
  143. package/es/style/base.css +1 -1
  144. package/es/style/base.less +5 -0
  145. package/es/swipe-cell/SwipeCell.js +1 -1
  146. package/es/swipe-cell/index.css +1 -1
  147. package/es/tabbar/Tabbar.d.ts +2 -2
  148. package/es/tabs/Tabs.d.ts +1 -1
  149. package/es/tabs/Tabs.js +1 -0
  150. package/es/tabs/types.d.ts +5 -4
  151. package/es/toast/Toast.js +1 -0
  152. package/es/toast/types.d.ts +3 -2
  153. package/es/tree-select/TreeSelect.d.ts +7 -6
  154. package/es/tree-select/index.d.ts +3 -3
  155. package/es/uploader/Uploader.d.ts +4 -4
  156. package/es/uploader/Uploader.js +3 -3
  157. package/es/uploader/UploaderPreviewItem.d.ts +3 -3
  158. package/es/uploader/UploaderPreviewItem.js +9 -6
  159. package/es/uploader/index.d.ts +2 -2
  160. package/es/uploader/types.d.ts +5 -5
  161. package/es/uploader/utils.d.ts +0 -1
  162. package/es/uploader/utils.js +2 -4
  163. package/es/utils/basic.d.ts +2 -0
  164. package/es/utils/basic.js +3 -1
  165. package/es/utils/format.d.ts +7 -6
  166. package/es/utils/format.js +6 -0
  167. package/es/utils/validate.d.ts +2 -1
  168. package/lib/action-bar/ActionBar.js +8 -13
  169. package/lib/action-bar/index.js +9 -16
  170. package/lib/action-bar-button/ActionBarButton.js +8 -13
  171. package/lib/action-bar-button/index.js +9 -16
  172. package/lib/action-bar-icon/ActionBarIcon.js +8 -13
  173. package/lib/action-bar-icon/index.js +9 -16
  174. package/lib/action-sheet/ActionSheet.js +8 -13
  175. package/lib/action-sheet/index.js +9 -16
  176. package/lib/address-edit/AddressEdit.d.ts +0 -17
  177. package/lib/address-edit/AddressEdit.js +12 -40
  178. package/lib/address-edit/AddressEditDetail.js +8 -13
  179. package/lib/address-edit/index.d.ts +0 -12
  180. package/lib/address-edit/index.js +9 -16
  181. package/lib/address-edit/types.d.ts +0 -1
  182. package/lib/address-edit/types.js +7 -12
  183. package/lib/address-list/AddressList.js +9 -16
  184. package/lib/address-list/AddressListItem.d.ts +3 -2
  185. package/lib/address-list/AddressListItem.js +8 -13
  186. package/lib/address-list/index.js +9 -16
  187. package/lib/area/Area.js +8 -13
  188. package/lib/area/index.js +9 -16
  189. package/lib/area/types.js +7 -12
  190. package/lib/area/utils.js +8 -13
  191. package/lib/badge/Badge.d.ts +4 -3
  192. package/lib/badge/Badge.js +8 -13
  193. package/lib/badge/index.d.ts +2 -2
  194. package/lib/badge/index.js +9 -16
  195. package/lib/button/Button.js +8 -13
  196. package/lib/button/index.js +9 -16
  197. package/lib/button/types.js +7 -12
  198. package/lib/calendar/Calendar.d.ts +4 -0
  199. package/lib/calendar/Calendar.js +12 -17
  200. package/lib/calendar/CalendarDay.js +12 -13
  201. package/lib/calendar/CalendarHeader.js +8 -13
  202. package/lib/calendar/CalendarMonth.js +9 -16
  203. package/lib/calendar/index.css +1 -1
  204. package/lib/calendar/index.d.ts +3 -0
  205. package/lib/calendar/index.js +9 -16
  206. package/lib/calendar/index.less +3 -0
  207. package/lib/calendar/types.d.ts +2 -1
  208. package/lib/calendar/types.js +7 -12
  209. package/lib/calendar/utils.js +8 -13
  210. package/lib/card/Card.js +8 -13
  211. package/lib/card/index.js +9 -16
  212. package/lib/cascader/Cascader.js +8 -13
  213. package/lib/cascader/index.js +9 -16
  214. package/lib/cascader/types.d.ts +2 -1
  215. package/lib/cascader/types.js +7 -12
  216. package/lib/cell/Cell.js +8 -13
  217. package/lib/cell/index.js +9 -16
  218. package/lib/cell-group/CellGroup.js +8 -13
  219. package/lib/cell-group/index.js +9 -16
  220. package/lib/checkbox/Checkbox.js +9 -16
  221. package/lib/checkbox/Checker.d.ts +2 -1
  222. package/lib/checkbox/Checker.js +8 -13
  223. package/lib/checkbox/index.js +9 -16
  224. package/lib/checkbox/types.js +7 -12
  225. package/lib/checkbox-group/CheckboxGroup.js +8 -13
  226. package/lib/checkbox-group/index.js +9 -16
  227. package/lib/checkbox-group/types.js +7 -12
  228. package/lib/circle/Circle.js +8 -13
  229. package/lib/circle/index.js +9 -16
  230. package/lib/col/Col.js +8 -13
  231. package/lib/col/index.js +9 -16
  232. package/lib/collapse/Collapse.d.ts +7 -6
  233. package/lib/collapse/Collapse.js +8 -13
  234. package/lib/collapse/index.d.ts +3 -3
  235. package/lib/collapse/index.js +9 -16
  236. package/lib/collapse-item/CollapseItem.js +8 -13
  237. package/lib/collapse-item/index.js +9 -16
  238. package/lib/collapse-item/types.js +7 -12
  239. package/lib/composables/on-popup-reopen.js +8 -13
  240. package/lib/composables/use-expose.js +8 -13
  241. package/lib/composables/use-height.js +8 -13
  242. package/lib/composables/use-id.js +8 -13
  243. package/lib/composables/use-lazy-render.js +8 -13
  244. package/lib/composables/use-lock-scroll.js +8 -13
  245. package/lib/composables/use-placeholder.js +8 -13
  246. package/lib/composables/use-refs.js +8 -13
  247. package/lib/composables/use-route.js +8 -13
  248. package/lib/composables/use-tab-status.js +8 -13
  249. package/lib/composables/use-touch.js +9 -14
  250. package/lib/composables/use-visibility-change.js +8 -13
  251. package/lib/config-provider/ConfigProvider.d.ts +4 -3
  252. package/lib/config-provider/ConfigProvider.js +10 -13
  253. package/lib/config-provider/index.d.ts +2 -2
  254. package/lib/config-provider/index.js +9 -16
  255. package/lib/contact-card/ContactCard.js +8 -13
  256. package/lib/contact-card/index.js +9 -16
  257. package/lib/contact-edit/ContactEdit.js +8 -13
  258. package/lib/contact-edit/index.js +9 -16
  259. package/lib/contact-list/ContactList.d.ts +3 -2
  260. package/lib/contact-list/ContactList.js +8 -13
  261. package/lib/contact-list/index.js +9 -16
  262. package/lib/count-down/CountDown.js +8 -13
  263. package/lib/count-down/index.js +9 -16
  264. package/lib/count-down/types.js +7 -12
  265. package/lib/count-down/utils.js +8 -13
  266. package/lib/coupon/Coupon.d.ts +2 -1
  267. package/lib/coupon/Coupon.js +8 -13
  268. package/lib/coupon/index.js +9 -16
  269. package/lib/coupon/utils.js +8 -13
  270. package/lib/coupon-cell/CouponCell.js +8 -13
  271. package/lib/coupon-cell/index.js +9 -16
  272. package/lib/coupon-list/CouponList.d.ts +3 -13
  273. package/lib/coupon-list/CouponList.js +17 -20
  274. package/lib/coupon-list/index.css +1 -1
  275. package/lib/coupon-list/index.d.ts +2 -9
  276. package/lib/coupon-list/index.js +9 -16
  277. package/lib/coupon-list/index.less +4 -16
  278. package/lib/coupon-list/style/index.js +1 -0
  279. package/lib/coupon-list/style/less.js +1 -0
  280. package/lib/date-picker/DatePicker.js +9 -14
  281. package/lib/date-picker/index.js +9 -16
  282. package/lib/date-picker/utils.js +8 -13
  283. package/lib/dialog/Dialog.js +8 -13
  284. package/lib/dialog/function-call.js +9 -16
  285. package/lib/dialog/index.css +1 -1
  286. package/lib/dialog/index.js +8 -13
  287. package/lib/dialog/index.less +2 -0
  288. package/lib/dialog/types.d.ts +2 -2
  289. package/lib/dialog/types.js +7 -12
  290. package/lib/divider/Divider.js +8 -13
  291. package/lib/divider/index.js +9 -16
  292. package/lib/dropdown-item/DropdownItem.js +8 -13
  293. package/lib/dropdown-item/index.js +9 -16
  294. package/lib/dropdown-item/types.d.ts +2 -1
  295. package/lib/dropdown-item/types.js +7 -12
  296. package/lib/dropdown-menu/DropdownMenu.js +8 -13
  297. package/lib/dropdown-menu/index.js +9 -16
  298. package/lib/dropdown-menu/types.js +7 -12
  299. package/lib/empty/Empty.d.ts +8 -7
  300. package/lib/empty/Empty.js +19 -27
  301. package/lib/empty/Images.d.ts +4 -0
  302. package/lib/empty/Images.js +290 -0
  303. package/lib/empty/index.d.ts +2 -2
  304. package/lib/empty/index.js +9 -16
  305. package/lib/field/Field.d.ts +4 -0
  306. package/lib/field/Field.js +15 -15
  307. package/lib/field/index.d.ts +2 -0
  308. package/lib/field/index.js +9 -16
  309. package/lib/field/types.d.ts +1 -1
  310. package/lib/field/types.js +7 -12
  311. package/lib/field/utils.js +8 -13
  312. package/lib/form/Form.d.ts +13 -13
  313. package/lib/form/Form.js +14 -15
  314. package/lib/form/index.d.ts +9 -9
  315. package/lib/form/index.js +9 -16
  316. package/lib/form/types.d.ts +1 -0
  317. package/lib/form/types.js +7 -12
  318. package/lib/grid/Grid.js +8 -13
  319. package/lib/grid/index.js +9 -16
  320. package/lib/grid-item/GridItem.js +8 -13
  321. package/lib/grid-item/index.js +9 -16
  322. package/lib/icon/Icon.js +8 -13
  323. package/lib/icon/index.css +1 -1
  324. package/lib/icon/index.js +9 -16
  325. package/lib/image/Image.js +8 -13
  326. package/lib/image/index.js +9 -16
  327. package/lib/image-preview/ImagePreview.js +9 -16
  328. package/lib/image-preview/ImagePreviewItem.js +8 -13
  329. package/lib/image-preview/function-call.js +9 -16
  330. package/lib/image-preview/index.js +8 -13
  331. package/lib/image-preview/types.js +7 -12
  332. package/lib/index-anchor/IndexAnchor.js +8 -13
  333. package/lib/index-anchor/index.js +9 -16
  334. package/lib/index-bar/IndexBar.d.ts +5 -4
  335. package/lib/index-bar/IndexBar.js +33 -17
  336. package/lib/index-bar/index.d.ts +3 -3
  337. package/lib/index-bar/index.js +9 -16
  338. package/lib/index-bar/types.d.ts +2 -1
  339. package/lib/index-bar/types.js +7 -12
  340. package/lib/index.css +1 -1
  341. package/lib/index.d.ts +1 -1
  342. package/lib/index.js +97 -101
  343. package/lib/index.less +2 -2
  344. package/lib/lazyload/index.js +8 -13
  345. package/lib/lazyload/vue-lazyload/index.js +9 -16
  346. package/lib/lazyload/vue-lazyload/lazy-component.js +8 -13
  347. package/lib/lazyload/vue-lazyload/lazy-container.js +8 -13
  348. package/lib/lazyload/vue-lazyload/lazy-image.js +8 -13
  349. package/lib/lazyload/vue-lazyload/lazy.js +9 -16
  350. package/lib/lazyload/vue-lazyload/listener.js +8 -13
  351. package/lib/lazyload/vue-lazyload/util.js +8 -13
  352. package/lib/list/List.js +8 -13
  353. package/lib/list/index.js +9 -16
  354. package/lib/list/types.js +7 -12
  355. package/lib/loading/Loading.js +11 -14
  356. package/lib/loading/index.js +9 -16
  357. package/lib/locale/index.js +9 -16
  358. package/lib/locale/lang/bn-BD.d.ts +0 -2
  359. package/lib/locale/lang/bn-BD.js +8 -15
  360. package/lib/locale/lang/da-DK.d.ts +64 -0
  361. package/lib/locale/lang/da-DK.js +85 -0
  362. package/lib/locale/lang/de-DE-formal.d.ts +0 -2
  363. package/lib/locale/lang/de-DE-formal.js +8 -15
  364. package/lib/locale/lang/de-DE.d.ts +0 -2
  365. package/lib/locale/lang/de-DE.js +8 -15
  366. package/lib/locale/lang/en-US.d.ts +0 -2
  367. package/lib/locale/lang/en-US.js +8 -15
  368. package/lib/locale/lang/es-ES.d.ts +0 -2
  369. package/lib/locale/lang/es-ES.js +8 -15
  370. package/lib/locale/lang/fr-FR.d.ts +0 -2
  371. package/lib/locale/lang/fr-FR.js +8 -15
  372. package/lib/locale/lang/hi-IN.d.ts +0 -2
  373. package/lib/locale/lang/hi-IN.js +8 -15
  374. package/lib/locale/lang/id-ID.d.ts +0 -2
  375. package/lib/locale/lang/id-ID.js +8 -15
  376. package/lib/locale/lang/is-IS.d.ts +62 -0
  377. package/lib/locale/lang/is-IS.js +91 -0
  378. package/lib/locale/lang/it-IT.d.ts +0 -2
  379. package/lib/locale/lang/it-IT.js +8 -15
  380. package/lib/locale/lang/ja-JP.d.ts +0 -2
  381. package/lib/locale/lang/ja-JP.js +8 -15
  382. package/lib/locale/lang/ko-KR.d.ts +0 -2
  383. package/lib/locale/lang/ko-KR.js +8 -15
  384. package/lib/locale/lang/la-LA.d.ts +62 -0
  385. package/lib/locale/lang/la-LA.js +83 -0
  386. package/lib/locale/lang/nb-NO.d.ts +0 -2
  387. package/lib/locale/lang/nb-NO.js +8 -15
  388. package/lib/locale/lang/pt-BR.d.ts +0 -2
  389. package/lib/locale/lang/pt-BR.js +8 -15
  390. package/lib/locale/lang/ro-RO.d.ts +0 -2
  391. package/lib/locale/lang/ro-RO.js +8 -15
  392. package/lib/locale/lang/ru-RU.d.ts +0 -2
  393. package/lib/locale/lang/ru-RU.js +8 -15
  394. package/lib/locale/lang/sv-SE.d.ts +62 -0
  395. package/lib/locale/lang/sv-SE.js +83 -0
  396. package/lib/locale/lang/th-TH.d.ts +0 -2
  397. package/lib/locale/lang/th-TH.js +8 -15
  398. package/lib/locale/lang/tr-TR.d.ts +0 -2
  399. package/lib/locale/lang/tr-TR.js +8 -15
  400. package/lib/locale/lang/uk-UA.d.ts +0 -2
  401. package/lib/locale/lang/uk-UA.js +8 -15
  402. package/lib/locale/lang/vi-VN.d.ts +0 -2
  403. package/lib/locale/lang/vi-VN.js +8 -15
  404. package/lib/locale/lang/zh-CN.d.ts +0 -2
  405. package/lib/locale/lang/zh-CN.js +8 -15
  406. package/lib/locale/lang/zh-HK.d.ts +0 -2
  407. package/lib/locale/lang/zh-HK.js +8 -15
  408. package/lib/locale/lang/zh-TW.d.ts +0 -2
  409. package/lib/locale/lang/zh-TW.js +8 -15
  410. package/lib/nav-bar/NavBar.d.ts +1 -1
  411. package/lib/nav-bar/NavBar.js +11 -16
  412. package/lib/nav-bar/index.d.ts +1 -1
  413. package/lib/nav-bar/index.js +9 -16
  414. package/lib/notice-bar/NoticeBar.js +8 -13
  415. package/lib/notice-bar/index.js +9 -16
  416. package/lib/notice-bar/types.js +7 -12
  417. package/lib/notify/Notify.js +8 -13
  418. package/lib/notify/function-call.js +9 -16
  419. package/lib/notify/index.js +8 -13
  420. package/lib/notify/types.d.ts +2 -1
  421. package/lib/notify/types.js +7 -12
  422. package/lib/number-keyboard/NumberKeyboard.js +19 -17
  423. package/lib/number-keyboard/NumberKeyboardKey.js +8 -13
  424. package/lib/number-keyboard/index.js +9 -16
  425. package/lib/overlay/Overlay.js +8 -13
  426. package/lib/overlay/index.js +9 -16
  427. package/lib/pagination/Pagination.js +8 -13
  428. package/lib/pagination/index.js +9 -16
  429. package/lib/password-input/PasswordInput.js +8 -13
  430. package/lib/password-input/index.js +9 -16
  431. package/lib/picker/Picker.d.ts +5 -4
  432. package/lib/picker/Picker.js +9 -16
  433. package/lib/picker/PickerColumn.js +8 -13
  434. package/lib/picker/index.css +1 -1
  435. package/lib/picker/index.d.ts +3 -3
  436. package/lib/picker/index.js +9 -16
  437. package/lib/picker/index.less +1 -0
  438. package/lib/picker/types.d.ts +4 -3
  439. package/lib/picker/types.js +7 -12
  440. package/lib/picker/utils.d.ts +4 -3
  441. package/lib/picker/utils.js +8 -13
  442. package/lib/popover/Popover.js +8 -13
  443. package/lib/popover/index.js +9 -16
  444. package/lib/popover/types.js +7 -12
  445. package/lib/popup/Popup.d.ts +4 -0
  446. package/lib/popup/Popup.js +11 -13
  447. package/lib/popup/index.css +1 -1
  448. package/lib/popup/index.d.ts +3 -0
  449. package/lib/popup/index.js +9 -16
  450. package/lib/popup/shared.js +8 -13
  451. package/lib/popup/types.js +7 -12
  452. package/lib/progress/Progress.d.ts +4 -3
  453. package/lib/progress/Progress.js +8 -13
  454. package/lib/progress/index.d.ts +2 -2
  455. package/lib/progress/index.js +9 -16
  456. package/lib/progress/types.js +7 -12
  457. package/lib/pull-refresh/PullRefresh.js +8 -13
  458. package/lib/pull-refresh/index.js +9 -16
  459. package/lib/radio/Radio.js +9 -16
  460. package/lib/radio/index.js +9 -16
  461. package/lib/radio-group/RadioGroup.js +8 -13
  462. package/lib/radio-group/index.js +9 -16
  463. package/lib/rate/Rate.js +39 -22
  464. package/lib/rate/index.js +9 -16
  465. package/lib/row/Row.js +8 -13
  466. package/lib/row/index.js +9 -16
  467. package/lib/search/Search.d.ts +3 -0
  468. package/lib/search/Search.js +8 -13
  469. package/lib/search/index.css +1 -1
  470. package/lib/search/index.d.ts +2 -0
  471. package/lib/search/index.js +9 -16
  472. package/lib/search/index.less +1 -1
  473. package/lib/search/types.js +7 -12
  474. package/lib/share-sheet/ShareSheet.js +33 -24
  475. package/lib/share-sheet/index.css +1 -1
  476. package/lib/share-sheet/index.js +9 -16
  477. package/lib/share-sheet/index.less +45 -1
  478. package/lib/sidebar/Sidebar.js +8 -13
  479. package/lib/sidebar/index.js +9 -16
  480. package/lib/sidebar-item/SidebarItem.js +8 -13
  481. package/lib/sidebar-item/index.js +9 -16
  482. package/lib/skeleton/Skeleton.d.ts +5 -4
  483. package/lib/skeleton/Skeleton.js +13 -16
  484. package/lib/skeleton/index.d.ts +3 -3
  485. package/lib/skeleton/index.js +9 -16
  486. package/lib/slider/Slider.js +8 -13
  487. package/lib/slider/index.css +1 -1
  488. package/lib/slider/index.js +9 -16
  489. package/lib/step/Step.js +8 -13
  490. package/lib/step/index.js +9 -16
  491. package/lib/stepper/Stepper.js +8 -13
  492. package/lib/stepper/index.js +9 -16
  493. package/lib/steps/Steps.js +8 -13
  494. package/lib/steps/index.js +9 -16
  495. package/lib/sticky/Sticky.js +8 -13
  496. package/lib/sticky/index.js +9 -16
  497. package/lib/style/animation.css +1 -1
  498. package/lib/style/base.css +1 -1
  499. package/lib/style/base.less +5 -0
  500. package/lib/submit-bar/SubmitBar.js +8 -13
  501. package/lib/submit-bar/index.js +9 -16
  502. package/lib/swipe/Swipe.js +8 -13
  503. package/lib/swipe/index.js +9 -16
  504. package/lib/swipe/types.js +7 -12
  505. package/lib/swipe-cell/SwipeCell.js +9 -14
  506. package/lib/swipe-cell/index.css +1 -1
  507. package/lib/swipe-cell/index.js +9 -16
  508. package/lib/swipe-cell/types.js +7 -12
  509. package/lib/swipe-item/SwipeItem.js +8 -13
  510. package/lib/swipe-item/index.js +9 -16
  511. package/lib/switch/Switch.js +8 -13
  512. package/lib/switch/index.js +9 -16
  513. package/lib/tab/Tab.js +8 -13
  514. package/lib/tab/index.js +9 -16
  515. package/lib/tabbar/Tabbar.d.ts +2 -2
  516. package/lib/tabbar/Tabbar.js +8 -13
  517. package/lib/tabbar/index.js +9 -16
  518. package/lib/tabbar-item/TabbarItem.js +8 -13
  519. package/lib/tabbar-item/index.js +9 -16
  520. package/lib/tabs/Tabs.d.ts +1 -1
  521. package/lib/tabs/Tabs.js +10 -16
  522. package/lib/tabs/TabsContent.js +8 -13
  523. package/lib/tabs/TabsTitle.js +8 -13
  524. package/lib/tabs/index.js +9 -16
  525. package/lib/tabs/types.d.ts +5 -4
  526. package/lib/tabs/types.js +7 -12
  527. package/lib/tabs/utils.js +8 -13
  528. package/lib/tag/Tag.js +8 -13
  529. package/lib/tag/index.js +9 -16
  530. package/lib/time-picker/TimePicker.js +8 -13
  531. package/lib/time-picker/index.js +9 -16
  532. package/lib/toast/Toast.js +9 -13
  533. package/lib/toast/function-call.js +9 -16
  534. package/lib/toast/index.js +8 -13
  535. package/lib/toast/lock-click.js +8 -13
  536. package/lib/toast/types.d.ts +3 -2
  537. package/lib/toast/types.js +7 -12
  538. package/lib/tree-select/TreeSelect.d.ts +7 -6
  539. package/lib/tree-select/TreeSelect.js +8 -13
  540. package/lib/tree-select/index.d.ts +3 -3
  541. package/lib/tree-select/index.js +9 -16
  542. package/lib/uploader/Uploader.d.ts +4 -4
  543. package/lib/uploader/Uploader.js +11 -18
  544. package/lib/uploader/UploaderPreviewItem.d.ts +3 -3
  545. package/lib/uploader/UploaderPreviewItem.js +17 -19
  546. package/lib/uploader/index.d.ts +2 -2
  547. package/lib/uploader/index.js +9 -16
  548. package/lib/uploader/types.d.ts +5 -5
  549. package/lib/uploader/types.js +7 -12
  550. package/lib/uploader/utils.d.ts +0 -1
  551. package/lib/uploader/utils.js +10 -17
  552. package/lib/utils/basic.d.ts +2 -0
  553. package/lib/utils/basic.js +11 -14
  554. package/lib/utils/constant.js +8 -13
  555. package/lib/utils/create.js +9 -16
  556. package/lib/utils/deep-assign.js +8 -13
  557. package/lib/utils/deep-clone.js +8 -13
  558. package/lib/utils/dom.js +8 -13
  559. package/lib/utils/format.d.ts +7 -6
  560. package/lib/utils/format.js +14 -13
  561. package/lib/utils/index.js +17 -21
  562. package/lib/utils/interceptor.js +8 -13
  563. package/lib/utils/mount-component.js +8 -13
  564. package/lib/utils/props.js +8 -13
  565. package/lib/utils/validate.d.ts +2 -1
  566. package/lib/utils/validate.js +8 -13
  567. package/lib/utils/with-install.js +8 -13
  568. package/lib/vant.cjs.js +538 -284
  569. package/lib/vant.cjs.min.js +1 -1
  570. package/lib/vant.es.js +538 -284
  571. package/lib/vant.es.min.js +538 -284
  572. package/lib/vant.js +538 -284
  573. package/lib/vant.min.js +1 -1
  574. package/package.json +4 -4
  575. package/vetur/attributes.json +388 -452
  576. package/vetur/tags.json +108 -106
  577. package/vetur/web-types.json +2027 -1172
  578. package/es/empty/Network.d.ts +0 -1
  579. package/es/empty/Network.js +0 -89
  580. package/lib/empty/Network.d.ts +0 -1
  581. package/lib/empty/Network.js +0 -113
@@ -23,6 +23,7 @@ function pick(obj, keys, ignoreUndefined) {
23
23
  }, {});
24
24
  }
25
25
  const isSameValue = (newValue, oldValue) => JSON.stringify(newValue) === JSON.stringify(oldValue);
26
+ const toArray = (item) => Array.isArray(item) ? item : [item];
26
27
  const unknownProp = null;
27
28
  const numericProp = [Number, String];
28
29
  const truthProp = {
@@ -119,6 +120,12 @@ function addUnit(value) {
119
120
  }
120
121
  function getSizeStyle(originSize) {
121
122
  if (isDef(originSize)) {
123
+ if (Array.isArray(originSize)) {
124
+ return {
125
+ width: addUnit(originSize[0]),
126
+ height: addUnit(originSize[1])
127
+ };
128
+ }
122
129
  const size = addUnit(originSize);
123
130
  return {
124
131
  width: size,
@@ -280,10 +287,8 @@ var stdin_default$1C = {
280
287
  },
281
288
  vanAddressEdit: {
282
289
  area: "\u5730\u533A",
283
- postal: "\u90AE\u653F\u7F16\u7801",
284
290
  areaEmpty: "\u8BF7\u9009\u62E9\u5730\u533A",
285
291
  addressEmpty: "\u8BF7\u586B\u5199\u8BE6\u7EC6\u5730\u5740",
286
- postalEmpty: "\u90AE\u653F\u7F16\u7801\u4E0D\u6B63\u786E",
287
292
  addressDetail: "\u8BE6\u7EC6\u5730\u5740",
288
293
  defaultAddress: "\u8BBE\u4E3A\u9ED8\u8BA4\u6536\u8D27\u5730\u5740"
289
294
  },
@@ -309,10 +314,10 @@ const Locale = {
309
314
  };
310
315
  var stdin_default$1B = Locale;
311
316
  function createTranslate(name2) {
312
- const prefix2 = camelize(name2) + ".";
317
+ const prefix = camelize(name2) + ".";
313
318
  return (path, ...args) => {
314
319
  const messages2 = stdin_default$1B.messages();
315
- const message = get(messages2, prefix2 + path) || get(messages2, path);
320
+ const message = get(messages2, prefix + path) || get(messages2, path);
316
321
  return isFunction(message) ? message(...args) : message;
317
322
  };
318
323
  }
@@ -560,6 +565,8 @@ var stdin_default$1y = defineComponent({
560
565
  watch(() => props.theme, (newVal, oldVal) => {
561
566
  document.body.classList.remove(`van-theme-${oldVal}`);
562
567
  document.body.classList.add(`van-theme-${newVal}`);
568
+ }, {
569
+ immediate: true
563
570
  });
564
571
  }
565
572
  provide(CONFIG_PROVIDER_KEY, props);
@@ -676,7 +683,9 @@ var stdin_default$1w = defineComponent({
676
683
  return createVNode("div", {
677
684
  "class": bem$1l([type, {
678
685
  vertical
679
- }])
686
+ }]),
687
+ "aria-live": "polite",
688
+ "aria-busy": true
680
689
  }, [createVNode("span", {
681
690
  "class": bem$1l("spinner", type),
682
691
  "style": spinnerStyle.value
@@ -994,7 +1003,7 @@ function useTouch() {
994
1003
  };
995
1004
  const move = (event) => {
996
1005
  const touch = event.touches[0];
997
- deltaX.value = touch.clientX < 0 ? 0 : touch.clientX - startX.value;
1006
+ deltaX.value = (touch.clientX < 0 ? 0 : touch.clientX) - startX.value;
998
1007
  deltaY.value = touch.clientY - startY.value;
999
1008
  offsetX.value = Math.abs(deltaX.value);
1000
1009
  offsetY.value = Math.abs(deltaY.value);
@@ -1134,6 +1143,7 @@ const popupProps$2 = extend({}, popupSharedProps, {
1134
1143
  iconPrefix: String,
1135
1144
  closeOnPopstate: Boolean,
1136
1145
  closeIconPosition: makeStringProp("top-right"),
1146
+ safeAreaInsetTop: Boolean,
1137
1147
  safeAreaInsetBottom: Boolean
1138
1148
  });
1139
1149
  const [name$1k, bem$1g] = createNamespace("popup");
@@ -1228,6 +1238,7 @@ var stdin_default$1r = defineComponent({
1228
1238
  const {
1229
1239
  round,
1230
1240
  position,
1241
+ safeAreaInsetTop,
1231
1242
  safeAreaInsetBottom
1232
1243
  } = props;
1233
1244
  return withDirectives(createVNode("div", mergeProps({
@@ -1237,6 +1248,7 @@ var stdin_default$1r = defineComponent({
1237
1248
  round,
1238
1249
  [position]: position
1239
1250
  }), {
1251
+ "van-safe-area-top": safeAreaInsetTop,
1240
1252
  "van-safe-area-bottom": safeAreaInsetBottom
1241
1253
  }],
1242
1254
  "onKeydown": onKeydown
@@ -2139,9 +2151,12 @@ const formProps = {
2139
2151
  scrollToError: Boolean,
2140
2152
  validateFirst: Boolean,
2141
2153
  submitOnEnter: truthProp,
2142
- validateTrigger: makeStringProp("onBlur"),
2143
2154
  showErrorMessage: truthProp,
2144
- errorMessageAlign: String
2155
+ errorMessageAlign: String,
2156
+ validateTrigger: {
2157
+ type: [String, Array],
2158
+ default: "onBlur"
2159
+ }
2145
2160
  };
2146
2161
  var stdin_default$1l = defineComponent({
2147
2162
  name: name$1e,
@@ -2256,6 +2271,7 @@ var stdin_default$1l = defineComponent({
2256
2271
  useExpose({
2257
2272
  submit,
2258
2273
  validate,
2274
+ getValues,
2259
2275
  scrollToField,
2260
2276
  resetValidation
2261
2277
  });
@@ -2353,7 +2369,7 @@ function cutString(str, maxlength) {
2353
2369
  return [...str].slice(0, maxlength).join("");
2354
2370
  }
2355
2371
  let current = 0;
2356
- function useId() {
2372
+ function useId$1() {
2357
2373
  const vm = getCurrentInstance();
2358
2374
  const { name: name2 = "unknown" } = (vm == null ? void 0 : vm.type) || {};
2359
2375
  return `${name2}-${++current}`;
@@ -2374,6 +2390,7 @@ const fieldSharedProps = {
2374
2390
  placeholder: String,
2375
2391
  autocomplete: String,
2376
2392
  errorMessage: String,
2393
+ enterkeyhint: String,
2377
2394
  clearTrigger: makeStringProp("focus"),
2378
2395
  formatTrigger: makeStringProp("onChange"),
2379
2396
  error: {
@@ -2412,7 +2429,7 @@ var stdin_default$1k = defineComponent({
2412
2429
  emit,
2413
2430
  slots
2414
2431
  }) {
2415
- const id = useId();
2432
+ const id = useId$1();
2416
2433
  const state = reactive({
2417
2434
  focused: false,
2418
2435
  validateFailed: false,
@@ -2502,10 +2519,13 @@ var stdin_default$1k = defineComponent({
2502
2519
  });
2503
2520
  const validateWithTrigger = (trigger) => {
2504
2521
  if (form && props.rules) {
2505
- const defaultTrigger = form.props.validateTrigger === trigger;
2522
+ const {
2523
+ validateTrigger
2524
+ } = form.props;
2525
+ const defaultTrigger = toArray(validateTrigger).includes(trigger);
2506
2526
  const rules = props.rules.filter((rule) => {
2507
2527
  if (rule.trigger) {
2508
- return rule.trigger === trigger;
2528
+ return toArray(rule.trigger).includes(trigger);
2509
2529
  }
2510
2530
  return defaultTrigger;
2511
2531
  });
@@ -2643,6 +2663,7 @@ var stdin_default$1k = defineComponent({
2643
2663
  autofocus: props.autofocus,
2644
2664
  placeholder: props.placeholder,
2645
2665
  autocomplete: props.autocomplete,
2666
+ enterkeyhint: props.enterkeyhint,
2646
2667
  "aria-labelledby": props.label ? `${id}-label` : void 0,
2647
2668
  onBlur,
2648
2669
  onFocus,
@@ -2906,6 +2927,7 @@ var stdin_default$1j = defineComponent({
2906
2927
  } = props;
2907
2928
  if (isDef(message) && message !== "") {
2908
2929
  return type === "html" ? createVNode("div", {
2930
+ "key": 0,
2909
2931
  "class": bem$18("text"),
2910
2932
  "innerHTML": String(message)
2911
2933
  }, null) : createVNode("div", {
@@ -3220,10 +3242,8 @@ const DEFAULT_DATA = {
3220
3242
  province: "",
3221
3243
  areaCode: "",
3222
3244
  isDefault: false,
3223
- postalCode: "",
3224
3245
  addressDetail: ""
3225
3246
  };
3226
- const isPostal = (value) => /^\d{6}$/.test(value);
3227
3247
  const addressEditProps = {
3228
3248
  areaList: Object,
3229
3249
  isSaving: Boolean,
@@ -3232,7 +3252,6 @@ const addressEditProps = {
3232
3252
  showArea: truthProp,
3233
3253
  showDetail: truthProp,
3234
3254
  showDelete: Boolean,
3235
- showPostal: Boolean,
3236
3255
  disableArea: Boolean,
3237
3256
  searchResult: Array,
3238
3257
  telMaxlength: numericProp,
@@ -3251,10 +3270,6 @@ const addressEditProps = {
3251
3270
  telValidator: {
3252
3271
  type: Function,
3253
3272
  default: isMobile
3254
- },
3255
- postalValidator: {
3256
- type: Function,
3257
- default: isPostal
3258
3273
  }
3259
3274
  };
3260
3275
  var stdin_default$1g = defineComponent({
@@ -3297,8 +3312,7 @@ var stdin_default$1g = defineComponent({
3297
3312
  const rules = computed(() => {
3298
3313
  const {
3299
3314
  validator,
3300
- telValidator,
3301
- postalValidator
3315
+ telValidator
3302
3316
  } = props;
3303
3317
  const makeRule = (name2, emptyMessage) => ({
3304
3318
  validator: (value) => {
@@ -3321,11 +3335,7 @@ var stdin_default$1g = defineComponent({
3321
3335
  message: t$h("telInvalid")
3322
3336
  }],
3323
3337
  areaCode: [makeRule("areaCode", t$h("areaEmpty"))],
3324
- addressDetail: [makeRule("addressDetail", t$h("addressEmpty"))],
3325
- postalCode: [makeRule("addressDetail", t$h("postalEmpty")), {
3326
- validator: postalValidator,
3327
- message: t$h("postalEmpty")
3328
- }]
3338
+ addressDetail: [makeRule("addressDetail", t$h("addressEmpty"))]
3329
3339
  };
3330
3340
  });
3331
3341
  const onSave = () => emit("save", data);
@@ -3450,16 +3460,7 @@ var stdin_default$1g = defineComponent({
3450
3460
  "onFocus": () => onFocus("addressDetail"),
3451
3461
  "onInput": onChangeDetail,
3452
3462
  "onSelectSearch": (event) => emit("selectSearch", event)
3453
- }, null), props.showPostal && withDirectives(createVNode(Field, {
3454
- "modelValue": data.postalCode,
3455
- "onUpdate:modelValue": ($event) => data.postalCode = $event,
3456
- "type": "tel",
3457
- "rules": rules.value.postalCode,
3458
- "label": t$h("postal"),
3459
- "maxlength": "6",
3460
- "placeholder": t$h("postal"),
3461
- "onFocus": () => onFocus("postalCode")
3462
- }, null), [[vShow, !hideBottomFields.value]]), (_a = slots.default) == null ? void 0 : _a.call(slots)]), renderSetDefaultCell(), withDirectives(createVNode("div", {
3463
+ }, null), (_a = slots.default) == null ? void 0 : _a.call(slots)]), renderSetDefaultCell(), withDirectives(createVNode("div", {
3463
3464
  "class": bem$15("buttons")
3464
3465
  }, [createVNode(Button, {
3465
3466
  "block": true,
@@ -4018,6 +4019,7 @@ var stdin_default$19 = defineComponent({
4018
4019
  slots
4019
4020
  }) {
4020
4021
  const style = computed(() => {
4022
+ var _a;
4021
4023
  const {
4022
4024
  item,
4023
4025
  index,
@@ -4049,6 +4051,9 @@ var stdin_default$19 = defineComponent({
4049
4051
  break;
4050
4052
  }
4051
4053
  }
4054
+ if (offset + (((_a = item.date) == null ? void 0 : _a.getDate()) || 1) > 28) {
4055
+ style2.marginBottom = 0;
4056
+ }
4052
4057
  return style2;
4053
4058
  });
4054
4059
  const onClick = () => {
@@ -4393,6 +4398,7 @@ const calendarProps = {
4393
4398
  showRangePrompt: truthProp,
4394
4399
  confirmDisabledText: String,
4395
4400
  closeOnClickOverlay: truthProp,
4401
+ safeAreaInsetTop: Boolean,
4396
4402
  safeAreaInsetBottom: truthProp,
4397
4403
  minDate: {
4398
4404
  type: Date,
@@ -4555,8 +4561,8 @@ var stdin_default$16 = defineComponent({
4555
4561
  }
4556
4562
  raf(() => {
4557
4563
  bodyHeight = Math.floor(useRect(bodyRef).height);
4558
- scrollToCurrentDate();
4559
4564
  });
4565
+ scrollToCurrentDate();
4560
4566
  };
4561
4567
  const reset = (date = getInitialDate()) => {
4562
4568
  currentDate.value = date;
@@ -4741,6 +4747,7 @@ var stdin_default$16 = defineComponent({
4741
4747
  "closeable": props.showTitle || props.showSubtitle,
4742
4748
  "teleport": props.teleport,
4743
4749
  "closeOnPopstate": props.closeOnPopstate,
4750
+ "safeAreaInsetTop": props.safeAreaInsetTop,
4744
4751
  "closeOnClickOverlay": props.closeOnClickOverlay,
4745
4752
  "onUpdate:show": updateShow
4746
4753
  }, {
@@ -5699,7 +5706,7 @@ var stdin_default$$ = defineComponent({
5699
5706
  const root = ref();
5700
5707
  const navRef = ref();
5701
5708
  const wrapRef = ref();
5702
- const id = useId();
5709
+ const id = useId$1();
5703
5710
  const scroller = useScrollParent(root);
5704
5711
  const [titleRefs, setTitleRefs] = useRefs();
5705
5712
  const {
@@ -5866,6 +5873,7 @@ var stdin_default$$ = defineComponent({
5866
5873
  }
5867
5874
  };
5868
5875
  const renderNav = () => children.map((item, index) => createVNode(stdin_default$12, mergeProps({
5876
+ "key": item.id,
5869
5877
  "id": `${id}-${index}`,
5870
5878
  "ref": setTitleRefs(index),
5871
5879
  "type": props.type,
@@ -6085,7 +6093,7 @@ var stdin_default$Z = defineComponent({
6085
6093
  setup(props, {
6086
6094
  slots
6087
6095
  }) {
6088
- const id = useId();
6096
+ const id = useId$1();
6089
6097
  const inited = ref(false);
6090
6098
  const {
6091
6099
  parent,
@@ -7455,14 +7463,328 @@ var stdin_default$K = defineComponent({
7455
7463
  }
7456
7464
  });
7457
7465
  const CouponCell = withInstall(stdin_default$K);
7458
- const [name$D, bem$C, t$8] = createNamespace("coupon-list");
7459
- const EMPTY_IMAGE = "https://img.yzcdn.cn/vant/coupon-empty.png";
7466
+ const getId = (num) => `van-empty-${num}`;
7467
+ const useId = (num) => `url(#${getId(num)})`;
7468
+ const renderStop = (color, offset, opacity) => createVNode("stop", {
7469
+ "stop-color": color,
7470
+ "offset": `${offset}%`,
7471
+ "stop-opacity": opacity
7472
+ }, null);
7473
+ const renderStops = (fromColor, toColor) => [renderStop(fromColor, 0), renderStop(toColor, 100)];
7474
+ const renderShadow = (id) => [createVNode("defs", null, [createVNode("radialGradient", {
7475
+ "id": getId(id),
7476
+ "cx": "50%",
7477
+ "cy": "54%",
7478
+ "fx": "50%",
7479
+ "fy": "54%",
7480
+ "r": "297%",
7481
+ "gradientTransform": "matrix(-.16 0 0 -.33 .58 .72)"
7482
+ }, [renderStop("#EBEDF0", 0), renderStop("#F2F3F5", 100, 0.3)])]), createVNode("ellipse", {
7483
+ "fill": useId(id),
7484
+ "opacity": ".8",
7485
+ "cx": "80",
7486
+ "cy": "140",
7487
+ "rx": "46",
7488
+ "ry": "8"
7489
+ }, null)];
7490
+ const renderBuilding = () => [createVNode("defs", null, [createVNode("linearGradient", {
7491
+ "id": getId("a"),
7492
+ "x1": "64%",
7493
+ "y1": "100%",
7494
+ "x2": "64%"
7495
+ }, [renderStop("#FFF", 0, 0.5), renderStop("#F2F3F5", 100)])]), createVNode("g", {
7496
+ "opacity": ".8"
7497
+ }, [createVNode("path", {
7498
+ "d": "M36 131V53H16v20H2v58h34z",
7499
+ "fill": useId("a")
7500
+ }, null), createVNode("path", {
7501
+ "d": "M123 15h22v14h9v77h-31V15z",
7502
+ "fill": useId("a")
7503
+ }, null)])];
7504
+ const renderCloud = () => [createVNode("defs", null, [createVNode("linearGradient", {
7505
+ "id": getId("b"),
7506
+ "x1": "64%",
7507
+ "y1": "97%",
7508
+ "x2": "64%",
7509
+ "y2": "0%"
7510
+ }, [renderStop("#F2F3F5", 0, 0.3), renderStop("#F2F3F5", 100)])]), createVNode("g", {
7511
+ "opacity": ".8"
7512
+ }, [createVNode("path", {
7513
+ "d": "M87 6c3 0 7 3 8 6a8 8 0 1 1-1 16H80a7 7 0 0 1-8-6c0-4 3-7 6-7 0-5 4-9 9-9Z",
7514
+ "fill": useId("b")
7515
+ }, null), createVNode("path", {
7516
+ "d": "M19 23c2 0 3 1 4 3 2 0 4 2 4 4a4 4 0 0 1-4 3v1h-7v-1l-1 1c-2 0-3-2-3-4 0-1 1-3 3-3 0-2 2-4 4-4Z",
7517
+ "fill": useId("b")
7518
+ }, null)])];
7519
+ const renderNetwork = () => createVNode("svg", {
7520
+ "viewBox": "0 0 160 160"
7521
+ }, [createVNode("defs", null, [createVNode("linearGradient", {
7522
+ "id": getId(1),
7523
+ "x1": "64%",
7524
+ "y1": "100%",
7525
+ "x2": "64%"
7526
+ }, [renderStop("#FFF", 0, 0.5), renderStop("#F2F3F5", 100)]), createVNode("linearGradient", {
7527
+ "id": getId(2),
7528
+ "x1": "50%",
7529
+ "x2": "50%",
7530
+ "y2": "84%"
7531
+ }, [renderStop("#EBEDF0", 0), renderStop("#DCDEE0", 100, 0)]), createVNode("linearGradient", {
7532
+ "id": getId(3),
7533
+ "x1": "100%",
7534
+ "x2": "100%",
7535
+ "y2": "100%"
7536
+ }, [renderStops("#EAEDF0", "#DCDEE0")]), createVNode("radialGradient", {
7537
+ "id": getId(4),
7538
+ "cx": "50%",
7539
+ "cy": "0%",
7540
+ "fx": "50%",
7541
+ "fy": "0%",
7542
+ "r": "100%",
7543
+ "gradientTransform": "matrix(0 1 -.54 0 .5 -.5)"
7544
+ }, [renderStop("#EBEDF0", 0), renderStop("#FFF", 100, 0)])]), createVNode("g", {
7545
+ "fill": "none"
7546
+ }, [renderBuilding(), createVNode("path", {
7547
+ "fill": useId(4),
7548
+ "d": "M0 139h160v21H0z"
7549
+ }, null), createVNode("path", {
7550
+ "d": "M80 54a7 7 0 0 1 3 13v27l-2 2h-2a2 2 0 0 1-2-2V67a7 7 0 0 1 3-13z",
7551
+ "fill": useId(2)
7552
+ }, null), createVNode("g", {
7553
+ "opacity": ".6",
7554
+ "stroke-linecap": "round",
7555
+ "stroke-width": "7"
7556
+ }, [createVNode("path", {
7557
+ "d": "M64 47a19 19 0 0 0-5 13c0 5 2 10 5 13",
7558
+ "stroke": useId(3)
7559
+ }, null), createVNode("path", {
7560
+ "d": "M53 36a34 34 0 0 0 0 48",
7561
+ "stroke": useId(3)
7562
+ }, null), createVNode("path", {
7563
+ "d": "M95 73a19 19 0 0 0 6-13c0-5-2-9-6-13",
7564
+ "stroke": useId(3)
7565
+ }, null), createVNode("path", {
7566
+ "d": "M106 84a34 34 0 0 0 0-48",
7567
+ "stroke": useId(3)
7568
+ }, null)]), createVNode("g", {
7569
+ "transform": "translate(31 105)"
7570
+ }, [createVNode("rect", {
7571
+ "fill": "#EBEDF0",
7572
+ "width": "98",
7573
+ "height": "34",
7574
+ "rx": "2"
7575
+ }, null), createVNode("rect", {
7576
+ "fill": "#FFF",
7577
+ "x": "9",
7578
+ "y": "8",
7579
+ "width": "80",
7580
+ "height": "18",
7581
+ "rx": "1.1"
7582
+ }, null), createVNode("rect", {
7583
+ "fill": "#EBEDF0",
7584
+ "x": "15",
7585
+ "y": "12",
7586
+ "width": "18",
7587
+ "height": "6",
7588
+ "rx": "1.1"
7589
+ }, null)])])]);
7590
+ const renderMaterial = () => createVNode("svg", {
7591
+ "viewBox": "0 0 160 160"
7592
+ }, [createVNode("defs", null, [createVNode("linearGradient", {
7593
+ "x1": "50%",
7594
+ "x2": "50%",
7595
+ "y2": "100%",
7596
+ "id": getId(5)
7597
+ }, [renderStops("#F2F3F5", "#DCDEE0")]), createVNode("linearGradient", {
7598
+ "x1": "95%",
7599
+ "y1": "48%",
7600
+ "x2": "5.5%",
7601
+ "y2": "51%",
7602
+ "id": getId(6)
7603
+ }, [renderStops("#EAEDF1", "#DCDEE0")]), createVNode("linearGradient", {
7604
+ "y1": "45%",
7605
+ "x2": "100%",
7606
+ "y2": "54%",
7607
+ "id": getId(7)
7608
+ }, [renderStops("#EAEDF1", "#DCDEE0")])]), renderBuilding(), renderCloud(), createVNode("g", {
7609
+ "transform": "translate(36 50)",
7610
+ "fill": "none"
7611
+ }, [createVNode("g", {
7612
+ "transform": "translate(8)"
7613
+ }, [createVNode("rect", {
7614
+ "fill": "#EBEDF0",
7615
+ "opacity": ".6",
7616
+ "x": "38",
7617
+ "y": "13",
7618
+ "width": "36",
7619
+ "height": "53",
7620
+ "rx": "2"
7621
+ }, null), createVNode("rect", {
7622
+ "fill": useId(5),
7623
+ "width": "64",
7624
+ "height": "66",
7625
+ "rx": "2"
7626
+ }, null), createVNode("rect", {
7627
+ "fill": "#FFF",
7628
+ "x": "6",
7629
+ "y": "6",
7630
+ "width": "52",
7631
+ "height": "55",
7632
+ "rx": "1"
7633
+ }, null), createVNode("g", {
7634
+ "transform": "translate(15 17)",
7635
+ "fill": useId(6)
7636
+ }, [createVNode("rect", {
7637
+ "width": "34",
7638
+ "height": "6",
7639
+ "rx": "1"
7640
+ }, null), createVNode("path", {
7641
+ "d": "M0 14h34v6H0z"
7642
+ }, null), createVNode("rect", {
7643
+ "y": "28",
7644
+ "width": "34",
7645
+ "height": "6",
7646
+ "rx": "1"
7647
+ }, null)])]), createVNode("rect", {
7648
+ "fill": useId(7),
7649
+ "y": "61",
7650
+ "width": "88",
7651
+ "height": "28",
7652
+ "rx": "1"
7653
+ }, null), createVNode("rect", {
7654
+ "fill": "#F7F8FA",
7655
+ "x": "29",
7656
+ "y": "72",
7657
+ "width": "30",
7658
+ "height": "6",
7659
+ "rx": "1"
7660
+ }, null)])]);
7661
+ const renderError = () => createVNode("svg", {
7662
+ "viewBox": "0 0 160 160"
7663
+ }, [createVNode("defs", null, [createVNode("linearGradient", {
7664
+ "x1": "50%",
7665
+ "x2": "50%",
7666
+ "y2": "100%",
7667
+ "id": getId(8)
7668
+ }, [renderStops("#EAEDF1", "#DCDEE0")])]), renderBuilding(), renderCloud(), renderShadow("c"), createVNode("path", {
7669
+ "d": "m59 60 21 21 21-21h3l9 9v3L92 93l21 21v3l-9 9h-3l-21-21-21 21h-3l-9-9v-3l21-21-21-21v-3l9-9h3Z",
7670
+ "fill": useId(8)
7671
+ }, null)]);
7672
+ const renderSearch = () => createVNode("svg", {
7673
+ "viewBox": "0 0 160 160"
7674
+ }, [createVNode("defs", null, [createVNode("linearGradient", {
7675
+ "x1": "50%",
7676
+ "y1": "100%",
7677
+ "x2": "50%",
7678
+ "id": getId(9)
7679
+ }, [renderStops("#EEE", "#D8D8D8")]), createVNode("linearGradient", {
7680
+ "x1": "100%",
7681
+ "y1": "50%",
7682
+ "y2": "50%",
7683
+ "id": getId(10)
7684
+ }, [renderStops("#F2F3F5", "#DCDEE0")]), createVNode("linearGradient", {
7685
+ "x1": "50%",
7686
+ "x2": "50%",
7687
+ "y2": "100%",
7688
+ "id": getId(11)
7689
+ }, [renderStops("#F2F3F5", "#DCDEE0")]), createVNode("linearGradient", {
7690
+ "x1": "50%",
7691
+ "x2": "50%",
7692
+ "y2": "100%",
7693
+ "id": getId(12)
7694
+ }, [renderStops("#FFF", "#F7F8FA")])]), renderBuilding(), renderCloud(), renderShadow("d"), createVNode("g", {
7695
+ "transform": "rotate(-45 113 -4)",
7696
+ "fill": "none"
7697
+ }, [createVNode("rect", {
7698
+ "fill": useId(9),
7699
+ "x": "24",
7700
+ "y": "52.8",
7701
+ "width": "5.8",
7702
+ "height": "19",
7703
+ "rx": "1"
7704
+ }, null), createVNode("rect", {
7705
+ "fill": useId(10),
7706
+ "x": "22.1",
7707
+ "y": "67.3",
7708
+ "width": "9.9",
7709
+ "height": "28",
7710
+ "rx": "1"
7711
+ }, null), createVNode("circle", {
7712
+ "stroke": useId(11),
7713
+ "stroke-width": "8",
7714
+ "cx": "27",
7715
+ "cy": "27",
7716
+ "r": "27"
7717
+ }, null), createVNode("circle", {
7718
+ "fill": useId(12),
7719
+ "cx": "27",
7720
+ "cy": "27",
7721
+ "r": "16"
7722
+ }, null), createVNode("path", {
7723
+ "d": "M37 7c-8 0-15 5-16 12",
7724
+ "stroke": useId(11),
7725
+ "stroke-width": "3",
7726
+ "opacity": ".5",
7727
+ "stroke-linecap": "round",
7728
+ "transform": "rotate(45 29 13)"
7729
+ }, null)])]);
7730
+ const [name$D, bem$C] = createNamespace("empty");
7731
+ const PRESET_IMAGES = {
7732
+ error: renderError,
7733
+ search: renderSearch,
7734
+ network: renderNetwork,
7735
+ default: renderMaterial
7736
+ };
7737
+ const emptyProps = {
7738
+ image: makeStringProp("default"),
7739
+ imageSize: [Number, String, Array],
7740
+ description: String
7741
+ };
7742
+ var stdin_default$J = defineComponent({
7743
+ name: name$D,
7744
+ props: emptyProps,
7745
+ setup(props, {
7746
+ slots
7747
+ }) {
7748
+ const renderImage = () => {
7749
+ var _a;
7750
+ if (slots.image) {
7751
+ return slots.image();
7752
+ }
7753
+ return ((_a = PRESET_IMAGES[props.image]) == null ? void 0 : _a.call(PRESET_IMAGES)) || createVNode("img", {
7754
+ "src": props.image
7755
+ }, null);
7756
+ };
7757
+ const renderDescription = () => {
7758
+ const description = slots.description ? slots.description() : props.description;
7759
+ if (description) {
7760
+ return createVNode("p", {
7761
+ "class": bem$C("description")
7762
+ }, [description]);
7763
+ }
7764
+ };
7765
+ const renderBottom = () => {
7766
+ if (slots.default) {
7767
+ return createVNode("div", {
7768
+ "class": bem$C("bottom")
7769
+ }, [slots.default()]);
7770
+ }
7771
+ };
7772
+ return () => createVNode("div", {
7773
+ "class": bem$C()
7774
+ }, [createVNode("div", {
7775
+ "class": bem$C("image"),
7776
+ "style": getSizeStyle(props.imageSize)
7777
+ }, [renderImage()]), renderDescription(), renderBottom()]);
7778
+ }
7779
+ });
7780
+ const Empty = withInstall(stdin_default$J);
7781
+ const [name$C, bem$B, t$8] = createNamespace("coupon-list");
7460
7782
  const couponListProps = {
7461
7783
  code: makeStringProp(""),
7462
7784
  coupons: makeArrayProp(),
7463
7785
  currency: makeStringProp("\xA5"),
7464
7786
  showCount: truthProp,
7465
- emptyImage: makeStringProp(EMPTY_IMAGE),
7787
+ emptyImage: String,
7466
7788
  chosenCoupon: makeNumberProp(-1),
7467
7789
  enabledTitle: String,
7468
7790
  disabledTitle: String,
@@ -7477,8 +7799,8 @@ const couponListProps = {
7477
7799
  exchangeButtonLoading: Boolean,
7478
7800
  exchangeButtonDisabled: Boolean
7479
7801
  };
7480
- var stdin_default$J = defineComponent({
7481
- name: name$D,
7802
+ var stdin_default$I = defineComponent({
7803
+ name: name$C,
7482
7804
  props: couponListProps,
7483
7805
  emits: ["change", "exchange", "update:code"],
7484
7806
  setup(props, {
@@ -7510,28 +7832,30 @@ var stdin_default$J = defineComponent({
7510
7832
  return (_a = couponRefs.value[index]) == null ? void 0 : _a.scrollIntoView();
7511
7833
  });
7512
7834
  };
7513
- const renderEmpty = () => createVNode("div", {
7514
- "class": bem$C("empty")
7515
- }, [createVNode("img", {
7516
- "src": props.emptyImage
7517
- }, null), createVNode("p", null, [t$8("noCoupon")])]);
7835
+ const renderEmpty = () => createVNode(Empty, {
7836
+ "image": props.emptyImage
7837
+ }, {
7838
+ default: () => [createVNode("p", {
7839
+ "class": bem$B("empty-tip")
7840
+ }, [t$8("noCoupon")])]
7841
+ });
7518
7842
  const renderExchangeBar = () => {
7519
7843
  if (props.showExchangeBar) {
7520
7844
  return createVNode("div", {
7521
7845
  "ref": barRef,
7522
- "class": bem$C("exchange-bar")
7846
+ "class": bem$B("exchange-bar")
7523
7847
  }, [createVNode(Field, {
7524
7848
  "modelValue": currentCode.value,
7525
7849
  "onUpdate:modelValue": ($event) => currentCode.value = $event,
7526
7850
  "clearable": true,
7527
7851
  "border": false,
7528
- "class": bem$C("field"),
7852
+ "class": bem$B("field"),
7529
7853
  "placeholder": props.inputPlaceholder || t$8("placeholder"),
7530
7854
  "maxlength": "20"
7531
7855
  }, null), createVNode(Button, {
7532
7856
  "plain": true,
7533
7857
  "type": "primary",
7534
- "class": bem$C("exchange"),
7858
+ "class": bem$B("exchange"),
7535
7859
  "text": props.exchangeButtonText || t$8("exchange"),
7536
7860
  "loading": props.exchangeButtonLoading,
7537
7861
  "disabled": buttonDisabled.value,
@@ -7551,7 +7875,7 @@ var stdin_default$J = defineComponent({
7551
7875
  default: () => {
7552
7876
  var _a;
7553
7877
  return [createVNode("div", {
7554
- "class": bem$C("list", {
7878
+ "class": bem$B("list", {
7555
7879
  "with-bottom": props.showCloseButton
7556
7880
  }),
7557
7881
  "style": {
@@ -7580,7 +7904,7 @@ var stdin_default$J = defineComponent({
7580
7904
  default: () => {
7581
7905
  var _a;
7582
7906
  return [createVNode("div", {
7583
- "class": bem$C("list", {
7907
+ "class": bem$B("list", {
7584
7908
  "with-bottom": props.showCloseButton
7585
7909
  }),
7586
7910
  "style": {
@@ -7607,28 +7931,28 @@ var stdin_default$J = defineComponent({
7607
7931
  });
7608
7932
  return () => createVNode("div", {
7609
7933
  "ref": root,
7610
- "class": bem$C()
7934
+ "class": bem$B()
7611
7935
  }, [renderExchangeBar(), createVNode(Tabs, {
7612
7936
  "active": activeTab.value,
7613
7937
  "onUpdate:active": ($event) => activeTab.value = $event,
7614
- "class": bem$C("tab")
7938
+ "class": bem$B("tab")
7615
7939
  }, {
7616
7940
  default: () => [renderCouponTab(), renderDisabledTab()]
7617
7941
  }), createVNode("div", {
7618
- "class": bem$C("bottom")
7942
+ "class": bem$B("bottom")
7619
7943
  }, [withDirectives(createVNode(Button, {
7620
7944
  "round": true,
7621
7945
  "block": true,
7622
7946
  "type": "primary",
7623
- "class": bem$C("close"),
7947
+ "class": bem$B("close"),
7624
7948
  "text": props.closeButtonText || t$8("close"),
7625
7949
  "onClick": () => emit("change", -1)
7626
7950
  }, null), [[vShow, props.showCloseButton]])])]);
7627
7951
  }
7628
7952
  });
7629
- const CouponList = withInstall(stdin_default$J);
7953
+ const CouponList = withInstall(stdin_default$I);
7630
7954
  const currentYear = new Date().getFullYear();
7631
- const [name$C] = createNamespace("date-picker");
7955
+ const [name$B] = createNamespace("date-picker");
7632
7956
  const datePickerProps = extend({}, sharedProps, {
7633
7957
  columnsType: {
7634
7958
  type: Array,
@@ -7645,8 +7969,8 @@ const datePickerProps = extend({}, sharedProps, {
7645
7969
  validator: isDate
7646
7970
  }
7647
7971
  });
7648
- var stdin_default$I = defineComponent({
7649
- name: name$C,
7972
+ var stdin_default$H = defineComponent({
7973
+ name: name$B,
7650
7974
  props: datePickerProps,
7651
7975
  emits: ["confirm", "cancel", "change", "update:modelValue"],
7652
7976
  setup(props, {
@@ -7713,7 +8037,7 @@ var stdin_default$I = defineComponent({
7713
8037
  }
7714
8038
  });
7715
8039
  watch(() => props.modelValue, (newValues) => {
7716
- if (isSameValue(newValues, currentValues.value)) {
8040
+ if (!isSameValue(newValues, currentValues.value)) {
7717
8041
  currentValues.value = newValues;
7718
8042
  }
7719
8043
  });
@@ -7730,8 +8054,8 @@ var stdin_default$I = defineComponent({
7730
8054
  }, pick(props, pickerInheritKeys)), slots);
7731
8055
  }
7732
8056
  });
7733
- const DatePicker = withInstall(stdin_default$I);
7734
- const [name$B, bem$B, t$7] = createNamespace("dialog");
8057
+ const DatePicker = withInstall(stdin_default$H);
8058
+ const [name$A, bem$A, t$7] = createNamespace("dialog");
7735
8059
  const dialogProps = extend({}, popupSharedProps, {
7736
8060
  title: String,
7737
8061
  theme: String,
@@ -7752,8 +8076,8 @@ const dialogProps = extend({}, popupSharedProps, {
7752
8076
  closeOnClickOverlay: Boolean
7753
8077
  });
7754
8078
  const popupInheritKeys$1 = [...popupSharedPropKeys, "transition", "closeOnPopstate"];
7755
- var stdin_default$H = defineComponent({
7756
- name: name$B,
8079
+ var stdin_default$G = defineComponent({
8080
+ name: name$A,
7757
8081
  props: dialogProps,
7758
8082
  emits: ["confirm", "cancel", "keydown", "update:show"],
7759
8083
  setup(props, {
@@ -7810,7 +8134,7 @@ var stdin_default$H = defineComponent({
7810
8134
  const title = slots.title ? slots.title() : props.title;
7811
8135
  if (title) {
7812
8136
  return createVNode("div", {
7813
- "class": bem$B("header", {
8137
+ "class": bem$A("header", {
7814
8138
  isolated: !props.message && !slots.default
7815
8139
  })
7816
8140
  }, [title]);
@@ -7822,7 +8146,7 @@ var stdin_default$H = defineComponent({
7822
8146
  allowHtml,
7823
8147
  messageAlign
7824
8148
  } = props;
7825
- const classNames = bem$B("message", {
8149
+ const classNames = bem$A("message", {
7826
8150
  "has-title": hasTitle,
7827
8151
  [messageAlign]: messageAlign
7828
8152
  });
@@ -7840,7 +8164,7 @@ var stdin_default$H = defineComponent({
7840
8164
  const renderContent = () => {
7841
8165
  if (slots.default) {
7842
8166
  return createVNode("div", {
7843
- "class": bem$B("content")
8167
+ "class": bem$A("content")
7844
8168
  }, [slots.default()]);
7845
8169
  }
7846
8170
  const {
@@ -7852,18 +8176,18 @@ var stdin_default$H = defineComponent({
7852
8176
  const hasTitle = !!(title || slots.title);
7853
8177
  return createVNode("div", {
7854
8178
  "key": allowHtml ? 1 : 0,
7855
- "class": bem$B("content", {
8179
+ "class": bem$A("content", {
7856
8180
  isolated: !hasTitle
7857
8181
  })
7858
8182
  }, [renderMessage(hasTitle)]);
7859
8183
  }
7860
8184
  };
7861
8185
  const renderButtons = () => createVNode("div", {
7862
- "class": [BORDER_TOP, bem$B("footer")]
8186
+ "class": [BORDER_TOP, bem$A("footer")]
7863
8187
  }, [props.showCancelButton && createVNode(Button, {
7864
8188
  "size": "large",
7865
8189
  "text": props.cancelButtonText || t$7("cancel"),
7866
- "class": bem$B("cancel"),
8190
+ "class": bem$A("cancel"),
7867
8191
  "style": {
7868
8192
  color: props.cancelButtonColor
7869
8193
  },
@@ -7872,7 +8196,7 @@ var stdin_default$H = defineComponent({
7872
8196
  }, null), props.showConfirmButton && createVNode(Button, {
7873
8197
  "size": "large",
7874
8198
  "text": props.confirmButtonText || t$7("confirm"),
7875
- "class": [bem$B("confirm"), {
8199
+ "class": [bem$A("confirm"), {
7876
8200
  [BORDER_LEFT]: props.showCancelButton
7877
8201
  }],
7878
8202
  "style": {
@@ -7882,19 +8206,19 @@ var stdin_default$H = defineComponent({
7882
8206
  "onClick": onConfirm
7883
8207
  }, null)]);
7884
8208
  const renderRoundButtons = () => createVNode(ActionBar, {
7885
- "class": bem$B("footer")
8209
+ "class": bem$A("footer")
7886
8210
  }, {
7887
8211
  default: () => [props.showCancelButton && createVNode(ActionBarButton, {
7888
8212
  "type": "warning",
7889
8213
  "text": props.cancelButtonText || t$7("cancel"),
7890
- "class": bem$B("cancel"),
8214
+ "class": bem$A("cancel"),
7891
8215
  "color": props.cancelButtonColor,
7892
8216
  "loading": loading.cancel,
7893
8217
  "onClick": onCancel
7894
8218
  }, null), props.showConfirmButton && createVNode(ActionBarButton, {
7895
8219
  "type": "danger",
7896
8220
  "text": props.confirmButtonText || t$7("confirm"),
7897
- "class": bem$B("confirm"),
8221
+ "class": bem$A("confirm"),
7898
8222
  "color": props.confirmButtonColor,
7899
8223
  "loading": loading.confirm,
7900
8224
  "onClick": onConfirm
@@ -7917,7 +8241,7 @@ var stdin_default$H = defineComponent({
7917
8241
  return createVNode(Popup, mergeProps({
7918
8242
  "ref": root,
7919
8243
  "role": "dialog",
7920
- "class": [bem$B([theme]), className],
8244
+ "class": [bem$A([theme]), className],
7921
8245
  "style": {
7922
8246
  width: addUnit(width)
7923
8247
  },
@@ -7939,7 +8263,7 @@ function initInstance$2() {
7939
8263
  state,
7940
8264
  toggle
7941
8265
  } = usePopupState();
7942
- return () => createVNode(stdin_default$H, mergeProps(state, {
8266
+ return () => createVNode(stdin_default$G, mergeProps(state, {
7943
8267
  "onUpdate:show": toggle
7944
8268
  }), null);
7945
8269
  }
@@ -8004,19 +8328,19 @@ Dialog.setDefaultOptions = (options) => {
8004
8328
  Dialog.resetDefaultOptions = () => {
8005
8329
  Dialog.currentOptions = extend({}, Dialog.defaultOptions);
8006
8330
  };
8007
- Dialog.Component = withInstall(stdin_default$H);
8331
+ Dialog.Component = withInstall(stdin_default$G);
8008
8332
  Dialog.install = (app) => {
8009
8333
  app.use(Dialog.Component);
8010
8334
  app.config.globalProperties.$dialog = Dialog;
8011
8335
  };
8012
- const [name$A, bem$A] = createNamespace("divider");
8336
+ const [name$z, bem$z] = createNamespace("divider");
8013
8337
  const dividerProps = {
8014
8338
  dashed: Boolean,
8015
8339
  hairline: truthProp,
8016
8340
  contentPosition: makeStringProp("center")
8017
8341
  };
8018
- var stdin_default$G = defineComponent({
8019
- name: name$A,
8342
+ var stdin_default$F = defineComponent({
8343
+ name: name$z,
8020
8344
  props: dividerProps,
8021
8345
  setup(props, {
8022
8346
  slots
@@ -8025,7 +8349,7 @@ var stdin_default$G = defineComponent({
8025
8349
  var _a;
8026
8350
  return createVNode("div", {
8027
8351
  "role": "separator",
8028
- "class": bem$A({
8352
+ "class": bem$z({
8029
8353
  dashed: props.dashed,
8030
8354
  hairline: props.hairline,
8031
8355
  [`content-${props.contentPosition}`]: !!slots.default
@@ -8034,8 +8358,8 @@ var stdin_default$G = defineComponent({
8034
8358
  };
8035
8359
  }
8036
8360
  });
8037
- const Divider = withInstall(stdin_default$G);
8038
- const [name$z, bem$z] = createNamespace("dropdown-menu");
8361
+ const Divider = withInstall(stdin_default$F);
8362
+ const [name$y, bem$y] = createNamespace("dropdown-menu");
8039
8363
  const dropdownMenuProps = {
8040
8364
  overlay: truthProp,
8041
8365
  zIndex: numericProp,
@@ -8045,14 +8369,14 @@ const dropdownMenuProps = {
8045
8369
  closeOnClickOutside: truthProp,
8046
8370
  closeOnClickOverlay: truthProp
8047
8371
  };
8048
- const DROPDOWN_KEY = Symbol(name$z);
8049
- var stdin_default$F = defineComponent({
8050
- name: name$z,
8372
+ const DROPDOWN_KEY = Symbol(name$y);
8373
+ var stdin_default$E = defineComponent({
8374
+ name: name$y,
8051
8375
  props: dropdownMenuProps,
8052
8376
  setup(props, {
8053
8377
  slots
8054
8378
  }) {
8055
- const id = useId();
8379
+ const id = useId$1();
8056
8380
  const root = ref();
8057
8381
  const barRef = ref();
8058
8382
  const offset = ref(0);
@@ -8115,7 +8439,7 @@ var stdin_default$F = defineComponent({
8115
8439
  "id": `${id}-${index}`,
8116
8440
  "role": "button",
8117
8441
  "tabindex": disabled ? void 0 : 0,
8118
- "class": [bem$z("item", {
8442
+ "class": [bem$y("item", {
8119
8443
  disabled
8120
8444
  }), {
8121
8445
  [HAPTICS_FEEDBACK]: !disabled
@@ -8126,7 +8450,7 @@ var stdin_default$F = defineComponent({
8126
8450
  }
8127
8451
  }
8128
8452
  }, [createVNode("span", {
8129
- "class": [bem$z("title", {
8453
+ "class": [bem$y("title", {
8130
8454
  down: showPopup === (props.direction === "down"),
8131
8455
  active: showPopup
8132
8456
  }), titleClass],
@@ -8150,18 +8474,18 @@ var stdin_default$F = defineComponent({
8150
8474
  var _a;
8151
8475
  return createVNode("div", {
8152
8476
  "ref": root,
8153
- "class": bem$z()
8477
+ "class": bem$y()
8154
8478
  }, [createVNode("div", {
8155
8479
  "ref": barRef,
8156
8480
  "style": barStyle.value,
8157
- "class": bem$z("bar", {
8481
+ "class": bem$y("bar", {
8158
8482
  opened: opened.value
8159
8483
  })
8160
8484
  }, [children.map(renderTitle)]), (_a = slots.default) == null ? void 0 : _a.call(slots)]);
8161
8485
  };
8162
8486
  }
8163
8487
  });
8164
- const [name$y, bem$y] = createNamespace("dropdown-item");
8488
+ const [name$x, bem$x] = createNamespace("dropdown-item");
8165
8489
  const dropdownItemProps = {
8166
8490
  title: String,
8167
8491
  options: makeArrayProp(),
@@ -8171,8 +8495,8 @@ const dropdownItemProps = {
8171
8495
  modelValue: unknownProp,
8172
8496
  titleClass: unknownProp
8173
8497
  };
8174
- var stdin_default$E = defineComponent({
8175
- name: name$y,
8498
+ var stdin_default$D = defineComponent({
8499
+ name: name$x,
8176
8500
  props: dropdownItemProps,
8177
8501
  emits: ["open", "opened", "close", "closed", "change", "update:modelValue"],
8178
8502
  setup(props, {
@@ -8239,7 +8563,7 @@ var stdin_default$E = defineComponent({
8239
8563
  const renderIcon = () => {
8240
8564
  if (active) {
8241
8565
  return createVNode(Icon, {
8242
- "class": bem$y("icon"),
8566
+ "class": bem$x("icon"),
8243
8567
  "color": activeColor,
8244
8568
  "name": "success"
8245
8569
  }, null);
@@ -8250,7 +8574,7 @@ var stdin_default$E = defineComponent({
8250
8574
  "key": option.value,
8251
8575
  "icon": option.icon,
8252
8576
  "title": option.text,
8253
- "class": bem$y("option", {
8577
+ "class": bem$x("option", {
8254
8578
  active
8255
8579
  }),
8256
8580
  "style": {
@@ -8282,13 +8606,13 @@ var stdin_default$E = defineComponent({
8282
8606
  }
8283
8607
  return withDirectives(createVNode("div", {
8284
8608
  "style": style,
8285
- "class": bem$y([direction]),
8609
+ "class": bem$x([direction]),
8286
8610
  "onClick": onClickWrapper
8287
8611
  }, [createVNode(Popup, {
8288
8612
  "show": state.showPopup,
8289
8613
  "onUpdate:show": ($event) => state.showPopup = $event,
8290
8614
  "role": "menu",
8291
- "class": bem$y("content"),
8615
+ "class": bem$x("content"),
8292
8616
  "overlay": overlay,
8293
8617
  "position": direction === "down" ? "top" : "bottom",
8294
8618
  "duration": state.transition ? duration : 0,
@@ -8326,147 +8650,8 @@ var stdin_default$E = defineComponent({
8326
8650
  };
8327
8651
  }
8328
8652
  });
8329
- const DropdownItem = withInstall(stdin_default$E);
8330
- const DropdownMenu = withInstall(stdin_default$F);
8331
- const prefix = "van-empty-network-";
8332
- const renderStop = (color, offset, opacity) => createVNode("stop", {
8333
- "stop-color": color,
8334
- "offset": `${offset}%`,
8335
- "stop-opacity": opacity
8336
- }, null);
8337
- const Network = createVNode("svg", {
8338
- "viewBox": "0 0 160 160"
8339
- }, [createVNode("defs", null, [createVNode("linearGradient", {
8340
- "id": `${prefix}1`,
8341
- "x1": "64%",
8342
- "y1": "100%",
8343
- "x2": "64%"
8344
- }, [renderStop("#FFF", 0, 0.5), renderStop("#F2F3F5", 100)]), createVNode("linearGradient", {
8345
- "id": `${prefix}2`,
8346
- "x1": "50%",
8347
- "x2": "50%",
8348
- "y2": "84%"
8349
- }, [renderStop("#EBEDF0", 0), renderStop("#DCDEE0", 100, 0)]), createVNode("linearGradient", {
8350
- "id": `${prefix}3`,
8351
- "x1": "100%",
8352
- "x2": "100%",
8353
- "y2": "100%"
8354
- }, [renderStop("#EAEDF0", 0), renderStop("#DCDEE0", 100)]), createVNode("radialGradient", {
8355
- "id": `${prefix}4`,
8356
- "cx": "50%",
8357
- "cy": "0%",
8358
- "fx": "50%",
8359
- "fy": "0%",
8360
- "r": "100%",
8361
- "gradientTransform": "matrix(0 1 -.54 0 .5 -.5)"
8362
- }, [renderStop("#EBEDF0", 0), renderStop("#FFF", 100, 0)])]), createVNode("g", {
8363
- "fill": "none"
8364
- }, [createVNode("g", {
8365
- "opacity": ".8"
8366
- }, [createVNode("path", {
8367
- "d": "M36 131V53H16v20H2v58h34z",
8368
- "fill": `url(#${prefix}1)`
8369
- }, null), createVNode("path", {
8370
- "d": "M123 15h22v14h9v77h-31V15z",
8371
- "fill": `url(#${prefix}1)`
8372
- }, null)]), createVNode("path", {
8373
- "fill": `url(#${prefix}4)`,
8374
- "d": "M0 139h160v21H0z"
8375
- }, null), createVNode("path", {
8376
- "d": "M80 54a7 7 0 0 1 3 13v27l-2 2h-2a2 2 0 0 1-2-2V67a7 7 0 0 1 3-13z",
8377
- "fill": `url(#${prefix}2)`
8378
- }, null), createVNode("g", {
8379
- "opacity": ".6",
8380
- "stroke-linecap": "round",
8381
- "stroke-width": "7"
8382
- }, [createVNode("path", {
8383
- "d": "M64 47a19 19 0 0 0-5 13c0 5 2 10 5 13",
8384
- "stroke": `url(#${prefix}3)`
8385
- }, null), createVNode("path", {
8386
- "d": "M53 36a34 34 0 0 0 0 48",
8387
- "stroke": `url(#${prefix}3)`
8388
- }, null), createVNode("path", {
8389
- "d": "M95 73a19 19 0 0 0 6-13c0-5-2-9-6-13",
8390
- "stroke": `url(#${prefix}3)`
8391
- }, null), createVNode("path", {
8392
- "d": "M106 84a34 34 0 0 0 0-48",
8393
- "stroke": `url(#${prefix}3)`
8394
- }, null)]), createVNode("g", {
8395
- "transform": "translate(31 105)"
8396
- }, [createVNode("rect", {
8397
- "fill": "#EBEDF0",
8398
- "width": "98",
8399
- "height": "34",
8400
- "rx": "2"
8401
- }, null), createVNode("rect", {
8402
- "fill": "#FFF",
8403
- "x": "9",
8404
- "y": "8",
8405
- "width": "80",
8406
- "height": "18",
8407
- "rx": "1.1"
8408
- }, null), createVNode("rect", {
8409
- "fill": "#EBEDF0",
8410
- "x": "15",
8411
- "y": "12",
8412
- "width": "18",
8413
- "height": "6",
8414
- "rx": "1.1"
8415
- }, null)])])]);
8416
- const [name$x, bem$x] = createNamespace("empty");
8417
- const PRESET_IMAGES = ["error", "search", "default"];
8418
- const emptyProps = {
8419
- image: makeStringProp("default"),
8420
- imageSize: numericProp,
8421
- description: String
8422
- };
8423
- var stdin_default$D = defineComponent({
8424
- name: name$x,
8425
- props: emptyProps,
8426
- setup(props, {
8427
- slots
8428
- }) {
8429
- const renderImage = () => {
8430
- if (slots.image) {
8431
- return slots.image();
8432
- }
8433
- let {
8434
- image
8435
- } = props;
8436
- if (image === "network") {
8437
- return Network;
8438
- }
8439
- if (PRESET_IMAGES.includes(image)) {
8440
- image = `https://img.yzcdn.cn/vant/empty-image-${image}.png`;
8441
- }
8442
- return createVNode("img", {
8443
- "src": image
8444
- }, null);
8445
- };
8446
- const renderDescription = () => {
8447
- const description = slots.description ? slots.description() : props.description;
8448
- if (description) {
8449
- return createVNode("p", {
8450
- "class": bem$x("description")
8451
- }, [description]);
8452
- }
8453
- };
8454
- const renderBottom = () => {
8455
- if (slots.default) {
8456
- return createVNode("div", {
8457
- "class": bem$x("bottom")
8458
- }, [slots.default()]);
8459
- }
8460
- };
8461
- return () => createVNode("div", {
8462
- "class": bem$x()
8463
- }, [createVNode("div", {
8464
- "class": bem$x("image"),
8465
- "style": getSizeStyle(props.imageSize)
8466
- }, [renderImage()]), renderDescription(), renderBottom()]);
8467
- }
8468
- });
8469
- const Empty = withInstall(stdin_default$D);
8653
+ const DropdownItem = withInstall(stdin_default$D);
8654
+ const DropdownMenu = withInstall(stdin_default$E);
8470
8655
  const [name$w, bem$w] = createNamespace("grid");
8471
8656
  const gridProps = {
8472
8657
  square: Boolean,
@@ -9120,6 +9305,7 @@ var stdin_default$y = defineComponent({
9120
9305
  children,
9121
9306
  linkChildren
9122
9307
  } = useChildren(INDEX_BAR_KEY);
9308
+ let selectActiveIndex;
9123
9309
  linkChildren({
9124
9310
  props
9125
9311
  });
@@ -9147,6 +9333,7 @@ var stdin_default$y = defineComponent({
9147
9333
  }
9148
9334
  return -1;
9149
9335
  };
9336
+ const getMatchAnchor = (index) => children.find((item) => String(item.index) === index);
9150
9337
  const onScroll = () => {
9151
9338
  if (isHidden(root)) {
9152
9339
  return;
@@ -9158,7 +9345,16 @@ var stdin_default$y = defineComponent({
9158
9345
  const scrollTop = getScrollTop(scrollParent.value);
9159
9346
  const scrollParentRect = useRect(scrollParent);
9160
9347
  const rects = children.map((item) => item.getRect(scrollParent.value, scrollParentRect));
9161
- const active = getActiveAnchor(scrollTop, rects);
9348
+ let active = -1;
9349
+ if (selectActiveIndex) {
9350
+ const match = getMatchAnchor(selectActiveIndex);
9351
+ if (match) {
9352
+ const rect = match.getRect(scrollParent.value, scrollParentRect);
9353
+ active = getActiveAnchor(rect.top, rects);
9354
+ }
9355
+ } else {
9356
+ active = getActiveAnchor(scrollTop, rects);
9357
+ }
9162
9358
  activeAnchor.value = indexList[active];
9163
9359
  if (sticky) {
9164
9360
  children.forEach((item, index) => {
@@ -9177,7 +9373,7 @@ var stdin_default$y = defineComponent({
9177
9373
  if (index === active) {
9178
9374
  state.active = true;
9179
9375
  state.top = Math.max(props.stickyOffsetTop, rects[index].top - scrollTop) + scrollParentRect.top;
9180
- } else if (index === active - 1) {
9376
+ } else if (index === active - 1 && selectActiveIndex === "") {
9181
9377
  const activeItemTop = rects[active].top - scrollTop;
9182
9378
  state.active = activeItemTop > 0;
9183
9379
  state.top = activeItemTop + scrollParentRect.top - rects[index].height;
@@ -9186,6 +9382,7 @@ var stdin_default$y = defineComponent({
9186
9382
  }
9187
9383
  });
9188
9384
  }
9385
+ selectActiveIndex = "";
9189
9386
  };
9190
9387
  const init = () => {
9191
9388
  nextTick(onScroll);
@@ -9211,9 +9408,18 @@ var stdin_default$y = defineComponent({
9211
9408
  }, [index]);
9212
9409
  });
9213
9410
  const scrollTo = (index) => {
9214
- index = String(index);
9215
- const match = children.find((item) => String(item.index) === index);
9411
+ selectActiveIndex = String(index);
9412
+ const match = getMatchAnchor(selectActiveIndex);
9216
9413
  if (match) {
9414
+ const scrollTop = getScrollTop(scrollParent.value);
9415
+ const scrollParentRect = useRect(scrollParent);
9416
+ const {
9417
+ offsetHeight
9418
+ } = document.documentElement;
9419
+ if (scrollTop === offsetHeight - scrollParentRect.height) {
9420
+ onScroll();
9421
+ return;
9422
+ }
9217
9423
  match.$el.scrollIntoView();
9218
9424
  if (props.sticky && props.stickyOffsetTop) {
9219
9425
  setRootScrollTop(getRootScrollTop() - props.stickyOffsetTop);
@@ -9547,10 +9753,10 @@ var stdin_default$v = defineComponent({
9547
9753
  "ref": navBarRef,
9548
9754
  "style": style,
9549
9755
  "class": [bem$p({
9550
- fixed,
9551
- "safe-area-inset-top": props.safeAreaInsetTop
9756
+ fixed
9552
9757
  }), {
9553
- [BORDER_BOTTOM]: border
9758
+ [BORDER_BOTTOM]: border,
9759
+ "van-safe-area-top": props.safeAreaInsetTop
9554
9760
  }]
9555
9761
  }, [createVNode("div", {
9556
9762
  "class": bem$p("content")
@@ -9939,6 +10145,15 @@ const numberKeyboardProps = {
9939
10145
  default: ""
9940
10146
  }
9941
10147
  };
10148
+ function shuffle(array) {
10149
+ for (let i = array.length - 1; i > 0; i--) {
10150
+ const j = Math.floor(Math.random() * (i + 1));
10151
+ const temp = array[i];
10152
+ array[i] = array[j];
10153
+ array[j] = temp;
10154
+ }
10155
+ return array;
10156
+ }
9942
10157
  var stdin_default$r = defineComponent({
9943
10158
  name: name$m,
9944
10159
  props: numberKeyboardProps,
@@ -9953,7 +10168,7 @@ var stdin_default$r = defineComponent({
9953
10168
  text: i + 1
9954
10169
  }));
9955
10170
  if (props.randomKeyOrder) {
9956
- keys2.sort(() => Math.random() > 0.5 ? 1 : -1);
10171
+ shuffle(keys2);
9957
10172
  }
9958
10173
  return keys2;
9959
10174
  };
@@ -10808,33 +11023,53 @@ var stdin_default$l = defineComponent({
10808
11023
  }) {
10809
11024
  const touch = useTouch();
10810
11025
  const [itemRefs, setItemRefs] = useRefs();
11026
+ const groupRef = ref();
10811
11027
  const untouchable = () => props.readonly || props.disabled || !props.touchable;
10812
11028
  const list = computed(() => Array(+props.count).fill("").map((_, i) => getRateStatus(props.modelValue, i + 1, props.allowHalf, props.readonly)));
10813
11029
  let ranges;
11030
+ let groupRefRect;
11031
+ let minRectTop = Number.MAX_SAFE_INTEGER;
11032
+ let maxRectTop = Number.MIN_SAFE_INTEGER;
10814
11033
  const updateRanges = () => {
11034
+ groupRefRect = useRect(groupRef);
10815
11035
  const rects = itemRefs.value.map(useRect);
10816
11036
  ranges = [];
10817
11037
  rects.forEach((rect, index) => {
11038
+ minRectTop = Math.min(rect.top, minRectTop);
11039
+ maxRectTop = Math.max(rect.top, maxRectTop);
10818
11040
  if (props.allowHalf) {
10819
11041
  ranges.push({
10820
11042
  score: index + 0.5,
10821
- left: rect.left
11043
+ left: rect.left,
11044
+ top: rect.top,
11045
+ height: rect.height
10822
11046
  }, {
10823
11047
  score: index + 1,
10824
- left: rect.left + rect.width / 2
11048
+ left: rect.left + rect.width / 2,
11049
+ top: rect.top,
11050
+ height: rect.height
10825
11051
  });
10826
11052
  } else {
10827
11053
  ranges.push({
10828
11054
  score: index + 1,
10829
- left: rect.left
11055
+ left: rect.left,
11056
+ top: rect.top,
11057
+ height: rect.height
10830
11058
  });
10831
11059
  }
10832
11060
  });
10833
11061
  };
10834
- const getScoreByPosition = (x) => {
11062
+ const getScoreByPosition = (x, y) => {
10835
11063
  for (let i = ranges.length - 1; i > 0; i--) {
10836
- if (x > ranges[i].left) {
10837
- return ranges[i].score;
11064
+ if (y >= groupRefRect.top && y <= groupRefRect.bottom) {
11065
+ if (x > ranges[i].left && y >= ranges[i].top && y <= ranges[i].top + ranges[i].height) {
11066
+ return ranges[i].score;
11067
+ }
11068
+ } else {
11069
+ const curTop = y < groupRefRect.top ? minRectTop : maxRectTop;
11070
+ if (x > ranges[i].left && ranges[i].top === curTop) {
11071
+ return ranges[i].score;
11072
+ }
10838
11073
  }
10839
11074
  }
10840
11075
  return props.allowHalf ? 0.5 : 1;
@@ -10859,10 +11094,11 @@ var stdin_default$l = defineComponent({
10859
11094
  touch.move(event);
10860
11095
  if (touch.isHorizontal()) {
10861
11096
  const {
10862
- clientX
11097
+ clientX,
11098
+ clientY
10863
11099
  } = event.touches[0];
10864
11100
  preventDefault(event);
10865
- select(getScoreByPosition(clientX));
11101
+ select(getScoreByPosition(clientX, clientY));
10866
11102
  }
10867
11103
  };
10868
11104
  const renderStar = (item, index) => {
@@ -10891,7 +11127,7 @@ var stdin_default$l = defineComponent({
10891
11127
  }
10892
11128
  const onClickItem = (event) => {
10893
11129
  updateRanges();
10894
- select(allowHalf ? getScoreByPosition(event.clientX) : score);
11130
+ select(allowHalf ? getScoreByPosition(event.clientX, event.clientY) : score);
10895
11131
  };
10896
11132
  return createVNode("div", {
10897
11133
  "key": index,
@@ -10929,6 +11165,7 @@ var stdin_default$l = defineComponent({
10929
11165
  };
10930
11166
  useCustomFieldValue(() => props.modelValue);
10931
11167
  return () => createVNode("div", {
11168
+ "ref": groupRef,
10932
11169
  "role": "radiogroup",
10933
11170
  "class": bem$f({
10934
11171
  readonly: props.readonly,
@@ -10963,7 +11200,7 @@ var stdin_default$k = defineComponent({
10963
11200
  slots,
10964
11201
  attrs
10965
11202
  }) {
10966
- const id = useId();
11203
+ const id = useId$1();
10967
11204
  const filedRef = ref();
10968
11205
  const onCancel = () => {
10969
11206
  if (!slots.action) {
@@ -11053,14 +11290,17 @@ var stdin_default$k = defineComponent({
11053
11290
  }
11054
11291
  });
11055
11292
  const Search = withInstall(stdin_default$k);
11056
- const PRESET_ICONS = ["qq", "link", "weibo", "wechat", "poster", "qrcode", "weapp-qrcode", "wechat-moments"];
11057
11293
  const popupInheritKeys = [...popupSharedPropKeys, "round", "closeOnPopstate", "safeAreaInsetBottom"];
11058
- function getIconURL(icon) {
11059
- if (PRESET_ICONS.includes(icon)) {
11060
- return `https://img.yzcdn.cn/vant/share-sheet-${icon}.png`;
11061
- }
11062
- return icon;
11063
- }
11294
+ const iconMap = {
11295
+ qq: "qq",
11296
+ link: "link-o",
11297
+ weibo: "weibo",
11298
+ qrcode: "qr",
11299
+ poster: "photo-o",
11300
+ wechat: "wechat",
11301
+ "weapp-qrcode": "miniprogram-o",
11302
+ "wechat-moments": "wechat-moments"
11303
+ };
11064
11304
  const [name$e, bem$d, t$2] = createNamespace("share-sheet");
11065
11305
  const shareSheetProps = extend({}, popupSharedProps, {
11066
11306
  title: String,
@@ -11098,6 +11338,19 @@ var stdin_default$j = defineComponent({
11098
11338
  }, [description])]);
11099
11339
  }
11100
11340
  };
11341
+ const renderIcon = (icon) => {
11342
+ if (iconMap[icon]) {
11343
+ return createVNode("div", {
11344
+ "class": bem$d("icon", [icon])
11345
+ }, [createVNode(Icon, {
11346
+ "name": iconMap[icon] || icon
11347
+ }, null)]);
11348
+ }
11349
+ return createVNode("img", {
11350
+ "src": icon,
11351
+ "class": bem$d("image-icon")
11352
+ }, null);
11353
+ };
11101
11354
  const renderOption = (option, index) => {
11102
11355
  const {
11103
11356
  name: name2,
@@ -11110,10 +11363,7 @@ var stdin_default$j = defineComponent({
11110
11363
  "tabindex": 0,
11111
11364
  "class": [bem$d("option"), className, HAPTICS_FEEDBACK],
11112
11365
  "onClick": () => onSelect(option, index)
11113
- }, [createVNode("img", {
11114
- "src": getIconURL(icon),
11115
- "class": bem$d("icon")
11116
- }, null), name2 && createVNode("span", {
11366
+ }, [renderIcon(icon), name2 && createVNode("span", {
11117
11367
  "class": bem$d("name")
11118
11368
  }, [name2]), description && createVNode("span", {
11119
11369
  "class": bem$d("option-description")
@@ -11271,9 +11521,11 @@ const skeletonProps = {
11271
11521
  };
11272
11522
  var stdin_default$g = defineComponent({
11273
11523
  name: name$b,
11524
+ inheritAttrs: false,
11274
11525
  props: skeletonProps,
11275
11526
  setup(props, {
11276
- slots
11527
+ slots,
11528
+ attrs
11277
11529
  }) {
11278
11530
  const renderAvatar = () => {
11279
11531
  if (props.avatar) {
@@ -11316,12 +11568,12 @@ var stdin_default$g = defineComponent({
11316
11568
  if (!props.loading) {
11317
11569
  return (_a = slots.default) == null ? void 0 : _a.call(slots);
11318
11570
  }
11319
- return createVNode("div", {
11571
+ return createVNode("div", mergeProps({
11320
11572
  "class": bem$a({
11321
11573
  animate: props.animate,
11322
11574
  round: props.round
11323
11575
  })
11324
- }, [renderAvatar(), createVNode("div", {
11576
+ }, attrs), [renderAvatar(), createVNode("div", {
11325
11577
  "class": bem$a("content")
11326
11578
  }, [renderTitle(), renderRows()])]);
11327
11579
  };
@@ -12211,7 +12463,7 @@ var stdin_default$a = defineComponent({
12211
12463
  return createVNode("div", {
12212
12464
  "ref": root,
12213
12465
  "class": bem$4(),
12214
- "onClick": getClickHandler("cell"),
12466
+ "onClick": getClickHandler("cell", lockClick2),
12215
12467
  "onTouchstart": onTouchStart,
12216
12468
  "onTouchmove": onTouchMove,
12217
12469
  "onTouchend": onTouchEnd,
@@ -12566,7 +12818,6 @@ var stdin_default$6 = defineComponent({
12566
12818
  });
12567
12819
  const TreeSelect = withInstall(stdin_default$6);
12568
12820
  const [name, bem, t] = createNamespace("uploader");
12569
- const toArray = (item) => Array.isArray(item) ? item : [item];
12570
12821
  function readFileContent(file, resultType) {
12571
12822
  return new Promise((resolve) => {
12572
12823
  if (resultType === "file") {
@@ -12632,7 +12883,7 @@ var stdin_default$5 = defineComponent({
12632
12883
  imageFit: String,
12633
12884
  lazyLoad: Boolean,
12634
12885
  deletable: Boolean,
12635
- previewSize: numericProp,
12886
+ previewSize: [Number, String, Array],
12636
12887
  beforeDelete: Function
12637
12888
  },
12638
12889
  emits: ["delete", "preview"],
@@ -12706,16 +12957,19 @@ var stdin_default$5 = defineComponent({
12706
12957
  };
12707
12958
  const renderPreview = () => {
12708
12959
  const {
12709
- item
12960
+ item,
12961
+ lazyLoad,
12962
+ imageFit,
12963
+ previewSize
12710
12964
  } = props;
12711
12965
  if (isImageFile(item)) {
12712
12966
  return createVNode(Image$1, {
12713
- "fit": props.imageFit,
12967
+ "fit": imageFit,
12714
12968
  "src": item.content || item.url,
12715
12969
  "class": bem("preview-image"),
12716
- "width": props.previewSize,
12717
- "height": props.previewSize,
12718
- "lazyLoad": props.lazyLoad,
12970
+ "width": Array.isArray(previewSize) ? previewSize[0] : previewSize,
12971
+ "height": Array.isArray(previewSize) ? previewSize[1] : previewSize,
12972
+ "lazyLoad": lazyLoad,
12719
12973
  "onClick": onPreview
12720
12974
  }, {
12721
12975
  default: renderCover
@@ -12755,7 +13009,7 @@ const uploaderProps = {
12755
13009
  modelValue: makeArrayProp(),
12756
13010
  beforeRead: Function,
12757
13011
  beforeDelete: Function,
12758
- previewSize: numericProp,
13012
+ previewSize: [Number, String, Array],
12759
13013
  previewImage: truthProp,
12760
13014
  previewOptions: Object,
12761
13015
  previewFullImage: truthProp,
@@ -13822,7 +14076,7 @@ const Lazyload = {
13822
14076
  });
13823
14077
  }
13824
14078
  };
13825
- const version = "4.0.0-alpha.0";
14079
+ const version = "4.0.0-alpha.3";
13826
14080
  function install(app) {
13827
14081
  const components = [
13828
14082
  ActionBar,