@element-plus/nightly 0.0.20240227 → 0.0.20240229
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/attributes.json +1 -1
- package/dist/index.css +1 -1
- package/dist/index.full.js +292 -284
- package/dist/index.full.min.js +26 -26
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +26 -26
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +293 -285
- package/dist/locale/af.js +1 -1
- package/dist/locale/af.min.js +1 -1
- package/dist/locale/af.min.mjs +1 -1
- package/dist/locale/af.mjs +1 -1
- package/dist/locale/ar-eg.js +1 -1
- package/dist/locale/ar-eg.min.js +1 -1
- package/dist/locale/ar-eg.min.mjs +1 -1
- package/dist/locale/ar-eg.mjs +1 -1
- package/dist/locale/ar.js +1 -1
- package/dist/locale/ar.min.js +1 -1
- package/dist/locale/ar.min.mjs +1 -1
- package/dist/locale/ar.mjs +1 -1
- package/dist/locale/az.js +1 -1
- package/dist/locale/az.min.js +1 -1
- package/dist/locale/az.min.mjs +1 -1
- package/dist/locale/az.mjs +1 -1
- package/dist/locale/bg.js +1 -1
- package/dist/locale/bg.min.js +1 -1
- package/dist/locale/bg.min.mjs +1 -1
- package/dist/locale/bg.mjs +1 -1
- package/dist/locale/bn.js +1 -1
- package/dist/locale/bn.min.js +1 -1
- package/dist/locale/bn.min.mjs +1 -1
- package/dist/locale/bn.mjs +1 -1
- package/dist/locale/ca.js +1 -1
- package/dist/locale/ca.min.js +1 -1
- package/dist/locale/ca.min.mjs +1 -1
- package/dist/locale/ca.mjs +1 -1
- package/dist/locale/ckb.js +1 -1
- package/dist/locale/ckb.min.js +1 -1
- package/dist/locale/ckb.min.mjs +1 -1
- package/dist/locale/ckb.mjs +1 -1
- package/dist/locale/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/hr.js +1 -1
- package/dist/locale/hr.min.js +1 -1
- package/dist/locale/hr.min.mjs +1 -1
- package/dist/locale/hr.mjs +1 -1
- package/dist/locale/hu.js +1 -1
- package/dist/locale/hu.min.js +1 -1
- package/dist/locale/hu.min.mjs +1 -1
- package/dist/locale/hu.mjs +1 -1
- package/dist/locale/hy-am.js +1 -1
- package/dist/locale/hy-am.min.js +1 -1
- package/dist/locale/hy-am.min.mjs +1 -1
- package/dist/locale/hy-am.mjs +1 -1
- package/dist/locale/id.js +1 -1
- package/dist/locale/id.min.js +1 -1
- package/dist/locale/id.min.mjs +1 -1
- package/dist/locale/id.mjs +1 -1
- package/dist/locale/it.js +1 -1
- package/dist/locale/it.min.js +1 -1
- package/dist/locale/it.min.mjs +1 -1
- package/dist/locale/it.mjs +1 -1
- package/dist/locale/ja.js +1 -1
- package/dist/locale/ja.min.js +1 -1
- package/dist/locale/ja.min.mjs +1 -1
- package/dist/locale/ja.mjs +1 -1
- package/dist/locale/kk.js +1 -1
- package/dist/locale/kk.min.js +1 -1
- package/dist/locale/kk.min.mjs +1 -1
- package/dist/locale/kk.mjs +1 -1
- package/dist/locale/km.js +1 -1
- package/dist/locale/km.min.js +1 -1
- package/dist/locale/km.min.mjs +1 -1
- package/dist/locale/km.mjs +1 -1
- package/dist/locale/ko.js +1 -1
- package/dist/locale/ko.min.js +1 -1
- package/dist/locale/ko.min.mjs +1 -1
- package/dist/locale/ko.mjs +1 -1
- package/dist/locale/ku.js +1 -1
- package/dist/locale/ku.min.js +1 -1
- package/dist/locale/ku.min.mjs +1 -1
- package/dist/locale/ku.mjs +1 -1
- package/dist/locale/ky.js +1 -1
- package/dist/locale/ky.min.js +1 -1
- package/dist/locale/ky.min.mjs +1 -1
- package/dist/locale/ky.mjs +1 -1
- package/dist/locale/lt.js +1 -1
- package/dist/locale/lt.min.js +1 -1
- package/dist/locale/lt.min.mjs +1 -1
- package/dist/locale/lt.mjs +1 -1
- package/dist/locale/lv.js +1 -1
- package/dist/locale/lv.min.js +1 -1
- package/dist/locale/lv.min.mjs +1 -1
- package/dist/locale/lv.mjs +1 -1
- package/dist/locale/mg.js +1 -1
- package/dist/locale/mg.min.js +1 -1
- package/dist/locale/mg.min.mjs +1 -1
- package/dist/locale/mg.mjs +1 -1
- package/dist/locale/mn.js +1 -1
- package/dist/locale/mn.min.js +1 -1
- package/dist/locale/mn.min.mjs +1 -1
- package/dist/locale/mn.mjs +1 -1
- package/dist/locale/nb-no.js +1 -1
- package/dist/locale/nb-no.min.js +1 -1
- package/dist/locale/nb-no.min.mjs +1 -1
- package/dist/locale/nb-no.mjs +1 -1
- package/dist/locale/nl.js +1 -1
- package/dist/locale/nl.min.js +1 -1
- package/dist/locale/nl.min.mjs +1 -1
- package/dist/locale/nl.mjs +1 -1
- package/dist/locale/pa.js +1 -1
- package/dist/locale/pa.min.js +1 -1
- package/dist/locale/pa.min.mjs +1 -1
- package/dist/locale/pa.mjs +1 -1
- package/dist/locale/pl.js +1 -1
- package/dist/locale/pl.min.js +1 -1
- package/dist/locale/pl.min.mjs +1 -1
- package/dist/locale/pl.mjs +1 -1
- package/dist/locale/pt-br.js +1 -1
- package/dist/locale/pt-br.min.js +1 -1
- package/dist/locale/pt-br.min.mjs +1 -1
- package/dist/locale/pt-br.mjs +1 -1
- package/dist/locale/pt.js +1 -1
- package/dist/locale/pt.min.js +1 -1
- package/dist/locale/pt.min.mjs +1 -1
- package/dist/locale/pt.mjs +1 -1
- package/dist/locale/ro.js +1 -1
- package/dist/locale/ro.min.js +1 -1
- package/dist/locale/ro.min.mjs +1 -1
- package/dist/locale/ro.mjs +1 -1
- package/dist/locale/ru.js +1 -1
- package/dist/locale/ru.min.js +1 -1
- package/dist/locale/ru.min.mjs +1 -1
- package/dist/locale/ru.mjs +1 -1
- package/dist/locale/sk.js +1 -1
- package/dist/locale/sk.min.js +1 -1
- package/dist/locale/sk.min.mjs +1 -1
- package/dist/locale/sk.mjs +1 -1
- package/dist/locale/sl.js +1 -1
- package/dist/locale/sl.min.js +1 -1
- package/dist/locale/sl.min.mjs +1 -1
- package/dist/locale/sl.mjs +1 -1
- package/dist/locale/sr.js +1 -1
- package/dist/locale/sr.min.js +1 -1
- package/dist/locale/sr.min.mjs +1 -1
- package/dist/locale/sr.mjs +1 -1
- package/dist/locale/sv.js +1 -1
- package/dist/locale/sv.min.js +1 -1
- package/dist/locale/sv.min.mjs +1 -1
- package/dist/locale/sv.mjs +1 -1
- package/dist/locale/sw.js +1 -1
- package/dist/locale/sw.min.js +1 -1
- package/dist/locale/sw.min.mjs +1 -1
- package/dist/locale/sw.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/th.js +1 -1
- package/dist/locale/th.min.js +1 -1
- package/dist/locale/th.min.mjs +1 -1
- package/dist/locale/th.mjs +1 -1
- package/dist/locale/tk.js +1 -1
- package/dist/locale/tk.min.js +1 -1
- package/dist/locale/tk.min.mjs +1 -1
- package/dist/locale/tk.mjs +1 -1
- package/dist/locale/tr.js +1 -1
- package/dist/locale/tr.min.js +1 -1
- package/dist/locale/tr.min.mjs +1 -1
- package/dist/locale/tr.mjs +1 -1
- package/dist/locale/ug-cn.js +1 -1
- package/dist/locale/ug-cn.min.js +1 -1
- package/dist/locale/ug-cn.min.mjs +1 -1
- package/dist/locale/ug-cn.mjs +1 -1
- package/dist/locale/uk.js +1 -1
- package/dist/locale/uk.min.js +1 -1
- package/dist/locale/uk.min.mjs +1 -1
- package/dist/locale/uk.mjs +1 -1
- package/dist/locale/uz-uz.js +1 -1
- package/dist/locale/uz-uz.min.js +1 -1
- package/dist/locale/uz-uz.min.mjs +1 -1
- package/dist/locale/uz-uz.mjs +1 -1
- package/dist/locale/vi.js +1 -1
- package/dist/locale/vi.min.js +1 -1
- package/dist/locale/vi.min.mjs +1 -1
- package/dist/locale/vi.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/dist/locale/zh-tw.js +1 -1
- package/dist/locale/zh-tw.min.js +1 -1
- package/dist/locale/zh-tw.min.mjs +1 -1
- package/dist/locale/zh-tw.mjs +1 -1
- package/es/components/calendar/src/calendar2.mjs +5 -5
- package/es/components/calendar/src/calendar2.mjs.map +1 -1
- package/es/components/calendar/src/use-calendar.mjs +1 -11
- package/es/components/calendar/src/use-calendar.mjs.map +1 -1
- package/es/components/card/index.mjs +2 -2
- package/es/components/card/src/card.mjs +43 -21
- package/es/components/card/src/card.mjs.map +1 -1
- package/es/components/card/src/card2.mjs +21 -43
- package/es/components/card/src/card2.mjs.map +1 -1
- package/es/components/carousel/index.d.ts +7 -0
- package/es/components/carousel/src/carousel.d.ts +1 -0
- package/es/components/carousel/src/carousel.mjs +4 -0
- package/es/components/carousel/src/carousel.mjs.map +1 -1
- package/es/components/carousel/src/carousel.vue.d.ts +7 -0
- package/es/components/carousel/src/carousel2.mjs +100 -66
- package/es/components/carousel/src/carousel2.mjs.map +1 -1
- package/es/components/carousel/src/use-carousel.d.ts +2 -0
- package/es/components/carousel/src/use-carousel.mjs +23 -0
- package/es/components/carousel/src/use-carousel.mjs.map +1 -1
- package/es/components/checkbox/index.d.ts +120 -0
- package/es/components/checkbox/src/checkbox-button.mjs +5 -4
- package/es/components/checkbox/src/checkbox-button.mjs.map +1 -1
- package/es/components/checkbox/src/checkbox-button.vue.d.ts +40 -0
- package/es/components/checkbox/src/checkbox.d.ts +24 -1
- package/es/components/checkbox/src/checkbox.mjs +12 -0
- package/es/components/checkbox/src/checkbox.mjs.map +1 -1
- package/es/components/checkbox/src/checkbox.vue.d.ts +40 -0
- package/es/components/checkbox/src/checkbox2.mjs +5 -4
- package/es/components/checkbox/src/checkbox2.mjs.map +1 -1
- package/es/components/checkbox/src/composables/use-checkbox-event.mjs +2 -2
- package/es/components/checkbox/src/composables/use-checkbox-event.mjs.map +1 -1
- package/es/components/checkbox/src/composables/use-checkbox-status.d.ts +1 -0
- package/es/components/checkbox/src/composables/use-checkbox-status.mjs +15 -8
- package/es/components/checkbox/src/composables/use-checkbox-status.mjs.map +1 -1
- package/es/components/checkbox/src/composables/use-checkbox.d.ts +1 -0
- package/es/components/checkbox/src/composables/use-checkbox.mjs +40 -13
- package/es/components/checkbox/src/composables/use-checkbox.mjs.map +1 -1
- package/es/components/col/index.mjs +2 -2
- package/es/components/col/src/col.mjs +43 -66
- package/es/components/col/src/col.mjs.map +1 -1
- package/es/components/col/src/col2.mjs +66 -43
- package/es/components/col/src/col2.mjs.map +1 -1
- package/es/components/date-picker/src/composables/use-basic-date-table.mjs +1 -1
- package/es/components/date-picker/src/composables/use-basic-date-table.mjs.map +1 -1
- package/es/components/index.mjs +6 -6
- package/es/components/menu/index.d.ts +0 -6
- package/es/components/menu/index.mjs +2 -2
- package/es/components/menu/src/menu-item-group.mjs +35 -4
- package/es/components/menu/src/menu-item-group.mjs.map +1 -1
- package/es/components/menu/src/menu-item-group2.mjs +4 -35
- package/es/components/menu/src/menu-item-group2.mjs.map +1 -1
- package/es/components/menu/src/menu.mjs +2 -0
- package/es/components/menu/src/menu.mjs.map +1 -1
- package/es/components/menu/src/sub-menu.d.ts +0 -4
- package/es/components/menu/src/sub-menu.mjs +2 -15
- package/es/components/menu/src/sub-menu.mjs.map +1 -1
- package/es/components/pagination/src/components/sizes.vue.d.ts +0 -3
- package/es/components/popper/index.mjs +2 -2
- package/es/components/popper/src/content.mjs +94 -137
- package/es/components/popper/src/content.mjs.map +1 -1
- package/es/components/popper/src/content2.mjs +137 -94
- package/es/components/popper/src/content2.mjs.map +1 -1
- package/es/components/radio/index.d.ts +77 -54
- package/es/components/radio/src/radio-button.d.ts +4 -2
- package/es/components/radio/src/radio-button.mjs +1 -5
- package/es/components/radio/src/radio-button.mjs.map +1 -1
- package/es/components/radio/src/radio-button.vue.d.ts +16 -7
- package/es/components/radio/src/radio-button2.mjs +4 -4
- package/es/components/radio/src/radio-button2.mjs.map +1 -1
- package/es/components/radio/src/radio-group.d.ts +3 -3
- package/es/components/radio/src/radio-group.mjs +1 -1
- package/es/components/radio/src/radio-group.mjs.map +1 -1
- package/es/components/radio/src/radio-group.vue.d.ts +10 -10
- package/es/components/radio/src/radio.d.ts +10 -6
- package/es/components/radio/src/radio.mjs +13 -9
- package/es/components/radio/src/radio.mjs.map +1 -1
- package/es/components/radio/src/radio.vue.d.ts +23 -18
- package/es/components/radio/src/radio2.mjs +4 -4
- package/es/components/radio/src/radio2.mjs.map +1 -1
- package/es/components/radio/src/use-radio.d.ts +4 -5
- package/es/components/radio/src/use-radio.mjs +21 -3
- package/es/components/radio/src/use-radio.mjs.map +1 -1
- package/es/components/select/index.d.ts +0 -3
- package/es/components/select/src/select.d.ts +0 -1
- package/es/components/select/src/select.mjs +0 -4
- package/es/components/select/src/select.mjs.map +1 -1
- package/es/components/select/src/select.vue.d.ts +0 -3
- package/es/components/select/src/useSelect.mjs +3 -19
- package/es/components/select/src/useSelect.mjs.map +1 -1
- package/es/components/select-v2/src/select-dropdown.mjs +5 -10
- package/es/components/select-v2/src/select-dropdown.mjs.map +1 -1
- package/es/components/select-v2/src/useSelect.mjs +10 -11
- package/es/components/select-v2/src/useSelect.mjs.map +1 -1
- package/es/components/switch/index.d.ts +0 -19
- package/es/components/switch/src/switch.d.ts +0 -4
- package/es/components/switch/src/switch.mjs +0 -16
- package/es/components/switch/src/switch.mjs.map +1 -1
- package/es/components/switch/src/switch.vue.d.ts +0 -19
- package/es/components/switch/src/switch2.mjs +3 -37
- package/es/components/switch/src/switch2.mjs.map +1 -1
- package/es/components/tabs/index.d.ts +0 -12
- package/es/components/tabs/src/tabs.d.ts +0 -18
- package/es/components/tabs/src/tabs.mjs +7 -29
- package/es/components/tabs/src/tabs.mjs.map +1 -1
- package/es/components/time-select/index.d.ts +0 -12
- package/es/components/time-select/src/time-select.vue.d.ts +0 -6
- package/es/components/tooltip/src/content.mjs +1 -1
- package/es/components/tooltip/src/content2.mjs +1 -1
- package/es/components/transfer/index.d.ts +400 -0
- package/es/components/transfer/src/transfer-panel.vue.d.ts +80 -0
- package/es/components/transfer/src/transfer.vue.d.ts +400 -0
- package/es/components/tree-select/src/select.d.ts +1 -1
- package/es/components/tree-select/src/select.mjs +15 -11
- package/es/components/tree-select/src/select.mjs.map +1 -1
- package/es/components/tree-select/src/tree.mjs +5 -6
- package/es/components/tree-select/src/tree.mjs.map +1 -1
- package/es/components/tree-v2/index.d.ts +80 -0
- package/es/components/tree-v2/src/tree-node.vue.d.ts +80 -0
- package/es/components/tree-v2/src/tree.vue.d.ts +80 -0
- package/es/components/upload/index.mjs +2 -2
- package/es/components/upload/src/upload-content.mjs +1 -1
- package/es/components/upload/src/upload-content2.mjs +1 -1
- package/es/components/upload/src/upload-list.mjs +1 -1
- package/es/components/upload/src/upload.mjs +118 -104
- package/es/components/upload/src/upload.mjs.map +1 -1
- package/es/components/upload/src/upload2.mjs +104 -118
- package/es/components/upload/src/upload2.mjs.map +1 -1
- package/es/components/upload/src/use-handlers.mjs +1 -1
- package/es/index.mjs +6 -6
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/calendar/src/calendar2.js +4 -4
- package/lib/components/calendar/src/calendar2.js.map +1 -1
- package/lib/components/calendar/src/use-calendar.js +0 -10
- package/lib/components/calendar/src/use-calendar.js.map +1 -1
- package/lib/components/card/index.js +2 -2
- package/lib/components/card/src/card.js +43 -21
- package/lib/components/card/src/card.js.map +1 -1
- package/lib/components/card/src/card2.js +21 -43
- package/lib/components/card/src/card2.js.map +1 -1
- package/lib/components/carousel/index.d.ts +7 -0
- package/lib/components/carousel/src/carousel.d.ts +1 -0
- package/lib/components/carousel/src/carousel.js +4 -0
- package/lib/components/carousel/src/carousel.js.map +1 -1
- package/lib/components/carousel/src/carousel.vue.d.ts +7 -0
- package/lib/components/carousel/src/carousel2.js +99 -65
- package/lib/components/carousel/src/carousel2.js.map +1 -1
- package/lib/components/carousel/src/use-carousel.d.ts +2 -0
- package/lib/components/carousel/src/use-carousel.js +23 -0
- package/lib/components/carousel/src/use-carousel.js.map +1 -1
- package/lib/components/checkbox/index.d.ts +120 -0
- package/lib/components/checkbox/src/checkbox-button.js +5 -4
- package/lib/components/checkbox/src/checkbox-button.js.map +1 -1
- package/lib/components/checkbox/src/checkbox-button.vue.d.ts +40 -0
- package/lib/components/checkbox/src/checkbox.d.ts +24 -1
- package/lib/components/checkbox/src/checkbox.js +12 -0
- package/lib/components/checkbox/src/checkbox.js.map +1 -1
- package/lib/components/checkbox/src/checkbox.vue.d.ts +40 -0
- package/lib/components/checkbox/src/checkbox2.js +5 -4
- package/lib/components/checkbox/src/checkbox2.js.map +1 -1
- package/lib/components/checkbox/src/composables/use-checkbox-event.js +2 -2
- package/lib/components/checkbox/src/composables/use-checkbox-event.js.map +1 -1
- package/lib/components/checkbox/src/composables/use-checkbox-status.d.ts +1 -0
- package/lib/components/checkbox/src/composables/use-checkbox-status.js +13 -6
- package/lib/components/checkbox/src/composables/use-checkbox-status.js.map +1 -1
- package/lib/components/checkbox/src/composables/use-checkbox.d.ts +1 -0
- package/lib/components/checkbox/src/composables/use-checkbox.js +40 -13
- package/lib/components/checkbox/src/composables/use-checkbox.js.map +1 -1
- package/lib/components/col/index.js +2 -2
- package/lib/components/col/src/col.js +43 -66
- package/lib/components/col/src/col.js.map +1 -1
- package/lib/components/col/src/col2.js +66 -43
- package/lib/components/col/src/col2.js.map +1 -1
- package/lib/components/date-picker/src/composables/use-basic-date-table.js +1 -1
- package/lib/components/date-picker/src/composables/use-basic-date-table.js.map +1 -1
- package/lib/components/index.js +6 -6
- package/lib/components/menu/index.d.ts +0 -6
- package/lib/components/menu/index.js +2 -2
- package/lib/components/menu/src/menu-item-group.js +35 -4
- package/lib/components/menu/src/menu-item-group.js.map +1 -1
- package/lib/components/menu/src/menu-item-group2.js +4 -35
- package/lib/components/menu/src/menu-item-group2.js.map +1 -1
- package/lib/components/menu/src/menu.js +2 -0
- package/lib/components/menu/src/menu.js.map +1 -1
- package/lib/components/menu/src/sub-menu.d.ts +0 -4
- package/lib/components/menu/src/sub-menu.js +10 -23
- package/lib/components/menu/src/sub-menu.js.map +1 -1
- package/lib/components/pagination/src/components/sizes.vue.d.ts +0 -3
- package/lib/components/popper/index.js +2 -2
- package/lib/components/popper/src/content.js +99 -137
- package/lib/components/popper/src/content.js.map +1 -1
- package/lib/components/popper/src/content2.js +137 -99
- package/lib/components/popper/src/content2.js.map +1 -1
- package/lib/components/radio/index.d.ts +77 -54
- package/lib/components/radio/src/radio-button.d.ts +4 -2
- package/lib/components/radio/src/radio-button.js +1 -5
- package/lib/components/radio/src/radio-button.js.map +1 -1
- package/lib/components/radio/src/radio-button.vue.d.ts +16 -7
- package/lib/components/radio/src/radio-button2.js +4 -4
- package/lib/components/radio/src/radio-button2.js.map +1 -1
- package/lib/components/radio/src/radio-group.d.ts +3 -3
- package/lib/components/radio/src/radio-group.js +1 -1
- package/lib/components/radio/src/radio-group.js.map +1 -1
- package/lib/components/radio/src/radio-group.vue.d.ts +10 -10
- package/lib/components/radio/src/radio.d.ts +10 -6
- package/lib/components/radio/src/radio.js +13 -9
- package/lib/components/radio/src/radio.js.map +1 -1
- package/lib/components/radio/src/radio.vue.d.ts +23 -18
- package/lib/components/radio/src/radio2.js +4 -4
- package/lib/components/radio/src/radio2.js.map +1 -1
- package/lib/components/radio/src/use-radio.d.ts +4 -5
- package/lib/components/radio/src/use-radio.js +21 -3
- package/lib/components/radio/src/use-radio.js.map +1 -1
- package/lib/components/select/index.d.ts +0 -3
- package/lib/components/select/src/select.d.ts +0 -1
- package/lib/components/select/src/select.js +0 -4
- package/lib/components/select/src/select.js.map +1 -1
- package/lib/components/select/src/select.vue.d.ts +0 -3
- package/lib/components/select/src/useSelect.js +4 -20
- package/lib/components/select/src/useSelect.js.map +1 -1
- package/lib/components/select-v2/src/select-dropdown.js +5 -10
- package/lib/components/select-v2/src/select-dropdown.js.map +1 -1
- package/lib/components/select-v2/src/useSelect.js +10 -11
- package/lib/components/select-v2/src/useSelect.js.map +1 -1
- package/lib/components/switch/index.d.ts +0 -19
- package/lib/components/switch/src/switch.d.ts +0 -4
- package/lib/components/switch/src/switch.js +0 -16
- package/lib/components/switch/src/switch.js.map +1 -1
- package/lib/components/switch/src/switch.vue.d.ts +0 -19
- package/lib/components/switch/src/switch2.js +9 -43
- package/lib/components/switch/src/switch2.js.map +1 -1
- package/lib/components/tabs/index.d.ts +0 -12
- package/lib/components/tabs/src/tabs.d.ts +0 -18
- package/lib/components/tabs/src/tabs.js +7 -29
- package/lib/components/tabs/src/tabs.js.map +1 -1
- package/lib/components/time-select/index.d.ts +0 -12
- package/lib/components/time-select/src/time-select.vue.d.ts +0 -6
- package/lib/components/tooltip/src/content.js +1 -1
- package/lib/components/tooltip/src/content2.js +1 -1
- package/lib/components/transfer/index.d.ts +400 -0
- package/lib/components/transfer/src/transfer-panel.vue.d.ts +80 -0
- package/lib/components/transfer/src/transfer.vue.d.ts +400 -0
- package/lib/components/tree-select/src/select.d.ts +1 -1
- package/lib/components/tree-select/src/select.js +14 -10
- package/lib/components/tree-select/src/select.js.map +1 -1
- package/lib/components/tree-select/src/tree.js +5 -6
- package/lib/components/tree-select/src/tree.js.map +1 -1
- package/lib/components/tree-v2/index.d.ts +80 -0
- package/lib/components/tree-v2/src/tree-node.vue.d.ts +80 -0
- package/lib/components/tree-v2/src/tree.vue.d.ts +80 -0
- package/lib/components/upload/index.js +2 -2
- package/lib/components/upload/src/upload-content.js +1 -1
- package/lib/components/upload/src/upload-content2.js +1 -1
- package/lib/components/upload/src/upload-list.js +1 -1
- package/lib/components/upload/src/upload.js +118 -107
- package/lib/components/upload/src/upload.js.map +1 -1
- package/lib/components/upload/src/upload2.js +107 -118
- package/lib/components/upload/src/upload2.js.map +1 -1
- package/lib/components/upload/src/use-handlers.js +1 -1
- package/lib/index.js +6 -6
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +2 -2
- package/tags.json +1 -1
- package/theme-chalk/el-carousel.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/carousel.scss +8 -0
- package/web-types.json +1 -1
|
@@ -4,7 +4,7 @@ import type ElTree from '@element-plus/nightly/es/components/tree';
|
|
|
4
4
|
export declare const useSelect: (props: any, { attrs, emit }: {
|
|
5
5
|
attrs: any;
|
|
6
6
|
emit: any;
|
|
7
|
-
}, { tree, key, }: {
|
|
7
|
+
}, { select, tree, key, }: {
|
|
8
8
|
select: Ref<InstanceType<typeof ElSelect> | undefined>;
|
|
9
9
|
tree: Ref<InstanceType<typeof ElTree> | undefined>;
|
|
10
10
|
key: Ref<string>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { toRefs, computed
|
|
1
|
+
import { watch, nextTick, toRefs, computed } from 'vue';
|
|
2
2
|
import { pick } from 'lodash-unified';
|
|
3
3
|
import { ElSelect } from '../../select/index.mjs';
|
|
4
4
|
import '../../../hooks/index.mjs';
|
|
@@ -7,10 +7,19 @@ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
|
7
7
|
import { UPDATE_MODEL_EVENT } from '../../../constants/event.mjs';
|
|
8
8
|
|
|
9
9
|
const useSelect = (props, { attrs, emit }, {
|
|
10
|
+
select,
|
|
10
11
|
tree,
|
|
11
12
|
key
|
|
12
13
|
}) => {
|
|
13
14
|
const ns = useNamespace("tree-select");
|
|
15
|
+
watch(() => props.data, () => {
|
|
16
|
+
if (props.filterable) {
|
|
17
|
+
nextTick(() => {
|
|
18
|
+
var _a, _b;
|
|
19
|
+
(_b = tree.value) == null ? void 0 : _b.filter((_a = select.value) == null ? void 0 : _a.states.inputValue);
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
}, { flush: "post" });
|
|
14
23
|
const result = {
|
|
15
24
|
...pick(toRefs(props), Object.keys(ElSelect.props)),
|
|
16
25
|
...attrs,
|
|
@@ -23,18 +32,13 @@ const useSelect = (props, { attrs, emit }, {
|
|
|
23
32
|
return classes.join(" ");
|
|
24
33
|
}),
|
|
25
34
|
filterMethod: (keyword = "") => {
|
|
26
|
-
|
|
35
|
+
var _a;
|
|
36
|
+
if (props.filterMethod) {
|
|
27
37
|
props.filterMethod(keyword);
|
|
28
|
-
|
|
29
|
-
|
|
38
|
+
} else if (props.remoteMethod) {
|
|
39
|
+
props.remoteMethod(keyword);
|
|
40
|
+
} else {
|
|
30
41
|
(_a = tree.value) == null ? void 0 : _a.filter(keyword);
|
|
31
|
-
});
|
|
32
|
-
},
|
|
33
|
-
onVisibleChange: (visible) => {
|
|
34
|
-
var _a;
|
|
35
|
-
(_a = attrs.onVisibleChange) == null ? void 0 : _a.call(attrs, visible);
|
|
36
|
-
if (props.filterable && visible) {
|
|
37
|
-
result.filterMethod();
|
|
38
42
|
}
|
|
39
43
|
}
|
|
40
44
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select.mjs","sources":["../../../../../../packages/components/tree-select/src/select.ts"],"sourcesContent":["// @ts-nocheck\nimport { computed, nextTick, toRefs } from 'vue'\nimport { pick } from 'lodash-unified'\nimport ElSelect from '@element-plus/components/select'\nimport { useNamespace } from '@element-plus/hooks'\nimport { UPDATE_MODEL_EVENT } from '@element-plus/constants'\nimport type { Ref } from 'vue'\nimport type ElTree from '@element-plus/components/tree'\n\nexport const useSelect = (\n props,\n { attrs, emit },\n {\n tree,\n key,\n }: {\n select: Ref<InstanceType<typeof ElSelect> | undefined>\n tree: Ref<InstanceType<typeof ElTree> | undefined>\n key: Ref<string>\n }\n) => {\n const ns = useNamespace('tree-select')\n\n const result = {\n ...pick(toRefs(props), Object.keys(ElSelect.props)),\n ...attrs,\n // attrs is not reactive, when v-model binding source changes,\n // this listener is still old, see the bug(or test 'v-model source change'):\n // https://github.com/element-plus/element-plus/issues/14204\n 'onUpdate:modelValue': (value) => emit(UPDATE_MODEL_EVENT, value),\n valueKey: key,\n popperClass: computed(() => {\n const classes = [ns.e('popper')]\n if (props.popperClass) classes.push(props.popperClass)\n return classes.join(' ')\n }),\n filterMethod: (keyword = '') => {\n if (props.filterMethod) props.filterMethod(keyword)\n\n
|
|
1
|
+
{"version":3,"file":"select.mjs","sources":["../../../../../../packages/components/tree-select/src/select.ts"],"sourcesContent":["// @ts-nocheck\nimport { computed, nextTick, toRefs, watch } from 'vue'\nimport { pick } from 'lodash-unified'\nimport ElSelect from '@element-plus/components/select'\nimport { useNamespace } from '@element-plus/hooks'\nimport { UPDATE_MODEL_EVENT } from '@element-plus/constants'\nimport type { Ref } from 'vue'\nimport type ElTree from '@element-plus/components/tree'\n\nexport const useSelect = (\n props,\n { attrs, emit },\n {\n select,\n tree,\n key,\n }: {\n select: Ref<InstanceType<typeof ElSelect> | undefined>\n tree: Ref<InstanceType<typeof ElTree> | undefined>\n key: Ref<string>\n }\n) => {\n const ns = useNamespace('tree-select')\n\n // update tree data when use filterMethod/remoteMethod\n watch(\n () => props.data,\n () => {\n if (props.filterable) {\n nextTick(() => {\n // let tree node expand only, same with tree filter\n tree.value?.filter(select.value?.states.inputValue)\n })\n }\n },\n { flush: 'post' }\n )\n\n const result = {\n ...pick(toRefs(props), Object.keys(ElSelect.props)),\n ...attrs,\n // attrs is not reactive, when v-model binding source changes,\n // this listener is still old, see the bug(or test 'v-model source change'):\n // https://github.com/element-plus/element-plus/issues/14204\n 'onUpdate:modelValue': (value) => emit(UPDATE_MODEL_EVENT, value),\n valueKey: key,\n popperClass: computed(() => {\n const classes = [ns.e('popper')]\n if (props.popperClass) classes.push(props.popperClass)\n return classes.join(' ')\n }),\n filterMethod: (keyword = '') => {\n if (props.filterMethod) {\n props.filterMethod(keyword)\n } else if (props.remoteMethod) {\n props.remoteMethod(keyword)\n } else {\n // let tree node expand only, same with tree filter\n tree.value?.filter(keyword)\n }\n },\n }\n\n return result\n}\n"],"names":[],"mappings":";;;;;;;;AAKY,MAAC,SAAS,GAAG,CAAC,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE;AA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Y,EAAE,CAAC,OAAO,GAAG,EAAE,KAAK;AACpC,MAAM,IAAI,EAAE,CAAC;AACb,MAAM,IAAI,KAAK,CAAC,YAAY,EAAE;AAC9B,QAAQ,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;AACpC,OAAO,MAAM,IAAI,KAAK,CAAC,YAAY,EAAE;AACrC,QAAQ,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,CAAC;AACpC,OAAO,MAAM;AACb,QAAQ,CAAC,EAAE,GAAG,IAAI,CAAC,KAAK,KAAK,IAAI,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AAChE,OAAO;AACP,KAAK;AACL,GAAG,CAAC;AACJ,EAAE,OAAO,MAAM,CAAC;AAChB;;;;"}
|
|
@@ -61,9 +61,6 @@ const useTree = (props, { attrs, slots, emit }, {
|
|
|
61
61
|
}, (data) => getNodeValByProp("children", data));
|
|
62
62
|
return options;
|
|
63
63
|
});
|
|
64
|
-
const cacheOptionsMap = computed(() => {
|
|
65
|
-
return cacheOptions.value.reduce((prev, next) => ({ ...prev, [next.value]: next }), {});
|
|
66
|
-
});
|
|
67
64
|
return {
|
|
68
65
|
...pick(toRefs(props), Object.keys(_Tree.props)),
|
|
69
66
|
...attrs,
|
|
@@ -109,14 +106,16 @@ const useTree = (props, { attrs, slots, emit }, {
|
|
|
109
106
|
if (!props.showCheckbox)
|
|
110
107
|
return;
|
|
111
108
|
const dataValue = getNodeValByProp("value", data);
|
|
109
|
+
const dataMap = {};
|
|
110
|
+
treeEach([tree.value.store.root], (node) => dataMap[node.key] = node, (node) => node.childNodes);
|
|
112
111
|
const uncachedCheckedKeys = params.checkedKeys;
|
|
113
|
-
const cachedKeys = props.multiple ? toValidArray(props.modelValue).filter((item) => item in
|
|
114
|
-
const checkedKeys =
|
|
112
|
+
const cachedKeys = props.multiple ? toValidArray(props.modelValue).filter((item) => !(item in dataMap) && !uncachedCheckedKeys.includes(item)) : [];
|
|
113
|
+
const checkedKeys = cachedKeys.concat(uncachedCheckedKeys);
|
|
115
114
|
if (props.checkStrictly) {
|
|
116
115
|
emit(UPDATE_MODEL_EVENT, props.multiple ? checkedKeys : checkedKeys.includes(dataValue) ? dataValue : void 0);
|
|
117
116
|
} else {
|
|
118
117
|
if (props.multiple) {
|
|
119
|
-
emit(UPDATE_MODEL_EVENT, tree.value.getCheckedKeys(true));
|
|
118
|
+
emit(UPDATE_MODEL_EVENT, cachedKeys.concat(tree.value.getCheckedKeys(true)));
|
|
120
119
|
} else {
|
|
121
120
|
const firstLeaf = treeFind([data], (data2) => !isValidArray(getNodeValByProp("children", data2)) && !getNodeValByProp("disabled", data2), (data2) => getNodeValByProp("children", data2));
|
|
122
121
|
const firstLeafKey = firstLeaf ? getNodeValByProp("value", firstLeaf) : void 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tree.mjs","sources":["../../../../../../packages/components/tree-select/src/tree.ts"],"sourcesContent":["// @ts-nocheck\nimport { computed, nextTick, toRefs, watch } from 'vue'\nimport { isEqual, pick } from 'lodash-unified'\nimport { UPDATE_MODEL_EVENT } from '@element-plus/constants'\nimport { escapeStringRegexp, isFunction } from '@element-plus/utils'\nimport ElTree from '@element-plus/components/tree'\nimport TreeSelectOption from './tree-select-option'\nimport {\n isValidArray,\n isValidValue,\n toValidArray,\n treeEach,\n treeFind,\n} from './utils'\nimport type { CacheOption } from './cache-options'\nimport type { Ref } from 'vue'\nimport type ElSelect from '@element-plus/components/select'\nimport type Node from '@element-plus/components/tree/src/model/node'\nimport type { TreeNodeData } from '@element-plus/components/tree/src/tree.type'\n\nexport const useTree = (\n props,\n { attrs, slots, emit },\n {\n select,\n tree,\n key,\n }: {\n select: Ref<InstanceType<typeof ElSelect> | undefined>\n tree: Ref<InstanceType<typeof ElTree> | undefined>\n key: Ref<string>\n }\n) => {\n watch(\n () => props.modelValue,\n () => {\n if (props.showCheckbox) {\n nextTick(() => {\n const treeInstance = tree.value\n if (\n treeInstance &&\n !isEqual(\n treeInstance.getCheckedKeys(),\n toValidArray(props.modelValue)\n )\n ) {\n treeInstance.setCheckedKeys(toValidArray(props.modelValue))\n }\n })\n }\n },\n {\n immediate: true,\n deep: true,\n }\n )\n\n const propsMap = computed(() => ({\n value: key.value,\n label: 'label',\n children: 'children',\n disabled: 'disabled',\n isLeaf: 'isLeaf',\n ...props.props,\n }))\n\n const getNodeValByProp = (\n prop: 'value' | 'label' | 'children' | 'disabled' | 'isLeaf',\n data: TreeNodeData\n ) => {\n const propVal = propsMap.value[prop]\n if (isFunction(propVal)) {\n return propVal(\n data,\n tree.value?.getNode(getNodeValByProp('value', data)) as Node\n )\n } else {\n return data[propVal as string]\n }\n }\n\n const defaultExpandedParentKeys = toValidArray(props.modelValue)\n .map((value) => {\n return treeFind(\n props.data || [],\n (data) => getNodeValByProp('value', data) === value,\n (data) => getNodeValByProp('children', data),\n (data, index, array, parent) =>\n parent && getNodeValByProp('value', parent)\n )\n })\n .filter((item) => isValidValue(item))\n\n const cacheOptions = computed(() => {\n if (!props.renderAfterExpand && !props.lazy) return []\n\n const options: CacheOption[] = []\n\n treeEach(\n props.data.concat(props.cacheData),\n (node) => {\n const value = getNodeValByProp('value', node)\n options.push({\n value,\n currentLabel: getNodeValByProp('label', node),\n isDisabled: getNodeValByProp('disabled', node),\n })\n },\n (data) => getNodeValByProp('children', data)\n )\n\n return options\n })\n\n const cacheOptionsMap = computed(() => {\n return cacheOptions.value.reduce(\n (prev, next) => ({ ...prev, [next.value]: next }),\n {}\n )\n })\n\n return {\n ...pick(toRefs(props), Object.keys(ElTree.props)),\n ...attrs,\n nodeKey: key,\n\n // only expand on click node when the `check-strictly` is false\n expandOnClickNode: computed(() => {\n return !props.checkStrictly && props.expandOnClickNode\n }),\n\n // show current selected node only first time,\n // fix the problem of expanding multiple nodes when checking multiple nodes\n defaultExpandedKeys: computed(() => {\n return props.defaultExpandedKeys\n ? props.defaultExpandedKeys.concat(defaultExpandedParentKeys)\n : defaultExpandedParentKeys\n }),\n\n renderContent: (h, { node, data, store }) => {\n return h(\n TreeSelectOption,\n {\n value: getNodeValByProp('value', data),\n label: getNodeValByProp('label', data),\n disabled: getNodeValByProp('disabled', data),\n },\n props.renderContent\n ? () => props.renderContent(h, { node, data, store })\n : slots.default\n ? () => slots.default({ node, data, store })\n : undefined\n )\n },\n filterNodeMethod: (value, data, node) => {\n if (props.filterNodeMethod)\n return props.filterNodeMethod(value, data, node)\n if (!value) return true\n const regexp = new RegExp(escapeStringRegexp(value), 'i')\n return regexp.test(getNodeValByProp('label', data) || '')\n },\n onNodeClick: (data, node, e) => {\n attrs.onNodeClick?.(data, node, e)\n\n // `onCheck` is trigger when `checkOnClickNode`\n if (props.showCheckbox && props.checkOnClickNode) return\n\n // now `checkOnClickNode` is false, only no checkbox and `checkStrictly` or `isLeaf`\n if (!props.showCheckbox && (props.checkStrictly || node.isLeaf)) {\n if (!getNodeValByProp('disabled', data)) {\n const option = select.value?.states.options.get(\n getNodeValByProp('value', data)\n )\n select.value?.handleOptionSelect(option)\n }\n } else if (props.expandOnClickNode) {\n e.proxy.handleExpandIconClick()\n }\n select.value?.focus()\n },\n onCheck: (data, params) => {\n // ignore when no checkbox, like only `checkOnClickNode` is true\n if (!props.showCheckbox) return\n\n const dataValue = getNodeValByProp('value', data)\n\n // fix: checkedKeys has not cached keys\n const uncachedCheckedKeys = params.checkedKeys\n const cachedKeys = props.multiple\n ? toValidArray(props.modelValue).filter(\n (item) =>\n item in cacheOptionsMap.value &&\n !tree.value.getNode(item) &&\n !uncachedCheckedKeys.includes(item)\n )\n : []\n const checkedKeys = uncachedCheckedKeys.concat(cachedKeys)\n\n if (props.checkStrictly) {\n emit(\n UPDATE_MODEL_EVENT,\n // Checking for changes may come from `check-on-node-click`\n props.multiple\n ? checkedKeys\n : checkedKeys.includes(dataValue)\n ? dataValue\n : undefined\n )\n }\n // only can select leaf node\n else {\n if (props.multiple) {\n emit(\n UPDATE_MODEL_EVENT,\n (tree.value as InstanceType<typeof ElTree>).getCheckedKeys(true)\n )\n } else {\n // select first leaf node when check parent\n const firstLeaf = treeFind(\n [data],\n (data) =>\n !isValidArray(getNodeValByProp('children', data)) &&\n !getNodeValByProp('disabled', data),\n (data) => getNodeValByProp('children', data)\n )\n const firstLeafKey = firstLeaf\n ? getNodeValByProp('value', firstLeaf)\n : undefined\n\n // unselect when any child checked\n const hasCheckedChild =\n isValidValue(props.modelValue) &&\n !!treeFind(\n [data],\n (data) => getNodeValByProp('value', data) === props.modelValue,\n (data) => getNodeValByProp('children', data)\n )\n\n emit(\n UPDATE_MODEL_EVENT,\n firstLeafKey === props.modelValue || hasCheckedChild\n ? undefined\n : firstLeafKey\n )\n }\n }\n\n nextTick(() => {\n const checkedKeys = toValidArray(props.modelValue)\n tree.value.setCheckedKeys(checkedKeys)\n\n attrs.onCheck?.(data, {\n checkedKeys: tree.value.getCheckedKeys(),\n checkedNodes: tree.value.getCheckedNodes(),\n halfCheckedKeys: tree.value.getHalfCheckedKeys(),\n halfCheckedNodes: tree.value.getHalfCheckedNodes(),\n })\n })\n\n select.value?.focus()\n },\n\n // else\n cacheOptions,\n }\n}\n"],"names":["ElTree","TreeSelectOption"],"mappings":";;;;;;;;;;;AAaY,MAAC,OAAO,GAAG,CAAC,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE;AACvD,EAAE,MAAM;AACR,EAAE,IAAI;AACN,EAAE,GAAG;AACL,CAAC,KAAK;AACN,EAAE,KAAK,CAAC,MAAM,KAAK,CAAC,UAAU,EAAE,MAAM;AACtC,IAAI,IAAI,KAAK,CAAC,YAAY,EAAE;AAC5B,MAAM,QAAQ,CAAC,MAAM;AACrB,QAAQ,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAAC;AACxC,QAAQ,IAAI,YAAY,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,cAAc,EAAE,EAAE,YAAY,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC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AI,EAAE;AACvE,UAAU,WAAW,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE;AAClD,UAAU,YAAY,EAAE,IAAI,CAAC,KAAK,CAAC,eAAe,EAAE;AACpD,UAAU,eAAe,EAAE,IAAI,CAAC,KAAK,CAAC,kBAAkB,EAAE;AAC1D,UAAU,gBAAgB,EAAE,IAAI,CAAC,KAAK,CAAC,mBAAmB,EAAE;AAC5D,SAAS,CAAC,CAAC;AACX,OAAO,CAAC,CAAC;AACT,MAAM,CAAC,EAAE,GAAG,MAAM,CAAC,KAAK,KAAK,IAAI,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,KAAK,EAAE,CAAC;AACxD,KAAK;AACL,IAAI,YAAY;AAChB,GAAG,CAAC;AACJ;;;;"}
|
|
1
|
+
{"version":3,"file":"tree.mjs","sources":["../../../../../../packages/components/tree-select/src/tree.ts"],"sourcesContent":["// @ts-nocheck\nimport { computed, nextTick, toRefs, watch } from 'vue'\nimport { isEqual, pick } from 'lodash-unified'\nimport { UPDATE_MODEL_EVENT } from '@element-plus/constants'\nimport { escapeStringRegexp, isFunction } from '@element-plus/utils'\nimport ElTree from '@element-plus/components/tree'\nimport TreeSelectOption from './tree-select-option'\nimport {\n isValidArray,\n isValidValue,\n toValidArray,\n treeEach,\n treeFind,\n} from './utils'\nimport type { CacheOption } from './cache-options'\nimport type { Ref } from 'vue'\nimport type ElSelect from '@element-plus/components/select'\nimport type Node from '@element-plus/components/tree/src/model/node'\nimport type { TreeNodeData } from '@element-plus/components/tree/src/tree.type'\n\nexport const useTree = (\n props,\n { attrs, slots, emit },\n {\n select,\n tree,\n key,\n }: {\n select: Ref<InstanceType<typeof ElSelect> | undefined>\n tree: Ref<InstanceType<typeof ElTree> | undefined>\n key: Ref<string>\n }\n) => {\n watch(\n () => props.modelValue,\n () => {\n if (props.showCheckbox) {\n nextTick(() => {\n const treeInstance = tree.value\n if (\n treeInstance &&\n !isEqual(\n treeInstance.getCheckedKeys(),\n toValidArray(props.modelValue)\n )\n ) {\n treeInstance.setCheckedKeys(toValidArray(props.modelValue))\n }\n })\n }\n },\n {\n immediate: true,\n deep: true,\n }\n )\n\n const propsMap = computed(() => ({\n value: key.value,\n label: 'label',\n children: 'children',\n disabled: 'disabled',\n isLeaf: 'isLeaf',\n ...props.props,\n }))\n\n const getNodeValByProp = (\n prop: 'value' | 'label' | 'children' | 'disabled' | 'isLeaf',\n data: TreeNodeData\n ) => {\n const propVal = propsMap.value[prop]\n if (isFunction(propVal)) {\n return propVal(\n data,\n tree.value?.getNode(getNodeValByProp('value', data)) as Node\n )\n } else {\n return data[propVal as string]\n }\n }\n\n const defaultExpandedParentKeys = toValidArray(props.modelValue)\n .map((value) => {\n return treeFind(\n props.data || [],\n (data) => getNodeValByProp('value', data) === value,\n (data) => getNodeValByProp('children', data),\n (data, index, array, parent) =>\n parent && getNodeValByProp('value', parent)\n )\n })\n .filter((item) => isValidValue(item))\n\n const cacheOptions = computed(() => {\n if (!props.renderAfterExpand && !props.lazy) return []\n\n const options: CacheOption[] = []\n\n treeEach(\n props.data.concat(props.cacheData),\n (node) => {\n const value = getNodeValByProp('value', node)\n options.push({\n value,\n currentLabel: getNodeValByProp('label', node),\n isDisabled: getNodeValByProp('disabled', node),\n })\n },\n (data) => getNodeValByProp('children', data)\n )\n\n return options\n })\n\n return {\n ...pick(toRefs(props), Object.keys(ElTree.props)),\n ...attrs,\n nodeKey: key,\n\n // only expand on click node when the `check-strictly` is false\n expandOnClickNode: computed(() => {\n return !props.checkStrictly && props.expandOnClickNode\n }),\n\n // show current selected node only first time,\n // fix the problem of expanding multiple nodes when checking multiple nodes\n defaultExpandedKeys: computed(() => {\n return props.defaultExpandedKeys\n ? props.defaultExpandedKeys.concat(defaultExpandedParentKeys)\n : defaultExpandedParentKeys\n }),\n\n renderContent: (h, { node, data, store }) => {\n return h(\n TreeSelectOption,\n {\n value: getNodeValByProp('value', data),\n label: getNodeValByProp('label', data),\n disabled: getNodeValByProp('disabled', data),\n },\n props.renderContent\n ? () => props.renderContent(h, { node, data, store })\n : slots.default\n ? () => slots.default({ node, data, store })\n : undefined\n )\n },\n filterNodeMethod: (value, data, node) => {\n if (props.filterNodeMethod)\n return props.filterNodeMethod(value, data, node)\n if (!value) return true\n const regexp = new RegExp(escapeStringRegexp(value), 'i')\n return regexp.test(getNodeValByProp('label', data) || '')\n },\n onNodeClick: (data, node, e) => {\n attrs.onNodeClick?.(data, node, e)\n\n // `onCheck` is trigger when `checkOnClickNode`\n if (props.showCheckbox && props.checkOnClickNode) return\n\n // now `checkOnClickNode` is false, only no checkbox and `checkStrictly` or `isLeaf`\n if (!props.showCheckbox && (props.checkStrictly || node.isLeaf)) {\n if (!getNodeValByProp('disabled', data)) {\n const option = select.value?.states.options.get(\n getNodeValByProp('value', data)\n )\n select.value?.handleOptionSelect(option)\n }\n } else if (props.expandOnClickNode) {\n e.proxy.handleExpandIconClick()\n }\n select.value?.focus()\n },\n onCheck: (data, params) => {\n // ignore when no checkbox, like only `checkOnClickNode` is true\n if (!props.showCheckbox) return\n\n const dataValue = getNodeValByProp('value', data)\n const dataMap = {}\n treeEach(\n [tree.value.store.root],\n (node) => (dataMap[node.key] = node),\n (node) => node.childNodes\n )\n\n // fix: checkedKeys has not cached keys\n const uncachedCheckedKeys = params.checkedKeys\n const cachedKeys = props.multiple\n ? toValidArray(props.modelValue).filter(\n (item) => !(item in dataMap) && !uncachedCheckedKeys.includes(item)\n )\n : []\n const checkedKeys = cachedKeys.concat(uncachedCheckedKeys)\n\n if (props.checkStrictly) {\n emit(\n UPDATE_MODEL_EVENT,\n // Checking for changes may come from `check-on-node-click`\n props.multiple\n ? checkedKeys\n : checkedKeys.includes(dataValue)\n ? dataValue\n : undefined\n )\n }\n // only can select leaf node\n else {\n if (props.multiple) {\n emit(\n UPDATE_MODEL_EVENT,\n cachedKeys.concat(\n (tree.value as InstanceType<typeof ElTree>).getCheckedKeys(true)\n )\n )\n } else {\n // select first leaf node when check parent\n const firstLeaf = treeFind(\n [data],\n (data) =>\n !isValidArray(getNodeValByProp('children', data)) &&\n !getNodeValByProp('disabled', data),\n (data) => getNodeValByProp('children', data)\n )\n const firstLeafKey = firstLeaf\n ? getNodeValByProp('value', firstLeaf)\n : undefined\n\n // unselect when any child checked\n const hasCheckedChild =\n isValidValue(props.modelValue) &&\n !!treeFind(\n [data],\n (data) => getNodeValByProp('value', data) === props.modelValue,\n (data) => getNodeValByProp('children', data)\n )\n\n emit(\n UPDATE_MODEL_EVENT,\n firstLeafKey === props.modelValue || hasCheckedChild\n ? undefined\n : firstLeafKey\n )\n }\n }\n\n nextTick(() => {\n const checkedKeys = toValidArray(props.modelValue)\n tree.value.setCheckedKeys(checkedKeys)\n\n attrs.onCheck?.(data, {\n checkedKeys: tree.value.getCheckedKeys(),\n checkedNodes: tree.value.getCheckedNodes(),\n halfCheckedKeys: tree.value.getHalfCheckedKeys(),\n halfCheckedNodes: tree.value.getHalfCheckedNodes(),\n })\n })\n\n select.value?.focus()\n },\n\n // else\n cacheOptions,\n }\n}\n"],"names":["ElTree","TreeSelectOption"],"mappings":";;;;;;;;;;;AAaY,MAAC,OAAO,GAAG,CAAC,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE;AACvD,EAAE,MAAM;AACR,EAAE,IAAI;AACN,EAAE,GAAG;AACL,CAAC,KAAK;AACN,EAAE,KAAK,CAAC,MAAM,KAAK,CAAC,UAAU,EAAE,MAAM;AACtC,IAAI,IAAI,KAAK,CAAC,YAAY,EAAE;AAC5B,MAAM,QAAQ,CAAC,MAAM;AACrB,QAAQ,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAAC;AACxC,QAAQ,IAAI,YAAY,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,cAAc,EAAE,EAAE,YAAY,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,EAAE;AACrG,UAAU,YAAY,CAAC,cAAc,CAAC,YAAY,CAAC,KAAK,CAAC,UAAU,CAAC,C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C,eAAe,EAAE;AACpD,UAAU,eAAe,EAAE,IAAI,CAAC,KAAK,CAAC,kBAAkB,EAAE;AAC1D,UAAU,gBAAgB,EAAE,IAAI,CAAC,KAAK,CAAC,mBAAmB,EAAE;AAC5D,SAAS,CAAC,CAAC;AACX,OAAO,CAAC,CAAC;AACT,MAAM,CAAC,EAAE,GAAG,MAAM,CAAC,KAAK,KAAK,IAAI,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC,KAAK,EAAE,CAAC;AACxD,KAAK;AACL,IAAI,YAAY;AAChB,GAAG,CAAC;AACJ;;;;"}
|
|
@@ -442,6 +442,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
442
442
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
443
443
|
default: undefined;
|
|
444
444
|
};
|
|
445
|
+
value: {
|
|
446
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
447
|
+
default: undefined;
|
|
448
|
+
};
|
|
445
449
|
indeterminate: BooleanConstructor;
|
|
446
450
|
disabled: BooleanConstructor;
|
|
447
451
|
checked: BooleanConstructor;
|
|
@@ -449,6 +453,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
449
453
|
type: StringConstructor;
|
|
450
454
|
default: undefined;
|
|
451
455
|
};
|
|
456
|
+
trueValue: {
|
|
457
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
458
|
+
default: undefined;
|
|
459
|
+
};
|
|
460
|
+
falseValue: {
|
|
461
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
462
|
+
default: undefined;
|
|
463
|
+
};
|
|
452
464
|
trueLabel: {
|
|
453
465
|
type: (NumberConstructor | StringConstructor)[];
|
|
454
466
|
default: undefined;
|
|
@@ -487,6 +499,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
487
499
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
488
500
|
default: undefined;
|
|
489
501
|
};
|
|
502
|
+
value: {
|
|
503
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
504
|
+
default: undefined;
|
|
505
|
+
};
|
|
490
506
|
indeterminate: BooleanConstructor;
|
|
491
507
|
disabled: BooleanConstructor;
|
|
492
508
|
checked: BooleanConstructor;
|
|
@@ -494,6 +510,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
494
510
|
type: StringConstructor;
|
|
495
511
|
default: undefined;
|
|
496
512
|
};
|
|
513
|
+
trueValue: {
|
|
514
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
515
|
+
default: undefined;
|
|
516
|
+
};
|
|
517
|
+
falseValue: {
|
|
518
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
519
|
+
default: undefined;
|
|
520
|
+
};
|
|
497
521
|
trueLabel: {
|
|
498
522
|
type: (NumberConstructor | StringConstructor)[];
|
|
499
523
|
default: undefined;
|
|
@@ -537,6 +561,7 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
537
561
|
checkboxSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
538
562
|
hasOwnLabel: import("vue").ComputedRef<boolean>;
|
|
539
563
|
model: import("vue").WritableComputedRef<any>;
|
|
564
|
+
actualValue: import("vue").ComputedRef<string | number | boolean | Record<string, any> | undefined>;
|
|
540
565
|
handleChange: (e: Event) => void;
|
|
541
566
|
onClickRoot: (e: MouseEvent) => Promise<void>;
|
|
542
567
|
ns: {
|
|
@@ -571,6 +596,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
571
596
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
572
597
|
default: undefined;
|
|
573
598
|
};
|
|
599
|
+
value: {
|
|
600
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
601
|
+
default: undefined;
|
|
602
|
+
};
|
|
574
603
|
indeterminate: BooleanConstructor;
|
|
575
604
|
disabled: BooleanConstructor;
|
|
576
605
|
checked: BooleanConstructor;
|
|
@@ -578,6 +607,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
578
607
|
type: StringConstructor;
|
|
579
608
|
default: undefined;
|
|
580
609
|
};
|
|
610
|
+
trueValue: {
|
|
611
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
612
|
+
default: undefined;
|
|
613
|
+
};
|
|
614
|
+
falseValue: {
|
|
615
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
616
|
+
default: undefined;
|
|
617
|
+
};
|
|
581
618
|
trueLabel: {
|
|
582
619
|
type: (NumberConstructor | StringConstructor)[];
|
|
583
620
|
default: undefined;
|
|
@@ -610,6 +647,7 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
610
647
|
onChange?: ((val: import("..").CheckboxValueType) => any) | undefined;
|
|
611
648
|
"onUpdate:modelValue"?: ((val: import("..").CheckboxValueType) => any) | undefined;
|
|
612
649
|
}, {
|
|
650
|
+
value: string | number | boolean | Record<string, any>;
|
|
613
651
|
modelValue: string | number | boolean;
|
|
614
652
|
label: string | number | boolean | Record<string, any>;
|
|
615
653
|
id: string;
|
|
@@ -619,6 +657,8 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
619
657
|
border: boolean;
|
|
620
658
|
indeterminate: boolean;
|
|
621
659
|
checked: boolean;
|
|
660
|
+
trueValue: string | number;
|
|
661
|
+
falseValue: string | number;
|
|
622
662
|
trueLabel: string | number;
|
|
623
663
|
falseLabel: string | number;
|
|
624
664
|
controls: string;
|
|
@@ -632,6 +672,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
632
672
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
633
673
|
default: undefined;
|
|
634
674
|
};
|
|
675
|
+
value: {
|
|
676
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
677
|
+
default: undefined;
|
|
678
|
+
};
|
|
635
679
|
indeterminate: BooleanConstructor;
|
|
636
680
|
disabled: BooleanConstructor;
|
|
637
681
|
checked: BooleanConstructor;
|
|
@@ -639,6 +683,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
639
683
|
type: StringConstructor;
|
|
640
684
|
default: undefined;
|
|
641
685
|
};
|
|
686
|
+
trueValue: {
|
|
687
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
688
|
+
default: undefined;
|
|
689
|
+
};
|
|
690
|
+
falseValue: {
|
|
691
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
692
|
+
default: undefined;
|
|
693
|
+
};
|
|
642
694
|
trueLabel: {
|
|
643
695
|
type: (NumberConstructor | StringConstructor)[];
|
|
644
696
|
default: undefined;
|
|
@@ -677,6 +729,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
677
729
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
678
730
|
default: undefined;
|
|
679
731
|
};
|
|
732
|
+
value: {
|
|
733
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
734
|
+
default: undefined;
|
|
735
|
+
};
|
|
680
736
|
indeterminate: BooleanConstructor;
|
|
681
737
|
disabled: BooleanConstructor;
|
|
682
738
|
checked: BooleanConstructor;
|
|
@@ -684,6 +740,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
684
740
|
type: StringConstructor;
|
|
685
741
|
default: undefined;
|
|
686
742
|
};
|
|
743
|
+
trueValue: {
|
|
744
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
745
|
+
default: undefined;
|
|
746
|
+
};
|
|
747
|
+
falseValue: {
|
|
748
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
749
|
+
default: undefined;
|
|
750
|
+
};
|
|
687
751
|
trueLabel: {
|
|
688
752
|
type: (NumberConstructor | StringConstructor)[];
|
|
689
753
|
default: undefined;
|
|
@@ -724,6 +788,7 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
724
788
|
isDisabled: import("vue").ComputedRef<boolean>;
|
|
725
789
|
checkboxButtonSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
726
790
|
model: import("vue").WritableComputedRef<any>;
|
|
791
|
+
actualValue: import("vue").ComputedRef<string | number | boolean | Record<string, any> | undefined>;
|
|
727
792
|
handleChange: (e: Event) => void;
|
|
728
793
|
checkboxGroup: ({
|
|
729
794
|
modelValue?: import("vue").WritableComputedRef<any> | undefined;
|
|
@@ -761,6 +826,10 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
761
826
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
762
827
|
default: undefined;
|
|
763
828
|
};
|
|
829
|
+
value: {
|
|
830
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
831
|
+
default: undefined;
|
|
832
|
+
};
|
|
764
833
|
indeterminate: BooleanConstructor;
|
|
765
834
|
disabled: BooleanConstructor;
|
|
766
835
|
checked: BooleanConstructor;
|
|
@@ -768,6 +837,14 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
768
837
|
type: StringConstructor;
|
|
769
838
|
default: undefined;
|
|
770
839
|
};
|
|
840
|
+
trueValue: {
|
|
841
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
842
|
+
default: undefined;
|
|
843
|
+
};
|
|
844
|
+
falseValue: {
|
|
845
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
846
|
+
default: undefined;
|
|
847
|
+
};
|
|
771
848
|
trueLabel: {
|
|
772
849
|
type: (NumberConstructor | StringConstructor)[];
|
|
773
850
|
default: undefined;
|
|
@@ -800,6 +877,7 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
800
877
|
onChange?: ((val: import("..").CheckboxValueType) => any) | undefined;
|
|
801
878
|
"onUpdate:modelValue"?: ((val: import("..").CheckboxValueType) => any) | undefined;
|
|
802
879
|
}, {
|
|
880
|
+
value: string | number | boolean | Record<string, any>;
|
|
803
881
|
modelValue: string | number | boolean;
|
|
804
882
|
label: string | number | boolean | Record<string, any>;
|
|
805
883
|
id: string;
|
|
@@ -809,6 +887,8 @@ export declare const ElTreeV2: import("@element-plus/nightly/es/utils").SFCWithI
|
|
|
809
887
|
border: boolean;
|
|
810
888
|
indeterminate: boolean;
|
|
811
889
|
checked: boolean;
|
|
890
|
+
trueValue: string | number;
|
|
891
|
+
falseValue: string | number;
|
|
812
892
|
trueLabel: string | number;
|
|
813
893
|
falseLabel: string | number;
|
|
814
894
|
controls: string;
|
|
@@ -131,6 +131,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
131
131
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
132
132
|
default: undefined;
|
|
133
133
|
};
|
|
134
|
+
value: {
|
|
135
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
136
|
+
default: undefined;
|
|
137
|
+
};
|
|
134
138
|
indeterminate: BooleanConstructor;
|
|
135
139
|
disabled: BooleanConstructor;
|
|
136
140
|
checked: BooleanConstructor;
|
|
@@ -138,6 +142,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
138
142
|
type: StringConstructor;
|
|
139
143
|
default: undefined;
|
|
140
144
|
};
|
|
145
|
+
trueValue: {
|
|
146
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
147
|
+
default: undefined;
|
|
148
|
+
};
|
|
149
|
+
falseValue: {
|
|
150
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
151
|
+
default: undefined;
|
|
152
|
+
};
|
|
141
153
|
trueLabel: {
|
|
142
154
|
type: (NumberConstructor | StringConstructor)[];
|
|
143
155
|
default: undefined;
|
|
@@ -176,6 +188,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
176
188
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
177
189
|
default: undefined;
|
|
178
190
|
};
|
|
191
|
+
value: {
|
|
192
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
193
|
+
default: undefined;
|
|
194
|
+
};
|
|
179
195
|
indeterminate: BooleanConstructor;
|
|
180
196
|
disabled: BooleanConstructor;
|
|
181
197
|
checked: BooleanConstructor;
|
|
@@ -183,6 +199,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
183
199
|
type: StringConstructor;
|
|
184
200
|
default: undefined;
|
|
185
201
|
};
|
|
202
|
+
trueValue: {
|
|
203
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
204
|
+
default: undefined;
|
|
205
|
+
};
|
|
206
|
+
falseValue: {
|
|
207
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
208
|
+
default: undefined;
|
|
209
|
+
};
|
|
186
210
|
trueLabel: {
|
|
187
211
|
type: (NumberConstructor | StringConstructor)[];
|
|
188
212
|
default: undefined;
|
|
@@ -226,6 +250,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
226
250
|
checkboxSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
227
251
|
hasOwnLabel: import("vue").ComputedRef<boolean>;
|
|
228
252
|
model: import("vue").WritableComputedRef<any>;
|
|
253
|
+
actualValue: import("vue").ComputedRef<string | number | boolean | Record<string, any> | undefined>;
|
|
229
254
|
handleChange: (e: Event) => void;
|
|
230
255
|
onClickRoot: (e: MouseEvent) => Promise<void>;
|
|
231
256
|
ns: {
|
|
@@ -260,6 +285,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
260
285
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
261
286
|
default: undefined;
|
|
262
287
|
};
|
|
288
|
+
value: {
|
|
289
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
290
|
+
default: undefined;
|
|
291
|
+
};
|
|
263
292
|
indeterminate: BooleanConstructor;
|
|
264
293
|
disabled: BooleanConstructor;
|
|
265
294
|
checked: BooleanConstructor;
|
|
@@ -267,6 +296,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
267
296
|
type: StringConstructor;
|
|
268
297
|
default: undefined;
|
|
269
298
|
};
|
|
299
|
+
trueValue: {
|
|
300
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
301
|
+
default: undefined;
|
|
302
|
+
};
|
|
303
|
+
falseValue: {
|
|
304
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
305
|
+
default: undefined;
|
|
306
|
+
};
|
|
270
307
|
trueLabel: {
|
|
271
308
|
type: (NumberConstructor | StringConstructor)[];
|
|
272
309
|
default: undefined;
|
|
@@ -299,6 +336,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
299
336
|
onChange?: ((val: CheckboxValueType) => any) | undefined;
|
|
300
337
|
"onUpdate:modelValue"?: ((val: CheckboxValueType) => any) | undefined;
|
|
301
338
|
}, {
|
|
339
|
+
value: string | number | boolean | Record<string, any>;
|
|
302
340
|
modelValue: string | number | boolean;
|
|
303
341
|
label: string | number | boolean | Record<string, any>;
|
|
304
342
|
id: string;
|
|
@@ -308,6 +346,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
308
346
|
border: boolean;
|
|
309
347
|
indeterminate: boolean;
|
|
310
348
|
checked: boolean;
|
|
349
|
+
trueValue: string | number;
|
|
350
|
+
falseValue: string | number;
|
|
311
351
|
trueLabel: string | number;
|
|
312
352
|
falseLabel: string | number;
|
|
313
353
|
controls: string;
|
|
@@ -321,6 +361,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
321
361
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
322
362
|
default: undefined;
|
|
323
363
|
};
|
|
364
|
+
value: {
|
|
365
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
366
|
+
default: undefined;
|
|
367
|
+
};
|
|
324
368
|
indeterminate: BooleanConstructor;
|
|
325
369
|
disabled: BooleanConstructor;
|
|
326
370
|
checked: BooleanConstructor;
|
|
@@ -328,6 +372,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
328
372
|
type: StringConstructor;
|
|
329
373
|
default: undefined;
|
|
330
374
|
};
|
|
375
|
+
trueValue: {
|
|
376
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
377
|
+
default: undefined;
|
|
378
|
+
};
|
|
379
|
+
falseValue: {
|
|
380
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
381
|
+
default: undefined;
|
|
382
|
+
};
|
|
331
383
|
trueLabel: {
|
|
332
384
|
type: (NumberConstructor | StringConstructor)[];
|
|
333
385
|
default: undefined;
|
|
@@ -366,6 +418,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
366
418
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
367
419
|
default: undefined;
|
|
368
420
|
};
|
|
421
|
+
value: {
|
|
422
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
423
|
+
default: undefined;
|
|
424
|
+
};
|
|
369
425
|
indeterminate: BooleanConstructor;
|
|
370
426
|
disabled: BooleanConstructor;
|
|
371
427
|
checked: BooleanConstructor;
|
|
@@ -373,6 +429,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
373
429
|
type: StringConstructor;
|
|
374
430
|
default: undefined;
|
|
375
431
|
};
|
|
432
|
+
trueValue: {
|
|
433
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
434
|
+
default: undefined;
|
|
435
|
+
};
|
|
436
|
+
falseValue: {
|
|
437
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
438
|
+
default: undefined;
|
|
439
|
+
};
|
|
376
440
|
trueLabel: {
|
|
377
441
|
type: (NumberConstructor | StringConstructor)[];
|
|
378
442
|
default: undefined;
|
|
@@ -413,6 +477,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
413
477
|
isDisabled: import("vue").ComputedRef<boolean>;
|
|
414
478
|
checkboxButtonSize: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
415
479
|
model: import("vue").WritableComputedRef<any>;
|
|
480
|
+
actualValue: import("vue").ComputedRef<string | number | boolean | Record<string, any> | undefined>;
|
|
416
481
|
handleChange: (e: Event) => void;
|
|
417
482
|
checkboxGroup: ({
|
|
418
483
|
modelValue?: import("vue").WritableComputedRef<any> | undefined;
|
|
@@ -450,6 +515,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
450
515
|
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
451
516
|
default: undefined;
|
|
452
517
|
};
|
|
518
|
+
value: {
|
|
519
|
+
type: (ObjectConstructor | NumberConstructor | BooleanConstructor | StringConstructor)[];
|
|
520
|
+
default: undefined;
|
|
521
|
+
};
|
|
453
522
|
indeterminate: BooleanConstructor;
|
|
454
523
|
disabled: BooleanConstructor;
|
|
455
524
|
checked: BooleanConstructor;
|
|
@@ -457,6 +526,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
457
526
|
type: StringConstructor;
|
|
458
527
|
default: undefined;
|
|
459
528
|
};
|
|
529
|
+
trueValue: {
|
|
530
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
531
|
+
default: undefined;
|
|
532
|
+
};
|
|
533
|
+
falseValue: {
|
|
534
|
+
type: (NumberConstructor | StringConstructor)[];
|
|
535
|
+
default: undefined;
|
|
536
|
+
};
|
|
460
537
|
trueLabel: {
|
|
461
538
|
type: (NumberConstructor | StringConstructor)[];
|
|
462
539
|
default: undefined;
|
|
@@ -489,6 +566,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
489
566
|
onChange?: ((val: CheckboxValueType) => any) | undefined;
|
|
490
567
|
"onUpdate:modelValue"?: ((val: CheckboxValueType) => any) | undefined;
|
|
491
568
|
}, {
|
|
569
|
+
value: string | number | boolean | Record<string, any>;
|
|
492
570
|
modelValue: string | number | boolean;
|
|
493
571
|
label: string | number | boolean | Record<string, any>;
|
|
494
572
|
id: string;
|
|
@@ -498,6 +576,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
498
576
|
border: boolean;
|
|
499
577
|
indeterminate: boolean;
|
|
500
578
|
checked: boolean;
|
|
579
|
+
trueValue: string | number;
|
|
580
|
+
falseValue: string | number;
|
|
501
581
|
trueLabel: string | number;
|
|
502
582
|
falseLabel: string | number;
|
|
503
583
|
controls: string;
|