@aiquants/menu-bar 1.20.0 → 1.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +64 -0
- package/README.md +38 -17
- package/dist/index.es.js +286 -292
- package/dist/index.umd.js +2 -2
- package/dist/styles/menu-bar.css +1 -1
- package/dist/styles/menu-bar.standalone.css +1 -1
- package/dist/typeScale.d.ts +2 -0
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,67 +1,67 @@
|
|
|
1
|
-
import
|
|
1
|
+
import Pe, { forwardRef as we, createElement as oe, useCallback as _, useSyncExternalStore as Ae, useMemo as ue, useState as X, useRef as $, useEffect as F, useLayoutEffect as ye } from "react";
|
|
2
2
|
import { useLocation as Re, Link as Ne } from "react-router-dom";
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
function
|
|
6
|
-
if (
|
|
7
|
-
|
|
3
|
+
var J = { exports: {} }, V = {};
|
|
4
|
+
var de;
|
|
5
|
+
function Ie() {
|
|
6
|
+
if (de) return V;
|
|
7
|
+
de = 1;
|
|
8
8
|
var t = /* @__PURE__ */ Symbol.for("react.transitional.element"), n = /* @__PURE__ */ Symbol.for("react.fragment");
|
|
9
|
-
function a(s,
|
|
9
|
+
function a(s, l, o) {
|
|
10
10
|
var u = null;
|
|
11
|
-
if (o !== void 0 && (u = "" + o),
|
|
11
|
+
if (o !== void 0 && (u = "" + o), l.key !== void 0 && (u = "" + l.key), "key" in l) {
|
|
12
12
|
o = {};
|
|
13
|
-
for (var d in
|
|
14
|
-
d !== "key" && (o[d] =
|
|
15
|
-
} else o =
|
|
16
|
-
return
|
|
13
|
+
for (var d in l)
|
|
14
|
+
d !== "key" && (o[d] = l[d]);
|
|
15
|
+
} else o = l;
|
|
16
|
+
return l = o.ref, {
|
|
17
17
|
$$typeof: t,
|
|
18
18
|
type: s,
|
|
19
19
|
key: u,
|
|
20
|
-
ref:
|
|
20
|
+
ref: l !== void 0 ? l : null,
|
|
21
21
|
props: o
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
|
-
return
|
|
24
|
+
return V.Fragment = n, V.jsx = a, V.jsxs = a, V;
|
|
25
25
|
}
|
|
26
26
|
var W = {};
|
|
27
|
-
var
|
|
28
|
-
function
|
|
29
|
-
return
|
|
27
|
+
var fe;
|
|
28
|
+
function Oe() {
|
|
29
|
+
return fe || (fe = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
30
30
|
function t(e) {
|
|
31
31
|
if (e == null) return null;
|
|
32
32
|
if (typeof e == "function")
|
|
33
|
-
return e.$$typeof ===
|
|
33
|
+
return e.$$typeof === U ? null : e.displayName || e.name || null;
|
|
34
34
|
if (typeof e == "string") return e;
|
|
35
35
|
switch (e) {
|
|
36
|
-
case
|
|
36
|
+
case c:
|
|
37
37
|
return "Fragment";
|
|
38
38
|
case S:
|
|
39
39
|
return "Profiler";
|
|
40
40
|
case p:
|
|
41
41
|
return "StrictMode";
|
|
42
|
-
case
|
|
42
|
+
case D:
|
|
43
43
|
return "Suspense";
|
|
44
44
|
case Q:
|
|
45
45
|
return "SuspenseList";
|
|
46
|
-
case
|
|
46
|
+
case H:
|
|
47
47
|
return "Activity";
|
|
48
48
|
}
|
|
49
49
|
if (typeof e == "object")
|
|
50
50
|
switch (typeof e.tag == "number" && console.error(
|
|
51
51
|
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
52
52
|
), e.$$typeof) {
|
|
53
|
-
case
|
|
53
|
+
case I:
|
|
54
54
|
return "Portal";
|
|
55
|
-
case
|
|
55
|
+
case T:
|
|
56
56
|
return e.displayName || "Context";
|
|
57
|
-
case
|
|
57
|
+
case k:
|
|
58
58
|
return (e._context.displayName || "Context") + ".Consumer";
|
|
59
59
|
case O:
|
|
60
60
|
var i = e.render;
|
|
61
61
|
return e = e.displayName, e || (e = i.displayName || i.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
62
|
-
case
|
|
62
|
+
case K:
|
|
63
63
|
return i = e.displayName || null, i !== null ? i : t(e.type) || "Memo";
|
|
64
|
-
case
|
|
64
|
+
case z:
|
|
65
65
|
i = e._payload, e = e._init;
|
|
66
66
|
try {
|
|
67
67
|
return t(e(i));
|
|
@@ -91,8 +91,8 @@ function Ie() {
|
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
93
|
function s(e) {
|
|
94
|
-
if (e ===
|
|
95
|
-
if (typeof e == "object" && e !== null && e.$$typeof ===
|
|
94
|
+
if (e === c) return "<>";
|
|
95
|
+
if (typeof e == "object" && e !== null && e.$$typeof === z)
|
|
96
96
|
return "<...>";
|
|
97
97
|
try {
|
|
98
98
|
var i = t(e);
|
|
@@ -101,15 +101,15 @@ function Ie() {
|
|
|
101
101
|
return "<...>";
|
|
102
102
|
}
|
|
103
103
|
}
|
|
104
|
-
function
|
|
105
|
-
var e =
|
|
104
|
+
function l() {
|
|
105
|
+
var e = q.A;
|
|
106
106
|
return e === null ? null : e.getOwner();
|
|
107
107
|
}
|
|
108
108
|
function o() {
|
|
109
109
|
return Error("react-stack-top-frame");
|
|
110
110
|
}
|
|
111
111
|
function u(e) {
|
|
112
|
-
if (
|
|
112
|
+
if (P.call(e, "key")) {
|
|
113
113
|
var i = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
114
114
|
if (i && i.isReactWarning) return !1;
|
|
115
115
|
}
|
|
@@ -117,7 +117,7 @@ function Ie() {
|
|
|
117
117
|
}
|
|
118
118
|
function d(e, i) {
|
|
119
119
|
function f() {
|
|
120
|
-
|
|
120
|
+
G || (G = !0, console.error(
|
|
121
121
|
"%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)",
|
|
122
122
|
i
|
|
123
123
|
));
|
|
@@ -129,19 +129,19 @@ function Ie() {
|
|
|
129
129
|
}
|
|
130
130
|
function m() {
|
|
131
131
|
var e = t(this.type);
|
|
132
|
-
return
|
|
132
|
+
return B[e] || (B[e] = !0, console.error(
|
|
133
133
|
"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."
|
|
134
134
|
)), e = this.props.ref, e !== void 0 ? e : null;
|
|
135
135
|
}
|
|
136
|
-
function
|
|
137
|
-
var
|
|
136
|
+
function x(e, i, f, b, Z, te) {
|
|
137
|
+
var v = f.ref;
|
|
138
138
|
return e = {
|
|
139
|
-
$$typeof:
|
|
139
|
+
$$typeof: C,
|
|
140
140
|
type: e,
|
|
141
141
|
key: i,
|
|
142
142
|
props: f,
|
|
143
143
|
_owner: b
|
|
144
|
-
}, (
|
|
144
|
+
}, (v !== void 0 ? v : null) !== null ? Object.defineProperty(e, "ref", {
|
|
145
145
|
enumerable: !1,
|
|
146
146
|
get: m
|
|
147
147
|
}) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
|
|
@@ -158,33 +158,33 @@ function Ie() {
|
|
|
158
158
|
configurable: !1,
|
|
159
159
|
enumerable: !1,
|
|
160
160
|
writable: !0,
|
|
161
|
-
value:
|
|
161
|
+
value: Z
|
|
162
162
|
}), Object.defineProperty(e, "_debugTask", {
|
|
163
163
|
configurable: !1,
|
|
164
164
|
enumerable: !1,
|
|
165
165
|
writable: !0,
|
|
166
|
-
value:
|
|
166
|
+
value: te
|
|
167
167
|
}), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
|
|
168
168
|
}
|
|
169
|
-
function y(e, i, f, b,
|
|
170
|
-
var
|
|
171
|
-
if (
|
|
169
|
+
function y(e, i, f, b, Z, te) {
|
|
170
|
+
var v = i.children;
|
|
171
|
+
if (v !== void 0)
|
|
172
172
|
if (b)
|
|
173
|
-
if (
|
|
174
|
-
for (b = 0; b <
|
|
175
|
-
N(
|
|
176
|
-
Object.freeze && Object.freeze(
|
|
173
|
+
if (ee(v)) {
|
|
174
|
+
for (b = 0; b < v.length; b++)
|
|
175
|
+
N(v[b]);
|
|
176
|
+
Object.freeze && Object.freeze(v);
|
|
177
177
|
} else
|
|
178
178
|
console.error(
|
|
179
179
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
180
180
|
);
|
|
181
|
-
else N(
|
|
182
|
-
if (
|
|
183
|
-
|
|
184
|
-
var L = Object.keys(i).filter(function(
|
|
185
|
-
return
|
|
181
|
+
else N(v);
|
|
182
|
+
if (P.call(i, "key")) {
|
|
183
|
+
v = t(e);
|
|
184
|
+
var L = Object.keys(i).filter(function(Me) {
|
|
185
|
+
return Me !== "key";
|
|
186
186
|
});
|
|
187
|
-
b = 0 < L.length ? "{key: someKey, " + L.join(": ..., ") + ": ...}" : "{key: someKey}", h[
|
|
187
|
+
b = 0 < L.length ? "{key: someKey, " + L.join(": ..., ") + ": ...}" : "{key: someKey}", h[v + b] || (L = 0 < L.length ? "{" + L.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
188
188
|
`A props object containing a "key" prop is being spread into JSX:
|
|
189
189
|
let props = %s;
|
|
190
190
|
<%s {...props} />
|
|
@@ -192,35 +192,35 @@ React keys must be passed directly to JSX without using spread:
|
|
|
192
192
|
let props = %s;
|
|
193
193
|
<%s key={someKey} {...props} />`,
|
|
194
194
|
b,
|
|
195
|
-
|
|
195
|
+
v,
|
|
196
196
|
L,
|
|
197
|
-
|
|
198
|
-
), h[
|
|
197
|
+
v
|
|
198
|
+
), h[v + b] = !0);
|
|
199
199
|
}
|
|
200
|
-
if (
|
|
200
|
+
if (v = null, f !== void 0 && (a(f), v = "" + f), u(i) && (a(i.key), v = "" + i.key), "key" in i) {
|
|
201
201
|
f = {};
|
|
202
|
-
for (var
|
|
203
|
-
|
|
202
|
+
for (var ne in i)
|
|
203
|
+
ne !== "key" && (f[ne] = i[ne]);
|
|
204
204
|
} else f = i;
|
|
205
|
-
return
|
|
205
|
+
return v && d(
|
|
206
206
|
f,
|
|
207
207
|
typeof e == "function" ? e.displayName || e.name || "Unknown" : e
|
|
208
|
-
),
|
|
208
|
+
), x(
|
|
209
209
|
e,
|
|
210
|
-
|
|
210
|
+
v,
|
|
211
211
|
f,
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
212
|
+
l(),
|
|
213
|
+
Z,
|
|
214
|
+
te
|
|
215
215
|
);
|
|
216
216
|
}
|
|
217
217
|
function N(e) {
|
|
218
|
-
|
|
218
|
+
w(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof === z && (e._payload.status === "fulfilled" ? w(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
|
|
219
219
|
}
|
|
220
|
-
function
|
|
221
|
-
return typeof e == "object" && e !== null && e.$$typeof ===
|
|
220
|
+
function w(e) {
|
|
221
|
+
return typeof e == "object" && e !== null && e.$$typeof === C;
|
|
222
222
|
}
|
|
223
|
-
var j =
|
|
223
|
+
var j = Pe, C = /* @__PURE__ */ Symbol.for("react.transitional.element"), I = /* @__PURE__ */ Symbol.for("react.portal"), c = /* @__PURE__ */ Symbol.for("react.fragment"), p = /* @__PURE__ */ Symbol.for("react.strict_mode"), S = /* @__PURE__ */ Symbol.for("react.profiler"), k = /* @__PURE__ */ Symbol.for("react.consumer"), T = /* @__PURE__ */ Symbol.for("react.context"), O = /* @__PURE__ */ Symbol.for("react.forward_ref"), D = /* @__PURE__ */ Symbol.for("react.suspense"), Q = /* @__PURE__ */ Symbol.for("react.suspense_list"), K = /* @__PURE__ */ Symbol.for("react.memo"), z = /* @__PURE__ */ Symbol.for("react.lazy"), H = /* @__PURE__ */ Symbol.for("react.activity"), U = /* @__PURE__ */ Symbol.for("react.client.reference"), q = j.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, P = Object.prototype.hasOwnProperty, ee = Array.isArray, M = console.createTask ? console.createTask : function() {
|
|
224
224
|
return null;
|
|
225
225
|
};
|
|
226
226
|
j = {
|
|
@@ -228,42 +228,42 @@ React keys must be passed directly to JSX without using spread:
|
|
|
228
228
|
return e();
|
|
229
229
|
}
|
|
230
230
|
};
|
|
231
|
-
var
|
|
231
|
+
var G, B = {}, A = j.react_stack_bottom_frame.bind(
|
|
232
232
|
j,
|
|
233
233
|
o
|
|
234
|
-
)(),
|
|
235
|
-
W.Fragment =
|
|
236
|
-
var b = 1e4 >
|
|
234
|
+
)(), Y = M(s(o)), h = {};
|
|
235
|
+
W.Fragment = c, W.jsx = function(e, i, f) {
|
|
236
|
+
var b = 1e4 > q.recentlyCreatedOwnerStacks++;
|
|
237
237
|
return y(
|
|
238
238
|
e,
|
|
239
239
|
i,
|
|
240
240
|
f,
|
|
241
241
|
!1,
|
|
242
|
-
b ? Error("react-stack-top-frame") :
|
|
243
|
-
b ?
|
|
242
|
+
b ? Error("react-stack-top-frame") : A,
|
|
243
|
+
b ? M(s(e)) : Y
|
|
244
244
|
);
|
|
245
245
|
}, W.jsxs = function(e, i, f) {
|
|
246
|
-
var b = 1e4 >
|
|
246
|
+
var b = 1e4 > q.recentlyCreatedOwnerStacks++;
|
|
247
247
|
return y(
|
|
248
248
|
e,
|
|
249
249
|
i,
|
|
250
250
|
f,
|
|
251
251
|
!0,
|
|
252
|
-
b ? Error("react-stack-top-frame") :
|
|
253
|
-
b ?
|
|
252
|
+
b ? Error("react-stack-top-frame") : A,
|
|
253
|
+
b ? M(s(e)) : Y
|
|
254
254
|
);
|
|
255
255
|
};
|
|
256
256
|
})()), W;
|
|
257
257
|
}
|
|
258
|
-
var
|
|
259
|
-
function
|
|
260
|
-
return
|
|
258
|
+
var me;
|
|
259
|
+
function qe() {
|
|
260
|
+
return me || (me = 1, process.env.NODE_ENV === "production" ? J.exports = Ie() : J.exports = Oe()), J.exports;
|
|
261
261
|
}
|
|
262
|
-
var r =
|
|
263
|
-
const
|
|
262
|
+
var r = qe();
|
|
263
|
+
const Le = (t) => t.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), $e = (t) => t.replace(
|
|
264
264
|
/^([A-Z])|[\s-_]+(\w)/g,
|
|
265
265
|
(n, a, s) => s ? s.toUpperCase() : a.toLowerCase()
|
|
266
|
-
),
|
|
266
|
+
), he = (t) => {
|
|
267
267
|
const n = $e(t);
|
|
268
268
|
return n.charAt(0).toUpperCase() + n.slice(1);
|
|
269
269
|
}, _e = (...t) => t.filter((n, a, s) => !!n && n.trim() !== "" && s.indexOf(n) === a).join(" ").trim(), De = (t) => {
|
|
@@ -282,17 +282,17 @@ var ze = {
|
|
|
282
282
|
strokeLinecap: "round",
|
|
283
283
|
strokeLinejoin: "round"
|
|
284
284
|
};
|
|
285
|
-
const He =
|
|
285
|
+
const He = we(
|
|
286
286
|
({
|
|
287
287
|
color: t = "currentColor",
|
|
288
288
|
size: n = 24,
|
|
289
289
|
strokeWidth: a = 2,
|
|
290
290
|
absoluteStrokeWidth: s,
|
|
291
|
-
className:
|
|
291
|
+
className: l = "",
|
|
292
292
|
children: o,
|
|
293
293
|
iconNode: u,
|
|
294
294
|
...d
|
|
295
|
-
}, m) =>
|
|
295
|
+
}, m) => oe(
|
|
296
296
|
"svg",
|
|
297
297
|
{
|
|
298
298
|
ref: m,
|
|
@@ -301,71 +301,71 @@ const He = ke(
|
|
|
301
301
|
height: n,
|
|
302
302
|
stroke: t,
|
|
303
303
|
strokeWidth: s ? Number(a) * 24 / Number(n) : a,
|
|
304
|
-
className: _e("lucide",
|
|
304
|
+
className: _e("lucide", l),
|
|
305
305
|
...!o && !De(d) && { "aria-hidden": "true" },
|
|
306
306
|
...d
|
|
307
307
|
},
|
|
308
308
|
[
|
|
309
|
-
...u.map(([
|
|
309
|
+
...u.map(([x, y]) => oe(x, y)),
|
|
310
310
|
...Array.isArray(o) ? o : [o]
|
|
311
311
|
]
|
|
312
312
|
)
|
|
313
313
|
);
|
|
314
314
|
const E = (t, n) => {
|
|
315
|
-
const a =
|
|
316
|
-
({ className: s, ...
|
|
315
|
+
const a = we(
|
|
316
|
+
({ className: s, ...l }, o) => oe(He, {
|
|
317
317
|
ref: o,
|
|
318
318
|
iconNode: n,
|
|
319
319
|
className: _e(
|
|
320
|
-
`lucide-${
|
|
320
|
+
`lucide-${Le(he(t))}`,
|
|
321
321
|
`lucide-${t}`,
|
|
322
322
|
s
|
|
323
323
|
),
|
|
324
|
-
...
|
|
324
|
+
...l
|
|
325
325
|
})
|
|
326
326
|
);
|
|
327
|
-
return a.displayName =
|
|
327
|
+
return a.displayName = he(t), a;
|
|
328
328
|
};
|
|
329
329
|
const Ye = [
|
|
330
330
|
["path", { d: "M15 3h6v6", key: "1q9fwt" }],
|
|
331
331
|
["path", { d: "M10 14 21 3", key: "gplh6r" }],
|
|
332
332
|
["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
|
|
333
|
-
],
|
|
334
|
-
const
|
|
333
|
+
], Ve = E("external-link", Ye);
|
|
334
|
+
const We = [
|
|
335
335
|
["path", { d: "M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2", key: "975kel" }],
|
|
336
336
|
["circle", { cx: "12", cy: "7", r: "4", key: "17ys0d" }]
|
|
337
|
-
], Fe = E("user",
|
|
338
|
-
const { user: n, LinkComponent: a =
|
|
337
|
+
], Fe = E("user", We), R = "text-[length:var(--aqmb-font-size-body,0.8125rem)] leading-[var(--aqmb-line-height-body,1.25rem)]", Ue = "text-[length:var(--aqmb-font-size-caption,0.6875rem)] leading-[var(--aqmb-line-height-caption,1.25rem)]", Ge = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0iI2NiZDVlMSI+PHBhdGggZD0iTTEyIDEyYzIuMjEgMCA0LTEuNzkgNC00cy0xLjc5LTQtNC00LTQgMS43OS00IDQgMS43OSA0IDQgNHptMCAyYy0yLjY3IDAtOCAxLjM0LTggNHYyaDE2di0yYzAtMi42Ni01LjMzLTQtOC00eiIvPjwvc3ZnPg==", Be = ({ to: t, className: n, children: a }) => /* @__PURE__ */ r.jsx("a", { href: t, className: n, children: a }), pe = `flex min-h-11 items-center justify-center gap-1 rounded-md border border-white/15 bg-white/10 px-1 py-1 font-medium ${R} text-white transition duration-150 hover:bg-white/25 active:scale-95 dark:border-slate-600/50 dark:bg-slate-700/50 dark:text-slate-200 dark:hover:bg-slate-600/80`, _t = (t) => {
|
|
338
|
+
const { user: n, LinkComponent: a = Be } = t;
|
|
339
339
|
return /* @__PURE__ */ r.jsx("div", { className: "w-full", children: n ? /* @__PURE__ */ r.jsxs(
|
|
340
340
|
"div",
|
|
341
341
|
{
|
|
342
342
|
"data-aqmb-session-card": !0,
|
|
343
|
-
className: "aiquants-session-card group relative flex flex-col gap-2 rounded-xl border border-white/20 bg-white/10 p-2.5 shadow-sm backdrop-blur-md transition-
|
|
343
|
+
className: "aiquants-session-card group relative flex flex-col gap-2 rounded-xl border border-white/20 bg-white/10 p-2.5 shadow-sm backdrop-blur-md transition-colors duration-200 hover:border-white/30 hover:bg-white/15 dark:border-slate-700/60 dark:bg-slate-800/60 dark:hover:border-slate-600/80 dark:hover:bg-slate-800/90",
|
|
344
344
|
children: [
|
|
345
345
|
/* @__PURE__ */ r.jsxs("div", { className: "flex min-w-0 items-center gap-2.5", children: [
|
|
346
346
|
/* @__PURE__ */ r.jsxs("div", { className: "relative shrink-0", children: [
|
|
347
|
-
/* @__PURE__ */ r.jsx("div", { className: "h-8 w-8 overflow-hidden rounded-full border border-white/40 shadow-xs dark:border-slate-500", children: /* @__PURE__ */ r.jsx("img", { className: "h-full w-full rounded-full object-cover", src: n.photo ||
|
|
347
|
+
/* @__PURE__ */ r.jsx("div", { className: "h-8 w-8 overflow-hidden rounded-full border border-white/40 shadow-xs dark:border-slate-500", children: /* @__PURE__ */ r.jsx("img", { className: "h-full w-full rounded-full object-cover", src: n.photo || Ge, alt: n.displayName || "user profile" }) }),
|
|
348
348
|
/* @__PURE__ */ r.jsx("span", { className: "absolute -right-0.5 -bottom-0.5 h-2.5 w-2.5 rounded-full border-2 border-slate-900 bg-emerald-400", title: "Online" })
|
|
349
349
|
] }),
|
|
350
350
|
/* @__PURE__ */ r.jsxs("div", { className: "min-w-0 flex-1 leading-tight", children: [
|
|
351
|
-
/* @__PURE__ */ r.jsx("div", { className: "
|
|
352
|
-
/* @__PURE__ */ r.jsx("div", { className:
|
|
351
|
+
/* @__PURE__ */ r.jsx("div", { className: "font-semibold text-white text-xs tracking-tight dark:text-slate-100", children: n.displayName }),
|
|
352
|
+
/* @__PURE__ */ r.jsx("div", { className: `mt-0.5 font-medium ${Ue} text-white/75 tracking-tight dark:text-slate-400`, children: "Google Account" })
|
|
353
353
|
] })
|
|
354
354
|
] }),
|
|
355
|
-
/* @__PURE__ */ r.jsxs("div", { className: "grid grid-cols-
|
|
356
|
-
/* @__PURE__ */ r.jsxs(a, { className:
|
|
355
|
+
/* @__PURE__ */ r.jsxs("div", { className: "grid grid-cols-1 gap-1.5 border-white/15 border-t pt-1.5 dark:border-slate-700/50", children: [
|
|
356
|
+
/* @__PURE__ */ r.jsxs(a, { className: pe, to: "/", children: [
|
|
357
357
|
/* @__PURE__ */ r.jsx(Fe, { size: 11, className: "shrink-0 opacity-80" }),
|
|
358
|
-
/* @__PURE__ */ r.jsx("span", { className: "
|
|
358
|
+
/* @__PURE__ */ r.jsx("span", { className: "min-w-0 text-center", children: "プロフィール" })
|
|
359
359
|
] }),
|
|
360
|
-
/* @__PURE__ */ r.jsxs(a, { className:
|
|
361
|
-
/* @__PURE__ */ r.jsx(
|
|
362
|
-
/* @__PURE__ */ r.jsx("span", { className: "
|
|
360
|
+
/* @__PURE__ */ r.jsxs(a, { className: pe, to: "https://myaccount.google.com/", children: [
|
|
361
|
+
/* @__PURE__ */ r.jsx(Ve, { size: 11, className: "shrink-0 opacity-80" }),
|
|
362
|
+
/* @__PURE__ */ r.jsx("span", { className: "min-w-0 text-center", children: "Google" })
|
|
363
363
|
] })
|
|
364
364
|
] })
|
|
365
365
|
]
|
|
366
366
|
}
|
|
367
367
|
) : /* @__PURE__ */ r.jsx("div", { "data-aqmb-session-card": !0, className: "aiquants-session-card flex items-center justify-between rounded-xl border border-white/20 bg-white/10 p-2.5 shadow-xs dark:border-slate-700/60 dark:bg-slate-800/60", children: /* @__PURE__ */ r.jsx("span", { className: "font-medium text-white/90 text-xs dark:text-slate-200", children: "ログインしてください" }) }) });
|
|
368
|
-
},
|
|
368
|
+
}, ie = "aiquants-menu-pin-change";
|
|
369
369
|
let g = { pinned: !1, width: 0, active: !1 };
|
|
370
370
|
const je = (t = 240) => {
|
|
371
371
|
if (typeof window > "u" || typeof document > "u")
|
|
@@ -375,26 +375,26 @@ const je = (t = 240) => {
|
|
|
375
375
|
if (n) {
|
|
376
376
|
const u = Number.parseInt(n, 10);
|
|
377
377
|
if (!Number.isNaN(u)) {
|
|
378
|
-
const d = u > 0, m = d ? u || t : 0,
|
|
379
|
-
return g.pinned === d && g.width === m && g.active ===
|
|
378
|
+
const d = u > 0, m = d ? u || t : 0, x = g.active ?? d;
|
|
379
|
+
return g.pinned === d && g.width === m && g.active === x || (g = { pinned: d, width: m, active: x }), g;
|
|
380
380
|
}
|
|
381
381
|
}
|
|
382
|
-
const s = localStorage.getItem("aiquants-menu-pinned") === "true",
|
|
383
|
-
return g.pinned === s && g.width ===
|
|
382
|
+
const s = localStorage.getItem("aiquants-menu-pinned") === "true", l = s ? t : 0, o = g.active ?? s;
|
|
383
|
+
return g.pinned === s && g.width === l && g.active === o || (g = { pinned: s, width: l, active: o }), g;
|
|
384
384
|
} catch {
|
|
385
385
|
return { pinned: !1, width: 0, active: !1 };
|
|
386
386
|
}
|
|
387
|
-
},
|
|
387
|
+
}, be = (t, n, a) => {
|
|
388
388
|
if (typeof window > "u") return;
|
|
389
|
-
const s = a ?? t,
|
|
390
|
-
(g.pinned !== t || g.width !== n || g.active !== s) && (g =
|
|
391
|
-
const o = new CustomEvent(
|
|
392
|
-
detail:
|
|
389
|
+
const s = a ?? t, l = { pinned: t, width: n, active: s };
|
|
390
|
+
(g.pinned !== t || g.width !== n || g.active !== s) && (g = l);
|
|
391
|
+
const o = new CustomEvent(ie, {
|
|
392
|
+
detail: l,
|
|
393
393
|
bubbles: !0,
|
|
394
394
|
cancelable: !1
|
|
395
395
|
});
|
|
396
396
|
window.dispatchEvent(o);
|
|
397
|
-
},
|
|
397
|
+
}, Ze = (t, n) => {
|
|
398
398
|
if (typeof window > "u")
|
|
399
399
|
return () => {
|
|
400
400
|
};
|
|
@@ -403,33 +403,33 @@ const je = (t = 240) => {
|
|
|
403
403
|
const o = je(s);
|
|
404
404
|
t(o);
|
|
405
405
|
}
|
|
406
|
-
const
|
|
406
|
+
const l = (o) => {
|
|
407
407
|
const u = o;
|
|
408
408
|
u.detail && t(u.detail);
|
|
409
409
|
};
|
|
410
|
-
return window.addEventListener(
|
|
411
|
-
window.removeEventListener(
|
|
410
|
+
return window.addEventListener(ie, l, { passive: !0 }), () => {
|
|
411
|
+
window.removeEventListener(ie, l);
|
|
412
412
|
};
|
|
413
|
-
},
|
|
413
|
+
}, jt = (t) => {
|
|
414
414
|
const n = t?.defaultPinnedWidth ?? 240, a = t?.initialPinned ?? !1, s = _(
|
|
415
|
-
(u) =>
|
|
415
|
+
(u) => Ze(
|
|
416
416
|
() => {
|
|
417
417
|
u();
|
|
418
418
|
},
|
|
419
419
|
{ immediate: !1, defaultPinnedWidth: n }
|
|
420
420
|
),
|
|
421
421
|
[n]
|
|
422
|
-
),
|
|
422
|
+
), l = _(() => je(n), [n]), o = _(() => ({
|
|
423
423
|
pinned: a,
|
|
424
424
|
width: a ? n : 0
|
|
425
425
|
}), [a, n]);
|
|
426
|
-
return
|
|
426
|
+
return Ae(s, l, o);
|
|
427
427
|
};
|
|
428
|
-
const
|
|
428
|
+
const Je = [
|
|
429
429
|
["path", { d: "m16 17 5-5-5-5", key: "1bji2h" }],
|
|
430
430
|
["path", { d: "M21 12H9", key: "dn1m92" }],
|
|
431
431
|
["path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4", key: "1uf3rs" }]
|
|
432
|
-
],
|
|
432
|
+
], Xe = E("log-out", Je);
|
|
433
433
|
const Qe = [
|
|
434
434
|
["path", { d: "M12 17v5", key: "bb1du9" }],
|
|
435
435
|
[
|
|
@@ -440,7 +440,7 @@ const Qe = [
|
|
|
440
440
|
}
|
|
441
441
|
]
|
|
442
442
|
], Ee = E("pin", Qe);
|
|
443
|
-
const
|
|
443
|
+
const Ke = [
|
|
444
444
|
["path", { d: "M12 17v5", key: "bb1du9" }],
|
|
445
445
|
["path", { d: "M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89", key: "znwnzq" }],
|
|
446
446
|
["path", { d: "m2 2 20 20", key: "1ooewy" }],
|
|
@@ -451,18 +451,18 @@ const Xe = [
|
|
|
451
451
|
key: "c9qhm2"
|
|
452
452
|
}
|
|
453
453
|
]
|
|
454
|
-
], Se = E("pin-off",
|
|
455
|
-
const
|
|
454
|
+
], Se = E("pin-off", Ke);
|
|
455
|
+
const et = [
|
|
456
456
|
["path", { d: "M5 21v-6", key: "1hz6c0" }],
|
|
457
457
|
["path", { d: "M12 21V9", key: "uvy0l4" }],
|
|
458
458
|
["path", { d: "M19 21V3", key: "11j9sm" }]
|
|
459
|
-
],
|
|
460
|
-
const
|
|
459
|
+
], tt = E("chart-no-axes-column-increasing", et);
|
|
460
|
+
const nt = [
|
|
461
461
|
["path", { d: "M12 15V3", key: "m9g1x1" }],
|
|
462
462
|
["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }],
|
|
463
463
|
["path", { d: "m7 10 5 5 5-5", key: "brsn70" }]
|
|
464
|
-
],
|
|
465
|
-
const
|
|
464
|
+
], rt = E("download", nt);
|
|
465
|
+
const at = [
|
|
466
466
|
[
|
|
467
467
|
"path",
|
|
468
468
|
{
|
|
@@ -474,30 +474,30 @@ const rt = [
|
|
|
474
474
|
["path", { d: "M10 9H8", key: "b1mrlr" }],
|
|
475
475
|
["path", { d: "M16 13H8", key: "t4e002" }],
|
|
476
476
|
["path", { d: "M16 17H8", key: "z1uh3a" }]
|
|
477
|
-
],
|
|
478
|
-
const
|
|
477
|
+
], ve = E("file-text", at);
|
|
478
|
+
const st = [
|
|
479
479
|
["path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71", key: "1cjeqo" }],
|
|
480
480
|
["path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71", key: "19qd67" }]
|
|
481
|
-
],
|
|
482
|
-
const
|
|
481
|
+
], ot = E("link", st);
|
|
482
|
+
const it = [
|
|
483
483
|
["rect", { width: "18", height: "11", x: "3", y: "11", rx: "2", ry: "2", key: "1w4ew1" }],
|
|
484
484
|
["path", { d: "M7 11V7a5 5 0 0 1 10 0v4", key: "fwvmzm" }]
|
|
485
|
-
],
|
|
485
|
+
], lt = E("lock", it);
|
|
486
486
|
const ct = [
|
|
487
487
|
["path", { d: "M12 3v18", key: "108xh3" }],
|
|
488
488
|
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
489
489
|
["path", { d: "M3 9h18", key: "1pudct" }],
|
|
490
490
|
["path", { d: "M3 15h18", key: "5xshup" }]
|
|
491
|
-
],
|
|
492
|
-
report:
|
|
493
|
-
slip:
|
|
494
|
-
table:
|
|
495
|
-
chart:
|
|
496
|
-
download:
|
|
497
|
-
lock:
|
|
498
|
-
href:
|
|
499
|
-
},
|
|
500
|
-
const a = t ?
|
|
491
|
+
], ut = E("table", ct), le = "flex min-h-11 flex-1 items-center", dt = "min-h-11 min-w-11", ft = typeof window < "u" ? ye : F, xe = "aiquants-menu-scroll", Te = new RegExp(/(^https?:\/\/)|(\.(html|htm)?$)/), mt = {
|
|
492
|
+
report: ve,
|
|
493
|
+
slip: ve,
|
|
494
|
+
table: ut,
|
|
495
|
+
chart: tt,
|
|
496
|
+
download: rt,
|
|
497
|
+
lock: lt,
|
|
498
|
+
href: ot
|
|
499
|
+
}, ht = ({ mark: t, children: n }) => {
|
|
500
|
+
const a = t ? mt[t] : void 0;
|
|
501
501
|
return a ? /* @__PURE__ */ r.jsxs("div", { className: "flex flex-nowrap items-center", children: [
|
|
502
502
|
/* @__PURE__ */ r.jsx(a, { className: "h-3.5 w-3.5 shrink-0" }),
|
|
503
503
|
/* @__PURE__ */ r.jsx("div", { className: "aiquants-menu-link mx-1 hover:underline", children: n })
|
|
@@ -521,149 +521,143 @@ const ct = [
|
|
|
521
521
|
title: t.title,
|
|
522
522
|
href: t.href
|
|
523
523
|
}
|
|
524
|
-
},
|
|
524
|
+
}, pt = ({ item: t, parentMenu: n, isCurrent: a, onMenuSelected: s }) => {
|
|
525
525
|
if (t.href === "separator")
|
|
526
526
|
return /* @__PURE__ */ r.jsx("hr", { className: "aiquants-menu-separator mx-2 my-1 h-px" });
|
|
527
|
-
const
|
|
528
|
-
className:
|
|
527
|
+
const l = /* @__PURE__ */ r.jsx(ht, { mark: t.mark, children: t.title }), o = {
|
|
528
|
+
className: le,
|
|
529
529
|
"aria-current": a ? "page" : void 0,
|
|
530
530
|
onClick: () => {
|
|
531
531
|
s && s(ce(n, t));
|
|
532
532
|
}
|
|
533
533
|
};
|
|
534
|
-
return t.new ? /* @__PURE__ */ r.jsx("a", { href: t.href, rel: "noopener noreferrer", target: "_blank", ...o, children:
|
|
535
|
-
},
|
|
536
|
-
const s =
|
|
534
|
+
return t.new ? /* @__PURE__ */ r.jsx("a", { href: t.href, rel: "noopener noreferrer", target: "_blank", ...o, children: l }) : Te.test(t.href) ? /* @__PURE__ */ r.jsx("a", { href: t.href, ...o, children: l }) : /* @__PURE__ */ r.jsx(Ne, { to: t.href, ...o, children: l });
|
|
535
|
+
}, Ce = (t) => t ? t.split(/[?#]/)[0].replace(/(?!^\/)\/$/, "") : "", ge = (t, n, a) => {
|
|
536
|
+
const s = Ce(t);
|
|
537
537
|
return s === "" ? -1 : s === a || n === "prefix" && s !== "/" && a.startsWith(`${s}/`) ? s.length : -1;
|
|
538
|
-
},
|
|
539
|
-
const a =
|
|
540
|
-
let s = null,
|
|
538
|
+
}, bt = (t, n) => {
|
|
539
|
+
const a = Ce(n);
|
|
540
|
+
let s = null, l = -1;
|
|
541
541
|
for (const o of t) {
|
|
542
542
|
const u = ge(o.href, o.match, a);
|
|
543
|
-
if (u >
|
|
543
|
+
if (u > l && (s = { menuId: o.id, subid: null }, l = u), o.submenu)
|
|
544
544
|
for (const d of o.submenu) {
|
|
545
545
|
const m = ge(d.href, d.match, a);
|
|
546
|
-
m >
|
|
546
|
+
m > l && (s = { menuId: o.id, subid: d.subid }, l = m);
|
|
547
547
|
}
|
|
548
548
|
}
|
|
549
549
|
return s;
|
|
550
|
-
},
|
|
551
|
-
const { menuList: n, onMenuSelected: a, pinnedSubmenuIds: s = [], onToggleSubmenuPin:
|
|
550
|
+
}, re = (t, n, a) => t !== null && t.menuId === n && t.subid === a, vt = (t) => {
|
|
551
|
+
const { menuList: n, onMenuSelected: a, pinnedSubmenuIds: s = [], onToggleSubmenuPin: l } = t;
|
|
552
552
|
let o = "";
|
|
553
553
|
try {
|
|
554
554
|
o = Re().pathname;
|
|
555
555
|
} catch {
|
|
556
556
|
typeof window < "u" && (o = window.location.pathname);
|
|
557
557
|
}
|
|
558
|
-
const u =
|
|
559
|
-
|
|
560
|
-
y.current !== o && (y.current = o, N.current = !1), !N.current && d !== null && (
|
|
558
|
+
const u = ue(() => bt(n, o), [n, o]), d = u === null ? null : u.menuId, [m, x] = X(d), y = $(o), N = $(d !== null);
|
|
559
|
+
F(() => {
|
|
560
|
+
y.current !== o && (y.current = o, N.current = !1), !N.current && d !== null && (x(d), N.current = !0);
|
|
561
561
|
}, [o, d]);
|
|
562
|
-
const
|
|
563
|
-
(
|
|
564
|
-
s.includes(
|
|
562
|
+
const w = _(
|
|
563
|
+
(c) => {
|
|
564
|
+
s.includes(c) || x((S) => S === c ? null : c);
|
|
565
565
|
},
|
|
566
566
|
[s]
|
|
567
|
-
), j =
|
|
568
|
-
|
|
569
|
-
const
|
|
570
|
-
if (
|
|
567
|
+
), j = $(null);
|
|
568
|
+
ft(() => {
|
|
569
|
+
const c = j.current;
|
|
570
|
+
if (c)
|
|
571
571
|
try {
|
|
572
|
-
const p = sessionStorage.getItem(
|
|
572
|
+
const p = sessionStorage.getItem(xe);
|
|
573
573
|
if (p !== null) {
|
|
574
574
|
const S = Number.parseFloat(p);
|
|
575
|
-
Number.isNaN(S) || (
|
|
575
|
+
Number.isNaN(S) || (c.scrollTop = S);
|
|
576
576
|
}
|
|
577
577
|
} catch {
|
|
578
578
|
}
|
|
579
579
|
}, []);
|
|
580
|
-
const
|
|
581
|
-
const
|
|
582
|
-
if (
|
|
580
|
+
const C = _(() => {
|
|
581
|
+
const c = j.current;
|
|
582
|
+
if (c)
|
|
583
583
|
try {
|
|
584
|
-
sessionStorage.setItem(
|
|
584
|
+
sessionStorage.setItem(xe, String(c.scrollTop));
|
|
585
585
|
} catch {
|
|
586
586
|
}
|
|
587
|
-
}, []),
|
|
588
|
-
"
|
|
587
|
+
}, []), I = ue(() => /* @__PURE__ */ r.jsx(r.Fragment, { children: n.map((c) => /* @__PURE__ */ r.jsx("div", { children: c.href ? /* @__PURE__ */ r.jsx("div", { className: `aiquants-menu-list-item relative mb-0.5 ml-1 flex items-center rounded-l-xl px-2.5 ${R} before:mr-2 before:inline-block before:h-2 before:w-2 before:shrink-0 before:rounded-full before:content-[''] sm:text-sm`, children: Te.test(c.href) ? /* @__PURE__ */ r.jsx(
|
|
588
|
+
"a",
|
|
589
589
|
{
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
onClick: () => {
|
|
598
|
-
a && a(ce(l));
|
|
599
|
-
},
|
|
600
|
-
children: /* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-link hover:underline", children: l.title })
|
|
601
|
-
}
|
|
602
|
-
) : /* @__PURE__ */ r.jsx(
|
|
603
|
-
Ne,
|
|
604
|
-
{
|
|
605
|
-
to: l.href,
|
|
606
|
-
className: ie,
|
|
607
|
-
"aria-current": ne(u, l.id, null) ? "page" : void 0,
|
|
608
|
-
onClick: () => {
|
|
609
|
-
a && a(ce(l));
|
|
610
|
-
},
|
|
611
|
-
children: /* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-link hover:underline", children: l.title })
|
|
612
|
-
}
|
|
613
|
-
)
|
|
590
|
+
href: c.href,
|
|
591
|
+
className: le,
|
|
592
|
+
"aria-current": re(u, c.id, null) ? "page" : void 0,
|
|
593
|
+
onClick: () => {
|
|
594
|
+
a && a(ce(c));
|
|
595
|
+
},
|
|
596
|
+
children: /* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-link hover:underline", children: c.title })
|
|
614
597
|
}
|
|
615
|
-
) : /* @__PURE__ */ r.
|
|
598
|
+
) : /* @__PURE__ */ r.jsx(
|
|
599
|
+
Ne,
|
|
600
|
+
{
|
|
601
|
+
to: c.href,
|
|
602
|
+
className: le,
|
|
603
|
+
"aria-current": re(u, c.id, null) ? "page" : void 0,
|
|
604
|
+
onClick: () => {
|
|
605
|
+
a && a(ce(c));
|
|
606
|
+
},
|
|
607
|
+
children: /* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-link hover:underline", children: c.title })
|
|
608
|
+
}
|
|
609
|
+
) }) : /* @__PURE__ */ r.jsxs("details", { className: "aiquants-menu-accordion-details", open: c.id === m || s.includes(c.id), children: [
|
|
616
610
|
/* @__PURE__ */ r.jsxs(
|
|
617
611
|
"summary",
|
|
618
612
|
{
|
|
619
|
-
className: `aiquants-menu-list-item aiquants-menu-accordion-summary relative mb-0.5 ml-1 list-none rounded-l-xl px-2.5 ${
|
|
613
|
+
className: `aiquants-menu-list-item aiquants-menu-accordion-summary relative mb-0.5 ml-1 min-h-11 list-none rounded-l-xl px-2.5 ${R} before:mr-2 before:inline-block before:h-2 before:w-2 before:shrink-0 before:rounded-full before:content-[''] focus-visible:outline-2 focus-visible:outline-current focus-visible:-outline-offset-2 sm:text-sm`,
|
|
620
614
|
onClick: (p) => {
|
|
621
|
-
p.preventDefault(),
|
|
615
|
+
p.preventDefault(), w(c.id);
|
|
622
616
|
},
|
|
623
617
|
onKeyDown: (p) => {
|
|
624
|
-
(p.key === "Enter" || p.key === " ") && (p.preventDefault(),
|
|
618
|
+
(p.key === "Enter" || p.key === " ") && (p.preventDefault(), w(c.id));
|
|
625
619
|
},
|
|
626
620
|
children: [
|
|
627
|
-
/* @__PURE__ */ r.jsx("span", { children:
|
|
621
|
+
/* @__PURE__ */ r.jsx("span", { children: c.title }),
|
|
628
622
|
/* @__PURE__ */ r.jsx(
|
|
629
623
|
"button",
|
|
630
624
|
{
|
|
631
625
|
type: "button",
|
|
632
626
|
"data-aqmb-submenu-pin-button": !0,
|
|
633
627
|
onClick: (p) => {
|
|
634
|
-
p.stopPropagation(), p.preventDefault(),
|
|
628
|
+
p.stopPropagation(), p.preventDefault(), l && l(c.id);
|
|
635
629
|
},
|
|
636
|
-
className: `aiquants-submenu-pin-button ${
|
|
637
|
-
title: s.includes(
|
|
638
|
-
children: s.includes(
|
|
630
|
+
className: `aiquants-submenu-pin-button ${dt} ${s.includes(c.id) ? "pinned" : ""}`,
|
|
631
|
+
title: s.includes(c.id) ? "ピン留め解除" : "ピン留め",
|
|
632
|
+
children: s.includes(c.id) ? /* @__PURE__ */ r.jsx(Ee, { size: 13 }) : /* @__PURE__ */ r.jsx(Se, { size: 13 })
|
|
639
633
|
}
|
|
640
634
|
)
|
|
641
635
|
]
|
|
642
636
|
}
|
|
643
637
|
),
|
|
644
|
-
/* @__PURE__ */ r.jsx("div", { className: "aiquants-menu-submenu pointer-events-auto my-0.5 mr-1 ml-3.5 rounded-lg px-2 py-1 shadow-sm", children:
|
|
645
|
-
] }) },
|
|
646
|
-
return /* @__PURE__ */ r.jsx("div", { ref: j, onScroll:
|
|
647
|
-
},
|
|
648
|
-
const { menuList: n, menuHeader: a, open: s, onMenuSelected:
|
|
638
|
+
/* @__PURE__ */ r.jsx("div", { className: "aiquants-menu-submenu pointer-events-auto my-0.5 mr-1 ml-3.5 rounded-lg px-2 py-1 shadow-sm", children: c.submenu.map((p) => /* @__PURE__ */ r.jsx("div", { className: `aiquants-menu-accordion-container block w-full ${R}`, children: /* @__PURE__ */ r.jsx(pt, { item: p, parentMenu: c, isCurrent: re(u, c.id, p.subid), onMenuSelected: a }) }, p.subid)) })
|
|
639
|
+
] }) }, c.id)) }), [n, a, m, w, s, u]);
|
|
640
|
+
return /* @__PURE__ */ r.jsx("div", { ref: j, onScroll: C, "data-aqmb-menu-list": !0, className: "aiquants-menu-list-scroller hidden-scrollbar", children: I });
|
|
641
|
+
}, ae = "min-h-11", ke = "min-w-11", xt = (t) => {
|
|
642
|
+
const { menuList: n, menuHeader: a, open: s, onMenuSelected: l, onClickSignout: o, theme: u, toggleTheme: d, isPinned: m, onTogglePin: x, pinnedSubmenuIds: y, onToggleSubmenuPin: N, ref: w } = t;
|
|
649
643
|
return /* @__PURE__ */ r.jsxs(
|
|
650
644
|
"div",
|
|
651
645
|
{
|
|
652
|
-
ref:
|
|
646
|
+
ref: w,
|
|
653
647
|
"data-aqmb-menu-content": !0,
|
|
654
648
|
inert: !s,
|
|
655
649
|
className: `aiquants-menu-content fixed top-0 right-0 z-2147483642 flex min-h-dvh w-[240px] select-none flex-col motion-safe:transition-transform motion-safe:duration-500 ${s ? "aiquants-menu-translate-x-0" : "aiquants-menu-translate-x-250"}`,
|
|
656
650
|
children: [
|
|
657
651
|
/* @__PURE__ */ r.jsx("div", { className: "flex shrink-0 flex-col justify-center border-white/15 border-b px-2.5 py-2 dark:border-slate-700/60", children: a }),
|
|
658
|
-
/* @__PURE__ */ r.jsx("div", { className: "
|
|
659
|
-
/* @__PURE__ */ r.jsx("div", { className: "border-white/15 border-t px-2.5 py-1.5 dark:border-slate-700/60", children: /* @__PURE__ */ r.jsxs("div", { className: "flex items-center justify-between gap-1.5", children: [
|
|
652
|
+
/* @__PURE__ */ r.jsx("div", { className: "aiquants-menu-list-region", children: /* @__PURE__ */ r.jsx(vt, { menuList: n, onMenuSelected: l, pinnedSubmenuIds: y, onToggleSubmenuPin: N }) }),
|
|
653
|
+
/* @__PURE__ */ r.jsx("div", { className: "border-white/15 border-t px-2.5 py-1.5 dark:border-slate-700/60", children: /* @__PURE__ */ r.jsxs("div", { className: "flex flex-wrap items-center justify-between gap-1.5", children: [
|
|
660
654
|
/* @__PURE__ */ r.jsx(
|
|
661
655
|
"button",
|
|
662
656
|
{
|
|
663
657
|
type: "button",
|
|
664
|
-
onClick:
|
|
658
|
+
onClick: x,
|
|
665
659
|
"data-aqmb-pin-button": !0,
|
|
666
|
-
className: `flex ${
|
|
660
|
+
className: `flex ${ae} ${ke} items-center justify-center rounded-md px-2 ${R} text-white shadow-2xs transition-colors duration-200 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-amber-300/60 ${m ? "bg-amber-500 hover:bg-amber-600 dark:bg-amber-600 dark:hover:bg-amber-500" : "border border-white/20 bg-white/10 hover:bg-white/20 dark:border-slate-600/60 dark:bg-slate-700/60 dark:hover:bg-slate-600"}`,
|
|
667
661
|
title: m ? "ピン留め解除" : "ピン留め",
|
|
668
662
|
"aria-label": m ? "ピン留め解除" : "ピン留め",
|
|
669
663
|
children: m ? /* @__PURE__ */ r.jsx(Ee, { size: 12 }) : /* @__PURE__ */ r.jsx(Se, { size: 12 })
|
|
@@ -675,10 +669,10 @@ const ct = [
|
|
|
675
669
|
type: "button",
|
|
676
670
|
onClick: d,
|
|
677
671
|
"data-aqmb-theme-button": !0,
|
|
678
|
-
className: `group relative flex ${
|
|
672
|
+
className: `group relative flex ${ae} ${ke} items-center justify-center rounded-md border border-white/20 bg-white/10 px-2 ${R} text-white shadow-2xs backdrop-blur-xs transition-colors duration-200 hover:bg-white/20 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-white/40 dark:border-slate-600/60 dark:bg-slate-700/60 dark:hover:bg-slate-600`,
|
|
679
673
|
title: u === "dark" ? "ライトモードに切り替え" : "ダークモードに切り替え",
|
|
680
674
|
"aria-label": u === "dark" ? "ライトモードに切り替え" : "ダークモードに切り替え",
|
|
681
|
-
children: /* @__PURE__ */ r.jsx("span", { className: "
|
|
675
|
+
children: /* @__PURE__ */ r.jsx("span", { className: "transition-transform duration-200 group-hover:scale-110", children: u === "dark" ? "🌞" : "🌙" })
|
|
682
676
|
}
|
|
683
677
|
),
|
|
684
678
|
/* @__PURE__ */ r.jsxs(
|
|
@@ -686,11 +680,11 @@ const ct = [
|
|
|
686
680
|
{
|
|
687
681
|
type: "button",
|
|
688
682
|
"data-aqmb-signout-button": !0,
|
|
689
|
-
className: `aiquants-signout-button flex ${
|
|
683
|
+
className: `aiquants-signout-button flex ${ae} flex-1 items-center justify-center gap-1.5 rounded-md bg-red-500/90 px-2.5 font-medium ${R} text-white shadow-2xs transition-colors duration-200 hover:bg-red-600 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-red-300/60 dark:bg-red-600/90 dark:hover:bg-red-500`,
|
|
690
684
|
onClick: o,
|
|
691
685
|
children: [
|
|
692
|
-
/* @__PURE__ */ r.jsx(
|
|
693
|
-
/* @__PURE__ */ r.jsx("span", { children: "サインアウト" })
|
|
686
|
+
/* @__PURE__ */ r.jsx(Xe, { size: 11, className: "shrink-0" }),
|
|
687
|
+
/* @__PURE__ */ r.jsx("span", { className: "text-center", children: "サインアウト" })
|
|
694
688
|
]
|
|
695
689
|
}
|
|
696
690
|
)
|
|
@@ -698,9 +692,9 @@ const ct = [
|
|
|
698
692
|
]
|
|
699
693
|
}
|
|
700
694
|
);
|
|
701
|
-
}, vt = (t) => {
|
|
702
|
-
t.preventDefault();
|
|
703
695
|
}, gt = (t) => {
|
|
696
|
+
t.preventDefault();
|
|
697
|
+
}, kt = (t) => {
|
|
704
698
|
const { isOverlay: n, onOverlayClick: a } = t;
|
|
705
699
|
return /* @__PURE__ */ r.jsx(
|
|
706
700
|
"div",
|
|
@@ -709,7 +703,7 @@ const ct = [
|
|
|
709
703
|
"data-aqmb-menu-overlay": !0,
|
|
710
704
|
inert: !n,
|
|
711
705
|
className: `fixed inset-0 z-2147483640 bg-black/50 motion-safe:transition-opacity motion-safe:duration-500 ${n ? "opacity-100" : "pointer-events-none opacity-0"}`,
|
|
712
|
-
onMouseDown:
|
|
706
|
+
onMouseDown: gt,
|
|
713
707
|
onClick: a
|
|
714
708
|
}
|
|
715
709
|
);
|
|
@@ -721,34 +715,34 @@ const ct = [
|
|
|
721
715
|
/* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-switch-bar" })
|
|
722
716
|
] }),
|
|
723
717
|
/* @__PURE__ */ r.jsx("span", { className: "aiquants-menu-switch-caption", "aria-hidden": "true", children: t ? "close" : "menu" })
|
|
724
|
-
] }),
|
|
718
|
+
] }), se = typeof window < "u" ? ye : F, Et = (t) => {
|
|
725
719
|
const {
|
|
726
720
|
menuList: n,
|
|
727
721
|
menuHeader: a,
|
|
728
722
|
onClickSignout: s,
|
|
729
|
-
isMenuhide:
|
|
723
|
+
isMenuhide: l,
|
|
730
724
|
isMenuHide: o,
|
|
731
725
|
theme: u,
|
|
732
726
|
toggleTheme: d,
|
|
733
727
|
onMenuNavigate: m,
|
|
734
|
-
isPinned:
|
|
728
|
+
isPinned: x,
|
|
735
729
|
pinnedWidth: y = 240,
|
|
736
730
|
onPinChange: N,
|
|
737
|
-
pinnedSubmenuIds:
|
|
731
|
+
pinnedSubmenuIds: w,
|
|
738
732
|
initialPinnedSubmenuIds: j,
|
|
739
|
-
onSubmenuPinChange:
|
|
740
|
-
closeOnEscape:
|
|
741
|
-
} = t,
|
|
733
|
+
onSubmenuPinChange: C,
|
|
734
|
+
closeOnEscape: I = "auto"
|
|
735
|
+
} = t, c = o ?? l ?? !1, [p, S] = X(() => {
|
|
742
736
|
try {
|
|
743
737
|
return localStorage.getItem("aiquants-menu-pinned") === "true";
|
|
744
738
|
} catch {
|
|
745
739
|
return !1;
|
|
746
740
|
}
|
|
747
|
-
}),
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
}, [
|
|
751
|
-
const [
|
|
741
|
+
}), k = x !== void 0 ? x : p, [T, O] = X(k);
|
|
742
|
+
F(() => {
|
|
743
|
+
k && O(!0);
|
|
744
|
+
}, [k]);
|
|
745
|
+
const [D, Q] = X(() => {
|
|
752
746
|
if (j)
|
|
753
747
|
return j;
|
|
754
748
|
try {
|
|
@@ -761,93 +755,93 @@ const ct = [
|
|
|
761
755
|
} catch {
|
|
762
756
|
}
|
|
763
757
|
return [];
|
|
764
|
-
}),
|
|
758
|
+
}), K = w !== void 0 ? w : D, z = _(
|
|
765
759
|
(h) => {
|
|
766
|
-
const e =
|
|
767
|
-
if (
|
|
760
|
+
const e = w !== void 0 ? w : D, i = e.includes(h) ? e.filter((f) => f !== h) : [...e, h];
|
|
761
|
+
if (w === void 0) {
|
|
768
762
|
Q(i);
|
|
769
763
|
try {
|
|
770
764
|
localStorage.setItem("aiquants-submenu-pinned", JSON.stringify(i));
|
|
771
765
|
} catch {
|
|
772
766
|
}
|
|
773
767
|
}
|
|
774
|
-
|
|
768
|
+
C && C(i);
|
|
775
769
|
},
|
|
776
|
-
[
|
|
777
|
-
),
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
}, [N]),
|
|
781
|
-
const h =
|
|
782
|
-
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", e),
|
|
783
|
-
}, [
|
|
784
|
-
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", "0px"),
|
|
770
|
+
[w, D, C]
|
|
771
|
+
), H = $(N);
|
|
772
|
+
se(() => {
|
|
773
|
+
H.current = N;
|
|
774
|
+
}, [N]), se(() => {
|
|
775
|
+
const h = k ? y : 0, e = `${h}px`;
|
|
776
|
+
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", e), be(k, h, T || k);
|
|
777
|
+
}, [k, y, T]), se(() => () => {
|
|
778
|
+
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", "0px"), be(!1, 0);
|
|
785
779
|
}, []);
|
|
786
|
-
const
|
|
787
|
-
|
|
788
|
-
}, []),
|
|
780
|
+
const U = $(null), q = $(null), P = _(() => {
|
|
781
|
+
q.current?.contains(document.activeElement) && U.current?.focus();
|
|
782
|
+
}, []), ee = _(() => {
|
|
789
783
|
O(!0);
|
|
790
|
-
}, []),
|
|
791
|
-
if (
|
|
784
|
+
}, []), M = _(() => {
|
|
785
|
+
if (P(), O(!1), x === void 0) {
|
|
792
786
|
S(!1);
|
|
793
787
|
try {
|
|
794
788
|
localStorage.removeItem("aiquants-menu-pinned");
|
|
795
789
|
} catch {
|
|
796
790
|
}
|
|
797
791
|
}
|
|
798
|
-
|
|
799
|
-
}, [
|
|
800
|
-
const h = !
|
|
801
|
-
if (
|
|
792
|
+
H.current?.(!1, 0);
|
|
793
|
+
}, [x, P]), G = _(() => {
|
|
794
|
+
const h = !k, e = h ? y : 0;
|
|
795
|
+
if (x === void 0) {
|
|
802
796
|
S(h);
|
|
803
797
|
try {
|
|
804
798
|
h ? localStorage.setItem("aiquants-menu-pinned", "true") : localStorage.removeItem("aiquants-menu-pinned");
|
|
805
799
|
} catch {
|
|
806
800
|
}
|
|
807
801
|
}
|
|
808
|
-
|
|
809
|
-
}, [
|
|
802
|
+
H.current?.(h, e);
|
|
803
|
+
}, [k, x, y]), B = _(
|
|
810
804
|
(h) => {
|
|
811
|
-
m && m(h),
|
|
805
|
+
m && m(h), k || (P(), O(!1));
|
|
812
806
|
},
|
|
813
|
-
[m,
|
|
814
|
-
),
|
|
807
|
+
[m, k, P]
|
|
808
|
+
), A = _(
|
|
815
809
|
(h) => {
|
|
816
|
-
h.key === "Escape" &&
|
|
810
|
+
h.key === "Escape" && M();
|
|
817
811
|
},
|
|
818
|
-
[
|
|
819
|
-
),
|
|
820
|
-
return
|
|
821
|
-
window.removeEventListener("keydown",
|
|
822
|
-
}), [
|
|
823
|
-
/* @__PURE__ */ r.jsx(wt, { ref:
|
|
812
|
+
[M]
|
|
813
|
+
), Y = I === !0 || I === "auto" && !k;
|
|
814
|
+
return F(() => (T && Y ? window.addEventListener("keydown", A) : window.removeEventListener("keydown", A), () => {
|
|
815
|
+
window.removeEventListener("keydown", A);
|
|
816
|
+
}), [T, Y, A]), c ? null : /* @__PURE__ */ r.jsxs("div", { className: `aiquants-menu-bar ${u}`, children: [
|
|
817
|
+
/* @__PURE__ */ r.jsx(wt, { ref: U, isMenuOpen: T, onMenuOpen: ee, onMenuClose: M }),
|
|
824
818
|
/* @__PURE__ */ r.jsx(
|
|
825
819
|
xt,
|
|
826
820
|
{
|
|
827
|
-
ref:
|
|
821
|
+
ref: q,
|
|
828
822
|
menuList: n,
|
|
829
823
|
menuHeader: a,
|
|
830
824
|
onClickSignout: s,
|
|
831
|
-
onMenuSelected:
|
|
832
|
-
open:
|
|
825
|
+
onMenuSelected: B,
|
|
826
|
+
open: T,
|
|
833
827
|
theme: u,
|
|
834
828
|
toggleTheme: d,
|
|
835
|
-
isPinned:
|
|
836
|
-
onTogglePin:
|
|
837
|
-
pinnedSubmenuIds:
|
|
838
|
-
onToggleSubmenuPin:
|
|
829
|
+
isPinned: k,
|
|
830
|
+
onTogglePin: G,
|
|
831
|
+
pinnedSubmenuIds: K,
|
|
832
|
+
onToggleSubmenuPin: z
|
|
839
833
|
}
|
|
840
834
|
),
|
|
841
|
-
/* @__PURE__ */ r.jsx(
|
|
835
|
+
/* @__PURE__ */ r.jsx(kt, { isOverlay: T && !k, onOverlayClick: M })
|
|
842
836
|
] });
|
|
843
837
|
};
|
|
844
838
|
export {
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
839
|
+
Be as DefaultLink,
|
|
840
|
+
ie as MENU_PIN_CHANGE_EVENT,
|
|
841
|
+
Et as MenuBar,
|
|
842
|
+
_t as SessionInfo,
|
|
843
|
+
be as dispatchMenuPinChange,
|
|
850
844
|
je as getInitialPinState,
|
|
851
|
-
|
|
852
|
-
|
|
845
|
+
Ze as subscribeMenuPinChange,
|
|
846
|
+
jt as useMenuPinState
|
|
853
847
|
};
|