@element-plus/nightly 0.0.20251229 → 0.0.20251231
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.full.js +29 -8
- 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 +29 -8
- package/dist/locale/af.js +1 -1
- package/dist/locale/af.min.js +1 -1
- package/dist/locale/af.min.mjs +1 -1
- package/dist/locale/af.mjs +1 -1
- package/dist/locale/ar-eg.js +1 -1
- package/dist/locale/ar-eg.min.js +1 -1
- package/dist/locale/ar-eg.min.mjs +1 -1
- package/dist/locale/ar-eg.mjs +1 -1
- package/dist/locale/ar.js +1 -1
- package/dist/locale/ar.min.js +1 -1
- package/dist/locale/ar.min.mjs +1 -1
- package/dist/locale/ar.mjs +1 -1
- package/dist/locale/az.js +1 -1
- package/dist/locale/az.min.js +1 -1
- package/dist/locale/az.min.mjs +1 -1
- package/dist/locale/az.mjs +1 -1
- package/dist/locale/bg.js +1 -1
- package/dist/locale/bg.min.js +1 -1
- package/dist/locale/bg.min.mjs +1 -1
- package/dist/locale/bg.mjs +1 -1
- package/dist/locale/bn.js +1 -1
- package/dist/locale/bn.min.js +1 -1
- package/dist/locale/bn.min.mjs +1 -1
- package/dist/locale/bn.mjs +1 -1
- package/dist/locale/ca.js +1 -1
- package/dist/locale/ca.min.js +1 -1
- package/dist/locale/ca.min.mjs +1 -1
- package/dist/locale/ca.mjs +1 -1
- package/dist/locale/ckb.js +1 -1
- package/dist/locale/ckb.min.js +1 -1
- package/dist/locale/ckb.min.mjs +1 -1
- package/dist/locale/ckb.mjs +1 -1
- package/dist/locale/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/hi.js +1 -1
- package/dist/locale/hi.min.js +1 -1
- package/dist/locale/hi.min.mjs +1 -1
- package/dist/locale/hi.mjs +1 -1
- package/dist/locale/hr.js +1 -1
- package/dist/locale/hr.min.js +1 -1
- package/dist/locale/hr.min.mjs +1 -1
- package/dist/locale/hr.mjs +1 -1
- package/dist/locale/hu.js +1 -1
- package/dist/locale/hu.min.js +1 -1
- package/dist/locale/hu.min.mjs +1 -1
- package/dist/locale/hu.mjs +1 -1
- package/dist/locale/hy-am.js +1 -1
- package/dist/locale/hy-am.min.js +1 -1
- package/dist/locale/hy-am.min.mjs +1 -1
- package/dist/locale/hy-am.mjs +1 -1
- package/dist/locale/id.js +1 -1
- package/dist/locale/id.min.js +1 -1
- package/dist/locale/id.min.mjs +1 -1
- package/dist/locale/id.mjs +1 -1
- package/dist/locale/it.js +1 -1
- package/dist/locale/it.min.js +1 -1
- package/dist/locale/it.min.mjs +1 -1
- package/dist/locale/it.mjs +1 -1
- package/dist/locale/ja.js +1 -1
- package/dist/locale/ja.min.js +1 -1
- package/dist/locale/ja.min.mjs +1 -1
- package/dist/locale/ja.mjs +1 -1
- package/dist/locale/kk.js +1 -1
- package/dist/locale/kk.min.js +1 -1
- package/dist/locale/kk.min.mjs +1 -1
- package/dist/locale/kk.mjs +1 -1
- package/dist/locale/km.js +1 -1
- package/dist/locale/km.min.js +1 -1
- package/dist/locale/km.min.mjs +1 -1
- package/dist/locale/km.mjs +1 -1
- package/dist/locale/ko.js +1 -1
- package/dist/locale/ko.min.js +1 -1
- package/dist/locale/ko.min.mjs +1 -1
- package/dist/locale/ko.mjs +1 -1
- package/dist/locale/ku.js +1 -1
- package/dist/locale/ku.min.js +1 -1
- package/dist/locale/ku.min.mjs +1 -1
- package/dist/locale/ku.mjs +1 -1
- package/dist/locale/ky.js +1 -1
- package/dist/locale/ky.min.js +1 -1
- package/dist/locale/ky.min.mjs +1 -1
- package/dist/locale/ky.mjs +1 -1
- package/dist/locale/lo.js +1 -1
- package/dist/locale/lo.min.js +1 -1
- package/dist/locale/lo.min.mjs +1 -1
- package/dist/locale/lo.mjs +1 -1
- package/dist/locale/lt.js +1 -1
- package/dist/locale/lt.min.js +1 -1
- package/dist/locale/lt.min.mjs +1 -1
- package/dist/locale/lt.mjs +1 -1
- package/dist/locale/lv.js +1 -1
- package/dist/locale/lv.min.js +1 -1
- package/dist/locale/lv.min.mjs +1 -1
- package/dist/locale/lv.mjs +1 -1
- package/dist/locale/mg.js +1 -1
- package/dist/locale/mg.min.js +1 -1
- package/dist/locale/mg.min.mjs +1 -1
- package/dist/locale/mg.mjs +1 -1
- package/dist/locale/mn.js +1 -1
- package/dist/locale/mn.min.js +1 -1
- package/dist/locale/mn.min.mjs +1 -1
- package/dist/locale/mn.mjs +1 -1
- package/dist/locale/ms.js +1 -1
- package/dist/locale/ms.min.js +1 -1
- package/dist/locale/ms.min.mjs +1 -1
- package/dist/locale/ms.mjs +1 -1
- package/dist/locale/my.js +1 -1
- package/dist/locale/my.min.js +1 -1
- package/dist/locale/my.min.mjs +1 -1
- package/dist/locale/my.mjs +1 -1
- package/dist/locale/nb-no.js +1 -1
- package/dist/locale/nb-no.min.js +1 -1
- package/dist/locale/nb-no.min.mjs +1 -1
- package/dist/locale/nb-no.mjs +1 -1
- package/dist/locale/nl.js +1 -1
- package/dist/locale/nl.min.js +1 -1
- package/dist/locale/nl.min.mjs +1 -1
- package/dist/locale/nl.mjs +1 -1
- package/dist/locale/no.js +1 -1
- package/dist/locale/no.min.js +1 -1
- package/dist/locale/no.min.mjs +1 -1
- package/dist/locale/no.mjs +1 -1
- package/dist/locale/pa.js +1 -1
- package/dist/locale/pa.min.js +1 -1
- package/dist/locale/pa.min.mjs +1 -1
- package/dist/locale/pa.mjs +1 -1
- package/dist/locale/pl.js +1 -1
- package/dist/locale/pl.min.js +1 -1
- package/dist/locale/pl.min.mjs +1 -1
- package/dist/locale/pl.mjs +1 -1
- package/dist/locale/pt-br.js +1 -1
- package/dist/locale/pt-br.min.js +1 -1
- package/dist/locale/pt-br.min.mjs +1 -1
- package/dist/locale/pt-br.mjs +1 -1
- package/dist/locale/pt.js +1 -1
- package/dist/locale/pt.min.js +1 -1
- package/dist/locale/pt.min.mjs +1 -1
- package/dist/locale/pt.mjs +1 -1
- package/dist/locale/ro.js +1 -1
- package/dist/locale/ro.min.js +1 -1
- package/dist/locale/ro.min.mjs +1 -1
- package/dist/locale/ro.mjs +1 -1
- package/dist/locale/ru.js +1 -1
- package/dist/locale/ru.min.js +1 -1
- package/dist/locale/ru.min.mjs +1 -1
- package/dist/locale/ru.mjs +1 -1
- package/dist/locale/sk.js +1 -1
- package/dist/locale/sk.min.js +1 -1
- package/dist/locale/sk.min.mjs +1 -1
- package/dist/locale/sk.mjs +1 -1
- package/dist/locale/sl.js +1 -1
- package/dist/locale/sl.min.js +1 -1
- package/dist/locale/sl.min.mjs +1 -1
- package/dist/locale/sl.mjs +1 -1
- package/dist/locale/sr.js +1 -1
- package/dist/locale/sr.min.js +1 -1
- package/dist/locale/sr.min.mjs +1 -1
- package/dist/locale/sr.mjs +1 -1
- package/dist/locale/sv.js +1 -1
- package/dist/locale/sv.min.js +1 -1
- package/dist/locale/sv.min.mjs +1 -1
- package/dist/locale/sv.mjs +1 -1
- package/dist/locale/sw.js +1 -1
- package/dist/locale/sw.min.js +1 -1
- package/dist/locale/sw.min.mjs +1 -1
- package/dist/locale/sw.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/te.js +1 -1
- package/dist/locale/te.min.js +1 -1
- package/dist/locale/te.min.mjs +1 -1
- package/dist/locale/te.mjs +1 -1
- package/dist/locale/th.js +1 -1
- package/dist/locale/th.min.js +1 -1
- package/dist/locale/th.min.mjs +1 -1
- package/dist/locale/th.mjs +1 -1
- package/dist/locale/tk.js +1 -1
- package/dist/locale/tk.min.js +1 -1
- package/dist/locale/tk.min.mjs +1 -1
- package/dist/locale/tk.mjs +1 -1
- package/dist/locale/tr.js +1 -1
- package/dist/locale/tr.min.js +1 -1
- package/dist/locale/tr.min.mjs +1 -1
- package/dist/locale/tr.mjs +1 -1
- package/dist/locale/ug-cn.js +1 -1
- package/dist/locale/ug-cn.min.js +1 -1
- package/dist/locale/ug-cn.min.mjs +1 -1
- package/dist/locale/ug-cn.mjs +1 -1
- package/dist/locale/uk.js +1 -1
- package/dist/locale/uk.min.js +1 -1
- package/dist/locale/uk.min.mjs +1 -1
- package/dist/locale/uk.mjs +1 -1
- package/dist/locale/uz-uz.js +1 -1
- package/dist/locale/uz-uz.min.js +1 -1
- package/dist/locale/uz-uz.min.mjs +1 -1
- package/dist/locale/uz-uz.mjs +1 -1
- package/dist/locale/vi.js +1 -1
- package/dist/locale/vi.min.js +1 -1
- package/dist/locale/vi.min.mjs +1 -1
- package/dist/locale/vi.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/dist/locale/zh-hk.js +1 -1
- package/dist/locale/zh-hk.min.js +1 -1
- package/dist/locale/zh-hk.min.mjs +1 -1
- package/dist/locale/zh-hk.mjs +1 -1
- package/dist/locale/zh-mo.js +1 -1
- package/dist/locale/zh-mo.min.js +1 -1
- package/dist/locale/zh-mo.min.mjs +1 -1
- package/dist/locale/zh-mo.mjs +1 -1
- package/dist/locale/zh-tw.js +1 -1
- package/dist/locale/zh-tw.min.js +1 -1
- package/dist/locale/zh-tw.min.mjs +1 -1
- package/dist/locale/zh-tw.mjs +1 -1
- package/es/components/affix/src/affix2.mjs +1 -1
- package/es/components/avatar/index.mjs +2 -2
- package/es/components/avatar/src/avatar.mjs +30 -74
- package/es/components/avatar/src/avatar.mjs.map +1 -1
- package/es/components/avatar/src/avatar2.mjs +74 -30
- package/es/components/avatar/src/avatar2.mjs.map +1 -1
- package/es/components/breadcrumb/index.mjs +2 -2
- package/es/components/breadcrumb/src/breadcrumb.mjs +37 -9
- package/es/components/breadcrumb/src/breadcrumb.mjs.map +1 -1
- package/es/components/breadcrumb/src/breadcrumb2.mjs +9 -37
- package/es/components/breadcrumb/src/breadcrumb2.mjs.map +1 -1
- package/es/components/cascader/src/cascader.vue.d.ts +1 -148
- package/es/components/cascader/src/cascader2.mjs +23 -2
- package/es/components/cascader/src/cascader2.mjs.map +1 -1
- package/es/components/col/index.mjs +2 -2
- package/es/components/col/src/col.mjs +65 -42
- package/es/components/col/src/col.mjs.map +1 -1
- package/es/components/col/src/col2.mjs +42 -65
- package/es/components/col/src/col2.mjs.map +1 -1
- package/es/components/collapse/index.mjs +2 -2
- package/es/components/collapse/src/collapse-item.mjs +118 -17
- package/es/components/collapse/src/collapse-item.mjs.map +1 -1
- package/es/components/collapse/src/collapse-item2.mjs +17 -118
- package/es/components/collapse/src/collapse-item2.mjs.map +1 -1
- package/es/components/countdown/index.mjs +2 -2
- package/es/components/countdown/src/countdown.mjs +83 -20
- package/es/components/countdown/src/countdown.mjs.map +1 -1
- package/es/components/countdown/src/countdown2.mjs +20 -83
- package/es/components/countdown/src/countdown2.mjs.map +1 -1
- package/es/components/dialog/src/dialog.mjs +1 -1
- package/es/components/dialog/src/use-dialog.mjs +1 -0
- package/es/components/dialog/src/use-dialog.mjs.map +1 -1
- package/es/components/empty/index.mjs +2 -2
- package/es/components/empty/src/empty.mjs +80 -10
- package/es/components/empty/src/empty.mjs.map +1 -1
- package/es/components/empty/src/empty2.mjs +10 -80
- package/es/components/empty/src/empty2.mjs.map +1 -1
- package/es/components/form/index.mjs +4 -4
- package/es/components/form/src/form-item.mjs +45 -355
- package/es/components/form/src/form-item.mjs.map +1 -1
- package/es/components/form/src/form-item2.mjs +355 -45
- package/es/components/form/src/form-item2.mjs.map +1 -1
- package/es/components/form/src/form.mjs +54 -174
- package/es/components/form/src/form.mjs.map +1 -1
- package/es/components/form/src/form2.mjs +174 -54
- package/es/components/form/src/form2.mjs.map +1 -1
- package/es/components/image/index.mjs +2 -2
- package/es/components/image/src/image.mjs +279 -68
- package/es/components/image/src/image.mjs.map +1 -1
- package/es/components/image/src/image2.mjs +68 -279
- package/es/components/image/src/image2.mjs.map +1 -1
- package/es/components/index.mjs +13 -13
- package/es/components/mention/src/mention-dropdown.mjs +205 -14
- package/es/components/mention/src/mention-dropdown.mjs.map +1 -1
- package/es/components/mention/src/mention-dropdown2.mjs +14 -205
- package/es/components/mention/src/mention-dropdown2.mjs.map +1 -1
- package/es/components/mention/src/mention2.mjs +1 -1
- package/es/components/message/index.mjs +1 -1
- package/es/components/message/src/message.mjs +107 -190
- package/es/components/message/src/message.mjs.map +1 -1
- package/es/components/message/src/message2.mjs +190 -107
- package/es/components/message/src/message2.mjs.map +1 -1
- package/es/components/message/src/method.mjs +2 -2
- package/es/components/pagination/src/components/next.mjs +17 -43
- package/es/components/pagination/src/components/next.mjs.map +1 -1
- package/es/components/pagination/src/components/next2.mjs +43 -17
- package/es/components/pagination/src/components/next2.mjs.map +1 -1
- package/es/components/pagination/src/components/pager.mjs +15 -229
- package/es/components/pagination/src/components/pager.mjs.map +1 -1
- package/es/components/pagination/src/components/pager2.mjs +229 -15
- package/es/components/pagination/src/components/pager2.mjs.map +1 -1
- package/es/components/pagination/src/pagination.mjs +2 -2
- package/es/components/progress/index.mjs +2 -2
- package/es/components/progress/src/progress.mjs +256 -52
- package/es/components/progress/src/progress.mjs.map +1 -1
- package/es/components/progress/src/progress2.mjs +52 -256
- package/es/components/progress/src/progress2.mjs.map +1 -1
- package/es/components/skeleton/index.mjs +2 -2
- package/es/components/skeleton/src/skeleton.mjs +17 -67
- package/es/components/skeleton/src/skeleton.mjs.map +1 -1
- package/es/components/skeleton/src/skeleton2.mjs +67 -17
- package/es/components/skeleton/src/skeleton2.mjs.map +1 -1
- package/es/components/table/src/table/key-render-helper.mjs +5 -6
- package/es/components/table/src/table/key-render-helper.mjs.map +1 -1
- package/es/components/tabs/index.mjs +1 -1
- package/es/components/tabs/src/tab-bar.mjs +102 -10
- package/es/components/tabs/src/tab-bar.mjs.map +1 -1
- package/es/components/tabs/src/tab-bar2.mjs +10 -102
- package/es/components/tabs/src/tab-bar2.mjs.map +1 -1
- package/es/components/tabs/src/tab-nav.mjs +1 -1
- package/es/components/teleport/index.mjs +2 -2
- package/es/components/teleport/src/teleport.mjs +8 -18
- package/es/components/teleport/src/teleport.mjs.map +1 -1
- package/es/components/teleport/src/teleport2.mjs +18 -8
- package/es/components/teleport/src/teleport2.mjs.map +1 -1
- package/es/components/tooltip/src/content.mjs +1 -1
- package/es/components/tour/src/tour.mjs +1 -1
- 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/affix/src/affix2.js +1 -1
- package/lib/components/avatar/index.js +2 -2
- package/lib/components/avatar/src/avatar.js +31 -74
- package/lib/components/avatar/src/avatar.js.map +1 -1
- package/lib/components/avatar/src/avatar2.js +74 -31
- package/lib/components/avatar/src/avatar2.js.map +1 -1
- package/lib/components/breadcrumb/index.js +2 -2
- package/lib/components/breadcrumb/src/breadcrumb.js +37 -9
- package/lib/components/breadcrumb/src/breadcrumb.js.map +1 -1
- package/lib/components/breadcrumb/src/breadcrumb2.js +9 -37
- package/lib/components/breadcrumb/src/breadcrumb2.js.map +1 -1
- package/lib/components/cascader/src/cascader.vue.d.ts +1 -148
- package/lib/components/cascader/src/cascader2.js +22 -1
- package/lib/components/cascader/src/cascader2.js.map +1 -1
- package/lib/components/col/index.js +2 -2
- package/lib/components/col/src/col.js +65 -42
- package/lib/components/col/src/col.js.map +1 -1
- package/lib/components/col/src/col2.js +42 -65
- package/lib/components/col/src/col2.js.map +1 -1
- package/lib/components/collapse/index.js +2 -2
- package/lib/components/collapse/src/collapse-item.js +118 -17
- package/lib/components/collapse/src/collapse-item.js.map +1 -1
- package/lib/components/collapse/src/collapse-item2.js +17 -118
- package/lib/components/collapse/src/collapse-item2.js.map +1 -1
- package/lib/components/countdown/index.js +2 -2
- package/lib/components/countdown/src/countdown.js +83 -21
- package/lib/components/countdown/src/countdown.js.map +1 -1
- package/lib/components/countdown/src/countdown2.js +21 -83
- package/lib/components/countdown/src/countdown2.js.map +1 -1
- package/lib/components/dialog/src/dialog.js +1 -1
- package/lib/components/dialog/src/use-dialog.js +1 -0
- package/lib/components/dialog/src/use-dialog.js.map +1 -1
- package/lib/components/empty/index.js +2 -2
- package/lib/components/empty/src/empty.js +80 -10
- package/lib/components/empty/src/empty.js.map +1 -1
- package/lib/components/empty/src/empty2.js +10 -80
- package/lib/components/empty/src/empty2.js.map +1 -1
- package/lib/components/form/index.js +4 -4
- package/lib/components/form/src/form-item.js +46 -359
- package/lib/components/form/src/form-item.js.map +1 -1
- package/lib/components/form/src/form-item2.js +359 -46
- package/lib/components/form/src/form-item2.js.map +1 -1
- package/lib/components/form/src/form.js +55 -173
- package/lib/components/form/src/form.js.map +1 -1
- package/lib/components/form/src/form2.js +173 -55
- package/lib/components/form/src/form2.js.map +1 -1
- package/lib/components/image/index.js +2 -2
- package/lib/components/image/src/image.js +278 -68
- package/lib/components/image/src/image.js.map +1 -1
- package/lib/components/image/src/image2.js +68 -278
- package/lib/components/image/src/image2.js.map +1 -1
- package/lib/components/index.js +13 -13
- package/lib/components/mention/src/mention-dropdown.js +205 -15
- package/lib/components/mention/src/mention-dropdown.js.map +1 -1
- package/lib/components/mention/src/mention-dropdown2.js +15 -205
- package/lib/components/mention/src/mention-dropdown2.js.map +1 -1
- package/lib/components/mention/src/mention2.js +1 -1
- package/lib/components/message/index.js +1 -1
- package/lib/components/message/src/message.js +111 -189
- package/lib/components/message/src/message.js.map +1 -1
- package/lib/components/message/src/message2.js +189 -111
- package/lib/components/message/src/message2.js.map +1 -1
- package/lib/components/message/src/method.js +2 -2
- package/lib/components/pagination/src/components/next.js +17 -43
- package/lib/components/pagination/src/components/next.js.map +1 -1
- package/lib/components/pagination/src/components/next2.js +43 -17
- package/lib/components/pagination/src/components/next2.js.map +1 -1
- package/lib/components/pagination/src/components/pager.js +15 -229
- package/lib/components/pagination/src/components/pager.js.map +1 -1
- package/lib/components/pagination/src/components/pager2.js +229 -15
- package/lib/components/pagination/src/components/pager2.js.map +1 -1
- package/lib/components/pagination/src/pagination.js +2 -2
- package/lib/components/progress/index.js +2 -2
- package/lib/components/progress/src/progress.js +256 -52
- package/lib/components/progress/src/progress.js.map +1 -1
- package/lib/components/progress/src/progress2.js +52 -256
- package/lib/components/progress/src/progress2.js.map +1 -1
- package/lib/components/skeleton/index.js +2 -2
- package/lib/components/skeleton/src/skeleton.js +17 -67
- package/lib/components/skeleton/src/skeleton.js.map +1 -1
- package/lib/components/skeleton/src/skeleton2.js +67 -17
- package/lib/components/skeleton/src/skeleton2.js.map +1 -1
- package/lib/components/table/src/table/key-render-helper.js +4 -5
- package/lib/components/table/src/table/key-render-helper.js.map +1 -1
- package/lib/components/tabs/index.js +1 -1
- package/lib/components/tabs/src/tab-bar.js +102 -10
- package/lib/components/tabs/src/tab-bar.js.map +1 -1
- package/lib/components/tabs/src/tab-bar2.js +10 -102
- package/lib/components/tabs/src/tab-bar2.js.map +1 -1
- package/lib/components/tabs/src/tab-nav.js +1 -1
- package/lib/components/teleport/index.js +2 -2
- package/lib/components/teleport/src/teleport.js +8 -18
- package/lib/components/teleport/src/teleport.js.map +1 -1
- package/lib/components/teleport/src/teleport2.js +18 -8
- package/lib/components/teleport/src/teleport2.js.map +1 -1
- package/lib/components/tooltip/src/content.js +1 -1
- package/lib/components/tour/src/tour.js +1 -1
- 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/web-types.json +1 -1
|
@@ -2,23 +2,237 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
var iconsVue = require('@element-plus/icons-vue');
|
|
7
|
+
var pager = require('./pager.js');
|
|
8
|
+
var pluginVue_exportHelper = require('../../../../_virtual/plugin-vue_export-helper.js');
|
|
9
|
+
var event = require('../../../../constants/event.js');
|
|
10
|
+
var index = require('../../../../hooks/use-namespace/index.js');
|
|
11
|
+
var index$1 = require('../../../../hooks/use-locale/index.js');
|
|
6
12
|
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
13
|
+
const _hoisted_1 = ["aria-current", "aria-label", "tabindex"];
|
|
14
|
+
const _hoisted_2 = ["tabindex", "aria-label"];
|
|
15
|
+
const _hoisted_3 = ["aria-current", "aria-label", "tabindex"];
|
|
16
|
+
const _hoisted_4 = ["tabindex", "aria-label"];
|
|
17
|
+
const _hoisted_5 = ["aria-current", "aria-label", "tabindex"];
|
|
18
|
+
const _sfc_main = vue.defineComponent({
|
|
19
|
+
...{
|
|
20
|
+
name: "ElPaginationPager"
|
|
11
21
|
},
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
22
|
+
__name: "pager",
|
|
23
|
+
props: pager.paginationPagerProps,
|
|
24
|
+
emits: [event.CHANGE_EVENT],
|
|
25
|
+
setup(__props, { emit: __emit }) {
|
|
26
|
+
const props = __props;
|
|
27
|
+
const emit = __emit;
|
|
28
|
+
const nsPager = index.useNamespace("pager");
|
|
29
|
+
const nsIcon = index.useNamespace("icon");
|
|
30
|
+
const { t } = index$1.useLocale();
|
|
31
|
+
const showPrevMore = vue.ref(false);
|
|
32
|
+
const showNextMore = vue.ref(false);
|
|
33
|
+
const quickPrevHover = vue.ref(false);
|
|
34
|
+
const quickNextHover = vue.ref(false);
|
|
35
|
+
const quickPrevFocus = vue.ref(false);
|
|
36
|
+
const quickNextFocus = vue.ref(false);
|
|
37
|
+
const pagers = vue.computed(() => {
|
|
38
|
+
const pagerCount = props.pagerCount;
|
|
39
|
+
const halfPagerCount = (pagerCount - 1) / 2;
|
|
40
|
+
const currentPage = Number(props.currentPage);
|
|
41
|
+
const pageCount = Number(props.pageCount);
|
|
42
|
+
let showPrevMore2 = false;
|
|
43
|
+
let showNextMore2 = false;
|
|
44
|
+
if (pageCount > pagerCount) {
|
|
45
|
+
if (currentPage > pagerCount - halfPagerCount) {
|
|
46
|
+
showPrevMore2 = true;
|
|
47
|
+
}
|
|
48
|
+
if (currentPage < pageCount - halfPagerCount) {
|
|
49
|
+
showNextMore2 = true;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
const array = [];
|
|
53
|
+
if (showPrevMore2 && !showNextMore2) {
|
|
54
|
+
const startPage = pageCount - (pagerCount - 2);
|
|
55
|
+
for (let i = startPage; i < pageCount; i++) {
|
|
56
|
+
array.push(i);
|
|
57
|
+
}
|
|
58
|
+
} else if (!showPrevMore2 && showNextMore2) {
|
|
59
|
+
for (let i = 2; i < pagerCount; i++) {
|
|
60
|
+
array.push(i);
|
|
61
|
+
}
|
|
62
|
+
} else if (showPrevMore2 && showNextMore2) {
|
|
63
|
+
const offset = Math.floor(pagerCount / 2) - 1;
|
|
64
|
+
for (let i = currentPage - offset; i <= currentPage + offset; i++) {
|
|
65
|
+
array.push(i);
|
|
66
|
+
}
|
|
67
|
+
} else {
|
|
68
|
+
for (let i = 2; i < pageCount; i++) {
|
|
69
|
+
array.push(i);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
return array;
|
|
73
|
+
});
|
|
74
|
+
const prevMoreKls = vue.computed(() => [
|
|
75
|
+
"more",
|
|
76
|
+
"btn-quickprev",
|
|
77
|
+
nsIcon.b(),
|
|
78
|
+
nsPager.is("disabled", props.disabled)
|
|
79
|
+
]);
|
|
80
|
+
const nextMoreKls = vue.computed(() => [
|
|
81
|
+
"more",
|
|
82
|
+
"btn-quicknext",
|
|
83
|
+
nsIcon.b(),
|
|
84
|
+
nsPager.is("disabled", props.disabled)
|
|
85
|
+
]);
|
|
86
|
+
const tabindex = vue.computed(() => props.disabled ? -1 : 0);
|
|
87
|
+
vue.watch(
|
|
88
|
+
() => [props.pageCount, props.pagerCount, props.currentPage],
|
|
89
|
+
([pageCount, pagerCount, currentPage]) => {
|
|
90
|
+
const halfPagerCount = (pagerCount - 1) / 2;
|
|
91
|
+
let showPrev = false;
|
|
92
|
+
let showNext = false;
|
|
93
|
+
if (pageCount > pagerCount) {
|
|
94
|
+
showPrev = currentPage > pagerCount - halfPagerCount;
|
|
95
|
+
showNext = currentPage < pageCount - halfPagerCount;
|
|
96
|
+
}
|
|
97
|
+
quickPrevHover.value && (quickPrevHover.value = showPrev);
|
|
98
|
+
quickNextHover.value && (quickNextHover.value = showNext);
|
|
99
|
+
showPrevMore.value = showPrev;
|
|
100
|
+
showNextMore.value = showNext;
|
|
101
|
+
},
|
|
102
|
+
{ immediate: true }
|
|
103
|
+
);
|
|
104
|
+
function onMouseEnter(forward = false) {
|
|
105
|
+
if (props.disabled)
|
|
106
|
+
return;
|
|
107
|
+
if (forward) {
|
|
108
|
+
quickPrevHover.value = true;
|
|
109
|
+
} else {
|
|
110
|
+
quickNextHover.value = true;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
function onFocus(forward = false) {
|
|
114
|
+
if (forward) {
|
|
115
|
+
quickPrevFocus.value = true;
|
|
116
|
+
} else {
|
|
117
|
+
quickNextFocus.value = true;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
function onEnter(e) {
|
|
121
|
+
const target = e.target;
|
|
122
|
+
if (target.tagName.toLowerCase() === "li" && Array.from(target.classList).includes("number")) {
|
|
123
|
+
const newPage = Number(target.textContent);
|
|
124
|
+
if (newPage !== props.currentPage) {
|
|
125
|
+
emit(event.CHANGE_EVENT, newPage);
|
|
126
|
+
}
|
|
127
|
+
} else if (target.tagName.toLowerCase() === "li" && Array.from(target.classList).includes("more")) {
|
|
128
|
+
onPagerClick(e);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
function onPagerClick(event$1) {
|
|
132
|
+
const target = event$1.target;
|
|
133
|
+
if (target.tagName.toLowerCase() === "ul" || props.disabled) {
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
136
|
+
let newPage = Number(target.textContent);
|
|
137
|
+
const pageCount = props.pageCount;
|
|
138
|
+
const currentPage = props.currentPage;
|
|
139
|
+
const pagerCountOffset = props.pagerCount - 2;
|
|
140
|
+
if (target.className.includes("more")) {
|
|
141
|
+
if (target.className.includes("quickprev")) {
|
|
142
|
+
newPage = currentPage - pagerCountOffset;
|
|
143
|
+
} else if (target.className.includes("quicknext")) {
|
|
144
|
+
newPage = currentPage + pagerCountOffset;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
if (!Number.isNaN(+newPage)) {
|
|
148
|
+
if (newPage < 1) {
|
|
149
|
+
newPage = 1;
|
|
150
|
+
}
|
|
151
|
+
if (newPage > pageCount) {
|
|
152
|
+
newPage = pageCount;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
if (newPage !== currentPage) {
|
|
156
|
+
emit(event.CHANGE_EVENT, newPage);
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
return (_ctx, _cache) => {
|
|
160
|
+
return vue.openBlock(), vue.createElementBlock(
|
|
161
|
+
"ul",
|
|
162
|
+
{
|
|
163
|
+
class: vue.normalizeClass(vue.unref(nsPager).b()),
|
|
164
|
+
onClick: onPagerClick,
|
|
165
|
+
onKeyup: vue.withKeys(onEnter, ["enter"])
|
|
166
|
+
},
|
|
167
|
+
[
|
|
168
|
+
_ctx.pageCount > 0 ? (vue.openBlock(), vue.createElementBlock("li", {
|
|
169
|
+
key: 0,
|
|
170
|
+
class: vue.normalizeClass([[
|
|
171
|
+
vue.unref(nsPager).is("active", _ctx.currentPage === 1),
|
|
172
|
+
vue.unref(nsPager).is("disabled", _ctx.disabled)
|
|
173
|
+
], "number"]),
|
|
174
|
+
"aria-current": _ctx.currentPage === 1,
|
|
175
|
+
"aria-label": vue.unref(t)("el.pagination.currentPage", { pager: 1 }),
|
|
176
|
+
tabindex: tabindex.value
|
|
177
|
+
}, " 1 ", 10, _hoisted_1)) : vue.createCommentVNode("v-if", true),
|
|
178
|
+
showPrevMore.value ? (vue.openBlock(), vue.createElementBlock("li", {
|
|
179
|
+
key: 1,
|
|
180
|
+
class: vue.normalizeClass(prevMoreKls.value),
|
|
181
|
+
tabindex: tabindex.value,
|
|
182
|
+
"aria-label": vue.unref(t)("el.pagination.prevPages", { pager: _ctx.pagerCount - 2 }),
|
|
183
|
+
onMouseenter: _cache[0] || (_cache[0] = ($event) => onMouseEnter(true)),
|
|
184
|
+
onMouseleave: _cache[1] || (_cache[1] = ($event) => quickPrevHover.value = false),
|
|
185
|
+
onFocus: _cache[2] || (_cache[2] = ($event) => onFocus(true)),
|
|
186
|
+
onBlur: _cache[3] || (_cache[3] = ($event) => quickPrevFocus.value = false)
|
|
187
|
+
}, [
|
|
188
|
+
(quickPrevHover.value || quickPrevFocus.value) && !_ctx.disabled ? (vue.openBlock(), vue.createBlock(vue.unref(iconsVue.DArrowLeft), { key: 0 })) : (vue.openBlock(), vue.createBlock(vue.unref(iconsVue.MoreFilled), { key: 1 }))
|
|
189
|
+
], 42, _hoisted_2)) : vue.createCommentVNode("v-if", true),
|
|
190
|
+
(vue.openBlock(true), vue.createElementBlock(
|
|
191
|
+
vue.Fragment,
|
|
192
|
+
null,
|
|
193
|
+
vue.renderList(pagers.value, (pager) => {
|
|
194
|
+
return vue.openBlock(), vue.createElementBlock("li", {
|
|
195
|
+
key: pager,
|
|
196
|
+
class: vue.normalizeClass([[
|
|
197
|
+
vue.unref(nsPager).is("active", _ctx.currentPage === pager),
|
|
198
|
+
vue.unref(nsPager).is("disabled", _ctx.disabled)
|
|
199
|
+
], "number"]),
|
|
200
|
+
"aria-current": _ctx.currentPage === pager,
|
|
201
|
+
"aria-label": vue.unref(t)("el.pagination.currentPage", { pager }),
|
|
202
|
+
tabindex: tabindex.value
|
|
203
|
+
}, vue.toDisplayString(pager), 11, _hoisted_3);
|
|
204
|
+
}),
|
|
205
|
+
128
|
|
206
|
+
)),
|
|
207
|
+
showNextMore.value ? (vue.openBlock(), vue.createElementBlock("li", {
|
|
208
|
+
key: 2,
|
|
209
|
+
class: vue.normalizeClass(nextMoreKls.value),
|
|
210
|
+
tabindex: tabindex.value,
|
|
211
|
+
"aria-label": vue.unref(t)("el.pagination.nextPages", { pager: _ctx.pagerCount - 2 }),
|
|
212
|
+
onMouseenter: _cache[4] || (_cache[4] = ($event) => onMouseEnter()),
|
|
213
|
+
onMouseleave: _cache[5] || (_cache[5] = ($event) => quickNextHover.value = false),
|
|
214
|
+
onFocus: _cache[6] || (_cache[6] = ($event) => onFocus()),
|
|
215
|
+
onBlur: _cache[7] || (_cache[7] = ($event) => quickNextFocus.value = false)
|
|
216
|
+
}, [
|
|
217
|
+
(quickNextHover.value || quickNextFocus.value) && !_ctx.disabled ? (vue.openBlock(), vue.createBlock(vue.unref(iconsVue.DArrowRight), { key: 0 })) : (vue.openBlock(), vue.createBlock(vue.unref(iconsVue.MoreFilled), { key: 1 }))
|
|
218
|
+
], 42, _hoisted_4)) : vue.createCommentVNode("v-if", true),
|
|
219
|
+
_ctx.pageCount > 1 ? (vue.openBlock(), vue.createElementBlock("li", {
|
|
220
|
+
key: 3,
|
|
221
|
+
class: vue.normalizeClass([[
|
|
222
|
+
vue.unref(nsPager).is("active", _ctx.currentPage === _ctx.pageCount),
|
|
223
|
+
vue.unref(nsPager).is("disabled", _ctx.disabled)
|
|
224
|
+
], "number"]),
|
|
225
|
+
"aria-current": _ctx.currentPage === _ctx.pageCount,
|
|
226
|
+
"aria-label": vue.unref(t)("el.pagination.currentPage", { pager: _ctx.pageCount }),
|
|
227
|
+
tabindex: tabindex.value
|
|
228
|
+
}, vue.toDisplayString(_ctx.pageCount), 11, _hoisted_5)) : vue.createCommentVNode("v-if", true)
|
|
229
|
+
],
|
|
230
|
+
34
|
|
231
|
+
);
|
|
232
|
+
};
|
|
233
|
+
}
|
|
21
234
|
});
|
|
235
|
+
var Pager = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/pager.vue"]]);
|
|
22
236
|
|
|
23
|
-
exports
|
|
237
|
+
exports["default"] = Pager;
|
|
24
238
|
//# sourceMappingURL=pager2.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pager2.js","sources":["../../../../../../../packages/components/pagination/src/components/pager.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\n\nimport type { ExtractPropTypes, ExtractPublicPropTypes } from 'vue'\nimport type Pager from './pager.vue'\n\nexport const paginationPagerProps = buildProps({\n currentPage: {\n type: Number,\n default: 1,\n },\n pageCount: {\n type: Number,\n required: true,\n },\n pagerCount: {\n type: Number,\n default: 7,\n },\n disabled: Boolean,\n} as const)\n\nexport type PaginationPagerProps = ExtractPropTypes<typeof paginationPagerProps>\nexport type PaginationPagerPropsPublic = ExtractPublicPropTypes<\n typeof paginationPagerProps\n>\n\nexport type PagerInstance = InstanceType<typeof Pager> & unknown\n"],"names":["buildProps"],"mappings":";;;;;;AAKO,MAAM,uBAAuBA,kBAAW,CAAA;AAAA,EAC7C,WAAa,EAAA;AAAA,IACX,IAAM,EAAA,MAAA;AAAA,IACN,OAAS,EAAA,CAAA;AAAA,GACX;AAAA,EACA,SAAW,EAAA;AAAA,IACT,IAAM,EAAA,MAAA;AAAA,IACN,QAAU,EAAA,IAAA;AAAA,GACZ;AAAA,EACA,UAAY,EAAA;AAAA,IACV,IAAM,EAAA,MAAA;AAAA,IACN,OAAS,EAAA,CAAA;AAAA,GACX;AAAA,EACA,QAAU,EAAA,OAAA;AACZ,CAAU;;;;"}
|
|
1
|
+
{"version":3,"file":"pager2.js","sources":["../../../../../../../packages/components/pagination/src/components/pager.vue"],"sourcesContent":["<template>\n <ul :class=\"nsPager.b()\" @click=\"onPagerClick\" @keyup.enter=\"onEnter\">\n <li\n v-if=\"pageCount > 0\"\n :class=\"[\n nsPager.is('active', currentPage === 1),\n nsPager.is('disabled', disabled),\n ]\"\n class=\"number\"\n :aria-current=\"currentPage === 1\"\n :aria-label=\"t('el.pagination.currentPage', { pager: 1 })\"\n :tabindex=\"tabindex\"\n >\n 1\n </li>\n <li\n v-if=\"showPrevMore\"\n :class=\"prevMoreKls\"\n :tabindex=\"tabindex\"\n :aria-label=\"t('el.pagination.prevPages', { pager: pagerCount - 2 })\"\n @mouseenter=\"onMouseEnter(true)\"\n @mouseleave=\"quickPrevHover = false\"\n @focus=\"onFocus(true)\"\n @blur=\"quickPrevFocus = false\"\n >\n <d-arrow-left v-if=\"(quickPrevHover || quickPrevFocus) && !disabled\" />\n <more-filled v-else />\n </li>\n <li\n v-for=\"pager in pagers\"\n :key=\"pager\"\n :class=\"[\n nsPager.is('active', currentPage === pager),\n nsPager.is('disabled', disabled),\n ]\"\n class=\"number\"\n :aria-current=\"currentPage === pager\"\n :aria-label=\"t('el.pagination.currentPage', { pager })\"\n :tabindex=\"tabindex\"\n >\n {{ pager }}\n </li>\n <li\n v-if=\"showNextMore\"\n :class=\"nextMoreKls\"\n :tabindex=\"tabindex\"\n :aria-label=\"t('el.pagination.nextPages', { pager: pagerCount - 2 })\"\n @mouseenter=\"onMouseEnter()\"\n @mouseleave=\"quickNextHover = false\"\n @focus=\"onFocus()\"\n @blur=\"quickNextFocus = false\"\n >\n <d-arrow-right v-if=\"(quickNextHover || quickNextFocus) && !disabled\" />\n <more-filled v-else />\n </li>\n <li\n v-if=\"pageCount > 1\"\n :class=\"[\n nsPager.is('active', currentPage === pageCount),\n nsPager.is('disabled', disabled),\n ]\"\n class=\"number\"\n :aria-current=\"currentPage === pageCount\"\n :aria-label=\"t('el.pagination.currentPage', { pager: pageCount })\"\n :tabindex=\"tabindex\"\n >\n {{ pageCount }}\n </li>\n </ul>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, ref, watch } from 'vue'\nimport { DArrowLeft, DArrowRight, MoreFilled } from '@element-plus/icons-vue'\nimport { useLocale, useNamespace } from '@element-plus/hooks'\nimport { CHANGE_EVENT } from '@element-plus/constants'\nimport { paginationPagerProps } from './pager'\n\ndefineOptions({\n name: 'ElPaginationPager',\n})\nconst props = defineProps(paginationPagerProps)\nconst emit = defineEmits([CHANGE_EVENT])\nconst nsPager = useNamespace('pager')\nconst nsIcon = useNamespace('icon')\nconst { t } = useLocale()\n\nconst showPrevMore = ref(false)\nconst showNextMore = ref(false)\nconst quickPrevHover = ref(false)\nconst quickNextHover = ref(false)\nconst quickPrevFocus = ref(false)\nconst quickNextFocus = ref(false)\nconst pagers = computed(() => {\n const pagerCount = props.pagerCount\n const halfPagerCount = (pagerCount - 1) / 2\n const currentPage = Number(props.currentPage)\n const pageCount = Number(props.pageCount)\n let showPrevMore = false\n let showNextMore = false\n if (pageCount > pagerCount) {\n if (currentPage > pagerCount - halfPagerCount) {\n showPrevMore = true\n }\n if (currentPage < pageCount - halfPagerCount) {\n showNextMore = true\n }\n }\n const array: number[] = []\n if (showPrevMore && !showNextMore) {\n const startPage = pageCount - (pagerCount - 2)\n for (let i = startPage; i < pageCount; i++) {\n array.push(i)\n }\n } else if (!showPrevMore && showNextMore) {\n for (let i = 2; i < pagerCount; i++) {\n array.push(i)\n }\n } else if (showPrevMore && showNextMore) {\n const offset = Math.floor(pagerCount / 2) - 1\n for (let i = currentPage - offset; i <= currentPage + offset; i++) {\n array.push(i)\n }\n } else {\n for (let i = 2; i < pageCount; i++) {\n array.push(i)\n }\n }\n return array\n})\n\nconst prevMoreKls = computed(() => [\n 'more',\n 'btn-quickprev',\n nsIcon.b(),\n nsPager.is('disabled', props.disabled),\n])\nconst nextMoreKls = computed(() => [\n 'more',\n 'btn-quicknext',\n nsIcon.b(),\n nsPager.is('disabled', props.disabled),\n])\n\nconst tabindex = computed(() => (props.disabled ? -1 : 0))\nwatch(\n () => [props.pageCount, props.pagerCount, props.currentPage],\n ([pageCount, pagerCount, currentPage]) => {\n const halfPagerCount = (pagerCount - 1) / 2\n let showPrev = false\n let showNext = false\n\n if (pageCount > pagerCount) {\n showPrev = currentPage > pagerCount - halfPagerCount\n showNext = currentPage < pageCount - halfPagerCount\n }\n\n quickPrevHover.value &&= showPrev\n quickNextHover.value &&= showNext\n showPrevMore.value = showPrev\n showNextMore.value = showNext\n },\n { immediate: true }\n)\nfunction onMouseEnter(forward = false) {\n if (props.disabled) return\n if (forward) {\n quickPrevHover.value = true\n } else {\n quickNextHover.value = true\n }\n}\nfunction onFocus(forward = false) {\n if (forward) {\n quickPrevFocus.value = true\n } else {\n quickNextFocus.value = true\n }\n}\nfunction onEnter(e: UIEvent) {\n const target = e.target as HTMLElement\n if (\n target.tagName.toLowerCase() === 'li' &&\n Array.from(target.classList).includes('number')\n ) {\n const newPage = Number(target.textContent)\n if (newPage !== props.currentPage) {\n emit(CHANGE_EVENT, newPage)\n }\n } else if (\n target.tagName.toLowerCase() === 'li' &&\n Array.from(target.classList).includes('more')\n ) {\n onPagerClick(e)\n }\n}\nfunction onPagerClick(event: UIEvent) {\n const target = event.target as HTMLElement\n if (target.tagName.toLowerCase() === 'ul' || props.disabled) {\n return\n }\n let newPage = Number(target.textContent)\n const pageCount = props.pageCount!\n const currentPage = props.currentPage\n const pagerCountOffset = props.pagerCount - 2\n if (target.className.includes('more')) {\n if (target.className.includes('quickprev')) {\n newPage = currentPage - pagerCountOffset\n } else if (target.className.includes('quicknext')) {\n newPage = currentPage + pagerCountOffset\n }\n }\n if (!Number.isNaN(+newPage)) {\n if (newPage < 1) {\n newPage = 1\n }\n if (newPage > pageCount) {\n newPage = pageCount\n }\n }\n if (newPage !== currentPage) {\n emit(CHANGE_EVENT, newPage)\n }\n}\n</script>\n"],"names":["useNamespace","useLocale","ref","computed","showPrevMore","showNextMore","watch","CHANGE_EVENT","event","_openBlock","_createElementBlock","_normalizeClass","_unref","_withKeys","pageCount","currentPage","disabled","_createCommentVNode","pagerCount","_createBlock","MoreFilled","_Fragment","_renderList","_toDisplayString"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAiFA,IAAA,MAAM,KAAQ,GAAA,OAAA,CAAA;AACd,I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A,CAAA,EAAA,IAAA,UAAA,CAAA,IAAAG,sBAAA,CAAA,MAAA,EAAA,IAAA,CAAA;AAAA;;;;;;;;;;"}
|
|
@@ -6,11 +6,11 @@ var vue = require('vue');
|
|
|
6
6
|
var iconsVue = require('@element-plus/icons-vue');
|
|
7
7
|
var constants = require('./constants.js');
|
|
8
8
|
var prev = require('./components/prev2.js');
|
|
9
|
-
var next = require('./components/
|
|
9
|
+
var next = require('./components/next2.js');
|
|
10
10
|
var sizes = require('./components/sizes2.js');
|
|
11
11
|
var jumper = require('./components/jumper2.js');
|
|
12
12
|
var total = require('./components/total2.js');
|
|
13
|
-
var pager = require('./components/
|
|
13
|
+
var pager = require('./components/pager2.js');
|
|
14
14
|
var index$2 = require('../../../hooks/use-size/index.js');
|
|
15
15
|
var runtime = require('../../../utils/vue/props/runtime.js');
|
|
16
16
|
var index = require('../../../hooks/use-locale/index.js');
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var progress$1 = require('./src/
|
|
6
|
-
var progress = require('./src/
|
|
5
|
+
var progress$1 = require('./src/progress.js');
|
|
6
|
+
var progress = require('./src/progress2.js');
|
|
7
7
|
var install = require('../../utils/vue/install.js');
|
|
8
8
|
|
|
9
9
|
const ElProgress = install.withInstall(progress$1["default"]);
|
|
@@ -2,61 +2,265 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
var index$1 = require('../../icon/index.js');
|
|
7
|
+
var iconsVue = require('@element-plus/icons-vue');
|
|
8
|
+
var progress = require('./progress2.js');
|
|
9
|
+
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
10
|
+
var index = require('../../../hooks/use-namespace/index.js');
|
|
11
|
+
var shared = require('@vue/shared');
|
|
6
12
|
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
const _hoisted_1 = ["aria-valuenow"];
|
|
14
|
+
const _hoisted_2 = { viewBox: "0 0 100 100" };
|
|
15
|
+
const _hoisted_3 = ["d", "stroke", "stroke-linecap", "stroke-width"];
|
|
16
|
+
const _hoisted_4 = ["d", "stroke", "opacity", "stroke-linecap", "stroke-width"];
|
|
17
|
+
const _hoisted_5 = { key: 0 };
|
|
18
|
+
const _sfc_main = vue.defineComponent({
|
|
19
|
+
...{
|
|
20
|
+
name: "ElProgress"
|
|
12
21
|
},
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
22
|
+
__name: "progress",
|
|
23
|
+
props: progress.progressProps,
|
|
24
|
+
setup(__props) {
|
|
25
|
+
const STATUS_COLOR_MAP = {
|
|
26
|
+
success: "#13ce66",
|
|
27
|
+
exception: "#ff4949",
|
|
28
|
+
warning: "#e6a23c",
|
|
29
|
+
default: "#20a0ff"
|
|
30
|
+
};
|
|
31
|
+
const props = __props;
|
|
32
|
+
const ns = index.useNamespace("progress");
|
|
33
|
+
const barStyle = vue.computed(() => {
|
|
34
|
+
const barStyle2 = {
|
|
35
|
+
width: `${props.percentage}%`,
|
|
36
|
+
animationDuration: `${props.duration}s`
|
|
37
|
+
};
|
|
38
|
+
const color = getCurrentColor(props.percentage);
|
|
39
|
+
if (color.includes("gradient")) {
|
|
40
|
+
barStyle2.background = color;
|
|
41
|
+
} else {
|
|
42
|
+
barStyle2.backgroundColor = color;
|
|
43
|
+
}
|
|
44
|
+
return barStyle2;
|
|
45
|
+
});
|
|
46
|
+
const relativeStrokeWidth = vue.computed(
|
|
47
|
+
() => (props.strokeWidth / props.width * 100).toFixed(1)
|
|
48
|
+
);
|
|
49
|
+
const radius = vue.computed(() => {
|
|
50
|
+
if (["circle", "dashboard"].includes(props.type)) {
|
|
51
|
+
return Number.parseInt(
|
|
52
|
+
`${50 - Number.parseFloat(relativeStrokeWidth.value) / 2}`,
|
|
53
|
+
10
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
return 0;
|
|
57
|
+
});
|
|
58
|
+
const trackPath = vue.computed(() => {
|
|
59
|
+
const r = radius.value;
|
|
60
|
+
const isDashboard = props.type === "dashboard";
|
|
61
|
+
return `
|
|
62
|
+
M 50 50
|
|
63
|
+
m 0 ${isDashboard ? "" : "-"}${r}
|
|
64
|
+
a ${r} ${r} 0 1 1 0 ${isDashboard ? "-" : ""}${r * 2}
|
|
65
|
+
a ${r} ${r} 0 1 1 0 ${isDashboard ? "" : "-"}${r * 2}
|
|
66
|
+
`;
|
|
67
|
+
});
|
|
68
|
+
const perimeter = vue.computed(() => 2 * Math.PI * radius.value);
|
|
69
|
+
const rate = vue.computed(() => props.type === "dashboard" ? 0.75 : 1);
|
|
70
|
+
const strokeDashoffset = vue.computed(() => {
|
|
71
|
+
const offset = -1 * perimeter.value * (1 - rate.value) / 2;
|
|
72
|
+
return `${offset}px`;
|
|
73
|
+
});
|
|
74
|
+
const trailPathStyle = vue.computed(() => ({
|
|
75
|
+
strokeDasharray: `${perimeter.value * rate.value}px, ${perimeter.value}px`,
|
|
76
|
+
strokeDashoffset: strokeDashoffset.value
|
|
77
|
+
}));
|
|
78
|
+
const circlePathStyle = vue.computed(() => ({
|
|
79
|
+
strokeDasharray: `${perimeter.value * rate.value * (props.percentage / 100)}px, ${perimeter.value}px`,
|
|
80
|
+
strokeDashoffset: strokeDashoffset.value,
|
|
81
|
+
transition: "stroke-dasharray 0.6s ease 0s, stroke 0.6s ease, opacity ease 0.6s"
|
|
82
|
+
}));
|
|
83
|
+
const stroke = vue.computed(() => {
|
|
84
|
+
let ret;
|
|
85
|
+
if (props.color) {
|
|
86
|
+
ret = getCurrentColor(props.percentage);
|
|
87
|
+
} else {
|
|
88
|
+
ret = STATUS_COLOR_MAP[props.status] || STATUS_COLOR_MAP.default;
|
|
89
|
+
}
|
|
90
|
+
return ret;
|
|
91
|
+
});
|
|
92
|
+
const statusIcon = vue.computed(() => {
|
|
93
|
+
if (props.status === "warning") {
|
|
94
|
+
return iconsVue.WarningFilled;
|
|
95
|
+
}
|
|
96
|
+
if (props.type === "line") {
|
|
97
|
+
return props.status === "success" ? iconsVue.CircleCheck : iconsVue.CircleClose;
|
|
98
|
+
} else {
|
|
99
|
+
return props.status === "success" ? iconsVue.Check : iconsVue.Close;
|
|
100
|
+
}
|
|
101
|
+
});
|
|
102
|
+
const progressTextSize = vue.computed(() => {
|
|
103
|
+
return props.type === "line" ? 12 + props.strokeWidth * 0.4 : props.width * 0.111111 + 2;
|
|
104
|
+
});
|
|
105
|
+
const content = vue.computed(() => props.format(props.percentage));
|
|
106
|
+
function getColors(color) {
|
|
107
|
+
const span = 100 / color.length;
|
|
108
|
+
const seriesColors = color.map((seriesColor, index) => {
|
|
109
|
+
if (shared.isString(seriesColor)) {
|
|
110
|
+
return {
|
|
111
|
+
color: seriesColor,
|
|
112
|
+
percentage: (index + 1) * span
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
return seriesColor;
|
|
116
|
+
});
|
|
117
|
+
return seriesColors.sort((a, b) => a.percentage - b.percentage);
|
|
118
|
+
}
|
|
119
|
+
const getCurrentColor = (percentage) => {
|
|
120
|
+
var _a;
|
|
121
|
+
const { color } = props;
|
|
122
|
+
if (shared.isFunction(color)) {
|
|
123
|
+
return color(percentage);
|
|
124
|
+
} else if (shared.isString(color)) {
|
|
125
|
+
return color;
|
|
126
|
+
} else {
|
|
127
|
+
const colors = getColors(color);
|
|
128
|
+
for (const color2 of colors) {
|
|
129
|
+
if (color2.percentage > percentage)
|
|
130
|
+
return color2.color;
|
|
131
|
+
}
|
|
132
|
+
return (_a = colors[colors.length - 1]) == null ? void 0 : _a.color;
|
|
133
|
+
}
|
|
134
|
+
};
|
|
135
|
+
return (_ctx, _cache) => {
|
|
136
|
+
return vue.openBlock(), vue.createElementBlock("div", {
|
|
137
|
+
class: vue.normalizeClass([
|
|
138
|
+
vue.unref(ns).b(),
|
|
139
|
+
vue.unref(ns).m(_ctx.type),
|
|
140
|
+
vue.unref(ns).is(_ctx.status),
|
|
141
|
+
{
|
|
142
|
+
[vue.unref(ns).m("without-text")]: !_ctx.showText,
|
|
143
|
+
[vue.unref(ns).m("text-inside")]: _ctx.textInside
|
|
144
|
+
}
|
|
145
|
+
]),
|
|
146
|
+
role: "progressbar",
|
|
147
|
+
"aria-valuenow": _ctx.percentage,
|
|
148
|
+
"aria-valuemin": "0",
|
|
149
|
+
"aria-valuemax": "100"
|
|
150
|
+
}, [
|
|
151
|
+
_ctx.type === "line" ? (vue.openBlock(), vue.createElementBlock(
|
|
152
|
+
"div",
|
|
153
|
+
{
|
|
154
|
+
key: 0,
|
|
155
|
+
class: vue.normalizeClass(vue.unref(ns).b("bar"))
|
|
156
|
+
},
|
|
157
|
+
[
|
|
158
|
+
vue.createElementVNode(
|
|
159
|
+
"div",
|
|
160
|
+
{
|
|
161
|
+
class: vue.normalizeClass(vue.unref(ns).be("bar", "outer")),
|
|
162
|
+
style: vue.normalizeStyle({ height: `${_ctx.strokeWidth}px` })
|
|
163
|
+
},
|
|
164
|
+
[
|
|
165
|
+
vue.createElementVNode(
|
|
166
|
+
"div",
|
|
167
|
+
{
|
|
168
|
+
class: vue.normalizeClass([
|
|
169
|
+
vue.unref(ns).be("bar", "inner"),
|
|
170
|
+
{ [vue.unref(ns).bem("bar", "inner", "indeterminate")]: _ctx.indeterminate },
|
|
171
|
+
{ [vue.unref(ns).bem("bar", "inner", "striped")]: _ctx.striped },
|
|
172
|
+
{ [vue.unref(ns).bem("bar", "inner", "striped-flow")]: _ctx.stripedFlow }
|
|
173
|
+
]),
|
|
174
|
+
style: vue.normalizeStyle(barStyle.value)
|
|
175
|
+
},
|
|
176
|
+
[
|
|
177
|
+
(_ctx.showText || _ctx.$slots.default) && _ctx.textInside ? (vue.openBlock(), vue.createElementBlock(
|
|
178
|
+
"div",
|
|
179
|
+
{
|
|
180
|
+
key: 0,
|
|
181
|
+
class: vue.normalizeClass(vue.unref(ns).be("bar", "innerText"))
|
|
182
|
+
},
|
|
183
|
+
[
|
|
184
|
+
vue.renderSlot(_ctx.$slots, "default", { percentage: _ctx.percentage }, () => [
|
|
185
|
+
vue.createElementVNode(
|
|
186
|
+
"span",
|
|
187
|
+
null,
|
|
188
|
+
vue.toDisplayString(content.value),
|
|
189
|
+
1
|
|
190
|
+
)
|
|
191
|
+
])
|
|
192
|
+
],
|
|
193
|
+
2
|
|
194
|
+
)) : vue.createCommentVNode("v-if", true)
|
|
195
|
+
],
|
|
196
|
+
6
|
|
197
|
+
)
|
|
198
|
+
],
|
|
199
|
+
6
|
|
200
|
+
)
|
|
201
|
+
],
|
|
202
|
+
2
|
|
203
|
+
)) : (vue.openBlock(), vue.createElementBlock(
|
|
204
|
+
"div",
|
|
205
|
+
{
|
|
206
|
+
key: 1,
|
|
207
|
+
class: vue.normalizeClass(vue.unref(ns).b("circle")),
|
|
208
|
+
style: vue.normalizeStyle({ height: `${_ctx.width}px`, width: `${_ctx.width}px` })
|
|
209
|
+
},
|
|
210
|
+
[
|
|
211
|
+
(vue.openBlock(), vue.createElementBlock("svg", _hoisted_2, [
|
|
212
|
+
vue.createElementVNode("path", {
|
|
213
|
+
class: vue.normalizeClass(vue.unref(ns).be("circle", "track")),
|
|
214
|
+
d: trackPath.value,
|
|
215
|
+
stroke: `var(${vue.unref(ns).cssVarName("fill-color-light")}, #e5e9f2)`,
|
|
216
|
+
"stroke-linecap": _ctx.strokeLinecap,
|
|
217
|
+
"stroke-width": relativeStrokeWidth.value,
|
|
218
|
+
fill: "none",
|
|
219
|
+
style: vue.normalizeStyle(trailPathStyle.value)
|
|
220
|
+
}, null, 14, _hoisted_3),
|
|
221
|
+
vue.createElementVNode("path", {
|
|
222
|
+
class: vue.normalizeClass(vue.unref(ns).be("circle", "path")),
|
|
223
|
+
d: trackPath.value,
|
|
224
|
+
stroke: stroke.value,
|
|
225
|
+
fill: "none",
|
|
226
|
+
opacity: _ctx.percentage ? 1 : 0,
|
|
227
|
+
"stroke-linecap": _ctx.strokeLinecap,
|
|
228
|
+
"stroke-width": relativeStrokeWidth.value,
|
|
229
|
+
style: vue.normalizeStyle(circlePathStyle.value)
|
|
230
|
+
}, null, 14, _hoisted_4)
|
|
231
|
+
]))
|
|
232
|
+
],
|
|
233
|
+
6
|
|
234
|
+
)),
|
|
235
|
+
(_ctx.showText || _ctx.$slots.default) && !_ctx.textInside ? (vue.openBlock(), vue.createElementBlock(
|
|
236
|
+
"div",
|
|
237
|
+
{
|
|
238
|
+
key: 2,
|
|
239
|
+
class: vue.normalizeClass(vue.unref(ns).e("text")),
|
|
240
|
+
style: vue.normalizeStyle({ fontSize: `${progressTextSize.value}px` })
|
|
241
|
+
},
|
|
242
|
+
[
|
|
243
|
+
vue.renderSlot(_ctx.$slots, "default", { percentage: _ctx.percentage }, () => [
|
|
244
|
+
!_ctx.status ? (vue.openBlock(), vue.createElementBlock(
|
|
245
|
+
"span",
|
|
246
|
+
_hoisted_5,
|
|
247
|
+
vue.toDisplayString(content.value),
|
|
248
|
+
1
|
|
249
|
+
)) : (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), { key: 1 }, {
|
|
250
|
+
default: vue.withCtx(() => [
|
|
251
|
+
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(statusIcon.value)))
|
|
252
|
+
]),
|
|
253
|
+
_: 1
|
|
254
|
+
}))
|
|
255
|
+
])
|
|
256
|
+
],
|
|
257
|
+
6
|
|
258
|
+
)) : vue.createCommentVNode("v-if", true)
|
|
259
|
+
], 10, _hoisted_1);
|
|
260
|
+
};
|
|
58
261
|
}
|
|
59
262
|
});
|
|
263
|
+
var Progress = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "/home/runner/work/element-plus/element-plus/packages/components/progress/src/progress.vue"]]);
|
|
60
264
|
|
|
61
|
-
exports
|
|
265
|
+
exports["default"] = Progress;
|
|
62
266
|
//# sourceMappingURL=progress.js.map
|