@element-plus/nightly 0.0.20250209 → 0.0.20250210
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.full.js +10 -12
- package/dist/index.full.min.js +3 -3
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +3 -3
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +10 -12
- 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/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 +3 -3
- package/es/components/anchor/src/anchor-link.mjs +5 -81
- package/es/components/anchor/src/anchor-link.mjs.map +1 -1
- package/es/components/anchor/src/anchor-link2.mjs +81 -5
- package/es/components/anchor/src/anchor-link2.mjs.map +1 -1
- package/es/components/anchor/src/anchor.mjs +192 -42
- package/es/components/anchor/src/anchor.mjs.map +1 -1
- package/es/components/anchor/src/anchor2.mjs +42 -192
- package/es/components/anchor/src/anchor2.mjs.map +1 -1
- package/es/components/autocomplete/src/autocomplete.mjs +1 -1
- package/es/components/avatar/index.mjs +2 -2
- package/es/components/avatar/src/avatar.mjs +31 -65
- package/es/components/avatar/src/avatar.mjs.map +1 -1
- package/es/components/avatar/src/avatar2.mjs +65 -31
- package/es/components/avatar/src/avatar2.mjs.map +1 -1
- package/es/components/badge/index.mjs +2 -2
- package/es/components/badge/src/badge.mjs +71 -32
- package/es/components/badge/src/badge.mjs.map +1 -1
- package/es/components/badge/src/badge2.mjs +32 -71
- package/es/components/badge/src/badge2.mjs.map +1 -1
- package/es/components/calendar/index.mjs +2 -2
- package/es/components/calendar/src/calendar.mjs +16 -134
- package/es/components/calendar/src/calendar.mjs.map +1 -1
- package/es/components/calendar/src/calendar2.mjs +134 -16
- package/es/components/calendar/src/calendar2.mjs.map +1 -1
- package/es/components/cascader/src/cascader.mjs +1 -1
- package/es/components/check-tag/index.mjs +2 -2
- package/es/components/check-tag/src/check-tag.mjs +38 -14
- package/es/components/check-tag/src/check-tag.mjs.map +1 -1
- package/es/components/check-tag/src/check-tag2.mjs +14 -38
- package/es/components/check-tag/src/check-tag2.mjs.map +1 -1
- package/es/components/color-picker/src/color-picker.mjs +1 -1
- package/es/components/dropdown/src/dropdown.mjs +1 -1
- package/es/components/image/index.mjs +2 -2
- package/es/components/image/src/image.mjs +68 -242
- package/es/components/image/src/image.mjs.map +1 -1
- package/es/components/image/src/image2.mjs +242 -68
- package/es/components/image/src/image2.mjs.map +1 -1
- package/es/components/index.mjs +16 -16
- package/es/components/mention/index.mjs +2 -2
- package/es/components/mention/src/mention.mjs +62 -282
- package/es/components/mention/src/mention.mjs.map +1 -1
- package/es/components/mention/src/mention2.mjs +282 -62
- package/es/components/mention/src/mention2.mjs.map +1 -1
- package/es/components/pagination/src/components/next.mjs +18 -35
- package/es/components/pagination/src/components/next.mjs.map +1 -1
- package/es/components/pagination/src/components/next2.mjs +35 -18
- package/es/components/pagination/src/components/next2.mjs.map +1 -1
- package/es/components/pagination/src/components/total.mjs +26 -6
- package/es/components/pagination/src/components/total.mjs.map +1 -1
- package/es/components/pagination/src/components/total2.mjs +6 -26
- package/es/components/pagination/src/components/total2.mjs.map +1 -1
- package/es/components/pagination/src/pagination.mjs +2 -2
- package/es/components/popconfirm/index.mjs +2 -2
- package/es/components/popconfirm/src/popconfirm.mjs +45 -114
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm2.mjs +114 -45
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/popover/src/popover.mjs +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/result/index.mjs +2 -2
- package/es/components/result/src/result.mjs +28 -62
- package/es/components/result/src/result.mjs.map +1 -1
- package/es/components/result/src/result2.mjs +62 -28
- package/es/components/result/src/result2.mjs.map +1 -1
- package/es/components/select/src/select.mjs +1 -1
- package/es/components/select-v2/src/defaults.mjs +1 -1
- package/es/components/skeleton/index.mjs +2 -2
- package/es/components/skeleton/src/skeleton.mjs +21 -48
- package/es/components/skeleton/src/skeleton.mjs.map +1 -1
- package/es/components/skeleton/src/skeleton2.mjs +48 -21
- package/es/components/skeleton/src/skeleton2.mjs.map +1 -1
- package/es/components/slider/src/button.mjs +89 -19
- package/es/components/slider/src/button.mjs.map +1 -1
- package/es/components/slider/src/button2.mjs +19 -89
- package/es/components/slider/src/button2.mjs.map +1 -1
- package/es/components/slider/src/slider2.mjs +1 -1
- package/es/components/tabs/index.mjs +1 -1
- package/es/components/tabs/src/tab-bar.mjs +7 -95
- package/es/components/tabs/src/tab-bar.mjs.map +1 -1
- package/es/components/tabs/src/tab-bar2.mjs +95 -7
- package/es/components/tabs/src/tab-bar2.mjs.map +1 -1
- package/es/components/tabs/src/tab-nav.mjs +1 -1
- package/es/components/tooltip/index.mjs +1 -1
- package/es/components/tooltip/src/content.mjs +28 -192
- package/es/components/tooltip/src/content.mjs.map +1 -1
- package/es/components/tooltip/src/content2.mjs +192 -28
- 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/tooltip-v2/index.mjs +1 -1
- package/es/components/tooltip-v2/src/arrow.mjs +21 -37
- package/es/components/tooltip-v2/src/arrow.mjs.map +1 -1
- package/es/components/tooltip-v2/src/arrow2.mjs +37 -21
- package/es/components/tooltip-v2/src/arrow2.mjs.map +1 -1
- package/es/components/tooltip-v2/src/content2.mjs +1 -1
- package/es/components/tooltip-v2/src/tooltip.mjs +1 -1
- package/es/components/tooltip-v2/src/tooltip2.mjs +2 -2
- package/es/components/tour/index.mjs +2 -2
- package/es/components/tour/src/step.mjs +168 -44
- package/es/components/tour/src/step.mjs.map +1 -1
- package/es/components/tour/src/step2.mjs +44 -168
- package/es/components/tour/src/step2.mjs.map +1 -1
- package/es/components/transfer/index.mjs +2 -2
- package/es/components/transfer/src/composables/use-checked-change.mjs +1 -1
- package/es/components/transfer/src/transfer-panel.mjs +1 -1
- package/es/components/transfer/src/transfer.mjs +68 -164
- package/es/components/transfer/src/transfer.mjs.map +1 -1
- package/es/components/transfer/src/transfer2.mjs +164 -68
- package/es/components/transfer/src/transfer2.mjs.map +1 -1
- package/es/components/tree/src/model/util.mjs +1 -5
- package/es/components/tree/src/model/util.mjs.map +1 -1
- package/es/components/tree/src/tree-node-content.mjs.map +1 -1
- package/es/components/tree/src/tree-node.mjs +7 -5
- package/es/components/tree/src/tree-node.mjs.map +1 -1
- package/es/components/tree/src/tree-node.vue.d.ts +4 -5
- package/es/components/upload/index.mjs +2 -2
- package/es/components/upload/src/upload-content.mjs +1 -1
- package/es/components/upload/src/upload-content2.mjs +1 -1
- package/es/components/upload/src/upload-list.mjs +1 -1
- package/es/components/upload/src/upload.mjs +97 -125
- package/es/components/upload/src/upload.mjs.map +1 -1
- package/es/components/upload/src/upload2.mjs +125 -97
- package/es/components/upload/src/upload2.mjs.map +1 -1
- package/es/components/upload/src/use-handlers.mjs +1 -1
- package/es/components/visual-hidden/index.mjs +3 -3
- package/es/components/visual-hidden/src/visual-hidden.mjs +35 -6
- package/es/components/visual-hidden/src/visual-hidden.mjs.map +1 -1
- package/es/components/visual-hidden/src/visual-hidden2.mjs +6 -35
- package/es/components/visual-hidden/src/visual-hidden2.mjs.map +1 -1
- package/es/directives/click-outside/index.mjs +1 -1
- package/es/hooks/use-focus-controller/index.mjs +1 -1
- package/es/hooks/use-lockscreen/index.mjs +1 -1
- package/es/index.mjs +16 -16
- 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 +3 -3
- package/lib/components/anchor/src/anchor-link.js +5 -81
- package/lib/components/anchor/src/anchor-link.js.map +1 -1
- package/lib/components/anchor/src/anchor-link2.js +81 -5
- package/lib/components/anchor/src/anchor-link2.js.map +1 -1
- package/lib/components/anchor/src/anchor.js +191 -42
- package/lib/components/anchor/src/anchor.js.map +1 -1
- package/lib/components/anchor/src/anchor2.js +42 -191
- package/lib/components/anchor/src/anchor2.js.map +1 -1
- package/lib/components/autocomplete/src/autocomplete.js +1 -1
- package/lib/components/avatar/index.js +2 -2
- package/lib/components/avatar/src/avatar.js +32 -65
- package/lib/components/avatar/src/avatar.js.map +1 -1
- package/lib/components/avatar/src/avatar2.js +65 -32
- package/lib/components/avatar/src/avatar2.js.map +1 -1
- package/lib/components/badge/index.js +2 -2
- package/lib/components/badge/src/badge.js +71 -32
- package/lib/components/badge/src/badge.js.map +1 -1
- package/lib/components/badge/src/badge2.js +32 -71
- package/lib/components/badge/src/badge2.js.map +1 -1
- package/lib/components/calendar/index.js +2 -2
- package/lib/components/calendar/src/calendar.js +17 -134
- package/lib/components/calendar/src/calendar.js.map +1 -1
- package/lib/components/calendar/src/calendar2.js +134 -17
- package/lib/components/calendar/src/calendar2.js.map +1 -1
- package/lib/components/cascader/src/cascader.js +1 -1
- package/lib/components/check-tag/index.js +2 -2
- package/lib/components/check-tag/src/check-tag.js +38 -15
- package/lib/components/check-tag/src/check-tag.js.map +1 -1
- package/lib/components/check-tag/src/check-tag2.js +15 -38
- package/lib/components/check-tag/src/check-tag2.js.map +1 -1
- package/lib/components/color-picker/src/color-picker.js +1 -1
- package/lib/components/dropdown/src/dropdown.js +1 -1
- package/lib/components/image/index.js +2 -2
- package/lib/components/image/src/image.js +68 -241
- package/lib/components/image/src/image.js.map +1 -1
- package/lib/components/image/src/image2.js +241 -68
- package/lib/components/image/src/image2.js.map +1 -1
- package/lib/components/index.js +16 -16
- package/lib/components/mention/index.js +2 -2
- package/lib/components/mention/src/mention.js +61 -280
- package/lib/components/mention/src/mention.js.map +1 -1
- package/lib/components/mention/src/mention2.js +280 -61
- package/lib/components/mention/src/mention2.js.map +1 -1
- package/lib/components/pagination/src/components/next.js +18 -35
- package/lib/components/pagination/src/components/next.js.map +1 -1
- package/lib/components/pagination/src/components/next2.js +35 -18
- package/lib/components/pagination/src/components/next2.js.map +1 -1
- package/lib/components/pagination/src/components/total.js +26 -6
- package/lib/components/pagination/src/components/total.js.map +1 -1
- package/lib/components/pagination/src/components/total2.js +6 -26
- package/lib/components/pagination/src/components/total2.js.map +1 -1
- package/lib/components/pagination/src/pagination.js +2 -2
- package/lib/components/popconfirm/index.js +2 -2
- package/lib/components/popconfirm/src/popconfirm.js +46 -114
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm2.js +114 -46
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/popover/src/popover.js +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/result/index.js +2 -2
- package/lib/components/result/src/result.js +30 -62
- package/lib/components/result/src/result.js.map +1 -1
- package/lib/components/result/src/result2.js +62 -30
- package/lib/components/result/src/result2.js.map +1 -1
- package/lib/components/select/src/select.js +1 -1
- package/lib/components/select-v2/src/defaults.js +1 -1
- package/lib/components/skeleton/index.js +2 -2
- package/lib/components/skeleton/src/skeleton.js +21 -48
- package/lib/components/skeleton/src/skeleton.js.map +1 -1
- package/lib/components/skeleton/src/skeleton2.js +48 -21
- package/lib/components/skeleton/src/skeleton2.js.map +1 -1
- package/lib/components/slider/src/button.js +89 -20
- package/lib/components/slider/src/button.js.map +1 -1
- package/lib/components/slider/src/button2.js +20 -89
- package/lib/components/slider/src/button2.js.map +1 -1
- package/lib/components/slider/src/slider2.js +1 -1
- package/lib/components/tabs/index.js +1 -1
- package/lib/components/tabs/src/tab-bar.js +7 -95
- package/lib/components/tabs/src/tab-bar.js.map +1 -1
- package/lib/components/tabs/src/tab-bar2.js +95 -7
- package/lib/components/tabs/src/tab-bar2.js.map +1 -1
- package/lib/components/tabs/src/tab-nav.js +1 -1
- package/lib/components/tooltip/index.js +1 -1
- package/lib/components/tooltip/src/content.js +28 -192
- package/lib/components/tooltip/src/content.js.map +1 -1
- package/lib/components/tooltip/src/content2.js +192 -28
- 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/tooltip-v2/index.js +1 -1
- package/lib/components/tooltip-v2/src/arrow.js +22 -37
- package/lib/components/tooltip-v2/src/arrow.js.map +1 -1
- package/lib/components/tooltip-v2/src/arrow2.js +37 -22
- package/lib/components/tooltip-v2/src/arrow2.js.map +1 -1
- package/lib/components/tooltip-v2/src/content2.js +1 -1
- package/lib/components/tooltip-v2/src/tooltip.js +1 -1
- package/lib/components/tooltip-v2/src/tooltip2.js +2 -2
- package/lib/components/tour/index.js +2 -2
- package/lib/components/tour/src/step.js +167 -44
- package/lib/components/tour/src/step.js.map +1 -1
- package/lib/components/tour/src/step2.js +44 -167
- package/lib/components/tour/src/step2.js.map +1 -1
- package/lib/components/transfer/index.js +2 -2
- package/lib/components/transfer/src/composables/use-checked-change.js +1 -1
- package/lib/components/transfer/src/transfer-panel.js +1 -1
- package/lib/components/transfer/src/transfer.js +72 -164
- package/lib/components/transfer/src/transfer.js.map +1 -1
- package/lib/components/transfer/src/transfer2.js +164 -72
- package/lib/components/transfer/src/transfer2.js.map +1 -1
- package/lib/components/tree/src/model/util.js +1 -5
- package/lib/components/tree/src/model/util.js.map +1 -1
- package/lib/components/tree/src/tree-node-content.js.map +1 -1
- package/lib/components/tree/src/tree-node.js +7 -5
- package/lib/components/tree/src/tree-node.js.map +1 -1
- package/lib/components/tree/src/tree-node.vue.d.ts +4 -5
- package/lib/components/upload/index.js +2 -2
- package/lib/components/upload/src/upload-content.js +1 -1
- package/lib/components/upload/src/upload-content2.js +1 -1
- package/lib/components/upload/src/upload-list.js +1 -1
- package/lib/components/upload/src/upload.js +100 -125
- package/lib/components/upload/src/upload.js.map +1 -1
- package/lib/components/upload/src/upload2.js +125 -100
- package/lib/components/upload/src/upload2.js.map +1 -1
- package/lib/components/upload/src/use-handlers.js +1 -1
- package/lib/components/visual-hidden/index.js +2 -2
- package/lib/components/visual-hidden/src/visual-hidden.js +35 -6
- package/lib/components/visual-hidden/src/visual-hidden.js.map +1 -1
- package/lib/components/visual-hidden/src/visual-hidden2.js +6 -35
- package/lib/components/visual-hidden/src/visual-hidden2.js.map +1 -1
- package/lib/directives/click-outside/index.js +1 -1
- package/lib/hooks/use-focus-controller/index.js +1 -1
- package/lib/hooks/use-lockscreen/index.js +1 -1
- package/lib/index.js +16 -16
- 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/web-types.json +1 -1
|
@@ -1,94 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import { useSliderButton } from './composables/use-slider-button.mjs';
|
|
6
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
1
|
+
import { placements } from '@popperjs/core';
|
|
2
|
+
import { buildProps } from '../../../utils/vue/props/runtime.mjs';
|
|
3
|
+
import { UPDATE_MODEL_EVENT } from '../../../constants/event.mjs';
|
|
4
|
+
import { isNumber } from '../../../utils/types.mjs';
|
|
7
5
|
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
hovering: false,
|
|
20
|
-
dragging: false,
|
|
21
|
-
isClick: false,
|
|
22
|
-
startX: 0,
|
|
23
|
-
currentX: 0,
|
|
24
|
-
startY: 0,
|
|
25
|
-
currentY: 0,
|
|
26
|
-
startPosition: 0,
|
|
27
|
-
newPosition: 0,
|
|
28
|
-
oldValue: props.modelValue
|
|
29
|
-
});
|
|
30
|
-
const {
|
|
31
|
-
disabled,
|
|
32
|
-
button,
|
|
33
|
-
tooltip,
|
|
34
|
-
showTooltip,
|
|
35
|
-
tooltipVisible,
|
|
36
|
-
wrapperStyle,
|
|
37
|
-
formatValue,
|
|
38
|
-
handleMouseEnter,
|
|
39
|
-
handleMouseLeave,
|
|
40
|
-
onButtonDown,
|
|
41
|
-
onKeyDown,
|
|
42
|
-
setPosition
|
|
43
|
-
} = useSliderButton(props, initData, emit);
|
|
44
|
-
const { hovering, dragging } = toRefs(initData);
|
|
45
|
-
expose({
|
|
46
|
-
onButtonDown,
|
|
47
|
-
onKeyDown,
|
|
48
|
-
setPosition,
|
|
49
|
-
hovering,
|
|
50
|
-
dragging
|
|
51
|
-
});
|
|
52
|
-
return (_ctx, _cache) => {
|
|
53
|
-
return openBlock(), createElementBlock("div", {
|
|
54
|
-
ref_key: "button",
|
|
55
|
-
ref: button,
|
|
56
|
-
class: normalizeClass([unref(ns).e("button-wrapper"), { hover: unref(hovering), dragging: unref(dragging) }]),
|
|
57
|
-
style: normalizeStyle(unref(wrapperStyle)),
|
|
58
|
-
tabindex: unref(disabled) ? -1 : 0,
|
|
59
|
-
onMouseenter: unref(handleMouseEnter),
|
|
60
|
-
onMouseleave: unref(handleMouseLeave),
|
|
61
|
-
onMousedown: unref(onButtonDown),
|
|
62
|
-
onFocus: unref(handleMouseEnter),
|
|
63
|
-
onBlur: unref(handleMouseLeave),
|
|
64
|
-
onKeydown: unref(onKeyDown)
|
|
65
|
-
}, [
|
|
66
|
-
createVNode(unref(ElTooltip), {
|
|
67
|
-
ref_key: "tooltip",
|
|
68
|
-
ref: tooltip,
|
|
69
|
-
visible: unref(tooltipVisible),
|
|
70
|
-
placement: _ctx.placement,
|
|
71
|
-
"fallback-placements": ["top", "bottom", "right", "left"],
|
|
72
|
-
"stop-popper-mouse-event": false,
|
|
73
|
-
"popper-class": _ctx.tooltipClass,
|
|
74
|
-
disabled: !unref(showTooltip),
|
|
75
|
-
persistent: unref(showTooltip)
|
|
76
|
-
}, {
|
|
77
|
-
content: withCtx(() => [
|
|
78
|
-
createElementVNode("span", null, toDisplayString(unref(formatValue)), 1)
|
|
79
|
-
]),
|
|
80
|
-
default: withCtx(() => [
|
|
81
|
-
createElementVNode("div", {
|
|
82
|
-
class: normalizeClass([unref(ns).e("button"), { hover: unref(hovering), dragging: unref(dragging) }])
|
|
83
|
-
}, null, 2)
|
|
84
|
-
]),
|
|
85
|
-
_: 1
|
|
86
|
-
}, 8, ["visible", "placement", "popper-class", "disabled", "persistent"])
|
|
87
|
-
], 46, ["tabindex", "onMouseenter", "onMouseleave", "onMousedown", "onFocus", "onBlur", "onKeydown"]);
|
|
88
|
-
};
|
|
6
|
+
const sliderButtonProps = buildProps({
|
|
7
|
+
modelValue: {
|
|
8
|
+
type: Number,
|
|
9
|
+
default: 0
|
|
10
|
+
},
|
|
11
|
+
vertical: Boolean,
|
|
12
|
+
tooltipClass: String,
|
|
13
|
+
placement: {
|
|
14
|
+
type: String,
|
|
15
|
+
values: placements,
|
|
16
|
+
default: "top"
|
|
89
17
|
}
|
|
90
18
|
});
|
|
91
|
-
|
|
19
|
+
const sliderButtonEmits = {
|
|
20
|
+
[UPDATE_MODEL_EVENT]: (value) => isNumber(value)
|
|
21
|
+
};
|
|
92
22
|
|
|
93
|
-
export {
|
|
23
|
+
export { sliderButtonEmits, sliderButtonProps };
|
|
94
24
|
//# sourceMappingURL=button2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button2.mjs","sources":["../../../../../../packages/components/slider/src/button.
|
|
1
|
+
{"version":3,"file":"button2.mjs","sources":["../../../../../../packages/components/slider/src/button.ts"],"sourcesContent":["import { placements } from '@popperjs/core'\nimport { buildProps, isNumber } from '@element-plus/utils'\nimport { UPDATE_MODEL_EVENT } from '@element-plus/constants'\nimport type { ComponentPublicInstance, ExtractPropTypes, Ref } from 'vue'\nimport type Button from './button.vue'\n\nexport const sliderButtonProps = buildProps({\n modelValue: {\n type: Number,\n default: 0,\n },\n vertical: Boolean,\n tooltipClass: String,\n placement: {\n type: String,\n values: placements,\n default: 'top',\n },\n} as const)\nexport type SliderButtonProps = ExtractPropTypes<typeof sliderButtonProps>\n\nexport const sliderButtonEmits = {\n [UPDATE_MODEL_EVENT]: (value: number) => isNumber(value),\n}\nexport type SliderButtonEmits = typeof sliderButtonEmits\n\nexport type SliderButtonInstance = ComponentPublicInstance<typeof Button>\n\nexport type ButtonRefs = Record<\n 'firstButton' | 'secondButton',\n Ref<SliderButtonInstance | undefined>\n>\n\nexport interface SliderButtonInitData {\n hovering: boolean\n dragging: boolean\n isClick: boolean\n startX: number\n currentX: number\n startY: number\n currentY: number\n startPosition: number\n newPosition: number\n oldValue: number\n}\n"],"names":[],"mappings":";;;;;AAGY,MAAC,iBAAiB,GAAG,UAAU,CAAC;AAC5C,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,CAAC;AACd,GAAG;AACH,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,YAAY,EAAE,MAAM;AACtB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,UAAU;AACtB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,iBAAiB,GAAG;AACjC,EAAE,CAAC,kBAAkB,GAAG,CAAC,KAAK,KAAK,QAAQ,CAAC,KAAK,CAAC;AAClD;;;;"}
|
|
@@ -3,7 +3,7 @@ import { useEventListener } from '@vueuse/core';
|
|
|
3
3
|
import { ElInputNumber } from '../../input-number/index.mjs';
|
|
4
4
|
import { sliderContextKey } from './constants.mjs';
|
|
5
5
|
import { sliderProps, sliderEmits } from './slider.mjs';
|
|
6
|
-
import SliderButton from './
|
|
6
|
+
import SliderButton from './button.mjs';
|
|
7
7
|
import SliderMarker from './marker.mjs';
|
|
8
8
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
9
9
|
import { useSlide } from './composables/use-slide.mjs';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import Tabs from './src/tabs.mjs';
|
|
2
2
|
export { tabsEmits, tabsProps } from './src/tabs.mjs';
|
|
3
3
|
import TabPane from './src/tab-pane2.mjs';
|
|
4
|
-
export { tabBarProps } from './src/tab-
|
|
4
|
+
export { tabBarProps } from './src/tab-bar.mjs';
|
|
5
5
|
export { tabNavEmits, tabNavProps } from './src/tab-nav.mjs';
|
|
6
6
|
export { tabPaneProps } from './src/tab-pane.mjs';
|
|
7
7
|
export { tabsRootContextKey } from './src/constants.mjs';
|
|
@@ -1,100 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { tabsRootContextKey } from './constants.mjs';
|
|
4
|
-
import { tabBarProps } from './tab-bar2.mjs';
|
|
5
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
6
|
-
import { throwError } from '../../../utils/error.mjs';
|
|
7
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
8
|
-
import { capitalize } from '../../../utils/strings.mjs';
|
|
1
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
2
|
+
import { mutable } from '../../../utils/typescript.mjs';
|
|
9
3
|
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
15
|
-
...__default__,
|
|
16
|
-
props: tabBarProps,
|
|
17
|
-
setup(__props, { expose }) {
|
|
18
|
-
const props = __props;
|
|
19
|
-
const instance = getCurrentInstance();
|
|
20
|
-
const rootTabs = inject(tabsRootContextKey);
|
|
21
|
-
if (!rootTabs)
|
|
22
|
-
throwError(COMPONENT_NAME, "<el-tabs><el-tab-bar /></el-tabs>");
|
|
23
|
-
const ns = useNamespace("tabs");
|
|
24
|
-
const barRef = ref();
|
|
25
|
-
const barStyle = ref();
|
|
26
|
-
const getBarStyle = () => {
|
|
27
|
-
let offset = 0;
|
|
28
|
-
let tabSize = 0;
|
|
29
|
-
const sizeName = ["top", "bottom"].includes(rootTabs.props.tabPosition) ? "width" : "height";
|
|
30
|
-
const sizeDir = sizeName === "width" ? "x" : "y";
|
|
31
|
-
const position = sizeDir === "x" ? "left" : "top";
|
|
32
|
-
props.tabs.every((tab) => {
|
|
33
|
-
var _a, _b;
|
|
34
|
-
const $el = (_b = (_a = instance.parent) == null ? void 0 : _a.refs) == null ? void 0 : _b[`tab-${tab.uid}`];
|
|
35
|
-
if (!$el)
|
|
36
|
-
return false;
|
|
37
|
-
if (!tab.active) {
|
|
38
|
-
return true;
|
|
39
|
-
}
|
|
40
|
-
offset = $el[`offset${capitalize(position)}`];
|
|
41
|
-
tabSize = $el[`client${capitalize(sizeName)}`];
|
|
42
|
-
const tabStyles = window.getComputedStyle($el);
|
|
43
|
-
if (sizeName === "width") {
|
|
44
|
-
tabSize -= Number.parseFloat(tabStyles.paddingLeft) + Number.parseFloat(tabStyles.paddingRight);
|
|
45
|
-
offset += Number.parseFloat(tabStyles.paddingLeft);
|
|
46
|
-
}
|
|
47
|
-
return false;
|
|
48
|
-
});
|
|
49
|
-
return {
|
|
50
|
-
[sizeName]: `${tabSize}px`,
|
|
51
|
-
transform: `translate${capitalize(sizeDir)}(${offset}px)`
|
|
52
|
-
};
|
|
53
|
-
};
|
|
54
|
-
const update = () => barStyle.value = getBarStyle();
|
|
55
|
-
const saveObserver = [];
|
|
56
|
-
const observerTabs = () => {
|
|
57
|
-
var _a;
|
|
58
|
-
saveObserver.forEach((observer) => observer.stop());
|
|
59
|
-
saveObserver.length = 0;
|
|
60
|
-
const list = (_a = instance.parent) == null ? void 0 : _a.refs;
|
|
61
|
-
if (!list)
|
|
62
|
-
return;
|
|
63
|
-
for (const key in list) {
|
|
64
|
-
if (key.startsWith("tab-")) {
|
|
65
|
-
const _el = list[key];
|
|
66
|
-
if (_el) {
|
|
67
|
-
saveObserver.push(useResizeObserver(_el, update));
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
};
|
|
72
|
-
watch(() => props.tabs, async () => {
|
|
73
|
-
await nextTick();
|
|
74
|
-
update();
|
|
75
|
-
observerTabs();
|
|
76
|
-
}, { immediate: true });
|
|
77
|
-
const barObserever = useResizeObserver(barRef, () => update());
|
|
78
|
-
onBeforeUnmount(() => {
|
|
79
|
-
saveObserver.forEach((observer) => observer.stop());
|
|
80
|
-
saveObserver.length = 0;
|
|
81
|
-
barObserever.stop();
|
|
82
|
-
});
|
|
83
|
-
expose({
|
|
84
|
-
ref: barRef,
|
|
85
|
-
update
|
|
86
|
-
});
|
|
87
|
-
return (_ctx, _cache) => {
|
|
88
|
-
return openBlock(), createElementBlock("div", {
|
|
89
|
-
ref_key: "barRef",
|
|
90
|
-
ref: barRef,
|
|
91
|
-
class: normalizeClass([unref(ns).e("active-bar"), unref(ns).is(unref(rootTabs).props.tabPosition)]),
|
|
92
|
-
style: normalizeStyle(barStyle.value)
|
|
93
|
-
}, null, 6);
|
|
94
|
-
};
|
|
4
|
+
const tabBarProps = buildProps({
|
|
5
|
+
tabs: {
|
|
6
|
+
type: definePropType(Array),
|
|
7
|
+
default: () => mutable([])
|
|
95
8
|
}
|
|
96
9
|
});
|
|
97
|
-
var TabBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "tab-bar.vue"]]);
|
|
98
10
|
|
|
99
|
-
export {
|
|
11
|
+
export { tabBarProps };
|
|
100
12
|
//# sourceMappingURL=tab-bar.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tab-bar.mjs","sources":["../../../../../../packages/components/tabs/src/tab-bar.
|
|
1
|
+
{"version":3,"file":"tab-bar.mjs","sources":["../../../../../../packages/components/tabs/src/tab-bar.ts"],"sourcesContent":["import { buildProps, definePropType, mutable } from '@element-plus/utils'\nimport type { ExtractPropTypes } from 'vue'\nimport type { TabsPaneContext } from './constants'\nimport type TabBar from './tab-bar.vue'\n\nexport const tabBarProps = buildProps({\n tabs: {\n type: definePropType<TabsPaneContext[]>(Array),\n default: () => mutable([] as const),\n },\n} as const)\n\nexport type TabBarProps = ExtractPropTypes<typeof tabBarProps>\nexport type TabBarInstance = InstanceType<typeof TabBar>\n"],"names":[],"mappings":";;;AACY,MAAC,WAAW,GAAG,UAAU,CAAC;AACtC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,cAAc,CAAC,KAAK,CAAC;AAC/B,IAAI,OAAO,EAAE,MAAM,OAAO,CAAC,EAAE,CAAC;AAC9B,GAAG;AACH,CAAC;;;;"}
|
|
@@ -1,12 +1,100 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { defineComponent, getCurrentInstance, inject, ref, watch, nextTick, onBeforeUnmount, openBlock, createElementBlock, normalizeClass, unref, normalizeStyle } from 'vue';
|
|
2
|
+
import { useResizeObserver } from '@vueuse/core';
|
|
3
|
+
import { tabsRootContextKey } from './constants.mjs';
|
|
4
|
+
import { tabBarProps } from './tab-bar.mjs';
|
|
5
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
6
|
+
import { throwError } from '../../../utils/error.mjs';
|
|
7
|
+
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
8
|
+
import { capitalize } from '../../../utils/strings.mjs';
|
|
3
9
|
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
10
|
+
const COMPONENT_NAME = "ElTabBar";
|
|
11
|
+
const __default__ = defineComponent({
|
|
12
|
+
name: COMPONENT_NAME
|
|
13
|
+
});
|
|
14
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
15
|
+
...__default__,
|
|
16
|
+
props: tabBarProps,
|
|
17
|
+
setup(__props, { expose }) {
|
|
18
|
+
const props = __props;
|
|
19
|
+
const instance = getCurrentInstance();
|
|
20
|
+
const rootTabs = inject(tabsRootContextKey);
|
|
21
|
+
if (!rootTabs)
|
|
22
|
+
throwError(COMPONENT_NAME, "<el-tabs><el-tab-bar /></el-tabs>");
|
|
23
|
+
const ns = useNamespace("tabs");
|
|
24
|
+
const barRef = ref();
|
|
25
|
+
const barStyle = ref();
|
|
26
|
+
const getBarStyle = () => {
|
|
27
|
+
let offset = 0;
|
|
28
|
+
let tabSize = 0;
|
|
29
|
+
const sizeName = ["top", "bottom"].includes(rootTabs.props.tabPosition) ? "width" : "height";
|
|
30
|
+
const sizeDir = sizeName === "width" ? "x" : "y";
|
|
31
|
+
const position = sizeDir === "x" ? "left" : "top";
|
|
32
|
+
props.tabs.every((tab) => {
|
|
33
|
+
var _a, _b;
|
|
34
|
+
const $el = (_b = (_a = instance.parent) == null ? void 0 : _a.refs) == null ? void 0 : _b[`tab-${tab.uid}`];
|
|
35
|
+
if (!$el)
|
|
36
|
+
return false;
|
|
37
|
+
if (!tab.active) {
|
|
38
|
+
return true;
|
|
39
|
+
}
|
|
40
|
+
offset = $el[`offset${capitalize(position)}`];
|
|
41
|
+
tabSize = $el[`client${capitalize(sizeName)}`];
|
|
42
|
+
const tabStyles = window.getComputedStyle($el);
|
|
43
|
+
if (sizeName === "width") {
|
|
44
|
+
tabSize -= Number.parseFloat(tabStyles.paddingLeft) + Number.parseFloat(tabStyles.paddingRight);
|
|
45
|
+
offset += Number.parseFloat(tabStyles.paddingLeft);
|
|
46
|
+
}
|
|
47
|
+
return false;
|
|
48
|
+
});
|
|
49
|
+
return {
|
|
50
|
+
[sizeName]: `${tabSize}px`,
|
|
51
|
+
transform: `translate${capitalize(sizeDir)}(${offset}px)`
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
const update = () => barStyle.value = getBarStyle();
|
|
55
|
+
const saveObserver = [];
|
|
56
|
+
const observerTabs = () => {
|
|
57
|
+
var _a;
|
|
58
|
+
saveObserver.forEach((observer) => observer.stop());
|
|
59
|
+
saveObserver.length = 0;
|
|
60
|
+
const list = (_a = instance.parent) == null ? void 0 : _a.refs;
|
|
61
|
+
if (!list)
|
|
62
|
+
return;
|
|
63
|
+
for (const key in list) {
|
|
64
|
+
if (key.startsWith("tab-")) {
|
|
65
|
+
const _el = list[key];
|
|
66
|
+
if (_el) {
|
|
67
|
+
saveObserver.push(useResizeObserver(_el, update));
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
watch(() => props.tabs, async () => {
|
|
73
|
+
await nextTick();
|
|
74
|
+
update();
|
|
75
|
+
observerTabs();
|
|
76
|
+
}, { immediate: true });
|
|
77
|
+
const barObserever = useResizeObserver(barRef, () => update());
|
|
78
|
+
onBeforeUnmount(() => {
|
|
79
|
+
saveObserver.forEach((observer) => observer.stop());
|
|
80
|
+
saveObserver.length = 0;
|
|
81
|
+
barObserever.stop();
|
|
82
|
+
});
|
|
83
|
+
expose({
|
|
84
|
+
ref: barRef,
|
|
85
|
+
update
|
|
86
|
+
});
|
|
87
|
+
return (_ctx, _cache) => {
|
|
88
|
+
return openBlock(), createElementBlock("div", {
|
|
89
|
+
ref_key: "barRef",
|
|
90
|
+
ref: barRef,
|
|
91
|
+
class: normalizeClass([unref(ns).e("active-bar"), unref(ns).is(unref(rootTabs).props.tabPosition)]),
|
|
92
|
+
style: normalizeStyle(barStyle.value)
|
|
93
|
+
}, null, 6);
|
|
94
|
+
};
|
|
8
95
|
}
|
|
9
96
|
});
|
|
97
|
+
var TabBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "tab-bar.vue"]]);
|
|
10
98
|
|
|
11
|
-
export {
|
|
99
|
+
export { TabBar as default };
|
|
12
100
|
//# sourceMappingURL=tab-bar2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tab-bar2.mjs","sources":["../../../../../../packages/components/tabs/src/tab-bar.
|
|
1
|
+
{"version":3,"file":"tab-bar2.mjs","sources":["../../../../../../packages/components/tabs/src/tab-bar.vue"],"sourcesContent":["<template>\n <div\n ref=\"barRef\"\n :class=\"[ns.e('active-bar'), ns.is(rootTabs!.props.tabPosition)]\"\n :style=\"barStyle\"\n />\n</template>\n\n<script lang=\"ts\" setup>\nimport {\n getCurrentInstance,\n inject,\n nextTick,\n onBeforeUnmount,\n ref,\n watch,\n} from 'vue'\nimport { useResizeObserver } from '@vueuse/core'\nimport { capitalize, throwError } from '@element-plus/utils'\nimport { useNamespace } from '@element-plus/hooks'\nimport { tabsRootContextKey } from './constants'\nimport { tabBarProps } from './tab-bar'\n\nimport type { CSSProperties } from 'vue'\n\nconst COMPONENT_NAME = 'ElTabBar'\ndefineOptions({\n name: COMPONENT_NAME,\n})\nconst props = defineProps(tabBarProps)\n\nconst instance = getCurrentInstance()!\nconst rootTabs = inject(tabsRootContextKey)\nif (!rootTabs) throwError(COMPONENT_NAME, '<el-tabs><el-tab-bar /></el-tabs>')\n\nconst ns = useNamespace('tabs')\n\nconst barRef = ref<HTMLDivElement>()\nconst barStyle = ref<CSSProperties>()\n\nconst getBarStyle = (): CSSProperties => {\n let offset = 0\n let tabSize = 0\n\n const sizeName = ['top', 'bottom'].includes(rootTabs.props.tabPosition)\n ? 'width'\n : 'height'\n const sizeDir = sizeName === 'width' ? 'x' : 'y'\n const position = sizeDir === 'x' ? 'left' : 'top'\n\n props.tabs.every((tab) => {\n const $el = instance.parent?.refs?.[`tab-${tab.uid}`] as HTMLElement\n if (!$el) return false\n\n if (!tab.active) {\n return true\n }\n\n offset = $el[`offset${capitalize(position)}`]\n tabSize = $el[`client${capitalize(sizeName)}`]\n\n const tabStyles = window.getComputedStyle($el)\n\n if (sizeName === 'width') {\n tabSize -=\n Number.parseFloat(tabStyles.paddingLeft) +\n Number.parseFloat(tabStyles.paddingRight)\n offset += Number.parseFloat(tabStyles.paddingLeft)\n }\n return false\n })\n\n return {\n [sizeName]: `${tabSize}px`,\n transform: `translate${capitalize(sizeDir)}(${offset}px)`,\n }\n}\n\nconst update = () => (barStyle.value = getBarStyle())\n\nconst saveObserver = [] as ReturnType<typeof useResizeObserver>[]\nconst observerTabs = () => {\n saveObserver.forEach((observer) => observer.stop())\n saveObserver.length = 0\n const list = instance.parent?.refs as Record<string, HTMLElement>\n if (!list) return\n for (const key in list) {\n if (key.startsWith('tab-')) {\n const _el = list[key]\n if (_el) {\n saveObserver.push(useResizeObserver(_el, update))\n }\n }\n }\n}\n\nwatch(\n () => props.tabs,\n async () => {\n await nextTick()\n update()\n\n observerTabs()\n },\n { immediate: true }\n)\nconst barObserever = useResizeObserver(barRef, () => update())\n\nonBeforeUnmount(() => {\n saveObserver.forEach((observer) => observer.stop())\n saveObserver.length = 0\n barObserever.stop()\n})\n\ndefineExpose({\n /** @description tab root html element */\n ref: barRef,\n /** @description method to manually update tab bar style */\n update,\n})\n</script>\n"],"names":[],"mappings":"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"}
|
|
@@ -2,7 +2,7 @@ import { defineComponent, inject, ref, computed, watch, onMounted, onUpdated, cr
|
|
|
2
2
|
import { useDocumentVisibility, useWindowFocus, useResizeObserver } from '@vueuse/core';
|
|
3
3
|
import { ElIcon } from '../../icon/index.mjs';
|
|
4
4
|
import { ArrowLeft, ArrowRight, Close } from '@element-plus/icons-vue';
|
|
5
|
-
import TabBar from './tab-
|
|
5
|
+
import TabBar from './tab-bar2.mjs';
|
|
6
6
|
import { tabsRootContextKey } from './constants.mjs';
|
|
7
7
|
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
8
8
|
import { mutable } from '../../../utils/typescript.mjs';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import Tooltip from './src/tooltip2.mjs';
|
|
2
2
|
export { tooltipEmits, useTooltipModelToggle, useTooltipModelToggleEmits, useTooltipModelToggleProps, useTooltipProps } from './src/tooltip.mjs';
|
|
3
3
|
export { useTooltipTriggerProps } from './src/trigger.mjs';
|
|
4
|
-
export { useTooltipContentProps } from './src/
|
|
4
|
+
export { useTooltipContentProps } from './src/content.mjs';
|
|
5
5
|
export { TOOLTIP_INJECTION_KEY } from './src/constants.mjs';
|
|
6
6
|
import { withInstall } from '../../utils/vue/install.mjs';
|
|
7
7
|
|
|
@@ -1,196 +1,32 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import '
|
|
4
|
-
import {
|
|
5
|
-
import { TOOLTIP_INJECTION_KEY } from './constants.mjs';
|
|
6
|
-
import { useTooltipContentProps } from './content2.mjs';
|
|
7
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
8
|
-
import { usePopperContainerId } from '../../../hooks/use-popper-container/index.mjs';
|
|
9
|
-
import ElPopperContent from '../../popper/src/content2.mjs';
|
|
10
|
-
import { tryFocus } from '../../focus-trap/src/utils.mjs';
|
|
11
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
12
|
-
import { composeEventHandlers } from '../../../utils/dom/event.mjs';
|
|
1
|
+
import { useDelayedToggleProps } from '../../../hooks/use-delayed-toggle/index.mjs';
|
|
2
|
+
import { popperContentProps } from '../../popper/src/content.mjs';
|
|
3
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
4
|
+
import { useAriaProps } from '../../../hooks/use-aria/index.mjs';
|
|
13
5
|
|
|
14
|
-
const
|
|
15
|
-
|
|
16
|
-
|
|
6
|
+
const useTooltipContentProps = buildProps({
|
|
7
|
+
...useDelayedToggleProps,
|
|
8
|
+
...popperContentProps,
|
|
9
|
+
appendTo: {
|
|
10
|
+
type: definePropType([String, Object])
|
|
11
|
+
},
|
|
12
|
+
content: {
|
|
13
|
+
type: String,
|
|
14
|
+
default: ""
|
|
15
|
+
},
|
|
16
|
+
rawContent: Boolean,
|
|
17
|
+
persistent: Boolean,
|
|
18
|
+
visible: {
|
|
19
|
+
type: definePropType(Boolean),
|
|
20
|
+
default: null
|
|
21
|
+
},
|
|
22
|
+
transition: String,
|
|
23
|
+
teleported: {
|
|
24
|
+
type: Boolean,
|
|
25
|
+
default: true
|
|
26
|
+
},
|
|
27
|
+
disabled: Boolean,
|
|
28
|
+
...useAriaProps(["ariaLabel"])
|
|
17
29
|
});
|
|
18
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
19
|
-
...__default__,
|
|
20
|
-
props: useTooltipContentProps,
|
|
21
|
-
setup(__props, { expose }) {
|
|
22
|
-
const props = __props;
|
|
23
|
-
const { selector } = usePopperContainerId();
|
|
24
|
-
const ns = useNamespace("tooltip");
|
|
25
|
-
const contentRef = ref();
|
|
26
|
-
let stopHandle;
|
|
27
|
-
const {
|
|
28
|
-
controlled,
|
|
29
|
-
id,
|
|
30
|
-
open,
|
|
31
|
-
trigger,
|
|
32
|
-
onClose,
|
|
33
|
-
onOpen,
|
|
34
|
-
onShow,
|
|
35
|
-
onHide,
|
|
36
|
-
onBeforeShow,
|
|
37
|
-
onBeforeHide
|
|
38
|
-
} = inject(TOOLTIP_INJECTION_KEY, void 0);
|
|
39
|
-
const transitionClass = computed(() => {
|
|
40
|
-
return props.transition || `${ns.namespace.value}-fade-in-linear`;
|
|
41
|
-
});
|
|
42
|
-
const persistentRef = computed(() => {
|
|
43
|
-
if (process.env.NODE_ENV === "test") {
|
|
44
|
-
return true;
|
|
45
|
-
}
|
|
46
|
-
return props.persistent;
|
|
47
|
-
});
|
|
48
|
-
onBeforeUnmount(() => {
|
|
49
|
-
stopHandle == null ? void 0 : stopHandle();
|
|
50
|
-
});
|
|
51
|
-
const shouldRender = computed(() => {
|
|
52
|
-
return unref(persistentRef) ? true : unref(open);
|
|
53
|
-
});
|
|
54
|
-
const shouldShow = computed(() => {
|
|
55
|
-
return props.disabled ? false : unref(open);
|
|
56
|
-
});
|
|
57
|
-
const appendTo = computed(() => {
|
|
58
|
-
return props.appendTo || selector.value;
|
|
59
|
-
});
|
|
60
|
-
const contentStyle = computed(() => {
|
|
61
|
-
var _a;
|
|
62
|
-
return (_a = props.style) != null ? _a : {};
|
|
63
|
-
});
|
|
64
|
-
const ariaHidden = ref(true);
|
|
65
|
-
const onTransitionLeave = () => {
|
|
66
|
-
onHide();
|
|
67
|
-
isFocusInsideContent() && tryFocus(document.body);
|
|
68
|
-
ariaHidden.value = true;
|
|
69
|
-
};
|
|
70
|
-
const stopWhenControlled = () => {
|
|
71
|
-
if (unref(controlled))
|
|
72
|
-
return true;
|
|
73
|
-
};
|
|
74
|
-
const onContentEnter = composeEventHandlers(stopWhenControlled, () => {
|
|
75
|
-
if (props.enterable && unref(trigger) === "hover") {
|
|
76
|
-
onOpen();
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
const onContentLeave = composeEventHandlers(stopWhenControlled, () => {
|
|
80
|
-
if (unref(trigger) === "hover") {
|
|
81
|
-
onClose();
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
const onBeforeEnter = () => {
|
|
85
|
-
var _a, _b;
|
|
86
|
-
(_b = (_a = contentRef.value) == null ? void 0 : _a.updatePopper) == null ? void 0 : _b.call(_a);
|
|
87
|
-
onBeforeShow == null ? void 0 : onBeforeShow();
|
|
88
|
-
};
|
|
89
|
-
const onBeforeLeave = () => {
|
|
90
|
-
onBeforeHide == null ? void 0 : onBeforeHide();
|
|
91
|
-
};
|
|
92
|
-
const onAfterShow = () => {
|
|
93
|
-
onShow();
|
|
94
|
-
stopHandle = onClickOutside(computed(() => {
|
|
95
|
-
var _a;
|
|
96
|
-
return (_a = contentRef.value) == null ? void 0 : _a.popperContentRef;
|
|
97
|
-
}), () => {
|
|
98
|
-
if (unref(controlled))
|
|
99
|
-
return;
|
|
100
|
-
const $trigger = unref(trigger);
|
|
101
|
-
if ($trigger !== "hover") {
|
|
102
|
-
onClose();
|
|
103
|
-
}
|
|
104
|
-
});
|
|
105
|
-
};
|
|
106
|
-
const onBlur = () => {
|
|
107
|
-
if (!props.virtualTriggering) {
|
|
108
|
-
onClose();
|
|
109
|
-
}
|
|
110
|
-
};
|
|
111
|
-
const isFocusInsideContent = (event) => {
|
|
112
|
-
var _a;
|
|
113
|
-
const popperContent = (_a = contentRef.value) == null ? void 0 : _a.popperContentRef;
|
|
114
|
-
const activeElement = (event == null ? void 0 : event.relatedTarget) || document.activeElement;
|
|
115
|
-
return popperContent == null ? void 0 : popperContent.contains(activeElement);
|
|
116
|
-
};
|
|
117
|
-
watch(() => unref(open), (val) => {
|
|
118
|
-
if (!val) {
|
|
119
|
-
stopHandle == null ? void 0 : stopHandle();
|
|
120
|
-
} else {
|
|
121
|
-
ariaHidden.value = false;
|
|
122
|
-
}
|
|
123
|
-
}, {
|
|
124
|
-
flush: "post"
|
|
125
|
-
});
|
|
126
|
-
watch(() => props.content, () => {
|
|
127
|
-
var _a, _b;
|
|
128
|
-
(_b = (_a = contentRef.value) == null ? void 0 : _a.updatePopper) == null ? void 0 : _b.call(_a);
|
|
129
|
-
});
|
|
130
|
-
expose({
|
|
131
|
-
contentRef,
|
|
132
|
-
isFocusInsideContent
|
|
133
|
-
});
|
|
134
|
-
return (_ctx, _cache) => {
|
|
135
|
-
return openBlock(), createBlock(unref(ElTeleport), {
|
|
136
|
-
disabled: !_ctx.teleported,
|
|
137
|
-
to: unref(appendTo)
|
|
138
|
-
}, {
|
|
139
|
-
default: withCtx(() => [
|
|
140
|
-
createVNode(Transition, {
|
|
141
|
-
name: unref(transitionClass),
|
|
142
|
-
onAfterLeave: onTransitionLeave,
|
|
143
|
-
onBeforeEnter,
|
|
144
|
-
onAfterEnter: onAfterShow,
|
|
145
|
-
onBeforeLeave
|
|
146
|
-
}, {
|
|
147
|
-
default: withCtx(() => [
|
|
148
|
-
unref(shouldRender) ? withDirectives((openBlock(), createBlock(unref(ElPopperContent), mergeProps({
|
|
149
|
-
key: 0,
|
|
150
|
-
id: unref(id),
|
|
151
|
-
ref_key: "contentRef",
|
|
152
|
-
ref: contentRef
|
|
153
|
-
}, _ctx.$attrs, {
|
|
154
|
-
"aria-label": _ctx.ariaLabel,
|
|
155
|
-
"aria-hidden": ariaHidden.value,
|
|
156
|
-
"boundaries-padding": _ctx.boundariesPadding,
|
|
157
|
-
"fallback-placements": _ctx.fallbackPlacements,
|
|
158
|
-
"gpu-acceleration": _ctx.gpuAcceleration,
|
|
159
|
-
offset: _ctx.offset,
|
|
160
|
-
placement: _ctx.placement,
|
|
161
|
-
"popper-options": _ctx.popperOptions,
|
|
162
|
-
strategy: _ctx.strategy,
|
|
163
|
-
effect: _ctx.effect,
|
|
164
|
-
enterable: _ctx.enterable,
|
|
165
|
-
pure: _ctx.pure,
|
|
166
|
-
"popper-class": _ctx.popperClass,
|
|
167
|
-
"popper-style": [_ctx.popperStyle, unref(contentStyle)],
|
|
168
|
-
"reference-el": _ctx.referenceEl,
|
|
169
|
-
"trigger-target-el": _ctx.triggerTargetEl,
|
|
170
|
-
visible: unref(shouldShow),
|
|
171
|
-
"z-index": _ctx.zIndex,
|
|
172
|
-
onMouseenter: unref(onContentEnter),
|
|
173
|
-
onMouseleave: unref(onContentLeave),
|
|
174
|
-
onBlur,
|
|
175
|
-
onClose: unref(onClose)
|
|
176
|
-
}), {
|
|
177
|
-
default: withCtx(() => [
|
|
178
|
-
renderSlot(_ctx.$slots, "default")
|
|
179
|
-
]),
|
|
180
|
-
_: 3
|
|
181
|
-
}, 16, ["id", "aria-label", "aria-hidden", "boundaries-padding", "fallback-placements", "gpu-acceleration", "offset", "placement", "popper-options", "strategy", "effect", "enterable", "pure", "popper-class", "popper-style", "reference-el", "trigger-target-el", "visible", "z-index", "onMouseenter", "onMouseleave", "onClose"])), [
|
|
182
|
-
[vShow, unref(shouldShow)]
|
|
183
|
-
]) : createCommentVNode("v-if", true)
|
|
184
|
-
]),
|
|
185
|
-
_: 3
|
|
186
|
-
}, 8, ["name"])
|
|
187
|
-
]),
|
|
188
|
-
_: 3
|
|
189
|
-
}, 8, ["disabled", "to"]);
|
|
190
|
-
};
|
|
191
|
-
}
|
|
192
|
-
});
|
|
193
|
-
var ElTooltipContent = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "content.vue"]]);
|
|
194
30
|
|
|
195
|
-
export {
|
|
31
|
+
export { useTooltipContentProps };
|
|
196
32
|
//# sourceMappingURL=content.mjs.map
|