@humain/ui 2.2.2 → 2.2.3
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/components/templates/AppShell/AppShell.d.ts +4 -2
- package/dist/components/templates/AppShell/index.d.ts +1 -1
- package/dist/components/templates/AppSidebar/AppSidebar.constants.d.ts +4 -0
- package/dist/components/templates/AppSidebar/AppSidebar.d.ts +1 -0
- package/dist/index.js +19 -18
- package/dist/index217.js +6 -24
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +20 -23
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +20 -95
- package/dist/index219.js.map +1 -1
- package/dist/index220.js +92 -88
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +97 -29
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +24 -470
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +450 -196
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +199 -754
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +777 -61
- package/dist/index225.js.map +1 -1
- package/dist/index226.js +58 -181
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +175 -259
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +246 -172
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +195 -32
- package/dist/index229.js.map +1 -1
- package/dist/index230.js +12 -40
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +23 -26
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +45 -22
- package/dist/index232.js.map +1 -1
- package/dist/index233.js +27 -48
- package/dist/index233.js.map +1 -1
- package/dist/index234.js +52 -26
- package/dist/index234.js.map +1 -1
- package/dist/index235.js +40 -225
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +217 -39
- package/dist/index236.js.map +1 -1
- package/dist/index237.js +50 -0
- package/dist/index237.js.map +1 -0
- package/dist/styles.css +1 -1
- package/dist/wc/{sidebar.js → AppSidebar.constants.js} +80 -78
- package/dist/wc/AppSidebar.constants.js.map +1 -0
- package/dist/wc/hf-app-shell.js +346 -343
- package/dist/wc/hf-app-shell.js.map +1 -1
- package/dist/wc/hf-app-sidebar.js +65 -62
- package/dist/wc/hf-app-sidebar.js.map +1 -1
- package/dist/wc-react/{sidebar.js → AppSidebar.constants.js} +89 -87
- package/dist/wc-react/AppSidebar.constants.js.map +1 -0
- package/dist/wc-react/hf-app-shell.js +383 -380
- package/dist/wc-react/hf-app-shell.js.map +1 -1
- package/dist/wc-react/hf-app-sidebar.js +69 -66
- package/dist/wc-react/hf-app-sidebar.js.map +1 -1
- package/package.json +1 -1
- package/skills/humain-ui/SKILL.md +1 -1
- package/skills/humain-ui-wc/SKILL.md +1 -1
- package/skills/humain-ui-wc.skill +0 -0
- package/skills/humain-ui.skill +0 -0
- package/dist/wc/sidebar.js.map +0 -1
- package/dist/wc-react/sidebar.js.map +0 -1
|
@@ -3,18 +3,18 @@ import { i as He, t as Te } from "./vendor/react.js";
|
|
|
3
3
|
import { n as p } from "./utils.js";
|
|
4
4
|
import { a as oe, i as Ve, l as We, n as qe, o as Ue, t as Ge, u as Ke } from "./_shared.js";
|
|
5
5
|
import { t as F } from "./createLucideIcon.js";
|
|
6
|
-
import { t as
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { t as
|
|
6
|
+
import { t as Xe } from "./calendar.js";
|
|
7
|
+
import { t as Ze } from "./chevron-right.js";
|
|
8
|
+
import { t as Je } from "./circle.js";
|
|
9
|
+
import { t as Qe } from "./file-text.js";
|
|
10
10
|
import { t as Ye } from "./house.js";
|
|
11
11
|
import { t as ce } from "./message-circle.js";
|
|
12
|
-
import { a as de, c as
|
|
12
|
+
import { _ as et, a as de, c as I, d as pe, f as tt, g as at, h as ot, i as ue, l as E, m as fe, n as me, p as be, r as rt, s as xe, t as he, u as ge, v as S } from "./AppSidebar.constants.js";
|
|
13
13
|
import { t as st } from "./settings.js";
|
|
14
14
|
import { t as re } from "./Avatar.js";
|
|
15
15
|
import { t as nt } from "./workflow.js";
|
|
16
|
-
import { t as
|
|
17
|
-
import { t as
|
|
16
|
+
import { t as ve } from "./dist.js";
|
|
17
|
+
import { t as Ne } from "./Badge.js";
|
|
18
18
|
import { t as it } from "./Separator3.js";
|
|
19
19
|
import { a as lt, i as ct, s as dt } from "./Popover.js";
|
|
20
20
|
import { n as M, r as $, t as B } from "./tooltip2.js";
|
|
@@ -72,7 +72,7 @@ var ut = [
|
|
|
72
72
|
r: "4",
|
|
73
73
|
key: "nufk8"
|
|
74
74
|
}]
|
|
75
|
-
], ht = F("users", xt), l = /* @__PURE__ */ Re(He(), 1), t = Te()
|
|
75
|
+
], ht = F("users", xt), l = /* @__PURE__ */ Re(He(), 1), t = Te();
|
|
76
76
|
function je(e, a) {
|
|
77
77
|
return a == null ? e : `${e}, ${typeof a == "number" ? `${a} ${a === 1 ? "item" : "items"}` : a}`;
|
|
78
78
|
}
|
|
@@ -93,11 +93,11 @@ function C(e, a) {
|
|
|
93
93
|
function gt(e) {
|
|
94
94
|
return (typeof e == "function" || typeof e == "object" && e !== null) && R in e;
|
|
95
95
|
}
|
|
96
|
-
function
|
|
96
|
+
function O(e) {
|
|
97
97
|
if (gt(e)) return e[R];
|
|
98
98
|
if (typeof e == "object" && e !== null) {
|
|
99
99
|
const a = e;
|
|
100
|
-
return
|
|
100
|
+
return O(a.type) ?? O(a.render);
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
103
|
function vt(e) {
|
|
@@ -125,7 +125,7 @@ function vt(e) {
|
|
|
125
125
|
a.explicitFooter = o;
|
|
126
126
|
return;
|
|
127
127
|
}
|
|
128
|
-
const n =
|
|
128
|
+
const n = O(r);
|
|
129
129
|
n === "header" ? a.header.push(o) : n === "content" ? a.content.push(o) : n === "footer" ? a.footer.push(o) : a.content.push(o);
|
|
130
130
|
}), a;
|
|
131
131
|
}, [e]);
|
|
@@ -223,8 +223,11 @@ function T({ logo: e, compactedLogo: a, subtext: o, className: r, ...n }) {
|
|
|
223
223
|
children: "HUMAIN"
|
|
224
224
|
})] })
|
|
225
225
|
}), o && /* @__PURE__ */ (0, t.jsx)("p", {
|
|
226
|
-
className: "text-sm text-sidebar-foreground",
|
|
227
|
-
children:
|
|
226
|
+
className: "ps-11 text-sm text-sidebar-foreground",
|
|
227
|
+
children: /* @__PURE__ */ (0, t.jsx)("span", {
|
|
228
|
+
"data-slot": "app-sidebar-logo-subtext",
|
|
229
|
+
children: o
|
|
230
|
+
})
|
|
228
231
|
})]
|
|
229
232
|
}), /* @__PURE__ */ (0, t.jsx)("button", {
|
|
230
233
|
type: "button",
|
|
@@ -264,7 +267,7 @@ function q({ children: e, className: a }) {
|
|
|
264
267
|
}
|
|
265
268
|
q.displayName = "AppSidebar.Footer";
|
|
266
269
|
function U({ children: e, "aria-label": a = "Sidebar navigation", className: o }) {
|
|
267
|
-
const r = /* @__PURE__ */ (0, t.jsx)(
|
|
270
|
+
const r = /* @__PURE__ */ (0, t.jsx)(be, {
|
|
268
271
|
className: "gap-0.5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:gap-1",
|
|
269
272
|
children: l.Children.map(e, (n) => /* @__PURE__ */ (0, t.jsx)(fe, { children: n }))
|
|
270
273
|
});
|
|
@@ -301,7 +304,7 @@ function we({ label: e, className: a }) {
|
|
|
301
304
|
});
|
|
302
305
|
}
|
|
303
306
|
we.displayName = "AppSidebar.NavSection";
|
|
304
|
-
var Ie =
|
|
307
|
+
var Ie = ve("relative flex w-full items-center gap-1.5 rounded-lg px-2 py-2 text-sm font-normal transition-[color,background-color] duration-200 ease-smooth motion-reduce:transition-none", {
|
|
305
308
|
variants: { state: {
|
|
306
309
|
default: "text-sidebar-foreground hover:bg-sidebar-accent",
|
|
307
310
|
active: "bg-primary/10 text-sidebar-foreground"
|
|
@@ -309,15 +312,15 @@ var Ie = he("relative flex w-full items-center gap-1.5 rounded-lg px-2 py-2 text
|
|
|
309
312
|
defaultVariants: { state: "default" }
|
|
310
313
|
});
|
|
311
314
|
function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i, className: c, children: u }) {
|
|
312
|
-
const { state: m, containerRef: f } = S(), { side: s } = H(), b = m === "collapsed", d = l.Children.count(u) > 0, v = l.Children.toArray(u).some((g) => l.isValidElement(g) && g.props.isActive === !0), h = o || v, [N, x] = l.useState(h && d),
|
|
313
|
-
const g = f.current, j = g?.getBoundingClientRect(), ae = g?.ownerDocument.defaultView?.innerHeight ?? j?.height ?? 0,
|
|
315
|
+
const { state: m, containerRef: f } = S(), { side: s } = H(), b = m === "collapsed", d = l.Children.count(u) > 0, v = l.Children.toArray(u).some((g) => l.isValidElement(g) && g.props.isActive === !0), h = o || v, [N, x] = l.useState(h && d), X = l.useId(), Z = s === "right" ? "left" : "right", ze = "linear-gradient(108deg, var(--opacity-white-87) 0.5219%, var(--opacity-white-75) 98.419%)", Fe = s === "right" ? "justify-end rounded-l-xl rounded-r-none" : "justify-start rounded-r-xl rounded-l-none", Me = s === "right" ? "rounded-l-xl" : "rounded-r-xl", $e = l.useMemo(() => ({ getBoundingClientRect: () => {
|
|
316
|
+
const g = f.current, j = g?.getBoundingClientRect(), ae = g?.ownerDocument.defaultView?.innerHeight ?? j?.height ?? 0, P = j ? s === "right" ? j.left : j.right : 0;
|
|
314
317
|
return {
|
|
315
|
-
x:
|
|
318
|
+
x: P,
|
|
316
319
|
y: 0,
|
|
317
320
|
top: 0,
|
|
318
|
-
right:
|
|
321
|
+
right: P,
|
|
319
322
|
bottom: ae,
|
|
320
|
-
left:
|
|
323
|
+
left: P,
|
|
321
324
|
width: 0,
|
|
322
325
|
height: ae
|
|
323
326
|
};
|
|
@@ -325,21 +328,21 @@ function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i
|
|
|
325
328
|
l.useEffect(() => {
|
|
326
329
|
h && d && x(!0);
|
|
327
330
|
}, [h, d]);
|
|
328
|
-
const A = je(a, r),
|
|
331
|
+
const A = je(a, r), J = /* @__PURE__ */ (0, t.jsx)("span", {
|
|
329
332
|
"data-slot": "nav-icon",
|
|
330
333
|
className: "flex shrink-0 items-center p-0.5 [&>svg]:size-4",
|
|
331
334
|
children: e
|
|
332
|
-
}),
|
|
335
|
+
}), Q = /* @__PURE__ */ (0, t.jsx)("span", {
|
|
333
336
|
className: "flex-1 text-start group-data-[collapsible=icon]:hidden",
|
|
334
337
|
children: a
|
|
335
|
-
}), Y = r != null && /* @__PURE__ */ (0, t.jsx)(
|
|
338
|
+
}), Y = r != null && /* @__PURE__ */ (0, t.jsx)(Ne, {
|
|
336
339
|
size: "sm",
|
|
337
340
|
variant: "soft",
|
|
338
341
|
color: "primary",
|
|
339
342
|
className: "px-1.5 group-data-[collapsible=icon]:hidden",
|
|
340
343
|
"aria-hidden": "true",
|
|
341
344
|
children: r
|
|
342
|
-
}), ee = d && /* @__PURE__ */ (0, t.jsx)(
|
|
345
|
+
}), ee = d && /* @__PURE__ */ (0, t.jsx)(Ze, {
|
|
343
346
|
"aria-hidden": "true",
|
|
344
347
|
className: p("size-4 shrink-0 text-muted-foreground transition-transform duration-200 ease-smooth group-data-[collapsible=icon]:hidden motion-reduce:transition-none", N ? "rotate-90" : "rtl:rotate-180", h && N && "text-primary")
|
|
345
348
|
}), k = p(Ie({ state: h ? "active" : "default" }), "focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring", "min-h-11 group-data-[collapsible=icon]:justify-center group-data-[collapsible=icon]:px-0 group-data-[collapsible=icon]:py-2 group-data-[collapsible=icon]:w-11 group-data-[collapsible=icon]:h-11", c), w = o ? { "aria-current": "page" } : {};
|
|
@@ -370,7 +373,7 @@ function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i
|
|
|
370
373
|
"data-slot": "app-sidebar-nav-item",
|
|
371
374
|
children: g
|
|
372
375
|
}), /* @__PURE__ */ (0, t.jsx)(ct, {
|
|
373
|
-
side:
|
|
376
|
+
side: Z,
|
|
374
377
|
align: "start",
|
|
375
378
|
sideOffset: 0,
|
|
376
379
|
alignOffset: 0,
|
|
@@ -396,7 +399,7 @@ function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i
|
|
|
396
399
|
}), u]
|
|
397
400
|
})
|
|
398
401
|
})] }) : a ? /* @__PURE__ */ (0, t.jsxs)(B, { children: [/* @__PURE__ */ (0, t.jsx)($, { render: j }), /* @__PURE__ */ (0, t.jsx)(M, {
|
|
399
|
-
side:
|
|
402
|
+
side: Z,
|
|
400
403
|
sideOffset: 8,
|
|
401
404
|
children: a
|
|
402
405
|
})] }) : j;
|
|
@@ -410,8 +413,8 @@ function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i
|
|
|
410
413
|
...w,
|
|
411
414
|
"data-slot": "app-sidebar-nav-item",
|
|
412
415
|
children: [
|
|
416
|
+
J,
|
|
413
417
|
Q,
|
|
414
|
-
X,
|
|
415
418
|
Y,
|
|
416
419
|
ee
|
|
417
420
|
]
|
|
@@ -421,18 +424,18 @@ function Ee({ icon: e, label: a, isActive: o = !1, badge: r, onClick: n, href: i
|
|
|
421
424
|
className: p(k, "cursor-pointer"),
|
|
422
425
|
"aria-label": A,
|
|
423
426
|
"aria-expanded": d ? N : void 0,
|
|
424
|
-
"aria-controls": d ?
|
|
427
|
+
"aria-controls": d ? X : void 0,
|
|
425
428
|
...w,
|
|
426
429
|
"data-slot": "app-sidebar-nav-item",
|
|
427
430
|
children: [
|
|
431
|
+
J,
|
|
428
432
|
Q,
|
|
429
|
-
X,
|
|
430
433
|
Y,
|
|
431
434
|
ee
|
|
432
435
|
]
|
|
433
436
|
});
|
|
434
437
|
return d ? /* @__PURE__ */ (0, t.jsxs)(t.Fragment, { children: [te, N && /* @__PURE__ */ (0, t.jsx)("ul", {
|
|
435
|
-
id:
|
|
438
|
+
id: X,
|
|
436
439
|
role: "group",
|
|
437
440
|
"aria-label": `${a} sub-navigation`,
|
|
438
441
|
className: "ms-4 flex flex-col items-start border-s border-sidebar-border py-1 ps-2",
|
|
@@ -444,7 +447,7 @@ function _e({ label: e, badge: a, isActive: o = !1, href: r, onClick: n, classNa
|
|
|
444
447
|
const c = je(e, a), u = p(Ie({ state: o ? "active" : "default" }), "min-h-11 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring", "transition-[color,background-color,transform] ltr:hover:translate-x-0.5 rtl:hover:-translate-x-0.5 motion-reduce:ltr:hover:translate-x-0 motion-reduce:rtl:hover:translate-x-0", i), m = o ? { "aria-current": "page" } : {}, f = /* @__PURE__ */ (0, t.jsxs)(t.Fragment, { children: [/* @__PURE__ */ (0, t.jsx)("span", {
|
|
445
448
|
className: "flex-1 text-start",
|
|
446
449
|
children: e
|
|
447
|
-
}), a != null && /* @__PURE__ */ (0, t.jsx)(
|
|
450
|
+
}), a != null && /* @__PURE__ */ (0, t.jsx)(Ne, {
|
|
448
451
|
size: "sm",
|
|
449
452
|
variant: "soft",
|
|
450
453
|
color: "primary",
|
|
@@ -474,9 +477,9 @@ function _({ count: e = 3, className: a }) {
|
|
|
474
477
|
const o = Ce(e, 3);
|
|
475
478
|
return /* @__PURE__ */ (0, t.jsx)(I, {
|
|
476
479
|
className: p("shrink-0 p-0 group-data-[collapsible=icon]:w-auto", a),
|
|
477
|
-
children: /* @__PURE__ */ (0, t.jsx)(E, { children: /* @__PURE__ */ (0, t.jsx)(
|
|
480
|
+
children: /* @__PURE__ */ (0, t.jsx)(E, { children: /* @__PURE__ */ (0, t.jsx)(be, {
|
|
478
481
|
className: "gap-0.5 group-data-[collapsible=icon]:items-center group-data-[collapsible=icon]:gap-2",
|
|
479
|
-
children: Array.from({ length: o }).map((r, n) => /* @__PURE__ */ (0, t.jsx)(fe, { children: /* @__PURE__ */ (0, t.jsx)(
|
|
482
|
+
children: Array.from({ length: o }).map((r, n) => /* @__PURE__ */ (0, t.jsx)(fe, { children: /* @__PURE__ */ (0, t.jsx)(at, {}) }, `nav-skeleton-${n}`))
|
|
480
483
|
}) })
|
|
481
484
|
});
|
|
482
485
|
}
|
|
@@ -487,7 +490,7 @@ function G({ label: e = "Recent Chats", children: a, className: o }) {
|
|
|
487
490
|
return r === "collapsed" ? null : /* @__PURE__ */ (0, t.jsxs)(I, {
|
|
488
491
|
"data-slot": "app-sidebar-chat-list",
|
|
489
492
|
className: p("mt-4 flex min-h-0 flex-1 flex-col p-0", o),
|
|
490
|
-
children: [/* @__PURE__ */ (0, t.jsx)(
|
|
493
|
+
children: [/* @__PURE__ */ (0, t.jsx)(ge, {
|
|
491
494
|
className: "shrink-0 px-3 py-1 text-xs font-bold text-muted-foreground",
|
|
492
495
|
children: e
|
|
493
496
|
}), /* @__PURE__ */ (0, t.jsx)(E, {
|
|
@@ -504,7 +507,7 @@ function G({ label: e = "Recent Chats", children: a, className: o }) {
|
|
|
504
507
|
}
|
|
505
508
|
G.displayName = "AppSidebar.ChatList";
|
|
506
509
|
C(G, "content");
|
|
507
|
-
var yt =
|
|
510
|
+
var yt = ve("flex w-full items-center justify-between gap-2 rounded-md px-3 py-2 min-h-11 transition-[color,background-color,transform] duration-200 ease-smooth cursor-pointer motion-reduce:transition-none ltr:hover:translate-x-0.5 rtl:hover:-translate-x-0.5 motion-reduce:ltr:hover:translate-x-0 motion-reduce:rtl:hover:translate-x-0", {
|
|
508
511
|
variants: { state: {
|
|
509
512
|
default: "hover:bg-muted",
|
|
510
513
|
hover: "bg-muted",
|
|
@@ -563,14 +566,14 @@ function L({ count: e = 5, label: a = "Recent Chats", className: o }) {
|
|
|
563
566
|
const r = Ce(e, 5);
|
|
564
567
|
return /* @__PURE__ */ (0, t.jsxs)(I, {
|
|
565
568
|
className: p("mt-4 flex min-h-0 flex-1 flex-col p-0 group-data-[collapsible=icon]:hidden", o),
|
|
566
|
-
children: [/* @__PURE__ */ (0, t.jsx)(
|
|
569
|
+
children: [/* @__PURE__ */ (0, t.jsx)(ge, {
|
|
567
570
|
className: "shrink-0 px-3 py-1 text-xs font-bold text-muted-foreground",
|
|
568
571
|
children: a
|
|
569
572
|
}), /* @__PURE__ */ (0, t.jsx)(E, {
|
|
570
573
|
className: "flex-1 overflow-hidden",
|
|
571
574
|
children: /* @__PURE__ */ (0, t.jsx)("div", {
|
|
572
575
|
className: "flex h-full flex-col overflow-y-auto pb-5",
|
|
573
|
-
children: Array.from({ length: r }).map((n, i) => /* @__PURE__ */ (0, t.jsx)(
|
|
576
|
+
children: Array.from({ length: r }).map((n, i) => /* @__PURE__ */ (0, t.jsx)(ot, {}, `chat-skeleton-${i}`))
|
|
574
577
|
})
|
|
575
578
|
})]
|
|
576
579
|
});
|
|
@@ -640,7 +643,7 @@ function K({ name: e, subtitle: a, avatarSrc: o, isOnline: r = !1, onExpand: n,
|
|
|
640
643
|
K.displayName = "AppSidebar.Account";
|
|
641
644
|
C(K, "footer");
|
|
642
645
|
function D({ className: e }) {
|
|
643
|
-
return /* @__PURE__ */ (0, t.jsx)(
|
|
646
|
+
return /* @__PURE__ */ (0, t.jsx)(rt, { className: e });
|
|
644
647
|
}
|
|
645
648
|
D.displayName = "AppSidebar.AccountSkeleton";
|
|
646
649
|
C(D, "footer");
|
|
@@ -649,11 +652,11 @@ function De({ navCount: e = 4, chatCount: a = 5, logo: o, compactedLogo: r, coll
|
|
|
649
652
|
containerRef: s,
|
|
650
653
|
explicitSide: i
|
|
651
654
|
}), v = Se(b, u);
|
|
652
|
-
return /* @__PURE__ */ (0, t.jsx)(
|
|
655
|
+
return /* @__PURE__ */ (0, t.jsx)(ue, {
|
|
653
656
|
collapsible: n,
|
|
654
657
|
side: d,
|
|
655
|
-
width:
|
|
656
|
-
collapsedWidth:
|
|
658
|
+
width: me,
|
|
659
|
+
collapsedWidth: he,
|
|
657
660
|
className: p("bg-transparent", m),
|
|
658
661
|
children: /* @__PURE__ */ (0, t.jsxs)("div", {
|
|
659
662
|
"data-slot": "app-sidebar-surface",
|
|
@@ -664,18 +667,18 @@ function De({ navCount: e = 4, chatCount: a = 5, logo: o, compactedLogo: r, coll
|
|
|
664
667
|
backgroundClass: v
|
|
665
668
|
}),
|
|
666
669
|
children: [
|
|
667
|
-
/* @__PURE__ */ (0, t.jsx)(
|
|
670
|
+
/* @__PURE__ */ (0, t.jsx)(pe, {
|
|
668
671
|
className: "h-[68px] w-full p-2",
|
|
669
672
|
children: /* @__PURE__ */ (0, t.jsx)(T, {
|
|
670
673
|
logo: o,
|
|
671
674
|
compactedLogo: r
|
|
672
675
|
})
|
|
673
676
|
}),
|
|
674
|
-
/* @__PURE__ */ (0, t.jsxs)(
|
|
677
|
+
/* @__PURE__ */ (0, t.jsxs)(de, {
|
|
675
678
|
className: "flex w-full flex-col gap-0 overflow-hidden pt-3 group-data-[collapsible=icon]:items-center",
|
|
676
679
|
children: [/* @__PURE__ */ (0, t.jsx)(_, { count: e }), /* @__PURE__ */ (0, t.jsx)(L, { count: a })]
|
|
677
680
|
}),
|
|
678
|
-
/* @__PURE__ */ (0, t.jsx)(
|
|
681
|
+
/* @__PURE__ */ (0, t.jsx)(xe, {
|
|
679
682
|
className: "w-full gap-0 p-0 group-data-[collapsible=icon]:items-center",
|
|
680
683
|
children: /* @__PURE__ */ (0, t.jsx)(D, {})
|
|
681
684
|
})
|
|
@@ -684,7 +687,7 @@ function De({ navCount: e = 4, chatCount: a = 5, logo: o, compactedLogo: r, coll
|
|
|
684
687
|
});
|
|
685
688
|
}
|
|
686
689
|
De.displayName = "AppSidebar.Skeleton";
|
|
687
|
-
function
|
|
690
|
+
function Pe({ logo: e, compactedLogo: a, logoSubtext: o, collapsible: r = "icon", side: n, rounded: i = !1, sidebarBgColor: c, className: u, children: m, dir: f, ...s }) {
|
|
688
691
|
const { state: b, containerRef: d } = S(), v = b === "collapsed", h = ke({
|
|
689
692
|
containerRef: d,
|
|
690
693
|
explicitDir: f,
|
|
@@ -692,11 +695,11 @@ function Oe({ logo: e, compactedLogo: a, logoSubtext: o, collapsible: r = "icon"
|
|
|
692
695
|
}), N = Se(v, c), x = vt(m);
|
|
693
696
|
return /* @__PURE__ */ (0, t.jsx)(Ae.Provider, {
|
|
694
697
|
value: { side: h },
|
|
695
|
-
children: /* @__PURE__ */ (0, t.jsx)(
|
|
698
|
+
children: /* @__PURE__ */ (0, t.jsx)(ue, {
|
|
696
699
|
collapsible: r,
|
|
697
700
|
side: h,
|
|
698
|
-
width:
|
|
699
|
-
collapsedWidth:
|
|
701
|
+
width: me,
|
|
702
|
+
collapsedWidth: he,
|
|
700
703
|
dir: f,
|
|
701
704
|
className: p("bg-transparent", u),
|
|
702
705
|
...s,
|
|
@@ -709,7 +712,7 @@ function Oe({ logo: e, compactedLogo: a, logoSubtext: o, collapsible: r = "icon"
|
|
|
709
712
|
backgroundClass: N
|
|
710
713
|
}),
|
|
711
714
|
children: [
|
|
712
|
-
/* @__PURE__ */ (0, t.jsx)(
|
|
715
|
+
/* @__PURE__ */ (0, t.jsx)(pe, {
|
|
713
716
|
className: "h-[68px] w-full p-2",
|
|
714
717
|
children: /* @__PURE__ */ (0, t.jsx)(T, {
|
|
715
718
|
logo: e,
|
|
@@ -717,11 +720,11 @@ function Oe({ logo: e, compactedLogo: a, logoSubtext: o, collapsible: r = "icon"
|
|
|
717
720
|
subtext: o
|
|
718
721
|
})
|
|
719
722
|
}),
|
|
720
|
-
/* @__PURE__ */ (0, t.jsx)(
|
|
723
|
+
/* @__PURE__ */ (0, t.jsx)(de, {
|
|
721
724
|
className: "flex w-full flex-col gap-0 overflow-hidden pt-3 group-data-[collapsible=icon]:items-center",
|
|
722
725
|
children: x.explicitContent ? x.explicitContent.props.children : x.content
|
|
723
726
|
}),
|
|
724
|
-
/* @__PURE__ */ (0, t.jsx)(
|
|
727
|
+
/* @__PURE__ */ (0, t.jsx)(xe, {
|
|
725
728
|
className: "w-full gap-0 p-0 group-data-[collapsible=icon]:items-center",
|
|
726
729
|
children: x.explicitFooter ? x.explicitFooter.props.children : x.footer
|
|
727
730
|
})
|
|
@@ -730,8 +733,8 @@ function Oe({ logo: e, compactedLogo: a, logoSubtext: o, collapsible: r = "icon"
|
|
|
730
733
|
})
|
|
731
734
|
});
|
|
732
735
|
}
|
|
733
|
-
|
|
734
|
-
var y = Object.assign(
|
|
736
|
+
Pe.displayName = "AppSidebar";
|
|
737
|
+
var y = Object.assign(Pe, {
|
|
735
738
|
Header: V,
|
|
736
739
|
Content: W,
|
|
737
740
|
Footer: q,
|
|
@@ -762,8 +765,8 @@ var y = Object.assign(Oe, {
|
|
|
762
765
|
}, Ct = {
|
|
763
766
|
home: Ye,
|
|
764
767
|
users: ht,
|
|
765
|
-
calendar:
|
|
766
|
-
"file-text":
|
|
768
|
+
calendar: Xe,
|
|
769
|
+
"file-text": Qe,
|
|
767
770
|
settings: st,
|
|
768
771
|
"message-circle": ce,
|
|
769
772
|
workflow: nt
|
|
@@ -778,7 +781,7 @@ function kt(e) {
|
|
|
778
781
|
if (o) return l.createElement(o, { "aria-hidden": !0 });
|
|
779
782
|
ie.has(a) || (ie.add(a), console.warn(`[hf-app-sidebar] Unsupported nav item icon "${a}". Falling back to "circle".`));
|
|
780
783
|
}
|
|
781
|
-
return l.createElement(
|
|
784
|
+
return l.createElement(Je, { "aria-hidden": !0 });
|
|
782
785
|
}
|
|
783
786
|
function wt(e) {
|
|
784
787
|
return e.type === "section";
|
|
@@ -790,7 +793,7 @@ function le(e, a) {
|
|
|
790
793
|
alt: e.alt || a
|
|
791
794
|
}) : null;
|
|
792
795
|
}
|
|
793
|
-
var
|
|
796
|
+
var Oe = class extends Ge {
|
|
794
797
|
get propDefs() {
|
|
795
798
|
return z;
|
|
796
799
|
}
|
|
@@ -841,7 +844,7 @@ var Pe = class extends Ge {
|
|
|
841
844
|
subtitle: r.subtitle,
|
|
842
845
|
avatarSrc: r.avatarSrc,
|
|
843
846
|
isOnline: r.isOnline
|
|
844
|
-
}))), a && f.push(l.createElement(
|
|
847
|
+
}))), a && f.push(l.createElement(tt, {
|
|
845
848
|
key: "inset",
|
|
846
849
|
connected: e.connected
|
|
847
850
|
}, We(a))), l.createElement(et, {
|
|
@@ -851,11 +854,11 @@ var Pe = class extends Ge {
|
|
|
851
854
|
}, ...f);
|
|
852
855
|
}
|
|
853
856
|
};
|
|
854
|
-
Ue(
|
|
855
|
-
Ke("hf-app-sidebar",
|
|
857
|
+
Ue(Oe, z);
|
|
858
|
+
Ke("hf-app-sidebar", Oe);
|
|
856
859
|
export {
|
|
857
|
-
|
|
858
|
-
|
|
860
|
+
Oe as AppSidebarWC,
|
|
861
|
+
Oe as default
|
|
859
862
|
};
|
|
860
863
|
|
|
861
864
|
//# sourceMappingURL=hf-app-sidebar.js.map
|