@element-plus/nightly 0.0.20221019 → 0.0.20221020
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 +289 -249
- package/dist/index.full.min.js +12 -12
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +13 -13
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +289 -249
- 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.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/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/hr.js +1 -1
- package/dist/locale/hr.min.js +1 -1
- package/dist/locale/hr.min.mjs +1 -1
- package/dist/locale/hr.mjs +1 -1
- package/dist/locale/hu.js +1 -1
- package/dist/locale/hu.min.js +1 -1
- package/dist/locale/hu.min.mjs +1 -1
- package/dist/locale/hu.mjs +1 -1
- package/dist/locale/hy-am.js +1 -1
- package/dist/locale/hy-am.min.js +1 -1
- package/dist/locale/hy-am.min.mjs +1 -1
- package/dist/locale/hy-am.mjs +1 -1
- package/dist/locale/id.js +1 -1
- package/dist/locale/id.min.js +1 -1
- package/dist/locale/id.min.mjs +1 -1
- package/dist/locale/id.mjs +1 -1
- package/dist/locale/it.js +1 -1
- package/dist/locale/it.min.js +1 -1
- package/dist/locale/it.min.mjs +1 -1
- package/dist/locale/it.mjs +1 -1
- package/dist/locale/ja.js +1 -1
- package/dist/locale/ja.min.js +1 -1
- package/dist/locale/ja.min.mjs +1 -1
- package/dist/locale/ja.mjs +1 -1
- package/dist/locale/kk.js +1 -1
- package/dist/locale/kk.min.js +1 -1
- package/dist/locale/kk.min.mjs +1 -1
- package/dist/locale/kk.mjs +1 -1
- package/dist/locale/km.js +1 -1
- package/dist/locale/km.min.js +1 -1
- package/dist/locale/km.min.mjs +1 -1
- package/dist/locale/km.mjs +1 -1
- package/dist/locale/ko.js +1 -1
- package/dist/locale/ko.min.js +1 -1
- package/dist/locale/ko.min.mjs +1 -1
- package/dist/locale/ko.mjs +1 -1
- package/dist/locale/ku.js +1 -1
- package/dist/locale/ku.min.js +1 -1
- package/dist/locale/ku.min.mjs +1 -1
- package/dist/locale/ku.mjs +1 -1
- package/dist/locale/ky.js +1 -1
- package/dist/locale/ky.min.js +1 -1
- package/dist/locale/ky.min.mjs +1 -1
- package/dist/locale/ky.mjs +1 -1
- package/dist/locale/lt.js +1 -1
- package/dist/locale/lt.min.js +1 -1
- package/dist/locale/lt.min.mjs +1 -1
- package/dist/locale/lt.mjs +1 -1
- package/dist/locale/lv.js +1 -1
- package/dist/locale/lv.min.js +1 -1
- package/dist/locale/lv.min.mjs +1 -1
- package/dist/locale/lv.mjs +1 -1
- package/dist/locale/mg.js +1 -1
- package/dist/locale/mg.min.js +1 -1
- package/dist/locale/mg.min.mjs +1 -1
- package/dist/locale/mg.mjs +1 -1
- package/dist/locale/mn.js +1 -1
- package/dist/locale/mn.min.js +1 -1
- package/dist/locale/mn.min.mjs +1 -1
- package/dist/locale/mn.mjs +1 -1
- package/dist/locale/nb-no.js +1 -1
- package/dist/locale/nb-no.min.js +1 -1
- package/dist/locale/nb-no.min.mjs +1 -1
- package/dist/locale/nb-no.mjs +1 -1
- package/dist/locale/nl.js +1 -1
- package/dist/locale/nl.min.js +1 -1
- package/dist/locale/nl.min.mjs +1 -1
- package/dist/locale/nl.mjs +1 -1
- package/dist/locale/pa.js +1 -1
- package/dist/locale/pa.min.js +1 -1
- package/dist/locale/pa.min.mjs +1 -1
- package/dist/locale/pa.mjs +1 -1
- package/dist/locale/pl.js +1 -1
- package/dist/locale/pl.min.js +1 -1
- package/dist/locale/pl.min.mjs +1 -1
- package/dist/locale/pl.mjs +1 -1
- package/dist/locale/pt-br.js +1 -1
- package/dist/locale/pt-br.min.js +1 -1
- package/dist/locale/pt-br.min.mjs +1 -1
- package/dist/locale/pt-br.mjs +1 -1
- package/dist/locale/pt.js +1 -1
- package/dist/locale/pt.min.js +1 -1
- package/dist/locale/pt.min.mjs +1 -1
- package/dist/locale/pt.mjs +1 -1
- package/dist/locale/ro.js +1 -1
- package/dist/locale/ro.min.js +1 -1
- package/dist/locale/ro.min.mjs +1 -1
- package/dist/locale/ro.mjs +1 -1
- package/dist/locale/ru.js +1 -1
- package/dist/locale/ru.min.js +1 -1
- package/dist/locale/ru.min.mjs +1 -1
- package/dist/locale/ru.mjs +1 -1
- package/dist/locale/sk.js +1 -1
- package/dist/locale/sk.min.js +1 -1
- package/dist/locale/sk.min.mjs +1 -1
- package/dist/locale/sk.mjs +1 -1
- package/dist/locale/sl.js +1 -1
- package/dist/locale/sl.min.js +1 -1
- package/dist/locale/sl.min.mjs +1 -1
- package/dist/locale/sl.mjs +1 -1
- package/dist/locale/sr.js +1 -1
- package/dist/locale/sr.min.js +1 -1
- package/dist/locale/sr.min.mjs +1 -1
- package/dist/locale/sr.mjs +1 -1
- package/dist/locale/sv.js +1 -1
- package/dist/locale/sv.min.js +1 -1
- package/dist/locale/sv.min.mjs +1 -1
- package/dist/locale/sv.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/th.js +1 -1
- package/dist/locale/th.min.js +1 -1
- package/dist/locale/th.min.mjs +1 -1
- package/dist/locale/th.mjs +1 -1
- package/dist/locale/tk.js +1 -1
- package/dist/locale/tk.min.js +1 -1
- package/dist/locale/tk.min.mjs +1 -1
- package/dist/locale/tk.mjs +1 -1
- package/dist/locale/tr.js +1 -1
- package/dist/locale/tr.min.js +1 -1
- package/dist/locale/tr.min.mjs +1 -1
- package/dist/locale/tr.mjs +1 -1
- package/dist/locale/ug-cn.js +1 -1
- package/dist/locale/ug-cn.min.js +1 -1
- package/dist/locale/ug-cn.min.mjs +1 -1
- package/dist/locale/ug-cn.mjs +1 -1
- package/dist/locale/uk.js +1 -1
- package/dist/locale/uk.min.js +1 -1
- package/dist/locale/uk.min.mjs +1 -1
- package/dist/locale/uk.mjs +1 -1
- package/dist/locale/uz-uz.js +1 -1
- package/dist/locale/uz-uz.min.js +1 -1
- package/dist/locale/uz-uz.min.mjs +1 -1
- package/dist/locale/uz-uz.mjs +1 -1
- package/dist/locale/vi.js +1 -1
- package/dist/locale/vi.min.js +1 -1
- package/dist/locale/vi.min.mjs +1 -1
- package/dist/locale/vi.mjs +1 -1
- package/dist/locale/zh-cn.js +1 -1
- package/dist/locale/zh-cn.min.js +1 -1
- package/dist/locale/zh-cn.min.mjs +1 -1
- package/dist/locale/zh-cn.mjs +1 -1
- package/dist/locale/zh-tw.js +1 -1
- package/dist/locale/zh-tw.min.js +1 -1
- package/dist/locale/zh-tw.min.mjs +1 -1
- package/dist/locale/zh-tw.mjs +1 -1
- package/es/components/backtop/index.d.ts +2 -6
- package/es/components/backtop/index.mjs.map +1 -1
- package/es/components/backtop/src/backtop.d.ts +0 -2
- package/es/components/backtop/src/backtop.mjs.map +1 -1
- package/es/components/backtop/src/backtop.vue.d.ts +5 -10
- package/es/components/backtop/src/backtop2.mjs +6 -52
- package/es/components/backtop/src/backtop2.mjs.map +1 -1
- package/es/components/backtop/src/instance.d.ts +2 -0
- package/es/components/backtop/src/instance.mjs +2 -0
- package/es/components/backtop/src/instance.mjs.map +1 -0
- package/es/components/backtop/src/use-backtop.d.ts +6 -0
- package/es/components/backtop/src/use-backtop.mjs +58 -0
- package/es/components/backtop/src/use-backtop.mjs.map +1 -0
- package/es/components/button/index.d.ts +4 -10
- package/es/components/button/index.mjs.map +1 -1
- package/es/components/button/src/button-group.d.ts +0 -2
- package/es/components/button/src/button-group.mjs.map +1 -1
- package/es/components/button/src/button.d.ts +0 -2
- package/es/components/button/src/button.mjs.map +1 -1
- package/es/components/button/src/button.vue.d.ts +3 -10
- package/es/components/button/src/button2.mjs +5 -46
- package/es/components/button/src/button2.mjs.map +1 -1
- package/es/components/button/src/instance.d.ts +4 -0
- package/es/components/button/src/instance.mjs +2 -0
- package/es/components/button/src/instance.mjs.map +1 -0
- package/es/components/button/src/use-button.d.ts +10 -0
- package/es/components/button/src/use-button.mjs +59 -0
- package/es/components/button/src/use-button.mjs.map +1 -0
- package/es/components/calendar/index.d.ts +16 -25
- package/es/components/calendar/index.mjs.map +1 -1
- package/es/components/calendar/src/calendar.vue.d.ts +15 -25
- package/es/components/calendar/src/date-table.d.ts +0 -2
- package/es/components/calendar/src/date-table.mjs.map +1 -1
- package/es/components/calendar/src/date-table.vue.d.ts +26 -31
- package/es/components/calendar/src/date-table2.mjs +14 -82
- package/es/components/calendar/src/date-table2.mjs.map +1 -1
- package/es/components/calendar/src/instance.d.ts +3 -0
- package/es/components/calendar/src/instance.mjs +2 -0
- package/es/components/calendar/src/instance.mjs.map +1 -0
- package/es/components/calendar/src/use-date-table.d.ts +18 -0
- package/es/components/calendar/src/use-date-table.mjs +96 -0
- package/es/components/calendar/src/use-date-table.mjs.map +1 -0
- package/es/components/color-picker/index.d.ts +3 -10
- package/es/components/color-picker/src/color-picker.vue.d.ts +3 -10
- package/es/components/date-picker/src/date-picker-com/panel-date-pick.vue.d.ts +3 -10
- package/es/components/date-picker/src/date-picker-com/panel-date-range.vue.d.ts +3 -10
- package/es/components/date-picker/src/panel-utils.d.ts +6 -20
- package/es/components/index.mjs +4 -4
- package/es/components/menu/src/menu-item2.mjs +1 -1
- package/es/components/message/index.mjs +1 -1
- package/es/components/message/src/message.mjs +146 -86
- package/es/components/message/src/message.mjs.map +1 -1
- package/es/components/message/src/message2.mjs +86 -146
- package/es/components/message/src/message2.mjs.map +1 -1
- package/es/components/message/src/method.mjs +2 -2
- package/es/components/popconfirm/index.d.ts +3 -10
- package/es/components/popconfirm/src/popconfirm.vue.d.ts +3 -10
- package/es/components/popper/index.mjs +4 -4
- package/es/components/popper/src/arrow.mjs +37 -8
- package/es/components/popper/src/arrow.mjs.map +1 -1
- package/es/components/popper/src/arrow2.mjs +8 -37
- package/es/components/popper/src/arrow2.mjs.map +1 -1
- package/es/components/popper/src/popper.mjs +33 -25
- package/es/components/popper/src/popper.mjs.map +1 -1
- package/es/components/popper/src/popper2.mjs +25 -33
- package/es/components/popper/src/popper2.mjs.map +1 -1
- package/es/components/skeleton/index.d.ts +1 -1
- package/es/components/skeleton/src/skeleton.vue.d.ts +1 -1
- package/es/components/tooltip/src/tooltip.mjs +2 -2
- package/es/components/tooltip/src/tooltip2.mjs +1 -1
- package/es/components/transfer/index.d.ts +3 -10
- package/es/components/transfer/src/transfer.vue.d.ts +3 -10
- package/es/index.mjs +4 -4
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/backtop/index.d.ts +2 -6
- package/lib/components/backtop/index.js.map +1 -1
- package/lib/components/backtop/src/backtop.d.ts +0 -2
- package/lib/components/backtop/src/backtop.js.map +1 -1
- package/lib/components/backtop/src/backtop.vue.d.ts +5 -10
- package/lib/components/backtop/src/backtop2.js +5 -51
- package/lib/components/backtop/src/backtop2.js.map +1 -1
- package/lib/components/backtop/src/instance.d.ts +2 -0
- package/lib/components/backtop/src/instance.js +3 -0
- package/lib/components/backtop/src/instance.js.map +1 -0
- package/lib/components/backtop/src/use-backtop.d.ts +6 -0
- package/lib/components/backtop/src/use-backtop.js +62 -0
- package/lib/components/backtop/src/use-backtop.js.map +1 -0
- package/lib/components/button/index.d.ts +4 -10
- package/lib/components/button/index.js.map +1 -1
- package/lib/components/button/src/button-group.d.ts +0 -2
- package/lib/components/button/src/button-group.js.map +1 -1
- package/lib/components/button/src/button.d.ts +0 -2
- package/lib/components/button/src/button.js.map +1 -1
- package/lib/components/button/src/button.vue.d.ts +3 -10
- package/lib/components/button/src/button2.js +8 -49
- package/lib/components/button/src/button2.js.map +1 -1
- package/lib/components/button/src/instance.d.ts +4 -0
- package/lib/components/button/src/instance.js +3 -0
- package/lib/components/button/src/instance.js.map +1 -0
- package/lib/components/button/src/use-button.d.ts +10 -0
- package/lib/components/button/src/use-button.js +63 -0
- package/lib/components/button/src/use-button.js.map +1 -0
- package/lib/components/calendar/index.d.ts +16 -25
- package/lib/components/calendar/index.js.map +1 -1
- package/lib/components/calendar/src/calendar.vue.d.ts +15 -25
- package/lib/components/calendar/src/date-table.d.ts +0 -2
- package/lib/components/calendar/src/date-table.js.map +1 -1
- package/lib/components/calendar/src/date-table.vue.d.ts +26 -31
- package/lib/components/calendar/src/date-table2.js +15 -88
- package/lib/components/calendar/src/date-table2.js.map +1 -1
- package/lib/components/calendar/src/instance.d.ts +3 -0
- package/lib/components/calendar/src/instance.js +3 -0
- package/lib/components/calendar/src/instance.js.map +1 -0
- package/lib/components/calendar/src/use-date-table.d.ts +18 -0
- package/lib/components/calendar/src/use-date-table.js +105 -0
- package/lib/components/calendar/src/use-date-table.js.map +1 -0
- package/lib/components/color-picker/index.d.ts +3 -10
- package/lib/components/color-picker/src/color-picker.vue.d.ts +3 -10
- package/lib/components/date-picker/src/date-picker-com/panel-date-pick.vue.d.ts +3 -10
- package/lib/components/date-picker/src/date-picker-com/panel-date-range.vue.d.ts +3 -10
- package/lib/components/date-picker/src/panel-utils.d.ts +6 -20
- package/lib/components/index.js +4 -4
- package/lib/components/menu/src/menu-item2.js +1 -1
- package/lib/components/message/index.js +1 -1
- package/lib/components/message/src/message.js +144 -87
- package/lib/components/message/src/message.js.map +1 -1
- package/lib/components/message/src/message2.js +87 -144
- package/lib/components/message/src/message2.js.map +1 -1
- package/lib/components/message/src/method.js +2 -2
- package/lib/components/popconfirm/index.d.ts +3 -10
- package/lib/components/popconfirm/src/popconfirm.vue.d.ts +3 -10
- package/lib/components/popper/index.js +4 -4
- package/lib/components/popper/src/arrow.js +37 -9
- package/lib/components/popper/src/arrow.js.map +1 -1
- package/lib/components/popper/src/arrow2.js +9 -37
- package/lib/components/popper/src/arrow2.js.map +1 -1
- package/lib/components/popper/src/popper.js +33 -28
- package/lib/components/popper/src/popper.js.map +1 -1
- package/lib/components/popper/src/popper2.js +28 -33
- package/lib/components/popper/src/popper2.js.map +1 -1
- package/lib/components/skeleton/index.d.ts +1 -1
- package/lib/components/skeleton/src/skeleton.vue.d.ts +1 -1
- package/lib/components/tooltip/src/tooltip.js +2 -2
- package/lib/components/tooltip/src/tooltip2.js +1 -1
- package/lib/components/transfer/index.d.ts +3 -10
- package/lib/components/transfer/src/transfer.vue.d.ts +3 -10
- package/lib/index.js +4 -4
- 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
|
@@ -1,38 +1,30 @@
|
|
|
1
|
-
import
|
|
2
|
-
import '../../../
|
|
3
|
-
import { popperProps } from './popper.mjs';
|
|
4
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
5
|
-
import { POPPER_INJECTION_KEY } from '../../../tokens/popper.mjs';
|
|
1
|
+
import '../../../utils/index.mjs';
|
|
2
|
+
import { buildProps } from '../../../utils/vue/props/runtime.mjs';
|
|
6
3
|
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
expose(popperProvides);
|
|
29
|
-
provide(POPPER_INJECTION_KEY, popperProvides);
|
|
30
|
-
return (_ctx, _cache) => {
|
|
31
|
-
return renderSlot(_ctx.$slots, "default");
|
|
32
|
-
};
|
|
4
|
+
const effects = ["light", "dark"];
|
|
5
|
+
const triggers = ["click", "contextmenu", "hover", "focus"];
|
|
6
|
+
const Effect = {
|
|
7
|
+
LIGHT: "light",
|
|
8
|
+
DARK: "dark"
|
|
9
|
+
};
|
|
10
|
+
const roleTypes = [
|
|
11
|
+
"dialog",
|
|
12
|
+
"grid",
|
|
13
|
+
"group",
|
|
14
|
+
"listbox",
|
|
15
|
+
"menu",
|
|
16
|
+
"navigation",
|
|
17
|
+
"tooltip",
|
|
18
|
+
"tree"
|
|
19
|
+
];
|
|
20
|
+
const popperProps = buildProps({
|
|
21
|
+
role: {
|
|
22
|
+
type: String,
|
|
23
|
+
values: roleTypes,
|
|
24
|
+
default: "tooltip"
|
|
33
25
|
}
|
|
34
26
|
});
|
|
35
|
-
|
|
27
|
+
const usePopperProps = popperProps;
|
|
36
28
|
|
|
37
|
-
export {
|
|
29
|
+
export { Effect, popperProps, roleTypes, usePopperProps };
|
|
38
30
|
//# sourceMappingURL=popper2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"popper2.mjs","sources":["../../../../../../packages/components/popper/src/popper.
|
|
1
|
+
{"version":3,"file":"popper2.mjs","sources":["../../../../../../packages/components/popper/src/popper.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\n\nimport type { ExtractPropTypes } from 'vue'\nimport type Popper from './popper.vue'\n\nconst effects = ['light', 'dark'] as const\nconst triggers = ['click', 'contextmenu', 'hover', 'focus'] as const\n\nexport const Effect = {\n LIGHT: 'light',\n DARK: 'dark',\n} as const\n\nexport const roleTypes = [\n 'dialog',\n 'grid',\n 'group',\n 'listbox',\n 'menu',\n 'navigation',\n 'tooltip',\n 'tree',\n] as const\n\nexport type PopperEffect = typeof effects[number]\nexport type PopperTrigger = typeof triggers[number]\n\nexport const popperProps = buildProps({\n role: {\n type: String,\n values: roleTypes,\n default: 'tooltip',\n },\n} as const)\n\nexport type PopperProps = ExtractPropTypes<typeof popperProps>\n\nexport type PopperInstance = InstanceType<typeof Popper>\n\n/** @deprecated use `popperProps` instead, and it will be deprecated in the next major version */\nexport const usePopperProps = popperProps\n\n/** @deprecated use `PopperProps` instead, and it will be deprecated in the next major version */\nexport type UsePopperProps = PopperProps\n"],"names":[],"mappings":";;;AACA,MAAM,OAAO,GAAG,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;AAClC,MAAM,QAAQ,GAAG,CAAC,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AAChD,MAAC,MAAM,GAAG;AACtB,EAAE,KAAK,EAAE,OAAO;AAChB,EAAE,IAAI,EAAE,MAAM;AACd,EAAE;AACU,MAAC,SAAS,GAAG;AACzB,EAAE,QAAQ;AACV,EAAE,MAAM;AACR,EAAE,OAAO;AACT,EAAE,SAAS;AACX,EAAE,MAAM;AACR,EAAE,YAAY;AACd,EAAE,SAAS;AACX,EAAE,MAAM;AACR,EAAE;AACU,MAAC,WAAW,GAAG,UAAU,CAAC;AACtC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,SAAS;AACrB,IAAI,OAAO,EAAE,SAAS;AACtB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,cAAc,GAAG;;;;"}
|
|
@@ -83,9 +83,9 @@ export declare const ElSkeleton: import("element-plus/es/utils").SFCWithInstall<
|
|
|
83
83
|
};
|
|
84
84
|
}>>, {
|
|
85
85
|
readonly loading: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
86
|
+
readonly rows: number;
|
|
86
87
|
readonly animated: import("element-plus/es/utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
87
88
|
readonly count: number;
|
|
88
|
-
readonly rows: number;
|
|
89
89
|
}>> & {
|
|
90
90
|
SkeletonItem: import("vue").DefineComponent<{
|
|
91
91
|
readonly variant: import("element-plus/es/utils").EpPropFinalized<StringConstructor, "text" | "button" | "circle" | "caption" | "image" | "rect" | "h1" | "h3" | "p", unknown, "text", boolean>;
|
|
@@ -83,8 +83,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
83
83
|
};
|
|
84
84
|
}>>, {
|
|
85
85
|
readonly loading: import("../../../utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
86
|
+
readonly rows: number;
|
|
86
87
|
readonly animated: import("../../../utils").EpPropMergeType<BooleanConstructor, unknown, unknown>;
|
|
87
88
|
readonly count: number;
|
|
88
|
-
readonly rows: number;
|
|
89
89
|
}>;
|
|
90
90
|
export default _default;
|
|
@@ -5,8 +5,8 @@ import { useTooltipContentProps } from './content.mjs';
|
|
|
5
5
|
import { useTooltipTriggerProps } from './trigger.mjs';
|
|
6
6
|
import { createModelToggleComposable } from '../../../hooks/use-model-toggle/index.mjs';
|
|
7
7
|
import { buildProps } from '../../../utils/vue/props/runtime.mjs';
|
|
8
|
-
import { popperProps } from '../../popper/src/
|
|
9
|
-
import { popperArrowProps } from '../../popper/src/
|
|
8
|
+
import { popperProps } from '../../popper/src/popper2.mjs';
|
|
9
|
+
import { popperArrowProps } from '../../popper/src/arrow2.mjs';
|
|
10
10
|
|
|
11
11
|
const {
|
|
12
12
|
useModelToggleProps: useTooltipModelToggleProps,
|
|
@@ -14,7 +14,7 @@ import { isBoolean } from '@vueuse/core';
|
|
|
14
14
|
import { useId } from '../../../hooks/use-id/index.mjs';
|
|
15
15
|
import { useDelayedToggle } from '../../../hooks/use-delayed-toggle/index.mjs';
|
|
16
16
|
import { TOOLTIP_INJECTION_KEY } from '../../../tokens/tooltip.mjs';
|
|
17
|
-
import ElPopperArrow from '../../popper/src/
|
|
17
|
+
import ElPopperArrow from '../../popper/src/arrow.mjs';
|
|
18
18
|
|
|
19
19
|
const _hoisted_1 = ["innerHTML"];
|
|
20
20
|
const _hoisted_2 = { key: 1 };
|
|
@@ -4635,11 +4635,7 @@ export declare const ElTransfer: import("element-plus/es/utils").SFCWithInstall<
|
|
|
4635
4635
|
onClick?: ((evt: MouseEvent) => any) | undefined;
|
|
4636
4636
|
}>>;
|
|
4637
4637
|
emit: (event: "click", evt: MouseEvent) => void;
|
|
4638
|
-
|
|
4639
|
-
[name: string]: import("vue").Slot | undefined;
|
|
4640
|
-
}>;
|
|
4641
|
-
buttonGroupContext: import("../..").ButtonGroupContext | undefined;
|
|
4642
|
-
globalConfig: import("vue").Ref<import("..").ButtonConfigContext | undefined>;
|
|
4638
|
+
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
4643
4639
|
ns: {
|
|
4644
4640
|
namespace: import("vue").Ref<string>;
|
|
4645
4641
|
b: (blockSuffix?: string) => string;
|
|
@@ -4658,14 +4654,11 @@ export declare const ElTransfer: import("element-plus/es/utils").SFCWithInstall<
|
|
|
4658
4654
|
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
4659
4655
|
cssVarBlockName: (name: string) => string;
|
|
4660
4656
|
};
|
|
4661
|
-
form: import("../..").FormContext | undefined;
|
|
4662
|
-
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
4663
|
-
_disabled: import("vue").ComputedRef<boolean>;
|
|
4664
4657
|
_ref: import("vue").Ref<HTMLButtonElement | undefined>;
|
|
4658
|
+
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
4665
4659
|
_type: import("vue").ComputedRef<"" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text">;
|
|
4666
|
-
|
|
4660
|
+
_disabled: import("vue").ComputedRef<boolean>;
|
|
4667
4661
|
shouldAddSpace: import("vue").ComputedRef<boolean>;
|
|
4668
|
-
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
4669
4662
|
handleClick: (evt: MouseEvent) => void;
|
|
4670
4663
|
ElIcon: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
4671
4664
|
readonly size: {
|
|
@@ -4636,11 +4636,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
4636
4636
|
onClick?: ((evt: MouseEvent) => any) | undefined;
|
|
4637
4637
|
}>>;
|
|
4638
4638
|
emit: (event: "click", evt: MouseEvent) => void;
|
|
4639
|
-
|
|
4640
|
-
[name: string]: import("vue").Slot | undefined;
|
|
4641
|
-
}>;
|
|
4642
|
-
buttonGroupContext: import("../../..").ButtonGroupContext | undefined;
|
|
4643
|
-
globalConfig: import("vue").Ref<import("element-plus/es/components/button").ButtonConfigContext | undefined>;
|
|
4639
|
+
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
4644
4640
|
ns: {
|
|
4645
4641
|
namespace: import("vue").Ref<string>;
|
|
4646
4642
|
b: (blockSuffix?: string) => string;
|
|
@@ -4659,14 +4655,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
4659
4655
|
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
4660
4656
|
cssVarBlockName: (name: string) => string;
|
|
4661
4657
|
};
|
|
4662
|
-
form: import("../../..").FormContext | undefined;
|
|
4663
|
-
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
4664
|
-
_disabled: import("vue").ComputedRef<boolean>;
|
|
4665
4658
|
_ref: import("vue").Ref<HTMLButtonElement | undefined>;
|
|
4659
|
+
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
4666
4660
|
_type: import("vue").ComputedRef<"" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text">;
|
|
4667
|
-
|
|
4661
|
+
_disabled: import("vue").ComputedRef<boolean>;
|
|
4668
4662
|
shouldAddSpace: import("vue").ComputedRef<boolean>;
|
|
4669
|
-
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
4670
4663
|
handleClick: (evt: MouseEvent) => void;
|
|
4671
4664
|
ElIcon: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
4672
4665
|
readonly size: {
|
package/es/index.mjs
CHANGED
|
@@ -94,11 +94,11 @@ export { paginationEmits, paginationProps } from './components/pagination/src/pa
|
|
|
94
94
|
export { ElPagination } from './components/pagination/index.mjs';
|
|
95
95
|
export { popconfirmProps } from './components/popconfirm/src/popconfirm.mjs';
|
|
96
96
|
export { ElPopconfirm } from './components/popconfirm/index.mjs';
|
|
97
|
-
export { Effect, popperProps, roleTypes, usePopperProps } from './components/popper/src/
|
|
97
|
+
export { Effect, popperProps, roleTypes, usePopperProps } from './components/popper/src/popper2.mjs';
|
|
98
98
|
export { popperTriggerProps, usePopperTriggerProps } from './components/popper/src/trigger.mjs';
|
|
99
99
|
export { popperContentEmits, popperContentProps, popperCoreConfigProps, usePopperContentEmits, usePopperContentProps, usePopperCoreConfigProps } from './components/popper/src/content.mjs';
|
|
100
|
-
export { popperArrowProps, usePopperArrowProps } from './components/popper/src/
|
|
101
|
-
export { default as ElPopperArrow } from './components/popper/src/
|
|
100
|
+
export { popperArrowProps, usePopperArrowProps } from './components/popper/src/arrow2.mjs';
|
|
101
|
+
export { default as ElPopperArrow } from './components/popper/src/arrow.mjs';
|
|
102
102
|
export { default as ElPopperTrigger } from './components/popper/src/trigger2.mjs';
|
|
103
103
|
export { default as ElPopperContent } from './components/popper/src/content2.mjs';
|
|
104
104
|
export { ElPopper } from './components/popper/index.mjs';
|
|
@@ -182,7 +182,7 @@ export { ElInfiniteScroll } from './components/infinite-scroll/index.mjs';
|
|
|
182
182
|
export { ElLoading } from './components/loading/index.mjs';
|
|
183
183
|
export { vLoading as ElLoadingDirective, vLoading } from './components/loading/src/directive.mjs';
|
|
184
184
|
export { Loading as ElLoadingService } from './components/loading/src/service.mjs';
|
|
185
|
-
export { messageDefaults, messageEmits, messageProps, messageTypes } from './components/message/src/
|
|
185
|
+
export { messageDefaults, messageEmits, messageProps, messageTypes } from './components/message/src/message2.mjs';
|
|
186
186
|
export { ElMessage } from './components/message/index.mjs';
|
|
187
187
|
export { ElMessageBox } from './components/message-box/index.mjs';
|
|
188
188
|
export { notificationEmits, notificationProps, notificationTypes } from './components/notification/src/notification.mjs';
|
package/es/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.0.
|
|
1
|
+
export declare const version = "0.0.20221020";
|
package/es/version.mjs
CHANGED
package/es/version.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.mjs","sources":["../../../packages/element-plus/version.ts"],"sourcesContent":["export const version = '0.0.
|
|
1
|
+
{"version":3,"file":"version.mjs","sources":["../../../packages/element-plus/version.ts"],"sourcesContent":["export const version = '0.0.20221020'\n"],"names":[],"mappings":"AAAY,MAAC,OAAO,GAAG;;;;"}
|
|
@@ -56,17 +56,12 @@ export declare const ElBacktop: import("element-plus/es/utils").SFCWithInstall<i
|
|
|
56
56
|
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
57
57
|
cssVarBlockName: (name: string) => string;
|
|
58
58
|
};
|
|
59
|
-
|
|
60
|
-
container: import("vue").ShallowRef<HTMLElement | Document | undefined>;
|
|
59
|
+
handleClick: (event: MouseEvent) => void;
|
|
61
60
|
visible: import("vue").Ref<boolean>;
|
|
62
61
|
backTopStyle: import("vue").ComputedRef<{
|
|
63
62
|
right: string;
|
|
64
63
|
bottom: string;
|
|
65
64
|
}>;
|
|
66
|
-
scrollToTop: () => void;
|
|
67
|
-
handleScroll: () => void;
|
|
68
|
-
handleClick: (event: MouseEvent) => void;
|
|
69
|
-
handleScrollThrottled: () => void;
|
|
70
65
|
ElIcon: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
71
66
|
readonly size: {
|
|
72
67
|
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
@@ -160,3 +155,4 @@ export declare const ElBacktop: import("element-plus/es/utils").SFCWithInstall<i
|
|
|
160
155
|
}>> & Record<string, any>;
|
|
161
156
|
export default ElBacktop;
|
|
162
157
|
export * from './src/backtop';
|
|
158
|
+
export type { BacktopInstance } from './src/instance';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../../packages/components/backtop/index.ts"],"sourcesContent":["import { withInstall } from '@element-plus/utils'\n\nimport Backtop from './src/backtop.vue'\n\nexport const ElBacktop = withInstall(Backtop)\nexport default ElBacktop\n\nexport * from './src/backtop'\n"],"names":["withInstall","Backtop"],"mappings":";;;;;;;;;AAEY,MAAC,SAAS,GAAGA,mBAAW,CAACC,oBAAO;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../packages/components/backtop/index.ts"],"sourcesContent":["import { withInstall } from '@element-plus/utils'\n\nimport Backtop from './src/backtop.vue'\n\nexport const ElBacktop = withInstall(Backtop)\nexport default ElBacktop\n\nexport * from './src/backtop'\nexport type { BacktopInstance } from './src/instance'\n"],"names":["withInstall","Backtop"],"mappings":";;;;;;;;;AAEY,MAAC,SAAS,GAAGA,mBAAW,CAACC,oBAAO;;;;;;;"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { ExtractPropTypes } from 'vue';
|
|
2
|
-
import type Backtop from './backtop.vue';
|
|
3
2
|
export declare const backtopProps: {
|
|
4
3
|
readonly visibilityHeight: {
|
|
5
4
|
readonly type: NumberConstructor;
|
|
@@ -23,4 +22,3 @@ export declare const backtopEmits: {
|
|
|
23
22
|
click: (evt: MouseEvent) => boolean;
|
|
24
23
|
};
|
|
25
24
|
export declare type BacktopEmits = typeof backtopEmits;
|
|
26
|
-
export declare type BacktopInstance = InstanceType<typeof Backtop>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backtop.js","sources":["../../../../../../packages/components/backtop/src/backtop.ts"],"sourcesContent":["import type { ExtractPropTypes } from 'vue'\
|
|
1
|
+
{"version":3,"file":"backtop.js","sources":["../../../../../../packages/components/backtop/src/backtop.ts"],"sourcesContent":["import type { ExtractPropTypes } from 'vue'\n\nexport const backtopProps = {\n visibilityHeight: {\n type: Number,\n default: 200,\n },\n target: {\n type: String,\n default: '',\n },\n right: {\n type: Number,\n default: 40,\n },\n bottom: {\n type: Number,\n default: 40,\n },\n} as const\nexport type BacktopProps = ExtractPropTypes<typeof backtopProps>\n\nexport const backtopEmits = {\n click: (evt: MouseEvent) => evt instanceof MouseEvent,\n}\nexport type BacktopEmits = typeof backtopEmits\n"],"names":[],"mappings":";;;;AAAY,MAAC,YAAY,GAAG;AAC5B,EAAE,gBAAgB,EAAE;AACpB,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE;AACU,MAAC,YAAY,GAAG;AAC5B,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,UAAU;AAC3C;;;;;"}
|
|
@@ -56,20 +56,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
56
56
|
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
57
57
|
cssVarBlockName: (name: string) => string;
|
|
58
58
|
};
|
|
59
|
-
|
|
60
|
-
container: import("vue").ShallowRef<HTMLElement | Document | undefined>;
|
|
59
|
+
handleClick: (event: MouseEvent) => void;
|
|
61
60
|
visible: import("vue").Ref<boolean>;
|
|
62
61
|
backTopStyle: import("vue").ComputedRef<{
|
|
63
62
|
right: string;
|
|
64
63
|
bottom: string;
|
|
65
64
|
}>;
|
|
66
|
-
|
|
67
|
-
handleScroll: () => void;
|
|
68
|
-
handleClick: (event: MouseEvent) => void;
|
|
69
|
-
handleScrollThrottled: () => void;
|
|
70
|
-
ElIcon: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
65
|
+
ElIcon: import("../../../utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
71
66
|
readonly size: {
|
|
72
|
-
readonly type: import("vue").PropType<import("
|
|
67
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
73
68
|
readonly required: false;
|
|
74
69
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
75
70
|
__epPropKey: true;
|
|
@@ -83,7 +78,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
83
78
|
}, {
|
|
84
79
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
85
80
|
readonly size: {
|
|
86
|
-
readonly type: import("vue").PropType<import("
|
|
81
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
87
82
|
readonly required: false;
|
|
88
83
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
89
84
|
__epPropKey: true;
|
|
@@ -118,7 +113,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
118
113
|
style: import("vue").ComputedRef<import("vue").CSSProperties>;
|
|
119
114
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
120
115
|
readonly size: {
|
|
121
|
-
readonly type: import("vue").PropType<import("
|
|
116
|
+
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
122
117
|
readonly required: false;
|
|
123
118
|
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
124
119
|
__epPropKey: true;
|
|
@@ -3,18 +3,14 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var vue = require('vue');
|
|
6
|
-
var core = require('@vueuse/core');
|
|
7
6
|
var index$1 = require('../../icon/index.js');
|
|
8
|
-
require('../../../utils/index.js');
|
|
9
7
|
var iconsVue = require('@element-plus/icons-vue');
|
|
10
8
|
require('../../../hooks/index.js');
|
|
11
9
|
var backtop = require('./backtop.js');
|
|
10
|
+
var useBacktop = require('./use-backtop.js');
|
|
12
11
|
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
13
12
|
var index = require('../../../hooks/use-namespace/index.js');
|
|
14
|
-
var animation = require('../../../utils/animation.js');
|
|
15
|
-
var error = require('../../../utils/error.js');
|
|
16
13
|
|
|
17
|
-
const _hoisted_1 = ["onClick"];
|
|
18
14
|
const COMPONENT_NAME = "ElBacktop";
|
|
19
15
|
const __default__ = vue.defineComponent({
|
|
20
16
|
name: COMPONENT_NAME
|
|
@@ -26,63 +22,21 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
26
22
|
setup(__props, { emit }) {
|
|
27
23
|
const props = __props;
|
|
28
24
|
const ns = index.useNamespace("backtop");
|
|
29
|
-
const
|
|
30
|
-
const container = vue.shallowRef();
|
|
31
|
-
const visible = vue.ref(false);
|
|
25
|
+
const { handleClick, visible } = useBacktop.useBackTop(props, emit, COMPONENT_NAME);
|
|
32
26
|
const backTopStyle = vue.computed(() => ({
|
|
33
27
|
right: `${props.right}px`,
|
|
34
28
|
bottom: `${props.bottom}px`
|
|
35
29
|
}));
|
|
36
|
-
const scrollToTop = () => {
|
|
37
|
-
if (!el.value)
|
|
38
|
-
return;
|
|
39
|
-
const beginTime = Date.now();
|
|
40
|
-
const beginValue = el.value.scrollTop;
|
|
41
|
-
const frameFunc = () => {
|
|
42
|
-
if (!el.value)
|
|
43
|
-
return;
|
|
44
|
-
const progress = (Date.now() - beginTime) / 500;
|
|
45
|
-
if (progress < 1) {
|
|
46
|
-
el.value.scrollTop = beginValue * (1 - animation.easeInOutCubic(progress));
|
|
47
|
-
requestAnimationFrame(frameFunc);
|
|
48
|
-
} else {
|
|
49
|
-
el.value.scrollTop = 0;
|
|
50
|
-
}
|
|
51
|
-
};
|
|
52
|
-
requestAnimationFrame(frameFunc);
|
|
53
|
-
};
|
|
54
|
-
const handleScroll = () => {
|
|
55
|
-
if (el.value)
|
|
56
|
-
visible.value = el.value.scrollTop >= props.visibilityHeight;
|
|
57
|
-
};
|
|
58
|
-
const handleClick = (event) => {
|
|
59
|
-
scrollToTop();
|
|
60
|
-
emit("click", event);
|
|
61
|
-
};
|
|
62
|
-
const handleScrollThrottled = core.useThrottleFn(handleScroll, 300, true);
|
|
63
|
-
core.useEventListener(container, "scroll", handleScrollThrottled);
|
|
64
|
-
vue.onMounted(() => {
|
|
65
|
-
var _a;
|
|
66
|
-
container.value = document;
|
|
67
|
-
el.value = document.documentElement;
|
|
68
|
-
if (props.target) {
|
|
69
|
-
el.value = (_a = document.querySelector(props.target)) != null ? _a : void 0;
|
|
70
|
-
if (!el.value) {
|
|
71
|
-
error.throwError(COMPONENT_NAME, `target is not existed: ${props.target}`);
|
|
72
|
-
}
|
|
73
|
-
container.value = el.value;
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
30
|
return (_ctx, _cache) => {
|
|
77
31
|
return vue.openBlock(), vue.createBlock(vue.Transition, {
|
|
78
32
|
name: `${vue.unref(ns).namespace.value}-fade-in`
|
|
79
33
|
}, {
|
|
80
34
|
default: vue.withCtx(() => [
|
|
81
|
-
visible
|
|
35
|
+
vue.unref(visible) ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
82
36
|
key: 0,
|
|
83
37
|
style: vue.normalizeStyle(vue.unref(backTopStyle)),
|
|
84
38
|
class: vue.normalizeClass(vue.unref(ns).b()),
|
|
85
|
-
onClick: vue.withModifiers(handleClick, ["stop"])
|
|
39
|
+
onClick: _cache[0] || (_cache[0] = vue.withModifiers((...args) => vue.unref(handleClick) && vue.unref(handleClick)(...args), ["stop"]))
|
|
86
40
|
}, [
|
|
87
41
|
vue.renderSlot(_ctx.$slots, "default", {}, () => [
|
|
88
42
|
vue.createVNode(vue.unref(index$1.ElIcon), {
|
|
@@ -94,7 +48,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
94
48
|
_: 1
|
|
95
49
|
}, 8, ["class"])
|
|
96
50
|
])
|
|
97
|
-
],
|
|
51
|
+
], 6)) : vue.createCommentVNode("v-if", true)
|
|
98
52
|
]),
|
|
99
53
|
_: 3
|
|
100
54
|
}, 8, ["name"]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"backtop2.js","sources":["../../../../../../packages/components/backtop/src/backtop.vue"],"sourcesContent":["<template>\n <transition :name=\"`${ns.namespace.value}-fade-in`\">\n <div\n v-if=\"visible\"\n :style=\"backTopStyle\"\n :class=\"ns.b()\"\n @click.stop=\"handleClick\"\n >\n <slot>\n <el-icon :class=\"ns.e('icon')\"><caret-top /></el-icon>\n </slot>\n </div>\n </transition>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed
|
|
1
|
+
{"version":3,"file":"backtop2.js","sources":["../../../../../../packages/components/backtop/src/backtop.vue"],"sourcesContent":["<template>\n <transition :name=\"`${ns.namespace.value}-fade-in`\">\n <div\n v-if=\"visible\"\n :style=\"backTopStyle\"\n :class=\"ns.b()\"\n @click.stop=\"handleClick\"\n >\n <slot>\n <el-icon :class=\"ns.e('icon')\"><caret-top /></el-icon>\n </slot>\n </div>\n </transition>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport { ElIcon } from '@element-plus/components/icon'\nimport { CaretTop } from '@element-plus/icons-vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { backtopEmits, backtopProps } from './backtop'\nimport { useBackTop } from './use-backtop'\n\nconst COMPONENT_NAME = 'ElBacktop'\n\ndefineOptions({\n name: COMPONENT_NAME,\n})\n\nconst props = defineProps(backtopProps)\nconst emit = defineEmits(backtopEmits)\n\nconst ns = useNamespace('backtop')\n\nconst { handleClick, visible } = useBackTop(props, emit, COMPONENT_NAME)\n\nconst backTopStyle = computed(() => ({\n right: `${props.right}px`,\n bottom: `${props.bottom}px`,\n}))\n</script>\n"],"names":["useNamespace","useBackTop","computed"],"mappings":";;;;;;;;;;;;;;uCAyBc,CAAA;AAAA,EACZ,IAAM,EAAA,cAAA;AACR;;;;;;;AAKA,IAAM,MAAA,EAAA,GAAKA,mBAAa,SAAS,CAAA,CAAA;AAEjC,IAAA,MAAM,EAAE,WAAa,EAAA,OAAA,EAAA,GAAYC,qBAAW,CAAA,KAAA,EAAO,MAAM,cAAc,CAAA,CAAA;AAEvE,IAAM,MAAA,YAAA,GAAeC,aAAS,OAAO;AAAA,MACnC,KAAA,EAAO,GAAG,KAAM,CAAA,KAAA,CAAA,EAAA,CAAA;AAAA,MAChB,MAAA,EAAQ,GAAG,KAAM,CAAA,MAAA,CAAA,EAAA,CAAA;AAAA,KACjB,CAAA,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instance.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { SetupContext } from 'vue';
|
|
2
|
+
import type { BacktopEmits, BacktopProps } from './backtop';
|
|
3
|
+
export declare const useBackTop: (props: BacktopProps, emit: SetupContext<BacktopEmits>['emit'], componentName: string) => {
|
|
4
|
+
visible: import("vue").Ref<boolean>;
|
|
5
|
+
handleClick: (event: MouseEvent) => void;
|
|
6
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
var core = require('@vueuse/core');
|
|
7
|
+
require('../../../utils/index.js');
|
|
8
|
+
var animation = require('../../../utils/animation.js');
|
|
9
|
+
var error = require('../../../utils/error.js');
|
|
10
|
+
|
|
11
|
+
const useBackTop = (props, emit, componentName) => {
|
|
12
|
+
const el = vue.shallowRef();
|
|
13
|
+
const container = vue.shallowRef();
|
|
14
|
+
const visible = vue.ref(false);
|
|
15
|
+
const scrollToTop = () => {
|
|
16
|
+
if (!el.value)
|
|
17
|
+
return;
|
|
18
|
+
const beginTime = Date.now();
|
|
19
|
+
const beginValue = el.value.scrollTop;
|
|
20
|
+
const frameFunc = () => {
|
|
21
|
+
if (!el.value)
|
|
22
|
+
return;
|
|
23
|
+
const progress = (Date.now() - beginTime) / 500;
|
|
24
|
+
if (progress < 1) {
|
|
25
|
+
el.value.scrollTop = beginValue * (1 - animation.easeInOutCubic(progress));
|
|
26
|
+
requestAnimationFrame(frameFunc);
|
|
27
|
+
} else {
|
|
28
|
+
el.value.scrollTop = 0;
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
requestAnimationFrame(frameFunc);
|
|
32
|
+
};
|
|
33
|
+
const handleScroll = () => {
|
|
34
|
+
if (el.value)
|
|
35
|
+
visible.value = el.value.scrollTop >= props.visibilityHeight;
|
|
36
|
+
};
|
|
37
|
+
const handleClick = (event) => {
|
|
38
|
+
scrollToTop();
|
|
39
|
+
emit("click", event);
|
|
40
|
+
};
|
|
41
|
+
const handleScrollThrottled = core.useThrottleFn(handleScroll, 300, true);
|
|
42
|
+
core.useEventListener(container, "scroll", handleScrollThrottled);
|
|
43
|
+
vue.onMounted(() => {
|
|
44
|
+
var _a;
|
|
45
|
+
container.value = document;
|
|
46
|
+
el.value = document.documentElement;
|
|
47
|
+
if (props.target) {
|
|
48
|
+
el.value = (_a = document.querySelector(props.target)) != null ? _a : void 0;
|
|
49
|
+
if (!el.value) {
|
|
50
|
+
error.throwError(componentName, `target does not exist: ${props.target}`);
|
|
51
|
+
}
|
|
52
|
+
container.value = el.value;
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
return {
|
|
56
|
+
visible,
|
|
57
|
+
handleClick
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
exports.useBackTop = useBackTop;
|
|
62
|
+
//# sourceMappingURL=use-backtop.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-backtop.js","sources":["../../../../../../packages/components/backtop/src/use-backtop.ts"],"sourcesContent":["import { onMounted, ref, shallowRef } from 'vue'\nimport { useEventListener, useThrottleFn } from '@vueuse/core'\nimport { easeInOutCubic, throwError } from '@element-plus/utils'\n\nimport type { SetupContext } from 'vue'\nimport type { BacktopEmits, BacktopProps } from './backtop'\n\nexport const useBackTop = (\n props: BacktopProps,\n emit: SetupContext<BacktopEmits>['emit'],\n componentName: string\n) => {\n const el = shallowRef<HTMLElement>()\n const container = shallowRef<Document | HTMLElement>()\n const visible = ref(false)\n\n const scrollToTop = () => {\n // TODO: use https://developer.mozilla.org/en-US/docs/Web/API/Window/scrollTo, with behavior: 'smooth'\n\n if (!el.value) return\n const beginTime = Date.now()\n const beginValue = el.value.scrollTop\n const frameFunc = () => {\n if (!el.value) return\n const progress = (Date.now() - beginTime) / 500\n if (progress < 1) {\n el.value.scrollTop = beginValue * (1 - easeInOutCubic(progress))\n requestAnimationFrame(frameFunc)\n } else {\n el.value.scrollTop = 0\n }\n }\n requestAnimationFrame(frameFunc)\n }\n const handleScroll = () => {\n if (el.value) visible.value = el.value.scrollTop >= props.visibilityHeight\n }\n\n const handleClick = (event: MouseEvent) => {\n scrollToTop()\n emit('click', event)\n }\n\n const handleScrollThrottled = useThrottleFn(handleScroll, 300, true)\n\n useEventListener(container, 'scroll', handleScrollThrottled)\n onMounted(() => {\n container.value = document\n el.value = document.documentElement\n\n if (props.target) {\n el.value = document.querySelector<HTMLElement>(props.target) ?? undefined\n if (!el.value) {\n throwError(componentName, `target does not exist: ${props.target}`)\n }\n container.value = el.value\n }\n })\n\n return {\n visible,\n handleClick,\n }\n}\n"],"names":["shallowRef","ref","easeInOutCubic","useThrottleFn","useEventListener","onMounted","throwError"],"mappings":";;;;;;;;;;AAGY,MAAC,UAAU,GAAG,CAAC,KAAK,EAAE,IAAI,EAAE,aAAa,KAAK;AAC1D,EAAE,MAAM,EAAE,GAAGA,cAAU,EAAE,CAAC;AAC1B,EAAE,MAAM,SAAS,GAAGA,cAAU,EAAE,CAAC;AACjC,EAAE,MAAM,OAAO,GAAGC,OAAG,CAAC,KAAK,CAAC,CAAC;AAC7B,EAAE,MAAM,WAAW,GAAG,MAAM;AAC5B,IAAI,IAAI,CAAC,EAAE,CAAC,KAAK;AACjB,MAAM,OAAO;AACb,IAAI,MAAM,SAAS,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC;AACjC,IAAI,MAAM,UAAU,GAAG,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC;AAC1C,IAAI,MAAM,SAAS,GAAG,MAAM;AAC5B,MAAM,IAAI,CAAC,EAAE,CAAC,KAAK;AACnB,QAAQ,OAAO;AACf,MAAM,MAAM,QAAQ,GAAG,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,SAAS,IAAI,GAAG,CAAC;AACtD,MAAM,IAAI,QAAQ,GAAG,CAAC,EAAE;AACxB,QAAQ,EAAE,CAAC,KAAK,CAAC,SAAS,GAAG,UAAU,IAAI,CAAC,GAAGC,wBAAc,CAAC,QAAQ,CAAC,CAAC,CAAC;AACzE,QAAQ,qBAAqB,CAAC,SAAS,CAAC,CAAC;AACzC,OAAO,MAAM;AACb,QAAQ,EAAE,CAAC,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC;AAC/B,OAAO;AACP,KAAK,CAAC;AACN,IAAI,qBAAqB,CAAC,SAAS,CAAC,CAAC;AACrC,GAAG,CAAC;AACJ,EAAE,MAAM,YAAY,GAAG,MAAM;AAC7B,IAAI,IAAI,EAAE,CAAC,KAAK;AAChB,MAAM,OAAO,CAAC,KAAK,GAAG,EAAE,CAAC,KAAK,CAAC,SAAS,IAAI,KAAK,CAAC,gBAAgB,CAAC;AACnE,GAAG,CAAC;AACJ,EAAE,MAAM,WAAW,GAAG,CAAC,KAAK,KAAK;AACjC,IAAI,WAAW,EAAE,CAAC;AAClB,IAAI,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC;AACzB,GAAG,CAAC;AACJ,EAAE,MAAM,qBAAqB,GAAGC,kBAAa,CAAC,YAAY,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;AACvE,EAAEC,qBAAgB,CAAC,SAAS,EAAE,QAAQ,EAAE,qBAAqB,CAAC,CAAC;AAC/D,EAAEC,aAAS,CAAC,MAAM;AAClB,IAAI,IAAI,EAAE,CAAC;AACX,IAAI,SAAS,CAAC,KAAK,GAAG,QAAQ,CAAC;AAC/B,IAAI,EAAE,CAAC,KAAK,GAAG,QAAQ,CAAC,eAAe,CAAC;AACxC,IAAI,IAAI,KAAK,CAAC,MAAM,EAAE;AACtB,MAAM,EAAE,CAAC,KAAK,GAAG,CAAC,EAAE,GAAG,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,IAAI,GAAG,EAAE,GAAG,KAAK,CAAC,CAAC;AACnF,MAAM,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE;AACrB,QAAQC,gBAAU,CAAC,aAAa,EAAE,CAAC,uBAAuB,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AAC5E,OAAO;AACP,MAAM,SAAS,CAAC,KAAK,GAAG,EAAE,CAAC,KAAK,CAAC;AACjC,KAAK;AACL,GAAG,CAAC,CAAC;AACL,EAAE,OAAO;AACT,IAAI,OAAO;AACX,IAAI,WAAW;AACf,GAAG,CAAC;AACJ;;;;"}
|
|
@@ -59,11 +59,7 @@ export declare const ElButton: import("element-plus/es/utils").SFCWithInstall<im
|
|
|
59
59
|
onClick?: ((evt: MouseEvent) => any) | undefined;
|
|
60
60
|
}>>;
|
|
61
61
|
emit: (event: "click", evt: MouseEvent) => void;
|
|
62
|
-
|
|
63
|
-
[name: string]: import("vue").Slot | undefined;
|
|
64
|
-
}>;
|
|
65
|
-
buttonGroupContext: import("../..").ButtonGroupContext | undefined;
|
|
66
|
-
globalConfig: import("vue").Ref<import("./src/button").ButtonConfigContext | undefined>;
|
|
62
|
+
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
67
63
|
ns: {
|
|
68
64
|
namespace: import("vue").Ref<string>;
|
|
69
65
|
b: (blockSuffix?: string) => string;
|
|
@@ -82,14 +78,11 @@ export declare const ElButton: import("element-plus/es/utils").SFCWithInstall<im
|
|
|
82
78
|
cssVarBlock: (object: Record<string, string>) => Record<string, string>;
|
|
83
79
|
cssVarBlockName: (name: string) => string;
|
|
84
80
|
};
|
|
85
|
-
form: import("../..").FormContext | undefined;
|
|
86
|
-
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
87
|
-
_disabled: import("vue").ComputedRef<boolean>;
|
|
88
81
|
_ref: import("vue").Ref<HTMLButtonElement | undefined>;
|
|
82
|
+
_size: import("vue").ComputedRef<"" | "default" | "small" | "large">;
|
|
89
83
|
_type: import("vue").ComputedRef<"" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text">;
|
|
90
|
-
|
|
84
|
+
_disabled: import("vue").ComputedRef<boolean>;
|
|
91
85
|
shouldAddSpace: import("vue").ComputedRef<boolean>;
|
|
92
|
-
buttonStyle: import("vue").ComputedRef<Record<string, string>>;
|
|
93
86
|
handleClick: (evt: MouseEvent) => void;
|
|
94
87
|
ElIcon: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
95
88
|
readonly size: {
|
|
@@ -303,3 +296,4 @@ export declare const ElButtonGroup: import("element-plus/es/utils").SFCWithInsta
|
|
|
303
296
|
}>>;
|
|
304
297
|
export default ElButton;
|
|
305
298
|
export * from './src/button';
|
|
299
|
+
export type { ButtonInstance, ButtonGroupInstance } from './src/instance';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../../packages/components/button/index.ts"],"sourcesContent":["import { withInstall, withNoopInstall } from '@element-plus/utils'\nimport Button from './src/button.vue'\nimport ButtonGroup from './src/button-group.vue'\n\nexport const ElButton = withInstall(Button, {\n ButtonGroup,\n})\nexport const ElButtonGroup = withNoopInstall(ButtonGroup)\nexport default ElButton\n\nexport * from './src/button'\n"],"names":["withInstall","Button","ButtonGroup","withNoopInstall"],"mappings":";;;;;;;;;;AAGY,MAAC,QAAQ,GAAGA,mBAAW,CAACC,mBAAM,EAAE;AAC5C,eAAEC,sBAAW;AACb,CAAC,EAAE;AACS,MAAC,aAAa,GAAGC,uBAAe,CAACD,sBAAW;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../packages/components/button/index.ts"],"sourcesContent":["import { withInstall, withNoopInstall } from '@element-plus/utils'\nimport Button from './src/button.vue'\nimport ButtonGroup from './src/button-group.vue'\n\nexport const ElButton = withInstall(Button, {\n ButtonGroup,\n})\nexport const ElButtonGroup = withNoopInstall(ButtonGroup)\nexport default ElButton\n\nexport * from './src/button'\nexport type { ButtonInstance, ButtonGroupInstance } from './src/instance'\n"],"names":["withInstall","Button","ButtonGroup","withNoopInstall"],"mappings":";;;;;;;;;;AAGY,MAAC,QAAQ,GAAGA,mBAAW,CAACC,mBAAM,EAAE;AAC5C,eAAEC,sBAAW;AACb,CAAC,EAAE;AACS,MAAC,aAAa,GAAGC,uBAAe,CAACD,sBAAW;;;;;;;;;;"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { ExtractPropTypes } from 'vue';
|
|
2
|
-
import type buttonGroup from './button-group.vue';
|
|
3
2
|
export declare const buttonGroupProps: {
|
|
4
3
|
readonly size: {
|
|
5
4
|
readonly type: import("vue").PropType<import("../../../utils").EpPropMergeType<StringConstructor, "" | "default" | "small" | "large", never>>;
|
|
@@ -10,4 +9,3 @@ export declare const buttonGroupProps: {
|
|
|
10
9
|
readonly type: import("../../../utils").EpPropFinalized<StringConstructor, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown, "", boolean>;
|
|
11
10
|
};
|
|
12
11
|
export declare type ButtonGroupProps = ExtractPropTypes<typeof buttonGroupProps>;
|
|
13
|
-
export declare type ButtonGroupInstance = InstanceType<typeof buttonGroup>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button-group.js","sources":["../../../../../../packages/components/button/src/button-group.ts"],"sourcesContent":["import { buttonProps } from './button'\n\nimport type { ExtractPropTypes } from 'vue'\
|
|
1
|
+
{"version":3,"file":"button-group.js","sources":["../../../../../../packages/components/button/src/button-group.ts"],"sourcesContent":["import { buttonProps } from './button'\n\nimport type { ExtractPropTypes } from 'vue'\n\nexport const buttonGroupProps = {\n size: buttonProps.size,\n type: buttonProps.type,\n} as const\nexport type ButtonGroupProps = ExtractPropTypes<typeof buttonGroupProps>\n"],"names":["buttonProps"],"mappings":";;;;;;AACY,MAAC,gBAAgB,GAAG;AAChC,EAAE,IAAI,EAAEA,kBAAW,CAAC,IAAI;AACxB,EAAE,IAAI,EAAEA,kBAAW,CAAC,IAAI;AACxB;;;;"}
|