@element-plus/nightly 0.0.20240214 → 0.0.20240216
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 +2 -2
- package/dist/index.full.min.js +2 -2
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +2 -2
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +2 -2
- package/dist/locale/af.js +1 -1
- package/dist/locale/af.min.js +1 -1
- package/dist/locale/af.min.mjs +1 -1
- package/dist/locale/af.mjs +1 -1
- package/dist/locale/ar-eg.js +1 -1
- package/dist/locale/ar-eg.min.js +1 -1
- package/dist/locale/ar-eg.min.mjs +1 -1
- package/dist/locale/ar-eg.mjs +1 -1
- package/dist/locale/ar.js +1 -1
- package/dist/locale/ar.min.js +1 -1
- package/dist/locale/ar.min.mjs +1 -1
- package/dist/locale/ar.mjs +1 -1
- package/dist/locale/az.js +1 -1
- package/dist/locale/az.min.js +1 -1
- package/dist/locale/az.min.mjs +1 -1
- package/dist/locale/az.mjs +1 -1
- package/dist/locale/bg.js +1 -1
- package/dist/locale/bg.min.js +1 -1
- package/dist/locale/bg.min.mjs +1 -1
- package/dist/locale/bg.mjs +1 -1
- package/dist/locale/bn.js +1 -1
- package/dist/locale/bn.min.js +1 -1
- package/dist/locale/bn.min.mjs +1 -1
- package/dist/locale/bn.mjs +1 -1
- package/dist/locale/ca.js +1 -1
- package/dist/locale/ca.min.js +1 -1
- package/dist/locale/ca.min.mjs +1 -1
- package/dist/locale/ca.mjs +1 -1
- package/dist/locale/ckb.js +1 -1
- package/dist/locale/ckb.min.js +1 -1
- package/dist/locale/ckb.min.mjs +1 -1
- package/dist/locale/ckb.mjs +1 -1
- package/dist/locale/cs.js +1 -1
- package/dist/locale/cs.min.js +1 -1
- package/dist/locale/cs.min.mjs +1 -1
- package/dist/locale/cs.mjs +1 -1
- package/dist/locale/da.js +1 -1
- package/dist/locale/da.min.js +1 -1
- package/dist/locale/da.min.mjs +1 -1
- package/dist/locale/da.mjs +1 -1
- package/dist/locale/de.js +1 -1
- package/dist/locale/de.min.js +1 -1
- package/dist/locale/de.min.mjs +1 -1
- package/dist/locale/de.mjs +1 -1
- package/dist/locale/el.js +1 -1
- package/dist/locale/el.min.js +1 -1
- package/dist/locale/el.min.mjs +1 -1
- package/dist/locale/el.mjs +1 -1
- package/dist/locale/en.js +1 -1
- package/dist/locale/en.min.js +1 -1
- package/dist/locale/en.min.mjs +1 -1
- package/dist/locale/en.mjs +1 -1
- package/dist/locale/eo.js +1 -1
- package/dist/locale/eo.min.js +1 -1
- package/dist/locale/eo.min.mjs +1 -1
- package/dist/locale/eo.mjs +1 -1
- package/dist/locale/es.js +1 -1
- package/dist/locale/es.min.js +1 -1
- package/dist/locale/es.min.mjs +1 -1
- package/dist/locale/es.mjs +1 -1
- package/dist/locale/et.js +1 -1
- package/dist/locale/et.min.js +1 -1
- package/dist/locale/et.min.mjs +1 -1
- package/dist/locale/et.mjs +1 -1
- package/dist/locale/eu.js +1 -1
- package/dist/locale/eu.min.js +1 -1
- package/dist/locale/eu.min.mjs +1 -1
- package/dist/locale/eu.mjs +1 -1
- package/dist/locale/fa.js +1 -1
- package/dist/locale/fa.min.js +1 -1
- package/dist/locale/fa.min.mjs +1 -1
- package/dist/locale/fa.mjs +1 -1
- package/dist/locale/fi.js +1 -1
- package/dist/locale/fi.min.js +1 -1
- package/dist/locale/fi.min.mjs +1 -1
- package/dist/locale/fi.mjs +1 -1
- package/dist/locale/fr.js +1 -1
- package/dist/locale/fr.min.js +1 -1
- package/dist/locale/fr.min.mjs +1 -1
- package/dist/locale/fr.mjs +1 -1
- package/dist/locale/he.js +1 -1
- package/dist/locale/he.min.js +1 -1
- package/dist/locale/he.min.mjs +1 -1
- package/dist/locale/he.mjs +1 -1
- package/dist/locale/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/sw.js +1 -1
- package/dist/locale/sw.min.js +1 -1
- package/dist/locale/sw.min.mjs +1 -1
- package/dist/locale/sw.mjs +1 -1
- package/dist/locale/ta.js +1 -1
- package/dist/locale/ta.min.js +1 -1
- package/dist/locale/ta.min.mjs +1 -1
- package/dist/locale/ta.mjs +1 -1
- package/dist/locale/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/breadcrumb/index.mjs +2 -2
- package/es/components/breadcrumb/src/breadcrumb.mjs +11 -36
- package/es/components/breadcrumb/src/breadcrumb.mjs.map +1 -1
- package/es/components/breadcrumb/src/breadcrumb2.mjs +36 -11
- package/es/components/breadcrumb/src/breadcrumb2.mjs.map +1 -1
- package/es/components/button/index.mjs +1 -1
- package/es/components/button/src/button-group.mjs +6 -30
- package/es/components/button/src/button-group.mjs.map +1 -1
- package/es/components/button/src/button-group2.mjs +30 -6
- package/es/components/button/src/button-group2.mjs.map +1 -1
- package/es/components/calendar/index.mjs +2 -2
- package/es/components/calendar/src/calendar.mjs +131 -18
- package/es/components/calendar/src/calendar.mjs.map +1 -1
- package/es/components/calendar/src/calendar2.mjs +18 -131
- package/es/components/calendar/src/calendar2.mjs.map +1 -1
- package/es/components/index.mjs +3 -3
- package/es/components/popconfirm/index.mjs +2 -2
- package/es/components/popconfirm/src/popconfirm.mjs +110 -47
- package/es/components/popconfirm/src/popconfirm.mjs.map +1 -1
- package/es/components/popconfirm/src/popconfirm2.mjs +47 -110
- package/es/components/popconfirm/src/popconfirm2.mjs.map +1 -1
- package/es/components/teleport/index.mjs +2 -2
- package/es/components/teleport/src/teleport.mjs +18 -44
- package/es/components/teleport/src/teleport.mjs.map +1 -1
- package/es/components/teleport/src/teleport2.mjs +44 -18
- package/es/components/teleport/src/teleport2.mjs.map +1 -1
- package/es/components/transfer/src/composables/use-check.mjs +1 -1
- package/es/components/transfer/src/transfer-panel.mjs +19 -128
- package/es/components/transfer/src/transfer-panel.mjs.map +1 -1
- package/es/components/transfer/src/transfer-panel2.mjs +128 -19
- package/es/components/transfer/src/transfer-panel2.mjs.map +1 -1
- package/es/components/transfer/src/transfer2.mjs +1 -1
- package/es/index.mjs +3 -3
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/es/version.mjs.map +1 -1
- package/lib/components/breadcrumb/index.js +2 -2
- package/lib/components/breadcrumb/src/breadcrumb.js +11 -36
- package/lib/components/breadcrumb/src/breadcrumb.js.map +1 -1
- package/lib/components/breadcrumb/src/breadcrumb2.js +36 -11
- package/lib/components/breadcrumb/src/breadcrumb2.js.map +1 -1
- package/lib/components/button/index.js +1 -1
- package/lib/components/button/src/button-group.js +6 -30
- package/lib/components/button/src/button-group.js.map +1 -1
- package/lib/components/button/src/button-group2.js +30 -6
- package/lib/components/button/src/button-group2.js.map +1 -1
- package/lib/components/calendar/index.js +2 -2
- package/lib/components/calendar/src/calendar.js +131 -19
- package/lib/components/calendar/src/calendar.js.map +1 -1
- package/lib/components/calendar/src/calendar2.js +19 -131
- package/lib/components/calendar/src/calendar2.js.map +1 -1
- package/lib/components/index.js +3 -3
- package/lib/components/popconfirm/index.js +2 -2
- package/lib/components/popconfirm/src/popconfirm.js +110 -48
- package/lib/components/popconfirm/src/popconfirm.js.map +1 -1
- package/lib/components/popconfirm/src/popconfirm2.js +48 -110
- package/lib/components/popconfirm/src/popconfirm2.js.map +1 -1
- package/lib/components/teleport/index.js +2 -2
- package/lib/components/teleport/src/teleport.js +18 -44
- package/lib/components/teleport/src/teleport.js.map +1 -1
- package/lib/components/teleport/src/teleport2.js +44 -18
- package/lib/components/teleport/src/teleport2.js.map +1 -1
- package/lib/components/transfer/src/composables/use-check.js +1 -1
- package/lib/components/transfer/src/transfer-panel.js +21 -128
- package/lib/components/transfer/src/transfer-panel.js.map +1 -1
- package/lib/components/transfer/src/transfer-panel2.js +128 -21
- package/lib/components/transfer/src/transfer-panel2.js.map +1 -1
- package/lib/components/transfer/src/transfer2.js +1 -1
- package/lib/index.js +3 -3
- 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/theme-chalk/src/dialog.scss +7 -4
- package/theme-chalk/src/message-box.scss +7 -4
- package/theme-chalk/src/tour.scss +7 -4
- package/web-types.json +1 -1
|
@@ -1,133 +1,24 @@
|
|
|
1
|
-
import { defineComponent, useSlots, reactive, computed, toRefs, openBlock, createElementBlock, normalizeClass, unref, createElementVNode, createVNode, isRef, withCtx, createTextVNode, toDisplayString, createBlock, createCommentVNode, withDirectives, Fragment, renderList, vShow, renderSlot } from 'vue';
|
|
2
1
|
import '../../../utils/index.mjs';
|
|
3
|
-
import '
|
|
4
|
-
import {
|
|
5
|
-
import { ElInput } from '../../input/index.mjs';
|
|
6
|
-
import { Search } from '@element-plus/icons-vue';
|
|
7
|
-
import { transferPanelProps, transferPanelEmits } from './transfer-panel2.mjs';
|
|
8
|
-
import './composables/index.mjs';
|
|
9
|
-
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
10
|
-
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
11
|
-
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
12
|
-
import { usePropsAlias } from './composables/use-props-alias.mjs';
|
|
13
|
-
import { useCheck } from './composables/use-check.mjs';
|
|
14
|
-
import { isEmpty } from '../../../utils/types.mjs';
|
|
2
|
+
import { transferProps, transferCheckedChangeFn } from './transfer.mjs';
|
|
3
|
+
import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
|
|
15
4
|
|
|
16
|
-
const
|
|
17
|
-
|
|
5
|
+
const CHECKED_CHANGE_EVENT = "checked-change";
|
|
6
|
+
const transferPanelProps = buildProps({
|
|
7
|
+
data: transferProps.data,
|
|
8
|
+
optionRender: {
|
|
9
|
+
type: definePropType(Function)
|
|
10
|
+
},
|
|
11
|
+
placeholder: String,
|
|
12
|
+
title: String,
|
|
13
|
+
filterable: Boolean,
|
|
14
|
+
format: transferProps.format,
|
|
15
|
+
filterMethod: transferProps.filterMethod,
|
|
16
|
+
defaultChecked: transferProps.leftDefaultChecked,
|
|
17
|
+
props: transferProps.props
|
|
18
18
|
});
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
emits: transferPanelEmits,
|
|
23
|
-
setup(__props, { expose, emit }) {
|
|
24
|
-
const props = __props;
|
|
25
|
-
const slots = useSlots();
|
|
26
|
-
const OptionContent = ({ option }) => option;
|
|
27
|
-
const { t } = useLocale();
|
|
28
|
-
const ns = useNamespace("transfer");
|
|
29
|
-
const panelState = reactive({
|
|
30
|
-
checked: [],
|
|
31
|
-
allChecked: false,
|
|
32
|
-
query: "",
|
|
33
|
-
checkChangeByUser: true
|
|
34
|
-
});
|
|
35
|
-
const propsAlias = usePropsAlias(props);
|
|
36
|
-
const {
|
|
37
|
-
filteredData,
|
|
38
|
-
checkedSummary,
|
|
39
|
-
isIndeterminate,
|
|
40
|
-
handleAllCheckedChange
|
|
41
|
-
} = useCheck(props, panelState, emit);
|
|
42
|
-
const hasNoMatch = computed(() => !isEmpty(panelState.query) && isEmpty(filteredData.value));
|
|
43
|
-
const hasFooter = computed(() => !isEmpty(slots.default()[0].children));
|
|
44
|
-
const { checked, allChecked, query } = toRefs(panelState);
|
|
45
|
-
expose({
|
|
46
|
-
query
|
|
47
|
-
});
|
|
48
|
-
return (_ctx, _cache) => {
|
|
49
|
-
return openBlock(), createElementBlock("div", {
|
|
50
|
-
class: normalizeClass(unref(ns).b("panel"))
|
|
51
|
-
}, [
|
|
52
|
-
createElementVNode("p", {
|
|
53
|
-
class: normalizeClass(unref(ns).be("panel", "header"))
|
|
54
|
-
}, [
|
|
55
|
-
createVNode(unref(ElCheckbox), {
|
|
56
|
-
modelValue: unref(allChecked),
|
|
57
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(allChecked) ? allChecked.value = $event : null),
|
|
58
|
-
indeterminate: unref(isIndeterminate),
|
|
59
|
-
"validate-event": false,
|
|
60
|
-
onChange: unref(handleAllCheckedChange)
|
|
61
|
-
}, {
|
|
62
|
-
default: withCtx(() => [
|
|
63
|
-
createTextVNode(toDisplayString(_ctx.title) + " ", 1),
|
|
64
|
-
createElementVNode("span", null, toDisplayString(unref(checkedSummary)), 1)
|
|
65
|
-
]),
|
|
66
|
-
_: 1
|
|
67
|
-
}, 8, ["modelValue", "indeterminate", "onChange"])
|
|
68
|
-
], 2),
|
|
69
|
-
createElementVNode("div", {
|
|
70
|
-
class: normalizeClass([unref(ns).be("panel", "body"), unref(ns).is("with-footer", unref(hasFooter))])
|
|
71
|
-
}, [
|
|
72
|
-
_ctx.filterable ? (openBlock(), createBlock(unref(ElInput), {
|
|
73
|
-
key: 0,
|
|
74
|
-
modelValue: unref(query),
|
|
75
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => isRef(query) ? query.value = $event : null),
|
|
76
|
-
class: normalizeClass(unref(ns).be("panel", "filter")),
|
|
77
|
-
size: "default",
|
|
78
|
-
placeholder: _ctx.placeholder,
|
|
79
|
-
"prefix-icon": unref(Search),
|
|
80
|
-
clearable: "",
|
|
81
|
-
"validate-event": false
|
|
82
|
-
}, null, 8, ["modelValue", "class", "placeholder", "prefix-icon"])) : createCommentVNode("v-if", true),
|
|
83
|
-
withDirectives(createVNode(unref(ElCheckboxGroup), {
|
|
84
|
-
modelValue: unref(checked),
|
|
85
|
-
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => isRef(checked) ? checked.value = $event : null),
|
|
86
|
-
"validate-event": false,
|
|
87
|
-
class: normalizeClass([unref(ns).is("filterable", _ctx.filterable), unref(ns).be("panel", "list")])
|
|
88
|
-
}, {
|
|
89
|
-
default: withCtx(() => [
|
|
90
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(filteredData), (item) => {
|
|
91
|
-
return openBlock(), createBlock(unref(ElCheckbox), {
|
|
92
|
-
key: item[unref(propsAlias).key],
|
|
93
|
-
class: normalizeClass(unref(ns).be("panel", "item")),
|
|
94
|
-
label: item[unref(propsAlias).key],
|
|
95
|
-
disabled: item[unref(propsAlias).disabled],
|
|
96
|
-
"validate-event": false
|
|
97
|
-
}, {
|
|
98
|
-
default: withCtx(() => {
|
|
99
|
-
var _a;
|
|
100
|
-
return [
|
|
101
|
-
createVNode(OptionContent, {
|
|
102
|
-
option: (_a = _ctx.optionRender) == null ? void 0 : _a.call(_ctx, item)
|
|
103
|
-
}, null, 8, ["option"])
|
|
104
|
-
];
|
|
105
|
-
}),
|
|
106
|
-
_: 2
|
|
107
|
-
}, 1032, ["class", "label", "disabled"]);
|
|
108
|
-
}), 128))
|
|
109
|
-
]),
|
|
110
|
-
_: 1
|
|
111
|
-
}, 8, ["modelValue", "class"]), [
|
|
112
|
-
[vShow, !unref(hasNoMatch) && !unref(isEmpty)(_ctx.data)]
|
|
113
|
-
]),
|
|
114
|
-
withDirectives(createElementVNode("p", {
|
|
115
|
-
class: normalizeClass(unref(ns).be("panel", "empty"))
|
|
116
|
-
}, toDisplayString(unref(hasNoMatch) ? unref(t)("el.transfer.noMatch") : unref(t)("el.transfer.noData")), 3), [
|
|
117
|
-
[vShow, unref(hasNoMatch) || unref(isEmpty)(_ctx.data)]
|
|
118
|
-
])
|
|
119
|
-
], 2),
|
|
120
|
-
unref(hasFooter) ? (openBlock(), createElementBlock("p", {
|
|
121
|
-
key: 0,
|
|
122
|
-
class: normalizeClass(unref(ns).be("panel", "footer"))
|
|
123
|
-
}, [
|
|
124
|
-
renderSlot(_ctx.$slots, "default")
|
|
125
|
-
], 2)) : createCommentVNode("v-if", true)
|
|
126
|
-
], 2);
|
|
127
|
-
};
|
|
128
|
-
}
|
|
129
|
-
});
|
|
130
|
-
var TransferPanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "transfer-panel.vue"]]);
|
|
19
|
+
const transferPanelEmits = {
|
|
20
|
+
[CHECKED_CHANGE_EVENT]: transferCheckedChangeFn
|
|
21
|
+
};
|
|
131
22
|
|
|
132
|
-
export {
|
|
23
|
+
export { CHECKED_CHANGE_EVENT, transferPanelEmits, transferPanelProps };
|
|
133
24
|
//# sourceMappingURL=transfer-panel.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transfer-panel.mjs","sources":["../../../../../../packages/components/transfer/src/transfer-panel.
|
|
1
|
+
{"version":3,"file":"transfer-panel.mjs","sources":["../../../../../../packages/components/transfer/src/transfer-panel.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-plus/utils'\nimport { transferCheckedChangeFn, transferProps } from './transfer'\n\nimport type { ExtractPropTypes, VNode } from 'vue'\nimport type { TransferDataItem, TransferKey } from './transfer'\nimport type TransferPanel from './transfer-panel.vue'\n\nexport interface TransferPanelState {\n checked: TransferKey[]\n allChecked: boolean\n query: string\n checkChangeByUser: boolean\n}\n\nexport const CHECKED_CHANGE_EVENT = 'checked-change'\n\nexport const transferPanelProps = buildProps({\n data: transferProps.data,\n optionRender: {\n type: definePropType<(option: TransferDataItem) => VNode | VNode[]>(\n Function\n ),\n },\n placeholder: String,\n title: String,\n filterable: Boolean,\n format: transferProps.format,\n filterMethod: transferProps.filterMethod,\n defaultChecked: transferProps.leftDefaultChecked,\n props: transferProps.props,\n} as const)\nexport type TransferPanelProps = ExtractPropTypes<typeof transferPanelProps>\n\nexport const transferPanelEmits = {\n [CHECKED_CHANGE_EVENT]: transferCheckedChangeFn,\n}\nexport type TransferPanelEmits = typeof transferPanelEmits\n\nexport type TransferPanelInstance = InstanceType<typeof TransferPanel>\n"],"names":[],"mappings":";;;;AAEY,MAAC,oBAAoB,GAAG,iBAAiB;AACzC,MAAC,kBAAkB,GAAG,UAAU,CAAC;AAC7C,EAAE,IAAI,EAAE,aAAa,CAAC,IAAI;AAC1B,EAAE,YAAY,EAAE;AAChB,IAAI,IAAI,EAAE,cAAc,CAAC,QAAQ,CAAC;AAClC,GAAG;AACH,EAAE,WAAW,EAAE,MAAM;AACrB,EAAE,KAAK,EAAE,MAAM;AACf,EAAE,UAAU,EAAE,OAAO;AACrB,EAAE,MAAM,EAAE,aAAa,CAAC,MAAM;AAC9B,EAAE,YAAY,EAAE,aAAa,CAAC,YAAY;AAC1C,EAAE,cAAc,EAAE,aAAa,CAAC,kBAAkB;AAClD,EAAE,KAAK,EAAE,aAAa,CAAC,KAAK;AAC5B,CAAC,EAAE;AACS,MAAC,kBAAkB,GAAG;AAClC,EAAE,CAAC,oBAAoB,GAAG,uBAAuB;AACjD;;;;"}
|
|
@@ -1,24 +1,133 @@
|
|
|
1
|
+
import { defineComponent, useSlots, reactive, computed, toRefs, openBlock, createElementBlock, normalizeClass, unref, createElementVNode, createVNode, isRef, withCtx, createTextVNode, toDisplayString, createBlock, createCommentVNode, withDirectives, Fragment, renderList, vShow, renderSlot } from 'vue';
|
|
1
2
|
import '../../../utils/index.mjs';
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
3
|
+
import '../../../hooks/index.mjs';
|
|
4
|
+
import { ElCheckbox, ElCheckboxGroup } from '../../checkbox/index.mjs';
|
|
5
|
+
import { ElInput } from '../../input/index.mjs';
|
|
6
|
+
import { Search } from '@element-plus/icons-vue';
|
|
7
|
+
import { transferPanelProps, transferPanelEmits } from './transfer-panel.mjs';
|
|
8
|
+
import './composables/index.mjs';
|
|
9
|
+
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
10
|
+
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
11
|
+
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
|
12
|
+
import { usePropsAlias } from './composables/use-props-alias.mjs';
|
|
13
|
+
import { useCheck } from './composables/use-check.mjs';
|
|
14
|
+
import { isEmpty } from '../../../utils/types.mjs';
|
|
4
15
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
data: transferProps.data,
|
|
8
|
-
optionRender: {
|
|
9
|
-
type: definePropType(Function)
|
|
10
|
-
},
|
|
11
|
-
placeholder: String,
|
|
12
|
-
title: String,
|
|
13
|
-
filterable: Boolean,
|
|
14
|
-
format: transferProps.format,
|
|
15
|
-
filterMethod: transferProps.filterMethod,
|
|
16
|
-
defaultChecked: transferProps.leftDefaultChecked,
|
|
17
|
-
props: transferProps.props
|
|
16
|
+
const __default__ = defineComponent({
|
|
17
|
+
name: "ElTransferPanel"
|
|
18
18
|
});
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
20
|
+
...__default__,
|
|
21
|
+
props: transferPanelProps,
|
|
22
|
+
emits: transferPanelEmits,
|
|
23
|
+
setup(__props, { expose, emit }) {
|
|
24
|
+
const props = __props;
|
|
25
|
+
const slots = useSlots();
|
|
26
|
+
const OptionContent = ({ option }) => option;
|
|
27
|
+
const { t } = useLocale();
|
|
28
|
+
const ns = useNamespace("transfer");
|
|
29
|
+
const panelState = reactive({
|
|
30
|
+
checked: [],
|
|
31
|
+
allChecked: false,
|
|
32
|
+
query: "",
|
|
33
|
+
checkChangeByUser: true
|
|
34
|
+
});
|
|
35
|
+
const propsAlias = usePropsAlias(props);
|
|
36
|
+
const {
|
|
37
|
+
filteredData,
|
|
38
|
+
checkedSummary,
|
|
39
|
+
isIndeterminate,
|
|
40
|
+
handleAllCheckedChange
|
|
41
|
+
} = useCheck(props, panelState, emit);
|
|
42
|
+
const hasNoMatch = computed(() => !isEmpty(panelState.query) && isEmpty(filteredData.value));
|
|
43
|
+
const hasFooter = computed(() => !isEmpty(slots.default()[0].children));
|
|
44
|
+
const { checked, allChecked, query } = toRefs(panelState);
|
|
45
|
+
expose({
|
|
46
|
+
query
|
|
47
|
+
});
|
|
48
|
+
return (_ctx, _cache) => {
|
|
49
|
+
return openBlock(), createElementBlock("div", {
|
|
50
|
+
class: normalizeClass(unref(ns).b("panel"))
|
|
51
|
+
}, [
|
|
52
|
+
createElementVNode("p", {
|
|
53
|
+
class: normalizeClass(unref(ns).be("panel", "header"))
|
|
54
|
+
}, [
|
|
55
|
+
createVNode(unref(ElCheckbox), {
|
|
56
|
+
modelValue: unref(allChecked),
|
|
57
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(allChecked) ? allChecked.value = $event : null),
|
|
58
|
+
indeterminate: unref(isIndeterminate),
|
|
59
|
+
"validate-event": false,
|
|
60
|
+
onChange: unref(handleAllCheckedChange)
|
|
61
|
+
}, {
|
|
62
|
+
default: withCtx(() => [
|
|
63
|
+
createTextVNode(toDisplayString(_ctx.title) + " ", 1),
|
|
64
|
+
createElementVNode("span", null, toDisplayString(unref(checkedSummary)), 1)
|
|
65
|
+
]),
|
|
66
|
+
_: 1
|
|
67
|
+
}, 8, ["modelValue", "indeterminate", "onChange"])
|
|
68
|
+
], 2),
|
|
69
|
+
createElementVNode("div", {
|
|
70
|
+
class: normalizeClass([unref(ns).be("panel", "body"), unref(ns).is("with-footer", unref(hasFooter))])
|
|
71
|
+
}, [
|
|
72
|
+
_ctx.filterable ? (openBlock(), createBlock(unref(ElInput), {
|
|
73
|
+
key: 0,
|
|
74
|
+
modelValue: unref(query),
|
|
75
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => isRef(query) ? query.value = $event : null),
|
|
76
|
+
class: normalizeClass(unref(ns).be("panel", "filter")),
|
|
77
|
+
size: "default",
|
|
78
|
+
placeholder: _ctx.placeholder,
|
|
79
|
+
"prefix-icon": unref(Search),
|
|
80
|
+
clearable: "",
|
|
81
|
+
"validate-event": false
|
|
82
|
+
}, null, 8, ["modelValue", "class", "placeholder", "prefix-icon"])) : createCommentVNode("v-if", true),
|
|
83
|
+
withDirectives(createVNode(unref(ElCheckboxGroup), {
|
|
84
|
+
modelValue: unref(checked),
|
|
85
|
+
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => isRef(checked) ? checked.value = $event : null),
|
|
86
|
+
"validate-event": false,
|
|
87
|
+
class: normalizeClass([unref(ns).is("filterable", _ctx.filterable), unref(ns).be("panel", "list")])
|
|
88
|
+
}, {
|
|
89
|
+
default: withCtx(() => [
|
|
90
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(filteredData), (item) => {
|
|
91
|
+
return openBlock(), createBlock(unref(ElCheckbox), {
|
|
92
|
+
key: item[unref(propsAlias).key],
|
|
93
|
+
class: normalizeClass(unref(ns).be("panel", "item")),
|
|
94
|
+
label: item[unref(propsAlias).key],
|
|
95
|
+
disabled: item[unref(propsAlias).disabled],
|
|
96
|
+
"validate-event": false
|
|
97
|
+
}, {
|
|
98
|
+
default: withCtx(() => {
|
|
99
|
+
var _a;
|
|
100
|
+
return [
|
|
101
|
+
createVNode(OptionContent, {
|
|
102
|
+
option: (_a = _ctx.optionRender) == null ? void 0 : _a.call(_ctx, item)
|
|
103
|
+
}, null, 8, ["option"])
|
|
104
|
+
];
|
|
105
|
+
}),
|
|
106
|
+
_: 2
|
|
107
|
+
}, 1032, ["class", "label", "disabled"]);
|
|
108
|
+
}), 128))
|
|
109
|
+
]),
|
|
110
|
+
_: 1
|
|
111
|
+
}, 8, ["modelValue", "class"]), [
|
|
112
|
+
[vShow, !unref(hasNoMatch) && !unref(isEmpty)(_ctx.data)]
|
|
113
|
+
]),
|
|
114
|
+
withDirectives(createElementVNode("p", {
|
|
115
|
+
class: normalizeClass(unref(ns).be("panel", "empty"))
|
|
116
|
+
}, toDisplayString(unref(hasNoMatch) ? unref(t)("el.transfer.noMatch") : unref(t)("el.transfer.noData")), 3), [
|
|
117
|
+
[vShow, unref(hasNoMatch) || unref(isEmpty)(_ctx.data)]
|
|
118
|
+
])
|
|
119
|
+
], 2),
|
|
120
|
+
unref(hasFooter) ? (openBlock(), createElementBlock("p", {
|
|
121
|
+
key: 0,
|
|
122
|
+
class: normalizeClass(unref(ns).be("panel", "footer"))
|
|
123
|
+
}, [
|
|
124
|
+
renderSlot(_ctx.$slots, "default")
|
|
125
|
+
], 2)) : createCommentVNode("v-if", true)
|
|
126
|
+
], 2);
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
var TransferPanel = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "transfer-panel.vue"]]);
|
|
22
131
|
|
|
23
|
-
export {
|
|
132
|
+
export { TransferPanel as default };
|
|
24
133
|
//# sourceMappingURL=transfer-panel2.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transfer-panel2.mjs","sources":["../../../../../../packages/components/transfer/src/transfer-panel.
|
|
1
|
+
{"version":3,"file":"transfer-panel2.mjs","sources":["../../../../../../packages/components/transfer/src/transfer-panel.vue"],"sourcesContent":["<template>\n <div :class=\"ns.b('panel')\">\n <p :class=\"ns.be('panel', 'header')\">\n <el-checkbox\n v-model=\"allChecked\"\n :indeterminate=\"isIndeterminate\"\n :validate-event=\"false\"\n @change=\"handleAllCheckedChange\"\n >\n {{ title }}\n <span>{{ checkedSummary }}</span>\n </el-checkbox>\n </p>\n\n <div :class=\"[ns.be('panel', 'body'), ns.is('with-footer', hasFooter)]\">\n <el-input\n v-if=\"filterable\"\n v-model=\"query\"\n :class=\"ns.be('panel', 'filter')\"\n size=\"default\"\n :placeholder=\"placeholder\"\n :prefix-icon=\"Search\"\n clearable\n :validate-event=\"false\"\n />\n <el-checkbox-group\n v-show=\"!hasNoMatch && !isEmpty(data)\"\n v-model=\"checked\"\n :validate-event=\"false\"\n :class=\"[ns.is('filterable', filterable), ns.be('panel', 'list')]\"\n >\n <el-checkbox\n v-for=\"item in filteredData\"\n :key=\"item[propsAlias.key]\"\n :class=\"ns.be('panel', 'item')\"\n :label=\"item[propsAlias.key]\"\n :disabled=\"item[propsAlias.disabled]\"\n :validate-event=\"false\"\n >\n <option-content :option=\"optionRender?.(item)\" />\n </el-checkbox>\n </el-checkbox-group>\n <p v-show=\"hasNoMatch || isEmpty(data)\" :class=\"ns.be('panel', 'empty')\">\n {{ hasNoMatch ? t('el.transfer.noMatch') : t('el.transfer.noData') }}\n </p>\n </div>\n <p v-if=\"hasFooter\" :class=\"ns.be('panel', 'footer')\">\n <slot />\n </p>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, reactive, toRefs, useSlots } from 'vue'\nimport { isEmpty } from '@element-plus/utils'\nimport { useLocale, useNamespace } from '@element-plus/hooks'\nimport { ElCheckbox, ElCheckboxGroup } from '@element-plus/components/checkbox'\nimport { ElInput } from '@element-plus/components/input'\nimport { Search } from '@element-plus/icons-vue'\nimport { transferPanelEmits, transferPanelProps } from './transfer-panel'\nimport { useCheck, usePropsAlias } from './composables'\n\nimport type { VNode } from 'vue'\nimport type { TransferPanelState } from './transfer-panel'\n\ndefineOptions({\n name: 'ElTransferPanel',\n})\n\nconst props = defineProps(transferPanelProps)\nconst emit = defineEmits(transferPanelEmits)\nconst slots = useSlots()\n\nconst OptionContent = ({ option }: { option: VNode | VNode[] }) => option\n\nconst { t } = useLocale()\nconst ns = useNamespace('transfer')\n\nconst panelState = reactive<TransferPanelState>({\n checked: [],\n allChecked: false,\n query: '',\n checkChangeByUser: true,\n})\n\nconst propsAlias = usePropsAlias(props)\n\nconst {\n filteredData,\n checkedSummary,\n isIndeterminate,\n handleAllCheckedChange,\n} = useCheck(props, panelState, emit)\n\nconst hasNoMatch = computed(\n () => !isEmpty(panelState.query) && isEmpty(filteredData.value)\n)\n\nconst hasFooter = computed(() => !isEmpty(slots.default!()[0].children))\n\nconst { checked, allChecked, query } = toRefs(panelState)\n\ndefineExpose({\n /** @description filter keyword */\n query,\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;mCAiEc,CAAA;AAAA,EACZ,IAAM,EAAA,iBAAA;AACR,CAAA,CAAA,CAAA;;;;;;;AAIA,IAAA,MAAM,QAAQ,QAAS,EAAA,CAAA;AAEvB,IAAM,MAAA,aAAA,GAAgB,CAAC,EAAE,MAA0C,EAAA,KAAA,MAAA,CAAA;AAEnE,IAAM,MAAA,EAAE,MAAM,SAAU,EAAA,CAAA;AACxB,IAAM,MAAA,EAAA,GAAK,aAAa,UAAU,CAAA,CAAA;AAElC,IAAA,MAAM,aAAa,QAA6B,CAAA;AAAA,MAC9C,SAAS,EAAC;AAAA,MACV,UAAY,EAAA,KAAA;AAAA,MACZ,KAAO,EAAA,EAAA;AAAA,MACP,iBAAmB,EAAA,IAAA;AAAA,KACpB,CAAA,CAAA;AAED,IAAM,MAAA,UAAA,GAAa,cAAc,KAAK,CAAA,CAAA;AAEtC,IAAM,MAAA;AAAA,MACJ,YAAA;AAAA,MACA,cAAA;AAAA,MACA,eAAA;AAAA,MACA,sBAAA;AAAA,KACE,GAAA,QAAA,CAAS,KAAO,EAAA,UAAA,EAAY,IAAI,CAAA,CAAA;AAEpC,IAAM,MAAA,UAAA,GAAa,QACjB,CAAA,MAAM,CAAC,OAAA,CAAQ,UAAW,CAAA,KAAK,CAAK,IAAA,OAAA,CAAQ,YAAa,CAAA,KAAK,CAChE,CAAA,CAAA;AAEA,IAAM,MAAA,SAAA,GAAY,QAAS,CAAA,MAAM,CAAC,OAAA,CAAQ,MAAM,OAAS,EAAA,CAAE,CAAG,CAAA,CAAA,QAAQ,CAAC,CAAA,CAAA;AAEvE,IAAA,MAAM,EAAE,OAAA,EAAS,UAAY,EAAA,KAAA,EAAA,GAAU,OAAO,UAAU,CAAA,CAAA;AAExD,IAAa,MAAA,CAAA;AAAA,MAEX,KAAA;AAAA,KACD,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -7,7 +7,7 @@ import '../../form/index.mjs';
|
|
|
7
7
|
import { ArrowLeft, ArrowRight } from '@element-plus/icons-vue';
|
|
8
8
|
import { transferProps, transferEmits } from './transfer.mjs';
|
|
9
9
|
import './composables/index.mjs';
|
|
10
|
-
import TransferPanel from './transfer-
|
|
10
|
+
import TransferPanel from './transfer-panel2.mjs';
|
|
11
11
|
import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
|
|
12
12
|
import { useLocale } from '../../../hooks/use-locale/index.mjs';
|
|
13
13
|
import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
|
package/es/index.mjs
CHANGED
|
@@ -18,14 +18,14 @@ export { backtopEmits, backtopProps } from './components/backtop/src/backtop.mjs
|
|
|
18
18
|
export { ElBacktop } from './components/backtop/index.mjs';
|
|
19
19
|
export { badgeProps } from './components/badge/src/badge.mjs';
|
|
20
20
|
export { ElBadge } from './components/badge/index.mjs';
|
|
21
|
-
export { breadcrumbProps } from './components/breadcrumb/src/
|
|
21
|
+
export { breadcrumbProps } from './components/breadcrumb/src/breadcrumb.mjs';
|
|
22
22
|
export { breadcrumbItemProps } from './components/breadcrumb/src/breadcrumb-item.mjs';
|
|
23
23
|
export { breadcrumbKey } from './components/breadcrumb/src/constants.mjs';
|
|
24
24
|
export { ElBreadcrumb, ElBreadcrumbItem } from './components/breadcrumb/index.mjs';
|
|
25
25
|
export { buttonEmits, buttonNativeTypes, buttonProps, buttonTypes } from './components/button/src/button.mjs';
|
|
26
26
|
export { buttonGroupContextKey } from './components/button/src/constants.mjs';
|
|
27
27
|
export { ElButton, ElButtonGroup } from './components/button/index.mjs';
|
|
28
|
-
export { calendarEmits, calendarProps } from './components/calendar/src/
|
|
28
|
+
export { calendarEmits, calendarProps } from './components/calendar/src/calendar2.mjs';
|
|
29
29
|
export { ElCalendar } from './components/calendar/index.mjs';
|
|
30
30
|
export { cardProps } from './components/card/src/card.mjs';
|
|
31
31
|
export { ElCard } from './components/card/index.mjs';
|
|
@@ -109,7 +109,7 @@ export { ElPageHeader } from './components/page-header/index.mjs';
|
|
|
109
109
|
export { paginationEmits, paginationProps } from './components/pagination/src/pagination.mjs';
|
|
110
110
|
export { elPaginationKey } from './components/pagination/src/constants.mjs';
|
|
111
111
|
export { ElPagination } from './components/pagination/index.mjs';
|
|
112
|
-
export { popconfirmEmits, popconfirmProps } from './components/popconfirm/src/
|
|
112
|
+
export { popconfirmEmits, popconfirmProps } from './components/popconfirm/src/popconfirm2.mjs';
|
|
113
113
|
export { ElPopconfirm } from './components/popconfirm/index.mjs';
|
|
114
114
|
export { Effect, popperProps, roleTypes, usePopperProps } from './components/popper/src/popper.mjs';
|
|
115
115
|
export { popperTriggerProps, usePopperTriggerProps } from './components/popper/src/trigger.mjs';
|
package/es/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "0.0.
|
|
1
|
+
export declare const version = "0.0.20240216";
|
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.20240216'\n"],"names":[],"mappings":"AAAY,MAAC,OAAO,GAAG;;;;"}
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
require('../../utils/index.js');
|
|
6
|
-
var breadcrumb$1 = require('./src/
|
|
6
|
+
var breadcrumb$1 = require('./src/breadcrumb2.js');
|
|
7
7
|
var breadcrumbItem$1 = require('./src/breadcrumb-item2.js');
|
|
8
|
-
var breadcrumb = require('./src/
|
|
8
|
+
var breadcrumb = require('./src/breadcrumb.js');
|
|
9
9
|
var breadcrumbItem = require('./src/breadcrumb-item.js');
|
|
10
10
|
var constants = require('./src/constants.js');
|
|
11
11
|
var install = require('../../utils/vue/install.js');
|
|
@@ -2,44 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
require('../../../
|
|
7
|
-
var
|
|
8
|
-
var breadcrumb = require('./breadcrumb2.js');
|
|
9
|
-
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
10
|
-
var index = require('../../../hooks/use-namespace/index.js');
|
|
5
|
+
require('../../../utils/index.js');
|
|
6
|
+
var runtime = require('../../../utils/vue/props/runtime.js');
|
|
7
|
+
var icon = require('../../../utils/vue/icon.js');
|
|
11
8
|
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
const props = __props;
|
|
20
|
-
const ns = index.useNamespace("breadcrumb");
|
|
21
|
-
const breadcrumb = vue.ref();
|
|
22
|
-
vue.provide(constants.breadcrumbKey, props);
|
|
23
|
-
vue.onMounted(() => {
|
|
24
|
-
const items = breadcrumb.value.querySelectorAll(`.${ns.e("item")}`);
|
|
25
|
-
if (items.length) {
|
|
26
|
-
items[items.length - 1].setAttribute("aria-current", "page");
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
return (_ctx, _cache) => {
|
|
30
|
-
return vue.openBlock(), vue.createElementBlock("div", {
|
|
31
|
-
ref_key: "breadcrumb",
|
|
32
|
-
ref: breadcrumb,
|
|
33
|
-
class: vue.normalizeClass(vue.unref(ns).b()),
|
|
34
|
-
"aria-label": "Breadcrumb",
|
|
35
|
-
role: "navigation"
|
|
36
|
-
}, [
|
|
37
|
-
vue.renderSlot(_ctx.$slots, "default")
|
|
38
|
-
], 2);
|
|
39
|
-
};
|
|
9
|
+
const breadcrumbProps = runtime.buildProps({
|
|
10
|
+
separator: {
|
|
11
|
+
type: String,
|
|
12
|
+
default: "/"
|
|
13
|
+
},
|
|
14
|
+
separatorIcon: {
|
|
15
|
+
type: icon.iconPropType
|
|
40
16
|
}
|
|
41
17
|
});
|
|
42
|
-
var Breadcrumb = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "breadcrumb.vue"]]);
|
|
43
18
|
|
|
44
|
-
exports
|
|
19
|
+
exports.breadcrumbProps = breadcrumbProps;
|
|
45
20
|
//# sourceMappingURL=breadcrumb.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"breadcrumb.js","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb.
|
|
1
|
+
{"version":3,"file":"breadcrumb.js","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb.ts"],"sourcesContent":["import { buildProps, iconPropType } from '@element-plus/utils'\nimport type { ExtractPropTypes } from 'vue'\n\nexport const breadcrumbProps = buildProps({\n /**\n * @description separator character\n */\n separator: {\n type: String,\n default: '/',\n },\n /**\n * @description icon component of icon separator\n */\n separatorIcon: {\n type: iconPropType,\n },\n} as const)\nexport type BreadcrumbProps = ExtractPropTypes<typeof breadcrumbProps>\n"],"names":["buildProps","iconPropType"],"mappings":";;;;;;;;AACY,MAAC,eAAe,GAAGA,kBAAU,CAAC;AAC1C,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,aAAa,EAAE;AACjB,IAAI,IAAI,EAAEC,iBAAY;AACtB,GAAG;AACH,CAAC;;;;"}
|
|
@@ -2,19 +2,44 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
require('
|
|
6
|
-
|
|
7
|
-
var
|
|
5
|
+
var vue = require('vue');
|
|
6
|
+
require('../../../hooks/index.js');
|
|
7
|
+
var constants = require('./constants.js');
|
|
8
|
+
var breadcrumb = require('./breadcrumb.js');
|
|
9
|
+
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
10
|
+
var index = require('../../../hooks/use-namespace/index.js');
|
|
8
11
|
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
const __default__ = vue.defineComponent({
|
|
13
|
+
name: "ElBreadcrumb"
|
|
14
|
+
});
|
|
15
|
+
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
16
|
+
...__default__,
|
|
17
|
+
props: breadcrumb.breadcrumbProps,
|
|
18
|
+
setup(__props) {
|
|
19
|
+
const props = __props;
|
|
20
|
+
const ns = index.useNamespace("breadcrumb");
|
|
21
|
+
const breadcrumb = vue.ref();
|
|
22
|
+
vue.provide(constants.breadcrumbKey, props);
|
|
23
|
+
vue.onMounted(() => {
|
|
24
|
+
const items = breadcrumb.value.querySelectorAll(`.${ns.e("item")}`);
|
|
25
|
+
if (items.length) {
|
|
26
|
+
items[items.length - 1].setAttribute("aria-current", "page");
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
return (_ctx, _cache) => {
|
|
30
|
+
return vue.openBlock(), vue.createElementBlock("div", {
|
|
31
|
+
ref_key: "breadcrumb",
|
|
32
|
+
ref: breadcrumb,
|
|
33
|
+
class: vue.normalizeClass(vue.unref(ns).b()),
|
|
34
|
+
"aria-label": "Breadcrumb",
|
|
35
|
+
role: "navigation"
|
|
36
|
+
}, [
|
|
37
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
38
|
+
], 2);
|
|
39
|
+
};
|
|
16
40
|
}
|
|
17
41
|
});
|
|
42
|
+
var Breadcrumb = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "breadcrumb.vue"]]);
|
|
18
43
|
|
|
19
|
-
exports
|
|
44
|
+
exports["default"] = Breadcrumb;
|
|
20
45
|
//# sourceMappingURL=breadcrumb2.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"breadcrumb2.js","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb.
|
|
1
|
+
{"version":3,"file":"breadcrumb2.js","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb.vue"],"sourcesContent":["<template>\n <div\n ref=\"breadcrumb\"\n :class=\"ns.b()\"\n aria-label=\"Breadcrumb\"\n role=\"navigation\"\n >\n <slot />\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { onMounted, provide, ref } from 'vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { breadcrumbKey } from './constants'\nimport { breadcrumbProps } from './breadcrumb'\n\ndefineOptions({\n name: 'ElBreadcrumb',\n})\n\nconst props = defineProps(breadcrumbProps)\n\nconst ns = useNamespace('breadcrumb')\nconst breadcrumb = ref<HTMLDivElement>()\n\nprovide(breadcrumbKey, props)\n\nonMounted(() => {\n const items = breadcrumb.value!.querySelectorAll(`.${ns.e('item')}`)\n if (items.length) {\n items[items.length - 1].setAttribute('aria-current', 'page')\n }\n})\n</script>\n"],"names":["useNamespace","ref","provide","breadcrumbKey","onMounted"],"mappings":";;;;;;;;;;;uCAiBc,CAAA;AAAA,EACZ,IAAM,EAAA,cAAA;AACR,CAAA,CAAA,CAAA;;;;;;AAIA,IAAM,MAAA,EAAA,GAAKA,mBAAa,YAAY,CAAA,CAAA;AACpC,IAAA,MAAM,aAAaC,OAAoB,EAAA,CAAA;AAEvC,IAAAC,WAAA,CAAQC,yBAAe,KAAK,CAAA,CAAA;AAE5B,IAAAC,aAAA,CAAU,MAAM;AACd,MAAM,MAAA,KAAA,GAAQ,WAAW,KAAO,CAAA,gBAAA,CAAiB,IAAI,EAAG,CAAA,CAAA,CAAE,MAAM,CAAG,CAAA,CAAA,CAAA,CAAA;AACnE,MAAA,IAAI,MAAM,MAAQ,EAAA;AAChB,QAAA,KAAA,CAAM,KAAM,CAAA,MAAA,GAAS,CAAG,CAAA,CAAA,YAAA,CAAa,gBAAgB,MAAM,CAAA,CAAA;AAAA,OAC7D;AAAA,KACD,CAAA,CAAA;;;;;;;;;;;;;;;;;;"}
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
require('../../utils/index.js');
|
|
6
6
|
var button$1 = require('./src/button2.js');
|
|
7
|
-
var buttonGroup = require('./src/button-
|
|
7
|
+
var buttonGroup = require('./src/button-group2.js');
|
|
8
8
|
var button = require('./src/button.js');
|
|
9
9
|
var constants = require('./src/constants.js');
|
|
10
10
|
var install = require('../../utils/vue/install.js');
|
|
@@ -2,36 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var
|
|
6
|
-
require('../../../hooks/index.js');
|
|
7
|
-
var buttonGroup = require('./button-group2.js');
|
|
8
|
-
var constants = require('./constants.js');
|
|
9
|
-
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
10
|
-
var index = require('../../../hooks/use-namespace/index.js');
|
|
5
|
+
var button = require('./button.js');
|
|
11
6
|
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
...__default__,
|
|
17
|
-
props: buttonGroup.buttonGroupProps,
|
|
18
|
-
setup(__props) {
|
|
19
|
-
const props = __props;
|
|
20
|
-
vue.provide(constants.buttonGroupContextKey, vue.reactive({
|
|
21
|
-
size: vue.toRef(props, "size"),
|
|
22
|
-
type: vue.toRef(props, "type")
|
|
23
|
-
}));
|
|
24
|
-
const ns = index.useNamespace("button");
|
|
25
|
-
return (_ctx, _cache) => {
|
|
26
|
-
return vue.openBlock(), vue.createElementBlock("div", {
|
|
27
|
-
class: vue.normalizeClass(`${vue.unref(ns).b("group")}`)
|
|
28
|
-
}, [
|
|
29
|
-
vue.renderSlot(_ctx.$slots, "default")
|
|
30
|
-
], 2);
|
|
31
|
-
};
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
var ButtonGroup = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "button-group.vue"]]);
|
|
7
|
+
const buttonGroupProps = {
|
|
8
|
+
size: button.buttonProps.size,
|
|
9
|
+
type: button.buttonProps.type
|
|
10
|
+
};
|
|
35
11
|
|
|
36
|
-
exports
|
|
12
|
+
exports.buttonGroupProps = buttonGroupProps;
|
|
37
13
|
//# sourceMappingURL=button-group.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button-group.js","sources":["../../../../../../packages/components/button/src/button-group.
|
|
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 /**\n * @description control the size of buttons in this button-group\n */\n size: buttonProps.size,\n /**\n * @description control the type of buttons in this button-group\n */\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;;;;"}
|