@hari_digitus/sms-ui-library 7.0.2 → 7.0.4
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/SideNavBar.cjs.js +10 -10
- package/dist/SideNavBar.es.js +344 -330
- package/package.json +1 -1
package/dist/SideNavBar.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import We, { createContext as pr, useState as
|
|
2
|
-
var
|
|
1
|
+
import We, { createContext as pr, useState as V, useContext as vr, useEffect as hr } from "react";
|
|
2
|
+
var ce = { exports: {} }, Q = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
5
|
* react-jsx-runtime.production.min.js
|
|
@@ -11,19 +11,19 @@ var oe = { exports: {} }, q = {};
|
|
|
11
11
|
*/
|
|
12
12
|
var Fe;
|
|
13
13
|
function mr() {
|
|
14
|
-
if (Fe) return
|
|
14
|
+
if (Fe) return Q;
|
|
15
15
|
Fe = 1;
|
|
16
|
-
var w = We, O = Symbol.for("react.element"),
|
|
17
|
-
function N(
|
|
18
|
-
var
|
|
19
|
-
I !== void 0 && (S = "" + I),
|
|
20
|
-
for (
|
|
21
|
-
if (
|
|
22
|
-
return { $$typeof: O, type:
|
|
16
|
+
var w = We, O = Symbol.for("react.element"), h = Symbol.for("react.fragment"), C = Object.prototype.hasOwnProperty, k = w.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, P = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
17
|
+
function N(m, d, I) {
|
|
18
|
+
var x, E = {}, S = null, W = null;
|
|
19
|
+
I !== void 0 && (S = "" + I), d.key !== void 0 && (S = "" + d.key), d.ref !== void 0 && (W = d.ref);
|
|
20
|
+
for (x in d) C.call(d, x) && !P.hasOwnProperty(x) && (E[x] = d[x]);
|
|
21
|
+
if (m && m.defaultProps) for (x in d = m.defaultProps, d) E[x] === void 0 && (E[x] = d[x]);
|
|
22
|
+
return { $$typeof: O, type: m, key: S, ref: W, props: E, _owner: k.current };
|
|
23
23
|
}
|
|
24
|
-
return
|
|
24
|
+
return Q.Fragment = h, Q.jsx = N, Q.jsxs = N, Q;
|
|
25
25
|
}
|
|
26
|
-
var
|
|
26
|
+
var ee = {};
|
|
27
27
|
/**
|
|
28
28
|
* @license React
|
|
29
29
|
* react-jsx-runtime.development.js
|
|
@@ -33,91 +33,91 @@ var H = {};
|
|
|
33
33
|
* This source code is licensed under the MIT license found in the
|
|
34
34
|
* LICENSE file in the root directory of this source tree.
|
|
35
35
|
*/
|
|
36
|
-
var
|
|
36
|
+
var $e;
|
|
37
37
|
function xr() {
|
|
38
|
-
return
|
|
39
|
-
var w = We, O = Symbol.for("react.element"),
|
|
40
|
-
function
|
|
38
|
+
return $e || ($e = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
39
|
+
var w = We, O = Symbol.for("react.element"), h = Symbol.for("react.portal"), C = Symbol.for("react.fragment"), k = Symbol.for("react.strict_mode"), P = Symbol.for("react.profiler"), N = Symbol.for("react.provider"), m = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), I = Symbol.for("react.suspense"), x = Symbol.for("react.suspense_list"), E = Symbol.for("react.memo"), S = Symbol.for("react.lazy"), W = Symbol.for("react.offscreen"), y = Symbol.iterator, re = "@@iterator";
|
|
40
|
+
function Y(e) {
|
|
41
41
|
if (e === null || typeof e != "object")
|
|
42
42
|
return null;
|
|
43
|
-
var r =
|
|
43
|
+
var r = y && e[y] || e[re];
|
|
44
44
|
return typeof r == "function" ? r : null;
|
|
45
45
|
}
|
|
46
|
-
var
|
|
47
|
-
function
|
|
46
|
+
var L = w.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
47
|
+
function p(e) {
|
|
48
48
|
{
|
|
49
49
|
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++)
|
|
50
50
|
t[a - 1] = arguments[a];
|
|
51
|
-
|
|
51
|
+
fe("error", e, t);
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
|
-
function
|
|
54
|
+
function fe(e, r, t) {
|
|
55
55
|
{
|
|
56
|
-
var a =
|
|
57
|
-
|
|
58
|
-
var
|
|
59
|
-
return String(
|
|
56
|
+
var a = L.ReactDebugCurrentFrame, s = a.getStackAddendum();
|
|
57
|
+
s !== "" && (r += "%s", t = t.concat([s]));
|
|
58
|
+
var u = t.map(function(o) {
|
|
59
|
+
return String(o);
|
|
60
60
|
});
|
|
61
|
-
|
|
61
|
+
u.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, u);
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
|
-
var
|
|
65
|
-
|
|
66
|
-
function
|
|
67
|
-
return !!(typeof e == "string" || typeof e == "function" || e === C || e ===
|
|
64
|
+
var de = !1, ne = !1, pe = !1, te = !1, ae = !1, F;
|
|
65
|
+
F = Symbol.for("react.module.reference");
|
|
66
|
+
function J(e) {
|
|
67
|
+
return !!(typeof e == "string" || typeof e == "function" || e === C || e === P || ae || e === k || e === I || e === x || te || e === W || de || ne || pe || typeof e == "object" && e !== null && (e.$$typeof === S || e.$$typeof === E || e.$$typeof === N || e.$$typeof === m || e.$$typeof === d || // This needs to include all possible module reference object
|
|
68
68
|
// types supported by any Flight configuration anywhere since
|
|
69
69
|
// we don't know which Flight build this will end up being used
|
|
70
70
|
// with.
|
|
71
|
-
e.$$typeof ===
|
|
71
|
+
e.$$typeof === F || e.getModuleId !== void 0));
|
|
72
72
|
}
|
|
73
|
-
function
|
|
73
|
+
function ie(e, r, t) {
|
|
74
74
|
var a = e.displayName;
|
|
75
75
|
if (a)
|
|
76
76
|
return a;
|
|
77
|
-
var
|
|
78
|
-
return
|
|
77
|
+
var s = r.displayName || r.name || "";
|
|
78
|
+
return s !== "" ? t + "(" + s + ")" : t;
|
|
79
79
|
}
|
|
80
|
-
function
|
|
80
|
+
function q(e) {
|
|
81
81
|
return e.displayName || "Context";
|
|
82
82
|
}
|
|
83
83
|
function T(e) {
|
|
84
84
|
if (e == null)
|
|
85
85
|
return null;
|
|
86
|
-
if (typeof e.tag == "number" &&
|
|
86
|
+
if (typeof e.tag == "number" && p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
|
|
87
87
|
return e.displayName || e.name || null;
|
|
88
88
|
if (typeof e == "string")
|
|
89
89
|
return e;
|
|
90
90
|
switch (e) {
|
|
91
91
|
case C:
|
|
92
92
|
return "Fragment";
|
|
93
|
-
case
|
|
93
|
+
case h:
|
|
94
94
|
return "Portal";
|
|
95
|
-
case k:
|
|
96
|
-
return "Profiler";
|
|
97
95
|
case P:
|
|
96
|
+
return "Profiler";
|
|
97
|
+
case k:
|
|
98
98
|
return "StrictMode";
|
|
99
99
|
case I:
|
|
100
100
|
return "Suspense";
|
|
101
|
-
case
|
|
101
|
+
case x:
|
|
102
102
|
return "SuspenseList";
|
|
103
103
|
}
|
|
104
104
|
if (typeof e == "object")
|
|
105
105
|
switch (e.$$typeof) {
|
|
106
|
-
case
|
|
106
|
+
case m:
|
|
107
107
|
var r = e;
|
|
108
|
-
return
|
|
108
|
+
return q(r) + ".Consumer";
|
|
109
109
|
case N:
|
|
110
110
|
var t = e;
|
|
111
|
-
return
|
|
112
|
-
case
|
|
113
|
-
return
|
|
114
|
-
case
|
|
111
|
+
return q(t._context) + ".Provider";
|
|
112
|
+
case d:
|
|
113
|
+
return ie(e, e.render, "ForwardRef");
|
|
114
|
+
case E:
|
|
115
115
|
var a = e.displayName || null;
|
|
116
116
|
return a !== null ? a : T(e.type) || "Memo";
|
|
117
117
|
case S: {
|
|
118
|
-
var
|
|
118
|
+
var s = e, u = s._payload, o = s._init;
|
|
119
119
|
try {
|
|
120
|
-
return T(
|
|
120
|
+
return T(o(u));
|
|
121
121
|
} catch {
|
|
122
122
|
return null;
|
|
123
123
|
}
|
|
@@ -125,18 +125,18 @@ function xr() {
|
|
|
125
125
|
}
|
|
126
126
|
return null;
|
|
127
127
|
}
|
|
128
|
-
var
|
|
129
|
-
function
|
|
128
|
+
var D = Object.assign, $ = 0, v, _, A, l, H, K, G;
|
|
129
|
+
function z() {
|
|
130
130
|
}
|
|
131
|
-
|
|
132
|
-
function
|
|
131
|
+
z.__reactDisabledLog = !0;
|
|
132
|
+
function g() {
|
|
133
133
|
{
|
|
134
|
-
if (
|
|
135
|
-
|
|
134
|
+
if ($ === 0) {
|
|
135
|
+
v = console.log, _ = console.info, A = console.warn, l = console.error, H = console.group, K = console.groupCollapsed, G = console.groupEnd;
|
|
136
136
|
var e = {
|
|
137
137
|
configurable: !0,
|
|
138
138
|
enumerable: !0,
|
|
139
|
-
value:
|
|
139
|
+
value: z,
|
|
140
140
|
writable: !0
|
|
141
141
|
};
|
|
142
142
|
Object.defineProperties(console, {
|
|
@@ -149,199 +149,199 @@ function xr() {
|
|
|
149
149
|
groupEnd: e
|
|
150
150
|
});
|
|
151
151
|
}
|
|
152
|
-
|
|
152
|
+
$++;
|
|
153
153
|
}
|
|
154
154
|
}
|
|
155
|
-
function
|
|
155
|
+
function ve() {
|
|
156
156
|
{
|
|
157
|
-
if (
|
|
157
|
+
if ($--, $ === 0) {
|
|
158
158
|
var e = {
|
|
159
159
|
configurable: !0,
|
|
160
160
|
enumerable: !0,
|
|
161
161
|
writable: !0
|
|
162
162
|
};
|
|
163
163
|
Object.defineProperties(console, {
|
|
164
|
-
log:
|
|
165
|
-
value:
|
|
164
|
+
log: D({}, e, {
|
|
165
|
+
value: v
|
|
166
166
|
}),
|
|
167
|
-
info:
|
|
168
|
-
value:
|
|
167
|
+
info: D({}, e, {
|
|
168
|
+
value: _
|
|
169
169
|
}),
|
|
170
|
-
warn:
|
|
171
|
-
value:
|
|
170
|
+
warn: D({}, e, {
|
|
171
|
+
value: A
|
|
172
172
|
}),
|
|
173
|
-
error:
|
|
174
|
-
value:
|
|
173
|
+
error: D({}, e, {
|
|
174
|
+
value: l
|
|
175
175
|
}),
|
|
176
|
-
group:
|
|
177
|
-
value:
|
|
176
|
+
group: D({}, e, {
|
|
177
|
+
value: H
|
|
178
178
|
}),
|
|
179
|
-
groupCollapsed:
|
|
180
|
-
value:
|
|
179
|
+
groupCollapsed: D({}, e, {
|
|
180
|
+
value: K
|
|
181
181
|
}),
|
|
182
|
-
groupEnd:
|
|
183
|
-
value:
|
|
182
|
+
groupEnd: D({}, e, {
|
|
183
|
+
value: G
|
|
184
184
|
})
|
|
185
185
|
});
|
|
186
186
|
}
|
|
187
|
-
|
|
187
|
+
$ < 0 && p("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
|
-
var
|
|
191
|
-
function
|
|
190
|
+
var X = L.ReactCurrentDispatcher, he;
|
|
191
|
+
function oe(e, r, t) {
|
|
192
192
|
{
|
|
193
|
-
if (
|
|
193
|
+
if (he === void 0)
|
|
194
194
|
try {
|
|
195
195
|
throw Error();
|
|
196
|
-
} catch (
|
|
197
|
-
var a =
|
|
198
|
-
|
|
196
|
+
} catch (s) {
|
|
197
|
+
var a = s.stack.trim().match(/\n( *(at )?)/);
|
|
198
|
+
he = a && a[1] || "";
|
|
199
199
|
}
|
|
200
200
|
return `
|
|
201
|
-
` +
|
|
201
|
+
` + he + e;
|
|
202
202
|
}
|
|
203
203
|
}
|
|
204
|
-
var
|
|
204
|
+
var me = !1, se;
|
|
205
205
|
{
|
|
206
|
-
var
|
|
207
|
-
|
|
206
|
+
var Be = typeof WeakMap == "function" ? WeakMap : Map;
|
|
207
|
+
se = new Be();
|
|
208
208
|
}
|
|
209
|
-
function
|
|
210
|
-
if (!e ||
|
|
209
|
+
function Ee(e, r) {
|
|
210
|
+
if (!e || me)
|
|
211
211
|
return "";
|
|
212
212
|
{
|
|
213
|
-
var t =
|
|
213
|
+
var t = se.get(e);
|
|
214
214
|
if (t !== void 0)
|
|
215
215
|
return t;
|
|
216
216
|
}
|
|
217
217
|
var a;
|
|
218
|
-
|
|
219
|
-
var
|
|
218
|
+
me = !0;
|
|
219
|
+
var s = Error.prepareStackTrace;
|
|
220
220
|
Error.prepareStackTrace = void 0;
|
|
221
|
-
var
|
|
222
|
-
|
|
221
|
+
var u;
|
|
222
|
+
u = X.current, X.current = null, g();
|
|
223
223
|
try {
|
|
224
224
|
if (r) {
|
|
225
|
-
var
|
|
225
|
+
var o = function() {
|
|
226
226
|
throw Error();
|
|
227
227
|
};
|
|
228
|
-
if (Object.defineProperty(
|
|
228
|
+
if (Object.defineProperty(o.prototype, "props", {
|
|
229
229
|
set: function() {
|
|
230
230
|
throw Error();
|
|
231
231
|
}
|
|
232
232
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
233
233
|
try {
|
|
234
|
-
Reflect.construct(
|
|
235
|
-
} catch (
|
|
236
|
-
a =
|
|
234
|
+
Reflect.construct(o, []);
|
|
235
|
+
} catch (j) {
|
|
236
|
+
a = j;
|
|
237
237
|
}
|
|
238
|
-
Reflect.construct(e, [],
|
|
238
|
+
Reflect.construct(e, [], o);
|
|
239
239
|
} else {
|
|
240
240
|
try {
|
|
241
|
-
|
|
242
|
-
} catch (
|
|
243
|
-
a =
|
|
241
|
+
o.call();
|
|
242
|
+
} catch (j) {
|
|
243
|
+
a = j;
|
|
244
244
|
}
|
|
245
|
-
e.call(
|
|
245
|
+
e.call(o.prototype);
|
|
246
246
|
}
|
|
247
247
|
} else {
|
|
248
248
|
try {
|
|
249
249
|
throw Error();
|
|
250
|
-
} catch (
|
|
251
|
-
a =
|
|
250
|
+
} catch (j) {
|
|
251
|
+
a = j;
|
|
252
252
|
}
|
|
253
253
|
e();
|
|
254
254
|
}
|
|
255
|
-
} catch (
|
|
256
|
-
if (
|
|
257
|
-
for (var i =
|
|
255
|
+
} catch (j) {
|
|
256
|
+
if (j && a && typeof j.stack == "string") {
|
|
257
|
+
for (var i = j.stack.split(`
|
|
258
258
|
`), b = a.stack.split(`
|
|
259
|
-
`),
|
|
260
|
-
|
|
261
|
-
for (;
|
|
262
|
-
if (i[
|
|
263
|
-
if (
|
|
259
|
+
`), c = i.length - 1, f = b.length - 1; c >= 1 && f >= 0 && i[c] !== b[f]; )
|
|
260
|
+
f--;
|
|
261
|
+
for (; c >= 1 && f >= 0; c--, f--)
|
|
262
|
+
if (i[c] !== b[f]) {
|
|
263
|
+
if (c !== 1 || f !== 1)
|
|
264
264
|
do
|
|
265
|
-
if (
|
|
266
|
-
var
|
|
267
|
-
` + i[
|
|
268
|
-
return e.displayName &&
|
|
265
|
+
if (c--, f--, f < 0 || i[c] !== b[f]) {
|
|
266
|
+
var R = `
|
|
267
|
+
` + i[c].replace(" at new ", " at ");
|
|
268
|
+
return e.displayName && R.includes("<anonymous>") && (R = R.replace("<anonymous>", e.displayName)), typeof e == "function" && se.set(e, R), R;
|
|
269
269
|
}
|
|
270
|
-
while (
|
|
270
|
+
while (c >= 1 && f >= 0);
|
|
271
271
|
break;
|
|
272
272
|
}
|
|
273
273
|
}
|
|
274
274
|
} finally {
|
|
275
|
-
|
|
275
|
+
me = !1, X.current = u, ve(), Error.prepareStackTrace = s;
|
|
276
276
|
}
|
|
277
|
-
var
|
|
278
|
-
return typeof e == "function" &&
|
|
277
|
+
var U = e ? e.displayName || e.name : "", M = U ? oe(U) : "";
|
|
278
|
+
return typeof e == "function" && se.set(e, M), M;
|
|
279
279
|
}
|
|
280
|
-
function
|
|
281
|
-
return
|
|
280
|
+
function Ue(e, r, t) {
|
|
281
|
+
return Ee(e, !1);
|
|
282
282
|
}
|
|
283
283
|
function Ve(e) {
|
|
284
284
|
var r = e.prototype;
|
|
285
285
|
return !!(r && r.isReactComponent);
|
|
286
286
|
}
|
|
287
|
-
function
|
|
287
|
+
function le(e, r, t) {
|
|
288
288
|
if (e == null)
|
|
289
289
|
return "";
|
|
290
290
|
if (typeof e == "function")
|
|
291
|
-
return
|
|
291
|
+
return Ee(e, Ve(e));
|
|
292
292
|
if (typeof e == "string")
|
|
293
|
-
return
|
|
293
|
+
return oe(e);
|
|
294
294
|
switch (e) {
|
|
295
295
|
case I:
|
|
296
|
-
return
|
|
297
|
-
case
|
|
298
|
-
return
|
|
296
|
+
return oe("Suspense");
|
|
297
|
+
case x:
|
|
298
|
+
return oe("SuspenseList");
|
|
299
299
|
}
|
|
300
300
|
if (typeof e == "object")
|
|
301
301
|
switch (e.$$typeof) {
|
|
302
|
-
case
|
|
303
|
-
return
|
|
304
|
-
case
|
|
305
|
-
return
|
|
302
|
+
case d:
|
|
303
|
+
return Ue(e.render);
|
|
304
|
+
case E:
|
|
305
|
+
return le(e.type, r, t);
|
|
306
306
|
case S: {
|
|
307
|
-
var a = e,
|
|
307
|
+
var a = e, s = a._payload, u = a._init;
|
|
308
308
|
try {
|
|
309
|
-
return
|
|
309
|
+
return le(u(s), r, t);
|
|
310
310
|
} catch {
|
|
311
311
|
}
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
314
|
return "";
|
|
315
315
|
}
|
|
316
|
-
var
|
|
317
|
-
function
|
|
316
|
+
var Z = Object.prototype.hasOwnProperty, Re = {}, Ce = L.ReactDebugCurrentFrame;
|
|
317
|
+
function ue(e) {
|
|
318
318
|
if (e) {
|
|
319
|
-
var r = e._owner, t =
|
|
320
|
-
|
|
319
|
+
var r = e._owner, t = le(e.type, e._source, r ? r.type : null);
|
|
320
|
+
Ce.setExtraStackFrame(t);
|
|
321
321
|
} else
|
|
322
|
-
|
|
322
|
+
Ce.setExtraStackFrame(null);
|
|
323
323
|
}
|
|
324
|
-
function Je(e, r, t, a,
|
|
324
|
+
function Je(e, r, t, a, s) {
|
|
325
325
|
{
|
|
326
|
-
var
|
|
327
|
-
for (var
|
|
328
|
-
if (
|
|
326
|
+
var u = Function.call.bind(Z);
|
|
327
|
+
for (var o in e)
|
|
328
|
+
if (u(e, o)) {
|
|
329
329
|
var i = void 0;
|
|
330
330
|
try {
|
|
331
|
-
if (typeof e[
|
|
332
|
-
var b = Error((a || "React class") + ": " + t + " type `" +
|
|
331
|
+
if (typeof e[o] != "function") {
|
|
332
|
+
var b = Error((a || "React class") + ": " + t + " type `" + o + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[o] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
333
333
|
throw b.name = "Invariant Violation", b;
|
|
334
334
|
}
|
|
335
|
-
i = e[
|
|
336
|
-
} catch (
|
|
337
|
-
i =
|
|
335
|
+
i = e[o](r, o, a, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
336
|
+
} catch (c) {
|
|
337
|
+
i = c;
|
|
338
338
|
}
|
|
339
|
-
i && !(i instanceof Error) && (
|
|
339
|
+
i && !(i instanceof Error) && (ue(s), p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", a || "React class", t, o, typeof i), ue(null)), i instanceof Error && !(i.message in Re) && (Re[i.message] = !0, ue(s), p("Failed %s type: %s", t, i.message), ue(null));
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
}
|
|
343
343
|
var qe = Array.isArray;
|
|
344
|
-
function
|
|
344
|
+
function xe(e) {
|
|
345
345
|
return qe(e);
|
|
346
346
|
}
|
|
347
347
|
function He(e) {
|
|
@@ -360,18 +360,18 @@ function xr() {
|
|
|
360
360
|
function _e(e) {
|
|
361
361
|
return "" + e;
|
|
362
362
|
}
|
|
363
|
-
function
|
|
363
|
+
function we(e) {
|
|
364
364
|
if (Ke(e))
|
|
365
|
-
return
|
|
365
|
+
return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), _e(e);
|
|
366
366
|
}
|
|
367
|
-
var
|
|
367
|
+
var Se = L.ReactCurrentOwner, Ge = {
|
|
368
368
|
key: !0,
|
|
369
369
|
ref: !0,
|
|
370
370
|
__self: !0,
|
|
371
371
|
__source: !0
|
|
372
|
-
},
|
|
372
|
+
}, Te, Oe;
|
|
373
373
|
function ze(e) {
|
|
374
|
-
if (
|
|
374
|
+
if (Z.call(e, "ref")) {
|
|
375
375
|
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
376
376
|
if (r && r.isReactWarning)
|
|
377
377
|
return !1;
|
|
@@ -379,7 +379,7 @@ function xr() {
|
|
|
379
379
|
return e.ref !== void 0;
|
|
380
380
|
}
|
|
381
381
|
function Xe(e) {
|
|
382
|
-
if (
|
|
382
|
+
if (Z.call(e, "key")) {
|
|
383
383
|
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
384
384
|
if (r && r.isReactWarning)
|
|
385
385
|
return !1;
|
|
@@ -387,12 +387,12 @@ function xr() {
|
|
|
387
387
|
return e.key !== void 0;
|
|
388
388
|
}
|
|
389
389
|
function Ze(e, r) {
|
|
390
|
-
typeof e.ref == "string" &&
|
|
390
|
+
typeof e.ref == "string" && Se.current;
|
|
391
391
|
}
|
|
392
392
|
function Qe(e, r) {
|
|
393
393
|
{
|
|
394
394
|
var t = function() {
|
|
395
|
-
|
|
395
|
+
Te || (Te = !0, p("%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://reactjs.org/link/special-props)", r));
|
|
396
396
|
};
|
|
397
397
|
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
398
398
|
get: t,
|
|
@@ -403,7 +403,7 @@ function xr() {
|
|
|
403
403
|
function er(e, r) {
|
|
404
404
|
{
|
|
405
405
|
var t = function() {
|
|
406
|
-
|
|
406
|
+
Oe || (Oe = !0, p("%s: `ref` 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://reactjs.org/link/special-props)", r));
|
|
407
407
|
};
|
|
408
408
|
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
409
409
|
get: t,
|
|
@@ -411,7 +411,7 @@ function xr() {
|
|
|
411
411
|
});
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
|
-
var rr = function(e, r, t, a,
|
|
414
|
+
var rr = function(e, r, t, a, s, u, o) {
|
|
415
415
|
var i = {
|
|
416
416
|
// This tag allows us to uniquely identify this as a React Element
|
|
417
417
|
$$typeof: O,
|
|
@@ -419,9 +419,9 @@ function xr() {
|
|
|
419
419
|
type: e,
|
|
420
420
|
key: r,
|
|
421
421
|
ref: t,
|
|
422
|
-
props:
|
|
422
|
+
props: o,
|
|
423
423
|
// Record the component responsible for creating this element.
|
|
424
|
-
_owner:
|
|
424
|
+
_owner: u
|
|
425
425
|
};
|
|
426
426
|
return i._store = {}, Object.defineProperty(i._store, "validated", {
|
|
427
427
|
configurable: !1,
|
|
@@ -437,44 +437,44 @@ function xr() {
|
|
|
437
437
|
configurable: !1,
|
|
438
438
|
enumerable: !1,
|
|
439
439
|
writable: !1,
|
|
440
|
-
value:
|
|
440
|
+
value: s
|
|
441
441
|
}), Object.freeze && (Object.freeze(i.props), Object.freeze(i)), i;
|
|
442
442
|
};
|
|
443
|
-
function nr(e, r, t, a,
|
|
443
|
+
function nr(e, r, t, a, s) {
|
|
444
444
|
{
|
|
445
|
-
var
|
|
446
|
-
t !== void 0 && (
|
|
447
|
-
for (
|
|
448
|
-
|
|
445
|
+
var u, o = {}, i = null, b = null;
|
|
446
|
+
t !== void 0 && (we(t), i = "" + t), Xe(r) && (we(r.key), i = "" + r.key), ze(r) && (b = r.ref, Ze(r, s));
|
|
447
|
+
for (u in r)
|
|
448
|
+
Z.call(r, u) && !Ge.hasOwnProperty(u) && (o[u] = r[u]);
|
|
449
449
|
if (e && e.defaultProps) {
|
|
450
|
-
var
|
|
451
|
-
for (
|
|
452
|
-
|
|
450
|
+
var c = e.defaultProps;
|
|
451
|
+
for (u in c)
|
|
452
|
+
o[u] === void 0 && (o[u] = c[u]);
|
|
453
453
|
}
|
|
454
454
|
if (i || b) {
|
|
455
|
-
var
|
|
456
|
-
i && Qe(
|
|
455
|
+
var f = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
456
|
+
i && Qe(o, f), b && er(o, f);
|
|
457
457
|
}
|
|
458
|
-
return rr(e, i, b,
|
|
458
|
+
return rr(e, i, b, s, a, Se.current, o);
|
|
459
459
|
}
|
|
460
460
|
}
|
|
461
|
-
var
|
|
462
|
-
function
|
|
461
|
+
var ge = L.ReactCurrentOwner, ke = L.ReactDebugCurrentFrame;
|
|
462
|
+
function B(e) {
|
|
463
463
|
if (e) {
|
|
464
|
-
var r = e._owner, t =
|
|
465
|
-
|
|
464
|
+
var r = e._owner, t = le(e.type, e._source, r ? r.type : null);
|
|
465
|
+
ke.setExtraStackFrame(t);
|
|
466
466
|
} else
|
|
467
|
-
|
|
467
|
+
ke.setExtraStackFrame(null);
|
|
468
468
|
}
|
|
469
|
-
var
|
|
470
|
-
|
|
471
|
-
function
|
|
469
|
+
var be;
|
|
470
|
+
be = !1;
|
|
471
|
+
function je(e) {
|
|
472
472
|
return typeof e == "object" && e !== null && e.$$typeof === O;
|
|
473
473
|
}
|
|
474
474
|
function Pe() {
|
|
475
475
|
{
|
|
476
|
-
if (
|
|
477
|
-
var e = T(
|
|
476
|
+
if (ge.current) {
|
|
477
|
+
var e = T(ge.current.type);
|
|
478
478
|
if (e)
|
|
479
479
|
return `
|
|
480
480
|
|
|
@@ -486,7 +486,7 @@ Check the render method of \`` + e + "`.";
|
|
|
486
486
|
function tr(e) {
|
|
487
487
|
return "";
|
|
488
488
|
}
|
|
489
|
-
var
|
|
489
|
+
var Ne = {};
|
|
490
490
|
function ar(e) {
|
|
491
491
|
{
|
|
492
492
|
var r = Pe();
|
|
@@ -499,35 +499,35 @@ Check the top-level render call using <` + t + ">.");
|
|
|
499
499
|
return r;
|
|
500
500
|
}
|
|
501
501
|
}
|
|
502
|
-
function
|
|
502
|
+
function Ie(e, r) {
|
|
503
503
|
{
|
|
504
504
|
if (!e._store || e._store.validated || e.key != null)
|
|
505
505
|
return;
|
|
506
506
|
e._store.validated = !0;
|
|
507
507
|
var t = ar(r);
|
|
508
|
-
if (
|
|
508
|
+
if (Ne[t])
|
|
509
509
|
return;
|
|
510
|
-
|
|
510
|
+
Ne[t] = !0;
|
|
511
511
|
var a = "";
|
|
512
|
-
e && e._owner && e._owner !==
|
|
512
|
+
e && e._owner && e._owner !== ge.current && (a = " It was passed a child from " + T(e._owner.type) + "."), B(e), p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, a), B(null);
|
|
513
513
|
}
|
|
514
514
|
}
|
|
515
|
-
function
|
|
515
|
+
function De(e, r) {
|
|
516
516
|
{
|
|
517
517
|
if (typeof e != "object")
|
|
518
518
|
return;
|
|
519
|
-
if (
|
|
519
|
+
if (xe(e))
|
|
520
520
|
for (var t = 0; t < e.length; t++) {
|
|
521
521
|
var a = e[t];
|
|
522
|
-
|
|
522
|
+
je(a) && Ie(a, r);
|
|
523
523
|
}
|
|
524
|
-
else if (
|
|
524
|
+
else if (je(e))
|
|
525
525
|
e._store && (e._store.validated = !0);
|
|
526
526
|
else if (e) {
|
|
527
|
-
var
|
|
528
|
-
if (typeof
|
|
529
|
-
for (var
|
|
530
|
-
|
|
527
|
+
var s = Y(e);
|
|
528
|
+
if (typeof s == "function" && s !== e.entries)
|
|
529
|
+
for (var u = s.call(e), o; !(o = u.next()).done; )
|
|
530
|
+
je(o.value) && Ie(o.value, r);
|
|
531
531
|
}
|
|
532
532
|
}
|
|
533
533
|
}
|
|
@@ -539,110 +539,110 @@ Check the top-level render call using <` + t + ">.");
|
|
|
539
539
|
var t;
|
|
540
540
|
if (typeof r == "function")
|
|
541
541
|
t = r.propTypes;
|
|
542
|
-
else if (typeof r == "object" && (r.$$typeof ===
|
|
542
|
+
else if (typeof r == "object" && (r.$$typeof === d || // Note: Memo only checks outer props here.
|
|
543
543
|
// Inner props are checked in the reconciler.
|
|
544
|
-
r.$$typeof ===
|
|
544
|
+
r.$$typeof === E))
|
|
545
545
|
t = r.propTypes;
|
|
546
546
|
else
|
|
547
547
|
return;
|
|
548
548
|
if (t) {
|
|
549
549
|
var a = T(r);
|
|
550
550
|
Je(t, e.props, "prop", a, e);
|
|
551
|
-
} else if (r.PropTypes !== void 0 && !
|
|
552
|
-
|
|
553
|
-
var
|
|
554
|
-
|
|
551
|
+
} else if (r.PropTypes !== void 0 && !be) {
|
|
552
|
+
be = !0;
|
|
553
|
+
var s = T(r);
|
|
554
|
+
p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", s || "Unknown");
|
|
555
555
|
}
|
|
556
|
-
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved &&
|
|
556
|
+
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
557
557
|
}
|
|
558
558
|
}
|
|
559
|
-
function
|
|
559
|
+
function or(e) {
|
|
560
560
|
{
|
|
561
561
|
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
|
|
562
562
|
var a = r[t];
|
|
563
563
|
if (a !== "children" && a !== "key") {
|
|
564
|
-
|
|
564
|
+
B(e), p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", a), B(null);
|
|
565
565
|
break;
|
|
566
566
|
}
|
|
567
567
|
}
|
|
568
|
-
e.ref !== null && (
|
|
568
|
+
e.ref !== null && (B(e), p("Invalid attribute `ref` supplied to `React.Fragment`."), B(null));
|
|
569
569
|
}
|
|
570
570
|
}
|
|
571
|
-
var
|
|
572
|
-
function
|
|
571
|
+
var Ae = {};
|
|
572
|
+
function Le(e, r, t, a, s, u) {
|
|
573
573
|
{
|
|
574
|
-
var
|
|
575
|
-
if (!
|
|
574
|
+
var o = J(e);
|
|
575
|
+
if (!o) {
|
|
576
576
|
var i = "";
|
|
577
577
|
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (i += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
578
578
|
var b = tr();
|
|
579
579
|
b ? i += b : i += Pe();
|
|
580
|
-
var
|
|
581
|
-
e === null ?
|
|
580
|
+
var c;
|
|
581
|
+
e === null ? c = "null" : xe(e) ? c = "array" : e !== void 0 && e.$$typeof === O ? (c = "<" + (T(e.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : c = typeof e, p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", c, i);
|
|
582
582
|
}
|
|
583
|
-
var
|
|
584
|
-
if (
|
|
585
|
-
return
|
|
586
|
-
if (
|
|
587
|
-
var
|
|
588
|
-
if (
|
|
583
|
+
var f = nr(e, r, t, s, u);
|
|
584
|
+
if (f == null)
|
|
585
|
+
return f;
|
|
586
|
+
if (o) {
|
|
587
|
+
var R = r.children;
|
|
588
|
+
if (R !== void 0)
|
|
589
589
|
if (a)
|
|
590
|
-
if (
|
|
591
|
-
for (var
|
|
592
|
-
|
|
593
|
-
Object.freeze && Object.freeze(
|
|
590
|
+
if (xe(R)) {
|
|
591
|
+
for (var U = 0; U < R.length; U++)
|
|
592
|
+
De(R[U], e);
|
|
593
|
+
Object.freeze && Object.freeze(R);
|
|
594
594
|
} else
|
|
595
|
-
|
|
595
|
+
p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
596
596
|
else
|
|
597
|
-
|
|
597
|
+
De(R, e);
|
|
598
598
|
}
|
|
599
|
-
if (
|
|
600
|
-
var
|
|
599
|
+
if (Z.call(r, "key")) {
|
|
600
|
+
var M = T(e), j = Object.keys(r).filter(function(dr) {
|
|
601
601
|
return dr !== "key";
|
|
602
|
-
}),
|
|
603
|
-
if (!
|
|
604
|
-
var fr =
|
|
605
|
-
|
|
602
|
+
}), ye = j.length > 0 ? "{key: someKey, " + j.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
603
|
+
if (!Ae[M + ye]) {
|
|
604
|
+
var fr = j.length > 0 ? "{" + j.join(": ..., ") + ": ...}" : "{}";
|
|
605
|
+
p(`A props object containing a "key" prop is being spread into JSX:
|
|
606
606
|
let props = %s;
|
|
607
607
|
<%s {...props} />
|
|
608
608
|
React keys must be passed directly to JSX without using spread:
|
|
609
609
|
let props = %s;
|
|
610
|
-
<%s key={someKey} {...props} />`,
|
|
610
|
+
<%s key={someKey} {...props} />`, ye, M, fr, M), Ae[M + ye] = !0;
|
|
611
611
|
}
|
|
612
612
|
}
|
|
613
|
-
return e === C ?
|
|
613
|
+
return e === C ? or(f) : ir(f), f;
|
|
614
614
|
}
|
|
615
615
|
}
|
|
616
|
-
function
|
|
617
|
-
return
|
|
616
|
+
function sr(e, r, t) {
|
|
617
|
+
return Le(e, r, t, !0);
|
|
618
618
|
}
|
|
619
619
|
function lr(e, r, t) {
|
|
620
|
-
return
|
|
620
|
+
return Le(e, r, t, !1);
|
|
621
621
|
}
|
|
622
|
-
var
|
|
623
|
-
|
|
624
|
-
})()),
|
|
622
|
+
var ur = lr, cr = sr;
|
|
623
|
+
ee.Fragment = C, ee.jsx = ur, ee.jsxs = cr;
|
|
624
|
+
})()), ee;
|
|
625
625
|
}
|
|
626
|
-
var
|
|
626
|
+
var Me;
|
|
627
627
|
function gr() {
|
|
628
|
-
return
|
|
628
|
+
return Me || (Me = 1, process.env.NODE_ENV === "production" ? ce.exports = mr() : ce.exports = xr()), ce.exports;
|
|
629
629
|
}
|
|
630
630
|
var n = gr();
|
|
631
|
-
const
|
|
632
|
-
const [O,
|
|
633
|
-
|
|
634
|
-
}, N = (
|
|
635
|
-
|
|
631
|
+
const Ye = pr(null), wr = ({ children: w }) => {
|
|
632
|
+
const [O, h] = V(!0), [C, k] = V(null), P = () => {
|
|
633
|
+
h((m) => !m), k(null);
|
|
634
|
+
}, N = (m) => {
|
|
635
|
+
k((d) => d === m ? null : m);
|
|
636
636
|
};
|
|
637
637
|
return /* @__PURE__ */ n.jsx(
|
|
638
|
-
|
|
638
|
+
Ye.Provider,
|
|
639
639
|
{
|
|
640
|
-
value: { isExpanded: O, toggleSidebar:
|
|
640
|
+
value: { isExpanded: O, toggleSidebar: P, openSubmenu: C, toggleSubmenu: N },
|
|
641
641
|
children: w
|
|
642
642
|
}
|
|
643
643
|
);
|
|
644
644
|
}, br = () => {
|
|
645
|
-
const w = vr(
|
|
645
|
+
const w = vr(Ye);
|
|
646
646
|
if (!w) throw new Error("useSidebar must be used inside <SidebarProvider>");
|
|
647
647
|
return w;
|
|
648
648
|
}, jr = () => /* @__PURE__ */ n.jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", children: [
|
|
@@ -659,66 +659,66 @@ const Me = pr(null), wr = ({ children: w }) => {
|
|
|
659
659
|
] }), Rr = () => /* @__PURE__ */ n.jsxs("svg", { width: "32", height: "32", viewBox: "0 0 32 32", fill: "none", children: [
|
|
660
660
|
/* @__PURE__ */ n.jsx("rect", { width: "32", height: "32", rx: "8", fill: "currentColor", opacity: "0.15" }),
|
|
661
661
|
/* @__PURE__ */ n.jsx("circle", { cx: "16", cy: "16", r: "6", fill: "currentColor" })
|
|
662
|
-
] }),
|
|
662
|
+
] }), Cr = () => /* @__PURE__ */ n.jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
663
663
|
/* @__PURE__ */ n.jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
|
|
664
664
|
/* @__PURE__ */ n.jsx("polyline", { points: "16 17 21 12 16 7" }),
|
|
665
665
|
/* @__PURE__ */ n.jsx("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
|
|
666
666
|
] }), Sr = ({ config: w }) => {
|
|
667
667
|
const {
|
|
668
668
|
navItems: O,
|
|
669
|
-
user:
|
|
669
|
+
user: h,
|
|
670
670
|
createButtonRoles: C,
|
|
671
|
-
createButtonLabel:
|
|
672
|
-
createButtonPath:
|
|
671
|
+
createButtonLabel: k = "Create",
|
|
672
|
+
createButtonPath: P,
|
|
673
673
|
brandName: N = "Amphenol",
|
|
674
|
-
brandSubtitle:
|
|
675
|
-
logo:
|
|
674
|
+
brandSubtitle: m = "COMMUNICATION SOLUTIONS",
|
|
675
|
+
logo: d,
|
|
676
676
|
helpLabel: I = "Help Center",
|
|
677
|
-
helpIcon:
|
|
678
|
-
onSignOut:
|
|
677
|
+
helpIcon: x,
|
|
678
|
+
onSignOut: E,
|
|
679
679
|
onNavigate: S,
|
|
680
|
-
className:
|
|
681
|
-
} = w, { isExpanded:
|
|
680
|
+
className: W = ""
|
|
681
|
+
} = w, { isExpanded: y, toggleSidebar: re, openSubmenu: Y, toggleSubmenu: L } = br(), [p, fe] = V(window.location.pathname), [de, ne] = V(!1), [pe, te] = V(!1), [ae, F] = V(null);
|
|
682
682
|
hr(() => {
|
|
683
|
-
const
|
|
684
|
-
return window.addEventListener("popstate",
|
|
683
|
+
const v = () => fe(window.location.pathname);
|
|
684
|
+
return window.addEventListener("popstate", v), () => window.removeEventListener("popstate", v);
|
|
685
685
|
}, []);
|
|
686
|
-
const
|
|
687
|
-
|
|
688
|
-
},
|
|
689
|
-
|
|
690
|
-
},
|
|
691
|
-
(
|
|
692
|
-
const
|
|
693
|
-
return
|
|
686
|
+
const J = (v, _) => {
|
|
687
|
+
v.preventDefault(), _ && (S ? S(_) : (window.history.pushState({}, "", _), window.dispatchEvent(new PopStateEvent("popstate"))));
|
|
688
|
+
}, ie = () => h.email ? h.email.split("@")[0] : "User", q = () => h.email ? h.email.charAt(0).toUpperCase() : "U", T = () => {
|
|
689
|
+
E ? E() : window.location.href = "/c/portal/logout";
|
|
690
|
+
}, D = !C || C.includes(h.role), $ = O.reduce(
|
|
691
|
+
(v, _) => {
|
|
692
|
+
const A = _.section || "GENERAL";
|
|
693
|
+
return v[A] || (v[A] = []), v[A].push(_), v;
|
|
694
694
|
},
|
|
695
695
|
{}
|
|
696
696
|
);
|
|
697
697
|
return /* @__PURE__ */ n.jsxs(
|
|
698
698
|
"aside",
|
|
699
699
|
{
|
|
700
|
-
style: { backgroundColor: "#0f172a" },
|
|
701
|
-
className: `rdr-sidebar ${
|
|
700
|
+
style: { backgroundColor: "#0f172a", overflowY: "hidden" },
|
|
701
|
+
className: `rdr-sidebar ${y ? "expanded" : "collapsed"} ${W}`,
|
|
702
702
|
children: [
|
|
703
703
|
/* @__PURE__ */ n.jsxs("div", { className: "sidebar-header ", style: { paddingTop: "10px" }, children: [
|
|
704
|
-
/* @__PURE__ */ n.jsxs("div", { className: "logo-section", onClick:
|
|
705
|
-
/* @__PURE__ */ n.jsx("span", { className: "logo-icon ", style: { color: "var(--sidebar-accent)", marginTop: "15px" }, children:
|
|
706
|
-
|
|
704
|
+
/* @__PURE__ */ n.jsxs("div", { className: "logo-section", onClick: re, children: [
|
|
705
|
+
/* @__PURE__ */ n.jsx("span", { className: "logo-icon ", style: { color: "var(--sidebar-accent)", marginTop: "15px" }, children: d ?? /* @__PURE__ */ n.jsx(Rr, {}) }),
|
|
706
|
+
y && /* @__PURE__ */ n.jsxs("div", { className: "brand-text", children: [
|
|
707
707
|
/* @__PURE__ */ n.jsx("h2", { children: N }),
|
|
708
|
-
|
|
708
|
+
m && /* @__PURE__ */ n.jsx("span", { children: m })
|
|
709
709
|
] })
|
|
710
710
|
] }),
|
|
711
|
-
|
|
711
|
+
y && /* @__PURE__ */ n.jsx(
|
|
712
712
|
"button",
|
|
713
713
|
{
|
|
714
714
|
className: "menu-toggle",
|
|
715
|
-
onClick:
|
|
715
|
+
onClick: re,
|
|
716
716
|
"aria-label": "Collapse sidebar",
|
|
717
717
|
children: /* @__PURE__ */ n.jsx(jr, {})
|
|
718
718
|
}
|
|
719
719
|
)
|
|
720
720
|
] }),
|
|
721
|
-
|
|
721
|
+
D && P && /* @__PURE__ */ n.jsx("div", { className: "sidebar-actions", children: /* @__PURE__ */ n.jsxs(
|
|
722
722
|
"button",
|
|
723
723
|
{
|
|
724
724
|
className: "sidebar-create-btn",
|
|
@@ -738,61 +738,68 @@ const Me = pr(null), wr = ({ children: w }) => {
|
|
|
738
738
|
fontSize: "14px",
|
|
739
739
|
fontWeight: 600,
|
|
740
740
|
color: "#fff",
|
|
741
|
-
background:
|
|
741
|
+
background: pe ? "#149B6E" : "#18B885",
|
|
742
742
|
transition: "background-color 0.2s ease"
|
|
743
743
|
},
|
|
744
|
-
onMouseEnter: () =>
|
|
745
|
-
onMouseLeave: () =>
|
|
746
|
-
onClick: (
|
|
744
|
+
onMouseEnter: () => te(!0),
|
|
745
|
+
onMouseLeave: () => te(!1),
|
|
746
|
+
onClick: (v) => J(v, P),
|
|
747
747
|
children: [
|
|
748
748
|
/* @__PURE__ */ n.jsx(yr, {}),
|
|
749
|
-
|
|
749
|
+
y && /* @__PURE__ */ n.jsx("span", { children: k })
|
|
750
750
|
]
|
|
751
751
|
}
|
|
752
752
|
) }),
|
|
753
|
-
/* @__PURE__ */ n.jsx("div", { className: "sidebar-nav", children: Object.entries(
|
|
754
|
-
const
|
|
755
|
-
(
|
|
753
|
+
/* @__PURE__ */ n.jsx("div", { className: "sidebar-nav", children: Object.entries($).map(([v, _]) => {
|
|
754
|
+
const A = _.filter(
|
|
755
|
+
(l) => !l.roles || l.roles.includes(h.role)
|
|
756
756
|
);
|
|
757
|
-
return
|
|
758
|
-
|
|
759
|
-
/* @__PURE__ */ n.jsx("ul", { className: "nav-items", children:
|
|
760
|
-
var
|
|
761
|
-
const
|
|
762
|
-
(
|
|
763
|
-
),
|
|
764
|
-
return /* @__PURE__ */ n.jsx("li", { children: (
|
|
757
|
+
return A.length ? /* @__PURE__ */ n.jsxs("div", { className: "nav-section", style: { listStyleType: "none" }, children: [
|
|
758
|
+
y && /* @__PURE__ */ n.jsx("h4", { className: "section-title", children: v }),
|
|
759
|
+
/* @__PURE__ */ n.jsx("ul", { className: "nav-items", children: A.map((l) => {
|
|
760
|
+
var G, z;
|
|
761
|
+
const H = (G = l.subItems) == null ? void 0 : G.some(
|
|
762
|
+
(g) => g.path && p.includes(g.path)
|
|
763
|
+
), K = l.path ? p === l.path : !1;
|
|
764
|
+
return /* @__PURE__ */ n.jsx("li", { children: (z = l.subItems) != null && z.length ? (
|
|
765
765
|
/* Parent with submenu */
|
|
766
766
|
/* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
767
767
|
/* @__PURE__ */ n.jsxs(
|
|
768
768
|
"div",
|
|
769
769
|
{
|
|
770
|
-
className: `nav-item ${
|
|
771
|
-
"data-label":
|
|
772
|
-
onClick: () =>
|
|
770
|
+
className: `nav-item ${Y === l.name || H ? "active" : ""}`,
|
|
771
|
+
"data-label": l.name,
|
|
772
|
+
onClick: () => L(l.name),
|
|
773
|
+
onMouseEnter: () => F(l.name),
|
|
774
|
+
onMouseLeave: () => F(null),
|
|
775
|
+
style: Y === l.name || H || ae === l.name ? {
|
|
776
|
+
backgroundColor: "#10B981",
|
|
777
|
+
border: "1px solid #10B981",
|
|
778
|
+
borderRadius: "8px"
|
|
779
|
+
} : {},
|
|
773
780
|
children: [
|
|
774
|
-
/* @__PURE__ */ n.jsx("span", { className: "nav-icon", children:
|
|
775
|
-
|
|
776
|
-
/* @__PURE__ */ n.jsx("span", { className: "nav-text", children:
|
|
777
|
-
/* @__PURE__ */ n.jsx("span", { className: "submenu-arrow", children:
|
|
781
|
+
/* @__PURE__ */ n.jsx("span", { className: "nav-icon", children: l.icon }),
|
|
782
|
+
y && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
783
|
+
/* @__PURE__ */ n.jsx("span", { className: "nav-text", children: l.name }),
|
|
784
|
+
/* @__PURE__ */ n.jsx("span", { className: "submenu-arrow", children: Y === l.name ? "−" : "+" })
|
|
778
785
|
] })
|
|
779
786
|
]
|
|
780
787
|
}
|
|
781
788
|
),
|
|
782
|
-
|
|
783
|
-
const
|
|
789
|
+
y && Y === l.name && /* @__PURE__ */ n.jsx("ul", { className: "submenu", children: l.subItems.map((g) => {
|
|
790
|
+
const ve = g.path ? p === g.path : !1;
|
|
784
791
|
return /* @__PURE__ */ n.jsx("li", { children: /* @__PURE__ */ n.jsxs(
|
|
785
792
|
"a",
|
|
786
793
|
{
|
|
787
|
-
href:
|
|
788
|
-
onClick: (
|
|
789
|
-
className: `submenu-item ${
|
|
794
|
+
href: g.path || "/",
|
|
795
|
+
onClick: (X) => J(X, g.path),
|
|
796
|
+
className: `submenu-item ${ve ? "active-sub" : ""}`,
|
|
790
797
|
children: [
|
|
791
|
-
|
|
792
|
-
/* @__PURE__ */ n.jsx("span", { children:
|
|
798
|
+
g.icon && /* @__PURE__ */ n.jsx("span", { className: "submenu-icon", children: g.icon }),
|
|
799
|
+
/* @__PURE__ */ n.jsx("span", { children: g.name })
|
|
793
800
|
]
|
|
794
801
|
}
|
|
795
|
-
) },
|
|
802
|
+
) }, g.name);
|
|
796
803
|
}) })
|
|
797
804
|
] })
|
|
798
805
|
) : (
|
|
@@ -800,61 +807,68 @@ const Me = pr(null), wr = ({ children: w }) => {
|
|
|
800
807
|
/* @__PURE__ */ n.jsxs(
|
|
801
808
|
"a",
|
|
802
809
|
{
|
|
803
|
-
href:
|
|
804
|
-
"data-label":
|
|
805
|
-
onClick: (
|
|
806
|
-
|
|
810
|
+
href: l.path || "/",
|
|
811
|
+
"data-label": l.name,
|
|
812
|
+
onClick: (g) => J(g, l.path),
|
|
813
|
+
style: K || ae === l.name ? {
|
|
814
|
+
backgroundColor: "#10B981",
|
|
815
|
+
border: "1px solid #10B981",
|
|
816
|
+
borderRadius: "8px"
|
|
817
|
+
} : {},
|
|
818
|
+
onMouseEnter: () => F(l.name),
|
|
819
|
+
onMouseLeave: () => F(null),
|
|
820
|
+
className: `nav-item ${K ? "active" : ""}`,
|
|
807
821
|
children: [
|
|
808
|
-
/* @__PURE__ */ n.jsx("span", { className: "nav-icon", children:
|
|
809
|
-
|
|
822
|
+
/* @__PURE__ */ n.jsx("span", { className: "nav-icon", children: l.icon }),
|
|
823
|
+
y && /* @__PURE__ */ n.jsx("span", { className: "nav-text", children: l.name })
|
|
810
824
|
]
|
|
811
825
|
}
|
|
812
826
|
)
|
|
813
|
-
) },
|
|
827
|
+
) }, l.name);
|
|
814
828
|
}) })
|
|
815
|
-
] },
|
|
829
|
+
] }, v) : null;
|
|
816
830
|
}) }),
|
|
817
831
|
/* @__PURE__ */ n.jsxs("div", { className: "sidebar-footer", children: [
|
|
818
832
|
/* @__PURE__ */ n.jsxs("div", { className: "footer-link", "data-label": I, children: [
|
|
819
|
-
/* @__PURE__ */ n.jsx("span", { children:
|
|
820
|
-
|
|
833
|
+
/* @__PURE__ */ n.jsx("span", { children: x ?? /* @__PURE__ */ n.jsx(Er, {}) }),
|
|
834
|
+
y && /* @__PURE__ */ n.jsx("span", { children: I })
|
|
821
835
|
] }),
|
|
822
836
|
/* @__PURE__ */ n.jsxs("div", { className: "user-profile-wrapper", children: [
|
|
823
837
|
/* @__PURE__ */ n.jsxs(
|
|
824
838
|
"div",
|
|
825
839
|
{
|
|
826
840
|
className: "user-profile",
|
|
827
|
-
onClick: () =>
|
|
841
|
+
onClick: () => ne((v) => !v),
|
|
828
842
|
children: [
|
|
829
|
-
/* @__PURE__ */ n.jsx("div", { className: "avatar", children:
|
|
830
|
-
|
|
831
|
-
/* @__PURE__ */ n.jsx("div", { className: "user-name", children:
|
|
832
|
-
/* @__PURE__ */ n.jsx("div", { className: "user-role", children:
|
|
843
|
+
/* @__PURE__ */ n.jsx("div", { className: "avatar", children: q() }),
|
|
844
|
+
y && /* @__PURE__ */ n.jsxs("div", { className: "user-info", children: [
|
|
845
|
+
/* @__PURE__ */ n.jsx("div", { className: "user-name", children: ie() }),
|
|
846
|
+
/* @__PURE__ */ n.jsx("div", { className: "user-role", children: h.roleName })
|
|
833
847
|
] })
|
|
834
848
|
]
|
|
835
849
|
}
|
|
836
850
|
),
|
|
837
|
-
|
|
851
|
+
de && /* @__PURE__ */ n.jsxs("div", { className: "profile-popup", children: [
|
|
838
852
|
/* @__PURE__ */ n.jsx(
|
|
839
853
|
"button",
|
|
840
854
|
{
|
|
841
855
|
className: "popup-close",
|
|
842
|
-
onClick: () =>
|
|
856
|
+
onClick: () => ne(!1),
|
|
843
857
|
"aria-label": "Close",
|
|
844
858
|
children: "✕"
|
|
845
859
|
}
|
|
846
860
|
),
|
|
847
861
|
/* @__PURE__ */ n.jsxs("div", { className: "popup-header", children: [
|
|
848
|
-
/* @__PURE__ */ n.jsx("div", { className: "popup-avatar", children:
|
|
862
|
+
/* @__PURE__ */ n.jsx("div", { className: "popup-avatar", children: q() }),
|
|
849
863
|
/* @__PURE__ */ n.jsxs("div", { className: "popup-user-details", children: [
|
|
850
|
-
/* @__PURE__ */ n.jsx("div", { className: "popup-name", children:
|
|
851
|
-
/* @__PURE__ */ n.jsx("div", { className: "popup-role", children:
|
|
852
|
-
/* @__PURE__ */ n.jsx("div", { className: "popup-email", children:
|
|
864
|
+
/* @__PURE__ */ n.jsx("div", { className: "popup-name", children: ie() }),
|
|
865
|
+
/* @__PURE__ */ n.jsx("div", { className: "popup-role", children: h.roleName }),
|
|
866
|
+
/* @__PURE__ */ n.jsx("div", { className: "popup-email", children: h.email })
|
|
853
867
|
] })
|
|
854
868
|
] }),
|
|
855
869
|
/* @__PURE__ */ n.jsx("div", { className: "popup-divider" }),
|
|
856
|
-
/* @__PURE__ */ n.jsxs("button", { className: "signout-btn", onClick:
|
|
857
|
-
/* @__PURE__ */ n.jsx(
|
|
870
|
+
/* @__PURE__ */ n.jsxs("button", { className: "signout-btn", onClick: T, children: [
|
|
871
|
+
/* @__PURE__ */ n.jsx(Cr, {}),
|
|
858
872
|
/* @__PURE__ */ n.jsx("span", { children: "Sign Out" })
|
|
859
873
|
] })
|
|
860
874
|
] })
|