element-plus 2.4.0 → 2.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/attributes.json +1 -1
- package/dist/index.css +1 -1
- package/dist/index.full.js +169 -123
- package/dist/index.full.min.js +22 -22
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +22 -22
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +168 -124
- 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.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 +174 -0
- package/dist/locale/sw.min.js +2 -0
- package/dist/locale/sw.min.js.map +1 -0
- package/dist/locale/sw.min.mjs +2 -0
- package/dist/locale/sw.min.mjs.map +1 -0
- package/dist/locale/sw.mjs +166 -0
- 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/carousel/src/use-carousel.mjs +2 -1
- package/es/components/carousel/src/use-carousel.mjs.map +1 -1
- package/es/components/dialog/src/use-dialog.mjs +6 -4
- package/es/components/dialog/src/use-dialog.mjs.map +1 -1
- package/es/components/index.d.ts +1 -0
- package/es/components/index.mjs +2 -0
- package/es/components/index.mjs.map +1 -1
- package/es/components/rate/src/rate2.mjs +14 -10
- package/es/components/rate/src/rate2.mjs.map +1 -1
- package/es/components/select/src/useSelect.mjs +1 -1
- package/es/components/select/src/useSelect.mjs.map +1 -1
- package/es/components/select-v2/index.d.ts +298 -464
- package/es/components/select-v2/src/defaults.d.ts +76 -110
- package/es/components/select-v2/src/defaults.mjs +25 -16
- package/es/components/select-v2/src/defaults.mjs.map +1 -1
- package/es/components/select-v2/src/option-item.mjs +8 -3
- package/es/components/select-v2/src/option-item.mjs.map +1 -1
- package/es/components/select-v2/src/option-item.vue.d.ts +31 -20
- package/es/components/select-v2/src/select-dropdown.mjs +10 -4
- package/es/components/select-v2/src/select-dropdown.mjs.map +1 -1
- package/es/components/select-v2/src/select.mjs +9 -9
- package/es/components/select-v2/src/select.mjs.map +1 -1
- package/es/components/select-v2/src/select.types.d.ts +5 -11
- package/es/components/select-v2/src/select.vue.d.ts +149 -232
- package/es/components/select-v2/src/token.d.ts +1 -1
- package/es/components/select-v2/src/token.mjs.map +1 -1
- package/es/components/select-v2/src/useAllowCreate.mjs +8 -6
- package/es/components/select-v2/src/useAllowCreate.mjs.map +1 -1
- package/es/components/select-v2/src/useProps.d.ts +21 -0
- package/es/components/select-v2/src/useProps.mjs +26 -0
- package/es/components/select-v2/src/useProps.mjs.map +1 -0
- package/es/components/select-v2/src/useSelect.d.ts +52 -58
- package/es/components/select-v2/src/useSelect.mjs +31 -31
- package/es/components/select-v2/src/useSelect.mjs.map +1 -1
- package/es/components/switch/index.d.ts +4 -0
- package/es/components/switch/src/switch.d.ts +1 -0
- package/es/components/switch/src/switch.mjs +4 -0
- package/es/components/switch/src/switch.mjs.map +1 -1
- package/es/components/switch/src/switch.vue.d.ts +4 -0
- package/es/components/switch/src/switch2.mjs +2 -1
- package/es/components/switch/src/switch2.mjs.map +1 -1
- package/es/components/tree-select/src/select.d.ts +2 -1
- package/es/components/tree-select/src/select.mjs +4 -1
- package/es/components/tree-select/src/select.mjs.map +1 -1
- package/es/components/upload/index.d.ts +18 -16
- package/es/components/upload/src/upload-content.d.ts +0 -1
- package/es/components/upload/src/upload-content.vue.d.ts +0 -4
- package/es/components/upload/src/upload-list.vue.d.ts +17 -0
- package/es/components/upload/src/upload-list2.mjs +8 -6
- package/es/components/upload/src/upload-list2.mjs.map +1 -1
- package/es/components/upload/src/upload.d.ts +9 -5
- package/es/components/upload/src/upload.mjs +0 -4
- package/es/components/upload/src/upload.mjs.map +1 -1
- package/es/components/upload/src/upload.vue.d.ts +18 -16
- package/es/components/watermark/index.d.ts +2 -0
- package/es/components/watermark/src/useClips.mjs +11 -3
- package/es/components/watermark/src/useClips.mjs.map +1 -1
- package/es/components/watermark/src/watermark.d.ts +2 -0
- package/es/components/watermark/src/watermark.mjs.map +1 -1
- package/es/components/watermark/src/watermark.vue.d.ts +2 -0
- package/es/components/watermark/src/watermark2.mjs +11 -1
- package/es/components/watermark/src/watermark2.mjs.map +1 -1
- package/es/components/watermark/style/css.d.ts +0 -0
- package/es/components/watermark/style/css.mjs +2 -0
- package/es/components/watermark/style/css.mjs.map +1 -0
- package/es/hooks/use-draggable/index.mjs +3 -1
- package/es/hooks/use-draggable/index.mjs.map +1 -1
- package/es/index.mjs +2 -0
- package/es/index.mjs.map +1 -1
- package/es/locale/lang/sw.d.ts +163 -0
- package/es/locale/lang/sw.mjs +165 -0
- package/es/locale/lang/sw.mjs.map +1 -0
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/global.d.ts +1 -0
- package/lib/components/carousel/src/use-carousel.js +2 -1
- package/lib/components/carousel/src/use-carousel.js.map +1 -1
- package/lib/components/dialog/src/use-dialog.js +6 -4
- package/lib/components/dialog/src/use-dialog.js.map +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/index.js +17 -13
- package/lib/components/index.js.map +1 -1
- package/lib/components/rate/src/rate2.js +14 -10
- package/lib/components/rate/src/rate2.js.map +1 -1
- package/lib/components/select/src/useSelect.js +1 -1
- package/lib/components/select/src/useSelect.js.map +1 -1
- package/lib/components/select-v2/index.d.ts +298 -464
- package/lib/components/select-v2/src/defaults.d.ts +76 -110
- package/lib/components/select-v2/src/defaults.js +25 -16
- package/lib/components/select-v2/src/defaults.js.map +1 -1
- package/lib/components/select-v2/src/option-item.js +7 -2
- package/lib/components/select-v2/src/option-item.js.map +1 -1
- package/lib/components/select-v2/src/option-item.vue.d.ts +31 -20
- package/lib/components/select-v2/src/select-dropdown.js +10 -4
- package/lib/components/select-v2/src/select-dropdown.js.map +1 -1
- package/lib/components/select-v2/src/select.js +9 -9
- package/lib/components/select-v2/src/select.js.map +1 -1
- package/lib/components/select-v2/src/select.types.d.ts +5 -11
- package/lib/components/select-v2/src/select.vue.d.ts +149 -232
- package/lib/components/select-v2/src/token.d.ts +1 -1
- package/lib/components/select-v2/src/token.js.map +1 -1
- package/lib/components/select-v2/src/useAllowCreate.js +8 -6
- package/lib/components/select-v2/src/useAllowCreate.js.map +1 -1
- package/lib/components/select-v2/src/useProps.d.ts +21 -0
- package/lib/components/select-v2/src/useProps.js +31 -0
- package/lib/components/select-v2/src/useProps.js.map +1 -0
- package/lib/components/select-v2/src/useSelect.d.ts +52 -58
- package/lib/components/select-v2/src/useSelect.js +31 -31
- package/lib/components/select-v2/src/useSelect.js.map +1 -1
- package/lib/components/switch/index.d.ts +4 -0
- package/lib/components/switch/src/switch.d.ts +1 -0
- package/lib/components/switch/src/switch.js +4 -0
- package/lib/components/switch/src/switch.js.map +1 -1
- package/lib/components/switch/src/switch.vue.d.ts +4 -0
- package/lib/components/switch/src/switch2.js +2 -1
- package/lib/components/switch/src/switch2.js.map +1 -1
- package/lib/components/tree-select/src/select.d.ts +2 -1
- package/lib/components/tree-select/src/select.js +4 -1
- package/lib/components/tree-select/src/select.js.map +1 -1
- package/lib/components/upload/index.d.ts +18 -16
- package/lib/components/upload/src/upload-content.d.ts +0 -1
- package/lib/components/upload/src/upload-content.vue.d.ts +0 -4
- package/lib/components/upload/src/upload-list.vue.d.ts +17 -0
- package/lib/components/upload/src/upload-list2.js +7 -5
- package/lib/components/upload/src/upload-list2.js.map +1 -1
- package/lib/components/upload/src/upload.d.ts +9 -5
- package/lib/components/upload/src/upload.js +0 -4
- package/lib/components/upload/src/upload.js.map +1 -1
- package/lib/components/upload/src/upload.vue.d.ts +18 -16
- package/lib/components/watermark/index.d.ts +2 -0
- package/lib/components/watermark/src/useClips.js +11 -3
- package/lib/components/watermark/src/useClips.js.map +1 -1
- package/lib/components/watermark/src/watermark.d.ts +2 -0
- package/lib/components/watermark/src/watermark.js.map +1 -1
- package/lib/components/watermark/src/watermark.vue.d.ts +2 -0
- package/lib/components/watermark/src/watermark2.js +11 -1
- package/lib/components/watermark/src/watermark2.js.map +1 -1
- package/lib/components/watermark/style/css.d.ts +0 -0
- package/lib/components/watermark/style/css.js +3 -0
- package/lib/components/watermark/style/css.js.map +1 -0
- package/lib/hooks/use-draggable/index.js +3 -1
- package/lib/hooks/use-draggable/index.js.map +1 -1
- package/lib/index.js +108 -104
- package/lib/index.js.map +1 -1
- package/lib/locale/lang/sw.d.ts +163 -0
- package/lib/locale/lang/sw.js +169 -0
- package/lib/locale/lang/sw.js.map +1 -0
- 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-button.css +1 -1
- package/theme-chalk/el-form.css +1 -1
- package/theme-chalk/el-menu.css +1 -1
- package/theme-chalk/el-rate.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/button.scss +1 -0
- package/theme-chalk/src/form.scss +28 -0
- package/theme-chalk/src/menu.scss +5 -0
- package/theme-chalk/src/rate.scss +7 -0
- package/web-types.json +1 -1
- package/es/components/select-v2/src/util.d.ts +0 -2
- package/es/components/select-v2/src/util.mjs +0 -26
- package/es/components/select-v2/src/util.mjs.map +0 -1
- package/lib/components/select-v2/src/util.d.ts +0 -2
- package/lib/components/select-v2/src/util.js +0 -30
- package/lib/components/select-v2/src/util.js.map +0 -1
package/dist/index.full.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! Element Plus v2.4.
|
|
1
|
+
/*! Element Plus v2.4.2 */
|
|
2
2
|
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('vue')) :
|
|
@@ -8850,7 +8850,9 @@
|
|
|
8850
8850
|
offsetX: moveX,
|
|
8851
8851
|
offsetY: moveY
|
|
8852
8852
|
};
|
|
8853
|
-
targetRef.value
|
|
8853
|
+
if (targetRef.value) {
|
|
8854
|
+
targetRef.value.style.transform = `translate(${addUnit(moveX)}, ${addUnit(moveY)})`;
|
|
8855
|
+
}
|
|
8854
8856
|
};
|
|
8855
8857
|
const onMouseup = () => {
|
|
8856
8858
|
document.removeEventListener("mousemove", onMousemove);
|
|
@@ -11291,7 +11293,7 @@
|
|
|
11291
11293
|
|
|
11292
11294
|
const ElConfigProvider = withInstall(ConfigProvider);
|
|
11293
11295
|
|
|
11294
|
-
const version$1 = "2.4.
|
|
11296
|
+
const version$1 = "2.4.2";
|
|
11295
11297
|
|
|
11296
11298
|
const makeInstaller = (components = []) => {
|
|
11297
11299
|
const install = (app, options) => {
|
|
@@ -21038,7 +21040,8 @@
|
|
|
21038
21040
|
}
|
|
21039
21041
|
function resetTimer() {
|
|
21040
21042
|
pauseTimer();
|
|
21041
|
-
|
|
21043
|
+
if (!props.pauseOnHover)
|
|
21044
|
+
startTimer();
|
|
21042
21045
|
}
|
|
21043
21046
|
function setContainerHeight(height) {
|
|
21044
21047
|
if (props.height !== "auto")
|
|
@@ -29251,6 +29254,7 @@
|
|
|
29251
29254
|
};
|
|
29252
29255
|
|
|
29253
29256
|
const useDialog = (props, targetRef) => {
|
|
29257
|
+
var _a;
|
|
29254
29258
|
const instance = vue.getCurrentInstance();
|
|
29255
29259
|
const emit = instance.emit;
|
|
29256
29260
|
const { nextZIndex } = useZIndex();
|
|
@@ -29260,7 +29264,7 @@
|
|
|
29260
29264
|
const visible = vue.ref(false);
|
|
29261
29265
|
const closed = vue.ref(false);
|
|
29262
29266
|
const rendered = vue.ref(false);
|
|
29263
|
-
const zIndex = vue.ref(props.zIndex
|
|
29267
|
+
const zIndex = vue.ref((_a = props.zIndex) != null ? _a : nextZIndex());
|
|
29264
29268
|
let openTimer = void 0;
|
|
29265
29269
|
let closeTimer = void 0;
|
|
29266
29270
|
const namespace = useGlobalConfig("namespace", defaultNamespace);
|
|
@@ -29347,8 +29351,8 @@
|
|
|
29347
29351
|
emit("closeAutoFocus");
|
|
29348
29352
|
}
|
|
29349
29353
|
function onFocusoutPrevented(event) {
|
|
29350
|
-
var
|
|
29351
|
-
if (((
|
|
29354
|
+
var _a2;
|
|
29355
|
+
if (((_a2 = event.detail) == null ? void 0 : _a2.focusReason) === "pointer") {
|
|
29352
29356
|
event.preventDefault();
|
|
29353
29357
|
}
|
|
29354
29358
|
}
|
|
@@ -29365,7 +29369,7 @@
|
|
|
29365
29369
|
closed.value = false;
|
|
29366
29370
|
open();
|
|
29367
29371
|
rendered.value = true;
|
|
29368
|
-
zIndex.value = props.zIndex ? zIndex.value
|
|
29372
|
+
zIndex.value = isUndefined$1(props.zIndex) ? nextZIndex() : zIndex.value++;
|
|
29369
29373
|
vue.nextTick(() => {
|
|
29370
29374
|
emit("open");
|
|
29371
29375
|
if (targetRef.value) {
|
|
@@ -33846,7 +33850,7 @@
|
|
|
33846
33850
|
originClientHeight = originClientHeight || (input2.clientHeight > 0 ? input2.clientHeight + 2 : 0);
|
|
33847
33851
|
const _tags = tags.value;
|
|
33848
33852
|
const cssVarOfSelectSize = getComputedStyle(input2).getPropertyValue(ns.cssVarName("input-height"));
|
|
33849
|
-
const gotSize = cssVarOfSelectSize || getComponentSize(selectSize.value || (form == null ? void 0 : form.size));
|
|
33853
|
+
const gotSize = Number.parseFloat(cssVarOfSelectSize) || getComponentSize(selectSize.value || (form == null ? void 0 : form.size));
|
|
33850
33854
|
const sizeInMap = selectSize.value || gotSize === originClientHeight || originClientHeight <= 0 ? gotSize : originClientHeight;
|
|
33851
33855
|
const isElHidden = input2.offsetParent === null;
|
|
33852
33856
|
!isElHidden && (input2.style.height = `${(states.selected.length === 0 ? sizeInMap : Math.max(_tags ? _tags.clientHeight + (_tags.clientHeight > sizeInMap ? 6 : 0) : 0, sizeInMap)) - 2}px`);
|
|
@@ -36750,16 +36754,20 @@
|
|
|
36750
36754
|
[vue.vShow, !(item <= currentValue.value)]
|
|
36751
36755
|
])
|
|
36752
36756
|
], 64)) : vue.createCommentVNode("v-if", true),
|
|
36753
|
-
showDecimalIcon(item) ? (vue.openBlock(), vue.
|
|
36754
|
-
|
|
36755
|
-
|
|
36756
|
-
|
|
36757
|
-
|
|
36758
|
-
|
|
36759
|
-
|
|
36760
|
-
|
|
36761
|
-
|
|
36762
|
-
|
|
36757
|
+
showDecimalIcon(item) ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
36758
|
+
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(voidComponent)), {
|
|
36759
|
+
class: vue.normalizeClass([vue.unref(ns).em("decimal", "box")])
|
|
36760
|
+
}, null, 8, ["class"])),
|
|
36761
|
+
vue.createVNode(vue.unref(ElIcon), {
|
|
36762
|
+
style: vue.normalizeStyle(vue.unref(decimalStyle)),
|
|
36763
|
+
class: vue.normalizeClass([vue.unref(ns).e("icon"), vue.unref(ns).e("decimal")])
|
|
36764
|
+
}, {
|
|
36765
|
+
default: vue.withCtx(() => [
|
|
36766
|
+
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(decimalIconComponent))))
|
|
36767
|
+
]),
|
|
36768
|
+
_: 1
|
|
36769
|
+
}, 8, ["style", "class"])
|
|
36770
|
+
], 64)) : vue.createCommentVNode("v-if", true)
|
|
36763
36771
|
]),
|
|
36764
36772
|
_: 2
|
|
36765
36773
|
}, 1032, ["class"])
|
|
@@ -38718,20 +38726,41 @@
|
|
|
38718
38726
|
};
|
|
38719
38727
|
}
|
|
38720
38728
|
|
|
38721
|
-
const
|
|
38729
|
+
const defaultProps$4 = {
|
|
38730
|
+
label: "label",
|
|
38731
|
+
value: "value",
|
|
38732
|
+
disabled: "disabled",
|
|
38733
|
+
options: "options"
|
|
38734
|
+
};
|
|
38735
|
+
function useProps(props) {
|
|
38736
|
+
const aliasProps = vue.computed(() => ({ ...defaultProps$4, ...props.props }));
|
|
38737
|
+
const getLabel = (option) => get(option, aliasProps.value.label);
|
|
38738
|
+
const getValue = (option) => get(option, aliasProps.value.value);
|
|
38739
|
+
const getDisabled = (option) => get(option, aliasProps.value.disabled);
|
|
38740
|
+
const getOptions = (option) => get(option, aliasProps.value.options);
|
|
38741
|
+
return {
|
|
38742
|
+
aliasProps,
|
|
38743
|
+
getLabel,
|
|
38744
|
+
getValue,
|
|
38745
|
+
getDisabled,
|
|
38746
|
+
getOptions
|
|
38747
|
+
};
|
|
38748
|
+
}
|
|
38749
|
+
|
|
38750
|
+
const SelectProps = buildProps({
|
|
38722
38751
|
allowCreate: Boolean,
|
|
38723
38752
|
autocomplete: {
|
|
38724
|
-
type: String,
|
|
38753
|
+
type: definePropType(String),
|
|
38725
38754
|
default: "none"
|
|
38726
38755
|
},
|
|
38727
38756
|
automaticDropdown: Boolean,
|
|
38728
38757
|
clearable: Boolean,
|
|
38729
38758
|
clearIcon: {
|
|
38730
|
-
type:
|
|
38759
|
+
type: iconPropType,
|
|
38731
38760
|
default: circle_close_default
|
|
38732
38761
|
},
|
|
38733
38762
|
effect: {
|
|
38734
|
-
type: String,
|
|
38763
|
+
type: definePropType(String),
|
|
38735
38764
|
default: "light"
|
|
38736
38765
|
},
|
|
38737
38766
|
collapseTags: Boolean,
|
|
@@ -38763,7 +38792,9 @@
|
|
|
38763
38792
|
loading: Boolean,
|
|
38764
38793
|
loadingText: String,
|
|
38765
38794
|
label: String,
|
|
38766
|
-
modelValue:
|
|
38795
|
+
modelValue: {
|
|
38796
|
+
type: definePropType([Array, String, Number, Boolean, Object])
|
|
38797
|
+
},
|
|
38767
38798
|
multiple: Boolean,
|
|
38768
38799
|
multipleLimit: {
|
|
38769
38800
|
type: Number,
|
|
@@ -38778,7 +38809,7 @@
|
|
|
38778
38809
|
default: true
|
|
38779
38810
|
},
|
|
38780
38811
|
options: {
|
|
38781
|
-
type: Array,
|
|
38812
|
+
type: definePropType(Array),
|
|
38782
38813
|
required: true
|
|
38783
38814
|
},
|
|
38784
38815
|
placeholder: {
|
|
@@ -38794,13 +38825,14 @@
|
|
|
38794
38825
|
default: ""
|
|
38795
38826
|
},
|
|
38796
38827
|
popperOptions: {
|
|
38797
|
-
type: Object,
|
|
38828
|
+
type: definePropType(Object),
|
|
38798
38829
|
default: () => ({})
|
|
38799
38830
|
},
|
|
38800
38831
|
remote: Boolean,
|
|
38801
|
-
size:
|
|
38802
|
-
|
|
38803
|
-
|
|
38832
|
+
size: useSizeProp,
|
|
38833
|
+
props: {
|
|
38834
|
+
type: definePropType(Object),
|
|
38835
|
+
default: () => defaultProps$4
|
|
38804
38836
|
},
|
|
38805
38837
|
valueKey: {
|
|
38806
38838
|
type: String,
|
|
@@ -38819,28 +38851,36 @@
|
|
|
38819
38851
|
values: Ee,
|
|
38820
38852
|
default: "bottom-start"
|
|
38821
38853
|
}
|
|
38822
|
-
};
|
|
38823
|
-
const OptionProps = {
|
|
38854
|
+
});
|
|
38855
|
+
const OptionProps = buildProps({
|
|
38824
38856
|
data: Array,
|
|
38825
38857
|
disabled: Boolean,
|
|
38826
38858
|
hovering: Boolean,
|
|
38827
|
-
item:
|
|
38859
|
+
item: {
|
|
38860
|
+
type: definePropType(Object),
|
|
38861
|
+
required: true
|
|
38862
|
+
},
|
|
38828
38863
|
index: Number,
|
|
38829
38864
|
style: Object,
|
|
38830
38865
|
selected: Boolean,
|
|
38831
38866
|
created: Boolean
|
|
38832
|
-
};
|
|
38867
|
+
});
|
|
38868
|
+
|
|
38869
|
+
const selectV2InjectionKey = Symbol("ElSelectV2Injection");
|
|
38833
38870
|
|
|
38834
38871
|
const _sfc_main$D = vue.defineComponent({
|
|
38835
38872
|
props: OptionProps,
|
|
38836
38873
|
emits: ["select", "hover"],
|
|
38837
38874
|
setup(props, { emit }) {
|
|
38875
|
+
const select = vue.inject(selectV2InjectionKey);
|
|
38838
38876
|
const ns = useNamespace("select");
|
|
38839
38877
|
const { hoverItem, selectOptionClick } = useOption(props, { emit });
|
|
38878
|
+
const { getLabel } = useProps(select.props);
|
|
38840
38879
|
return {
|
|
38841
38880
|
ns,
|
|
38842
38881
|
hoverItem,
|
|
38843
|
-
selectOptionClick
|
|
38882
|
+
selectOptionClick,
|
|
38883
|
+
getLabel
|
|
38844
38884
|
};
|
|
38845
38885
|
}
|
|
38846
38886
|
});
|
|
@@ -38864,14 +38904,12 @@
|
|
|
38864
38904
|
index: _ctx.index,
|
|
38865
38905
|
disabled: _ctx.disabled
|
|
38866
38906
|
}, () => [
|
|
38867
|
-
vue.createElementVNode("span", null, vue.toDisplayString(_ctx.item
|
|
38907
|
+
vue.createElementVNode("span", null, vue.toDisplayString(_ctx.getLabel(_ctx.item)), 1)
|
|
38868
38908
|
])
|
|
38869
38909
|
], 46, _hoisted_1$h);
|
|
38870
38910
|
}
|
|
38871
38911
|
var OptionItem = /* @__PURE__ */ _export_sfc(_sfc_main$D, [["render", _sfc_render$6], ["__file", "option-item.vue"]]);
|
|
38872
38912
|
|
|
38873
|
-
const selectV2InjectionKey = Symbol("ElSelectV2Injection");
|
|
38874
|
-
|
|
38875
38913
|
var ElSelectMenu = vue.defineComponent({
|
|
38876
38914
|
name: "ElSelectDropdown",
|
|
38877
38915
|
props: {
|
|
@@ -38888,6 +38926,11 @@
|
|
|
38888
38926
|
}) {
|
|
38889
38927
|
const select = vue.inject(selectV2InjectionKey);
|
|
38890
38928
|
const ns = useNamespace("select");
|
|
38929
|
+
const {
|
|
38930
|
+
getLabel,
|
|
38931
|
+
getValue,
|
|
38932
|
+
getDisabled
|
|
38933
|
+
} = useProps(select.props);
|
|
38891
38934
|
const cachedHeights = vue.ref([]);
|
|
38892
38935
|
const listRef = vue.ref();
|
|
38893
38936
|
const size = vue.computed(() => props.data.length);
|
|
@@ -38932,9 +38975,9 @@
|
|
|
38932
38975
|
};
|
|
38933
38976
|
const isItemSelected = (modelValue, target) => {
|
|
38934
38977
|
if (select.props.multiple) {
|
|
38935
|
-
return contains(modelValue, target
|
|
38978
|
+
return contains(modelValue, getValue(target));
|
|
38936
38979
|
}
|
|
38937
|
-
return isEqual(modelValue, target
|
|
38980
|
+
return isEqual(modelValue, getValue(target));
|
|
38938
38981
|
};
|
|
38939
38982
|
const isItemDisabled = (modelValue, selected) => {
|
|
38940
38983
|
const {
|
|
@@ -38997,7 +39040,7 @@
|
|
|
38997
39040
|
const isHovering = isItemHovering(index);
|
|
38998
39041
|
return vue.createVNode(OptionItem, vue.mergeProps(itemProps, {
|
|
38999
39042
|
"selected": isSelected,
|
|
39000
|
-
"disabled": item
|
|
39043
|
+
"disabled": getDisabled(item) || isDisabled,
|
|
39001
39044
|
"created": !!item.created,
|
|
39002
39045
|
"hovering": isHovering,
|
|
39003
39046
|
"item": item,
|
|
@@ -39006,7 +39049,7 @@
|
|
|
39006
39049
|
}), {
|
|
39007
39050
|
default: (props2) => {
|
|
39008
39051
|
var _a;
|
|
39009
|
-
return ((_a = slots.default) == null ? void 0 : _a.call(slots, props2)) || vue.createVNode("span", null, [item
|
|
39052
|
+
return ((_a = slots.default) == null ? void 0 : _a.call(slots, props2)) || vue.createVNode("span", null, [getLabel(item)]);
|
|
39010
39053
|
}
|
|
39011
39054
|
});
|
|
39012
39055
|
};
|
|
@@ -39098,13 +39141,14 @@
|
|
|
39098
39141
|
});
|
|
39099
39142
|
|
|
39100
39143
|
function useAllowCreate(props, states) {
|
|
39144
|
+
const { aliasProps, getLabel, getValue } = useProps(props);
|
|
39101
39145
|
const createOptionCount = vue.ref(0);
|
|
39102
39146
|
const cachedSelectedOption = vue.ref(null);
|
|
39103
39147
|
const enableAllowCreateMode = vue.computed(() => {
|
|
39104
39148
|
return props.allowCreate && props.filterable;
|
|
39105
39149
|
});
|
|
39106
39150
|
function hasExistingOption(query) {
|
|
39107
|
-
const hasValue = (option) => option
|
|
39151
|
+
const hasValue = (option) => getValue(option) === query;
|
|
39108
39152
|
return props.options && props.options.some(hasValue) || states.createdOptions.some(hasValue);
|
|
39109
39153
|
}
|
|
39110
39154
|
function selectNewOption(option) {
|
|
@@ -39121,10 +39165,10 @@
|
|
|
39121
39165
|
if (enableAllowCreateMode.value) {
|
|
39122
39166
|
if (query && query.length > 0 && !hasExistingOption(query)) {
|
|
39123
39167
|
const newOption = {
|
|
39124
|
-
value: query,
|
|
39125
|
-
label: query,
|
|
39168
|
+
[aliasProps.value.value]: query,
|
|
39169
|
+
[aliasProps.value.label]: query,
|
|
39126
39170
|
created: true,
|
|
39127
|
-
disabled: false
|
|
39171
|
+
[aliasProps.value.disabled]: false
|
|
39128
39172
|
};
|
|
39129
39173
|
if (states.createdOptions.length >= createOptionCount.value) {
|
|
39130
39174
|
states.createdOptions[createOptionCount.value] = newOption;
|
|
@@ -39145,10 +39189,10 @@
|
|
|
39145
39189
|
}
|
|
39146
39190
|
}
|
|
39147
39191
|
function removeNewOption(option) {
|
|
39148
|
-
if (!enableAllowCreateMode.value || !option || !option.created || option.created && props.reserveKeyword && states.inputValue === option
|
|
39192
|
+
if (!enableAllowCreateMode.value || !option || !option.created || option.created && props.reserveKeyword && states.inputValue === getLabel(option)) {
|
|
39149
39193
|
return;
|
|
39150
39194
|
}
|
|
39151
|
-
const idx = states.createdOptions.findIndex((it) => it
|
|
39195
|
+
const idx = states.createdOptions.findIndex((it) => getValue(it) === getValue(option));
|
|
39152
39196
|
if (~idx) {
|
|
39153
39197
|
states.createdOptions.splice(idx, 1);
|
|
39154
39198
|
createOptionCount.value--;
|
|
@@ -39168,28 +39212,6 @@
|
|
|
39168
39212
|
};
|
|
39169
39213
|
}
|
|
39170
39214
|
|
|
39171
|
-
const flattenOptions = (options) => {
|
|
39172
|
-
const flattened = [];
|
|
39173
|
-
options.forEach((option) => {
|
|
39174
|
-
if (isArray$1(option.options)) {
|
|
39175
|
-
flattened.push({
|
|
39176
|
-
label: option.label,
|
|
39177
|
-
isTitle: true,
|
|
39178
|
-
type: "Group"
|
|
39179
|
-
});
|
|
39180
|
-
option.options.forEach((o) => {
|
|
39181
|
-
flattened.push(o);
|
|
39182
|
-
});
|
|
39183
|
-
flattened.push({
|
|
39184
|
-
type: "Group"
|
|
39185
|
-
});
|
|
39186
|
-
} else {
|
|
39187
|
-
flattened.push(option);
|
|
39188
|
-
}
|
|
39189
|
-
});
|
|
39190
|
-
return flattened;
|
|
39191
|
-
};
|
|
39192
|
-
|
|
39193
39215
|
function useInput(handleInput) {
|
|
39194
39216
|
const isComposing = vue.ref(false);
|
|
39195
39217
|
const handleCompositionStart = () => {
|
|
@@ -39227,6 +39249,7 @@
|
|
|
39227
39249
|
const nsSelectV2 = useNamespace("select-v2");
|
|
39228
39250
|
const nsInput = useNamespace("input");
|
|
39229
39251
|
const { form: elForm, formItem: elFormItem } = useFormItem();
|
|
39252
|
+
const { getLabel, getValue, getDisabled, getOptions } = useProps(props);
|
|
39230
39253
|
const states = vue.reactive({
|
|
39231
39254
|
inputValue: DEFAULT_INPUT_PLACEHOLDER,
|
|
39232
39255
|
displayInputValue: DEFAULT_INPUT_PLACEHOLDER,
|
|
@@ -39300,37 +39323,37 @@
|
|
|
39300
39323
|
const isValidOption = (o) => {
|
|
39301
39324
|
const query = states.inputValue;
|
|
39302
39325
|
const regexp = new RegExp(escapeStringRegexp(query), "i");
|
|
39303
|
-
const containsQueryString = query ? regexp.test(o
|
|
39326
|
+
const containsQueryString = query ? regexp.test(getLabel(o) || "") : true;
|
|
39304
39327
|
return containsQueryString;
|
|
39305
39328
|
};
|
|
39306
39329
|
if (props.loading) {
|
|
39307
39330
|
return [];
|
|
39308
39331
|
}
|
|
39309
|
-
return
|
|
39310
|
-
|
|
39311
|
-
|
|
39332
|
+
return [...props.options, ...states.createdOptions].reduce((all, item) => {
|
|
39333
|
+
const options = getOptions(item);
|
|
39334
|
+
if (isArray$1(options)) {
|
|
39335
|
+
const filtered = options.filter(isValidOption);
|
|
39312
39336
|
if (filtered.length > 0) {
|
|
39313
|
-
|
|
39314
|
-
|
|
39315
|
-
|
|
39316
|
-
|
|
39317
|
-
|
|
39318
|
-
} else {
|
|
39319
|
-
if (props.remote || isValidOption(v)) {
|
|
39320
|
-
return v;
|
|
39337
|
+
all.push({
|
|
39338
|
+
label: getLabel(item),
|
|
39339
|
+
isTitle: true,
|
|
39340
|
+
type: "Group"
|
|
39341
|
+
}, ...filtered, { type: "Group" });
|
|
39321
39342
|
}
|
|
39343
|
+
} else if (props.remote || isValidOption(item)) {
|
|
39344
|
+
all.push(item);
|
|
39322
39345
|
}
|
|
39323
|
-
return
|
|
39324
|
-
}
|
|
39346
|
+
return all;
|
|
39347
|
+
}, []);
|
|
39325
39348
|
});
|
|
39326
39349
|
const filteredOptionsValueMap = vue.computed(() => {
|
|
39327
39350
|
const valueMap = /* @__PURE__ */ new Map();
|
|
39328
39351
|
filteredOptions.value.forEach((option, index) => {
|
|
39329
|
-
valueMap.set(getValueKey(option
|
|
39352
|
+
valueMap.set(getValueKey(getValue(option)), { option, index });
|
|
39330
39353
|
});
|
|
39331
39354
|
return valueMap;
|
|
39332
39355
|
});
|
|
39333
|
-
const optionsAllDisabled = vue.computed(() => filteredOptions.value.every((option) => option
|
|
39356
|
+
const optionsAllDisabled = vue.computed(() => filteredOptions.value.every((option) => getDisabled(option)));
|
|
39334
39357
|
const selectSize = useFormSize();
|
|
39335
39358
|
const collapseTagSize = vue.computed(() => selectSize.value === "small" ? "small" : "default");
|
|
39336
39359
|
const tagMaxWidth = vue.computed(() => {
|
|
@@ -39446,7 +39469,7 @@
|
|
|
39446
39469
|
const update = (val) => {
|
|
39447
39470
|
emit(UPDATE_MODEL_EVENT, val);
|
|
39448
39471
|
emitChange(val);
|
|
39449
|
-
states.previousValue = val
|
|
39472
|
+
states.previousValue = String(val);
|
|
39450
39473
|
};
|
|
39451
39474
|
const getValueIndex = (arr = [], value) => {
|
|
39452
39475
|
if (!isObject$1(value)) {
|
|
@@ -39466,9 +39489,6 @@
|
|
|
39466
39489
|
const getValueKey = (item) => {
|
|
39467
39490
|
return isObject$1(item) ? get(item, props.valueKey) : item;
|
|
39468
39491
|
};
|
|
39469
|
-
const getLabel = (item) => {
|
|
39470
|
-
return isObject$1(item) ? item.label : item;
|
|
39471
|
-
};
|
|
39472
39492
|
const resetInputHeight = () => {
|
|
39473
39493
|
return vue.nextTick(() => {
|
|
39474
39494
|
var _a, _b;
|
|
@@ -39500,7 +39520,7 @@
|
|
|
39500
39520
|
var _a, _b;
|
|
39501
39521
|
if (props.multiple) {
|
|
39502
39522
|
let selectedOptions = props.modelValue.slice();
|
|
39503
|
-
const index = getValueIndex(selectedOptions, option
|
|
39523
|
+
const index = getValueIndex(selectedOptions, getValue(option));
|
|
39504
39524
|
if (index > -1) {
|
|
39505
39525
|
selectedOptions = [
|
|
39506
39526
|
...selectedOptions.slice(0, index),
|
|
@@ -39509,7 +39529,7 @@
|
|
|
39509
39529
|
states.cachedOptions.splice(index, 1);
|
|
39510
39530
|
removeNewOption(option);
|
|
39511
39531
|
} else if (props.multipleLimit <= 0 || selectedOptions.length < props.multipleLimit) {
|
|
39512
|
-
selectedOptions = [...selectedOptions, option
|
|
39532
|
+
selectedOptions = [...selectedOptions, getValue(option)];
|
|
39513
39533
|
states.cachedOptions.push(option);
|
|
39514
39534
|
selectNewOption(option);
|
|
39515
39535
|
updateHoveringIndex(idx);
|
|
@@ -39531,8 +39551,8 @@
|
|
|
39531
39551
|
setSoftFocus();
|
|
39532
39552
|
} else {
|
|
39533
39553
|
selectedIndex.value = idx;
|
|
39534
|
-
states.selectedLabel = option
|
|
39535
|
-
update(option
|
|
39554
|
+
states.selectedLabel = getLabel(option);
|
|
39555
|
+
update(getValue(option));
|
|
39536
39556
|
expanded.value = false;
|
|
39537
39557
|
states.isComposing = false;
|
|
39538
39558
|
states.isSilentBlur = byClick;
|
|
@@ -39545,7 +39565,7 @@
|
|
|
39545
39565
|
};
|
|
39546
39566
|
const deleteTag = (event, option) => {
|
|
39547
39567
|
let selectedOptions = props.modelValue.slice();
|
|
39548
|
-
const index = getValueIndex(selectedOptions, option
|
|
39568
|
+
const index = getValueIndex(selectedOptions, getValue(option));
|
|
39549
39569
|
if (index > -1 && !selectDisabled.value) {
|
|
39550
39570
|
selectedOptions = [
|
|
39551
39571
|
...props.modelValue.slice(0, index),
|
|
@@ -39553,7 +39573,7 @@
|
|
|
39553
39573
|
];
|
|
39554
39574
|
states.cachedOptions.splice(index, 1);
|
|
39555
39575
|
update(selectedOptions);
|
|
39556
|
-
emit("remove-tag", option
|
|
39576
|
+
emit("remove-tag", getValue(option));
|
|
39557
39577
|
states.softFocus = true;
|
|
39558
39578
|
removeNewOption(option);
|
|
39559
39579
|
return vue.nextTick(focusAndUpdatePopup);
|
|
@@ -39651,7 +39671,7 @@
|
|
|
39651
39671
|
}
|
|
39652
39672
|
}
|
|
39653
39673
|
const option = options[newIndex];
|
|
39654
|
-
if (option
|
|
39674
|
+
if (getDisabled(option) || option.type === "Group") {
|
|
39655
39675
|
return onKeyboardNavigate(direction, newIndex);
|
|
39656
39676
|
} else {
|
|
39657
39677
|
updateHoveringIndex(newIndex);
|
|
@@ -39736,12 +39756,12 @@
|
|
|
39736
39756
|
if (hasModelValue.value) {
|
|
39737
39757
|
states.previousValue = props.modelValue;
|
|
39738
39758
|
const options = filteredOptions.value;
|
|
39739
|
-
const selectedItemIndex = options.findIndex((option) => getValueKey(option
|
|
39759
|
+
const selectedItemIndex = options.findIndex((option) => getValueKey(getValue(option)) === getValueKey(props.modelValue));
|
|
39740
39760
|
if (~selectedItemIndex) {
|
|
39741
|
-
states.selectedLabel = options[selectedItemIndex]
|
|
39761
|
+
states.selectedLabel = getLabel(options[selectedItemIndex]);
|
|
39742
39762
|
updateHoveringIndex(selectedItemIndex);
|
|
39743
39763
|
} else {
|
|
39744
|
-
states.selectedLabel =
|
|
39764
|
+
states.selectedLabel = getValueKey(props.modelValue);
|
|
39745
39765
|
}
|
|
39746
39766
|
} else {
|
|
39747
39767
|
states.selectedLabel = "";
|
|
@@ -39830,6 +39850,8 @@
|
|
|
39830
39850
|
debouncedOnInputChange,
|
|
39831
39851
|
deleteTag,
|
|
39832
39852
|
getLabel,
|
|
39853
|
+
getValue,
|
|
39854
|
+
getDisabled,
|
|
39833
39855
|
getValueKey,
|
|
39834
39856
|
handleBlur,
|
|
39835
39857
|
handleClear,
|
|
@@ -39962,11 +39984,11 @@
|
|
|
39962
39984
|
_ctx.collapseTags && _ctx.modelValue.length > 0 ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
|
|
39963
39985
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.showTagList, (item) => {
|
|
39964
39986
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
39965
|
-
key: _ctx.getValueKey(item),
|
|
39987
|
+
key: _ctx.getValueKey(_ctx.getValue(item)),
|
|
39966
39988
|
class: vue.normalizeClass(_ctx.nsSelectV2.e("selected-item"))
|
|
39967
39989
|
}, [
|
|
39968
39990
|
vue.createVNode(_component_el_tag, {
|
|
39969
|
-
closable: !_ctx.selectDisabled && !(item
|
|
39991
|
+
closable: !_ctx.selectDisabled && !_ctx.getDisabled(item),
|
|
39970
39992
|
size: _ctx.collapseTagSize,
|
|
39971
39993
|
type: "info",
|
|
39972
39994
|
"disable-transitions": "",
|
|
@@ -39978,7 +40000,7 @@
|
|
|
39978
40000
|
style: vue.normalizeStyle({
|
|
39979
40001
|
maxWidth: `${_ctx.tagMaxWidth}px`
|
|
39980
40002
|
})
|
|
39981
|
-
}, vue.toDisplayString(item
|
|
40003
|
+
}, vue.toDisplayString(_ctx.getLabel(item)), 7)
|
|
39982
40004
|
]),
|
|
39983
40005
|
_: 2
|
|
39984
40006
|
}, 1032, ["closable", "size", "onClose"])
|
|
@@ -40009,7 +40031,7 @@
|
|
|
40009
40031
|
style: vue.normalizeStyle({
|
|
40010
40032
|
maxWidth: `${_ctx.tagMaxWidth}px`
|
|
40011
40033
|
})
|
|
40012
|
-
}, "+ " + vue.toDisplayString(_ctx.modelValue.length - _ctx.maxCollapseTags), 7)
|
|
40034
|
+
}, " + " + vue.toDisplayString(_ctx.modelValue.length - _ctx.maxCollapseTags), 7)
|
|
40013
40035
|
]),
|
|
40014
40036
|
content: vue.withCtx(() => [
|
|
40015
40037
|
vue.createElementVNode("div", {
|
|
@@ -40017,11 +40039,11 @@
|
|
|
40017
40039
|
}, [
|
|
40018
40040
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.collapseTagList, (selected) => {
|
|
40019
40041
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
40020
|
-
key: _ctx.getValueKey(selected),
|
|
40042
|
+
key: _ctx.getValueKey(_ctx.getValue(selected)),
|
|
40021
40043
|
class: vue.normalizeClass(_ctx.nsSelectV2.e("selected-item"))
|
|
40022
40044
|
}, [
|
|
40023
40045
|
vue.createVNode(_component_el_tag, {
|
|
40024
|
-
closable: !_ctx.selectDisabled && !selected
|
|
40046
|
+
closable: !_ctx.selectDisabled && !_ctx.getDisabled(selected),
|
|
40025
40047
|
size: _ctx.collapseTagSize,
|
|
40026
40048
|
class: "in-tooltip",
|
|
40027
40049
|
type: "info",
|
|
@@ -40049,18 +40071,18 @@
|
|
|
40049
40071
|
style: vue.normalizeStyle({
|
|
40050
40072
|
maxWidth: `${_ctx.tagMaxWidth}px`
|
|
40051
40073
|
})
|
|
40052
|
-
}, "+ " + vue.toDisplayString(_ctx.modelValue.length - _ctx.maxCollapseTags), 7))
|
|
40074
|
+
}, " + " + vue.toDisplayString(_ctx.modelValue.length - _ctx.maxCollapseTags), 7))
|
|
40053
40075
|
]),
|
|
40054
40076
|
_: 1
|
|
40055
40077
|
}, 8, ["size"])) : vue.createCommentVNode("v-if", true)
|
|
40056
40078
|
], 2)
|
|
40057
40079
|
], 64)) : (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 1 }, vue.renderList(_ctx.states.cachedOptions, (selected) => {
|
|
40058
40080
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
40059
|
-
key: _ctx.getValueKey(selected),
|
|
40081
|
+
key: _ctx.getValueKey(_ctx.getValue(selected)),
|
|
40060
40082
|
class: vue.normalizeClass(_ctx.nsSelectV2.e("selected-item"))
|
|
40061
40083
|
}, [
|
|
40062
40084
|
vue.createVNode(_component_el_tag, {
|
|
40063
|
-
closable: !_ctx.selectDisabled && !selected
|
|
40085
|
+
closable: !_ctx.selectDisabled && !_ctx.getDisabled(selected),
|
|
40064
40086
|
size: _ctx.collapseTagSize,
|
|
40065
40087
|
type: "info",
|
|
40066
40088
|
"disable-transitions": "",
|
|
@@ -42068,6 +42090,10 @@
|
|
|
42068
42090
|
value: {
|
|
42069
42091
|
type: [Boolean, String, Number],
|
|
42070
42092
|
default: false
|
|
42093
|
+
},
|
|
42094
|
+
label: {
|
|
42095
|
+
type: String,
|
|
42096
|
+
default: void 0
|
|
42071
42097
|
}
|
|
42072
42098
|
});
|
|
42073
42099
|
const switchEmits = {
|
|
@@ -42077,7 +42103,7 @@
|
|
|
42077
42103
|
};
|
|
42078
42104
|
|
|
42079
42105
|
const _hoisted_1$d = ["onClick"];
|
|
42080
|
-
const _hoisted_2$9 = ["id", "aria-checked", "aria-disabled", "name", "true-value", "false-value", "disabled", "tabindex", "onKeydown"];
|
|
42106
|
+
const _hoisted_2$9 = ["id", "aria-checked", "aria-disabled", "aria-label", "name", "true-value", "false-value", "disabled", "tabindex", "onKeydown"];
|
|
42081
42107
|
const _hoisted_3$4 = ["aria-hidden"];
|
|
42082
42108
|
const _hoisted_4$2 = ["aria-hidden"];
|
|
42083
42109
|
const _hoisted_5$1 = ["aria-hidden"];
|
|
@@ -42233,6 +42259,7 @@
|
|
|
42233
42259
|
role: "switch",
|
|
42234
42260
|
"aria-checked": vue.unref(checked),
|
|
42235
42261
|
"aria-disabled": vue.unref(switchDisabled),
|
|
42262
|
+
"aria-label": _ctx.label,
|
|
42236
42263
|
name: _ctx.name,
|
|
42237
42264
|
"true-value": _ctx.activeValue,
|
|
42238
42265
|
"false-value": _ctx.inactiveValue,
|
|
@@ -52617,7 +52644,7 @@
|
|
|
52617
52644
|
const _Tree = Tree;
|
|
52618
52645
|
const ElTree = _Tree;
|
|
52619
52646
|
|
|
52620
|
-
const useSelect = (props, { attrs }, {
|
|
52647
|
+
const useSelect = (props, { attrs, emit }, {
|
|
52621
52648
|
tree,
|
|
52622
52649
|
key
|
|
52623
52650
|
}) => {
|
|
@@ -52625,6 +52652,7 @@
|
|
|
52625
52652
|
const result = {
|
|
52626
52653
|
...pick(vue.toRefs(props), Object.keys(ElSelect.props)),
|
|
52627
52654
|
...attrs,
|
|
52655
|
+
"onUpdate:modelValue": (value) => emit(UPDATE_MODEL_EVENT, value),
|
|
52628
52656
|
valueKey: key,
|
|
52629
52657
|
popperClass: vue.computed(() => {
|
|
52630
52658
|
const classes = [ns.e("popper")];
|
|
@@ -53935,10 +53963,6 @@
|
|
|
53935
53963
|
type: String,
|
|
53936
53964
|
default: ""
|
|
53937
53965
|
},
|
|
53938
|
-
type: {
|
|
53939
|
-
type: String,
|
|
53940
|
-
default: "select"
|
|
53941
|
-
},
|
|
53942
53966
|
fileList: {
|
|
53943
53967
|
type: definePropType(Array),
|
|
53944
53968
|
default: () => mutable([])
|
|
@@ -54035,23 +54059,25 @@
|
|
|
54035
54059
|
props: uploadListProps,
|
|
54036
54060
|
emits: uploadListEmits,
|
|
54037
54061
|
setup(__props, { emit }) {
|
|
54062
|
+
const props = __props;
|
|
54038
54063
|
const { t } = useLocale();
|
|
54039
54064
|
const nsUpload = useNamespace("upload");
|
|
54040
54065
|
const nsIcon = useNamespace("icon");
|
|
54041
54066
|
const nsList = useNamespace("list");
|
|
54042
54067
|
const disabled = useFormDisabled();
|
|
54043
54068
|
const focusing = vue.ref(false);
|
|
54069
|
+
const containerKls = vue.computed(() => [
|
|
54070
|
+
nsUpload.b("list"),
|
|
54071
|
+
nsUpload.bm("list", props.listType),
|
|
54072
|
+
nsUpload.is("disabled", props.disabled)
|
|
54073
|
+
]);
|
|
54044
54074
|
const handleRemove = (file) => {
|
|
54045
54075
|
emit("remove", file);
|
|
54046
54076
|
};
|
|
54047
54077
|
return (_ctx, _cache) => {
|
|
54048
54078
|
return vue.openBlock(), vue.createBlock(vue.TransitionGroup, {
|
|
54049
54079
|
tag: "ul",
|
|
54050
|
-
class: vue.normalizeClass(
|
|
54051
|
-
vue.unref(nsUpload).b("list"),
|
|
54052
|
-
vue.unref(nsUpload).bm("list", _ctx.listType),
|
|
54053
|
-
vue.unref(nsUpload).is("disabled", vue.unref(disabled))
|
|
54054
|
-
]),
|
|
54080
|
+
class: vue.normalizeClass(vue.unref(containerKls)),
|
|
54055
54081
|
name: vue.unref(nsList).b()
|
|
54056
54082
|
}, {
|
|
54057
54083
|
default: vue.withCtx(() => [
|
|
@@ -54782,12 +54808,20 @@
|
|
|
54782
54808
|
if (content instanceof HTMLImageElement) {
|
|
54783
54809
|
ctx.drawImage(content, 0, 0, contentWidth, contentHeight);
|
|
54784
54810
|
} else {
|
|
54785
|
-
const {
|
|
54811
|
+
const {
|
|
54812
|
+
color,
|
|
54813
|
+
fontSize,
|
|
54814
|
+
fontStyle,
|
|
54815
|
+
fontWeight,
|
|
54816
|
+
fontFamily,
|
|
54817
|
+
textAlign,
|
|
54818
|
+
textBaseline
|
|
54819
|
+
} = font;
|
|
54786
54820
|
const mergedFontSize = Number(fontSize) * ratio;
|
|
54787
54821
|
ctx.font = `${fontStyle} normal ${fontWeight} ${mergedFontSize}px/${height}px ${fontFamily}`;
|
|
54788
54822
|
ctx.fillStyle = color;
|
|
54789
|
-
ctx.textAlign =
|
|
54790
|
-
ctx.textBaseline =
|
|
54823
|
+
ctx.textAlign = textAlign;
|
|
54824
|
+
ctx.textBaseline = textBaseline;
|
|
54791
54825
|
const contents = Array.isArray(content) ? content : [content];
|
|
54792
54826
|
contents == null ? void 0 : contents.forEach((item, index) => {
|
|
54793
54827
|
ctx.fillText(item != null ? item : "", contentWidth / 2, index * (mergedFontSize + FontGap * ratio));
|
|
@@ -54876,6 +54910,14 @@
|
|
|
54876
54910
|
var _a, _b;
|
|
54877
54911
|
return (_b = (_a = props.font) == null ? void 0 : _a.fontFamily) != null ? _b : "sans-serif";
|
|
54878
54912
|
});
|
|
54913
|
+
const textAlign = vue.computed(() => {
|
|
54914
|
+
var _a, _b;
|
|
54915
|
+
return (_b = (_a = props.font) == null ? void 0 : _a.textAlign) != null ? _b : "center";
|
|
54916
|
+
});
|
|
54917
|
+
const textBaseline = vue.computed(() => {
|
|
54918
|
+
var _a, _b;
|
|
54919
|
+
return (_b = (_a = props.font) == null ? void 0 : _a.textBaseline) != null ? _b : "top";
|
|
54920
|
+
});
|
|
54879
54921
|
const gapX = vue.computed(() => props.gap[0]);
|
|
54880
54922
|
const gapY = vue.computed(() => props.gap[1]);
|
|
54881
54923
|
const gapXCenter = vue.computed(() => gapX.value / 2);
|
|
@@ -54979,7 +55021,9 @@
|
|
|
54979
55021
|
fontSize: fontSize.value,
|
|
54980
55022
|
fontStyle: fontStyle.value,
|
|
54981
55023
|
fontWeight: fontWeight.value,
|
|
54982
|
-
fontFamily: fontFamily.value
|
|
55024
|
+
fontFamily: fontFamily.value,
|
|
55025
|
+
textAlign: textAlign.value,
|
|
55026
|
+
textBaseline: textBaseline.value
|
|
54983
55027
|
}, gapX.value, gapY.value);
|
|
54984
55028
|
appendWatermark(textClips, clipWidth);
|
|
54985
55029
|
};
|
|
@@ -56957,6 +57001,7 @@
|
|
|
56957
57001
|
exports.ElTreeSelect = ElTreeSelect;
|
|
56958
57002
|
exports.ElTreeV2 = ElTreeV2;
|
|
56959
57003
|
exports.ElUpload = ElUpload;
|
|
57004
|
+
exports.ElWatermark = ElWatermark;
|
|
56960
57005
|
exports.FIRST_KEYS = FIRST_KEYS;
|
|
56961
57006
|
exports.FIRST_LAST_KEYS = FIRST_LAST_KEYS;
|
|
56962
57007
|
exports.FORWARD_REF_INJECTION_KEY = FORWARD_REF_INJECTION_KEY;
|
|
@@ -57258,6 +57303,7 @@
|
|
|
57258
57303
|
exports.virtualizedListProps = virtualizedListProps;
|
|
57259
57304
|
exports.virtualizedProps = virtualizedProps;
|
|
57260
57305
|
exports.virtualizedScrollbarProps = virtualizedScrollbarProps;
|
|
57306
|
+
exports.watermarkProps = watermarkProps;
|
|
57261
57307
|
exports.zIndexContextKey = zIndexContextKey;
|
|
57262
57308
|
|
|
57263
57309
|
Object.defineProperty(exports, '__esModule', { value: true });
|