@element-plus/nightly 0.0.20251210 → 0.0.20251211
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +1 -1
- package/dist/index.full.js +22 -8
- package/dist/index.full.min.js +7 -7
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +10 -10
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +22 -8
- 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/hi.js +1 -1
- package/dist/locale/hi.min.js +1 -1
- package/dist/locale/hi.min.mjs +1 -1
- package/dist/locale/hi.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/lo.js +1 -1
- package/dist/locale/lo.min.js +1 -1
- package/dist/locale/lo.min.mjs +1 -1
- package/dist/locale/lo.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/ms.js +1 -1
- package/dist/locale/ms.min.js +1 -1
- package/dist/locale/ms.min.mjs +1 -1
- package/dist/locale/ms.mjs +1 -1
- package/dist/locale/my.js +1 -1
- package/dist/locale/my.min.js +1 -1
- package/dist/locale/my.min.mjs +1 -1
- package/dist/locale/my.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/no.js +1 -1
- package/dist/locale/no.min.js +1 -1
- package/dist/locale/no.min.mjs +1 -1
- package/dist/locale/no.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/te.js +1 -1
- package/dist/locale/te.min.js +1 -1
- package/dist/locale/te.min.mjs +1 -1
- package/dist/locale/te.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-hk.js +1 -1
- package/dist/locale/zh-hk.min.js +1 -1
- package/dist/locale/zh-hk.min.mjs +1 -1
- package/dist/locale/zh-hk.mjs +1 -1
- package/dist/locale/zh-mo.js +1 -1
- package/dist/locale/zh-mo.min.js +1 -1
- package/dist/locale/zh-mo.min.mjs +1 -1
- package/dist/locale/zh-mo.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/anchor/index.mjs +2 -2
- package/es/components/anchor/src/anchor.mjs +40 -213
- package/es/components/anchor/src/anchor.mjs.map +1 -1
- package/es/components/anchor/src/anchor2.mjs +213 -40
- package/es/components/anchor/src/anchor2.mjs.map +1 -1
- package/es/components/autocomplete/src/autocomplete.mjs +2 -2
- package/es/components/autocomplete/src/autocomplete2.mjs +1 -1
- package/es/components/cascader/src/cascader.mjs +1 -1
- package/es/components/color-picker/index.mjs +2 -2
- package/es/components/color-picker/src/color-picker.mjs +347 -49
- package/es/components/color-picker/src/color-picker.mjs.map +1 -1
- package/es/components/color-picker/src/color-picker2.mjs +49 -347
- package/es/components/color-picker/src/color-picker2.mjs.map +1 -1
- package/es/components/dialog/src/dialog2.mjs +6 -2
- package/es/components/dialog/src/dialog2.mjs.map +1 -1
- package/es/components/dialog/src/use-dialog.d.ts +1 -0
- package/es/components/dialog/src/use-dialog.mjs +5 -1
- package/es/components/dialog/src/use-dialog.mjs.map +1 -1
- package/es/components/dropdown/src/dropdown.mjs +2 -2
- package/es/components/image/index.mjs +2 -2
- package/es/components/image/src/image.mjs +69 -234
- package/es/components/image/src/image.mjs.map +1 -1
- package/es/components/image/src/image2.mjs +234 -69
- package/es/components/image/src/image2.mjs.map +1 -1
- package/es/components/image-viewer/index.mjs +2 -2
- package/es/components/image-viewer/src/image-viewer.mjs +51 -484
- package/es/components/image-viewer/src/image-viewer.mjs.map +1 -1
- package/es/components/image-viewer/src/image-viewer2.mjs +484 -51
- package/es/components/image-viewer/src/image-viewer2.mjs.map +1 -1
- package/es/components/index.mjs +18 -18
- package/es/components/input/index.mjs +2 -2
- package/es/components/input/src/input.mjs +484 -125
- package/es/components/input/src/input.mjs.map +1 -1
- package/es/components/input/src/input2.mjs +125 -484
- package/es/components/input/src/input2.mjs.map +1 -1
- package/es/components/link/index.mjs +2 -2
- package/es/components/link/src/link.mjs +25 -71
- package/es/components/link/src/link.mjs.map +1 -1
- package/es/components/link/src/link2.mjs +71 -25
- package/es/components/link/src/link2.mjs.map +1 -1
- package/es/components/mention/src/mention.mjs +2 -2
- package/es/components/mention/src/mention2.mjs +1 -1
- package/es/components/menu/index.mjs +2 -2
- package/es/components/menu/src/menu-item.mjs +103 -15
- package/es/components/menu/src/menu-item.mjs.map +1 -1
- package/es/components/menu/src/menu-item2.mjs +15 -103
- package/es/components/menu/src/menu-item2.mjs.map +1 -1
- package/es/components/pagination/src/components/next.mjs +35 -18
- package/es/components/pagination/src/components/next.mjs.map +1 -1
- package/es/components/pagination/src/components/next2.mjs +18 -35
- package/es/components/pagination/src/components/next2.mjs.map +1 -1
- package/es/components/pagination/src/components/pager.mjs +16 -210
- package/es/components/pagination/src/components/pager.mjs.map +1 -1
- package/es/components/pagination/src/components/pager2.mjs +210 -16
- package/es/components/pagination/src/components/pager2.mjs.map +1 -1
- package/es/components/pagination/src/components/sizes.mjs +72 -26
- package/es/components/pagination/src/components/sizes.mjs.map +1 -1
- package/es/components/pagination/src/components/sizes2.mjs +26 -72
- package/es/components/pagination/src/components/sizes2.mjs.map +1 -1
- package/es/components/pagination/src/pagination.mjs +3 -3
- package/es/components/popconfirm/src/popconfirm.mjs +1 -1
- package/es/components/popover/index.mjs +2 -2
- package/es/components/popover/src/popover.mjs +66 -112
- package/es/components/popover/src/popover.mjs.map +1 -1
- package/es/components/popover/src/popover2.mjs +112 -66
- package/es/components/popover/src/popover2.mjs.map +1 -1
- package/es/components/popper/index.mjs +2 -2
- package/es/components/popper/src/popper.mjs +32 -22
- package/es/components/popper/src/popper.mjs.map +1 -1
- package/es/components/popper/src/popper2.mjs +22 -32
- package/es/components/popper/src/popper2.mjs.map +1 -1
- package/es/components/progress/index.mjs +2 -2
- package/es/components/progress/src/progress.mjs +207 -53
- package/es/components/progress/src/progress.mjs.map +1 -1
- package/es/components/progress/src/progress2.mjs +53 -207
- package/es/components/progress/src/progress2.mjs.map +1 -1
- package/es/components/radio/index.mjs +2 -2
- package/es/components/radio/src/radio-group.mjs +54 -86
- package/es/components/radio/src/radio-group.mjs.map +1 -1
- package/es/components/radio/src/radio-group2.mjs +86 -54
- package/es/components/radio/src/radio-group2.mjs.map +1 -1
- package/es/components/rate/index.mjs +2 -2
- package/es/components/rate/src/rate.mjs +86 -255
- package/es/components/rate/src/rate.mjs.map +1 -1
- package/es/components/rate/src/rate2.mjs +255 -86
- package/es/components/rate/src/rate2.mjs.map +1 -1
- package/es/components/scrollbar/src/bar.mjs +10 -64
- package/es/components/scrollbar/src/bar.mjs.map +1 -1
- package/es/components/scrollbar/src/bar2.mjs +64 -10
- package/es/components/scrollbar/src/bar2.mjs.map +1 -1
- package/es/components/scrollbar/src/scrollbar2.mjs +1 -1
- package/es/components/select/src/select.mjs +1 -1
- package/es/components/select-v2/src/defaults.mjs +1 -1
- package/es/components/switch/index.mjs +2 -2
- package/es/components/switch/src/switch.mjs +230 -75
- package/es/components/switch/src/switch.mjs.map +1 -1
- package/es/components/switch/src/switch2.mjs +75 -230
- package/es/components/switch/src/switch2.mjs.map +1 -1
- package/es/components/table/src/filter-panel.mjs +1 -1
- package/es/components/time-picker/src/common/props.mjs +1 -1
- package/es/components/timeline/index.mjs +2 -2
- package/es/components/timeline/src/timeline-item.mjs +33 -72
- package/es/components/timeline/src/timeline-item.mjs.map +1 -1
- package/es/components/timeline/src/timeline-item2.mjs +72 -33
- package/es/components/timeline/src/timeline-item2.mjs.map +1 -1
- package/es/components/tooltip/index.mjs +1 -1
- package/es/components/tooltip/src/content.mjs +29 -203
- package/es/components/tooltip/src/content.mjs.map +1 -1
- package/es/components/tooltip/src/content2.mjs +203 -29
- package/es/components/tooltip/src/content2.mjs.map +1 -1
- package/es/components/tooltip/src/tooltip.mjs +2 -2
- package/es/components/tooltip/src/tooltip2.mjs +1 -1
- package/es/components/tour/index.mjs +3 -3
- package/es/components/tour/src/content.mjs +43 -67
- package/es/components/tour/src/content.mjs.map +1 -1
- package/es/components/tour/src/content2.mjs +67 -43
- package/es/components/tour/src/content2.mjs.map +1 -1
- package/es/components/tour/src/step.mjs +192 -44
- package/es/components/tour/src/step.mjs.map +1 -1
- package/es/components/tour/src/step2.mjs +44 -192
- package/es/components/tour/src/step2.mjs.map +1 -1
- package/es/components/tour/src/tour.mjs +1 -1
- package/es/components/tour/src/tour2.mjs +1 -1
- package/es/components/tree/src/model/useNodeExpandEventBroadcast.mjs +10 -4
- package/es/components/tree/src/model/useNodeExpandEventBroadcast.mjs.map +1 -1
- package/es/components/watermark/index.mjs +2 -2
- package/es/components/watermark/src/watermark.mjs +27 -226
- package/es/components/watermark/src/watermark.mjs.map +1 -1
- package/es/components/watermark/src/watermark2.mjs +226 -27
- package/es/components/watermark/src/watermark2.mjs.map +1 -1
- package/es/index.mjs +18 -18
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/anchor/index.js +2 -2
- package/lib/components/anchor/src/anchor.js +40 -212
- package/lib/components/anchor/src/anchor.js.map +1 -1
- package/lib/components/anchor/src/anchor2.js +212 -40
- package/lib/components/anchor/src/anchor2.js.map +1 -1
- package/lib/components/autocomplete/src/autocomplete.js +2 -2
- package/lib/components/autocomplete/src/autocomplete2.js +1 -1
- package/lib/components/cascader/src/cascader.js +1 -1
- package/lib/components/color-picker/index.js +2 -2
- package/lib/components/color-picker/src/color-picker.js +346 -49
- package/lib/components/color-picker/src/color-picker.js.map +1 -1
- package/lib/components/color-picker/src/color-picker2.js +49 -346
- package/lib/components/color-picker/src/color-picker2.js.map +1 -1
- package/lib/components/dialog/src/dialog2.js +6 -2
- package/lib/components/dialog/src/dialog2.js.map +1 -1
- package/lib/components/dialog/src/use-dialog.d.ts +1 -0
- package/lib/components/dialog/src/use-dialog.js +5 -1
- package/lib/components/dialog/src/use-dialog.js.map +1 -1
- package/lib/components/dropdown/src/dropdown.js +2 -2
- package/lib/components/image/index.js +2 -2
- package/lib/components/image/src/image.js +69 -233
- package/lib/components/image/src/image.js.map +1 -1
- package/lib/components/image/src/image2.js +233 -69
- package/lib/components/image/src/image2.js.map +1 -1
- package/lib/components/image-viewer/index.js +2 -2
- package/lib/components/image-viewer/src/image-viewer.js +52 -484
- package/lib/components/image-viewer/src/image-viewer.js.map +1 -1
- package/lib/components/image-viewer/src/image-viewer2.js +484 -52
- package/lib/components/image-viewer/src/image-viewer2.js.map +1 -1
- package/lib/components/index.js +18 -18
- package/lib/components/input/index.js +2 -2
- package/lib/components/input/src/input.js +480 -122
- package/lib/components/input/src/input.js.map +1 -1
- package/lib/components/input/src/input2.js +122 -480
- package/lib/components/input/src/input2.js.map +1 -1
- package/lib/components/link/index.js +2 -2
- package/lib/components/link/src/link.js +26 -71
- package/lib/components/link/src/link.js.map +1 -1
- package/lib/components/link/src/link2.js +71 -26
- package/lib/components/link/src/link2.js.map +1 -1
- package/lib/components/mention/src/mention.js +2 -2
- package/lib/components/mention/src/mention2.js +1 -1
- package/lib/components/menu/index.js +2 -2
- package/lib/components/menu/src/menu-item.js +103 -16
- package/lib/components/menu/src/menu-item.js.map +1 -1
- package/lib/components/menu/src/menu-item2.js +16 -103
- package/lib/components/menu/src/menu-item2.js.map +1 -1
- package/lib/components/pagination/src/components/next.js +35 -18
- package/lib/components/pagination/src/components/next.js.map +1 -1
- package/lib/components/pagination/src/components/next2.js +18 -35
- package/lib/components/pagination/src/components/next2.js.map +1 -1
- package/lib/components/pagination/src/components/pager.js +16 -210
- package/lib/components/pagination/src/components/pager.js.map +1 -1
- package/lib/components/pagination/src/components/pager2.js +210 -16
- package/lib/components/pagination/src/components/pager2.js.map +1 -1
- package/lib/components/pagination/src/components/sizes.js +72 -26
- package/lib/components/pagination/src/components/sizes.js.map +1 -1
- package/lib/components/pagination/src/components/sizes2.js +26 -72
- package/lib/components/pagination/src/components/sizes2.js.map +1 -1
- package/lib/components/pagination/src/pagination.js +3 -3
- package/lib/components/popconfirm/src/popconfirm.js +1 -1
- package/lib/components/popover/index.js +2 -2
- package/lib/components/popover/src/popover.js +67 -112
- package/lib/components/popover/src/popover.js.map +1 -1
- package/lib/components/popover/src/popover2.js +112 -67
- package/lib/components/popover/src/popover2.js.map +1 -1
- package/lib/components/popper/index.js +2 -2
- package/lib/components/popper/src/popper.js +32 -25
- package/lib/components/popper/src/popper.js.map +1 -1
- package/lib/components/popper/src/popper2.js +25 -32
- package/lib/components/popper/src/popper2.js.map +1 -1
- package/lib/components/progress/index.js +2 -2
- package/lib/components/progress/src/progress.js +207 -53
- package/lib/components/progress/src/progress.js.map +1 -1
- package/lib/components/progress/src/progress2.js +53 -207
- package/lib/components/progress/src/progress2.js.map +1 -1
- package/lib/components/radio/index.js +2 -2
- package/lib/components/radio/src/radio-group.js +56 -86
- package/lib/components/radio/src/radio-group.js.map +1 -1
- package/lib/components/radio/src/radio-group2.js +86 -56
- package/lib/components/radio/src/radio-group2.js.map +1 -1
- package/lib/components/rate/index.js +2 -2
- package/lib/components/rate/src/rate.js +86 -254
- package/lib/components/rate/src/rate.js.map +1 -1
- package/lib/components/rate/src/rate2.js +254 -86
- package/lib/components/rate/src/rate2.js.map +1 -1
- package/lib/components/scrollbar/src/bar.js +10 -64
- package/lib/components/scrollbar/src/bar.js.map +1 -1
- package/lib/components/scrollbar/src/bar2.js +64 -10
- package/lib/components/scrollbar/src/bar2.js.map +1 -1
- package/lib/components/scrollbar/src/scrollbar2.js +1 -1
- package/lib/components/select/src/select.js +1 -1
- package/lib/components/select-v2/src/defaults.js +1 -1
- package/lib/components/switch/index.js +2 -2
- package/lib/components/switch/src/switch.js +229 -75
- package/lib/components/switch/src/switch.js.map +1 -1
- package/lib/components/switch/src/switch2.js +75 -229
- package/lib/components/switch/src/switch2.js.map +1 -1
- package/lib/components/table/src/filter-panel.js +1 -1
- package/lib/components/time-picker/src/common/props.js +1 -1
- package/lib/components/timeline/index.js +2 -2
- package/lib/components/timeline/src/timeline-item.js +33 -72
- package/lib/components/timeline/src/timeline-item.js.map +1 -1
- package/lib/components/timeline/src/timeline-item2.js +72 -33
- package/lib/components/timeline/src/timeline-item2.js.map +1 -1
- package/lib/components/tooltip/index.js +1 -1
- package/lib/components/tooltip/src/content.js +29 -203
- package/lib/components/tooltip/src/content.js.map +1 -1
- package/lib/components/tooltip/src/content2.js +203 -29
- package/lib/components/tooltip/src/content2.js.map +1 -1
- package/lib/components/tooltip/src/tooltip.js +2 -2
- package/lib/components/tooltip/src/tooltip2.js +1 -1
- package/lib/components/tour/index.js +3 -3
- package/lib/components/tour/src/content.js +46 -67
- package/lib/components/tour/src/content.js.map +1 -1
- package/lib/components/tour/src/content2.js +67 -46
- package/lib/components/tour/src/content2.js.map +1 -1
- package/lib/components/tour/src/step.js +191 -44
- package/lib/components/tour/src/step.js.map +1 -1
- package/lib/components/tour/src/step2.js +44 -191
- package/lib/components/tour/src/step2.js.map +1 -1
- package/lib/components/tour/src/tour.js +1 -1
- package/lib/components/tour/src/tour2.js +1 -1
- package/lib/components/tree/src/model/useNodeExpandEventBroadcast.js +9 -3
- package/lib/components/tree/src/model/useNodeExpandEventBroadcast.js.map +1 -1
- package/lib/components/watermark/index.js +2 -2
- package/lib/components/watermark/src/watermark.js +27 -226
- package/lib/components/watermark/src/watermark.js.map +1 -1
- package/lib/components/watermark/src/watermark2.js +226 -27
- package/lib/components/watermark/src/watermark2.js.map +1 -1
- package/lib/index.js +18 -18
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +3 -3
- package/theme-chalk/el-dialog.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/dialog.scss +6 -0
- package/web-types.json +1 -1
|
@@ -1,488 +1,129 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import { useAttrs as useAttrs$1 } from '../../../hooks/use-attrs/index.mjs';
|
|
10
|
-
import { useFormItem, useFormItemInputId } from '../../form/src/hooks/use-form-item.mjs';
|
|
11
|
-
import { useFormSize, useFormDisabled } from '../../form/src/hooks/use-form-common-props.mjs';
|
|
12
|
-
import { useFocusController } from '../../../hooks/use-focus-controller/index.mjs';
|
|
13
|
-
import { ValidateComponentsMap } from '../../../utils/vue/icon.mjs';
|
|
14
|
-
import { useComposition } from '../../../hooks/use-composition/index.mjs';
|
|
15
|
-
import { INPUT_EVENT, UPDATE_MODEL_EVENT, CHANGE_EVENT } from '../../../constants/event.mjs';
|
|
16
|
-
import { useCursor } from '../../../hooks/use-cursor/index.mjs';
|
|
17
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
18
|
-
import { debugWarn } from '../../../utils/error.mjs';
|
|
19
|
-
import { NOOP, isObject } from '@vue/shared';
|
|
1
|
+
import { CircleClose } from '@element-plus/icons-vue';
|
|
2
|
+
import { useSizeProp } from '../../../hooks/use-size/index.mjs';
|
|
3
|
+
import { iconPropType } from '../../../utils/vue/icon.mjs';
|
|
4
|
+
import { mutable } from '../../../utils/typescript.mjs';
|
|
5
|
+
import { useAriaProps } from '../../../hooks/use-aria/index.mjs';
|
|
6
|
+
import { UPDATE_MODEL_EVENT } from '../../../constants/event.mjs';
|
|
7
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
8
|
+
import { isString } from '@vue/shared';
|
|
20
9
|
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
10
|
+
const inputProps = buildProps({
|
|
11
|
+
id: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: void 0
|
|
14
|
+
},
|
|
15
|
+
size: useSizeProp,
|
|
16
|
+
disabled: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: void 0
|
|
19
|
+
},
|
|
20
|
+
modelValue: {
|
|
21
|
+
type: definePropType([
|
|
22
|
+
String,
|
|
23
|
+
Number,
|
|
24
|
+
Object
|
|
25
|
+
]),
|
|
26
|
+
default: ""
|
|
27
|
+
},
|
|
28
|
+
modelModifiers: {
|
|
29
|
+
type: definePropType(Object),
|
|
30
|
+
default: () => ({})
|
|
31
|
+
},
|
|
32
|
+
maxlength: {
|
|
33
|
+
type: [String, Number]
|
|
34
|
+
},
|
|
35
|
+
minlength: {
|
|
36
|
+
type: [String, Number]
|
|
37
|
+
},
|
|
38
|
+
type: {
|
|
39
|
+
type: definePropType(String),
|
|
40
|
+
default: "text"
|
|
41
|
+
},
|
|
42
|
+
resize: {
|
|
43
|
+
type: String,
|
|
44
|
+
values: ["none", "both", "horizontal", "vertical"]
|
|
45
|
+
},
|
|
46
|
+
autosize: {
|
|
47
|
+
type: definePropType([Boolean, Object]),
|
|
48
|
+
default: false
|
|
49
|
+
},
|
|
50
|
+
autocomplete: {
|
|
51
|
+
type: definePropType(String),
|
|
52
|
+
default: "off"
|
|
53
|
+
},
|
|
54
|
+
formatter: {
|
|
55
|
+
type: Function
|
|
56
|
+
},
|
|
57
|
+
parser: {
|
|
58
|
+
type: Function
|
|
59
|
+
},
|
|
60
|
+
placeholder: {
|
|
61
|
+
type: String
|
|
62
|
+
},
|
|
63
|
+
form: {
|
|
64
|
+
type: String
|
|
65
|
+
},
|
|
66
|
+
readonly: Boolean,
|
|
67
|
+
clearable: Boolean,
|
|
68
|
+
clearIcon: {
|
|
69
|
+
type: iconPropType,
|
|
70
|
+
default: CircleClose
|
|
71
|
+
},
|
|
72
|
+
showPassword: Boolean,
|
|
73
|
+
showWordLimit: Boolean,
|
|
74
|
+
wordLimitPosition: {
|
|
75
|
+
type: String,
|
|
76
|
+
values: ["inside", "outside"],
|
|
77
|
+
default: "inside"
|
|
78
|
+
},
|
|
79
|
+
suffixIcon: {
|
|
80
|
+
type: iconPropType
|
|
81
|
+
},
|
|
82
|
+
prefixIcon: {
|
|
83
|
+
type: iconPropType
|
|
84
|
+
},
|
|
85
|
+
containerRole: {
|
|
86
|
+
type: String,
|
|
87
|
+
default: void 0
|
|
88
|
+
},
|
|
89
|
+
tabindex: {
|
|
90
|
+
type: [String, Number],
|
|
91
|
+
default: 0
|
|
92
|
+
},
|
|
93
|
+
validateEvent: {
|
|
94
|
+
type: Boolean,
|
|
95
|
+
default: true
|
|
96
|
+
},
|
|
97
|
+
inputStyle: {
|
|
98
|
+
type: definePropType([Object, Array, String]),
|
|
99
|
+
default: () => mutable({})
|
|
100
|
+
},
|
|
101
|
+
autofocus: Boolean,
|
|
102
|
+
rows: {
|
|
103
|
+
type: Number,
|
|
104
|
+
default: 2
|
|
105
|
+
},
|
|
106
|
+
...useAriaProps(["ariaLabel"]),
|
|
107
|
+
inputmode: {
|
|
108
|
+
type: definePropType(String),
|
|
109
|
+
default: void 0
|
|
110
|
+
},
|
|
111
|
+
name: String
|
|
25
112
|
});
|
|
26
|
-
const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
{
|
|
41
|
-
[nsInput.b("group")]: slots.prepend || slots.append,
|
|
42
|
-
[nsInput.m("prefix")]: slots.prefix || props.prefixIcon,
|
|
43
|
-
[nsInput.m("suffix")]: slots.suffix || props.suffixIcon || props.clearable || props.showPassword,
|
|
44
|
-
[nsInput.bm("suffix", "password-clear")]: showClear.value && showPwdVisible.value,
|
|
45
|
-
[nsInput.b("hidden")]: props.type === "hidden"
|
|
46
|
-
},
|
|
47
|
-
rawAttrs.class
|
|
48
|
-
]);
|
|
49
|
-
const wrapperKls = computed(() => [
|
|
50
|
-
nsInput.e("wrapper"),
|
|
51
|
-
nsInput.is("focus", isFocused.value)
|
|
52
|
-
]);
|
|
53
|
-
const { form: elForm, formItem: elFormItem } = useFormItem();
|
|
54
|
-
const { inputId } = useFormItemInputId(props, {
|
|
55
|
-
formItemContext: elFormItem
|
|
56
|
-
});
|
|
57
|
-
const inputSize = useFormSize();
|
|
58
|
-
const inputDisabled = useFormDisabled();
|
|
59
|
-
const nsInput = useNamespace("input");
|
|
60
|
-
const nsTextarea = useNamespace("textarea");
|
|
61
|
-
const input = shallowRef();
|
|
62
|
-
const textarea = shallowRef();
|
|
63
|
-
const hovering = ref(false);
|
|
64
|
-
const passwordVisible = ref(false);
|
|
65
|
-
const countStyle = ref();
|
|
66
|
-
const textareaCalcStyle = shallowRef(props.inputStyle);
|
|
67
|
-
const _ref = computed(() => input.value || textarea.value);
|
|
68
|
-
const { wrapperRef, isFocused, handleFocus, handleBlur } = useFocusController(_ref, {
|
|
69
|
-
disabled: inputDisabled,
|
|
70
|
-
afterBlur() {
|
|
71
|
-
var _a;
|
|
72
|
-
if (props.validateEvent) {
|
|
73
|
-
(_a = elFormItem == null ? void 0 : elFormItem.validate) == null ? void 0 : _a.call(elFormItem, "blur").catch((err) => debugWarn(err));
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
const needStatusIcon = computed(() => {
|
|
78
|
-
var _a;
|
|
79
|
-
return (_a = elForm == null ? void 0 : elForm.statusIcon) != null ? _a : false;
|
|
80
|
-
});
|
|
81
|
-
const validateState = computed(() => (elFormItem == null ? void 0 : elFormItem.validateState) || "");
|
|
82
|
-
const validateIcon = computed(() => validateState.value && ValidateComponentsMap[validateState.value]);
|
|
83
|
-
const passwordIcon = computed(() => passwordVisible.value ? View : Hide);
|
|
84
|
-
const containerStyle = computed(() => [
|
|
85
|
-
rawAttrs.style
|
|
86
|
-
]);
|
|
87
|
-
const textareaStyle = computed(() => [
|
|
88
|
-
props.inputStyle,
|
|
89
|
-
textareaCalcStyle.value,
|
|
90
|
-
{ resize: props.resize }
|
|
91
|
-
]);
|
|
92
|
-
const nativeInputValue = computed(() => isNil(props.modelValue) ? "" : String(props.modelValue));
|
|
93
|
-
const showClear = computed(() => props.clearable && !inputDisabled.value && !props.readonly && !!nativeInputValue.value && (isFocused.value || hovering.value));
|
|
94
|
-
const showPwdVisible = computed(() => props.showPassword && !inputDisabled.value && !!nativeInputValue.value);
|
|
95
|
-
const isWordLimitVisible = computed(() => props.showWordLimit && !!props.maxlength && (props.type === "text" || props.type === "textarea") && !inputDisabled.value && !props.readonly && !props.showPassword);
|
|
96
|
-
const textLength = computed(() => nativeInputValue.value.length);
|
|
97
|
-
const inputExceed = computed(() => !!isWordLimitVisible.value && textLength.value > Number(props.maxlength));
|
|
98
|
-
const suffixVisible = computed(() => !!slots.suffix || !!props.suffixIcon || showClear.value || props.showPassword || isWordLimitVisible.value || !!validateState.value && needStatusIcon.value);
|
|
99
|
-
const hasModelModifiers = computed(() => !!Object.keys(props.modelModifiers).length);
|
|
100
|
-
const [recordCursor, setCursor] = useCursor(input);
|
|
101
|
-
useResizeObserver(textarea, (entries) => {
|
|
102
|
-
onceInitSizeTextarea();
|
|
103
|
-
if (!isWordLimitVisible.value || props.resize !== "both" && props.resize !== "horizontal")
|
|
104
|
-
return;
|
|
105
|
-
const entry = entries[0];
|
|
106
|
-
const { width } = entry.contentRect;
|
|
107
|
-
countStyle.value = {
|
|
108
|
-
right: `calc(100% - ${width + 22 - 10}px)`
|
|
109
|
-
};
|
|
110
|
-
});
|
|
111
|
-
const resizeTextarea = () => {
|
|
112
|
-
const { type, autosize } = props;
|
|
113
|
-
if (!isClient || type !== "textarea" || !textarea.value)
|
|
114
|
-
return;
|
|
115
|
-
if (autosize) {
|
|
116
|
-
const minRows = isObject(autosize) ? autosize.minRows : void 0;
|
|
117
|
-
const maxRows = isObject(autosize) ? autosize.maxRows : void 0;
|
|
118
|
-
const textareaStyle2 = calcTextareaHeight(textarea.value, minRows, maxRows);
|
|
119
|
-
textareaCalcStyle.value = {
|
|
120
|
-
overflowY: "hidden",
|
|
121
|
-
...textareaStyle2
|
|
122
|
-
};
|
|
123
|
-
nextTick(() => {
|
|
124
|
-
textarea.value.offsetHeight;
|
|
125
|
-
textareaCalcStyle.value = textareaStyle2;
|
|
126
|
-
});
|
|
127
|
-
} else {
|
|
128
|
-
textareaCalcStyle.value = {
|
|
129
|
-
minHeight: calcTextareaHeight(textarea.value).minHeight
|
|
130
|
-
};
|
|
131
|
-
}
|
|
132
|
-
};
|
|
133
|
-
const createOnceInitResize = (resizeTextarea2) => {
|
|
134
|
-
let isInit = false;
|
|
135
|
-
return () => {
|
|
136
|
-
var _a;
|
|
137
|
-
if (isInit || !props.autosize)
|
|
138
|
-
return;
|
|
139
|
-
const isElHidden = ((_a = textarea.value) == null ? void 0 : _a.offsetParent) === null;
|
|
140
|
-
if (!isElHidden) {
|
|
141
|
-
setTimeout(resizeTextarea2);
|
|
142
|
-
isInit = true;
|
|
143
|
-
}
|
|
144
|
-
};
|
|
145
|
-
};
|
|
146
|
-
const onceInitSizeTextarea = createOnceInitResize(resizeTextarea);
|
|
147
|
-
const setNativeInputValue = () => {
|
|
148
|
-
const input2 = _ref.value;
|
|
149
|
-
const formatterValue = props.formatter ? props.formatter(nativeInputValue.value) : nativeInputValue.value;
|
|
150
|
-
if (!input2 || input2.value === formatterValue || props.type === "file")
|
|
151
|
-
return;
|
|
152
|
-
input2.value = formatterValue;
|
|
153
|
-
};
|
|
154
|
-
const formatValue = (value) => {
|
|
155
|
-
const { trim, number } = props.modelModifiers;
|
|
156
|
-
if (trim) {
|
|
157
|
-
value = value.trim();
|
|
158
|
-
}
|
|
159
|
-
if (number) {
|
|
160
|
-
value = `${looseToNumber(value)}`;
|
|
161
|
-
}
|
|
162
|
-
if (props.formatter && props.parser) {
|
|
163
|
-
value = props.parser(value);
|
|
164
|
-
}
|
|
165
|
-
return value;
|
|
166
|
-
};
|
|
167
|
-
const handleInput = async (event) => {
|
|
168
|
-
if (isComposing.value)
|
|
169
|
-
return;
|
|
170
|
-
const { lazy } = props.modelModifiers;
|
|
171
|
-
let { value } = event.target;
|
|
172
|
-
if (lazy) {
|
|
173
|
-
emit(INPUT_EVENT, value);
|
|
174
|
-
return;
|
|
175
|
-
}
|
|
176
|
-
value = formatValue(value);
|
|
177
|
-
if (String(value) === nativeInputValue.value) {
|
|
178
|
-
if (props.formatter) {
|
|
179
|
-
setNativeInputValue();
|
|
180
|
-
}
|
|
181
|
-
return;
|
|
182
|
-
}
|
|
183
|
-
recordCursor();
|
|
184
|
-
emit(UPDATE_MODEL_EVENT, value);
|
|
185
|
-
emit(INPUT_EVENT, value);
|
|
186
|
-
await nextTick();
|
|
187
|
-
if (props.formatter && props.parser || !hasModelModifiers.value) {
|
|
188
|
-
setNativeInputValue();
|
|
189
|
-
}
|
|
190
|
-
setCursor();
|
|
191
|
-
};
|
|
192
|
-
const handleChange = async (event) => {
|
|
193
|
-
let { value } = event.target;
|
|
194
|
-
value = formatValue(value);
|
|
195
|
-
if (props.modelModifiers.lazy) {
|
|
196
|
-
emit(UPDATE_MODEL_EVENT, value);
|
|
197
|
-
}
|
|
198
|
-
emit(CHANGE_EVENT, value, event);
|
|
199
|
-
await nextTick();
|
|
200
|
-
setNativeInputValue();
|
|
201
|
-
};
|
|
202
|
-
const {
|
|
203
|
-
isComposing,
|
|
204
|
-
handleCompositionStart,
|
|
205
|
-
handleCompositionUpdate,
|
|
206
|
-
handleCompositionEnd
|
|
207
|
-
} = useComposition({ emit, afterComposition: handleInput });
|
|
208
|
-
const handlePasswordVisible = () => {
|
|
209
|
-
passwordVisible.value = !passwordVisible.value;
|
|
210
|
-
};
|
|
211
|
-
const focus = () => {
|
|
212
|
-
var _a;
|
|
213
|
-
return (_a = _ref.value) == null ? void 0 : _a.focus();
|
|
214
|
-
};
|
|
215
|
-
const blur = () => {
|
|
216
|
-
var _a;
|
|
217
|
-
return (_a = _ref.value) == null ? void 0 : _a.blur();
|
|
218
|
-
};
|
|
219
|
-
const handleMouseLeave = (evt) => {
|
|
220
|
-
hovering.value = false;
|
|
221
|
-
emit("mouseleave", evt);
|
|
222
|
-
};
|
|
223
|
-
const handleMouseEnter = (evt) => {
|
|
224
|
-
hovering.value = true;
|
|
225
|
-
emit("mouseenter", evt);
|
|
226
|
-
};
|
|
227
|
-
const handleKeydown = (evt) => {
|
|
228
|
-
emit("keydown", evt);
|
|
229
|
-
};
|
|
230
|
-
const select = () => {
|
|
231
|
-
var _a;
|
|
232
|
-
(_a = _ref.value) == null ? void 0 : _a.select();
|
|
233
|
-
};
|
|
234
|
-
const clear = () => {
|
|
235
|
-
emit(UPDATE_MODEL_EVENT, "");
|
|
236
|
-
emit(CHANGE_EVENT, "");
|
|
237
|
-
emit("clear");
|
|
238
|
-
emit(INPUT_EVENT, "");
|
|
239
|
-
};
|
|
240
|
-
watch(() => props.modelValue, () => {
|
|
241
|
-
var _a;
|
|
242
|
-
nextTick(() => resizeTextarea());
|
|
243
|
-
if (props.validateEvent) {
|
|
244
|
-
(_a = elFormItem == null ? void 0 : elFormItem.validate) == null ? void 0 : _a.call(elFormItem, "change").catch((err) => debugWarn(err));
|
|
245
|
-
}
|
|
246
|
-
});
|
|
247
|
-
watch(nativeInputValue, (newValue) => {
|
|
248
|
-
if (!_ref.value) {
|
|
249
|
-
return;
|
|
250
|
-
}
|
|
251
|
-
const { trim, number } = props.modelModifiers;
|
|
252
|
-
const elValue = _ref.value.value;
|
|
253
|
-
const displayValue = (number || props.type === "number") && !/^0\d/.test(elValue) ? `${looseToNumber(elValue)}` : elValue;
|
|
254
|
-
if (displayValue === newValue) {
|
|
255
|
-
return;
|
|
256
|
-
}
|
|
257
|
-
if (document.activeElement === _ref.value && _ref.value.type !== "range") {
|
|
258
|
-
if (trim && displayValue.trim() === newValue) {
|
|
259
|
-
return;
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
setNativeInputValue();
|
|
263
|
-
});
|
|
264
|
-
watch(() => props.type, async () => {
|
|
265
|
-
await nextTick();
|
|
266
|
-
setNativeInputValue();
|
|
267
|
-
resizeTextarea();
|
|
268
|
-
});
|
|
269
|
-
onMounted(() => {
|
|
270
|
-
if (!props.formatter && props.parser) {
|
|
271
|
-
debugWarn(COMPONENT_NAME, "If you set the parser, you also need to set the formatter.");
|
|
272
|
-
}
|
|
273
|
-
setNativeInputValue();
|
|
274
|
-
nextTick(resizeTextarea);
|
|
275
|
-
});
|
|
276
|
-
expose({
|
|
277
|
-
input,
|
|
278
|
-
textarea,
|
|
279
|
-
ref: _ref,
|
|
280
|
-
textareaStyle,
|
|
281
|
-
autosize: toRef(props, "autosize"),
|
|
282
|
-
isComposing,
|
|
283
|
-
focus,
|
|
284
|
-
blur,
|
|
285
|
-
select,
|
|
286
|
-
clear,
|
|
287
|
-
resizeTextarea
|
|
288
|
-
});
|
|
289
|
-
return (_ctx, _cache) => {
|
|
290
|
-
return openBlock(), createElementBlock("div", {
|
|
291
|
-
class: normalizeClass([
|
|
292
|
-
unref(containerKls),
|
|
293
|
-
{
|
|
294
|
-
[unref(nsInput).bm("group", "append")]: _ctx.$slots.append,
|
|
295
|
-
[unref(nsInput).bm("group", "prepend")]: _ctx.$slots.prepend
|
|
296
|
-
}
|
|
297
|
-
]),
|
|
298
|
-
style: normalizeStyle(unref(containerStyle)),
|
|
299
|
-
onMouseenter: handleMouseEnter,
|
|
300
|
-
onMouseleave: handleMouseLeave
|
|
301
|
-
}, [
|
|
302
|
-
createCommentVNode(" input "),
|
|
303
|
-
_ctx.type !== "textarea" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
304
|
-
createCommentVNode(" prepend slot "),
|
|
305
|
-
_ctx.$slots.prepend ? (openBlock(), createElementBlock("div", {
|
|
306
|
-
key: 0,
|
|
307
|
-
class: normalizeClass(unref(nsInput).be("group", "prepend"))
|
|
308
|
-
}, [
|
|
309
|
-
renderSlot(_ctx.$slots, "prepend")
|
|
310
|
-
], 2)) : createCommentVNode("v-if", true),
|
|
311
|
-
createElementVNode("div", {
|
|
312
|
-
ref_key: "wrapperRef",
|
|
313
|
-
ref: wrapperRef,
|
|
314
|
-
class: normalizeClass(unref(wrapperKls))
|
|
315
|
-
}, [
|
|
316
|
-
createCommentVNode(" prefix slot "),
|
|
317
|
-
_ctx.$slots.prefix || _ctx.prefixIcon ? (openBlock(), createElementBlock("span", {
|
|
318
|
-
key: 0,
|
|
319
|
-
class: normalizeClass(unref(nsInput).e("prefix"))
|
|
320
|
-
}, [
|
|
321
|
-
createElementVNode("span", {
|
|
322
|
-
class: normalizeClass(unref(nsInput).e("prefix-inner"))
|
|
323
|
-
}, [
|
|
324
|
-
renderSlot(_ctx.$slots, "prefix"),
|
|
325
|
-
_ctx.prefixIcon ? (openBlock(), createBlock(unref(ElIcon), {
|
|
326
|
-
key: 0,
|
|
327
|
-
class: normalizeClass(unref(nsInput).e("icon"))
|
|
328
|
-
}, {
|
|
329
|
-
default: withCtx(() => [
|
|
330
|
-
(openBlock(), createBlock(resolveDynamicComponent(_ctx.prefixIcon)))
|
|
331
|
-
]),
|
|
332
|
-
_: 1
|
|
333
|
-
}, 8, ["class"])) : createCommentVNode("v-if", true)
|
|
334
|
-
], 2)
|
|
335
|
-
], 2)) : createCommentVNode("v-if", true),
|
|
336
|
-
createElementVNode("input", mergeProps({
|
|
337
|
-
id: unref(inputId),
|
|
338
|
-
ref_key: "input",
|
|
339
|
-
ref: input,
|
|
340
|
-
class: unref(nsInput).e("inner")
|
|
341
|
-
}, unref(attrs), {
|
|
342
|
-
name: _ctx.name,
|
|
343
|
-
minlength: _ctx.minlength,
|
|
344
|
-
maxlength: _ctx.maxlength,
|
|
345
|
-
type: _ctx.showPassword ? passwordVisible.value ? "text" : "password" : _ctx.type,
|
|
346
|
-
disabled: unref(inputDisabled),
|
|
347
|
-
readonly: _ctx.readonly,
|
|
348
|
-
autocomplete: _ctx.autocomplete,
|
|
349
|
-
tabindex: _ctx.tabindex,
|
|
350
|
-
"aria-label": _ctx.ariaLabel,
|
|
351
|
-
placeholder: _ctx.placeholder,
|
|
352
|
-
style: _ctx.inputStyle,
|
|
353
|
-
form: _ctx.form,
|
|
354
|
-
autofocus: _ctx.autofocus,
|
|
355
|
-
role: _ctx.containerRole,
|
|
356
|
-
inputmode: _ctx.inputmode,
|
|
357
|
-
onCompositionstart: unref(handleCompositionStart),
|
|
358
|
-
onCompositionupdate: unref(handleCompositionUpdate),
|
|
359
|
-
onCompositionend: unref(handleCompositionEnd),
|
|
360
|
-
onInput: handleInput,
|
|
361
|
-
onChange: handleChange,
|
|
362
|
-
onKeydown: handleKeydown
|
|
363
|
-
}), null, 16, ["id", "name", "minlength", "maxlength", "type", "disabled", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder", "form", "autofocus", "role", "inputmode", "onCompositionstart", "onCompositionupdate", "onCompositionend"]),
|
|
364
|
-
createCommentVNode(" suffix slot "),
|
|
365
|
-
unref(suffixVisible) ? (openBlock(), createElementBlock("span", {
|
|
366
|
-
key: 1,
|
|
367
|
-
class: normalizeClass(unref(nsInput).e("suffix"))
|
|
368
|
-
}, [
|
|
369
|
-
createElementVNode("span", {
|
|
370
|
-
class: normalizeClass(unref(nsInput).e("suffix-inner"))
|
|
371
|
-
}, [
|
|
372
|
-
!unref(showClear) || !unref(showPwdVisible) || !unref(isWordLimitVisible) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
373
|
-
renderSlot(_ctx.$slots, "suffix"),
|
|
374
|
-
_ctx.suffixIcon ? (openBlock(), createBlock(unref(ElIcon), {
|
|
375
|
-
key: 0,
|
|
376
|
-
class: normalizeClass(unref(nsInput).e("icon"))
|
|
377
|
-
}, {
|
|
378
|
-
default: withCtx(() => [
|
|
379
|
-
(openBlock(), createBlock(resolveDynamicComponent(_ctx.suffixIcon)))
|
|
380
|
-
]),
|
|
381
|
-
_: 1
|
|
382
|
-
}, 8, ["class"])) : createCommentVNode("v-if", true)
|
|
383
|
-
], 64)) : createCommentVNode("v-if", true),
|
|
384
|
-
unref(showClear) ? (openBlock(), createBlock(unref(ElIcon), {
|
|
385
|
-
key: 1,
|
|
386
|
-
class: normalizeClass([unref(nsInput).e("icon"), unref(nsInput).e("clear")]),
|
|
387
|
-
onMousedown: withModifiers(unref(NOOP), ["prevent"]),
|
|
388
|
-
onClick: clear
|
|
389
|
-
}, {
|
|
390
|
-
default: withCtx(() => [
|
|
391
|
-
(openBlock(), createBlock(resolveDynamicComponent(_ctx.clearIcon)))
|
|
392
|
-
]),
|
|
393
|
-
_: 1
|
|
394
|
-
}, 8, ["class", "onMousedown"])) : createCommentVNode("v-if", true),
|
|
395
|
-
unref(showPwdVisible) ? (openBlock(), createBlock(unref(ElIcon), {
|
|
396
|
-
key: 2,
|
|
397
|
-
class: normalizeClass([unref(nsInput).e("icon"), unref(nsInput).e("password")]),
|
|
398
|
-
onClick: handlePasswordVisible,
|
|
399
|
-
onMousedown: withModifiers(unref(NOOP), ["prevent"]),
|
|
400
|
-
onMouseup: withModifiers(unref(NOOP), ["prevent"])
|
|
401
|
-
}, {
|
|
402
|
-
default: withCtx(() => [
|
|
403
|
-
(openBlock(), createBlock(resolveDynamicComponent(unref(passwordIcon))))
|
|
404
|
-
]),
|
|
405
|
-
_: 1
|
|
406
|
-
}, 8, ["class", "onMousedown", "onMouseup"])) : createCommentVNode("v-if", true),
|
|
407
|
-
unref(isWordLimitVisible) ? (openBlock(), createElementBlock("span", {
|
|
408
|
-
key: 3,
|
|
409
|
-
class: normalizeClass([
|
|
410
|
-
unref(nsInput).e("count"),
|
|
411
|
-
unref(nsInput).is("outside", _ctx.wordLimitPosition === "outside")
|
|
412
|
-
])
|
|
413
|
-
}, [
|
|
414
|
-
createElementVNode("span", {
|
|
415
|
-
class: normalizeClass(unref(nsInput).e("count-inner"))
|
|
416
|
-
}, toDisplayString(unref(textLength)) + " / " + toDisplayString(_ctx.maxlength), 3)
|
|
417
|
-
], 2)) : createCommentVNode("v-if", true),
|
|
418
|
-
unref(validateState) && unref(validateIcon) && unref(needStatusIcon) ? (openBlock(), createBlock(unref(ElIcon), {
|
|
419
|
-
key: 4,
|
|
420
|
-
class: normalizeClass([
|
|
421
|
-
unref(nsInput).e("icon"),
|
|
422
|
-
unref(nsInput).e("validateIcon"),
|
|
423
|
-
unref(nsInput).is("loading", unref(validateState) === "validating")
|
|
424
|
-
])
|
|
425
|
-
}, {
|
|
426
|
-
default: withCtx(() => [
|
|
427
|
-
(openBlock(), createBlock(resolveDynamicComponent(unref(validateIcon))))
|
|
428
|
-
]),
|
|
429
|
-
_: 1
|
|
430
|
-
}, 8, ["class"])) : createCommentVNode("v-if", true)
|
|
431
|
-
], 2)
|
|
432
|
-
], 2)) : createCommentVNode("v-if", true)
|
|
433
|
-
], 2),
|
|
434
|
-
createCommentVNode(" append slot "),
|
|
435
|
-
_ctx.$slots.append ? (openBlock(), createElementBlock("div", {
|
|
436
|
-
key: 1,
|
|
437
|
-
class: normalizeClass(unref(nsInput).be("group", "append"))
|
|
438
|
-
}, [
|
|
439
|
-
renderSlot(_ctx.$slots, "append")
|
|
440
|
-
], 2)) : createCommentVNode("v-if", true)
|
|
441
|
-
], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
442
|
-
createCommentVNode(" textarea "),
|
|
443
|
-
createElementVNode("textarea", mergeProps({
|
|
444
|
-
id: unref(inputId),
|
|
445
|
-
ref_key: "textarea",
|
|
446
|
-
ref: textarea,
|
|
447
|
-
class: [unref(nsTextarea).e("inner"), unref(nsInput).is("focus", unref(isFocused))]
|
|
448
|
-
}, unref(attrs), {
|
|
449
|
-
name: _ctx.name,
|
|
450
|
-
minlength: _ctx.minlength,
|
|
451
|
-
maxlength: _ctx.maxlength,
|
|
452
|
-
tabindex: _ctx.tabindex,
|
|
453
|
-
disabled: unref(inputDisabled),
|
|
454
|
-
readonly: _ctx.readonly,
|
|
455
|
-
autocomplete: _ctx.autocomplete,
|
|
456
|
-
style: unref(textareaStyle),
|
|
457
|
-
"aria-label": _ctx.ariaLabel,
|
|
458
|
-
placeholder: _ctx.placeholder,
|
|
459
|
-
form: _ctx.form,
|
|
460
|
-
autofocus: _ctx.autofocus,
|
|
461
|
-
rows: _ctx.rows,
|
|
462
|
-
role: _ctx.containerRole,
|
|
463
|
-
onCompositionstart: unref(handleCompositionStart),
|
|
464
|
-
onCompositionupdate: unref(handleCompositionUpdate),
|
|
465
|
-
onCompositionend: unref(handleCompositionEnd),
|
|
466
|
-
onInput: handleInput,
|
|
467
|
-
onFocus: unref(handleFocus),
|
|
468
|
-
onBlur: unref(handleBlur),
|
|
469
|
-
onChange: handleChange,
|
|
470
|
-
onKeydown: handleKeydown
|
|
471
|
-
}), null, 16, ["id", "name", "minlength", "maxlength", "tabindex", "disabled", "readonly", "autocomplete", "aria-label", "placeholder", "form", "autofocus", "rows", "role", "onCompositionstart", "onCompositionupdate", "onCompositionend", "onFocus", "onBlur"]),
|
|
472
|
-
unref(isWordLimitVisible) ? (openBlock(), createElementBlock("span", {
|
|
473
|
-
key: 0,
|
|
474
|
-
style: normalizeStyle(countStyle.value),
|
|
475
|
-
class: normalizeClass([
|
|
476
|
-
unref(nsInput).e("count"),
|
|
477
|
-
unref(nsInput).is("outside", _ctx.wordLimitPosition === "outside")
|
|
478
|
-
])
|
|
479
|
-
}, toDisplayString(unref(textLength)) + " / " + toDisplayString(_ctx.maxlength), 7)) : createCommentVNode("v-if", true)
|
|
480
|
-
], 64))
|
|
481
|
-
], 38);
|
|
482
|
-
};
|
|
483
|
-
}
|
|
484
|
-
});
|
|
485
|
-
var Input = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "input.vue"]]);
|
|
113
|
+
const inputEmits = {
|
|
114
|
+
[UPDATE_MODEL_EVENT]: (value) => isString(value),
|
|
115
|
+
input: (value) => isString(value),
|
|
116
|
+
change: (value, evt) => isString(value) && (evt instanceof Event || evt === void 0),
|
|
117
|
+
focus: (evt) => evt instanceof FocusEvent,
|
|
118
|
+
blur: (evt) => evt instanceof FocusEvent,
|
|
119
|
+
clear: () => true,
|
|
120
|
+
mouseleave: (evt) => evt instanceof MouseEvent,
|
|
121
|
+
mouseenter: (evt) => evt instanceof MouseEvent,
|
|
122
|
+
keydown: (evt) => evt instanceof Event,
|
|
123
|
+
compositionstart: (evt) => evt instanceof CompositionEvent,
|
|
124
|
+
compositionupdate: (evt) => evt instanceof CompositionEvent,
|
|
125
|
+
compositionend: (evt) => evt instanceof CompositionEvent
|
|
126
|
+
};
|
|
486
127
|
|
|
487
|
-
export {
|
|
128
|
+
export { inputEmits, inputProps };
|
|
488
129
|
//# sourceMappingURL=input2.mjs.map
|