@element-plus/nightly 0.0.20220131 → 0.0.20220204
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.css +1 -1
- package/dist/index.full.js +348 -205
- package/dist/index.full.min.js +6 -6
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +6 -6
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +347 -207
- 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/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/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/autocomplete/index.d.ts +12 -4
- package/es/components/autocomplete/src/index.mjs +11 -4
- package/es/components/autocomplete/src/index.mjs.map +1 -1
- package/es/components/autocomplete/src/index.vue.d.ts +6 -2
- package/es/components/cascader/index.d.ts +12 -4
- package/es/components/cascader/src/index.mjs +12 -5
- package/es/components/cascader/src/index.mjs.map +1 -1
- package/es/components/cascader/src/index.vue.d.ts +6 -2
- package/es/components/dialog/index.d.ts +4 -0
- package/es/components/dialog/src/dialog.d.ts +1 -0
- package/es/components/dialog/src/dialog.mjs +4 -0
- package/es/components/dialog/src/dialog.mjs.map +1 -1
- package/es/components/dialog/src/dialog.vue.d.ts +4 -0
- package/es/components/dialog/src/dialog2.mjs +12 -3
- package/es/components/dialog/src/dialog2.mjs.map +1 -1
- package/es/components/drawer/index.d.ts +3 -0
- package/es/components/drawer/src/drawer.d.ts +1 -0
- package/es/components/drawer/src/drawer.vue.d.ts +3 -0
- package/es/components/index.mjs +1 -0
- package/es/components/index.mjs.map +1 -1
- package/es/components/message-box/src/index.mjs +133 -113
- package/es/components/message-box/src/index.mjs.map +1 -1
- package/es/components/message-box/src/index.vue.d.ts +14 -4
- package/es/components/message-box/src/message-box.type.d.ts +2 -0
- package/es/components/popconfirm/index.d.ts +26 -22
- package/es/components/popconfirm/src/popconfirm.d.ts +12 -11
- package/es/components/popconfirm/src/popconfirm.mjs +48 -43
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm.vue.d.ts +26 -22
- package/es/components/popconfirm/src/popconfirm2.mjs +8 -3
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/popover/index.d.ts +26 -0
- package/es/components/popover/src/index.mjs +8 -3
- package/es/components/popover/src/index.mjs.map +1 -1
- package/es/components/popover/src/index.vue.d.ts +39 -26
- package/es/components/popover/src/popover.d.ts +5 -0
- package/es/components/popover/src/popover.mjs +2 -0
- package/es/components/popover/src/popover.mjs.map +1 -1
- package/es/components/popper/index.d.ts +1 -0
- package/es/components/popper/index.mjs +1 -0
- package/es/components/popper/index.mjs.map +1 -1
- package/es/components/popper/src/deprecation.d.ts +3 -0
- package/es/components/popper/src/deprecation.mjs +24 -0
- package/es/components/popper/src/deprecation.mjs.map +1 -0
- package/es/components/select/index.d.ts +6 -2
- package/es/components/select/src/select.mjs +13 -6
- package/es/components/select/src/select.mjs.map +1 -1
- package/es/components/select/src/select.vue.d.ts +30 -26
- package/es/components/select-v2/index.d.ts +12 -12
- package/es/components/select-v2/src/defaults.d.ts +2 -1
- package/es/components/select-v2/src/defaults.mjs +4 -1
- package/es/components/select-v2/src/defaults.mjs.map +1 -1
- package/es/components/select-v2/src/select.mjs +2 -2
- package/es/components/select-v2/src/select.mjs.map +1 -1
- package/es/components/select-v2/src/select.vue.d.ts +6 -6
- package/es/components/select-v2/src/useSelect.d.ts +1 -4
- package/es/components/select-v2/src/useSelect.mjs +4 -2
- package/es/components/select-v2/src/useSelect.mjs.map +1 -1
- package/es/hooks/index.d.ts +2 -0
- package/es/hooks/index.mjs +2 -0
- package/es/hooks/index.mjs.map +1 -1
- package/es/hooks/use-deprecated/index.d.ts +10 -0
- package/es/hooks/use-deprecated/index.mjs +17 -0
- package/es/hooks/use-deprecated/index.mjs.map +1 -0
- package/es/hooks/use-draggable/index.d.ts +2 -0
- package/es/hooks/use-draggable/index.mjs +65 -0
- package/es/hooks/use-draggable/index.mjs.map +1 -0
- package/es/index.mjs +3 -0
- package/es/index.mjs.map +1 -1
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/autocomplete/index.d.ts +12 -4
- package/lib/components/autocomplete/src/index.js +11 -4
- package/lib/components/autocomplete/src/index.js.map +1 -1
- package/lib/components/autocomplete/src/index.vue.d.ts +6 -2
- package/lib/components/cascader/index.d.ts +12 -4
- package/lib/components/cascader/src/index.js +12 -5
- package/lib/components/cascader/src/index.js.map +1 -1
- package/lib/components/cascader/src/index.vue.d.ts +6 -2
- package/lib/components/dialog/index.d.ts +4 -0
- package/lib/components/dialog/src/dialog.d.ts +1 -0
- package/lib/components/dialog/src/dialog.js +4 -0
- package/lib/components/dialog/src/dialog.js.map +1 -1
- package/lib/components/dialog/src/dialog.vue.d.ts +4 -0
- package/lib/components/dialog/src/dialog2.js +11 -2
- package/lib/components/dialog/src/dialog2.js.map +1 -1
- package/lib/components/drawer/index.d.ts +3 -0
- package/lib/components/drawer/src/drawer.d.ts +1 -0
- package/lib/components/drawer/src/drawer.vue.d.ts +3 -0
- package/lib/components/index.js +2 -0
- package/lib/components/index.js.map +1 -1
- package/lib/components/message-box/src/index.js +140 -120
- package/lib/components/message-box/src/index.js.map +1 -1
- package/lib/components/message-box/src/index.vue.d.ts +14 -4
- package/lib/components/message-box/src/message-box.type.d.ts +2 -0
- package/lib/components/popconfirm/index.d.ts +26 -22
- package/lib/components/popconfirm/src/popconfirm.d.ts +12 -11
- package/lib/components/popconfirm/src/popconfirm.js +48 -43
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm.vue.d.ts +26 -22
- package/lib/components/popconfirm/src/popconfirm2.js +8 -3
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/popover/index.d.ts +26 -0
- package/lib/components/popover/src/index.js +8 -3
- package/lib/components/popover/src/index.js.map +1 -1
- package/lib/components/popover/src/index.vue.d.ts +39 -26
- package/lib/components/popover/src/popover.d.ts +5 -0
- package/lib/components/popover/src/popover.js +2 -0
- package/lib/components/popover/src/popover.js.map +1 -1
- package/lib/components/popper/index.d.ts +1 -0
- package/lib/components/popper/index.js +2 -0
- package/lib/components/popper/index.js.map +1 -1
- package/lib/components/popper/src/deprecation.d.ts +3 -0
- package/lib/components/popper/src/deprecation.js +28 -0
- package/lib/components/popper/src/deprecation.js.map +1 -0
- package/lib/components/select/index.d.ts +6 -2
- package/lib/components/select/src/select.js +13 -6
- package/lib/components/select/src/select.js.map +1 -1
- package/lib/components/select/src/select.vue.d.ts +30 -26
- package/lib/components/select-v2/index.d.ts +12 -12
- package/lib/components/select-v2/src/defaults.d.ts +2 -1
- package/lib/components/select-v2/src/defaults.js +4 -1
- package/lib/components/select-v2/src/defaults.js.map +1 -1
- package/lib/components/select-v2/src/select.js +2 -2
- package/lib/components/select-v2/src/select.js.map +1 -1
- package/lib/components/select-v2/src/select.vue.d.ts +6 -6
- package/lib/components/select-v2/src/useSelect.d.ts +1 -4
- package/lib/components/select-v2/src/useSelect.js +11 -9
- package/lib/components/select-v2/src/useSelect.js.map +1 -1
- package/lib/hooks/index.d.ts +2 -0
- package/lib/hooks/index.js +62 -58
- package/lib/hooks/index.js.map +1 -1
- package/lib/hooks/use-deprecated/index.d.ts +10 -0
- package/lib/hooks/use-deprecated/index.js +21 -0
- package/lib/hooks/use-deprecated/index.js.map +1 -0
- package/lib/hooks/use-draggable/index.d.ts +2 -0
- package/lib/hooks/use-draggable/index.js +69 -0
- package/lib/hooks/use-draggable/index.js.map +1 -0
- package/lib/index.js +64 -58
- package/lib/index.js.map +1 -1
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/lib/version.js.map +1 -1
- package/package.json +2 -2
- package/tags.json +1 -1
- package/theme-chalk/el-dialog.css +1 -1
- package/theme-chalk/el-message-box.css +1 -1
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/dialog.scss +7 -0
- package/theme-chalk/src/message-box.scss +26 -15
- package/web-types.json +1 -1
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import type { Component, ExtractPropTypes } from 'vue';
|
|
2
2
|
export declare const popconfirmProps: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
3
|
+
teleported: import("element-plus/es/utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
4
|
+
title: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
5
|
+
confirmButtonText: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
6
|
+
cancelButtonText: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
7
|
+
confirmButtonType: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, "primary", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
8
|
+
cancelButtonType: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, "text", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
9
|
+
icon: import("element-plus/es/utils/props").BuildPropReturn<import("element-plus/es/utils/props").PropWrapper<string | Component<any, any, any, import("vue").ComputedOptions, import("vue").MethodOptions>>, any, unknown, unknown, unknown>;
|
|
10
|
+
iconColor: import("element-plus/es/utils/props").BuildPropReturn<StringConstructor, "#f90", unknown, unknown, unknown>;
|
|
11
|
+
hideIcon: import("element-plus/es/utils/props").BuildPropReturn<BooleanConstructor, false, unknown, unknown, unknown>;
|
|
12
|
+
hideAfter: import("element-plus/es/utils/props").BuildPropReturn<NumberConstructor, 200, unknown, unknown, unknown>;
|
|
13
|
+
onConfirm: import("element-plus/es/utils/props").BuildPropReturn<import("element-plus/es/utils/props").PropWrapper<(e: Event) => Promise<boolean> | boolean>, unknown, unknown, unknown, unknown>;
|
|
14
|
+
onCancel: import("element-plus/es/utils/props").BuildPropReturn<import("element-plus/es/utils/props").PropWrapper<(e: Event) => Promise<boolean> | boolean>, unknown, unknown, unknown, unknown>;
|
|
14
15
|
};
|
|
15
16
|
export declare type PopconfirmProps = ExtractPropTypes<typeof popconfirmProps>;
|
|
@@ -1,51 +1,56 @@
|
|
|
1
1
|
import '../../button/index.mjs';
|
|
2
2
|
import { QuestionFilled } from '@element-plus/icons-vue';
|
|
3
3
|
import { buildProps, definePropType } from '../../../utils/props.mjs';
|
|
4
|
+
import '../../tooltip/index.mjs';
|
|
4
5
|
import { buttonType } from '../../button/src/button.mjs';
|
|
6
|
+
import { useTooltipContentProps } from '../../tooltip/src/tooltip.mjs';
|
|
5
7
|
|
|
6
|
-
const popconfirmProps =
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}
|
|
8
|
+
const popconfirmProps = {
|
|
9
|
+
...buildProps({
|
|
10
|
+
title: {
|
|
11
|
+
type: String
|
|
12
|
+
},
|
|
13
|
+
confirmButtonText: {
|
|
14
|
+
type: String
|
|
15
|
+
},
|
|
16
|
+
cancelButtonText: {
|
|
17
|
+
type: String
|
|
18
|
+
},
|
|
19
|
+
confirmButtonType: {
|
|
20
|
+
type: String,
|
|
21
|
+
values: buttonType,
|
|
22
|
+
default: "primary"
|
|
23
|
+
},
|
|
24
|
+
cancelButtonType: {
|
|
25
|
+
type: String,
|
|
26
|
+
values: buttonType,
|
|
27
|
+
default: "text"
|
|
28
|
+
},
|
|
29
|
+
icon: {
|
|
30
|
+
type: definePropType([String, Object]),
|
|
31
|
+
default: QuestionFilled
|
|
32
|
+
},
|
|
33
|
+
iconColor: {
|
|
34
|
+
type: String,
|
|
35
|
+
default: "#f90"
|
|
36
|
+
},
|
|
37
|
+
hideIcon: {
|
|
38
|
+
type: Boolean,
|
|
39
|
+
default: false
|
|
40
|
+
},
|
|
41
|
+
hideAfter: {
|
|
42
|
+
type: Number,
|
|
43
|
+
default: 200
|
|
44
|
+
},
|
|
45
|
+
onConfirm: {
|
|
46
|
+
type: definePropType(Function)
|
|
47
|
+
},
|
|
48
|
+
onCancel: {
|
|
49
|
+
type: definePropType(Function)
|
|
50
|
+
}
|
|
51
|
+
}),
|
|
52
|
+
teleported: useTooltipContentProps.teleported
|
|
53
|
+
};
|
|
49
54
|
|
|
50
55
|
export { popconfirmProps };
|
|
51
56
|
//# sourceMappingURL=popconfirm.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"popconfirm.mjs","sources":["../../../../../../packages/components/popconfirm/src/popconfirm.ts"],"sourcesContent":["import { buttonType } from '@element-plus/components/button'\nimport { QuestionFilled } from '@element-plus/icons-vue'\nimport { buildProps, definePropType } from '@element-plus/utils/props'\n\nimport type { Component, ExtractPropTypes } from 'vue'\n\nexport const popconfirmProps = buildProps({\n
|
|
1
|
+
{"version":3,"file":"popconfirm.mjs","sources":["../../../../../../packages/components/popconfirm/src/popconfirm.ts"],"sourcesContent":["import { buttonType } from '@element-plus/components/button'\nimport { QuestionFilled } from '@element-plus/icons-vue'\nimport { buildProps, definePropType } from '@element-plus/utils/props'\nimport { useTooltipContentProps } from '@element-plus/components/tooltip'\n\nimport type { Component, ExtractPropTypes } from 'vue'\n\nexport const popconfirmProps = {\n ...buildProps({\n title: {\n type: String,\n },\n confirmButtonText: {\n type: String,\n },\n cancelButtonText: {\n type: String,\n },\n confirmButtonType: {\n type: String,\n values: buttonType,\n default: 'primary',\n },\n cancelButtonType: {\n type: String,\n values: buttonType,\n default: 'text',\n },\n icon: {\n type: definePropType<string | Component>([String, Object]),\n default: QuestionFilled as any,\n },\n iconColor: {\n type: String,\n default: '#f90',\n },\n hideIcon: {\n type: Boolean,\n default: false,\n },\n hideAfter: {\n type: Number,\n default: 200,\n },\n onConfirm: {\n type: definePropType<(e: Event) => Promise<boolean> | boolean>(Function),\n },\n onCancel: {\n type: definePropType<(e: Event) => Promise<boolean> | boolean>(Function),\n },\n } as const),\n teleported: useTooltipContentProps.teleported,\n}\nexport type PopconfirmProps = ExtractPropTypes<typeof popconfirmProps>\n"],"names":[],"mappings":";;;;;;;AAIY,MAAC,eAAe,GAAG;AAC/B,EAAE,GAAG,UAAU,CAAC;AAChB,IAAI,KAAK,EAAE;AACX,MAAM,IAAI,EAAE,MAAM;AAClB,KAAK;AACL,IAAI,iBAAiB,EAAE;AACvB,MAAM,IAAI,EAAE,MAAM;AAClB,KAAK;AACL,IAAI,gBAAgB,EAAE;AACtB,MAAM,IAAI,EAAE,MAAM;AAClB,KAAK;AACL,IAAI,iBAAiB,EAAE;AACvB,MAAM,IAAI,EAAE,MAAM;AAClB,MAAM,MAAM,EAAE,UAAU;AACxB,MAAM,OAAO,EAAE,SAAS;AACxB,KAAK;AACL,IAAI,gBAAgB,EAAE;AACtB,MAAM,IAAI,EAAE,MAAM;AAClB,MAAM,MAAM,EAAE,UAAU;AACxB,MAAM,OAAO,EAAE,MAAM;AACrB,KAAK;AACL,IAAI,IAAI,EAAE;AACV,MAAM,IAAI,EAAE,cAAc,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAC5C,MAAM,OAAO,EAAE,cAAc;AAC7B,KAAK;AACL,IAAI,SAAS,EAAE;AACf,MAAM,IAAI,EAAE,MAAM;AAClB,MAAM,OAAO,EAAE,MAAM;AACrB,KAAK;AACL,IAAI,QAAQ,EAAE;AACd,MAAM,IAAI,EAAE,OAAO;AACnB,MAAM,OAAO,EAAE,KAAK;AACpB,KAAK;AACL,IAAI,SAAS,EAAE;AACf,MAAM,IAAI,EAAE,MAAM;AAClB,MAAM,OAAO,EAAE,GAAG;AAClB,KAAK;AACL,IAAI,SAAS,EAAE;AACf,MAAM,IAAI,EAAE,cAAc,CAAC,QAAQ,CAAC;AACpC,KAAK;AACL,IAAI,QAAQ,EAAE;AACd,MAAM,IAAI,EAAE,cAAc,CAAC,QAAQ,CAAC;AACpC,KAAK;AACL,GAAG,CAAC;AACJ,EAAE,UAAU,EAAE,sBAAsB,CAAC,UAAU;AAC/C;;;;"}
|
|
@@ -1,39 +1,43 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
2
|
+
teleported: import("../../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
3
|
+
title: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
4
|
+
confirmButtonText: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
5
|
+
cancelButtonText: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
6
|
+
confirmButtonType: import("../../../utils/props").BuildPropReturn<StringConstructor, "primary", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
7
|
+
cancelButtonType: import("../../../utils/props").BuildPropReturn<StringConstructor, "text", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
8
|
+
icon: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<string | import("vue").Component<any, any, any, import("vue").ComputedOptions, import("vue").MethodOptions>>, any, unknown, unknown, unknown>;
|
|
9
|
+
iconColor: import("../../../utils/props").BuildPropReturn<StringConstructor, "#f90", unknown, unknown, unknown>;
|
|
10
|
+
hideIcon: import("../../../utils/props").BuildPropReturn<BooleanConstructor, false, unknown, unknown, unknown>;
|
|
11
|
+
hideAfter: import("../../../utils/props").BuildPropReturn<NumberConstructor, 200, unknown, unknown, unknown>;
|
|
12
|
+
onConfirm: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<(e: Event) => boolean | Promise<boolean>>, unknown, unknown, unknown, unknown>;
|
|
13
|
+
onCancel: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<(e: Event) => boolean | Promise<boolean>>, unknown, unknown, unknown, unknown>;
|
|
13
14
|
}, {
|
|
14
15
|
finalConfirmButtonText: import("vue").ComputedRef<string>;
|
|
15
16
|
finalCancelButtonText: import("vue").ComputedRef<string>;
|
|
16
17
|
tooltipRef: import("vue").Ref<{
|
|
17
18
|
onClose: () => void;
|
|
18
19
|
} | undefined>;
|
|
20
|
+
compatTeleported: import("vue").ComputedRef<boolean>;
|
|
19
21
|
confirm: (e: Event) => void;
|
|
20
22
|
cancel: (e: Event) => void;
|
|
21
23
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
24
|
+
teleported: import("../../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
25
|
+
title: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
26
|
+
confirmButtonText: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
27
|
+
cancelButtonText: import("../../../utils/props").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
|
|
28
|
+
confirmButtonType: import("../../../utils/props").BuildPropReturn<StringConstructor, "primary", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
29
|
+
cancelButtonType: import("../../../utils/props").BuildPropReturn<StringConstructor, "text", unknown, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
30
|
+
icon: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<string | import("vue").Component<any, any, any, import("vue").ComputedOptions, import("vue").MethodOptions>>, any, unknown, unknown, unknown>;
|
|
31
|
+
iconColor: import("../../../utils/props").BuildPropReturn<StringConstructor, "#f90", unknown, unknown, unknown>;
|
|
32
|
+
hideIcon: import("../../../utils/props").BuildPropReturn<BooleanConstructor, false, unknown, unknown, unknown>;
|
|
33
|
+
hideAfter: import("../../../utils/props").BuildPropReturn<NumberConstructor, 200, unknown, unknown, unknown>;
|
|
34
|
+
onConfirm: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<(e: Event) => boolean | Promise<boolean>>, unknown, unknown, unknown, unknown>;
|
|
35
|
+
onCancel: import("../../../utils/props").BuildPropReturn<import("../../../utils/props").PropWrapper<(e: Event) => boolean | Promise<boolean>>, unknown, unknown, unknown, unknown>;
|
|
33
36
|
}>>, {
|
|
34
37
|
icon: import("../../../utils/props").BuildPropType<import("../../../utils/props").PropWrapper<string | import("vue").Component<any, any, any, import("vue").ComputedOptions, import("vue").MethodOptions>>, unknown, unknown>;
|
|
35
38
|
title: string;
|
|
36
39
|
hideAfter: number;
|
|
40
|
+
teleported: import("../../../utils/props").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
37
41
|
confirmButtonText: string;
|
|
38
42
|
cancelButtonText: string;
|
|
39
43
|
confirmButtonType: import("../../../utils/props").BuildPropType<StringConstructor, "" | "default" | "primary" | "success" | "warning" | "info" | "danger" | "text", unknown>;
|
|
@@ -2,13 +2,16 @@ import { defineComponent, ref, unref, computed, resolveComponent, openBlock, cre
|
|
|
2
2
|
import { ElButton } from '../../button/index.mjs';
|
|
3
3
|
import { ElIcon } from '../../icon/index.mjs';
|
|
4
4
|
import { ElTooltip } from '../../tooltip/index.mjs';
|
|
5
|
+
import '../../popper/index.mjs';
|
|
5
6
|
import '../../../hooks/index.mjs';
|
|
6
7
|
import { popconfirmProps } from './popconfirm.mjs';
|
|
7
8
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
9
|
+
import { useDeprecateAppendToBody } from '../../popper/src/deprecation.mjs';
|
|
8
10
|
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
9
11
|
|
|
12
|
+
const COMPONENT_NAME = "Elpopperconfirm";
|
|
10
13
|
const _sfc_main = defineComponent({
|
|
11
|
-
name:
|
|
14
|
+
name: COMPONENT_NAME,
|
|
12
15
|
components: {
|
|
13
16
|
ElButton,
|
|
14
17
|
ElTooltip,
|
|
@@ -16,6 +19,7 @@ const _sfc_main = defineComponent({
|
|
|
16
19
|
},
|
|
17
20
|
props: popconfirmProps,
|
|
18
21
|
setup(props) {
|
|
22
|
+
const { compatTeleported } = useDeprecateAppendToBody(COMPONENT_NAME, "appendToBody");
|
|
19
23
|
const { t } = useLocale();
|
|
20
24
|
const tooltipRef = ref();
|
|
21
25
|
const hidePopper = () => {
|
|
@@ -41,6 +45,7 @@ const _sfc_main = defineComponent({
|
|
|
41
45
|
finalConfirmButtonText,
|
|
42
46
|
finalCancelButtonText,
|
|
43
47
|
tooltipRef,
|
|
48
|
+
compatTeleported,
|
|
44
49
|
confirm,
|
|
45
50
|
cancel
|
|
46
51
|
};
|
|
@@ -57,7 +62,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
57
62
|
trigger: "click",
|
|
58
63
|
effect: "light",
|
|
59
64
|
"popper-class": "el-popover",
|
|
60
|
-
|
|
65
|
+
teleported: _ctx.compatTeleported,
|
|
61
66
|
"fallback-placements": ["bottom", "top", "right", "left"],
|
|
62
67
|
"hide-after": _ctx.hideAfter,
|
|
63
68
|
persistent: ""
|
|
@@ -105,7 +110,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
105
110
|
_ctx.$slots.reference ? renderSlot(_ctx.$slots, "reference", { key: 0 }) : createCommentVNode("v-if", true)
|
|
106
111
|
]),
|
|
107
112
|
_: 3
|
|
108
|
-
}, 16, ["hide-after"]);
|
|
113
|
+
}, 16, ["teleported", "hide-after"]);
|
|
109
114
|
}
|
|
110
115
|
var Popconfirm = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
111
116
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"popconfirm2.mjs","sources":["../../../../../../packages/components/popconfirm/src/popconfirm.vue"],"sourcesContent":["<template>\n <el-tooltip\n ref=\"tooltipRef\"\n v-bind=\"$attrs\"\n trigger=\"click\"\n effect=\"light\"\n popper-class=\"el-popover\"\n
|
|
1
|
+
{"version":3,"file":"popconfirm2.mjs","sources":["../../../../../../packages/components/popconfirm/src/popconfirm.vue"],"sourcesContent":["<template>\n <el-tooltip\n ref=\"tooltipRef\"\n v-bind=\"$attrs\"\n trigger=\"click\"\n effect=\"light\"\n popper-class=\"el-popover\"\n :teleported=\"compatTeleported\"\n :fallback-placements=\"['bottom', 'top', 'right', 'left']\"\n :hide-after=\"hideAfter\"\n persistent\n >\n <template #content>\n <div class=\"el-popconfirm\">\n <div class=\"el-popconfirm__main\">\n <el-icon\n v-if=\"!hideIcon && icon\"\n class=\"el-popconfirm__icon\"\n :style=\"{ color: iconColor }\"\n >\n <component :is=\"icon\" />\n </el-icon>\n {{ title }}\n </div>\n <div class=\"el-popconfirm__action\">\n <el-button size=\"small\" :type=\"cancelButtonType\" @click=\"cancel\">\n {{ finalCancelButtonText }}\n </el-button>\n <el-button size=\"small\" :type=\"confirmButtonType\" @click=\"confirm\">\n {{ finalConfirmButtonText }}\n </el-button>\n </div>\n </div>\n </template>\n <template v-if=\"$slots.reference\">\n <slot name=\"reference\" />\n </template>\n </el-tooltip>\n</template>\n\n<script lang=\"ts\">\nimport { defineComponent, ref, computed, unref } from 'vue'\nimport ElButton from '@element-plus/components/button'\nimport ElIcon from '@element-plus/components/icon'\nimport ElTooltip from '@element-plus/components/tooltip'\nimport { useDeprecateAppendToBody } from '@element-plus/components/popper'\nimport { useLocale } from '@element-plus/hooks'\nimport { popconfirmProps } from './popconfirm'\n\nconst COMPONENT_NAME = 'Elpopperconfirm'\nexport default defineComponent({\n name: COMPONENT_NAME,\n\n components: {\n ElButton,\n ElTooltip,\n ElIcon,\n },\n\n props: popconfirmProps,\n\n setup(props) {\n const { compatTeleported } = useDeprecateAppendToBody(\n COMPONENT_NAME,\n 'appendToBody'\n )\n const { t } = useLocale()\n const tooltipRef = ref<{ onClose: () => void }>()\n\n const hidePopper = () => {\n unref(tooltipRef)?.onClose?.()\n }\n\n const handleCallback = () => {\n hidePopper()\n }\n\n const confirm = (e: Event) => {\n props.onConfirm?.(e)\n handleCallback()\n }\n const cancel = (e: Event) => {\n props.onCancel?.(e)\n handleCallback()\n }\n\n const finalConfirmButtonText = computed(\n () => props.confirmButtonText || t('el.popconfirm.confirmButtonText')\n )\n const finalCancelButtonText = computed(\n () => props.cancelButtonText || t('el.popconfirm.cancelButtonText')\n )\n\n return {\n finalConfirmButtonText,\n finalCancelButtonText,\n tooltipRef,\n\n // Deprecation in 2.1.0\n compatTeleported,\n\n confirm,\n cancel,\n }\n },\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;AAiDA,MAAM,iBAAiB;AACvB,MAAK,YAAa,gBAAa;AAAA,EAC7B,MAAM;AAAA,EAEN,YAAY;AAAA,IACV;AAAA,IACA;AAAA,IACA;AAAA;AAAA,EAGF,OAAO;AAAA,EAEP,MAAM,OAAO;AACX,UAAM,EAAE,qBAAqB,yBAC3B,gBACA;AAEF,UAAM,EAAE,MAAM;AACd,UAAM,aAAa;AAEnB,UAAM,aAAa,MAAM;AACvB,YAAM;AAAa;AAGrB;AACE;AAAA;AAGF;AACE;AACA;AAAA;AAEF,oBAAgB;AACd;AACA;AAAA;AAGF,mCAA+B,SAC7B,MAAM;AAER;AAIA;AAAO;AACL;AACA;AACA,MAGA;AAAA,MAEA;AAAA,MACA;AAAA;AAAA;AAAA;;;;;;;;;AAlGa;AACR;AACP;AACa,IACZ;AAAA,IACA;AAAqB,IACtB,cAAU;AAAA;;AAEC;AAoBH;AATE;AAPqB,2BADzB;;AAEO;AACC;;;AAEN;;;;AAEF;;;AAKY;AAFW;AAAQ;AAA0B;;;;;;;AAK7C;AAFW,YAAE;AAAM,uBAA2B;AAAA;;;;;;;;;;;AAMhC;;;;;;;;;;;;"}
|
|
@@ -3,6 +3,10 @@ declare const _PopoverDirective: SFCWithInstall<import("vue").ObjectDirective<an
|
|
|
3
3
|
declare const _Popover: SFCWithInstall<import("vue").DefineComponent<{
|
|
4
4
|
title: StringConstructor;
|
|
5
5
|
width: import("../../utils/props").BuildPropReturn<(StringConstructor | NumberConstructor)[], number, unknown, unknown, unknown>;
|
|
6
|
+
appendToBody: {
|
|
7
|
+
type: BooleanConstructor;
|
|
8
|
+
default: undefined;
|
|
9
|
+
};
|
|
6
10
|
content: import("../../utils/props").BuildPropReturn<StringConstructor, string | (() => string) | undefined, unknown, unknown, unknown>;
|
|
7
11
|
popperStyle: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<import("vue").StyleValue>, string | import("vue").CSSProperties | (() => string) | (() => import("vue").CSSProperties) | (() => import("vue").StyleValue[]) | undefined, unknown, unknown, unknown>;
|
|
8
12
|
popperClass: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<string | {
|
|
@@ -68,7 +72,9 @@ declare const _Popover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
68
72
|
validator: ((val: unknown) => boolean) | undefined;
|
|
69
73
|
__elPropsReservedKey: true;
|
|
70
74
|
};
|
|
75
|
+
teleported: import("../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
71
76
|
}, {
|
|
77
|
+
compatTeleported: import("vue").ComputedRef<boolean>;
|
|
72
78
|
kls: import("vue").ComputedRef<(string | {
|
|
73
79
|
[x: string]: any;
|
|
74
80
|
} | (string | {
|
|
@@ -844,6 +850,10 @@ declare const _Popover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
844
850
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
845
851
|
title: StringConstructor;
|
|
846
852
|
width: import("../../utils/props").BuildPropReturn<(StringConstructor | NumberConstructor)[], number, unknown, unknown, unknown>;
|
|
853
|
+
appendToBody: {
|
|
854
|
+
type: BooleanConstructor;
|
|
855
|
+
default: undefined;
|
|
856
|
+
};
|
|
847
857
|
content: import("../../utils/props").BuildPropReturn<StringConstructor, string | (() => string) | undefined, unknown, unknown, unknown>;
|
|
848
858
|
popperStyle: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<import("vue").StyleValue>, string | import("vue").CSSProperties | (() => string) | (() => import("vue").CSSProperties) | (() => import("vue").StyleValue[]) | undefined, unknown, unknown, unknown>;
|
|
849
859
|
popperClass: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<string | {
|
|
@@ -909,6 +919,7 @@ declare const _Popover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
909
919
|
validator: ((val: unknown) => boolean) | undefined;
|
|
910
920
|
__elPropsReservedKey: true;
|
|
911
921
|
};
|
|
922
|
+
teleported: import("../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
912
923
|
}>> & {
|
|
913
924
|
[x: string & `on${string}`]: ((...args: any[]) => any) | undefined;
|
|
914
925
|
}, {
|
|
@@ -942,6 +953,8 @@ declare const _Popover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
942
953
|
} | any)[])[])[])[])[])[])[])[])[])[])[];
|
|
943
954
|
popperStyle: import("vue").StyleValue;
|
|
944
955
|
content: string;
|
|
956
|
+
teleported: import("../../utils/props").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
957
|
+
appendToBody: boolean;
|
|
945
958
|
}>> & {
|
|
946
959
|
directive: typeof _PopoverDirective;
|
|
947
960
|
};
|
|
@@ -949,6 +962,10 @@ export default _Popover;
|
|
|
949
962
|
export declare const ElPopover: SFCWithInstall<import("vue").DefineComponent<{
|
|
950
963
|
title: StringConstructor;
|
|
951
964
|
width: import("../../utils/props").BuildPropReturn<(StringConstructor | NumberConstructor)[], number, unknown, unknown, unknown>;
|
|
965
|
+
appendToBody: {
|
|
966
|
+
type: BooleanConstructor;
|
|
967
|
+
default: undefined;
|
|
968
|
+
};
|
|
952
969
|
content: import("../../utils/props").BuildPropReturn<StringConstructor, string | (() => string) | undefined, unknown, unknown, unknown>;
|
|
953
970
|
popperStyle: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<import("vue").StyleValue>, string | import("vue").CSSProperties | (() => string) | (() => import("vue").CSSProperties) | (() => import("vue").StyleValue[]) | undefined, unknown, unknown, unknown>;
|
|
954
971
|
popperClass: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<string | {
|
|
@@ -1014,7 +1031,9 @@ export declare const ElPopover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
1014
1031
|
validator: ((val: unknown) => boolean) | undefined;
|
|
1015
1032
|
__elPropsReservedKey: true;
|
|
1016
1033
|
};
|
|
1034
|
+
teleported: import("../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
1017
1035
|
}, {
|
|
1036
|
+
compatTeleported: import("vue").ComputedRef<boolean>;
|
|
1018
1037
|
kls: import("vue").ComputedRef<(string | {
|
|
1019
1038
|
[x: string]: any;
|
|
1020
1039
|
} | (string | {
|
|
@@ -1790,6 +1809,10 @@ export declare const ElPopover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
1790
1809
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
1791
1810
|
title: StringConstructor;
|
|
1792
1811
|
width: import("../../utils/props").BuildPropReturn<(StringConstructor | NumberConstructor)[], number, unknown, unknown, unknown>;
|
|
1812
|
+
appendToBody: {
|
|
1813
|
+
type: BooleanConstructor;
|
|
1814
|
+
default: undefined;
|
|
1815
|
+
};
|
|
1793
1816
|
content: import("../../utils/props").BuildPropReturn<StringConstructor, string | (() => string) | undefined, unknown, unknown, unknown>;
|
|
1794
1817
|
popperStyle: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<import("vue").StyleValue>, string | import("vue").CSSProperties | (() => string) | (() => import("vue").CSSProperties) | (() => import("vue").StyleValue[]) | undefined, unknown, unknown, unknown>;
|
|
1795
1818
|
popperClass: import("../../utils/props").BuildPropReturn<import("../../utils/props").PropWrapper<string | {
|
|
@@ -1855,6 +1878,7 @@ export declare const ElPopover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
1855
1878
|
validator: ((val: unknown) => boolean) | undefined;
|
|
1856
1879
|
__elPropsReservedKey: true;
|
|
1857
1880
|
};
|
|
1881
|
+
teleported: import("../../utils/props").BuildPropReturn<BooleanConstructor, boolean | (() => false) | (() => true) | undefined, unknown, unknown, unknown>;
|
|
1858
1882
|
}>> & {
|
|
1859
1883
|
[x: string & `on${string}`]: ((...args: any[]) => any) | undefined;
|
|
1860
1884
|
}, {
|
|
@@ -1888,6 +1912,8 @@ export declare const ElPopover: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
1888
1912
|
} | any)[])[])[])[])[])[])[])[])[])[])[];
|
|
1889
1913
|
popperStyle: import("vue").StyleValue;
|
|
1890
1914
|
content: string;
|
|
1915
|
+
teleported: import("../../utils/props").BuildPropType<BooleanConstructor, unknown, unknown>;
|
|
1916
|
+
appendToBody: boolean;
|
|
1891
1917
|
}>> & {
|
|
1892
1918
|
directive: typeof _PopoverDirective;
|
|
1893
1919
|
};
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, unref, resolveComponent, openBlock, createBlock, mergeProps, withCtx, createElementBlock, toDisplayString, createCommentVNode, renderSlot, createTextVNode } from 'vue';
|
|
2
2
|
import { ElTooltip } from '../../tooltip/index.mjs';
|
|
3
|
+
import '../../popper/index.mjs';
|
|
3
4
|
import '../../../utils/util.mjs';
|
|
4
5
|
import { usePopoverProps } from './popover.mjs';
|
|
5
6
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
6
7
|
import { isString } from '@vue/shared';
|
|
8
|
+
import { useDeprecateAppendToBody } from '../../popper/src/deprecation.mjs';
|
|
7
9
|
|
|
8
10
|
const emits = ["update:visible", "after-enter", "after-leave"];
|
|
9
|
-
const
|
|
11
|
+
const COMPONENT_NAME = "ElPopover";
|
|
10
12
|
const _sfc_main = defineComponent({
|
|
11
|
-
name:
|
|
13
|
+
name: COMPONENT_NAME,
|
|
12
14
|
components: {
|
|
13
15
|
ElTooltip
|
|
14
16
|
},
|
|
@@ -41,6 +43,7 @@ const _sfc_main = defineComponent({
|
|
|
41
43
|
props.popperClass
|
|
42
44
|
];
|
|
43
45
|
});
|
|
46
|
+
const { compatTeleported } = useDeprecateAppendToBody(COMPONENT_NAME, "appendToBody");
|
|
44
47
|
const hide = () => {
|
|
45
48
|
var _a;
|
|
46
49
|
(_a = tooltipRef.value) == null ? void 0 : _a.hide();
|
|
@@ -52,6 +55,7 @@ const _sfc_main = defineComponent({
|
|
|
52
55
|
emit("after-leave");
|
|
53
56
|
};
|
|
54
57
|
return {
|
|
58
|
+
compatTeleported,
|
|
55
59
|
kls,
|
|
56
60
|
style,
|
|
57
61
|
tooltipRef,
|
|
@@ -75,6 +79,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
75
79
|
enterable: _ctx.enterable,
|
|
76
80
|
"popper-class": _ctx.kls,
|
|
77
81
|
"popper-style": _ctx.style,
|
|
82
|
+
teleported: _ctx.compatTeleported,
|
|
78
83
|
persistent: "",
|
|
79
84
|
onShow: _ctx.afterEnter,
|
|
80
85
|
onHide: _ctx.afterLeave
|
|
@@ -89,7 +94,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
89
94
|
_ctx.$slots.reference ? renderSlot(_ctx.$slots, "reference", { key: 0 }) : createCommentVNode("v-if", true)
|
|
90
95
|
]),
|
|
91
96
|
_: 3
|
|
92
|
-
}, 16, ["aria-label", "effect", "enterable", "popper-class", "popper-style", "onShow", "onHide"]);
|
|
97
|
+
}, 16, ["aria-label", "effect", "enterable", "popper-class", "popper-style", "teleported", "onShow", "onHide"]);
|
|
93
98
|
}
|
|
94
99
|
var Popover = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
95
100
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/components/popover/src/index.vue"],"sourcesContent":["<template>\n <el-tooltip\n ref=\"tooltipRef\"\n v-bind=\"$attrs\"\n :aria-label=\"title\"\n :effect=\"effect\"\n :enterable=\"enterable\"\n :popper-class=\"kls\"\n :popper-style=\"style\"\n persistent\n @show=\"afterEnter\"\n @hide=\"afterLeave\"\n >\n <template v-if=\"$slots.reference\">\n <slot name=\"reference\" />\n </template>\n\n <template #content>\n <div v-if=\"title\" class=\"el-popover__title\" role=\"title\">\n {{ title }}\n </div>\n <slot>\n {{ content }}\n </slot>\n </template>\n </el-tooltip>\n</template>\n<script lang=\"ts\">\nimport { defineComponent, computed, ref, unref } from 'vue'\nimport ElTooltip from '@element-plus/components/tooltip'\nimport { isString } from '@element-plus/utils/util'\nimport { usePopoverProps } from './popover'\n\nimport type { StyleValue } from 'vue'\n\nconst emits = ['update:visible', 'after-enter', 'after-leave']\n\nconst
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../../packages/components/popover/src/index.vue"],"sourcesContent":["<template>\n <el-tooltip\n ref=\"tooltipRef\"\n v-bind=\"$attrs\"\n :aria-label=\"title\"\n :effect=\"effect\"\n :enterable=\"enterable\"\n :popper-class=\"kls\"\n :popper-style=\"style\"\n :teleported=\"compatTeleported\"\n persistent\n @show=\"afterEnter\"\n @hide=\"afterLeave\"\n >\n <template v-if=\"$slots.reference\">\n <slot name=\"reference\" />\n </template>\n\n <template #content>\n <div v-if=\"title\" class=\"el-popover__title\" role=\"title\">\n {{ title }}\n </div>\n <slot>\n {{ content }}\n </slot>\n </template>\n </el-tooltip>\n</template>\n<script lang=\"ts\">\nimport { defineComponent, computed, ref, unref } from 'vue'\nimport ElTooltip from '@element-plus/components/tooltip'\nimport { useDeprecateAppendToBody } from '@element-plus/components/popper'\nimport { isString } from '@element-plus/utils/util'\nimport { usePopoverProps } from './popover'\n\nimport type { StyleValue } from 'vue'\n\nconst emits = ['update:visible', 'after-enter', 'after-leave']\n\nconst COMPONENT_NAME = 'ElPopover'\n\nexport default defineComponent({\n name: COMPONENT_NAME,\n components: {\n ElTooltip,\n },\n props: usePopoverProps,\n emits,\n setup(props, { emit }) {\n const tooltipRef = ref<InstanceType<typeof ElTooltip> | null>(null)\n const popperRef = computed(() => {\n return unref(tooltipRef)?.popperRef\n })\n const width = computed(() => {\n if (isString(props.width)) {\n return props.width as string\n }\n return `${props.width}px`\n })\n\n const style = computed(() => {\n return [\n {\n width: width.value,\n },\n props.popperStyle,\n ] as StyleValue\n })\n\n const kls = computed(() => {\n return [\n { 'el-popover--plain': !!props.content },\n 'el-popover',\n props.popperClass,\n ]\n })\n\n const { compatTeleported } = useDeprecateAppendToBody(\n COMPONENT_NAME,\n 'appendToBody'\n )\n\n const hide = () => {\n tooltipRef.value?.hide()\n }\n\n const afterEnter = () => {\n emit('after-enter')\n }\n\n const afterLeave = () => {\n emit('after-leave')\n }\n\n return {\n compatTeleported,\n kls,\n style,\n tooltipRef,\n popperRef,\n hide,\n afterEnter,\n afterLeave,\n }\n },\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;AAqCA,MAAM,QAAQ,CAAC,kBAAkB,eAAe;AAEhD,MAAM,iBAAiB;AAEvB,MAAK,YAAa,gBAAa;AAAA,EAC7B,MAAM;AAAA,EACN,YAAY;AAAA,IACV;AAAA;AAAA,EAEF,OAAO;AAAA,EACP;AAAA,EACA,MAAM,OAAO,EAAE,QAAQ;AACrB,UAAM,aAAa,IAA2C;AAC9D,UAAM,YAAY,SAAS,MAAM;AAC/B,aAAO;AAAmB;AAE5B;AACE,UAAI,uBAAuB;AACzB;AAAa;AAEf;AAAgB;AAGlB;AACE;AAAO;AACL;AACe;AAAA;AAET;AAAA;AAIV;AACE,aAAO;AAAA;AAC0B,QAC/B;AAAA,QACA;AAAM;AAAA;AAIV;AAKA,UAAM;AACJ,iBAAW;AAAO;AAGpB,uBAAmB;AACjB;AAAK;AAGP,UAAM;AACJ;AAAK;AAGP,WAAO;AAAA,MACL;AAAA;AACA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAAA;AAAA;;;AAnFuB;AAA0B;;;;SAflD;AAAiB;AACH;AACH,IACX;AAAc,IACd;AAAc,IACd,gBAAY;AAAA,IACb;AAAU,IACT;AAAM,IACN;AAAM;;AAMI;AACO;AAKT;AADF;;;;AATyB;;;;;;;;;;;"}
|