@element-plus/nightly 0.0.20250107 → 0.0.20250108
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.full.js +2 -2
- package/dist/index.full.min.js +2 -2
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +2 -2
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +2 -2
- 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/pa.js +1 -1
- package/dist/locale/pa.min.js +1 -1
- package/dist/locale/pa.min.mjs +1 -1
- package/dist/locale/pa.mjs +1 -1
- package/dist/locale/pl.js +1 -1
- package/dist/locale/pl.min.js +1 -1
- package/dist/locale/pl.min.mjs +1 -1
- package/dist/locale/pl.mjs +1 -1
- package/dist/locale/pt-br.js +1 -1
- package/dist/locale/pt-br.min.js +1 -1
- package/dist/locale/pt-br.min.mjs +1 -1
- package/dist/locale/pt-br.mjs +1 -1
- package/dist/locale/pt.js +1 -1
- package/dist/locale/pt.min.js +1 -1
- package/dist/locale/pt.min.mjs +1 -1
- package/dist/locale/pt.mjs +1 -1
- package/dist/locale/ro.js +1 -1
- package/dist/locale/ro.min.js +1 -1
- package/dist/locale/ro.min.mjs +1 -1
- package/dist/locale/ro.mjs +1 -1
- package/dist/locale/ru.js +1 -1
- package/dist/locale/ru.min.js +1 -1
- package/dist/locale/ru.min.mjs +1 -1
- package/dist/locale/ru.mjs +1 -1
- package/dist/locale/sk.js +1 -1
- package/dist/locale/sk.min.js +1 -1
- package/dist/locale/sk.min.mjs +1 -1
- package/dist/locale/sk.mjs +1 -1
- package/dist/locale/sl.js +1 -1
- package/dist/locale/sl.min.js +1 -1
- package/dist/locale/sl.min.mjs +1 -1
- package/dist/locale/sl.mjs +1 -1
- package/dist/locale/sr.js +1 -1
- package/dist/locale/sr.min.js +1 -1
- package/dist/locale/sr.min.mjs +1 -1
- package/dist/locale/sr.mjs +1 -1
- package/dist/locale/sv.js +1 -1
- package/dist/locale/sv.min.js +1 -1
- package/dist/locale/sv.min.mjs +1 -1
- package/dist/locale/sv.mjs +1 -1
- package/dist/locale/sw.js +1 -1
- package/dist/locale/sw.min.js +1 -1
- package/dist/locale/sw.min.mjs +1 -1
- package/dist/locale/sw.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/th.js +1 -1
- package/dist/locale/th.min.js +1 -1
- package/dist/locale/th.min.mjs +1 -1
- package/dist/locale/th.mjs +1 -1
- package/dist/locale/tk.js +1 -1
- package/dist/locale/tk.min.js +1 -1
- package/dist/locale/tk.min.mjs +1 -1
- package/dist/locale/tk.mjs +1 -1
- package/dist/locale/tr.js +1 -1
- package/dist/locale/tr.min.js +1 -1
- package/dist/locale/tr.min.mjs +1 -1
- package/dist/locale/tr.mjs +1 -1
- package/dist/locale/ug-cn.js +1 -1
- package/dist/locale/ug-cn.min.js +1 -1
- package/dist/locale/ug-cn.min.mjs +1 -1
- package/dist/locale/ug-cn.mjs +1 -1
- package/dist/locale/uk.js +1 -1
- package/dist/locale/uk.min.js +1 -1
- package/dist/locale/uk.min.mjs +1 -1
- package/dist/locale/uk.mjs +1 -1
- package/dist/locale/uz-uz.js +1 -1
- package/dist/locale/uz-uz.min.js +1 -1
- package/dist/locale/uz-uz.min.mjs +1 -1
- package/dist/locale/uz-uz.mjs +1 -1
- package/dist/locale/vi.js +1 -1
- package/dist/locale/vi.min.js +1 -1
- package/dist/locale/vi.min.mjs +1 -1
- package/dist/locale/vi.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/dist/locale/zh-tw.js +1 -1
- package/dist/locale/zh-tw.min.js +1 -1
- package/dist/locale/zh-tw.min.mjs +1 -1
- package/dist/locale/zh-tw.mjs +1 -1
- package/es/components/affix/index.mjs +2 -2
- package/es/components/affix/src/affix.mjs +25 -118
- package/es/components/affix/src/affix.mjs.map +1 -1
- package/es/components/affix/src/affix2.mjs +118 -25
- package/es/components/affix/src/affix2.mjs.map +1 -1
- package/es/components/backtop/index.mjs +2 -2
- package/es/components/backtop/src/backtop.mjs +21 -53
- package/es/components/backtop/src/backtop.mjs.map +1 -1
- package/es/components/backtop/src/backtop2.mjs +53 -21
- package/es/components/backtop/src/backtop2.mjs.map +1 -1
- package/es/components/breadcrumb/index.mjs +2 -2
- package/es/components/breadcrumb/src/breadcrumb.mjs +10 -37
- package/es/components/breadcrumb/src/breadcrumb.mjs.map +1 -1
- package/es/components/breadcrumb/src/breadcrumb2.mjs +37 -10
- package/es/components/breadcrumb/src/breadcrumb2.mjs.map +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/collapse/index.mjs +2 -2
- package/es/components/collapse/src/collapse.mjs +28 -16
- package/es/components/collapse/src/collapse.mjs.map +1 -1
- package/es/components/collapse/src/collapse2.mjs +16 -28
- package/es/components/collapse/src/collapse2.mjs.map +1 -1
- package/es/components/collection/index.mjs +1 -1
- package/es/components/collection/src/collection.mjs +10 -62
- package/es/components/collection/src/collection.mjs.map +1 -1
- package/es/components/collection/src/collection2.mjs +62 -10
- package/es/components/collection/src/collection2.mjs.map +1 -1
- package/es/components/dropdown/src/dropdown-item-impl.mjs +1 -1
- package/es/components/dropdown/src/dropdown.mjs +1 -1
- package/es/components/form/index.mjs +4 -4
- package/es/components/form/src/form-item.mjs +47 -319
- package/es/components/form/src/form-item.mjs.map +1 -1
- package/es/components/form/src/form-item2.mjs +319 -47
- package/es/components/form/src/form-item2.mjs.map +1 -1
- package/es/components/form/src/form.mjs +53 -153
- package/es/components/form/src/form.mjs.map +1 -1
- package/es/components/form/src/form2.mjs +153 -53
- package/es/components/form/src/form2.mjs.map +1 -1
- package/es/components/index.mjs +15 -15
- package/es/components/notification/index.mjs +1 -1
- package/es/components/notification/src/notification.mjs +68 -142
- package/es/components/notification/src/notification.mjs.map +1 -1
- package/es/components/notification/src/notification2.mjs +142 -68
- package/es/components/notification/src/notification2.mjs.map +1 -1
- package/es/components/notification/src/notify.mjs +2 -2
- 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 +1 -1
- package/es/components/radio/index.mjs +2 -2
- package/es/components/radio/src/radio-group.mjs +65 -34
- package/es/components/radio/src/radio-group.mjs.map +1 -1
- package/es/components/radio/src/radio-group2.mjs +34 -65
- package/es/components/radio/src/radio-group2.mjs.map +1 -1
- package/es/components/roving-focus-group/src/roving-focus-group.mjs +1 -1
- package/es/components/scrollbar/index.mjs +2 -2
- package/es/components/scrollbar/src/scrollbar.mjs +170 -55
- package/es/components/scrollbar/src/scrollbar.mjs.map +1 -1
- package/es/components/scrollbar/src/scrollbar2.mjs +55 -170
- package/es/components/scrollbar/src/scrollbar2.mjs.map +1 -1
- package/es/components/skeleton/index.mjs +2 -2
- package/es/components/skeleton/src/skeleton-item.mjs +22 -17
- package/es/components/skeleton/src/skeleton-item.mjs.map +1 -1
- package/es/components/skeleton/src/skeleton-item2.mjs +17 -22
- package/es/components/skeleton/src/skeleton-item2.mjs.map +1 -1
- package/es/components/skeleton/src/skeleton.mjs +1 -1
- package/es/components/slider/index.mjs +2 -2
- package/es/components/slider/src/slider.mjs +88 -238
- package/es/components/slider/src/slider.mjs.map +1 -1
- package/es/components/slider/src/slider2.mjs +238 -88
- package/es/components/slider/src/slider2.mjs.map +1 -1
- package/es/components/statistic/index.mjs +2 -2
- package/es/components/statistic/src/statistic.mjs +69 -25
- package/es/components/statistic/src/statistic.mjs.map +1 -1
- package/es/components/statistic/src/statistic2.mjs +25 -69
- package/es/components/statistic/src/statistic2.mjs.map +1 -1
- package/es/components/tabs/index.mjs +1 -1
- package/es/components/tabs/src/tab-bar.mjs +95 -7
- package/es/components/tabs/src/tab-bar.mjs.map +1 -1
- package/es/components/tabs/src/tab-bar2.mjs +7 -95
- 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-v2/index.mjs +3 -3
- package/es/components/tooltip-v2/src/tooltip.mjs +19 -77
- package/es/components/tooltip-v2/src/tooltip.mjs.map +1 -1
- package/es/components/tooltip-v2/src/tooltip2.mjs +77 -19
- package/es/components/tooltip-v2/src/tooltip2.mjs.map +1 -1
- package/es/components/tooltip-v2/src/trigger.mjs +89 -12
- package/es/components/tooltip-v2/src/trigger.mjs.map +1 -1
- package/es/components/tooltip-v2/src/trigger2.mjs +12 -89
- package/es/components/tooltip-v2/src/trigger2.mjs.map +1 -1
- package/es/components/transfer/src/composables/use-check.mjs +1 -1
- package/es/components/transfer/src/transfer-panel.mjs +19 -130
- package/es/components/transfer/src/transfer-panel.mjs.map +1 -1
- package/es/components/transfer/src/transfer-panel2.mjs +130 -19
- package/es/components/transfer/src/transfer-panel2.mjs.map +1 -1
- package/es/components/transfer/src/transfer2.mjs +1 -1
- package/es/components/watermark/index.mjs +2 -2
- package/es/components/watermark/src/watermark.mjs +210 -27
- package/es/components/watermark/src/watermark.mjs.map +1 -1
- package/es/components/watermark/src/watermark2.mjs +27 -210
- package/es/components/watermark/src/watermark2.mjs.map +1 -1
- package/es/index.mjs +15 -15
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/affix/index.js +2 -2
- package/lib/components/affix/src/affix.js +26 -118
- package/lib/components/affix/src/affix.js.map +1 -1
- package/lib/components/affix/src/affix2.js +118 -26
- package/lib/components/affix/src/affix2.js.map +1 -1
- package/lib/components/backtop/index.js +2 -2
- package/lib/components/backtop/src/backtop.js +22 -53
- package/lib/components/backtop/src/backtop.js.map +1 -1
- package/lib/components/backtop/src/backtop2.js +53 -22
- package/lib/components/backtop/src/backtop2.js.map +1 -1
- package/lib/components/breadcrumb/index.js +2 -2
- package/lib/components/breadcrumb/src/breadcrumb.js +10 -37
- package/lib/components/breadcrumb/src/breadcrumb.js.map +1 -1
- package/lib/components/breadcrumb/src/breadcrumb2.js +37 -10
- package/lib/components/breadcrumb/src/breadcrumb2.js.map +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/collapse/index.js +2 -2
- package/lib/components/collapse/src/collapse.js +28 -18
- package/lib/components/collapse/src/collapse.js.map +1 -1
- package/lib/components/collapse/src/collapse2.js +18 -28
- package/lib/components/collapse/src/collapse2.js.map +1 -1
- package/lib/components/collection/index.js +1 -1
- package/lib/components/collection/src/collection.js +9 -62
- package/lib/components/collection/src/collection.js.map +1 -1
- package/lib/components/collection/src/collection2.js +62 -9
- package/lib/components/collection/src/collection2.js.map +1 -1
- package/lib/components/dropdown/src/dropdown-item-impl.js +1 -1
- package/lib/components/dropdown/src/dropdown.js +1 -1
- package/lib/components/form/index.js +4 -4
- package/lib/components/form/src/form-item.js +48 -323
- package/lib/components/form/src/form-item.js.map +1 -1
- package/lib/components/form/src/form-item2.js +323 -48
- package/lib/components/form/src/form-item2.js.map +1 -1
- package/lib/components/form/src/form.js +54 -152
- package/lib/components/form/src/form.js.map +1 -1
- package/lib/components/form/src/form2.js +152 -54
- package/lib/components/form/src/form2.js.map +1 -1
- package/lib/components/index.js +15 -15
- package/lib/components/notification/index.js +1 -1
- package/lib/components/notification/src/notification.js +69 -141
- package/lib/components/notification/src/notification.js.map +1 -1
- package/lib/components/notification/src/notification2.js +141 -69
- package/lib/components/notification/src/notification2.js.map +1 -1
- package/lib/components/notification/src/notify.js +2 -2
- 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 +1 -1
- package/lib/components/radio/index.js +2 -2
- package/lib/components/radio/src/radio-group.js +65 -35
- package/lib/components/radio/src/radio-group.js.map +1 -1
- package/lib/components/radio/src/radio-group2.js +35 -65
- package/lib/components/radio/src/radio-group2.js.map +1 -1
- package/lib/components/roving-focus-group/src/roving-focus-group.js +1 -1
- package/lib/components/scrollbar/index.js +2 -2
- package/lib/components/scrollbar/src/scrollbar.js +170 -56
- package/lib/components/scrollbar/src/scrollbar.js.map +1 -1
- package/lib/components/scrollbar/src/scrollbar2.js +56 -170
- package/lib/components/scrollbar/src/scrollbar2.js.map +1 -1
- package/lib/components/skeleton/index.js +2 -2
- package/lib/components/skeleton/src/skeleton-item.js +22 -17
- package/lib/components/skeleton/src/skeleton-item.js.map +1 -1
- package/lib/components/skeleton/src/skeleton-item2.js +17 -22
- package/lib/components/skeleton/src/skeleton-item2.js.map +1 -1
- package/lib/components/skeleton/src/skeleton.js +1 -1
- package/lib/components/slider/index.js +2 -2
- package/lib/components/slider/src/slider.js +89 -238
- package/lib/components/slider/src/slider.js.map +1 -1
- package/lib/components/slider/src/slider2.js +238 -89
- package/lib/components/slider/src/slider2.js.map +1 -1
- package/lib/components/statistic/index.js +2 -2
- package/lib/components/statistic/src/statistic.js +69 -25
- package/lib/components/statistic/src/statistic.js.map +1 -1
- package/lib/components/statistic/src/statistic2.js +25 -69
- package/lib/components/statistic/src/statistic2.js.map +1 -1
- package/lib/components/tabs/index.js +1 -1
- package/lib/components/tabs/src/tab-bar.js +95 -7
- package/lib/components/tabs/src/tab-bar.js.map +1 -1
- package/lib/components/tabs/src/tab-bar2.js +7 -95
- 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-v2/index.js +3 -3
- package/lib/components/tooltip-v2/src/tooltip.js +19 -77
- package/lib/components/tooltip-v2/src/tooltip.js.map +1 -1
- package/lib/components/tooltip-v2/src/tooltip2.js +77 -19
- package/lib/components/tooltip-v2/src/tooltip2.js.map +1 -1
- package/lib/components/tooltip-v2/src/trigger.js +89 -12
- package/lib/components/tooltip-v2/src/trigger.js.map +1 -1
- package/lib/components/tooltip-v2/src/trigger2.js +12 -89
- package/lib/components/tooltip-v2/src/trigger2.js.map +1 -1
- package/lib/components/transfer/src/composables/use-check.js +1 -1
- package/lib/components/transfer/src/transfer-panel.js +21 -130
- package/lib/components/transfer/src/transfer-panel.js.map +1 -1
- package/lib/components/transfer/src/transfer-panel2.js +130 -21
- package/lib/components/transfer/src/transfer-panel2.js.map +1 -1
- package/lib/components/transfer/src/transfer2.js +1 -1
- package/lib/components/watermark/index.js +2 -2
- package/lib/components/watermark/src/watermark.js +210 -27
- package/lib/components/watermark/src/watermark.js.map +1 -1
- package/lib/components/watermark/src/watermark2.js +27 -210
- package/lib/components/watermark/src/watermark2.js.map +1 -1
- package/lib/index.js +15 -15
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +1 -1
- package/web-types.json +1 -1
@@ -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-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';
|
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-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.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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"}
|
@@ -1,100 +1,12 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
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';
|
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-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.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;;;;"}
|
@@ -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-bar.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,9 +1,9 @@
|
|
1
|
-
import TooltipV2 from './src/
|
1
|
+
import TooltipV2 from './src/tooltip2.mjs';
|
2
2
|
export { tooltipV2ArrowProps, tooltipV2ArrowSpecialProps } from './src/arrow.mjs';
|
3
3
|
export { tooltipV2ContentProps } from './src/content.mjs';
|
4
4
|
export { tooltipV2RootProps } from './src/root.mjs';
|
5
|
-
export { tooltipV2Props } from './src/
|
6
|
-
export { tooltipV2TriggerProps } from './src/
|
5
|
+
export { tooltipV2Props } from './src/tooltip.mjs';
|
6
|
+
export { tooltipV2TriggerProps } from './src/trigger2.mjs';
|
7
7
|
export { TOOLTIP_V2_OPEN, tooltipV2ContentKey, tooltipV2RootKey } from './src/constants.mjs';
|
8
8
|
import { withInstall } from '../../utils/vue/install.mjs';
|
9
9
|
|
@@ -1,84 +1,26 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
3
|
-
import { ElTeleport } from '../../teleport/index.mjs';
|
1
|
+
import { tooltipV2RootProps } from './root.mjs';
|
2
|
+
import { tooltipV2TriggerProps } from './trigger2.mjs';
|
4
3
|
import { tooltipV2ArrowProps } from './arrow.mjs';
|
5
4
|
import { tooltipV2ContentProps } from './content.mjs';
|
6
|
-
import {
|
7
|
-
import { tooltipV2Props } from './tooltip2.mjs';
|
8
|
-
import { tooltipV2TriggerProps } from './trigger.mjs';
|
9
|
-
import TooltipV2Root from './root2.mjs';
|
10
|
-
import TooltipV2Arrow from './arrow2.mjs';
|
11
|
-
import TooltipV2Content from './content2.mjs';
|
12
|
-
import TooltipV2Trigger from './trigger2.mjs';
|
13
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
5
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
14
6
|
|
15
|
-
const
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
...
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
default: withCtx(({ open }) => [
|
31
|
-
createVNode(TooltipV2Trigger, mergeProps(triggerProps, { nowrap: "" }), {
|
32
|
-
default: withCtx(() => [
|
33
|
-
renderSlot(_ctx.$slots, "trigger")
|
34
|
-
]),
|
35
|
-
_: 3
|
36
|
-
}, 16),
|
37
|
-
createVNode(unref(ElTeleport), {
|
38
|
-
to: _ctx.to,
|
39
|
-
disabled: !_ctx.teleported
|
40
|
-
}, {
|
41
|
-
default: withCtx(() => [
|
42
|
-
_ctx.fullTransition ? (openBlock(), createBlock(Transition, normalizeProps(mergeProps({ key: 0 }, _ctx.transitionProps)), {
|
43
|
-
default: withCtx(() => [
|
44
|
-
_ctx.alwaysOn || open ? (openBlock(), createBlock(TooltipV2Content, normalizeProps(mergeProps({ key: 0 }, contentProps)), {
|
45
|
-
arrow: withCtx(({ style, side }) => [
|
46
|
-
_ctx.showArrow ? (openBlock(), createBlock(TooltipV2Arrow, mergeProps({ key: 0 }, arrowProps, {
|
47
|
-
style,
|
48
|
-
side
|
49
|
-
}), null, 16, ["style", "side"])) : createCommentVNode("v-if", true)
|
50
|
-
]),
|
51
|
-
default: withCtx(() => [
|
52
|
-
renderSlot(_ctx.$slots, "default")
|
53
|
-
]),
|
54
|
-
_: 3
|
55
|
-
}, 16)) : createCommentVNode("v-if", true)
|
56
|
-
]),
|
57
|
-
_: 2
|
58
|
-
}, 1040)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
59
|
-
_ctx.alwaysOn || open ? (openBlock(), createBlock(TooltipV2Content, normalizeProps(mergeProps({ key: 0 }, contentProps)), {
|
60
|
-
arrow: withCtx(({ style, side }) => [
|
61
|
-
_ctx.showArrow ? (openBlock(), createBlock(TooltipV2Arrow, mergeProps({ key: 0 }, arrowProps, {
|
62
|
-
style,
|
63
|
-
side
|
64
|
-
}), null, 16, ["style", "side"])) : createCommentVNode("v-if", true)
|
65
|
-
]),
|
66
|
-
default: withCtx(() => [
|
67
|
-
renderSlot(_ctx.$slots, "default")
|
68
|
-
]),
|
69
|
-
_: 3
|
70
|
-
}, 16)) : createCommentVNode("v-if", true)
|
71
|
-
], 64))
|
72
|
-
]),
|
73
|
-
_: 2
|
74
|
-
}, 1032, ["to", "disabled"])
|
75
|
-
]),
|
76
|
-
_: 3
|
77
|
-
}, 16);
|
78
|
-
};
|
7
|
+
const tooltipV2Props = buildProps({
|
8
|
+
...tooltipV2RootProps,
|
9
|
+
...tooltipV2ArrowProps,
|
10
|
+
...tooltipV2TriggerProps,
|
11
|
+
...tooltipV2ContentProps,
|
12
|
+
alwaysOn: Boolean,
|
13
|
+
fullTransition: Boolean,
|
14
|
+
transitionProps: {
|
15
|
+
type: definePropType(Object),
|
16
|
+
default: null
|
17
|
+
},
|
18
|
+
teleported: Boolean,
|
19
|
+
to: {
|
20
|
+
type: definePropType(String),
|
21
|
+
default: "body"
|
79
22
|
}
|
80
23
|
});
|
81
|
-
var TooltipV2 = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "tooltip.vue"]]);
|
82
24
|
|
83
|
-
export {
|
25
|
+
export { tooltipV2Props };
|
84
26
|
//# sourceMappingURL=tooltip.mjs.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"tooltip.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/tooltip.
|
1
|
+
{"version":3,"file":"tooltip.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/tooltip.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-plus/utils'\nimport { tooltipV2RootProps } from './root'\nimport { tooltipV2TriggerProps } from './trigger'\nimport { tooltipV2ArrowProps } from './arrow'\nimport { tooltipV2ContentProps } from './content'\n\nimport type { ExtractPropTypes, TeleportProps, TransitionProps } from 'vue'\n\nexport const tooltipV2Props = buildProps({\n ...tooltipV2RootProps,\n ...tooltipV2ArrowProps,\n ...tooltipV2TriggerProps,\n ...tooltipV2ContentProps,\n alwaysOn: Boolean,\n fullTransition: Boolean,\n transitionProps: {\n type: definePropType<TransitionProps | null>(Object),\n default: null,\n },\n teleported: Boolean,\n to: {\n type: definePropType<TeleportProps['to']>(String),\n default: 'body',\n },\n} as const)\n\nexport type TooltipV2Props = ExtractPropTypes<typeof tooltipV2Props>\n"],"names":[],"mappings":";;;;;;AAKY,MAAC,cAAc,GAAG,UAAU,CAAC;AACzC,EAAE,GAAG,kBAAkB;AACvB,EAAE,GAAG,mBAAmB;AACxB,EAAE,GAAG,qBAAqB;AAC1B,EAAE,GAAG,qBAAqB;AAC1B,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,cAAc,EAAE,OAAO;AACzB,EAAE,eAAe,EAAE;AACnB,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,UAAU,EAAE,OAAO;AACrB,EAAE,EAAE,EAAE;AACN,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,MAAM;AACnB,GAAG;AACH,CAAC;;;;"}
|
@@ -1,26 +1,84 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
1
|
+
import { defineComponent, toRefs, reactive, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx, createVNode, mergeProps, renderSlot, unref, Transition, createCommentVNode, createElementBlock, Fragment } from 'vue';
|
2
|
+
import { pick } from 'lodash-unified';
|
3
|
+
import { ElTeleport } from '../../teleport/index.mjs';
|
3
4
|
import { tooltipV2ArrowProps } from './arrow.mjs';
|
4
5
|
import { tooltipV2ContentProps } from './content.mjs';
|
5
|
-
import {
|
6
|
+
import { tooltipV2RootProps } from './root.mjs';
|
7
|
+
import { tooltipV2Props } from './tooltip.mjs';
|
8
|
+
import { tooltipV2TriggerProps } from './trigger2.mjs';
|
9
|
+
import TooltipV2Root from './root2.mjs';
|
10
|
+
import TooltipV2Arrow from './arrow2.mjs';
|
11
|
+
import TooltipV2Content from './content2.mjs';
|
12
|
+
import TooltipV2Trigger from './trigger.mjs';
|
13
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
6
14
|
|
7
|
-
const
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
...
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
15
|
+
const __default__ = defineComponent({
|
16
|
+
name: "ElTooltipV2"
|
17
|
+
});
|
18
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
19
|
+
...__default__,
|
20
|
+
props: tooltipV2Props,
|
21
|
+
setup(__props) {
|
22
|
+
const props = __props;
|
23
|
+
const refedProps = toRefs(props);
|
24
|
+
const arrowProps = reactive(pick(refedProps, Object.keys(tooltipV2ArrowProps)));
|
25
|
+
const contentProps = reactive(pick(refedProps, Object.keys(tooltipV2ContentProps)));
|
26
|
+
const rootProps = reactive(pick(refedProps, Object.keys(tooltipV2RootProps)));
|
27
|
+
const triggerProps = reactive(pick(refedProps, Object.keys(tooltipV2TriggerProps)));
|
28
|
+
return (_ctx, _cache) => {
|
29
|
+
return openBlock(), createBlock(TooltipV2Root, normalizeProps(guardReactiveProps(rootProps)), {
|
30
|
+
default: withCtx(({ open }) => [
|
31
|
+
createVNode(TooltipV2Trigger, mergeProps(triggerProps, { nowrap: "" }), {
|
32
|
+
default: withCtx(() => [
|
33
|
+
renderSlot(_ctx.$slots, "trigger")
|
34
|
+
]),
|
35
|
+
_: 3
|
36
|
+
}, 16),
|
37
|
+
createVNode(unref(ElTeleport), {
|
38
|
+
to: _ctx.to,
|
39
|
+
disabled: !_ctx.teleported
|
40
|
+
}, {
|
41
|
+
default: withCtx(() => [
|
42
|
+
_ctx.fullTransition ? (openBlock(), createBlock(Transition, normalizeProps(mergeProps({ key: 0 }, _ctx.transitionProps)), {
|
43
|
+
default: withCtx(() => [
|
44
|
+
_ctx.alwaysOn || open ? (openBlock(), createBlock(TooltipV2Content, normalizeProps(mergeProps({ key: 0 }, contentProps)), {
|
45
|
+
arrow: withCtx(({ style, side }) => [
|
46
|
+
_ctx.showArrow ? (openBlock(), createBlock(TooltipV2Arrow, mergeProps({ key: 0 }, arrowProps, {
|
47
|
+
style,
|
48
|
+
side
|
49
|
+
}), null, 16, ["style", "side"])) : createCommentVNode("v-if", true)
|
50
|
+
]),
|
51
|
+
default: withCtx(() => [
|
52
|
+
renderSlot(_ctx.$slots, "default")
|
53
|
+
]),
|
54
|
+
_: 3
|
55
|
+
}, 16)) : createCommentVNode("v-if", true)
|
56
|
+
]),
|
57
|
+
_: 2
|
58
|
+
}, 1040)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
59
|
+
_ctx.alwaysOn || open ? (openBlock(), createBlock(TooltipV2Content, normalizeProps(mergeProps({ key: 0 }, contentProps)), {
|
60
|
+
arrow: withCtx(({ style, side }) => [
|
61
|
+
_ctx.showArrow ? (openBlock(), createBlock(TooltipV2Arrow, mergeProps({ key: 0 }, arrowProps, {
|
62
|
+
style,
|
63
|
+
side
|
64
|
+
}), null, 16, ["style", "side"])) : createCommentVNode("v-if", true)
|
65
|
+
]),
|
66
|
+
default: withCtx(() => [
|
67
|
+
renderSlot(_ctx.$slots, "default")
|
68
|
+
]),
|
69
|
+
_: 3
|
70
|
+
}, 16)) : createCommentVNode("v-if", true)
|
71
|
+
], 64))
|
72
|
+
]),
|
73
|
+
_: 2
|
74
|
+
}, 1032, ["to", "disabled"])
|
75
|
+
]),
|
76
|
+
_: 3
|
77
|
+
}, 16);
|
78
|
+
};
|
22
79
|
}
|
23
80
|
});
|
81
|
+
var TooltipV2 = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "tooltip.vue"]]);
|
24
82
|
|
25
|
-
export {
|
83
|
+
export { TooltipV2 as default };
|
26
84
|
//# sourceMappingURL=tooltip2.mjs.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"tooltip2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/tooltip.
|
1
|
+
{"version":3,"file":"tooltip2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/tooltip.vue"],"sourcesContent":["<template>\n <tooltip-v2-root v-bind=\"rootProps\">\n <template #default=\"{ open }\">\n <tooltip-v2-trigger v-bind=\"triggerProps\" nowrap>\n <slot name=\"trigger\" />\n </tooltip-v2-trigger>\n <el-teleport :to=\"to\" :disabled=\"!teleported\">\n <template v-if=\"fullTransition\">\n <transition v-bind=\"transitionProps\">\n <tooltip-v2-content v-if=\"alwaysOn || open\" v-bind=\"contentProps\">\n <slot />\n <template #arrow=\"{ style, side }\">\n <tooltip-v2-arrow\n v-if=\"showArrow\"\n v-bind=\"arrowProps\"\n :style=\"style\"\n :side=\"side\"\n />\n </template>\n </tooltip-v2-content>\n </transition>\n </template>\n <template v-else>\n <tooltip-v2-content v-if=\"alwaysOn || open\" v-bind=\"contentProps\">\n <slot />\n <template #arrow=\"{ style, side }\">\n <tooltip-v2-arrow\n v-if=\"showArrow\"\n v-bind=\"arrowProps\"\n :style=\"style\"\n :side=\"side\"\n />\n </template>\n </tooltip-v2-content>\n </template>\n </el-teleport>\n </template>\n </tooltip-v2-root>\n</template>\n\n<script setup lang=\"ts\">\n// @ts-nocheck\nimport { reactive, toRefs } from 'vue'\nimport { pick } from 'lodash-unified'\nimport ElTeleport from '@element-plus/components/teleport'\nimport { tooltipV2ArrowProps } from './arrow'\nimport { tooltipV2ContentProps } from './content'\nimport { tooltipV2RootProps } from './root'\nimport { tooltipV2Props } from './tooltip'\nimport { tooltipV2TriggerProps } from './trigger'\nimport TooltipV2Root from './root.vue'\nimport TooltipV2Arrow from './arrow.vue'\nimport TooltipV2Content from './content.vue'\nimport TooltipV2Trigger from './trigger.vue'\n\ndefineOptions({\n name: 'ElTooltipV2',\n})\n\nconst props = defineProps(tooltipV2Props)\n\nconst refedProps = toRefs(props)\n\nconst arrowProps = reactive(pick(refedProps, Object.keys(tooltipV2ArrowProps)))\n\nconst contentProps = reactive(\n pick(refedProps, Object.keys(tooltipV2ContentProps))\n)\n\nconst rootProps = reactive(pick(refedProps, Object.keys(tooltipV2RootProps)))\n\nconst triggerProps = reactive(\n pick(refedProps, Object.keys(tooltipV2TriggerProps))\n)\n</script>\n"],"names":["_openBlock","_createBlock","_normalizeProps","_guardReactiveProps","_withCtx","_createVNode","_mergeProps"],"mappings":";;;;;;;;;;;;;;mCAuDc,CAAA;AAAA,EACZ,IAAM,EAAA,aAAA;AACR,CAAA,CAAA,CAAA;;;;;;AAIA,IAAM,MAAA,UAAA,GAAa,OAAO,KAAK,CAAA,CAAA;AAE/B,IAAM,MAAA,UAAA,GAAa,SAAS,IAAK,CAAA,UAAA,EAAY,OAAO,IAAK,CAAA,mBAAmB,CAAC,CAAC,CAAA,CAAA;AAE9E,IAAA,MAAM,YAAe,GAAA,QAAA,CAAA,IAAA,CAAA,UAAA,EAAA,MAAA,CAAA,IAAA,CAAA,qBAAA,CAAA,CAAA,CAAA,CAAA;AAAA,IAAA,MACd,SAAA,GAAA,QAAmB,CAAA,IAAK,wBAAsB,CAAA,kBAAA,CAAA,CAAA,CAAA,CAAA;AAAA,IACrD,MAAA,YAAA,GAAA,QAAA,CAAA,IAAA,CAAA,UAAA,EAAA,MAAA,CAAA,IAAA,CAAA,qBAAA,CAAA,CAAA,CAAA,CAAA;AAEA,IAAM,OAAA,CAAA,IAAA,EAAA;AAEN,MAAA,OAAqBA,SAAA,EAAA,EAAAC,WAAA,CAAA,aAAA,EAAAC,cAAA,CAAAC,kBAAA,CAAA,SAAA,CAAA,CAAA,EAAA;AAAA,QACd,OAAA,EAAAC,OAAmB,CAAA,CAAA,EAAA,IAAA,EAAK;AAAsB,UACrDC,WAAA,CAAA,gBAAA,EAAAC,UAAA,CAAA,YAAA,EAAA,EAAA,MAAA,EAAA,EAAA,EAAA,CAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
@@ -1,16 +1,93 @@
|
|
1
|
-
import {
|
1
|
+
import { defineComponent, inject, watch, onBeforeUnmount, openBlock, createBlock, unref, withCtx, renderSlot, createElementBlock, mergeProps } from 'vue';
|
2
|
+
import { tooltipV2RootKey } from './constants.mjs';
|
3
|
+
import ForwardRef from './forward-ref.mjs';
|
4
|
+
import { tooltipV2TriggerProps } from './trigger2.mjs';
|
5
|
+
import { tooltipV2CommonProps } from './common.mjs';
|
6
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
7
|
+
import { composeEventHandlers } from '../../../utils/dom/event.mjs';
|
2
8
|
|
3
|
-
const
|
4
|
-
|
5
|
-
};
|
6
|
-
const tooltipV2TriggerProps = buildProps({
|
7
|
-
onBlur: EventHandler,
|
8
|
-
onClick: EventHandler,
|
9
|
-
onFocus: EventHandler,
|
10
|
-
onMouseDown: EventHandler,
|
11
|
-
onMouseEnter: EventHandler,
|
12
|
-
onMouseLeave: EventHandler
|
9
|
+
const __default__ = defineComponent({
|
10
|
+
name: "ElTooltipV2Trigger"
|
13
11
|
});
|
12
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
13
|
+
...__default__,
|
14
|
+
props: {
|
15
|
+
...tooltipV2CommonProps,
|
16
|
+
...tooltipV2TriggerProps
|
17
|
+
},
|
18
|
+
setup(__props) {
|
19
|
+
const props = __props;
|
20
|
+
const { onClose, onOpen, onDelayOpen, triggerRef, contentId } = inject(tooltipV2RootKey);
|
21
|
+
let isMousedown = false;
|
22
|
+
const setTriggerRef = (el) => {
|
23
|
+
triggerRef.value = el;
|
24
|
+
};
|
25
|
+
const onMouseup = () => {
|
26
|
+
isMousedown = false;
|
27
|
+
};
|
28
|
+
const onMouseenter = composeEventHandlers(props.onMouseEnter, onDelayOpen);
|
29
|
+
const onMouseleave = composeEventHandlers(props.onMouseLeave, onClose);
|
30
|
+
const onMousedown = composeEventHandlers(props.onMouseDown, () => {
|
31
|
+
onClose();
|
32
|
+
isMousedown = true;
|
33
|
+
document.addEventListener("mouseup", onMouseup, { once: true });
|
34
|
+
});
|
35
|
+
const onFocus = composeEventHandlers(props.onFocus, () => {
|
36
|
+
if (!isMousedown)
|
37
|
+
onOpen();
|
38
|
+
});
|
39
|
+
const onBlur = composeEventHandlers(props.onBlur, onClose);
|
40
|
+
const onClick = composeEventHandlers(props.onClick, (e) => {
|
41
|
+
if (e.detail === 0)
|
42
|
+
onClose();
|
43
|
+
});
|
44
|
+
const events = {
|
45
|
+
blur: onBlur,
|
46
|
+
click: onClick,
|
47
|
+
focus: onFocus,
|
48
|
+
mousedown: onMousedown,
|
49
|
+
mouseenter: onMouseenter,
|
50
|
+
mouseleave: onMouseleave
|
51
|
+
};
|
52
|
+
const setEvents = (el, events2, type) => {
|
53
|
+
if (el) {
|
54
|
+
Object.entries(events2).forEach(([name, handler]) => {
|
55
|
+
el[type](name, handler);
|
56
|
+
});
|
57
|
+
}
|
58
|
+
};
|
59
|
+
watch(triggerRef, (triggerEl, previousTriggerEl) => {
|
60
|
+
setEvents(triggerEl, events, "addEventListener");
|
61
|
+
setEvents(previousTriggerEl, events, "removeEventListener");
|
62
|
+
if (triggerEl) {
|
63
|
+
triggerEl.setAttribute("aria-describedby", contentId.value);
|
64
|
+
}
|
65
|
+
});
|
66
|
+
onBeforeUnmount(() => {
|
67
|
+
setEvents(triggerRef.value, events, "removeEventListener");
|
68
|
+
document.removeEventListener("mouseup", onMouseup);
|
69
|
+
});
|
70
|
+
return (_ctx, _cache) => {
|
71
|
+
return _ctx.nowrap ? (openBlock(), createBlock(unref(ForwardRef), {
|
72
|
+
key: 0,
|
73
|
+
"set-ref": setTriggerRef,
|
74
|
+
"only-child": ""
|
75
|
+
}, {
|
76
|
+
default: withCtx(() => [
|
77
|
+
renderSlot(_ctx.$slots, "default")
|
78
|
+
]),
|
79
|
+
_: 3
|
80
|
+
})) : (openBlock(), createElementBlock("button", mergeProps({
|
81
|
+
key: 1,
|
82
|
+
ref_key: "triggerRef",
|
83
|
+
ref: triggerRef
|
84
|
+
}, _ctx.$attrs), [
|
85
|
+
renderSlot(_ctx.$slots, "default")
|
86
|
+
], 16));
|
87
|
+
};
|
88
|
+
}
|
89
|
+
});
|
90
|
+
var TooltipV2Trigger = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "trigger.vue"]]);
|
14
91
|
|
15
|
-
export {
|
92
|
+
export { TooltipV2Trigger as default };
|
16
93
|
//# sourceMappingURL=trigger.mjs.map
|