@mounaji_npm/saas-template 0.1.1 → 0.1.2
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/mounajisaastemplate.es.js +972 -645
- package/dist/mounajisaastemplate.es.js.map +1 -1
- package/dist/mounajisaastemplate.umd.cjs +39 -4
- package/dist/mounajisaastemplate.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/src/shell/AppShell.jsx +78 -66
- package/src/shell/Sidebar.jsx +684 -264
- package/src/shell/TopNav.jsx +114 -133
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
var
|
|
1
|
+
import je, { createContext as we, useState as B, useCallback as N, useMemo as me, useContext as Ee, useEffect as Y, useRef as O, useLayoutEffect as ae } from "react";
|
|
2
|
+
import { TokensProvider as Se } from "@mounaji_npm/tokens";
|
|
3
|
+
var ee = { exports: {} }, Z = {};
|
|
4
4
|
/**
|
|
5
5
|
* @license React
|
|
6
6
|
* react-jsx-runtime.production.js
|
|
@@ -10,29 +10,29 @@ var C = { exports: {} }, S = {};
|
|
|
10
10
|
* This source code is licensed under the MIT license found in the
|
|
11
11
|
* LICENSE file in the root directory of this source tree.
|
|
12
12
|
*/
|
|
13
|
-
var
|
|
14
|
-
function
|
|
15
|
-
if (
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
function
|
|
19
|
-
var
|
|
20
|
-
if (
|
|
21
|
-
|
|
22
|
-
for (var
|
|
23
|
-
|
|
24
|
-
} else
|
|
25
|
-
return
|
|
26
|
-
$$typeof:
|
|
27
|
-
type:
|
|
28
|
-
key:
|
|
29
|
-
ref:
|
|
30
|
-
props:
|
|
13
|
+
var le;
|
|
14
|
+
function _e() {
|
|
15
|
+
if (le) return Z;
|
|
16
|
+
le = 1;
|
|
17
|
+
var e = Symbol.for("react.transitional.element"), n = Symbol.for("react.fragment");
|
|
18
|
+
function o(s, i, l) {
|
|
19
|
+
var f = null;
|
|
20
|
+
if (l !== void 0 && (f = "" + l), i.key !== void 0 && (f = "" + i.key), "key" in i) {
|
|
21
|
+
l = {};
|
|
22
|
+
for (var a in i)
|
|
23
|
+
a !== "key" && (l[a] = i[a]);
|
|
24
|
+
} else l = i;
|
|
25
|
+
return i = l.ref, {
|
|
26
|
+
$$typeof: e,
|
|
27
|
+
type: s,
|
|
28
|
+
key: f,
|
|
29
|
+
ref: i !== void 0 ? i : null,
|
|
30
|
+
props: l
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
|
-
return
|
|
33
|
+
return Z.Fragment = n, Z.jsx = o, Z.jsxs = o, Z;
|
|
34
34
|
}
|
|
35
|
-
var
|
|
35
|
+
var Q = {};
|
|
36
36
|
/**
|
|
37
37
|
* @license React
|
|
38
38
|
* react-jsx-runtime.development.js
|
|
@@ -42,428 +42,406 @@ var R = {};
|
|
|
42
42
|
* This source code is licensed under the MIT license found in the
|
|
43
43
|
* LICENSE file in the root directory of this source tree.
|
|
44
44
|
*/
|
|
45
|
-
var
|
|
46
|
-
function
|
|
47
|
-
return
|
|
48
|
-
function r
|
|
49
|
-
if (
|
|
50
|
-
if (typeof
|
|
51
|
-
return
|
|
52
|
-
if (typeof
|
|
53
|
-
switch (
|
|
54
|
-
case
|
|
45
|
+
var de;
|
|
46
|
+
function ke() {
|
|
47
|
+
return de || (de = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
48
|
+
function e(r) {
|
|
49
|
+
if (r == null) return null;
|
|
50
|
+
if (typeof r == "function")
|
|
51
|
+
return r.$$typeof === P ? null : r.displayName || r.name || null;
|
|
52
|
+
if (typeof r == "string") return r;
|
|
53
|
+
switch (r) {
|
|
54
|
+
case M:
|
|
55
55
|
return "Fragment";
|
|
56
|
-
case
|
|
56
|
+
case T:
|
|
57
57
|
return "Profiler";
|
|
58
58
|
case j:
|
|
59
59
|
return "StrictMode";
|
|
60
|
-
case
|
|
60
|
+
case k:
|
|
61
61
|
return "Suspense";
|
|
62
|
-
case
|
|
62
|
+
case W:
|
|
63
63
|
return "SuspenseList";
|
|
64
|
-
case
|
|
64
|
+
case X:
|
|
65
65
|
return "Activity";
|
|
66
66
|
}
|
|
67
|
-
if (typeof
|
|
68
|
-
switch (typeof
|
|
67
|
+
if (typeof r == "object")
|
|
68
|
+
switch (typeof r.tag == "number" && console.error(
|
|
69
69
|
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
70
|
-
),
|
|
71
|
-
case d:
|
|
72
|
-
return "Portal";
|
|
70
|
+
), r.$$typeof) {
|
|
73
71
|
case I:
|
|
74
|
-
return
|
|
75
|
-
case
|
|
76
|
-
return
|
|
72
|
+
return "Portal";
|
|
73
|
+
case E:
|
|
74
|
+
return r.displayName || "Context";
|
|
75
|
+
case x:
|
|
76
|
+
return (r._context.displayName || "Context") + ".Consumer";
|
|
77
|
+
case b:
|
|
78
|
+
var c = r.render;
|
|
79
|
+
return r = r.displayName, r || (r = c.displayName || c.name || "", r = r !== "" ? "ForwardRef(" + r + ")" : "ForwardRef"), r;
|
|
80
|
+
case L:
|
|
81
|
+
return c = r.displayName || null, c !== null ? c : e(r.type) || "Memo";
|
|
77
82
|
case F:
|
|
78
|
-
|
|
79
|
-
return e = e.displayName, e || (e = l.displayName || l.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
80
|
-
case B:
|
|
81
|
-
return l = e.displayName || null, l !== null ? l : r(e.type) || "Memo";
|
|
82
|
-
case z:
|
|
83
|
-
l = e._payload, e = e._init;
|
|
83
|
+
c = r._payload, r = r._init;
|
|
84
84
|
try {
|
|
85
|
-
return r(
|
|
85
|
+
return e(r(c));
|
|
86
86
|
} catch {
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
return null;
|
|
90
90
|
}
|
|
91
|
-
function
|
|
92
|
-
return "" +
|
|
91
|
+
function n(r) {
|
|
92
|
+
return "" + r;
|
|
93
93
|
}
|
|
94
|
-
function
|
|
94
|
+
function o(r) {
|
|
95
95
|
try {
|
|
96
|
-
|
|
97
|
-
var
|
|
96
|
+
n(r);
|
|
97
|
+
var c = !1;
|
|
98
98
|
} catch {
|
|
99
|
-
|
|
99
|
+
c = !0;
|
|
100
100
|
}
|
|
101
|
-
if (
|
|
102
|
-
|
|
103
|
-
var
|
|
104
|
-
return
|
|
105
|
-
|
|
101
|
+
if (c) {
|
|
102
|
+
c = console;
|
|
103
|
+
var w = c.error, S = typeof Symbol == "function" && Symbol.toStringTag && r[Symbol.toStringTag] || r.constructor.name || "Object";
|
|
104
|
+
return w.call(
|
|
105
|
+
c,
|
|
106
106
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
107
|
-
|
|
108
|
-
),
|
|
107
|
+
S
|
|
108
|
+
), n(r);
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
-
function
|
|
112
|
-
if (
|
|
113
|
-
if (typeof
|
|
111
|
+
function s(r) {
|
|
112
|
+
if (r === M) return "<>";
|
|
113
|
+
if (typeof r == "object" && r !== null && r.$$typeof === F)
|
|
114
114
|
return "<...>";
|
|
115
115
|
try {
|
|
116
|
-
var
|
|
117
|
-
return
|
|
116
|
+
var c = e(r);
|
|
117
|
+
return c ? "<" + c + ">" : "<...>";
|
|
118
118
|
} catch {
|
|
119
119
|
return "<...>";
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
|
-
function
|
|
123
|
-
var
|
|
124
|
-
return
|
|
122
|
+
function i() {
|
|
123
|
+
var r = $.A;
|
|
124
|
+
return r === null ? null : r.getOwner();
|
|
125
125
|
}
|
|
126
|
-
function
|
|
126
|
+
function l() {
|
|
127
127
|
return Error("react-stack-top-frame");
|
|
128
128
|
}
|
|
129
|
-
function
|
|
130
|
-
if (
|
|
131
|
-
var
|
|
132
|
-
if (
|
|
129
|
+
function f(r) {
|
|
130
|
+
if (z.call(r, "key")) {
|
|
131
|
+
var c = Object.getOwnPropertyDescriptor(r, "key").get;
|
|
132
|
+
if (c && c.isReactWarning) return !1;
|
|
133
133
|
}
|
|
134
|
-
return
|
|
134
|
+
return r.key !== void 0;
|
|
135
135
|
}
|
|
136
|
-
function
|
|
137
|
-
function
|
|
138
|
-
|
|
136
|
+
function a(r, c) {
|
|
137
|
+
function w() {
|
|
138
|
+
m || (m = !0, console.error(
|
|
139
139
|
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
140
|
-
|
|
140
|
+
c
|
|
141
141
|
));
|
|
142
142
|
}
|
|
143
|
-
|
|
144
|
-
get:
|
|
143
|
+
w.isReactWarning = !0, Object.defineProperty(r, "key", {
|
|
144
|
+
get: w,
|
|
145
145
|
configurable: !0
|
|
146
146
|
});
|
|
147
147
|
}
|
|
148
|
-
function
|
|
149
|
-
var
|
|
150
|
-
return
|
|
148
|
+
function h() {
|
|
149
|
+
var r = e(this.type);
|
|
150
|
+
return A[r] || (A[r] = !0, console.error(
|
|
151
151
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
152
|
-
)),
|
|
152
|
+
)), r = this.props.ref, r !== void 0 ? r : null;
|
|
153
153
|
}
|
|
154
|
-
function
|
|
155
|
-
var
|
|
156
|
-
return
|
|
157
|
-
$$typeof:
|
|
158
|
-
type:
|
|
159
|
-
key:
|
|
160
|
-
props:
|
|
161
|
-
_owner:
|
|
162
|
-
}, (
|
|
154
|
+
function d(r, c, w, S, K, te) {
|
|
155
|
+
var _ = w.ref;
|
|
156
|
+
return r = {
|
|
157
|
+
$$typeof: C,
|
|
158
|
+
type: r,
|
|
159
|
+
key: c,
|
|
160
|
+
props: w,
|
|
161
|
+
_owner: S
|
|
162
|
+
}, (_ !== void 0 ? _ : null) !== null ? Object.defineProperty(r, "ref", {
|
|
163
163
|
enumerable: !1,
|
|
164
|
-
get:
|
|
165
|
-
}) : Object.defineProperty(
|
|
164
|
+
get: h
|
|
165
|
+
}) : Object.defineProperty(r, "ref", { enumerable: !1, value: null }), r._store = {}, Object.defineProperty(r._store, "validated", {
|
|
166
166
|
configurable: !1,
|
|
167
167
|
enumerable: !1,
|
|
168
168
|
writable: !0,
|
|
169
169
|
value: 0
|
|
170
|
-
}), Object.defineProperty(
|
|
170
|
+
}), Object.defineProperty(r, "_debugInfo", {
|
|
171
171
|
configurable: !1,
|
|
172
172
|
enumerable: !1,
|
|
173
173
|
writable: !0,
|
|
174
174
|
value: null
|
|
175
|
-
}), Object.defineProperty(
|
|
175
|
+
}), Object.defineProperty(r, "_debugStack", {
|
|
176
176
|
configurable: !1,
|
|
177
177
|
enumerable: !1,
|
|
178
178
|
writable: !0,
|
|
179
|
-
value:
|
|
180
|
-
}), Object.defineProperty(
|
|
179
|
+
value: K
|
|
180
|
+
}), Object.defineProperty(r, "_debugTask", {
|
|
181
181
|
configurable: !1,
|
|
182
182
|
enumerable: !1,
|
|
183
183
|
writable: !0,
|
|
184
|
-
value:
|
|
185
|
-
}), Object.freeze && (Object.freeze(
|
|
184
|
+
value: te
|
|
185
|
+
}), Object.freeze && (Object.freeze(r.props), Object.freeze(r)), r;
|
|
186
186
|
}
|
|
187
|
-
function
|
|
188
|
-
var
|
|
189
|
-
if (
|
|
190
|
-
if (
|
|
191
|
-
if (
|
|
192
|
-
for (
|
|
193
|
-
|
|
194
|
-
Object.freeze && Object.freeze(
|
|
187
|
+
function y(r, c, w, S, K, te) {
|
|
188
|
+
var _ = c.children;
|
|
189
|
+
if (_ !== void 0)
|
|
190
|
+
if (S)
|
|
191
|
+
if (U(_)) {
|
|
192
|
+
for (S = 0; S < _.length; S++)
|
|
193
|
+
u(_[S]);
|
|
194
|
+
Object.freeze && Object.freeze(_);
|
|
195
195
|
} else
|
|
196
196
|
console.error(
|
|
197
197
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
198
198
|
);
|
|
199
|
-
else
|
|
200
|
-
if (
|
|
201
|
-
|
|
202
|
-
var
|
|
203
|
-
return
|
|
199
|
+
else u(_);
|
|
200
|
+
if (z.call(c, "key")) {
|
|
201
|
+
_ = e(r);
|
|
202
|
+
var J = Object.keys(c).filter(function(ve) {
|
|
203
|
+
return ve !== "key";
|
|
204
204
|
});
|
|
205
|
-
|
|
205
|
+
S = 0 < J.length ? "{key: someKey, " + J.join(": ..., ") + ": ...}" : "{key: someKey}", se[_ + S] || (J = 0 < J.length ? "{" + J.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
206
206
|
`A props object containing a "key" prop is being spread into JSX:
|
|
207
207
|
let props = %s;
|
|
208
208
|
<%s {...props} />
|
|
209
209
|
React keys must be passed directly to JSX without using spread:
|
|
210
210
|
let props = %s;
|
|
211
211
|
<%s key={someKey} {...props} />`,
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
),
|
|
212
|
+
S,
|
|
213
|
+
_,
|
|
214
|
+
J,
|
|
215
|
+
_
|
|
216
|
+
), se[_ + S] = !0);
|
|
217
217
|
}
|
|
218
|
-
if (
|
|
219
|
-
|
|
220
|
-
for (var
|
|
221
|
-
|
|
222
|
-
} else
|
|
223
|
-
return
|
|
224
|
-
|
|
225
|
-
typeof
|
|
226
|
-
),
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
218
|
+
if (_ = null, w !== void 0 && (o(w), _ = "" + w), f(c) && (o(c.key), _ = "" + c.key), "key" in c) {
|
|
219
|
+
w = {};
|
|
220
|
+
for (var re in c)
|
|
221
|
+
re !== "key" && (w[re] = c[re]);
|
|
222
|
+
} else w = c;
|
|
223
|
+
return _ && a(
|
|
224
|
+
w,
|
|
225
|
+
typeof r == "function" ? r.displayName || r.name || "Unknown" : r
|
|
226
|
+
), d(
|
|
227
|
+
r,
|
|
228
|
+
_,
|
|
229
|
+
w,
|
|
230
|
+
i(),
|
|
231
|
+
K,
|
|
232
|
+
te
|
|
233
233
|
);
|
|
234
234
|
}
|
|
235
|
-
function
|
|
236
|
-
|
|
235
|
+
function u(r) {
|
|
236
|
+
v(r) ? r._store && (r._store.validated = 1) : typeof r == "object" && r !== null && r.$$typeof === F && (r._payload.status === "fulfilled" ? v(r._payload.value) && r._payload.value._store && (r._payload.value._store.validated = 1) : r._store && (r._store.validated = 1));
|
|
237
237
|
}
|
|
238
|
-
function
|
|
239
|
-
return typeof
|
|
238
|
+
function v(r) {
|
|
239
|
+
return typeof r == "object" && r !== null && r.$$typeof === C;
|
|
240
240
|
}
|
|
241
|
-
var
|
|
241
|
+
var p = je, C = Symbol.for("react.transitional.element"), I = Symbol.for("react.portal"), M = Symbol.for("react.fragment"), j = Symbol.for("react.strict_mode"), T = Symbol.for("react.profiler"), x = Symbol.for("react.consumer"), E = Symbol.for("react.context"), b = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), W = Symbol.for("react.suspense_list"), L = Symbol.for("react.memo"), F = Symbol.for("react.lazy"), X = Symbol.for("react.activity"), P = Symbol.for("react.client.reference"), $ = p.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, z = Object.prototype.hasOwnProperty, U = Array.isArray, H = console.createTask ? console.createTask : function() {
|
|
242
242
|
return null;
|
|
243
243
|
};
|
|
244
|
-
|
|
245
|
-
react_stack_bottom_frame: function(
|
|
246
|
-
return
|
|
244
|
+
p = {
|
|
245
|
+
react_stack_bottom_frame: function(r) {
|
|
246
|
+
return r();
|
|
247
247
|
}
|
|
248
248
|
};
|
|
249
|
-
var
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
)(),
|
|
253
|
-
|
|
254
|
-
var
|
|
255
|
-
return
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
249
|
+
var m, A = {}, q = p.react_stack_bottom_frame.bind(
|
|
250
|
+
p,
|
|
251
|
+
l
|
|
252
|
+
)(), ie = H(s(l)), se = {};
|
|
253
|
+
Q.Fragment = M, Q.jsx = function(r, c, w) {
|
|
254
|
+
var S = 1e4 > $.recentlyCreatedOwnerStacks++;
|
|
255
|
+
return y(
|
|
256
|
+
r,
|
|
257
|
+
c,
|
|
258
|
+
w,
|
|
259
259
|
!1,
|
|
260
|
-
|
|
261
|
-
|
|
260
|
+
S ? Error("react-stack-top-frame") : q,
|
|
261
|
+
S ? H(s(r)) : ie
|
|
262
262
|
);
|
|
263
|
-
},
|
|
264
|
-
var
|
|
265
|
-
return
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
263
|
+
}, Q.jsxs = function(r, c, w) {
|
|
264
|
+
var S = 1e4 > $.recentlyCreatedOwnerStacks++;
|
|
265
|
+
return y(
|
|
266
|
+
r,
|
|
267
|
+
c,
|
|
268
|
+
w,
|
|
269
269
|
!0,
|
|
270
|
-
|
|
271
|
-
|
|
270
|
+
S ? Error("react-stack-top-frame") : q,
|
|
271
|
+
S ? H(s(r)) : ie
|
|
272
272
|
);
|
|
273
273
|
};
|
|
274
|
-
})()),
|
|
274
|
+
})()), Q;
|
|
275
275
|
}
|
|
276
|
-
var
|
|
277
|
-
function
|
|
278
|
-
return
|
|
276
|
+
var ce;
|
|
277
|
+
function Re() {
|
|
278
|
+
return ce || (ce = 1, process.env.NODE_ENV === "production" ? ee.exports = _e() : ee.exports = ke()), ee.exports;
|
|
279
279
|
}
|
|
280
|
-
var
|
|
281
|
-
const
|
|
280
|
+
var t = Re();
|
|
281
|
+
const be = we({
|
|
282
282
|
modules: [],
|
|
283
283
|
register: () => {
|
|
284
284
|
},
|
|
285
285
|
unregister: () => {
|
|
286
286
|
}
|
|
287
287
|
});
|
|
288
|
-
function
|
|
289
|
-
const [
|
|
290
|
-
|
|
291
|
-
}, []),
|
|
292
|
-
|
|
293
|
-
}, []),
|
|
294
|
-
const
|
|
295
|
-
return [...
|
|
296
|
-
}, [
|
|
297
|
-
return /* @__PURE__ */
|
|
288
|
+
function Ce({ children: e, initialModules: n = [] }) {
|
|
289
|
+
const [o, s] = B([]), i = N((a) => {
|
|
290
|
+
s((h) => h.find((y) => y.id === a.id) ? h.map((y) => y.id === a.id ? a : y) : [...h, a]);
|
|
291
|
+
}, []), l = N((a) => {
|
|
292
|
+
s((h) => h.filter((d) => d.id !== a));
|
|
293
|
+
}, []), f = me(() => {
|
|
294
|
+
const a = /* @__PURE__ */ new Map();
|
|
295
|
+
return [...n, ...o].forEach((h) => a.set(h.id, h)), Array.from(a.values());
|
|
296
|
+
}, [n, o]);
|
|
297
|
+
return /* @__PURE__ */ t.jsx(be.Provider, { value: { modules: f, register: i, unregister: l }, children: e });
|
|
298
298
|
}
|
|
299
|
-
function
|
|
300
|
-
return
|
|
299
|
+
function ge() {
|
|
300
|
+
return Ee(be);
|
|
301
301
|
}
|
|
302
|
-
function
|
|
303
|
-
const { register:
|
|
304
|
-
|
|
305
|
-
if (!(!
|
|
306
|
-
return
|
|
307
|
-
}, [
|
|
302
|
+
function Je(e, n = !0) {
|
|
303
|
+
const { register: o, unregister: s } = ge();
|
|
304
|
+
Y(() => {
|
|
305
|
+
if (!(!n || !(e != null && e.id)))
|
|
306
|
+
return o(e), () => s(e.id);
|
|
307
|
+
}, [e == null ? void 0 : e.id, n]);
|
|
308
308
|
}
|
|
309
|
-
function
|
|
310
|
-
const { modules:
|
|
311
|
-
return
|
|
312
|
-
const
|
|
313
|
-
|
|
314
|
-
const
|
|
315
|
-
|
|
316
|
-
}),
|
|
317
|
-
const
|
|
318
|
-
return
|
|
319
|
-
}, [
|
|
309
|
+
function Te() {
|
|
310
|
+
const { modules: e } = ge();
|
|
311
|
+
return me(() => {
|
|
312
|
+
const n = e.filter((i) => !i.hidden), o = /* @__PURE__ */ new Map();
|
|
313
|
+
n.forEach((i) => {
|
|
314
|
+
const l = i.section ?? "__TOP__";
|
|
315
|
+
o.has(l) || o.set(l, []), o.get(l).push(i);
|
|
316
|
+
}), o.forEach((i) => i.sort((l, f) => (l.order ?? 99) - (f.order ?? 99)));
|
|
317
|
+
const s = [];
|
|
318
|
+
return o.has("__TOP__") && s.push({ label: null, items: o.get("__TOP__") }), Array.from(o.entries()).filter(([i]) => i !== "__TOP__").sort(([i], [l]) => i.localeCompare(l)).forEach(([i, l]) => s.push({ label: i, items: l })), s;
|
|
319
|
+
}, [e]);
|
|
320
320
|
}
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
const o = {
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
}
|
|
321
|
+
const D = 3e3, ue = 1024;
|
|
322
|
+
function fe(e, n = "width") {
|
|
323
|
+
const o = {
|
|
324
|
+
fast: { dur: "340ms", ease: "cubic-bezier(0.16, 1, 0.3, 1)" },
|
|
325
|
+
normal: { dur: "380ms", ease: "cubic-bezier(0.16, 1, 0.3, 1)" },
|
|
326
|
+
slow: { dur: "700ms", ease: "cubic-bezier(0.4, 0, 0.2, 1)" }
|
|
327
|
+
}, { dur: s, ease: i } = o[e] ?? o.normal;
|
|
328
|
+
return n.split(",").map((l) => `${l.trim()} ${s} ${i}`).join(", ");
|
|
328
329
|
}
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
330
|
+
function V(e, n, o, s, i) {
|
|
331
|
+
return e ? `var(${n}, ${o})` : `var(${s}, ${i})`;
|
|
332
|
+
}
|
|
333
|
+
const g = {
|
|
334
|
+
navBg: (e) => V(e, "--mn-color-nav-dark", "#07091C", "--mn-color-nav-light", "#E1DAD0"),
|
|
335
|
+
border: (e) => V(e, "--mn-border-dark", "rgba(255,255,255,0.07)", "--mn-border-light", "#C9C2B6"),
|
|
336
|
+
borderMd: (e) => V(e, "--mn-border-md-dark", "rgba(255,255,255,0.13)", "--mn-border-md-light", "#BDB5A8"),
|
|
337
|
+
textPri: (e) => V(e, "--mn-text-primary-dark", "#F0F4FF", "--mn-text-primary-light", "#1C1915"),
|
|
338
|
+
textSec: (e) => V(e, "--mn-text-secondary-dark", "#94A3B8", "--mn-text-secondary-light", "#47413C"),
|
|
339
|
+
textMuted: (e) => V(e, "--mn-text-muted-dark", "#64748B", "--mn-text-muted-light", "#7A7470"),
|
|
340
|
+
activeItemBg: (e) => e ? "rgba(255,255,255,0.08)" : "rgba(59,130,246,0.10)",
|
|
341
|
+
hoverItemBg: (e) => e ? "rgba(255,255,255,0.04)" : "rgba(0,0,0,0.04)",
|
|
342
|
+
bottomBg: (e) => e ? "rgba(0,0,0,0.20)" : "rgba(0,0,0,0.03)",
|
|
343
|
+
userCard: (e) => e ? "rgba(255,255,255,0.04)" : "rgba(0,0,0,0.04)",
|
|
344
|
+
mobileTopBg: (e) => e ? "rgba(0,0,0,0)" : "rgba(255,255,255,0.95)"
|
|
345
|
+
}, Ae = ({ size: e = 16, style: n }) => /* @__PURE__ */ t.jsx("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", style: n, children: /* @__PURE__ */ t.jsx("path", { d: "M15 18l-6-6 6-6" }) }), ye = ({ size: e = 16, style: n }) => /* @__PURE__ */ t.jsx("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", style: n, children: /* @__PURE__ */ t.jsx("path", { d: "M9 18l6-6-6-6" }) }), xe = ({ size: e = 14, style: n }) => /* @__PURE__ */ t.jsx("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", style: n, children: /* @__PURE__ */ t.jsx("path", { d: "M6 9l6 6 6-6" }) }), Me = ({ size: e = 18 }) => /* @__PURE__ */ t.jsxs("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
346
|
+
/* @__PURE__ */ t.jsx("line", { x1: "3", y1: "6", x2: "21", y2: "6" }),
|
|
347
|
+
/* @__PURE__ */ t.jsx("line", { x1: "3", y1: "12", x2: "21", y2: "12" }),
|
|
348
|
+
/* @__PURE__ */ t.jsx("line", { x1: "3", y1: "18", x2: "21", y2: "18" })
|
|
349
|
+
] }), Ie = ({ size: e = 16 }) => /* @__PURE__ */ t.jsxs("svg", { width: e, height: e, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
350
|
+
/* @__PURE__ */ t.jsx("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
|
|
351
|
+
/* @__PURE__ */ t.jsx("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
|
|
352
|
+
] });
|
|
353
|
+
function Be({ onCollapse: e, onExpand: n }) {
|
|
354
|
+
const o = O(null), s = O({ active: !1, startX: 0, startY: 0, moved: !1 });
|
|
355
|
+
Y(() => {
|
|
356
|
+
const a = o.current;
|
|
357
|
+
a && (a.style.opacity = "1", a.style.transform = "");
|
|
346
358
|
}, []);
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
359
|
+
const i = N((a) => {
|
|
360
|
+
const h = a.touches[0];
|
|
361
|
+
s.current = { active: !0, startX: h.clientX, startY: h.clientY, moved: !1 };
|
|
362
|
+
const d = o.current;
|
|
363
|
+
d && (d.style.transition = "box-shadow 0.1s ease", d.style.transform = "scale(1.12)", d.style.boxShadow = "0 0 0 6px rgba(99,102,241,0.2), 0 8px 28px rgba(99,102,241,0.55)");
|
|
364
|
+
}, []), l = N((a) => {
|
|
365
|
+
if (!s.current.active) return;
|
|
366
|
+
const h = a.touches[0], d = h.clientX - s.current.startX, y = h.clientY - s.current.startY;
|
|
367
|
+
(Math.abs(d) > 5 || Math.abs(y) > 5) && (s.current.moved = !0);
|
|
368
|
+
const u = o.current;
|
|
369
|
+
u && (u.style.transition = "none", u.style.transform = `translate(${d * 0.45}px, ${y * 0.45}px) scale(1.1)`);
|
|
370
|
+
}, []), f = N((a) => {
|
|
371
|
+
if (!s.current.active) return;
|
|
372
|
+
const h = a.changedTouches[0], d = h.clientX - s.current.startX, y = h.clientY - s.current.startY;
|
|
373
|
+
s.current.active = !1;
|
|
374
|
+
const u = o.current;
|
|
375
|
+
if (u && (u.style.transition = "transform 0.38s cubic-bezier(0.16,1,0.3,1), box-shadow 0.25s ease", u.style.boxShadow = "0 4px 18px rgba(99,102,241,0.4)"), s.current.moved) {
|
|
376
|
+
const v = Math.abs(d), p = Math.abs(y);
|
|
377
|
+
v >= p * 0.75 && v > 22 ? (u && (u.style.transform = `translateX(${d > 0 ? 24 : -24}px) scale(0.85)`, u.style.opacity = "0"), setTimeout(() => n(), 80)) : p > v && p > 22 ? (u && (u.style.transform = "translateY(-10px) scale(1.06)"), setTimeout(() => {
|
|
378
|
+
u && (u.style.transform = "scale(1) translateY(0)");
|
|
379
|
+
}, 80)) : u && (u.style.transform = "scale(1) translate(0,0)");
|
|
380
|
+
} else
|
|
381
|
+
u && (u.style.transform = "scale(1) translate(0,0)"), e();
|
|
382
|
+
}, [e, n]);
|
|
383
|
+
return /* @__PURE__ */ t.jsx(
|
|
384
|
+
"button",
|
|
353
385
|
{
|
|
386
|
+
ref: o,
|
|
387
|
+
onTouchStart: i,
|
|
388
|
+
onTouchMove: l,
|
|
389
|
+
onTouchEnd: f,
|
|
390
|
+
onClick: e,
|
|
391
|
+
title: "Open sidebar",
|
|
354
392
|
style: {
|
|
355
393
|
position: "fixed",
|
|
356
|
-
top:
|
|
357
|
-
left:
|
|
358
|
-
|
|
359
|
-
width:
|
|
394
|
+
top: 12,
|
|
395
|
+
left: 12,
|
|
396
|
+
zIndex: 50,
|
|
397
|
+
width: 40,
|
|
398
|
+
height: 40,
|
|
399
|
+
borderRadius: "50%",
|
|
360
400
|
display: "flex",
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
401
|
+
alignItems: "center",
|
|
402
|
+
justifyContent: "center",
|
|
403
|
+
background: "linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%)",
|
|
404
|
+
border: "1px solid rgba(139,92,246,0.5)",
|
|
405
|
+
color: "#fff",
|
|
406
|
+
cursor: "pointer",
|
|
407
|
+
touchAction: "none",
|
|
408
|
+
boxShadow: "0 4px 18px rgba(99,102,241,0.4)",
|
|
409
|
+
animation: "mn-fab-appear 0.42s cubic-bezier(0.16,1,0.3,1) both, mn-fab-ring 2.8s ease-in-out 0.6s infinite"
|
|
370
410
|
},
|
|
371
|
-
children:
|
|
372
|
-
/* @__PURE__ */ n.jsxs("div", { style: {
|
|
373
|
-
height: 56,
|
|
374
|
-
display: "flex",
|
|
375
|
-
alignItems: "center",
|
|
376
|
-
justifyContent: t ? "center" : "space-between",
|
|
377
|
-
padding: t ? "0" : "0 12px 0 16px",
|
|
378
|
-
borderBottom: "1px solid var(--mn-border-dark, rgba(255,255,255,0.07))",
|
|
379
|
-
flexShrink: 0,
|
|
380
|
-
gap: 8
|
|
381
|
-
}, children: [
|
|
382
|
-
!t && /* @__PURE__ */ n.jsx("div", { style: { display: "flex", alignItems: "center", gap: 8, minWidth: 0, overflow: "hidden" }, children: r ?? /* @__PURE__ */ n.jsx(we, {}) }),
|
|
383
|
-
/* @__PURE__ */ n.jsx(Re, { collapsed: t, onCollapse: () => i == null ? void 0 : i(!t) })
|
|
384
|
-
] }),
|
|
385
|
-
/* @__PURE__ */ n.jsx("nav", { style: { flex: 1, overflowY: "auto", overflowX: "hidden", padding: "8px 0" }, children: b.map((d) => /* @__PURE__ */ n.jsx(
|
|
386
|
-
Ee,
|
|
387
|
-
{
|
|
388
|
-
section: d,
|
|
389
|
-
collapsed: t,
|
|
390
|
-
isActive: g,
|
|
391
|
-
expandedIds: h,
|
|
392
|
-
onToggle: y,
|
|
393
|
-
onNavigate: s,
|
|
394
|
-
LinkComponent: u
|
|
395
|
-
},
|
|
396
|
-
d.label ?? "__top__"
|
|
397
|
-
)) }),
|
|
398
|
-
o.length > 0 && /* @__PURE__ */ n.jsx("div", { style: {
|
|
399
|
-
borderTop: "1px solid var(--mn-border-dark, rgba(255,255,255,0.07))",
|
|
400
|
-
padding: "8px 0",
|
|
401
|
-
flexShrink: 0
|
|
402
|
-
}, children: o.map((d) => /* @__PURE__ */ n.jsx(
|
|
403
|
-
q,
|
|
404
|
-
{
|
|
405
|
-
item: d,
|
|
406
|
-
collapsed: t,
|
|
407
|
-
active: g(d.path),
|
|
408
|
-
onNavigate: s,
|
|
409
|
-
LinkComponent: u
|
|
410
|
-
},
|
|
411
|
-
d.id
|
|
412
|
-
)) })
|
|
413
|
-
]
|
|
411
|
+
children: /* @__PURE__ */ t.jsx(Me, { size: 18 })
|
|
414
412
|
}
|
|
415
413
|
);
|
|
416
414
|
}
|
|
417
|
-
function
|
|
418
|
-
return /* @__PURE__ */
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
fontWeight: 600,
|
|
423
|
-
letterSpacing: "0.08em",
|
|
415
|
+
function Oe({ label: e, isDark: n }) {
|
|
416
|
+
return /* @__PURE__ */ t.jsxs("div", { style: { padding: "20px 12px 4px", display: "flex", alignItems: "center", gap: 8 }, children: [
|
|
417
|
+
/* @__PURE__ */ t.jsx("span", { className: "mn-text-reveal", style: {
|
|
418
|
+
fontSize: 9,
|
|
419
|
+
fontWeight: 700,
|
|
424
420
|
textTransform: "uppercase",
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
whiteSpace: "nowrap"
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
r.label && o && /* @__PURE__ */ n.jsx("div", { style: { height: 8 } }),
|
|
431
|
-
r.items.map((c) => /* @__PURE__ */ n.jsx(
|
|
432
|
-
q,
|
|
433
|
-
{
|
|
434
|
-
item: c,
|
|
435
|
-
collapsed: o,
|
|
436
|
-
active: t(c.path),
|
|
437
|
-
expanded: i.has(c.id),
|
|
438
|
-
onToggle: () => {
|
|
439
|
-
var f;
|
|
440
|
-
return ((f = c.children) == null ? void 0 : f.length) && a(c.id);
|
|
441
|
-
},
|
|
442
|
-
onNavigate: s,
|
|
443
|
-
LinkComponent: u,
|
|
444
|
-
isActive: t
|
|
445
|
-
},
|
|
446
|
-
c.id
|
|
447
|
-
))
|
|
421
|
+
letterSpacing: "0.15em",
|
|
422
|
+
color: g.textMuted(n),
|
|
423
|
+
whiteSpace: "nowrap"
|
|
424
|
+
}, children: e }),
|
|
425
|
+
/* @__PURE__ */ t.jsx("div", { style: { flex: 1, height: 1, backgroundColor: g.border(n) } })
|
|
448
426
|
] });
|
|
449
427
|
}
|
|
450
|
-
function
|
|
451
|
-
var
|
|
452
|
-
const
|
|
428
|
+
function ne({ item: e, collapsed: n, active: o, expanded: s, onToggle: i, onNavigate: l, onLinkClick: f, LinkComponent: a, isActiveFn: h, isDark: d }) {
|
|
429
|
+
var E;
|
|
430
|
+
const [y, u] = B(!1), v = ((E = e.children) == null ? void 0 : E.length) > 0, p = !!e.disabled, C = {
|
|
453
431
|
display: "flex",
|
|
454
432
|
alignItems: "center",
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
padding:
|
|
459
|
-
margin: "1px 6px",
|
|
460
|
-
width: "calc(100% - 12px)",
|
|
461
|
-
height: 36,
|
|
433
|
+
position: "relative",
|
|
434
|
+
justifyContent: n ? "center" : "flex-start",
|
|
435
|
+
gap: n ? 0 : 10,
|
|
436
|
+
padding: n ? 0 : "0 10px",
|
|
437
|
+
margin: n ? "1px auto" : "1px 6px",
|
|
438
|
+
width: n ? 40 : "calc(100% - 12px)",
|
|
439
|
+
height: n ? 40 : 36,
|
|
462
440
|
borderRadius: "var(--mn-radius-lg, 0.75rem)",
|
|
463
441
|
fontSize: "var(--mn-font-size-sm, 0.875rem)",
|
|
464
|
-
fontWeight: 500,
|
|
465
|
-
cursor:
|
|
466
|
-
opacity:
|
|
442
|
+
fontWeight: o && !v ? 600 : 500,
|
|
443
|
+
cursor: p ? "not-allowed" : "pointer",
|
|
444
|
+
opacity: p ? 0.4 : 1,
|
|
467
445
|
textDecoration: "none",
|
|
468
446
|
border: "none",
|
|
469
447
|
outline: "none",
|
|
@@ -471,445 +449,794 @@ function q({ item: r, collapsed: o, active: t, expanded: i, onToggle: a, onNavig
|
|
|
471
449
|
whiteSpace: "nowrap",
|
|
472
450
|
overflow: "hidden",
|
|
473
451
|
fontFamily: "var(--mn-font-family, inherit)",
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
452
|
+
backgroundColor: o && !v ? g.activeItemBg(d) : y && !p ? g.hoverItemBg(d) : "transparent",
|
|
453
|
+
color: o && !v ? g.textPri(d) : g.textSec(d)
|
|
454
|
+
}, I = o && !v ? "var(--mn-color-primary, #3B82F6)" : g.textMuted(d), M = e.icon ? typeof e.icon == "string" ? /* @__PURE__ */ t.jsx("span", { style: { fontSize: 14, width: 16, textAlign: "center", flexShrink: 0 }, children: e.icon }) : typeof e.icon == "function" ? e.icon({ style: { width: 16, height: 16, color: I, flexShrink: 0 } }) : /* @__PURE__ */ t.jsx("span", { style: { width: 16, height: 16, color: I, flexShrink: 0, display: "flex", alignItems: "center", justifyContent: "center" }, children: e.icon }) : /* @__PURE__ */ t.jsx("span", { style: { width: 16, flexShrink: 0 } }), j = /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
455
|
+
o && !v && /* @__PURE__ */ t.jsx("span", { style: {
|
|
456
|
+
position: "absolute",
|
|
457
|
+
left: 0,
|
|
458
|
+
top: "50%",
|
|
459
|
+
transform: "translateY(-50%)",
|
|
460
|
+
width: 3,
|
|
461
|
+
height: n ? 24 : 20,
|
|
462
|
+
borderRadius: "0 4px 4px 0",
|
|
463
|
+
backgroundColor: "var(--mn-color-primary, #3B82F6)"
|
|
464
|
+
} }),
|
|
465
|
+
M,
|
|
466
|
+
!n && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
467
|
+
/* @__PURE__ */ t.jsx("span", { className: "mn-text-reveal", style: { flex: 1, overflow: "hidden", textOverflow: "ellipsis" }, children: e.label }),
|
|
468
|
+
e.badge && /* @__PURE__ */ t.jsx("span", { className: "mn-text-reveal", style: {
|
|
486
469
|
fontSize: 10,
|
|
487
470
|
fontWeight: 600,
|
|
488
471
|
padding: "1px 6px",
|
|
489
472
|
borderRadius: "var(--mn-radius-full, 9999px)",
|
|
490
|
-
backgroundColor: "rgba(99,102,241,0.
|
|
473
|
+
backgroundColor: "rgba(99,102,241,0.15)",
|
|
491
474
|
color: "var(--mn-color-accent, #8B5CF6)",
|
|
492
|
-
flexShrink: 0
|
|
493
|
-
}, children: r.badge }),
|
|
494
|
-
f && /* @__PURE__ */ n.jsx("span", { style: {
|
|
495
|
-
fontSize: 10,
|
|
496
|
-
color: "var(--mn-text-muted-dark, #64748B)",
|
|
497
475
|
flexShrink: 0,
|
|
498
|
-
|
|
476
|
+
marginLeft: "auto"
|
|
477
|
+
}, children: e.badge }),
|
|
478
|
+
o && !v && /* @__PURE__ */ t.jsx("span", { style: {
|
|
479
|
+
width: 6,
|
|
480
|
+
height: 6,
|
|
481
|
+
borderRadius: "50%",
|
|
482
|
+
flexShrink: 0,
|
|
483
|
+
backgroundColor: "var(--mn-color-primary, #3B82F6)"
|
|
484
|
+
} }),
|
|
485
|
+
v && /* @__PURE__ */ t.jsx(xe, { size: 14, style: {
|
|
486
|
+
flexShrink: 0,
|
|
487
|
+
color: g.textMuted(d),
|
|
488
|
+
transform: s ? "rotate(180deg)" : "none",
|
|
499
489
|
transition: "transform 200ms"
|
|
500
|
-
}
|
|
490
|
+
} })
|
|
501
491
|
] })
|
|
502
|
-
] }),
|
|
503
|
-
if (
|
|
504
|
-
|
|
492
|
+
] }), T = (b) => {
|
|
493
|
+
if (p) {
|
|
494
|
+
b.preventDefault();
|
|
505
495
|
return;
|
|
506
496
|
}
|
|
507
|
-
if (
|
|
508
|
-
|
|
497
|
+
if (v) {
|
|
498
|
+
b.preventDefault(), i == null || i();
|
|
509
499
|
return;
|
|
510
500
|
}
|
|
511
|
-
|
|
512
|
-
},
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
style: h,
|
|
516
|
-
...r.external ? { target: "_blank", rel: "noopener noreferrer" } : {},
|
|
517
|
-
title: o ? r.label : void 0
|
|
501
|
+
f == null || f(), !e.external && l && (b.preventDefault(), l(e.path));
|
|
502
|
+
}, x = {
|
|
503
|
+
onMouseEnter: () => u(!0),
|
|
504
|
+
onMouseLeave: () => u(!1)
|
|
518
505
|
};
|
|
519
|
-
return /* @__PURE__ */
|
|
520
|
-
|
|
521
|
-
f && i && !o && /* @__PURE__ */ n.jsx("div", { style: { paddingLeft: 16, marginBottom: 4 }, children: r.children.map((d) => /* @__PURE__ */ n.jsx(
|
|
522
|
-
q,
|
|
523
|
-
{
|
|
524
|
-
item: { id: d.id ?? d.path, ...d },
|
|
525
|
-
collapsed: !1,
|
|
526
|
-
active: c ? c(d.path) : !1,
|
|
527
|
-
onNavigate: s,
|
|
528
|
-
LinkComponent: u
|
|
529
|
-
},
|
|
530
|
-
d.id ?? d.path
|
|
531
|
-
)) })
|
|
532
|
-
] });
|
|
533
|
-
}
|
|
534
|
-
function Se({ icon: r, active: o }) {
|
|
535
|
-
const t = {
|
|
536
|
-
width: 16,
|
|
537
|
-
height: 16,
|
|
538
|
-
flexShrink: 0,
|
|
539
|
-
color: o ? "var(--mn-color-primary, #3B82F6)" : "inherit"
|
|
540
|
-
};
|
|
541
|
-
return r ? typeof r == "string" ? /* @__PURE__ */ n.jsx("span", { style: { fontSize: 14, width: 16, textAlign: "center" }, children: r }) : typeof r == "function" ? r({ style: t }) : /* @__PURE__ */ n.jsx("span", { style: t, children: r }) : /* @__PURE__ */ n.jsx("span", { style: { width: 16 } });
|
|
542
|
-
}
|
|
543
|
-
function Re({ collapsed: r, onCollapse: o }) {
|
|
544
|
-
return /* @__PURE__ */ n.jsx(
|
|
545
|
-
"button",
|
|
506
|
+
return v ? n ? /* @__PURE__ */ t.jsx(a, { href: e.path, style: C, title: e.label, ...x, children: j }) : /* @__PURE__ */ t.jsxs(
|
|
507
|
+
"div",
|
|
546
508
|
{
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
style: {
|
|
550
|
-
width: 28,
|
|
551
|
-
height: 28,
|
|
552
|
-
borderRadius: "var(--mn-radius-md, 0.5rem)",
|
|
553
|
-
background: "rgba(255,255,255,0.04)",
|
|
554
|
-
border: "1px solid var(--mn-border-dark, rgba(255,255,255,0.07))",
|
|
555
|
-
cursor: "pointer",
|
|
556
|
-
display: "flex",
|
|
557
|
-
alignItems: "center",
|
|
558
|
-
justifyContent: "center",
|
|
559
|
-
color: "var(--mn-text-muted-dark, #64748B)",
|
|
560
|
-
fontSize: 12,
|
|
561
|
-
flexShrink: 0,
|
|
562
|
-
transition: "background-color 150ms"
|
|
563
|
-
},
|
|
564
|
-
children: r ? "›" : "‹"
|
|
565
|
-
}
|
|
566
|
-
);
|
|
567
|
-
}
|
|
568
|
-
function we() {
|
|
569
|
-
return /* @__PURE__ */ n.jsx("div", { style: {
|
|
570
|
-
width: 24,
|
|
571
|
-
height: 24,
|
|
572
|
-
borderRadius: 6,
|
|
573
|
-
background: "var(--mn-color-primary, #3B82F6)",
|
|
574
|
-
display: "flex",
|
|
575
|
-
alignItems: "center",
|
|
576
|
-
justifyContent: "center",
|
|
577
|
-
fontSize: 11,
|
|
578
|
-
fontWeight: 800,
|
|
579
|
-
color: "#fff"
|
|
580
|
-
}, children: "M" });
|
|
581
|
-
}
|
|
582
|
-
function Te(r) {
|
|
583
|
-
if (!r) return {};
|
|
584
|
-
const o = {};
|
|
585
|
-
return Object.entries(r).forEach(([t, i]) => {
|
|
586
|
-
const a = te[t];
|
|
587
|
-
a && (o[a] = i);
|
|
588
|
-
}), o;
|
|
589
|
-
}
|
|
590
|
-
function Ce({
|
|
591
|
-
org: r,
|
|
592
|
-
project: o,
|
|
593
|
-
onOrgClick: t,
|
|
594
|
-
onProjectClick: i,
|
|
595
|
-
onNewProject: a,
|
|
596
|
-
user: s,
|
|
597
|
-
onThemeToggle: u,
|
|
598
|
-
isDark: c = !0,
|
|
599
|
-
leftSlot: f,
|
|
600
|
-
centerSlot: b,
|
|
601
|
-
rightSlot: h,
|
|
602
|
-
onLogout: v,
|
|
603
|
-
tokens: y,
|
|
604
|
-
style: g
|
|
605
|
-
}) {
|
|
606
|
-
return /* @__PURE__ */ n.jsxs(
|
|
607
|
-
"header",
|
|
608
|
-
{
|
|
609
|
-
style: {
|
|
610
|
-
height: 52,
|
|
611
|
-
display: "flex",
|
|
612
|
-
alignItems: "center",
|
|
613
|
-
gap: 12,
|
|
614
|
-
padding: "0 16px",
|
|
615
|
-
backgroundColor: "var(--mn-color-nav-dark, #07091C)",
|
|
616
|
-
borderBottom: "1px solid var(--mn-border-dark, rgba(255,255,255,0.07))",
|
|
617
|
-
backdropFilter: "blur(12px)",
|
|
618
|
-
WebkitBackdropFilter: "blur(12px)",
|
|
619
|
-
position: "sticky",
|
|
620
|
-
top: 0,
|
|
621
|
-
zIndex: 30,
|
|
622
|
-
fontFamily: "var(--mn-font-family, inherit)",
|
|
623
|
-
...Te(y),
|
|
624
|
-
...g
|
|
625
|
-
},
|
|
509
|
+
style: { ...C, cursor: "default", backgroundColor: y ? g.hoverItemBg(d) : "transparent" },
|
|
510
|
+
...x,
|
|
626
511
|
children: [
|
|
627
|
-
/* @__PURE__ */
|
|
628
|
-
|
|
512
|
+
/* @__PURE__ */ t.jsxs(
|
|
513
|
+
a,
|
|
629
514
|
{
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
515
|
+
href: e.path,
|
|
516
|
+
onClick: (b) => {
|
|
517
|
+
f == null || f(), l && (b.preventDefault(), l(e.path));
|
|
518
|
+
},
|
|
519
|
+
style: { display: "flex", alignItems: "center", gap: 10, flex: 1, minWidth: 0, textDecoration: "none", color: "inherit" },
|
|
520
|
+
children: [
|
|
521
|
+
M,
|
|
522
|
+
/* @__PURE__ */ t.jsx("span", { className: "mn-text-reveal", style: { flex: 1, overflow: "hidden", textOverflow: "ellipsis", fontSize: "var(--mn-font-size-sm, 0.875rem)", fontWeight: 500 }, children: e.label })
|
|
523
|
+
]
|
|
635
524
|
}
|
|
636
|
-
)
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
525
|
+
),
|
|
526
|
+
/* @__PURE__ */ t.jsx(
|
|
527
|
+
"button",
|
|
528
|
+
{
|
|
529
|
+
onClick: (b) => {
|
|
530
|
+
b.stopPropagation(), i == null || i();
|
|
531
|
+
},
|
|
532
|
+
style: { background: "none", border: "none", cursor: "pointer", padding: "0 8px 0 0", display: "flex", color: g.textMuted(d) },
|
|
533
|
+
children: /* @__PURE__ */ t.jsx(xe, { size: 14, style: { transform: s ? "rotate(180deg)" : "none", transition: "transform 200ms" } })
|
|
534
|
+
}
|
|
535
|
+
)
|
|
643
536
|
]
|
|
644
537
|
}
|
|
538
|
+
) : p ? /* @__PURE__ */ t.jsx("div", { style: C, "aria-disabled": "true", title: n ? e.label : void 0, ...x, children: j }) : /* @__PURE__ */ t.jsx(
|
|
539
|
+
a,
|
|
540
|
+
{
|
|
541
|
+
href: e.path,
|
|
542
|
+
onClick: T,
|
|
543
|
+
title: n ? e.label : void 0,
|
|
544
|
+
style: C,
|
|
545
|
+
...e.external ? { target: "_blank", rel: "noopener noreferrer" } : {},
|
|
546
|
+
...x,
|
|
547
|
+
children: j
|
|
548
|
+
}
|
|
645
549
|
);
|
|
646
550
|
}
|
|
647
|
-
function
|
|
648
|
-
|
|
649
|
-
|
|
551
|
+
function he({ collapsed: e, isDark: n, sections: o, bottomItems: s, activePath: i, onNavigate: l, onLinkClick: f, LinkComponent: a, logo: h, user: d, onCollapseClick: y, collapseLabel: u, showExpandBtn: v, onExpandClick: p }) {
|
|
552
|
+
var T;
|
|
553
|
+
const [C, I] = B(/* @__PURE__ */ new Set()), M = N((x) => {
|
|
554
|
+
I((E) => {
|
|
555
|
+
const b = new Set(E);
|
|
556
|
+
return b.has(x) ? b.delete(x) : b.add(x), b;
|
|
557
|
+
});
|
|
558
|
+
}, []);
|
|
559
|
+
function j(x) {
|
|
560
|
+
return x ? x === "/" ? i === "/" : i === x || i.startsWith(x + "/") : !1;
|
|
561
|
+
}
|
|
562
|
+
return /* @__PURE__ */ t.jsxs("div", { style: { position: "relative", display: "flex", flexDirection: "column", height: "100%", width: "100%", overflow: "hidden" }, children: [
|
|
563
|
+
!e && /* @__PURE__ */ t.jsx("div", { "aria-hidden": "true", style: {
|
|
564
|
+
position: "absolute",
|
|
565
|
+
top: 0,
|
|
566
|
+
right: 0,
|
|
567
|
+
width: 1,
|
|
568
|
+
height: "100%",
|
|
569
|
+
zIndex: 1,
|
|
570
|
+
pointerEvents: "none",
|
|
571
|
+
background: "linear-gradient(to bottom, transparent 0%, rgba(99,102,241,0) 15%, rgba(99,102,241,0.7) 50%, rgba(99,102,241,0) 85%, transparent 100%)",
|
|
572
|
+
animation: "mn-scan 0.55s cubic-bezier(0.16,1,0.3,1) both"
|
|
573
|
+
} }),
|
|
574
|
+
/* @__PURE__ */ t.jsxs("div", { style: {
|
|
575
|
+
height: 60,
|
|
576
|
+
display: "flex",
|
|
577
|
+
alignItems: "center",
|
|
578
|
+
flexShrink: 0,
|
|
579
|
+
justifyContent: e ? "center" : "space-between",
|
|
580
|
+
padding: e ? "0 14px" : "0 8px 0 16px",
|
|
581
|
+
borderBottom: `1px solid ${g.border(n)}`,
|
|
582
|
+
backgroundColor: n ? "transparent" : "rgba(255,255,255,0.95)"
|
|
583
|
+
}, children: [
|
|
584
|
+
/* @__PURE__ */ t.jsx(a, { href: "/", onClick: f, style: { display: "flex", alignItems: "center", gap: 10, minWidth: 0, textDecoration: "none", overflow: "hidden" }, children: h ?? /* @__PURE__ */ t.jsx(Fe, {}) }),
|
|
585
|
+
!e && y && /* @__PURE__ */ t.jsx(
|
|
586
|
+
"button",
|
|
587
|
+
{
|
|
588
|
+
onClick: y,
|
|
589
|
+
title: u,
|
|
590
|
+
style: { flexShrink: 0, width: 28, height: 28, borderRadius: 8, background: "none", border: "none", cursor: "pointer", display: "flex", alignItems: "center", justifyContent: "center", color: g.textMuted(n) },
|
|
591
|
+
children: /* @__PURE__ */ t.jsx(Ae, { size: 16 })
|
|
592
|
+
}
|
|
593
|
+
)
|
|
594
|
+
] }),
|
|
595
|
+
e && v && /* @__PURE__ */ t.jsx("div", { style: { display: "flex", justifyContent: "center", padding: "8px 0", borderBottom: `1px solid ${g.border(n)}`, flexShrink: 0 }, children: /* @__PURE__ */ t.jsx(
|
|
650
596
|
"button",
|
|
651
597
|
{
|
|
652
|
-
onClick:
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
598
|
+
onClick: p,
|
|
599
|
+
title: "Expand sidebar",
|
|
600
|
+
style: { width: 32, height: 32, borderRadius: 8, background: "none", border: "none", cursor: "pointer", display: "flex", alignItems: "center", justifyContent: "center", color: g.textMuted(n) },
|
|
601
|
+
children: /* @__PURE__ */ t.jsx(ye, { size: 16 })
|
|
602
|
+
}
|
|
603
|
+
) }),
|
|
604
|
+
/* @__PURE__ */ t.jsx("nav", { style: { flex: 1, overflowY: "auto", overflowX: "hidden", padding: "12px 0", scrollbarWidth: "thin" }, children: o.map((x) => /* @__PURE__ */ t.jsxs("div", { style: { marginBottom: 4 }, children: [
|
|
605
|
+
x.label && !e && /* @__PURE__ */ t.jsx(Oe, { label: x.label, isDark: n }),
|
|
606
|
+
x.label && e && /* @__PURE__ */ t.jsx("div", { style: { height: 8 } }),
|
|
607
|
+
/* @__PURE__ */ t.jsx("div", { style: { display: "flex", flexDirection: "column", gap: 2 }, children: x.items.map((E) => {
|
|
608
|
+
var b;
|
|
609
|
+
return /* @__PURE__ */ t.jsxs("div", { children: [
|
|
610
|
+
/* @__PURE__ */ t.jsx(
|
|
611
|
+
ne,
|
|
612
|
+
{
|
|
613
|
+
item: E,
|
|
614
|
+
collapsed: e,
|
|
615
|
+
active: j(E.path),
|
|
616
|
+
expanded: C.has(E.id),
|
|
617
|
+
onToggle: () => {
|
|
618
|
+
var k;
|
|
619
|
+
return ((k = E.children) == null ? void 0 : k.length) && M(E.id);
|
|
620
|
+
},
|
|
621
|
+
onNavigate: l,
|
|
622
|
+
onLinkClick: f,
|
|
623
|
+
LinkComponent: a,
|
|
624
|
+
isActiveFn: j,
|
|
625
|
+
isDark: n
|
|
626
|
+
}
|
|
627
|
+
),
|
|
628
|
+
!e && C.has(E.id) && ((b = E.children) == null ? void 0 : b.length) > 0 && /* @__PURE__ */ t.jsx("div", { style: { marginLeft: 12, paddingLeft: 12, borderLeft: `1px solid ${g.border(n)}`, marginBottom: 4 }, children: E.children.map((k) => /* @__PURE__ */ t.jsx(
|
|
629
|
+
ne,
|
|
630
|
+
{
|
|
631
|
+
item: { id: k.id ?? k.path, ...k },
|
|
632
|
+
collapsed: !1,
|
|
633
|
+
active: j(k.path),
|
|
634
|
+
onNavigate: l,
|
|
635
|
+
onLinkClick: f,
|
|
636
|
+
LinkComponent: a,
|
|
637
|
+
isDark: n
|
|
638
|
+
},
|
|
639
|
+
k.id ?? k.path
|
|
640
|
+
)) })
|
|
641
|
+
] }, E.id);
|
|
642
|
+
}) })
|
|
643
|
+
] }, x.label ?? "__top__")) }),
|
|
644
|
+
s.length > 0 && /* @__PURE__ */ t.jsxs("div", { style: { flexShrink: 0, borderTop: `1px solid ${g.border(n)}`, padding: "8px 0", backgroundColor: g.bottomBg(n) }, children: [
|
|
645
|
+
/* @__PURE__ */ t.jsx("div", { style: { display: "flex", flexDirection: "column", gap: 2 }, children: s.map((x) => /* @__PURE__ */ t.jsx(
|
|
646
|
+
ne,
|
|
647
|
+
{
|
|
648
|
+
item: x,
|
|
649
|
+
collapsed: e,
|
|
650
|
+
active: i === x.path || i.startsWith(x.path + "/"),
|
|
651
|
+
onNavigate: l,
|
|
652
|
+
onLinkClick: f,
|
|
653
|
+
LinkComponent: a,
|
|
654
|
+
isDark: n
|
|
655
|
+
},
|
|
656
|
+
x.id
|
|
657
|
+
)) }),
|
|
658
|
+
d && !e && /* @__PURE__ */ t.jsxs("div", { style: { margin: "8px 8px 0", padding: "10px 12px", borderRadius: "var(--mn-radius-lg, 0.75rem)", backgroundColor: g.userCard(n), border: `1px solid ${g.border(n)}`, display: "flex", alignItems: "center", gap: 10 }, children: [
|
|
659
|
+
/* @__PURE__ */ t.jsx("div", { style: { width: 28, height: 28, borderRadius: 8, background: "linear-gradient(135deg, #3B82F6, #7C3AED)", display: "flex", alignItems: "center", justifyContent: "center", color: "#fff", fontSize: 11, fontWeight: 700, flexShrink: 0 }, children: (d.name || d.email || "U")[0].toUpperCase() }),
|
|
660
|
+
/* @__PURE__ */ t.jsxs("div", { style: { minWidth: 0, flex: 1 }, children: [
|
|
661
|
+
/* @__PURE__ */ t.jsx("p", { className: "mn-text-reveal", style: { margin: 0, fontSize: 12, fontWeight: 600, color: g.textPri(n), overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", lineHeight: 1.2 }, children: d.name || ((T = d.email) == null ? void 0 : T.split("@")[0]) }),
|
|
662
|
+
d.email && /* @__PURE__ */ t.jsx("p", { className: "mn-text-reveal", style: { margin: 0, fontSize: 10, color: g.textMuted(n), overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", lineHeight: 1.2 }, children: d.email })
|
|
663
|
+
] })
|
|
664
|
+
] }),
|
|
665
|
+
d && e && /* @__PURE__ */ t.jsx("div", { style: { marginTop: 8, display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ t.jsx("div", { title: d.name || d.email, style: { width: 32, height: 32, borderRadius: 8, background: "linear-gradient(135deg, #3B82F6, #7C3AED)", display: "flex", alignItems: "center", justifyContent: "center", color: "#fff", fontSize: 11, fontWeight: 700 }, children: (d.name || d.email || "U")[0].toUpperCase() }) })
|
|
666
|
+
] })
|
|
667
|
+
] });
|
|
668
|
+
}
|
|
669
|
+
function Fe() {
|
|
670
|
+
return /* @__PURE__ */ t.jsx("div", { style: { width: 28, height: 28, borderRadius: 8, background: "linear-gradient(135deg, #3B82F6, #7C3AED)", display: "flex", alignItems: "center", justifyContent: "center", fontSize: 12, fontWeight: 800, color: "#fff", flexShrink: 0 }, children: "M" });
|
|
671
|
+
}
|
|
672
|
+
function Pe({
|
|
673
|
+
logo: e,
|
|
674
|
+
bottomItems: n = [],
|
|
675
|
+
collapsed: o = !1,
|
|
676
|
+
onCollapse: s,
|
|
677
|
+
activePath: i = "/",
|
|
678
|
+
onNavigate: l,
|
|
679
|
+
LinkComponent: f = "a",
|
|
680
|
+
isDark: a = !0,
|
|
681
|
+
user: h,
|
|
682
|
+
style: d
|
|
683
|
+
}) {
|
|
684
|
+
const y = Te(), [u, v] = B(
|
|
685
|
+
() => typeof window < "u" ? window.innerWidth < ue : !1
|
|
686
|
+
);
|
|
687
|
+
Y(() => {
|
|
688
|
+
const m = window.matchMedia(`(max-width: ${ue - 1}px)`), A = (q) => v(q.matches);
|
|
689
|
+
return m.addEventListener("change", A), () => m.removeEventListener("change", A);
|
|
690
|
+
}, []);
|
|
691
|
+
const [p, C] = B("hidden"), [I, M] = B("normal");
|
|
692
|
+
function j(m, A = "normal") {
|
|
693
|
+
M(A), C(m);
|
|
694
|
+
}
|
|
695
|
+
const T = p === "hidden", x = p === "collapsed", E = p === "expanded", b = p === "fading", k = O(null), W = O(null), L = O(null), F = O(null);
|
|
696
|
+
ae(() => {
|
|
697
|
+
const m = fe(I, "width, transform");
|
|
698
|
+
k.current && (k.current.style.transition = m), W.current && (W.current.style.transition = m);
|
|
699
|
+
}, [I]);
|
|
700
|
+
const X = O(o);
|
|
701
|
+
Y(() => {
|
|
702
|
+
const m = X.current;
|
|
703
|
+
X.current = o;
|
|
704
|
+
const A = L.current;
|
|
705
|
+
if (A) {
|
|
706
|
+
if (!o) {
|
|
707
|
+
A.style.animation = "";
|
|
708
|
+
return;
|
|
709
|
+
}
|
|
710
|
+
m === !1 && (A.style.animation = "mn-content-dip 570ms ease-in-out both");
|
|
711
|
+
}
|
|
712
|
+
}, [o]);
|
|
713
|
+
const P = O(null), $ = O(p), z = N(() => {
|
|
714
|
+
const m = F.current;
|
|
715
|
+
m && (m.style.transition = "none", m.style.opacity = "1", m.offsetHeight, m.style.transition = `opacity ${D}ms ease-in`, m.style.opacity = "0", clearTimeout(P.current), P.current = setTimeout(() => j("hidden", "fast"), D));
|
|
716
|
+
}, []), U = N(() => {
|
|
717
|
+
clearTimeout(P.current);
|
|
718
|
+
const m = F.current;
|
|
719
|
+
m && (m.style.transition = "opacity 300ms ease-out", m.style.opacity = "1");
|
|
720
|
+
}, []);
|
|
721
|
+
Y(() => {
|
|
722
|
+
const m = $.current;
|
|
723
|
+
if ($.current = p, p === "collapsed") {
|
|
724
|
+
const q = setTimeout(z, m === "expanded" ? 50 : 0);
|
|
725
|
+
return () => {
|
|
726
|
+
clearTimeout(q), clearTimeout(P.current);
|
|
727
|
+
};
|
|
728
|
+
}
|
|
729
|
+
return U(), () => clearTimeout(P.current);
|
|
730
|
+
}, [p, z, U]), ae(() => {
|
|
731
|
+
if (!b) return;
|
|
732
|
+
const m = W.current;
|
|
733
|
+
if (!m) return;
|
|
734
|
+
m.style.animation = `mn-mobile-fade-out ${D}ms ease-in both`;
|
|
735
|
+
const A = setTimeout(() => j("hidden", "fast"), D);
|
|
736
|
+
return () => {
|
|
737
|
+
clearTimeout(A), m.style.animation = "", m.style.transition = fe("fast", "width, transform");
|
|
738
|
+
};
|
|
739
|
+
}, [b]);
|
|
740
|
+
const H = {
|
|
741
|
+
isDark: a,
|
|
742
|
+
sections: y,
|
|
743
|
+
bottomItems: n,
|
|
744
|
+
activePath: i,
|
|
745
|
+
onNavigate: l,
|
|
746
|
+
LinkComponent: f,
|
|
747
|
+
logo: e,
|
|
748
|
+
user: h
|
|
749
|
+
};
|
|
750
|
+
return /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
751
|
+
u && T && /* @__PURE__ */ t.jsx(
|
|
752
|
+
Be,
|
|
753
|
+
{
|
|
754
|
+
onCollapse: () => j("collapsed", "fast"),
|
|
755
|
+
onExpand: () => j("expanded", "fast")
|
|
658
756
|
}
|
|
659
757
|
),
|
|
660
|
-
|
|
661
|
-
o ? /* @__PURE__ */ n.jsxs("button", { onClick: i, style: Y, children: [
|
|
662
|
-
/* @__PURE__ */ n.jsx("span", { style: { fontSize: 12 }, children: "📁" }),
|
|
663
|
-
/* @__PURE__ */ n.jsx("span", { style: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" }, children: o.name })
|
|
664
|
-
] }) : a && /* @__PURE__ */ n.jsx(
|
|
758
|
+
u && !T && !b && /* @__PURE__ */ t.jsx(
|
|
665
759
|
"button",
|
|
666
760
|
{
|
|
667
|
-
onClick:
|
|
668
|
-
|
|
669
|
-
|
|
761
|
+
onClick: () => {
|
|
762
|
+
j(x ? "expanded" : "hidden", "fast");
|
|
763
|
+
},
|
|
764
|
+
title: x ? "Expand sidebar" : "Hide sidebar",
|
|
765
|
+
style: {
|
|
766
|
+
position: "fixed",
|
|
767
|
+
top: 14,
|
|
768
|
+
left: 16,
|
|
769
|
+
zIndex: 50,
|
|
770
|
+
width: 36,
|
|
771
|
+
height: 36,
|
|
772
|
+
borderRadius: 10,
|
|
773
|
+
display: "flex",
|
|
774
|
+
alignItems: "center",
|
|
775
|
+
justifyContent: "center",
|
|
776
|
+
backgroundColor: a ? "#060919" : "#fff",
|
|
777
|
+
border: `1px solid ${g.border(a)}`,
|
|
778
|
+
boxShadow: "0 2px 8px rgba(0,0,0,0.15)",
|
|
779
|
+
cursor: "pointer",
|
|
780
|
+
color: g.textSec(a)
|
|
781
|
+
},
|
|
782
|
+
children: x ? /* @__PURE__ */ t.jsx(ye, { size: 18 }) : /* @__PURE__ */ t.jsx(Ie, { size: 16 })
|
|
783
|
+
}
|
|
784
|
+
),
|
|
785
|
+
u && (E || b) && /* @__PURE__ */ t.jsx(
|
|
786
|
+
"div",
|
|
787
|
+
{
|
|
788
|
+
onClick: b ? void 0 : () => j("collapsed", "fast"),
|
|
789
|
+
style: {
|
|
790
|
+
position: "fixed",
|
|
791
|
+
inset: 0,
|
|
792
|
+
zIndex: 40,
|
|
793
|
+
backgroundColor: "rgba(0,0,0,0.6)",
|
|
794
|
+
backdropFilter: "blur(4px)",
|
|
795
|
+
animation: b ? `mn-backdrop-out ${D}ms ease-in forwards` : "mn-backdrop-in 0.22s ease both",
|
|
796
|
+
pointerEvents: b ? "none" : void 0
|
|
797
|
+
}
|
|
670
798
|
}
|
|
671
|
-
)
|
|
799
|
+
),
|
|
800
|
+
u && /* @__PURE__ */ t.jsx(
|
|
801
|
+
"aside",
|
|
802
|
+
{
|
|
803
|
+
ref: W,
|
|
804
|
+
onTouchStart: () => {
|
|
805
|
+
x && z(), b && j("expanded", "fast");
|
|
806
|
+
},
|
|
807
|
+
onClick: () => {
|
|
808
|
+
b && j("expanded", "fast");
|
|
809
|
+
},
|
|
810
|
+
style: {
|
|
811
|
+
position: "fixed",
|
|
812
|
+
top: 0,
|
|
813
|
+
left: 0,
|
|
814
|
+
zIndex: 40,
|
|
815
|
+
height: "100vh",
|
|
816
|
+
overflow: "hidden",
|
|
817
|
+
backgroundColor: g.navBg(a),
|
|
818
|
+
borderRight: `1px solid ${g.border(a)}`,
|
|
819
|
+
boxShadow: "0 0 40px rgba(0,0,0,0.3)",
|
|
820
|
+
width: T || x ? 60 : 288,
|
|
821
|
+
transform: T ? "translateX(-100%)" : "translateX(0)"
|
|
822
|
+
},
|
|
823
|
+
children: /* @__PURE__ */ t.jsx("div", { ref: F, style: { display: "flex", flexDirection: "column", height: "100%", width: "100%" }, children: /* @__PURE__ */ t.jsx(
|
|
824
|
+
he,
|
|
825
|
+
{
|
|
826
|
+
...H,
|
|
827
|
+
collapsed: x || T,
|
|
828
|
+
onLinkClick: () => j("collapsed", "fast"),
|
|
829
|
+
onCollapseClick: () => j("collapsed", "fast"),
|
|
830
|
+
collapseLabel: "Minimize sidebar"
|
|
831
|
+
}
|
|
832
|
+
) })
|
|
833
|
+
}
|
|
834
|
+
),
|
|
835
|
+
!u && /* @__PURE__ */ t.jsx(
|
|
836
|
+
"aside",
|
|
837
|
+
{
|
|
838
|
+
ref: k,
|
|
839
|
+
style: {
|
|
840
|
+
position: "fixed",
|
|
841
|
+
top: 0,
|
|
842
|
+
left: 0,
|
|
843
|
+
zIndex: 30,
|
|
844
|
+
height: "100vh",
|
|
845
|
+
overflow: "hidden",
|
|
846
|
+
display: "flex",
|
|
847
|
+
flexDirection: "column",
|
|
848
|
+
backgroundColor: g.navBg(a),
|
|
849
|
+
borderRight: `1px solid ${g.border(a)}`,
|
|
850
|
+
backdropFilter: "blur(20px)",
|
|
851
|
+
boxShadow: a ? "1px 0 0 0 rgba(255,255,255,0.04)" : "1px 0 0 0 rgba(0,0,0,0.04)",
|
|
852
|
+
width: o ? 60 : 220,
|
|
853
|
+
fontFamily: "var(--mn-font-family, inherit)",
|
|
854
|
+
...d
|
|
855
|
+
},
|
|
856
|
+
children: /* @__PURE__ */ t.jsx("div", { ref: L, style: { display: "flex", flexDirection: "column", height: "100%", width: "100%" }, children: /* @__PURE__ */ t.jsx(
|
|
857
|
+
he,
|
|
858
|
+
{
|
|
859
|
+
...H,
|
|
860
|
+
collapsed: o,
|
|
861
|
+
onCollapseClick: () => s == null ? void 0 : s(!o),
|
|
862
|
+
collapseLabel: "Collapse sidebar",
|
|
863
|
+
showExpandBtn: o,
|
|
864
|
+
onExpandClick: () => s == null ? void 0 : s(!1)
|
|
865
|
+
}
|
|
866
|
+
) })
|
|
867
|
+
}
|
|
868
|
+
),
|
|
869
|
+
/* @__PURE__ */ t.jsx("style", { children: `
|
|
870
|
+
.mn-text-reveal {
|
|
871
|
+
animation: mn-text-in 0.28s cubic-bezier(0.16,1,0.3,1) both;
|
|
872
|
+
}
|
|
873
|
+
@keyframes mn-text-in {
|
|
874
|
+
0% { opacity: 0; filter: blur(5px); transform: translateX(-10px); }
|
|
875
|
+
55% { filter: blur(1px); }
|
|
876
|
+
100% { opacity: 1; filter: blur(0); transform: translateX(0); }
|
|
877
|
+
}
|
|
878
|
+
@keyframes mn-scan {
|
|
879
|
+
0% { transform: translateY(-100%); opacity: 0; }
|
|
880
|
+
15% { opacity: 1; }
|
|
881
|
+
85% { opacity: 1; }
|
|
882
|
+
100% { transform: translateY(100%); opacity: 0; }
|
|
883
|
+
}
|
|
884
|
+
@keyframes mn-fab-appear {
|
|
885
|
+
0% { opacity: 0; transform: scale(0.5); filter: blur(4px); }
|
|
886
|
+
60% { filter: blur(0); }
|
|
887
|
+
100% { opacity: 1; transform: scale(1); filter: blur(0); }
|
|
888
|
+
}
|
|
889
|
+
@keyframes mn-fab-ring {
|
|
890
|
+
0%, 100% { box-shadow: 0 0 0 0 rgba(99,102,241,0.5), 0 4px 18px rgba(99,102,241,0.4); }
|
|
891
|
+
55% { box-shadow: 0 0 0 10px rgba(99,102,241,0), 0 4px 18px rgba(99,102,241,0.4); }
|
|
892
|
+
}
|
|
893
|
+
@keyframes mn-backdrop-in { from { opacity: 0; } to { opacity: 1; } }
|
|
894
|
+
@keyframes mn-backdrop-out { from { opacity: 1; } to { opacity: 0; } }
|
|
895
|
+
@keyframes mn-content-dip {
|
|
896
|
+
0% { opacity: 1; }
|
|
897
|
+
55% { opacity: 0; }
|
|
898
|
+
100% { opacity: 1; }
|
|
899
|
+
}
|
|
900
|
+
@keyframes mn-mobile-fade-out {
|
|
901
|
+
from { opacity: 1; transform: translateX(0); }
|
|
902
|
+
to { opacity: 0; transform: translateX(-100%); }
|
|
903
|
+
}
|
|
904
|
+
` })
|
|
672
905
|
] });
|
|
673
906
|
}
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
maxWidth: 160,
|
|
687
|
-
fontFamily: "inherit",
|
|
688
|
-
transition: "background-color 150ms"
|
|
907
|
+
function G(e, n, o, s, i) {
|
|
908
|
+
return e ? `var(${n}, ${o})` : `var(${s}, ${i})`;
|
|
909
|
+
}
|
|
910
|
+
const R = {
|
|
911
|
+
navBg: (e) => G(e, "--mn-color-nav-dark", "#07091C", "--mn-color-nav-light", "#E1DAD0"),
|
|
912
|
+
border: (e) => G(e, "--mn-border-dark", "rgba(255,255,255,0.07)", "--mn-border-light", "#C9C2B6"),
|
|
913
|
+
cardBg: (e) => G(e, "--mn-color-card-dark", "#0B0F23", "--mn-color-card-light", "#EDE8DE"),
|
|
914
|
+
textPri: (e) => G(e, "--mn-text-primary-dark", "#F0F4FF", "--mn-text-primary-light", "#1C1915"),
|
|
915
|
+
textSec: (e) => G(e, "--mn-text-secondary-dark", "#94A3B8", "--mn-text-secondary-light", "#47413C"),
|
|
916
|
+
textMuted: (e) => G(e, "--mn-text-muted-dark", "#64748B", "--mn-text-muted-light", "#7A7470"),
|
|
917
|
+
iconBg: (e) => e ? "rgba(255,255,255,0.04)" : "rgba(0,0,0,0.04)",
|
|
918
|
+
menuHover: (e) => e ? "rgba(255,255,255,0.05)" : "rgba(0,0,0,0.04)"
|
|
689
919
|
};
|
|
690
|
-
function
|
|
691
|
-
|
|
920
|
+
function $e({
|
|
921
|
+
org: e,
|
|
922
|
+
project: n,
|
|
923
|
+
onOrgClick: o,
|
|
924
|
+
onProjectClick: s,
|
|
925
|
+
onNewProject: i,
|
|
926
|
+
user: l,
|
|
927
|
+
onLogout: f,
|
|
928
|
+
isDark: a = !0,
|
|
929
|
+
onThemeToggle: h,
|
|
930
|
+
leftSlot: d,
|
|
931
|
+
centerSlot: y,
|
|
932
|
+
rightSlot: u,
|
|
933
|
+
style: v
|
|
934
|
+
}) {
|
|
935
|
+
return /* @__PURE__ */ t.jsxs("header", { style: {
|
|
936
|
+
height: 52,
|
|
937
|
+
display: "flex",
|
|
938
|
+
alignItems: "center",
|
|
939
|
+
gap: 12,
|
|
940
|
+
padding: "0 16px",
|
|
941
|
+
backgroundColor: R.navBg(a),
|
|
942
|
+
borderBottom: `1px solid ${R.border(a)}`,
|
|
943
|
+
backdropFilter: "blur(12px)",
|
|
944
|
+
WebkitBackdropFilter: "blur(12px)",
|
|
945
|
+
position: "sticky",
|
|
946
|
+
top: 0,
|
|
947
|
+
zIndex: 30,
|
|
948
|
+
fontFamily: "var(--mn-font-family, inherit)",
|
|
949
|
+
transition: "background-color 300ms, border-color 300ms",
|
|
950
|
+
...v
|
|
951
|
+
}, children: [
|
|
952
|
+
/* @__PURE__ */ t.jsx("div", { style: { flex: 1, display: "flex", alignItems: "center", gap: 6, minWidth: 0 }, children: d ?? /* @__PURE__ */ t.jsx(
|
|
953
|
+
ze,
|
|
954
|
+
{
|
|
955
|
+
org: e,
|
|
956
|
+
project: n,
|
|
957
|
+
onOrgClick: o,
|
|
958
|
+
onProjectClick: s,
|
|
959
|
+
onNewProject: i,
|
|
960
|
+
isDark: a
|
|
961
|
+
}
|
|
962
|
+
) }),
|
|
963
|
+
y && /* @__PURE__ */ t.jsx("div", { style: { flexShrink: 0 }, children: y }),
|
|
964
|
+
/* @__PURE__ */ t.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 8, flexShrink: 0 }, children: [
|
|
965
|
+
h && /* @__PURE__ */ t.jsx(Ye, { onClick: h, title: a ? "Light mode" : "Dark mode", isDark: a, children: /* @__PURE__ */ t.jsx("span", { style: { fontSize: 15 }, children: a ? "☀" : "☾" }) }),
|
|
966
|
+
u,
|
|
967
|
+
l && /* @__PURE__ */ t.jsx(We, { user: l, onLogout: f, isDark: a })
|
|
968
|
+
] })
|
|
969
|
+
] });
|
|
692
970
|
}
|
|
693
|
-
function
|
|
694
|
-
|
|
695
|
-
const
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
971
|
+
function ze({ org: e, project: n, onOrgClick: o, onProjectClick: s, onNewProject: i, isDark: l }) {
|
|
972
|
+
if (!e && !n) return null;
|
|
973
|
+
const f = {
|
|
974
|
+
display: "inline-flex",
|
|
975
|
+
alignItems: "center",
|
|
976
|
+
gap: 6,
|
|
977
|
+
padding: "4px 8px",
|
|
978
|
+
borderRadius: "var(--mn-radius-md, 0.5rem)",
|
|
979
|
+
background: "none",
|
|
980
|
+
border: "none",
|
|
981
|
+
color: R.textSec(l),
|
|
982
|
+
fontSize: "var(--mn-font-size-sm, 0.875rem)",
|
|
983
|
+
fontWeight: 500,
|
|
984
|
+
cursor: "pointer",
|
|
985
|
+
maxWidth: 160,
|
|
986
|
+
fontFamily: "inherit",
|
|
987
|
+
transition: "background-color 150ms",
|
|
988
|
+
whiteSpace: "nowrap",
|
|
989
|
+
overflow: "hidden",
|
|
990
|
+
textOverflow: "ellipsis"
|
|
991
|
+
};
|
|
992
|
+
return /* @__PURE__ */ t.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 4, minWidth: 0 }, children: [
|
|
993
|
+
e && /* @__PURE__ */ t.jsxs("button", { onClick: o, style: f, children: [
|
|
994
|
+
/* @__PURE__ */ t.jsx("span", { style: { width: 8, height: 8, borderRadius: "50%", backgroundColor: "var(--mn-color-accent, #8B5CF6)", flexShrink: 0, display: "inline-block" } }),
|
|
995
|
+
/* @__PURE__ */ t.jsx("span", { style: { overflow: "hidden", textOverflow: "ellipsis" }, children: e.name })
|
|
996
|
+
] }),
|
|
997
|
+
e && n && /* @__PURE__ */ t.jsx("span", { style: { color: R.textMuted(l), fontSize: 14 }, children: "/" }),
|
|
998
|
+
n ? /* @__PURE__ */ t.jsxs("button", { onClick: s, style: f, children: [
|
|
999
|
+
/* @__PURE__ */ t.jsx("span", { style: { fontSize: 12 }, children: "📁" }),
|
|
1000
|
+
/* @__PURE__ */ t.jsx("span", { style: { overflow: "hidden", textOverflow: "ellipsis" }, children: n.name })
|
|
1001
|
+
] }) : i && /* @__PURE__ */ t.jsx("button", { onClick: i, style: { ...f, color: "var(--mn-color-primary, #3B82F6)", opacity: 0.7 }, children: "+ New Project" })
|
|
1002
|
+
] });
|
|
1003
|
+
}
|
|
1004
|
+
function We({ user: e, onLogout: n, isDark: o }) {
|
|
1005
|
+
var f;
|
|
1006
|
+
const [s, i] = B(!1), l = O(null);
|
|
1007
|
+
return Y(() => {
|
|
1008
|
+
if (!s) return;
|
|
1009
|
+
function a(h) {
|
|
1010
|
+
l.current && !l.current.contains(h.target) && i(!1);
|
|
700
1011
|
}
|
|
701
|
-
return document.addEventListener("mousedown",
|
|
702
|
-
}, [
|
|
703
|
-
/* @__PURE__ */
|
|
1012
|
+
return document.addEventListener("mousedown", a), () => document.removeEventListener("mousedown", a);
|
|
1013
|
+
}, [s]), /* @__PURE__ */ t.jsxs("div", { ref: l, style: { position: "relative" }, children: [
|
|
1014
|
+
/* @__PURE__ */ t.jsxs(
|
|
704
1015
|
"button",
|
|
705
1016
|
{
|
|
706
|
-
onClick: () => i((
|
|
1017
|
+
onClick: () => i((a) => !a),
|
|
707
1018
|
style: {
|
|
708
1019
|
display: "flex",
|
|
709
1020
|
alignItems: "center",
|
|
710
1021
|
gap: 6,
|
|
711
|
-
padding: "4px
|
|
1022
|
+
padding: "4px 8px",
|
|
712
1023
|
borderRadius: "var(--mn-radius-md, 0.5rem)",
|
|
713
|
-
background: "none",
|
|
1024
|
+
background: s ? R.iconBg(o) : "none",
|
|
714
1025
|
border: "none",
|
|
715
1026
|
cursor: "pointer",
|
|
716
|
-
color:
|
|
717
|
-
fontFamily: "inherit"
|
|
1027
|
+
color: R.textSec(o),
|
|
1028
|
+
fontFamily: "inherit",
|
|
1029
|
+
transition: "background-color 150ms"
|
|
718
1030
|
},
|
|
719
1031
|
children: [
|
|
720
|
-
/* @__PURE__ */
|
|
721
|
-
/* @__PURE__ */
|
|
722
|
-
/* @__PURE__ */
|
|
1032
|
+
/* @__PURE__ */ t.jsx(Ne, { user: e, size: 26 }),
|
|
1033
|
+
/* @__PURE__ */ t.jsx("span", { style: { fontSize: "var(--mn-font-size-sm, 0.875rem)", fontWeight: 500 }, children: ((f = e.name) == null ? void 0 : f.split(" ")[0]) ?? "Account" }),
|
|
1034
|
+
/* @__PURE__ */ t.jsx("span", { style: { fontSize: 10, color: R.textMuted(o) }, children: "▾" })
|
|
723
1035
|
]
|
|
724
1036
|
}
|
|
725
1037
|
),
|
|
726
|
-
|
|
1038
|
+
s && /* @__PURE__ */ t.jsxs("div", { style: {
|
|
727
1039
|
position: "absolute",
|
|
728
|
-
top: "100%",
|
|
1040
|
+
top: "calc(100% + 6px)",
|
|
729
1041
|
right: 0,
|
|
730
|
-
|
|
731
|
-
width: 200,
|
|
1042
|
+
width: 210,
|
|
732
1043
|
borderRadius: "var(--mn-radius-lg, 0.75rem)",
|
|
733
|
-
backgroundColor:
|
|
734
|
-
border:
|
|
1044
|
+
backgroundColor: R.cardBg(o),
|
|
1045
|
+
border: `1px solid ${R.border(o)}`,
|
|
735
1046
|
boxShadow: "var(--mn-shadow-lg, 0 4px 30px rgba(0,0,0,0.4))",
|
|
736
1047
|
zIndex: 100,
|
|
737
1048
|
overflow: "hidden"
|
|
738
1049
|
}, children: [
|
|
739
|
-
/* @__PURE__ */
|
|
740
|
-
/* @__PURE__ */
|
|
741
|
-
|
|
1050
|
+
/* @__PURE__ */ t.jsxs("div", { style: { padding: "12px 14px", borderBottom: `1px solid ${R.border(o)}` }, children: [
|
|
1051
|
+
/* @__PURE__ */ t.jsx("p", { style: { margin: 0, fontSize: "0.8125rem", fontWeight: 600, color: R.textPri(o) }, children: e.name }),
|
|
1052
|
+
e.email && /* @__PURE__ */ t.jsx("p", { style: { margin: "2px 0 0", fontSize: 11, color: R.textMuted(o) }, children: e.email })
|
|
742
1053
|
] }),
|
|
743
|
-
/* @__PURE__ */
|
|
744
|
-
/* @__PURE__ */
|
|
745
|
-
/* @__PURE__ */
|
|
746
|
-
|
|
747
|
-
/* @__PURE__ */
|
|
748
|
-
/* @__PURE__ */
|
|
749
|
-
i(!1),
|
|
750
|
-
}, danger: !0, children: "Log out" })
|
|
1054
|
+
/* @__PURE__ */ t.jsxs("div", { style: { padding: "6px 0" }, children: [
|
|
1055
|
+
/* @__PURE__ */ t.jsx(oe, { onClick: () => i(!1), isDark: o, children: "Profile settings" }),
|
|
1056
|
+
/* @__PURE__ */ t.jsx(oe, { onClick: () => i(!1), isDark: o, children: "API Keys" }),
|
|
1057
|
+
n && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1058
|
+
/* @__PURE__ */ t.jsx("div", { style: { height: 1, backgroundColor: R.border(o), margin: "6px 0" } }),
|
|
1059
|
+
/* @__PURE__ */ t.jsx(oe, { onClick: () => {
|
|
1060
|
+
i(!1), n();
|
|
1061
|
+
}, isDark: o, danger: !0, children: "Log out" })
|
|
751
1062
|
] })
|
|
752
1063
|
] })
|
|
753
1064
|
] })
|
|
754
1065
|
] });
|
|
755
1066
|
}
|
|
756
|
-
function
|
|
757
|
-
|
|
1067
|
+
function oe({ children: e, onClick: n, isDark: o, danger: s }) {
|
|
1068
|
+
const [i, l] = B(!1);
|
|
1069
|
+
return /* @__PURE__ */ t.jsx(
|
|
758
1070
|
"button",
|
|
759
1071
|
{
|
|
760
|
-
onClick:
|
|
1072
|
+
onClick: n,
|
|
1073
|
+
onMouseEnter: () => l(!0),
|
|
1074
|
+
onMouseLeave: () => l(!1),
|
|
761
1075
|
style: {
|
|
762
1076
|
display: "block",
|
|
763
1077
|
width: "100%",
|
|
764
1078
|
textAlign: "left",
|
|
765
1079
|
padding: "8px 14px",
|
|
766
|
-
background: "none",
|
|
1080
|
+
background: i ? R.menuHover(o) : "none",
|
|
767
1081
|
border: "none",
|
|
768
1082
|
fontSize: "var(--mn-font-size-sm, 0.875rem)",
|
|
769
|
-
color:
|
|
1083
|
+
color: s ? "var(--mn-color-danger, #EF4444)" : R.textSec(o),
|
|
770
1084
|
cursor: "pointer",
|
|
771
1085
|
fontFamily: "inherit",
|
|
772
1086
|
transition: "background-color 100ms"
|
|
773
1087
|
},
|
|
774
|
-
children:
|
|
1088
|
+
children: e
|
|
775
1089
|
}
|
|
776
1090
|
);
|
|
777
1091
|
}
|
|
778
|
-
function
|
|
779
|
-
const
|
|
780
|
-
return /* @__PURE__ */
|
|
781
|
-
width:
|
|
782
|
-
height:
|
|
1092
|
+
function Ne({ user: e, size: n = 28 }) {
|
|
1093
|
+
const o = (e.name ?? e.email ?? "?").split(" ").slice(0, 2).map((s) => s[0]).join("").toUpperCase();
|
|
1094
|
+
return /* @__PURE__ */ t.jsx("div", { style: {
|
|
1095
|
+
width: n,
|
|
1096
|
+
height: n,
|
|
783
1097
|
borderRadius: "50%",
|
|
784
|
-
|
|
1098
|
+
background: e.avatar ? `url(${e.avatar}) center/cover` : "linear-gradient(135deg, #6366f1, #8b5cf6)",
|
|
785
1099
|
display: "flex",
|
|
786
1100
|
alignItems: "center",
|
|
787
1101
|
justifyContent: "center",
|
|
788
|
-
fontSize:
|
|
1102
|
+
fontSize: n * 0.38,
|
|
789
1103
|
fontWeight: 700,
|
|
790
1104
|
color: "#fff",
|
|
791
1105
|
flexShrink: 0,
|
|
792
|
-
backgroundImage: r.avatar ? `url(${r.avatar})` : "none",
|
|
793
|
-
backgroundSize: "cover",
|
|
794
1106
|
overflow: "hidden"
|
|
795
|
-
}, children: !
|
|
1107
|
+
}, children: !e.avatar && o });
|
|
796
1108
|
}
|
|
797
|
-
function
|
|
798
|
-
|
|
1109
|
+
function Ye({ children: e, onClick: n, title: o, isDark: s }) {
|
|
1110
|
+
const [i, l] = B(!1);
|
|
1111
|
+
return /* @__PURE__ */ t.jsx(
|
|
799
1112
|
"button",
|
|
800
1113
|
{
|
|
801
|
-
onClick:
|
|
802
|
-
title:
|
|
1114
|
+
onClick: n,
|
|
1115
|
+
title: o,
|
|
1116
|
+
onMouseEnter: () => l(!0),
|
|
1117
|
+
onMouseLeave: () => l(!1),
|
|
803
1118
|
style: {
|
|
804
1119
|
width: 32,
|
|
805
1120
|
height: 32,
|
|
806
1121
|
borderRadius: "var(--mn-radius-md, 0.5rem)",
|
|
807
|
-
background:
|
|
808
|
-
border:
|
|
1122
|
+
background: i ? R.iconBg(s) : "transparent",
|
|
1123
|
+
border: `1px solid ${R.border(s)}`,
|
|
809
1124
|
cursor: "pointer",
|
|
810
1125
|
display: "flex",
|
|
811
1126
|
alignItems: "center",
|
|
812
1127
|
justifyContent: "center",
|
|
813
|
-
color:
|
|
814
|
-
fontSize: 14,
|
|
1128
|
+
color: R.textSec(s),
|
|
815
1129
|
transition: "background-color 150ms"
|
|
816
1130
|
},
|
|
817
|
-
children:
|
|
1131
|
+
children: e
|
|
818
1132
|
}
|
|
819
1133
|
);
|
|
820
1134
|
}
|
|
821
|
-
const
|
|
822
|
-
function
|
|
1135
|
+
const Le = 220, Xe = 60, pe = 1024;
|
|
1136
|
+
function Ve({
|
|
823
1137
|
// Nav
|
|
824
|
-
modules:
|
|
825
|
-
bottomModules:
|
|
826
|
-
activePath:
|
|
827
|
-
onNavigate:
|
|
828
|
-
LinkComponent:
|
|
829
|
-
logo:
|
|
1138
|
+
modules: e = [],
|
|
1139
|
+
bottomModules: n = Ue,
|
|
1140
|
+
activePath: o = "/",
|
|
1141
|
+
onNavigate: s,
|
|
1142
|
+
LinkComponent: i = "a",
|
|
1143
|
+
logo: l,
|
|
830
1144
|
// TopNav
|
|
831
|
-
org:
|
|
832
|
-
project:
|
|
833
|
-
onOrgClick:
|
|
834
|
-
onProjectClick:
|
|
835
|
-
onNewProject:
|
|
836
|
-
user:
|
|
837
|
-
onLogout:
|
|
838
|
-
isDark:
|
|
839
|
-
onThemeToggle:
|
|
840
|
-
topNavLeft:
|
|
841
|
-
topNavCenter:
|
|
1145
|
+
org: f,
|
|
1146
|
+
project: a,
|
|
1147
|
+
onOrgClick: h,
|
|
1148
|
+
onProjectClick: d,
|
|
1149
|
+
onNewProject: y,
|
|
1150
|
+
user: u,
|
|
1151
|
+
onLogout: v,
|
|
1152
|
+
isDark: p = !0,
|
|
1153
|
+
onThemeToggle: C,
|
|
1154
|
+
topNavLeft: I,
|
|
1155
|
+
topNavCenter: M,
|
|
842
1156
|
topNavRight: j,
|
|
843
1157
|
// Tokens
|
|
844
|
-
tokens:
|
|
845
|
-
tokenPersist:
|
|
846
|
-
tokenStorageKey:
|
|
1158
|
+
tokens: T,
|
|
1159
|
+
tokenPersist: x = !0,
|
|
1160
|
+
tokenStorageKey: E = "mn_design_tokens",
|
|
847
1161
|
// Content
|
|
848
|
-
children:
|
|
1162
|
+
children: b
|
|
849
1163
|
}) {
|
|
850
|
-
const [
|
|
851
|
-
|
|
852
|
-
|
|
1164
|
+
const [k, W] = B(!1), [L, F] = B(
|
|
1165
|
+
() => typeof window < "u" ? window.innerWidth < pe : !1
|
|
1166
|
+
);
|
|
1167
|
+
Y(() => {
|
|
1168
|
+
const $ = window.matchMedia(`(max-width: ${pe - 1}px)`), z = (U) => F(U.matches);
|
|
1169
|
+
return $.addEventListener("change", z), () => $.removeEventListener("change", z);
|
|
1170
|
+
}, []);
|
|
1171
|
+
const X = L ? 0 : k ? Xe : Le, P = p ? "var(--mn-color-bg-dark, #060919)" : "var(--mn-color-bg-light, #E5DED2)";
|
|
1172
|
+
return /* @__PURE__ */ t.jsx(Se, { initialTokens: T, persist: x, storageKey: E, children: /* @__PURE__ */ t.jsx(Ce, { initialModules: e, children: /* @__PURE__ */ t.jsxs(
|
|
1173
|
+
"div",
|
|
853
1174
|
{
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
1175
|
+
"data-mn-theme": p ? "dark" : "light",
|
|
1176
|
+
style: {
|
|
1177
|
+
display: "flex",
|
|
1178
|
+
minHeight: "100vh",
|
|
1179
|
+
backgroundColor: P,
|
|
1180
|
+
fontFamily: "var(--mn-font-family, system-ui, sans-serif)"
|
|
1181
|
+
},
|
|
1182
|
+
children: [
|
|
1183
|
+
/* @__PURE__ */ t.jsx(
|
|
1184
|
+
Pe,
|
|
860
1185
|
{
|
|
861
|
-
logo:
|
|
862
|
-
bottomItems:
|
|
863
|
-
collapsed:
|
|
864
|
-
onCollapse:
|
|
865
|
-
activePath:
|
|
866
|
-
onNavigate:
|
|
867
|
-
LinkComponent:
|
|
1186
|
+
logo: l,
|
|
1187
|
+
bottomItems: n,
|
|
1188
|
+
collapsed: k,
|
|
1189
|
+
onCollapse: W,
|
|
1190
|
+
activePath: o,
|
|
1191
|
+
onNavigate: s,
|
|
1192
|
+
LinkComponent: i,
|
|
1193
|
+
isDark: p,
|
|
1194
|
+
user: u
|
|
868
1195
|
}
|
|
869
1196
|
),
|
|
870
|
-
/* @__PURE__ */
|
|
1197
|
+
/* @__PURE__ */ t.jsxs("div", { style: {
|
|
871
1198
|
flex: 1,
|
|
872
|
-
marginLeft:
|
|
1199
|
+
marginLeft: X,
|
|
873
1200
|
transition: "margin-left 340ms cubic-bezier(0.16,1,0.3,1)",
|
|
874
1201
|
display: "flex",
|
|
875
1202
|
flexDirection: "column",
|
|
876
1203
|
minWidth: 0
|
|
877
1204
|
}, children: [
|
|
878
|
-
/* @__PURE__ */
|
|
879
|
-
|
|
1205
|
+
/* @__PURE__ */ t.jsx(
|
|
1206
|
+
$e,
|
|
880
1207
|
{
|
|
881
|
-
org:
|
|
882
|
-
project:
|
|
883
|
-
onOrgClick:
|
|
884
|
-
onProjectClick:
|
|
885
|
-
onNewProject:
|
|
886
|
-
user:
|
|
887
|
-
onLogout:
|
|
888
|
-
isDark:
|
|
889
|
-
onThemeToggle:
|
|
890
|
-
leftSlot:
|
|
891
|
-
centerSlot:
|
|
1208
|
+
org: f,
|
|
1209
|
+
project: a,
|
|
1210
|
+
onOrgClick: h,
|
|
1211
|
+
onProjectClick: d,
|
|
1212
|
+
onNewProject: y,
|
|
1213
|
+
user: u,
|
|
1214
|
+
onLogout: v,
|
|
1215
|
+
isDark: p,
|
|
1216
|
+
onThemeToggle: C,
|
|
1217
|
+
leftSlot: I,
|
|
1218
|
+
centerSlot: M,
|
|
892
1219
|
rightSlot: j
|
|
893
1220
|
}
|
|
894
1221
|
),
|
|
895
|
-
/* @__PURE__ */
|
|
1222
|
+
/* @__PURE__ */ t.jsx("main", { style: { flex: 1, minHeight: 0 }, children: b })
|
|
896
1223
|
] })
|
|
897
|
-
]
|
|
1224
|
+
]
|
|
898
1225
|
}
|
|
899
|
-
);
|
|
1226
|
+
) }) });
|
|
900
1227
|
}
|
|
901
|
-
const
|
|
1228
|
+
const Ue = [
|
|
902
1229
|
{ id: "settings", label: "Settings", icon: "⚙", path: "/settings", order: 1 },
|
|
903
1230
|
{ id: "help", label: "Help", icon: "?", path: "/help", order: 2 }
|
|
904
1231
|
];
|
|
905
1232
|
export {
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
1233
|
+
Ve as AppShell,
|
|
1234
|
+
Ue as DEFAULT_BOTTOM_MODULES,
|
|
1235
|
+
Ce as ModuleRegistryProvider,
|
|
1236
|
+
Pe as Sidebar,
|
|
1237
|
+
$e as TopNav,
|
|
1238
|
+
ge as useModuleRegistry,
|
|
1239
|
+
Te as useNavTree,
|
|
1240
|
+
Je as useRegisterModule
|
|
914
1241
|
};
|
|
915
1242
|
//# sourceMappingURL=mounajisaastemplate.es.js.map
|