vant 3.2.5 → 3.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/action-bar/ActionBar.d.ts +8 -0
- package/es/action-bar/ActionBar.js +8 -6
- package/es/action-bar/index.css +1 -1
- package/es/action-bar/index.d.ts +1 -0
- package/es/action-bar/index.less +1 -1
- package/es/action-bar/var.less +1 -1
- package/es/action-bar-button/ActionBarButton.d.ts +14 -1
- package/es/action-bar-button/ActionBarButton.js +13 -11
- package/es/action-bar-button/index.d.ts +1 -0
- package/es/action-bar-icon/ActionBarIcon.d.ts +15 -0
- package/es/action-bar-icon/ActionBarIcon.js +16 -14
- package/es/action-bar-icon/index.css +1 -1
- package/es/action-bar-icon/index.d.ts +1 -0
- package/es/action-bar-icon/index.less +1 -1
- package/es/action-bar-icon/var.less +1 -1
- package/es/action-sheet/ActionSheet.d.ts +72 -9
- package/es/action-sheet/ActionSheet.js +25 -30
- package/es/action-sheet/index.css +1 -1
- package/es/action-sheet/index.d.ts +11 -4
- package/es/action-sheet/index.less +2 -7
- package/es/action-sheet/var.less +4 -5
- package/es/address-edit/AddressEdit.d.ts +3 -4
- package/es/address-edit/AddressEdit.js +164 -193
- package/es/address-edit/AddressEditDetail.d.ts +10 -9
- package/es/address-edit/AddressEditDetail.js +15 -15
- package/es/address-edit/index.css +1 -1
- package/es/address-edit/index.d.ts +1 -2
- package/es/address-edit/index.less +2 -2
- package/es/address-edit/style/index.js +0 -3
- package/es/address-edit/style/less.js +0 -3
- package/es/address-list/AddressList.d.ts +20 -0
- package/es/address-list/AddressList.js +18 -19
- package/es/address-list/AddressListItem.js +6 -4
- package/es/address-list/index.css +1 -1
- package/es/address-list/index.d.ts +1 -0
- package/es/address-list/index.less +2 -2
- package/es/address-list/var.less +2 -2
- package/es/area/Area.d.ts +2 -2
- package/es/area/Area.js +20 -9
- package/es/area/index.d.ts +1 -2
- package/es/badge/Badge.d.ts +18 -2
- package/es/badge/Badge.js +17 -14
- package/es/badge/index.css +1 -1
- package/es/badge/index.d.ts +2 -1
- package/es/badge/index.less +5 -3
- package/es/button/Button.d.ts +43 -5
- package/es/button/Button.js +31 -28
- package/es/button/index.css +1 -1
- package/es/button/index.d.ts +18 -17
- package/es/button/types.d.ts +5 -0
- package/es/button/types.js +1 -0
- package/es/button/var.less +1 -1
- package/es/calendar/Calendar.d.ts +2 -2
- package/es/calendar/Calendar.js +43 -18
- package/es/calendar/CalendarDay.js +5 -4
- package/es/calendar/CalendarHeader.js +7 -7
- package/es/calendar/CalendarMonth.d.ts +2 -2
- package/es/calendar/CalendarMonth.js +7 -6
- package/es/calendar/index.css +1 -1
- package/es/calendar/index.d.ts +1 -2
- package/es/calendar/index.less +3 -3
- package/es/calendar/types.d.ts +1 -1
- package/es/calendar/utils.d.ts +1 -1
- package/es/calendar/var.less +2 -2
- package/es/card/Card.d.ts +18 -0
- package/es/card/Card.js +20 -17
- package/es/card/index.css +1 -1
- package/es/card/index.d.ts +1 -0
- package/es/card/index.less +1 -1
- package/es/card/var.less +3 -3
- package/es/cascader/Cascader.d.ts +25 -14
- package/es/cascader/Cascader.js +81 -60
- package/es/cascader/index.css +1 -1
- package/es/cascader/index.d.ts +7 -6
- package/es/cascader/index.less +0 -5
- package/es/cascader/types.d.ts +18 -0
- package/es/cascader/types.js +1 -0
- package/es/cascader/var.less +2 -3
- package/es/cell/Cell.d.ts +35 -5
- package/es/cell/Cell.js +8 -13
- package/es/cell/index.css +1 -1
- package/es/cell/index.d.ts +3 -3
- package/es/cell/index.less +1 -1
- package/es/cell/var.less +3 -3
- package/es/cell-group/CellGroup.d.ts +10 -0
- package/es/cell-group/CellGroup.js +12 -9
- package/es/cell-group/index.css +1 -1
- package/es/cell-group/index.d.ts +1 -0
- package/es/cell-group/index.less +1 -1
- package/es/cell-group/var.less +2 -2
- package/es/checkbox/Checkbox.d.ts +2 -2
- package/es/checkbox/Checkbox.js +12 -7
- package/es/checkbox/Checker.js +7 -13
- package/es/checkbox/index.css +1 -1
- package/es/checkbox/index.d.ts +2 -3
- package/es/checkbox/types.d.ts +5 -6
- package/es/checkbox/var.less +1 -1
- package/es/checkbox-group/CheckboxGroup.d.ts +2 -2
- package/es/checkbox-group/CheckboxGroup.js +12 -7
- package/es/checkbox-group/index.d.ts +2 -3
- package/es/checkbox-group/types.d.ts +2 -1
- package/es/circle/Circle.d.ts +37 -1
- package/es/circle/Circle.js +20 -18
- package/es/circle/index.d.ts +1 -1
- package/es/col/Col.d.ts +13 -0
- package/es/col/Col.js +10 -8
- package/es/col/index.d.ts +1 -0
- package/es/collapse/Collapse.d.ts +13 -1
- package/es/collapse/Collapse.js +14 -12
- package/es/collapse/index.d.ts +1 -0
- package/es/collapse-item/CollapseItem.d.ts +5 -5
- package/es/collapse-item/CollapseItem.js +13 -8
- package/es/collapse-item/index.css +1 -1
- package/es/collapse-item/index.d.ts +3 -4
- package/es/collapse-item/index.less +1 -1
- package/es/collapse-item/var.less +3 -3
- package/es/composables/use-id.d.ts +1 -0
- package/es/composables/use-id.js +14 -0
- package/es/composables/use-route.d.ts +1 -1
- package/es/composables/use-route.js +4 -4
- package/es/config-provider/ConfigProvider.d.ts +11 -2
- package/es/config-provider/ConfigProvider.js +10 -8
- package/es/config-provider/index.d.ts +2 -1
- package/es/contact-card/ContactCard.d.ts +15 -0
- package/es/contact-card/ContactCard.js +13 -10
- package/es/contact-card/index.css +1 -1
- package/es/contact-card/index.d.ts +1 -1
- package/es/contact-card/index.less +2 -2
- package/es/contact-edit/ContactEdit.d.ts +17 -1
- package/es/contact-edit/ContactEdit.js +21 -22
- package/es/contact-edit/index.d.ts +1 -1
- package/es/contact-edit/style/index.js +0 -5
- package/es/contact-edit/style/less.js +0 -5
- package/es/contact-list/ContactList.d.ts +8 -1
- package/es/contact-list/ContactList.js +12 -9
- package/es/contact-list/index.css +1 -1
- package/es/contact-list/index.d.ts +1 -1
- package/es/contact-list/index.less +1 -1
- package/es/count-down/CountDown.d.ts +2 -2
- package/es/count-down/CountDown.js +8 -6
- package/es/count-down/index.d.ts +1 -2
- package/es/coupon/Coupon.js +2 -11
- package/es/coupon/index.css +1 -1
- package/es/coupon/index.less +3 -2
- package/es/coupon/utils.d.ts +3 -0
- package/es/coupon/utils.js +7 -0
- package/es/coupon/var.less +3 -2
- package/es/coupon-cell/CouponCell.d.ts +25 -0
- package/es/coupon-cell/CouponCell.js +17 -12
- package/es/coupon-cell/index.d.ts +1 -0
- package/es/coupon-list/CouponList.d.ts +55 -0
- package/es/coupon-list/CouponList.js +66 -48
- package/es/coupon-list/index.css +1 -1
- package/es/coupon-list/index.d.ts +1 -0
- package/es/coupon-list/index.less +4 -9
- package/es/coupon-list/var.less +1 -1
- package/es/datetime-picker/DatePicker.js +13 -10
- package/es/datetime-picker/DatetimePicker.d.ts +2 -2
- package/es/datetime-picker/DatetimePicker.js +10 -9
- package/es/datetime-picker/TimePicker.js +13 -10
- package/es/datetime-picker/utils.d.ts +1 -1
- package/es/datetime-picker/utils.js +3 -3
- package/es/dialog/Dialog.d.ts +55 -1
- package/es/dialog/Dialog.js +31 -34
- package/es/dialog/function-call.d.ts +2 -2
- package/es/dialog/function-call.js +2 -2
- package/es/dialog/index.css +1 -1
- package/es/dialog/index.d.ts +1 -0
- package/es/dialog/index.less +1 -1
- package/es/dialog/var.less +1 -1
- package/es/divider/Divider.d.ts +13 -0
- package/es/divider/Divider.js +10 -8
- package/es/divider/index.css +1 -1
- package/es/divider/index.d.ts +1 -1
- package/es/divider/var.less +1 -1
- package/es/dropdown-item/DropdownItem.d.ts +2 -2
- package/es/dropdown-item/DropdownItem.js +24 -10
- package/es/dropdown-item/types.d.ts +2 -6
- package/es/dropdown-menu/DropdownMenu.d.ts +2 -2
- package/es/dropdown-menu/DropdownMenu.js +17 -10
- package/es/dropdown-menu/index.css +1 -1
- package/es/dropdown-menu/index.less +1 -9
- package/es/dropdown-menu/types.d.ts +1 -0
- package/es/dropdown-menu/var.less +2 -2
- package/es/empty/Empty.d.ts +10 -0
- package/es/empty/Empty.js +11 -8
- package/es/empty/Network.js +26 -57
- package/es/empty/index.css +1 -1
- package/es/empty/index.d.ts +1 -0
- package/es/empty/var.less +1 -1
- package/es/field/Field.d.ts +6 -6
- package/es/field/Field.js +60 -39
- package/es/field/index.css +1 -1
- package/es/field/index.d.ts +4 -4
- package/es/field/types.d.ts +7 -6
- package/es/field/utils.d.ts +2 -2
- package/es/field/utils.js +9 -6
- package/es/field/var.less +3 -3
- package/es/form/Form.d.ts +2 -2
- package/es/form/Form.js +9 -8
- package/es/grid/Grid.d.ts +3 -2
- package/es/grid/Grid.js +6 -5
- package/es/grid/index.d.ts +1 -1
- package/es/grid-item/GridItem.d.ts +14 -0
- package/es/grid-item/GridItem.js +16 -14
- package/es/grid-item/index.css +1 -1
- package/es/grid-item/index.d.ts +1 -0
- package/es/grid-item/index.less +1 -1
- package/es/grid-item/var.less +1 -1
- package/es/icon/Icon.d.ts +14 -0
- package/es/icon/Icon.js +14 -12
- package/es/icon/index.d.ts +1 -0
- package/es/image/Image.d.ts +31 -2
- package/es/image/Image.js +43 -55
- package/es/image/index.css +1 -1
- package/es/image/index.d.ts +2 -2
- package/es/image/index.less +1 -1
- package/es/image/var.less +1 -1
- package/es/image-preview/ImagePreview.d.ts +2 -2
- package/es/image-preview/ImagePreview.js +16 -17
- package/es/image-preview/ImagePreviewItem.js +4 -3
- package/es/image-preview/function-call.js +7 -3
- package/es/image-preview/index.css +1 -1
- package/es/image-preview/index.less +1 -6
- package/es/image-preview/var.less +0 -1
- package/es/index-anchor/IndexAnchor.d.ts +5 -0
- package/es/index-anchor/IndexAnchor.js +8 -6
- package/es/index-anchor/index.css +1 -1
- package/es/index-anchor/index.d.ts +1 -0
- package/es/index-anchor/index.less +2 -2
- package/es/index-anchor/var.less +1 -1
- package/es/index-bar/IndexBar.d.ts +2 -2
- package/es/index-bar/IndexBar.js +8 -18
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/lazyload/index.d.ts +1 -1
- package/es/lazyload/index.js +1 -1
- package/es/lazyload/vue-lazyload/index.d.ts +55 -0
- package/es/lazyload/vue-lazyload/index.js +46 -0
- package/es/lazyload/vue-lazyload/lazy-component.js +53 -0
- package/es/lazyload/vue-lazyload/lazy-container.js +98 -0
- package/es/lazyload/vue-lazyload/lazy-image.js +115 -0
- package/es/lazyload/vue-lazyload/lazy.js +507 -0
- package/es/lazyload/vue-lazyload/listener.js +241 -0
- package/es/lazyload/vue-lazyload/util.js +183 -0
- package/es/list/List.d.ts +2 -2
- package/es/list/List.js +10 -7
- package/es/list/index.css +1 -1
- package/es/list/var.less +1 -1
- package/es/loading/Loading.d.ts +13 -0
- package/es/loading/Loading.js +13 -11
- package/es/loading/index.css +1 -1
- package/es/loading/index.d.ts +1 -1
- package/es/loading/var.less +1 -1
- package/es/locale/index.js +5 -1
- package/es/locale/lang/de-DE-formal.d.ts +0 -1
- package/es/locale/lang/de-DE-formal.js +0 -1
- package/es/locale/lang/de-DE.d.ts +0 -1
- package/es/locale/lang/de-DE.js +0 -1
- package/es/locale/lang/en-US.d.ts +0 -1
- package/es/locale/lang/en-US.js +0 -1
- package/es/locale/lang/es-ES.d.ts +0 -1
- package/es/locale/lang/es-ES.js +0 -1
- package/es/locale/lang/fr-FR.d.ts +0 -1
- package/es/locale/lang/fr-FR.js +0 -1
- package/es/locale/lang/ja-JP.d.ts +0 -1
- package/es/locale/lang/ja-JP.js +0 -1
- package/es/locale/lang/nb-NO.d.ts +0 -1
- package/es/locale/lang/nb-NO.js +0 -1
- package/es/locale/lang/ro-RO.d.ts +0 -1
- package/es/locale/lang/ro-RO.js +0 -1
- package/es/locale/lang/ru-RU.d.ts +0 -1
- package/es/locale/lang/ru-RU.js +0 -1
- package/es/locale/lang/th-TH.d.ts +0 -1
- package/es/locale/lang/th-TH.js +0 -1
- package/es/locale/lang/tr-TR.d.ts +0 -1
- package/es/locale/lang/tr-TR.js +0 -1
- package/es/locale/lang/zh-CN.d.ts +0 -1
- package/es/locale/lang/zh-CN.js +0 -1
- package/es/locale/lang/zh-HK.d.ts +0 -1
- package/es/locale/lang/zh-HK.js +0 -1
- package/es/locale/lang/zh-TW.d.ts +0 -1
- package/es/locale/lang/zh-TW.js +0 -1
- package/es/nav-bar/NavBar.d.ts +16 -0
- package/es/nav-bar/NavBar.js +20 -18
- package/es/nav-bar/index.css +1 -1
- package/es/nav-bar/index.d.ts +1 -0
- package/es/nav-bar/index.less +1 -5
- package/es/nav-bar/var.less +1 -1
- package/es/notice-bar/NoticeBar.d.ts +3 -3
- package/es/notice-bar/NoticeBar.js +7 -6
- package/es/notice-bar/index.css +1 -1
- package/es/notice-bar/index.d.ts +1 -1
- package/es/notice-bar/index.less +1 -1
- package/es/notify/Notify.d.ts +42 -2
- package/es/notify/Notify.js +20 -12
- package/es/notify/function-call.d.ts +4 -2
- package/es/notify/function-call.js +1 -1
- package/es/notify/index.css +1 -1
- package/es/notify/index.d.ts +1 -0
- package/es/notify/index.less +4 -4
- package/es/number-keyboard/NumberKeyboard.d.ts +48 -1
- package/es/number-keyboard/NumberKeyboard.js +30 -28
- package/es/number-keyboard/NumberKeyboardKey.js +9 -8
- package/es/number-keyboard/index.css +1 -1
- package/es/number-keyboard/index.d.ts +1 -1
- package/es/number-keyboard/index.less +3 -7
- package/es/number-keyboard/var.less +1 -1
- package/es/overlay/Overlay.d.ts +13 -1
- package/es/overlay/Overlay.js +15 -13
- package/es/overlay/index.css +1 -1
- package/es/overlay/index.d.ts +1 -0
- package/es/overlay/index.less +1 -1
- package/es/pagination/Pagination.d.ts +31 -0
- package/es/pagination/Pagination.js +84 -64
- package/es/pagination/index.css +1 -1
- package/es/pagination/index.d.ts +1 -1
- package/es/pagination/index.less +33 -32
- package/es/pagination/var.less +1 -1
- package/es/password-input/PasswordInput.d.ts +21 -1
- package/es/password-input/PasswordInput.js +15 -12
- package/es/password-input/index.css +1 -1
- package/es/password-input/index.d.ts +2 -1
- package/es/password-input/index.less +3 -3
- package/es/password-input/var.less +3 -3
- package/es/picker/Picker.d.ts +40 -1
- package/es/picker/Picker.js +20 -17
- package/es/picker/PickerColumn.js +5 -4
- package/es/picker/index.css +1 -1
- package/es/picker/index.less +4 -12
- package/es/picker/var.less +9 -3
- package/es/popover/Popover.d.ts +50 -11
- package/es/popover/Popover.js +38 -34
- package/es/popover/index.css +1 -1
- package/es/popover/index.d.ts +17 -16
- package/es/popover/index.less +2 -2
- package/es/popover/types.d.ts +11 -0
- package/es/popover/types.js +1 -0
- package/es/popover/var.less +3 -3
- package/es/popup/Popup.d.ts +48 -3
- package/es/popup/Popup.js +25 -28
- package/es/popup/index.css +1 -1
- package/es/popup/index.d.ts +2 -3
- package/es/popup/index.less +1 -6
- package/es/popup/var.less +1 -2
- package/es/progress/Progress.d.ts +2 -2
- package/es/progress/Progress.js +11 -7
- package/es/progress/index.css +1 -1
- package/es/progress/index.less +10 -1
- package/es/progress/var.less +1 -0
- package/es/pull-refresh/PullRefresh.d.ts +23 -0
- package/es/pull-refresh/PullRefresh.js +20 -18
- package/es/pull-refresh/index.css +1 -1
- package/es/pull-refresh/index.d.ts +1 -0
- package/es/pull-refresh/var.less +1 -1
- package/es/radio/Radio.d.ts +11 -6
- package/es/radio/Radio.js +5 -4
- package/es/radio/index.css +1 -1
- package/es/radio/index.d.ts +1 -0
- package/es/radio/var.less +1 -1
- package/es/radio-group/RadioGroup.d.ts +4 -2
- package/es/radio-group/RadioGroup.js +7 -6
- package/es/radio-group/index.d.ts +1 -0
- package/es/rate/Rate.d.ts +33 -0
- package/es/rate/Rate.js +26 -22
- package/es/rate/index.d.ts +1 -0
- package/es/row/Row.d.ts +18 -1
- package/es/row/Row.js +12 -10
- package/es/row/index.d.ts +1 -1
- package/es/search/Search.d.ts +2 -2
- package/es/search/Search.js +19 -13
- package/es/search/index.css +1 -1
- package/es/search/index.less +2 -2
- package/es/search/var.less +1 -1
- package/es/share-sheet/ShareSheet.d.ts +55 -0
- package/es/share-sheet/ShareSheet.js +22 -20
- package/es/share-sheet/index.css +1 -1
- package/es/share-sheet/index.d.ts +8 -1
- package/es/share-sheet/index.less +0 -4
- package/es/share-sheet/var.less +3 -3
- package/es/sidebar/Sidebar.d.ts +8 -1
- package/es/sidebar/Sidebar.js +10 -7
- package/es/sidebar/index.d.ts +1 -0
- package/es/sidebar-item/SidebarItem.d.ts +12 -0
- package/es/sidebar-item/SidebarItem.js +16 -11
- package/es/sidebar-item/index.css +1 -1
- package/es/sidebar-item/index.d.ts +1 -0
- package/es/sidebar-item/index.less +1 -1
- package/es/sidebar-item/var.less +2 -2
- package/es/skeleton/Skeleton.d.ts +29 -1
- package/es/skeleton/Skeleton.js +21 -18
- package/es/skeleton/index.css +1 -1
- package/es/skeleton/index.d.ts +5 -6
- package/es/skeleton/index.less +2 -2
- package/es/slider/Slider.d.ts +31 -3
- package/es/slider/Slider.js +29 -25
- package/es/slider/index.css +1 -1
- package/es/slider/index.d.ts +3 -2
- package/es/slider/index.less +3 -3
- package/es/step/Step.js +4 -3
- package/es/step/index.css +1 -1
- package/es/step/index.less +1 -1
- package/es/step/var.less +1 -1
- package/es/stepper/Stepper.d.ts +54 -2
- package/es/stepper/Stepper.js +50 -41
- package/es/stepper/index.css +1 -1
- package/es/stepper/index.d.ts +3 -4
- package/es/stepper/index.less +6 -21
- package/es/stepper/var.less +1 -2
- package/es/steps/Steps.d.ts +3 -2
- package/es/steps/Steps.js +7 -6
- package/es/steps/index.css +1 -1
- package/es/steps/index.d.ts +1 -0
- package/es/steps/var.less +1 -1
- package/es/sticky/Sticky.d.ts +18 -1
- package/es/sticky/Sticky.js +13 -11
- package/es/sticky/index.d.ts +1 -1
- package/es/style/base.css +1 -1
- package/es/style/base.less +4 -0
- package/es/style/css-variables.css +1 -1
- package/es/style/css-variables.less +3 -1
- package/es/style/mixins/hairline.less +3 -3
- package/es/style/var.less +5 -3
- package/es/submit-bar/SubmitBar.d.ts +33 -3
- package/es/submit-bar/SubmitBar.js +23 -20
- package/es/submit-bar/index.css +1 -1
- package/es/submit-bar/index.d.ts +3 -2
- package/es/submit-bar/index.less +2 -2
- package/es/submit-bar/var.less +3 -3
- package/es/swipe/Swipe.d.ts +2 -2
- package/es/swipe/Swipe.js +32 -18
- package/es/swipe/types.d.ts +1 -3
- package/es/swipe-cell/SwipeCell.d.ts +2 -2
- package/es/swipe-cell/SwipeCell.js +13 -9
- package/es/swipe-item/SwipeItem.js +4 -3
- package/es/switch/Switch.d.ts +18 -0
- package/es/switch/Switch.js +23 -19
- package/es/switch/index.css +1 -1
- package/es/switch/index.d.ts +1 -0
- package/es/switch/index.less +5 -3
- package/es/switch/var.less +1 -1
- package/es/tab/Tab.d.ts +19 -1
- package/es/tab/Tab.js +33 -18
- package/es/tab/index.css +1 -1
- package/es/tab/index.d.ts +1 -0
- package/es/tab/index.less +1 -1
- package/es/tabbar/Tabbar.d.ts +4 -3
- package/es/tabbar/Tabbar.js +17 -17
- package/es/tabbar/index.css +1 -1
- package/es/tabbar/index.d.ts +1 -0
- package/es/tabbar/index.less +1 -1
- package/es/tabbar/var.less +1 -1
- package/es/tabbar-item/TabbarItem.d.ts +13 -0
- package/es/tabbar-item/TabbarItem.js +27 -18
- package/es/tabbar-item/index.css +1 -1
- package/es/tabbar-item/index.d.ts +1 -0
- package/es/tabbar-item/var.less +1 -1
- package/es/tabs/Tabs.d.ts +2 -2
- package/es/tabs/Tabs.js +32 -23
- package/es/tabs/TabsContent.js +5 -4
- package/es/tabs/TabsTitle.d.ts +6 -0
- package/es/tabs/TabsTitle.js +7 -1
- package/es/tabs/index.css +1 -1
- package/es/tabs/index.less +2 -2
- package/es/tabs/types.d.ts +1 -0
- package/es/tabs/var.less +2 -2
- package/es/tag/Tag.d.ts +23 -3
- package/es/tag/Tag.js +18 -15
- package/es/tag/index.css +1 -1
- package/es/tag/index.d.ts +3 -2
- package/es/tag/index.less +6 -6
- package/es/tag/var.less +1 -1
- package/es/toast/Toast.d.ts +33 -1
- package/es/toast/Toast.js +29 -33
- package/es/toast/function-call.js +10 -2
- package/es/toast/index.css +1 -1
- package/es/toast/index.d.ts +1 -0
- package/es/toast/index.less +1 -1
- package/es/tree-select/TreeSelect.d.ts +28 -1
- package/es/tree-select/TreeSelect.js +18 -15
- package/es/tree-select/index.css +1 -1
- package/es/tree-select/index.d.ts +1 -1
- package/es/tree-select/index.less +2 -2
- package/es/tree-select/var.less +1 -1
- package/es/uploader/Uploader.d.ts +2 -2
- package/es/uploader/Uploader.js +17 -10
- package/es/uploader/UploaderPreviewItem.js +13 -9
- package/es/uploader/index.css +1 -1
- package/es/uploader/index.less +4 -4
- package/es/uploader/utils.d.ts +2 -2
- package/es/uploader/utils.js +2 -2
- package/es/uploader/var.less +1 -1
- package/es/utils/constant.d.ts +1 -0
- package/es/utils/constant.js +1 -0
- package/es/utils/create.d.ts +2 -2
- package/es/utils/create.js +6 -1
- package/es/utils/deep-assign.d.ts +1 -1
- package/es/utils/deep-assign.js +1 -1
- package/es/utils/deep-clone.js +2 -2
- package/es/utils/dom.d.ts +1 -1
- package/es/utils/dom.js +6 -7
- package/es/utils/format.js +20 -7
- package/es/utils/interceptor.d.ts +3 -4
- package/es/utils/interceptor.js +4 -5
- package/es/vue-tsx-shim.d.ts +1 -0
- package/lib/action-bar/ActionBar.d.ts +8 -0
- package/lib/action-bar/ActionBar.js +8 -6
- package/lib/action-bar/index.css +1 -1
- package/lib/action-bar/index.d.ts +1 -0
- package/lib/action-bar/index.less +1 -1
- package/lib/action-bar/var.less +1 -1
- package/lib/action-bar-button/ActionBarButton.d.ts +14 -1
- package/lib/action-bar-button/ActionBarButton.js +13 -11
- package/lib/action-bar-button/index.d.ts +1 -0
- package/lib/action-bar-icon/ActionBarIcon.d.ts +15 -0
- package/lib/action-bar-icon/ActionBarIcon.js +16 -14
- package/lib/action-bar-icon/index.css +1 -1
- package/lib/action-bar-icon/index.d.ts +1 -0
- package/lib/action-bar-icon/index.less +1 -1
- package/lib/action-bar-icon/var.less +1 -1
- package/lib/action-sheet/ActionSheet.d.ts +72 -9
- package/lib/action-sheet/ActionSheet.js +24 -29
- package/lib/action-sheet/index.css +1 -1
- package/lib/action-sheet/index.d.ts +11 -4
- package/lib/action-sheet/index.less +2 -7
- package/lib/action-sheet/var.less +4 -5
- package/lib/address-edit/AddressEdit.d.ts +3 -4
- package/lib/address-edit/AddressEdit.js +165 -194
- package/lib/address-edit/AddressEditDetail.d.ts +10 -9
- package/lib/address-edit/AddressEditDetail.js +14 -14
- package/lib/address-edit/index.css +1 -1
- package/lib/address-edit/index.d.ts +1 -2
- package/lib/address-edit/index.less +2 -2
- package/lib/address-edit/style/index.js +0 -6
- package/lib/address-edit/style/less.js +0 -6
- package/lib/address-list/AddressList.d.ts +20 -0
- package/lib/address-list/AddressList.js +18 -19
- package/lib/address-list/AddressListItem.js +6 -4
- package/lib/address-list/index.css +1 -1
- package/lib/address-list/index.d.ts +1 -0
- package/lib/address-list/index.less +2 -2
- package/lib/address-list/var.less +2 -2
- package/lib/area/Area.d.ts +2 -2
- package/lib/area/Area.js +19 -8
- package/lib/area/index.d.ts +1 -2
- package/lib/badge/Badge.d.ts +18 -2
- package/lib/badge/Badge.js +16 -13
- package/lib/badge/index.css +1 -1
- package/lib/badge/index.d.ts +2 -1
- package/lib/badge/index.less +5 -3
- package/lib/button/Button.d.ts +43 -5
- package/lib/button/Button.js +28 -26
- package/lib/button/index.css +1 -1
- package/lib/button/index.d.ts +18 -17
- package/lib/button/types.d.ts +5 -0
- package/lib/button/types.js +3 -0
- package/lib/button/var.less +1 -1
- package/lib/calendar/Calendar.d.ts +2 -2
- package/lib/calendar/Calendar.js +43 -18
- package/lib/calendar/CalendarDay.js +5 -4
- package/lib/calendar/CalendarHeader.js +7 -7
- package/lib/calendar/CalendarMonth.d.ts +2 -2
- package/lib/calendar/CalendarMonth.js +7 -6
- package/lib/calendar/index.css +1 -1
- package/lib/calendar/index.d.ts +1 -2
- package/lib/calendar/index.less +3 -3
- package/lib/calendar/types.d.ts +1 -1
- package/lib/calendar/utils.d.ts +1 -1
- package/lib/calendar/var.less +2 -2
- package/lib/card/Card.d.ts +18 -0
- package/lib/card/Card.js +20 -17
- package/lib/card/index.css +1 -1
- package/lib/card/index.d.ts +1 -0
- package/lib/card/index.less +1 -1
- package/lib/card/var.less +3 -3
- package/lib/cascader/Cascader.d.ts +25 -14
- package/lib/cascader/Cascader.js +79 -58
- package/lib/cascader/index.css +1 -1
- package/lib/cascader/index.d.ts +7 -6
- package/lib/cascader/index.less +0 -5
- package/lib/cascader/types.d.ts +18 -0
- package/lib/cascader/types.js +3 -0
- package/lib/cascader/var.less +2 -3
- package/lib/cell/Cell.d.ts +35 -5
- package/lib/cell/Cell.js +10 -15
- package/lib/cell/index.css +1 -1
- package/lib/cell/index.d.ts +3 -3
- package/lib/cell/index.less +1 -1
- package/lib/cell/var.less +3 -3
- package/lib/cell-group/CellGroup.d.ts +10 -0
- package/lib/cell-group/CellGroup.js +13 -10
- package/lib/cell-group/index.css +1 -1
- package/lib/cell-group/index.d.ts +1 -0
- package/lib/cell-group/index.less +1 -1
- package/lib/cell-group/var.less +2 -2
- package/lib/checkbox/Checkbox.d.ts +2 -2
- package/lib/checkbox/Checkbox.js +12 -7
- package/lib/checkbox/Checker.js +7 -13
- package/lib/checkbox/index.css +1 -1
- package/lib/checkbox/index.d.ts +2 -3
- package/lib/checkbox/types.d.ts +5 -6
- package/lib/checkbox/var.less +1 -1
- package/lib/checkbox-group/CheckboxGroup.d.ts +2 -2
- package/lib/checkbox-group/CheckboxGroup.js +12 -7
- package/lib/checkbox-group/index.d.ts +2 -3
- package/lib/checkbox-group/types.d.ts +2 -1
- package/lib/circle/Circle.d.ts +37 -1
- package/lib/circle/Circle.js +21 -18
- package/lib/circle/index.d.ts +1 -1
- package/lib/col/Col.d.ts +13 -0
- package/lib/col/Col.js +10 -8
- package/lib/col/index.d.ts +1 -0
- package/lib/collapse/Collapse.d.ts +13 -1
- package/lib/collapse/Collapse.js +14 -12
- package/lib/collapse/index.d.ts +1 -0
- package/lib/collapse-item/CollapseItem.d.ts +5 -5
- package/lib/collapse-item/CollapseItem.js +12 -7
- package/lib/collapse-item/index.css +1 -1
- package/lib/collapse-item/index.d.ts +3 -4
- package/lib/collapse-item/index.less +1 -1
- package/lib/collapse-item/var.less +3 -3
- package/lib/composables/use-id.d.ts +1 -0
- package/lib/composables/use-id.js +21 -0
- package/lib/composables/use-route.d.ts +1 -1
- package/lib/composables/use-route.js +4 -4
- package/lib/config-provider/ConfigProvider.d.ts +11 -2
- package/lib/config-provider/ConfigProvider.js +11 -9
- package/lib/config-provider/index.d.ts +2 -1
- package/lib/contact-card/ContactCard.d.ts +15 -0
- package/lib/contact-card/ContactCard.js +13 -10
- package/lib/contact-card/index.css +1 -1
- package/lib/contact-card/index.d.ts +1 -1
- package/lib/contact-card/index.less +2 -2
- package/lib/contact-edit/ContactEdit.d.ts +17 -1
- package/lib/contact-edit/ContactEdit.js +21 -23
- package/lib/contact-edit/index.d.ts +1 -1
- package/lib/contact-edit/style/index.js +0 -10
- package/lib/contact-edit/style/less.js +0 -10
- package/lib/contact-list/ContactList.d.ts +8 -1
- package/lib/contact-list/ContactList.js +12 -9
- package/lib/contact-list/index.css +1 -1
- package/lib/contact-list/index.d.ts +1 -1
- package/lib/contact-list/index.less +1 -1
- package/lib/count-down/CountDown.d.ts +2 -2
- package/lib/count-down/CountDown.js +8 -6
- package/lib/count-down/index.d.ts +1 -2
- package/lib/coupon/Coupon.js +6 -13
- package/lib/coupon/index.css +1 -1
- package/lib/coupon/index.less +3 -2
- package/lib/coupon/utils.d.ts +3 -0
- package/lib/coupon/utils.js +20 -0
- package/lib/coupon/var.less +3 -2
- package/lib/coupon-cell/CouponCell.d.ts +25 -0
- package/lib/coupon-cell/CouponCell.js +16 -11
- package/lib/coupon-cell/index.d.ts +1 -0
- package/lib/coupon-list/CouponList.d.ts +55 -0
- package/lib/coupon-list/CouponList.js +65 -46
- package/lib/coupon-list/index.css +1 -1
- package/lib/coupon-list/index.d.ts +1 -0
- package/lib/coupon-list/index.less +4 -9
- package/lib/coupon-list/var.less +1 -1
- package/lib/datetime-picker/DatePicker.js +12 -9
- package/lib/datetime-picker/DatetimePicker.d.ts +2 -2
- package/lib/datetime-picker/DatetimePicker.js +10 -9
- package/lib/datetime-picker/TimePicker.js +12 -9
- package/lib/datetime-picker/utils.d.ts +1 -1
- package/lib/datetime-picker/utils.js +4 -4
- package/lib/dialog/Dialog.d.ts +55 -1
- package/lib/dialog/Dialog.js +31 -34
- package/lib/dialog/function-call.d.ts +2 -2
- package/lib/dialog/function-call.js +2 -2
- package/lib/dialog/index.css +1 -1
- package/lib/dialog/index.d.ts +1 -0
- package/lib/dialog/index.less +1 -1
- package/lib/dialog/var.less +1 -1
- package/lib/divider/Divider.d.ts +13 -0
- package/lib/divider/Divider.js +11 -9
- package/lib/divider/index.css +1 -1
- package/lib/divider/index.d.ts +1 -1
- package/lib/divider/var.less +1 -1
- package/lib/dropdown-item/DropdownItem.d.ts +2 -2
- package/lib/dropdown-item/DropdownItem.js +24 -10
- package/lib/dropdown-item/types.d.ts +2 -6
- package/lib/dropdown-menu/DropdownMenu.d.ts +2 -2
- package/lib/dropdown-menu/DropdownMenu.js +17 -9
- package/lib/dropdown-menu/index.css +1 -1
- package/lib/dropdown-menu/index.less +1 -9
- package/lib/dropdown-menu/types.d.ts +1 -0
- package/lib/dropdown-menu/var.less +2 -2
- package/lib/empty/Empty.d.ts +10 -0
- package/lib/empty/Empty.js +12 -9
- package/lib/empty/Network.js +26 -57
- package/lib/empty/index.css +1 -1
- package/lib/empty/index.d.ts +1 -0
- package/lib/empty/var.less +1 -1
- package/lib/field/Field.d.ts +6 -6
- package/lib/field/Field.js +60 -38
- package/lib/field/index.css +1 -1
- package/lib/field/index.d.ts +4 -4
- package/lib/field/types.d.ts +7 -6
- package/lib/field/utils.d.ts +2 -2
- package/lib/field/utils.js +8 -5
- package/lib/field/var.less +3 -3
- package/lib/form/Form.d.ts +2 -2
- package/lib/form/Form.js +8 -7
- package/lib/grid/Grid.d.ts +3 -2
- package/lib/grid/Grid.js +6 -5
- package/lib/grid/index.d.ts +1 -1
- package/lib/grid-item/GridItem.d.ts +14 -0
- package/lib/grid-item/GridItem.js +15 -13
- package/lib/grid-item/index.css +1 -1
- package/lib/grid-item/index.d.ts +1 -0
- package/lib/grid-item/index.less +1 -1
- package/lib/grid-item/var.less +1 -1
- package/lib/icon/Icon.d.ts +14 -0
- package/lib/icon/Icon.js +15 -12
- package/lib/icon/index.d.ts +1 -0
- package/lib/image/Image.d.ts +31 -2
- package/lib/image/Image.js +43 -55
- package/lib/image/index.css +1 -1
- package/lib/image/index.d.ts +2 -2
- package/lib/image/index.less +1 -1
- package/lib/image/var.less +1 -1
- package/lib/image-preview/ImagePreview.d.ts +2 -2
- package/lib/image-preview/ImagePreview.js +14 -15
- package/lib/image-preview/ImagePreviewItem.js +4 -3
- package/lib/image-preview/function-call.js +7 -3
- package/lib/image-preview/index.css +1 -1
- package/lib/image-preview/index.less +1 -6
- package/lib/image-preview/var.less +0 -1
- package/lib/index-anchor/IndexAnchor.d.ts +5 -0
- package/lib/index-anchor/IndexAnchor.js +8 -6
- package/lib/index-anchor/index.css +1 -1
- package/lib/index-anchor/index.d.ts +1 -0
- package/lib/index-anchor/index.less +2 -2
- package/lib/index-anchor/var.less +1 -1
- package/lib/index-bar/IndexBar.d.ts +2 -2
- package/lib/index-bar/IndexBar.js +8 -18
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/index.less +1 -1
- package/lib/lazyload/index.d.ts +1 -1
- package/lib/lazyload/index.js +3 -3
- package/lib/lazyload/vue-lazyload/index.d.ts +55 -0
- package/lib/lazyload/vue-lazyload/index.js +58 -0
- package/lib/lazyload/vue-lazyload/lazy-component.js +62 -0
- package/lib/lazyload/vue-lazyload/lazy-container.js +106 -0
- package/lib/lazyload/vue-lazyload/lazy-image.js +125 -0
- package/lib/lazyload/vue-lazyload/lazy.js +520 -0
- package/lib/lazyload/vue-lazyload/listener.js +251 -0
- package/lib/lazyload/vue-lazyload/util.js +213 -0
- package/lib/list/List.d.ts +2 -2
- package/lib/list/List.js +10 -7
- package/lib/list/index.css +1 -1
- package/lib/list/var.less +1 -1
- package/lib/loading/Loading.d.ts +13 -0
- package/lib/loading/Loading.js +13 -11
- package/lib/loading/index.css +1 -1
- package/lib/loading/index.d.ts +1 -1
- package/lib/loading/var.less +1 -1
- package/lib/locale/index.js +5 -1
- package/lib/locale/lang/de-DE-formal.d.ts +0 -1
- package/lib/locale/lang/de-DE-formal.js +0 -1
- package/lib/locale/lang/de-DE.d.ts +0 -1
- package/lib/locale/lang/de-DE.js +0 -1
- package/lib/locale/lang/en-US.d.ts +0 -1
- package/lib/locale/lang/en-US.js +0 -1
- package/lib/locale/lang/es-ES.d.ts +0 -1
- package/lib/locale/lang/es-ES.js +0 -1
- package/lib/locale/lang/fr-FR.d.ts +0 -1
- package/lib/locale/lang/fr-FR.js +0 -1
- package/lib/locale/lang/ja-JP.d.ts +0 -1
- package/lib/locale/lang/ja-JP.js +0 -1
- package/lib/locale/lang/nb-NO.d.ts +0 -1
- package/lib/locale/lang/nb-NO.js +0 -1
- package/lib/locale/lang/ro-RO.d.ts +0 -1
- package/lib/locale/lang/ro-RO.js +0 -1
- package/lib/locale/lang/ru-RU.d.ts +0 -1
- package/lib/locale/lang/ru-RU.js +0 -1
- package/lib/locale/lang/th-TH.d.ts +0 -1
- package/lib/locale/lang/th-TH.js +0 -1
- package/lib/locale/lang/tr-TR.d.ts +0 -1
- package/lib/locale/lang/tr-TR.js +0 -1
- package/lib/locale/lang/zh-CN.d.ts +0 -1
- package/lib/locale/lang/zh-CN.js +0 -1
- package/lib/locale/lang/zh-HK.d.ts +0 -1
- package/lib/locale/lang/zh-HK.js +0 -1
- package/lib/locale/lang/zh-TW.d.ts +0 -1
- package/lib/locale/lang/zh-TW.js +0 -1
- package/lib/nav-bar/NavBar.d.ts +16 -0
- package/lib/nav-bar/NavBar.js +19 -17
- package/lib/nav-bar/index.css +1 -1
- package/lib/nav-bar/index.d.ts +1 -0
- package/lib/nav-bar/index.less +1 -5
- package/lib/nav-bar/var.less +1 -1
- package/lib/notice-bar/NoticeBar.d.ts +3 -3
- package/lib/notice-bar/NoticeBar.js +7 -6
- package/lib/notice-bar/index.css +1 -1
- package/lib/notice-bar/index.d.ts +1 -1
- package/lib/notice-bar/index.less +1 -1
- package/lib/notify/Notify.d.ts +42 -2
- package/lib/notify/Notify.js +21 -13
- package/lib/notify/function-call.d.ts +4 -2
- package/lib/notify/function-call.js +1 -1
- package/lib/notify/index.css +1 -1
- package/lib/notify/index.d.ts +1 -0
- package/lib/notify/index.less +4 -4
- package/lib/number-keyboard/NumberKeyboard.d.ts +48 -1
- package/lib/number-keyboard/NumberKeyboard.js +29 -27
- package/lib/number-keyboard/NumberKeyboardKey.js +8 -7
- package/lib/number-keyboard/index.css +1 -1
- package/lib/number-keyboard/index.d.ts +1 -1
- package/lib/number-keyboard/index.less +3 -7
- package/lib/number-keyboard/var.less +1 -1
- package/lib/overlay/Overlay.d.ts +13 -1
- package/lib/overlay/Overlay.js +15 -13
- package/lib/overlay/index.css +1 -1
- package/lib/overlay/index.d.ts +1 -0
- package/lib/overlay/index.less +1 -1
- package/lib/pagination/Pagination.d.ts +31 -0
- package/lib/pagination/Pagination.js +83 -62
- package/lib/pagination/index.css +1 -1
- package/lib/pagination/index.d.ts +1 -1
- package/lib/pagination/index.less +33 -32
- package/lib/pagination/var.less +1 -1
- package/lib/password-input/PasswordInput.d.ts +21 -1
- package/lib/password-input/PasswordInput.js +15 -12
- package/lib/password-input/index.css +1 -1
- package/lib/password-input/index.d.ts +2 -1
- package/lib/password-input/index.less +3 -3
- package/lib/password-input/var.less +3 -3
- package/lib/picker/Picker.d.ts +40 -1
- package/lib/picker/Picker.js +21 -18
- package/lib/picker/PickerColumn.js +5 -4
- package/lib/picker/index.css +1 -1
- package/lib/picker/index.less +4 -12
- package/lib/picker/var.less +9 -3
- package/lib/popover/Popover.d.ts +50 -11
- package/lib/popover/Popover.js +36 -33
- package/lib/popover/index.css +1 -1
- package/lib/popover/index.d.ts +17 -16
- package/lib/popover/index.less +2 -2
- package/lib/popover/types.d.ts +11 -0
- package/lib/popover/types.js +3 -0
- package/lib/popover/var.less +3 -3
- package/lib/popup/Popup.d.ts +48 -3
- package/lib/popup/Popup.js +24 -27
- package/lib/popup/index.css +1 -1
- package/lib/popup/index.d.ts +2 -3
- package/lib/popup/index.less +1 -6
- package/lib/popup/var.less +1 -2
- package/lib/progress/Progress.d.ts +2 -2
- package/lib/progress/Progress.js +11 -7
- package/lib/progress/index.css +1 -1
- package/lib/progress/index.less +10 -1
- package/lib/progress/var.less +1 -0
- package/lib/pull-refresh/PullRefresh.d.ts +23 -0
- package/lib/pull-refresh/PullRefresh.js +19 -17
- package/lib/pull-refresh/index.css +1 -1
- package/lib/pull-refresh/index.d.ts +1 -0
- package/lib/pull-refresh/var.less +1 -1
- package/lib/radio/Radio.d.ts +11 -6
- package/lib/radio/Radio.js +5 -4
- package/lib/radio/index.css +1 -1
- package/lib/radio/index.d.ts +1 -0
- package/lib/radio/var.less +1 -1
- package/lib/radio-group/RadioGroup.d.ts +4 -2
- package/lib/radio-group/RadioGroup.js +7 -6
- package/lib/radio-group/index.d.ts +1 -0
- package/lib/rate/Rate.d.ts +33 -0
- package/lib/rate/Rate.js +27 -22
- package/lib/rate/index.d.ts +1 -0
- package/lib/row/Row.d.ts +18 -1
- package/lib/row/Row.js +12 -10
- package/lib/row/index.d.ts +1 -1
- package/lib/search/Search.d.ts +2 -2
- package/lib/search/Search.js +20 -13
- package/lib/search/index.css +1 -1
- package/lib/search/index.less +2 -2
- package/lib/search/var.less +1 -1
- package/lib/share-sheet/ShareSheet.d.ts +55 -0
- package/lib/share-sheet/ShareSheet.js +21 -19
- package/lib/share-sheet/index.css +1 -1
- package/lib/share-sheet/index.d.ts +8 -1
- package/lib/share-sheet/index.less +0 -4
- package/lib/share-sheet/var.less +3 -3
- package/lib/sidebar/Sidebar.d.ts +8 -1
- package/lib/sidebar/Sidebar.js +10 -7
- package/lib/sidebar/index.d.ts +1 -0
- package/lib/sidebar-item/SidebarItem.d.ts +12 -0
- package/lib/sidebar-item/SidebarItem.js +16 -11
- package/lib/sidebar-item/index.css +1 -1
- package/lib/sidebar-item/index.d.ts +1 -0
- package/lib/sidebar-item/index.less +1 -1
- package/lib/sidebar-item/var.less +2 -2
- package/lib/skeleton/Skeleton.d.ts +29 -1
- package/lib/skeleton/Skeleton.js +22 -19
- package/lib/skeleton/index.css +1 -1
- package/lib/skeleton/index.d.ts +5 -6
- package/lib/skeleton/index.less +2 -2
- package/lib/slider/Slider.d.ts +31 -3
- package/lib/slider/Slider.js +29 -25
- package/lib/slider/index.css +1 -1
- package/lib/slider/index.d.ts +3 -2
- package/lib/slider/index.less +3 -3
- package/lib/step/Step.js +4 -3
- package/lib/step/index.css +1 -1
- package/lib/step/index.less +1 -1
- package/lib/step/var.less +1 -1
- package/lib/stepper/Stepper.d.ts +54 -2
- package/lib/stepper/Stepper.js +49 -39
- package/lib/stepper/index.css +1 -1
- package/lib/stepper/index.d.ts +3 -4
- package/lib/stepper/index.less +6 -21
- package/lib/stepper/var.less +1 -2
- package/lib/steps/Steps.d.ts +3 -2
- package/lib/steps/Steps.js +7 -6
- package/lib/steps/index.css +1 -1
- package/lib/steps/index.d.ts +1 -0
- package/lib/steps/var.less +1 -1
- package/lib/sticky/Sticky.d.ts +18 -1
- package/lib/sticky/Sticky.js +13 -11
- package/lib/sticky/index.d.ts +1 -1
- package/lib/style/base.css +1 -1
- package/lib/style/base.less +4 -0
- package/lib/style/css-variables.css +1 -1
- package/lib/style/css-variables.less +3 -1
- package/lib/style/mixins/hairline.less +3 -3
- package/lib/style/var.less +5 -3
- package/lib/submit-bar/SubmitBar.d.ts +33 -3
- package/lib/submit-bar/SubmitBar.js +23 -20
- package/lib/submit-bar/index.css +1 -1
- package/lib/submit-bar/index.d.ts +3 -2
- package/lib/submit-bar/index.less +2 -2
- package/lib/submit-bar/var.less +3 -3
- package/lib/swipe/Swipe.d.ts +2 -2
- package/lib/swipe/Swipe.js +30 -16
- package/lib/swipe/types.d.ts +1 -3
- package/lib/swipe-cell/SwipeCell.d.ts +2 -2
- package/lib/swipe-cell/SwipeCell.js +13 -9
- package/lib/swipe-item/SwipeItem.js +4 -3
- package/lib/switch/Switch.d.ts +18 -0
- package/lib/switch/Switch.js +23 -19
- package/lib/switch/index.css +1 -1
- package/lib/switch/index.d.ts +1 -0
- package/lib/switch/index.less +5 -3
- package/lib/switch/var.less +1 -1
- package/lib/tab/Tab.d.ts +19 -1
- package/lib/tab/Tab.js +35 -18
- package/lib/tab/index.css +1 -1
- package/lib/tab/index.d.ts +1 -0
- package/lib/tab/index.less +1 -1
- package/lib/tabbar/Tabbar.d.ts +4 -3
- package/lib/tabbar/Tabbar.js +17 -17
- package/lib/tabbar/index.css +1 -1
- package/lib/tabbar/index.d.ts +1 -0
- package/lib/tabbar/index.less +1 -1
- package/lib/tabbar/var.less +1 -1
- package/lib/tabbar-item/TabbarItem.d.ts +13 -0
- package/lib/tabbar-item/TabbarItem.js +25 -16
- package/lib/tabbar-item/index.css +1 -1
- package/lib/tabbar-item/index.d.ts +1 -0
- package/lib/tabbar-item/var.less +1 -1
- package/lib/tabs/Tabs.d.ts +2 -2
- package/lib/tabs/Tabs.js +31 -21
- package/lib/tabs/TabsContent.js +5 -4
- package/lib/tabs/TabsTitle.d.ts +6 -0
- package/lib/tabs/TabsTitle.js +7 -1
- package/lib/tabs/index.css +1 -1
- package/lib/tabs/index.less +2 -2
- package/lib/tabs/types.d.ts +1 -0
- package/lib/tabs/var.less +2 -2
- package/lib/tag/Tag.d.ts +23 -3
- package/lib/tag/Tag.js +18 -15
- package/lib/tag/index.css +1 -1
- package/lib/tag/index.d.ts +3 -2
- package/lib/tag/index.less +6 -6
- package/lib/tag/var.less +1 -1
- package/lib/toast/Toast.d.ts +33 -1
- package/lib/toast/Toast.js +28 -32
- package/lib/toast/function-call.js +10 -2
- package/lib/toast/index.css +1 -1
- package/lib/toast/index.d.ts +1 -0
- package/lib/toast/index.less +1 -1
- package/lib/tree-select/TreeSelect.d.ts +28 -1
- package/lib/tree-select/TreeSelect.js +18 -15
- package/lib/tree-select/index.css +1 -1
- package/lib/tree-select/index.d.ts +1 -1
- package/lib/tree-select/index.less +2 -2
- package/lib/tree-select/var.less +1 -1
- package/lib/uploader/Uploader.d.ts +2 -2
- package/lib/uploader/Uploader.js +17 -10
- package/lib/uploader/UploaderPreviewItem.js +11 -7
- package/lib/uploader/index.css +1 -1
- package/lib/uploader/index.less +4 -4
- package/lib/uploader/utils.d.ts +2 -2
- package/lib/uploader/utils.js +3 -2
- package/lib/uploader/var.less +1 -1
- package/lib/utils/constant.d.ts +1 -0
- package/lib/utils/constant.js +3 -1
- package/lib/utils/create.d.ts +2 -2
- package/lib/utils/create.js +6 -1
- package/lib/utils/deep-assign.d.ts +1 -1
- package/lib/utils/deep-assign.js +1 -1
- package/lib/utils/deep-clone.js +1 -1
- package/lib/utils/dom.d.ts +1 -1
- package/lib/utils/dom.js +9 -9
- package/lib/utils/format.js +21 -7
- package/lib/utils/interceptor.d.ts +3 -4
- package/lib/utils/interceptor.js +4 -5
- package/lib/vant.es.js +4056 -3778
- package/lib/vant.es.min.js +4056 -3778
- package/lib/vant.js +4055 -3777
- package/lib/vant.min.js +1 -1
- package/lib/vue-tsx-shim.d.ts +1 -0
- package/package.json +10 -7
- package/vetur/attributes.json +12 -8
- package/vetur/tags.json +1 -0
- package/vetur/web-types.json +36 -14
- package/changelog.generated.md +0 -148
- package/es/composables/use-link-field.d.ts +0 -0
- package/es/composables/use-link-field.js +0 -0
- package/lib/composables/use-link-field.d.ts +0 -0
- package/lib/composables/use-link-field.js +0 -1
@@ -1,4 +1,59 @@
|
|
1
|
+
import { ExtractPropTypes } from 'vue';
|
1
2
|
import { CouponInfo } from '../coupon';
|
3
|
+
declare const couponListProps: {
|
4
|
+
code: {
|
5
|
+
type: import("vue").PropType<string>;
|
6
|
+
default: string;
|
7
|
+
};
|
8
|
+
coupons: {
|
9
|
+
type: import("vue").PropType<CouponInfo[]>;
|
10
|
+
default: () => never[];
|
11
|
+
};
|
12
|
+
currency: {
|
13
|
+
type: import("vue").PropType<string>;
|
14
|
+
default: string;
|
15
|
+
};
|
16
|
+
showCount: {
|
17
|
+
type: BooleanConstructor;
|
18
|
+
default: true;
|
19
|
+
};
|
20
|
+
emptyImage: {
|
21
|
+
type: import("vue").PropType<string>;
|
22
|
+
default: string;
|
23
|
+
};
|
24
|
+
chosenCoupon: {
|
25
|
+
type: NumberConstructor;
|
26
|
+
default: number;
|
27
|
+
};
|
28
|
+
enabledTitle: StringConstructor;
|
29
|
+
disabledTitle: StringConstructor;
|
30
|
+
disabledCoupons: {
|
31
|
+
type: import("vue").PropType<CouponInfo[]>;
|
32
|
+
default: () => never[];
|
33
|
+
};
|
34
|
+
showExchangeBar: {
|
35
|
+
type: BooleanConstructor;
|
36
|
+
default: true;
|
37
|
+
};
|
38
|
+
showCloseButton: {
|
39
|
+
type: BooleanConstructor;
|
40
|
+
default: true;
|
41
|
+
};
|
42
|
+
closeButtonText: StringConstructor;
|
43
|
+
inputPlaceholder: StringConstructor;
|
44
|
+
exchangeMinLength: {
|
45
|
+
type: NumberConstructor;
|
46
|
+
default: number;
|
47
|
+
};
|
48
|
+
exchangeButtonText: StringConstructor;
|
49
|
+
displayedCouponIndex: {
|
50
|
+
type: NumberConstructor;
|
51
|
+
default: number;
|
52
|
+
};
|
53
|
+
exchangeButtonLoading: BooleanConstructor;
|
54
|
+
exchangeButtonDisabled: BooleanConstructor;
|
55
|
+
};
|
56
|
+
export declare type CouponListProps = ExtractPropTypes<typeof couponListProps>;
|
2
57
|
declare const _default: import("vue").DefineComponent<{
|
3
58
|
code: {
|
4
59
|
type: import("vue").PropType<string>;
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { withDirectives as _withDirectives, vShow as _vShow, createVNode as _createVNode } from "vue";
|
2
|
-
import { watch, computed, nextTick,
|
2
|
+
import { ref, watch, computed, nextTick, onMounted, defineComponent } from 'vue'; // Utils
|
3
3
|
|
4
|
-
import { truthProp, makeArrayProp, makeStringProp, makeNumberProp, createNamespace } from '../utils'; // Composables
|
4
|
+
import { truthProp, windowHeight, makeArrayProp, makeStringProp, makeNumberProp, createNamespace } from '../utils'; // Composables
|
5
5
|
|
6
6
|
import { useRefs } from '../composables/use-refs'; // Components
|
7
7
|
|
@@ -10,56 +10,67 @@ import { Tabs } from '../tabs';
|
|
10
10
|
import { Field } from '../field';
|
11
11
|
import { Button } from '../button';
|
12
12
|
import { Coupon } from '../coupon';
|
13
|
+
import { useRect } from '@vant/use';
|
13
14
|
var [name, bem, t] = createNamespace('coupon-list');
|
14
15
|
var EMPTY_IMAGE = 'https://img.yzcdn.cn/vant/coupon-empty.png';
|
16
|
+
var couponListProps = {
|
17
|
+
code: makeStringProp(''),
|
18
|
+
coupons: makeArrayProp(),
|
19
|
+
currency: makeStringProp('¥'),
|
20
|
+
showCount: truthProp,
|
21
|
+
emptyImage: makeStringProp(EMPTY_IMAGE),
|
22
|
+
chosenCoupon: makeNumberProp(-1),
|
23
|
+
enabledTitle: String,
|
24
|
+
disabledTitle: String,
|
25
|
+
disabledCoupons: makeArrayProp(),
|
26
|
+
showExchangeBar: truthProp,
|
27
|
+
showCloseButton: truthProp,
|
28
|
+
closeButtonText: String,
|
29
|
+
inputPlaceholder: String,
|
30
|
+
exchangeMinLength: makeNumberProp(1),
|
31
|
+
exchangeButtonText: String,
|
32
|
+
displayedCouponIndex: makeNumberProp(-1),
|
33
|
+
exchangeButtonLoading: Boolean,
|
34
|
+
exchangeButtonDisabled: Boolean
|
35
|
+
};
|
15
36
|
export default defineComponent({
|
16
37
|
name,
|
17
|
-
props:
|
18
|
-
code: makeStringProp(''),
|
19
|
-
coupons: makeArrayProp(),
|
20
|
-
currency: makeStringProp('¥'),
|
21
|
-
showCount: truthProp,
|
22
|
-
emptyImage: makeStringProp(EMPTY_IMAGE),
|
23
|
-
chosenCoupon: makeNumberProp(-1),
|
24
|
-
enabledTitle: String,
|
25
|
-
disabledTitle: String,
|
26
|
-
disabledCoupons: makeArrayProp(),
|
27
|
-
showExchangeBar: truthProp,
|
28
|
-
showCloseButton: truthProp,
|
29
|
-
closeButtonText: String,
|
30
|
-
inputPlaceholder: String,
|
31
|
-
exchangeMinLength: makeNumberProp(1),
|
32
|
-
exchangeButtonText: String,
|
33
|
-
displayedCouponIndex: makeNumberProp(-1),
|
34
|
-
exchangeButtonLoading: Boolean,
|
35
|
-
exchangeButtonDisabled: Boolean
|
36
|
-
},
|
38
|
+
props: couponListProps,
|
37
39
|
emits: ['change', 'exchange', 'update:code'],
|
38
40
|
|
39
|
-
setup(props, {
|
40
|
-
|
41
|
-
|
42
|
-
|
41
|
+
setup(props, _ref) {
|
42
|
+
var {
|
43
|
+
emit,
|
44
|
+
slots
|
45
|
+
} = _ref;
|
43
46
|
var [couponRefs, setCouponRefs] = useRefs();
|
44
|
-
var
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
var
|
47
|
+
var root = ref();
|
48
|
+
var barRef = ref();
|
49
|
+
var activeTab = ref(0);
|
50
|
+
var listHeight = ref(0);
|
51
|
+
var currentCode = ref(props.code);
|
52
|
+
var buttonDisabled = computed(() => !props.exchangeButtonLoading && (props.exchangeButtonDisabled || !currentCode.value || currentCode.value.length < props.exchangeMinLength));
|
53
|
+
|
54
|
+
var updateListHeight = () => {
|
55
|
+
var TABS_HEIGHT = 44;
|
56
|
+
var rootHeight = useRect(root).height;
|
57
|
+
var headerHeight = useRect(barRef).height + TABS_HEIGHT;
|
58
|
+
listHeight.value = (rootHeight > headerHeight ? rootHeight : windowHeight.value) - headerHeight;
|
59
|
+
};
|
49
60
|
|
50
61
|
var onExchange = () => {
|
51
|
-
emit('exchange',
|
62
|
+
emit('exchange', currentCode.value); // auto clear currentCode when not use v-model
|
52
63
|
|
53
64
|
if (!props.code) {
|
54
|
-
|
65
|
+
currentCode.value = '';
|
55
66
|
}
|
56
67
|
};
|
57
68
|
|
58
69
|
var scrollToCoupon = index => {
|
59
70
|
nextTick(() => {
|
60
|
-
|
61
|
-
|
62
|
-
|
71
|
+
var _couponRefs$value$ind;
|
72
|
+
|
73
|
+
return (_couponRefs$value$ind = couponRefs.value[index]) == null ? void 0 : _couponRefs$value$ind.scrollIntoView();
|
63
74
|
});
|
64
75
|
};
|
65
76
|
|
@@ -72,10 +83,11 @@ export default defineComponent({
|
|
72
83
|
var renderExchangeBar = () => {
|
73
84
|
if (props.showExchangeBar) {
|
74
85
|
return _createVNode("div", {
|
86
|
+
"ref": barRef,
|
75
87
|
"class": bem('exchange-bar')
|
76
88
|
}, [_createVNode(Field, {
|
77
|
-
"modelValue":
|
78
|
-
"onUpdate:modelValue": $event =>
|
89
|
+
"modelValue": currentCode.value,
|
90
|
+
"onUpdate:modelValue": $event => currentCode.value = $event,
|
79
91
|
"clearable": true,
|
80
92
|
"border": false,
|
81
93
|
"class": bem('field'),
|
@@ -106,9 +118,11 @@ export default defineComponent({
|
|
106
118
|
}, {
|
107
119
|
default: () => [_createVNode("div", {
|
108
120
|
"class": bem('list', {
|
109
|
-
'with-bar': props.showExchangeBar,
|
110
121
|
'with-bottom': props.showCloseButton
|
111
|
-
})
|
122
|
+
}),
|
123
|
+
"style": {
|
124
|
+
height: listHeight.value + "px"
|
125
|
+
}
|
112
126
|
}, [coupons.map((coupon, index) => _createVNode(Coupon, {
|
113
127
|
"key": coupon.id,
|
114
128
|
"ref": setCouponRefs(index),
|
@@ -133,9 +147,11 @@ export default defineComponent({
|
|
133
147
|
}, {
|
134
148
|
default: () => [_createVNode("div", {
|
135
149
|
"class": bem('list', {
|
136
|
-
'with-bar': props.showExchangeBar,
|
137
150
|
'with-bottom': props.showCloseButton
|
138
|
-
})
|
151
|
+
}),
|
152
|
+
"style": {
|
153
|
+
height: listHeight.value + "px"
|
154
|
+
}
|
139
155
|
}, [disabledCoupons.map(coupon => _createVNode(Coupon, {
|
140
156
|
"disabled": true,
|
141
157
|
"key": coupon.id,
|
@@ -146,20 +162,22 @@ export default defineComponent({
|
|
146
162
|
};
|
147
163
|
|
148
164
|
watch(() => props.code, value => {
|
149
|
-
|
165
|
+
currentCode.value = value;
|
150
166
|
});
|
151
|
-
watch(
|
167
|
+
watch(windowHeight, updateListHeight);
|
168
|
+
watch(currentCode, value => emit('update:code', value));
|
152
169
|
watch(() => props.displayedCouponIndex, scrollToCoupon);
|
153
170
|
onMounted(() => {
|
171
|
+
updateListHeight();
|
154
172
|
scrollToCoupon(props.displayedCouponIndex);
|
155
173
|
});
|
156
174
|
return () => _createVNode("div", {
|
175
|
+
"ref": root,
|
157
176
|
"class": bem()
|
158
177
|
}, [renderExchangeBar(), _createVNode(Tabs, {
|
159
|
-
|
160
|
-
"onUpdate:active": $event =>
|
161
|
-
"class": bem('tab')
|
162
|
-
"border": false
|
178
|
+
"active": activeTab.value,
|
179
|
+
"onUpdate:active": $event => activeTab.value = $event,
|
180
|
+
"class": bem('tab')
|
163
181
|
}, {
|
164
182
|
default: () => [renderCouponTab(), renderDisabledTab()]
|
165
183
|
}), _createVNode("div", {
|
package/es/coupon-list/index.css
CHANGED
@@ -1 +1 @@
|
|
1
|
-
:root{--van-coupon-list-background-color:var(--van-background-color);--van-coupon-list-field-padding:5px 0 5px var(--van-padding-md);--van-coupon-list-exchange-button-height:32px;--van-coupon-list-close-button-height:40px;--van-coupon-list-empty-image-size:200px;--van-coupon-list-empty-tip-color:var(--van-
|
1
|
+
:root{--van-coupon-list-background-color:var(--van-background-color);--van-coupon-list-field-padding:5px 0 5px var(--van-padding-md);--van-coupon-list-exchange-button-height:32px;--van-coupon-list-close-button-height:40px;--van-coupon-list-empty-image-size:200px;--van-coupon-list-empty-tip-color:var(--van-text-color-2);--van-coupon-list-empty-tip-font-size:var(--van-font-size-md);--van-coupon-list-empty-tip-line-height:var(--van-line-height-md)}.van-coupon-list{position:relative;height:100%;background:var(--van-coupon-list-background-color)}.van-coupon-list__field{padding:var(--van-coupon-list-field-padding)}.van-coupon-list__field .van-field__body{height:34px;padding-left:var(--van-padding-sm);line-height:34px;background:var(--van-gray-1);border-radius:17px}.van-coupon-list__field .van-field__body::-webkit-input-placeholder{color:var(--van-text-color-3)}.van-coupon-list__field .van-field__body::placeholder{color:var(--van-text-color-3)}.van-coupon-list__field .van-field__clear{margin-right:0}.van-coupon-list__exchange-bar{display:flex;align-items:center;background-color:var(--van-background-color-light)}.van-coupon-list__exchange{flex:none;height:var(--van-coupon-list-exchange-button-height);font-size:var(--van-font-size-lg);line-height:calc(var(--van-coupon-list-exchange-button-height) - 2px);border:0}.van-coupon-list .van-tabs__wrap{box-shadow:0 6px 12px -12px var(--van-gray-6)}.van-coupon-list__list{box-sizing:border-box;padding:var(--van-padding-md) 0 var(--van-padding-lg);overflow-y:auto;-webkit-overflow-scrolling:touch}.van-coupon-list__list--with-bottom{padding-bottom:50px}.van-coupon-list__bottom{position:absolute;bottom:0;left:0;z-index:999;box-sizing:border-box;width:100%;padding:5px var(--van-padding-md);font-weight:var(--van-font-weight-bold);background-color:var(--van-background-color-light)}.van-coupon-list__close{height:var(--van-coupon-list-close-button-height)}.van-coupon-list__empty{padding-top:60px;text-align:center}.van-coupon-list__empty p{margin:var(--van-padding-md) 0;color:var(--van-coupon-list-empty-tip-color);font-size:var(--van-coupon-list-empty-tip-font-size);line-height:var(--van-coupon-list-empty-tip-line-height)}.van-coupon-list__empty img{width:var(--van-coupon-list-empty-image-size);height:var(--van-coupon-list-empty-image-size)}
|
@@ -14,7 +14,7 @@
|
|
14
14
|
.van-coupon-list {
|
15
15
|
position: relative;
|
16
16
|
height: 100%;
|
17
|
-
background
|
17
|
+
background: var(--van-coupon-list-background-color);
|
18
18
|
|
19
19
|
&__field {
|
20
20
|
padding: var(--van-coupon-list-field-padding);
|
@@ -27,7 +27,7 @@
|
|
27
27
|
border-radius: 17px;
|
28
28
|
|
29
29
|
&::placeholder {
|
30
|
-
color: var(--van-
|
30
|
+
color: var(--van-text-color-3);
|
31
31
|
}
|
32
32
|
}
|
33
33
|
|
@@ -39,7 +39,7 @@
|
|
39
39
|
&__exchange-bar {
|
40
40
|
display: flex;
|
41
41
|
align-items: center;
|
42
|
-
background-color: var(--van-
|
42
|
+
background-color: var(--van-background-color-light);
|
43
43
|
}
|
44
44
|
|
45
45
|
&__exchange {
|
@@ -56,15 +56,10 @@
|
|
56
56
|
|
57
57
|
&__list {
|
58
58
|
box-sizing: border-box;
|
59
|
-
height: calc(100vh - 108px);
|
60
59
|
padding: var(--van-padding-md) 0 var(--van-padding-lg);
|
61
60
|
overflow-y: auto;
|
62
61
|
-webkit-overflow-scrolling: touch;
|
63
62
|
|
64
|
-
&--with-bar {
|
65
|
-
height: calc(100vh - 152px);
|
66
|
-
}
|
67
|
-
|
68
63
|
&--with-bottom {
|
69
64
|
padding-bottom: 50px;
|
70
65
|
}
|
@@ -79,7 +74,7 @@
|
|
79
74
|
width: 100%;
|
80
75
|
padding: 5px var(--van-padding-md);
|
81
76
|
font-weight: var(--van-font-weight-bold);
|
82
|
-
background-color: var(--van-
|
77
|
+
background-color: var(--van-background-color-light);
|
83
78
|
}
|
84
79
|
|
85
80
|
&__close {
|
package/es/coupon-list/var.less
CHANGED
@@ -5,6 +5,6 @@
|
|
5
5
|
@coupon-list-exchange-button-height: 32px;
|
6
6
|
@coupon-list-close-button-height: 40px;
|
7
7
|
@coupon-list-empty-image-size: 200px;
|
8
|
-
@coupon-list-empty-tip-color: var(--van-
|
8
|
+
@coupon-list-empty-tip-color: var(--van-text-color-2);
|
9
9
|
@coupon-list-empty-tip-font-size: var(--van-font-size-md);
|
10
10
|
@coupon-list-empty-tip-line-height: var(--van-line-height-md);
|
@@ -2,7 +2,7 @@ import { createVNode as _createVNode, mergeProps as _mergeProps, resolveDirectiv
|
|
2
2
|
import { ref, watch, computed, nextTick, onMounted, defineComponent } from 'vue'; // Utils
|
3
3
|
|
4
4
|
import { pick, clamp, extend, isDate, padZero, makeStringProp, createNamespace } from '../utils';
|
5
|
-
import { times,
|
5
|
+
import { times, sharedProps, getTrueValue, getMonthEndDay, pickerInheritKeys } from './utils'; // Composables
|
6
6
|
|
7
7
|
import { useExpose } from '../composables/use-expose'; // Components
|
8
8
|
|
@@ -28,10 +28,12 @@ export default defineComponent({
|
|
28
28
|
}),
|
29
29
|
emits: ['confirm', 'cancel', 'change', 'update:modelValue'],
|
30
30
|
|
31
|
-
setup(props, {
|
32
|
-
|
33
|
-
|
34
|
-
|
31
|
+
setup(props, _ref) {
|
32
|
+
var {
|
33
|
+
emit,
|
34
|
+
slots
|
35
|
+
} = _ref;
|
36
|
+
|
35
37
|
var formatValue = value => {
|
36
38
|
if (isDate(value)) {
|
37
39
|
var timestamp = clamp(value.getTime(), props.minDate.getTime(), props.maxDate.getTime());
|
@@ -141,10 +143,11 @@ export default defineComponent({
|
|
141
143
|
|
142
144
|
return result;
|
143
145
|
});
|
144
|
-
var originColumns = computed(() => ranges.value.map(
|
145
|
-
|
146
|
-
|
147
|
-
|
146
|
+
var originColumns = computed(() => ranges.value.map(_ref2 => {
|
147
|
+
var {
|
148
|
+
type,
|
149
|
+
range: rangeArr
|
150
|
+
} = _ref2;
|
148
151
|
var values = times(rangeArr[1] - rangeArr[0] + 1, index => padZero(rangeArr[0] + index));
|
149
152
|
|
150
153
|
if (props.filter) {
|
@@ -286,7 +289,7 @@ export default defineComponent({
|
|
286
289
|
"onChange": onChange,
|
287
290
|
"onCancel": onCancel,
|
288
291
|
"onConfirm": onConfirm
|
289
|
-
}, pick(props,
|
292
|
+
}, pick(props, pickerInheritKeys)), slots);
|
290
293
|
}
|
291
294
|
|
292
295
|
});
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { ExtractPropTypes } from 'vue';
|
2
|
-
declare const
|
3
|
-
export declare type DatetimePickerProps = ExtractPropTypes<typeof
|
2
|
+
declare const datetimePickerProps: any;
|
3
|
+
export declare type DatetimePickerProps = ExtractPropTypes<typeof datetimePickerProps>;
|
4
4
|
declare const _default: import("vue").DefineComponent<any, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("@vue/runtime-core").ComponentCustomProps, Readonly<any>, {} | {
|
5
5
|
[x: string]: any;
|
6
6
|
}>;
|
@@ -5,19 +5,20 @@ import { useExpose } from '../composables/use-expose';
|
|
5
5
|
import TimePicker from './TimePicker';
|
6
6
|
import DatePicker from './DatePicker';
|
7
7
|
var [name, bem] = createNamespace('datetime-picker');
|
8
|
-
var
|
9
|
-
var
|
10
|
-
var
|
8
|
+
var timePickerPropKeys = Object.keys(TimePicker.props);
|
9
|
+
var datePickerPropKeys = Object.keys(DatePicker.props);
|
10
|
+
var datetimePickerProps = extend({}, TimePicker.props, DatePicker.props, {
|
11
11
|
modelValue: [String, Date]
|
12
12
|
});
|
13
13
|
export default defineComponent({
|
14
14
|
name,
|
15
|
-
props,
|
15
|
+
props: datetimePickerProps,
|
16
16
|
|
17
|
-
setup(props, {
|
18
|
-
|
19
|
-
|
20
|
-
|
17
|
+
setup(props, _ref) {
|
18
|
+
var {
|
19
|
+
attrs,
|
20
|
+
slots
|
21
|
+
} = _ref;
|
21
22
|
var root = ref();
|
22
23
|
useExpose({
|
23
24
|
getPicker: () => {
|
@@ -29,7 +30,7 @@ export default defineComponent({
|
|
29
30
|
return () => {
|
30
31
|
var isTimePicker = props.type === 'time';
|
31
32
|
var Component = isTimePicker ? TimePicker : DatePicker;
|
32
|
-
var inheritProps = pick(props, isTimePicker ?
|
33
|
+
var inheritProps = pick(props, isTimePicker ? timePickerPropKeys : datePickerPropKeys);
|
33
34
|
return _createVNode(Component, _mergeProps({
|
34
35
|
"ref": root,
|
35
36
|
"class": bem()
|
@@ -2,7 +2,7 @@ import { createVNode as _createVNode, mergeProps as _mergeProps, resolveDirectiv
|
|
2
2
|
import { ref, watch, computed, nextTick, onMounted, defineComponent } from 'vue'; // Utils
|
3
3
|
|
4
4
|
import { pick, clamp, extend, padZero, createNamespace, makeNumericProp } from '../utils';
|
5
|
-
import { times, sharedProps,
|
5
|
+
import { times, sharedProps, pickerInheritKeys } from './utils'; // Composables
|
6
6
|
|
7
7
|
import { useExpose } from '../composables/use-expose'; // Components
|
8
8
|
|
@@ -19,10 +19,12 @@ export default defineComponent({
|
|
19
19
|
}),
|
20
20
|
emits: ['confirm', 'cancel', 'change', 'update:modelValue'],
|
21
21
|
|
22
|
-
setup(props, {
|
23
|
-
|
24
|
-
|
25
|
-
|
22
|
+
setup(props, _ref) {
|
23
|
+
var {
|
24
|
+
emit,
|
25
|
+
slots
|
26
|
+
} = _ref;
|
27
|
+
|
26
28
|
var formatValue = value => {
|
27
29
|
var {
|
28
30
|
minHour,
|
@@ -50,10 +52,11 @@ export default defineComponent({
|
|
50
52
|
type: 'minute',
|
51
53
|
range: [+props.minMinute, +props.maxMinute]
|
52
54
|
}]);
|
53
|
-
var originColumns = computed(() => ranges.value.map(
|
54
|
-
|
55
|
-
|
56
|
-
|
55
|
+
var originColumns = computed(() => ranges.value.map(_ref2 => {
|
56
|
+
var {
|
57
|
+
type,
|
58
|
+
range: rangeArr
|
59
|
+
} = _ref2;
|
57
60
|
var values = times(rangeArr[1] - rangeArr[0] + 1, index => padZero(rangeArr[0] + index));
|
58
61
|
|
59
62
|
if (props.filter) {
|
@@ -126,7 +129,7 @@ export default defineComponent({
|
|
126
129
|
"onChange": onChange,
|
127
130
|
"onCancel": onCancel,
|
128
131
|
"onConfirm": onConfirm
|
129
|
-
}, pick(props,
|
132
|
+
}, pick(props, pickerInheritKeys)), slots);
|
130
133
|
}
|
131
134
|
|
132
135
|
});
|
@@ -31,7 +31,7 @@ export declare const sharedProps: {
|
|
31
31
|
default: (type: string, value: string) => string;
|
32
32
|
};
|
33
33
|
};
|
34
|
-
export declare const
|
34
|
+
export declare const pickerInheritKeys: ("title" | "readonly" | "loading" | "allowHtml" | "itemHeight" | "showToolbar" | "swipeDuration" | "visibleItemCount" | "cancelButtonText" | "confirmButtonText")[];
|
35
35
|
export declare function times<T>(n: number, iteratee: (index: number) => T): T[];
|
36
36
|
export declare function getTrueValue(value: string | undefined): number;
|
37
37
|
export declare const getMonthEndDay: (year: number, month: number) => number;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { extend } from '../utils';
|
2
|
-
import {
|
3
|
-
export var sharedProps = extend({},
|
2
|
+
import { pickerSharedProps } from '../picker/Picker';
|
3
|
+
export var sharedProps = extend({}, pickerSharedProps, {
|
4
4
|
filter: Function,
|
5
5
|
columnsOrder: Array,
|
6
6
|
formatter: {
|
@@ -8,7 +8,7 @@ export var sharedProps = extend({}, pickerProps, {
|
|
8
8
|
default: (type, value) => value
|
9
9
|
}
|
10
10
|
});
|
11
|
-
export var
|
11
|
+
export var pickerInheritKeys = Object.keys(pickerSharedProps);
|
12
12
|
export function times(n, iteratee) {
|
13
13
|
var index = -1;
|
14
14
|
var result = Array(n);
|
package/es/dialog/Dialog.d.ts
CHANGED
@@ -1,5 +1,59 @@
|
|
1
|
-
import { PropType } from 'vue';
|
1
|
+
import { PropType, ExtractPropTypes } from 'vue';
|
2
2
|
import type { DialogTheme, DialogAction, DialogMessage, DialogMessageAlign } from './types';
|
3
|
+
declare const dialogProps: {
|
4
|
+
show: BooleanConstructor;
|
5
|
+
zIndex: (NumberConstructor | StringConstructor)[];
|
6
|
+
overlay: {
|
7
|
+
type: BooleanConstructor;
|
8
|
+
default: true;
|
9
|
+
};
|
10
|
+
duration: (NumberConstructor | StringConstructor)[];
|
11
|
+
teleport: PropType<string | import("vue").RendererElement | null | undefined>;
|
12
|
+
lockScroll: {
|
13
|
+
type: BooleanConstructor;
|
14
|
+
default: true;
|
15
|
+
};
|
16
|
+
lazyRender: {
|
17
|
+
type: BooleanConstructor;
|
18
|
+
default: true;
|
19
|
+
};
|
20
|
+
beforeClose: PropType<import("../utils").Interceptor>;
|
21
|
+
overlayStyle: PropType<import("vue").CSSProperties>;
|
22
|
+
overlayClass: PropType<unknown>;
|
23
|
+
transitionAppear: BooleanConstructor;
|
24
|
+
closeOnClickOverlay: {
|
25
|
+
type: BooleanConstructor;
|
26
|
+
default: true;
|
27
|
+
};
|
28
|
+
} & {
|
29
|
+
title: StringConstructor;
|
30
|
+
theme: PropType<DialogTheme>;
|
31
|
+
width: (NumberConstructor | StringConstructor)[];
|
32
|
+
message: PropType<DialogMessage>;
|
33
|
+
callback: PropType<(action?: DialogAction | undefined) => void>;
|
34
|
+
allowHtml: BooleanConstructor;
|
35
|
+
className: PropType<unknown>;
|
36
|
+
transition: {
|
37
|
+
type: PropType<string>;
|
38
|
+
default: string;
|
39
|
+
};
|
40
|
+
messageAlign: PropType<DialogMessageAlign>;
|
41
|
+
closeOnPopstate: {
|
42
|
+
type: BooleanConstructor;
|
43
|
+
default: true;
|
44
|
+
};
|
45
|
+
showCancelButton: BooleanConstructor;
|
46
|
+
cancelButtonText: StringConstructor;
|
47
|
+
cancelButtonColor: StringConstructor;
|
48
|
+
confirmButtonText: StringConstructor;
|
49
|
+
confirmButtonColor: StringConstructor;
|
50
|
+
showConfirmButton: {
|
51
|
+
type: BooleanConstructor;
|
52
|
+
default: true;
|
53
|
+
};
|
54
|
+
closeOnClickOverlay: BooleanConstructor;
|
55
|
+
};
|
56
|
+
export declare type DialogProps = ExtractPropTypes<typeof dialogProps>;
|
3
57
|
declare const _default: import("vue").DefineComponent<{
|
4
58
|
show: BooleanConstructor;
|
5
59
|
zIndex: (NumberConstructor | StringConstructor)[];
|
package/es/dialog/Dialog.js
CHANGED
@@ -10,34 +10,36 @@ import { ActionBar } from '../action-bar';
|
|
10
10
|
import { ActionBarButton } from '../action-bar-button'; // Types
|
11
11
|
|
12
12
|
var [name, bem, t] = createNamespace('dialog');
|
13
|
-
var
|
13
|
+
var dialogProps = extend({}, popupSharedProps, {
|
14
|
+
title: String,
|
15
|
+
theme: String,
|
16
|
+
width: numericProp,
|
17
|
+
message: [String, Function],
|
18
|
+
callback: Function,
|
19
|
+
allowHtml: Boolean,
|
20
|
+
className: unknownProp,
|
21
|
+
transition: makeStringProp('van-dialog-bounce'),
|
22
|
+
messageAlign: String,
|
23
|
+
closeOnPopstate: truthProp,
|
24
|
+
showCancelButton: Boolean,
|
25
|
+
cancelButtonText: String,
|
26
|
+
cancelButtonColor: String,
|
27
|
+
confirmButtonText: String,
|
28
|
+
confirmButtonColor: String,
|
29
|
+
showConfirmButton: truthProp,
|
30
|
+
closeOnClickOverlay: Boolean
|
31
|
+
});
|
32
|
+
var popupInheritKeys = [...popupSharedPropKeys, 'transition', 'closeOnPopstate'];
|
14
33
|
export default defineComponent({
|
15
34
|
name,
|
16
|
-
props:
|
17
|
-
title: String,
|
18
|
-
theme: String,
|
19
|
-
width: numericProp,
|
20
|
-
message: [String, Function],
|
21
|
-
callback: Function,
|
22
|
-
allowHtml: Boolean,
|
23
|
-
className: unknownProp,
|
24
|
-
transition: makeStringProp('van-dialog-bounce'),
|
25
|
-
messageAlign: String,
|
26
|
-
closeOnPopstate: truthProp,
|
27
|
-
showCancelButton: Boolean,
|
28
|
-
cancelButtonText: String,
|
29
|
-
cancelButtonColor: String,
|
30
|
-
confirmButtonText: String,
|
31
|
-
confirmButtonColor: String,
|
32
|
-
showConfirmButton: truthProp,
|
33
|
-
closeOnClickOverlay: Boolean
|
34
|
-
}),
|
35
|
+
props: dialogProps,
|
35
36
|
emits: ['confirm', 'cancel', 'update:show'],
|
36
37
|
|
37
|
-
setup(props, {
|
38
|
-
|
39
|
-
|
40
|
-
|
38
|
+
setup(props, _ref) {
|
39
|
+
var {
|
40
|
+
emit,
|
41
|
+
slots
|
42
|
+
} = _ref;
|
41
43
|
var loading = reactive({
|
42
44
|
confirm: false,
|
43
45
|
cancel: false
|
@@ -47,10 +49,7 @@ export default defineComponent({
|
|
47
49
|
|
48
50
|
var close = action => {
|
49
51
|
updateShow(false);
|
50
|
-
|
51
|
-
if (props.callback) {
|
52
|
-
props.callback(action);
|
53
|
-
}
|
52
|
+
props.callback == null ? void 0 : props.callback(action);
|
54
53
|
};
|
55
54
|
|
56
55
|
var getActionHandler = action => () => {
|
@@ -63,8 +62,7 @@ export default defineComponent({
|
|
63
62
|
|
64
63
|
if (props.beforeClose) {
|
65
64
|
loading[action] = true;
|
66
|
-
callInterceptor({
|
67
|
-
interceptor: props.beforeClose,
|
65
|
+
callInterceptor(props.beforeClose, {
|
68
66
|
args: [action],
|
69
67
|
|
70
68
|
done() {
|
@@ -211,10 +209,9 @@ export default defineComponent({
|
|
211
209
|
"style": {
|
212
210
|
width: addUnit(width)
|
213
211
|
},
|
214
|
-
"aria-labelledby": title || message
|
215
|
-
|
216
|
-
|
217
|
-
}), {
|
212
|
+
"aria-labelledby": title || message,
|
213
|
+
"onUpdate:show": updateShow
|
214
|
+
}, pick(props, popupInheritKeys)), {
|
218
215
|
default: () => [renderTitle(), renderContent(), renderFooter()]
|
219
216
|
});
|
220
217
|
};
|
@@ -13,7 +13,7 @@ declare namespace Dialog {
|
|
13
13
|
className: string;
|
14
14
|
allowHtml: boolean;
|
15
15
|
lockScroll: boolean;
|
16
|
-
transition:
|
16
|
+
transition: undefined;
|
17
17
|
beforeClose: null;
|
18
18
|
overlayClass: string;
|
19
19
|
overlayStyle: undefined;
|
@@ -38,7 +38,7 @@ declare namespace Dialog {
|
|
38
38
|
className: string;
|
39
39
|
allowHtml: boolean;
|
40
40
|
lockScroll: boolean;
|
41
|
-
transition:
|
41
|
+
transition: undefined;
|
42
42
|
beforeClose: null;
|
43
43
|
overlayClass: string;
|
44
44
|
overlayStyle: undefined;
|