@inf-monkeys-tech/monkeys-design 1.0.6 → 1.0.7

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.
@@ -2255,6 +2255,93 @@ var BaseTooltip = forwardRef(
2255
2255
  );
2256
2256
  }
2257
2257
  );
2258
+ var rootTokenStyles = {
2259
+ width: "var(--monkeys-component-app-shell-sidebar-width, 16rem)",
2260
+ borderRadius: "var(--monkeys-component-app-shell-sidebar-radius, var(--radius, 0.75rem))",
2261
+ background: "var(--monkeys-component-app-shell-sidebar-background, hsl(var(--card)))",
2262
+ color: "var(--monkeys-component-app-shell-sidebar-foreground, hsl(var(--card-foreground)))",
2263
+ borderColor: "var(--monkeys-component-app-shell-sidebar-border-color, hsl(var(--border)))",
2264
+ boxShadow: "var(--monkeys-component-app-shell-sidebar-shadow, none)"
2265
+ };
2266
+ var headerTokenStyles = {
2267
+ padding: "var(--monkeys-component-app-shell-sidebar-header-padding, var(--global-spacing, 0.75rem))",
2268
+ borderColor: "var(--monkeys-component-app-shell-sidebar-header-border-color, hsl(var(--border)))"
2269
+ };
2270
+ var navigationTokenStyles = {
2271
+ padding: "var(--monkeys-component-app-shell-sidebar-navigation-padding, var(--global-spacing, 0.75rem))",
2272
+ "--monkeys-component-accordion-item-border-color": "transparent"
2273
+ };
2274
+ var footerTokenStyles = {
2275
+ padding: "var(--monkeys-component-app-shell-sidebar-footer-padding, var(--global-spacing, 0.75rem))",
2276
+ background: "var(--monkeys-component-app-shell-sidebar-footer-background, hsl(var(--muted) / 0.22))",
2277
+ borderColor: "var(--monkeys-component-app-shell-sidebar-footer-border-color, hsl(var(--border)))"
2278
+ };
2279
+ var AppShellSidebar = forwardRef(
2280
+ function AppShellSidebar2({
2281
+ navigation,
2282
+ header,
2283
+ footer,
2284
+ width,
2285
+ className,
2286
+ classNames,
2287
+ style,
2288
+ "aria-label": ariaLabel = "Application navigation",
2289
+ ...props
2290
+ }, ref) {
2291
+ return /* @__PURE__ */ jsxs(
2292
+ "aside",
2293
+ {
2294
+ ref,
2295
+ "aria-label": ariaLabel,
2296
+ "data-app-shell-sidebar": "",
2297
+ className: cn(
2298
+ "relative isolate flex h-full min-h-0 shrink-0 flex-col overflow-hidden border",
2299
+ classNames?.root,
2300
+ className
2301
+ ),
2302
+ style: {
2303
+ ...rootTokenStyles,
2304
+ ...width === void 0 ? null : { width },
2305
+ ...style
2306
+ },
2307
+ ...props,
2308
+ children: [
2309
+ header ? /* @__PURE__ */ jsx(
2310
+ "div",
2311
+ {
2312
+ "data-slot": "header",
2313
+ className: cn("shrink-0 border-b", classNames?.header),
2314
+ style: headerTokenStyles,
2315
+ children: header
2316
+ }
2317
+ ) : null,
2318
+ /* @__PURE__ */ jsx(
2319
+ "div",
2320
+ {
2321
+ "data-slot": "navigation",
2322
+ className: cn(
2323
+ "relative min-h-0 flex-1 overflow-hidden",
2324
+ classNames?.navigation
2325
+ ),
2326
+ style: navigationTokenStyles,
2327
+ children: navigation
2328
+ }
2329
+ ),
2330
+ footer ? /* @__PURE__ */ jsx(
2331
+ "div",
2332
+ {
2333
+ "data-slot": "footer",
2334
+ className: cn("shrink-0 border-t", classNames?.footer),
2335
+ style: footerTokenStyles,
2336
+ children: footer
2337
+ }
2338
+ ) : null
2339
+ ]
2340
+ }
2341
+ );
2342
+ }
2343
+ );
2344
+ AppShellSidebar.displayName = "AppShellSidebar";
2258
2345
  var defaultAppearance = {
2259
2346
  preset: "soft",
2260
2347
  density: "compact",
@@ -2529,7 +2616,14 @@ function UserAccountMenu({
2529
2616
  function cn2(...inputs) {
2530
2617
  return inputs.filter(Boolean).join(" ");
2531
2618
  }
2532
- function NavButton({ active, icon, postfix, onClick, className, children }) {
2619
+ function NavButton({
2620
+ active,
2621
+ icon,
2622
+ postfix,
2623
+ onClick,
2624
+ className,
2625
+ children
2626
+ }) {
2533
2627
  return /* @__PURE__ */ jsxs(
2534
2628
  "div",
2535
2629
  {
@@ -2581,7 +2675,14 @@ function AppHeader({
2581
2675
  "flex h-8 w-8 items-center justify-center rounded-lg overflow-hidden",
2582
2676
  logo.url ? "bg-transparent" : "bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]"
2583
2677
  ),
2584
- children: logo.url ? /* @__PURE__ */ jsx("img", { src: logo.url, alt: logo.title, className: "h-full w-full object-contain" }) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
2678
+ children: logo.url ? /* @__PURE__ */ jsx(
2679
+ "img",
2680
+ {
2681
+ src: logo.url,
2682
+ alt: logo.title,
2683
+ className: "h-full w-full object-contain"
2684
+ }
2685
+ ) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
2585
2686
  }
2586
2687
  ),
2587
2688
  /* @__PURE__ */ jsx("span", { className: "text-lg font-semibold whitespace-nowrap", children: logo.title })
@@ -2607,7 +2708,14 @@ function AppHeader({
2607
2708
  /* @__PURE__ */ jsxs("div", { className: "flex shrink-0 items-center gap-4", children: [
2608
2709
  extra,
2609
2710
  user && /* @__PURE__ */ jsxs(DropdownMenu.Root, { children: [
2610
- /* @__PURE__ */ jsx(DropdownMenu.Trigger, { asChild: true, children: /* @__PURE__ */ jsx("button", { className: "flex h-8 w-8 items-center justify-center rounded-full hover:ring-2 hover:ring-[hsl(var(--ring))]/20 transition-all overflow-hidden focus-visible:outline-none", children: user.photo ? /* @__PURE__ */ jsx("img", { src: user.photo, alt: user.name, className: "h-8 w-8 rounded-full object-cover" }) : /* @__PURE__ */ jsx("div", { className: "flex h-8 w-8 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-xs font-medium", children: user.name ? getUserInitials(user.name) : "U" }) }) }),
2711
+ /* @__PURE__ */ jsx(DropdownMenu.Trigger, { asChild: true, children: /* @__PURE__ */ jsx("button", { className: "flex h-8 w-8 items-center justify-center rounded-full hover:ring-2 hover:ring-[hsl(var(--ring))]/20 transition-all overflow-hidden focus-visible:outline-none", children: user.photo ? /* @__PURE__ */ jsx(
2712
+ "img",
2713
+ {
2714
+ src: user.photo,
2715
+ alt: user.name,
2716
+ className: "h-8 w-8 rounded-full object-cover"
2717
+ }
2718
+ ) : /* @__PURE__ */ jsx("div", { className: "flex h-8 w-8 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-xs font-medium", children: user.name ? getUserInitials(user.name) : "U" }) }) }),
2611
2719
  /* @__PURE__ */ jsx(DropdownMenu.Portal, { children: /* @__PURE__ */ jsxs(
2612
2720
  DropdownMenu.Content,
2613
2721
  {
@@ -2616,7 +2724,14 @@ function AppHeader({
2616
2724
  align: "end",
2617
2725
  children: [
2618
2726
  /* @__PURE__ */ jsxs(DropdownMenu.Label, { className: "flex items-center gap-2 px-2 py-1.5 font-normal", children: [
2619
- user.photo ? /* @__PURE__ */ jsx("img", { src: user.photo, alt: user.name, className: "h-8 w-8 rounded-full object-cover" }) : /* @__PURE__ */ jsx("div", { className: "flex h-8 w-8 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-xs font-medium", children: user.name ? getUserInitials(user.name) : "U" }),
2727
+ user.photo ? /* @__PURE__ */ jsx(
2728
+ "img",
2729
+ {
2730
+ src: user.photo,
2731
+ alt: user.name,
2732
+ className: "h-8 w-8 rounded-full object-cover"
2733
+ }
2734
+ ) : /* @__PURE__ */ jsx("div", { className: "flex h-8 w-8 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-xs font-medium", children: user.name ? getUserInitials(user.name) : "U" }),
2620
2735
  /* @__PURE__ */ jsxs("div", { className: "flex flex-col", children: [
2621
2736
  /* @__PURE__ */ jsx("span", { className: "text-sm font-medium leading-none", children: user.name }),
2622
2737
  user.email && /* @__PURE__ */ jsx("span", { className: "text-xs text-[hsl(var(--muted-foreground))] leading-none mt-1", children: user.email })
@@ -2631,11 +2746,25 @@ function AppHeader({
2631
2746
  className: "relative flex cursor-pointer select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm text-[hsl(var(--destructive))] outline-none transition-colors hover:bg-[hsl(var(--accent))]",
2632
2747
  onSelect: () => onLogout?.(),
2633
2748
  children: [
2634
- /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round", children: [
2635
- /* @__PURE__ */ jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
2636
- /* @__PURE__ */ jsx("polyline", { points: "16 17 21 12 16 7" }),
2637
- /* @__PURE__ */ jsx("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
2638
- ] }),
2749
+ /* @__PURE__ */ jsxs(
2750
+ "svg",
2751
+ {
2752
+ xmlns: "http://www.w3.org/2000/svg",
2753
+ width: "16",
2754
+ height: "16",
2755
+ viewBox: "0 0 24 24",
2756
+ fill: "none",
2757
+ stroke: "currentColor",
2758
+ strokeWidth: "1.5",
2759
+ strokeLinecap: "round",
2760
+ strokeLinejoin: "round",
2761
+ children: [
2762
+ /* @__PURE__ */ jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
2763
+ /* @__PURE__ */ jsx("polyline", { points: "16 17 21 12 16 7" }),
2764
+ /* @__PURE__ */ jsx("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
2765
+ ]
2766
+ }
2767
+ ),
2639
2768
  logoutLabel
2640
2769
  ]
2641
2770
  }
@@ -2670,19 +2799,33 @@ function AppSidebar({
2670
2799
  className
2671
2800
  ),
2672
2801
  children: [
2673
- logo && /* @__PURE__ */ jsxs("div", { className: "flex shrink-0 cursor-pointer items-center gap-2", onClick: logo.onClick, children: [
2674
- /* @__PURE__ */ jsx(
2675
- "div",
2676
- {
2677
- className: cn2(
2678
- "flex h-8 w-8 items-center justify-center rounded-lg overflow-hidden",
2679
- logo.url ? "bg-transparent" : "bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]"
2802
+ logo && /* @__PURE__ */ jsxs(
2803
+ "div",
2804
+ {
2805
+ className: "flex shrink-0 cursor-pointer items-center gap-2",
2806
+ onClick: logo.onClick,
2807
+ children: [
2808
+ /* @__PURE__ */ jsx(
2809
+ "div",
2810
+ {
2811
+ className: cn2(
2812
+ "flex h-8 w-8 items-center justify-center rounded-lg overflow-hidden",
2813
+ logo.url ? "bg-transparent" : "bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]"
2814
+ ),
2815
+ children: logo.url ? /* @__PURE__ */ jsx(
2816
+ "img",
2817
+ {
2818
+ src: logo.url,
2819
+ alt: logo.title,
2820
+ className: "h-full w-full object-contain"
2821
+ }
2822
+ ) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
2823
+ }
2680
2824
  ),
2681
- children: logo.url ? /* @__PURE__ */ jsx("img", { src: logo.url, alt: logo.title, className: "h-full w-full object-contain" }) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
2682
- }
2683
- ),
2684
- /* @__PURE__ */ jsx("span", { className: "text-lg font-semibold whitespace-nowrap", children: logo.title })
2685
- ] }),
2825
+ /* @__PURE__ */ jsx("span", { className: "text-lg font-semibold whitespace-nowrap", children: logo.title })
2826
+ ]
2827
+ }
2828
+ ),
2686
2829
  /* @__PURE__ */ jsx(
2687
2830
  SidebarNavList,
2688
2831
  {
@@ -2695,7 +2838,14 @@ function AppSidebar({
2695
2838
  (account || footer) && /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2", children: [
2696
2839
  account && /* @__PURE__ */ jsx("div", { className: "flex w-full flex-col gap-2 rounded-lg bg-[hsl(var(--muted))] p-2 shadow-sm", children: /* @__PURE__ */ jsxs("div", { className: "flex w-full items-center justify-between px-3 py-1", children: [
2697
2840
  /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
2698
- account.photo ? /* @__PURE__ */ jsx("img", { src: account.photo, alt: account.name, className: "h-5 w-5 rounded-full object-cover" }) : /* @__PURE__ */ jsx("div", { className: "flex h-5 w-5 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[10px] font-medium", children: account.name ? account.name.charAt(0).toUpperCase() : "U" }),
2841
+ account.photo ? /* @__PURE__ */ jsx(
2842
+ "img",
2843
+ {
2844
+ src: account.photo,
2845
+ alt: account.name,
2846
+ className: "h-5 w-5 rounded-full object-cover"
2847
+ }
2848
+ ) : /* @__PURE__ */ jsx("div", { className: "flex h-5 w-5 items-center justify-center rounded-full bg-[hsl(var(--muted))] text-[10px] font-medium", children: account.name ? account.name.charAt(0).toUpperCase() : "U" }),
2699
2849
  /* @__PURE__ */ jsx("span", { className: "text-xs font-medium truncate max-w-[100px]", children: account.name })
2700
2850
  ] }),
2701
2851
  onLogout && /* @__PURE__ */ jsx(
@@ -2704,11 +2854,25 @@ function AppSidebar({
2704
2854
  onClick: onLogout,
2705
2855
  className: "flex items-center justify-center text-[hsl(var(--destructive))] hover:opacity-80 transition-opacity",
2706
2856
  title: logoutLabel,
2707
- children: /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round", children: [
2708
- /* @__PURE__ */ jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
2709
- /* @__PURE__ */ jsx("polyline", { points: "16 17 21 12 16 7" }),
2710
- /* @__PURE__ */ jsx("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
2711
- ] })
2857
+ children: /* @__PURE__ */ jsxs(
2858
+ "svg",
2859
+ {
2860
+ xmlns: "http://www.w3.org/2000/svg",
2861
+ width: "16",
2862
+ height: "16",
2863
+ viewBox: "0 0 24 24",
2864
+ fill: "none",
2865
+ stroke: "currentColor",
2866
+ strokeWidth: "1.5",
2867
+ strokeLinecap: "round",
2868
+ strokeLinejoin: "round",
2869
+ children: [
2870
+ /* @__PURE__ */ jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
2871
+ /* @__PURE__ */ jsx("polyline", { points: "16 17 21 12 16 7" }),
2872
+ /* @__PURE__ */ jsx("line", { x1: "21", y1: "12", x2: "9", y2: "12" })
2873
+ ]
2874
+ }
2875
+ )
2712
2876
  }
2713
2877
  )
2714
2878
  ] }) }),
@@ -2718,7 +2882,12 @@ function AppSidebar({
2718
2882
  }
2719
2883
  );
2720
2884
  }
2721
- function SidebarNavList({ items, activeItemId, onNavigate, defaultExpandedGroups }) {
2885
+ function SidebarNavList({
2886
+ items,
2887
+ activeItemId,
2888
+ onNavigate,
2889
+ defaultExpandedGroups
2890
+ }) {
2722
2891
  const [expanded, setExpanded] = useState(() => {
2723
2892
  const map = {};
2724
2893
  (defaultExpandedGroups ?? items.map((i) => i.id)).forEach((id) => {
@@ -2733,84 +2902,115 @@ function SidebarNavList({ items, activeItemId, onNavigate, defaultExpandedGroups
2733
2902
  }
2734
2903
  }, [activeItemId]);
2735
2904
  const toggle = (id) => {
2736
- setExpanded((prev) => ({ ...prev, [id]: !prev[id] }));
2905
+ setExpanded((prev) => ({
2906
+ ...prev,
2907
+ [id]: !prev[id]
2908
+ }));
2737
2909
  };
2738
2910
  const resolvedActiveItemId = activeItemId ?? localActiveItemId;
2739
- return /* @__PURE__ */ jsxs("div", { className: "h-full flex-1 overflow-y-auto", style: { scrollbarWidth: "none", msOverflowStyle: "none" }, children: [
2740
- /* @__PURE__ */ jsx("style", { children: `.monkeys-sidebar-nav::-webkit-scrollbar { display: none; }` }),
2741
- /* @__PURE__ */ jsx("div", { className: "monkeys-sidebar-nav flex w-full flex-col gap-2 text-xs text-[hsl(var(--foreground))]", children: items.map((item) => {
2742
- if (item.children && item.children.length > 0) {
2743
- const isExpanded = expanded[item.id] ?? true;
2744
- return /* @__PURE__ */ jsxs("div", { children: [
2745
- /* @__PURE__ */ jsx(
2746
- NavButton,
2747
- {
2748
- icon: item.icon,
2749
- onClick: () => toggle(item.id),
2750
- postfix: /* @__PURE__ */ jsx("div", { className: "flex flex-1 justify-end", children: /* @__PURE__ */ jsx(
2751
- "svg",
2911
+ return /* @__PURE__ */ jsxs(
2912
+ "div",
2913
+ {
2914
+ className: "h-full flex-1 overflow-y-auto",
2915
+ style: { scrollbarWidth: "none", msOverflowStyle: "none" },
2916
+ children: [
2917
+ /* @__PURE__ */ jsx("style", { children: `.monkeys-sidebar-nav::-webkit-scrollbar { display: none; }` }),
2918
+ /* @__PURE__ */ jsx("div", { className: "monkeys-sidebar-nav flex w-full flex-col gap-2 text-xs text-[hsl(var(--foreground))]", children: items.map((item) => {
2919
+ if (item.children && item.children.length > 0) {
2920
+ const isExpanded = expanded[item.id] ?? true;
2921
+ return /* @__PURE__ */ jsxs("div", { children: [
2922
+ /* @__PURE__ */ jsx(
2923
+ NavButton,
2752
2924
  {
2753
- xmlns: "http://www.w3.org/2000/svg",
2754
- width: "16",
2755
- height: "16",
2756
- viewBox: "0 0 24 24",
2757
- fill: "none",
2758
- stroke: "currentColor",
2759
- strokeWidth: "2",
2760
- strokeLinecap: "round",
2761
- strokeLinejoin: "round",
2762
- className: "shrink-0 text-[hsl(var(--foreground))] transition-transform duration-200",
2763
- style: { transform: isExpanded ? "rotate(90deg)" : "rotate(0deg)" },
2764
- children: /* @__PURE__ */ jsx("path", { d: "m9 18 6-6-6-6" })
2925
+ icon: item.icon,
2926
+ onClick: () => toggle(item.id),
2927
+ postfix: /* @__PURE__ */ jsx("div", { className: "flex flex-1 justify-end", children: /* @__PURE__ */ jsx(
2928
+ "svg",
2929
+ {
2930
+ xmlns: "http://www.w3.org/2000/svg",
2931
+ width: "16",
2932
+ height: "16",
2933
+ viewBox: "0 0 24 24",
2934
+ fill: "none",
2935
+ stroke: "currentColor",
2936
+ strokeWidth: "2",
2937
+ strokeLinecap: "round",
2938
+ strokeLinejoin: "round",
2939
+ className: "shrink-0 text-[hsl(var(--foreground))] transition-transform duration-200",
2940
+ style: {
2941
+ transform: isExpanded ? "rotate(90deg)" : "rotate(0deg)"
2942
+ },
2943
+ children: /* @__PURE__ */ jsx("path", { d: "m9 18 6-6-6-6" })
2944
+ }
2945
+ ) }),
2946
+ children: item.label
2765
2947
  }
2766
- ) }),
2767
- children: item.label
2768
- }
2769
- ),
2770
- isExpanded && /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-1 mt-1", children: item.children.map((child) => /* @__PURE__ */ jsx(
2948
+ ),
2949
+ isExpanded && /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-1 mt-1", children: item.children.map((child) => /* @__PURE__ */ jsx(
2950
+ NavButton,
2951
+ {
2952
+ active: child.id === resolvedActiveItemId,
2953
+ onClick: () => {
2954
+ setLocalActiveItemId(child.id);
2955
+ onNavigate?.(child.id);
2956
+ },
2957
+ children: child.label
2958
+ },
2959
+ child.id
2960
+ )) })
2961
+ ] }, item.id);
2962
+ }
2963
+ return /* @__PURE__ */ jsx(
2771
2964
  NavButton,
2772
2965
  {
2773
- active: child.id === resolvedActiveItemId,
2966
+ icon: item.icon,
2967
+ active: item.id === resolvedActiveItemId,
2774
2968
  onClick: () => {
2775
- setLocalActiveItemId(child.id);
2776
- onNavigate?.(child.id);
2969
+ setLocalActiveItemId(item.id);
2970
+ onNavigate?.(item.id);
2777
2971
  },
2778
- children: child.label
2972
+ children: item.label
2779
2973
  },
2780
- child.id
2781
- )) })
2782
- ] }, item.id);
2783
- }
2784
- return /* @__PURE__ */ jsx(
2785
- NavButton,
2786
- {
2787
- icon: item.icon,
2788
- active: item.id === resolvedActiveItemId,
2789
- onClick: () => {
2790
- setLocalActiveItemId(item.id);
2791
- onNavigate?.(item.id);
2792
- },
2793
- children: item.label
2794
- },
2795
- item.id
2796
- );
2797
- }) })
2798
- ] });
2974
+ item.id
2975
+ );
2976
+ }) })
2977
+ ]
2978
+ }
2979
+ );
2799
2980
  }
2800
- function AppLayout({ header, sidebar, children, flush = false, className }) {
2801
- return /* @__PURE__ */ jsxs("div", { className: cn2(
2802
- "flex h-screen flex-col gap-[var(--global-spacing,0.75rem)] overflow-hidden p-[var(--global-spacing,0.75rem)]",
2803
- className
2804
- ), style: { backgroundColor: "hsl(var(--muted))" }, children: [
2805
- header ? header : null,
2806
- /* @__PURE__ */ jsxs("div", { className: "flex flex-1 gap-[var(--global-spacing,0.75rem)] overflow-hidden min-h-0", children: [
2807
- sidebar ? sidebar : null,
2808
- /* @__PURE__ */ jsx("main", { className: cn2(
2809
- "flex-1 min-h-0 overflow-hidden rounded-xl border border-[hsl(var(--input))] bg-[hsl(var(--background))]",
2810
- !flush && "overflow-y-auto"
2811
- ), children: flush ? children : /* @__PURE__ */ jsx("div", { className: "h-full overflow-y-auto", children }) })
2812
- ] })
2813
- ] });
2981
+ function AppLayout({
2982
+ header,
2983
+ sidebar,
2984
+ children,
2985
+ flush = false,
2986
+ className
2987
+ }) {
2988
+ return /* @__PURE__ */ jsxs(
2989
+ "div",
2990
+ {
2991
+ className: cn2(
2992
+ "flex h-screen flex-col gap-[var(--global-spacing,0.75rem)] overflow-hidden p-[var(--global-spacing,0.75rem)]",
2993
+ className
2994
+ ),
2995
+ style: { backgroundColor: "hsl(var(--muted))" },
2996
+ children: [
2997
+ header ? header : null,
2998
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-1 gap-[var(--global-spacing,0.75rem)] overflow-hidden min-h-0", children: [
2999
+ sidebar ? sidebar : null,
3000
+ /* @__PURE__ */ jsx(
3001
+ "main",
3002
+ {
3003
+ className: cn2(
3004
+ "flex-1 min-h-0 overflow-hidden rounded-xl border border-[hsl(var(--input))] bg-[hsl(var(--background))]",
3005
+ !flush && "overflow-y-auto"
3006
+ ),
3007
+ children: flush ? children : /* @__PURE__ */ jsx("div", { className: "h-full overflow-y-auto", children })
3008
+ }
3009
+ )
3010
+ ] })
3011
+ ]
3012
+ }
3013
+ );
2814
3014
  }
2815
3015
  var NAVIGATION_LAYOUT_SIDEBAR_EXPANDED_WIDTH = "13.7rem";
2816
3016
  var NAVIGATION_LAYOUT_SIDEBAR_COLLAPSED_WIDTH = "4.25rem";
@@ -2832,15 +3032,39 @@ var NAVIGATION_LAYOUT_DEFAULT_APPEARANCE = {
2832
3032
  };
2833
3033
  var NAVIGATION_LAYOUT_MENU_RADIUS_CLASS_MAP = {
2834
3034
  none: { all: "rounded-none", left: "!rounded-none", right: "!rounded-none" },
2835
- sm: { all: "rounded-sm", left: "!rounded-l-sm !rounded-r-none", right: "!rounded-l-none !rounded-r-sm" },
2836
- md: { all: "rounded-md", left: "!rounded-l-md !rounded-r-none", right: "!rounded-l-none !rounded-r-md" },
2837
- lg: { all: "rounded-lg", left: "!rounded-l-lg !rounded-r-none", right: "!rounded-l-none !rounded-r-lg" },
2838
- xl: { all: "rounded-xl", left: "!rounded-l-xl !rounded-r-none", right: "!rounded-l-none !rounded-r-xl" },
2839
- full: { all: "rounded-full", left: "!rounded-l-full !rounded-r-none", right: "!rounded-l-none !rounded-r-full" }
3035
+ sm: {
3036
+ all: "rounded-sm",
3037
+ left: "!rounded-l-sm !rounded-r-none",
3038
+ right: "!rounded-l-none !rounded-r-sm"
3039
+ },
3040
+ md: {
3041
+ all: "rounded-md",
3042
+ left: "!rounded-l-md !rounded-r-none",
3043
+ right: "!rounded-l-none !rounded-r-md"
3044
+ },
3045
+ lg: {
3046
+ all: "rounded-lg",
3047
+ left: "!rounded-l-lg !rounded-r-none",
3048
+ right: "!rounded-l-none !rounded-r-lg"
3049
+ },
3050
+ xl: {
3051
+ all: "rounded-xl",
3052
+ left: "!rounded-l-xl !rounded-r-none",
3053
+ right: "!rounded-l-none !rounded-r-xl"
3054
+ },
3055
+ full: {
3056
+ all: "rounded-full",
3057
+ left: "!rounded-l-full !rounded-r-none",
3058
+ right: "!rounded-l-none !rounded-r-full"
3059
+ }
2840
3060
  };
2841
3061
  function clampHeadbarHeight(value) {
2842
- if (typeof value !== "number" || !Number.isFinite(value)) return NAVIGATION_LAYOUT_HEADBAR_DEFAULT_HEIGHT_PX;
2843
- return Math.min(NAVIGATION_LAYOUT_HEADBAR_MAX_HEIGHT_PX, Math.max(NAVIGATION_LAYOUT_HEADBAR_MIN_HEIGHT_PX, Math.round(value)));
3062
+ if (typeof value !== "number" || !Number.isFinite(value))
3063
+ return NAVIGATION_LAYOUT_HEADBAR_DEFAULT_HEIGHT_PX;
3064
+ return Math.min(
3065
+ NAVIGATION_LAYOUT_HEADBAR_MAX_HEIGHT_PX,
3066
+ Math.max(NAVIGATION_LAYOUT_HEADBAR_MIN_HEIGHT_PX, Math.round(value))
3067
+ );
2844
3068
  }
2845
3069
  function getHeadbarVerticalPaddingPx(heightPx) {
2846
3070
  return heightPx <= NAVIGATION_LAYOUT_HEADBAR_COMPACT_HEIGHT_THRESHOLD_PX ? NAVIGATION_LAYOUT_HEADBAR_COMPACT_VERTICAL_PADDING_PX : NAVIGATION_LAYOUT_HEADBAR_BOXED_VERTICAL_PADDING_PX;
@@ -2858,7 +3082,13 @@ function getHeadbarMenuRadiusClass(menuRadius = "default", part = "all") {
2858
3082
  }
2859
3083
  function getHeadbarFrameClass(layoutMode = "boxed", navPosition = "center") {
2860
3084
  const columns = navPosition === "center" ? "grid-cols-[minmax(max-content,1fr)_minmax(0,max-content)_minmax(max-content,1fr)]" : "grid-cols-[max-content_minmax(0,1fr)_max-content]";
2861
- return layoutMode === "full-bleed" ? cn2("sticky top-0 z-40 grid w-full shrink-0 items-center gap-4 rounded-none border-b border-x-0 border-t-0 border-[hsl(var(--input))] bg-[hsl(var(--background))] p-[var(--global-spacing,0.75rem)]", columns) : cn2("sticky top-0 z-40 grid w-full shrink-0 items-center gap-4 rounded-xl border border-[hsl(var(--input))] bg-[hsl(var(--background))] p-[var(--global-spacing,0.75rem)]", columns);
3085
+ return layoutMode === "full-bleed" ? cn2(
3086
+ "sticky top-0 z-40 grid w-full shrink-0 items-center gap-4 rounded-none border-b border-x-0 border-t-0 border-[hsl(var(--input))] bg-[hsl(var(--background))] p-[var(--global-spacing,0.75rem)]",
3087
+ columns
3088
+ ) : cn2(
3089
+ "sticky top-0 z-40 grid w-full shrink-0 items-center gap-4 rounded-xl border border-[hsl(var(--input))] bg-[hsl(var(--background))] p-[var(--global-spacing,0.75rem)]",
3090
+ columns
3091
+ );
2862
3092
  }
2863
3093
  function getHeadbarFrameStyle(layoutMode = "boxed", heightPx, surface = "card") {
2864
3094
  const verticalPaddingPx = getHeadbarVerticalPaddingPx(heightPx);
@@ -2904,7 +3134,8 @@ function getHeadbarItemStyle(active, useTokenRadius = true) {
2904
3134
  function findNavigationRootId(items, activeItemId) {
2905
3135
  for (const item of items) {
2906
3136
  if (item.id === activeItemId) return item.id;
2907
- if (item.children?.some((child) => child.id === activeItemId)) return item.id;
3137
+ if (item.children?.some((child) => child.id === activeItemId))
3138
+ return item.id;
2908
3139
  }
2909
3140
  return activeItemId;
2910
3141
  }
@@ -2973,7 +3204,9 @@ function SidebarNavigationList({
2973
3204
  revealRequest
2974
3205
  }) {
2975
3206
  const navRef = useRef(null);
2976
- const [expandedByRoot, setExpandedByRoot] = useState({});
3207
+ const [expandedByRoot, setExpandedByRoot] = useState(
3208
+ {}
3209
+ );
2977
3210
  const toggleRoot = (id) => {
2978
3211
  setExpandedByRoot((current) => ({
2979
3212
  ...current,
@@ -2991,65 +3224,86 @@ function SidebarNavigationList({
2991
3224
  `[data-navigation-sidebar-root-id="${CSS.escape(revealRequest.id)}"]`
2992
3225
  );
2993
3226
  if (targetElement instanceof HTMLElement) {
2994
- targetElement.scrollIntoView({ behavior: "auto", block: "nearest", inline: "nearest" });
3227
+ targetElement.scrollIntoView({
3228
+ behavior: "auto",
3229
+ block: "nearest",
3230
+ inline: "nearest"
3231
+ });
2995
3232
  }
2996
3233
  });
2997
3234
  return () => window.cancelAnimationFrame(frameId);
2998
3235
  }, [revealRequest]);
2999
- return /* @__PURE__ */ jsxs("div", { className: "h-full flex-1 overflow-y-auto", style: { scrollbarWidth: "none", msOverflowStyle: "none" }, children: [
3000
- /* @__PURE__ */ jsx("style", { children: `.monkeys-navigation-sidebar-nav::-webkit-scrollbar { display: none; }` }),
3001
- /* @__PURE__ */ jsx(
3002
- "div",
3003
- {
3004
- ref: navRef,
3005
- className: "monkeys-navigation-sidebar-nav flex w-full flex-col gap-2 text-xs text-[hsl(var(--foreground))]",
3006
- children: items.map((item) => {
3007
- const isGroup = Boolean(item.children?.length);
3008
- const isExpanded = Boolean(expandedByRoot[item.id]);
3009
- const isActive = activeItemId === item.id;
3010
- if (isGroup) {
3011
- return /* @__PURE__ */ jsxs("div", { "data-navigation-sidebar-root-id": item.id, children: [
3012
- /* @__PURE__ */ jsx(
3236
+ return /* @__PURE__ */ jsxs(
3237
+ "div",
3238
+ {
3239
+ className: "h-full flex-1 overflow-y-auto",
3240
+ style: { scrollbarWidth: "none", msOverflowStyle: "none" },
3241
+ children: [
3242
+ /* @__PURE__ */ jsx("style", { children: `.monkeys-navigation-sidebar-nav::-webkit-scrollbar { display: none; }` }),
3243
+ /* @__PURE__ */ jsx(
3244
+ "div",
3245
+ {
3246
+ ref: navRef,
3247
+ className: "monkeys-navigation-sidebar-nav flex w-full flex-col gap-2 text-xs text-[hsl(var(--foreground))]",
3248
+ children: items.map((item) => {
3249
+ const isGroup = Boolean(item.children?.length);
3250
+ const isExpanded = Boolean(expandedByRoot[item.id]);
3251
+ const isActive = activeItemId === item.id;
3252
+ if (isGroup) {
3253
+ return /* @__PURE__ */ jsxs("div", { "data-navigation-sidebar-root-id": item.id, children: [
3254
+ /* @__PURE__ */ jsx(
3255
+ NavButton,
3256
+ {
3257
+ icon: item.icon,
3258
+ onClick: () => toggleRoot(item.id),
3259
+ postfix: /* @__PURE__ */ jsx("div", { className: "flex flex-1 justify-end", children: /* @__PURE__ */ jsx(
3260
+ "svg",
3261
+ {
3262
+ xmlns: "http://www.w3.org/2000/svg",
3263
+ width: "16",
3264
+ height: "16",
3265
+ viewBox: "0 0 24 24",
3266
+ fill: "none",
3267
+ stroke: "currentColor",
3268
+ strokeWidth: "2",
3269
+ strokeLinecap: "round",
3270
+ strokeLinejoin: "round",
3271
+ className: "shrink-0 text-[hsl(var(--foreground))] transition-transform duration-200",
3272
+ style: {
3273
+ transform: isExpanded ? "rotate(90deg)" : "rotate(0deg)"
3274
+ },
3275
+ children: /* @__PURE__ */ jsx("path", { d: "m9 18 6-6-6-6" })
3276
+ }
3277
+ ) }),
3278
+ children: item.label
3279
+ }
3280
+ ),
3281
+ isExpanded ? /* @__PURE__ */ jsx("div", { className: "mt-1 flex flex-col gap-1", children: item.children?.map((child) => /* @__PURE__ */ jsx(
3282
+ NavButton,
3283
+ {
3284
+ active: activeItemId === child.id,
3285
+ onClick: () => onNavigate?.(child.id),
3286
+ children: child.label
3287
+ },
3288
+ child.id
3289
+ )) }) : null
3290
+ ] }, item.id);
3291
+ }
3292
+ return /* @__PURE__ */ jsx("div", { "data-navigation-sidebar-root-id": item.id, children: /* @__PURE__ */ jsx(
3013
3293
  NavButton,
3014
3294
  {
3295
+ active: isActive,
3015
3296
  icon: item.icon,
3016
- onClick: () => toggleRoot(item.id),
3017
- postfix: /* @__PURE__ */ jsx("div", { className: "flex flex-1 justify-end", children: /* @__PURE__ */ jsx(
3018
- "svg",
3019
- {
3020
- xmlns: "http://www.w3.org/2000/svg",
3021
- width: "16",
3022
- height: "16",
3023
- viewBox: "0 0 24 24",
3024
- fill: "none",
3025
- stroke: "currentColor",
3026
- strokeWidth: "2",
3027
- strokeLinecap: "round",
3028
- strokeLinejoin: "round",
3029
- className: "shrink-0 text-[hsl(var(--foreground))] transition-transform duration-200",
3030
- style: { transform: isExpanded ? "rotate(90deg)" : "rotate(0deg)" },
3031
- children: /* @__PURE__ */ jsx("path", { d: "m9 18 6-6-6-6" })
3032
- }
3033
- ) }),
3297
+ onClick: () => onNavigate?.(item.id),
3034
3298
  children: item.label
3035
3299
  }
3036
- ),
3037
- isExpanded ? /* @__PURE__ */ jsx("div", { className: "mt-1 flex flex-col gap-1", children: item.children?.map((child) => /* @__PURE__ */ jsx(
3038
- NavButton,
3039
- {
3040
- active: activeItemId === child.id,
3041
- onClick: () => onNavigate?.(child.id),
3042
- children: child.label
3043
- },
3044
- child.id
3045
- )) }) : null
3046
- ] }, item.id);
3300
+ ) }, item.id);
3301
+ })
3047
3302
  }
3048
- return /* @__PURE__ */ jsx("div", { "data-navigation-sidebar-root-id": item.id, children: /* @__PURE__ */ jsx(NavButton, { active: isActive, icon: item.icon, onClick: () => onNavigate?.(item.id), children: item.label }) }, item.id);
3049
- })
3050
- }
3051
- )
3052
- ] });
3303
+ )
3304
+ ]
3305
+ }
3306
+ );
3053
3307
  }
3054
3308
  function SidebarBrand({
3055
3309
  collapsed,
@@ -3065,7 +3319,14 @@ function SidebarBrand({
3065
3319
  "flex h-9 w-9 shrink-0 items-center justify-center overflow-hidden rounded-lg",
3066
3320
  logo.url ? "bg-transparent" : "bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]"
3067
3321
  ),
3068
- children: logo.url ? /* @__PURE__ */ jsx("img", { src: logo.url, alt: logo.title, className: "h-full w-full object-contain" }) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
3322
+ children: logo.url ? /* @__PURE__ */ jsx(
3323
+ "img",
3324
+ {
3325
+ src: logo.url,
3326
+ alt: logo.title,
3327
+ className: "h-full w-full object-contain"
3328
+ }
3329
+ ) : /* @__PURE__ */ jsx("span", { className: "text-sm font-bold", children: logo.title.charAt(0) })
3069
3330
  }
3070
3331
  );
3071
3332
  if (collapsed) {
@@ -3199,7 +3460,10 @@ function HeadbarChevronIcon({ open }) {
3199
3460
  "svg",
3200
3461
  {
3201
3462
  "aria-hidden": "true",
3202
- className: cn2("h-4 w-4 shrink-0 transition-transform duration-200", open && "rotate-180"),
3463
+ className: cn2(
3464
+ "h-4 w-4 shrink-0 transition-transform duration-200",
3465
+ open && "rotate-180"
3466
+ ),
3203
3467
  viewBox: "0 0 24 24",
3204
3468
  fill: "none",
3205
3469
  stroke: "currentColor",
@@ -3293,7 +3557,10 @@ function HeadbarNavMenuItem({
3293
3557
  "relative flex cursor-pointer select-none items-center gap-2.5 px-3 py-2 text-sm outline-none transition-colors hover:bg-[var(--monkeys-component-navigation-headbar-item-hover-background,hsl(var(--accent)))]",
3294
3558
  menuItemRadiusClass
3295
3559
  ),
3296
- style: getHeadbarItemStyle(child.id === activeItemId, useTokenRadius),
3560
+ style: getHeadbarItemStyle(
3561
+ child.id === activeItemId,
3562
+ useTokenRadius
3563
+ ),
3297
3564
  onSelect: () => {
3298
3565
  if (child.disabled) return;
3299
3566
  setOpen(false);
@@ -3394,7 +3661,10 @@ function NavigationHeadbar({
3394
3661
  return /* @__PURE__ */ jsxs(
3395
3662
  "header",
3396
3663
  {
3397
- className: cn2(getHeadbarFrameClass(layoutMode, layout?.navPosition), className),
3664
+ className: cn2(
3665
+ getHeadbarFrameClass(layoutMode, layout?.navPosition),
3666
+ className
3667
+ ),
3398
3668
  "data-navigation-headbar": "",
3399
3669
  "data-navigation-headbar-surface": surface,
3400
3670
  style: frameStyle,
@@ -3412,7 +3682,14 @@ function NavigationHeadbar({
3412
3682
  logo.url ? "w-auto max-w-[min(22rem,30vw)] bg-transparent" : "bg-[hsl(var(--primary))] text-[hsl(var(--primary-foreground))]"
3413
3683
  ),
3414
3684
  style: logo.url ? { height: logoHeightPx } : { width: logoHeightPx, height: logoHeightPx },
3415
- children: logo.url ? /* @__PURE__ */ jsx("img", { src: logo.url, alt: logo.title, className: "block h-full w-auto object-contain" }) : /* @__PURE__ */ jsx("span", { className: "text-base font-bold", children: logo.title.charAt(0) })
3685
+ children: logo.url ? /* @__PURE__ */ jsx(
3686
+ "img",
3687
+ {
3688
+ src: logo.url,
3689
+ alt: logo.title,
3690
+ className: "block h-full w-auto object-contain"
3691
+ }
3692
+ ) : /* @__PURE__ */ jsx("span", { className: "text-base font-bold", children: logo.title.charAt(0) })
3416
3693
  }
3417
3694
  ),
3418
3695
  label: showBrandTitle ? /* @__PURE__ */ jsx("span", { className: "truncate whitespace-nowrap text-base font-medium text-[hsl(var(--foreground))]", children: layout?.brandTitle }) : null,
@@ -3423,16 +3700,25 @@ function NavigationHeadbar({
3423
3700
  onClick: logo.onClick
3424
3701
  }
3425
3702
  ) : null) }),
3426
- /* @__PURE__ */ jsx("div", { className: cn2("flex min-w-0 items-center", getHeadbarNavClass(layout?.navPosition)), children: /* @__PURE__ */ jsx("div", { className: "no-scrollbar flex max-w-full min-w-0 items-center overflow-x-auto overscroll-x-contain", children: navigation ?? /* @__PURE__ */ jsx(
3427
- NavigationHeadbarMenu,
3703
+ /* @__PURE__ */ jsx(
3704
+ "div",
3428
3705
  {
3429
- activeItemId,
3430
- activeRootId,
3431
- items: navItems,
3432
- menuRadius,
3433
- onNavigate
3706
+ className: cn2(
3707
+ "flex min-w-0 items-center",
3708
+ getHeadbarNavClass(layout?.navPosition)
3709
+ ),
3710
+ children: /* @__PURE__ */ jsx("div", { className: "no-scrollbar flex max-w-full min-w-0 items-center overflow-x-auto overscroll-x-contain", children: navigation ?? /* @__PURE__ */ jsx(
3711
+ NavigationHeadbarMenu,
3712
+ {
3713
+ activeItemId,
3714
+ activeRootId,
3715
+ items: navItems,
3716
+ menuRadius,
3717
+ onNavigate
3718
+ }
3719
+ ) })
3434
3720
  }
3435
- ) }) }),
3721
+ ),
3436
3722
  /* @__PURE__ */ jsxs("div", { className: "flex min-w-0 items-center justify-end gap-3", children: [
3437
3723
  actions,
3438
3724
  extra,
@@ -3510,21 +3796,47 @@ function NavigationLayout({
3510
3796
  id: "toggle-headbar",
3511
3797
  label: switchToHeadbarLabel,
3512
3798
  onClick: () => setNavigationMode("headbar"),
3513
- icon: /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", className: "h-[18px] w-[18px] rotate-180", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", children: [
3514
- /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3515
- /* @__PURE__ */ jsx("path", { d: "M3 9h18" })
3516
- ] })
3799
+ icon: /* @__PURE__ */ jsxs(
3800
+ "svg",
3801
+ {
3802
+ xmlns: "http://www.w3.org/2000/svg",
3803
+ className: "h-[18px] w-[18px] rotate-180",
3804
+ viewBox: "0 0 24 24",
3805
+ fill: "none",
3806
+ stroke: "currentColor",
3807
+ strokeWidth: "1.8",
3808
+ strokeLinecap: "round",
3809
+ strokeLinejoin: "round",
3810
+ children: [
3811
+ /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3812
+ /* @__PURE__ */ jsx("path", { d: "M3 9h18" })
3813
+ ]
3814
+ }
3815
+ )
3517
3816
  });
3518
3817
  }
3519
3818
  navigationActions.push({
3520
3819
  id: "toggle-sidebar",
3521
3820
  label: sidebarCollapsed ? expandSidebarLabel : collapseSidebarLabel,
3522
3821
  onClick: () => setCollapsed(!sidebarCollapsed),
3523
- icon: /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", className: "h-[18px] w-[18px]", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", children: [
3524
- /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3525
- /* @__PURE__ */ jsx("path", { d: "M9 3v18" }),
3526
- /* @__PURE__ */ jsx("path", { d: sidebarCollapsed ? "m14 9 3 3-3 3" : "m16 15-3-3 3-3" })
3527
- ] })
3822
+ icon: /* @__PURE__ */ jsxs(
3823
+ "svg",
3824
+ {
3825
+ xmlns: "http://www.w3.org/2000/svg",
3826
+ className: "h-[18px] w-[18px]",
3827
+ viewBox: "0 0 24 24",
3828
+ fill: "none",
3829
+ stroke: "currentColor",
3830
+ strokeWidth: "1.8",
3831
+ strokeLinecap: "round",
3832
+ strokeLinejoin: "round",
3833
+ children: [
3834
+ /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3835
+ /* @__PURE__ */ jsx("path", { d: "M9 3v18" }),
3836
+ /* @__PURE__ */ jsx("path", { d: sidebarCollapsed ? "m14 9 3 3-3 3" : "m16 15-3-3 3-3" })
3837
+ ]
3838
+ }
3839
+ )
3528
3840
  });
3529
3841
  const sidebar = isHeadbarMode ? null : /* @__PURE__ */ jsx(
3530
3842
  "div",
@@ -3533,7 +3845,10 @@ function NavigationLayout({
3533
3845
  "relative h-full min-h-0 shrink-0 transition-[width] duration-260",
3534
3846
  sidebarCollapsed ? "z-20 overflow-visible" : "z-10 overflow-hidden"
3535
3847
  ),
3536
- style: { width: sidebarWidth, transitionTimingFunction: NAVIGATION_LAYOUT_TRANSITION_TIMING },
3848
+ style: {
3849
+ width: sidebarWidth,
3850
+ transitionTimingFunction: NAVIGATION_LAYOUT_TRANSITION_TIMING
3851
+ },
3537
3852
  children: /* @__PURE__ */ jsx(
3538
3853
  Sidebar,
3539
3854
  {
@@ -3548,7 +3863,10 @@ function NavigationLayout({
3548
3863
  logo,
3549
3864
  onCollapsedChange: setCollapsed,
3550
3865
  onNavigate,
3551
- onRevealRoot: (rootId) => setRevealRequest((prev) => ({ id: rootId, nonce: (prev?.nonce ?? 0) + 1 })),
3866
+ onRevealRoot: (rootId) => setRevealRequest((prev) => ({
3867
+ id: rootId,
3868
+ nonce: (prev?.nonce ?? 0) + 1
3869
+ })),
3552
3870
  revealRequest,
3553
3871
  title: headbarLayout?.brandTitle
3554
3872
  }
@@ -3567,11 +3885,24 @@ function NavigationLayout({
3567
3885
  {
3568
3886
  appearance: NAVIGATION_LAYOUT_DEFAULT_APPEARANCE,
3569
3887
  tone: "muted",
3570
- icon: /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", className: "h-4 w-4 shrink-0", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", strokeLinejoin: "round", children: [
3571
- /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3572
- /* @__PURE__ */ jsx("path", { d: "M9 3v18" }),
3573
- /* @__PURE__ */ jsx("path", { d: "m14 9 3 3-3 3" })
3574
- ] }),
3888
+ icon: /* @__PURE__ */ jsxs(
3889
+ "svg",
3890
+ {
3891
+ xmlns: "http://www.w3.org/2000/svg",
3892
+ className: "h-4 w-4 shrink-0",
3893
+ viewBox: "0 0 24 24",
3894
+ fill: "none",
3895
+ stroke: "currentColor",
3896
+ strokeWidth: "1.8",
3897
+ strokeLinecap: "round",
3898
+ strokeLinejoin: "round",
3899
+ children: [
3900
+ /* @__PURE__ */ jsx("rect", { width: "18", height: "18", x: "3", y: "3", rx: "2" }),
3901
+ /* @__PURE__ */ jsx("path", { d: "M9 3v18" }),
3902
+ /* @__PURE__ */ jsx("path", { d: "m14 9 3 3-3 3" })
3903
+ ]
3904
+ }
3905
+ ),
3575
3906
  label: /* @__PURE__ */ jsx("span", { className: "truncate whitespace-nowrap", children: switchToSidebarLabel }),
3576
3907
  onClick: () => setNavigationMode("sidebar"),
3577
3908
  className: cn2(
@@ -3589,9 +3920,18 @@ function NavigationLayout({
3589
3920
  onNavigate
3590
3921
  }
3591
3922
  ) : null;
3592
- return /* @__PURE__ */ jsx(AppLayout, { header, sidebar, flush, className, children });
3923
+ return /* @__PURE__ */ jsx(
3924
+ AppLayout,
3925
+ {
3926
+ header,
3927
+ sidebar,
3928
+ flush,
3929
+ className,
3930
+ children
3931
+ }
3932
+ );
3593
3933
  }
3594
3934
 
3595
- export { AppHeader, AppLayout, AppSidebar, NavButton, NavigationHeadbar, NavigationHeadbarMenu, NavigationLayout, UserAccountMenu, cn2 as cn };
3935
+ export { AppHeader, AppLayout, AppShellSidebar, AppSidebar, NavButton, NavigationHeadbar, NavigationHeadbarMenu, NavigationLayout, UserAccountMenu, cn2 as cn };
3596
3936
  //# sourceMappingURL=index.mjs.map
3597
3937
  //# sourceMappingURL=index.mjs.map