@element-plus/nightly 0.0.20241223 → 0.0.20241224
Sign up to get free protection for your applications and to get access to all the features.
- package/attributes.json +1 -1
- package/dist/index.css +1 -1
- package/dist/index.full.js +69 -9
- package/dist/index.full.min.js +15 -15
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +15 -15
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +69 -9
- package/dist/locale/af.js +1 -1
- package/dist/locale/af.min.js +1 -1
- package/dist/locale/af.min.mjs +1 -1
- package/dist/locale/af.mjs +1 -1
- package/dist/locale/ar-eg.js +1 -1
- package/dist/locale/ar-eg.min.js +1 -1
- package/dist/locale/ar-eg.min.mjs +1 -1
- package/dist/locale/ar-eg.mjs +1 -1
- package/dist/locale/ar.js +1 -1
- package/dist/locale/ar.min.js +1 -1
- package/dist/locale/ar.min.mjs +1 -1
- package/dist/locale/ar.mjs +1 -1
- package/dist/locale/az.js +1 -1
- package/dist/locale/az.min.js +1 -1
- package/dist/locale/az.min.mjs +1 -1
- package/dist/locale/az.mjs +1 -1
- package/dist/locale/bg.js +1 -1
- package/dist/locale/bg.min.js +1 -1
- package/dist/locale/bg.min.mjs +1 -1
- package/dist/locale/bg.mjs +1 -1
- package/dist/locale/bn.js +1 -1
- package/dist/locale/bn.min.js +1 -1
- package/dist/locale/bn.min.mjs +1 -1
- package/dist/locale/bn.mjs +1 -1
- package/dist/locale/ca.js +1 -1
- package/dist/locale/ca.min.js +1 -1
- package/dist/locale/ca.min.mjs +1 -1
- package/dist/locale/ca.mjs +1 -1
- package/dist/locale/ckb.js +1 -1
- package/dist/locale/ckb.min.js +1 -1
- package/dist/locale/ckb.min.mjs +1 -1
- package/dist/locale/ckb.mjs +1 -1
- package/dist/locale/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/hr.js +1 -1
- package/dist/locale/hr.min.js +1 -1
- package/dist/locale/hr.min.mjs +1 -1
- package/dist/locale/hr.mjs +1 -1
- package/dist/locale/hu.js +1 -1
- package/dist/locale/hu.min.js +1 -1
- package/dist/locale/hu.min.mjs +1 -1
- package/dist/locale/hu.mjs +1 -1
- package/dist/locale/hy-am.js +1 -1
- package/dist/locale/hy-am.min.js +1 -1
- package/dist/locale/hy-am.min.mjs +1 -1
- package/dist/locale/hy-am.mjs +1 -1
- package/dist/locale/id.js +1 -1
- package/dist/locale/id.min.js +1 -1
- package/dist/locale/id.min.mjs +1 -1
- package/dist/locale/id.mjs +1 -1
- package/dist/locale/it.js +1 -1
- package/dist/locale/it.min.js +1 -1
- package/dist/locale/it.min.mjs +1 -1
- package/dist/locale/it.mjs +1 -1
- package/dist/locale/ja.js +1 -1
- package/dist/locale/ja.min.js +1 -1
- package/dist/locale/ja.min.mjs +1 -1
- package/dist/locale/ja.mjs +1 -1
- package/dist/locale/kk.js +1 -1
- package/dist/locale/kk.min.js +1 -1
- package/dist/locale/kk.min.mjs +1 -1
- package/dist/locale/kk.mjs +1 -1
- package/dist/locale/km.js +1 -1
- package/dist/locale/km.min.js +1 -1
- package/dist/locale/km.min.mjs +1 -1
- package/dist/locale/km.mjs +1 -1
- package/dist/locale/ko.js +1 -1
- package/dist/locale/ko.min.js +1 -1
- package/dist/locale/ko.min.mjs +1 -1
- package/dist/locale/ko.mjs +1 -1
- package/dist/locale/ku.js +1 -1
- package/dist/locale/ku.min.js +1 -1
- package/dist/locale/ku.min.mjs +1 -1
- package/dist/locale/ku.mjs +1 -1
- package/dist/locale/ky.js +1 -1
- package/dist/locale/ky.min.js +1 -1
- package/dist/locale/ky.min.mjs +1 -1
- package/dist/locale/ky.mjs +1 -1
- package/dist/locale/lt.js +1 -1
- package/dist/locale/lt.min.js +1 -1
- package/dist/locale/lt.min.mjs +1 -1
- package/dist/locale/lt.mjs +1 -1
- package/dist/locale/lv.js +1 -1
- package/dist/locale/lv.min.js +1 -1
- package/dist/locale/lv.min.mjs +1 -1
- package/dist/locale/lv.mjs +1 -1
- package/dist/locale/mg.js +1 -1
- package/dist/locale/mg.min.js +1 -1
- package/dist/locale/mg.min.mjs +1 -1
- package/dist/locale/mg.mjs +1 -1
- package/dist/locale/mn.js +1 -1
- package/dist/locale/mn.min.js +1 -1
- package/dist/locale/mn.min.mjs +1 -1
- package/dist/locale/mn.mjs +1 -1
- package/dist/locale/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/autocomplete/src/autocomplete.vue.d.ts +4 -0
- 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/button/index.mjs +3 -3
- package/es/components/button/src/button-group.mjs +29 -6
- package/es/components/button/src/button-group.mjs.map +1 -1
- package/es/components/button/src/button-group2.mjs +6 -29
- package/es/components/button/src/button-group2.mjs.map +1 -1
- package/es/components/button/src/button.mjs +56 -77
- package/es/components/button/src/button.mjs.map +1 -1
- package/es/components/button/src/button2.mjs +77 -56
- package/es/components/button/src/button2.mjs.map +1 -1
- package/es/components/calendar/index.mjs +2 -2
- package/es/components/calendar/src/calendar.mjs +134 -16
- package/es/components/calendar/src/calendar.mjs.map +1 -1
- package/es/components/calendar/src/calendar2.mjs +16 -134
- package/es/components/calendar/src/calendar2.mjs.map +1 -1
- package/es/components/card/index.mjs +2 -2
- package/es/components/card/src/card.mjs +42 -20
- package/es/components/card/src/card.mjs.map +1 -1
- package/es/components/card/src/card2.mjs +20 -42
- package/es/components/card/src/card2.mjs.map +1 -1
- package/es/components/color-picker/src/color-picker2.mjs +4 -1
- package/es/components/color-picker/src/color-picker2.mjs.map +1 -1
- package/es/components/dialog/src/dialog-content.mjs +87 -26
- package/es/components/dialog/src/dialog-content.mjs.map +1 -1
- package/es/components/dialog/src/dialog-content2.mjs +26 -87
- package/es/components/dialog/src/dialog-content2.mjs.map +1 -1
- package/es/components/dialog/src/dialog.mjs +1 -1
- package/es/components/dialog/src/dialog2.mjs +1 -1
- package/es/components/dropdown/src/dropdown.vue.d.ts +4 -0
- package/es/components/empty/index.mjs +2 -2
- package/es/components/empty/src/empty.mjs +52 -11
- package/es/components/empty/src/empty.mjs.map +1 -1
- package/es/components/empty/src/empty2.mjs +11 -52
- package/es/components/empty/src/empty2.mjs.map +1 -1
- package/es/components/focus-trap/src/utils.mjs +10 -0
- package/es/components/focus-trap/src/utils.mjs.map +1 -1
- package/es/components/image-viewer/index.mjs +2 -2
- package/es/components/image-viewer/src/image-viewer.mjs +412 -45
- package/es/components/image-viewer/src/image-viewer.mjs.map +1 -1
- package/es/components/image-viewer/src/image-viewer2.mjs +45 -412
- package/es/components/image-viewer/src/image-viewer2.mjs.map +1 -1
- package/es/components/index.mjs +22 -22
- package/es/components/mention/index.mjs +2 -2
- package/es/components/mention/src/mention.mjs +282 -62
- package/es/components/mention/src/mention.mjs.map +1 -1
- package/es/components/mention/src/mention.vue.d.ts +4 -0
- package/es/components/mention/src/mention2.mjs +62 -282
- package/es/components/mention/src/mention2.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 +1 -1
- package/es/components/popconfirm/index.mjs +2 -2
- package/es/components/popconfirm/src/popconfirm.mjs +114 -45
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm2.mjs +45 -114
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/popper/index.mjs +4 -4
- package/es/components/popper/src/content.mjs +92 -132
- package/es/components/popper/src/content.mjs.map +1 -1
- package/es/components/popper/src/content2.mjs +132 -92
- package/es/components/popper/src/content2.mjs.map +1 -1
- package/es/components/popper/src/popper.mjs +22 -32
- package/es/components/popper/src/popper.mjs.map +1 -1
- package/es/components/popper/src/popper2.mjs +32 -22
- package/es/components/popper/src/popper2.mjs.map +1 -1
- package/es/components/radio/index.mjs +2 -2
- package/es/components/radio/src/radio-button.mjs +65 -5
- package/es/components/radio/src/radio-button.mjs.map +1 -1
- package/es/components/radio/src/radio-button2.mjs +5 -65
- package/es/components/radio/src/radio-button2.mjs.map +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/select/index.mjs +1 -1
- package/es/components/select/src/select.mjs +419 -113
- package/es/components/select/src/select.mjs.map +1 -1
- package/es/components/select/src/select2.mjs +113 -419
- package/es/components/select/src/select2.mjs.map +1 -1
- package/es/components/select-v2/src/defaults.d.ts +1 -0
- package/es/components/select-v2/src/defaults.mjs +8 -1
- package/es/components/select-v2/src/defaults.mjs.map +1 -1
- package/es/components/select-v2/src/select.vue.d.ts +3 -0
- package/es/components/select-v2/src/useSelect.mjs +38 -1
- package/es/components/select-v2/src/useSelect.mjs.map +1 -1
- package/es/components/skeleton/index.mjs +4 -4
- 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 +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/index.mjs +2 -2
- 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/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/steps/index.mjs +2 -2
- package/es/components/steps/src/item.mjs +190 -19
- package/es/components/steps/src/item.mjs.map +1 -1
- package/es/components/steps/src/item2.mjs +19 -190
- package/es/components/steps/src/item2.mjs.map +1 -1
- package/es/components/switch/index.mjs +2 -2
- package/es/components/switch/src/switch.mjs +228 -72
- package/es/components/switch/src/switch.mjs.map +1 -1
- package/es/components/switch/src/switch2.mjs +72 -228
- package/es/components/switch/src/switch2.mjs.map +1 -1
- package/es/components/table/src/filter-panel.vue.d.ts +4 -0
- package/es/components/tabs/index.mjs +2 -2
- package/es/components/tabs/src/tab-pane.mjs +71 -13
- package/es/components/tabs/src/tab-pane.mjs.map +1 -1
- package/es/components/tabs/src/tab-pane2.mjs +13 -71
- package/es/components/tabs/src/tab-pane2.mjs.map +1 -1
- package/es/components/timeline/index.mjs +2 -2
- package/es/components/timeline/src/timeline-item.mjs +72 -33
- package/es/components/timeline/src/timeline-item.mjs.map +1 -1
- package/es/components/timeline/src/timeline-item2.mjs +33 -72
- package/es/components/timeline/src/timeline-item2.mjs.map +1 -1
- package/es/components/tooltip/src/content.mjs +1 -1
- package/es/components/tooltip/src/content.vue.d.ts +4 -0
- package/es/components/tooltip/src/content2.mjs +11 -2
- package/es/components/tooltip/src/content2.mjs.map +1 -1
- package/es/components/tooltip/src/tooltip.mjs +1 -1
- package/es/components/tooltip/src/tooltip.vue.d.ts +2 -0
- package/es/components/tooltip/src/tooltip2.mjs +2 -4
- package/es/components/tooltip/src/tooltip2.mjs.map +1 -1
- package/es/components/tooltip-v2/index.mjs +2 -2
- package/es/components/tooltip-v2/src/arrow.mjs +37 -21
- package/es/components/tooltip-v2/src/arrow.mjs.map +1 -1
- package/es/components/tooltip-v2/src/arrow2.mjs +21 -37
- package/es/components/tooltip-v2/src/arrow2.mjs.map +1 -1
- package/es/components/tooltip-v2/src/content.mjs +110 -48
- package/es/components/tooltip-v2/src/content.mjs.map +1 -1
- package/es/components/tooltip-v2/src/content2.mjs +48 -110
- package/es/components/tooltip-v2/src/content2.mjs.map +1 -1
- package/es/components/tooltip-v2/src/tooltip.mjs +2 -2
- package/es/components/tooltip-v2/src/tooltip2.mjs +4 -4
- package/es/components/tour/src/mask.mjs +75 -18
- package/es/components/tour/src/mask.mjs.map +1 -1
- package/es/components/tour/src/mask2.mjs +18 -75
- package/es/components/tour/src/mask2.mjs.map +1 -1
- package/es/components/tour/src/tour2.mjs +1 -1
- package/es/components/upload/index.mjs +3 -3
- package/es/components/upload/src/upload-content.mjs +196 -33
- package/es/components/upload/src/upload-content.mjs.map +1 -1
- package/es/components/upload/src/upload-content2.mjs +33 -196
- package/es/components/upload/src/upload-content2.mjs.map +1 -1
- package/es/components/upload/src/upload-list.mjs +1 -1
- package/es/components/upload/src/upload.mjs +125 -97
- package/es/components/upload/src/upload.mjs.map +1 -1
- package/es/components/upload/src/upload2.mjs +97 -125
- package/es/components/upload/src/upload2.mjs.map +1 -1
- package/es/components/upload/src/use-handlers.mjs +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 +22 -22
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/autocomplete/src/autocomplete.vue.d.ts +4 -0
- 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/button/index.js +3 -3
- package/lib/components/button/src/button-group.js +29 -6
- package/lib/components/button/src/button-group.js.map +1 -1
- package/lib/components/button/src/button-group2.js +6 -29
- package/lib/components/button/src/button-group2.js.map +1 -1
- package/lib/components/button/src/button.js +59 -77
- package/lib/components/button/src/button.js.map +1 -1
- package/lib/components/button/src/button2.js +77 -59
- package/lib/components/button/src/button2.js.map +1 -1
- package/lib/components/calendar/index.js +2 -2
- package/lib/components/calendar/src/calendar.js +134 -17
- package/lib/components/calendar/src/calendar.js.map +1 -1
- package/lib/components/calendar/src/calendar2.js +17 -134
- package/lib/components/calendar/src/calendar2.js.map +1 -1
- package/lib/components/card/index.js +2 -2
- package/lib/components/card/src/card.js +42 -20
- package/lib/components/card/src/card.js.map +1 -1
- package/lib/components/card/src/card2.js +20 -42
- package/lib/components/card/src/card2.js.map +1 -1
- package/lib/components/color-picker/src/color-picker2.js +4 -1
- package/lib/components/color-picker/src/color-picker2.js.map +1 -1
- package/lib/components/dialog/src/dialog-content.js +86 -26
- package/lib/components/dialog/src/dialog-content.js.map +1 -1
- package/lib/components/dialog/src/dialog-content2.js +26 -86
- package/lib/components/dialog/src/dialog-content2.js.map +1 -1
- package/lib/components/dialog/src/dialog.js +1 -1
- package/lib/components/dialog/src/dialog2.js +1 -1
- package/lib/components/dropdown/src/dropdown.vue.d.ts +4 -0
- package/lib/components/empty/index.js +2 -2
- package/lib/components/empty/src/empty.js +52 -11
- package/lib/components/empty/src/empty.js.map +1 -1
- package/lib/components/empty/src/empty2.js +11 -52
- package/lib/components/empty/src/empty2.js.map +1 -1
- package/lib/components/focus-trap/src/utils.js +10 -0
- package/lib/components/focus-trap/src/utils.js.map +1 -1
- package/lib/components/image-viewer/index.js +2 -2
- package/lib/components/image-viewer/src/image-viewer.js +412 -46
- package/lib/components/image-viewer/src/image-viewer.js.map +1 -1
- package/lib/components/image-viewer/src/image-viewer2.js +46 -412
- package/lib/components/image-viewer/src/image-viewer2.js.map +1 -1
- package/lib/components/index.js +22 -22
- package/lib/components/mention/index.js +2 -2
- package/lib/components/mention/src/mention.js +280 -61
- package/lib/components/mention/src/mention.js.map +1 -1
- package/lib/components/mention/src/mention.vue.d.ts +4 -0
- package/lib/components/mention/src/mention2.js +61 -280
- package/lib/components/mention/src/mention2.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 +1 -1
- package/lib/components/popconfirm/index.js +2 -2
- package/lib/components/popconfirm/src/popconfirm.js +114 -46
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm2.js +46 -114
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/popper/index.js +4 -4
- package/lib/components/popper/src/content.js +97 -132
- package/lib/components/popper/src/content.js.map +1 -1
- package/lib/components/popper/src/content2.js +132 -97
- package/lib/components/popper/src/content2.js.map +1 -1
- package/lib/components/popper/src/popper.js +25 -32
- package/lib/components/popper/src/popper.js.map +1 -1
- package/lib/components/popper/src/popper2.js +32 -25
- package/lib/components/popper/src/popper2.js.map +1 -1
- package/lib/components/radio/index.js +2 -2
- package/lib/components/radio/src/radio-button.js +65 -5
- package/lib/components/radio/src/radio-button.js.map +1 -1
- package/lib/components/radio/src/radio-button2.js +5 -65
- package/lib/components/radio/src/radio-button2.js.map +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/select/index.js +1 -1
- package/lib/components/select/src/select.js +419 -113
- package/lib/components/select/src/select.js.map +1 -1
- package/lib/components/select/src/select2.js +113 -419
- package/lib/components/select/src/select2.js.map +1 -1
- package/lib/components/select-v2/src/defaults.d.ts +1 -0
- package/lib/components/select-v2/src/defaults.js +8 -1
- package/lib/components/select-v2/src/defaults.js.map +1 -1
- package/lib/components/select-v2/src/select.vue.d.ts +3 -0
- package/lib/components/select-v2/src/useSelect.js +38 -1
- package/lib/components/select-v2/src/useSelect.js.map +1 -1
- package/lib/components/skeleton/index.js +4 -4
- 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 +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/index.js +2 -2
- 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/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/steps/index.js +2 -2
- package/lib/components/steps/src/item.js +190 -19
- package/lib/components/steps/src/item.js.map +1 -1
- package/lib/components/steps/src/item2.js +19 -190
- package/lib/components/steps/src/item2.js.map +1 -1
- package/lib/components/switch/index.js +2 -2
- package/lib/components/switch/src/switch.js +227 -72
- package/lib/components/switch/src/switch.js.map +1 -1
- package/lib/components/switch/src/switch2.js +72 -227
- package/lib/components/switch/src/switch2.js.map +1 -1
- package/lib/components/table/src/filter-panel.vue.d.ts +4 -0
- package/lib/components/tabs/index.js +2 -2
- package/lib/components/tabs/src/tab-pane.js +71 -13
- package/lib/components/tabs/src/tab-pane.js.map +1 -1
- package/lib/components/tabs/src/tab-pane2.js +13 -71
- package/lib/components/tabs/src/tab-pane2.js.map +1 -1
- package/lib/components/timeline/index.js +2 -2
- package/lib/components/timeline/src/timeline-item.js +72 -33
- package/lib/components/timeline/src/timeline-item.js.map +1 -1
- package/lib/components/timeline/src/timeline-item2.js +33 -72
- package/lib/components/timeline/src/timeline-item2.js.map +1 -1
- package/lib/components/tooltip/src/content.js +1 -1
- package/lib/components/tooltip/src/content.vue.d.ts +4 -0
- package/lib/components/tooltip/src/content2.js +11 -2
- package/lib/components/tooltip/src/content2.js.map +1 -1
- package/lib/components/tooltip/src/tooltip.js +1 -1
- package/lib/components/tooltip/src/tooltip.vue.d.ts +2 -0
- package/lib/components/tooltip/src/tooltip2.js +2 -4
- package/lib/components/tooltip/src/tooltip2.js.map +1 -1
- package/lib/components/tooltip-v2/index.js +2 -2
- package/lib/components/tooltip-v2/src/arrow.js +37 -22
- package/lib/components/tooltip-v2/src/arrow.js.map +1 -1
- package/lib/components/tooltip-v2/src/arrow2.js +22 -37
- package/lib/components/tooltip-v2/src/arrow2.js.map +1 -1
- package/lib/components/tooltip-v2/src/content.js +110 -48
- package/lib/components/tooltip-v2/src/content.js.map +1 -1
- package/lib/components/tooltip-v2/src/content2.js +48 -110
- package/lib/components/tooltip-v2/src/content2.js.map +1 -1
- package/lib/components/tooltip-v2/src/tooltip.js +2 -2
- package/lib/components/tooltip-v2/src/tooltip2.js +4 -4
- package/lib/components/tour/src/mask.js +75 -18
- package/lib/components/tour/src/mask.js.map +1 -1
- package/lib/components/tour/src/mask2.js +18 -75
- package/lib/components/tour/src/mask2.js.map +1 -1
- package/lib/components/tour/src/tour2.js +1 -1
- package/lib/components/upload/index.js +3 -3
- package/lib/components/upload/src/upload-content.js +195 -32
- package/lib/components/upload/src/upload-content.js.map +1 -1
- package/lib/components/upload/src/upload-content2.js +32 -195
- package/lib/components/upload/src/upload-content2.js.map +1 -1
- package/lib/components/upload/src/upload-list.js +1 -1
- package/lib/components/upload/src/upload.js +125 -100
- package/lib/components/upload/src/upload.js.map +1 -1
- package/lib/components/upload/src/upload2.js +100 -125
- package/lib/components/upload/src/upload2.js.map +1 -1
- package/lib/components/upload/src/use-handlers.js +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 +22 -22
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +2 -2
- package/tags.json +1 -1
- package/theme-chalk/el-input-number.css +1 -1
- package/theme-chalk/el-input.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/input-number.scss +8 -0
- package/theme-chalk/src/input.scss +5 -3
- package/web-types.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"arrow2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/arrow.
|
1
|
+
{"version":3,"file":"arrow2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/arrow.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-plus/utils'\nimport { tooltipV2Sides } from './common'\n\nimport type { CSSProperties, ExtractPropTypes } from 'vue'\nimport type { TooltipV2Sides } from './common'\n\nexport const tooltipV2ArrowProps = buildProps({\n width: {\n type: Number,\n default: 10,\n },\n height: {\n type: Number,\n default: 10,\n },\n style: {\n type: definePropType<CSSProperties | null>(Object),\n default: null,\n },\n} as const)\n\nexport const tooltipV2ArrowSpecialProps = buildProps({\n side: {\n type: definePropType<TooltipV2Sides>(String),\n values: tooltipV2Sides,\n required: true,\n },\n} as const)\n\nexport type TooltipV2ArrowProps = ExtractPropTypes<typeof tooltipV2ArrowProps>\n"],"names":[],"mappings":";;;AAEY,MAAC,mBAAmB,GAAG,UAAU,CAAC;AAC9C,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,0BAA0B,GAAG,UAAU,CAAC;AACrD,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,MAAM,EAAE,cAAc;AAC1B,IAAI,QAAQ,EAAE,IAAI;AAClB,GAAG;AACH,CAAC;;;;"}
|
@@ -1,52 +1,114 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
1
|
+
import { defineComponent, inject, ref, computed, unref, watch, onMounted, provide, openBlock, createElementBlock, normalizeStyle, normalizeClass, renderSlot, createVNode, withCtx, Fragment, createTextVNode, toDisplayString, createCommentVNode } from 'vue';
|
2
|
+
import { offset } from '@floating-ui/dom';
|
3
|
+
import ElVisuallyHidden from '../../visual-hidden/src/visual-hidden2.mjs';
|
4
|
+
import { tooltipV2RootKey, tooltipV2ContentKey } from './constants.mjs';
|
5
|
+
import { tooltipV2ContentProps } from './content2.mjs';
|
6
|
+
import { tooltipV2CommonProps } from './common.mjs';
|
7
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
8
|
+
import { useFloating, arrowMiddleware } from '../../../hooks/use-floating/index.mjs';
|
9
|
+
import { useZIndex } from '../../../hooks/use-z-index/index.mjs';
|
10
|
+
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
3
11
|
|
4
|
-
const
|
5
|
-
|
6
|
-
"top-start",
|
7
|
-
"top-end",
|
8
|
-
"top",
|
9
|
-
"bottom-start",
|
10
|
-
"bottom-end",
|
11
|
-
"bottom",
|
12
|
-
"left-start",
|
13
|
-
"left-end",
|
14
|
-
"left",
|
15
|
-
"right-start",
|
16
|
-
"right-end",
|
17
|
-
"right"
|
18
|
-
];
|
19
|
-
const tooltipV2ContentProps = buildProps({
|
20
|
-
arrowPadding: {
|
21
|
-
type: definePropType(Number),
|
22
|
-
default: 5
|
23
|
-
},
|
24
|
-
effect: {
|
25
|
-
type: definePropType(String),
|
26
|
-
default: "light"
|
27
|
-
},
|
28
|
-
contentClass: String,
|
29
|
-
placement: {
|
30
|
-
type: definePropType(String),
|
31
|
-
values: tooltipV2Placements,
|
32
|
-
default: "bottom"
|
33
|
-
},
|
34
|
-
reference: {
|
35
|
-
type: definePropType(Object),
|
36
|
-
default: null
|
37
|
-
},
|
38
|
-
offset: {
|
39
|
-
type: Number,
|
40
|
-
default: 8
|
41
|
-
},
|
42
|
-
strategy: {
|
43
|
-
type: definePropType(String),
|
44
|
-
values: tooltipV2Strategies,
|
45
|
-
default: "absolute"
|
46
|
-
},
|
47
|
-
showArrow: Boolean,
|
48
|
-
...useAriaProps(["ariaLabel"])
|
12
|
+
const __default__ = defineComponent({
|
13
|
+
name: "ElTooltipV2Content"
|
49
14
|
});
|
15
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
16
|
+
...__default__,
|
17
|
+
props: { ...tooltipV2ContentProps, ...tooltipV2CommonProps },
|
18
|
+
setup(__props) {
|
19
|
+
const props = __props;
|
20
|
+
const { triggerRef, contentId } = inject(tooltipV2RootKey);
|
21
|
+
const placement = ref(props.placement);
|
22
|
+
const strategy = ref(props.strategy);
|
23
|
+
const arrowRef = ref(null);
|
24
|
+
const { referenceRef, contentRef, middlewareData, x, y, update } = useFloating({
|
25
|
+
placement,
|
26
|
+
strategy,
|
27
|
+
middleware: computed(() => {
|
28
|
+
const middleware = [offset(props.offset)];
|
29
|
+
if (props.showArrow) {
|
30
|
+
middleware.push(arrowMiddleware({
|
31
|
+
arrowRef
|
32
|
+
}));
|
33
|
+
}
|
34
|
+
return middleware;
|
35
|
+
})
|
36
|
+
});
|
37
|
+
const zIndex = useZIndex().nextZIndex();
|
38
|
+
const ns = useNamespace("tooltip-v2");
|
39
|
+
const side = computed(() => {
|
40
|
+
return placement.value.split("-")[0];
|
41
|
+
});
|
42
|
+
const contentStyle = computed(() => {
|
43
|
+
return {
|
44
|
+
position: unref(strategy),
|
45
|
+
top: `${unref(y) || 0}px`,
|
46
|
+
left: `${unref(x) || 0}px`,
|
47
|
+
zIndex
|
48
|
+
};
|
49
|
+
});
|
50
|
+
const arrowStyle = computed(() => {
|
51
|
+
if (!props.showArrow)
|
52
|
+
return {};
|
53
|
+
const { arrow } = unref(middlewareData);
|
54
|
+
return {
|
55
|
+
[`--${ns.namespace.value}-tooltip-v2-arrow-x`]: `${arrow == null ? void 0 : arrow.x}px` || "",
|
56
|
+
[`--${ns.namespace.value}-tooltip-v2-arrow-y`]: `${arrow == null ? void 0 : arrow.y}px` || ""
|
57
|
+
};
|
58
|
+
});
|
59
|
+
const contentClass = computed(() => [
|
60
|
+
ns.e("content"),
|
61
|
+
ns.is("dark", props.effect === "dark"),
|
62
|
+
ns.is(unref(strategy)),
|
63
|
+
props.contentClass
|
64
|
+
]);
|
65
|
+
watch(arrowRef, () => update());
|
66
|
+
watch(() => props.placement, (val) => placement.value = val);
|
67
|
+
onMounted(() => {
|
68
|
+
watch(() => props.reference || triggerRef.value, (el) => {
|
69
|
+
referenceRef.value = el || void 0;
|
70
|
+
}, {
|
71
|
+
immediate: true
|
72
|
+
});
|
73
|
+
});
|
74
|
+
provide(tooltipV2ContentKey, { arrowRef });
|
75
|
+
return (_ctx, _cache) => {
|
76
|
+
return openBlock(), createElementBlock("div", {
|
77
|
+
ref_key: "contentRef",
|
78
|
+
ref: contentRef,
|
79
|
+
style: normalizeStyle(unref(contentStyle)),
|
80
|
+
"data-tooltip-v2-root": ""
|
81
|
+
}, [
|
82
|
+
!_ctx.nowrap ? (openBlock(), createElementBlock("div", {
|
83
|
+
key: 0,
|
84
|
+
"data-side": unref(side),
|
85
|
+
class: normalizeClass(unref(contentClass))
|
86
|
+
}, [
|
87
|
+
renderSlot(_ctx.$slots, "default", {
|
88
|
+
contentStyle: unref(contentStyle),
|
89
|
+
contentClass: unref(contentClass)
|
90
|
+
}),
|
91
|
+
createVNode(unref(ElVisuallyHidden), {
|
92
|
+
id: unref(contentId),
|
93
|
+
role: "tooltip"
|
94
|
+
}, {
|
95
|
+
default: withCtx(() => [
|
96
|
+
_ctx.ariaLabel ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
97
|
+
createTextVNode(toDisplayString(_ctx.ariaLabel), 1)
|
98
|
+
], 64)) : renderSlot(_ctx.$slots, "default", { key: 1 })
|
99
|
+
]),
|
100
|
+
_: 3
|
101
|
+
}, 8, ["id"]),
|
102
|
+
renderSlot(_ctx.$slots, "arrow", {
|
103
|
+
style: normalizeStyle(unref(arrowStyle)),
|
104
|
+
side: unref(side)
|
105
|
+
})
|
106
|
+
], 10, ["data-side"])) : createCommentVNode("v-if", true)
|
107
|
+
], 4);
|
108
|
+
};
|
109
|
+
}
|
110
|
+
});
|
111
|
+
var TooltipV2Content = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "content.vue"]]);
|
50
112
|
|
51
|
-
export {
|
113
|
+
export { TooltipV2Content as default };
|
52
114
|
//# sourceMappingURL=content.mjs.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"content.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/content.
|
1
|
+
{"version":3,"file":"content.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/content.vue"],"sourcesContent":["<template>\n <div ref=\"contentRef\" :style=\"contentStyle\" data-tooltip-v2-root>\n <div v-if=\"!nowrap\" :data-side=\"side\" :class=\"contentClass\">\n <slot :content-style=\"contentStyle\" :content-class=\"contentClass\" />\n <el-visually-hidden :id=\"contentId\" role=\"tooltip\">\n <template v-if=\"ariaLabel\">\n {{ ariaLabel }}\n </template>\n <slot v-else />\n </el-visually-hidden>\n <slot name=\"arrow\" :style=\"arrowStyle\" :side=\"side\" />\n </div>\n </div>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed, inject, onMounted, provide, ref, unref, watch } from 'vue'\nimport { offset } from '@floating-ui/dom'\nimport {\n arrowMiddleware,\n useFloating,\n useNamespace,\n useZIndex,\n} from '@element-plus/hooks'\nimport ElVisuallyHidden from '@element-plus/components/visual-hidden'\nimport { tooltipV2ContentKey, tooltipV2RootKey } from './constants'\nimport { tooltipV2ContentProps } from './content'\nimport { tooltipV2CommonProps } from './common'\n\nimport type { CSSProperties } from 'vue'\nimport type { Middleware } from '@floating-ui/dom'\n\ndefineOptions({\n name: 'ElTooltipV2Content',\n})\n\nconst props = defineProps({ ...tooltipV2ContentProps, ...tooltipV2CommonProps })\n\nconst { triggerRef, contentId } = inject(tooltipV2RootKey)!\n\nconst placement = ref(props.placement)\nconst strategy = ref(props.strategy)\nconst arrowRef = ref<HTMLElement | null>(null)\n\nconst { referenceRef, contentRef, middlewareData, x, y, update } = useFloating({\n placement,\n strategy,\n middleware: computed(() => {\n const middleware: Middleware[] = [offset(props.offset)]\n\n if (props.showArrow) {\n middleware.push(\n arrowMiddleware({\n arrowRef,\n })\n )\n }\n\n return middleware\n }),\n})\n\nconst zIndex = useZIndex().nextZIndex()\n\nconst ns = useNamespace('tooltip-v2')\n\nconst side = computed(() => {\n return placement.value.split('-')[0]\n})\n\nconst contentStyle = computed<CSSProperties>(() => {\n return {\n position: unref(strategy),\n top: `${unref(y) || 0}px`,\n left: `${unref(x) || 0}px`,\n zIndex,\n }\n})\n\nconst arrowStyle = computed<CSSProperties>(() => {\n if (!props.showArrow) return {}\n\n const { arrow } = unref(middlewareData)\n\n return {\n [`--${ns.namespace.value}-tooltip-v2-arrow-x`]: `${arrow?.x}px` || '',\n [`--${ns.namespace.value}-tooltip-v2-arrow-y`]: `${arrow?.y}px` || '',\n }\n})\n\nconst contentClass = computed(() => [\n ns.e('content'),\n ns.is('dark', props.effect === 'dark'),\n ns.is(unref(strategy)),\n props.contentClass,\n])\n\nwatch(arrowRef, () => update())\n\nwatch(\n () => props.placement,\n (val) => (placement.value = val)\n)\n\nonMounted(() => {\n watch(\n () => props.reference || triggerRef.value,\n (el) => {\n referenceRef.value = el || undefined\n },\n {\n immediate: true,\n }\n )\n})\n\nprovide(tooltipV2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AAA,EAAA,MAAA,MAAA,EAAA,CAAA,CAAA;AAED,IAAM,KAAA,CAAA,MAAA,KAAgB,CAAA,SAAA,EAAO,CAAC,GAAA,KAAA,SAAA,CAAA,KAAA,GAAA,GAAA,CAAA,CAAA;AAE9B,IAAA,SAAA,CAAA,MAAA;AAAA,MACE,MAAM,MAAM,KAAA,CAAA,SAAA,IAAA,UAAA,CAAA,KAAA,EAAA,CAAA,EAAA,KAAA;AAAA,QACF,YAAA,CAAA,KAAkB,GAAA,EAAA,IAAA,KAAA,CAAA,CAAA;AAAA,OAC9B,EAAA;AAEA,QAAA,SAAgB,EAAA,IAAA;AACd,OAAA,CAAA,CAAA;AAAA,KACE,CAAA,CAAA;AAAoC,IAAA,OAC5B,CAAA,mBAAA,EAAA,EAAA,QAAA,EAAA,CAAA,CAAA;AACN,IAAA,OAAA,CAAA,IAAA,EAAA;AAA2B,MAC7B,OAAAA,SAAA,EAAA,EAAAC,kBAAA,CAAA,KAAA,EAAA;AAAA,QACA,OAAA,EAAA,YAAA;AAAA,QAAA,GACa,EAAA,UAAA;AAAA,QACb,KAAA,EAAAC,cAAA,CAAAC,KAAA,CAAA,YAAA,CAAA,CAAA;AAAA,QACF,sBAAA,EAAA,EAAA;AAAA,OACD,EAAA;AAED,QAAQ,CAAA,IAAA,CAAA,MAAA,IAAAH,SAAuB,EAAA,EAAAC,kBAAU,CAAA,KAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
@@ -1,114 +1,52 @@
|
|
1
|
-
import {
|
2
|
-
import {
|
3
|
-
import ElVisuallyHidden from '../../visual-hidden/src/visual-hidden2.mjs';
|
4
|
-
import { tooltipV2RootKey, tooltipV2ContentKey } from './constants.mjs';
|
5
|
-
import { tooltipV2ContentProps } from './content.mjs';
|
6
|
-
import { tooltipV2CommonProps } from './common.mjs';
|
7
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
8
|
-
import { useFloating, arrowMiddleware } from '../../../hooks/use-floating/index.mjs';
|
9
|
-
import { useZIndex } from '../../../hooks/use-z-index/index.mjs';
|
10
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
1
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
2
|
+
import { useAriaProps } from '../../../hooks/use-aria/index.mjs';
|
11
3
|
|
12
|
-
const
|
13
|
-
|
4
|
+
const tooltipV2Strategies = ["absolute", "fixed"];
|
5
|
+
const tooltipV2Placements = [
|
6
|
+
"top-start",
|
7
|
+
"top-end",
|
8
|
+
"top",
|
9
|
+
"bottom-start",
|
10
|
+
"bottom-end",
|
11
|
+
"bottom",
|
12
|
+
"left-start",
|
13
|
+
"left-end",
|
14
|
+
"left",
|
15
|
+
"right-start",
|
16
|
+
"right-end",
|
17
|
+
"right"
|
18
|
+
];
|
19
|
+
const tooltipV2ContentProps = buildProps({
|
20
|
+
arrowPadding: {
|
21
|
+
type: definePropType(Number),
|
22
|
+
default: 5
|
23
|
+
},
|
24
|
+
effect: {
|
25
|
+
type: definePropType(String),
|
26
|
+
default: "light"
|
27
|
+
},
|
28
|
+
contentClass: String,
|
29
|
+
placement: {
|
30
|
+
type: definePropType(String),
|
31
|
+
values: tooltipV2Placements,
|
32
|
+
default: "bottom"
|
33
|
+
},
|
34
|
+
reference: {
|
35
|
+
type: definePropType(Object),
|
36
|
+
default: null
|
37
|
+
},
|
38
|
+
offset: {
|
39
|
+
type: Number,
|
40
|
+
default: 8
|
41
|
+
},
|
42
|
+
strategy: {
|
43
|
+
type: definePropType(String),
|
44
|
+
values: tooltipV2Strategies,
|
45
|
+
default: "absolute"
|
46
|
+
},
|
47
|
+
showArrow: Boolean,
|
48
|
+
...useAriaProps(["ariaLabel"])
|
14
49
|
});
|
15
|
-
const _sfc_main = /* @__PURE__ */ defineComponent({
|
16
|
-
...__default__,
|
17
|
-
props: { ...tooltipV2ContentProps, ...tooltipV2CommonProps },
|
18
|
-
setup(__props) {
|
19
|
-
const props = __props;
|
20
|
-
const { triggerRef, contentId } = inject(tooltipV2RootKey);
|
21
|
-
const placement = ref(props.placement);
|
22
|
-
const strategy = ref(props.strategy);
|
23
|
-
const arrowRef = ref(null);
|
24
|
-
const { referenceRef, contentRef, middlewareData, x, y, update } = useFloating({
|
25
|
-
placement,
|
26
|
-
strategy,
|
27
|
-
middleware: computed(() => {
|
28
|
-
const middleware = [offset(props.offset)];
|
29
|
-
if (props.showArrow) {
|
30
|
-
middleware.push(arrowMiddleware({
|
31
|
-
arrowRef
|
32
|
-
}));
|
33
|
-
}
|
34
|
-
return middleware;
|
35
|
-
})
|
36
|
-
});
|
37
|
-
const zIndex = useZIndex().nextZIndex();
|
38
|
-
const ns = useNamespace("tooltip-v2");
|
39
|
-
const side = computed(() => {
|
40
|
-
return placement.value.split("-")[0];
|
41
|
-
});
|
42
|
-
const contentStyle = computed(() => {
|
43
|
-
return {
|
44
|
-
position: unref(strategy),
|
45
|
-
top: `${unref(y) || 0}px`,
|
46
|
-
left: `${unref(x) || 0}px`,
|
47
|
-
zIndex
|
48
|
-
};
|
49
|
-
});
|
50
|
-
const arrowStyle = computed(() => {
|
51
|
-
if (!props.showArrow)
|
52
|
-
return {};
|
53
|
-
const { arrow } = unref(middlewareData);
|
54
|
-
return {
|
55
|
-
[`--${ns.namespace.value}-tooltip-v2-arrow-x`]: `${arrow == null ? void 0 : arrow.x}px` || "",
|
56
|
-
[`--${ns.namespace.value}-tooltip-v2-arrow-y`]: `${arrow == null ? void 0 : arrow.y}px` || ""
|
57
|
-
};
|
58
|
-
});
|
59
|
-
const contentClass = computed(() => [
|
60
|
-
ns.e("content"),
|
61
|
-
ns.is("dark", props.effect === "dark"),
|
62
|
-
ns.is(unref(strategy)),
|
63
|
-
props.contentClass
|
64
|
-
]);
|
65
|
-
watch(arrowRef, () => update());
|
66
|
-
watch(() => props.placement, (val) => placement.value = val);
|
67
|
-
onMounted(() => {
|
68
|
-
watch(() => props.reference || triggerRef.value, (el) => {
|
69
|
-
referenceRef.value = el || void 0;
|
70
|
-
}, {
|
71
|
-
immediate: true
|
72
|
-
});
|
73
|
-
});
|
74
|
-
provide(tooltipV2ContentKey, { arrowRef });
|
75
|
-
return (_ctx, _cache) => {
|
76
|
-
return openBlock(), createElementBlock("div", {
|
77
|
-
ref_key: "contentRef",
|
78
|
-
ref: contentRef,
|
79
|
-
style: normalizeStyle(unref(contentStyle)),
|
80
|
-
"data-tooltip-v2-root": ""
|
81
|
-
}, [
|
82
|
-
!_ctx.nowrap ? (openBlock(), createElementBlock("div", {
|
83
|
-
key: 0,
|
84
|
-
"data-side": unref(side),
|
85
|
-
class: normalizeClass(unref(contentClass))
|
86
|
-
}, [
|
87
|
-
renderSlot(_ctx.$slots, "default", {
|
88
|
-
contentStyle: unref(contentStyle),
|
89
|
-
contentClass: unref(contentClass)
|
90
|
-
}),
|
91
|
-
createVNode(unref(ElVisuallyHidden), {
|
92
|
-
id: unref(contentId),
|
93
|
-
role: "tooltip"
|
94
|
-
}, {
|
95
|
-
default: withCtx(() => [
|
96
|
-
_ctx.ariaLabel ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
97
|
-
createTextVNode(toDisplayString(_ctx.ariaLabel), 1)
|
98
|
-
], 64)) : renderSlot(_ctx.$slots, "default", { key: 1 })
|
99
|
-
]),
|
100
|
-
_: 3
|
101
|
-
}, 8, ["id"]),
|
102
|
-
renderSlot(_ctx.$slots, "arrow", {
|
103
|
-
style: normalizeStyle(unref(arrowStyle)),
|
104
|
-
side: unref(side)
|
105
|
-
})
|
106
|
-
], 10, ["data-side"])) : createCommentVNode("v-if", true)
|
107
|
-
], 4);
|
108
|
-
};
|
109
|
-
}
|
110
|
-
});
|
111
|
-
var TooltipV2Content = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "content.vue"]]);
|
112
50
|
|
113
|
-
export {
|
51
|
+
export { tooltipV2ContentProps };
|
114
52
|
//# sourceMappingURL=content2.mjs.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"content2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/content.
|
1
|
+
{"version":3,"file":"content2.mjs","sources":["../../../../../../packages/components/tooltip-v2/src/content.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-plus/utils'\nimport { useAriaProps } from '@element-plus/hooks'\n\nimport type { PopperEffect } from '@element-plus/components/popper'\nimport type { ExtractPropTypes } from 'vue'\nimport type { Placement, Strategy, VirtualElement } from '@floating-ui/dom'\n\nconst tooltipV2Strategies = ['absolute', 'fixed'] as const\n\nconst tooltipV2Placements = [\n 'top-start',\n 'top-end',\n 'top',\n 'bottom-start',\n 'bottom-end',\n 'bottom',\n 'left-start',\n 'left-end',\n 'left',\n 'right-start',\n 'right-end',\n 'right',\n] as const\n\nexport const tooltipV2ContentProps = buildProps({\n arrowPadding: {\n type: definePropType<number>(Number),\n default: 5,\n },\n effect: {\n type: definePropType<PopperEffect>(String),\n default: 'light',\n },\n contentClass: String,\n /**\n * Placement of tooltip content relative to reference element (when absent it refers to trigger)\n */\n placement: {\n type: definePropType<Placement>(String),\n values: tooltipV2Placements,\n default: 'bottom',\n },\n /**\n * Reference element for tooltip content to set its position\n */\n reference: {\n type: definePropType<HTMLElement | VirtualElement | null>(Object),\n default: null,\n },\n offset: {\n type: Number,\n default: 8,\n },\n strategy: {\n type: definePropType<Strategy>(String),\n values: tooltipV2Strategies,\n default: 'absolute',\n },\n showArrow: Boolean,\n ...useAriaProps(['ariaLabel']),\n} as const)\n\nexport type TooltipV2ContentProps = ExtractPropTypes<\n typeof tooltipV2ContentProps\n>\n"],"names":[],"mappings":";;;AAEA,MAAM,mBAAmB,GAAG,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;AAClD,MAAM,mBAAmB,GAAG;AAC5B,EAAE,WAAW;AACb,EAAE,SAAS;AACX,EAAE,KAAK;AACP,EAAE,cAAc;AAChB,EAAE,YAAY;AACd,EAAE,QAAQ;AACV,EAAE,YAAY;AACd,EAAE,UAAU;AACZ,EAAE,MAAM;AACR,EAAE,aAAa;AACf,EAAE,WAAW;AACb,EAAE,OAAO;AACT,CAAC,CAAC;AACU,MAAC,qBAAqB,GAAG,UAAU,CAAC;AAChD,EAAE,YAAY,EAAE;AAChB,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,CAAC;AACd,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,OAAO;AACpB,GAAG;AACH,EAAE,YAAY,EAAE,MAAM;AACtB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,MAAM,EAAE,mBAAmB;AAC/B,IAAI,OAAO,EAAE,QAAQ;AACrB,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,CAAC;AACd,GAAG;AACH,EAAE,QAAQ,EAAE;AACZ,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,MAAM,EAAE,mBAAmB;AAC/B,IAAI,OAAO,EAAE,UAAU;AACvB,GAAG;AACH,EAAE,SAAS,EAAE,OAAO;AACpB,EAAE,GAAG,YAAY,CAAC,CAAC,WAAW,CAAC,CAAC;AAChC,CAAC;;;;"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { tooltipV2RootProps } from './root.mjs';
|
2
2
|
import { tooltipV2TriggerProps } from './trigger.mjs';
|
3
|
-
import { tooltipV2ArrowProps } from './
|
4
|
-
import { tooltipV2ContentProps } from './
|
3
|
+
import { tooltipV2ArrowProps } from './arrow2.mjs';
|
4
|
+
import { tooltipV2ContentProps } from './content2.mjs';
|
5
5
|
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
6
6
|
|
7
7
|
const tooltipV2Props = buildProps({
|
@@ -1,14 +1,14 @@
|
|
1
1
|
import { defineComponent, toRefs, reactive, openBlock, createBlock, normalizeProps, guardReactiveProps, withCtx, createVNode, mergeProps, renderSlot, unref, Transition, createCommentVNode, createElementBlock, Fragment } from 'vue';
|
2
2
|
import { pick } from 'lodash-unified';
|
3
3
|
import { ElTeleport } from '../../teleport/index.mjs';
|
4
|
-
import { tooltipV2ArrowProps } from './
|
5
|
-
import { tooltipV2ContentProps } from './
|
4
|
+
import { tooltipV2ArrowProps } from './arrow2.mjs';
|
5
|
+
import { tooltipV2ContentProps } from './content2.mjs';
|
6
6
|
import { tooltipV2RootProps } from './root.mjs';
|
7
7
|
import { tooltipV2Props } from './tooltip.mjs';
|
8
8
|
import { tooltipV2TriggerProps } from './trigger.mjs';
|
9
9
|
import TooltipV2Root from './root2.mjs';
|
10
|
-
import TooltipV2Arrow from './
|
11
|
-
import TooltipV2Content from './
|
10
|
+
import TooltipV2Arrow from './arrow.mjs';
|
11
|
+
import TooltipV2Content from './content.mjs';
|
12
12
|
import TooltipV2Trigger from './trigger2.mjs';
|
13
13
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
14
14
|
|
@@ -1,23 +1,80 @@
|
|
1
|
-
import {
|
1
|
+
import { defineComponent, inject, computed, toRef, openBlock, createElementBlock, mergeProps, unref, createElementVNode, normalizeClass, normalizeStyle, createCommentVNode } from 'vue';
|
2
|
+
import { maskProps } from './mask2.mjs';
|
3
|
+
import { tourKey } from './helper.mjs';
|
4
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
5
|
+
import { useLockscreen } from '../../../hooks/use-lockscreen/index.mjs';
|
2
6
|
|
3
|
-
const
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
7
|
+
const __default__ = defineComponent({
|
8
|
+
name: "ElTourMask",
|
9
|
+
inheritAttrs: false
|
10
|
+
});
|
11
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
12
|
+
...__default__,
|
13
|
+
props: maskProps,
|
14
|
+
setup(__props) {
|
15
|
+
const props = __props;
|
16
|
+
const { ns } = inject(tourKey);
|
17
|
+
const radius = computed(() => {
|
18
|
+
var _a, _b;
|
19
|
+
return (_b = (_a = props.pos) == null ? void 0 : _a.radius) != null ? _b : 2;
|
20
|
+
});
|
21
|
+
const roundInfo = computed(() => {
|
22
|
+
const v = radius.value;
|
23
|
+
const baseInfo = `a${v},${v} 0 0 1`;
|
24
|
+
return {
|
25
|
+
topRight: `${baseInfo} ${v},${v}`,
|
26
|
+
bottomRight: `${baseInfo} ${-v},${v}`,
|
27
|
+
bottomLeft: `${baseInfo} ${-v},${-v}`,
|
28
|
+
topLeft: `${baseInfo} ${v},${-v}`
|
29
|
+
};
|
30
|
+
});
|
31
|
+
const path = computed(() => {
|
32
|
+
const width = window.innerWidth;
|
33
|
+
const height = window.innerHeight;
|
34
|
+
const info = roundInfo.value;
|
35
|
+
const _path = `M${width},0 L0,0 L0,${height} L${width},${height} L${width},0 Z`;
|
36
|
+
const _radius = radius.value;
|
37
|
+
return props.pos ? `${_path} M${props.pos.left + _radius},${props.pos.top} h${props.pos.width - _radius * 2} ${info.topRight} v${props.pos.height - _radius * 2} ${info.bottomRight} h${-props.pos.width + _radius * 2} ${info.bottomLeft} v${-props.pos.height + _radius * 2} ${info.topLeft} z` : _path;
|
38
|
+
});
|
39
|
+
const pathStyle = computed(() => {
|
40
|
+
return {
|
41
|
+
fill: props.fill,
|
42
|
+
pointerEvents: "auto",
|
43
|
+
cursor: "auto"
|
44
|
+
};
|
45
|
+
});
|
46
|
+
useLockscreen(toRef(props, "visible"), {
|
47
|
+
ns
|
48
|
+
});
|
49
|
+
return (_ctx, _cache) => {
|
50
|
+
return _ctx.visible ? (openBlock(), createElementBlock("div", mergeProps({
|
51
|
+
key: 0,
|
52
|
+
class: unref(ns).e("mask"),
|
53
|
+
style: {
|
54
|
+
position: "fixed",
|
55
|
+
left: 0,
|
56
|
+
right: 0,
|
57
|
+
top: 0,
|
58
|
+
bottom: 0,
|
59
|
+
zIndex: _ctx.zIndex,
|
60
|
+
pointerEvents: _ctx.pos && _ctx.targetAreaClickable ? "none" : "auto"
|
61
|
+
}
|
62
|
+
}, _ctx.$attrs), [
|
63
|
+
(openBlock(), createElementBlock("svg", { style: {
|
64
|
+
width: "100%",
|
65
|
+
height: "100%"
|
66
|
+
} }, [
|
67
|
+
createElementVNode("path", {
|
68
|
+
class: normalizeClass(unref(ns).e("hollow")),
|
69
|
+
style: normalizeStyle(unref(pathStyle)),
|
70
|
+
d: unref(path)
|
71
|
+
}, null, 14, ["d"])
|
72
|
+
]))
|
73
|
+
], 16)) : createCommentVNode("v-if", true);
|
74
|
+
};
|
19
75
|
}
|
20
76
|
});
|
77
|
+
var ElTourMask = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "mask.vue"]]);
|
21
78
|
|
22
|
-
export {
|
79
|
+
export { ElTourMask as default };
|
23
80
|
//# sourceMappingURL=mask.mjs.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"mask.mjs","sources":["../../../../../../packages/components/tour/src/mask.
|
1
|
+
{"version":3,"file":"mask.mjs","sources":["../../../../../../packages/components/tour/src/mask.vue"],"sourcesContent":["<template>\n <div\n v-if=\"visible\"\n :class=\"ns.e('mask')\"\n :style=\"({\n position: 'fixed',\n left: 0,\n right: 0,\n top: 0,\n bottom: 0,\n zIndex,\n pointerEvents: pos && targetAreaClickable ? 'none' : 'auto',\n } as any)\"\n v-bind=\"$attrs\"\n >\n <svg\n :style=\"{\n width: '100%',\n height: '100%',\n }\"\n >\n <path :class=\"ns.e('hollow')\" :style=\"pathStyle\" :d=\"path\" />\n </svg>\n </div>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed, inject, toRef } from 'vue'\nimport { useLockscreen } from '@element-plus/hooks'\nimport { maskProps } from './mask'\nimport { tourKey } from './helper'\nimport type { CSSProperties } from 'vue'\n\ndefineOptions({\n name: 'ElTourMask',\n inheritAttrs: false,\n})\n\nconst props = defineProps(maskProps)\n\nconst { ns } = inject(tourKey)!\nconst radius = computed(() => props.pos?.radius ?? 2)\nconst roundInfo = computed(() => {\n const v = radius.value\n const baseInfo = `a${v},${v} 0 0 1`\n return {\n topRight: `${baseInfo} ${v},${v}`,\n bottomRight: `${baseInfo} ${-v},${v}`,\n bottomLeft: `${baseInfo} ${-v},${-v}`,\n topLeft: `${baseInfo} ${v},${-v}`,\n }\n})\n\nconst path = computed(() => {\n const width = window.innerWidth\n const height = window.innerHeight\n const info = roundInfo.value\n const _path = `M${width},0 L0,0 L0,${height} L${width},${height} L${width},0 Z`\n const _radius = radius.value\n return props.pos\n ? `${_path} M${props.pos.left + _radius},${props.pos.top} h${\n props.pos.width - _radius * 2\n } ${info.topRight} v${props.pos.height - _radius * 2} ${\n info.bottomRight\n } h${-props.pos.width + _radius * 2} ${info.bottomLeft} v${\n -props.pos.height + _radius * 2\n } ${info.topLeft} z`\n : _path\n})\n\nconst pathStyle = computed<CSSProperties>(() => {\n return {\n fill: props.fill,\n pointerEvents: 'auto',\n cursor: 'auto',\n }\n})\n\nuseLockscreen(toRef(props, 'visible'), {\n ns,\n})\n</script>\n"],"names":[],"mappings":";;;;;;mCAiCc,CAAA;AAAA,EACZ,IAAM,EAAA,YAAA;AAAA,EACN,YAAc,EAAA,KAAA;AAChB,CAAA,CAAA,CAAA;;;;;;AAIA,IAAA,MAAM,EAAE,EAAA,EAAO,GAAA,MAAA,CAAO,OAAO,CAAA,CAAA;AAC7B,IAAA,MAAM,SAAS,QAAS,CAAA,MAAM;AAC9B,MAAM,IAAA,EAAA,EAAA,EAAA,CAAA;AACJ,MAAA,UAAU,GAAO,CAAA,EAAA,GAAA,KAAA,CAAA,GAAA,KAAA,IAAA,GAAA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