@element-plus/nightly 0.0.20251126 → 0.0.20251129
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -5
- package/attributes.json +1 -1
- package/dist/index.full.js +48 -26
- package/dist/index.full.min.js +15 -15
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +10 -10
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +48 -26
- package/dist/locale/af.js +1 -1
- package/dist/locale/af.min.js +1 -1
- package/dist/locale/af.min.mjs +1 -1
- package/dist/locale/af.mjs +1 -1
- package/dist/locale/ar-eg.js +1 -1
- package/dist/locale/ar-eg.min.js +1 -1
- package/dist/locale/ar-eg.min.mjs +1 -1
- package/dist/locale/ar-eg.mjs +1 -1
- package/dist/locale/ar.js +1 -1
- package/dist/locale/ar.min.js +1 -1
- package/dist/locale/ar.min.mjs +1 -1
- package/dist/locale/ar.mjs +1 -1
- package/dist/locale/az.js +1 -1
- package/dist/locale/az.min.js +1 -1
- package/dist/locale/az.min.mjs +1 -1
- package/dist/locale/az.mjs +1 -1
- package/dist/locale/bg.js +1 -1
- package/dist/locale/bg.min.js +1 -1
- package/dist/locale/bg.min.mjs +1 -1
- package/dist/locale/bg.mjs +1 -1
- package/dist/locale/bn.js +1 -1
- package/dist/locale/bn.min.js +1 -1
- package/dist/locale/bn.min.mjs +1 -1
- package/dist/locale/bn.mjs +1 -1
- package/dist/locale/ca.js +1 -1
- package/dist/locale/ca.min.js +1 -1
- package/dist/locale/ca.min.mjs +1 -1
- package/dist/locale/ca.mjs +1 -1
- package/dist/locale/ckb.js +1 -1
- package/dist/locale/ckb.min.js +1 -1
- package/dist/locale/ckb.min.mjs +1 -1
- package/dist/locale/ckb.mjs +1 -1
- package/dist/locale/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/hi.js +1 -1
- package/dist/locale/hi.min.js +1 -1
- package/dist/locale/hi.min.mjs +1 -1
- package/dist/locale/hi.mjs +1 -1
- package/dist/locale/hr.js +1 -1
- package/dist/locale/hr.min.js +1 -1
- package/dist/locale/hr.min.mjs +1 -1
- package/dist/locale/hr.mjs +1 -1
- package/dist/locale/hu.js +1 -1
- package/dist/locale/hu.min.js +1 -1
- package/dist/locale/hu.min.mjs +1 -1
- package/dist/locale/hu.mjs +1 -1
- package/dist/locale/hy-am.js +1 -1
- package/dist/locale/hy-am.min.js +1 -1
- package/dist/locale/hy-am.min.mjs +1 -1
- package/dist/locale/hy-am.mjs +1 -1
- package/dist/locale/id.js +1 -1
- package/dist/locale/id.min.js +1 -1
- package/dist/locale/id.min.mjs +1 -1
- package/dist/locale/id.mjs +1 -1
- package/dist/locale/it.js +1 -1
- package/dist/locale/it.min.js +1 -1
- package/dist/locale/it.min.mjs +1 -1
- package/dist/locale/it.mjs +1 -1
- package/dist/locale/ja.js +1 -1
- package/dist/locale/ja.min.js +1 -1
- package/dist/locale/ja.min.mjs +1 -1
- package/dist/locale/ja.mjs +1 -1
- package/dist/locale/kk.js +1 -1
- package/dist/locale/kk.min.js +1 -1
- package/dist/locale/kk.min.mjs +1 -1
- package/dist/locale/kk.mjs +1 -1
- package/dist/locale/km.js +1 -1
- package/dist/locale/km.min.js +1 -1
- package/dist/locale/km.min.mjs +1 -1
- package/dist/locale/km.mjs +1 -1
- package/dist/locale/ko.js +1 -1
- package/dist/locale/ko.min.js +1 -1
- package/dist/locale/ko.min.mjs +1 -1
- package/dist/locale/ko.mjs +1 -1
- package/dist/locale/ku.js +1 -1
- package/dist/locale/ku.min.js +1 -1
- package/dist/locale/ku.min.mjs +1 -1
- package/dist/locale/ku.mjs +1 -1
- package/dist/locale/ky.js +1 -1
- package/dist/locale/ky.min.js +1 -1
- package/dist/locale/ky.min.mjs +1 -1
- package/dist/locale/ky.mjs +1 -1
- package/dist/locale/lo.js +1 -1
- package/dist/locale/lo.min.js +1 -1
- package/dist/locale/lo.min.mjs +1 -1
- package/dist/locale/lo.mjs +1 -1
- package/dist/locale/lt.js +1 -1
- package/dist/locale/lt.min.js +1 -1
- package/dist/locale/lt.min.mjs +1 -1
- package/dist/locale/lt.mjs +1 -1
- package/dist/locale/lv.js +1 -1
- package/dist/locale/lv.min.js +1 -1
- package/dist/locale/lv.min.mjs +1 -1
- package/dist/locale/lv.mjs +1 -1
- package/dist/locale/mg.js +1 -1
- package/dist/locale/mg.min.js +1 -1
- package/dist/locale/mg.min.mjs +1 -1
- package/dist/locale/mg.mjs +1 -1
- package/dist/locale/mn.js +1 -1
- package/dist/locale/mn.min.js +1 -1
- package/dist/locale/mn.min.mjs +1 -1
- package/dist/locale/mn.mjs +1 -1
- package/dist/locale/ms.js +1 -1
- package/dist/locale/ms.min.js +1 -1
- package/dist/locale/ms.min.mjs +1 -1
- package/dist/locale/ms.mjs +1 -1
- package/dist/locale/my.js +1 -1
- package/dist/locale/my.min.js +1 -1
- package/dist/locale/my.min.mjs +1 -1
- package/dist/locale/my.mjs +1 -1
- package/dist/locale/nb-no.js +1 -1
- package/dist/locale/nb-no.min.js +1 -1
- package/dist/locale/nb-no.min.mjs +1 -1
- package/dist/locale/nb-no.mjs +1 -1
- package/dist/locale/nl.js +1 -1
- package/dist/locale/nl.min.js +1 -1
- package/dist/locale/nl.min.mjs +1 -1
- package/dist/locale/nl.mjs +1 -1
- package/dist/locale/no.js +1 -1
- package/dist/locale/no.min.js +1 -1
- package/dist/locale/no.min.mjs +1 -1
- package/dist/locale/no.mjs +1 -1
- package/dist/locale/pa.js +1 -1
- package/dist/locale/pa.min.js +1 -1
- package/dist/locale/pa.min.mjs +1 -1
- package/dist/locale/pa.mjs +1 -1
- package/dist/locale/pl.js +1 -1
- package/dist/locale/pl.min.js +1 -1
- package/dist/locale/pl.min.mjs +1 -1
- package/dist/locale/pl.mjs +1 -1
- package/dist/locale/pt-br.js +1 -1
- package/dist/locale/pt-br.min.js +1 -1
- package/dist/locale/pt-br.min.mjs +1 -1
- package/dist/locale/pt-br.mjs +1 -1
- package/dist/locale/pt.js +1 -1
- package/dist/locale/pt.min.js +1 -1
- package/dist/locale/pt.min.mjs +1 -1
- package/dist/locale/pt.mjs +1 -1
- package/dist/locale/ro.js +1 -1
- package/dist/locale/ro.min.js +1 -1
- package/dist/locale/ro.min.mjs +1 -1
- package/dist/locale/ro.mjs +1 -1
- package/dist/locale/ru.js +1 -1
- package/dist/locale/ru.min.js +1 -1
- package/dist/locale/ru.min.mjs +1 -1
- package/dist/locale/ru.mjs +1 -1
- package/dist/locale/sk.js +1 -1
- package/dist/locale/sk.min.js +1 -1
- package/dist/locale/sk.min.mjs +1 -1
- package/dist/locale/sk.mjs +1 -1
- package/dist/locale/sl.js +1 -1
- package/dist/locale/sl.min.js +1 -1
- package/dist/locale/sl.min.mjs +1 -1
- package/dist/locale/sl.mjs +1 -1
- package/dist/locale/sr.js +1 -1
- package/dist/locale/sr.min.js +1 -1
- package/dist/locale/sr.min.mjs +1 -1
- package/dist/locale/sr.mjs +1 -1
- package/dist/locale/sv.js +1 -1
- package/dist/locale/sv.min.js +1 -1
- package/dist/locale/sv.min.mjs +1 -1
- package/dist/locale/sv.mjs +1 -1
- package/dist/locale/sw.js +1 -1
- package/dist/locale/sw.min.js +1 -1
- package/dist/locale/sw.min.mjs +1 -1
- package/dist/locale/sw.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/te.js +1 -1
- package/dist/locale/te.min.js +1 -1
- package/dist/locale/te.min.mjs +1 -1
- package/dist/locale/te.mjs +1 -1
- package/dist/locale/th.js +1 -1
- package/dist/locale/th.min.js +1 -1
- package/dist/locale/th.min.mjs +1 -1
- package/dist/locale/th.mjs +1 -1
- package/dist/locale/tk.js +1 -1
- package/dist/locale/tk.min.js +1 -1
- package/dist/locale/tk.min.mjs +1 -1
- package/dist/locale/tk.mjs +1 -1
- package/dist/locale/tr.js +1 -1
- package/dist/locale/tr.min.js +1 -1
- package/dist/locale/tr.min.mjs +1 -1
- package/dist/locale/tr.mjs +1 -1
- package/dist/locale/ug-cn.js +1 -1
- package/dist/locale/ug-cn.min.js +1 -1
- package/dist/locale/ug-cn.min.mjs +1 -1
- package/dist/locale/ug-cn.mjs +1 -1
- package/dist/locale/uk.js +1 -1
- package/dist/locale/uk.min.js +1 -1
- package/dist/locale/uk.min.mjs +1 -1
- package/dist/locale/uk.mjs +1 -1
- package/dist/locale/uz-uz.js +1 -1
- package/dist/locale/uz-uz.min.js +1 -1
- package/dist/locale/uz-uz.min.mjs +1 -1
- package/dist/locale/uz-uz.mjs +1 -1
- package/dist/locale/vi.js +1 -1
- package/dist/locale/vi.min.js +1 -1
- package/dist/locale/vi.min.mjs +1 -1
- package/dist/locale/vi.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/dist/locale/zh-hk.js +1 -1
- package/dist/locale/zh-hk.min.js +1 -1
- package/dist/locale/zh-hk.min.mjs +1 -1
- package/dist/locale/zh-hk.mjs +1 -1
- package/dist/locale/zh-mo.js +1 -1
- package/dist/locale/zh-mo.min.js +1 -1
- package/dist/locale/zh-mo.min.mjs +1 -1
- package/dist/locale/zh-mo.mjs +1 -1
- package/dist/locale/zh-tw.js +1 -1
- package/dist/locale/zh-tw.min.js +1 -1
- package/dist/locale/zh-tw.min.mjs +1 -1
- package/dist/locale/zh-tw.mjs +1 -1
- package/es/components/anchor/index.mjs +1 -1
- package/es/components/anchor/src/anchor-link.mjs +81 -5
- package/es/components/anchor/src/anchor-link.mjs.map +1 -1
- package/es/components/anchor/src/anchor-link2.mjs +5 -81
- package/es/components/anchor/src/anchor-link2.mjs.map +1 -1
- package/es/components/backtop/index.mjs +2 -2
- package/es/components/backtop/src/backtop.mjs +53 -21
- package/es/components/backtop/src/backtop.mjs.map +1 -1
- package/es/components/backtop/src/backtop2.mjs +21 -53
- package/es/components/backtop/src/backtop2.mjs.map +1 -1
- package/es/components/carousel/index.mjs +2 -2
- package/es/components/carousel/src/carousel-item.mjs +69 -7
- package/es/components/carousel/src/carousel-item.mjs.map +1 -1
- package/es/components/carousel/src/carousel-item2.mjs +7 -69
- package/es/components/carousel/src/carousel-item2.mjs.map +1 -1
- package/es/components/cascader/src/cascader.mjs +1 -1
- package/es/components/color-picker-panel/src/components/alpha-slider.mjs +3 -2
- package/es/components/color-picker-panel/src/components/alpha-slider.mjs.map +1 -1
- package/es/components/color-picker-panel/src/components/hue-slider.mjs +3 -2
- package/es/components/color-picker-panel/src/components/hue-slider.mjs.map +1 -1
- package/es/components/color-picker-panel/src/components/sv-panel.mjs +3 -2
- package/es/components/color-picker-panel/src/components/sv-panel.mjs.map +1 -1
- package/es/components/date-picker-panel/src/date-picker-com/basic-date-table.mjs +3 -2
- package/es/components/date-picker-panel/src/date-picker-com/basic-date-table.mjs.map +1 -1
- package/es/components/date-picker-panel/src/date-picker-com/panel-date-pick.mjs +6 -4
- package/es/components/date-picker-panel/src/date-picker-com/panel-date-pick.mjs.map +1 -1
- package/es/components/date-picker-panel/src/date-picker-com/panel-date-range.mjs +12 -8
- package/es/components/date-picker-panel/src/date-picker-com/panel-date-range.mjs.map +1 -1
- package/es/components/divider/index.mjs +2 -2
- package/es/components/divider/src/divider.mjs +34 -16
- package/es/components/divider/src/divider.mjs.map +1 -1
- package/es/components/divider/src/divider2.mjs +16 -34
- package/es/components/divider/src/divider2.mjs.map +1 -1
- package/es/components/image/index.mjs +2 -2
- package/es/components/image/src/image.mjs +234 -69
- package/es/components/image/src/image.mjs.map +1 -1
- package/es/components/image/src/image2.mjs +69 -234
- package/es/components/image/src/image2.mjs.map +1 -1
- package/es/components/image-viewer/index.mjs +2 -2
- package/es/components/image-viewer/src/image-viewer.mjs +484 -51
- package/es/components/image-viewer/src/image-viewer.mjs.map +1 -1
- package/es/components/image-viewer/src/image-viewer2.mjs +51 -484
- package/es/components/image-viewer/src/image-viewer2.mjs.map +1 -1
- package/es/components/index.mjs +13 -13
- package/es/components/input-tag/src/input-tag.mjs +1 -1
- package/es/components/menu/index.mjs +2 -2
- package/es/components/menu/src/menu-item.mjs +101 -15
- package/es/components/menu/src/menu-item.mjs.map +1 -1
- package/es/components/menu/src/menu-item2.mjs +15 -101
- package/es/components/menu/src/menu-item2.mjs.map +1 -1
- package/es/components/pagination/src/components/next.mjs +35 -18
- package/es/components/pagination/src/components/next.mjs.map +1 -1
- package/es/components/pagination/src/components/next2.mjs +18 -35
- package/es/components/pagination/src/components/next2.mjs.map +1 -1
- package/es/components/pagination/src/pagination.mjs +1 -1
- package/es/components/popconfirm/index.mjs +2 -2
- package/es/components/popconfirm/src/popconfirm.mjs +135 -50
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm2.mjs +50 -135
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/select/src/select.mjs +1 -1
- package/es/components/select-v2/src/defaults.mjs +1 -1
- package/es/components/skeleton/index.mjs +2 -2
- package/es/components/skeleton/src/skeleton-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/skeleton2.mjs +1 -1
- package/es/components/splitter/index.mjs +2 -2
- package/es/components/splitter/src/split-panel.d.ts +1 -1
- package/es/components/splitter/src/split-panel.mjs +1 -1
- package/es/components/splitter/src/split-panel.mjs.map +1 -1
- package/es/components/splitter/src/split-panel.vue.d.ts +2 -2
- package/es/components/splitter/src/splitter.mjs +15 -100
- package/es/components/splitter/src/splitter.mjs.map +1 -1
- package/es/components/splitter/src/splitter2.mjs +101 -15
- package/es/components/splitter/src/splitter2.mjs.map +1 -1
- package/es/components/table/src/table/defaults.d.ts +3 -3
- package/es/components/table/src/table/defaults.mjs +1 -1
- package/es/components/table/src/table/defaults.mjs.map +1 -1
- package/es/components/table/src/table-column/watcher-helper.mjs +3 -0
- package/es/components/table/src/table-column/watcher-helper.mjs.map +1 -1
- package/es/components/table/src/table.vue.d.ts +3 -3
- package/es/components/tabs/index.mjs +1 -1
- package/es/components/tabs/src/tab-bar.mjs +11 -92
- package/es/components/tabs/src/tab-bar.mjs.map +1 -1
- package/es/components/tabs/src/tab-bar2.mjs +92 -11
- package/es/components/tabs/src/tab-bar2.mjs.map +1 -1
- package/es/components/tabs/src/tab-nav.mjs +1 -1
- package/es/components/tag/index.mjs +2 -2
- package/es/components/tag/src/tag.mjs +99 -27
- package/es/components/tag/src/tag.mjs.map +1 -1
- package/es/components/tag/src/tag2.mjs +27 -99
- package/es/components/tag/src/tag2.mjs.map +1 -1
- package/es/components/time-select/index.mjs +2 -2
- package/es/components/time-select/src/time-select.mjs +64 -134
- package/es/components/time-select/src/time-select.mjs.map +1 -1
- package/es/components/time-select/src/time-select2.mjs +134 -64
- package/es/components/time-select/src/time-select2.mjs.map +1 -1
- package/es/components/timeline/src/timeline.d.ts +8 -2
- package/es/components/timeline/src/timeline.mjs +12 -3
- package/es/components/timeline/src/timeline.mjs.map +1 -1
- package/es/components/tour/index.mjs +1 -1
- package/es/components/tour/src/content.mjs +43 -67
- package/es/components/tour/src/content.mjs.map +1 -1
- package/es/components/tour/src/content2.mjs +67 -43
- package/es/components/tour/src/content2.mjs.map +1 -1
- package/es/components/tour/src/step.mjs +1 -1
- package/es/components/tour/src/tour.mjs +1 -1
- package/es/components/tour/src/tour2.mjs +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/tree-select/index.d.ts +1 -0
- package/es/components/tree-select/index.mjs.map +1 -1
- package/es/components/tree-select/src/instance.d.ts +6 -0
- package/es/components/tree-select/src/instance.mjs +2 -0
- package/es/components/tree-select/src/instance.mjs.map +1 -0
- package/es/index.mjs +13 -13
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/anchor/index.js +1 -1
- package/lib/components/anchor/src/anchor-link.js +81 -5
- package/lib/components/anchor/src/anchor-link.js.map +1 -1
- package/lib/components/anchor/src/anchor-link2.js +5 -81
- package/lib/components/anchor/src/anchor-link2.js.map +1 -1
- package/lib/components/backtop/index.js +2 -2
- package/lib/components/backtop/src/backtop.js +53 -22
- package/lib/components/backtop/src/backtop.js.map +1 -1
- package/lib/components/backtop/src/backtop2.js +22 -53
- package/lib/components/backtop/src/backtop2.js.map +1 -1
- package/lib/components/carousel/index.js +2 -2
- package/lib/components/carousel/src/carousel-item.js +69 -7
- package/lib/components/carousel/src/carousel-item.js.map +1 -1
- package/lib/components/carousel/src/carousel-item2.js +7 -69
- package/lib/components/carousel/src/carousel-item2.js.map +1 -1
- package/lib/components/cascader/src/cascader.js +1 -1
- package/lib/components/color-picker-panel/src/components/alpha-slider.js +3 -2
- package/lib/components/color-picker-panel/src/components/alpha-slider.js.map +1 -1
- package/lib/components/color-picker-panel/src/components/hue-slider.js +3 -2
- package/lib/components/color-picker-panel/src/components/hue-slider.js.map +1 -1
- package/lib/components/color-picker-panel/src/components/sv-panel.js +3 -2
- package/lib/components/color-picker-panel/src/components/sv-panel.js.map +1 -1
- package/lib/components/date-picker-panel/src/date-picker-com/basic-date-table.js +3 -2
- package/lib/components/date-picker-panel/src/date-picker-com/basic-date-table.js.map +1 -1
- package/lib/components/date-picker-panel/src/date-picker-com/panel-date-pick.js +6 -4
- package/lib/components/date-picker-panel/src/date-picker-com/panel-date-pick.js.map +1 -1
- package/lib/components/date-picker-panel/src/date-picker-com/panel-date-range.js +12 -8
- package/lib/components/date-picker-panel/src/date-picker-com/panel-date-range.js.map +1 -1
- package/lib/components/divider/index.js +2 -2
- package/lib/components/divider/src/divider.js +34 -16
- package/lib/components/divider/src/divider.js.map +1 -1
- package/lib/components/divider/src/divider2.js +16 -34
- package/lib/components/divider/src/divider2.js.map +1 -1
- package/lib/components/image/index.js +2 -2
- package/lib/components/image/src/image.js +233 -69
- package/lib/components/image/src/image.js.map +1 -1
- package/lib/components/image/src/image2.js +69 -233
- package/lib/components/image/src/image2.js.map +1 -1
- package/lib/components/image-viewer/index.js +2 -2
- package/lib/components/image-viewer/src/image-viewer.js +484 -52
- package/lib/components/image-viewer/src/image-viewer.js.map +1 -1
- package/lib/components/image-viewer/src/image-viewer2.js +52 -484
- package/lib/components/image-viewer/src/image-viewer2.js.map +1 -1
- package/lib/components/index.js +13 -13
- package/lib/components/input-tag/src/input-tag.js +1 -1
- package/lib/components/menu/index.js +2 -2
- package/lib/components/menu/src/menu-item.js +101 -16
- package/lib/components/menu/src/menu-item.js.map +1 -1
- package/lib/components/menu/src/menu-item2.js +16 -101
- package/lib/components/menu/src/menu-item2.js.map +1 -1
- package/lib/components/pagination/src/components/next.js +35 -18
- package/lib/components/pagination/src/components/next.js.map +1 -1
- package/lib/components/pagination/src/components/next2.js +18 -35
- package/lib/components/pagination/src/components/next2.js.map +1 -1
- package/lib/components/pagination/src/pagination.js +1 -1
- package/lib/components/popconfirm/index.js +2 -2
- package/lib/components/popconfirm/src/popconfirm.js +135 -51
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm2.js +51 -135
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/select/src/select.js +1 -1
- package/lib/components/select-v2/src/defaults.js +1 -1
- package/lib/components/skeleton/index.js +2 -2
- package/lib/components/skeleton/src/skeleton-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/skeleton2.js +1 -1
- package/lib/components/splitter/index.js +2 -2
- package/lib/components/splitter/src/split-panel.d.ts +1 -1
- package/lib/components/splitter/src/split-panel.js +1 -1
- package/lib/components/splitter/src/split-panel.js.map +1 -1
- package/lib/components/splitter/src/split-panel.vue.d.ts +2 -2
- package/lib/components/splitter/src/splitter.js +16 -100
- package/lib/components/splitter/src/splitter.js.map +1 -1
- package/lib/components/splitter/src/splitter2.js +101 -16
- package/lib/components/splitter/src/splitter2.js.map +1 -1
- package/lib/components/table/src/table/defaults.d.ts +3 -3
- package/lib/components/table/src/table/defaults.js +1 -1
- package/lib/components/table/src/table/defaults.js.map +1 -1
- package/lib/components/table/src/table-column/watcher-helper.js +3 -0
- package/lib/components/table/src/table-column/watcher-helper.js.map +1 -1
- package/lib/components/table/src/table.vue.d.ts +3 -3
- package/lib/components/tabs/index.js +1 -1
- package/lib/components/tabs/src/tab-bar.js +11 -92
- package/lib/components/tabs/src/tab-bar.js.map +1 -1
- package/lib/components/tabs/src/tab-bar2.js +92 -11
- package/lib/components/tabs/src/tab-bar2.js.map +1 -1
- package/lib/components/tabs/src/tab-nav.js +1 -1
- package/lib/components/tag/index.js +2 -2
- package/lib/components/tag/src/tag.js +99 -28
- package/lib/components/tag/src/tag.js.map +1 -1
- package/lib/components/tag/src/tag2.js +28 -99
- package/lib/components/tag/src/tag2.js.map +1 -1
- package/lib/components/time-select/index.js +2 -2
- package/lib/components/time-select/src/time-select.js +64 -139
- package/lib/components/time-select/src/time-select.js.map +1 -1
- package/lib/components/time-select/src/time-select2.js +139 -64
- package/lib/components/time-select/src/time-select2.js.map +1 -1
- package/lib/components/timeline/src/timeline.d.ts +8 -2
- package/lib/components/timeline/src/timeline.js +11 -2
- package/lib/components/timeline/src/timeline.js.map +1 -1
- package/lib/components/tour/index.js +1 -1
- package/lib/components/tour/src/content.js +46 -67
- package/lib/components/tour/src/content.js.map +1 -1
- package/lib/components/tour/src/content2.js +67 -46
- package/lib/components/tour/src/content2.js.map +1 -1
- package/lib/components/tour/src/step.js +1 -1
- package/lib/components/tour/src/tour.js +1 -1
- package/lib/components/tour/src/tour2.js +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/tree-select/index.d.ts +1 -0
- package/lib/components/tree-select/index.js.map +1 -1
- package/lib/components/tree-select/src/instance.d.ts +6 -0
- package/lib/components/tree-select/src/instance.js +3 -0
- package/lib/components/tree-select/src/instance.js.map +1 -0
- package/lib/index.js +13 -13
- 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/web-types.json +1 -1
|
@@ -26,6 +26,6 @@ export type SplitterPanelProps = ExtractPropTypes<typeof splitterPanelProps>;
|
|
|
26
26
|
export type SplitterPanelPropsPublic = __ExtractPublicPropTypes<typeof splitterPanelProps>;
|
|
27
27
|
export type SplitterPanelInstance = InstanceType<typeof SplitterPanel> & unknown;
|
|
28
28
|
export declare const splitterPanelEmits: {
|
|
29
|
-
'update:size': (value: number) => boolean;
|
|
29
|
+
'update:size': (value: number | string) => boolean;
|
|
30
30
|
};
|
|
31
31
|
export type SplitterPanelEmits = typeof splitterPanelEmits;
|
|
@@ -17,7 +17,7 @@ const splitterPanelProps = buildProps({
|
|
|
17
17
|
collapsible: Boolean
|
|
18
18
|
});
|
|
19
19
|
const splitterPanelEmits = {
|
|
20
|
-
"update:size": (value) => typeof value === "number"
|
|
20
|
+
"update:size": (value) => typeof value === "number" || typeof value === "string"
|
|
21
21
|
};
|
|
22
22
|
|
|
23
23
|
export { splitterPanelEmits, splitterPanelProps };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"split-panel.mjs","sources":["../../../../../../packages/components/splitter/src/split-panel.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type SplitterPanel from './split-panel.vue'\n\nexport const splitterPanelProps = buildProps({\n min: {\n type: [String, Number],\n },\n max: {\n type: [String, Number],\n },\n size: {\n type: [String, Number],\n },\n resizable: {\n type: Boolean,\n default: true,\n },\n collapsible: Boolean,\n} as const)\n\nexport type SplitterPanelProps = ExtractPropTypes<typeof splitterPanelProps>\nexport type SplitterPanelPropsPublic = __ExtractPublicPropTypes<\n typeof splitterPanelProps\n>\nexport type SplitterPanelInstance = InstanceType<typeof SplitterPanel> & unknown\n\nexport const splitterPanelEmits = {\n 'update:size': (value: number)
|
|
1
|
+
{"version":3,"file":"split-panel.mjs","sources":["../../../../../../packages/components/splitter/src/split-panel.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type SplitterPanel from './split-panel.vue'\n\nexport const splitterPanelProps = buildProps({\n min: {\n type: [String, Number],\n },\n max: {\n type: [String, Number],\n },\n size: {\n type: [String, Number],\n },\n resizable: {\n type: Boolean,\n default: true,\n },\n collapsible: Boolean,\n} as const)\n\nexport type SplitterPanelProps = ExtractPropTypes<typeof splitterPanelProps>\nexport type SplitterPanelPropsPublic = __ExtractPublicPropTypes<\n typeof splitterPanelProps\n>\nexport type SplitterPanelInstance = InstanceType<typeof SplitterPanel> & unknown\n\nexport const splitterPanelEmits = {\n 'update:size': (value: number | string) =>\n typeof value === 'number' || typeof value === 'string',\n}\n\nexport type SplitterPanelEmits = typeof splitterPanelEmits\n"],"names":[],"mappings":";;AACY,MAAC,kBAAkB,GAAG,UAAU,CAAC;AAC7C,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,WAAW,EAAE,OAAO;AACtB,CAAC,EAAE;AACS,MAAC,kBAAkB,GAAG;AAClC,EAAE,aAAa,EAAE,CAAC,KAAK,KAAK,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,QAAQ;AAClF;;;;"}
|
|
@@ -28,7 +28,7 @@ declare const __VLS_component: import("vue").DefineComponent<{
|
|
|
28
28
|
/** @description splitter-panel html element */
|
|
29
29
|
splitterPanelRef: import("vue").Ref<HTMLDivElement | undefined>;
|
|
30
30
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
31
|
-
"update:size": (value: number) => void;
|
|
31
|
+
"update:size": (value: string | number) => void;
|
|
32
32
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
33
33
|
readonly min: {
|
|
34
34
|
readonly type: import("vue").PropType<import("@element-plus/nightly/es/utils").EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown>>;
|
|
@@ -51,7 +51,7 @@ declare const __VLS_component: import("vue").DefineComponent<{
|
|
|
51
51
|
readonly resizable: import("@element-plus/nightly/es/utils").EpPropFinalized<BooleanConstructor, unknown, unknown, true, boolean>;
|
|
52
52
|
readonly collapsible: BooleanConstructor;
|
|
53
53
|
}>> & {
|
|
54
|
-
"onUpdate:size"?: ((value: number) => any) | undefined;
|
|
54
|
+
"onUpdate:size"?: ((value: string | number) => any) | undefined;
|
|
55
55
|
}, {
|
|
56
56
|
readonly resizable: import("@element-plus/nightly/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
57
57
|
readonly collapsible: boolean;
|
|
@@ -1,104 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { splitterProps, splitterEmits } from './splitter2.mjs';
|
|
3
|
-
import { splitterRootContextKey } from './type.mjs';
|
|
4
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
5
|
-
import { useContainer } from './hooks/useContainer.mjs';
|
|
6
|
-
import { useSize } from './hooks/useSize.mjs';
|
|
7
|
-
import { useResize } from './hooks/useResize.mjs';
|
|
8
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
9
|
-
import { useOrderedChildren } from '../../../hooks/use-ordered-children/index.mjs';
|
|
1
|
+
import { buildProps } from '../../../utils/vue/props/runtime.mjs';
|
|
10
2
|
|
|
11
|
-
const
|
|
12
|
-
|
|
3
|
+
const splitterProps = buildProps({
|
|
4
|
+
layout: {
|
|
5
|
+
type: String,
|
|
6
|
+
default: "horizontal",
|
|
7
|
+
values: ["horizontal", "vertical"]
|
|
8
|
+
},
|
|
9
|
+
lazy: Boolean
|
|
13
10
|
});
|
|
14
|
-
const
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
const ns = useNamespace("splitter");
|
|
21
|
-
const layout = toRef(props, "layout");
|
|
22
|
-
const lazy = toRef(props, "lazy");
|
|
23
|
-
const { containerEl, containerSize } = useContainer(layout);
|
|
24
|
-
const {
|
|
25
|
-
removeChild: unregisterPanel,
|
|
26
|
-
children: panels,
|
|
27
|
-
addChild: registerPanel,
|
|
28
|
-
ChildrenSorter: PanelsSorter
|
|
29
|
-
} = useOrderedChildren(getCurrentInstance(), "ElSplitterPanel");
|
|
30
|
-
watch(panels, () => {
|
|
31
|
-
panels.value.forEach((instance, index) => {
|
|
32
|
-
instance.setIndex(index);
|
|
33
|
-
});
|
|
34
|
-
});
|
|
35
|
-
const { percentSizes, pxSizes } = useSize(panels, containerSize);
|
|
36
|
-
const {
|
|
37
|
-
lazyOffset,
|
|
38
|
-
movingIndex,
|
|
39
|
-
onMoveStart,
|
|
40
|
-
onMoving,
|
|
41
|
-
onMoveEnd,
|
|
42
|
-
onCollapse
|
|
43
|
-
} = useResize(panels, containerSize, pxSizes, lazy);
|
|
44
|
-
const splitterStyles = computed(() => {
|
|
45
|
-
return {
|
|
46
|
-
[ns.cssVarBlockName("bar-offset")]: lazy.value ? `${lazyOffset.value}px` : void 0
|
|
47
|
-
};
|
|
48
|
-
});
|
|
49
|
-
const onResizeStart = (index) => {
|
|
50
|
-
onMoveStart(index);
|
|
51
|
-
emits("resizeStart", index, pxSizes.value);
|
|
52
|
-
};
|
|
53
|
-
const onResize = (index, offset) => {
|
|
54
|
-
onMoving(index, offset);
|
|
55
|
-
if (!lazy.value) {
|
|
56
|
-
emits("resize", index, pxSizes.value);
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
const onResizeEnd = async (index) => {
|
|
60
|
-
onMoveEnd();
|
|
61
|
-
await nextTick();
|
|
62
|
-
emits("resizeEnd", index, pxSizes.value);
|
|
63
|
-
};
|
|
64
|
-
const onCollapsible = (index, type) => {
|
|
65
|
-
onCollapse(index, type);
|
|
66
|
-
emits("collapse", index, type, pxSizes.value);
|
|
67
|
-
};
|
|
68
|
-
provide(splitterRootContextKey, reactive({
|
|
69
|
-
panels,
|
|
70
|
-
percentSizes,
|
|
71
|
-
pxSizes,
|
|
72
|
-
layout,
|
|
73
|
-
lazy,
|
|
74
|
-
movingIndex,
|
|
75
|
-
containerSize,
|
|
76
|
-
onMoveStart: onResizeStart,
|
|
77
|
-
onMoving: onResize,
|
|
78
|
-
onMoveEnd: onResizeEnd,
|
|
79
|
-
onCollapse: onCollapsible,
|
|
80
|
-
registerPanel,
|
|
81
|
-
unregisterPanel
|
|
82
|
-
}));
|
|
83
|
-
return (_ctx, _cache) => {
|
|
84
|
-
return openBlock(), createElementBlock("div", {
|
|
85
|
-
ref_key: "containerEl",
|
|
86
|
-
ref: containerEl,
|
|
87
|
-
class: normalizeClass([unref(ns).b(), unref(ns).e(unref(layout))]),
|
|
88
|
-
style: normalizeStyle(unref(splitterStyles))
|
|
89
|
-
}, [
|
|
90
|
-
renderSlot(_ctx.$slots, "default"),
|
|
91
|
-
createVNode(unref(PanelsSorter)),
|
|
92
|
-
createCommentVNode(" Prevent iframe touch events from breaking "),
|
|
93
|
-
unref(movingIndex) ? (openBlock(), createElementBlock("div", {
|
|
94
|
-
key: 0,
|
|
95
|
-
class: normalizeClass([unref(ns).e("mask"), unref(ns).e(`mask-${unref(layout)}`)])
|
|
96
|
-
}, null, 2)) : createCommentVNode("v-if", true)
|
|
97
|
-
], 6);
|
|
98
|
-
};
|
|
99
|
-
}
|
|
100
|
-
});
|
|
101
|
-
var Splitter = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "splitter.vue"]]);
|
|
11
|
+
const splitterEmits = {
|
|
12
|
+
resizeStart: (index, sizes) => true,
|
|
13
|
+
resize: (index, sizes) => true,
|
|
14
|
+
resizeEnd: (index, sizes) => true,
|
|
15
|
+
collapse: (index, type, sizes) => true
|
|
16
|
+
};
|
|
102
17
|
|
|
103
|
-
export {
|
|
18
|
+
export { splitterEmits, splitterProps };
|
|
104
19
|
//# sourceMappingURL=splitter.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"splitter.mjs","sources":["../../../../../../packages/components/splitter/src/splitter.
|
|
1
|
+
{"version":3,"file":"splitter.mjs","sources":["../../../../../../packages/components/splitter/src/splitter.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type Splitter from './splitter.vue'\n\nexport const splitterProps = buildProps({\n layout: {\n type: String,\n default: 'horizontal',\n values: ['horizontal', 'vertical'] as const,\n },\n lazy: Boolean,\n} as const)\n\nexport type SplitterProps = ExtractPropTypes<typeof splitterProps>\nexport type SplitterPropsPublic = __ExtractPublicPropTypes<typeof splitterProps>\nexport type SplitterInstance = InstanceType<typeof Splitter> & unknown\n\n/* eslint-disable @typescript-eslint/no-unused-vars */\nexport const splitterEmits = {\n resizeStart: (index: number, sizes: number[]) => true,\n resize: (index: number, sizes: number[]) => true,\n resizeEnd: (index: number, sizes: number[]) => true,\n collapse: (index: number, type: 'start' | 'end', sizes: number[]) => true,\n}\n/* eslint-enable @typescript-eslint/no-unused-vars */\n\nexport type SplitterEmits = typeof splitterEmits\n"],"names":[],"mappings":";;AACY,MAAC,aAAa,GAAG,UAAU,CAAC;AACxC,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,YAAY;AACzB,IAAI,MAAM,EAAE,CAAC,YAAY,EAAE,UAAU,CAAC;AACtC,GAAG;AACH,EAAE,IAAI,EAAE,OAAO;AACf,CAAC,EAAE;AACS,MAAC,aAAa,GAAG;AAC7B,EAAE,WAAW,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI;AACrC,EAAE,MAAM,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI;AAChC,EAAE,SAAS,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI;AACnC,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,KAAK,IAAI;AACxC;;;;"}
|
|
@@ -1,19 +1,105 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { defineComponent, toRef, getCurrentInstance, watch, computed, provide, reactive, openBlock, createElementBlock, normalizeClass, unref, normalizeStyle, renderSlot, createVNode, createCommentVNode, nextTick } from 'vue';
|
|
2
|
+
import { splitterProps, splitterEmits } from './splitter.mjs';
|
|
3
|
+
import { splitterRootContextKey } from './type.mjs';
|
|
4
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
5
|
+
import { useContainer } from './hooks/useContainer.mjs';
|
|
6
|
+
import { useSize } from './hooks/useSize.mjs';
|
|
7
|
+
import { useResize } from './hooks/useResize.mjs';
|
|
8
|
+
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
9
|
+
import { useOrderedChildren } from '../../../hooks/use-ordered-children/index.mjs';
|
|
2
10
|
|
|
3
|
-
const
|
|
4
|
-
|
|
5
|
-
type: String,
|
|
6
|
-
default: "horizontal",
|
|
7
|
-
values: ["horizontal", "vertical"]
|
|
8
|
-
},
|
|
9
|
-
lazy: Boolean
|
|
11
|
+
const __default__ = defineComponent({
|
|
12
|
+
name: "ElSplitter"
|
|
10
13
|
});
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
15
|
+
...__default__,
|
|
16
|
+
props: splitterProps,
|
|
17
|
+
emits: splitterEmits,
|
|
18
|
+
setup(__props, { emit: emits }) {
|
|
19
|
+
const props = __props;
|
|
20
|
+
const ns = useNamespace("splitter");
|
|
21
|
+
const layout = toRef(props, "layout");
|
|
22
|
+
const lazy = toRef(props, "lazy");
|
|
23
|
+
const { containerEl, containerSize } = useContainer(layout);
|
|
24
|
+
const {
|
|
25
|
+
removeChild: unregisterPanel,
|
|
26
|
+
children: panels,
|
|
27
|
+
addChild: registerPanel,
|
|
28
|
+
ChildrenSorter: PanelsSorter
|
|
29
|
+
} = useOrderedChildren(getCurrentInstance(), "ElSplitterPanel");
|
|
30
|
+
watch(panels, () => {
|
|
31
|
+
movingIndex.value = null;
|
|
32
|
+
panels.value.forEach((instance, index) => {
|
|
33
|
+
instance.setIndex(index);
|
|
34
|
+
});
|
|
35
|
+
});
|
|
36
|
+
const { percentSizes, pxSizes } = useSize(panels, containerSize);
|
|
37
|
+
const {
|
|
38
|
+
lazyOffset,
|
|
39
|
+
movingIndex,
|
|
40
|
+
onMoveStart,
|
|
41
|
+
onMoving,
|
|
42
|
+
onMoveEnd,
|
|
43
|
+
onCollapse
|
|
44
|
+
} = useResize(panels, containerSize, pxSizes, lazy);
|
|
45
|
+
const splitterStyles = computed(() => {
|
|
46
|
+
return {
|
|
47
|
+
[ns.cssVarBlockName("bar-offset")]: lazy.value ? `${lazyOffset.value}px` : void 0
|
|
48
|
+
};
|
|
49
|
+
});
|
|
50
|
+
const onResizeStart = (index) => {
|
|
51
|
+
onMoveStart(index);
|
|
52
|
+
emits("resizeStart", index, pxSizes.value);
|
|
53
|
+
};
|
|
54
|
+
const onResize = (index, offset) => {
|
|
55
|
+
onMoving(index, offset);
|
|
56
|
+
if (!lazy.value) {
|
|
57
|
+
emits("resize", index, pxSizes.value);
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
const onResizeEnd = async (index) => {
|
|
61
|
+
onMoveEnd();
|
|
62
|
+
await nextTick();
|
|
63
|
+
emits("resizeEnd", index, pxSizes.value);
|
|
64
|
+
};
|
|
65
|
+
const onCollapsible = (index, type) => {
|
|
66
|
+
onCollapse(index, type);
|
|
67
|
+
emits("collapse", index, type, pxSizes.value);
|
|
68
|
+
};
|
|
69
|
+
provide(splitterRootContextKey, reactive({
|
|
70
|
+
panels,
|
|
71
|
+
percentSizes,
|
|
72
|
+
pxSizes,
|
|
73
|
+
layout,
|
|
74
|
+
lazy,
|
|
75
|
+
movingIndex,
|
|
76
|
+
containerSize,
|
|
77
|
+
onMoveStart: onResizeStart,
|
|
78
|
+
onMoving: onResize,
|
|
79
|
+
onMoveEnd: onResizeEnd,
|
|
80
|
+
onCollapse: onCollapsible,
|
|
81
|
+
registerPanel,
|
|
82
|
+
unregisterPanel
|
|
83
|
+
}));
|
|
84
|
+
return (_ctx, _cache) => {
|
|
85
|
+
return openBlock(), createElementBlock("div", {
|
|
86
|
+
ref_key: "containerEl",
|
|
87
|
+
ref: containerEl,
|
|
88
|
+
class: normalizeClass([unref(ns).b(), unref(ns).e(unref(layout))]),
|
|
89
|
+
style: normalizeStyle(unref(splitterStyles))
|
|
90
|
+
}, [
|
|
91
|
+
renderSlot(_ctx.$slots, "default"),
|
|
92
|
+
createVNode(unref(PanelsSorter)),
|
|
93
|
+
createCommentVNode(" Prevent iframe touch events from breaking "),
|
|
94
|
+
unref(movingIndex) ? (openBlock(), createElementBlock("div", {
|
|
95
|
+
key: 0,
|
|
96
|
+
class: normalizeClass([unref(ns).e("mask"), unref(ns).e(`mask-${unref(layout)}`)])
|
|
97
|
+
}, null, 2)) : createCommentVNode("v-if", true)
|
|
98
|
+
], 6);
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
});
|
|
102
|
+
var Splitter = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "splitter.vue"]]);
|
|
17
103
|
|
|
18
|
-
export {
|
|
104
|
+
export { Splitter as default };
|
|
19
105
|
//# sourceMappingURL=splitter2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"splitter2.mjs","sources":["../../../../../../packages/components/splitter/src/splitter.
|
|
1
|
+
{"version":3,"file":"splitter2.mjs","sources":["../../../../../../packages/components/splitter/src/splitter.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport {\n computed,\n getCurrentInstance,\n nextTick,\n provide,\n reactive,\n toRef,\n watch,\n} from 'vue'\nimport { useNamespace, useOrderedChildren } from '@element-plus/hooks'\nimport { useContainer, useResize, useSize } from './hooks'\nimport { splitterEmits, splitterProps } from './splitter'\nimport { splitterRootContextKey } from './type'\n\nimport type { PanelItemState } from './type'\n\nconst ns = useNamespace('splitter')\n\ndefineOptions({\n name: 'ElSplitter',\n})\n\nconst emits = defineEmits(splitterEmits)\n\nconst props = defineProps(splitterProps)\nconst layout = toRef(props, 'layout')\nconst lazy = toRef(props, 'lazy')\n\nconst { containerEl, containerSize } = useContainer(layout)\n\nconst {\n removeChild: unregisterPanel,\n children: panels,\n addChild: registerPanel,\n ChildrenSorter: PanelsSorter,\n} = useOrderedChildren<PanelItemState>(getCurrentInstance()!, 'ElSplitterPanel')\n\nwatch(panels, () => {\n movingIndex.value = null\n panels.value.forEach((instance: PanelItemState, index: number) => {\n instance.setIndex(index)\n })\n})\n\nconst { percentSizes, pxSizes } = useSize(panels, containerSize)\n\nconst {\n lazyOffset,\n movingIndex,\n onMoveStart,\n onMoving,\n onMoveEnd,\n onCollapse,\n} = useResize(panels, containerSize, pxSizes, lazy)\n\nconst splitterStyles = computed(() => {\n return {\n [ns.cssVarBlockName('bar-offset')]: lazy.value\n ? `${lazyOffset.value}px`\n : undefined,\n }\n})\n\nconst onResizeStart = (index: number) => {\n onMoveStart(index)\n emits('resizeStart', index, pxSizes.value)\n}\n\nconst onResize = (index: number, offset: number) => {\n onMoving(index, offset)\n\n if (!lazy.value) {\n emits('resize', index, pxSizes.value)\n }\n}\n\nconst onResizeEnd = async (index: number) => {\n onMoveEnd()\n await nextTick()\n emits('resizeEnd', index, pxSizes.value)\n}\n\nconst onCollapsible = (index: number, type: 'start' | 'end') => {\n onCollapse(index, type)\n emits('collapse', index, type, pxSizes.value)\n}\n\nprovide(\n splitterRootContextKey,\n reactive({\n panels,\n percentSizes,\n pxSizes,\n layout,\n lazy,\n movingIndex,\n containerSize,\n onMoveStart: onResizeStart,\n onMoving: onResize,\n onMoveEnd: onResizeEnd,\n onCollapse: onCollapsible,\n registerPanel,\n unregisterPanel,\n })\n)\n</script>\n\n<template>\n <div\n ref=\"containerEl\"\n :class=\"[ns.b(), ns.e(layout)]\"\n :style=\"splitterStyles\"\n >\n <slot />\n <panels-sorter />\n <!-- Prevent iframe touch events from breaking -->\n <div v-if=\"movingIndex\" :class=\"[ns.e('mask'), ns.e(`mask-${layout}`)]\" />\n </div>\n</template>\n"],"names":["_openBlock","_createElementBlock"],"mappings":";;;;;;;;;;mCAmBc,CAAA;AAAA,EACZ,IAAM,EAAA,YAAA;AACR,CAAA,CAAA,CAAA;;;;;;;AAJA,IAAM,MAAA,EAAA,GAAK,aAAa,UAAU,CAAA,CAAA;AASlC,IAAM,MAAA,MAAA,GAAS,KAAM,CAAA,KAAA,EAAO,QAAQ,CAAA,CAAA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SAAA,EAAA,EAAAC,kBAAA,CAAA,KAAA,EAAA;AAAA,QACH,OAAA,EAAA,aAAA;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CSSProperties, ComponentInternalInstance, PropType, Ref, VNode } from 'vue';
|
|
1
|
+
import type { CSSProperties, ComponentInternalInstance, PropType, Ref, StyleValue, VNode } from 'vue';
|
|
2
2
|
import type { ComponentSize } from '@element-plus/nightly/es/constants';
|
|
3
3
|
import type { Nullable } from '@element-plus/nightly/es/utils';
|
|
4
4
|
import type { Store } from '../store';
|
|
@@ -123,7 +123,7 @@ interface TableProps<T extends DefaultRow> {
|
|
|
123
123
|
lazy?: boolean;
|
|
124
124
|
load?: (row: T, treeNode: TreeNode, resolve: (data: T[]) => void) => void;
|
|
125
125
|
className?: string;
|
|
126
|
-
style?:
|
|
126
|
+
style?: StyleValue;
|
|
127
127
|
tableLayout?: Layout;
|
|
128
128
|
scrollbarAlwaysOn?: boolean;
|
|
129
129
|
flexible?: boolean;
|
|
@@ -330,7 +330,7 @@ declare const _default: {
|
|
|
330
330
|
*/
|
|
331
331
|
load: PropType<TableProps<any>["load"]>;
|
|
332
332
|
style: {
|
|
333
|
-
type: PropType<
|
|
333
|
+
type: PropType<TableProps<any>["style"]>;
|
|
334
334
|
default: () => {};
|
|
335
335
|
};
|
|
336
336
|
className: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defaults.mjs","sources":["../../../../../../../packages/components/table/src/table/defaults.ts"],"sourcesContent":["import { useSizeProp } from '@element-plus/hooks'\n\nimport type {\n CSSProperties,\n ComponentInternalInstance,\n PropType,\n Ref,\n VNode,\n} from 'vue'\nimport type { ComponentSize } from '@element-plus/constants'\nimport type { Nullable } from '@element-plus/utils'\nimport type { Store } from '../store'\nimport type { TableColumnCtx } from '../table-column/defaults'\nimport type TableLayout from '../table-layout'\nimport type {\n TableOverflowTooltipFormatter,\n TableOverflowTooltipOptions,\n} from '../util'\n\ntype DefaultRow = Record<PropertyKey, any>\n\ninterface TableRefs {\n tableWrapper: HTMLElement\n headerWrapper: HTMLElement\n footerWrapper: HTMLElement\n fixedBodyWrapper: HTMLElement\n rightFixedBodyWrapper: HTMLElement\n bodyWrapper: HTMLElement\n appendWrapper: HTMLElement\n [key: string]: any\n}\n\ninterface TableState {\n isGroup: Ref<boolean>\n resizeState: Ref<{\n width: any\n height: any\n }>\n doLayout: () => void\n debouncedUpdateLayout: () => void\n}\n\ninterface TreeProps {\n hasChildren?: string\n children?: string\n checkStrictly?: boolean\n}\n\ntype HoverState<T extends DefaultRow> = Nullable<{\n cell: HTMLElement\n column: TableColumnCtx<T>\n row: T\n}>\n\ntype RIS<T extends DefaultRow> = {\n row: T\n $index: number\n store: Store<T>\n expanded: boolean\n}\n\ntype RenderExpanded<T extends DefaultRow> = ({\n row,\n $index,\n store,\n expanded,\n}: RIS<T>) => VNode[] | undefined\n\ntype SummaryMethod<T extends DefaultRow> = (data: {\n columns: TableColumnCtx<T>[]\n data: T[]\n}) => (string | VNode)[]\n\ninterface Table<T extends DefaultRow = any> extends ComponentInternalInstance {\n $ready: boolean\n hoverState?: HoverState<T> | null\n renderExpanded: RenderExpanded<T>\n store: Store<T>\n layout: TableLayout<T>\n refs: TableRefs\n tableId: string\n state: TableState\n}\n\ntype ColumnCls<T> = string | ((data: { row: T; rowIndex: number }) => string)\ntype ColumnStyle<T> =\n | CSSProperties\n | ((data: { row: T; rowIndex: number }) => CSSProperties)\ntype CellCls<T extends DefaultRow> =\n | string\n | ((data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) => string)\ntype CellStyle<T extends DefaultRow> =\n | CSSProperties\n | ((data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) => CSSProperties)\ntype Layout = 'fixed' | 'auto'\ninterface TableProps<T extends DefaultRow> {\n data: T[]\n size?: ComponentSize\n width?: string | number\n height?: string | number\n maxHeight?: string | number\n fit?: boolean\n stripe?: boolean\n border?: boolean\n rowKey?: string | ((row: T) => string)\n context?: Table<T>\n showHeader?: boolean\n showSummary?: boolean\n sumText?: string\n summaryMethod?: SummaryMethod<T>\n rowClassName?: ColumnCls<T>\n rowStyle?: ColumnStyle<T>\n cellClassName?: CellCls<T>\n cellStyle?: CellStyle<T>\n headerRowClassName?: ColumnCls<T>\n headerRowStyle?: ColumnStyle<T>\n headerCellClassName?: CellCls<T>\n headerCellStyle?: CellStyle<T>\n highlightCurrentRow?: boolean\n currentRowKey?: string | number\n emptyText?: string\n expandRowKeys?: Array<string>\n defaultExpandAll?: boolean\n defaultSort?: Sort\n tooltipEffect?: string\n tooltipOptions?: TableOverflowTooltipOptions\n spanMethod?: (data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) =>\n | number[]\n | {\n rowspan: number\n colspan: number\n }\n | undefined\n selectOnIndeterminate?: boolean\n indent?: number\n treeProps?: TreeProps\n lazy?: boolean\n load?: (row: T, treeNode: TreeNode, resolve: (data: T[]) => void) => void\n className?: string\n style?: CSSProperties\n tableLayout?: Layout\n scrollbarAlwaysOn?: boolean\n flexible?: boolean\n showOverflowTooltip?: boolean | TableOverflowTooltipOptions\n tooltipFormatter?: TableOverflowTooltipFormatter<T>\n appendFilterPanelTo?: string\n scrollbarTabindex?: number | string\n nativeScrollbar?: boolean\n}\n\ntype TableTooltipData<T extends DefaultRow> = Parameters<\n TableOverflowTooltipFormatter<T>\n>[0]\ntype TableSortOrder = 'ascending' | 'descending'\n\ninterface Sort {\n prop: string\n order: TableSortOrder\n init?: any\n silent?: any\n}\n\ninterface Filter<T extends DefaultRow> {\n column: TableColumnCtx<T>\n values: string[]\n silent: any\n}\n\ninterface TreeNode {\n expanded?: boolean\n loading?: boolean\n noLazyChildren?: boolean\n indent?: number\n level?: number\n display?: boolean\n}\n\ninterface RenderRowData<T extends DefaultRow> {\n store: Store<T>\n _self: Table<T>\n column: TableColumnCtx<T>\n row: T\n $index: number\n cellIndex: number\n treeNode?: TreeNode\n expanded: boolean\n}\n\nexport default {\n /**\n * @description table data\n */\n data: {\n type: Array as PropType<any[]>,\n default: () => [],\n },\n /**\n * @description size of Table\n */\n size: useSizeProp,\n width: [String, Number],\n /**\n * @description table's height. By default it has an `auto` height. If its value is a number, the height is measured in pixels; if its value is a string, the value will be assigned to element's style.height, the height is affected by external styles\n */\n height: [String, Number],\n /**\n * @description table's max-height. The legal value is a number or the height in px\n */\n maxHeight: [String, Number],\n /**\n * @description whether width of column automatically fits its container\n */\n fit: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether Table is striped\n */\n stripe: Boolean,\n /**\n * @description whether Table has vertical border\n */\n border: Boolean,\n /**\n * @description key of row data, used for optimizing rendering. Required if `reserve-selection` is on or display tree data. When its type is String, multi-level access is supported, e.g. `user.info.id`, but `user.info[0].id` is not supported, in which case `Function` should be used\n */\n rowKey: [String, Function] as PropType<TableProps<any>['rowKey']>,\n /**\n * @description whether Table header is visible\n */\n showHeader: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether to display a summary row\n */\n showSummary: Boolean,\n /**\n * @description displayed text for the first column of summary row\n */\n sumText: String,\n /**\n * @description custom summary method\n */\n summaryMethod: Function as PropType<TableProps<any>['summaryMethod']>,\n /**\n * @description function that returns custom class names for a row, or a string assigning class names for every row\n */\n rowClassName: [String, Function] as PropType<TableProps<any>['rowClassName']>,\n /**\n * @description function that returns custom style for a row, or an object assigning custom style for every row\n */\n rowStyle: [Object, Function] as PropType<TableProps<any>['rowStyle']>,\n /**\n * @description function that returns custom class names for a cell, or a string assigning class names for every cell\n */\n cellClassName: [String, Function] as PropType<\n TableProps<any>['cellClassName']\n >,\n /**\n * @description function that returns custom style for a cell, or an object assigning custom style for every cell\n */\n cellStyle: [Object, Function] as PropType<TableProps<any>['cellStyle']>,\n /**\n * @description function that returns custom class names for a row in table header, or a string assigning class names for every row in table header\n */\n headerRowClassName: [String, Function] as PropType<\n TableProps<any>['headerRowClassName']\n >,\n /**\n * @description function that returns custom style for a row in table header, or an object assigning custom style for every row in table header\n */\n headerRowStyle: [Object, Function] as PropType<\n TableProps<any>['headerRowStyle']\n >,\n /**\n * @description function that returns custom class names for a cell in table header, or a string assigning class names for every cell in table header\n */\n headerCellClassName: [String, Function] as PropType<\n TableProps<any>['headerCellClassName']\n >,\n /**\n * @description function that returns custom style for a cell in table header, or an object assigning custom style for every cell in table header\n */\n headerCellStyle: [Object, Function] as PropType<\n TableProps<any>['headerCellStyle']\n >,\n /**\n * @description whether current row is highlighted\n */\n highlightCurrentRow: Boolean,\n /**\n * @description key of current row, a set only prop\n */\n currentRowKey: [String, Number],\n /**\n * @description displayed text when data is empty. You can customize this area with `#empty`\n */\n emptyText: String,\n /**\n * @description set expanded rows by this prop, prop's value is the keys of expand rows, you should set row-key before using this prop\n */\n expandRowKeys: Array as PropType<TableProps<any>['expandRowKeys']>,\n /**\n * @description whether expand all rows by default, works when the table has a column type=\"expand\" or contains tree structure data\n */\n defaultExpandAll: Boolean,\n /**\n * @description set the default sort column and order. property `prop` is used to set default sort column, property `order` is used to set default sort order\n */\n defaultSort: Object as PropType<TableProps<any>['defaultSort']>,\n /**\n * @description the `effect` of the overflow tooltip\n */\n tooltipEffect: String,\n /**\n * @description the options for the overflow tooltip, [see the following tooltip component](tooltip.html#attributes)\n */\n tooltipOptions: Object as PropType<TableProps<any>['tooltipOptions']>,\n /**\n * @description method that returns rowspan and colspan\n */\n spanMethod: Function as PropType<TableProps<any>['spanMethod']>,\n /**\n * @description controls the behavior of master checkbox in multi-select tables when only some rows are selected (but not all). If true, all rows will be selected, else deselected\n */\n selectOnIndeterminate: {\n type: Boolean,\n default: true,\n },\n /**\n * @description horizontal indentation of tree data\n */\n indent: {\n type: Number,\n default: 16,\n },\n /**\n * @description configuration for rendering nested data\n */\n treeProps: {\n type: Object as PropType<TableProps<any>['treeProps']>,\n default: () => {\n return {\n hasChildren: 'hasChildren',\n children: 'children',\n checkStrictly: false,\n }\n },\n },\n /**\n * @description whether to lazy loading data\n */\n lazy: Boolean,\n /**\n * @description method for loading child row data, only works when `lazy` is true\n */\n load: Function as PropType<TableProps<any>['load']>,\n style: {\n type: Object as PropType<CSSProperties>,\n default: () => ({}),\n },\n className: {\n type: String,\n default: '',\n },\n /**\n * @description sets the algorithm used to lay out table cells, rows, and columns\n */\n tableLayout: {\n type: String as PropType<Layout>,\n default: 'fixed',\n },\n /**\n * @description always show scrollbar\n */\n scrollbarAlwaysOn: Boolean,\n /**\n * @description ensure main axis minimum-size doesn't follow the content\n */\n flexible: Boolean,\n /**\n * @description whether to hide extra content and show them in a tooltip when hovering on the cell.It will affect all the table columns\n */\n showOverflowTooltip: [Boolean, Object] as PropType<\n TableProps<any>['showOverflowTooltip']\n >,\n /**\n * @description function that formats cell tooltip content, works when `show-overflow-tooltip` is `true`\n */\n tooltipFormatter: Function as PropType<TableProps<any>['tooltipFormatter']>,\n appendFilterPanelTo: String,\n scrollbarTabindex: {\n type: [Number, String],\n default: undefined,\n },\n /**\n * @description whether to allow drag the last column\n */\n allowDragLastColumn: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether to preserve expanded row content in DOM when collapsed\n */\n preserveExpandedContent: Boolean,\n /**\n * @description whether to use native scrollbars\n */\n nativeScrollbar: Boolean,\n}\nexport type {\n SummaryMethod,\n Table,\n TableProps,\n TableRefs,\n ColumnCls,\n ColumnStyle,\n CellCls,\n CellStyle,\n DefaultRow,\n TreeNode,\n RenderRowData,\n Sort,\n Filter,\n TableColumnCtx,\n TreeProps,\n TableTooltipData,\n TableSortOrder,\n RenderExpanded,\n}\n"],"names":[],"mappings":";;AACA,mBAAe;AACf,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,KAAK;AACf,IAAI,OAAO,EAAE,MAAM,EAAE;AACrB,GAAG;AACH,EAAE,IAAI,EAAE,WAAW;AACnB,EAAE,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AACzB,EAAE,MAAM,EAAE,CAAC,MA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AE,eAAe,EAAE,OAAO;AAC1B,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"defaults.mjs","sources":["../../../../../../../packages/components/table/src/table/defaults.ts"],"sourcesContent":["import { useSizeProp } from '@element-plus/hooks'\n\nimport type {\n CSSProperties,\n ComponentInternalInstance,\n PropType,\n Ref,\n StyleValue,\n VNode,\n} from 'vue'\nimport type { ComponentSize } from '@element-plus/constants'\nimport type { Nullable } from '@element-plus/utils'\nimport type { Store } from '../store'\nimport type { TableColumnCtx } from '../table-column/defaults'\nimport type TableLayout from '../table-layout'\nimport type {\n TableOverflowTooltipFormatter,\n TableOverflowTooltipOptions,\n} from '../util'\n\ntype DefaultRow = Record<PropertyKey, any>\n\ninterface TableRefs {\n tableWrapper: HTMLElement\n headerWrapper: HTMLElement\n footerWrapper: HTMLElement\n fixedBodyWrapper: HTMLElement\n rightFixedBodyWrapper: HTMLElement\n bodyWrapper: HTMLElement\n appendWrapper: HTMLElement\n [key: string]: any\n}\n\ninterface TableState {\n isGroup: Ref<boolean>\n resizeState: Ref<{\n width: any\n height: any\n }>\n doLayout: () => void\n debouncedUpdateLayout: () => void\n}\n\ninterface TreeProps {\n hasChildren?: string\n children?: string\n checkStrictly?: boolean\n}\n\ntype HoverState<T extends DefaultRow> = Nullable<{\n cell: HTMLElement\n column: TableColumnCtx<T>\n row: T\n}>\n\ntype RIS<T extends DefaultRow> = {\n row: T\n $index: number\n store: Store<T>\n expanded: boolean\n}\n\ntype RenderExpanded<T extends DefaultRow> = ({\n row,\n $index,\n store,\n expanded,\n}: RIS<T>) => VNode[] | undefined\n\ntype SummaryMethod<T extends DefaultRow> = (data: {\n columns: TableColumnCtx<T>[]\n data: T[]\n}) => (string | VNode)[]\n\ninterface Table<T extends DefaultRow = any> extends ComponentInternalInstance {\n $ready: boolean\n hoverState?: HoverState<T> | null\n renderExpanded: RenderExpanded<T>\n store: Store<T>\n layout: TableLayout<T>\n refs: TableRefs\n tableId: string\n state: TableState\n}\n\ntype ColumnCls<T> = string | ((data: { row: T; rowIndex: number }) => string)\ntype ColumnStyle<T> =\n | CSSProperties\n | ((data: { row: T; rowIndex: number }) => CSSProperties)\ntype CellCls<T extends DefaultRow> =\n | string\n | ((data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) => string)\ntype CellStyle<T extends DefaultRow> =\n | CSSProperties\n | ((data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) => CSSProperties)\ntype Layout = 'fixed' | 'auto'\ninterface TableProps<T extends DefaultRow> {\n data: T[]\n size?: ComponentSize\n width?: string | number\n height?: string | number\n maxHeight?: string | number\n fit?: boolean\n stripe?: boolean\n border?: boolean\n rowKey?: string | ((row: T) => string)\n context?: Table<T>\n showHeader?: boolean\n showSummary?: boolean\n sumText?: string\n summaryMethod?: SummaryMethod<T>\n rowClassName?: ColumnCls<T>\n rowStyle?: ColumnStyle<T>\n cellClassName?: CellCls<T>\n cellStyle?: CellStyle<T>\n headerRowClassName?: ColumnCls<T>\n headerRowStyle?: ColumnStyle<T>\n headerCellClassName?: CellCls<T>\n headerCellStyle?: CellStyle<T>\n highlightCurrentRow?: boolean\n currentRowKey?: string | number\n emptyText?: string\n expandRowKeys?: Array<string>\n defaultExpandAll?: boolean\n defaultSort?: Sort\n tooltipEffect?: string\n tooltipOptions?: TableOverflowTooltipOptions\n spanMethod?: (data: {\n row: T\n rowIndex: number\n column: TableColumnCtx<T>\n columnIndex: number\n }) =>\n | number[]\n | {\n rowspan: number\n colspan: number\n }\n | undefined\n selectOnIndeterminate?: boolean\n indent?: number\n treeProps?: TreeProps\n lazy?: boolean\n load?: (row: T, treeNode: TreeNode, resolve: (data: T[]) => void) => void\n className?: string\n style?: StyleValue\n tableLayout?: Layout\n scrollbarAlwaysOn?: boolean\n flexible?: boolean\n showOverflowTooltip?: boolean | TableOverflowTooltipOptions\n tooltipFormatter?: TableOverflowTooltipFormatter<T>\n appendFilterPanelTo?: string\n scrollbarTabindex?: number | string\n nativeScrollbar?: boolean\n}\n\ntype TableTooltipData<T extends DefaultRow> = Parameters<\n TableOverflowTooltipFormatter<T>\n>[0]\ntype TableSortOrder = 'ascending' | 'descending'\n\ninterface Sort {\n prop: string\n order: TableSortOrder\n init?: any\n silent?: any\n}\n\ninterface Filter<T extends DefaultRow> {\n column: TableColumnCtx<T>\n values: string[]\n silent: any\n}\n\ninterface TreeNode {\n expanded?: boolean\n loading?: boolean\n noLazyChildren?: boolean\n indent?: number\n level?: number\n display?: boolean\n}\n\ninterface RenderRowData<T extends DefaultRow> {\n store: Store<T>\n _self: Table<T>\n column: TableColumnCtx<T>\n row: T\n $index: number\n cellIndex: number\n treeNode?: TreeNode\n expanded: boolean\n}\n\nexport default {\n /**\n * @description table data\n */\n data: {\n type: Array as PropType<any[]>,\n default: () => [],\n },\n /**\n * @description size of Table\n */\n size: useSizeProp,\n width: [String, Number],\n /**\n * @description table's height. By default it has an `auto` height. If its value is a number, the height is measured in pixels; if its value is a string, the value will be assigned to element's style.height, the height is affected by external styles\n */\n height: [String, Number],\n /**\n * @description table's max-height. The legal value is a number or the height in px\n */\n maxHeight: [String, Number],\n /**\n * @description whether width of column automatically fits its container\n */\n fit: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether Table is striped\n */\n stripe: Boolean,\n /**\n * @description whether Table has vertical border\n */\n border: Boolean,\n /**\n * @description key of row data, used for optimizing rendering. Required if `reserve-selection` is on or display tree data. When its type is String, multi-level access is supported, e.g. `user.info.id`, but `user.info[0].id` is not supported, in which case `Function` should be used\n */\n rowKey: [String, Function] as PropType<TableProps<any>['rowKey']>,\n /**\n * @description whether Table header is visible\n */\n showHeader: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether to display a summary row\n */\n showSummary: Boolean,\n /**\n * @description displayed text for the first column of summary row\n */\n sumText: String,\n /**\n * @description custom summary method\n */\n summaryMethod: Function as PropType<TableProps<any>['summaryMethod']>,\n /**\n * @description function that returns custom class names for a row, or a string assigning class names for every row\n */\n rowClassName: [String, Function] as PropType<TableProps<any>['rowClassName']>,\n /**\n * @description function that returns custom style for a row, or an object assigning custom style for every row\n */\n rowStyle: [Object, Function] as PropType<TableProps<any>['rowStyle']>,\n /**\n * @description function that returns custom class names for a cell, or a string assigning class names for every cell\n */\n cellClassName: [String, Function] as PropType<\n TableProps<any>['cellClassName']\n >,\n /**\n * @description function that returns custom style for a cell, or an object assigning custom style for every cell\n */\n cellStyle: [Object, Function] as PropType<TableProps<any>['cellStyle']>,\n /**\n * @description function that returns custom class names for a row in table header, or a string assigning class names for every row in table header\n */\n headerRowClassName: [String, Function] as PropType<\n TableProps<any>['headerRowClassName']\n >,\n /**\n * @description function that returns custom style for a row in table header, or an object assigning custom style for every row in table header\n */\n headerRowStyle: [Object, Function] as PropType<\n TableProps<any>['headerRowStyle']\n >,\n /**\n * @description function that returns custom class names for a cell in table header, or a string assigning class names for every cell in table header\n */\n headerCellClassName: [String, Function] as PropType<\n TableProps<any>['headerCellClassName']\n >,\n /**\n * @description function that returns custom style for a cell in table header, or an object assigning custom style for every cell in table header\n */\n headerCellStyle: [Object, Function] as PropType<\n TableProps<any>['headerCellStyle']\n >,\n /**\n * @description whether current row is highlighted\n */\n highlightCurrentRow: Boolean,\n /**\n * @description key of current row, a set only prop\n */\n currentRowKey: [String, Number],\n /**\n * @description displayed text when data is empty. You can customize this area with `#empty`\n */\n emptyText: String,\n /**\n * @description set expanded rows by this prop, prop's value is the keys of expand rows, you should set row-key before using this prop\n */\n expandRowKeys: Array as PropType<TableProps<any>['expandRowKeys']>,\n /**\n * @description whether expand all rows by default, works when the table has a column type=\"expand\" or contains tree structure data\n */\n defaultExpandAll: Boolean,\n /**\n * @description set the default sort column and order. property `prop` is used to set default sort column, property `order` is used to set default sort order\n */\n defaultSort: Object as PropType<TableProps<any>['defaultSort']>,\n /**\n * @description the `effect` of the overflow tooltip\n */\n tooltipEffect: String,\n /**\n * @description the options for the overflow tooltip, [see the following tooltip component](tooltip.html#attributes)\n */\n tooltipOptions: Object as PropType<TableProps<any>['tooltipOptions']>,\n /**\n * @description method that returns rowspan and colspan\n */\n spanMethod: Function as PropType<TableProps<any>['spanMethod']>,\n /**\n * @description controls the behavior of master checkbox in multi-select tables when only some rows are selected (but not all). If true, all rows will be selected, else deselected\n */\n selectOnIndeterminate: {\n type: Boolean,\n default: true,\n },\n /**\n * @description horizontal indentation of tree data\n */\n indent: {\n type: Number,\n default: 16,\n },\n /**\n * @description configuration for rendering nested data\n */\n treeProps: {\n type: Object as PropType<TableProps<any>['treeProps']>,\n default: () => {\n return {\n hasChildren: 'hasChildren',\n children: 'children',\n checkStrictly: false,\n }\n },\n },\n /**\n * @description whether to lazy loading data\n */\n lazy: Boolean,\n /**\n * @description method for loading child row data, only works when `lazy` is true\n */\n load: Function as PropType<TableProps<any>['load']>,\n style: {\n type: [String, Object, Array] as PropType<TableProps<any>['style']>,\n default: () => ({}),\n },\n className: {\n type: String,\n default: '',\n },\n /**\n * @description sets the algorithm used to lay out table cells, rows, and columns\n */\n tableLayout: {\n type: String as PropType<Layout>,\n default: 'fixed',\n },\n /**\n * @description always show scrollbar\n */\n scrollbarAlwaysOn: Boolean,\n /**\n * @description ensure main axis minimum-size doesn't follow the content\n */\n flexible: Boolean,\n /**\n * @description whether to hide extra content and show them in a tooltip when hovering on the cell.It will affect all the table columns\n */\n showOverflowTooltip: [Boolean, Object] as PropType<\n TableProps<any>['showOverflowTooltip']\n >,\n /**\n * @description function that formats cell tooltip content, works when `show-overflow-tooltip` is `true`\n */\n tooltipFormatter: Function as PropType<TableProps<any>['tooltipFormatter']>,\n appendFilterPanelTo: String,\n scrollbarTabindex: {\n type: [Number, String],\n default: undefined,\n },\n /**\n * @description whether to allow drag the last column\n */\n allowDragLastColumn: {\n type: Boolean,\n default: true,\n },\n /**\n * @description whether to preserve expanded row content in DOM when collapsed\n */\n preserveExpandedContent: Boolean,\n /**\n * @description whether to use native scrollbars\n */\n nativeScrollbar: Boolean,\n}\nexport type {\n SummaryMethod,\n Table,\n TableProps,\n TableRefs,\n ColumnCls,\n ColumnStyle,\n CellCls,\n CellStyle,\n DefaultRow,\n TreeNode,\n RenderRowData,\n Sort,\n Filter,\n TableColumnCtx,\n TreeProps,\n TableTooltipData,\n TableSortOrder,\n RenderExpanded,\n}\n"],"names":[],"mappings":";;AACA,mBAAe;AACf,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,KAAK;AACf,IAAI,OAAO,EAAE,MAAM,EAAE;AACrB,GAAG;AACH,EAAE,IAAI,EAAE,WAAW;AACnB,EAAE,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AACzB,EAAE,MAAM,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,EAAE,SAAS,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC7B,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,MAAM,EAAE,OAAO;AACjB,EAAE,MAAM,EAAE,OAAO;AACjB,EAAE,MAAM,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AAC5B,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,WAAW,EAAE,OAAO;AACtB,EAAE,OAAO,EAAE,MAAM;AACjB,EAAE,aAAa,EAAE,QAAQ;AACzB,EAAE,YAAY,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AAClC,EAAE,QAAQ,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AAC9B,EAAE,aAAa,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AACnC,EAAE,SAAS,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AAC/B,EAAE,kBAAkB,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AACxC,EAAE,cAAc,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC;AACp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,EAAE,iBAAiB,EAAE,OAAO;AAC5B,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,mBAAmB,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC;AACxC,EAAE,gBAAgB,EAAE,QAAQ;AAC5B,EAAE,mBAAmB,EAAE,MAAM;AAC7B,EAAE,iBAAiB,EAAE;AACrB,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,IAAI,OAAO,EAAE,KAAK,CAAC;AACnB,GAAG;AACH,EAAE,mBAAmB,EAAE;AACvB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,uBAAuB,EAAE,OAAO;AAClC,EAAE,eAAe,EAAE,OAAO;AAC1B,CAAC;;;;"}
|
|
@@ -64,6 +64,9 @@ function useWatcher(owner, props_) {
|
|
|
64
64
|
if (hasOwn(props_, columnKey)) {
|
|
65
65
|
watch(() => props_[columnKey], (newVal) => {
|
|
66
66
|
instance.columnConfig.value[key] = newVal;
|
|
67
|
+
if (key === "filters" || key === "filterMethod") {
|
|
68
|
+
instance.columnConfig.value["filterable"] = !!(instance.columnConfig.value["filters"] || instance.columnConfig.value["filterMethod"]);
|
|
69
|
+
}
|
|
67
70
|
});
|
|
68
71
|
}
|
|
69
72
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"watcher-helper.mjs","sources":["../../../../../../../packages/components/table/src/table-column/watcher-helper.ts"],"sourcesContent":["import { getCurrentInstance, watch } from 'vue'\nimport { hasOwn } from '@element-plus/utils'\nimport { parseMinWidth, parseWidth } from '../util'\n\nimport type { ComputedRef } from 'vue'\nimport type { DefaultRow } from '../table/defaults'\nimport type { TableColumn, TableColumnCtx, ValueOf } from './defaults'\n\nfunction getAllAliases(props: string[], aliases: Record<string, string>) {\n return props.reduce((prev, cur) => {\n prev[cur as keyof typeof prev] = cur\n return prev\n }, aliases)\n}\nfunction useWatcher<T extends DefaultRow>(\n owner: ComputedRef<any>,\n props_: Partial<TableColumnCtx<T>>\n) {\n const instance = getCurrentInstance() as TableColumn<T>\n const registerComplexWatchers = () => {\n const props = ['fixed']\n const aliases: Record<string, string> = {\n realWidth: 'width',\n realMinWidth: 'minWidth',\n }\n const allAliases = getAllAliases(props, aliases)\n Object.keys(allAliases).forEach((key) => {\n const columnKey = aliases[key]\n if (hasOwn(props_, columnKey)) {\n watch(\n () => props_[columnKey],\n (newVal) => {\n let value: ValueOf<TableColumnCtx<T>> = newVal\n if (columnKey === 'width' && key === 'realWidth') {\n value = parseWidth(newVal)\n }\n if (columnKey === 'minWidth' && key === 'realMinWidth') {\n value = parseMinWidth(newVal)\n }\n instance.columnConfig.value[columnKey as never] = value as never\n instance.columnConfig.value[key as never] = value as never\n const updateColumns = columnKey === 'fixed'\n owner.value.store.scheduleLayout(updateColumns)\n }\n )\n }\n })\n }\n const registerNormalWatchers = () => {\n const props = [\n 'label',\n 'filters',\n 'filterMultiple',\n 'filteredValue',\n 'sortable',\n 'index',\n 'formatter',\n 'className',\n 'labelClassName',\n 'filterClassName',\n 'showOverflowTooltip',\n 'tooltipFormatter',\n 'resizable',\n ]\n const parentProps = ['showOverflowTooltip']\n const aliases: Record<string, string> = {\n property: 'prop',\n align: 'realAlign',\n headerAlign: 'realHeaderAlign',\n }\n const allAliases = getAllAliases(props, aliases)\n Object.keys(allAliases).forEach((key) => {\n const columnKey = aliases[key]\n if (hasOwn(props_, columnKey)) {\n watch(\n () => props_[columnKey],\n (newVal) => {\n instance.columnConfig.value[key as never] = newVal\n }\n )\n }\n })\n parentProps.forEach((key) => {\n if (hasOwn(owner.value.props, key)) {\n watch(\n () => owner.value.props[key],\n (newVal) => {\n instance.columnConfig.value[key] = newVal as never\n }\n )\n }\n })\n }\n\n return {\n registerComplexWatchers,\n registerNormalWatchers,\n }\n}\n\nexport default useWatcher\n"],"names":[],"mappings":";;;;AAGA,SAAS,aAAa,CAAC,KAAK,EAAE,OAAO,EAAE;AACvC,E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AAG,CAAC,GAAG,MAAM,CAAC;AACpD,SAAS,CAAC,CAAC;AACX,OAAO;AACP,KAAK,CAAC,CAAC;AACP,IAAI,WAAW,CAAC,OAAO,CAAC,CAAC,GAAG,KAAK;AACjC,MAAM,IAAI,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,EAAE,GAAG,CAAC,EAAE;AAC1C,QAAQ,KAAK,CAAC,MAAM,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC,MAAM,KAAK;AACxD,UAAU,QAAQ,CAAC,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC;AACpD,SAAS,CAAC,CAAC;AACX,OAAO;AACP,KAAK,CAAC,CAAC;AACP,GAAG,CAAC;AACJ,EAAE,OAAO;AACT,IAAI,uBAAuB;AAC3B,IAAI,sBAAsB;AAC1B,GAAG,CAAC;AACJ;;;;"}
|
|
1
|
+
{"version":3,"file":"watcher-helper.mjs","sources":["../../../../../../../packages/components/table/src/table-column/watcher-helper.ts"],"sourcesContent":["import { getCurrentInstance, watch } from 'vue'\nimport { hasOwn } from '@element-plus/utils'\nimport { parseMinWidth, parseWidth } from '../util'\n\nimport type { ComputedRef } from 'vue'\nimport type { DefaultRow } from '../table/defaults'\nimport type { TableColumn, TableColumnCtx, ValueOf } from './defaults'\n\nfunction getAllAliases(props: string[], aliases: Record<string, string>) {\n return props.reduce((prev, cur) => {\n prev[cur as keyof typeof prev] = cur\n return prev\n }, aliases)\n}\nfunction useWatcher<T extends DefaultRow>(\n owner: ComputedRef<any>,\n props_: Partial<TableColumnCtx<T>>\n) {\n const instance = getCurrentInstance() as TableColumn<T>\n const registerComplexWatchers = () => {\n const props = ['fixed']\n const aliases: Record<string, string> = {\n realWidth: 'width',\n realMinWidth: 'minWidth',\n }\n const allAliases = getAllAliases(props, aliases)\n Object.keys(allAliases).forEach((key) => {\n const columnKey = aliases[key]\n if (hasOwn(props_, columnKey)) {\n watch(\n () => props_[columnKey],\n (newVal) => {\n let value: ValueOf<TableColumnCtx<T>> = newVal\n if (columnKey === 'width' && key === 'realWidth') {\n value = parseWidth(newVal)\n }\n if (columnKey === 'minWidth' && key === 'realMinWidth') {\n value = parseMinWidth(newVal)\n }\n instance.columnConfig.value[columnKey as never] = value as never\n instance.columnConfig.value[key as never] = value as never\n const updateColumns = columnKey === 'fixed'\n owner.value.store.scheduleLayout(updateColumns)\n }\n )\n }\n })\n }\n const registerNormalWatchers = () => {\n const props = [\n 'label',\n 'filters',\n 'filterMultiple',\n 'filteredValue',\n 'sortable',\n 'index',\n 'formatter',\n 'className',\n 'labelClassName',\n 'filterClassName',\n 'showOverflowTooltip',\n 'tooltipFormatter',\n 'resizable',\n ]\n const parentProps = ['showOverflowTooltip']\n const aliases: Record<string, string> = {\n property: 'prop',\n align: 'realAlign',\n headerAlign: 'realHeaderAlign',\n }\n const allAliases = getAllAliases(props, aliases)\n Object.keys(allAliases).forEach((key) => {\n const columnKey = aliases[key]\n if (hasOwn(props_, columnKey)) {\n watch(\n () => props_[columnKey],\n (newVal) => {\n instance.columnConfig.value[key as never] = newVal\n if (key === 'filters' || key === 'filterMethod') {\n instance.columnConfig.value['filterable'] = !!(\n instance.columnConfig.value['filters'] ||\n instance.columnConfig.value['filterMethod']\n )\n }\n }\n )\n }\n })\n parentProps.forEach((key) => {\n if (hasOwn(owner.value.props, key)) {\n watch(\n () => owner.value.props[key],\n (newVal) => {\n instance.columnConfig.value[key] = newVal as never\n }\n )\n }\n })\n }\n\n return {\n registerComplexWatchers,\n registerNormalWatchers,\n }\n}\n\nexport default useWatcher\n"],"names":[],"mappings":";;;;AAGA,SAAS,aAAa,CAAC,KAAK,EAAE,OAAO,EAAE;AACvC,EAAE,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,GAAG,KAAK;AACrC,IAAI,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC;AACpB,IAAI,OAAO,IAAI,CAAC;AAChB,GAAG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AG,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC,KAAK,CAAC,SAAS,CAAC,IAAI,QAAQ,CAAC,YAAY,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC;AAClJ,WAAW;AACX,SAAS,CAAC,CAAC;AACX,OAAO;AACP,KAAK,CAAC,CAAC;AACP,IAAI,WAAW,CAAC,OAAO,CAAC,CAAC,GAAG,KAAK;AACjC,MAAM,IAAI,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,EAAE,GAAG,CAAC,EAAE;AAC1C,QAAQ,KAAK,CAAC,MAAM,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC,MAAM,KAAK;AACxD,UAAU,QAAQ,CAAC,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,MAAM,CAAC;AACpD,SAAS,CAAC,CAAC;AACX,OAAO;AACP,KAAK,CAAC,CAAC;AACP,GAAG,CAAC;AACJ,EAAE,OAAO;AACT,IAAI,uBAAuB;AAC3B,IAAI,sBAAsB;AAC1B,GAAG,CAAC;AACJ;;;;"}
|
|
@@ -64,7 +64,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
64
64
|
lazy: BooleanConstructor;
|
|
65
65
|
load: import("vue").PropType<import("./table/defaults").TableProps<any>["load"]>;
|
|
66
66
|
style: {
|
|
67
|
-
type: import("vue").PropType<import("
|
|
67
|
+
type: import("vue").PropType<import("./table/defaults").TableProps<any>["style"]>;
|
|
68
68
|
default: () => {};
|
|
69
69
|
};
|
|
70
70
|
className: {
|
|
@@ -797,7 +797,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
797
797
|
lazy: BooleanConstructor;
|
|
798
798
|
load: import("vue").PropType<import("./table/defaults").TableProps<any>["load"]>;
|
|
799
799
|
style: {
|
|
800
|
-
type: import("vue").PropType<import("
|
|
800
|
+
type: import("vue").PropType<import("./table/defaults").TableProps<any>["style"]>;
|
|
801
801
|
default: () => {};
|
|
802
802
|
};
|
|
803
803
|
className: {
|
|
@@ -845,7 +845,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
845
845
|
"onRow-dblclick"?: ((...args: any[]) => any) | undefined;
|
|
846
846
|
}, {
|
|
847
847
|
data: any[];
|
|
848
|
-
style: import("vue").
|
|
848
|
+
style: import("vue").StyleValue | undefined;
|
|
849
849
|
tableLayout: "fixed" | "auto";
|
|
850
850
|
border: boolean;
|
|
851
851
|
className: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import Tabs from './src/tabs.mjs';
|
|
2
2
|
export { tabsEmits, tabsProps } from './src/tabs.mjs';
|
|
3
3
|
import TabPane from './src/tab-pane2.mjs';
|
|
4
|
-
export { tabBarProps } from './src/tab-
|
|
4
|
+
export { tabBarProps } from './src/tab-bar.mjs';
|
|
5
5
|
export { tabNavEmits, tabNavProps } from './src/tab-nav.mjs';
|
|
6
6
|
export { tabPaneProps } from './src/tab-pane.mjs';
|
|
7
7
|
export { tabsRootContextKey } from './src/constants.mjs';
|