mamba-layout 0.2.0 → 0.3.0

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.
@@ -1 +1 @@
1
- .layout-shell[data-v-259cbdf0]{background:var(--ui-topnav-bg);color:var(--ui-text-primary)}.layout-shell__overlay[data-v-259cbdf0]{background:#000000b3}.layout-page-view[data-v-259cbdf0]{display:flex;flex:1 1 auto;flex-direction:column;width:100%;min-width:0;min-height:0;background:var(--ui-bg-page);contain:paint}.layout-page-enter-active[data-v-259cbdf0],.layout-page-leave-active[data-v-259cbdf0]{transition:opacity var(--ui-transition-base),transform var(--ui-transition-base);will-change:opacity,transform}.layout-page-enter-from[data-v-259cbdf0]{opacity:0;transform:translate3d(8px,0,0)}.layout-page-leave-to[data-v-259cbdf0]{opacity:0;transform:translate3d(-6px,0,0)}@media(prefers-reduced-motion:reduce){.layout-page-enter-active[data-v-259cbdf0],.layout-page-leave-active[data-v-259cbdf0]{transition:none}.layout-page-enter-from[data-v-259cbdf0],.layout-page-leave-to[data-v-259cbdf0]{opacity:1;transform:none}}
1
+ .layout-shell[data-v-b3392308]{background:var(--ui-topnav-bg);color:var(--ui-text-primary)}.layout-shell__overlay[data-v-b3392308]{background:#000000b3}.layout-page-view[data-v-b3392308]{display:flex;flex:1 1 auto;flex-direction:column;width:100%;min-width:0;min-height:0;background:var(--ui-bg-page);contain:paint}.layout-page-enter-active[data-v-b3392308],.layout-page-leave-active[data-v-b3392308]{transition:opacity var(--ui-transition-base),transform var(--ui-transition-base);will-change:opacity,transform}.layout-page-enter-from[data-v-b3392308]{opacity:0;transform:translate3d(8px,0,0)}.layout-page-leave-to[data-v-b3392308]{opacity:0;transform:translate3d(-6px,0,0)}@media(prefers-reduced-motion:reduce){.layout-page-enter-active[data-v-b3392308],.layout-page-leave-active[data-v-b3392308]{transition:none}.layout-page-enter-from[data-v-b3392308],.layout-page-leave-to[data-v-b3392308]{opacity:1;transform:none}}
@@ -1,7 +1,7 @@
1
1
  import o from "./BaseLayout.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-259cbdf0"]]);
4
+ const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-b3392308"]]);
5
5
  export {
6
- m as default
6
+ p as default
7
7
  };
@@ -1,56 +1,87 @@
1
- import { defineComponent as x, computed as w, watchEffect as k, resolveComponent as L, openBlock as o, createElementBlock as r, createVNode as u, withCtx as c, renderSlot as b, createElementVNode as d, unref as m, createBlock as f, Transition as B, resolveDynamicComponent as C, normalizeClass as S, createCommentVNode as M } from "vue";
2
- import E from "./components/AsideBar.vue.js";
3
- import N from "./components/HeaderBar.vue.js";
4
- import V from "./components/mobile/AsideBarMobile.vue.js";
5
- import z from "../assets/logo.png.js";
6
- import { provideSetting as A } from "./hooks/useSetting.js";
7
- import { useStateHook as H } from "./hooks/useState.js";
8
- const O = { class: "layout-shell w-full h-screen flex flex-col" }, D = { class: "flex flex-1 min-h-0 rounded-[var(--ui-body-radius)] overflow-hidden" }, T = { class: "flex flex-col flex-1 min-h-0 min-w-0 h-full" }, $ = { class: "flex-1 w-full min-h-0 flex flex-col overflow-hidden bg-[var(--ui-color-background)]" }, P = /* @__PURE__ */ x({
1
+ import { defineComponent as E, computed as A, watchEffect as C, watch as S, onMounted as M, onUnmounted as N, resolveComponent as j, openBlock as s, createElementBlock as f, createVNode as u, withCtx as c, renderSlot as K, createElementVNode as p, unref as y, createBlock as v, Transition as k, resolveDynamicComponent as O, createCommentVNode as R } from "vue";
2
+ import V from "./components/AsideBar.vue.js";
3
+ import $ from "./components/HeaderBar.vue.js";
4
+ import H from "./components/mobile/AsideBarMobile.vue.js";
5
+ import P from "../assets/logo.png.js";
6
+ import { provideSetting as D } from "./hooks/useSetting.js";
7
+ import { useStateHook as T } from "./hooks/useState.js";
8
+ const U = { class: "layout-shell w-full flex flex-col" }, q = { class: "layout-shell__body flex flex-1 min-h-0 overflow-hidden" }, z = { class: "layout-shell__main flex flex-col flex-1 min-h-0 min-w-0 h-full" }, F = { class: "layout-shell__content flex-1 w-full min-h-0 flex flex-col overflow-hidden" }, Z = /* @__PURE__ */ E({
9
9
  __name: "BaseLayout",
10
10
  props: {
11
11
  setting: {}
12
12
  },
13
- setup(_) {
14
- const e = _, h = w(() => {
15
- var n, a, l, i, t, g, v;
13
+ setup(x) {
14
+ const l = x, L = A(() => {
15
+ var e, o, a, t, n, g, w;
16
16
  return {
17
- ...e.setting || {},
18
- logo: ((n = e.setting) == null ? void 0 : n.logo) || z,
19
- menus: ((a = e.setting) == null ? void 0 : a.menus) || [],
20
- accountMenu: ((l = e.setting) == null ? void 0 : l.accountMenu) || [],
21
- user: ((i = e.setting) == null ? void 0 : i.user) ?? null,
22
- appList: ((t = e.setting) == null ? void 0 : t.appList) || [],
23
- onLogin: (g = e.setting) == null ? void 0 : g.onLogin,
24
- onLogout: (v = e.setting) == null ? void 0 : v.onLogout
17
+ ...l.setting || {},
18
+ logo: ((e = l.setting) == null ? void 0 : e.logo) || P,
19
+ menus: ((o = l.setting) == null ? void 0 : o.menus) || [],
20
+ accountMenu: ((a = l.setting) == null ? void 0 : a.accountMenu) || [],
21
+ user: ((t = l.setting) == null ? void 0 : t.user) ?? null,
22
+ appList: ((n = l.setting) == null ? void 0 : n.appList) || [],
23
+ onLogin: (g = l.setting) == null ? void 0 : g.onLogin,
24
+ onLogout: (w = l.setting) == null ? void 0 : w.onLogout
25
25
  };
26
26
  });
27
- k(() => void A(h.value));
28
- const { isMobile: p, sideOpen: s } = H(), y = () => void (s.value = !s.value);
29
- return (n, a) => {
30
- const l = L("router-view");
31
- return o(), r("div", O, [
32
- u(N, null, {
27
+ C(() => void D(L.value));
28
+ const { isMobile: i, sideOpen: d } = T();
29
+ let m = "", r = !1;
30
+ const h = () => void (d.value = !1), B = (e) => {
31
+ const o = e.matched[1];
32
+ if (!o) return e.path;
33
+ const a = b(o, e);
34
+ return [o.path, a].filter(Boolean).join("|");
35
+ }, b = (e, o) => Array.from(
36
+ e.path.matchAll(/:(\w+)/g),
37
+ ([, t]) => t
38
+ ).map((t) => {
39
+ const n = o.params[t];
40
+ return `${t}:${Array.isArray(n) ? n.join(",") : n || ""}`;
41
+ }).join("|"), _ = (e) => {
42
+ e.key === "Escape" && i.value && d.value && h();
43
+ };
44
+ return S(
45
+ () => i.value && d.value,
46
+ (e) => {
47
+ if (!(typeof document > "u")) {
48
+ if (e && !r) {
49
+ m = document.body.style.overflow, document.body.style.overflow = "hidden", r = !0;
50
+ return;
51
+ }
52
+ !e && r && (document.body.style.overflow = m, r = !1);
53
+ }
54
+ },
55
+ { immediate: !0 }
56
+ ), M(() => {
57
+ window.addEventListener("keydown", _);
58
+ }), N(() => {
59
+ window.removeEventListener("keydown", _), typeof document < "u" && r && (document.body.style.overflow = m);
60
+ }), (e, o) => {
61
+ const a = j("router-view");
62
+ return s(), f("div", U, [
63
+ u($, null, {
33
64
  default: c(() => [
34
- b(n.$slots, "header-right", {}, void 0, !0)
65
+ K(e.$slots, "header-right", {}, void 0, !0)
35
66
  ]),
36
67
  _: 3
37
68
  }),
38
- d("div", D, [
39
- m(p) ? (o(), f(V, { key: 1 })) : (o(), f(E, { key: 0 })),
40
- d("div", T, [
41
- d("div", $, [
42
- u(l, null, {
43
- default: c(({ Component: i, route: t }) => [
44
- u(B, {
45
- name: String(t.meta.transition || "layout-page"),
69
+ p("div", q, [
70
+ y(i) ? (s(), v(H, { key: 1 })) : (s(), v(V, { key: 0 })),
71
+ p("main", z, [
72
+ p("div", F, [
73
+ u(a, null, {
74
+ default: c(({ Component: t, route: n }) => [
75
+ u(k, {
76
+ name: String(n.meta.transition || "layout-page"),
46
77
  mode: "out-in"
47
78
  }, {
48
79
  default: c(() => [
49
- (o(), r("div", {
50
- key: t.path,
80
+ (s(), f("div", {
81
+ key: B(n),
51
82
  class: "layout-page-view"
52
83
  }, [
53
- (o(), f(C(i)))
84
+ (s(), v(O(t)))
54
85
  ]))
55
86
  ]),
56
87
  _: 2
@@ -61,15 +92,20 @@ const O = { class: "layout-shell w-full h-screen flex flex-col" }, D = { class:
61
92
  ])
62
93
  ])
63
94
  ]),
64
- m(p) ? (o(), r("div", {
65
- key: 0,
66
- class: S(["layout-shell__overlay fixed top-0 left-0 w-full h-full z-100 transition-all", [m(s) ? "visible opacity-100" : "invisible opacity-0"]]),
67
- onClick: y
68
- }, null, 2)) : M("", !0)
95
+ u(k, { name: "layout-overlay" }, {
96
+ default: c(() => [
97
+ y(i) && y(d) ? (s(), f("div", {
98
+ key: 0,
99
+ class: "layout-shell__overlay",
100
+ onClick: h
101
+ })) : R("", !0)
102
+ ]),
103
+ _: 1
104
+ })
69
105
  ]);
70
106
  };
71
107
  }
72
108
  });
73
109
  export {
74
- P as default
110
+ Z as default
75
111
  };
@@ -18,8 +18,8 @@ type __VLS_Props = {
18
18
  };
19
19
  declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
20
20
  parentPath: string;
21
- currentTitle: string;
22
21
  items: LayoutBreadcrumbItem[];
22
+ currentTitle: string;
23
23
  preserveQueryKeys: string[];
24
24
  showCurrent: boolean;
25
25
  showBack: boolean;
@@ -2,7 +2,7 @@ import o from "./UserInfo.vue2.js";
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  import r from "../../_virtual/_plugin-vue_export-helper.js";
5
- const s = /* @__PURE__ */ r(o, [["__scopeId", "data-v-63bc60f6"]]);
5
+ const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-ac052463"]]);
6
6
  export {
7
- s as default
7
+ f as default
8
8
  };
@@ -1 +1 @@
1
- .user-info__trigger[data-v-63bc60f6]{display:inline-flex;width:28px;height:28px;overflow:hidden;border-radius:var(--ui-radius-pill);background:var(--ui-avatar-bg, var(--el-color-primary));border:1px solid var(--ui-topnav-border);align-items:center;justify-content:center;font-size:12px;font-weight:600;color:var(--ui-text-on-brand);cursor:pointer;flex-shrink:0;-webkit-user-select:none;user-select:none;transition:border-color var(--ui-transition-fast),filter var(--ui-transition-fast)}.user-info__trigger[data-v-63bc60f6]:hover{border-color:var(--ui-topnav-foreground);filter:brightness(1.05)}.user-info__panel[data-v-63bc60f6]{display:grid;gap:4px}.user-info__profile[data-v-63bc60f6]{display:grid;grid-template-columns:44px minmax(0,1fr);gap:12px;align-items:center;padding:8px 8px 10px}.user-info__profile-avatar[data-v-63bc60f6]{width:44px;height:44px;overflow:hidden;border-radius:var(--ui-radius-pill);display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;background:var(--ui-avatar-bg, var(--el-color-primary));color:var(--ui-text-on-brand);font-size:16px;font-weight:700}.user-info__profile-main[data-v-63bc60f6]{min-width:0}.user-info__display-name[data-v-63bc60f6]{color:var(--ui-text-primary);font-size:14px;font-weight:700;line-height:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-info__username[data-v-63bc60f6]{margin-top:2px;color:var(--ui-text-muted);font-size:12px;line-height:18px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-info__meta[data-v-63bc60f6]{display:grid;gap:2px;padding:8px;margin-bottom:2px;border-radius:var(--ui-radius-control);background:var(--ui-bg-muted)}.user-info__meta-row[data-v-63bc60f6]{display:grid;grid-template-columns:64px minmax(0,1fr);gap:8px;align-items:center;min-height:24px;font-size:12px;line-height:18px}.user-info__meta-label[data-v-63bc60f6]{color:var(--ui-text-muted)}.user-info__meta-value[data-v-63bc60f6]{min-width:0;color:var(--ui-text-secondary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:right}.user-info__item[data-v-63bc60f6]{display:flex;align-items:center;gap:8px;padding:10px 12px;border-radius:var(--ui-radius-control);color:var(--ui-text-primary);cursor:pointer;transition:background var(--ui-transition-fast),color var(--ui-transition-fast)}.user-info__item[data-v-63bc60f6]:hover{background:var(--ui-bg-muted)}.user-info__item--danger[data-v-63bc60f6]{color:var(--el-color-danger)}.user-info__divider[data-v-63bc60f6]{height:1px;background:var(--ui-border-soft);margin:4px 0}
1
+ .user-info__trigger[data-v-ac052463]{display:inline-flex;width:28px;height:28px;overflow:hidden;border-radius:var(--ui-radius-pill);background:var(--ui-avatar-bg, var(--el-color-primary));border:1px solid var(--ui-topnav-border);align-items:center;justify-content:center;font-size:12px;font-weight:600;color:var(--ui-text-on-brand);cursor:pointer;flex-shrink:0;-webkit-user-select:none;user-select:none;transition:border-color var(--ui-transition-fast),filter var(--ui-transition-fast)}.user-info__trigger[data-v-ac052463]:hover{border-color:var(--ui-topnav-foreground);filter:brightness(1.05)}.user-info__panel[data-v-ac052463]{display:grid;gap:2px}.user-info__profile[data-v-ac052463]{display:grid;grid-template-columns:44px minmax(0,1fr);gap:12px;align-items:center;padding:8px 8px 10px}.user-info__profile-avatar[data-v-ac052463]{width:44px;height:44px;overflow:hidden;border-radius:var(--ui-radius-pill);display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;background:var(--ui-avatar-bg, var(--el-color-primary));color:var(--ui-text-on-brand);font-size:16px;font-weight:700}.user-info__profile-main[data-v-ac052463]{min-width:0}.user-info__display-name[data-v-ac052463]{color:var(--ui-text-primary);font-size:14px;font-weight:700;line-height:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-info__username[data-v-ac052463]{margin-top:2px;color:var(--ui-text-muted);font-size:12px;line-height:18px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-info__meta[data-v-ac052463]{display:grid;gap:2px;padding:8px;margin-bottom:2px;border-radius:var(--ui-radius-control);background:var(--ui-bg-muted)}.user-info__meta-row[data-v-ac052463]{display:grid;grid-template-columns:64px minmax(0,1fr);gap:8px;align-items:center;min-height:24px;font-size:12px;line-height:18px}.user-info__meta-label[data-v-ac052463]{color:var(--ui-text-muted)}.user-info__meta-value[data-v-ac052463]{min-width:0;color:var(--ui-text-secondary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:right}.user-info__item[data-v-ac052463]{display:flex;align-items:center;gap:8px;padding:8px 12px;border-radius:var(--ui-radius-control);color:var(--ui-text-primary);font-size:12px;cursor:pointer;transition:background var(--ui-transition-fast),color var(--ui-transition-fast)}.user-info__item[data-v-ac052463]:hover{background:var(--ui-bg-muted)}.user-info__item--danger[data-v-ac052463]{color:var(--el-color-danger)}.user-info__divider[data-v-ac052463]{height:1px;background:var(--ui-border-soft);margin:4px 0}
@@ -3,17 +3,17 @@ import { useApp as I } from "../../hooks/useApp.js";
3
3
  import { injectLayoutContext as w } from "../../hooks/useState.js";
4
4
  const L = {
5
5
  key: 0,
6
- class: "w-full px-3"
6
+ class: "min-w-0 flex-1"
7
7
  }, F = /* @__PURE__ */ C({
8
8
  __name: "AppSelectMobile",
9
9
  setup(N) {
10
10
  const { currentAppId: v } = w(), { appList: s, getAppPath: a, findAppById: h } = I(), g = x(() => {
11
- const t = h(v.value);
12
- return t ? a(t) : "";
13
- }), k = (t) => {
14
- t && (location.href = t);
11
+ const n = h(v.value);
12
+ return n ? a(n) : "";
13
+ }), k = (n) => {
14
+ n && (location.href = n);
15
15
  };
16
- return (t, P) => {
16
+ return (n, P) => {
17
17
  var d;
18
18
  const _ = p("el-option"), y = p("el-option-group"), b = p("el-select");
19
19
  return (d = l(s)) != null && d.length ? (e(), o("div", L, [
@@ -23,17 +23,17 @@ const L = {
23
23
  onChange: k
24
24
  }, {
25
25
  default: i(() => [
26
- (e(!0), o(c, null, f(l(s), (n) => {
26
+ (e(!0), o(c, null, f(l(s), (t) => {
27
27
  var m;
28
28
  return e(), o(c, {
29
- key: n.appId
29
+ key: t.appId
30
30
  }, [
31
- (m = n.children) != null && m.length ? (e(), u(y, {
31
+ (m = t.children) != null && m.length ? (e(), u(y, {
32
32
  key: 0,
33
- label: n.name
33
+ label: t.name
34
34
  }, {
35
35
  default: i(() => [
36
- (e(!0), o(c, null, f(n.children, (r) => (e(), u(_, {
36
+ (e(!0), o(c, null, f(t.children, (r) => (e(), u(_, {
37
37
  key: r.appId,
38
38
  label: r.name,
39
39
  value: l(a)(r),
@@ -43,8 +43,8 @@ const L = {
43
43
  _: 2
44
44
  }, 1032, ["label"])) : (e(), u(_, {
45
45
  key: 1,
46
- label: n.name,
47
- value: l(a)(n)
46
+ label: t.name,
47
+ value: l(a)(t)
48
48
  }, null, 8, ["label", "value"]))
49
49
  ], 64);
50
50
  }), 128))
@@ -1 +1 @@
1
- .aside-bar-mobile[data-v-dede8d1e]{border-right:1px solid var(--ui-sidebar-border);background:var(--ui-sidebar-bg);color:var(--ui-sidebar-foreground);box-shadow:var(--ui-shadow-pop)}.aside-bar-mobile__head[data-v-dede8d1e]{border-bottom:1px solid var(--ui-sidebar-border)}.aside-bar-mobile__close[data-v-dede8d1e]{color:var(--ui-text-muted)}
1
+ .aside-bar-mobile[data-v-ffd10c8b]{width:min(86vw,320px);max-width:calc(100vw - 32px);height:100vh;height:100dvh;z-index:240;border-right:1px solid var(--ui-sidebar-border);background:var(--ui-sidebar-bg);color:var(--ui-sidebar-foreground);box-shadow:var(--ui-shadow-pop);will-change:transform}.aside-bar-mobile__head[data-v-ffd10c8b]{min-height:var(--layout-mobile-header-height, 56px);padding:10px 12px;border-bottom:1px solid var(--ui-sidebar-border);flex-shrink:0}.aside-bar-mobile__close[data-v-ffd10c8b]{width:36px;height:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;border:1px solid var(--ui-sidebar-border);border-radius:var(--ui-radius-control);background:var(--ui-sidebar-accent);color:var(--ui-text-muted);cursor:pointer;transition:background var(--ui-transition-fast),color var(--ui-transition-fast),border-color var(--ui-transition-fast)}.aside-bar-mobile__close[data-v-ffd10c8b]:hover{background:var(--ui-sidebar-hover-bg);color:var(--ui-sidebar-foreground)}.aside-bar-mobile[data-v-ffd10c8b] .el-scrollbar{flex:1 1 auto;min-height:0}
@@ -1,7 +1,7 @@
1
1
  import o from "./AsideBarMobile.vue2.js";
2
2
  /* empty css */
3
- import e from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ e(o, [["__scopeId", "data-v-dede8d1e"]]);
3
+ import r from "../../../_virtual/_plugin-vue_export-helper.js";
4
+ const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-ffd10c8b"]]);
5
5
  export {
6
- a as default
6
+ e as default
7
7
  };
@@ -1,47 +1,49 @@
1
- import { defineComponent as d, resolveComponent as s, unref as o, openBlock as _, createElementBlock as f, normalizeClass as p, createElementVNode as l, createVNode as e, withCtx as i, renderSlot as u, createCommentVNode as b } from "vue";
1
+ import { defineComponent as d, resolveComponent as r, unref as o, openBlock as _, createElementBlock as f, normalizeClass as p, createElementVNode as t, createVNode as e, withCtx as a, renderSlot as u, createCommentVNode as b } from "vue";
2
2
  import { Fold as x } from "@element-plus/icons-vue";
3
3
  import { injectLayoutContext as h } from "../../hooks/useState.js";
4
- import v from "../AsideSubMenus.vue.js";
5
- import C from "./AppSelectMobile.vue.js";
6
- import g from "./AsideUserMobile.vue.js";
7
- const k = { class: "aside-bar-mobile__head flex justify-between items-center pt-4 pb-4 px-4" }, w = { class: "p-3" }, A = /* @__PURE__ */ d({
4
+ import C from "../AsideSubMenus.vue.js";
5
+ import v from "./AppSelectMobile.vue.js";
6
+ import k from "./AsideUserMobile.vue.js";
7
+ const y = { class: "aside-bar-mobile__head flex items-center gap-3" }, S = { class: "p-3" }, M = /* @__PURE__ */ d({
8
8
  __name: "AsideBarMobile",
9
9
  setup($) {
10
- const { menus: n, sideOpen: t } = h(), a = () => void (t.value = !t.value);
11
- return (r, y) => {
12
- const m = s("el-icon"), c = s("el-scrollbar");
13
- return o(n).length && !r.$route.meta.hideSidebar ? (_(), f("div", {
10
+ const { menus: l, sideOpen: n } = h(), i = () => void (n.value = !1);
11
+ return (s, B) => {
12
+ const m = r("el-icon"), c = r("el-scrollbar");
13
+ return o(l).length && !s.$route.meta.hideSidebar ? (_(), f("div", {
14
14
  key: 0,
15
- class: p(["aside-bar-mobile flex flex-col h-full min-h-0 w-1/2 min-w-70 fixed top-0 left-0 z-200 transition-all", [o(t) ? "translate-x-[0px]" : "translate-x-[-100%]"]])
15
+ class: p(["aside-bar-mobile fixed inset-y-0 left-0 z-200 flex min-h-0 flex-col transition-transform", [o(n) ? "translate-x-[0px]" : "translate-x-[-100%]"]])
16
16
  }, [
17
- l("div", k, [
18
- l("div", {
19
- class: "aside-bar-mobile__close text-lg cursor-pointer p-2 leading-4",
20
- onClick: a
17
+ t("div", y, [
18
+ t("button", {
19
+ type: "button",
20
+ class: "aside-bar-mobile__close",
21
+ "aria-label": "Close menu",
22
+ onClick: i
21
23
  }, [
22
24
  e(m, null, {
23
- default: i(() => [
25
+ default: a(() => [
24
26
  e(o(x))
25
27
  ]),
26
28
  _: 1
27
29
  })
28
30
  ]),
29
- e(C)
31
+ e(v)
30
32
  ]),
31
33
  e(c, { ref: "leftScrollRef" }, {
32
- default: i(() => [
33
- l("div", w, [
34
- e(v, { menus: o(n) }, null, 8, ["menus"])
34
+ default: a(() => [
35
+ t("div", S, [
36
+ e(C, { menus: o(l) }, null, 8, ["menus"])
35
37
  ])
36
38
  ]),
37
39
  _: 1
38
40
  }, 512),
39
- u(r.$slots, "sidebar-foot", {}, void 0, !0),
40
- e(g)
41
+ u(s.$slots, "sidebar-foot", {}, void 0, !0),
42
+ e(k)
41
43
  ], 2)) : b("", !0);
42
44
  };
43
45
  }
44
46
  });
45
47
  export {
46
- A as default
48
+ M as default
47
49
  };
@@ -1 +1 @@
1
- .header-right-mobile[data-v-03748150]{--nav-icon-btn-size: 40px;display:flex;align-items:center;gap:10px;padding-right:4px}.header-right-mobile__action[data-v-03748150]{--nav-icon-btn-color: var(--ui-topnav-foreground);--nav-icon-btn-bg: var(--ui-topnav-surface);--nav-icon-btn-border-color: var(--ui-topnav-border);--nav-icon-btn-hover-bg: var(--ui-topnav-hover);--nav-icon-btn-hover-color: var(--ui-topnav-foreground);--nav-icon-btn-hover-border-color: var(--ui-topnav-border)}
1
+ .header-right-mobile[data-v-48792b0a]{--nav-icon-btn-size: 40px;display:flex;align-items:center;gap:8px;padding-right:0;min-width:0}.header-right-mobile[data-v-48792b0a] .nav-icon-btn{--nav-icon-btn-size: 40px;--nav-icon-btn-color: var(--ui-topnav-foreground);--nav-icon-btn-bg: var(--ui-topnav-surface);--nav-icon-btn-border-color: var(--ui-topnav-border);--nav-icon-btn-hover-bg: var(--ui-topnav-hover);--nav-icon-btn-hover-color: var(--ui-topnav-foreground);--nav-icon-btn-hover-border-color: var(--ui-topnav-border)}.header-right-mobile__action[data-v-48792b0a]{--nav-icon-btn-color: var(--ui-topnav-foreground);--nav-icon-btn-bg: var(--ui-topnav-surface);--nav-icon-btn-border-color: var(--ui-topnav-border);--nav-icon-btn-hover-bg: var(--ui-topnav-hover);--nav-icon-btn-hover-color: var(--ui-topnav-foreground);--nav-icon-btn-hover-border-color: var(--ui-topnav-border)}@media(max-width:374px){.header-right-mobile[data-v-48792b0a]{--nav-icon-btn-size: 36px;gap:6px}.header-right-mobile[data-v-48792b0a] .nav-icon-btn{--nav-icon-btn-size: 36px}}
@@ -1,7 +1,7 @@
1
1
  import o from "./HeaderRightMobile.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const i = /* @__PURE__ */ t(o, [["__scopeId", "data-v-03748150"]]);
4
+ const i = /* @__PURE__ */ t(o, [["__scopeId", "data-v-48792b0a"]]);
5
5
  export {
6
6
  i as default
7
7
  };
@@ -1,29 +1,27 @@
1
- import { defineComponent as u, computed as d, openBlock as r, createElementBlock as p, createVNode as i, createBlock as l, withCtx as n, createElementVNode as s } from "vue";
2
- import { useSetting as f } from "../../hooks/useSetting.js";
3
- import { redirectToLayoutLogin as g } from "../../utils/index.js";
1
+ import { defineComponent as u, computed as d, openBlock as r, createElementBlock as p, createVNode as n, createBlock as l, withCtx as i, createElementVNode as s } from "vue";
2
+ import { useSetting as g } from "../../hooks/useSetting.js";
3
+ import { redirectToLayoutLogin as _ } from "../../utils/index.js";
4
4
  import a from "../NavIconBtn.vue.js";
5
- import _ from "../ThemeToggle.vue.js";
6
- import h from "../TimezoneSelect.vue.js";
7
- import v from "./AsideUserMobilePopover.vue.js";
8
- const k = { class: "header-right-mobile" }, E = /* @__PURE__ */ u({
5
+ import f from "../ThemeToggle.vue.js";
6
+ import h from "./AsideUserMobilePopover.vue.js";
7
+ const v = { class: "header-right-mobile" }, N = /* @__PURE__ */ u({
9
8
  __name: "HeaderRightMobile",
10
- setup(b) {
11
- const t = f(), m = d(
9
+ setup(k) {
10
+ const t = g(), m = d(
12
11
  () => {
13
12
  var o, e;
14
13
  return !!((o = t.value.user) != null && o.id || (e = t.value.user) != null && e.userId);
15
14
  }
16
15
  ), c = () => {
17
16
  var o, e;
18
- (e = (o = t.value).onLogin) != null && e.call(o) || g(t.value);
17
+ (e = (o = t.value).onLogin) != null && e.call(o) || _(t.value);
19
18
  };
20
- return (o, e) => (r(), p("div", k, [
21
- i(h),
22
- i(_),
23
- m.value ? (r(), l(v, { key: 0 }, {
24
- reference: n(() => [
25
- i(a, { class: "header-right-mobile__action" }, {
26
- default: n(() => [...e[0] || (e[0] = [
19
+ return (o, e) => (r(), p("div", v, [
20
+ n(f),
21
+ m.value ? (r(), l(h, { key: 0 }, {
22
+ reference: i(() => [
23
+ n(a, { class: "header-right-mobile__action" }, {
24
+ default: i(() => [...e[0] || (e[0] = [
27
25
  s("i", { class: "metisicon-yonghu1" }, null, -1)
28
26
  ])]),
29
27
  _: 1
@@ -35,7 +33,7 @@ const k = { class: "header-right-mobile" }, E = /* @__PURE__ */ u({
35
33
  class: "header-right-mobile__action",
36
34
  onClick: c
37
35
  }, {
38
- default: n(() => [...e[1] || (e[1] = [
36
+ default: i(() => [...e[1] || (e[1] = [
39
37
  s("i", { class: "metisicon-yonghu1" }, null, -1)
40
38
  ])]),
41
39
  _: 1
@@ -44,5 +42,5 @@ const k = { class: "header-right-mobile" }, E = /* @__PURE__ */ u({
44
42
  }
45
43
  });
46
44
  export {
47
- E as default
45
+ N as default
48
46
  };
@@ -1 +1 @@
1
- .mobile-menu-toggle[data-v-3aac408b]{width:52px;height:52px;display:inline-flex;align-items:center;justify-content:center;border:0;border-right:1px solid var(--ui-topnav-border);background:var(--ui-topnav-accent);color:var(--ui-topnav-foreground);cursor:pointer;transition:background var(--ui-transition-fast),color var(--ui-transition-fast)}.mobile-menu-toggle[data-v-3aac408b]:hover{background:var(--ui-topnav-hover)}.mobile-menu-toggle__icon[data-v-3aac408b]{width:24px;height:24px;display:inline-flex;align-items:center;justify-content:center;font-size:18px}
1
+ .mobile-menu-toggle[data-v-c14b8f72]{width:40px;height:40px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;border:1px solid var(--ui-topnav-border);border-radius:var(--ui-radius-control);background:var(--ui-topnav-surface);color:var(--ui-topnav-foreground);cursor:pointer;transition:background var(--ui-transition-fast),color var(--ui-transition-fast)}.mobile-menu-toggle[data-v-c14b8f72]:hover{background:var(--ui-topnav-hover)}.mobile-menu-toggle[data-v-c14b8f72]:focus-visible{outline:2px solid var(--ui-topnav-foreground);outline-offset:2px}.mobile-menu-toggle__icon[data-v-c14b8f72]{width:24px;height:24px;display:inline-flex;align-items:center;justify-content:center;font-size:18px}
@@ -1,7 +1,7 @@
1
1
  import o from "./MobileMenuToggle.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-3aac408b"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-c14b8f72"]]);
5
5
  export {
6
6
  m as default
7
7
  };
@@ -1,28 +1,30 @@
1
- import { defineComponent as l, resolveComponent as c, openBlock as i, createElementBlock as m, createElementVNode as r, createVNode as o, withCtx as s, unref as _ } from "vue";
2
- import { Expand as a } from "@element-plus/icons-vue";
3
- import { injectLayoutContext as p } from "../../hooks/useState.js";
4
- const u = { class: "mobile-menu-toggle__icon" }, v = /* @__PURE__ */ l({
1
+ import { defineComponent as a, resolveComponent as c, openBlock as i, createElementBlock as r, unref as o, createElementVNode as m, createVNode as n, withCtx as s } from "vue";
2
+ import { Expand as p } from "@element-plus/icons-vue";
3
+ import { injectLayoutContext as _ } from "../../hooks/useState.js";
4
+ const u = ["aria-label", "aria-expanded"], d = { class: "mobile-menu-toggle__icon" }, v = /* @__PURE__ */ a({
5
5
  __name: "MobileMenuToggle",
6
- setup(d) {
7
- const { sideOpen: e } = p(), t = () => {
6
+ setup(f) {
7
+ const { sideOpen: e } = _(), t = () => {
8
8
  e.value = !e.value;
9
9
  };
10
- return (f, g) => {
11
- const n = c("el-icon");
12
- return i(), m("button", {
10
+ return (g, b) => {
11
+ const l = c("el-icon");
12
+ return i(), r("button", {
13
13
  type: "button",
14
14
  class: "mobile-menu-toggle",
15
+ "aria-label": o(e) ? "Close menu" : "Open menu",
16
+ "aria-expanded": o(e),
15
17
  onClick: t
16
18
  }, [
17
- r("div", u, [
18
- o(n, null, {
19
+ m("div", d, [
20
+ n(l, null, {
19
21
  default: s(() => [
20
- o(_(a))
22
+ n(o(p))
21
23
  ]),
22
24
  _: 1
23
25
  })
24
26
  ])
25
- ]);
27
+ ], 8, u);
26
28
  };
27
29
  }
28
30
  });