sard-uniapp 1.27.0 → 1.28.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/CHANGELOG.md +29 -0
- package/README.md +1 -1
- package/components/accordion/README.md +21 -11
- package/components/accordion/accordion.d.ts +7 -1
- package/components/accordion/accordion.vue +5 -4
- package/components/accordion/common.d.ts +8 -0
- package/components/accordion/common.js +4 -0
- package/components/accordion-item/accordion-item.vue +12 -4
- package/components/accordion-item/index.scss +4 -0
- package/components/action-sheet/action-sheet.vue +1 -1
- package/components/action-sheet/common.d.ts +2 -130
- package/components/action-sheet/common.js +5 -1
- package/components/action-sheet-agent/common.d.ts +2 -585
- package/components/action-sheet-agent/common.js +4 -3
- package/components/alert/README.md +16 -9
- package/components/alert/alert.d.ts +1 -0
- package/components/alert/alert.vue +10 -3
- package/components/alert/common.d.ts +3 -65
- package/components/alert/common.js +4 -1
- package/components/alert/index.scss +17 -12
- package/components/alert/variables.scss +1 -0
- package/components/avatar/avatar.d.ts +1 -1
- package/components/avatar/avatar.vue +1 -1
- package/components/avatar/common.d.ts +2 -101
- package/components/avatar/common.js +4 -1
- package/components/avatar-group/avatar-group.vue +1 -1
- package/components/avatar-group/common.d.ts +2 -65
- package/components/avatar-group/common.js +5 -1
- package/components/back-top/common.d.ts +2 -43
- package/components/back-top/common.js +1 -0
- package/components/badge/badge.vue +1 -1
- package/components/badge/common.d.ts +2 -101
- package/components/badge/common.js +5 -1
- package/components/button/button.d.ts +3 -3
- package/components/button/button.vue +10 -4
- package/components/button/common.d.ts +2 -962
- package/components/button/common.js +10 -1
- package/components/button/index.scss +93 -0
- package/components/calendar/calendar.d.ts +1 -1
- package/components/calendar/calendar.vue +1 -1
- package/components/calendar/common.d.ts +2 -362
- package/components/calendar/common.js +6 -1
- package/components/calendar-input/calendar-input.d.ts +3 -3
- package/components/calendar-input/common.d.ts +2 -1601
- package/components/calendar-input/common.js +6 -0
- package/components/calendar-popout/calendar-popout.d.ts +1 -1
- package/components/calendar-popout/common.d.ts +2 -677
- package/components/calendar-popout/common.js +5 -0
- package/components/card/common.d.ts +2 -0
- package/components/card/common.js +4 -1
- package/components/cascader/cascader.d.ts +16 -3
- package/components/cascader/cascader.vue +1 -1
- package/components/cascader/common.d.ts +2 -3
- package/components/cascader/common.js +4 -2
- package/components/cascader/useCascaderTree.d.ts +1 -1
- package/components/cascader-input/cascader-input.d.ts +4 -4
- package/components/cascader-input/common.d.ts +2 -1297
- package/components/cascader-input/common.js +3 -0
- package/components/cascader-popout/cascader-popout.d.ts +2 -2
- package/components/cascader-popout/cascader-popout.vue +1 -1
- package/components/cascader-popout/common.d.ts +2 -485
- package/components/cascader-popout/common.js +5 -1
- package/components/checkbox/checkbox.d.ts +1 -1
- package/components/checkbox/checkbox.vue +1 -1
- package/components/checkbox/common.d.ts +3 -327
- package/components/checkbox/common.js +9 -2
- package/components/checkbox-group/checkbox-group.d.ts +3 -3
- package/components/checkbox-group/checkbox-group.vue +1 -1
- package/components/checkbox-input/checkbox-input.d.ts +4 -4
- package/components/checkbox-input/common.d.ts +4 -4
- package/components/checkbox-popout/checkbox-popout.d.ts +2 -2
- package/components/checkbox-popout/common.d.ts +2 -507
- package/components/checkbox-popout/common.js +2 -0
- package/components/compact/README.md +72 -0
- package/components/compact/common.d.ts +24 -0
- package/components/compact/common.js +6 -0
- package/components/compact/compact.d.ts +15 -0
- package/components/compact/compact.vue +81 -0
- package/components/compact/index.d.ts +1 -0
- package/components/compact/index.js +1 -0
- package/components/compact/index.scss +17 -0
- package/components/config/index.d.ts +10 -4
- package/components/config/index.js +21 -509
- package/components/cool-icon/common.d.ts +2 -65
- package/components/cool-icon/common.js +4 -1
- package/components/cool-icon/cool-icon.d.ts +1 -1
- package/components/cool-icon/cool-icon.vue +1 -1
- package/components/count-down/common.d.ts +2 -50
- package/components/count-down/common.js +6 -1
- package/components/count-down/count-down.vue +1 -1
- package/components/count-to/common.d.ts +2 -37
- package/components/count-to/common.js +7 -1
- package/components/count-to/count-to.vue +1 -1
- package/components/crop-image/common.d.ts +2 -290
- package/components/crop-image/common.js +7 -1
- package/components/crop-image/crop-image.vue +1 -1
- package/components/crop-image-agent/common.d.ts +2 -290
- package/components/crop-image-agent/common.js +3 -2
- package/components/datetime-picker/common.d.ts +2 -122
- package/components/datetime-picker/common.js +5 -1
- package/components/datetime-picker/datetime-picker.d.ts +2 -2
- package/components/datetime-picker/datetime-picker.vue +1 -1
- package/components/datetime-picker-input/common.d.ts +2 -1025
- package/components/datetime-picker-input/common.js +3 -0
- package/components/datetime-picker-input/datetime-picker-input.d.ts +4 -4
- package/components/datetime-picker-popout/common.d.ts +2 -325
- package/components/datetime-picker-popout/common.js +3 -0
- package/components/datetime-picker-popout/datetime-picker-popout.d.ts +2 -2
- package/components/datetime-range-picker/common.d.ts +2 -145
- package/components/datetime-range-picker/common.js +4 -1
- package/components/datetime-range-picker/datetime-range-picker.d.ts +3 -3
- package/components/datetime-range-picker/datetime-range-picker.vue +1 -1
- package/components/datetime-range-picker-input/common.d.ts +2 -1090
- package/components/datetime-range-picker-input/common.js +2 -0
- package/components/datetime-range-picker-input/datetime-range-picker-input.d.ts +5 -5
- package/components/datetime-range-picker-popout/common.d.ts +2 -362
- package/components/datetime-range-picker-popout/common.js +3 -1
- package/components/datetime-range-picker-popout/datetime-range-picker-popout.d.ts +3 -3
- package/components/datetime-range-picker-popout/datetime-range-picker-popout.vue +2 -2
- package/components/dialog/common.d.ts +2 -362
- package/components/dialog/common.js +9 -1
- package/components/dialog/dialog.vue +2 -2
- package/components/dialog-agent/common.d.ts +2 -1025
- package/components/dialog-agent/common.js +4 -3
- package/components/divider/common.d.ts +2 -50
- package/components/divider/common.js +6 -1
- package/components/divider/divider.vue +1 -1
- package/components/dropdown/README.md +18 -11
- package/components/dropdown/common.d.ts +4 -102
- package/components/dropdown/common.js +11 -3
- package/components/dropdown/dropdown.d.ts +2 -1
- package/components/dropdown/dropdown.vue +12 -4
- package/components/dropdown/index.scss +29 -1
- package/components/dropdown/variables.scss +1 -0
- package/components/dropdown-item/dropdown-item.vue +1 -1
- package/components/empty/common.d.ts +2 -65
- package/components/empty/common.js +4 -1
- package/components/empty/empty.d.ts +1 -1
- package/components/empty/empty.vue +1 -1
- package/components/fab/common.d.ts +2 -622
- package/components/fab/common.js +7 -0
- package/components/fab/fab.d.ts +3 -3
- package/components/fab/index.scss +2 -0
- package/components/fab-item/common.d.ts +1 -1
- package/components/fab-item/common.js +1 -1
- package/components/fab-item/fab-item.vue +1 -1
- package/components/floating-bubble/common.d.ts +2 -155
- package/components/floating-bubble/common.js +7 -1
- package/components/floating-bubble/floating-bubble.vue +1 -1
- package/components/floating-panel/common.d.ts +2 -65
- package/components/floating-panel/common.js +6 -1
- package/components/floating-panel/floating-panel.vue +1 -1
- package/components/form/common.d.ts +3 -345
- package/components/form/common.js +13 -1
- package/components/form/form.d.ts +4 -3
- package/components/form/form.vue +1 -1
- package/components/form-item/index.scss +3 -0
- package/components/form-plain/form-plain.d.ts +4 -3
- package/components/form-plain/form-plain.vue +1 -1
- package/components/grid/common.d.ts +2 -101
- package/components/grid/common.js +5 -1
- package/components/grid/grid.vue +1 -1
- package/components/icon/common.d.ts +2 -65
- package/components/icon/common.js +6 -1
- package/components/icon/icon.vue +1 -1
- package/components/image/common.d.ts +2 -401
- package/components/image/common.js +11 -1
- package/components/image/image.d.ts +1 -1
- package/components/image/image.vue +1 -1
- package/components/indexes/common.d.ts +2 -0
- package/components/indexes/common.js +5 -0
- package/components/indexes/indexes.d.ts +6 -1
- package/components/indexes/indexes.vue +5 -4
- package/components/indexes-nav/indexes-nav.vue +4 -2
- package/components/input/common.d.ts +3 -2402
- package/components/input/common.js +17 -1
- package/components/input/index.scss +54 -0
- package/components/input/input.d.ts +3 -2
- package/components/input/input.vue +10 -4
- package/components/input/variables.scss +5 -0
- package/components/keyboard/common.d.ts +2 -26
- package/components/keyboard/common.js +5 -1
- package/components/keyboard/keyboard.d.ts +2 -2
- package/components/keyboard/keyboard.vue +1 -1
- package/components/list/common.d.ts +2 -170
- package/components/list/common.js +4 -1
- package/components/list-item/list-item.d.ts +1 -1
- package/components/list-item/list-item.vue +1 -1
- package/components/load-more/common.d.ts +1 -1
- package/components/load-more/common.js +2 -2
- package/components/load-more/load-more.vue +1 -1
- package/components/loading/common.d.ts +2 -121
- package/components/loading/common.js +1 -0
- package/components/marquee/common.d.ts +2 -37
- package/components/marquee/common.js +6 -1
- package/components/marquee/marquee.vue +1 -1
- package/components/menu/common.d.ts +1 -1
- package/components/menu/common.js +2 -2
- package/components/menu/menu.vue +1 -1
- package/components/notice-bar/common.d.ts +2 -197
- package/components/notice-bar/common.js +7 -1
- package/components/notice-bar/notice-bar.d.ts +2 -2
- package/components/notice-bar/notice-bar.vue +1 -1
- package/components/notify/common.d.ts +2 -145
- package/components/notify/common.js +7 -1
- package/components/notify/notify.d.ts +1 -1
- package/components/notify/notify.vue +1 -1
- package/components/notify-agent/common.d.ts +2 -485
- package/components/notify-agent/common.js +4 -3
- package/components/notify-agent/notify-agent.d.ts +1 -1
- package/components/overlay/common.d.ts +2 -65
- package/components/overlay/common.js +4 -1
- package/components/overlay/overlay.vue +1 -1
- package/components/pagination/common.d.ts +2 -145
- package/components/pagination/common.js +9 -1
- package/components/pagination/pagination.d.ts +1 -1
- package/components/pagination/pagination.vue +1 -1
- package/components/password-input/common.d.ts +2 -170
- package/components/password-input/common.js +6 -1
- package/components/password-input/password-input.d.ts +1 -1
- package/components/password-input/password-input.vue +1 -1
- package/components/picker/common.d.ts +2 -49
- package/components/picker/common.js +1 -0
- package/components/picker-input/common.d.ts +38 -38
- package/components/picker-input/picker-input.d.ts +3 -3
- package/components/picker-popout/common.d.ts +2 -211
- package/components/picker-popout/common.js +1 -0
- package/components/picker-popout/picker-popout.d.ts +1 -1
- package/components/popout/common.d.ts +2 -530
- package/components/popout/common.js +11 -1
- package/components/popout/popout.d.ts +1 -1
- package/components/popout/popout.vue +1 -1
- package/components/popout-input/common.d.ts +2 -241
- package/components/popout-input/common.js +5 -1
- package/components/popout-input/index.scss +19 -0
- package/components/popout-input/popout-input.d.ts +6 -6
- package/components/popout-input/popout-input.vue +7 -2
- package/components/popover/common.d.ts +2 -170
- package/components/popover/common.js +10 -1
- package/components/popover/popover.d.ts +1 -1
- package/components/popover/popover.vue +1 -1
- package/components/popup/common.d.ts +2 -226
- package/components/popup/common.js +9 -1
- package/components/popup/popup.d.ts +1 -1
- package/components/popup/popup.vue +1 -1
- package/components/progress-bar/common.d.ts +2 -145
- package/components/progress-bar/common.js +5 -1
- package/components/progress-bar/progress-bar.vue +1 -1
- package/components/progress-circle/common.d.ts +2 -82
- package/components/progress-circle/common.js +5 -1
- package/components/progress-circle/progress-circle.vue +1 -1
- package/components/pull-down-refresh/common.d.ts +2 -64
- package/components/pull-down-refresh/common.js +8 -4
- package/components/pull-down-refresh/pull-down-refresh.d.ts +1 -1
- package/components/puzzle-verify/common.d.ts +2 -170
- package/components/puzzle-verify/common.js +3 -2
- package/components/puzzle-verify/puzzle-verify.vue +1 -1
- package/components/qrcode/common.d.ts +2 -170
- package/components/qrcode/common.js +11 -1
- package/components/qrcode/qrcode.d.ts +1 -1
- package/components/qrcode/qrcode.vue +1 -1
- package/components/radio/common.d.ts +2 -157
- package/components/radio/common.js +5 -1
- package/components/radio-group/radio-group.d.ts +1 -1
- package/components/radio-group/radio-group.vue +1 -1
- package/components/radio-input/common.d.ts +2 -2
- package/components/radio-input/radio-input.d.ts +4 -4
- package/components/radio-popout/common.d.ts +2 -441
- package/components/radio-popout/common.js +3 -0
- package/components/radio-popout/radio-popout.d.ts +2 -2
- package/components/rate/common.d.ts +2 -362
- package/components/rate/common.js +7 -1
- package/components/rate/rate.d.ts +2 -2
- package/components/rate/rate.vue +1 -1
- package/components/read-more/common.d.ts +2 -82
- package/components/read-more/common.js +4 -1
- package/components/read-more/read-more.vue +1 -1
- package/components/resize-sensor/common.d.ts +2 -26
- package/components/resize-sensor/common.js +4 -1
- package/components/resize-sensor/resize-sensor.vue +1 -1
- package/components/result/common.d.ts +2 -82
- package/components/result/common.js +4 -1
- package/components/result/result.d.ts +1 -1
- package/components/result/result.vue +1 -1
- package/components/rotate-verify/common.d.ts +2 -145
- package/components/rotate-verify/common.js +3 -2
- package/components/rotate-verify/rotate-verify.vue +1 -1
- package/components/scroll-list/common.d.ts +1 -1
- package/components/scroll-list/common.js +1 -1
- package/components/scroll-list/scroll-list.vue +1 -1
- package/components/search/common.d.ts +2 -226
- package/components/search/common.js +5 -1
- package/components/search/search.d.ts +3 -3
- package/components/search/search.vue +1 -1
- package/components/segmented/common.d.ts +2 -133
- package/components/segmented/common.js +7 -1
- package/components/segmented/segmented.d.ts +1 -1
- package/components/segmented/segmented.vue +1 -1
- package/components/segmented-item/common.d.ts +1 -1
- package/components/segmented-item/common.js +1 -1
- package/components/segmented-item/segmented-item.vue +1 -1
- package/components/select/common.d.ts +4 -256
- package/components/select/common.js +2 -0
- package/components/select/select.d.ts +3 -1
- package/components/select/select.vue +6 -3
- package/components/select/useSelect.js +9 -1
- package/components/select-input/common.d.ts +2 -1407
- package/components/select-input/common.js +1 -0
- package/components/select-input/select-input.d.ts +4 -4
- package/components/select-input/select-input.vue +1 -0
- package/components/select-option/common.d.ts +1 -1
- package/components/select-option/common.js +1 -1
- package/components/select-option/select-option.vue +1 -1
- package/components/select-option-group/common.d.ts +1 -1
- package/components/select-option-group/common.js +1 -1
- package/components/select-option-group/select-option-group.vue +1 -1
- package/components/select-popout/README.md +9 -8
- package/components/select-popout/common.d.ts +2 -553
- package/components/select-popout/common.js +2 -0
- package/components/select-popout/select-popout.d.ts +2 -2
- package/components/select-popout/select-popout.vue +10 -1
- package/components/share-sheet/common.d.ts +2 -122
- package/components/share-sheet/common.js +5 -1
- package/components/share-sheet/share-sheet.vue +1 -1
- package/components/signature/common.d.ts +2 -257
- package/components/signature/common.js +10 -1
- package/components/signature/signature.vue +1 -1
- package/components/skeleton/common.d.ts +2 -122
- package/components/skeleton/common.js +5 -1
- package/components/skeleton/skeleton.d.ts +2 -2
- package/components/skeleton/skeleton.vue +1 -1
- package/components/slide-verify/common.d.ts +2 -122
- package/components/slide-verify/common.js +4 -1
- package/components/slide-verify/slide-verify.vue +1 -1
- package/components/slider/common.d.ts +2 -530
- package/components/slider/common.js +7 -1
- package/components/slider/slider.d.ts +3 -3
- package/components/slider/slider.vue +1 -1
- package/components/space/common.d.ts +2 -65
- package/components/space/common.js +5 -1
- package/components/space/space.vue +1 -1
- package/components/status-bar/common.d.ts +1 -1
- package/components/status-bar/common.js +1 -1
- package/components/status-bar/status-bar.vue +1 -1
- package/components/stepper/common.d.ts +2 -362
- package/components/stepper/common.js +12 -1
- package/components/stepper/stepper.d.ts +2 -2
- package/components/stepper/stepper.vue +1 -1
- package/components/steps/common.d.ts +2 -226
- package/components/steps/common.js +11 -1
- package/components/steps/steps.vue +1 -1
- package/components/style/functions.scss +16 -0
- package/components/swiper-dot/common.d.ts +2 -65
- package/components/swiper-dot/common.js +7 -1
- package/components/swiper-dot/swiper-dot.vue +1 -1
- package/components/switch/common.d.ts +2 -155
- package/components/switch/common.js +6 -1
- package/components/switch/index.scss +1 -0
- package/components/switch/switch.d.ts +4 -4
- package/components/switch/switch.vue +1 -1
- package/components/tabbar/common.d.ts +2 -82
- package/components/tabbar/common.js +4 -1
- package/components/tabbar/tabbar.vue +1 -1
- package/components/table/common.d.ts +2 -37
- package/components/table/common.js +5 -1
- package/components/table/table.vue +1 -1
- package/components/tabs/common.d.ts +2 -50
- package/components/tabs/common.js +4 -1
- package/components/tabs/tabs.d.ts +1 -1
- package/components/tabs/tabs.vue +1 -1
- package/components/tag/common.d.ts +2 -122
- package/components/tag/common.js +5 -1
- package/components/tag/tag.d.ts +2 -2
- package/components/tag/tag.vue +1 -1
- package/components/toast/common.d.ts +2 -122
- package/components/toast/common.js +9 -1
- package/components/toast/toast.d.ts +1 -1
- package/components/toast/toast.vue +1 -1
- package/components/toast-agent/common.d.ts +2 -442
- package/components/toast-agent/common.js +4 -3
- package/components/toast-agent/toast-agent.d.ts +1 -1
- package/components/tree/common.d.ts +2 -601
- package/components/tree/common.js +3 -0
- package/components/tree-node/tree-node.vue +4 -4
- package/components/upload/common.d.ts +3 -199
- package/components/upload/common.js +15 -2
- package/components/upload/upload.d.ts +5 -2
- package/components/upload/upload.vue +1 -1
- package/components/upload-preview/upload-preview.vue +1 -1
- package/components/waterfall/common.d.ts +2 -37
- package/components/waterfall/common.js +6 -1
- package/components/waterfall/waterfall.vue +1 -1
- package/components/watermark/common.d.ts +2 -145
- package/components/watermark/common.js +8 -1
- package/components/watermark/watermark.d.ts +1 -1
- package/components/watermark/watermark.vue +1 -1
- package/global.d.ts +2 -1
- package/index.d.ts +2 -1
- package/index.js +2 -1
- package/package.json +1 -1
- package/use/useZIndex.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,32 @@
|
|
|
1
|
+
# [1.28.0](https://github.com/sutras/sard-uniapp/compare/v1.27.1...v1.28.0) (2026-03-27)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **button:** 设置icon对是否块级不影响 ([14ee315](https://github.com/sutras/sard-uniapp/commit/14ee315b594ac8f2d10af830a6974bdbb590f703))
|
|
7
|
+
* **faq:** 修复文字长度不一导致图标不对齐问题 ([2805d43](https://github.com/sutras/sard-uniapp/commit/2805d436859952ad39271c043b176ec7e646791a))
|
|
8
|
+
* 优化form和switch布局 ([aae9bc1](https://github.com/sutras/sard-uniapp/commit/aae9bc1d382dd287005bce28fc459ab52a3f7b0d))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **accordion:** 新增title, extra, arrow插槽 ([76f56d7](https://github.com/sutras/sard-uniapp/commit/76f56d71cd6a20681b56a845db0cd942e7b18697))
|
|
14
|
+
* **alert:** 新增 square 属性,添加默认圆角 ([45b59af](https://github.com/sutras/sard-uniapp/commit/45b59af19477f67f29f48b1dacd85299a75841dc))
|
|
15
|
+
* **compact:** 新增 Compact 组件 ([84b9dc4](https://github.com/sutras/sard-uniapp/commit/84b9dc40689a0817b436347fbbe44b20dcf647fc))
|
|
16
|
+
* **dialog:** 使用text元素包裹message,以支持转义字符 ([b66c347](https://github.com/sutras/sard-uniapp/commit/b66c34705244263724361c0dfdb709f357a04587))
|
|
17
|
+
* **dropdown:** 新增分割线类型 ([0cd77cd](https://github.com/sutras/sard-uniapp/commit/0cd77cd31cdbbea390f266d0d337a4863919b087))
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
## [1.27.1](https://github.com/sutras/sard-uniapp/compare/v1.27.0...v1.27.1) (2026-03-07)
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
### Features
|
|
25
|
+
|
|
26
|
+
* **select-popout:** 新增show-confirm属性 ([017d4ba](https://github.com/sutras/sard-uniapp/commit/017d4ba86f05ebe368ace11d4b47f2ff6f752c67))
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
1
30
|
# [1.27.0](https://github.com/sutras/sard-uniapp/compare/v1.26.3...v1.27.0) (2026-02-23)
|
|
2
31
|
|
|
3
32
|
|
package/README.md
CHANGED
|
@@ -44,6 +44,12 @@ import AccordionItem from 'sard-uniapp/components/accordion-item/accordion-item.
|
|
|
44
44
|
|
|
45
45
|
@code('${DEMO_PATH}/accordion/demo/HideBorder.vue')
|
|
46
46
|
|
|
47
|
+
### 插槽 <sup>1.28+</sup>
|
|
48
|
+
|
|
49
|
+
可以使用 `title`, `extra`, `arrow` 插槽来自定义内容。
|
|
50
|
+
|
|
51
|
+
@code('${DEMO_PATH}/accordion/demo/Slot.vue')
|
|
52
|
+
|
|
47
53
|
## API
|
|
48
54
|
|
|
49
55
|
### AccordionProps
|
|
@@ -70,20 +76,24 @@ import AccordionItem from 'sard-uniapp/components/accordion-item/accordion-item.
|
|
|
70
76
|
|
|
71
77
|
### AccordionItemProps
|
|
72
78
|
|
|
73
|
-
| 属性
|
|
74
|
-
|
|
|
75
|
-
| root-class
|
|
76
|
-
| root-style
|
|
77
|
-
| title
|
|
78
|
-
|
|
|
79
|
-
|
|
|
80
|
-
|
|
|
79
|
+
| 属性 | 描述 | 类型 | 默认值 |
|
|
80
|
+
| ------------------------------- | -------------- | ---------------- | ------ |
|
|
81
|
+
| root-class | 组件根元素类名 | string | - |
|
|
82
|
+
| root-style | 组件根元素样式 | StyleValue | - |
|
|
83
|
+
| title | 面板标题 | string | - |
|
|
84
|
+
| extra <sup>1.28+</sup> | 面板右边的内容 | string | - |
|
|
85
|
+
| value (同extra,建议使用 extra) | 面板右边的内容 | string | - |
|
|
86
|
+
| name | 面板的唯一标识 | string \| number | - |
|
|
87
|
+
| disabled | 禁用面板 | boolean | false |
|
|
81
88
|
|
|
82
89
|
### AccordionItemSlots
|
|
83
90
|
|
|
84
|
-
| 插槽
|
|
85
|
-
|
|
|
86
|
-
| default
|
|
91
|
+
| 插槽 | 描述 | 属性 |
|
|
92
|
+
| ---------------------- | ---------------- | -------------------- |
|
|
93
|
+
| default | 自定义默认内容 | - |
|
|
94
|
+
| title <sup>1.28+</sup> | 自定义标题内容 | - |
|
|
95
|
+
| extra <sup>1.28+</sup> | 自定义值内容内容 | - |
|
|
96
|
+
| arrow <sup>1.28+</sup> | 自定义箭头 | { visible: boolean } |
|
|
87
97
|
|
|
88
98
|
### AccordionItemEmits
|
|
89
99
|
|
|
@@ -4,7 +4,13 @@ declare const __VLS_component: import("vue").DefineComponent<AccordionProps, {},
|
|
|
4
4
|
"update:model-value": (event: any) => any;
|
|
5
5
|
}, string, import("vue").PublicProps, Readonly<AccordionProps> & Readonly<{
|
|
6
6
|
"onUpdate:model-value"?: ((event: any) => any) | undefined;
|
|
7
|
-
}>, {
|
|
7
|
+
}>, {
|
|
8
|
+
multiple: boolean;
|
|
9
|
+
rootStyle: string | false | import("vue").CSSProperties | import("vue").StyleValue[] | null;
|
|
10
|
+
rootClass: string;
|
|
11
|
+
modelValue: (string | number)[] | string | number;
|
|
12
|
+
hideBorder: boolean;
|
|
13
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
8
14
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
9
15
|
export default _default;
|
|
10
16
|
|
|
@@ -5,11 +5,12 @@
|
|
|
5
5
|
</template>
|
|
6
6
|
|
|
7
7
|
<script>
|
|
8
|
-
import { defineComponent as _defineComponent } from "vue";
|
|
8
|
+
import { mergeDefaults as _mergeDefaults, defineComponent as _defineComponent } from "vue";
|
|
9
9
|
import { computed, provide, ref, watch, toRef, reactive } from "vue";
|
|
10
10
|
import { classNames, stringifyStyle, createBem } from "../../utils";
|
|
11
11
|
import {
|
|
12
|
-
accoridonContextSymbol
|
|
12
|
+
accoridonContextSymbol,
|
|
13
|
+
defaultAccordionProps
|
|
13
14
|
} from "./common";
|
|
14
15
|
/**
|
|
15
16
|
* @property {string} rootClass 组件根元素类名,默认值:-。
|
|
@@ -27,13 +28,13 @@ export default _defineComponent({
|
|
|
27
28
|
}
|
|
28
29
|
},
|
|
29
30
|
__name: "accordion",
|
|
30
|
-
props:
|
|
31
|
+
props: _mergeDefaults({
|
|
31
32
|
rootStyle: { type: null, required: false },
|
|
32
33
|
rootClass: { type: String, required: false },
|
|
33
34
|
modelValue: { type: [Array, String, Number], required: false },
|
|
34
35
|
multiple: { type: Boolean, required: false },
|
|
35
36
|
hideBorder: { type: Boolean, required: false }
|
|
36
|
-
},
|
|
37
|
+
}, defaultAccordionProps()),
|
|
37
38
|
emits: ["update:model-value"],
|
|
38
39
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
39
40
|
__expose();
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type StyleValue } from 'vue';
|
|
2
|
+
import { type DefaultProps } from '../config';
|
|
2
3
|
export interface AccordionProps {
|
|
3
4
|
rootStyle?: StyleValue;
|
|
4
5
|
rootClass?: string;
|
|
@@ -6,6 +7,7 @@ export interface AccordionProps {
|
|
|
6
7
|
multiple?: boolean;
|
|
7
8
|
hideBorder?: boolean;
|
|
8
9
|
}
|
|
10
|
+
export declare const defaultAccordionProps: () => DefaultProps<AccordionProps>;
|
|
9
11
|
export interface AccordionEmits {
|
|
10
12
|
(e: 'update:model-value', event: any): void;
|
|
11
13
|
}
|
|
@@ -24,6 +26,7 @@ export interface AccordionItemProps {
|
|
|
24
26
|
rootClass?: string;
|
|
25
27
|
title?: string;
|
|
26
28
|
value?: string;
|
|
29
|
+
extra?: string;
|
|
27
30
|
name?: string | number;
|
|
28
31
|
disabled?: boolean;
|
|
29
32
|
}
|
|
@@ -32,4 +35,9 @@ export interface AccordionItemEmits {
|
|
|
32
35
|
}
|
|
33
36
|
export interface AccordionItemSlots {
|
|
34
37
|
default?(props: Record<string, never>): any;
|
|
38
|
+
title?(props: Record<string, never>): any;
|
|
39
|
+
extra?(props: Record<string, never>): any;
|
|
40
|
+
arrow?(props: {
|
|
41
|
+
visible: boolean;
|
|
42
|
+
}): any;
|
|
35
43
|
}
|
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<view :class="accordionItemClass" :style="accordionItemStyle">
|
|
3
3
|
<view :class="classNames(bem.e('header'))" @click="onClick">
|
|
4
|
-
<view :class="bem.e('title')">
|
|
5
|
-
|
|
4
|
+
<view :class="bem.e('title')">
|
|
5
|
+
<slot name="title">{{ title }}</slot>
|
|
6
|
+
</view>
|
|
7
|
+
<view v-if="extra || value || $slots.extra" :class="bem.e('extra')">
|
|
8
|
+
<slot name="extra">{{ extra || value }}</slot>
|
|
9
|
+
</view>
|
|
6
10
|
<view :class="bem.e('arrow')">
|
|
7
|
-
<
|
|
11
|
+
<slot name="arrow" :visible="visible">
|
|
12
|
+
<sar-icon family="sari" :name="arrowName" />
|
|
13
|
+
</slot>
|
|
8
14
|
</view>
|
|
9
15
|
</view>
|
|
10
16
|
<sar-collapse :visible="visible">
|
|
@@ -28,7 +34,8 @@ import SarIcon from "../icon/icon.vue";
|
|
|
28
34
|
* @property {string} rootClass 组件根元素类名,默认值:-。
|
|
29
35
|
* @property {StyleValue} rootStyle 组件根元素样式,默认值:-。
|
|
30
36
|
* @property {string} title 面板标题,默认值:-。
|
|
31
|
-
* @property {string}
|
|
37
|
+
* @property {string} extra 面板右边的内容,默认值:-。
|
|
38
|
+
* @property {string} value 面板右边的内容,默认值:-。
|
|
32
39
|
* @property {string | number} name 面板的唯一标识,默认值:-。
|
|
33
40
|
* @property {boolean} disabled 禁用面板,默认值:false。
|
|
34
41
|
* @event {(event: any) => void} click 点击面板头部时触发
|
|
@@ -50,6 +57,7 @@ export default _defineComponent({
|
|
|
50
57
|
rootClass: { type: String, required: false },
|
|
51
58
|
title: { type: String, required: false },
|
|
52
59
|
value: { type: String, required: false },
|
|
60
|
+
extra: { type: String, required: false },
|
|
53
61
|
name: { type: [String, Number], required: false },
|
|
54
62
|
disabled: { type: Boolean, required: false }
|
|
55
63
|
},
|
|
@@ -114,7 +114,7 @@ export default _defineComponent({
|
|
|
114
114
|
overlayClosable: { type: Boolean, required: false },
|
|
115
115
|
beforeClose: { type: Function, required: false },
|
|
116
116
|
duration: { type: Number, required: false }
|
|
117
|
-
}, defaultActionSheetProps),
|
|
117
|
+
}, defaultActionSheetProps()),
|
|
118
118
|
emits: ["update:visible", "close", "cancel", "select", "before-enter", "enter", "after-enter", "enter-cancelled", "before-leave", "leave", "after-leave", "leave-cancelled", "visible-hook"],
|
|
119
119
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
120
120
|
__expose();
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type StyleValue } from 'vue';
|
|
2
|
+
import { type DefaultProps } from '../config';
|
|
2
3
|
import { type TransitionHookEmits } from '../popup/common';
|
|
3
4
|
export type ActionSheetBeforeClose = ((type: 'close' | 'cancel', loading: {
|
|
4
5
|
readonly cancel: boolean;
|
|
@@ -21,136 +22,7 @@ export interface ActionSheetProps {
|
|
|
21
22
|
beforeClose?: ActionSheetBeforeClose;
|
|
22
23
|
duration?: number;
|
|
23
24
|
}
|
|
24
|
-
export declare const defaultActionSheetProps:
|
|
25
|
-
rootStyle?: (string | false | ((props: {
|
|
26
|
-
rootStyle: StyleValue;
|
|
27
|
-
rootClass: string;
|
|
28
|
-
description: string;
|
|
29
|
-
itemList: ActionSheetItem[];
|
|
30
|
-
cancel: string;
|
|
31
|
-
showCancel: boolean;
|
|
32
|
-
visible: boolean;
|
|
33
|
-
overlayClosable: boolean;
|
|
34
|
-
beforeClose: ActionSheetBeforeClose;
|
|
35
|
-
duration: number;
|
|
36
|
-
}) => string | false | import("vue").CSSProperties | StyleValue[]) | null) | undefined;
|
|
37
|
-
rootClass?: (string | ((props: {
|
|
38
|
-
rootStyle: StyleValue;
|
|
39
|
-
rootClass: string;
|
|
40
|
-
description: string;
|
|
41
|
-
itemList: ActionSheetItem[];
|
|
42
|
-
cancel: string;
|
|
43
|
-
showCancel: boolean;
|
|
44
|
-
visible: boolean;
|
|
45
|
-
overlayClosable: boolean;
|
|
46
|
-
beforeClose: ActionSheetBeforeClose;
|
|
47
|
-
duration: number;
|
|
48
|
-
}) => string)) | undefined;
|
|
49
|
-
description?: (string | ((props: {
|
|
50
|
-
rootStyle: StyleValue;
|
|
51
|
-
rootClass: string;
|
|
52
|
-
description: string;
|
|
53
|
-
itemList: ActionSheetItem[];
|
|
54
|
-
cancel: string;
|
|
55
|
-
showCancel: boolean;
|
|
56
|
-
visible: boolean;
|
|
57
|
-
overlayClosable: boolean;
|
|
58
|
-
beforeClose: ActionSheetBeforeClose;
|
|
59
|
-
duration: number;
|
|
60
|
-
}) => string)) | undefined;
|
|
61
|
-
itemList?: ((props: {
|
|
62
|
-
rootStyle: StyleValue;
|
|
63
|
-
rootClass: string;
|
|
64
|
-
description: string;
|
|
65
|
-
itemList: ActionSheetItem[];
|
|
66
|
-
cancel: string;
|
|
67
|
-
showCancel: boolean;
|
|
68
|
-
visible: boolean;
|
|
69
|
-
overlayClosable: boolean;
|
|
70
|
-
beforeClose: ActionSheetBeforeClose;
|
|
71
|
-
duration: number;
|
|
72
|
-
}) => ActionSheetItem[]) | undefined;
|
|
73
|
-
cancel?: (string | ((props: {
|
|
74
|
-
rootStyle: StyleValue;
|
|
75
|
-
rootClass: string;
|
|
76
|
-
description: string;
|
|
77
|
-
itemList: ActionSheetItem[];
|
|
78
|
-
cancel: string;
|
|
79
|
-
showCancel: boolean;
|
|
80
|
-
visible: boolean;
|
|
81
|
-
overlayClosable: boolean;
|
|
82
|
-
beforeClose: ActionSheetBeforeClose;
|
|
83
|
-
duration: number;
|
|
84
|
-
}) => string)) | undefined;
|
|
85
|
-
showCancel?: (boolean | ((props: {
|
|
86
|
-
rootStyle: StyleValue;
|
|
87
|
-
rootClass: string;
|
|
88
|
-
description: string;
|
|
89
|
-
itemList: ActionSheetItem[];
|
|
90
|
-
cancel: string;
|
|
91
|
-
showCancel: boolean;
|
|
92
|
-
visible: boolean;
|
|
93
|
-
overlayClosable: boolean;
|
|
94
|
-
beforeClose: ActionSheetBeforeClose;
|
|
95
|
-
duration: number;
|
|
96
|
-
}) => boolean)) | undefined;
|
|
97
|
-
visible?: (boolean | ((props: {
|
|
98
|
-
rootStyle: StyleValue;
|
|
99
|
-
rootClass: string;
|
|
100
|
-
description: string;
|
|
101
|
-
itemList: ActionSheetItem[];
|
|
102
|
-
cancel: string;
|
|
103
|
-
showCancel: boolean;
|
|
104
|
-
visible: boolean;
|
|
105
|
-
overlayClosable: boolean;
|
|
106
|
-
beforeClose: ActionSheetBeforeClose;
|
|
107
|
-
duration: number;
|
|
108
|
-
}) => boolean)) | undefined;
|
|
109
|
-
overlayClosable?: (boolean | ((props: {
|
|
110
|
-
rootStyle: StyleValue;
|
|
111
|
-
rootClass: string;
|
|
112
|
-
description: string;
|
|
113
|
-
itemList: ActionSheetItem[];
|
|
114
|
-
cancel: string;
|
|
115
|
-
showCancel: boolean;
|
|
116
|
-
visible: boolean;
|
|
117
|
-
overlayClosable: boolean;
|
|
118
|
-
beforeClose: ActionSheetBeforeClose;
|
|
119
|
-
duration: number;
|
|
120
|
-
}) => boolean)) | undefined;
|
|
121
|
-
beforeClose?: (ActionSheetBeforeClose | ((props: {
|
|
122
|
-
rootStyle: StyleValue;
|
|
123
|
-
rootClass: string;
|
|
124
|
-
description: string;
|
|
125
|
-
itemList: ActionSheetItem[];
|
|
126
|
-
cancel: string;
|
|
127
|
-
showCancel: boolean;
|
|
128
|
-
visible: boolean;
|
|
129
|
-
overlayClosable: boolean;
|
|
130
|
-
beforeClose: ActionSheetBeforeClose;
|
|
131
|
-
duration: number;
|
|
132
|
-
}) => ((type: "close" | "cancel", loading: {
|
|
133
|
-
readonly cancel: boolean;
|
|
134
|
-
readonly select: boolean;
|
|
135
|
-
readonly close: boolean;
|
|
136
|
-
}) => any | Promise<any>) & ((type: "select", item: ActionSheetItem, index: number, loading: {
|
|
137
|
-
readonly cancel: boolean;
|
|
138
|
-
readonly select: boolean;
|
|
139
|
-
readonly close: boolean;
|
|
140
|
-
}) => any | Promise<any>))) | undefined;
|
|
141
|
-
duration?: (number | ((props: {
|
|
142
|
-
rootStyle: StyleValue;
|
|
143
|
-
rootClass: string;
|
|
144
|
-
description: string;
|
|
145
|
-
itemList: ActionSheetItem[];
|
|
146
|
-
cancel: string;
|
|
147
|
-
showCancel: boolean;
|
|
148
|
-
visible: boolean;
|
|
149
|
-
overlayClosable: boolean;
|
|
150
|
-
beforeClose: ActionSheetBeforeClose;
|
|
151
|
-
duration: number;
|
|
152
|
-
}) => number)) | undefined;
|
|
153
|
-
};
|
|
25
|
+
export declare const defaultActionSheetProps: () => DefaultProps<ActionSheetProps>;
|
|
154
26
|
export interface ActionSheetEmits extends TransitionHookEmits {
|
|
155
27
|
(e: 'update:visible', visible: boolean): void;
|
|
156
28
|
(e: 'close'): void;
|