jmash-core 0.0.3 → 0.0.5
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/401-DZeMj80g.mjs +103 -0
- package/dist/404-D1KiG-19.mjs +37 -0
- package/dist/BarChart-BYm859ri.mjs +203 -0
- package/dist/FileSaver.min-DJ2XURfB.mjs +77 -0
- package/dist/FunnelChart-Czy2TVI1.mjs +106 -0
- package/dist/PieChart-BRbbIH3_.mjs +4 -0
- package/dist/PieChart.vue_vue_type_script_setup_true_lang-XjLBqCzM.mjs +90 -0
- package/dist/RadarChart-Bk_uy6Km.mjs +4 -0
- package/dist/RadarChart.vue_vue_type_script_setup_true_lang-COsDkkQU.mjs +109 -0
- package/dist/_plugin-vue_export-helper-CHgC5LLL.mjs +9 -0
- package/dist/caret-bottom-DGvkHVYd.mjs +59 -0
- package/dist/common-DuVBTwAv.mjs +36 -0
- package/dist/debounce-XYByYe_I.mjs +81 -0
- package/dist/dropdown2-D_RJXnOl.mjs +160 -0
- package/dist/edit-BTjApg1x.mjs +468 -0
- package/dist/edit-BcLHrCSo.mjs +4 -0
- package/dist/edit-DC3SyT6J.mjs +4 -0
- package/dist/edit-DmP9tv3r.mjs +4 -0
- package/dist/edit-Dr-9X4r3.mjs +4 -0
- package/dist/edit-FjRAXd1B.mjs +832 -0
- package/dist/edit-bpHMc65Q.mjs +4 -0
- package/dist/edit-lB54egzx.mjs +4 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-BKutjIoX.mjs +621 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-BVXBx_a-.mjs +221 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-Bm1SAtWP.mjs +225 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-CYZNHUnm.mjs +156 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-CZmh3q4f.mjs +287 -0
- package/dist/edit.vue_vue_type_script_setup_true_lang-DqZ2GCoE.mjs +136 -0
- package/dist/el-card-Da9MvaWO.mjs +61 -0
- package/dist/el-checkbox-B44P9jFr.mjs +548 -0
- package/dist/el-checkbox-group-l0sNRNKZ.mjs +1 -0
- package/dist/el-col-BY0nB6k3.mjs +135 -0
- package/dist/el-date-picker-CVwJoDEA.mjs +3349 -0
- package/dist/el-dialog-CSWvTJrq.mjs +378 -0
- package/dist/el-dropdown-item-CD8hUpml.mjs +675 -0
- package/dist/el-form-item-f-baJSfe.mjs +1489 -0
- package/dist/el-icon-l0sNRNKZ.mjs +1 -0
- package/dist/el-popover-D8RrIMbA.mjs +159 -0
- package/dist/el-popper-C13p_dqu.mjs +1656 -0
- package/dist/el-progress-CHUzIxT1.mjs +898 -0
- package/dist/el-radio-BpdPD-RN.mjs +251 -0
- package/dist/el-scrollbar-B8QteGV0.mjs +607 -0
- package/dist/el-select-ChOy6agQ.mjs +1040 -0
- package/dist/el-switch-cqWxQwcb.mjs +254 -0
- package/dist/el-table-c9Sup56w.mjs +3168 -0
- package/dist/el-tag-l0sNRNKZ.mjs +1 -0
- package/dist/el-tooltip-l0sNRNKZ.mjs +1 -0
- package/dist/el-tree-select-CKOwMXR7.mjs +1316 -0
- package/dist/importUpload.vue_vue_type_script_setup_true_lang-DWrcOBGS.mjs +116 -0
- package/dist/index-B6wY38lY.mjs +13173 -0
- package/dist/index-BH-_mfRR.mjs +107 -0
- package/dist/index-BfhiNV8H.mjs +486 -0
- package/dist/index-BjqMDjBg.mjs +43994 -0
- package/dist/index-BuHauank.mjs +13 -0
- package/dist/index-CBJwB8q2.mjs +633 -0
- package/dist/index-CGCQHwLq.mjs +482 -0
- package/dist/index-CU0iVHXP.mjs +281 -0
- package/dist/index-CYxGYOaT.mjs +504 -0
- package/dist/index-Cjii0qCc.mjs +278 -0
- package/dist/index-Czh2Pqwr.mjs +63 -0
- package/dist/index-DJ08yxAP.mjs +11 -0
- package/dist/index-DUKlDGLk.mjs +2589 -0
- package/dist/index-DUVtKaDI.mjs +515 -0
- package/dist/index-Dgd4Zhxz.mjs +93 -0
- package/dist/index-Di5--Hao.mjs +328 -0
- package/dist/index-DjkMA-Wh.mjs +40 -0
- package/dist/index-DrKW_cyG.mjs +247 -0
- package/dist/index-LuiPOgGW.mjs +291 -0
- package/dist/index-VD-Tf32c.mjs +74 -0
- package/dist/index-cRrjzkNb.mjs +452 -0
- package/dist/index-cp7l4CIE.mjs +134 -0
- package/dist/index-dKz1IRM_.mjs +279 -0
- package/dist/index-dLPnFa10.mjs +964 -0
- package/dist/index-uykKwY2Z.mjs +12 -0
- package/dist/index-vp1_Sd0A.mjs +55 -0
- package/dist/index.mjs +22 -273
- package/dist/index.vue_vue_type_script_setup_true_lang-DcIQIMBC.mjs +286 -0
- package/dist/index.vue_vue_type_script_setup_true_lang-DidEhco6.mjs +58 -0
- package/dist/isUndefined-CUQZk6oB.mjs +6 -0
- package/dist/moment-CMYwqyVT.mjs +2579 -0
- package/dist/picture-kDaEiPHi.mjs +599 -0
- package/dist/profile-Sn98YUfh.mjs +319 -0
- package/dist/refs-COP_DuTD.mjs +9 -0
- package/dist/style.css +1 -1
- package/dist/types-BolK_Oyb.mjs +205 -0
- package/dist/updatePwd-B3rEU05i.mjs +4 -0
- package/dist/updatePwd.vue_vue_type_script_setup_true_lang-1LEdjkQ3.mjs +151 -0
- package/dist/useColumnToggleTable-CC9EXcfR.mjs +272 -0
- package/dts/src/App.vue.d.ts +1 -1
- package/dts/src/api/auth/index.d.ts +41 -0
- package/dts/src/api/auth/types.d.ts +180 -0
- package/dts/src/api/file/index.d.ts +14 -0
- package/dts/src/api/file/types.d.ts +7 -0
- package/dts/src/api/system/dept/index.d.ts +91 -0
- package/dts/src/api/system/dept/types.d.ts +63 -0
- package/dts/src/api/system/index.d.ts +7 -0
- package/dts/src/api/system/job/index.d.ts +42 -0
- package/dts/src/api/system/job/types.d.ts +60 -0
- package/dts/src/api/system/log/index.d.ts +29 -0
- package/dts/src/api/system/log/types.d.ts +42 -0
- package/dts/src/api/system/menu/index.d.ts +103 -0
- package/dts/src/api/system/menu/types.d.ts +96 -0
- package/dts/src/api/system/module/index.d.ts +57 -0
- package/dts/src/api/system/module/types.d.ts +13 -0
- package/dts/src/api/system/operation/index.d.ts +51 -0
- package/dts/src/api/system/operation/types.d.ts +12 -0
- package/dts/src/api/system/permission/index.d.ts +50 -0
- package/dts/src/api/system/permission/types.d.ts +12 -0
- package/dts/src/api/system/role/index.d.ts +77 -0
- package/dts/src/api/system/role/types.d.ts +26 -0
- package/dts/src/api/system/user/index.d.ts +133 -0
- package/dts/src/api/system/user/types.d.ts +53 -0
- package/dts/src/api/system/userLog/index.d.ts +29 -0
- package/dts/src/api/system/userLog/types.d.ts +22 -0
- package/dts/src/assets/icons/index.d.ts +0 -0
- package/dts/src/components/{icons/IconDocumentation.vue.d.ts → Breadcrumb/index.vue.d.ts} +1 -1
- package/dts/src/components/DictRadio/index.vue.d.ts +23 -0
- package/dts/src/components/DictSelect/index.vue.d.ts +41 -0
- package/dts/src/components/Dictionary/index.vue.d.ts +47 -0
- package/dts/src/components/{TheWelcome.vue.d.ts → GithubCorner/index.vue.d.ts} +1 -1
- package/dts/src/components/Hamburger/index.vue.d.ts +18 -0
- package/dts/src/components/IconSelect/index.vue.d.ts +20 -0
- package/dts/src/components/IconSelect/requireIcons.d.ts +2 -0
- package/dts/src/components/{icons/IconEcosystem.vue.d.ts → LangSelect/index.vue.d.ts} +1 -1
- package/dts/src/components/Pagination/index.vue.d.ts +88 -0
- package/dts/src/components/RightPanel/index.vue.d.ts +21 -0
- package/dts/src/components/{icons/IconCommunity.vue.d.ts → SizeSelect/index.vue.d.ts} +1 -1
- package/dts/src/components/SvgIcon/index.vue.d.ts +43 -0
- package/dts/src/components/Table/index.vue.d.ts +73 -0
- package/dts/src/components/TableSet/index.vue.d.ts +29 -0
- package/dts/src/components/Upload/MultiUpload.vue.d.ts +65 -0
- package/dts/src/components/Upload/SingleUpload.vue.d.ts +18 -0
- package/dts/src/components/Upload/importUpload.vue.d.ts +31 -0
- package/dts/src/components/Upload/index.vue.d.ts +18 -0
- package/dts/src/components/WangEditor/index.vue.d.ts +18 -0
- package/dts/src/directive/index.d.ts +5 -0
- package/dts/src/directive/permission/index.d.ts +9 -0
- package/dts/src/enums/MenuTypeEnum.d.ts +18 -0
- package/dts/src/hooks/useColumnToggleTable.d.ts +7 -0
- package/dts/src/index.d.ts +29 -3
- package/dts/src/lang/index.d.ts +534 -0
- package/dts/src/lang/package/en.d.ts +261 -0
- package/dts/src/lang/package/zh-cn.d.ts +275 -0
- package/dts/src/layout/components/AppMain.vue.d.ts +2 -0
- package/dts/src/layout/components/NavBar/NavRight.vue.d.ts +2 -0
- package/dts/src/layout/components/NavBar/index.vue.d.ts +2 -0
- package/dts/src/layout/components/Settings/index.vue.d.ts +2 -0
- package/dts/src/layout/components/Sidebar/Item.vue.d.ts +23 -0
- package/dts/src/layout/components/Sidebar/LeftMenu.vue.d.ts +24 -0
- package/dts/src/layout/components/Sidebar/Link.vue.d.ts +19 -0
- package/dts/src/layout/components/Sidebar/Logo.vue.d.ts +12 -0
- package/dts/src/layout/components/Sidebar/SidebarItem.vue.d.ts +42 -0
- package/dts/src/layout/components/Sidebar/TopMenu.vue.d.ts +2 -0
- package/dts/src/layout/components/Sidebar/index.vue.d.ts +2 -0
- package/dts/src/layout/components/TagsView/ScrollPane.vue.d.ts +16 -0
- package/dts/src/layout/components/TagsView/index.vue.d.ts +2 -0
- package/dts/src/layout/components/index.d.ts +4 -0
- package/dts/src/layout/index.vue.d.ts +2 -0
- package/dts/src/layout/main.vue.d.ts +2 -0
- package/dts/src/main.d.ts +5 -1
- package/dts/src/permission.d.ts +1 -0
- package/dts/src/router/index.d.ts +10 -0
- package/dts/src/settings.d.ts +13 -0
- package/dts/src/stores/index.d.ts +7 -0
- package/dts/src/stores/modules/tagsView.d.ts +82 -0
- package/dts/src/utils/common.d.ts +6 -0
- package/dts/src/utils/grpc.d.ts +2 -0
- package/dts/src/utils/i18n.d.ts +1 -0
- package/dts/src/utils/index.d.ts +24 -0
- package/dts/src/utils/request.d.ts +2 -0
- package/dts/src/utils/resize.d.ts +1 -0
- package/dts/src/utils/scroll-to.d.ts +6 -0
- package/dts/src/views/dashboard/components/BarChart.vue.d.ts +45 -0
- package/dts/src/views/dashboard/components/FunnelChart.vue.d.ts +45 -0
- package/dts/src/views/dashboard/components/PieChart.vue.d.ts +45 -0
- package/dts/src/views/dashboard/components/RadarChart.vue.d.ts +45 -0
- package/dts/src/views/dashboard/index.vue.d.ts +2 -0
- package/dts/src/views/error-page/401.vue.d.ts +2 -0
- package/dts/src/views/error-page/404.vue.d.ts +2 -0
- package/dts/src/views/login/components/types.vue.d.ts +2 -0
- package/dts/src/views/login/index.vue.d.ts +2 -0
- package/dts/src/views/my/profile.vue.d.ts +2 -0
- package/dts/src/views/my/updatePwd.vue.d.ts +18 -0
- package/dts/src/views/redirect/index.vue.d.ts +2 -0
- package/dts/src/views/system/dept/edit.vue.d.ts +31 -0
- package/dts/src/views/system/dept/index.vue.d.ts +2 -0
- package/dts/src/views/system/job/edit.vue.d.ts +30 -0
- package/dts/src/views/system/job/index.vue.d.ts +2 -0
- package/dts/src/views/system/log/index.vue.d.ts +2 -0
- package/dts/src/views/system/log/oplog/index.vue.d.ts +2 -0
- package/dts/src/views/system/log/userLog/index.vue.d.ts +2 -0
- package/dts/src/views/system/menu/edit.vue.d.ts +31 -0
- package/dts/src/views/system/menu/index.vue.d.ts +2 -0
- package/dts/src/views/system/module/edit.vue.d.ts +31 -0
- package/dts/src/views/system/module/index.vue.d.ts +2 -0
- package/dts/src/views/system/operation/edit.vue.d.ts +31 -0
- package/dts/src/views/system/operation/index.vue.d.ts +2 -0
- package/dts/src/views/system/permission/edit.vue.d.ts +30 -0
- package/dts/src/views/system/permission/index.vue.d.ts +2 -0
- package/dts/src/views/system/role/edit.vue.d.ts +31 -0
- package/dts/src/views/system/role/index.vue.d.ts +2 -0
- package/dts/src/views/system/user/edit.vue.d.ts +31 -0
- package/dts/src/views/system/user/index.vue.d.ts +2 -0
- package/dts/tsconfig.tsbuildinfo +1 -1
- package/package.json +31 -2
- package/dts/src/components/HelloWorld.vue.d.ts +0 -15
- package/dts/src/components/WelcomeItem.vue.d.ts +0 -11
- package/dts/src/components/icons/IconSupport.vue.d.ts +0 -2
- package/dts/src/components/icons/IconTooling.vue.d.ts +0 -2
- package/dts/src/stores/counter.d.ts +0 -13
- package/dts/src/views/AboutView.vue.d.ts +0 -2
- package/dts/src/views/HomeView.vue.d.ts +0 -2
|
@@ -0,0 +1,675 @@
|
|
|
1
|
+
import { defineComponent as G, ref as $, inject as h, computed as C, provide as W, readonly as $e, toRef as H, unref as k, watch as ce, renderSlot as B, resolveComponent as b, openBlock as N, createBlock as U, withCtx as v, createVNode as R, normalizeProps as Te, guardReactiveProps as Fe, nextTick as Re, getCurrentInstance as pe, onBeforeUnmount as Se, createElementBlock as j, normalizeClass as Q, createSlots as Oe, mergeProps as V, createCommentVNode as X, Fragment as ke, createElementVNode as Pe, withModifiers as x, resolveDynamicComponent as De, normalizeStyle as Ne } from "vue";
|
|
2
|
+
import { m as Ke, n as q, J as E, I as Be, _ as A, aR as fe, h as ve, z as me, a5 as Le, x as ee, w as Me, bs as Ge, aO as Ae, bM as ze, L as Ue, Z as ge } from "./index-B6wY38lY.mjs";
|
|
3
|
+
import { c as P, E as Ye, O as He, w as ae } from "./el-popper-C13p_dqu.mjs";
|
|
4
|
+
import { E as Ve } from "./el-scrollbar-B8QteGV0.mjs";
|
|
5
|
+
import { c as Je, E as We, d as je, a as be, C as Ze, b as qe, e as Qe, f as Xe, g as xe, F as eo, L as oo } from "./dropdown2-D_RJXnOl.mjs";
|
|
6
|
+
import { f as no } from "./el-form-item-f-baJSfe.mjs";
|
|
7
|
+
import { c as we } from "./refs-COP_DuTD.mjs";
|
|
8
|
+
const to = Ke({
|
|
9
|
+
style: { type: q([String, Array, Object]) },
|
|
10
|
+
currentTabId: {
|
|
11
|
+
type: q(String)
|
|
12
|
+
},
|
|
13
|
+
defaultCurrentTabId: String,
|
|
14
|
+
loop: Boolean,
|
|
15
|
+
dir: {
|
|
16
|
+
type: String,
|
|
17
|
+
values: ["ltr", "rtl"],
|
|
18
|
+
default: "ltr"
|
|
19
|
+
},
|
|
20
|
+
orientation: {
|
|
21
|
+
type: q(String)
|
|
22
|
+
},
|
|
23
|
+
onBlur: Function,
|
|
24
|
+
onFocus: Function,
|
|
25
|
+
onMousedown: Function
|
|
26
|
+
}), {
|
|
27
|
+
ElCollection: ro,
|
|
28
|
+
ElCollectionItem: lo,
|
|
29
|
+
COLLECTION_INJECTION_KEY: oe,
|
|
30
|
+
COLLECTION_ITEM_INJECTION_KEY: so
|
|
31
|
+
} = Je("RovingFocusGroup"), ne = Symbol("elRovingFocusGroup"), Ie = Symbol("elRovingFocusGroupItem"), io = {
|
|
32
|
+
ArrowLeft: "prev",
|
|
33
|
+
ArrowUp: "prev",
|
|
34
|
+
ArrowRight: "next",
|
|
35
|
+
ArrowDown: "next",
|
|
36
|
+
PageUp: "first",
|
|
37
|
+
Home: "first",
|
|
38
|
+
PageDown: "last",
|
|
39
|
+
End: "last"
|
|
40
|
+
}, ao = (e, o) => {
|
|
41
|
+
if (o !== "rtl")
|
|
42
|
+
return e;
|
|
43
|
+
switch (e) {
|
|
44
|
+
case E.right:
|
|
45
|
+
return E.left;
|
|
46
|
+
case E.left:
|
|
47
|
+
return E.right;
|
|
48
|
+
default:
|
|
49
|
+
return e;
|
|
50
|
+
}
|
|
51
|
+
}, uo = (e, o, a) => {
|
|
52
|
+
const t = ao(e.key, a);
|
|
53
|
+
if (!(o === "vertical" && [E.left, E.right].includes(t)) && !(o === "horizontal" && [E.up, E.down].includes(t)))
|
|
54
|
+
return io[t];
|
|
55
|
+
}, co = (e, o) => e.map((a, t) => e[(t + o) % e.length]), te = (e) => {
|
|
56
|
+
const { activeElement: o } = document;
|
|
57
|
+
for (const a of e)
|
|
58
|
+
if (a === o || (a.focus(), o !== document.activeElement))
|
|
59
|
+
return;
|
|
60
|
+
}, de = "currentTabIdChange", ue = "rovingFocusGroup.entryFocus", po = { bubbles: !1, cancelable: !0 }, fo = G({
|
|
61
|
+
name: "ElRovingFocusGroupImpl",
|
|
62
|
+
inheritAttrs: !1,
|
|
63
|
+
props: to,
|
|
64
|
+
emits: [de, "entryFocus"],
|
|
65
|
+
setup(e, { emit: o }) {
|
|
66
|
+
var a;
|
|
67
|
+
const t = $((a = e.currentTabId || e.defaultCurrentTabId) != null ? a : null), c = $(!1), u = $(!1), s = $(null), { getItems: l } = h(oe, void 0), p = C(() => [
|
|
68
|
+
{
|
|
69
|
+
outline: "none"
|
|
70
|
+
},
|
|
71
|
+
e.style
|
|
72
|
+
]), m = (i) => {
|
|
73
|
+
o(de, i);
|
|
74
|
+
}, g = () => {
|
|
75
|
+
c.value = !0;
|
|
76
|
+
}, w = P((i) => {
|
|
77
|
+
var f;
|
|
78
|
+
(f = e.onMousedown) == null || f.call(e, i);
|
|
79
|
+
}, () => {
|
|
80
|
+
u.value = !0;
|
|
81
|
+
}), _ = P((i) => {
|
|
82
|
+
var f;
|
|
83
|
+
(f = e.onFocus) == null || f.call(e, i);
|
|
84
|
+
}, (i) => {
|
|
85
|
+
const f = !k(u), { target: K, currentTarget: S } = i;
|
|
86
|
+
if (K === S && f && !k(c)) {
|
|
87
|
+
const L = new Event(ue, po);
|
|
88
|
+
if (S == null || S.dispatchEvent(L), !L.defaultPrevented) {
|
|
89
|
+
const I = l().filter((F) => F.focusable), y = I.find((F) => F.active), T = I.find((F) => F.id === k(t)), M = [y, T, ...I].filter(Boolean).map((F) => F.ref);
|
|
90
|
+
te(M);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
u.value = !1;
|
|
94
|
+
}), n = P((i) => {
|
|
95
|
+
var f;
|
|
96
|
+
(f = e.onBlur) == null || f.call(e, i);
|
|
97
|
+
}, () => {
|
|
98
|
+
c.value = !1;
|
|
99
|
+
}), d = (...i) => {
|
|
100
|
+
o("entryFocus", ...i);
|
|
101
|
+
};
|
|
102
|
+
W(ne, {
|
|
103
|
+
currentTabbedId: $e(t),
|
|
104
|
+
loop: H(e, "loop"),
|
|
105
|
+
tabIndex: C(() => k(c) ? -1 : 0),
|
|
106
|
+
rovingFocusGroupRef: s,
|
|
107
|
+
rovingFocusGroupRootStyle: p,
|
|
108
|
+
orientation: H(e, "orientation"),
|
|
109
|
+
dir: H(e, "dir"),
|
|
110
|
+
onItemFocus: m,
|
|
111
|
+
onItemShiftTab: g,
|
|
112
|
+
onBlur: n,
|
|
113
|
+
onFocus: _,
|
|
114
|
+
onMousedown: w
|
|
115
|
+
}), ce(() => e.currentTabId, (i) => {
|
|
116
|
+
t.value = i ?? null;
|
|
117
|
+
}), Be(s, ue, d);
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
function vo(e, o, a, t, c, u) {
|
|
121
|
+
return B(e.$slots, "default");
|
|
122
|
+
}
|
|
123
|
+
var mo = /* @__PURE__ */ A(fo, [["render", vo], ["__file", "roving-focus-group-impl.vue"]]);
|
|
124
|
+
const go = G({
|
|
125
|
+
name: "ElRovingFocusGroup",
|
|
126
|
+
components: {
|
|
127
|
+
ElFocusGroupCollection: ro,
|
|
128
|
+
ElRovingFocusGroupImpl: mo
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
function bo(e, o, a, t, c, u) {
|
|
132
|
+
const s = b("el-roving-focus-group-impl"), l = b("el-focus-group-collection");
|
|
133
|
+
return N(), U(l, null, {
|
|
134
|
+
default: v(() => [
|
|
135
|
+
R(s, Te(Fe(e.$attrs)), {
|
|
136
|
+
default: v(() => [
|
|
137
|
+
B(e.$slots, "default")
|
|
138
|
+
]),
|
|
139
|
+
_: 3
|
|
140
|
+
}, 16)
|
|
141
|
+
]),
|
|
142
|
+
_: 3
|
|
143
|
+
});
|
|
144
|
+
}
|
|
145
|
+
var wo = /* @__PURE__ */ A(go, [["render", bo], ["__file", "roving-focus-group.vue"]]);
|
|
146
|
+
const Io = G({
|
|
147
|
+
components: {
|
|
148
|
+
ElRovingFocusCollectionItem: lo
|
|
149
|
+
},
|
|
150
|
+
props: {
|
|
151
|
+
focusable: {
|
|
152
|
+
type: Boolean,
|
|
153
|
+
default: !0
|
|
154
|
+
},
|
|
155
|
+
active: {
|
|
156
|
+
type: Boolean,
|
|
157
|
+
default: !1
|
|
158
|
+
}
|
|
159
|
+
},
|
|
160
|
+
emits: ["mousedown", "focus", "keydown"],
|
|
161
|
+
setup(e, { emit: o }) {
|
|
162
|
+
const { currentTabbedId: a, loop: t, onItemFocus: c, onItemShiftTab: u } = h(ne, void 0), { getItems: s } = h(oe, void 0), l = fe(), p = $(null), m = P((n) => {
|
|
163
|
+
o("mousedown", n);
|
|
164
|
+
}, (n) => {
|
|
165
|
+
e.focusable ? c(k(l)) : n.preventDefault();
|
|
166
|
+
}), g = P((n) => {
|
|
167
|
+
o("focus", n);
|
|
168
|
+
}, () => {
|
|
169
|
+
c(k(l));
|
|
170
|
+
}), w = P((n) => {
|
|
171
|
+
o("keydown", n);
|
|
172
|
+
}, (n) => {
|
|
173
|
+
const { key: d, shiftKey: i, target: f, currentTarget: K } = n;
|
|
174
|
+
if (d === E.tab && i) {
|
|
175
|
+
u();
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
if (f !== K)
|
|
179
|
+
return;
|
|
180
|
+
const S = uo(n);
|
|
181
|
+
if (S) {
|
|
182
|
+
n.preventDefault();
|
|
183
|
+
let I = s().filter((y) => y.focusable).map((y) => y.ref);
|
|
184
|
+
switch (S) {
|
|
185
|
+
case "last": {
|
|
186
|
+
I.reverse();
|
|
187
|
+
break;
|
|
188
|
+
}
|
|
189
|
+
case "prev":
|
|
190
|
+
case "next": {
|
|
191
|
+
S === "prev" && I.reverse();
|
|
192
|
+
const y = I.indexOf(K);
|
|
193
|
+
I = t.value ? co(I, y + 1) : I.slice(y + 1);
|
|
194
|
+
break;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
Re(() => {
|
|
198
|
+
te(I);
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
}), _ = C(() => a.value === k(l));
|
|
202
|
+
return W(Ie, {
|
|
203
|
+
rovingFocusGroupItemRef: p,
|
|
204
|
+
tabIndex: C(() => k(_) ? 0 : -1),
|
|
205
|
+
handleMousedown: m,
|
|
206
|
+
handleFocus: g,
|
|
207
|
+
handleKeydown: w
|
|
208
|
+
}), {
|
|
209
|
+
id: l,
|
|
210
|
+
handleKeydown: w,
|
|
211
|
+
handleFocus: g,
|
|
212
|
+
handleMousedown: m
|
|
213
|
+
};
|
|
214
|
+
}
|
|
215
|
+
});
|
|
216
|
+
function Eo(e, o, a, t, c, u) {
|
|
217
|
+
const s = b("el-roving-focus-collection-item");
|
|
218
|
+
return N(), U(s, {
|
|
219
|
+
id: e.id,
|
|
220
|
+
focusable: e.focusable,
|
|
221
|
+
active: e.active
|
|
222
|
+
}, {
|
|
223
|
+
default: v(() => [
|
|
224
|
+
B(e.$slots, "default")
|
|
225
|
+
]),
|
|
226
|
+
_: 3
|
|
227
|
+
}, 8, ["id", "focusable", "active"]);
|
|
228
|
+
}
|
|
229
|
+
var _o = /* @__PURE__ */ A(Io, [["render", Eo], ["__file", "roving-focus-item.vue"]]);
|
|
230
|
+
const Z = Symbol("elDropdown"), { ButtonGroup: ho } = ve, Co = G({
|
|
231
|
+
name: "ElDropdown",
|
|
232
|
+
components: {
|
|
233
|
+
ElButton: ve,
|
|
234
|
+
ElButtonGroup: ho,
|
|
235
|
+
ElScrollbar: Ve,
|
|
236
|
+
ElDropdownCollection: We,
|
|
237
|
+
ElTooltip: Ye,
|
|
238
|
+
ElRovingFocusGroup: wo,
|
|
239
|
+
ElOnlyChild: He,
|
|
240
|
+
ElIcon: me,
|
|
241
|
+
ArrowDown: Le
|
|
242
|
+
},
|
|
243
|
+
props: je,
|
|
244
|
+
emits: ["visible-change", "click", "command"],
|
|
245
|
+
setup(e, { emit: o }) {
|
|
246
|
+
const a = pe(), t = ee("dropdown"), { t: c } = Me(), u = $(), s = $(), l = $(null), p = $(null), m = $(null), g = $(null), w = $(!1), _ = [E.enter, E.space, E.down], n = C(() => ({
|
|
247
|
+
maxHeight: Ge(e.maxHeight)
|
|
248
|
+
})), d = C(() => [t.m(y.value)]), i = C(() => no(e.trigger)), f = fe().value, K = C(() => e.id || f);
|
|
249
|
+
ce([u, i], ([r, O], [z]) => {
|
|
250
|
+
var le, se, ie;
|
|
251
|
+
(le = z == null ? void 0 : z.$el) != null && le.removeEventListener && z.$el.removeEventListener("pointerenter", D), (se = r == null ? void 0 : r.$el) != null && se.removeEventListener && r.$el.removeEventListener("pointerenter", D), (ie = r == null ? void 0 : r.$el) != null && ie.addEventListener && O.includes("hover") && r.$el.addEventListener("pointerenter", D);
|
|
252
|
+
}, { immediate: !0 }), Se(() => {
|
|
253
|
+
var r, O;
|
|
254
|
+
(O = (r = u.value) == null ? void 0 : r.$el) != null && O.removeEventListener && u.value.$el.removeEventListener("pointerenter", D);
|
|
255
|
+
});
|
|
256
|
+
function S() {
|
|
257
|
+
L();
|
|
258
|
+
}
|
|
259
|
+
function L() {
|
|
260
|
+
var r;
|
|
261
|
+
(r = l.value) == null || r.onClose();
|
|
262
|
+
}
|
|
263
|
+
function I() {
|
|
264
|
+
var r;
|
|
265
|
+
(r = l.value) == null || r.onOpen();
|
|
266
|
+
}
|
|
267
|
+
const y = Ae();
|
|
268
|
+
function T(...r) {
|
|
269
|
+
o("command", ...r);
|
|
270
|
+
}
|
|
271
|
+
function D() {
|
|
272
|
+
var r, O;
|
|
273
|
+
(O = (r = u.value) == null ? void 0 : r.$el) == null || O.focus();
|
|
274
|
+
}
|
|
275
|
+
function M() {
|
|
276
|
+
}
|
|
277
|
+
function F() {
|
|
278
|
+
const r = k(p);
|
|
279
|
+
i.value.includes("hover") && (r == null || r.focus()), g.value = null;
|
|
280
|
+
}
|
|
281
|
+
function re(r) {
|
|
282
|
+
g.value = r;
|
|
283
|
+
}
|
|
284
|
+
function J(r) {
|
|
285
|
+
w.value || (r.preventDefault(), r.stopImmediatePropagation());
|
|
286
|
+
}
|
|
287
|
+
function Y() {
|
|
288
|
+
o("visible-change", !0);
|
|
289
|
+
}
|
|
290
|
+
function Ce(r) {
|
|
291
|
+
(r == null ? void 0 : r.type) === "keydown" && p.value.focus();
|
|
292
|
+
}
|
|
293
|
+
function ye() {
|
|
294
|
+
o("visible-change", !1);
|
|
295
|
+
}
|
|
296
|
+
return W(Z, {
|
|
297
|
+
contentRef: p,
|
|
298
|
+
role: C(() => e.role),
|
|
299
|
+
triggerId: K,
|
|
300
|
+
isUsingKeyboard: w,
|
|
301
|
+
onItemEnter: M,
|
|
302
|
+
onItemLeave: F
|
|
303
|
+
}), W("elDropdown", {
|
|
304
|
+
instance: a,
|
|
305
|
+
dropdownSize: y,
|
|
306
|
+
handleClick: S,
|
|
307
|
+
commandHandler: T,
|
|
308
|
+
trigger: H(e, "trigger"),
|
|
309
|
+
hideOnClick: H(e, "hideOnClick")
|
|
310
|
+
}), {
|
|
311
|
+
t: c,
|
|
312
|
+
ns: t,
|
|
313
|
+
scrollbar: m,
|
|
314
|
+
wrapStyle: n,
|
|
315
|
+
dropdownTriggerKls: d,
|
|
316
|
+
dropdownSize: y,
|
|
317
|
+
triggerId: K,
|
|
318
|
+
triggerKeys: _,
|
|
319
|
+
currentTabId: g,
|
|
320
|
+
handleCurrentTabIdChange: re,
|
|
321
|
+
handlerMainButtonClick: (r) => {
|
|
322
|
+
o("click", r);
|
|
323
|
+
},
|
|
324
|
+
handleEntryFocus: J,
|
|
325
|
+
handleClose: L,
|
|
326
|
+
handleOpen: I,
|
|
327
|
+
handleBeforeShowTooltip: Y,
|
|
328
|
+
handleShowTooltip: Ce,
|
|
329
|
+
handleBeforeHideTooltip: ye,
|
|
330
|
+
onFocusAfterTrapped: (r) => {
|
|
331
|
+
var O, z;
|
|
332
|
+
r.preventDefault(), (z = (O = p.value) == null ? void 0 : O.focus) == null || z.call(O, {
|
|
333
|
+
preventScroll: !0
|
|
334
|
+
});
|
|
335
|
+
},
|
|
336
|
+
popperRef: l,
|
|
337
|
+
contentRef: p,
|
|
338
|
+
triggeringElementRef: u,
|
|
339
|
+
referenceElementRef: s
|
|
340
|
+
};
|
|
341
|
+
}
|
|
342
|
+
});
|
|
343
|
+
function yo(e, o, a, t, c, u) {
|
|
344
|
+
var s;
|
|
345
|
+
const l = b("el-dropdown-collection"), p = b("el-roving-focus-group"), m = b("el-scrollbar"), g = b("el-only-child"), w = b("el-tooltip"), _ = b("el-button"), n = b("arrow-down"), d = b("el-icon"), i = b("el-button-group");
|
|
346
|
+
return N(), j("div", {
|
|
347
|
+
class: Q([e.ns.b(), e.ns.is("disabled", e.disabled)])
|
|
348
|
+
}, [
|
|
349
|
+
R(w, {
|
|
350
|
+
ref: "popperRef",
|
|
351
|
+
role: e.role,
|
|
352
|
+
effect: e.effect,
|
|
353
|
+
"fallback-placements": ["bottom", "top"],
|
|
354
|
+
"popper-options": e.popperOptions,
|
|
355
|
+
"gpu-acceleration": !1,
|
|
356
|
+
"hide-after": e.trigger === "hover" ? e.hideTimeout : 0,
|
|
357
|
+
"manual-mode": !0,
|
|
358
|
+
placement: e.placement,
|
|
359
|
+
"popper-class": [e.ns.e("popper"), e.popperClass],
|
|
360
|
+
"reference-element": (s = e.referenceElementRef) == null ? void 0 : s.$el,
|
|
361
|
+
trigger: e.trigger,
|
|
362
|
+
"trigger-keys": e.triggerKeys,
|
|
363
|
+
"trigger-target-el": e.contentRef,
|
|
364
|
+
"show-after": e.trigger === "hover" ? e.showTimeout : 0,
|
|
365
|
+
"stop-popper-mouse-event": !1,
|
|
366
|
+
"virtual-ref": e.triggeringElementRef,
|
|
367
|
+
"virtual-triggering": e.splitButton,
|
|
368
|
+
disabled: e.disabled,
|
|
369
|
+
transition: `${e.ns.namespace.value}-zoom-in-top`,
|
|
370
|
+
teleported: e.teleported,
|
|
371
|
+
pure: "",
|
|
372
|
+
persistent: "",
|
|
373
|
+
onBeforeShow: e.handleBeforeShowTooltip,
|
|
374
|
+
onShow: e.handleShowTooltip,
|
|
375
|
+
onBeforeHide: e.handleBeforeHideTooltip
|
|
376
|
+
}, Oe({
|
|
377
|
+
content: v(() => [
|
|
378
|
+
R(m, {
|
|
379
|
+
ref: "scrollbar",
|
|
380
|
+
"wrap-style": e.wrapStyle,
|
|
381
|
+
tag: "div",
|
|
382
|
+
"view-class": e.ns.e("list")
|
|
383
|
+
}, {
|
|
384
|
+
default: v(() => [
|
|
385
|
+
R(p, {
|
|
386
|
+
loop: e.loop,
|
|
387
|
+
"current-tab-id": e.currentTabId,
|
|
388
|
+
orientation: "horizontal",
|
|
389
|
+
onCurrentTabIdChange: e.handleCurrentTabIdChange,
|
|
390
|
+
onEntryFocus: e.handleEntryFocus
|
|
391
|
+
}, {
|
|
392
|
+
default: v(() => [
|
|
393
|
+
R(l, null, {
|
|
394
|
+
default: v(() => [
|
|
395
|
+
B(e.$slots, "dropdown")
|
|
396
|
+
]),
|
|
397
|
+
_: 3
|
|
398
|
+
})
|
|
399
|
+
]),
|
|
400
|
+
_: 3
|
|
401
|
+
}, 8, ["loop", "current-tab-id", "onCurrentTabIdChange", "onEntryFocus"])
|
|
402
|
+
]),
|
|
403
|
+
_: 3
|
|
404
|
+
}, 8, ["wrap-style", "view-class"])
|
|
405
|
+
]),
|
|
406
|
+
_: 2
|
|
407
|
+
}, [
|
|
408
|
+
e.splitButton ? void 0 : {
|
|
409
|
+
name: "default",
|
|
410
|
+
fn: v(() => [
|
|
411
|
+
R(g, {
|
|
412
|
+
id: e.triggerId,
|
|
413
|
+
ref: "triggeringElementRef",
|
|
414
|
+
role: "button",
|
|
415
|
+
tabindex: e.tabindex
|
|
416
|
+
}, {
|
|
417
|
+
default: v(() => [
|
|
418
|
+
B(e.$slots, "default")
|
|
419
|
+
]),
|
|
420
|
+
_: 3
|
|
421
|
+
}, 8, ["id", "tabindex"])
|
|
422
|
+
])
|
|
423
|
+
}
|
|
424
|
+
]), 1032, ["role", "effect", "popper-options", "hide-after", "placement", "popper-class", "reference-element", "trigger", "trigger-keys", "trigger-target-el", "show-after", "virtual-ref", "virtual-triggering", "disabled", "transition", "teleported", "onBeforeShow", "onShow", "onBeforeHide"]),
|
|
425
|
+
e.splitButton ? (N(), U(i, { key: 0 }, {
|
|
426
|
+
default: v(() => [
|
|
427
|
+
R(_, V({ ref: "referenceElementRef" }, e.buttonProps, {
|
|
428
|
+
size: e.dropdownSize,
|
|
429
|
+
type: e.type,
|
|
430
|
+
disabled: e.disabled,
|
|
431
|
+
tabindex: e.tabindex,
|
|
432
|
+
onClick: e.handlerMainButtonClick
|
|
433
|
+
}), {
|
|
434
|
+
default: v(() => [
|
|
435
|
+
B(e.$slots, "default")
|
|
436
|
+
]),
|
|
437
|
+
_: 3
|
|
438
|
+
}, 16, ["size", "type", "disabled", "tabindex", "onClick"]),
|
|
439
|
+
R(_, V({
|
|
440
|
+
id: e.triggerId,
|
|
441
|
+
ref: "triggeringElementRef"
|
|
442
|
+
}, e.buttonProps, {
|
|
443
|
+
role: "button",
|
|
444
|
+
size: e.dropdownSize,
|
|
445
|
+
type: e.type,
|
|
446
|
+
class: e.ns.e("caret-button"),
|
|
447
|
+
disabled: e.disabled,
|
|
448
|
+
tabindex: e.tabindex,
|
|
449
|
+
"aria-label": e.t("el.dropdown.toggleDropdown")
|
|
450
|
+
}), {
|
|
451
|
+
default: v(() => [
|
|
452
|
+
R(d, {
|
|
453
|
+
class: Q(e.ns.e("icon"))
|
|
454
|
+
}, {
|
|
455
|
+
default: v(() => [
|
|
456
|
+
R(n)
|
|
457
|
+
]),
|
|
458
|
+
_: 1
|
|
459
|
+
}, 8, ["class"])
|
|
460
|
+
]),
|
|
461
|
+
_: 1
|
|
462
|
+
}, 16, ["id", "size", "type", "class", "disabled", "tabindex", "aria-label"])
|
|
463
|
+
]),
|
|
464
|
+
_: 3
|
|
465
|
+
})) : X("v-if", !0)
|
|
466
|
+
], 2);
|
|
467
|
+
}
|
|
468
|
+
var $o = /* @__PURE__ */ A(Co, [["render", yo], ["__file", "dropdown.vue"]]);
|
|
469
|
+
const To = G({
|
|
470
|
+
name: "DropdownItemImpl",
|
|
471
|
+
components: {
|
|
472
|
+
ElIcon: me
|
|
473
|
+
},
|
|
474
|
+
props: be,
|
|
475
|
+
emits: ["pointermove", "pointerleave", "click", "clickimpl"],
|
|
476
|
+
setup(e, { emit: o }) {
|
|
477
|
+
const a = ee("dropdown"), { role: t } = h(Z, void 0), { collectionItemRef: c } = h(Ze, void 0), { collectionItemRef: u } = h(so, void 0), {
|
|
478
|
+
rovingFocusGroupItemRef: s,
|
|
479
|
+
tabIndex: l,
|
|
480
|
+
handleFocus: p,
|
|
481
|
+
handleKeydown: m,
|
|
482
|
+
handleMousedown: g
|
|
483
|
+
} = h(Ie, void 0), w = we(c, u, s), _ = C(() => t.value === "menu" ? "menuitem" : t.value === "navigation" ? "link" : "button"), n = P((d) => {
|
|
484
|
+
const { code: i } = d;
|
|
485
|
+
if (i === E.enter || i === E.space)
|
|
486
|
+
return d.preventDefault(), d.stopImmediatePropagation(), o("clickimpl", d), !0;
|
|
487
|
+
}, m);
|
|
488
|
+
return {
|
|
489
|
+
ns: a,
|
|
490
|
+
itemRef: w,
|
|
491
|
+
dataset: {
|
|
492
|
+
[qe]: ""
|
|
493
|
+
},
|
|
494
|
+
role: _,
|
|
495
|
+
tabIndex: l,
|
|
496
|
+
handleFocus: p,
|
|
497
|
+
handleKeydown: n,
|
|
498
|
+
handleMousedown: g
|
|
499
|
+
};
|
|
500
|
+
}
|
|
501
|
+
}), Fo = ["aria-disabled", "tabindex", "role"];
|
|
502
|
+
function Ro(e, o, a, t, c, u) {
|
|
503
|
+
const s = b("el-icon");
|
|
504
|
+
return N(), j(ke, null, [
|
|
505
|
+
e.divided ? (N(), j("li", V({
|
|
506
|
+
key: 0,
|
|
507
|
+
role: "separator",
|
|
508
|
+
class: e.ns.bem("menu", "item", "divided")
|
|
509
|
+
}, e.$attrs), null, 16)) : X("v-if", !0),
|
|
510
|
+
Pe("li", V({ ref: e.itemRef }, { ...e.dataset, ...e.$attrs }, {
|
|
511
|
+
"aria-disabled": e.disabled,
|
|
512
|
+
class: [e.ns.be("menu", "item"), e.ns.is("disabled", e.disabled)],
|
|
513
|
+
tabindex: e.tabIndex,
|
|
514
|
+
role: e.role,
|
|
515
|
+
onClick: o[0] || (o[0] = (l) => e.$emit("clickimpl", l)),
|
|
516
|
+
onFocus: o[1] || (o[1] = (...l) => e.handleFocus && e.handleFocus(...l)),
|
|
517
|
+
onKeydown: o[2] || (o[2] = x((...l) => e.handleKeydown && e.handleKeydown(...l), ["self"])),
|
|
518
|
+
onMousedown: o[3] || (o[3] = (...l) => e.handleMousedown && e.handleMousedown(...l)),
|
|
519
|
+
onPointermove: o[4] || (o[4] = (l) => e.$emit("pointermove", l)),
|
|
520
|
+
onPointerleave: o[5] || (o[5] = (l) => e.$emit("pointerleave", l))
|
|
521
|
+
}), [
|
|
522
|
+
e.icon ? (N(), U(s, { key: 0 }, {
|
|
523
|
+
default: v(() => [
|
|
524
|
+
(N(), U(De(e.icon)))
|
|
525
|
+
]),
|
|
526
|
+
_: 1
|
|
527
|
+
})) : X("v-if", !0),
|
|
528
|
+
B(e.$slots, "default")
|
|
529
|
+
], 16, Fo)
|
|
530
|
+
], 64);
|
|
531
|
+
}
|
|
532
|
+
var So = /* @__PURE__ */ A(To, [["render", Ro], ["__file", "dropdown-item-impl.vue"]]);
|
|
533
|
+
const Ee = () => {
|
|
534
|
+
const e = h("elDropdown", {}), o = C(() => e == null ? void 0 : e.dropdownSize);
|
|
535
|
+
return {
|
|
536
|
+
elDropdown: e,
|
|
537
|
+
_elDropdownSize: o
|
|
538
|
+
};
|
|
539
|
+
}, Oo = G({
|
|
540
|
+
name: "ElDropdownItem",
|
|
541
|
+
components: {
|
|
542
|
+
ElDropdownCollectionItem: Qe,
|
|
543
|
+
ElRovingFocusItem: _o,
|
|
544
|
+
ElDropdownItemImpl: So
|
|
545
|
+
},
|
|
546
|
+
inheritAttrs: !1,
|
|
547
|
+
props: be,
|
|
548
|
+
emits: ["pointermove", "pointerleave", "click"],
|
|
549
|
+
setup(e, { emit: o, attrs: a }) {
|
|
550
|
+
const { elDropdown: t } = Ee(), c = pe(), u = $(null), s = C(() => {
|
|
551
|
+
var n, d;
|
|
552
|
+
return (d = (n = k(u)) == null ? void 0 : n.textContent) != null ? d : "";
|
|
553
|
+
}), { onItemEnter: l, onItemLeave: p } = h(Z, void 0), m = P((n) => (o("pointermove", n), n.defaultPrevented), ae((n) => {
|
|
554
|
+
if (e.disabled) {
|
|
555
|
+
p(n);
|
|
556
|
+
return;
|
|
557
|
+
}
|
|
558
|
+
const d = n.currentTarget;
|
|
559
|
+
d === document.activeElement || d.contains(document.activeElement) || (l(n), n.defaultPrevented || d == null || d.focus());
|
|
560
|
+
})), g = P((n) => (o("pointerleave", n), n.defaultPrevented), ae((n) => {
|
|
561
|
+
p(n);
|
|
562
|
+
})), w = P((n) => {
|
|
563
|
+
if (!e.disabled)
|
|
564
|
+
return o("click", n), n.type !== "keydown" && n.defaultPrevented;
|
|
565
|
+
}, (n) => {
|
|
566
|
+
var d, i, f;
|
|
567
|
+
if (e.disabled) {
|
|
568
|
+
n.stopImmediatePropagation();
|
|
569
|
+
return;
|
|
570
|
+
}
|
|
571
|
+
(d = t == null ? void 0 : t.hideOnClick) != null && d.value && ((i = t.handleClick) == null || i.call(t)), (f = t.commandHandler) == null || f.call(t, e.command, c, n);
|
|
572
|
+
}), _ = C(() => ({ ...e, ...a }));
|
|
573
|
+
return {
|
|
574
|
+
handleClick: w,
|
|
575
|
+
handlePointerMove: m,
|
|
576
|
+
handlePointerLeave: g,
|
|
577
|
+
textContent: s,
|
|
578
|
+
propsAndAttrs: _
|
|
579
|
+
};
|
|
580
|
+
}
|
|
581
|
+
});
|
|
582
|
+
function ko(e, o, a, t, c, u) {
|
|
583
|
+
var s;
|
|
584
|
+
const l = b("el-dropdown-item-impl"), p = b("el-roving-focus-item"), m = b("el-dropdown-collection-item");
|
|
585
|
+
return N(), U(m, {
|
|
586
|
+
disabled: e.disabled,
|
|
587
|
+
"text-value": (s = e.textValue) != null ? s : e.textContent
|
|
588
|
+
}, {
|
|
589
|
+
default: v(() => [
|
|
590
|
+
R(p, {
|
|
591
|
+
focusable: !e.disabled
|
|
592
|
+
}, {
|
|
593
|
+
default: v(() => [
|
|
594
|
+
R(l, V(e.propsAndAttrs, {
|
|
595
|
+
onPointerleave: e.handlePointerLeave,
|
|
596
|
+
onPointermove: e.handlePointerMove,
|
|
597
|
+
onClickimpl: e.handleClick
|
|
598
|
+
}), {
|
|
599
|
+
default: v(() => [
|
|
600
|
+
B(e.$slots, "default")
|
|
601
|
+
]),
|
|
602
|
+
_: 3
|
|
603
|
+
}, 16, ["onPointerleave", "onPointermove", "onClickimpl"])
|
|
604
|
+
]),
|
|
605
|
+
_: 3
|
|
606
|
+
}, 8, ["focusable"])
|
|
607
|
+
]),
|
|
608
|
+
_: 3
|
|
609
|
+
}, 8, ["disabled", "text-value"]);
|
|
610
|
+
}
|
|
611
|
+
var _e = /* @__PURE__ */ A(Oo, [["render", ko], ["__file", "dropdown-item.vue"]]);
|
|
612
|
+
const Po = G({
|
|
613
|
+
name: "ElDropdownMenu",
|
|
614
|
+
props: Xe,
|
|
615
|
+
setup(e) {
|
|
616
|
+
const o = ee("dropdown"), { _elDropdownSize: a } = Ee(), t = a.value, { focusTrapRef: c, onKeydown: u } = h(ze, void 0), { contentRef: s, role: l, triggerId: p } = h(Z, void 0), { collectionRef: m, getItems: g } = h(xe, void 0), {
|
|
617
|
+
rovingFocusGroupRef: w,
|
|
618
|
+
rovingFocusGroupRootStyle: _,
|
|
619
|
+
tabIndex: n,
|
|
620
|
+
onBlur: d,
|
|
621
|
+
onFocus: i,
|
|
622
|
+
onMousedown: f
|
|
623
|
+
} = h(ne, void 0), { collectionRef: K } = h(oe, void 0), S = C(() => [o.b("menu"), o.bm("menu", t == null ? void 0 : t.value)]), L = we(s, m, c, w, K), I = P((T) => {
|
|
624
|
+
var D;
|
|
625
|
+
(D = e.onKeydown) == null || D.call(e, T);
|
|
626
|
+
}, (T) => {
|
|
627
|
+
const { currentTarget: D, code: M, target: F } = T;
|
|
628
|
+
if (D.contains(F), E.tab === M && T.stopImmediatePropagation(), T.preventDefault(), F !== k(s) || !eo.includes(M))
|
|
629
|
+
return;
|
|
630
|
+
const J = g().filter((Y) => !Y.disabled).map((Y) => Y.ref);
|
|
631
|
+
oo.includes(M) && J.reverse(), te(J);
|
|
632
|
+
});
|
|
633
|
+
return {
|
|
634
|
+
size: t,
|
|
635
|
+
rovingFocusGroupRootStyle: _,
|
|
636
|
+
tabIndex: n,
|
|
637
|
+
dropdownKls: S,
|
|
638
|
+
role: l,
|
|
639
|
+
triggerId: p,
|
|
640
|
+
dropdownListWrapperRef: L,
|
|
641
|
+
handleKeydown: (T) => {
|
|
642
|
+
I(T), u(T);
|
|
643
|
+
},
|
|
644
|
+
onBlur: d,
|
|
645
|
+
onFocus: i,
|
|
646
|
+
onMousedown: f
|
|
647
|
+
};
|
|
648
|
+
}
|
|
649
|
+
}), Do = ["role", "aria-labelledby"];
|
|
650
|
+
function No(e, o, a, t, c, u) {
|
|
651
|
+
return N(), j("ul", {
|
|
652
|
+
ref: e.dropdownListWrapperRef,
|
|
653
|
+
class: Q(e.dropdownKls),
|
|
654
|
+
style: Ne(e.rovingFocusGroupRootStyle),
|
|
655
|
+
tabindex: -1,
|
|
656
|
+
role: e.role,
|
|
657
|
+
"aria-labelledby": e.triggerId,
|
|
658
|
+
onBlur: o[0] || (o[0] = (...s) => e.onBlur && e.onBlur(...s)),
|
|
659
|
+
onFocus: o[1] || (o[1] = (...s) => e.onFocus && e.onFocus(...s)),
|
|
660
|
+
onKeydown: o[2] || (o[2] = x((...s) => e.handleKeydown && e.handleKeydown(...s), ["self"])),
|
|
661
|
+
onMousedown: o[3] || (o[3] = x((...s) => e.onMousedown && e.onMousedown(...s), ["self"]))
|
|
662
|
+
}, [
|
|
663
|
+
B(e.$slots, "default")
|
|
664
|
+
], 46, Do);
|
|
665
|
+
}
|
|
666
|
+
var he = /* @__PURE__ */ A(Po, [["render", No], ["__file", "dropdown-menu.vue"]]);
|
|
667
|
+
const Ho = Ue($o, {
|
|
668
|
+
DropdownItem: _e,
|
|
669
|
+
DropdownMenu: he
|
|
670
|
+
}), Vo = ge(_e), Jo = ge(he);
|
|
671
|
+
export {
|
|
672
|
+
Vo as E,
|
|
673
|
+
Jo as a,
|
|
674
|
+
Ho as b
|
|
675
|
+
};
|