@imengyu/vue3-context-menu 1.4.5 → 1.4.6

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.
@@ -254,7 +254,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
254
254
  clickHandler: v,
255
255
  clickClose: S,
256
256
  clickableWhenHasChildren: i,
257
- disabled: m,
257
+ disabled: p,
258
258
  hidden: b,
259
259
  label: n,
260
260
  icon: x,
@@ -269,7 +269,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
269
269
  hideSubMenu: () => {
270
270
  y.closeOtherSubMenu();
271
271
  },
272
- isDisabledOrHidden: () => m.value || b.value,
272
+ isDisabledOrHidden: () => p.value || b.value,
273
273
  getElement: () => a.value,
274
274
  focus: () => o.value = !0,
275
275
  blur: () => o.value = !1,
@@ -277,7 +277,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
277
277
  };
278
278
  Y("menuItemInstance", W), ge(() => {
279
279
  y.isMenuItemDataCollectedFlag() ? me(() => {
280
- let p = 0;
280
+ let m = 0;
281
281
  const B = y.getElement();
282
282
  if (B) {
283
283
  let V = 0;
@@ -285,41 +285,41 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
285
285
  const te = B.children[X];
286
286
  if (te.getAttribute("data-type") === "ContextMenuItem") {
287
287
  if (te === a.value) {
288
- p = V;
288
+ m = V;
289
289
  break;
290
290
  }
291
291
  V++;
292
292
  }
293
293
  }
294
294
  }
295
- y.addChildMenuItem(W, p);
295
+ y.addChildMenuItem(W, m);
296
296
  }) : y.addChildMenuItem(W);
297
297
  }), We(() => {
298
298
  y.removeChildMenuItem(W);
299
299
  });
300
- function D(p) {
301
- if (!m.value) {
302
- if (p) {
303
- const B = p.target;
300
+ function D(m) {
301
+ if (!p.value) {
302
+ if (m) {
303
+ const B = m.target;
304
304
  if (B.classList.contains("mx-context-no-clickable") || g.value.ignoreClickClassName && B.classList.contains(g.value.ignoreClickClassName))
305
305
  return;
306
306
  if (g.value.clickCloseClassName && B.classList.contains(g.value.clickCloseClassName)) {
307
- p.stopPropagation(), c(r.rawMenuItem);
307
+ m.stopPropagation(), c(r.rawMenuItem);
308
308
  return;
309
309
  }
310
310
  }
311
- L.value ? i.value ? (typeof v.value == "function" && v.value(p), f("click", p)) : M.value || z() : (typeof v.value == "function" && v.value(p), f("click", p), S.value && c(r.rawMenuItem));
311
+ L.value ? i.value ? (typeof v.value == "function" && v.value(m), f("click", m)) : M.value || z() : (typeof v.value == "function" && v.value(m), f("click", m), S.value && c(r.rawMenuItem));
312
312
  }
313
313
  }
314
- function z(p) {
315
- o.value = !1, y.checkCloseOtherSubMenuTimeOut() || y.closeOtherSubMenu(), m.value || (y.markActiveMenuItem(W), L.value && (p || y.markThisOpenedByKeyBoard(), y.addOpenedSubMenu(ee), M.value = !0, me(() => f("subMenuOpen", W))));
314
+ function z(m) {
315
+ o.value = !1, y.checkCloseOtherSubMenuTimeOut() || y.closeOtherSubMenu(), p.value || (y.markActiveMenuItem(W), L.value && (m || y.markThisOpenedByKeyBoard(), y.addOpenedSubMenu(ee), M.value = !0, me(() => f("subMenuOpen", W))));
316
316
  }
317
317
  function ee() {
318
318
  o.value = !1, M.value = !1, f("subMenuClose", W);
319
319
  }
320
320
  function H() {
321
321
  return {
322
- disabled: m.value,
322
+ disabled: p.value,
323
323
  label: n.value,
324
324
  icon: x.value,
325
325
  iconFontClass: $.value,
@@ -335,7 +335,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
335
335
  closeMenu: c
336
336
  };
337
337
  }
338
- return t(W), (p, B) => l(b) ? A("", !0) : (d(), P("div", {
338
+ return t(W), (m, B) => l(b) ? A("", !0) : (d(), P("div", {
339
339
  key: 0,
340
340
  class: "mx-context-menu-item-wrapper",
341
341
  ref_key: "menuItemRef",
@@ -353,7 +353,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
353
353
  key: 2,
354
354
  class: Z([
355
355
  "mx-context-menu-item",
356
- l(m) ? "disabled" : "",
356
+ l(p) ? "disabled" : "",
357
357
  o.value ? "keyboard-focus" : "",
358
358
  e.customClass ? " " + e.customClass : "",
359
359
  M.value ? "open" : ""
@@ -361,7 +361,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
361
361
  onClick: D,
362
362
  onMouseenter: z
363
363
  }, [
364
- F(p.$slots, "default", {}, () => [
364
+ F(m.$slots, "default", {}, () => [
365
365
  j("div", bt, [
366
366
  j("div", {
367
367
  class: Z([
@@ -369,7 +369,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
369
369
  e.preserveIconWidth ? "preserve-width" : ""
370
370
  ])
371
371
  }, [
372
- F(p.$slots, "icon", {}, () => [
372
+ F(m.$slots, "icon", {}, () => [
373
373
  l(C)("itemIconRender") ? (d(), O(l(K), {
374
374
  key: 0,
375
375
  vnode: () => l(R)("itemIconRender", H())
@@ -387,7 +387,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
387
387
  class: Z(l(x) + " icon " + l($) + " " + l(g).iconFontClass)
388
388
  }, null, 2)) : A("", !0)
389
389
  ]),
390
- e.checked ? F(p.$slots, "check", { key: 0 }, () => [
390
+ e.checked ? F(m.$slots, "check", { key: 0 }, () => [
391
391
  l(C)("itemCheckRender") ? (d(), O(l(K), {
392
392
  key: 0,
393
393
  vnode: () => l(R)("itemCheckRender", H())
@@ -395,7 +395,7 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
395
395
  le(ft)
396
396
  ]) : A("", !0)
397
397
  ], 2),
398
- F(p.$slots, "label", {}, () => [
398
+ F(m.$slots, "label", {}, () => [
399
399
  l(C)("itemLabelRender") ? (d(), O(l(K), {
400
400
  key: 0,
401
401
  vnode: () => l(R)("itemLabelRender", H())
@@ -407,14 +407,14 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
407
407
  ])
408
408
  ]),
409
409
  j("div", yt, [
410
- l(E) ? F(p.$slots, "shortcut", { key: 0 }, () => [
410
+ l(E) || m.$slots.shortcut ? F(m.$slots, "shortcut", { key: 0 }, () => [
411
411
  l(C)("itemShortcutRender") ? (d(), O(l(K), {
412
412
  key: 0,
413
413
  vnode: () => l(R)("itemShortcutRender", H())
414
414
  }, null, 8, ["vnode"])) : A("", !0),
415
415
  j("span", St, ke(l(E)), 1)
416
416
  ]) : A("", !0),
417
- l(w) ? F(p.$slots, "rightArrow", { key: 1 }, () => [
417
+ l(w) ? F(m.$slots, "rightArrow", { key: 1 }, () => [
418
418
  l(C)("itemRightArrowRender") ? (d(), O(l(K), {
419
419
  key: 0,
420
420
  vnode: () => l(R)("itemRightArrowRender", H())
@@ -426,10 +426,10 @@ const Ke = /* @__PURE__ */ fe(vt, [["render", gt]]), bt = { class: "mx-item-row"
426
426
  ], 34)),
427
427
  l(g).menuTransitionProps ? (d(), O(Ee, Ge(xe({ key: 3 }, l(g).menuTransitionProps)), {
428
428
  default: ce(() => [
429
- M.value ? F(p.$slots, "submenu", { key: 0 }) : A("", !0)
429
+ M.value ? F(m.$slots, "submenu", { key: 0 }) : A("", !0)
430
430
  ]),
431
431
  _: 3
432
- }, 16)) : M.value ? F(p.$slots, "submenu", { key: 4 }) : A("", !0)
432
+ }, 16)) : M.value ? F(m.$slots, "submenu", { key: 4 }) : A("", !0)
433
433
  ], 512));
434
434
  }
435
435
  }), xt = Q({
@@ -501,7 +501,7 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
501
501
  }
502
502
  },
503
503
  setup(e) {
504
- const t = _("menuContext"), u = _("globalOptions"), r = _("globalHasSlot"), f = _("globalRenderSlot"), { zIndex: v, getParentWidth: S, getParentHeight: i, getZoom: m } = t, { adjustPosition: b } = se(e), n = I(), x = I(), $ = I(), w = I(), E = [], L = _("globalSetCurrentSubMenu"), M = [];
504
+ const t = _("menuContext"), u = _("globalOptions"), r = _("globalHasSlot"), f = _("globalRenderSlot"), { zIndex: v, getParentWidth: S, getParentHeight: i, getZoom: p } = t, { adjustPosition: b } = se(e), n = I(), x = I(), $ = I(), w = I(), E = [], L = _("globalSetCurrentSubMenu"), M = [];
505
505
  let o = null, a = 0;
506
506
  function g() {
507
507
  o && o.blur();
@@ -523,7 +523,7 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
523
523
  function R(s) {
524
524
  if (o && g(), s !== void 0 && (o = M[Math.max(0, Math.min(s, M.length - 1))]), !!o && (o.focus(), ne.value)) {
525
525
  const h = o.getElement();
526
- h && (p.value = Math.min(Math.max(-B.value, -h.offsetTop - h.offsetHeight + U.value), 0));
526
+ h && (m.value = Math.min(Math.max(-B.value, -h.offsetTop - h.offsetHeight + U.value), 0));
527
527
  }
528
528
  }
529
529
  function c() {
@@ -614,8 +614,8 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
614
614
  } : { width: 0, height: 0 },
615
615
  getSubmenuRoot: () => n.value,
616
616
  getMenu: () => x.value,
617
- getScrollValue: () => p.value,
618
- setScrollValue: (s) => p.value = s,
617
+ getScrollValue: () => m.value,
618
+ setScrollValue: (s) => m.value = s,
619
619
  getScrollHeight: () => B.value,
620
620
  getMaxHeight: () => U.value,
621
621
  getPosition: () => k.value,
@@ -624,9 +624,9 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
624
624
  }
625
625
  }, H = _("menuItemInstance", void 0);
626
626
  H && (H.getSubMenuInstance = () => ee);
627
- const p = I(0), B = I(0);
627
+ const m = I(0), B = I(0);
628
628
  function V(s) {
629
- s ? p.value = Math.min(Math.max(p.value - 50, -B.value), 0) : p.value = Math.min(p.value + 50, 0);
629
+ s ? m.value = Math.min(Math.max(m.value - 50, -B.value), 0) : m.value = Math.min(m.value + 50, 0);
630
630
  }
631
631
  function X(s) {
632
632
  s.preventDefault(), s.stopPropagation(), V(s.deltaY > 0);
@@ -638,15 +638,15 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
638
638
  return ge(() => {
639
639
  const s = t.getPositon();
640
640
  k.value = {
641
- x: (s[0] ?? u.value.xOffset ?? 0) / m(),
642
- y: (s[1] ?? u.value.yOffset ?? 0) / m()
641
+ x: (s[0] ?? u.value.xOffset ?? 0) / p(),
642
+ y: (s[1] ?? u.value.yOffset ?? 0) / p()
643
643
  }, L(y), me(() => {
644
644
  var T, Oe;
645
645
  const h = x.value;
646
646
  if (h && $.value) {
647
- const { container: oe } = t, be = (S == null ? void 0 : S()) ?? 0, $e = (i == null ? void 0 : i()) ?? 0, ve = typeof t.adjustPadding == "number" ? t.adjustPadding : ((T = t.adjustPadding) == null ? void 0 : T.x) ?? 0, he = typeof t.adjustPadding == "number" ? t.adjustPadding : ((Oe = t.adjustPadding) == null ? void 0 : Oe.y) ?? 0, ie = $e > 0 ? he : 0, Ye = document.documentElement.scrollHeight / m(), Ze = document.documentElement.scrollWidth / m(), Xe = Math.min(Ze, oe.offsetWidth), Ce = Math.min(Ye, oe.offsetHeight);
647
+ const { container: oe } = t, be = (S == null ? void 0 : S()) ?? 0, $e = (i == null ? void 0 : i()) ?? 0, ve = typeof t.adjustPadding == "number" ? t.adjustPadding : ((T = t.adjustPadding) == null ? void 0 : T.x) ?? 0, he = typeof t.adjustPadding == "number" ? t.adjustPadding : ((Oe = t.adjustPadding) == null ? void 0 : Oe.y) ?? 0, ie = $e > 0 ? he : 0, Ye = document.documentElement.scrollHeight / p(), Ze = document.documentElement.scrollWidth / p(), Xe = Math.min(Ze, oe.offsetWidth), Ce = Math.min(Ye, oe.offsetHeight);
648
648
  let Me = J(h, oe), ye = q(h, oe);
649
- e.direction.includes("l") ? k.value.x -= h.offsetWidth + ve : e.direction.includes("r") ? k.value.x += be + ve : (k.value.x += be / 2, k.value.x -= (h.offsetWidth + ve) / 2), e.direction.includes("t") ? k.value.y -= (h.offsetHeight + he * 2) / m() : e.direction.includes("b") ? k.value.y -= he / m() : (k.value.y += $e / 2 / m(), k.value.y -= (h.offsetHeight + he) / 2 / m()), b.value && me(() => {
649
+ e.direction.includes("l") ? k.value.x -= h.offsetWidth + ve : e.direction.includes("r") ? k.value.x += be + ve : (k.value.x += be / 2, k.value.x -= (h.offsetWidth + ve) / 2), e.direction.includes("t") ? k.value.y -= (h.offsetHeight + he * 2) / p() : e.direction.includes("b") ? k.value.y -= he / p() : (k.value.y += $e / 2 / p(), k.value.y -= (h.offsetHeight + he) / 2 / p()), b.value && me(() => {
650
650
  Me = J(h, oe), ye = q(h, oe);
651
651
  const Ue = Me + h.offsetWidth - Xe, Re = ye + h.offsetHeight + ie * 2 - Ce;
652
652
  if (ne.value = Re > 0, B.value = h.offsetHeight - Ce + ie * 2, Ue > 0) {
@@ -674,7 +674,7 @@ const we = /* @__PURE__ */ fe(xt, [["render", It]]), wt = Q({
674
674
  options: u,
675
675
  zIndex: v,
676
676
  constOptions: N,
677
- scrollValue: p,
677
+ scrollValue: m,
678
678
  upScrollButton: w,
679
679
  overflow: ne,
680
680
  position: k,
@@ -702,7 +702,7 @@ const Wt = {
702
702
  ref: "scroll"
703
703
  };
704
704
  function $t(e, t, u, r, f, v) {
705
- const S = de("ContextMenuSeparator"), i = de("ContextSubMenu", !0), m = de("ContextMenuItem"), b = de("ContextMenuIconRight");
705
+ const S = de("ContextMenuSeparator"), i = de("ContextSubMenu", !0), p = de("ContextMenuItem"), b = de("ContextMenuIconRight");
706
706
  return d(), P("div", {
707
707
  ref: "submenuRoot",
708
708
  class: Z([
@@ -733,7 +733,7 @@ function $t(e, t, u, r, f, v) {
733
733
  e.overflow && e.options.updownButtonSpaceholder ? (d(), P("div", Wt)) : A("", !0),
734
734
  (d(!0), P(Ie, null, De(e.items, (n, x) => (d(), P(Ie, { key: x }, [
735
735
  n.hidden !== !0 && n.divided === "up" ? (d(), O(S, { key: 0 })) : A("", !0),
736
- n.hidden !== !0 && n.divided === "self" ? (d(), O(S, { key: 1 })) : (d(), O(m, {
736
+ n.hidden !== !0 && n.divided === "self" ? (d(), O(S, { key: 1 })) : (d(), O(p, {
737
737
  key: 2,
738
738
  clickHandler: n.onClick ? ($) => n.onClick($) : void 0,
739
739
  disabled: typeof n.disabled == "object" ? n.disabled.value : n.disabled,
@@ -840,14 +840,14 @@ const pe = /* @__PURE__ */ fe(wt, [["render", $t]]), Rt = { class: "mx-menu-ghos
840
840
  setup(e, { expose: t, emit: u }) {
841
841
  const r = e, f = u, v = Je(), S = I(), {
842
842
  options: i,
843
- show: m,
843
+ show: p,
844
844
  container: b
845
845
  } = se(r);
846
846
  ge(() => {
847
- m.value && $();
847
+ p.value && $();
848
848
  }), We(() => {
849
849
  M();
850
- }), Te(m, (c) => {
850
+ }), Te(p, (c) => {
851
851
  c ? $() : (Fe(n), M());
852
852
  });
853
853
  const n = {
@@ -871,16 +871,16 @@ const pe = /* @__PURE__ */ fe(wt, [["render", $t]]), Rt = { class: "mx-menu-ghos
871
871
  }
872
872
  function L() {
873
873
  setTimeout(() => {
874
- document.addEventListener("click", C, !0), document.addEventListener("contextmenu", C, !0), document.addEventListener("scroll", g, !0), !r.isFullScreenContainer && b.value && b.value.addEventListener("scroll", g, !0), i.value.keyboardControl !== !1 && document.addEventListener("keydown", a);
874
+ document.addEventListener("click", C, !0), document.addEventListener("contextmenu", C, !0), document.addEventListener("scroll", g, !0), !r.isFullScreenContainer && b.value && b.value.addEventListener("scroll", g, !0), i.value.keyboardControl !== !1 && document.addEventListener("keydown", a, !0);
875
875
  }, 50);
876
876
  }
877
877
  function M() {
878
- document.removeEventListener("contextmenu", C, !0), document.removeEventListener("click", C, !0), document.removeEventListener("scroll", g, !0), !r.isFullScreenContainer && b.value && b.value.removeEventListener("scroll", g, !0), i.value.keyboardControl !== !1 && document.removeEventListener("keydown", a);
878
+ document.removeEventListener("contextmenu", C, !0), document.removeEventListener("click", C, !0), document.removeEventListener("scroll", g, !0), !r.isFullScreenContainer && b.value && b.value.removeEventListener("scroll", g, !0), i.value.keyboardControl !== !1 && document.removeEventListener("keydown", a, !0);
879
879
  }
880
880
  const o = I();
881
881
  Y("globalSetCurrentSubMenu", (c) => o.value = c);
882
882
  function a(c) {
883
- var W, D, z, ee, H, p, B, V, X, te, ne, k, U;
883
+ var W, D, z, ee, H, m, B, V, X, te, ne, k, U;
884
884
  let y = !0;
885
885
  switch (c.key) {
886
886
  case "Escape": {
@@ -897,7 +897,7 @@ const pe = /* @__PURE__ */ fe(wt, [["render", $t]]), Rt = { class: "mx-menu-ghos
897
897
  (H = o.value) == null || H.moveCurrentItemFirst();
898
898
  break;
899
899
  case "End":
900
- (p = o.value) == null || p.moveCurrentItemLast();
900
+ (m = o.value) == null || m.moveCurrentItemLast();
901
901
  break;
902
902
  case "ArrowLeft": {
903
903
  (B = o.value) != null && B.closeSelfAndActiveParent() || (X = (V = i.value).onKeyFocusMoveLeft) == null || X.call(V);
@@ -970,7 +970,7 @@ const pe = /* @__PURE__ */ fe(wt, [["render", $t]]), Rt = { class: "mx-menu-ghos
970
970
  onAfterLeave: y[0] || (y[0] = (W) => f("closeAnimFinished"))
971
971
  }), {
972
972
  default: ce(() => [
973
- l(m) ? (d(), O(pe, {
973
+ l(p) ? (d(), O(pe, {
974
974
  key: 0,
975
975
  ref_key: "submenuInstance",
976
976
  ref: S,
@@ -988,7 +988,7 @@ const pe = /* @__PURE__ */ fe(wt, [["render", $t]]), Rt = { class: "mx-menu-ghos
988
988
  }, 8, ["items", "adjustPosition", "maxWidth", "minWidth", "direction"])) : A("", !0)
989
989
  ]),
990
990
  _: 3
991
- }, 16)) : l(m) ? (d(), O(pe, {
991
+ }, 16)) : l(p) ? (d(), O(pe, {
992
992
  key: 1,
993
993
  ref_key: "submenuInstance",
994
994
  ref: S,
@@ -1055,9 +1055,9 @@ const Bt = Q({
1055
1055
  show: r,
1056
1056
  container: S,
1057
1057
  isFullScreenContainer: !v,
1058
- onClose: (m) => {
1058
+ onClose: (p) => {
1059
1059
  var b, n;
1060
- t.emit("update:show", !1), t.emit("close"), (n = (b = u.value).onClose) == null || n.call(b, m);
1060
+ t.emit("update:show", !1), t.emit("close"), (n = (b = u.value).onClose) == null || n.call(b, p);
1061
1061
  }
1062
1062
  }, t.slots)
1063
1063
  ]
@@ -1196,13 +1196,13 @@ const Bt = Q({
1196
1196
  }
1197
1197
  },
1198
1198
  setup(e, t) {
1199
- const u = _("globalOptions"), { adjustSubMenuPosition: r, maxWidth: f, minWidth: v } = se(e), S = typeof r.value < "u" ? r.value : u.value.adjustPosition, i = I(), m = I();
1199
+ const u = _("globalOptions"), { adjustSubMenuPosition: r, maxWidth: f, minWidth: v } = se(e), S = typeof r.value < "u" ? r.value : u.value.adjustPosition, i = I(), p = I();
1200
1200
  return t.expose({
1201
1201
  getSubMenuRef: () => i.value,
1202
- getMenuItemRef: () => m.value
1202
+ getMenuItemRef: () => p.value
1203
1203
  }), () => ue(Pe, {
1204
1204
  ...e,
1205
- ref: m,
1205
+ ref: p,
1206
1206
  showRightArrow: !0,
1207
1207
  maxWidth: void 0,
1208
1208
  minWidth: void 0,
@@ -1363,7 +1363,7 @@ const Nt = /* @__PURE__ */ fe(jt, [["render", Tt]]), zt = ["onClick", "onMouseen
1363
1363
  }), Te(() => t.options, () => {
1364
1364
  f.value = t.options.items || [];
1365
1365
  });
1366
- let m = null, b = -1;
1366
+ let p = null, b = -1;
1367
1367
  function n() {
1368
1368
  b < f.value.length - 1 ? b++ : b = 0, w(b, f.value[b]);
1369
1369
  }
@@ -1379,11 +1379,11 @@ const Nt = /* @__PURE__ */ fe(jt, [["render", Tt]]), zt = ["onClick", "onMouseen
1379
1379
  var C;
1380
1380
  if (b = o, !a.children)
1381
1381
  return;
1382
- m && (m.closeMenu(), m = null, r.value = !0), v.value = a;
1382
+ p && (p.closeMenu(), p = null, r.value = !0), v.value = a;
1383
1383
  const g = (C = u.value) == null ? void 0 : C.children[o];
1384
1384
  if (g) {
1385
1385
  const { x: R, y: c } = $(g);
1386
- m = Le.showContextMenu({
1386
+ p = Le.showContextMenu({
1387
1387
  ...t.options,
1388
1388
  items: a.children,
1389
1389
  x: R,
@@ -1397,7 +1397,7 @@ const Nt = /* @__PURE__ */ fe(jt, [["render", Tt]]), zt = ["onClick", "onMouseen
1397
1397
  onClose() {
1398
1398
  v.value == a && (r.value = !1, v.value = null), typeof a.onSubMenuClose == "function" && a.onSubMenuClose(void 0);
1399
1399
  }
1400
- }), m && typeof a.onSubMenuOpen == "function" && a.onSubMenuOpen(void 0);
1400
+ }), p && typeof a.onSubMenuOpen == "function" && a.onSubMenuOpen(void 0);
1401
1401
  }
1402
1402
  }
1403
1403
  function E() {
@@ -1405,7 +1405,7 @@ const Nt = /* @__PURE__ */ fe(jt, [["render", Tt]]), zt = ["onClick", "onMouseen
1405
1405
  const o = u.value;
1406
1406
  if (o) {
1407
1407
  const { x: a, y: g } = $(o);
1408
- m = Le.showContextMenu({
1408
+ p = Le.showContextMenu({
1409
1409
  ...t.options,
1410
1410
  x: a,
1411
1411
  y: g