@krak-stack/registry 0.11.4 → 0.11.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -1
- package/README.md +23 -9
- package/dist/components/agent/react.js +226 -1072
- package/dist/components/app-switcher/html.js +10 -53
- package/dist/components/app-switcher/react.js +29 -139
- package/dist/components/async-action-button/html.js +3 -34
- package/dist/components/async-action-button/react.d.ts +1 -1
- package/dist/components/async-action-button/react.js +8 -54
- package/dist/components/audit-log-table/react.js +555 -1265
- package/dist/components/bulk-list-input/html.js +3 -40
- package/dist/components/bulk-list-input/react.d.ts +1 -1
- package/dist/components/bulk-list-input/react.js +6 -59
- package/dist/components/code-block/html.js +1 -35
- package/dist/components/code-block/react.js +12 -59
- package/dist/components/color-input/html.js +2 -19
- package/dist/components/color-input/react.js +6 -97
- package/dist/components/copy-button/html.js +1 -35
- package/dist/components/copy-button/react.d.ts +1 -1
- package/dist/components/copy-button/react.js +7 -54
- package/dist/components/copy-value/html.js +11 -52
- package/dist/components/copy-value/react.js +25 -165
- package/dist/components/cron-input/html.js +2 -18
- package/dist/components/cron-input/react.js +15 -30
- package/dist/components/danger-confirmation/html.js +11 -57
- package/dist/components/danger-confirmation/react.js +26 -187
- package/dist/components/data-table/html.d.ts +12 -12
- package/dist/components/data-table/html.js +200 -174
- package/dist/components/data-table/react.js +549 -1259
- package/dist/components/date-input/html.js +19 -74
- package/dist/components/date-input/react.d.ts +1 -1
- package/dist/components/date-input/react.js +28 -313
- package/dist/components/docs/classes.d.ts +15 -0
- package/dist/components/docs/html.d.ts +55 -0
- package/dist/components/docs/html.js +837 -0
- package/dist/components/docs/index.d.ts +49 -0
- package/dist/components/docs/react.d.ts +10 -0
- package/dist/components/docs/react.js +949 -0
- package/dist/components/docs/schema.d.ts +49 -0
- package/dist/components/editable-text/html.js +6 -52
- package/dist/components/editable-text/react.js +13 -83
- package/dist/components/editing-locale-switcher/html.d.ts +2 -2
- package/dist/components/editing-locale-switcher/html.js +13 -43
- package/dist/components/editing-locale-switcher/react.js +17 -141
- package/dist/components/effect-form/react.js +249 -812
- package/dist/components/email-composer/react.js +62 -279
- package/dist/components/email-editor/html.js +13 -58
- package/dist/components/email-editor/react.js +187 -483
- package/dist/components/error-component/html.js +2 -47
- package/dist/components/error-component/react.js +33 -137
- package/dist/components/file-input/html.js +9 -40
- package/dist/components/file-input/react.js +39 -208
- package/dist/components/form/react.js +212 -777
- package/dist/components/icon-input/html.js +9 -56
- package/dist/components/icon-input/react.js +43 -143
- package/dist/components/image-crop-editor/html.js +1 -35
- package/dist/components/image-crop-editor/react.js +21 -66
- package/dist/components/locale-switcher/html.js +8 -55
- package/dist/components/locale-switcher/react.js +21 -146
- package/dist/components/map-menu/html.d.ts +8 -8
- package/dist/components/map-menu/html.js +13 -72
- package/dist/components/map-menu/react.js +92 -309
- package/dist/components/markdown/html.js +1 -35
- package/dist/components/markdown/react.js +20 -64
- package/dist/components/notification-menu/html.js +14 -50
- package/dist/components/notification-menu/react.js +73 -343
- package/dist/components/pagination/html.js +17 -73
- package/dist/components/pagination/react.js +37 -200
- package/dist/components/phone-number-input/html.js +19 -57
- package/dist/components/phone-number-input/react.d.ts +1 -1
- package/dist/components/phone-number-input/react.js +43 -142
- package/dist/components/presence-transition/index.d.ts +2 -2
- package/dist/components/registry-previews/component-example.js +26 -126
- package/dist/components/rich-text-editor/html.d.ts +12 -12
- package/dist/components/rich-text-editor/html.js +12 -85
- package/dist/components/rich-text-editor/react.js +55 -272
- package/dist/components/search-menu/classes.d.ts +2 -0
- package/dist/components/search-menu/html.d.ts +2 -0
- package/dist/components/search-menu/html.js +40 -73
- package/dist/components/search-menu/index.d.ts +27 -2
- package/dist/components/search-menu/react.d.ts +1 -1
- package/dist/components/search-menu/react.js +59 -280
- package/dist/components/search-menu/schema.d.ts +1 -0
- package/dist/components/select-with-custom-input/html.d.ts +2 -2
- package/dist/components/select-with-custom-input/html.js +13 -48
- package/dist/components/select-with-custom-input/react.js +22 -146
- package/dist/components/sidebar-layout/html.d.ts +16 -6
- package/dist/components/sidebar-layout/html.js +83 -69
- package/dist/components/sidebar-layout/index.d.ts +16 -0
- package/dist/components/sidebar-layout/react.js +105 -698
- package/dist/components/stats-card/react.js +13 -58
- package/dist/components/support/html.js +14 -69
- package/dist/components/support/react.js +74 -320
- package/dist/components/theme-switcher/html.js +11 -55
- package/dist/components/theme-switcher/react.js +28 -152
- package/dist/components/time-input/html.d.ts +2 -2
- package/dist/components/time-input/html.js +8 -53
- package/dist/components/time-input/react.js +34 -188
- package/dist/components/timezone-input/html.js +11 -67
- package/dist/components/timezone-input/react.js +41 -143
- package/dist/components/toast/html.d.ts +6 -6
- package/dist/components/toast/html.js +13 -46
- package/dist/components/tracking-notice/react.js +39 -188
- package/dist/components/unsaved-changes-guard/html.js +9 -43
- package/dist/components/unsaved-changes-guard/react.js +19 -169
- package/dist/components/upload-attachment/html.d.ts +4 -4
- package/dist/components/upload-attachment/html.js +4 -35
- package/dist/components/upload-attachment/react.js +25 -164
- package/dist/components/virtualized-combobox/html.js +10 -35
- package/dist/components/virtualized-combobox/react.js +28 -129
- package/dist/components/webhook-delivery-table/html.js +211 -184
- package/dist/components/webhook-delivery-table/react.js +585 -1362
- package/dist/lib/docs.integrations.server.js +150 -202
- package/dist/lib/docs.js +305 -1085
- package/dist/lib/docs.server.js +134 -186
- package/dist/lib/documentation-toolkit.js +144 -196
- package/dist/services/agent/client/index.js +226 -1072
- package/dist/services/notification/client/index.js +73 -343
- package/dist/services/notification/public.js +73 -343
- package/package.json +5 -13
- package/dist/components/effectcn/alert-dialog.d.ts +0 -13
- package/dist/components/effectcn/button.d.ts +0 -31
- package/dist/components/effectcn/calendar.d.ts +0 -12
- package/dist/components/effectcn/checkbox.d.ts +0 -10
- package/dist/components/effectcn/combobox.d.ts +0 -25
- package/dist/components/effectcn/dialog.d.ts +0 -19
- package/dist/components/effectcn/field.d.ts +0 -11
- package/dist/components/effectcn/file-drop.d.ts +0 -8
- package/dist/components/effectcn/input.d.ts +0 -26
- package/dist/components/effectcn/menu.d.ts +0 -85
- package/dist/components/effectcn/menubar.d.ts +0 -8
- package/dist/components/effectcn/popover.d.ts +0 -18
- package/dist/components/effectcn/scroll-area.d.ts +0 -12
- package/dist/components/effectcn/select.d.ts +0 -68
- package/dist/components/effectcn/toast.d.ts +0 -29
- package/dist/components/ui/alert-dialog.d.ts +0 -18
- package/dist/components/ui/alert.d.ts +0 -10
- package/dist/components/ui/attachment.d.ts +0 -23
- package/dist/components/ui/badge.d.ts +0 -7
- package/dist/components/ui/bubble.d.ts +0 -16
- package/dist/components/ui/button.d.ts +0 -8
- package/dist/components/ui/calendar.d.ts +0 -10
- package/dist/components/ui/card.d.ts +0 -11
- package/dist/components/ui/checkbox.d.ts +0 -3
- package/dist/components/ui/collapsible.d.ts +0 -5
- package/dist/components/ui/command.d.ts +0 -18
- package/dist/components/ui/dialog.d.ts +0 -17
- package/dist/components/ui/dropdown-menu.d.ts +0 -29
- package/dist/components/ui/empty.d.ts +0 -11
- package/dist/components/ui/field.d.ts +0 -24
- package/dist/components/ui/input-group.d.ts +0 -17
- package/dist/components/ui/input.d.ts +0 -3
- package/dist/components/ui/item.d.ts +0 -22
- package/dist/components/ui/label.d.ts +0 -3
- package/dist/components/ui/menubar.d.ts +0 -29
- package/dist/components/ui/message-scroller.d.ts +0 -10
- package/dist/components/ui/message.d.ts +0 -10
- package/dist/components/ui/popover.d.ts +0 -9
- package/dist/components/ui/scroll-area.d.ts +0 -4
- package/dist/components/ui/select.d.ts +0 -15
- package/dist/components/ui/select.js +0 -159
- package/dist/components/ui/separator.d.ts +0 -3
- package/dist/components/ui/sheet.d.ts +0 -14
- package/dist/components/ui/sidebar.d.ts +0 -63
- package/dist/components/ui/skeleton.d.ts +0 -2
- package/dist/components/ui/table.d.ts +0 -10
- package/dist/components/ui/tabs.d.ts +0 -10
- package/dist/components/ui/textarea.d.ts +0 -3
- package/dist/components/ui/tooltip.d.ts +0 -6
- package/dist/components/ui/trace.d.ts +0 -18
- package/dist/lib/effectcn-form.d.ts +0 -3
- package/dist/lib/effectcn-form.js +0 -54
|
@@ -2,632 +2,31 @@
|
|
|
2
2
|
import { Link, Outlet } from "@tanstack/react-router";
|
|
3
3
|
import { Component as Component2, View } from "effect/ui";
|
|
4
4
|
import { useModel } from "@krak-stack/registry/effect-ui-adapter/react";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
import { Badge } from "@/components/ui/badge";
|
|
6
|
+
import {
|
|
7
|
+
Sidebar,
|
|
8
|
+
SidebarContent,
|
|
9
|
+
SidebarFooter,
|
|
10
|
+
SidebarGroup,
|
|
11
|
+
SidebarGroupContent,
|
|
12
|
+
SidebarGroupLabel,
|
|
13
|
+
SidebarHeader,
|
|
14
|
+
SidebarMenu,
|
|
15
|
+
SidebarMenuButton,
|
|
16
|
+
SidebarMenuItem,
|
|
17
|
+
SidebarMenuSub,
|
|
18
|
+
SidebarMenuSubButton,
|
|
19
|
+
SidebarMenuSubItem,
|
|
20
|
+
SidebarRail,
|
|
21
|
+
SidebarInset,
|
|
22
|
+
SidebarProvider,
|
|
23
|
+
SidebarTrigger,
|
|
24
|
+
useSidebar
|
|
25
|
+
} from "@/components/ui/sidebar";
|
|
10
26
|
|
|
11
27
|
// ../../src/lib/utils.ts
|
|
12
28
|
import { cn } from "cn";
|
|
13
29
|
|
|
14
|
-
// ../../src/components/ui/badge.tsx
|
|
15
|
-
var badgeVariants = cva("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!", {
|
|
16
|
-
variants: {
|
|
17
|
-
variant: {
|
|
18
|
-
default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
|
|
19
|
-
secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
|
|
20
|
-
destructive: "bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",
|
|
21
|
-
outline: "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
|
|
22
|
-
ghost: "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
|
|
23
|
-
link: "text-primary underline-offset-4 hover:underline"
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
defaultVariants: {
|
|
27
|
-
variant: "default"
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
function Badge({
|
|
31
|
-
className,
|
|
32
|
-
variant = "default",
|
|
33
|
-
render,
|
|
34
|
-
...props
|
|
35
|
-
}) {
|
|
36
|
-
return useRender({
|
|
37
|
-
defaultTagName: "span",
|
|
38
|
-
props: mergeProps({
|
|
39
|
-
className: cn(badgeVariants({ variant }), className)
|
|
40
|
-
}, props),
|
|
41
|
-
render,
|
|
42
|
-
state: {
|
|
43
|
-
slot: "badge",
|
|
44
|
-
variant
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// ../../src/components/ui/sidebar.tsx
|
|
50
|
-
import * as React2 from "react";
|
|
51
|
-
import { mergeProps as mergeProps2 } from "@base-ui/react/merge-props";
|
|
52
|
-
import { useRender as useRender2 } from "@base-ui/react/use-render";
|
|
53
|
-
import { cva as cva3 } from "class-variance-authority";
|
|
54
|
-
|
|
55
|
-
// ../../src/hooks/use-mobile.ts
|
|
56
|
-
import * as React from "react";
|
|
57
|
-
var MOBILE_BREAKPOINT = 768;
|
|
58
|
-
var subscribe = (onChange) => {
|
|
59
|
-
const query = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);
|
|
60
|
-
query.addEventListener("change", onChange);
|
|
61
|
-
return () => query.removeEventListener("change", onChange);
|
|
62
|
-
};
|
|
63
|
-
var getSnapshot = () => window.innerWidth < MOBILE_BREAKPOINT;
|
|
64
|
-
var getServerSnapshot = () => false;
|
|
65
|
-
function useIsMobile() {
|
|
66
|
-
return React.useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
// ../../src/components/ui/button.tsx
|
|
70
|
-
import { Button as ButtonPrimitive } from "@base-ui/react/button";
|
|
71
|
-
import { cva as cva2 } from "class-variance-authority";
|
|
72
|
-
import { jsx } from "react/jsx-runtime";
|
|
73
|
-
var buttonVariants = cva2("group/button inline-flex shrink-0 items-center justify-center rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
74
|
-
variants: {
|
|
75
|
-
variant: {
|
|
76
|
-
default: "bg-primary text-primary-foreground hover:bg-primary/80",
|
|
77
|
-
outline: "border-border bg-background shadow-xs hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
|
|
78
|
-
secondary: "bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",
|
|
79
|
-
ghost: "hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",
|
|
80
|
-
destructive: "bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",
|
|
81
|
-
link: "text-primary underline-offset-4 hover:underline"
|
|
82
|
-
},
|
|
83
|
-
size: {
|
|
84
|
-
default: "h-9 gap-1.5 px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
85
|
-
xs: "h-6 gap-1 rounded-[min(var(--radius-md),8px)] px-2 text-xs in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
|
|
86
|
-
sm: "h-8 gap-1 rounded-[min(var(--radius-md),10px)] px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5",
|
|
87
|
-
lg: "h-10 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
88
|
-
icon: "size-9",
|
|
89
|
-
"icon-xs": "size-6 rounded-[min(var(--radius-md),8px)] in-data-[slot=button-group]:rounded-md [&_svg:not([class*='size-'])]:size-3",
|
|
90
|
-
"icon-sm": "size-8 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-md",
|
|
91
|
-
"icon-lg": "size-10"
|
|
92
|
-
}
|
|
93
|
-
},
|
|
94
|
-
defaultVariants: {
|
|
95
|
-
variant: "default",
|
|
96
|
-
size: "default"
|
|
97
|
-
}
|
|
98
|
-
});
|
|
99
|
-
function Button({
|
|
100
|
-
className,
|
|
101
|
-
variant = "default",
|
|
102
|
-
size = "default",
|
|
103
|
-
...props
|
|
104
|
-
}) {
|
|
105
|
-
return /* @__PURE__ */ jsx(ButtonPrimitive, {
|
|
106
|
-
"data-slot": "button",
|
|
107
|
-
className: cn(buttonVariants({ variant, size, className })),
|
|
108
|
-
...props
|
|
109
|
-
});
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
// ../../src/components/ui/input.tsx
|
|
113
|
-
import { Input as InputPrimitive } from "@base-ui/react/input";
|
|
114
|
-
|
|
115
|
-
// ../../src/components/ui/separator.tsx
|
|
116
|
-
import { Separator as SeparatorPrimitive } from "@base-ui/react/separator";
|
|
117
|
-
|
|
118
|
-
// ../../src/components/ui/sheet.tsx
|
|
119
|
-
import { Dialog as SheetPrimitive } from "@base-ui/react/dialog";
|
|
120
|
-
import { XIcon } from "lucide-react";
|
|
121
|
-
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
122
|
-
"use client";
|
|
123
|
-
function Sheet({ ...props }) {
|
|
124
|
-
return /* @__PURE__ */ jsx2(SheetPrimitive.Root, {
|
|
125
|
-
"data-slot": "sheet",
|
|
126
|
-
...props
|
|
127
|
-
});
|
|
128
|
-
}
|
|
129
|
-
function SheetPortal({ ...props }) {
|
|
130
|
-
return /* @__PURE__ */ jsx2(SheetPrimitive.Portal, {
|
|
131
|
-
"data-slot": "sheet-portal",
|
|
132
|
-
...props
|
|
133
|
-
});
|
|
134
|
-
}
|
|
135
|
-
function SheetOverlay({ className, ...props }) {
|
|
136
|
-
return /* @__PURE__ */ jsx2(SheetPrimitive.Backdrop, {
|
|
137
|
-
"data-slot": "sheet-overlay",
|
|
138
|
-
className: cn("fixed inset-0 z-50 bg-black/10 transition-opacity duration-150 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs", className),
|
|
139
|
-
...props
|
|
140
|
-
});
|
|
141
|
-
}
|
|
142
|
-
function SheetContent({
|
|
143
|
-
className,
|
|
144
|
-
children,
|
|
145
|
-
side = "right",
|
|
146
|
-
showCloseButton = true,
|
|
147
|
-
...props
|
|
148
|
-
}) {
|
|
149
|
-
return /* @__PURE__ */ jsxs(SheetPortal, {
|
|
150
|
-
children: [
|
|
151
|
-
/* @__PURE__ */ jsx2(SheetOverlay, {}),
|
|
152
|
-
/* @__PURE__ */ jsxs(SheetPrimitive.Popup, {
|
|
153
|
-
"data-slot": "sheet-content",
|
|
154
|
-
"data-side": side,
|
|
155
|
-
className: cn("fixed z-50 flex flex-col gap-4 bg-popover bg-clip-padding text-sm text-popover-foreground shadow-lg transition duration-200 ease-in-out data-ending-style:opacity-0 data-starting-style:opacity-0 data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=bottom]:data-ending-style:translate-y-[2.5rem] data-[side=bottom]:data-starting-style:translate-y-[2.5rem] data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=left]:data-ending-style:translate-x-[-2.5rem] data-[side=left]:data-starting-style:translate-x-[-2.5rem] data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=right]:data-ending-style:translate-x-[2.5rem] data-[side=right]:data-starting-style:translate-x-[2.5rem] data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=top]:data-ending-style:translate-y-[-2.5rem] data-[side=top]:data-starting-style:translate-y-[-2.5rem] data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm", className),
|
|
156
|
-
...props,
|
|
157
|
-
children: [
|
|
158
|
-
children,
|
|
159
|
-
showCloseButton && /* @__PURE__ */ jsxs(SheetPrimitive.Close, {
|
|
160
|
-
"data-slot": "sheet-close",
|
|
161
|
-
render: /* @__PURE__ */ jsx2(Button, {
|
|
162
|
-
variant: "ghost",
|
|
163
|
-
className: "absolute top-4 right-4",
|
|
164
|
-
size: "icon-sm"
|
|
165
|
-
}),
|
|
166
|
-
children: [
|
|
167
|
-
/* @__PURE__ */ jsx2(XIcon, {}),
|
|
168
|
-
/* @__PURE__ */ jsx2("span", {
|
|
169
|
-
className: "sr-only",
|
|
170
|
-
children: "Close"
|
|
171
|
-
})
|
|
172
|
-
]
|
|
173
|
-
})
|
|
174
|
-
]
|
|
175
|
-
})
|
|
176
|
-
]
|
|
177
|
-
});
|
|
178
|
-
}
|
|
179
|
-
function SheetHeader({ className, ...props }) {
|
|
180
|
-
return /* @__PURE__ */ jsx2("div", {
|
|
181
|
-
"data-slot": "sheet-header",
|
|
182
|
-
className: cn("flex flex-col gap-1.5 p-4", className),
|
|
183
|
-
...props
|
|
184
|
-
});
|
|
185
|
-
}
|
|
186
|
-
function SheetTitle({ className, ...props }) {
|
|
187
|
-
return /* @__PURE__ */ jsx2(SheetPrimitive.Title, {
|
|
188
|
-
"data-slot": "sheet-title",
|
|
189
|
-
className: cn("font-medium text-foreground", className),
|
|
190
|
-
...props
|
|
191
|
-
});
|
|
192
|
-
}
|
|
193
|
-
function SheetDescription({
|
|
194
|
-
className,
|
|
195
|
-
...props
|
|
196
|
-
}) {
|
|
197
|
-
return /* @__PURE__ */ jsx2(SheetPrimitive.Description, {
|
|
198
|
-
"data-slot": "sheet-description",
|
|
199
|
-
className: cn("text-sm text-muted-foreground", className),
|
|
200
|
-
...props
|
|
201
|
-
});
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
// ../../src/components/ui/tooltip.tsx
|
|
205
|
-
import { Tooltip as TooltipPrimitive } from "@base-ui/react/tooltip";
|
|
206
|
-
import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
207
|
-
"use client";
|
|
208
|
-
function Tooltip({ ...props }) {
|
|
209
|
-
return /* @__PURE__ */ jsx3(TooltipPrimitive.Root, {
|
|
210
|
-
"data-slot": "tooltip",
|
|
211
|
-
...props
|
|
212
|
-
});
|
|
213
|
-
}
|
|
214
|
-
function TooltipTrigger({ ...props }) {
|
|
215
|
-
return /* @__PURE__ */ jsx3(TooltipPrimitive.Trigger, {
|
|
216
|
-
"data-slot": "tooltip-trigger",
|
|
217
|
-
...props
|
|
218
|
-
});
|
|
219
|
-
}
|
|
220
|
-
function TooltipContent({
|
|
221
|
-
className,
|
|
222
|
-
side = "top",
|
|
223
|
-
sideOffset = 4,
|
|
224
|
-
align = "center",
|
|
225
|
-
alignOffset = 0,
|
|
226
|
-
children,
|
|
227
|
-
...props
|
|
228
|
-
}) {
|
|
229
|
-
return /* @__PURE__ */ jsx3(TooltipPrimitive.Portal, {
|
|
230
|
-
children: /* @__PURE__ */ jsx3(TooltipPrimitive.Positioner, {
|
|
231
|
-
align,
|
|
232
|
-
alignOffset,
|
|
233
|
-
side,
|
|
234
|
-
sideOffset,
|
|
235
|
-
className: "isolate z-50",
|
|
236
|
-
children: /* @__PURE__ */ jsxs2(TooltipPrimitive.Popup, {
|
|
237
|
-
"data-slot": "tooltip-content",
|
|
238
|
-
className: cn("z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className),
|
|
239
|
-
...props,
|
|
240
|
-
children: [
|
|
241
|
-
children,
|
|
242
|
-
/* @__PURE__ */ jsx3(TooltipPrimitive.Arrow, {
|
|
243
|
-
className: "bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] data-[side=bottom]:top-1 data-[side=inline-end]:top-1/2! data-[side=inline-end]:-left-1 data-[side=inline-end]:-translate-y-1/2 data-[side=inline-start]:top-1/2! data-[side=inline-start]:-right-1 data-[side=inline-start]:-translate-y-1/2 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5"
|
|
244
|
-
})
|
|
245
|
-
]
|
|
246
|
-
})
|
|
247
|
-
})
|
|
248
|
-
});
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
// ../../src/components/ui/sidebar.tsx
|
|
252
|
-
import { PanelLeftIcon } from "lucide-react";
|
|
253
|
-
import { Schema } from "effect";
|
|
254
|
-
import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
255
|
-
var SIDEBAR_COOKIE_NAME = "sidebar_state";
|
|
256
|
-
var SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
|
|
257
|
-
var SIDEBAR_WIDTH = "16rem";
|
|
258
|
-
var SIDEBAR_WIDTH_MOBILE = "18rem";
|
|
259
|
-
var SIDEBAR_WIDTH_ICON = "3rem";
|
|
260
|
-
var SIDEBAR_KEYBOARD_SHORTCUT = "b";
|
|
261
|
-
var SidebarContext = React2.createContext(null);
|
|
262
|
-
function useSidebar() {
|
|
263
|
-
const context = React2.useContext(SidebarContext);
|
|
264
|
-
if (!context) {
|
|
265
|
-
throw new Error("useSidebar must be used within a SidebarProvider.");
|
|
266
|
-
}
|
|
267
|
-
return context;
|
|
268
|
-
}
|
|
269
|
-
function SidebarProvider({
|
|
270
|
-
defaultOpen = true,
|
|
271
|
-
open: openProp,
|
|
272
|
-
onOpenChange: setOpenProp,
|
|
273
|
-
className,
|
|
274
|
-
style,
|
|
275
|
-
children,
|
|
276
|
-
...props
|
|
277
|
-
}) {
|
|
278
|
-
const isMobile = useIsMobile();
|
|
279
|
-
const [openMobile, setOpenMobile] = React2.useState(false);
|
|
280
|
-
const [_open, _setOpen] = React2.useState(defaultOpen);
|
|
281
|
-
const open = openProp ?? _open;
|
|
282
|
-
const setOpen = React2.useCallback((openState) => {
|
|
283
|
-
if (setOpenProp) {
|
|
284
|
-
setOpenProp(openState);
|
|
285
|
-
} else {
|
|
286
|
-
_setOpen(openState);
|
|
287
|
-
}
|
|
288
|
-
document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;
|
|
289
|
-
}, [setOpenProp]);
|
|
290
|
-
const toggleSidebar = React2.useCallback(() => {
|
|
291
|
-
return isMobile ? setOpenMobile((open) => !open) : setOpen(!open);
|
|
292
|
-
}, [isMobile, open, setOpen, setOpenMobile]);
|
|
293
|
-
React2.useEffect(() => {
|
|
294
|
-
const handleKeyDown = (event) => {
|
|
295
|
-
if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
|
|
296
|
-
event.preventDefault();
|
|
297
|
-
toggleSidebar();
|
|
298
|
-
}
|
|
299
|
-
};
|
|
300
|
-
window.addEventListener("keydown", handleKeyDown);
|
|
301
|
-
return () => window.removeEventListener("keydown", handleKeyDown);
|
|
302
|
-
}, [toggleSidebar]);
|
|
303
|
-
const state = open ? "expanded" : "collapsed";
|
|
304
|
-
const contextValue = React2.useMemo(() => ({
|
|
305
|
-
state,
|
|
306
|
-
open,
|
|
307
|
-
setOpen,
|
|
308
|
-
isMobile,
|
|
309
|
-
openMobile,
|
|
310
|
-
setOpenMobile,
|
|
311
|
-
toggleSidebar
|
|
312
|
-
}), [state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]);
|
|
313
|
-
const wrapperStyle = {
|
|
314
|
-
"--sidebar-width": SIDEBAR_WIDTH,
|
|
315
|
-
"--sidebar-width-icon": SIDEBAR_WIDTH_ICON,
|
|
316
|
-
...style
|
|
317
|
-
};
|
|
318
|
-
return /* @__PURE__ */ jsx4(SidebarContext.Provider, {
|
|
319
|
-
value: contextValue,
|
|
320
|
-
children: /* @__PURE__ */ jsx4("div", {
|
|
321
|
-
"data-slot": "sidebar-wrapper",
|
|
322
|
-
style: wrapperStyle,
|
|
323
|
-
className: cn("group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar", className),
|
|
324
|
-
...props,
|
|
325
|
-
children
|
|
326
|
-
})
|
|
327
|
-
});
|
|
328
|
-
}
|
|
329
|
-
function Sidebar({
|
|
330
|
-
side = "left",
|
|
331
|
-
variant = "sidebar",
|
|
332
|
-
collapsible = "offcanvas",
|
|
333
|
-
className,
|
|
334
|
-
children,
|
|
335
|
-
dir,
|
|
336
|
-
...props
|
|
337
|
-
}) {
|
|
338
|
-
const { isMobile, state, openMobile, setOpenMobile } = useSidebar();
|
|
339
|
-
if (collapsible === "none") {
|
|
340
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
341
|
-
"data-slot": "sidebar",
|
|
342
|
-
className: cn("flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground", className),
|
|
343
|
-
...props,
|
|
344
|
-
children
|
|
345
|
-
});
|
|
346
|
-
}
|
|
347
|
-
if (isMobile) {
|
|
348
|
-
const mobileStyle = {
|
|
349
|
-
"--sidebar-width": SIDEBAR_WIDTH_MOBILE
|
|
350
|
-
};
|
|
351
|
-
return /* @__PURE__ */ jsx4(Sheet, {
|
|
352
|
-
open: openMobile,
|
|
353
|
-
onOpenChange: setOpenMobile,
|
|
354
|
-
...props,
|
|
355
|
-
children: /* @__PURE__ */ jsxs3(SheetContent, {
|
|
356
|
-
dir,
|
|
357
|
-
"data-sidebar": "sidebar",
|
|
358
|
-
"data-slot": "sidebar",
|
|
359
|
-
"data-mobile": "true",
|
|
360
|
-
className: "bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",
|
|
361
|
-
style: mobileStyle,
|
|
362
|
-
side,
|
|
363
|
-
children: [
|
|
364
|
-
/* @__PURE__ */ jsxs3(SheetHeader, {
|
|
365
|
-
className: "sr-only",
|
|
366
|
-
children: [
|
|
367
|
-
/* @__PURE__ */ jsx4(SheetTitle, {
|
|
368
|
-
children: "Sidebar"
|
|
369
|
-
}),
|
|
370
|
-
/* @__PURE__ */ jsx4(SheetDescription, {
|
|
371
|
-
children: "Displays the mobile sidebar."
|
|
372
|
-
})
|
|
373
|
-
]
|
|
374
|
-
}),
|
|
375
|
-
/* @__PURE__ */ jsx4("div", {
|
|
376
|
-
className: "flex h-full w-full flex-col",
|
|
377
|
-
children
|
|
378
|
-
})
|
|
379
|
-
]
|
|
380
|
-
})
|
|
381
|
-
});
|
|
382
|
-
}
|
|
383
|
-
return /* @__PURE__ */ jsxs3("div", {
|
|
384
|
-
className: "group peer text-sidebar-foreground hidden md:block",
|
|
385
|
-
"data-state": state,
|
|
386
|
-
"data-collapsible": state === "collapsed" ? collapsible : "",
|
|
387
|
-
"data-variant": variant,
|
|
388
|
-
"data-side": side,
|
|
389
|
-
"data-slot": "sidebar",
|
|
390
|
-
children: [
|
|
391
|
-
/* @__PURE__ */ jsx4("div", {
|
|
392
|
-
"data-slot": "sidebar-gap",
|
|
393
|
-
className: cn("relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear", "group-data-[collapsible=offcanvas]:w-0", "group-data-[side=right]:rotate-180", variant === "floating" || variant === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon)")
|
|
394
|
-
}),
|
|
395
|
-
/* @__PURE__ */ jsx4("div", {
|
|
396
|
-
"data-slot": "sidebar-container",
|
|
397
|
-
"data-side": side,
|
|
398
|
-
className: cn("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear data-[side=left]:left-0 data-[side=left]:group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)] data-[side=right]:right-0 data-[side=right]:group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)] md:flex", variant === "floating" || variant === "inset" ? "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l", className),
|
|
399
|
-
...props,
|
|
400
|
-
children: /* @__PURE__ */ jsx4("div", {
|
|
401
|
-
"data-sidebar": "sidebar",
|
|
402
|
-
"data-slot": "sidebar-inner",
|
|
403
|
-
className: "bg-sidebar group-data-[variant=floating]:ring-sidebar-border flex size-full flex-col group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1",
|
|
404
|
-
children
|
|
405
|
-
})
|
|
406
|
-
})
|
|
407
|
-
]
|
|
408
|
-
});
|
|
409
|
-
}
|
|
410
|
-
function SidebarTrigger({
|
|
411
|
-
className,
|
|
412
|
-
onClick,
|
|
413
|
-
...props
|
|
414
|
-
}) {
|
|
415
|
-
const { toggleSidebar } = useSidebar();
|
|
416
|
-
return /* @__PURE__ */ jsxs3(Button, {
|
|
417
|
-
"data-sidebar": "trigger",
|
|
418
|
-
"data-slot": "sidebar-trigger",
|
|
419
|
-
variant: "ghost",
|
|
420
|
-
size: "icon-sm",
|
|
421
|
-
className: cn(className),
|
|
422
|
-
onClick: (event) => {
|
|
423
|
-
onClick?.(event);
|
|
424
|
-
toggleSidebar();
|
|
425
|
-
},
|
|
426
|
-
...props,
|
|
427
|
-
children: [
|
|
428
|
-
/* @__PURE__ */ jsx4(PanelLeftIcon, {}),
|
|
429
|
-
/* @__PURE__ */ jsx4("span", {
|
|
430
|
-
className: "sr-only",
|
|
431
|
-
children: "Toggle Sidebar"
|
|
432
|
-
})
|
|
433
|
-
]
|
|
434
|
-
});
|
|
435
|
-
}
|
|
436
|
-
function SidebarRail({ className, ...props }) {
|
|
437
|
-
const { toggleSidebar } = useSidebar();
|
|
438
|
-
return /* @__PURE__ */ jsx4("button", {
|
|
439
|
-
"data-sidebar": "rail",
|
|
440
|
-
"data-slot": "sidebar-rail",
|
|
441
|
-
"aria-label": "Toggle Sidebar",
|
|
442
|
-
tabIndex: -1,
|
|
443
|
-
onClick: toggleSidebar,
|
|
444
|
-
title: "Toggle Sidebar",
|
|
445
|
-
className: cn("absolute inset-y-0 z-20 hidden w-4 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:start-1/2 after:w-[2px] hover:after:bg-sidebar-border sm:flex ltr:-translate-x-1/2 rtl:-translate-x-1/2", "in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize", "[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize", "group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full hover:group-data-[collapsible=offcanvas]:bg-sidebar", "[[data-side=left][data-collapsible=offcanvas]_&]:-right-2", "[[data-side=right][data-collapsible=offcanvas]_&]:-left-2", className),
|
|
446
|
-
...props
|
|
447
|
-
});
|
|
448
|
-
}
|
|
449
|
-
function SidebarInset({ className, ...props }) {
|
|
450
|
-
return /* @__PURE__ */ jsx4("main", {
|
|
451
|
-
"data-slot": "sidebar-inset",
|
|
452
|
-
className: cn("relative flex w-full flex-1 flex-col bg-background md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2", className),
|
|
453
|
-
...props
|
|
454
|
-
});
|
|
455
|
-
}
|
|
456
|
-
function SidebarHeader({ className, ...props }) {
|
|
457
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
458
|
-
"data-slot": "sidebar-header",
|
|
459
|
-
"data-sidebar": "header",
|
|
460
|
-
className: cn("flex flex-col gap-2 p-2", className),
|
|
461
|
-
...props
|
|
462
|
-
});
|
|
463
|
-
}
|
|
464
|
-
function SidebarFooter({ className, ...props }) {
|
|
465
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
466
|
-
"data-slot": "sidebar-footer",
|
|
467
|
-
"data-sidebar": "footer",
|
|
468
|
-
className: cn("flex flex-col gap-2 p-2", className),
|
|
469
|
-
...props
|
|
470
|
-
});
|
|
471
|
-
}
|
|
472
|
-
function SidebarContent({ className, ...props }) {
|
|
473
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
474
|
-
"data-slot": "sidebar-content",
|
|
475
|
-
"data-sidebar": "content",
|
|
476
|
-
className: cn("no-scrollbar flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden", className),
|
|
477
|
-
...props
|
|
478
|
-
});
|
|
479
|
-
}
|
|
480
|
-
function SidebarGroup({ className, ...props }) {
|
|
481
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
482
|
-
"data-slot": "sidebar-group",
|
|
483
|
-
"data-sidebar": "group",
|
|
484
|
-
className: cn("relative flex w-full min-w-0 flex-col p-2", className),
|
|
485
|
-
...props
|
|
486
|
-
});
|
|
487
|
-
}
|
|
488
|
-
function SidebarGroupLabel({
|
|
489
|
-
className,
|
|
490
|
-
render,
|
|
491
|
-
...props
|
|
492
|
-
}) {
|
|
493
|
-
return useRender2({
|
|
494
|
-
defaultTagName: "div",
|
|
495
|
-
props: mergeProps2({
|
|
496
|
-
className: cn("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 ring-sidebar-ring outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0", className)
|
|
497
|
-
}, props),
|
|
498
|
-
render,
|
|
499
|
-
state: {
|
|
500
|
-
slot: "sidebar-group-label",
|
|
501
|
-
sidebar: "group-label"
|
|
502
|
-
}
|
|
503
|
-
});
|
|
504
|
-
}
|
|
505
|
-
function SidebarGroupContent({
|
|
506
|
-
className,
|
|
507
|
-
...props
|
|
508
|
-
}) {
|
|
509
|
-
return /* @__PURE__ */ jsx4("div", {
|
|
510
|
-
"data-slot": "sidebar-group-content",
|
|
511
|
-
"data-sidebar": "group-content",
|
|
512
|
-
className: cn("w-full text-sm", className),
|
|
513
|
-
...props
|
|
514
|
-
});
|
|
515
|
-
}
|
|
516
|
-
function SidebarMenu({ className, ...props }) {
|
|
517
|
-
return /* @__PURE__ */ jsx4("ul", {
|
|
518
|
-
"data-slot": "sidebar-menu",
|
|
519
|
-
"data-sidebar": "menu",
|
|
520
|
-
className: cn("flex w-full min-w-0 flex-col gap-1", className),
|
|
521
|
-
...props
|
|
522
|
-
});
|
|
523
|
-
}
|
|
524
|
-
function SidebarMenuItem({ className, ...props }) {
|
|
525
|
-
return /* @__PURE__ */ jsx4("li", {
|
|
526
|
-
"data-slot": "sidebar-menu-item",
|
|
527
|
-
"data-sidebar": "menu-item",
|
|
528
|
-
className: cn("group/menu-item relative", className),
|
|
529
|
-
...props
|
|
530
|
-
});
|
|
531
|
-
}
|
|
532
|
-
var sidebarMenuButtonVariants = cva3("peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm ring-sidebar-ring outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate", {
|
|
533
|
-
variants: {
|
|
534
|
-
variant: {
|
|
535
|
-
default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
|
|
536
|
-
outline: "bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"
|
|
537
|
-
},
|
|
538
|
-
size: {
|
|
539
|
-
default: "h-8 text-sm",
|
|
540
|
-
sm: "h-7 text-xs",
|
|
541
|
-
lg: "h-12 text-sm group-data-[collapsible=icon]:p-0!"
|
|
542
|
-
}
|
|
543
|
-
},
|
|
544
|
-
defaultVariants: {
|
|
545
|
-
variant: "default",
|
|
546
|
-
size: "default"
|
|
547
|
-
}
|
|
548
|
-
});
|
|
549
|
-
function SidebarMenuButton({
|
|
550
|
-
render,
|
|
551
|
-
isActive = false,
|
|
552
|
-
variant = "default",
|
|
553
|
-
size = "default",
|
|
554
|
-
tooltip,
|
|
555
|
-
className,
|
|
556
|
-
...props
|
|
557
|
-
}) {
|
|
558
|
-
const { isMobile, state } = useSidebar();
|
|
559
|
-
const comp = useRender2({
|
|
560
|
-
defaultTagName: "button",
|
|
561
|
-
props: mergeProps2({
|
|
562
|
-
className: cn(sidebarMenuButtonVariants({ variant, size }), className)
|
|
563
|
-
}, props),
|
|
564
|
-
render: !tooltip ? render : /* @__PURE__ */ jsx4(TooltipTrigger, {
|
|
565
|
-
render
|
|
566
|
-
}),
|
|
567
|
-
state: {
|
|
568
|
-
slot: "sidebar-menu-button",
|
|
569
|
-
sidebar: "menu-button",
|
|
570
|
-
size,
|
|
571
|
-
active: isActive
|
|
572
|
-
}
|
|
573
|
-
});
|
|
574
|
-
if (!tooltip) {
|
|
575
|
-
return comp;
|
|
576
|
-
}
|
|
577
|
-
const tooltipProps = Schema.is(Schema.String)(tooltip) ? { children: tooltip } : tooltip;
|
|
578
|
-
return /* @__PURE__ */ jsxs3(Tooltip, {
|
|
579
|
-
children: [
|
|
580
|
-
comp,
|
|
581
|
-
/* @__PURE__ */ jsx4(TooltipContent, {
|
|
582
|
-
side: "right",
|
|
583
|
-
align: "center",
|
|
584
|
-
hidden: state !== "collapsed" || isMobile,
|
|
585
|
-
...tooltipProps
|
|
586
|
-
})
|
|
587
|
-
]
|
|
588
|
-
});
|
|
589
|
-
}
|
|
590
|
-
function SidebarMenuSub({ className, ...props }) {
|
|
591
|
-
return /* @__PURE__ */ jsx4("ul", {
|
|
592
|
-
"data-slot": "sidebar-menu-sub",
|
|
593
|
-
"data-sidebar": "menu-sub",
|
|
594
|
-
className: cn("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5 group-data-[collapsible=icon]:hidden", className),
|
|
595
|
-
...props
|
|
596
|
-
});
|
|
597
|
-
}
|
|
598
|
-
function SidebarMenuSubItem({
|
|
599
|
-
className,
|
|
600
|
-
...props
|
|
601
|
-
}) {
|
|
602
|
-
return /* @__PURE__ */ jsx4("li", {
|
|
603
|
-
"data-slot": "sidebar-menu-sub-item",
|
|
604
|
-
"data-sidebar": "menu-sub-item",
|
|
605
|
-
className: cn("group/menu-sub-item relative", className),
|
|
606
|
-
...props
|
|
607
|
-
});
|
|
608
|
-
}
|
|
609
|
-
function SidebarMenuSubButton({
|
|
610
|
-
render,
|
|
611
|
-
size = "md",
|
|
612
|
-
isActive = false,
|
|
613
|
-
className,
|
|
614
|
-
...props
|
|
615
|
-
}) {
|
|
616
|
-
return useRender2({
|
|
617
|
-
defaultTagName: "a",
|
|
618
|
-
props: mergeProps2({
|
|
619
|
-
className: cn("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground ring-sidebar-ring outline-hidden group-data-[collapsible=icon]:hidden hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[size=md]:text-sm data-[size=sm]:text-xs data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground", className)
|
|
620
|
-
}, props),
|
|
621
|
-
render,
|
|
622
|
-
state: {
|
|
623
|
-
slot: "sidebar-menu-sub-button",
|
|
624
|
-
sidebar: "menu-sub-button",
|
|
625
|
-
size,
|
|
626
|
-
active: isActive
|
|
627
|
-
}
|
|
628
|
-
});
|
|
629
|
-
}
|
|
630
|
-
|
|
631
30
|
// ../../src/components/sidebar-layout/classes.ts
|
|
632
31
|
var sidebarLayoutClasses = {
|
|
633
32
|
header: "flex flex-col gap-4 sm:flex-row sm:items-start sm:justify-between",
|
|
@@ -645,83 +44,91 @@ var resolveSidebarLayoutClasses = (overrides) => ({
|
|
|
645
44
|
});
|
|
646
45
|
|
|
647
46
|
// ../../src/components/sidebar-layout/index.ts
|
|
648
|
-
import { Option, Schema as
|
|
47
|
+
import { Option, Schema as Schema2 } from "effect";
|
|
649
48
|
import { Cookies } from "effect/http";
|
|
650
49
|
import { Component, UiSchema } from "effect/ui";
|
|
651
50
|
|
|
652
51
|
// ../../src/components/sidebar-layout/schema.ts
|
|
653
|
-
import { Schema
|
|
654
|
-
var SidebarCollapsibleSchema =
|
|
52
|
+
import { Schema, Struct } from "effect";
|
|
53
|
+
var SidebarCollapsibleSchema = Schema.Literals([
|
|
655
54
|
"icon",
|
|
656
55
|
"offcanvas",
|
|
657
56
|
"none"
|
|
658
57
|
]);
|
|
659
|
-
var NavItemSchema =
|
|
660
|
-
label:
|
|
661
|
-
href:
|
|
662
|
-
exact:
|
|
663
|
-
badge:
|
|
664
|
-
external:
|
|
58
|
+
var NavItemSchema = Schema.Struct({
|
|
59
|
+
label: Schema.String,
|
|
60
|
+
href: Schema.String,
|
|
61
|
+
exact: Schema.optional(Schema.Boolean),
|
|
62
|
+
badge: Schema.optional(Schema.String),
|
|
63
|
+
external: Schema.optional(Schema.Boolean)
|
|
665
64
|
}).annotate({ identifier: "SidebarNavItem" });
|
|
666
|
-
var NavGroupSchema =
|
|
667
|
-
label:
|
|
668
|
-
items:
|
|
65
|
+
var NavGroupSchema = Schema.Struct({
|
|
66
|
+
label: Schema.String,
|
|
67
|
+
items: Schema.Array(NavItemSchema)
|
|
669
68
|
}).annotate({ identifier: "SidebarNavGroup" });
|
|
670
69
|
var layoutSlots = ["toolbar", "content", "desktopViewport"];
|
|
671
|
-
var SidebarLayoutClassesOverridesSchema =
|
|
672
|
-
var SidebarPageHeaderClassesOverridesSchema =
|
|
673
|
-
var SidebarLayoutPropsSchema =
|
|
674
|
-
classes:
|
|
675
|
-
groups:
|
|
676
|
-
contentClassName:
|
|
677
|
-
fullPage:
|
|
678
|
-
sidebarCollapsible:
|
|
679
|
-
defaultOpen:
|
|
70
|
+
var SidebarLayoutClassesOverridesSchema = Schema.Record(Schema.Literals(Struct.keys(Struct.pick(sidebarLayoutClasses, layoutSlots))), Schema.optionalKey(Schema.String)).annotate({ identifier: "SidebarLayoutClassesOverrides" });
|
|
71
|
+
var SidebarPageHeaderClassesOverridesSchema = Schema.Record(Schema.Literals(Struct.keys(Struct.omit(sidebarLayoutClasses, layoutSlots))), Schema.optionalKey(Schema.String)).annotate({ identifier: "SidebarPageHeaderClassesOverrides" });
|
|
72
|
+
var SidebarLayoutPropsSchema = Schema.Struct({
|
|
73
|
+
classes: Schema.optional(SidebarLayoutClassesOverridesSchema),
|
|
74
|
+
groups: Schema.Array(NavGroupSchema),
|
|
75
|
+
contentClassName: Schema.optional(Schema.String),
|
|
76
|
+
fullPage: Schema.optional(Schema.Boolean),
|
|
77
|
+
sidebarCollapsible: Schema.optional(SidebarCollapsibleSchema),
|
|
78
|
+
defaultOpen: Schema.optional(Schema.Boolean)
|
|
680
79
|
}).annotate({ identifier: "SidebarLayoutProps" });
|
|
681
|
-
var SidebarPageHeaderPropsSchema =
|
|
682
|
-
classes:
|
|
683
|
-
title:
|
|
684
|
-
description:
|
|
685
|
-
badge:
|
|
686
|
-
label:
|
|
687
|
-
variant:
|
|
80
|
+
var SidebarPageHeaderPropsSchema = Schema.Struct({
|
|
81
|
+
classes: Schema.optional(SidebarPageHeaderClassesOverridesSchema),
|
|
82
|
+
title: Schema.String,
|
|
83
|
+
description: Schema.optional(Schema.String),
|
|
84
|
+
badge: Schema.optional(Schema.Struct({
|
|
85
|
+
label: Schema.String,
|
|
86
|
+
variant: Schema.optional(Schema.Literals(["default", "secondary", "outline", "destructive"]))
|
|
688
87
|
}))
|
|
689
88
|
}).annotate({ identifier: "SidebarPageHeaderProps" });
|
|
690
89
|
|
|
691
90
|
// ../../src/components/sidebar-layout/index.ts
|
|
692
91
|
var cookieName = "sidebar_state";
|
|
693
|
-
var SidebarOpenCookie =
|
|
92
|
+
var SidebarOpenCookie = Schema2.Literals(["true", "false"]).annotate({
|
|
694
93
|
identifier: "SidebarOpenCookie"
|
|
695
94
|
});
|
|
696
|
-
var getSidebarDefaultOpen = (defaultOpen) =>
|
|
95
|
+
var getSidebarDefaultOpen = (defaultOpen) => Schema2.decodeUnknownOption(SidebarOpenCookie)(Cookies.parseHeader(globalThis.document?.cookie ?? "")[cookieName]).pipe(Option.map((value) => value === "true"), Option.getOrElse(() => defaultOpen));
|
|
697
96
|
var SidebarLayoutMessage = UiSchema.TaggedEnum({
|
|
698
|
-
SetOpen: { open:
|
|
699
|
-
SetMobileOpen: { open:
|
|
97
|
+
SetOpen: { open: Schema2.Boolean },
|
|
98
|
+
SetMobileOpen: { open: Schema2.Boolean },
|
|
99
|
+
SetMobileViewport: { mobile: Schema2.Boolean },
|
|
100
|
+
SetItemTooltip: { href: Schema2.String, open: Schema2.Boolean }
|
|
700
101
|
}).annotate({ identifier: "SidebarLayoutMessage" });
|
|
701
102
|
var sidebarLayoutOptions = {
|
|
702
103
|
name: "SidebarLayout",
|
|
703
104
|
props: SidebarLayoutPropsSchema,
|
|
704
|
-
model:
|
|
705
|
-
open:
|
|
706
|
-
mobileOpen:
|
|
105
|
+
model: Schema2.Struct({
|
|
106
|
+
open: Schema2.Boolean,
|
|
107
|
+
mobileOpen: Schema2.Boolean,
|
|
108
|
+
mobile: Schema2.Boolean,
|
|
109
|
+
tooltipHref: Schema2.NullOr(Schema2.String)
|
|
707
110
|
}).annotate({ identifier: "SidebarLayoutModel" }),
|
|
708
111
|
message: SidebarLayoutMessage,
|
|
709
112
|
restore: false
|
|
710
113
|
};
|
|
711
114
|
var update = Component.define(sidebarLayoutOptions).update({
|
|
712
|
-
SetOpen: ($, { open }) => ({ ...$.model, open }),
|
|
713
|
-
SetMobileOpen: ($, { open }) => ({ ...$.model, mobileOpen: open })
|
|
115
|
+
SetOpen: ($, { open }) => ({ ...$.model, open, tooltipHref: null }),
|
|
116
|
+
SetMobileOpen: ($, { open }) => ({ ...$.model, mobileOpen: open }),
|
|
117
|
+
SetMobileViewport: ($, { mobile }) => $.model.mobile === mobile ? $.model : { ...$.model, mobile, mobileOpen: false, tooltipHref: null },
|
|
118
|
+
SetItemTooltip: ($, { href, open }) => open && !$.model.open && !$.model.mobile ? { ...$.model, tooltipHref: href } : $.model.tooltipHref === href ? { ...$.model, tooltipHref: null } : $.model
|
|
714
119
|
});
|
|
715
120
|
var sidebarLayoutBehaviours = {
|
|
716
121
|
init: ({ props }) => ({
|
|
717
122
|
open: getSidebarDefaultOpen(props.defaultOpen ?? true),
|
|
718
|
-
mobileOpen: false
|
|
123
|
+
mobileOpen: false,
|
|
124
|
+
mobile: false,
|
|
125
|
+
tooltipHref: null
|
|
719
126
|
}),
|
|
720
127
|
update
|
|
721
128
|
};
|
|
722
129
|
|
|
723
130
|
// ../../src/components/sidebar-layout/react.tsx
|
|
724
|
-
import { jsx
|
|
131
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
725
132
|
var SidebarModel = Component2.define(sidebarLayoutOptions).make({
|
|
726
133
|
...sidebarLayoutBehaviours,
|
|
727
134
|
view: () => View.text("")
|
|
@@ -736,28 +143,28 @@ function AppSidebar({ collapsible, footer, groups, header }) {
|
|
|
736
143
|
if (isMobile)
|
|
737
144
|
setOpenMobile(false);
|
|
738
145
|
};
|
|
739
|
-
return /* @__PURE__ */
|
|
146
|
+
return /* @__PURE__ */ jsxs(Sidebar, {
|
|
740
147
|
collapsible,
|
|
741
148
|
children: [
|
|
742
|
-
header && /* @__PURE__ */
|
|
149
|
+
header && /* @__PURE__ */ jsx(SidebarHeader, {
|
|
743
150
|
children: header
|
|
744
151
|
}),
|
|
745
|
-
/* @__PURE__ */
|
|
152
|
+
/* @__PURE__ */ jsx(SidebarContent, {
|
|
746
153
|
className: "group-data-[collapsible=icon]:overflow-x-hidden group-data-[collapsible=icon]:overflow-y-auto",
|
|
747
|
-
children: groups.map((group) => /* @__PURE__ */
|
|
154
|
+
children: groups.map((group) => /* @__PURE__ */ jsxs(SidebarGroup, {
|
|
748
155
|
children: [
|
|
749
|
-
/* @__PURE__ */
|
|
156
|
+
/* @__PURE__ */ jsx(SidebarGroupLabel, {
|
|
750
157
|
children: group.label()
|
|
751
158
|
}),
|
|
752
|
-
/* @__PURE__ */
|
|
753
|
-
children: /* @__PURE__ */
|
|
159
|
+
/* @__PURE__ */ jsx(SidebarGroupContent, {
|
|
160
|
+
children: /* @__PURE__ */ jsx(SidebarMenu, {
|
|
754
161
|
"aria-label": group.label(),
|
|
755
162
|
children: group.items.map((item) => {
|
|
756
|
-
const render = item.external ? /* @__PURE__ */
|
|
163
|
+
const render = item.external ? /* @__PURE__ */ jsx("a", {
|
|
757
164
|
href: item.href,
|
|
758
165
|
target: "_blank",
|
|
759
166
|
rel: "noreferrer"
|
|
760
|
-
}) : /* @__PURE__ */
|
|
167
|
+
}) : /* @__PURE__ */ jsx(Link, {
|
|
761
168
|
to: item.href,
|
|
762
169
|
activeOptions: {
|
|
763
170
|
exact: item.exact ?? false,
|
|
@@ -765,31 +172,31 @@ function AppSidebar({ collapsible, footer, groups, header }) {
|
|
|
765
172
|
},
|
|
766
173
|
activeProps: { "data-active": "" }
|
|
767
174
|
});
|
|
768
|
-
return /* @__PURE__ */
|
|
175
|
+
return /* @__PURE__ */ jsxs(SidebarMenuItem, {
|
|
769
176
|
children: [
|
|
770
|
-
/* @__PURE__ */
|
|
177
|
+
/* @__PURE__ */ jsxs(SidebarMenuButton, {
|
|
771
178
|
className: "h-auto min-h-8",
|
|
772
179
|
onClick: closeMobileSidebar,
|
|
773
180
|
render,
|
|
774
181
|
tooltip: item.label(),
|
|
775
182
|
children: [
|
|
776
|
-
item.icon ? /* @__PURE__ */
|
|
777
|
-
/* @__PURE__ */
|
|
183
|
+
item.icon ? /* @__PURE__ */ jsx(item.icon, {}) : null,
|
|
184
|
+
/* @__PURE__ */ jsx("span", {
|
|
778
185
|
children: item.label()
|
|
779
186
|
}),
|
|
780
|
-
item.badge ? /* @__PURE__ */
|
|
187
|
+
item.badge ? /* @__PURE__ */ jsx(Badge, {
|
|
781
188
|
className: "ml-auto",
|
|
782
189
|
variant: "secondary",
|
|
783
190
|
children: item.badge()
|
|
784
191
|
}) : null
|
|
785
192
|
]
|
|
786
193
|
}),
|
|
787
|
-
item.children?.length ? /* @__PURE__ */
|
|
194
|
+
item.children?.length ? /* @__PURE__ */ jsx(SidebarMenuSub, {
|
|
788
195
|
"aria-label": item.label(),
|
|
789
|
-
children: item.children.map((child) => /* @__PURE__ */
|
|
790
|
-
children: /* @__PURE__ */
|
|
196
|
+
children: item.children.map((child) => /* @__PURE__ */ jsx(SidebarMenuSubItem, {
|
|
197
|
+
children: /* @__PURE__ */ jsx(SidebarMenuSubButton, {
|
|
791
198
|
onClick: closeMobileSidebar,
|
|
792
|
-
render: /* @__PURE__ */
|
|
199
|
+
render: /* @__PURE__ */ jsx(Link, {
|
|
793
200
|
to: child.href,
|
|
794
201
|
activeOptions: {
|
|
795
202
|
exact: true,
|
|
@@ -797,7 +204,7 @@ function AppSidebar({ collapsible, footer, groups, header }) {
|
|
|
797
204
|
},
|
|
798
205
|
activeProps: { "data-active": "" }
|
|
799
206
|
}),
|
|
800
|
-
children: /* @__PURE__ */
|
|
207
|
+
children: /* @__PURE__ */ jsx("span", {
|
|
801
208
|
children: child.label()
|
|
802
209
|
})
|
|
803
210
|
})
|
|
@@ -811,10 +218,10 @@ function AppSidebar({ collapsible, footer, groups, header }) {
|
|
|
811
218
|
]
|
|
812
219
|
}, group.label()))
|
|
813
220
|
}),
|
|
814
|
-
footer ? /* @__PURE__ */
|
|
221
|
+
footer ? /* @__PURE__ */ jsx(SidebarFooter, {
|
|
815
222
|
children: footer
|
|
816
223
|
}) : null,
|
|
817
|
-
/* @__PURE__ */
|
|
224
|
+
/* @__PURE__ */ jsx(SidebarRail, {})
|
|
818
225
|
]
|
|
819
226
|
});
|
|
820
227
|
}
|
|
@@ -826,25 +233,25 @@ function SidebarPageHeader({
|
|
|
826
233
|
actions
|
|
827
234
|
}) {
|
|
828
235
|
const sidebarLayoutClasses = resolveSidebarLayoutClasses(classOverrides);
|
|
829
|
-
return /* @__PURE__ */
|
|
236
|
+
return /* @__PURE__ */ jsxs("header", {
|
|
830
237
|
className: sidebarLayoutClasses.header,
|
|
831
238
|
children: [
|
|
832
|
-
/* @__PURE__ */
|
|
239
|
+
/* @__PURE__ */ jsxs("div", {
|
|
833
240
|
className: sidebarLayoutClasses.headerMain,
|
|
834
241
|
children: [
|
|
835
|
-
badge ? /* @__PURE__ */
|
|
242
|
+
badge ? /* @__PURE__ */ jsx(Badge, {
|
|
836
243
|
className: "w-fit",
|
|
837
244
|
variant: badge.variant ?? "secondary",
|
|
838
245
|
children: badge.label
|
|
839
246
|
}) : null,
|
|
840
|
-
/* @__PURE__ */
|
|
247
|
+
/* @__PURE__ */ jsxs("div", {
|
|
841
248
|
className: sidebarLayoutClasses.headerText,
|
|
842
249
|
children: [
|
|
843
|
-
/* @__PURE__ */
|
|
250
|
+
/* @__PURE__ */ jsx("h1", {
|
|
844
251
|
className: sidebarLayoutClasses.title,
|
|
845
252
|
children: title
|
|
846
253
|
}),
|
|
847
|
-
description ? /* @__PURE__ */
|
|
254
|
+
description ? /* @__PURE__ */ jsx("p", {
|
|
848
255
|
className: sidebarLayoutClasses.description,
|
|
849
256
|
children: description
|
|
850
257
|
}) : null
|
|
@@ -852,7 +259,7 @@ function SidebarPageHeader({
|
|
|
852
259
|
})
|
|
853
260
|
]
|
|
854
261
|
}),
|
|
855
|
-
actions ? /* @__PURE__ */
|
|
262
|
+
actions ? /* @__PURE__ */ jsx("div", {
|
|
856
263
|
className: "flex gap-2",
|
|
857
264
|
children: actions
|
|
858
265
|
}) : null
|
|
@@ -879,36 +286,36 @@ function SidebarLayout({
|
|
|
879
286
|
groups: [],
|
|
880
287
|
defaultOpen
|
|
881
288
|
});
|
|
882
|
-
return /* @__PURE__ */
|
|
289
|
+
return /* @__PURE__ */ jsxs(SidebarProvider, {
|
|
883
290
|
open: sidebarOpen,
|
|
884
291
|
onOpenChange: (open) => send(SidebarLayoutMessage.SetOpen({ open })),
|
|
885
292
|
className: cn(fullPage && sidebarLayoutClasses.desktopViewport),
|
|
886
293
|
children: [
|
|
887
|
-
/* @__PURE__ */
|
|
294
|
+
/* @__PURE__ */ jsx(AppSidebar, {
|
|
888
295
|
collapsible: sidebarCollapsible,
|
|
889
296
|
footer: sidebarFooter,
|
|
890
297
|
groups,
|
|
891
298
|
header: sidebarHeader
|
|
892
299
|
}),
|
|
893
|
-
/* @__PURE__ */
|
|
300
|
+
/* @__PURE__ */ jsxs(SidebarInset, {
|
|
894
301
|
className: cn("min-w-0 overflow-x-clip", fullPage && sidebarLayoutClasses.desktopViewport),
|
|
895
302
|
children: [
|
|
896
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ jsx("div", {
|
|
897
304
|
className: "h-14 shrink-0",
|
|
898
|
-
children: /* @__PURE__ */
|
|
305
|
+
children: /* @__PURE__ */ jsxs("header", {
|
|
899
306
|
className: cn("bg-background/95 supports-[backdrop-filter]:bg-background/60 fixed inset-x-0 top-0 z-10 flex h-14 items-center gap-2 border-b px-4 backdrop-blur transition-[left] duration-200 ease-linear", sidebarCollapsible === "none" ? "left-(--sidebar-width)" : sidebarOpen ? "md:left-(--sidebar-width)" : sidebarCollapsible === "icon" ? "md:left-(--sidebar-width-icon)" : "md:left-0", fullPage && "xl:static"),
|
|
900
307
|
children: [
|
|
901
|
-
/* @__PURE__ */
|
|
902
|
-
/* @__PURE__ */
|
|
308
|
+
/* @__PURE__ */ jsx(SidebarTrigger, {}),
|
|
309
|
+
/* @__PURE__ */ jsx("div", {
|
|
903
310
|
className: sidebarLayoutClasses.toolbar,
|
|
904
311
|
children: headerActions
|
|
905
312
|
})
|
|
906
313
|
]
|
|
907
314
|
})
|
|
908
315
|
}),
|
|
909
|
-
/* @__PURE__ */
|
|
316
|
+
/* @__PURE__ */ jsx("div", {
|
|
910
317
|
className: cn(sidebarLayoutClasses.content, contentClassName ?? "flex flex-col gap-6 px-5 py-6 md:px-8"),
|
|
911
|
-
children: children ?? /* @__PURE__ */
|
|
318
|
+
children: children ?? /* @__PURE__ */ jsx(Outlet, {})
|
|
912
319
|
})
|
|
913
320
|
]
|
|
914
321
|
})
|