@aiquants/menu-bar 1.17.6 → 1.17.9
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/index.es.js +430 -304
- package/dist/index.umd.js +2 -2
- package/dist/styles/menu-bar.standalone.css +1 -1
- package/package.json +1 -1
- package/src/contents/MenuContent.tsx +13 -10
- package/src/contents/MenuList.tsx +8 -1
- package/src/lucide-icons.d.ts +6 -0
- package/src/styles/menu-bar.css +194 -196
package/dist/index.es.js
CHANGED
|
@@ -1,50 +1,49 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
var
|
|
5
|
-
var re;
|
|
1
|
+
import ke, { forwardRef as me, createElement as B, useMemo as re, useState as z, useRef as C, useEffect as L, useCallback as w, useLayoutEffect as pe } from "react";
|
|
2
|
+
import { useLocation as we, Link as he } from "react-router-dom";
|
|
3
|
+
var D = { exports: {} }, O = {};
|
|
4
|
+
var oe;
|
|
6
5
|
function je() {
|
|
7
|
-
if (
|
|
8
|
-
|
|
9
|
-
var
|
|
10
|
-
function a
|
|
6
|
+
if (oe) return O;
|
|
7
|
+
oe = 1;
|
|
8
|
+
var n = /* @__PURE__ */ Symbol.for("react.transitional.element"), r = /* @__PURE__ */ Symbol.for("react.fragment");
|
|
9
|
+
function o(a, c, i) {
|
|
11
10
|
var u = null;
|
|
12
11
|
if (i !== void 0 && (u = "" + i), c.key !== void 0 && (u = "" + c.key), "key" in c) {
|
|
13
12
|
i = {};
|
|
14
|
-
for (var
|
|
15
|
-
|
|
13
|
+
for (var p in c)
|
|
14
|
+
p !== "key" && (i[p] = c[p]);
|
|
16
15
|
} else i = c;
|
|
17
16
|
return c = i.ref, {
|
|
18
|
-
$$typeof:
|
|
19
|
-
type:
|
|
17
|
+
$$typeof: n,
|
|
18
|
+
type: a,
|
|
20
19
|
key: u,
|
|
21
20
|
ref: c !== void 0 ? c : null,
|
|
22
21
|
props: i
|
|
23
22
|
};
|
|
24
23
|
}
|
|
25
|
-
return
|
|
24
|
+
return O.Fragment = r, O.jsx = o, O.jsxs = o, O;
|
|
26
25
|
}
|
|
27
|
-
var
|
|
26
|
+
var I = {};
|
|
28
27
|
var se;
|
|
29
|
-
function
|
|
28
|
+
function Ne() {
|
|
30
29
|
return se || (se = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
31
|
-
function
|
|
30
|
+
function n(e) {
|
|
32
31
|
if (e == null) return null;
|
|
33
32
|
if (typeof e == "function")
|
|
34
|
-
return e.$$typeof ===
|
|
33
|
+
return e.$$typeof === k ? null : e.displayName || e.name || null;
|
|
35
34
|
if (typeof e == "string") return e;
|
|
36
35
|
switch (e) {
|
|
37
36
|
case m:
|
|
38
37
|
return "Fragment";
|
|
39
|
-
case
|
|
38
|
+
case N:
|
|
40
39
|
return "Profiler";
|
|
41
|
-
case
|
|
40
|
+
case _:
|
|
42
41
|
return "StrictMode";
|
|
43
42
|
case P:
|
|
44
43
|
return "Suspense";
|
|
45
|
-
case
|
|
44
|
+
case H:
|
|
46
45
|
return "SuspenseList";
|
|
47
|
-
case
|
|
46
|
+
case q:
|
|
48
47
|
return "Activity";
|
|
49
48
|
}
|
|
50
49
|
if (typeof e == "object")
|
|
@@ -53,19 +52,19 @@ function Ee() {
|
|
|
53
52
|
), e.$$typeof) {
|
|
54
53
|
case s:
|
|
55
54
|
return "Portal";
|
|
56
|
-
case
|
|
55
|
+
case F:
|
|
57
56
|
return e.displayName || "Context";
|
|
58
|
-
case
|
|
57
|
+
case Y:
|
|
59
58
|
return (e._context.displayName || "Context") + ".Consumer";
|
|
60
|
-
case
|
|
61
|
-
var
|
|
62
|
-
return e = e.displayName, e || (e =
|
|
63
|
-
case
|
|
64
|
-
return
|
|
65
|
-
case
|
|
66
|
-
|
|
59
|
+
case V:
|
|
60
|
+
var l = e.render;
|
|
61
|
+
return e = e.displayName, e || (e = l.displayName || l.name || "", e = e !== "" ? "ForwardRef(" + e + ")" : "ForwardRef"), e;
|
|
62
|
+
case W:
|
|
63
|
+
return l = e.displayName || null, l !== null ? l : n(e.type) || "Memo";
|
|
64
|
+
case T:
|
|
65
|
+
l = e._payload, e = e._init;
|
|
67
66
|
try {
|
|
68
|
-
return
|
|
67
|
+
return n(e(l));
|
|
69
68
|
} catch {
|
|
70
69
|
}
|
|
71
70
|
}
|
|
@@ -74,77 +73,77 @@ function Ee() {
|
|
|
74
73
|
function r(e) {
|
|
75
74
|
return "" + e;
|
|
76
75
|
}
|
|
77
|
-
function
|
|
76
|
+
function o(e) {
|
|
78
77
|
try {
|
|
79
78
|
r(e);
|
|
80
|
-
var
|
|
79
|
+
var l = !1;
|
|
81
80
|
} catch {
|
|
82
|
-
|
|
81
|
+
l = !0;
|
|
83
82
|
}
|
|
84
|
-
if (
|
|
85
|
-
|
|
86
|
-
var
|
|
87
|
-
return
|
|
88
|
-
|
|
83
|
+
if (l) {
|
|
84
|
+
l = console;
|
|
85
|
+
var h = l.error, y = typeof Symbol == "function" && Symbol.toStringTag && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
86
|
+
return h.call(
|
|
87
|
+
l,
|
|
89
88
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
90
|
-
|
|
89
|
+
y
|
|
91
90
|
), r(e);
|
|
92
91
|
}
|
|
93
92
|
}
|
|
94
|
-
function
|
|
93
|
+
function a(e) {
|
|
95
94
|
if (e === m) return "<>";
|
|
96
|
-
if (typeof e == "object" && e !== null && e.$$typeof ===
|
|
95
|
+
if (typeof e == "object" && e !== null && e.$$typeof === T)
|
|
97
96
|
return "<...>";
|
|
98
97
|
try {
|
|
99
|
-
var
|
|
100
|
-
return
|
|
98
|
+
var l = n(e);
|
|
99
|
+
return l ? "<" + l + ">" : "<...>";
|
|
101
100
|
} catch {
|
|
102
101
|
return "<...>";
|
|
103
102
|
}
|
|
104
103
|
}
|
|
105
104
|
function c() {
|
|
106
|
-
var e =
|
|
105
|
+
var e = E.A;
|
|
107
106
|
return e === null ? null : e.getOwner();
|
|
108
107
|
}
|
|
109
108
|
function i() {
|
|
110
109
|
return Error("react-stack-top-frame");
|
|
111
110
|
}
|
|
112
111
|
function u(e) {
|
|
113
|
-
if (
|
|
114
|
-
var
|
|
115
|
-
if (
|
|
112
|
+
if (R.call(e, "key")) {
|
|
113
|
+
var l = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
114
|
+
if (l && l.isReactWarning) return !1;
|
|
116
115
|
}
|
|
117
116
|
return e.key !== void 0;
|
|
118
117
|
}
|
|
119
|
-
function
|
|
120
|
-
function
|
|
121
|
-
|
|
118
|
+
function p(e, l) {
|
|
119
|
+
function h() {
|
|
120
|
+
X || (X = !0, console.error(
|
|
122
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)",
|
|
123
|
-
|
|
122
|
+
l
|
|
124
123
|
));
|
|
125
124
|
}
|
|
126
|
-
|
|
127
|
-
get:
|
|
125
|
+
h.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
126
|
+
get: h,
|
|
128
127
|
configurable: !0
|
|
129
128
|
});
|
|
130
129
|
}
|
|
131
|
-
function
|
|
132
|
-
var e =
|
|
133
|
-
return
|
|
130
|
+
function b() {
|
|
131
|
+
var e = n(this.type);
|
|
132
|
+
return K[e] || (K[e] = !0, console.error(
|
|
134
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."
|
|
135
134
|
)), e = this.props.ref, e !== void 0 ? e : null;
|
|
136
135
|
}
|
|
137
|
-
function d(e,
|
|
138
|
-
var
|
|
136
|
+
function d(e, l, h, y, $, J) {
|
|
137
|
+
var v = h.ref;
|
|
139
138
|
return e = {
|
|
140
|
-
$$typeof:
|
|
139
|
+
$$typeof: S,
|
|
141
140
|
type: e,
|
|
142
|
-
key:
|
|
143
|
-
props:
|
|
144
|
-
_owner:
|
|
145
|
-
}, (
|
|
141
|
+
key: l,
|
|
142
|
+
props: h,
|
|
143
|
+
_owner: y
|
|
144
|
+
}, (v !== void 0 ? v : null) !== null ? Object.defineProperty(e, "ref", {
|
|
146
145
|
enumerable: !1,
|
|
147
|
-
get:
|
|
146
|
+
get: b
|
|
148
147
|
}) : Object.defineProperty(e, "ref", { enumerable: !1, value: null }), e._store = {}, Object.defineProperty(e._store, "validated", {
|
|
149
148
|
configurable: !1,
|
|
150
149
|
enumerable: !1,
|
|
@@ -159,69 +158,69 @@ function Ee() {
|
|
|
159
158
|
configurable: !1,
|
|
160
159
|
enumerable: !1,
|
|
161
160
|
writable: !0,
|
|
162
|
-
value:
|
|
161
|
+
value: $
|
|
163
162
|
}), Object.defineProperty(e, "_debugTask", {
|
|
164
163
|
configurable: !1,
|
|
165
164
|
enumerable: !1,
|
|
166
165
|
writable: !0,
|
|
167
|
-
value:
|
|
166
|
+
value: J
|
|
168
167
|
}), Object.freeze && (Object.freeze(e.props), Object.freeze(e)), e;
|
|
169
168
|
}
|
|
170
|
-
function f(e,
|
|
171
|
-
var
|
|
172
|
-
if (
|
|
173
|
-
if (
|
|
174
|
-
if (
|
|
175
|
-
for (
|
|
176
|
-
|
|
177
|
-
Object.freeze && Object.freeze(
|
|
169
|
+
function f(e, l, h, y, $, J) {
|
|
170
|
+
var v = l.children;
|
|
171
|
+
if (v !== void 0)
|
|
172
|
+
if (y)
|
|
173
|
+
if (U(v)) {
|
|
174
|
+
for (y = 0; y < v.length; y++)
|
|
175
|
+
g(v[y]);
|
|
176
|
+
Object.freeze && Object.freeze(v);
|
|
178
177
|
} else
|
|
179
178
|
console.error(
|
|
180
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."
|
|
181
180
|
);
|
|
182
|
-
else
|
|
183
|
-
if (
|
|
184
|
-
|
|
185
|
-
var
|
|
186
|
-
return
|
|
181
|
+
else g(v);
|
|
182
|
+
if (R.call(l, "key")) {
|
|
183
|
+
v = n(e);
|
|
184
|
+
var A = Object.keys(l).filter(function(ge) {
|
|
185
|
+
return ge !== "key";
|
|
187
186
|
});
|
|
188
|
-
|
|
187
|
+
y = 0 < A.length ? "{key: someKey, " + A.join(": ..., ") + ": ...}" : "{key: someKey}", ne[v + y] || (A = 0 < A.length ? "{" + A.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
189
188
|
`A props object containing a "key" prop is being spread into JSX:
|
|
190
189
|
let props = %s;
|
|
191
190
|
<%s {...props} />
|
|
192
191
|
React keys must be passed directly to JSX without using spread:
|
|
193
192
|
let props = %s;
|
|
194
193
|
<%s key={someKey} {...props} />`,
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
),
|
|
194
|
+
y,
|
|
195
|
+
v,
|
|
196
|
+
A,
|
|
197
|
+
v
|
|
198
|
+
), ne[v + y] = !0);
|
|
200
199
|
}
|
|
201
|
-
if (
|
|
202
|
-
|
|
203
|
-
for (var
|
|
204
|
-
|
|
205
|
-
} else
|
|
206
|
-
return
|
|
207
|
-
|
|
200
|
+
if (v = null, h !== void 0 && (o(h), v = "" + h), u(l) && (o(l.key), v = "" + l.key), "key" in l) {
|
|
201
|
+
h = {};
|
|
202
|
+
for (var G in l)
|
|
203
|
+
G !== "key" && (h[G] = l[G]);
|
|
204
|
+
} else h = l;
|
|
205
|
+
return v && p(
|
|
206
|
+
h,
|
|
208
207
|
typeof e == "function" ? e.displayName || e.name || "Unknown" : e
|
|
209
208
|
), d(
|
|
210
209
|
e,
|
|
211
|
-
|
|
212
|
-
|
|
210
|
+
v,
|
|
211
|
+
h,
|
|
213
212
|
c(),
|
|
214
|
-
|
|
215
|
-
|
|
213
|
+
$,
|
|
214
|
+
J
|
|
216
215
|
);
|
|
217
216
|
}
|
|
218
|
-
function
|
|
219
|
-
j(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof ===
|
|
217
|
+
function g(e) {
|
|
218
|
+
j(e) ? e._store && (e._store.validated = 1) : typeof e == "object" && e !== null && e.$$typeof === T && (e._payload.status === "fulfilled" ? j(e._payload.value) && e._payload.value._store && (e._payload.value._store.validated = 1) : e._store && (e._store.validated = 1));
|
|
220
219
|
}
|
|
221
220
|
function j(e) {
|
|
222
|
-
return typeof e == "object" && e !== null && e.$$typeof ===
|
|
221
|
+
return typeof e == "object" && e !== null && e.$$typeof === S;
|
|
223
222
|
}
|
|
224
|
-
var x =
|
|
223
|
+
var x = ke, S = /* @__PURE__ */ Symbol.for("react.transitional.element"), s = /* @__PURE__ */ Symbol.for("react.portal"), m = /* @__PURE__ */ Symbol.for("react.fragment"), _ = /* @__PURE__ */ Symbol.for("react.strict_mode"), N = /* @__PURE__ */ Symbol.for("react.profiler"), Y = /* @__PURE__ */ Symbol.for("react.consumer"), F = /* @__PURE__ */ Symbol.for("react.context"), V = /* @__PURE__ */ Symbol.for("react.forward_ref"), P = /* @__PURE__ */ Symbol.for("react.suspense"), H = /* @__PURE__ */ Symbol.for("react.suspense_list"), W = /* @__PURE__ */ Symbol.for("react.memo"), T = /* @__PURE__ */ Symbol.for("react.lazy"), q = /* @__PURE__ */ Symbol.for("react.activity"), k = /* @__PURE__ */ Symbol.for("react.client.reference"), E = x.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, R = Object.prototype.hasOwnProperty, U = Array.isArray, Z = console.createTask ? console.createTask : function() {
|
|
225
224
|
return null;
|
|
226
225
|
};
|
|
227
226
|
x = {
|
|
@@ -229,70 +228,195 @@ React keys must be passed directly to JSX without using spread:
|
|
|
229
228
|
return e();
|
|
230
229
|
}
|
|
231
230
|
};
|
|
232
|
-
var
|
|
231
|
+
var X, K = {}, ee = x.react_stack_bottom_frame.bind(
|
|
233
232
|
x,
|
|
234
233
|
i
|
|
235
|
-
)(),
|
|
236
|
-
|
|
237
|
-
var
|
|
234
|
+
)(), te = Z(a(i)), ne = {};
|
|
235
|
+
I.Fragment = m, I.jsx = function(e, l, h) {
|
|
236
|
+
var y = 1e4 > E.recentlyCreatedOwnerStacks++;
|
|
238
237
|
return f(
|
|
239
238
|
e,
|
|
240
|
-
|
|
241
|
-
|
|
239
|
+
l,
|
|
240
|
+
h,
|
|
242
241
|
!1,
|
|
243
|
-
|
|
244
|
-
|
|
242
|
+
y ? Error("react-stack-top-frame") : ee,
|
|
243
|
+
y ? Z(a(e)) : te
|
|
245
244
|
);
|
|
246
|
-
},
|
|
247
|
-
var
|
|
245
|
+
}, I.jsxs = function(e, l, h) {
|
|
246
|
+
var y = 1e4 > E.recentlyCreatedOwnerStacks++;
|
|
248
247
|
return f(
|
|
249
248
|
e,
|
|
250
|
-
|
|
251
|
-
|
|
249
|
+
l,
|
|
250
|
+
h,
|
|
252
251
|
!0,
|
|
253
|
-
|
|
254
|
-
|
|
252
|
+
y ? Error("react-stack-top-frame") : ee,
|
|
253
|
+
y ? Z(a(e)) : te
|
|
255
254
|
);
|
|
256
255
|
};
|
|
257
|
-
})()),
|
|
256
|
+
})()), I;
|
|
258
257
|
}
|
|
259
|
-
var
|
|
260
|
-
function
|
|
261
|
-
return
|
|
258
|
+
var ae;
|
|
259
|
+
function Ee() {
|
|
260
|
+
return ae || (ae = 1, process.env.NODE_ENV === "production" ? D.exports = je() : D.exports = Ne()), D.exports;
|
|
262
261
|
}
|
|
263
|
-
var
|
|
264
|
-
const
|
|
265
|
-
const { user: r, LinkComponent:
|
|
266
|
-
return /* @__PURE__ */
|
|
267
|
-
/* @__PURE__ */
|
|
268
|
-
/* @__PURE__ */
|
|
269
|
-
/* @__PURE__ */
|
|
270
|
-
/* @__PURE__ */
|
|
271
|
-
/* @__PURE__ */
|
|
272
|
-
/* @__PURE__ */
|
|
262
|
+
var t = Ee();
|
|
263
|
+
const _e = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0iI2NiZDVlMSI+PHBhdGggZD0iTTEyIDEyYzIuMjEgMCA0LTEuNzkgNC00cy0xLjc5LTQtNC00LTQgMS43OS00IDQgMS43OSA0IDQgNHptMCAyYy0yLjY3IDAtOCAxLjM0LTggNHYyaDE2di0yYzAtMi42Ni01LjMzLTQtOC00eiIvPjwvc3ZnPg==", Se = ({ to: n, className: r, children: o }) => /* @__PURE__ */ t.jsx("a", { href: n, className: r, children: o }), nt = (n) => {
|
|
264
|
+
const { user: r, LinkComponent: o = Se } = n;
|
|
265
|
+
return /* @__PURE__ */ t.jsx("div", { className: "max-h-20 max-w-52", children: /* @__PURE__ */ t.jsx("div", { className: "flex grow flex-col", children: r ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
266
|
+
/* @__PURE__ */ t.jsxs("div", { className: "flex flex-row", children: [
|
|
267
|
+
/* @__PURE__ */ t.jsx("div", { className: "aiquants-session-photo m-1 h-14 w-14 p-0.5", children: /* @__PURE__ */ t.jsx("img", { className: "object-contain", src: r.photo || _e, "aria-label": "profile photo" }) }),
|
|
268
|
+
/* @__PURE__ */ t.jsxs("div", { className: "mx-1 flex flex-col", children: [
|
|
269
|
+
/* @__PURE__ */ t.jsx(o, { className: "aiquants-session-link my-1 rounded-lg px-2 text-center text-xs", to: "/", children: "プロフィールを編集" }),
|
|
270
|
+
/* @__PURE__ */ t.jsx(o, { className: "aiquants-session-link rounded-lg px-2 text-center text-xs", to: "/", children: "プロフィール" }),
|
|
271
|
+
/* @__PURE__ */ t.jsx(o, { className: "aiquants-session-link my-1 rounded-lg px-2 text-center text-xs", to: "https://myaccount.google.com/", children: "Google Account" })
|
|
273
272
|
] })
|
|
274
273
|
] }),
|
|
275
|
-
/* @__PURE__ */
|
|
276
|
-
] }) : /* @__PURE__ */
|
|
277
|
-
}
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
274
|
+
/* @__PURE__ */ t.jsx("div", { className: "aiquants-session-info mb-1 min-h-[1em] w-full rounded-r-lg px-2 py-0.5 text-xs", children: r.displayName })
|
|
275
|
+
] }) : /* @__PURE__ */ t.jsx("div", { className: "aiquants-session-info mb-1 min-h-[1em] w-9/12 rounded-r-lg py-0.5 pl-1 text-xs", children: "ログインはこちら" }) }) });
|
|
276
|
+
};
|
|
277
|
+
const Ce = (n) => n.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), Te = (n) => n.replace(
|
|
278
|
+
/^([A-Z])|[\s-_]+(\w)/g,
|
|
279
|
+
(r, o, a) => a ? a.toUpperCase() : o.toLowerCase()
|
|
280
|
+
), le = (n) => {
|
|
281
|
+
const r = Te(n);
|
|
282
|
+
return r.charAt(0).toUpperCase() + r.slice(1);
|
|
283
|
+
}, be = (...n) => n.filter((r, o, a) => !!r && r.trim() !== "" && a.indexOf(r) === o).join(" ").trim(), Re = (n) => {
|
|
284
|
+
for (const r in n)
|
|
285
|
+
if (r.startsWith("aria-") || r === "role" || r === "title")
|
|
286
|
+
return !0;
|
|
287
|
+
};
|
|
288
|
+
var Me = {
|
|
289
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
290
|
+
width: 24,
|
|
291
|
+
height: 24,
|
|
292
|
+
viewBox: "0 0 24 24",
|
|
293
|
+
fill: "none",
|
|
294
|
+
stroke: "currentColor",
|
|
295
|
+
strokeWidth: 2,
|
|
296
|
+
strokeLinecap: "round",
|
|
297
|
+
strokeLinejoin: "round"
|
|
298
|
+
};
|
|
299
|
+
const Pe = me(
|
|
300
|
+
({
|
|
301
|
+
color: n = "currentColor",
|
|
302
|
+
size: r = 24,
|
|
303
|
+
strokeWidth: o = 2,
|
|
304
|
+
absoluteStrokeWidth: a,
|
|
305
|
+
className: c = "",
|
|
306
|
+
children: i,
|
|
307
|
+
iconNode: u,
|
|
308
|
+
...p
|
|
309
|
+
}, b) => B(
|
|
310
|
+
"svg",
|
|
311
|
+
{
|
|
312
|
+
ref: b,
|
|
313
|
+
...Me,
|
|
314
|
+
width: r,
|
|
315
|
+
height: r,
|
|
316
|
+
stroke: n,
|
|
317
|
+
strokeWidth: a ? Number(o) * 24 / Number(r) : o,
|
|
318
|
+
className: be("lucide", c),
|
|
319
|
+
...!i && !Re(p) && { "aria-hidden": "true" },
|
|
320
|
+
...p
|
|
321
|
+
},
|
|
322
|
+
[
|
|
323
|
+
...u.map(([d, f]) => B(d, f)),
|
|
324
|
+
...Array.isArray(i) ? i : [i]
|
|
325
|
+
]
|
|
326
|
+
)
|
|
327
|
+
);
|
|
328
|
+
const M = (n, r) => {
|
|
329
|
+
const o = me(
|
|
330
|
+
({ className: a, ...c }, i) => B(Pe, {
|
|
331
|
+
ref: i,
|
|
332
|
+
iconNode: r,
|
|
333
|
+
className: be(
|
|
334
|
+
`lucide-${Ce(le(n))}`,
|
|
335
|
+
`lucide-${n}`,
|
|
336
|
+
a
|
|
337
|
+
),
|
|
338
|
+
...c
|
|
339
|
+
})
|
|
340
|
+
);
|
|
341
|
+
return o.displayName = le(n), o;
|
|
342
|
+
};
|
|
343
|
+
const Ae = [
|
|
344
|
+
["path", { d: "M12 17v5", key: "bb1du9" }],
|
|
345
|
+
[
|
|
346
|
+
"path",
|
|
347
|
+
{
|
|
348
|
+
d: "M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z",
|
|
349
|
+
key: "1nkz8b"
|
|
350
|
+
}
|
|
351
|
+
]
|
|
352
|
+
], xe = M("pin", Ae);
|
|
353
|
+
const Oe = [
|
|
354
|
+
["path", { d: "M12 17v5", key: "bb1du9" }],
|
|
355
|
+
["path", { d: "M15 9.34V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H7.89", key: "znwnzq" }],
|
|
356
|
+
["path", { d: "m2 2 20 20", key: "1ooewy" }],
|
|
357
|
+
[
|
|
358
|
+
"path",
|
|
359
|
+
{
|
|
360
|
+
d: "M9 9v1.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h11",
|
|
361
|
+
key: "c9qhm2"
|
|
362
|
+
}
|
|
363
|
+
]
|
|
364
|
+
], ye = M("pin-off", Oe);
|
|
365
|
+
const Ie = [
|
|
366
|
+
["path", { d: "M5 21v-6", key: "1hz6c0" }],
|
|
367
|
+
["path", { d: "M12 21V9", key: "uvy0l4" }],
|
|
368
|
+
["path", { d: "M19 21V3", key: "11j9sm" }]
|
|
369
|
+
], Le = M("chart-no-axes-column-increasing", Ie);
|
|
370
|
+
const qe = [
|
|
371
|
+
["path", { d: "M12 15V3", key: "m9g1x1" }],
|
|
372
|
+
["path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4", key: "ih7n3h" }],
|
|
373
|
+
["path", { d: "m7 10 5 5 5-5", key: "brsn70" }]
|
|
374
|
+
], $e = M("download", qe);
|
|
375
|
+
const De = [
|
|
376
|
+
[
|
|
377
|
+
"path",
|
|
378
|
+
{
|
|
379
|
+
d: "M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",
|
|
380
|
+
key: "1oefj6"
|
|
381
|
+
}
|
|
382
|
+
],
|
|
383
|
+
["path", { d: "M14 2v5a1 1 0 0 0 1 1h5", key: "wfsgrz" }],
|
|
384
|
+
["path", { d: "M10 9H8", key: "b1mrlr" }],
|
|
385
|
+
["path", { d: "M16 13H8", key: "t4e002" }],
|
|
386
|
+
["path", { d: "M16 17H8", key: "z1uh3a" }]
|
|
387
|
+
], ie = M("file-text", De);
|
|
388
|
+
const ze = [
|
|
389
|
+
["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" }],
|
|
390
|
+
["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" }]
|
|
391
|
+
], Ye = M("link", ze);
|
|
392
|
+
const Fe = [
|
|
393
|
+
["rect", { width: "18", height: "11", x: "3", y: "11", rx: "2", ry: "2", key: "1w4ew1" }],
|
|
394
|
+
["path", { d: "M7 11V7a5 5 0 0 1 10 0v4", key: "fwvmzm" }]
|
|
395
|
+
], Ve = M("lock", Fe);
|
|
396
|
+
const He = [
|
|
397
|
+
["path", { d: "M12 3v18", key: "108xh3" }],
|
|
398
|
+
["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
|
|
399
|
+
["path", { d: "M3 9h18", key: "1pudct" }],
|
|
400
|
+
["path", { d: "M3 15h18", key: "5xshup" }]
|
|
401
|
+
], We = M("table", He), Ue = typeof window < "u" ? pe : L, ce = "aiquants-menu-scroll", ve = new RegExp(/(^https?:\/\/)|(\.(html|htm)?$)/), Ze = {
|
|
402
|
+
report: ie,
|
|
403
|
+
slip: ie,
|
|
404
|
+
table: We,
|
|
405
|
+
chart: Le,
|
|
406
|
+
download: $e,
|
|
407
|
+
lock: Ve,
|
|
408
|
+
href: Ye
|
|
409
|
+
}, Je = ({ mark: n, children: r }) => {
|
|
410
|
+
const o = n ? Ze[n] : void 0;
|
|
411
|
+
return o ? /* @__PURE__ */ t.jsxs("div", { className: "flex flex-nowrap items-center", children: [
|
|
412
|
+
/* @__PURE__ */ t.jsx(o, { className: "h-4 w-4" }),
|
|
413
|
+
/* @__PURE__ */ t.jsx("div", { className: "aiquants-menu-link mx-1 hover:underline", children: r })
|
|
414
|
+
] }) : /* @__PURE__ */ t.jsx("span", { className: "mx-1 text-sky-600 hover:underline dark:text-sky-400", children: r });
|
|
415
|
+
}, Q = (n, r) => r ? {
|
|
292
416
|
menu: {
|
|
293
|
-
id:
|
|
294
|
-
title:
|
|
295
|
-
href:
|
|
417
|
+
id: n.id,
|
|
418
|
+
title: n.title,
|
|
419
|
+
href: n.href
|
|
296
420
|
},
|
|
297
421
|
submenu: {
|
|
298
422
|
subid: r.subid,
|
|
@@ -303,243 +427,245 @@ const Se = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMj
|
|
|
303
427
|
}
|
|
304
428
|
} : {
|
|
305
429
|
menu: {
|
|
306
|
-
id:
|
|
307
|
-
title:
|
|
308
|
-
href:
|
|
430
|
+
id: n.id,
|
|
431
|
+
title: n.title,
|
|
432
|
+
href: n.href
|
|
309
433
|
}
|
|
310
|
-
},
|
|
311
|
-
if (
|
|
312
|
-
return /* @__PURE__ */
|
|
313
|
-
const
|
|
434
|
+
}, Ge = ({ item: n, parentMenu: r, onMenuSelected: o }) => {
|
|
435
|
+
if (n.href === "separator")
|
|
436
|
+
return /* @__PURE__ */ t.jsx("hr", { className: "aiquants-menu-separator mx-2 my-1 h-px" });
|
|
437
|
+
const a = /* @__PURE__ */ t.jsx(Je, { mark: n.mark, children: n.title }), c = {
|
|
314
438
|
onClick: () => {
|
|
315
|
-
|
|
439
|
+
o && o(Q(r, n));
|
|
316
440
|
}
|
|
317
441
|
};
|
|
318
|
-
return
|
|
319
|
-
},
|
|
320
|
-
const
|
|
321
|
-
for (const
|
|
322
|
-
if (
|
|
323
|
-
return
|
|
324
|
-
if (
|
|
325
|
-
for (const c of
|
|
326
|
-
if (
|
|
327
|
-
return
|
|
442
|
+
return n.new ? /* @__PURE__ */ t.jsx("a", { href: n.href, rel: "noopener noreferrer", target: "_blank", ...c, children: a }) : ve.test(n.href) ? /* @__PURE__ */ t.jsx("a", { href: n.href, ...c, children: a }) : /* @__PURE__ */ t.jsx(he, { to: n.href, ...c, children: a });
|
|
443
|
+
}, ue = (n) => n ? n.split(/[?#]/)[0].replace(/(?!^\/)\/$/, "") : "", de = (n, r) => {
|
|
444
|
+
const o = r !== "/" && r.endsWith("/") ? r.slice(0, -1) : r;
|
|
445
|
+
for (const a of n) {
|
|
446
|
+
if (ue(a.href) === o)
|
|
447
|
+
return a.id;
|
|
448
|
+
if (a.submenu) {
|
|
449
|
+
for (const c of a.submenu)
|
|
450
|
+
if (ue(c.href) === o)
|
|
451
|
+
return a.id;
|
|
328
452
|
}
|
|
329
453
|
}
|
|
330
454
|
return null;
|
|
331
|
-
},
|
|
332
|
-
const { menuList: r, onMenuSelected:
|
|
455
|
+
}, Be = (n) => {
|
|
456
|
+
const { menuList: r, onMenuSelected: o, pinnedSubmenuIds: a = [], onToggleSubmenuPin: c } = n;
|
|
333
457
|
let i = "";
|
|
334
458
|
try {
|
|
335
|
-
i =
|
|
459
|
+
i = we().pathname;
|
|
336
460
|
} catch {
|
|
337
461
|
typeof window < "u" && (i = window.location.pathname);
|
|
338
462
|
}
|
|
339
|
-
const u =
|
|
340
|
-
|
|
463
|
+
const u = re(() => de(r, i), [r, i]), [p, b] = z(u), d = C(i), f = C(u !== null);
|
|
464
|
+
L(() => {
|
|
341
465
|
if (d.current !== i && (d.current = i, f.current = !1), !f.current) {
|
|
342
|
-
const s =
|
|
343
|
-
s !== null && (
|
|
466
|
+
const s = de(r, i);
|
|
467
|
+
s !== null && (b(s), f.current = !0);
|
|
344
468
|
}
|
|
345
469
|
}, [i, r]);
|
|
346
|
-
const
|
|
470
|
+
const g = w(
|
|
347
471
|
(s) => {
|
|
348
|
-
|
|
472
|
+
a.includes(s) || b((_) => _ === s ? null : s);
|
|
349
473
|
},
|
|
350
|
-
[
|
|
351
|
-
), j =
|
|
352
|
-
|
|
474
|
+
[a]
|
|
475
|
+
), j = C(null);
|
|
476
|
+
Ue(() => {
|
|
353
477
|
const s = j.current;
|
|
354
478
|
if (s)
|
|
355
479
|
try {
|
|
356
|
-
const m = sessionStorage.getItem(
|
|
480
|
+
const m = sessionStorage.getItem(ce);
|
|
357
481
|
if (m !== null) {
|
|
358
|
-
const
|
|
359
|
-
Number.isNaN(
|
|
482
|
+
const _ = Number.parseFloat(m);
|
|
483
|
+
Number.isNaN(_) || (s.scrollTop = _);
|
|
360
484
|
}
|
|
361
485
|
} catch {
|
|
362
486
|
}
|
|
363
487
|
}, []);
|
|
364
|
-
const x =
|
|
488
|
+
const x = w(() => {
|
|
365
489
|
const s = j.current;
|
|
366
490
|
if (s)
|
|
367
491
|
try {
|
|
368
|
-
sessionStorage.setItem(
|
|
492
|
+
sessionStorage.setItem(ce, String(s.scrollTop));
|
|
369
493
|
} catch {
|
|
370
494
|
}
|
|
371
|
-
}, []),
|
|
495
|
+
}, []), S = re(() => /* @__PURE__ */ t.jsx(t.Fragment, { children: r.map((s) => /* @__PURE__ */ t.jsx("div", { children: s.href ? /* @__PURE__ */ t.jsx("div", { className: "aiquants-menu-list-item relative mb-1 ml-1 h-full rounded-l-2xl p-2 align-middle text-sm before:-mt-1 before:mr-2 before:inline-block before:h-4 before:w-4 before:rounded-full before:align-middle before:content-['']", children: ve.test(s.href) ? /* @__PURE__ */ t.jsx(
|
|
372
496
|
"a",
|
|
373
497
|
{
|
|
374
498
|
href: s.href,
|
|
375
499
|
onClick: () => {
|
|
376
|
-
|
|
500
|
+
o && o(Q(s));
|
|
377
501
|
},
|
|
378
|
-
children: /* @__PURE__ */
|
|
502
|
+
children: /* @__PURE__ */ t.jsx("span", { className: "aiquants-menu-link hover:underline", children: s.title })
|
|
379
503
|
}
|
|
380
|
-
) : /* @__PURE__ */
|
|
381
|
-
|
|
504
|
+
) : /* @__PURE__ */ t.jsx(
|
|
505
|
+
he,
|
|
382
506
|
{
|
|
383
507
|
to: s.href,
|
|
384
508
|
onClick: () => {
|
|
385
|
-
|
|
509
|
+
o && o(Q(s));
|
|
386
510
|
},
|
|
387
|
-
children: /* @__PURE__ */
|
|
511
|
+
children: /* @__PURE__ */ t.jsx("span", { className: "aiquants-menu-link hover:underline", children: s.title })
|
|
388
512
|
}
|
|
389
|
-
) }) : /* @__PURE__ */
|
|
390
|
-
/* @__PURE__ */
|
|
513
|
+
) }) : /* @__PURE__ */ t.jsxs("details", { className: "aiquants-menu-accordion-details", open: s.id === p || a.includes(s.id), children: [
|
|
514
|
+
/* @__PURE__ */ t.jsxs(
|
|
391
515
|
"summary",
|
|
392
516
|
{
|
|
393
517
|
className: "aiquants-menu-list-item aiquants-menu-accordion-summary relative mb-1 ml-1 h-full list-none rounded-l-2xl p-2 text-sm outline-none before:mr-2 before:inline-block before:h-4 before:w-4 before:rounded-full before:content-['']",
|
|
394
518
|
onClick: (m) => {
|
|
395
|
-
m.preventDefault(),
|
|
519
|
+
m.preventDefault(), g(s.id);
|
|
396
520
|
},
|
|
397
521
|
onKeyDown: (m) => {
|
|
398
|
-
(m.key === "Enter" || m.key === " ") && (m.preventDefault(),
|
|
522
|
+
(m.key === "Enter" || m.key === " ") && (m.preventDefault(), g(s.id));
|
|
399
523
|
},
|
|
400
524
|
children: [
|
|
401
|
-
/* @__PURE__ */
|
|
402
|
-
/* @__PURE__ */
|
|
525
|
+
/* @__PURE__ */ t.jsx("span", { children: s.title }),
|
|
526
|
+
/* @__PURE__ */ t.jsx(
|
|
403
527
|
"button",
|
|
404
528
|
{
|
|
405
529
|
type: "button",
|
|
406
530
|
onClick: (m) => {
|
|
407
531
|
m.stopPropagation(), m.preventDefault(), c && c(s.id);
|
|
408
532
|
},
|
|
409
|
-
className: `aiquants-submenu-pin-button ${
|
|
410
|
-
title:
|
|
411
|
-
children:
|
|
533
|
+
className: `aiquants-submenu-pin-button ${a.includes(s.id) ? "pinned" : ""}`,
|
|
534
|
+
title: a.includes(s.id) ? "ピン留め解除" : "ピン留め",
|
|
535
|
+
children: a.includes(s.id) ? /* @__PURE__ */ t.jsx(xe, { size: 14 }) : /* @__PURE__ */ t.jsx(ye, { size: 14 })
|
|
412
536
|
}
|
|
413
537
|
)
|
|
414
538
|
]
|
|
415
539
|
}
|
|
416
540
|
),
|
|
417
|
-
/* @__PURE__ */
|
|
418
|
-
] }) }, s.id)) }), [r,
|
|
419
|
-
return /* @__PURE__ */
|
|
420
|
-
},
|
|
421
|
-
const { menuList: r, menuHeader:
|
|
422
|
-
return /* @__PURE__ */
|
|
423
|
-
/* @__PURE__ */
|
|
424
|
-
/* @__PURE__ */
|
|
425
|
-
/* @__PURE__ */
|
|
426
|
-
/* @__PURE__ */
|
|
541
|
+
/* @__PURE__ */ t.jsx("div", { className: "aiquants-menu-submenu pointer-events-auto my-1 mr-1 ml-4 rounded p-2 shadow-md", children: s.submenu.map((m) => /* @__PURE__ */ t.jsx("div", { className: "aiquants-menu-accordion-container block w-full whitespace-nowrap text-sm", children: /* @__PURE__ */ t.jsx(Ge, { item: m, parentMenu: s, onMenuSelected: o }) }, m.subid)) })
|
|
542
|
+
] }) }, s.id)) }), [r, o, p, g, a]);
|
|
543
|
+
return /* @__PURE__ */ t.jsx("div", { ref: j, onScroll: x, className: "hidden-scrollbar h-0 grow overflow-y-scroll", children: S });
|
|
544
|
+
}, Qe = (n) => {
|
|
545
|
+
const { menuList: r, menuHeader: o, open: a, onMenuSelected: c, onClickSignout: i, theme: u, toggleTheme: p, isPinned: b, onTogglePin: d, pinnedSubmenuIds: f, onToggleSubmenuPin: g } = n;
|
|
546
|
+
return /* @__PURE__ */ t.jsxs("div", { className: `aiquants-menu-content fixed top-0 right-0 z-2147483642 flex min-h-dvh w-[250px] select-none flex-col transition-transform duration-500 ${a ? "aiquants-menu-translate-x-0" : "aiquants-menu-translate-x-250"}`, children: [
|
|
547
|
+
/* @__PURE__ */ t.jsx("div", { className: "flex h-[100px] flex-col", children: o }),
|
|
548
|
+
/* @__PURE__ */ t.jsx("div", { className: "flex grow flex-col", children: /* @__PURE__ */ t.jsx(Be, { menuList: r, onMenuSelected: c, pinnedSubmenuIds: f, onToggleSubmenuPin: g }) }),
|
|
549
|
+
/* @__PURE__ */ t.jsx("div", { className: "px-4 pt-2 pb-4", children: /* @__PURE__ */ t.jsxs("div", { className: "flex items-center justify-between gap-2", children: [
|
|
550
|
+
/* @__PURE__ */ t.jsx(
|
|
427
551
|
"button",
|
|
428
552
|
{
|
|
429
553
|
type: "button",
|
|
430
554
|
onClick: d,
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
555
|
+
"data-aqmb-pin-button": !0,
|
|
556
|
+
className: `flex items-center justify-center rounded-md px-3 py-2 text-white text-xs shadow-sm transition-colors duration-300 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-amber-300/60 ${b ? "bg-amber-500/90 hover:bg-amber-600" : "border border-white/15 bg-white/10 hover:bg-white/20"}`,
|
|
557
|
+
title: b ? "ピン留め解除" : "ピン留め",
|
|
558
|
+
"aria-label": b ? "ピン留め解除" : "ピン留め",
|
|
559
|
+
children: b ? /* @__PURE__ */ t.jsx(xe, { size: 14 }) : /* @__PURE__ */ t.jsx(ye, { size: 14 })
|
|
434
560
|
}
|
|
435
561
|
),
|
|
436
|
-
/* @__PURE__ */
|
|
562
|
+
/* @__PURE__ */ t.jsx(
|
|
437
563
|
"button",
|
|
438
564
|
{
|
|
439
565
|
type: "button",
|
|
440
|
-
onClick:
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
]
|
|
566
|
+
onClick: p,
|
|
567
|
+
"data-aqmb-theme-button": !0,
|
|
568
|
+
className: "group relative flex items-center justify-center rounded-md border border-white/15 bg-white/10 px-3 py-2 text-white text-xs shadow-sm backdrop-blur-sm transition-all duration-300 hover:border-white/25 hover:bg-white/20 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-white/40 focus-visible:ring-offset-0 dark:border-gray-600/40 dark:bg-gray-800/80 dark:hover:border-gray-500/60 dark:hover:bg-gray-700",
|
|
569
|
+
title: u === "dark" ? "ライトモードに切り替え" : "ダークモードに切り替え",
|
|
570
|
+
"aria-label": u === "dark" ? "ライトモードに切り替え" : "ダークモードに切り替え",
|
|
571
|
+
children: /* @__PURE__ */ t.jsx("span", { className: "text-sm transition-transform duration-300 group-hover:scale-110", children: u === "dark" ? "🌞" : "🌙" })
|
|
447
572
|
}
|
|
448
573
|
),
|
|
449
|
-
/* @__PURE__ */
|
|
574
|
+
/* @__PURE__ */ t.jsx(
|
|
450
575
|
"button",
|
|
451
576
|
{
|
|
452
577
|
type: "button",
|
|
453
|
-
|
|
578
|
+
"data-aqmb-signout-button": !0,
|
|
579
|
+
className: "aiquants-signout-button flex flex-1 items-center justify-center whitespace-nowrap rounded-md bg-red-500/90 px-3 py-2 font-medium text-white text-xs shadow-sm transition-colors duration-300 hover:bg-red-500 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-red-300/60",
|
|
454
580
|
onClick: i,
|
|
455
|
-
children: /* @__PURE__ */
|
|
581
|
+
children: /* @__PURE__ */ t.jsx("span", { children: "サインアウト" })
|
|
456
582
|
}
|
|
457
583
|
)
|
|
458
584
|
] }) })
|
|
459
585
|
] });
|
|
460
|
-
},
|
|
461
|
-
const { isOverlay: r, onOverlayClick:
|
|
462
|
-
return /* @__PURE__ */
|
|
463
|
-
},
|
|
464
|
-
const { open: r, onMenuOpen:
|
|
465
|
-
if (u.current &&
|
|
466
|
-
const
|
|
467
|
-
u.current.style.backgroundColor =
|
|
586
|
+
}, Xe = (n) => {
|
|
587
|
+
const { isOverlay: r, onOverlayClick: o } = n;
|
|
588
|
+
return /* @__PURE__ */ t.jsx("button", { type: "button", className: `fixed inset-0 z-2147483640 cursor-default bg-black/50 transition-opacity duration-500 ${r ? "opacity-100" : "pointer-events-none opacity-0"}`, onClick: o });
|
|
589
|
+
}, Ke = (n) => {
|
|
590
|
+
const { open: r, onMenuOpen: o, onMenuClose: a, theme: c } = n, i = C(r), u = C(null), p = C(null), b = C(null), d = C(null), f = C(null), g = w(() => {
|
|
591
|
+
if (u.current && p.current && b.current && d.current && f.current) {
|
|
592
|
+
const N = c === "dark" ? "#fff" : "#000";
|
|
593
|
+
u.current.style.backgroundColor = N, u.current.style.width = "100%", u.current.style.height = "3px", u.current.style.transform = "", p.current.style.opacity = "1", p.current.style.backgroundColor = N, b.current.style.opacity = "1", b.current.style.backgroundColor = N, d.current.style.backgroundColor = N, d.current.style.width = "100%", d.current.style.height = "3px", d.current.style.transform = "", f.current.style.color = N, f.current.classList.remove("after:content-['close']"), f.current.classList.remove("after:ml-0.5"), f.current.classList.add("after:content-['menu']"), f.current.classList.add("after:-ml-0.5"), i.current = !0;
|
|
468
594
|
}
|
|
469
|
-
}, [c]), j =
|
|
470
|
-
u.current &&
|
|
471
|
-
}, []), x =
|
|
472
|
-
|
|
473
|
-
}, [
|
|
474
|
-
j(),
|
|
475
|
-
}, [j,
|
|
476
|
-
i.current ?
|
|
477
|
-
}, [x,
|
|
478
|
-
|
|
479
|
-
}, []),
|
|
480
|
-
|
|
595
|
+
}, [c]), j = w(() => {
|
|
596
|
+
u.current && p.current && b.current && d.current && f.current && (u.current.style.backgroundColor = "#fff", u.current.style.width = "32px", u.current.style.height = "4px", u.current.style.transform = "translateY(9px) rotate(-45deg)", p.current.style.opacity = "0", b.current.style.opacity = "0", d.current.style.backgroundColor = "#fff", d.current.style.width = "32px", d.current.style.height = "4px", d.current.style.transform = "translateY(-9px) rotate(45deg)", f.current.style.color = "#fff", f.current.classList.remove("after:content-['menu']"), f.current.classList.remove("after:-ml-0.5"), f.current.classList.add("after:content-['close']"), f.current.classList.add("after:ml-0.5"), i.current = !1);
|
|
597
|
+
}, []), x = w(() => {
|
|
598
|
+
g(), a && a();
|
|
599
|
+
}, [g, a]), S = w(() => {
|
|
600
|
+
j(), o && o();
|
|
601
|
+
}, [j, o]), s = w(() => {
|
|
602
|
+
i.current ? S() : x();
|
|
603
|
+
}, [x, S]), m = w((N) => {
|
|
604
|
+
N.currentTarget.blur();
|
|
605
|
+
}, []), _ = w((N) => {
|
|
606
|
+
N.preventDefault();
|
|
481
607
|
}, []);
|
|
482
|
-
return
|
|
483
|
-
r ?
|
|
484
|
-
}, [r,
|
|
485
|
-
/* @__PURE__ */
|
|
486
|
-
/* @__PURE__ */
|
|
487
|
-
/* @__PURE__ */
|
|
488
|
-
/* @__PURE__ */
|
|
489
|
-
/* @__PURE__ */
|
|
608
|
+
return L(() => {
|
|
609
|
+
r ? g() : j();
|
|
610
|
+
}, [r, g, j]), /* @__PURE__ */ t.jsxs("button", { type: "button", "data-aqmb-menu-switch": !0, className: "aiquants-menu-switch fixed z-2147483647 inline-block h-[27px] w-[27px] cursor-pointer align-middle outline-hidden", onClick: s, onFocus: m, onMouseDown: _, tabIndex: -1, children: [
|
|
611
|
+
/* @__PURE__ */ t.jsx("span", { className: "absolute top-0 left-0 box-border inline-block h-[3px] w-full select-none", ref: u }),
|
|
612
|
+
/* @__PURE__ */ t.jsx("span", { className: "absolute top-1.5 left-0 box-border inline-block h-[3px] w-full select-none", ref: p }),
|
|
613
|
+
/* @__PURE__ */ t.jsx("span", { className: "absolute top-3 left-0 box-border inline-block h-[3px] w-full select-none", ref: b }),
|
|
614
|
+
/* @__PURE__ */ t.jsx("span", { className: "absolute top-[18px] left-0 box-border inline-block h-[3px] w-full select-none", ref: d }),
|
|
615
|
+
/* @__PURE__ */ t.jsx("div", { className: "absolute w-full text-xs after:mt-2 after:block", ref: f })
|
|
490
616
|
] });
|
|
491
|
-
},
|
|
492
|
-
const { menuList: r, menuHeader:
|
|
617
|
+
}, fe = typeof window < "u" ? pe : L, rt = (n) => {
|
|
618
|
+
const { menuList: r, menuHeader: o, onClickSignout: a, isMenuhide: c, theme: i, toggleTheme: u, onMenuNavigate: p, onPinChange: b, pinnedSubmenuIds: d, initialPinnedSubmenuIds: f, onSubmenuPinChange: g, closeOnEscape: j = "auto" } = n, [x, S] = z(() => {
|
|
493
619
|
try {
|
|
494
620
|
return localStorage.getItem("aiquants-menu-pinned") === "true";
|
|
495
621
|
} catch {
|
|
496
622
|
return !1;
|
|
497
623
|
}
|
|
498
|
-
}), [s, m] =
|
|
624
|
+
}), [s, m] = z(x), [_, N] = z(() => {
|
|
499
625
|
if (f)
|
|
500
626
|
return f;
|
|
501
627
|
try {
|
|
502
|
-
const
|
|
503
|
-
if (
|
|
504
|
-
const
|
|
505
|
-
if (Array.isArray(
|
|
506
|
-
return
|
|
628
|
+
const k = localStorage.getItem("aiquants-submenu-pinned");
|
|
629
|
+
if (k) {
|
|
630
|
+
const E = JSON.parse(k);
|
|
631
|
+
if (Array.isArray(E))
|
|
632
|
+
return E.filter((R) => typeof R == "number");
|
|
507
633
|
}
|
|
508
634
|
} catch {
|
|
509
635
|
}
|
|
510
636
|
return [];
|
|
511
|
-
}),
|
|
512
|
-
(
|
|
513
|
-
const
|
|
637
|
+
}), Y = d !== void 0 ? d : _, F = w(
|
|
638
|
+
(k) => {
|
|
639
|
+
const E = d !== void 0 ? d : _, R = E.includes(k) ? E.filter((U) => U !== k) : [...E, k];
|
|
514
640
|
if (d === void 0) {
|
|
515
|
-
|
|
641
|
+
N(R);
|
|
516
642
|
try {
|
|
517
|
-
localStorage.setItem("aiquants-submenu-pinned", JSON.stringify(
|
|
643
|
+
localStorage.setItem("aiquants-submenu-pinned", JSON.stringify(R));
|
|
518
644
|
} catch {
|
|
519
645
|
}
|
|
520
646
|
}
|
|
521
|
-
|
|
647
|
+
g && g(R);
|
|
522
648
|
},
|
|
523
|
-
[d,
|
|
649
|
+
[d, _, g]
|
|
524
650
|
);
|
|
525
|
-
|
|
526
|
-
const
|
|
527
|
-
document.documentElement.style.setProperty("--aiquants-menu-pinned-width",
|
|
528
|
-
}, [x,
|
|
651
|
+
fe(() => {
|
|
652
|
+
const k = x ? "250px" : "0px";
|
|
653
|
+
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", k), b?.(x);
|
|
654
|
+
}, [x, b]), fe(() => () => {
|
|
529
655
|
document.documentElement.style.setProperty("--aiquants-menu-pinned-width", "0px");
|
|
530
656
|
}, []);
|
|
531
|
-
const
|
|
657
|
+
const V = w(() => {
|
|
532
658
|
m(!0);
|
|
533
|
-
}, []), P =
|
|
534
|
-
m(!1),
|
|
659
|
+
}, []), P = w(() => {
|
|
660
|
+
m(!1), S(!1);
|
|
535
661
|
try {
|
|
536
662
|
localStorage.removeItem("aiquants-menu-pinned");
|
|
537
663
|
} catch {
|
|
538
664
|
}
|
|
539
|
-
}, []),
|
|
540
|
-
|
|
541
|
-
const
|
|
542
|
-
if (
|
|
665
|
+
}, []), H = w(() => {
|
|
666
|
+
S((k) => {
|
|
667
|
+
const E = !k;
|
|
668
|
+
if (E)
|
|
543
669
|
try {
|
|
544
670
|
localStorage.setItem("aiquants-menu-pinned", "true");
|
|
545
671
|
} catch {
|
|
@@ -549,44 +675,44 @@ const Se = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMj
|
|
|
549
675
|
localStorage.removeItem("aiquants-menu-pinned");
|
|
550
676
|
} catch {
|
|
551
677
|
}
|
|
552
|
-
return
|
|
678
|
+
return E;
|
|
553
679
|
});
|
|
554
|
-
}, []),
|
|
555
|
-
(
|
|
556
|
-
|
|
680
|
+
}, []), W = w(
|
|
681
|
+
(k) => {
|
|
682
|
+
p && p(k), x || m(!1);
|
|
557
683
|
},
|
|
558
|
-
[
|
|
559
|
-
),
|
|
560
|
-
(
|
|
561
|
-
|
|
684
|
+
[p, x]
|
|
685
|
+
), T = w(
|
|
686
|
+
(k) => {
|
|
687
|
+
k.key === "Escape" && P();
|
|
562
688
|
},
|
|
563
689
|
[P]
|
|
564
|
-
),
|
|
565
|
-
return
|
|
566
|
-
window.removeEventListener("keydown",
|
|
567
|
-
}), [s,
|
|
568
|
-
/* @__PURE__ */
|
|
569
|
-
/* @__PURE__ */
|
|
570
|
-
|
|
690
|
+
), q = j === !0 || j === "auto" && !x;
|
|
691
|
+
return L(() => (s && q ? window.addEventListener("keydown", T, { passive: !0 }) : window.removeEventListener("keydown", T), () => {
|
|
692
|
+
window.removeEventListener("keydown", T);
|
|
693
|
+
}), [s, q, T]), c ? null : /* @__PURE__ */ t.jsxs("div", { className: `aiquants-menu-bar ${i}`, children: [
|
|
694
|
+
/* @__PURE__ */ t.jsx(Ke, { onMenuClose: P, onMenuOpen: V, open: !s, theme: i }),
|
|
695
|
+
/* @__PURE__ */ t.jsx(
|
|
696
|
+
Qe,
|
|
571
697
|
{
|
|
572
698
|
menuList: r,
|
|
573
|
-
menuHeader:
|
|
574
|
-
onClickSignout:
|
|
575
|
-
onMenuSelected:
|
|
699
|
+
menuHeader: o,
|
|
700
|
+
onClickSignout: a,
|
|
701
|
+
onMenuSelected: W,
|
|
576
702
|
open: s,
|
|
577
703
|
theme: i,
|
|
578
704
|
toggleTheme: u,
|
|
579
705
|
isPinned: x,
|
|
580
|
-
onTogglePin:
|
|
581
|
-
pinnedSubmenuIds:
|
|
582
|
-
onToggleSubmenuPin:
|
|
706
|
+
onTogglePin: H,
|
|
707
|
+
pinnedSubmenuIds: Y,
|
|
708
|
+
onToggleSubmenuPin: F
|
|
583
709
|
}
|
|
584
710
|
),
|
|
585
|
-
/* @__PURE__ */
|
|
711
|
+
/* @__PURE__ */ t.jsx(Xe, { isOverlay: s && !x, onOverlayClick: P })
|
|
586
712
|
] });
|
|
587
713
|
};
|
|
588
714
|
export {
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
715
|
+
Se as DefaultLink,
|
|
716
|
+
rt as MenuBar,
|
|
717
|
+
nt as SessionInfo
|
|
592
718
|
};
|