vant 3.2.7 → 3.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (191) hide show
  1. package/es/address-edit/AddressEdit.js +154 -180
  2. package/es/address-edit/AddressEditDetail.d.ts +10 -9
  3. package/es/address-edit/AddressEditDetail.js +6 -6
  4. package/es/button/Button.js +2 -2
  5. package/es/calendar/Calendar.js +8 -14
  6. package/es/calendar/CalendarHeader.js +1 -3
  7. package/es/calendar/CalendarMonth.js +11 -10
  8. package/es/calendar/types.d.ts +1 -1
  9. package/es/cascader/Cascader.js +17 -5
  10. package/es/checkbox/Checker.js +1 -1
  11. package/es/checkbox/types.d.ts +2 -6
  12. package/es/composables/use-id.d.ts +1 -0
  13. package/es/composables/use-id.js +14 -0
  14. package/es/composables/use-route.d.ts +1 -1
  15. package/es/composables/use-route.js +4 -4
  16. package/es/count-down/CountDown.js +1 -0
  17. package/es/coupon-list/CouponList.js +40 -24
  18. package/es/coupon-list/index.css +1 -1
  19. package/es/coupon-list/index.less +0 -5
  20. package/es/dropdown-item/DropdownItem.js +7 -2
  21. package/es/dropdown-item/types.d.ts +2 -6
  22. package/es/dropdown-menu/DropdownMenu.js +7 -3
  23. package/es/dropdown-menu/types.d.ts +1 -0
  24. package/es/empty/Network.js +22 -34
  25. package/es/field/Field.d.ts +1 -1
  26. package/es/field/Field.js +13 -5
  27. package/es/field/index.d.ts +2 -2
  28. package/es/field/types.d.ts +7 -6
  29. package/es/form/Form.js +2 -2
  30. package/es/image/Image.js +4 -9
  31. package/es/image-preview/ImagePreview.js +3 -4
  32. package/es/index.d.ts +1 -1
  33. package/es/index.js +1 -1
  34. package/es/lazyload/index.d.ts +1 -1
  35. package/es/lazyload/index.js +1 -1
  36. package/es/lazyload/vue-lazyload/index.d.ts +55 -0
  37. package/es/lazyload/vue-lazyload/index.js +46 -0
  38. package/es/lazyload/vue-lazyload/lazy-component.js +53 -0
  39. package/es/lazyload/vue-lazyload/lazy-container.js +98 -0
  40. package/es/lazyload/vue-lazyload/lazy-image.js +115 -0
  41. package/es/lazyload/vue-lazyload/lazy.js +507 -0
  42. package/es/lazyload/vue-lazyload/listener.js +241 -0
  43. package/es/lazyload/vue-lazyload/util.js +183 -0
  44. package/es/list/List.js +3 -1
  45. package/es/nav-bar/NavBar.d.ts +1 -1
  46. package/es/nav-bar/index.d.ts +1 -1
  47. package/es/number-keyboard/NumberKeyboardKey.js +4 -4
  48. package/es/pagination/Pagination.js +67 -49
  49. package/es/pagination/index.css +1 -1
  50. package/es/pagination/index.less +32 -31
  51. package/es/password-input/PasswordInput.d.ts +21 -1
  52. package/es/password-input/PasswordInput.js +10 -9
  53. package/es/password-input/index.d.ts +2 -1
  54. package/es/popover/Popover.js +2 -0
  55. package/es/popup/Popup.d.ts +1 -2
  56. package/es/popup/Popup.js +2 -5
  57. package/es/popup/index.d.ts +1 -2
  58. package/es/progress/Progress.js +2 -2
  59. package/es/rate/Rate.js +5 -3
  60. package/es/search/Search.js +8 -2
  61. package/es/sidebar/Sidebar.js +1 -0
  62. package/es/sidebar-item/SidebarItem.js +4 -1
  63. package/es/slider/Slider.js +5 -3
  64. package/es/stepper/Stepper.js +11 -8
  65. package/es/submit-bar/SubmitBar.d.ts +4 -3
  66. package/es/submit-bar/index.d.ts +3 -2
  67. package/es/swipe/Swipe.js +11 -6
  68. package/es/swipe/types.d.ts +1 -3
  69. package/es/switch/Switch.js +1 -0
  70. package/es/switch/index.css +1 -1
  71. package/es/switch/index.less +2 -0
  72. package/es/tab/Tab.js +18 -5
  73. package/es/tab/index.css +1 -1
  74. package/es/tab/index.less +1 -1
  75. package/es/tabbar/Tabbar.d.ts +1 -1
  76. package/es/tabbar/Tabbar.js +10 -10
  77. package/es/tabbar-item/TabbarItem.js +16 -7
  78. package/es/tabs/Tabs.js +17 -11
  79. package/es/tabs/TabsTitle.d.ts +6 -0
  80. package/es/tabs/TabsTitle.js +7 -1
  81. package/es/tabs/types.d.ts +1 -0
  82. package/es/uploader/UploaderPreviewItem.js +4 -1
  83. package/es/uploader/utils.d.ts +2 -2
  84. package/es/uploader/utils.js +2 -2
  85. package/es/utils/dom.d.ts +1 -0
  86. package/es/utils/dom.js +6 -2
  87. package/es/utils/format.js +6 -5
  88. package/es/vue-tsx-shim.d.ts +1 -0
  89. package/lib/address-edit/AddressEdit.js +155 -180
  90. package/lib/address-edit/AddressEditDetail.d.ts +10 -9
  91. package/lib/address-edit/AddressEditDetail.js +6 -6
  92. package/lib/button/Button.js +1 -1
  93. package/lib/calendar/Calendar.js +8 -14
  94. package/lib/calendar/CalendarHeader.js +1 -3
  95. package/lib/calendar/CalendarMonth.js +11 -10
  96. package/lib/calendar/types.d.ts +1 -1
  97. package/lib/cascader/Cascader.js +17 -5
  98. package/lib/checkbox/Checker.js +1 -1
  99. package/lib/checkbox/types.d.ts +2 -6
  100. package/lib/composables/use-id.d.ts +1 -0
  101. package/lib/composables/use-id.js +21 -0
  102. package/lib/composables/use-route.d.ts +1 -1
  103. package/lib/composables/use-route.js +4 -4
  104. package/lib/count-down/CountDown.js +1 -0
  105. package/lib/coupon-list/CouponList.js +39 -22
  106. package/lib/coupon-list/index.css +1 -1
  107. package/lib/coupon-list/index.less +0 -5
  108. package/lib/dropdown-item/DropdownItem.js +7 -2
  109. package/lib/dropdown-item/types.d.ts +2 -6
  110. package/lib/dropdown-menu/DropdownMenu.js +7 -2
  111. package/lib/dropdown-menu/types.d.ts +1 -0
  112. package/lib/empty/Network.js +22 -34
  113. package/lib/field/Field.d.ts +1 -1
  114. package/lib/field/Field.js +14 -5
  115. package/lib/field/index.d.ts +2 -2
  116. package/lib/field/types.d.ts +7 -6
  117. package/lib/form/Form.js +1 -1
  118. package/lib/image/Image.js +4 -9
  119. package/lib/image-preview/ImagePreview.js +1 -2
  120. package/lib/index.css +1 -1
  121. package/lib/index.d.ts +1 -1
  122. package/lib/index.js +1 -1
  123. package/lib/lazyload/index.d.ts +1 -1
  124. package/lib/lazyload/index.js +3 -3
  125. package/lib/lazyload/vue-lazyload/index.d.ts +55 -0
  126. package/lib/lazyload/vue-lazyload/index.js +58 -0
  127. package/lib/lazyload/vue-lazyload/lazy-component.js +62 -0
  128. package/lib/lazyload/vue-lazyload/lazy-container.js +106 -0
  129. package/lib/lazyload/vue-lazyload/lazy-image.js +125 -0
  130. package/lib/lazyload/vue-lazyload/lazy.js +520 -0
  131. package/lib/lazyload/vue-lazyload/listener.js +251 -0
  132. package/lib/lazyload/vue-lazyload/util.js +213 -0
  133. package/lib/list/List.js +3 -1
  134. package/lib/nav-bar/NavBar.d.ts +1 -1
  135. package/lib/nav-bar/index.d.ts +1 -1
  136. package/lib/number-keyboard/NumberKeyboardKey.js +3 -3
  137. package/lib/pagination/Pagination.js +65 -47
  138. package/lib/pagination/index.css +1 -1
  139. package/lib/pagination/index.less +32 -31
  140. package/lib/password-input/PasswordInput.d.ts +21 -1
  141. package/lib/password-input/PasswordInput.js +10 -9
  142. package/lib/password-input/index.d.ts +2 -1
  143. package/lib/popover/Popover.js +2 -0
  144. package/lib/popup/Popup.d.ts +1 -2
  145. package/lib/popup/Popup.js +2 -5
  146. package/lib/popup/index.d.ts +1 -2
  147. package/lib/progress/Progress.js +2 -2
  148. package/lib/rate/Rate.js +5 -3
  149. package/lib/search/Search.js +9 -2
  150. package/lib/sidebar/Sidebar.js +1 -0
  151. package/lib/sidebar-item/SidebarItem.js +4 -1
  152. package/lib/slider/Slider.js +5 -3
  153. package/lib/stepper/Stepper.js +11 -8
  154. package/lib/submit-bar/SubmitBar.d.ts +4 -3
  155. package/lib/submit-bar/index.d.ts +3 -2
  156. package/lib/swipe/Swipe.js +9 -4
  157. package/lib/swipe/types.d.ts +1 -3
  158. package/lib/switch/Switch.js +1 -0
  159. package/lib/switch/index.css +1 -1
  160. package/lib/switch/index.less +2 -0
  161. package/lib/tab/Tab.js +20 -5
  162. package/lib/tab/index.css +1 -1
  163. package/lib/tab/index.less +1 -1
  164. package/lib/tabbar/Tabbar.d.ts +1 -1
  165. package/lib/tabbar/Tabbar.js +10 -10
  166. package/lib/tabbar-item/TabbarItem.js +16 -7
  167. package/lib/tabs/Tabs.js +16 -9
  168. package/lib/tabs/TabsTitle.d.ts +6 -0
  169. package/lib/tabs/TabsTitle.js +7 -1
  170. package/lib/tabs/types.d.ts +1 -0
  171. package/lib/uploader/UploaderPreviewItem.js +3 -0
  172. package/lib/uploader/utils.d.ts +2 -2
  173. package/lib/uploader/utils.js +3 -2
  174. package/lib/utils/dom.d.ts +1 -0
  175. package/lib/utils/dom.js +9 -2
  176. package/lib/utils/format.js +7 -5
  177. package/lib/vant.cjs.js +14407 -0
  178. package/lib/vant.cjs.min.js +1 -0
  179. package/lib/vant.es.js +1217 -2203
  180. package/lib/vant.es.min.js +1217 -2203
  181. package/lib/vant.js +1349 -1254
  182. package/lib/vant.min.js +1 -1
  183. package/lib/vue-tsx-shim.d.ts +1 -0
  184. package/package.json +27 -13
  185. package/vetur/attributes.json +115 -115
  186. package/vetur/tags.json +35 -35
  187. package/vetur/web-types.json +370 -366
  188. package/es/composables/use-link-field.d.ts +0 -0
  189. package/es/composables/use-link-field.js +0 -0
  190. package/lib/composables/use-link-field.d.ts +0 -0
  191. package/lib/composables/use-link-field.js +0 -1
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "framework": "vue",
4
4
  "name": "vant",
5
- "version": "3.2.7",
5
+ "version": "3.3.2",
6
6
  "contributions": {
7
7
  "html": {
8
8
  "tags": [
@@ -244,76 +244,72 @@
244
244
  ]
245
245
  },
246
246
  {
247
- "name": "van-action-sheet",
247
+ "name": "van-address-edit",
248
248
  "slots": [
249
249
  {
250
250
  "name": "default",
251
- "description": "自定义面板的展示内容"
252
- },
253
- {
254
- "name": "description",
255
- "description": "自定义描述文案"
256
- },
257
- {
258
- "name": "cancel",
259
- "description": "自定义取消按钮内容"
251
+ "description": "在邮政编码下方插入内容"
260
252
  }
261
253
  ],
262
254
  "events": [
263
255
  {
264
- "name": "select",
265
- "description": "点击选项时触发,禁用或加载状态下不会触发"
256
+ "name": "save",
257
+ "description": "点击保存按钮时触发"
266
258
  },
267
259
  {
268
- "name": "cancel",
269
- "description": "点击取消按钮时触发"
260
+ "name": "focus",
261
+ "description": "输入框聚焦时触发"
270
262
  },
271
263
  {
272
- "name": "open",
273
- "description": "打开面板时触发"
264
+ "name": "delete",
265
+ "description": "确认删除地址时触发"
274
266
  },
275
267
  {
276
- "name": "close",
277
- "description": "关闭面板时触发"
268
+ "name": "select-search",
269
+ "description": "选中搜索结果时触发"
278
270
  },
279
271
  {
280
- "name": "opened",
281
- "description": "打开面板且动画结束后触发"
272
+ "name": "click-area",
273
+ "description": "点击收件地区时触发"
282
274
  },
283
275
  {
284
- "name": "closed",
285
- "description": "关闭面板且动画结束后触发"
276
+ "name": "change-area",
277
+ "description": "修改收件地区时触发"
286
278
  },
287
279
  {
288
- "name": "click-overlay",
289
- "description": "点击遮罩层时触发"
280
+ "name": "change-detail",
281
+ "description": "修改详细地址时触发"
282
+ },
283
+ {
284
+ "name": "change-default",
285
+ "description": "切换是否使用默认地址时触发"
290
286
  }
291
287
  ],
292
288
  "attributes": [
293
289
  {
294
- "name": "v-model:show",
295
- "default": "`false`",
296
- "description": "是否显示动作面板",
290
+ "name": "area-list",
291
+ "default": "-",
292
+ "description": "地区列表",
297
293
  "options": [],
298
294
  "value": {
299
- "type": "boolean",
295
+ "type": "object",
300
296
  "kind": "expression"
301
297
  }
302
298
  },
303
299
  {
304
- "name": "actions",
300
+ "name": "area-columns-placeholder",
305
301
  "default": "`[]`",
306
- "description": "面板选项列表",
302
+ "description": "地区选择列占位提示文字",
307
303
  "options": [],
308
304
  "value": {
309
- "type": "ActionSheetAction[]",
305
+ "type": "string[]",
310
306
  "kind": "expression"
311
307
  }
312
308
  },
313
309
  {
314
- "name": "title",
315
- "default": "-",
316
- "description": "顶部标题",
310
+ "name": "area-placeholder",
311
+ "default": "`选择省 / 市 / 区`",
312
+ "description": "地区输入框占位提示文字",
317
313
  "options": [],
318
314
  "value": {
319
315
  "type": "string",
@@ -321,29 +317,29 @@
321
317
  }
322
318
  },
323
319
  {
324
- "name": "cancel-text",
325
- "default": "-",
326
- "description": "取消按钮文字",
320
+ "name": "address-info",
321
+ "default": "`{}`",
322
+ "description": "地址信息初始值",
327
323
  "options": [],
328
324
  "value": {
329
- "type": "string",
325
+ "type": "AddressEditInfo",
330
326
  "kind": "expression"
331
327
  }
332
328
  },
333
329
  {
334
- "name": "description",
335
- "default": "-",
336
- "description": "选项上方的描述信息",
330
+ "name": "search-result",
331
+ "default": "`[]`",
332
+ "description": "详细地址搜索结果",
337
333
  "options": [],
338
334
  "value": {
339
- "type": "string",
335
+ "type": "AddressEditSearchItem[]",
340
336
  "kind": "expression"
341
337
  }
342
338
  },
343
339
  {
344
- "name": "closeable",
345
- "default": "`true`",
346
- "description": "是否显示关闭图标",
340
+ "name": "show-postal",
341
+ "default": "`false`",
342
+ "description": "是否显示邮政编码",
347
343
  "options": [],
348
344
  "value": {
349
345
  "type": "boolean",
@@ -351,29 +347,39 @@
351
347
  }
352
348
  },
353
349
  {
354
- "name": "close-icon",
355
- "default": "`cross`",
356
- "description": "关闭[图标名称](#/zh-CN/icon)或图片链接",
350
+ "name": "show-delete",
351
+ "default": "`false`",
352
+ "description": "是否显示删除按钮",
357
353
  "options": [],
358
354
  "value": {
359
- "type": "string",
355
+ "type": "boolean",
360
356
  "kind": "expression"
361
357
  }
362
358
  },
363
359
  {
364
- "name": "duration",
365
- "default": "`0.3`",
366
- "description": "动画时长,单位秒,设置为 0 可以禁用动画",
360
+ "name": "show-set-default",
361
+ "default": "`false`",
362
+ "description": "是否显示默认地址栏",
367
363
  "options": [],
368
364
  "value": {
369
- "type": "number | string",
365
+ "type": "boolean",
370
366
  "kind": "expression"
371
367
  }
372
368
  },
373
369
  {
374
- "name": "round",
370
+ "name": "show-search-result",
371
+ "default": "`false`",
372
+ "description": "是否显示搜索结果",
373
+ "options": [],
374
+ "value": {
375
+ "type": "boolean",
376
+ "kind": "expression"
377
+ }
378
+ },
379
+ {
380
+ "name": "show-area",
375
381
  "default": "`true`",
376
- "description": "是否显示圆角",
382
+ "description": "是否显示地区",
377
383
  "options": [],
378
384
  "value": {
379
385
  "type": "boolean",
@@ -381,9 +387,9 @@
381
387
  }
382
388
  },
383
389
  {
384
- "name": "overlay",
390
+ "name": "show-detail",
385
391
  "default": "`true`",
386
- "description": "是否显示遮罩层",
392
+ "description": "是否显示详细地址",
387
393
  "options": [],
388
394
  "value": {
389
395
  "type": "boolean",
@@ -391,61 +397,59 @@
391
397
  }
392
398
  },
393
399
  {
394
- "name": "overlay-class",
395
- "default": "object_",
396
- "description": "自定义遮罩层类名",
397
- "options": [
398
- "-"
399
- ],
400
+ "name": "disable-area",
401
+ "default": "`false`",
402
+ "description": "是否禁用地区选择",
403
+ "options": [],
400
404
  "value": {
401
- "type": "string | Array \\",
405
+ "type": "boolean",
402
406
  "kind": "expression"
403
407
  }
404
408
  },
405
409
  {
406
- "name": "overlay-style",
407
- "default": "-",
408
- "description": "自定义遮罩层样式",
410
+ "name": "save-button-text",
411
+ "default": "`保存`",
412
+ "description": "保存按钮文字",
409
413
  "options": [],
410
414
  "value": {
411
- "type": "object",
415
+ "type": "string",
412
416
  "kind": "expression"
413
417
  }
414
418
  },
415
419
  {
416
- "name": "lock-scroll",
417
- "default": "`true`",
418
- "description": "是否锁定背景滚动",
420
+ "name": "delete-button-text",
421
+ "default": "`删除`",
422
+ "description": "删除按钮文字",
419
423
  "options": [],
420
424
  "value": {
421
- "type": "boolean",
425
+ "type": "string",
422
426
  "kind": "expression"
423
427
  }
424
428
  },
425
429
  {
426
- "name": "lazy-render",
427
- "default": "`true`",
428
- "description": "是否在显示弹层时才渲染节点",
430
+ "name": "detail-rows",
431
+ "default": "`1`",
432
+ "description": "详细地址输入框行数",
429
433
  "options": [],
430
434
  "value": {
431
- "type": "boolean",
435
+ "type": "number | string",
432
436
  "kind": "expression"
433
437
  }
434
438
  },
435
439
  {
436
- "name": "close-on-popstate",
437
- "default": "`true`",
438
- "description": "是否在页面回退时自动关闭",
440
+ "name": "detail-maxlength",
441
+ "default": "`200`",
442
+ "description": "详细地址最大长度",
439
443
  "options": [],
440
444
  "value": {
441
- "type": "boolean",
445
+ "type": "number | string",
442
446
  "kind": "expression"
443
447
  }
444
448
  },
445
449
  {
446
- "name": "close-on-click-action",
450
+ "name": "is-saving",
447
451
  "default": "`false`",
448
- "description": "是否在点击选项后关闭",
452
+ "description": "是否显示保存按钮加载动画",
449
453
  "options": [],
450
454
  "value": {
451
455
  "type": "boolean",
@@ -453,9 +457,9 @@
453
457
  }
454
458
  },
455
459
  {
456
- "name": "close-on-click-overlay",
457
- "default": "`true`",
458
- "description": "是否在点击遮罩层后关闭",
460
+ "name": "is-deleting",
461
+ "default": "`false`",
462
+ "description": "是否显示删除按钮加载动画",
459
463
  "options": [],
460
464
  "value": {
461
465
  "type": "boolean",
@@ -463,32 +467,42 @@
463
467
  }
464
468
  },
465
469
  {
466
- "name": "safe-area-inset-bottom",
467
- "default": "`true`",
468
- "description": "是否开启[底部安全区适配](#/zh-CN/advanced-usage#di-bu-an-quan-qu-gua-pei)",
470
+ "name": "tel-validator",
471
+ "default": "-",
472
+ "description": "手机号格式校验函数",
469
473
  "options": [],
470
474
  "value": {
471
- "type": "boolean",
475
+ "type": "string => boolean",
472
476
  "kind": "expression"
473
477
  }
474
478
  },
475
479
  {
476
- "name": "teleport",
480
+ "name": "tel-maxlength",
477
481
  "default": "-",
478
- "description": "指定挂载的节点,等同于 Teleport 组件的 [to 属性](https://v3.cn.vuejs.org/api/built-in-components.html#teleport)",
482
+ "description": "手机号最大长度",
479
483
  "options": [],
480
484
  "value": {
481
- "type": "string | Element",
485
+ "type": "number | string",
482
486
  "kind": "expression"
483
487
  }
484
488
  },
485
489
  {
486
- "name": "before-close",
490
+ "name": "postal-validator",
487
491
  "default": "-",
488
- "description": "关闭前的回调函数,返回 `false` 可阻止关闭,支持返回 Promise",
492
+ "description": "邮政编码格式校验函数",
489
493
  "options": [],
490
494
  "value": {
491
- "type": "(action: string) => boolean | Promise\\<boolean\\>",
495
+ "type": "string => boolean",
496
+ "kind": "expression"
497
+ }
498
+ },
499
+ {
500
+ "name": "validator",
501
+ "default": "-",
502
+ "description": "自定义校验函数",
503
+ "options": [],
504
+ "value": {
505
+ "type": "(key, val) => string",
492
506
  "kind": "expression"
493
507
  }
494
508
  }
@@ -607,272 +621,7 @@
607
621
  "description": "默认地址标签文字",
608
622
  "options": [],
609
623
  "value": {
610
- "type": "string",
611
- "kind": "expression"
612
- }
613
- }
614
- ]
615
- },
616
- {
617
- "name": "van-address-edit",
618
- "slots": [
619
- {
620
- "name": "default",
621
- "description": "在邮政编码下方插入内容"
622
- }
623
- ],
624
- "events": [
625
- {
626
- "name": "save",
627
- "description": "点击保存按钮时触发"
628
- },
629
- {
630
- "name": "focus",
631
- "description": "输入框聚焦时触发"
632
- },
633
- {
634
- "name": "delete",
635
- "description": "确认删除地址时触发"
636
- },
637
- {
638
- "name": "select-search",
639
- "description": "选中搜索结果时触发"
640
- },
641
- {
642
- "name": "click-area",
643
- "description": "点击收件地区时触发"
644
- },
645
- {
646
- "name": "change-area",
647
- "description": "修改收件地区时触发"
648
- },
649
- {
650
- "name": "change-detail",
651
- "description": "修改详细地址时触发"
652
- },
653
- {
654
- "name": "change-default",
655
- "description": "切换是否使用默认地址时触发"
656
- }
657
- ],
658
- "attributes": [
659
- {
660
- "name": "area-list",
661
- "default": "-",
662
- "description": "地区列表",
663
- "options": [],
664
- "value": {
665
- "type": "object",
666
- "kind": "expression"
667
- }
668
- },
669
- {
670
- "name": "area-columns-placeholder",
671
- "default": "`[]`",
672
- "description": "地区选择列占位提示文字",
673
- "options": [],
674
- "value": {
675
- "type": "string[]",
676
- "kind": "expression"
677
- }
678
- },
679
- {
680
- "name": "area-placeholder",
681
- "default": "`选择省 / 市 / 区`",
682
- "description": "地区输入框占位提示文字",
683
- "options": [],
684
- "value": {
685
- "type": "string",
686
- "kind": "expression"
687
- }
688
- },
689
- {
690
- "name": "address-info",
691
- "default": "`{}`",
692
- "description": "地址信息初始值",
693
- "options": [],
694
- "value": {
695
- "type": "AddressEditInfo",
696
- "kind": "expression"
697
- }
698
- },
699
- {
700
- "name": "search-result",
701
- "default": "`[]`",
702
- "description": "详细地址搜索结果",
703
- "options": [],
704
- "value": {
705
- "type": "AddressEditSearchItem[]",
706
- "kind": "expression"
707
- }
708
- },
709
- {
710
- "name": "show-postal",
711
- "default": "`false`",
712
- "description": "是否显示邮政编码",
713
- "options": [],
714
- "value": {
715
- "type": "boolean",
716
- "kind": "expression"
717
- }
718
- },
719
- {
720
- "name": "show-delete",
721
- "default": "`false`",
722
- "description": "是否显示删除按钮",
723
- "options": [],
724
- "value": {
725
- "type": "boolean",
726
- "kind": "expression"
727
- }
728
- },
729
- {
730
- "name": "show-set-default",
731
- "default": "`false`",
732
- "description": "是否显示默认地址栏",
733
- "options": [],
734
- "value": {
735
- "type": "boolean",
736
- "kind": "expression"
737
- }
738
- },
739
- {
740
- "name": "show-search-result",
741
- "default": "`false`",
742
- "description": "是否显示搜索结果",
743
- "options": [],
744
- "value": {
745
- "type": "boolean",
746
- "kind": "expression"
747
- }
748
- },
749
- {
750
- "name": "show-area",
751
- "default": "`true`",
752
- "description": "是否显示地区",
753
- "options": [],
754
- "value": {
755
- "type": "boolean",
756
- "kind": "expression"
757
- }
758
- },
759
- {
760
- "name": "show-detail",
761
- "default": "`true`",
762
- "description": "是否显示详细地址",
763
- "options": [],
764
- "value": {
765
- "type": "boolean",
766
- "kind": "expression"
767
- }
768
- },
769
- {
770
- "name": "disable-area",
771
- "default": "`false`",
772
- "description": "是否禁用地区选择",
773
- "options": [],
774
- "value": {
775
- "type": "boolean",
776
- "kind": "expression"
777
- }
778
- },
779
- {
780
- "name": "save-button-text",
781
- "default": "`保存`",
782
- "description": "保存按钮文字",
783
- "options": [],
784
- "value": {
785
- "type": "string",
786
- "kind": "expression"
787
- }
788
- },
789
- {
790
- "name": "delete-button-text",
791
- "default": "`删除`",
792
- "description": "删除按钮文字",
793
- "options": [],
794
- "value": {
795
- "type": "string",
796
- "kind": "expression"
797
- }
798
- },
799
- {
800
- "name": "detail-rows",
801
- "default": "`1`",
802
- "description": "详细地址输入框行数",
803
- "options": [],
804
- "value": {
805
- "type": "number | string",
806
- "kind": "expression"
807
- }
808
- },
809
- {
810
- "name": "detail-maxlength",
811
- "default": "`200`",
812
- "description": "详细地址最大长度",
813
- "options": [],
814
- "value": {
815
- "type": "number | string",
816
- "kind": "expression"
817
- }
818
- },
819
- {
820
- "name": "is-saving",
821
- "default": "`false`",
822
- "description": "是否显示保存按钮加载动画",
823
- "options": [],
824
- "value": {
825
- "type": "boolean",
826
- "kind": "expression"
827
- }
828
- },
829
- {
830
- "name": "is-deleting",
831
- "default": "`false`",
832
- "description": "是否显示删除按钮加载动画",
833
- "options": [],
834
- "value": {
835
- "type": "boolean",
836
- "kind": "expression"
837
- }
838
- },
839
- {
840
- "name": "tel-validator",
841
- "default": "-",
842
- "description": "手机号格式校验函数",
843
- "options": [],
844
- "value": {
845
- "type": "string => boolean",
846
- "kind": "expression"
847
- }
848
- },
849
- {
850
- "name": "tel-maxlength",
851
- "default": "-",
852
- "description": "手机号最大长度",
853
- "options": [],
854
- "value": {
855
- "type": "number | string",
856
- "kind": "expression"
857
- }
858
- },
859
- {
860
- "name": "postal-validator",
861
- "default": "-",
862
- "description": "邮政编码格式校验函数",
863
- "options": [],
864
- "value": {
865
- "type": "string => boolean",
866
- "kind": "expression"
867
- }
868
- },
869
- {
870
- "name": "validator",
871
- "default": "-",
872
- "description": "自定义校验函数",
873
- "options": [],
874
- "value": {
875
- "type": "(key, val) => string",
624
+ "type": "string",
876
625
  "kind": "expression"
877
626
  }
878
627
  }
@@ -1053,6 +802,257 @@
1053
802
  }
1054
803
  ]
1055
804
  },
805
+ {
806
+ "name": "van-action-sheet",
807
+ "slots": [
808
+ {
809
+ "name": "default",
810
+ "description": "自定义面板的展示内容"
811
+ },
812
+ {
813
+ "name": "description",
814
+ "description": "自定义描述文案"
815
+ },
816
+ {
817
+ "name": "cancel",
818
+ "description": "自定义取消按钮内容"
819
+ }
820
+ ],
821
+ "events": [
822
+ {
823
+ "name": "select",
824
+ "description": "点击选项时触发,禁用或加载状态下不会触发"
825
+ },
826
+ {
827
+ "name": "cancel",
828
+ "description": "点击取消按钮时触发"
829
+ },
830
+ {
831
+ "name": "open",
832
+ "description": "打开面板时触发"
833
+ },
834
+ {
835
+ "name": "close",
836
+ "description": "关闭面板时触发"
837
+ },
838
+ {
839
+ "name": "opened",
840
+ "description": "打开面板且动画结束后触发"
841
+ },
842
+ {
843
+ "name": "closed",
844
+ "description": "关闭面板且动画结束后触发"
845
+ },
846
+ {
847
+ "name": "click-overlay",
848
+ "description": "点击遮罩层时触发"
849
+ }
850
+ ],
851
+ "attributes": [
852
+ {
853
+ "name": "v-model:show",
854
+ "default": "`false`",
855
+ "description": "是否显示动作面板",
856
+ "options": [],
857
+ "value": {
858
+ "type": "boolean",
859
+ "kind": "expression"
860
+ }
861
+ },
862
+ {
863
+ "name": "actions",
864
+ "default": "`[]`",
865
+ "description": "面板选项列表",
866
+ "options": [],
867
+ "value": {
868
+ "type": "ActionSheetAction[]",
869
+ "kind": "expression"
870
+ }
871
+ },
872
+ {
873
+ "name": "title",
874
+ "default": "-",
875
+ "description": "顶部标题",
876
+ "options": [],
877
+ "value": {
878
+ "type": "string",
879
+ "kind": "expression"
880
+ }
881
+ },
882
+ {
883
+ "name": "cancel-text",
884
+ "default": "-",
885
+ "description": "取消按钮文字",
886
+ "options": [],
887
+ "value": {
888
+ "type": "string",
889
+ "kind": "expression"
890
+ }
891
+ },
892
+ {
893
+ "name": "description",
894
+ "default": "-",
895
+ "description": "选项上方的描述信息",
896
+ "options": [],
897
+ "value": {
898
+ "type": "string",
899
+ "kind": "expression"
900
+ }
901
+ },
902
+ {
903
+ "name": "closeable",
904
+ "default": "`true`",
905
+ "description": "是否显示关闭图标",
906
+ "options": [],
907
+ "value": {
908
+ "type": "boolean",
909
+ "kind": "expression"
910
+ }
911
+ },
912
+ {
913
+ "name": "close-icon",
914
+ "default": "`cross`",
915
+ "description": "关闭[图标名称](#/zh-CN/icon)或图片链接",
916
+ "options": [],
917
+ "value": {
918
+ "type": "string",
919
+ "kind": "expression"
920
+ }
921
+ },
922
+ {
923
+ "name": "duration",
924
+ "default": "`0.3`",
925
+ "description": "动画时长,单位秒,设置为 0 可以禁用动画",
926
+ "options": [],
927
+ "value": {
928
+ "type": "number | string",
929
+ "kind": "expression"
930
+ }
931
+ },
932
+ {
933
+ "name": "round",
934
+ "default": "`true`",
935
+ "description": "是否显示圆角",
936
+ "options": [],
937
+ "value": {
938
+ "type": "boolean",
939
+ "kind": "expression"
940
+ }
941
+ },
942
+ {
943
+ "name": "overlay",
944
+ "default": "`true`",
945
+ "description": "是否显示遮罩层",
946
+ "options": [],
947
+ "value": {
948
+ "type": "boolean",
949
+ "kind": "expression"
950
+ }
951
+ },
952
+ {
953
+ "name": "overlay-class",
954
+ "default": "object_",
955
+ "description": "自定义遮罩层类名",
956
+ "options": [
957
+ "-"
958
+ ],
959
+ "value": {
960
+ "type": "string | Array \\",
961
+ "kind": "expression"
962
+ }
963
+ },
964
+ {
965
+ "name": "overlay-style",
966
+ "default": "-",
967
+ "description": "自定义遮罩层样式",
968
+ "options": [],
969
+ "value": {
970
+ "type": "object",
971
+ "kind": "expression"
972
+ }
973
+ },
974
+ {
975
+ "name": "lock-scroll",
976
+ "default": "`true`",
977
+ "description": "是否锁定背景滚动",
978
+ "options": [],
979
+ "value": {
980
+ "type": "boolean",
981
+ "kind": "expression"
982
+ }
983
+ },
984
+ {
985
+ "name": "lazy-render",
986
+ "default": "`true`",
987
+ "description": "是否在显示弹层时才渲染节点",
988
+ "options": [],
989
+ "value": {
990
+ "type": "boolean",
991
+ "kind": "expression"
992
+ }
993
+ },
994
+ {
995
+ "name": "close-on-popstate",
996
+ "default": "`true`",
997
+ "description": "是否在页面回退时自动关闭",
998
+ "options": [],
999
+ "value": {
1000
+ "type": "boolean",
1001
+ "kind": "expression"
1002
+ }
1003
+ },
1004
+ {
1005
+ "name": "close-on-click-action",
1006
+ "default": "`false`",
1007
+ "description": "是否在点击选项后关闭",
1008
+ "options": [],
1009
+ "value": {
1010
+ "type": "boolean",
1011
+ "kind": "expression"
1012
+ }
1013
+ },
1014
+ {
1015
+ "name": "close-on-click-overlay",
1016
+ "default": "`true`",
1017
+ "description": "是否在点击遮罩层后关闭",
1018
+ "options": [],
1019
+ "value": {
1020
+ "type": "boolean",
1021
+ "kind": "expression"
1022
+ }
1023
+ },
1024
+ {
1025
+ "name": "safe-area-inset-bottom",
1026
+ "default": "`true`",
1027
+ "description": "是否开启[底部安全区适配](#/zh-CN/advanced-usage#di-bu-an-quan-qu-gua-pei)",
1028
+ "options": [],
1029
+ "value": {
1030
+ "type": "boolean",
1031
+ "kind": "expression"
1032
+ }
1033
+ },
1034
+ {
1035
+ "name": "teleport",
1036
+ "default": "-",
1037
+ "description": "指定挂载的节点,等同于 Teleport 组件的 [to 属性](https://v3.cn.vuejs.org/api/built-in-components.html#teleport)",
1038
+ "options": [],
1039
+ "value": {
1040
+ "type": "string | Element",
1041
+ "kind": "expression"
1042
+ }
1043
+ },
1044
+ {
1045
+ "name": "before-close",
1046
+ "default": "-",
1047
+ "description": "关闭前的回调函数,返回 `false` 可阻止关闭,支持返回 Promise",
1048
+ "options": [],
1049
+ "value": {
1050
+ "type": "(action: string) => boolean | Promise\\<boolean\\>",
1051
+ "kind": "expression"
1052
+ }
1053
+ }
1054
+ ]
1055
+ },
1056
1056
  {
1057
1057
  "name": "van-badge",
1058
1058
  "slots": [
@@ -1950,6 +1950,10 @@
1950
1950
  {
1951
1951
  "name": "options-top",
1952
1952
  "description": "自定义选项上方的内容"
1953
+ },
1954
+ {
1955
+ "name": "options-bottom",
1956
+ "description": "自定义选项下方的内容"
1953
1957
  }
1954
1958
  ],
1955
1959
  "events": [
@@ -4446,7 +4450,7 @@
4446
4450
  },
4447
4451
  {
4448
4452
  "name": "id",
4449
- "default": "-",
4453
+ "default": "`van-field-n-input`",
4450
4454
  "description": "输入框 id,同时会设置 label 的 for 属性",
4451
4455
  "options": [],
4452
4456
  "value": {
@@ -6082,7 +6086,7 @@
6082
6086
  },
6083
6087
  {
6084
6088
  "name": "color",
6085
- "default": "`#f60`",
6089
+ "default": "`#ed6a0c`",
6086
6090
  "description": "通知文本颜色",
6087
6091
  "options": [],
6088
6092
  "value": {
@@ -6092,7 +6096,7 @@
6092
6096
  },
6093
6097
  {
6094
6098
  "name": "background",
6095
- "default": "`#fff7cc`",
6099
+ "default": "`#fffbe8`",
6096
6100
  "description": "滚动条背景",
6097
6101
  "options": [],
6098
6102
  "value": {
@@ -7906,7 +7910,7 @@
7906
7910
  },
7907
7911
  {
7908
7912
  "name": "id",
7909
- "default": "-",
7913
+ "default": "`van-search-n-input`",
7910
7914
  "description": "搜索框 id,同时会设置 label 的 for 属性",
7911
7915
  "options": [],
7912
7916
  "value": {