vft 0.0.509 → 0.0.513
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/dist/index.css +1 -1
- package/es/components/affix/affix.vue2.js +2 -2
- package/es/components/alert/alert.vue2.js +1 -1
- package/es/components/autocomplete/autocomplete.vue.d.ts +2 -2
- package/es/components/autocomplete/autocomplete.vue2.js +1 -1
- package/es/components/autocomplete/index.d.ts +6 -6
- package/es/components/avatar/avatar.vue2.js +2 -2
- package/es/components/avatar-stack/avatar-stack.vue2.js +7 -7
- package/es/components/backtop/backtop.vue2.js +1 -1
- package/es/components/breadcrumb/breadcrumb-item.vue2.js +3 -3
- package/es/components/breadcrumb/breadcrumb.vue2.js +2 -2
- package/es/components/button/button-group.vue2.js +2 -2
- package/es/components/button/button.vue2.js +7 -7
- package/es/components/button/index.d.ts +9 -9
- package/es/components/button/use-button.js +3 -3
- package/es/components/card/card.vue2.js +6 -6
- package/es/components/carousel/carousel-item.vue2.js +3 -3
- package/es/components/carousel/carousel.vue2.js +1 -1
- package/es/components/cascader/cascader.vue2.js +202 -203
- package/es/components/cascader-panel/index.vue2.js +1 -1
- package/es/components/cascader-panel/menu.vue2.js +49 -50
- package/es/components/cascader-panel/node.vue2.js +8 -8
- package/es/components/check-tag/check-tag.vue2.js +2 -2
- package/es/components/checkbox/checkbox-button.vue2.js +13 -13
- package/es/components/checkbox/checkbox-group.vue2.js +3 -3
- package/es/components/checkbox/checkbox.vue2.js +1 -1
- package/es/components/clamp/clamp.vue2.js +2 -2
- package/es/components/clamp-toggle/clamp-toggle.vue2.js +18 -19
- package/es/components/clamp-tooltip/clamp-tooltip.vue2.js +6 -6
- package/es/components/col/col.vue2.js +2 -2
- package/es/components/collapse/collapse-item.vue2.js +2 -2
- package/es/components/collapse/collapse.vue2.js +2 -2
- package/es/components/collapse-transition/collapse-transition.vue2.js +2 -2
- package/es/components/color-picker/color-picker.vue2.js +133 -134
- package/es/components/color-picker/components/alpha-slider.vue2.js +2 -2
- package/es/components/color-picker/components/hue-slider.vue.js +2 -2
- package/es/components/color-picker/components/predefine.vue.js +3 -3
- package/es/components/color-picker/components/sv-panel.vue.js +2 -2
- package/es/components/config-provider/config-provider.vue.d.ts +0 -2
- package/es/components/config-provider/config-provider.vue2.js +4 -5
- package/es/components/config-provider/constants.d.ts +0 -1
- package/es/components/config-provider/constants.js +2 -3
- package/es/components/config-provider/hooks/use-global-config.js +30 -33
- package/es/components/config-provider/index.d.ts +0 -9
- package/es/components/config-provider/index.js +5 -6
- package/es/components/container/aside.vue2.js +2 -2
- package/es/components/container/container.vue2.js +2 -2
- package/es/components/container/footer.vue2.js +2 -2
- package/es/components/container/header.vue2.js +2 -2
- package/es/components/container/main.vue2.js +2 -2
- package/es/components/context-menu/context-menu.vue2.js +1 -1
- package/es/components/countdown/countdown.vue2.js +2 -2
- package/es/components/date-picker/composables/use-basic-date-table.d.ts +1 -1
- package/es/components/date-picker/composables/use-basic-date-table.js +123 -124
- package/es/components/date-picker/composables/use-month-range-header.js +14 -15
- package/es/components/date-picker/composables/use-panel-date-range.js +23 -24
- package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +6 -6
- package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +39 -40
- package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +40 -41
- package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +178 -179
- package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +224 -225
- package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +12 -12
- package/es/components/date-picker/date-picker-com/panel-year-range.vue2.js +12 -12
- package/es/components/date-picker/props/basic-date-table.js +3 -3
- package/es/components/date-picker/props/basic-month-table.js +3 -3
- package/es/components/date-picker/props/basic-year-table.js +3 -3
- package/es/components/date-time-select/date-time-select.vue2.js +36 -39
- package/es/components/descriptions/description.vue2.js +1 -1
- package/es/components/descriptions/descriptions-row.vue2.js +10 -10
- package/es/components/dialog/dialog-content.vue2.js +3 -3
- package/es/components/dialog/dialog.vue2.js +5 -5
- package/es/components/divider/divider.vue2.js +5 -5
- package/es/components/drawer/drawer.vue2.js +4 -4
- package/es/components/dropdown/dropdown-item-impl.vue2.js +3 -3
- package/es/components/dropdown/dropdown-item.vue2.js +2 -2
- package/es/components/dropdown/dropdown-menu.vue2.js +2 -2
- package/es/components/dropdown/dropdown.vue2.js +66 -67
- package/es/components/empty/empty.vue2.js +36 -37
- package/es/components/footer-layout/footer-layout.vue2.js +2 -2
- package/es/components/form/form-item.vue2.js +16 -16
- package/es/components/form/form.vue2.js +2 -2
- package/es/components/full-screen/full-screen.vue2.js +17 -18
- package/es/components/header-layout/header-layout.vue2.js +1 -1
- package/es/components/horizontal-menu/horizontal-menu.vue2.js +3 -3
- package/es/components/icon/icon.vue2.js +3 -3
- package/es/components/icon-text/icon-text.vue2.js +1 -1
- package/es/components/iframe-layout/iframe-layout.vue2.js +4 -4
- package/es/components/iframe-layout/iframe-page.vue2.js +2 -2
- package/es/components/image/image.vue2.js +59 -60
- package/es/components/image-viewer/image-viewer.vue2.js +44 -45
- package/es/components/index.d.ts +1 -0
- package/es/components/index.js +213 -211
- package/es/components/input/input.vue2.js +6 -6
- package/es/components/input-number/input-number.vue2.js +4 -4
- package/es/components/input-tag/input-tag.vue2.js +7 -7
- package/es/components/link/link.vue2.js +1 -1
- package/es/components/list-cell/list-cell.vue2.js +1 -1
- package/es/components/logo/logo.vue2.js +10 -10
- package/es/components/md-comment/md-comment.vue2.js +2 -2
- package/es/components/md-container/md-container.vue2.js +74 -75
- package/es/components/md-container/toc.js +36 -37
- package/es/components/menu/menu-collapse-transition.vue.js +2 -2
- package/es/components/menu/menu-item-group.vue2.js +7 -7
- package/es/components/menu/menu-item.vue2.js +1 -1
- package/es/components/message/message.vue2.js +3 -3
- package/es/components/message-box/index.d.ts +4 -0
- package/es/components/message-box/index.js +14 -0
- package/es/components/message-box/message-box.vue.d.ts +103 -0
- package/es/components/message-box/message-box.vue.js +4 -0
- package/es/components/message-box/message-box.vue2.js +358 -0
- package/es/components/message-box/method.d.ts +3 -0
- package/es/components/message-box/method.js +100 -0
- package/es/components/message-box/style/css.d.ts +2 -0
- package/es/components/message-box/style/css.js +3 -0
- package/es/components/message-box/style/index.d.ts +2 -0
- package/es/components/message-box/style/index.js +3 -0
- package/es/components/message-box/types.d.ts +202 -0
- package/es/components/modal/index.d.ts +1 -0
- package/es/components/modal/modal-footer-action.vue2.js +24 -25
- package/es/components/modal/modal.vue.d.ts +1 -0
- package/es/components/modal/modal.vue2.js +30 -28
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +16 -17
- package/es/components/multiple-tabs/tab-content.vue2.js +2 -2
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +53 -54
- package/es/components/notification/notification.vue2.js +1 -1
- package/es/components/overlay/overlay.vue2.js +1 -1
- package/es/components/page-wrapper/page-wrapper.vue2.js +2 -2
- package/es/components/pagination/components/jumper.vue2.js +28 -29
- package/es/components/pagination/components/next.vue2.js +4 -4
- package/es/components/pagination/components/pager.vue2.js +1 -1
- package/es/components/pagination/components/prev.vue2.js +4 -4
- package/es/components/pagination/components/sizes.vue2.js +20 -21
- package/es/components/pagination/components/total.vue2.js +10 -11
- package/es/components/popconfirm/index.d.ts +15 -15
- package/es/components/popconfirm/popconfirm.vue.d.ts +1 -1
- package/es/components/popconfirm/popconfirm.vue2.js +39 -40
- package/es/components/popover/popover.vue2.js +1 -1
- package/es/components/popper/arrow.vue2.js +2 -2
- package/es/components/popper/content.vue2.js +2 -2
- package/es/components/popper/trigger.vue2.js +4 -4
- package/es/components/progress/progress.vue2.js +1 -1
- package/es/components/progress-i/progress-i.vue2.js +2 -2
- package/es/components/qrcode/qrcode.vue2.js +1 -1
- package/es/components/radio/radio-button.vue2.js +2 -2
- package/es/components/radio/radio-group.vue2.js +3 -3
- package/es/components/radio/radio.vue2.js +2 -2
- package/es/components/rate/rate.vue2.js +6 -6
- package/es/components/router-view-content/router-view-content.vue2.js +7 -7
- package/es/components/roving-focus-group/roving-focus-group.vue2.js +2 -2
- package/es/components/roving-focus-group/roving-focus-item.vue2.js +2 -2
- package/es/components/row/row.vue2.js +2 -2
- package/es/components/scrollbar/bar.vue2.js +2 -2
- package/es/components/scrollbar/scrollbar.vue2.js +7 -7
- package/es/components/scrollbar/thumb.vue2.js +2 -2
- package/es/components/search/search.vue2.js +50 -51
- package/es/components/segmented/segmented.vue2.js +7 -7
- package/es/components/select/group-item.vue.js +2 -2
- package/es/components/select/index.d.ts +4 -4
- package/es/components/select/option-item.vue.js +2 -2
- package/es/components/select/select.vue.d.ts +4 -4
- package/es/components/select/select.vue.js +1 -1
- package/es/components/select/useSelect.d.ts +4 -4
- package/es/components/select/useSelect.js +231 -232
- package/es/components/skeleton/skeleton-item.vue2.js +2 -2
- package/es/components/skeleton/skeleton.vue2.js +8 -8
- package/es/components/slider/button.vue2.js +2 -2
- package/es/components/slider/slider.vue2.js +1 -1
- package/es/components/space/space.js +1 -1
- package/es/components/statistic/statistic.vue2.js +17 -17
- package/es/components/steps/item.vue2.js +11 -11
- package/es/components/steps/steps.vue2.js +2 -2
- package/es/components/super-form/super-form-action.vue2.js +47 -48
- package/es/components/super-form/super-form-item.vue2.js +204 -206
- package/es/components/super-form/super-form.vue2.js +7 -7
- package/es/components/super-form/use/helper.d.ts +1 -1
- package/es/components/super-form/use/helper.js +63 -63
- package/es/components/super-form/use/use-form.js +8 -8
- package/es/components/switch/switch.vue2.js +1 -1
- package/es/components/table/field.js +111 -130
- package/es/components/table/table.vue2.js +128 -133
- package/es/components/table/use/use-columns.js +26 -29
- package/es/components/table/use/use-data-source.js +59 -60
- package/es/components/tabs/tab-bar.vue2.js +2 -2
- package/es/components/tabs/tab-pane.vue2.js +6 -6
- package/es/components/teleport/teleport.vue2.js +2 -2
- package/es/components/time-picker/common/picker-range-trigger.vue2.js +2 -2
- package/es/components/time-picker/common/picker.vue2.js +8 -8
- package/es/components/time-picker/time-picker-com/basic-time-spinner.vue2.js +1 -1
- package/es/components/time-picker/time-picker-com/panel-time-pick.vue2.js +65 -66
- package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +133 -134
- package/es/components/time-select/time-select.vue2.js +3 -3
- package/es/components/timeline/timeline-item.vue2.js +1 -1
- package/es/components/tooltip/content.vue2.js +6 -6
- package/es/components/tooltip/tooltip.vue2.js +1 -1
- package/es/components/tooltip/trigger.vue2.js +2 -2
- package/es/components/transfer/transfer-panel.vue2.js +58 -59
- package/es/components/transfer/transfer.vue2.js +69 -70
- package/es/components/tree/tree-node.vue.js +1 -1
- package/es/components/tree/tree.vue2.js +59 -60
- package/es/components/upload/upload-content.vue2.js +47 -48
- package/es/components/upload/upload-dragger.vue2.js +2 -2
- package/es/components/upload/upload-list.vue2.js +45 -46
- package/es/components/upload/upload.vue2.js +98 -99
- package/es/components/verify-code/verify-code.vue2.js +2 -2
- package/es/components/watermark/watermark.vue2.js +2 -2
- package/es/hooks/use-id/index.js +2 -2
- package/es/hooks/use-z-index/index.js +3 -3
- package/es/index.d.ts +0 -1
- package/es/index.js +39 -42
- package/es/package.json.d.ts +1 -1
- package/es/package.json.js +1 -1
- package/es/plugin.js +5 -3
- package/es/utils/helper.js +2 -2
- package/es/utils/ns-cover.js +1 -1
- package/es/utils/vue/vnode.js +3 -3
- package/lib/components/autocomplete/autocomplete.vue.d.ts +2 -2
- package/lib/components/autocomplete/index.d.ts +6 -6
- package/lib/components/button/index.d.ts +9 -9
- package/lib/components/button/use-button.cjs +1 -1
- package/lib/components/cascader/cascader.vue2.cjs +1 -1
- package/lib/components/cascader-panel/menu.vue2.cjs +4 -4
- package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
- package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
- package/lib/components/config-provider/config-provider.vue.d.ts +0 -2
- package/lib/components/config-provider/config-provider.vue2.cjs +1 -1
- package/lib/components/config-provider/constants.cjs +1 -1
- package/lib/components/config-provider/constants.d.ts +0 -1
- package/lib/components/config-provider/hooks/use-global-config.cjs +1 -1
- package/lib/components/config-provider/index.cjs +1 -1
- package/lib/components/config-provider/index.d.ts +0 -9
- package/lib/components/date-picker/composables/use-basic-date-table.cjs +1 -1
- package/lib/components/date-picker/composables/use-basic-date-table.d.ts +1 -1
- package/lib/components/date-picker/composables/use-month-range-header.cjs +1 -1
- package/lib/components/date-picker/composables/use-panel-date-range.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
- package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
- package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
- package/lib/components/empty/empty.vue2.cjs +1 -1
- package/lib/components/full-screen/full-screen.vue2.cjs +1 -1
- package/lib/components/image/image.vue2.cjs +1 -1
- package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
- package/lib/components/index.cjs +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/input/input.vue2.cjs +1 -1
- package/lib/components/md-container/md-container.vue2.cjs +1 -1
- package/lib/components/md-container/toc.cjs +1 -1
- package/lib/components/message-box/index.cjs +1 -0
- package/lib/components/message-box/index.d.ts +4 -0
- package/lib/components/message-box/message-box.vue.cjs +1 -0
- package/lib/components/message-box/message-box.vue.d.ts +103 -0
- package/lib/components/message-box/message-box.vue2.cjs +1 -0
- package/lib/components/message-box/method.cjs +1 -0
- package/lib/components/message-box/method.d.ts +3 -0
- package/lib/components/message-box/style/css.cjs +1 -0
- package/lib/components/message-box/style/css.d.ts +2 -0
- package/lib/components/message-box/style/index.cjs +1 -0
- package/lib/components/message-box/style/index.d.ts +2 -0
- package/lib/components/message-box/types.d.ts +202 -0
- package/lib/components/modal/index.d.ts +1 -0
- package/lib/components/modal/modal-footer-action.vue2.cjs +1 -1
- package/lib/components/modal/modal.vue.d.ts +1 -0
- package/lib/components/modal/modal.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/components/pagination/components/jumper.vue2.cjs +1 -1
- package/lib/components/pagination/components/sizes.vue2.cjs +1 -1
- package/lib/components/pagination/components/total.vue2.cjs +1 -1
- package/lib/components/popconfirm/index.d.ts +15 -15
- package/lib/components/popconfirm/popconfirm.vue.d.ts +1 -1
- package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
- package/lib/components/search/search.vue2.cjs +1 -1
- package/lib/components/select/index.d.ts +4 -4
- package/lib/components/select/select.vue.d.ts +4 -4
- package/lib/components/select/useSelect.cjs +1 -1
- package/lib/components/select/useSelect.d.ts +4 -4
- package/lib/components/super-form/super-form-action.vue2.cjs +1 -1
- package/lib/components/super-form/super-form-item.vue2.cjs +1 -1
- package/lib/components/super-form/use/helper.cjs +1 -1
- package/lib/components/super-form/use/helper.d.ts +1 -1
- package/lib/components/super-form/use/use-form.cjs +1 -1
- package/lib/components/table/field.cjs +1 -1
- package/lib/components/table/table.vue2.cjs +1 -1
- package/lib/components/table/use/use-columns.cjs +1 -1
- package/lib/components/table/use/use-data-source.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-pick.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
- package/lib/components/transfer/transfer-panel.vue2.cjs +1 -1
- package/lib/components/transfer/transfer.vue2.cjs +1 -1
- package/lib/components/tree/tree.vue2.cjs +1 -1
- package/lib/components/upload/upload-content.vue2.cjs +1 -1
- package/lib/components/upload/upload-list.vue2.cjs +1 -1
- package/lib/components/upload/upload.vue2.cjs +1 -1
- package/lib/index.cjs +1 -1
- package/lib/index.d.ts +0 -1
- package/lib/package.json.cjs +1 -1
- package/lib/package.json.d.ts +1 -1
- package/lib/plugin.cjs +1 -1
- package/package.json +3 -3
- package/theme-style/index.css +1 -1
- package/theme-style/src/message-box.scss +2 -2
- package/theme-style/src/table.scss +6 -0
- package/theme-style/vft-message-box.css +1 -1
- package/theme-style/vft-table.css +1 -1
- package/web-types.json +1 -1
- package/es/locale/index.d.ts +0 -26
- package/es/locale/index.js +0 -10
- package/es/locale/lang/en.d.ts +0 -183
- package/es/locale/lang/en.js +0 -241
- package/es/locale/lang/zh-cn.d.ts +0 -183
- package/es/locale/lang/zh-cn.js +0 -241
- package/es/locale/lang/zh-tw.d.ts +0 -183
- package/es/locale/lang/zh-tw.js +0 -241
- package/es/locale/use-locale.d.ts +0 -17
- package/es/locale/use-locale.js +0 -56
- package/lib/locale/index.cjs +0 -1
- package/lib/locale/index.d.ts +0 -26
- package/lib/locale/lang/en.cjs +0 -1
- package/lib/locale/lang/en.d.ts +0 -183
- package/lib/locale/lang/zh-cn.cjs +0 -1
- package/lib/locale/lang/zh-cn.d.ts +0 -183
- package/lib/locale/lang/zh-tw.cjs +0 -1
- package/lib/locale/lang/zh-tw.d.ts +0 -183
- package/lib/locale/use-locale.cjs +0 -1
- package/lib/locale/use-locale.d.ts +0 -17
- /package/es/{locale/index.d.js → components/message-box/types.js} +0 -0
- /package/lib/{locale/index.d.cjs → components/message-box/types.cjs} +0 -0
|
@@ -1,112 +1,111 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { cloneDeep as
|
|
3
|
-
import { useResizeObserver as
|
|
4
|
-
import { focusNode as
|
|
5
|
-
import { isPromise as
|
|
6
|
-
import { debugWarn as
|
|
1
|
+
import { defineComponent as Se, useAttrs as Ye, ref as c, computed as i, unref as s, watch as x, nextTick as N, onMounted as Ze, openBlock as r, createBlock as E, withCtx as v, createElementBlock as m, withModifiers as F, normalizeClass as d, renderSlot as V, createCommentVNode as P, withDirectives as q, createVNode as te, vShow as Te, Fragment as le, renderList as se, createElementVNode as z, toDisplayString as U, normalizeStyle as _e, createSlots as et, withKeys as tt, vModelText as lt } from "vue";
|
|
2
|
+
import { cloneDeep as st, debounce as ot } from "lodash-es";
|
|
3
|
+
import { useResizeObserver as at, useCssVar as nt } from "@vueuse/core";
|
|
4
|
+
import { focusNode as rt, getSibling as it } from "../../utils/dom/aria.js";
|
|
5
|
+
import { isPromise as ut, isClient as ct } from "@vft/utils";
|
|
6
|
+
import { debugWarn as pt } from "../../utils/error.js";
|
|
7
7
|
import "../config-provider/hooks/use-global-config.js";
|
|
8
8
|
import { EVENT_CODE as h } from "../../constants/aria.js";
|
|
9
|
-
import { UPDATE_MODEL_EVENT as
|
|
9
|
+
import { UPDATE_MODEL_EVENT as dt, CHANGE_EVENT as ft } from "../../constants/event.js";
|
|
10
10
|
import "../form/index.js";
|
|
11
|
-
import { VftCascaderPanel as
|
|
12
|
-
import { VftInput as
|
|
13
|
-
import { VftTooltip as
|
|
14
|
-
import { VftScrollbar as
|
|
15
|
-
import { VftTag as
|
|
11
|
+
import { VftCascaderPanel as vt } from "../cascader-panel/index.js";
|
|
12
|
+
import { VftInput as mt } from "../input/index.js";
|
|
13
|
+
import { VftTooltip as Ee } from "../tooltip/index.js";
|
|
14
|
+
import { VftScrollbar as we } from "../scrollbar/index.js";
|
|
15
|
+
import { VftTag as $e } from "../tag/index.js";
|
|
16
16
|
import { VftIcon as oe } from "../icon/index.js";
|
|
17
|
-
import { ClickOutside as
|
|
18
|
-
import { useNamespace as
|
|
17
|
+
import { ClickOutside as gt } from "@vft/directives";
|
|
18
|
+
import { useNamespace as Ve } from "../../hooks/use-namespace/index.js";
|
|
19
19
|
import "../../hooks/use-model-toggle/index.js";
|
|
20
20
|
import "@popperjs/core";
|
|
21
21
|
import "../../hooks/use-z-index/index.js";
|
|
22
|
-
import { useComposition as
|
|
23
|
-
import { useEmptyValues as
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
const a = Pe, C = Ie, xe = {
|
|
22
|
+
import { useComposition as ht } from "../../hooks/use-composition/index.js";
|
|
23
|
+
import { useEmptyValues as kt } from "../../hooks/use-empty-values/index.js";
|
|
24
|
+
import { cascaderEmits as Ct, cascaderProps as yt } from "./cascader.js";
|
|
25
|
+
import { useFormItem as bt } from "../form/hooks/use-form-item.js";
|
|
26
|
+
import { useFormSize as Tt } from "../form/hooks/use-form-common-props.js";
|
|
27
|
+
const Et = { key: 0 }, wt = ["placeholder"], $t = ["onClick"], Vt = "VftCascader", St = Se({
|
|
28
|
+
name: Vt
|
|
29
|
+
}), el = /* @__PURE__ */ Se({
|
|
30
|
+
...St,
|
|
31
|
+
props: yt,
|
|
32
|
+
emits: Ct,
|
|
33
|
+
setup(Ne, { expose: Pe, emit: De }) {
|
|
34
|
+
const a = Ne, C = De, Ie = {
|
|
36
35
|
modifiers: [
|
|
37
36
|
{
|
|
38
37
|
name: "arrowPosition",
|
|
39
38
|
enabled: !0,
|
|
40
39
|
phase: "main",
|
|
41
40
|
fn: ({ state: e }) => {
|
|
42
|
-
const { modifiersData: t, placement:
|
|
43
|
-
["right", "left", "bottom", "top"].includes(
|
|
41
|
+
const { modifiersData: t, placement: l } = e;
|
|
42
|
+
["right", "left", "bottom", "top"].includes(l) || t.arrow && (t.arrow.x = 35);
|
|
44
43
|
},
|
|
45
44
|
requires: ["arrow"]
|
|
46
45
|
}
|
|
47
46
|
]
|
|
48
|
-
}, ae =
|
|
47
|
+
}, ae = Ye();
|
|
49
48
|
let D = 0, G = 0;
|
|
50
|
-
const n =
|
|
49
|
+
const n = Ve("cascader"), j = Ve("input"), { form: xe, formItem: ne } = bt(), { valueOnClear: Fe } = kt(a), { isComposing: re, handleComposition: k } = ht({
|
|
51
50
|
afterComposition(e) {
|
|
52
51
|
const t = e.target?.value;
|
|
53
52
|
ee(t);
|
|
54
53
|
}
|
|
55
|
-
}),
|
|
56
|
-
() => w.value || $.value.length > 0 ||
|
|
57
|
-
),
|
|
58
|
-
() =>
|
|
59
|
-
), T = i(() => !!a.props.multiple),
|
|
60
|
-
() => T.value ? w.value :
|
|
61
|
-
),
|
|
54
|
+
}), A = c(null), S = c(null), ie = c(null), f = c(null), K = c(null), g = c(!1), ue = c(!1), y = c(!1), J = c(!1), B = c(""), w = c(""), $ = c([]), H = c([]), Q = c([]), ze = i(() => ae.style), b = i(() => a.disabled || xe?.disabled), ce = i(() => a.placeholder ?? "请选择"), Ae = i(
|
|
55
|
+
() => w.value || $.value.length > 0 || re.value ? "" : ce.value
|
|
56
|
+
), M = Tt(), pe = i(
|
|
57
|
+
() => M.value === "small" ? "small" : "default"
|
|
58
|
+
), T = i(() => !!a.props.multiple), de = i(() => !a.filterable || T.value), fe = i(
|
|
59
|
+
() => T.value ? w.value : B.value
|
|
60
|
+
), ve = [], O = i(() => {
|
|
62
61
|
const e = f.value;
|
|
63
62
|
if (!e)
|
|
64
|
-
return
|
|
65
|
-
const t = e.checkedNodes,
|
|
66
|
-
return Array.isArray(
|
|
67
|
-
}),
|
|
68
|
-
const { showAllLevels: e, separator: t } = a,
|
|
69
|
-
return
|
|
70
|
-
}),
|
|
63
|
+
return ve;
|
|
64
|
+
const t = e.checkedNodes, l = s(t);
|
|
65
|
+
return Array.isArray(l) && l.length ? l : ve;
|
|
66
|
+
}), Ke = i(() => !a.clearable || b.value || y.value ? !1 : !!O.value.length), L = i(() => {
|
|
67
|
+
const { showAllLevels: e, separator: t } = a, l = O.value;
|
|
68
|
+
return l.length ? T.value ? "" : l[0].calcText(e, t) : "";
|
|
69
|
+
}), Be = i(() => ne?.validateState || ""), me = i({
|
|
71
70
|
get() {
|
|
72
|
-
return
|
|
71
|
+
return st(a.modelValue);
|
|
73
72
|
},
|
|
74
73
|
set(e) {
|
|
75
|
-
const t = e ??
|
|
76
|
-
C(
|
|
74
|
+
const t = e ?? Fe.value;
|
|
75
|
+
C(dt, t), C(ft, t), a.validateEvent && ne?.validate("change").catch((l) => pt(l));
|
|
77
76
|
}
|
|
78
|
-
}),
|
|
77
|
+
}), He = i(() => [
|
|
79
78
|
n.b(),
|
|
80
|
-
n.m(
|
|
79
|
+
n.m(M.value),
|
|
81
80
|
n.is("disabled", b.value),
|
|
82
81
|
ae.class
|
|
83
|
-
]),
|
|
82
|
+
]), Me = i(() => [j.e("icon"), n.is("reverse", g.value)]), Oe = i(() => n.is("focus", g.value || J.value)), ge = i(() => A.value?.popperRef?.contentRef), p = (e) => {
|
|
84
83
|
b.value || (e = e ?? !g.value, e !== g.value && (g.value = e, S.value?.input?.setAttribute("aria-expanded", `${e}`), e ? (I(), N(f.value?.scrollToExpandingNode)) : a.filterable && _(), C("visibleChange", e)));
|
|
85
84
|
}, I = () => {
|
|
86
85
|
N(() => {
|
|
87
|
-
|
|
86
|
+
A.value?.updatePopper();
|
|
88
87
|
});
|
|
89
88
|
}, X = () => {
|
|
90
89
|
y.value = !1;
|
|
91
90
|
}, Y = (e) => {
|
|
92
|
-
const { showAllLevels: t, separator:
|
|
91
|
+
const { showAllLevels: t, separator: l } = a;
|
|
93
92
|
return {
|
|
94
93
|
node: e,
|
|
95
94
|
key: e.uid,
|
|
96
|
-
text: e.calcText(t,
|
|
95
|
+
text: e.calcText(t, l),
|
|
97
96
|
hitState: !1,
|
|
98
97
|
closable: !b.value && !e.isDisabled,
|
|
99
98
|
isCollapseTag: !1
|
|
100
99
|
};
|
|
101
|
-
},
|
|
100
|
+
}, R = (e) => {
|
|
102
101
|
const t = e.node;
|
|
103
102
|
t.doCheck(!1), f.value?.calculateCheckedValue(), C("removeTag", t.valueByOption);
|
|
104
|
-
},
|
|
103
|
+
}, Le = () => {
|
|
105
104
|
switch (a.showCheckedStrategy) {
|
|
106
105
|
case "child":
|
|
107
|
-
return
|
|
106
|
+
return O.value;
|
|
108
107
|
case "parent": {
|
|
109
|
-
const e =
|
|
108
|
+
const e = ke(!1), t = e.map((o) => o.value);
|
|
110
109
|
return e.filter(
|
|
111
110
|
(o) => !o.parent || !t.includes(o.parent.value)
|
|
112
111
|
);
|
|
@@ -114,39 +113,39 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
114
113
|
default:
|
|
115
114
|
return [];
|
|
116
115
|
}
|
|
117
|
-
},
|
|
116
|
+
}, Re = () => {
|
|
118
117
|
if (!T.value) return;
|
|
119
|
-
const e =
|
|
120
|
-
if (e.forEach((o) =>
|
|
121
|
-
e.slice(0, a.maxCollapseTags).forEach((
|
|
118
|
+
const e = Le(), t = [], l = [];
|
|
119
|
+
if (e.forEach((o) => l.push(Y(o))), H.value = l, e.length) {
|
|
120
|
+
e.slice(0, a.maxCollapseTags).forEach((W) => t.push(Y(W)));
|
|
122
121
|
const o = e.slice(a.maxCollapseTags), u = o.length;
|
|
123
122
|
u && (a.collapseTags ? t.push({
|
|
124
123
|
key: -1,
|
|
125
124
|
text: `+ ${u}`,
|
|
126
125
|
closable: !1,
|
|
127
126
|
isCollapseTag: !0
|
|
128
|
-
}) : o.forEach((
|
|
127
|
+
}) : o.forEach((W) => t.push(Y(W))));
|
|
129
128
|
}
|
|
130
129
|
$.value = t;
|
|
131
|
-
},
|
|
132
|
-
const { filterMethod: e, showAllLevels: t, separator:
|
|
130
|
+
}, he = () => {
|
|
131
|
+
const { filterMethod: e, showAllLevels: t, separator: l } = a, o = f.value?.getFlattedNodes(!a.props.checkStrictly)?.filter((u) => u.isDisabled ? !1 : (u.calcText(t, l), e(u, fe.value)));
|
|
133
132
|
T.value && ($.value.forEach((u) => {
|
|
134
133
|
u.hitState = !1;
|
|
135
|
-
}),
|
|
134
|
+
}), H.value.forEach((u) => {
|
|
136
135
|
u.hitState = !1;
|
|
137
136
|
})), y.value = !0, Q.value = o, I();
|
|
138
|
-
},
|
|
137
|
+
}, We = () => {
|
|
139
138
|
let e;
|
|
140
|
-
y.value &&
|
|
139
|
+
y.value && K.value ? e = K.value.$el.querySelector(
|
|
141
140
|
`.${n.e("suggestion-item")}`
|
|
142
141
|
) : e = f.value?.$el.querySelector(
|
|
143
142
|
`.${n.b("node")}[tabindex="-1"]`
|
|
144
143
|
), e && (e.focus(), !y.value && e.click());
|
|
145
144
|
}, Z = () => {
|
|
146
|
-
const e = S.value?.input, t =
|
|
147
|
-
if (!(!
|
|
148
|
-
if (
|
|
149
|
-
const o =
|
|
145
|
+
const e = S.value?.input, t = ie.value, l = K.value?.$el;
|
|
146
|
+
if (!(!ct || !e)) {
|
|
147
|
+
if (l) {
|
|
148
|
+
const o = l.querySelector(
|
|
150
149
|
`.${n.e("suggestion-list")}`
|
|
151
150
|
);
|
|
152
151
|
o.style.minWidth = `${e.offsetWidth}px`;
|
|
@@ -156,17 +155,17 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
156
155
|
e.style.height = u, I();
|
|
157
156
|
}
|
|
158
157
|
}
|
|
159
|
-
},
|
|
158
|
+
}, ke = (e) => f.value?.getCheckedNodes(e), qe = (e) => {
|
|
160
159
|
I(), C("expandChange", e);
|
|
161
|
-
},
|
|
162
|
-
if (!
|
|
160
|
+
}, Ue = (e) => {
|
|
161
|
+
if (!re.value)
|
|
163
162
|
switch (e.code) {
|
|
164
163
|
case h.enter:
|
|
165
164
|
case h.numpadEnter:
|
|
166
165
|
p();
|
|
167
166
|
break;
|
|
168
167
|
case h.down:
|
|
169
|
-
p(!0), N(
|
|
168
|
+
p(!0), N(We), e.preventDefault();
|
|
170
169
|
break;
|
|
171
170
|
case h.esc:
|
|
172
171
|
g.value === !0 && (e.preventDefault(), e.stopPropagation(), p(!1));
|
|
@@ -175,23 +174,23 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
175
174
|
p(!1);
|
|
176
175
|
break;
|
|
177
176
|
}
|
|
178
|
-
},
|
|
177
|
+
}, Ge = () => {
|
|
179
178
|
f.value?.clearCheckedNodes(), !g.value && a.filterable && _(), p(!1), C("clear");
|
|
180
179
|
}, _ = () => {
|
|
181
|
-
const { value: e } =
|
|
182
|
-
|
|
183
|
-
},
|
|
180
|
+
const { value: e } = L;
|
|
181
|
+
B.value = e, w.value = e;
|
|
182
|
+
}, je = (e) => {
|
|
184
183
|
const { checked: t } = e;
|
|
185
184
|
T.value ? f.value?.handleCheckChange(e, !t, !1) : (!t && f.value?.handleCheckChange(e, !0, !1), p(!1));
|
|
186
|
-
},
|
|
187
|
-
const t = e.target, { code:
|
|
188
|
-
switch (
|
|
185
|
+
}, Je = (e) => {
|
|
186
|
+
const t = e.target, { code: l } = e;
|
|
187
|
+
switch (l) {
|
|
189
188
|
case h.up:
|
|
190
189
|
case h.down: {
|
|
191
190
|
e.preventDefault();
|
|
192
|
-
const o =
|
|
193
|
-
|
|
194
|
-
|
|
191
|
+
const o = l === h.up ? -1 : 1;
|
|
192
|
+
rt(
|
|
193
|
+
it(
|
|
195
194
|
t,
|
|
196
195
|
o,
|
|
197
196
|
`.${n.e("suggestion-item")}[tabindex="-1"]`
|
|
@@ -204,44 +203,44 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
204
203
|
t.click();
|
|
205
204
|
break;
|
|
206
205
|
}
|
|
207
|
-
},
|
|
206
|
+
}, Qe = () => {
|
|
208
207
|
const e = $.value, t = e[e.length - 1];
|
|
209
|
-
G = w.value ? 0 : G + 1, !(!t || !G || a.collapseTags && e.length > 1) && (t.hitState ?
|
|
210
|
-
},
|
|
208
|
+
G = w.value ? 0 : G + 1, !(!t || !G || a.collapseTags && e.length > 1) && (t.hitState ? R(t) : t.hitState = !0);
|
|
209
|
+
}, Ce = (e) => {
|
|
211
210
|
J.value = !0, C("focus", e);
|
|
212
|
-
},
|
|
211
|
+
}, ye = (e) => {
|
|
213
212
|
N(() => {
|
|
214
|
-
const t = S.value?.$el,
|
|
215
|
-
t?.contains(
|
|
213
|
+
const t = S.value?.$el, l = document.activeElement;
|
|
214
|
+
t?.contains(l) || A.value?.isFocusInsideContent?.(e) || (J.value = !1);
|
|
216
215
|
}), C("blur", e);
|
|
217
|
-
},
|
|
218
|
-
const { value: e } =
|
|
216
|
+
}, Xe = ot(() => {
|
|
217
|
+
const { value: e } = fe;
|
|
219
218
|
if (!e) return;
|
|
220
219
|
const t = a.beforeFilter(e);
|
|
221
|
-
|
|
222
|
-
}) : t !== !1 ?
|
|
220
|
+
ut(t) ? t.then(he).catch(() => {
|
|
221
|
+
}) : t !== !1 ? he() : X();
|
|
223
222
|
}, a.debounce), ee = (e, t) => {
|
|
224
|
-
!g.value && p(!0), !t?.isComposing && (e ?
|
|
225
|
-
},
|
|
226
|
-
|
|
223
|
+
!g.value && p(!0), !t?.isComposing && (e ? Xe() : X());
|
|
224
|
+
}, be = (e) => Number.parseFloat(
|
|
225
|
+
nt(j.cssVarName("input-height"), e).value
|
|
227
226
|
) - 2;
|
|
228
227
|
return x(y, I), x(
|
|
229
|
-
[
|
|
230
|
-
|
|
228
|
+
[O, b, () => a.collapseTags],
|
|
229
|
+
Re
|
|
231
230
|
), x($, () => {
|
|
232
231
|
N(() => Z());
|
|
233
|
-
}), x(
|
|
232
|
+
}), x(M, async () => {
|
|
234
233
|
await N();
|
|
235
234
|
const e = S.value.input;
|
|
236
|
-
D =
|
|
237
|
-
}), x(
|
|
238
|
-
const e = S.value.input, t =
|
|
239
|
-
D = e.offsetHeight || t,
|
|
240
|
-
}),
|
|
235
|
+
D = be(e) || D, Z();
|
|
236
|
+
}), x(L, _, { immediate: !0 }), Ze(() => {
|
|
237
|
+
const e = S.value.input, t = be(e);
|
|
238
|
+
D = e.offsetHeight || t, at(e, Z);
|
|
239
|
+
}), Pe({
|
|
241
240
|
/**
|
|
242
241
|
* @description get an array of currently selected node,(leafOnly) whether only return the leaf checked nodes, default is `false`
|
|
243
242
|
*/
|
|
244
|
-
getCheckedNodes:
|
|
243
|
+
getCheckedNodes: ke,
|
|
245
244
|
/**
|
|
246
245
|
* @description cascader panel ref
|
|
247
246
|
*/
|
|
@@ -253,67 +252,67 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
253
252
|
/**
|
|
254
253
|
* @description cascader content ref
|
|
255
254
|
*/
|
|
256
|
-
contentRef:
|
|
255
|
+
contentRef: ge,
|
|
257
256
|
/**
|
|
258
257
|
* @description selected content text
|
|
259
258
|
*/
|
|
260
|
-
presentText:
|
|
261
|
-
}), (e, t) => (r(), E(
|
|
259
|
+
presentText: L
|
|
260
|
+
}), (e, t) => (r(), E(s(Ee), {
|
|
262
261
|
ref_key: "tooltipRef",
|
|
263
|
-
ref:
|
|
262
|
+
ref: A,
|
|
264
263
|
visible: g.value,
|
|
265
264
|
teleported: e.teleported,
|
|
266
|
-
"popper-class": [
|
|
267
|
-
"popper-options":
|
|
265
|
+
"popper-class": [s(n).e("dropdown"), e.popperClass],
|
|
266
|
+
"popper-options": Ie,
|
|
268
267
|
"fallback-placements": e.fallbackPlacements,
|
|
269
268
|
"stop-popper-mouse-event": !1,
|
|
270
269
|
"gpu-acceleration": !1,
|
|
271
270
|
placement: e.placement,
|
|
272
|
-
transition: `${
|
|
271
|
+
transition: `${s(n).namespace.value}-zoom-in-top`,
|
|
273
272
|
effect: e.effect,
|
|
274
273
|
pure: "",
|
|
275
274
|
persistent: e.persistent,
|
|
276
275
|
onHide: X
|
|
277
276
|
}, {
|
|
278
277
|
default: v(() => [
|
|
279
|
-
|
|
280
|
-
class: d(
|
|
281
|
-
style:
|
|
282
|
-
onClick: t[8] || (t[8] = () => p(
|
|
283
|
-
onKeydown:
|
|
284
|
-
onMouseenter: t[9] || (t[9] = (
|
|
285
|
-
onMouseleave: t[10] || (t[10] = (
|
|
278
|
+
q((r(), m("div", {
|
|
279
|
+
class: d(He.value),
|
|
280
|
+
style: _e(ze.value),
|
|
281
|
+
onClick: t[8] || (t[8] = () => p(de.value ? void 0 : !0)),
|
|
282
|
+
onKeydown: Ue,
|
|
283
|
+
onMouseenter: t[9] || (t[9] = (l) => ue.value = !0),
|
|
284
|
+
onMouseleave: t[10] || (t[10] = (l) => ue.value = !1)
|
|
286
285
|
}, [
|
|
287
|
-
te(
|
|
286
|
+
te(s(mt), {
|
|
288
287
|
ref_key: "input",
|
|
289
288
|
ref: S,
|
|
290
|
-
modelValue:
|
|
291
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
292
|
-
placeholder:
|
|
293
|
-
readonly:
|
|
289
|
+
modelValue: B.value,
|
|
290
|
+
"onUpdate:modelValue": t[1] || (t[1] = (l) => B.value = l),
|
|
291
|
+
placeholder: Ae.value,
|
|
292
|
+
readonly: de.value,
|
|
294
293
|
disabled: b.value,
|
|
295
294
|
"validate-event": !1,
|
|
296
|
-
size:
|
|
297
|
-
class: d(
|
|
295
|
+
size: s(M),
|
|
296
|
+
class: d(Oe.value),
|
|
298
297
|
tabindex: T.value && e.filterable && !b.value ? -1 : void 0,
|
|
299
|
-
onCompositionstart:
|
|
300
|
-
onCompositionupdate:
|
|
301
|
-
onCompositionend:
|
|
302
|
-
onFocus:
|
|
303
|
-
onBlur:
|
|
298
|
+
onCompositionstart: s(k),
|
|
299
|
+
onCompositionupdate: s(k),
|
|
300
|
+
onCompositionend: s(k),
|
|
301
|
+
onFocus: Ce,
|
|
302
|
+
onBlur: ye,
|
|
304
303
|
onInput: ee
|
|
305
|
-
},
|
|
304
|
+
}, et({
|
|
306
305
|
suffix: v(() => [
|
|
307
|
-
|
|
306
|
+
Ke.value ? (r(), E(s(oe), {
|
|
308
307
|
key: "clear",
|
|
309
308
|
icon: "icon-circle-close",
|
|
310
|
-
class: d(["icon-circle-close", [
|
|
311
|
-
onClick: F(
|
|
312
|
-
}, null, 8, ["class"])) : (r(), E(
|
|
309
|
+
class: d(["icon-circle-close", [s(j).e("icon")]]),
|
|
310
|
+
onClick: F(Ge, ["stop"])
|
|
311
|
+
}, null, 8, ["class"])) : (r(), E(s(oe), {
|
|
313
312
|
icon: "icon-arrow-down",
|
|
314
313
|
key: "arrow-down",
|
|
315
|
-
class: d(
|
|
316
|
-
onClick: t[0] || (t[0] = F((
|
|
314
|
+
class: d(Me.value),
|
|
315
|
+
onClick: t[0] || (t[0] = F((l) => p(), ["stop"]))
|
|
317
316
|
}, null, 8, ["class"]))
|
|
318
317
|
]),
|
|
319
318
|
_: 2
|
|
@@ -329,28 +328,28 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
329
328
|
T.value ? (r(), m("div", {
|
|
330
329
|
key: 0,
|
|
331
330
|
ref_key: "tagWrapper",
|
|
332
|
-
ref:
|
|
331
|
+
ref: ie,
|
|
333
332
|
class: d([
|
|
334
|
-
|
|
335
|
-
|
|
333
|
+
s(n).e("tags"),
|
|
334
|
+
s(n).is("validate", !!Be.value)
|
|
336
335
|
])
|
|
337
336
|
}, [
|
|
338
337
|
V(e.$slots, "tag", {
|
|
339
|
-
data:
|
|
340
|
-
deleteTag:
|
|
338
|
+
data: H.value,
|
|
339
|
+
deleteTag: R
|
|
341
340
|
}, () => [
|
|
342
|
-
(r(!0), m(
|
|
343
|
-
key:
|
|
341
|
+
(r(!0), m(le, null, se($.value, (l) => (r(), E(s($e), {
|
|
342
|
+
key: l.key,
|
|
344
343
|
type: e.tagType,
|
|
345
|
-
size:
|
|
344
|
+
size: pe.value,
|
|
346
345
|
effect: e.tagEffect,
|
|
347
|
-
hit:
|
|
348
|
-
closable:
|
|
346
|
+
hit: l.hitState,
|
|
347
|
+
closable: l.closable,
|
|
349
348
|
"disable-transitions": "",
|
|
350
|
-
onClose: (o) =>
|
|
349
|
+
onClose: (o) => R(l)
|
|
351
350
|
}, {
|
|
352
351
|
default: v(() => [
|
|
353
|
-
|
|
352
|
+
l.isCollapseTag === !1 ? (r(), m("span", Et, U(l.text), 1)) : (r(), E(s(Ee), {
|
|
354
353
|
key: 1,
|
|
355
354
|
disabled: g.value || !e.collapseTagsTooltip,
|
|
356
355
|
"fallback-placements": ["bottom", "top", "right", "left"],
|
|
@@ -358,33 +357,33 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
358
357
|
effect: e.effect
|
|
359
358
|
}, {
|
|
360
359
|
default: v(() => [
|
|
361
|
-
z("span", null,
|
|
360
|
+
z("span", null, U(l.text), 1)
|
|
362
361
|
]),
|
|
363
362
|
content: v(() => [
|
|
364
|
-
te(
|
|
363
|
+
te(s(we), { "max-height": e.maxCollapseTagsTooltipHeight }, {
|
|
365
364
|
default: v(() => [
|
|
366
365
|
z("div", {
|
|
367
|
-
class: d(
|
|
366
|
+
class: d(s(n).e("collapse-tags"))
|
|
368
367
|
}, [
|
|
369
|
-
(r(!0), m(
|
|
368
|
+
(r(!0), m(le, null, se(H.value.slice(
|
|
370
369
|
e.maxCollapseTags
|
|
371
370
|
), (o, u) => (r(), m("div", {
|
|
372
371
|
key: u,
|
|
373
|
-
class: d(
|
|
372
|
+
class: d(s(n).e("collapse-tag"))
|
|
374
373
|
}, [
|
|
375
|
-
(r(), E(
|
|
374
|
+
(r(), E(s($e), {
|
|
376
375
|
key: o.key,
|
|
377
376
|
class: "in-tooltip",
|
|
378
377
|
type: e.tagType,
|
|
379
|
-
size:
|
|
378
|
+
size: pe.value,
|
|
380
379
|
effect: e.tagEffect,
|
|
381
380
|
hit: o.hitState,
|
|
382
381
|
closable: o.closable,
|
|
383
382
|
"disable-transitions": "",
|
|
384
|
-
onClose: (
|
|
383
|
+
onClose: (W) => R(o)
|
|
385
384
|
}, {
|
|
386
385
|
default: v(() => [
|
|
387
|
-
z("span", null,
|
|
386
|
+
z("span", null, U(o.text), 1)
|
|
388
387
|
]),
|
|
389
388
|
_: 2
|
|
390
389
|
}, 1032, ["type", "size", "effect", "hit", "closable", "onClose"]))
|
|
@@ -400,98 +399,98 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
400
399
|
_: 2
|
|
401
400
|
}, 1032, ["type", "size", "effect", "hit", "closable", "onClose"]))), 128))
|
|
402
401
|
]),
|
|
403
|
-
e.filterable && !b.value ?
|
|
402
|
+
e.filterable && !b.value ? q((r(), m("input", {
|
|
404
403
|
key: 0,
|
|
405
|
-
"onUpdate:modelValue": t[2] || (t[2] = (
|
|
404
|
+
"onUpdate:modelValue": t[2] || (t[2] = (l) => w.value = l),
|
|
406
405
|
type: "text",
|
|
407
|
-
class: d(
|
|
408
|
-
placeholder:
|
|
409
|
-
onInput: t[3] || (t[3] = (
|
|
410
|
-
onClick: t[4] || (t[4] = F((
|
|
411
|
-
onKeydown:
|
|
406
|
+
class: d(s(n).e("search-input")),
|
|
407
|
+
placeholder: L.value ? "" : ce.value,
|
|
408
|
+
onInput: t[3] || (t[3] = (l) => ee(w.value, l)),
|
|
409
|
+
onClick: t[4] || (t[4] = F((l) => p(!0), ["stop"])),
|
|
410
|
+
onKeydown: tt(Qe, ["delete"]),
|
|
412
411
|
onCompositionstart: t[5] || (t[5] = //@ts-ignore
|
|
413
|
-
(...
|
|
412
|
+
(...l) => s(k) && s(k)(...l)),
|
|
414
413
|
onCompositionupdate: t[6] || (t[6] = //@ts-ignore
|
|
415
|
-
(...
|
|
414
|
+
(...l) => s(k) && s(k)(...l)),
|
|
416
415
|
onCompositionend: t[7] || (t[7] = //@ts-ignore
|
|
417
|
-
(...
|
|
418
|
-
onFocus:
|
|
419
|
-
onBlur:
|
|
420
|
-
}, null, 42,
|
|
416
|
+
(...l) => s(k) && s(k)(...l)),
|
|
417
|
+
onFocus: Ce,
|
|
418
|
+
onBlur: ye
|
|
419
|
+
}, null, 42, wt)), [
|
|
421
420
|
[lt, w.value]
|
|
422
421
|
]) : P("", !0)
|
|
423
422
|
], 2)) : P("", !0)
|
|
424
423
|
], 38)), [
|
|
425
|
-
[
|
|
424
|
+
[s(gt), () => p(!1), ge.value]
|
|
426
425
|
])
|
|
427
426
|
]),
|
|
428
427
|
content: v(() => [
|
|
429
428
|
e.$slots.header ? (r(), m("div", {
|
|
430
429
|
key: 0,
|
|
431
|
-
class: d(
|
|
430
|
+
class: d(s(n).e("header")),
|
|
432
431
|
onClick: t[11] || (t[11] = F(() => {
|
|
433
432
|
}, ["stop"]))
|
|
434
433
|
}, [
|
|
435
434
|
V(e.$slots, "header")
|
|
436
435
|
], 2)) : P("", !0),
|
|
437
|
-
|
|
436
|
+
q(te(s(vt), {
|
|
438
437
|
ref_key: "cascaderPanelRef",
|
|
439
438
|
ref: f,
|
|
440
|
-
modelValue:
|
|
441
|
-
"onUpdate:modelValue": t[12] || (t[12] = (
|
|
439
|
+
modelValue: me.value,
|
|
440
|
+
"onUpdate:modelValue": t[12] || (t[12] = (l) => me.value = l),
|
|
442
441
|
options: e.options,
|
|
443
442
|
props: a.props,
|
|
444
443
|
border: !1,
|
|
445
444
|
"render-label": e.$slots.default,
|
|
446
|
-
onExpandChange:
|
|
447
|
-
onClose: t[13] || (t[13] = (
|
|
445
|
+
onExpandChange: qe,
|
|
446
|
+
onClose: t[13] || (t[13] = (l) => e.$nextTick(() => p(!1)))
|
|
448
447
|
}, {
|
|
449
448
|
empty: v(() => [
|
|
450
449
|
V(e.$slots, "empty")
|
|
451
450
|
]),
|
|
452
451
|
_: 3
|
|
453
452
|
}, 8, ["modelValue", "options", "props", "render-label"]), [
|
|
454
|
-
[
|
|
453
|
+
[Te, !y.value]
|
|
455
454
|
]),
|
|
456
|
-
e.filterable ?
|
|
455
|
+
e.filterable ? q((r(), E(s(we), {
|
|
457
456
|
key: 1,
|
|
458
457
|
ref_key: "suggestionPanel",
|
|
459
|
-
ref:
|
|
458
|
+
ref: K,
|
|
460
459
|
tag: "ul",
|
|
461
|
-
class: d(
|
|
462
|
-
"view-class":
|
|
463
|
-
onKeydown:
|
|
460
|
+
class: d(s(n).e("suggestion-panel")),
|
|
461
|
+
"view-class": s(n).e("suggestion-list"),
|
|
462
|
+
onKeydown: Je
|
|
464
463
|
}, {
|
|
465
464
|
default: v(() => [
|
|
466
|
-
Q.value.length ? (r(!0), m(
|
|
467
|
-
key:
|
|
465
|
+
Q.value.length ? (r(!0), m(le, { key: 0 }, se(Q.value, (l) => (r(), m("li", {
|
|
466
|
+
key: l.uid,
|
|
468
467
|
class: d([
|
|
469
|
-
|
|
470
|
-
|
|
468
|
+
s(n).e("suggestion-item"),
|
|
469
|
+
s(n).is("checked", l.checked)
|
|
471
470
|
]),
|
|
472
471
|
tabindex: -1,
|
|
473
|
-
onClick: (o) =>
|
|
472
|
+
onClick: (o) => je(l)
|
|
474
473
|
}, [
|
|
475
|
-
V(e.$slots, "suggestion-item", { item:
|
|
476
|
-
z("span", null,
|
|
477
|
-
|
|
474
|
+
V(e.$slots, "suggestion-item", { item: l }, () => [
|
|
475
|
+
z("span", null, U(l.text), 1),
|
|
476
|
+
l.checked ? (r(), E(s(oe), {
|
|
478
477
|
key: 0,
|
|
479
478
|
icon: "icon-check"
|
|
480
479
|
})) : P("", !0)
|
|
481
480
|
])
|
|
482
|
-
], 10,
|
|
481
|
+
], 10, $t))), 128)) : V(e.$slots, "empty", { key: 1 }, () => [
|
|
483
482
|
z("li", {
|
|
484
|
-
class: d(
|
|
485
|
-
},
|
|
483
|
+
class: d(s(n).e("empty-text"))
|
|
484
|
+
}, "无匹配数据", 2)
|
|
486
485
|
])
|
|
487
486
|
]),
|
|
488
487
|
_: 3
|
|
489
488
|
}, 8, ["class", "view-class"])), [
|
|
490
|
-
[
|
|
489
|
+
[Te, y.value]
|
|
491
490
|
]) : P("", !0),
|
|
492
491
|
e.$slots.footer ? (r(), m("div", {
|
|
493
492
|
key: 2,
|
|
494
|
-
class: d(
|
|
493
|
+
class: d(s(n).e("footer")),
|
|
495
494
|
onClick: t[14] || (t[14] = F(() => {
|
|
496
495
|
}, ["stop"]))
|
|
497
496
|
}, [
|
|
@@ -503,5 +502,5 @@ const $t = { key: 0 }, Vt = ["placeholder"], St = ["onClick"], Nt = "VftCascader
|
|
|
503
502
|
}
|
|
504
503
|
});
|
|
505
504
|
export {
|
|
506
|
-
|
|
505
|
+
el as default
|
|
507
506
|
};
|