@element-plus/nightly 0.0.20251120 → 0.0.20251121
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/attributes.json +1 -1
- package/dist/index.full.js +25 -13
- package/dist/index.full.min.js +9 -9
- 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 +25 -13
- 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/index.mjs +2 -2
- package/es/components/affix/src/affix.mjs +129 -24
- package/es/components/affix/src/affix.mjs.map +1 -1
- package/es/components/affix/src/affix2.mjs +24 -129
- package/es/components/affix/src/affix2.mjs.map +1 -1
- package/es/components/avatar/index.mjs +2 -2
- package/es/components/avatar/src/avatar.mjs +65 -31
- package/es/components/avatar/src/avatar.mjs.map +1 -1
- package/es/components/avatar/src/avatar2.mjs +31 -65
- package/es/components/avatar/src/avatar2.mjs.map +1 -1
- package/es/components/button/index.mjs +2 -2
- package/es/components/button/src/button-group.mjs +1 -1
- package/es/components/button/src/button.mjs +88 -65
- package/es/components/button/src/button.mjs.map +1 -1
- package/es/components/button/src/button2.mjs +65 -88
- package/es/components/button/src/button2.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/color-picker/src/color-picker2.mjs +1 -1
- package/es/components/color-picker-panel/index.mjs +2 -2
- package/es/components/color-picker-panel/src/color-picker-panel.mjs +132 -27
- package/es/components/color-picker-panel/src/color-picker-panel.mjs.map +1 -1
- package/es/components/color-picker-panel/src/color-picker-panel2.mjs +27 -132
- package/es/components/color-picker-panel/src/color-picker-panel2.mjs.map +1 -1
- package/es/components/color-picker-panel/src/composables/use-predefine.mjs +1 -1
- package/es/components/index.mjs +13 -13
- package/es/components/input-tag/index.mjs +2 -2
- package/es/components/input-tag/src/input-tag.mjs +283 -83
- package/es/components/input-tag/src/input-tag.mjs.map +1 -1
- package/es/components/input-tag/src/input-tag2.mjs +83 -283
- package/es/components/input-tag/src/input-tag2.mjs.map +1 -1
- package/es/components/page-header/index.mjs +2 -2
- package/es/components/page-header/src/page-header.mjs +16 -97
- package/es/components/page-header/src/page-header.mjs.map +1 -1
- package/es/components/page-header/src/page-header2.mjs +97 -16
- package/es/components/page-header/src/page-header2.mjs.map +1 -1
- package/es/components/popconfirm/index.mjs +2 -2
- package/es/components/popconfirm/src/popconfirm.mjs +50 -135
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm2.mjs +135 -50
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/popover/index.mjs +2 -2
- package/es/components/popover/src/popover.mjs +112 -66
- package/es/components/popover/src/popover.mjs.map +1 -1
- package/es/components/popover/src/popover2.mjs +66 -112
- package/es/components/popover/src/popover2.mjs.map +1 -1
- package/es/components/scrollbar/src/bar.mjs +64 -10
- package/es/components/scrollbar/src/bar.mjs.map +1 -1
- package/es/components/scrollbar/src/bar2.mjs +10 -64
- package/es/components/scrollbar/src/bar2.mjs.map +1 -1
- package/es/components/scrollbar/src/scrollbar2.mjs +1 -1
- package/es/components/segmented/index.mjs +2 -2
- package/es/components/segmented/src/segmented.mjs +170 -42
- package/es/components/segmented/src/segmented.mjs.map +1 -1
- package/es/components/segmented/src/segmented2.mjs +42 -170
- package/es/components/segmented/src/segmented2.mjs.map +1 -1
- package/es/components/steps/index.mjs +2 -2
- package/es/components/steps/src/item.mjs +19 -198
- package/es/components/steps/src/item.mjs.map +1 -1
- package/es/components/steps/src/item2.mjs +198 -19
- package/es/components/steps/src/item2.mjs.map +1 -1
- package/es/components/switch/index.mjs +2 -2
- package/es/components/switch/src/switch.mjs +72 -225
- package/es/components/switch/src/switch.mjs.map +1 -1
- package/es/components/switch/src/switch2.mjs +225 -72
- package/es/components/switch/src/switch2.mjs.map +1 -1
- package/es/components/table/src/table/style-helper.mjs +7 -9
- package/es/components/table/src/table/style-helper.mjs.map +1 -1
- package/es/components/tabs/src/tab-bar2.mjs +9 -3
- package/es/components/tabs/src/tab-bar2.mjs.map +1 -1
- package/es/components/tabs/src/tabs.d.ts +18 -0
- package/es/components/tabs/src/tabs.mjs +10 -2
- package/es/components/tabs/src/tabs.mjs.map +1 -1
- package/es/components/text/index.mjs +2 -2
- package/es/components/text/src/text.mjs +67 -21
- package/es/components/text/src/text.mjs.map +1 -1
- package/es/components/text/src/text2.mjs +21 -67
- package/es/components/text/src/text2.mjs.map +1 -1
- package/es/components/tooltip/src/trigger2.mjs.map +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/index.js +2 -2
- package/lib/components/affix/src/affix.js +129 -25
- package/lib/components/affix/src/affix.js.map +1 -1
- package/lib/components/affix/src/affix2.js +25 -129
- package/lib/components/affix/src/affix2.js.map +1 -1
- package/lib/components/avatar/index.js +2 -2
- package/lib/components/avatar/src/avatar.js +65 -32
- package/lib/components/avatar/src/avatar.js.map +1 -1
- package/lib/components/avatar/src/avatar2.js +32 -65
- package/lib/components/avatar/src/avatar2.js.map +1 -1
- package/lib/components/button/index.js +2 -2
- package/lib/components/button/src/button-group.js +1 -1
- package/lib/components/button/src/button.js +88 -68
- package/lib/components/button/src/button.js.map +1 -1
- package/lib/components/button/src/button2.js +68 -88
- package/lib/components/button/src/button2.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/color-picker/src/color-picker2.js +1 -1
- package/lib/components/color-picker-panel/index.js +2 -2
- package/lib/components/color-picker-panel/src/color-picker-panel.js +132 -30
- package/lib/components/color-picker-panel/src/color-picker-panel.js.map +1 -1
- package/lib/components/color-picker-panel/src/color-picker-panel2.js +30 -132
- package/lib/components/color-picker-panel/src/color-picker-panel2.js.map +1 -1
- package/lib/components/color-picker-panel/src/composables/use-predefine.js +1 -1
- package/lib/components/index.js +13 -13
- package/lib/components/input-tag/index.js +2 -2
- package/lib/components/input-tag/src/input-tag.js +281 -82
- package/lib/components/input-tag/src/input-tag.js.map +1 -1
- package/lib/components/input-tag/src/input-tag2.js +82 -281
- package/lib/components/input-tag/src/input-tag2.js.map +1 -1
- package/lib/components/page-header/index.js +2 -2
- package/lib/components/page-header/src/page-header.js +17 -97
- package/lib/components/page-header/src/page-header.js.map +1 -1
- package/lib/components/page-header/src/page-header2.js +97 -17
- package/lib/components/page-header/src/page-header2.js.map +1 -1
- package/lib/components/popconfirm/index.js +2 -2
- package/lib/components/popconfirm/src/popconfirm.js +51 -135
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm2.js +135 -51
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/popover/index.js +2 -2
- package/lib/components/popover/src/popover.js +112 -67
- package/lib/components/popover/src/popover.js.map +1 -1
- package/lib/components/popover/src/popover2.js +67 -112
- package/lib/components/popover/src/popover2.js.map +1 -1
- package/lib/components/scrollbar/src/bar.js +64 -10
- package/lib/components/scrollbar/src/bar.js.map +1 -1
- package/lib/components/scrollbar/src/bar2.js +10 -64
- package/lib/components/scrollbar/src/bar2.js.map +1 -1
- package/lib/components/scrollbar/src/scrollbar2.js +1 -1
- package/lib/components/segmented/index.js +2 -2
- package/lib/components/segmented/src/segmented.js +170 -44
- package/lib/components/segmented/src/segmented.js.map +1 -1
- package/lib/components/segmented/src/segmented2.js +44 -170
- package/lib/components/segmented/src/segmented2.js.map +1 -1
- package/lib/components/steps/index.js +2 -2
- package/lib/components/steps/src/item.js +19 -198
- package/lib/components/steps/src/item.js.map +1 -1
- package/lib/components/steps/src/item2.js +198 -19
- package/lib/components/steps/src/item2.js.map +1 -1
- package/lib/components/switch/index.js +2 -2
- package/lib/components/switch/src/switch.js +72 -224
- package/lib/components/switch/src/switch.js.map +1 -1
- package/lib/components/switch/src/switch2.js +224 -72
- package/lib/components/switch/src/switch2.js.map +1 -1
- package/lib/components/table/src/table/style-helper.js +6 -8
- package/lib/components/table/src/table/style-helper.js.map +1 -1
- package/lib/components/tabs/src/tab-bar2.js +8 -2
- package/lib/components/tabs/src/tab-bar2.js.map +1 -1
- package/lib/components/tabs/src/tabs.d.ts +18 -0
- package/lib/components/tabs/src/tabs.js +10 -2
- package/lib/components/tabs/src/tabs.js.map +1 -1
- package/lib/components/text/index.js +2 -2
- package/lib/components/text/src/text.js +67 -21
- package/lib/components/text/src/text.js.map +1 -1
- package/lib/components/text/src/text2.js +21 -67
- package/lib/components/text/src/text2.js.map +1 -1
- package/lib/components/tooltip/src/trigger2.js.map +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/tags.json +1 -1
- package/web-types.json +1 -1
|
@@ -2,138 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var vue = require('vue');
|
|
6
|
-
var core = require('@vueuse/core');
|
|
7
|
-
var affix = require('./affix.js');
|
|
8
|
-
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
9
|
-
var index = require('../../../hooks/use-namespace/index.js');
|
|
10
|
-
var scroll = require('../../../utils/dom/scroll.js');
|
|
11
|
-
var style = require('../../../utils/dom/style.js');
|
|
12
5
|
var event = require('../../../constants/event.js');
|
|
13
|
-
var
|
|
6
|
+
var runtime = require('../../../utils/vue/props/runtime.js');
|
|
7
|
+
var types = require('../../../utils/types.js');
|
|
14
8
|
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
width: rootWidth,
|
|
33
|
-
top: rootTop,
|
|
34
|
-
bottom: rootBottom,
|
|
35
|
-
update: updateRoot
|
|
36
|
-
} = core.useElementBounding(root, { windowScroll: false });
|
|
37
|
-
const targetRect = core.useElementBounding(target);
|
|
38
|
-
const fixed = vue.ref(false);
|
|
39
|
-
const scrollTop = vue.ref(0);
|
|
40
|
-
const transform = vue.ref(0);
|
|
41
|
-
const rootStyle = vue.computed(() => {
|
|
42
|
-
return {
|
|
43
|
-
height: fixed.value ? `${rootHeight.value}px` : "",
|
|
44
|
-
width: fixed.value ? `${rootWidth.value}px` : ""
|
|
45
|
-
};
|
|
46
|
-
});
|
|
47
|
-
const affixStyle = vue.computed(() => {
|
|
48
|
-
if (!fixed.value)
|
|
49
|
-
return {};
|
|
50
|
-
const offset = style.addUnit(props.offset);
|
|
51
|
-
return {
|
|
52
|
-
height: `${rootHeight.value}px`,
|
|
53
|
-
width: `${rootWidth.value}px`,
|
|
54
|
-
top: props.position === "top" ? offset : "",
|
|
55
|
-
bottom: props.position === "bottom" ? offset : "",
|
|
56
|
-
transform: transform.value ? `translateY(${transform.value}px)` : "",
|
|
57
|
-
zIndex: props.zIndex
|
|
58
|
-
};
|
|
59
|
-
});
|
|
60
|
-
const update = () => {
|
|
61
|
-
if (!scrollContainer.value)
|
|
62
|
-
return;
|
|
63
|
-
scrollTop.value = scrollContainer.value instanceof Window ? document.documentElement.scrollTop : scrollContainer.value.scrollTop || 0;
|
|
64
|
-
const { position, target: target2, offset } = props;
|
|
65
|
-
const rootHeightOffset = offset + rootHeight.value;
|
|
66
|
-
if (position === "top") {
|
|
67
|
-
if (target2) {
|
|
68
|
-
const difference = targetRect.bottom.value - rootHeightOffset;
|
|
69
|
-
fixed.value = offset > rootTop.value && targetRect.bottom.value > 0;
|
|
70
|
-
transform.value = difference < 0 ? difference : 0;
|
|
71
|
-
} else {
|
|
72
|
-
fixed.value = offset > rootTop.value;
|
|
73
|
-
}
|
|
74
|
-
} else if (target2) {
|
|
75
|
-
const difference = windowHeight.value - targetRect.top.value - rootHeightOffset;
|
|
76
|
-
fixed.value = windowHeight.value - offset < rootBottom.value && windowHeight.value > targetRect.top.value;
|
|
77
|
-
transform.value = difference < 0 ? -difference : 0;
|
|
78
|
-
} else {
|
|
79
|
-
fixed.value = windowHeight.value - offset < rootBottom.value;
|
|
80
|
-
}
|
|
81
|
-
};
|
|
82
|
-
const updateRootRect = async () => {
|
|
83
|
-
if (!fixed.value) {
|
|
84
|
-
updateRoot();
|
|
85
|
-
return;
|
|
86
|
-
}
|
|
87
|
-
fixed.value = false;
|
|
88
|
-
await vue.nextTick();
|
|
89
|
-
updateRoot();
|
|
90
|
-
fixed.value = true;
|
|
91
|
-
};
|
|
92
|
-
const handleScroll = async () => {
|
|
93
|
-
updateRoot();
|
|
94
|
-
await vue.nextTick();
|
|
95
|
-
emit("scroll", {
|
|
96
|
-
scrollTop: scrollTop.value,
|
|
97
|
-
fixed: fixed.value
|
|
98
|
-
});
|
|
99
|
-
};
|
|
100
|
-
vue.watch(fixed, (val) => emit(event.CHANGE_EVENT, val));
|
|
101
|
-
vue.onMounted(() => {
|
|
102
|
-
var _a;
|
|
103
|
-
if (props.target) {
|
|
104
|
-
target.value = (_a = document.querySelector(props.target)) != null ? _a : void 0;
|
|
105
|
-
if (!target.value)
|
|
106
|
-
error.throwError(COMPONENT_NAME, `Target does not exist: ${props.target}`);
|
|
107
|
-
} else {
|
|
108
|
-
target.value = document.documentElement;
|
|
109
|
-
}
|
|
110
|
-
scrollContainer.value = scroll.getScrollContainer(root.value, true);
|
|
111
|
-
updateRoot();
|
|
112
|
-
});
|
|
113
|
-
core.useEventListener(scrollContainer, "scroll", handleScroll);
|
|
114
|
-
vue.watchEffect(update);
|
|
115
|
-
expose({
|
|
116
|
-
update,
|
|
117
|
-
updateRoot: updateRootRect
|
|
118
|
-
});
|
|
119
|
-
return (_ctx, _cache) => {
|
|
120
|
-
return vue.openBlock(), vue.createElementBlock("div", {
|
|
121
|
-
ref_key: "root",
|
|
122
|
-
ref: root,
|
|
123
|
-
class: vue.normalizeClass(vue.unref(ns).b()),
|
|
124
|
-
style: vue.normalizeStyle(vue.unref(rootStyle))
|
|
125
|
-
}, [
|
|
126
|
-
vue.createElementVNode("div", {
|
|
127
|
-
class: vue.normalizeClass({ [vue.unref(ns).m("fixed")]: fixed.value }),
|
|
128
|
-
style: vue.normalizeStyle(vue.unref(affixStyle))
|
|
129
|
-
}, [
|
|
130
|
-
vue.renderSlot(_ctx.$slots, "default")
|
|
131
|
-
], 6)
|
|
132
|
-
], 6);
|
|
133
|
-
};
|
|
9
|
+
const affixProps = runtime.buildProps({
|
|
10
|
+
zIndex: {
|
|
11
|
+
type: runtime.definePropType([Number, String]),
|
|
12
|
+
default: 100
|
|
13
|
+
},
|
|
14
|
+
target: {
|
|
15
|
+
type: String,
|
|
16
|
+
default: ""
|
|
17
|
+
},
|
|
18
|
+
offset: {
|
|
19
|
+
type: Number,
|
|
20
|
+
default: 0
|
|
21
|
+
},
|
|
22
|
+
position: {
|
|
23
|
+
type: String,
|
|
24
|
+
values: ["top", "bottom"],
|
|
25
|
+
default: "top"
|
|
134
26
|
}
|
|
135
27
|
});
|
|
136
|
-
|
|
28
|
+
const affixEmits = {
|
|
29
|
+
scroll: ({ scrollTop, fixed }) => types.isNumber(scrollTop) && types.isBoolean(fixed),
|
|
30
|
+
[event.CHANGE_EVENT]: (fixed) => types.isBoolean(fixed)
|
|
31
|
+
};
|
|
137
32
|
|
|
138
|
-
exports
|
|
33
|
+
exports.affixEmits = affixEmits;
|
|
34
|
+
exports.affixProps = affixProps;
|
|
139
35
|
//# sourceMappingURL=affix2.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"affix2.js","sources":["../../../../../../packages/components/affix/src/affix.
|
|
1
|
+
{"version":3,"file":"affix2.js","sources":["../../../../../../packages/components/affix/src/affix.ts"],"sourcesContent":["import {\n buildProps,\n definePropType,\n isBoolean,\n isNumber,\n} from '@element-plus/utils'\nimport { CHANGE_EVENT } from '@element-plus/constants'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type { ZIndexProperty } from 'csstype'\nimport type Affix from './affix.vue'\n\nexport const affixProps = buildProps({\n /**\n * @description affix element zIndex value\n * */\n zIndex: {\n type: definePropType<ZIndexProperty>([Number, String]),\n default: 100,\n },\n /**\n * @description target container. (CSS selector)\n */\n target: {\n type: String,\n default: '',\n },\n /**\n * @description offset distance\n * */\n offset: {\n type: Number,\n default: 0,\n },\n /**\n * @description position of affix\n * */\n position: {\n type: String,\n values: ['top', 'bottom'],\n default: 'top',\n },\n} as const)\nexport type AffixProps = ExtractPropTypes<typeof affixProps>\nexport type AffixPropsPublic = __ExtractPublicPropTypes<typeof affixProps>\n\nexport const affixEmits = {\n scroll: ({ scrollTop, fixed }: { scrollTop: number; fixed: boolean }) =>\n isNumber(scrollTop) && isBoolean(fixed),\n [CHANGE_EVENT]: (fixed: boolean) => isBoolean(fixed),\n}\nexport type AffixEmits = typeof affixEmits\n\nexport type AffixInstance = InstanceType<typeof Affix> & unknown\n"],"names":["buildProps","definePropType","isNumber","isBoolean","CHANGE_EVENT"],"mappings":";;;;;;;;AAOY,MAAC,UAAU,GAAGA,kBAAU,CAAC;AACrC,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAEC,sBAAc,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAC1C,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,CAAC;AACd,GAAG;AACH,EAAE,QAAQ,EAAE;AACZ,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,KAAK,EAAE,QAAQ,CAAC;AAC7B,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,UAAU,GAAG;AAC1B,EAAE,MAAM,EAAE,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,KAAKC,cAAQ,CAAC,SAAS,CAAC,IAAIC,eAAS,CAAC,KAAK,CAAC;AAC3E,EAAE,CAACC,kBAAY,GAAG,CAAC,KAAK,KAAKD,eAAS,CAAC,KAAK,CAAC;AAC7C;;;;;"}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var avatar$1 = require('./src/
|
|
6
|
-
var avatar = require('./src/
|
|
5
|
+
var avatar$1 = require('./src/avatar.js');
|
|
6
|
+
var avatar = require('./src/avatar2.js');
|
|
7
7
|
var install = require('../../utils/vue/install.js');
|
|
8
8
|
|
|
9
9
|
const ElAvatar = install.withInstall(avatar$1["default"]);
|
|
@@ -2,41 +2,74 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
6
|
-
var
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
var index$1 = require('../../icon/index.js');
|
|
7
|
+
var avatar = require('./avatar2.js');
|
|
8
|
+
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
9
|
+
var index = require('../../../hooks/use-namespace/index.js');
|
|
10
|
+
var shared = require('@vue/shared');
|
|
7
11
|
var types = require('../../../utils/types.js');
|
|
8
|
-
var
|
|
12
|
+
var style = require('../../../utils/dom/style.js');
|
|
9
13
|
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
14
|
+
const __default__ = vue.defineComponent({
|
|
15
|
+
name: "ElAvatar"
|
|
16
|
+
});
|
|
17
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
18
|
+
...__default__,
|
|
19
|
+
props: avatar.avatarProps,
|
|
20
|
+
emits: avatar.avatarEmits,
|
|
21
|
+
setup(__props, { emit }) {
|
|
22
|
+
const props = __props;
|
|
23
|
+
const ns = index.useNamespace("avatar");
|
|
24
|
+
const hasLoadError = vue.ref(false);
|
|
25
|
+
const avatarClass = vue.computed(() => {
|
|
26
|
+
const { size, icon, shape } = props;
|
|
27
|
+
const classList = [ns.b()];
|
|
28
|
+
if (shared.isString(size))
|
|
29
|
+
classList.push(ns.m(size));
|
|
30
|
+
if (icon)
|
|
31
|
+
classList.push(ns.m("icon"));
|
|
32
|
+
if (shape)
|
|
33
|
+
classList.push(ns.m(shape));
|
|
34
|
+
return classList;
|
|
35
|
+
});
|
|
36
|
+
const sizeStyle = vue.computed(() => {
|
|
37
|
+
const { size } = props;
|
|
38
|
+
return types.isNumber(size) ? ns.cssVarBlock({
|
|
39
|
+
size: style.addUnit(size)
|
|
40
|
+
}) : void 0;
|
|
41
|
+
});
|
|
42
|
+
const fitStyle = vue.computed(() => ({
|
|
43
|
+
objectFit: props.fit
|
|
44
|
+
}));
|
|
45
|
+
vue.watch(() => props.src, () => hasLoadError.value = false);
|
|
46
|
+
function handleError(e) {
|
|
47
|
+
hasLoadError.value = true;
|
|
48
|
+
emit("error", e);
|
|
49
|
+
}
|
|
50
|
+
return (_ctx, _cache) => {
|
|
51
|
+
return vue.openBlock(), vue.createElementBlock("span", {
|
|
52
|
+
class: vue.normalizeClass(vue.unref(avatarClass)),
|
|
53
|
+
style: vue.normalizeStyle(vue.unref(sizeStyle))
|
|
54
|
+
}, [
|
|
55
|
+
(_ctx.src || _ctx.srcSet) && !hasLoadError.value ? (vue.openBlock(), vue.createElementBlock("img", {
|
|
56
|
+
key: 0,
|
|
57
|
+
src: _ctx.src,
|
|
58
|
+
alt: _ctx.alt,
|
|
59
|
+
srcset: _ctx.srcSet,
|
|
60
|
+
style: vue.normalizeStyle(vue.unref(fitStyle)),
|
|
61
|
+
onError: handleError
|
|
62
|
+
}, null, 44, ["src", "alt", "srcset"])) : _ctx.icon ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), { key: 1 }, {
|
|
63
|
+
default: vue.withCtx(() => [
|
|
64
|
+
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.icon)))
|
|
65
|
+
]),
|
|
66
|
+
_: 1
|
|
67
|
+
})) : vue.renderSlot(_ctx.$slots, "default", { key: 2 })
|
|
68
|
+
], 6);
|
|
69
|
+
};
|
|
34
70
|
}
|
|
35
71
|
});
|
|
36
|
-
|
|
37
|
-
error: (evt) => evt instanceof Event
|
|
38
|
-
};
|
|
72
|
+
var Avatar = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "avatar.vue"]]);
|
|
39
73
|
|
|
40
|
-
exports
|
|
41
|
-
exports.avatarProps = avatarProps;
|
|
74
|
+
exports["default"] = Avatar;
|
|
42
75
|
//# sourceMappingURL=avatar.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"avatar.js","sources":["../../../../../../packages/components/avatar/src/avatar.
|
|
1
|
+
{"version":3,"file":"avatar.js","sources":["../../../../../../packages/components/avatar/src/avatar.vue"],"sourcesContent":["<template>\n <span :class=\"avatarClass\" :style=\"sizeStyle\">\n <img\n v-if=\"(src || srcSet) && !hasLoadError\"\n :src=\"src\"\n :alt=\"alt\"\n :srcset=\"srcSet\"\n :style=\"fitStyle\"\n @error=\"handleError\"\n />\n <el-icon v-else-if=\"icon\">\n <component :is=\"icon\" />\n </el-icon>\n <slot v-else />\n </span>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, ref, watch } from 'vue'\nimport { ElIcon } from '@element-plus/components/icon'\nimport { useNamespace } from '@element-plus/hooks'\nimport { addUnit, isNumber, isString } from '@element-plus/utils'\nimport { avatarEmits, avatarProps } from './avatar'\n\nimport type { CSSProperties } from 'vue'\n\ndefineOptions({\n name: 'ElAvatar',\n})\n\nconst props = defineProps(avatarProps)\nconst emit = defineEmits(avatarEmits)\n\nconst ns = useNamespace('avatar')\n\nconst hasLoadError = ref(false)\n\nconst avatarClass = computed(() => {\n const { size, icon, shape } = props\n const classList = [ns.b()]\n if (isString(size)) classList.push(ns.m(size))\n if (icon) classList.push(ns.m('icon'))\n if (shape) classList.push(ns.m(shape))\n return classList\n})\n\nconst sizeStyle = computed(() => {\n const { size } = props\n return isNumber(size)\n ? (ns.cssVarBlock({\n size: addUnit(size)!,\n }) as CSSProperties)\n : undefined\n})\n\nconst fitStyle = computed<CSSProperties>(() => ({\n objectFit: props.fit,\n}))\n\n// need reset hasLoadError to false if src changed\nwatch(\n () => props.src,\n () => (hasLoadError.value = false)\n)\n\nfunction handleError(e: Event) {\n hasLoadError.value = true\n emit('error', e)\n}\n</script>\n"],"names":["useNamespace","ref","computed","isString","isNumber","addUnit","watch"],"mappings":";;;;;;;;;;;;;uCA0Bc,CAAA;AAAA,EACZ,IAAM,EAAA,UAAA;AACR,CAAA,CAAA,CAAA;;;;;;;AAKA,IAAM,MAAA,EAAA,GAAKA,mBAAa,QAAQ,CAAA,CAAA;AAEhC,IAAM,MAAA,YAAA,GAAeC,QAAI,KAAK,CAAA,CAAA;AAE9B,IAAM,MAAA,WAAA,GAAcC,aAAS,MAAM;AACjC,MAAA,MAAM,EAAE,IAAA,EAAM,IAAM,EAAA,KAAA,EAAU,GAAA,KAAA,CAAA;AAC9B,MAAA,MAAM,SAAY,GAAA,CAAC,EAAG,CAAA,CAAA,EAAG,CAAA,CAAA;AACzB,MAAI,IAAAC,eAAA,CAAS,IAAI,CAAG;AACpB,QAAA,SAAoB,CAAA,IAAA,CAAA,EAAA,CAAA,CAAA,CAAA,IAAQ,CAAA,CAAA,CAAA;AAC5B,MAAA,IAAI;AACJ,QAAO,SAAA,CAAA,IAAA,CAAA,EAAA,CAAA,CAAA,CAAA,MAAA,CAAA,CAAA,CAAA;AAAA,MACR,IAAA,KAAA;AAED,QAAM,SAAA,CAAA,IAAY,WAAe,CAAA,CAAA,CAAA;AAC/B,MAAM,OAAA,SAAW,CAAA;AACjB,KAAA,CAAA,CAAA;AACoB,IACd,MAAA,YAAcD,YAAI,CAAA,MAAA;AAAA,MACpB,MACA,EAAA,IAAA,EAAA,GAAA,KAAA,CAAA;AAAA,MACL,OAAAE,cAAA,CAAA,IAAA,CAAA,GAAA,EAAA,CAAA,WAAA,CAAA;AAED,QAAM,IAAA,EAAAC,aAAW;AAA+B,iBACnC,CAAM;AAAA,KACjB,CAAA,CAAA;AAGF,IAAA,MAAA,QAAA,GAAAH,YAAA,CAAA,OAAA;AAAA,MACE,SAAY,EAAA,KAAA,CAAA,GAAA;AAAA,KACZ,CAAA,CAAA,CAAA;AAA4B,IAC9BI,SAAA,CAAA,MAAA,KAAA,CAAA,GAAA,EAAA,MAAA,YAAA,CAAA,KAAA,GAAA,KAAA,CAAA,CAAA;AAEA,IAAA,SAAS,YAAY,CAAU,EAAA;AAC7B,MAAA,YAAA,CAAa,KAAQ,GAAA,IAAA,CAAA;AACrB,MAAA,IAAA,CAAK,SAAS,CAAC,CAAA,CAAA;AAAA,KACjB;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -2,74 +2,41 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var avatar = require('./avatar.js');
|
|
8
|
-
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
9
|
-
var index = require('../../../hooks/use-namespace/index.js');
|
|
10
|
-
var shared = require('@vue/shared');
|
|
5
|
+
var runtime = require('../../../utils/vue/props/runtime.js');
|
|
6
|
+
var size = require('../../../constants/size.js');
|
|
11
7
|
var types = require('../../../utils/types.js');
|
|
12
|
-
var
|
|
8
|
+
var icon = require('../../../utils/vue/icon.js');
|
|
13
9
|
|
|
14
|
-
const
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
return types.isNumber(size) ? ns.cssVarBlock({
|
|
39
|
-
size: style.addUnit(size)
|
|
40
|
-
}) : void 0;
|
|
41
|
-
});
|
|
42
|
-
const fitStyle = vue.computed(() => ({
|
|
43
|
-
objectFit: props.fit
|
|
44
|
-
}));
|
|
45
|
-
vue.watch(() => props.src, () => hasLoadError.value = false);
|
|
46
|
-
function handleError(e) {
|
|
47
|
-
hasLoadError.value = true;
|
|
48
|
-
emit("error", e);
|
|
49
|
-
}
|
|
50
|
-
return (_ctx, _cache) => {
|
|
51
|
-
return vue.openBlock(), vue.createElementBlock("span", {
|
|
52
|
-
class: vue.normalizeClass(vue.unref(avatarClass)),
|
|
53
|
-
style: vue.normalizeStyle(vue.unref(sizeStyle))
|
|
54
|
-
}, [
|
|
55
|
-
(_ctx.src || _ctx.srcSet) && !hasLoadError.value ? (vue.openBlock(), vue.createElementBlock("img", {
|
|
56
|
-
key: 0,
|
|
57
|
-
src: _ctx.src,
|
|
58
|
-
alt: _ctx.alt,
|
|
59
|
-
srcset: _ctx.srcSet,
|
|
60
|
-
style: vue.normalizeStyle(vue.unref(fitStyle)),
|
|
61
|
-
onError: handleError
|
|
62
|
-
}, null, 44, ["src", "alt", "srcset"])) : _ctx.icon ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), { key: 1 }, {
|
|
63
|
-
default: vue.withCtx(() => [
|
|
64
|
-
(vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.icon)))
|
|
65
|
-
]),
|
|
66
|
-
_: 1
|
|
67
|
-
})) : vue.renderSlot(_ctx.$slots, "default", { key: 2 })
|
|
68
|
-
], 6);
|
|
69
|
-
};
|
|
10
|
+
const avatarProps = runtime.buildProps({
|
|
11
|
+
size: {
|
|
12
|
+
type: [Number, String],
|
|
13
|
+
values: size.componentSizes,
|
|
14
|
+
default: "",
|
|
15
|
+
validator: (val) => types.isNumber(val)
|
|
16
|
+
},
|
|
17
|
+
shape: {
|
|
18
|
+
type: String,
|
|
19
|
+
values: ["circle", "square"],
|
|
20
|
+
default: "circle"
|
|
21
|
+
},
|
|
22
|
+
icon: {
|
|
23
|
+
type: icon.iconPropType
|
|
24
|
+
},
|
|
25
|
+
src: {
|
|
26
|
+
type: String,
|
|
27
|
+
default: ""
|
|
28
|
+
},
|
|
29
|
+
alt: String,
|
|
30
|
+
srcSet: String,
|
|
31
|
+
fit: {
|
|
32
|
+
type: runtime.definePropType(String),
|
|
33
|
+
default: "cover"
|
|
70
34
|
}
|
|
71
35
|
});
|
|
72
|
-
|
|
36
|
+
const avatarEmits = {
|
|
37
|
+
error: (evt) => evt instanceof Event
|
|
38
|
+
};
|
|
73
39
|
|
|
74
|
-
exports
|
|
40
|
+
exports.avatarEmits = avatarEmits;
|
|
41
|
+
exports.avatarProps = avatarProps;
|
|
75
42
|
//# sourceMappingURL=avatar2.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"avatar2.js","sources":["../../../../../../packages/components/avatar/src/avatar.
|
|
1
|
+
{"version":3,"file":"avatar2.js","sources":["../../../../../../packages/components/avatar/src/avatar.ts"],"sourcesContent":["import {\n buildProps,\n definePropType,\n iconPropType,\n isNumber,\n} from '@element-plus/utils'\nimport { componentSizes } from '@element-plus/constants'\n\nimport type { ExtractPropTypes, __ExtractPublicPropTypes } from 'vue'\nimport type { ObjectFitProperty } from 'csstype'\n\nexport const avatarProps = buildProps({\n /**\n * @description avatar size.\n */\n size: {\n type: [Number, String],\n values: componentSizes,\n default: '',\n validator: (val: unknown): val is number => isNumber(val),\n },\n /**\n * @description avatar shape.\n */\n shape: {\n type: String,\n values: ['circle', 'square'],\n default: 'circle',\n },\n /**\n * @description representation type to icon, more info on icon component.\n */\n icon: {\n type: iconPropType,\n },\n /**\n * @description the source of the image for an image avatar.\n */\n src: {\n type: String,\n default: '',\n },\n /**\n * @description native attribute `alt` of image avatar.\n */\n alt: String,\n /**\n * @description native attribute srcset of image avatar.\n */\n srcSet: String,\n /**\n * @description set how the image fit its container for an image avatar.\n */\n fit: {\n type: definePropType<ObjectFitProperty>(String),\n default: 'cover',\n },\n} as const)\nexport type AvatarProps = ExtractPropTypes<typeof avatarProps>\nexport type AvatarPropsPublic = __ExtractPublicPropTypes<typeof avatarProps>\n\nexport const avatarEmits = {\n error: (evt: Event) => evt instanceof Event,\n}\nexport type AvatarEmits = typeof avatarEmits\n"],"names":["buildProps","componentSizes","isNumber","iconPropType","definePropType"],"mappings":";;;;;;;;;AAOY,MAAC,WAAW,GAAGA,kBAAU,CAAC;AACtC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,IAAI,MAAM,EAAEC,mBAAc;AAC1B,IAAI,OAAO,EAAE,EAAE;AACf,IAAI,SAAS,EAAE,CAAC,GAAG,KAAKC,cAAQ,CAAC,GAAG,CAAC;AACrC,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAC;AAChC,IAAI,OAAO,EAAE,QAAQ;AACrB,GAAG;AACH,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAEC,iBAAY;AACtB,GAAG;AACH,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,GAAG,EAAE,MAAM;AACb,EAAE,MAAM,EAAE,MAAM;AAChB,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAEC,sBAAc,CAAC,MAAM,CAAC;AAChC,IAAI,OAAO,EAAE,OAAO;AACpB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,WAAW,GAAG;AAC3B,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,KAAK;AACtC;;;;;"}
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var button$1 = require('./src/
|
|
5
|
+
var button$1 = require('./src/button.js');
|
|
6
6
|
var buttonGroup = require('./src/button-group2.js');
|
|
7
|
-
var button = require('./src/
|
|
7
|
+
var button = require('./src/button2.js');
|
|
8
8
|
var constants = require('./src/constants.js');
|
|
9
9
|
var install = require('../../utils/vue/install.js');
|
|
10
10
|
|