@customafk/lunas-ui 0.1.99 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/button-6-3G2PiR.mjs +2 -0
- package/dist/{button-C_yZHudZ.mjs.map → button-6-3G2PiR.mjs.map} +1 -1
- package/dist/button-D0WaocKO.cjs +2 -0
- package/dist/button-D0WaocKO.cjs.map +1 -0
- package/dist/{button-Dy39kE9k.d.cts → button-D0YsVKtm.d.cts} +5 -5
- package/dist/{button-8vMj-_no.d.mts → button-L3Ts3X9d.d.mts} +3 -3
- package/dist/button.variants-DuuH1O0_.mjs +2 -0
- package/dist/button.variants-DuuH1O0_.mjs.map +1 -0
- package/dist/button.variants-rdXrPUao.cjs +2 -0
- package/dist/button.variants-rdXrPUao.cjs.map +1 -0
- package/dist/{calendar-DgLMLD8R.cjs → calendar-CO20ceyB.cjs} +2 -2
- package/dist/{calendar-DgLMLD8R.cjs.map → calendar-CO20ceyB.cjs.map} +1 -1
- package/dist/{calendar-e9Pu8pNj.mjs → calendar-D3hTjPxn.mjs} +2 -2
- package/dist/{calendar-e9Pu8pNj.mjs.map → calendar-D3hTjPxn.mjs.map} +1 -1
- package/dist/cards/grid-product-card.cjs +1 -1
- package/dist/cards/grid-product-card.mjs +1 -1
- package/dist/cards/product-card.cjs +1 -1
- package/dist/cards/product-card.mjs +1 -1
- package/dist/cards/simple-card.cjs +1 -1
- package/dist/cards/simple-card.d.mts +2 -2
- package/dist/cards/simple-card.mjs +1 -1
- package/dist/{command-Uq5FAdtW.mjs → command-DhBTNTqz.mjs} +2 -2
- package/dist/{command-Uq5FAdtW.mjs.map → command-DhBTNTqz.mjs.map} +1 -1
- package/dist/{command-Dd4OnuB0.cjs → command-_zpTaaIk.cjs} +2 -2
- package/dist/{command-Dd4OnuB0.cjs.map → command-_zpTaaIk.cjs.map} +1 -1
- package/dist/data-display/country.cjs +1 -1
- package/dist/data-display/country.mjs +1 -1
- package/dist/data-display/date-tooltip.cjs +1 -1
- package/dist/data-display/date-tooltip.mjs +1 -1
- package/dist/data-display/date.cjs +1 -1
- package/dist/data-display/date.mjs +1 -1
- package/dist/data-display/name.cjs +1 -1
- package/dist/data-display/name.mjs +1 -1
- package/dist/data-display/statistic.d.mts +2 -2
- package/dist/data-display/user.cjs +1 -1
- package/dist/data-display/user.mjs +1 -1
- package/dist/date-By93kONr.mjs +2 -0
- package/dist/date-By93kONr.mjs.map +1 -0
- package/dist/date-em5f7hCx.cjs +2 -0
- package/dist/date-em5f7hCx.cjs.map +1 -0
- package/dist/{dialog-ArqTBRVT.d.mts → dialog-C3T_1iTB.d.cts} +12 -12
- package/dist/{dialog-BtlJFvlf.d.cts → dialog-COoKGA4Q.d.mts} +12 -12
- package/dist/{dialog-DTz8ngeU.mjs → dialog-CxELDK98.mjs} +2 -2
- package/dist/{dialog-DTz8ngeU.mjs.map → dialog-CxELDK98.mjs.map} +1 -1
- package/dist/{dialog-2N-D9B9o.cjs → dialog-DjRiV5vR.cjs} +2 -2
- package/dist/{dialog-2N-D9B9o.cjs.map → dialog-DjRiV5vR.cjs.map} +1 -1
- package/dist/dialogs/confirm-dialog.cjs +1 -1
- package/dist/dialogs/confirm-dialog.mjs +1 -1
- package/dist/dialogs/detail-dialog/components/sidebar.cjs +1 -1
- package/dist/dialogs/detail-dialog/components/sidebar.d.cts +26 -26
- package/dist/dialogs/detail-dialog/components/sidebar.d.mts +26 -26
- package/dist/dialogs/detail-dialog/components/sidebar.mjs +1 -1
- package/dist/dialogs/detail-dialog/index.cjs +1 -1
- package/dist/dialogs/detail-dialog/index.mjs +1 -1
- package/dist/dialogs/error-dialog.cjs +1 -1
- package/dist/dialogs/error-dialog.mjs +1 -1
- package/dist/dialogs/loading-dialog.cjs +1 -1
- package/dist/dialogs/loading-dialog.mjs +1 -1
- package/dist/features/descriptions/index.cjs +1 -1
- package/dist/features/descriptions/index.d.cts +4 -4
- package/dist/features/descriptions/index.mjs +1 -1
- package/dist/features/search-modal/index.cjs +1 -1
- package/dist/features/search-modal/index.d.cts +2 -2
- package/dist/features/search-modal/index.d.mts +2 -2
- package/dist/features/search-modal/index.mjs +1 -1
- package/dist/features/tables/index.cjs +1 -1
- package/dist/features/tables/index.cjs.map +1 -1
- package/dist/features/tables/index.d.cts +1 -1
- package/dist/features/tables/index.d.mts +1 -1
- package/dist/features/tables/index.mjs +1 -1
- package/dist/features/tables/index.mjs.map +1 -1
- package/dist/features/tanstack-form/index.cjs +1 -1
- package/dist/features/tanstack-form/index.cjs.map +1 -1
- package/dist/features/tanstack-form/index.d.cts +231 -224
- package/dist/features/tanstack-form/index.d.mts +58 -51
- package/dist/features/tanstack-form/index.mjs +1 -1
- package/dist/features/tanstack-form/index.mjs.map +1 -1
- package/dist/{input-DERBzcV_.d.mts → input-C3M7uZqX.d.cts} +5 -5
- package/dist/{input-DqoSygui.d.cts → input-C9dS5env.d.mts} +6 -6
- package/dist/layouts/cms-layout/index.cjs +1 -1
- package/dist/layouts/cms-layout/index.cjs.map +1 -1
- package/dist/layouts/cms-layout/index.mjs +1 -1
- package/dist/layouts/cms-layout/index.mjs.map +1 -1
- package/dist/layouts/flex.d.cts +2 -2
- package/dist/layouts/flex.d.mts +2 -2
- package/dist/layouts/payment-layout/index.cjs +1 -1
- package/dist/layouts/payment-layout/index.mjs +1 -1
- package/dist/pages/FeatureDeveloping.cjs +1 -1
- package/dist/pages/FeatureDeveloping.d.cts +2 -2
- package/dist/pages/FeatureDeveloping.d.mts +2 -2
- package/dist/pages/FeatureDeveloping.mjs +1 -1
- package/dist/pages/FeatureFixing.cjs +1 -1
- package/dist/pages/FeatureFixing.d.cts +2 -2
- package/dist/pages/FeatureFixing.mjs +1 -1
- package/dist/pages/NotAuthorized.cjs +1 -1
- package/dist/pages/NotAuthorized.d.cts +2 -2
- package/dist/pages/NotAuthorized.d.mts +2 -2
- package/dist/pages/NotAuthorized.mjs +1 -1
- package/dist/pages/NotFound.cjs +1 -1
- package/dist/pages/NotFound.d.cts +2 -2
- package/dist/pages/NotFound.d.mts +2 -2
- package/dist/pages/NotFound.mjs +1 -1
- package/dist/{paragraph-BBye8n4M.cjs → paragraph-B72bHMf7.cjs} +2 -2
- package/dist/paragraph-B72bHMf7.cjs.map +1 -0
- package/dist/{paragraph-BS88Xdo7.mjs → paragraph-moBSTPmT.mjs} +2 -2
- package/dist/paragraph-moBSTPmT.mjs.map +1 -0
- package/dist/typography/paragraph.cjs +1 -1
- package/dist/typography/paragraph.d.cts +6 -6
- package/dist/typography/paragraph.d.mts +6 -6
- package/dist/typography/paragraph.mjs +1 -1
- package/dist/typography/title.d.cts +2 -2
- package/dist/typography/title.d.mts +2 -2
- package/dist/ui/alert-dialog.cjs +1 -1
- package/dist/ui/alert-dialog.d.cts +12 -12
- package/dist/ui/alert-dialog.d.mts +12 -12
- package/dist/ui/alert-dialog.mjs +1 -1
- package/dist/ui/alert.d.cts +6 -6
- package/dist/ui/alert.d.mts +6 -6
- package/dist/ui/aspect-ratio.d.cts +2 -2
- package/dist/ui/aspect-ratio.d.mts +2 -2
- package/dist/ui/avatar.d.cts +4 -4
- package/dist/ui/avatar.d.mts +4 -4
- package/dist/ui/badge.d.cts +4 -4
- package/dist/ui/badge.d.mts +4 -4
- package/dist/ui/breadcrumb.d.cts +8 -8
- package/dist/ui/breadcrumb.d.mts +8 -8
- package/dist/ui/button-group.d.cts +6 -6
- package/dist/ui/button-group.d.mts +6 -6
- package/dist/ui/button.cjs +1 -1
- package/dist/ui/button.d.cts +1 -1
- package/dist/ui/button.d.mts +1 -1
- package/dist/ui/button.mjs +1 -1
- package/dist/ui/buttons/add-new.cjs +1 -1
- package/dist/ui/buttons/add-new.mjs +1 -1
- package/dist/ui/buttons/edit.cjs +1 -1
- package/dist/ui/buttons/edit.mjs +1 -1
- package/dist/ui/buttons/refresh.cjs +1 -1
- package/dist/ui/buttons/refresh.mjs +1 -1
- package/dist/ui/buttons/trash.cjs +1 -1
- package/dist/ui/buttons/trash.mjs +1 -1
- package/dist/ui/buttons/upload-image.cjs +1 -1
- package/dist/ui/buttons/upload-image.mjs +1 -1
- package/dist/ui/calendar.cjs +1 -1
- package/dist/ui/calendar.d.cts +4 -4
- package/dist/ui/calendar.d.mts +4 -4
- package/dist/ui/calendar.mjs +1 -1
- package/dist/ui/card.cjs +1 -1
- package/dist/ui/card.d.cts +8 -8
- package/dist/ui/card.d.mts +8 -8
- package/dist/ui/card.mjs +1 -1
- package/dist/ui/carousel.cjs +1 -1
- package/dist/ui/carousel.d.cts +7 -7
- package/dist/ui/carousel.d.mts +7 -7
- package/dist/ui/carousel.mjs +1 -1
- package/dist/ui/checkbox.d.cts +2 -2
- package/dist/ui/checkbox.d.mts +2 -2
- package/dist/ui/collapsible.d.cts +4 -4
- package/dist/ui/collapsible.d.mts +4 -4
- package/dist/ui/command.cjs +1 -1
- package/dist/ui/command.d.cts +11 -11
- package/dist/ui/command.d.mts +11 -11
- package/dist/ui/command.mjs +1 -1
- package/dist/ui/context-menu.d.cts +16 -16
- package/dist/ui/context-menu.d.mts +16 -16
- package/dist/ui/dialog.cjs +1 -1
- package/dist/ui/dialog.d.cts +1 -1
- package/dist/ui/dialog.d.mts +1 -1
- package/dist/ui/dialog.mjs +1 -1
- package/dist/ui/drawer.d.cts +11 -11
- package/dist/ui/drawer.d.mts +11 -11
- package/dist/ui/dropdown-menu.d.cts +16 -16
- package/dist/ui/dropdown-menu.d.mts +16 -16
- package/dist/ui/empty.d.cts +9 -9
- package/dist/ui/empty.d.mts +9 -9
- package/dist/ui/field.d.cts +24 -24
- package/dist/ui/field.d.mts +24 -24
- package/dist/ui/file-uploader.cjs +1 -1
- package/dist/ui/file-uploader.d.cts +2 -2
- package/dist/ui/file-uploader.d.mts +2 -2
- package/dist/ui/file-uploader.mjs +1 -1
- package/dist/ui/form.d.cts +11 -11
- package/dist/ui/form.d.mts +7 -7
- package/dist/ui/hover-card.d.cts +4 -4
- package/dist/ui/hover-card.d.mts +4 -4
- package/dist/ui/input-otp.d.cts +5 -5
- package/dist/ui/input-otp.d.mts +5 -5
- package/dist/ui/input.d.cts +1 -1
- package/dist/ui/input.d.mts +1 -1
- package/dist/ui/inputs/search-input.d.cts +3 -3
- package/dist/ui/inputs/search-input.d.mts +3 -3
- package/dist/ui/item.d.cts +15 -15
- package/dist/ui/item.d.mts +15 -15
- package/dist/ui/label.d.cts +2 -2
- package/dist/ui/label.d.mts +2 -2
- package/dist/ui/menubar.d.cts +17 -17
- package/dist/ui/menubar.d.mts +17 -17
- package/dist/ui/multi-select.cjs +1 -1
- package/dist/ui/multi-select.d.cts +2 -2
- package/dist/ui/multi-select.d.mts +3 -3
- package/dist/ui/multi-select.mjs +1 -1
- package/dist/ui/navigation-menu.d.cts +9 -9
- package/dist/ui/navigation-menu.d.mts +11 -11
- package/dist/ui/pagination.cjs +1 -1
- package/dist/ui/pagination.d.cts +9 -9
- package/dist/ui/pagination.d.mts +9 -9
- package/dist/ui/pagination.mjs +1 -1
- package/dist/ui/popover.d.cts +6 -6
- package/dist/ui/popover.d.mts +6 -6
- package/dist/ui/progress.d.cts +2 -2
- package/dist/ui/progress.d.mts +2 -2
- package/dist/ui/radio-group.d.cts +3 -3
- package/dist/ui/radio-group.d.mts +3 -3
- package/dist/ui/resizable.d.cts +9 -9
- package/dist/ui/resizable.d.mts +9 -9
- package/dist/ui/scroll-area.d.cts +6 -6
- package/dist/ui/scroll-area.d.mts +3 -3
- package/dist/ui/select.d.cts +9 -9
- package/dist/ui/select.d.mts +9 -9
- package/dist/ui/separator.d.cts +2 -2
- package/dist/ui/separator.d.mts +2 -2
- package/dist/ui/sheet.d.cts +9 -9
- package/dist/ui/sheet.d.mts +9 -9
- package/dist/ui/sidebar.cjs +1 -1
- package/dist/ui/sidebar.d.cts +28 -28
- package/dist/ui/sidebar.d.mts +28 -28
- package/dist/ui/sidebar.mjs +1 -1
- package/dist/ui/skeleton.d.cts +2 -2
- package/dist/ui/skeleton.d.mts +2 -2
- package/dist/ui/slider.d.cts +2 -2
- package/dist/ui/slider.d.mts +2 -2
- package/dist/ui/sonner.d.cts +2 -2
- package/dist/ui/sonner.d.mts +2 -2
- package/dist/ui/spinner.d.cts +2 -2
- package/dist/ui/spinner.d.mts +2 -2
- package/dist/ui/switch.d.cts +2 -2
- package/dist/ui/switch.d.mts +2 -2
- package/dist/ui/table.d.cts +18 -18
- package/dist/ui/table.d.mts +18 -18
- package/dist/ui/tabs.d.cts +5 -5
- package/dist/ui/tabs.d.mts +5 -5
- package/dist/ui/textarea.d.cts +2 -2
- package/dist/ui/textarea.d.mts +2 -2
- package/dist/ui/toggle-group.d.cts +3 -3
- package/dist/ui/toggle-group.d.mts +3 -3
- package/dist/ui/toggle.d.cts +4 -4
- package/dist/ui/toggle.d.mts +2 -2
- package/dist/ui/tooltip.d.cts +5 -5
- package/dist/ui/tooltip.d.mts +5 -5
- package/package.json +2 -2
- package/dist/button-8Snjc8iT.cjs +0 -2
- package/dist/button-8Snjc8iT.cjs.map +0 -1
- package/dist/button-C_yZHudZ.mjs +0 -2
- package/dist/button.variants-8QOIR433.cjs +0 -2
- package/dist/button.variants-8QOIR433.cjs.map +0 -1
- package/dist/button.variants-CL2rLGYO.mjs +0 -2
- package/dist/button.variants-CL2rLGYO.mjs.map +0 -1
- package/dist/date-CK7XBqG9.mjs +0 -2
- package/dist/date-CK7XBqG9.mjs.map +0 -1
- package/dist/date-CTmoK8tv.cjs +0 -2
- package/dist/date-CTmoK8tv.cjs.map +0 -1
- package/dist/paragraph-BBye8n4M.cjs.map +0 -1
- package/dist/paragraph-BS88Xdo7.mjs.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as Button } from "../../../button-
|
|
1
|
+
import { t as Button } from "../../../button-D0YsVKtm.cjs";
|
|
2
2
|
import { Separator } from "../../../ui/separator.cjs";
|
|
3
3
|
import { TooltipContent } from "../../../ui/tooltip.cjs";
|
|
4
|
-
import * as
|
|
5
|
-
import * as
|
|
4
|
+
import * as react_jsx_runtime38 from "react/jsx-runtime";
|
|
5
|
+
import * as class_variance_authority_types3 from "class-variance-authority/types";
|
|
6
6
|
import { VariantProps } from "class-variance-authority";
|
|
7
7
|
|
|
8
8
|
//#region packages/components/dialogs/detail-dialog/components/sidebar.d.ts
|
|
@@ -28,7 +28,7 @@ declare function SidebarProvider({
|
|
|
28
28
|
defaultOpen?: boolean;
|
|
29
29
|
open?: boolean;
|
|
30
30
|
onOpenChange?: (open: boolean) => void;
|
|
31
|
-
}):
|
|
31
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
32
32
|
declare function Sidebar({
|
|
33
33
|
side,
|
|
34
34
|
variant,
|
|
@@ -40,71 +40,71 @@ declare function Sidebar({
|
|
|
40
40
|
side?: 'left' | 'right';
|
|
41
41
|
variant?: 'sidebar' | 'floating' | 'inset';
|
|
42
42
|
collapsible?: 'offcanvas' | 'icon' | 'none';
|
|
43
|
-
}):
|
|
43
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
44
44
|
declare function DetailDialogSidebarTrigger({
|
|
45
45
|
className,
|
|
46
46
|
onClick,
|
|
47
47
|
...props
|
|
48
|
-
}: React.ComponentProps<typeof Button>):
|
|
48
|
+
}: React.ComponentProps<typeof Button>): react_jsx_runtime38.JSX.Element;
|
|
49
49
|
declare function DetailDialogSidebarRail({
|
|
50
50
|
className,
|
|
51
51
|
...props
|
|
52
|
-
}: React.ComponentProps<'button'>):
|
|
52
|
+
}: React.ComponentProps<'button'>): react_jsx_runtime38.JSX.Element;
|
|
53
53
|
declare function SidebarInset({
|
|
54
54
|
className,
|
|
55
55
|
...props
|
|
56
|
-
}: React.ComponentProps<'main'>):
|
|
56
|
+
}: React.ComponentProps<'main'>): react_jsx_runtime38.JSX.Element;
|
|
57
57
|
declare function DetailDialogSidebarHeader({
|
|
58
58
|
className,
|
|
59
59
|
...props
|
|
60
|
-
}: React.ComponentProps<'div'>):
|
|
60
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
61
61
|
declare function DetailDialogSidebarFooter({
|
|
62
62
|
className,
|
|
63
63
|
children,
|
|
64
64
|
...props
|
|
65
|
-
}: React.ComponentProps<'div'>):
|
|
65
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
66
66
|
declare function DetailDialogSidebarSeparator({
|
|
67
67
|
className,
|
|
68
68
|
...props
|
|
69
|
-
}: React.ComponentProps<typeof Separator>):
|
|
69
|
+
}: React.ComponentProps<typeof Separator>): react_jsx_runtime38.JSX.Element;
|
|
70
70
|
declare function DetailDialogSidebarContent({
|
|
71
71
|
className,
|
|
72
72
|
...props
|
|
73
|
-
}: React.ComponentProps<'div'>):
|
|
73
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
74
74
|
declare function DetailDialogSidebarGroup({
|
|
75
75
|
className,
|
|
76
76
|
...props
|
|
77
|
-
}: React.ComponentProps<'div'>):
|
|
77
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
78
78
|
declare function DetailDialogSidebarGroupLabel({
|
|
79
79
|
className,
|
|
80
80
|
asChild,
|
|
81
81
|
...props
|
|
82
82
|
}: React.ComponentProps<'div'> & {
|
|
83
83
|
asChild?: boolean;
|
|
84
|
-
}):
|
|
84
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
85
85
|
declare function DetailDialogSidebarGroupAction({
|
|
86
86
|
className,
|
|
87
87
|
asChild,
|
|
88
88
|
...props
|
|
89
89
|
}: React.ComponentProps<'button'> & {
|
|
90
90
|
asChild?: boolean;
|
|
91
|
-
}):
|
|
91
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
92
92
|
declare function DetailDialogSidebarGroupContent({
|
|
93
93
|
className,
|
|
94
94
|
...props
|
|
95
|
-
}: React.ComponentProps<'div'>):
|
|
95
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
96
96
|
declare function DetailDialogSidebarMenu({
|
|
97
97
|
className,
|
|
98
98
|
...props
|
|
99
|
-
}: React.ComponentProps<'ul'>):
|
|
99
|
+
}: React.ComponentProps<'ul'>): react_jsx_runtime38.JSX.Element;
|
|
100
100
|
declare function DetailDialogSidebarMenuItem({
|
|
101
101
|
className,
|
|
102
102
|
...props
|
|
103
|
-
}: React.ComponentProps<'li'>):
|
|
103
|
+
}: React.ComponentProps<'li'>): react_jsx_runtime38.JSX.Element;
|
|
104
104
|
declare const sidebarMenuButtonVariants: (props?: ({
|
|
105
105
|
variant?: "default" | "outline" | null | undefined;
|
|
106
106
|
size?: "sm" | "lg" | "default" | null | undefined;
|
|
107
|
-
} &
|
|
107
|
+
} & class_variance_authority_types3.ClassProp) | undefined) => string;
|
|
108
108
|
declare function DetailDialogSidebarMenuButton({
|
|
109
109
|
asChild,
|
|
110
110
|
isActive,
|
|
@@ -117,7 +117,7 @@ declare function DetailDialogSidebarMenuButton({
|
|
|
117
117
|
asChild?: boolean;
|
|
118
118
|
isActive?: boolean;
|
|
119
119
|
tooltip?: string | React.ComponentProps<typeof TooltipContent>;
|
|
120
|
-
} & VariantProps<typeof sidebarMenuButtonVariants>):
|
|
120
|
+
} & VariantProps<typeof sidebarMenuButtonVariants>): react_jsx_runtime38.JSX.Element;
|
|
121
121
|
declare function DetailDialogSidebarMenuAction({
|
|
122
122
|
className,
|
|
123
123
|
asChild,
|
|
@@ -126,26 +126,26 @@ declare function DetailDialogSidebarMenuAction({
|
|
|
126
126
|
}: React.ComponentProps<'button'> & {
|
|
127
127
|
asChild?: boolean;
|
|
128
128
|
showOnHover?: boolean;
|
|
129
|
-
}):
|
|
129
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
130
130
|
declare function DetailDialogSidebarMenuBadge({
|
|
131
131
|
className,
|
|
132
132
|
...props
|
|
133
|
-
}: React.ComponentProps<'div'>):
|
|
133
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime38.JSX.Element;
|
|
134
134
|
declare function DetailDialogSidebarMenuSkeleton({
|
|
135
135
|
className,
|
|
136
136
|
showIcon,
|
|
137
137
|
...props
|
|
138
138
|
}: React.ComponentProps<'div'> & {
|
|
139
139
|
showIcon?: boolean;
|
|
140
|
-
}):
|
|
140
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
141
141
|
declare function DetailDialogSidebarMenuSub({
|
|
142
142
|
className,
|
|
143
143
|
...props
|
|
144
|
-
}: React.ComponentProps<'ul'>):
|
|
144
|
+
}: React.ComponentProps<'ul'>): react_jsx_runtime38.JSX.Element;
|
|
145
145
|
declare function DetailDialogSidebarMenuSubItem({
|
|
146
146
|
className,
|
|
147
147
|
...props
|
|
148
|
-
}: React.ComponentProps<'li'>):
|
|
148
|
+
}: React.ComponentProps<'li'>): react_jsx_runtime38.JSX.Element;
|
|
149
149
|
declare function DetailDialogSidebarMenuSubButton({
|
|
150
150
|
asChild,
|
|
151
151
|
size,
|
|
@@ -156,7 +156,7 @@ declare function DetailDialogSidebarMenuSubButton({
|
|
|
156
156
|
asChild?: boolean;
|
|
157
157
|
size?: 'sm' | 'md';
|
|
158
158
|
isActive?: boolean;
|
|
159
|
-
}):
|
|
159
|
+
}): react_jsx_runtime38.JSX.Element;
|
|
160
160
|
//#endregion
|
|
161
161
|
export { DetailDialogSidebarContent, DetailDialogSidebarFooter, DetailDialogSidebarGroup, DetailDialogSidebarGroupAction, DetailDialogSidebarGroupContent, DetailDialogSidebarGroupLabel, DetailDialogSidebarHeader, DetailDialogSidebarMenu, DetailDialogSidebarMenuAction, DetailDialogSidebarMenuBadge, DetailDialogSidebarMenuButton, DetailDialogSidebarMenuItem, DetailDialogSidebarMenuSkeleton, DetailDialogSidebarMenuSub, DetailDialogSidebarMenuSubButton, DetailDialogSidebarMenuSubItem, DetailDialogSidebarRail, DetailDialogSidebarSeparator, DetailDialogSidebarTrigger, Sidebar, SidebarInset, SidebarProvider, useSidebar };
|
|
162
162
|
//# sourceMappingURL=sidebar.d.cts.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { t as Button } from "../../../button-
|
|
1
|
+
import { t as Button } from "../../../button-L3Ts3X9d.mjs";
|
|
2
2
|
import { Separator } from "../../../ui/separator.mjs";
|
|
3
3
|
import { TooltipContent } from "../../../ui/tooltip.mjs";
|
|
4
4
|
import { VariantProps } from "class-variance-authority";
|
|
5
|
-
import * as
|
|
6
|
-
import * as
|
|
5
|
+
import * as react_jsx_runtime2 from "react/jsx-runtime";
|
|
6
|
+
import * as class_variance_authority_types0 from "class-variance-authority/types";
|
|
7
7
|
|
|
8
8
|
//#region packages/components/dialogs/detail-dialog/components/sidebar.d.ts
|
|
9
9
|
type SidebarContextProps = {
|
|
@@ -28,7 +28,7 @@ declare function SidebarProvider({
|
|
|
28
28
|
defaultOpen?: boolean;
|
|
29
29
|
open?: boolean;
|
|
30
30
|
onOpenChange?: (open: boolean) => void;
|
|
31
|
-
}):
|
|
31
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
32
32
|
declare function Sidebar({
|
|
33
33
|
side,
|
|
34
34
|
variant,
|
|
@@ -40,71 +40,71 @@ declare function Sidebar({
|
|
|
40
40
|
side?: 'left' | 'right';
|
|
41
41
|
variant?: 'sidebar' | 'floating' | 'inset';
|
|
42
42
|
collapsible?: 'offcanvas' | 'icon' | 'none';
|
|
43
|
-
}):
|
|
43
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
44
44
|
declare function DetailDialogSidebarTrigger({
|
|
45
45
|
className,
|
|
46
46
|
onClick,
|
|
47
47
|
...props
|
|
48
|
-
}: React.ComponentProps<typeof Button>):
|
|
48
|
+
}: React.ComponentProps<typeof Button>): react_jsx_runtime2.JSX.Element;
|
|
49
49
|
declare function DetailDialogSidebarRail({
|
|
50
50
|
className,
|
|
51
51
|
...props
|
|
52
|
-
}: React.ComponentProps<'button'>):
|
|
52
|
+
}: React.ComponentProps<'button'>): react_jsx_runtime2.JSX.Element;
|
|
53
53
|
declare function SidebarInset({
|
|
54
54
|
className,
|
|
55
55
|
...props
|
|
56
|
-
}: React.ComponentProps<'main'>):
|
|
56
|
+
}: React.ComponentProps<'main'>): react_jsx_runtime2.JSX.Element;
|
|
57
57
|
declare function DetailDialogSidebarHeader({
|
|
58
58
|
className,
|
|
59
59
|
...props
|
|
60
|
-
}: React.ComponentProps<'div'>):
|
|
60
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
61
61
|
declare function DetailDialogSidebarFooter({
|
|
62
62
|
className,
|
|
63
63
|
children,
|
|
64
64
|
...props
|
|
65
|
-
}: React.ComponentProps<'div'>):
|
|
65
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
66
66
|
declare function DetailDialogSidebarSeparator({
|
|
67
67
|
className,
|
|
68
68
|
...props
|
|
69
|
-
}: React.ComponentProps<typeof Separator>):
|
|
69
|
+
}: React.ComponentProps<typeof Separator>): react_jsx_runtime2.JSX.Element;
|
|
70
70
|
declare function DetailDialogSidebarContent({
|
|
71
71
|
className,
|
|
72
72
|
...props
|
|
73
|
-
}: React.ComponentProps<'div'>):
|
|
73
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
74
74
|
declare function DetailDialogSidebarGroup({
|
|
75
75
|
className,
|
|
76
76
|
...props
|
|
77
|
-
}: React.ComponentProps<'div'>):
|
|
77
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
78
78
|
declare function DetailDialogSidebarGroupLabel({
|
|
79
79
|
className,
|
|
80
80
|
asChild,
|
|
81
81
|
...props
|
|
82
82
|
}: React.ComponentProps<'div'> & {
|
|
83
83
|
asChild?: boolean;
|
|
84
|
-
}):
|
|
84
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
85
85
|
declare function DetailDialogSidebarGroupAction({
|
|
86
86
|
className,
|
|
87
87
|
asChild,
|
|
88
88
|
...props
|
|
89
89
|
}: React.ComponentProps<'button'> & {
|
|
90
90
|
asChild?: boolean;
|
|
91
|
-
}):
|
|
91
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
92
92
|
declare function DetailDialogSidebarGroupContent({
|
|
93
93
|
className,
|
|
94
94
|
...props
|
|
95
|
-
}: React.ComponentProps<'div'>):
|
|
95
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
96
96
|
declare function DetailDialogSidebarMenu({
|
|
97
97
|
className,
|
|
98
98
|
...props
|
|
99
|
-
}: React.ComponentProps<'ul'>):
|
|
99
|
+
}: React.ComponentProps<'ul'>): react_jsx_runtime2.JSX.Element;
|
|
100
100
|
declare function DetailDialogSidebarMenuItem({
|
|
101
101
|
className,
|
|
102
102
|
...props
|
|
103
|
-
}: React.ComponentProps<'li'>):
|
|
103
|
+
}: React.ComponentProps<'li'>): react_jsx_runtime2.JSX.Element;
|
|
104
104
|
declare const sidebarMenuButtonVariants: (props?: ({
|
|
105
105
|
variant?: "default" | "outline" | null | undefined;
|
|
106
106
|
size?: "sm" | "lg" | "default" | null | undefined;
|
|
107
|
-
} &
|
|
107
|
+
} & class_variance_authority_types0.ClassProp) | undefined) => string;
|
|
108
108
|
declare function DetailDialogSidebarMenuButton({
|
|
109
109
|
asChild,
|
|
110
110
|
isActive,
|
|
@@ -117,7 +117,7 @@ declare function DetailDialogSidebarMenuButton({
|
|
|
117
117
|
asChild?: boolean;
|
|
118
118
|
isActive?: boolean;
|
|
119
119
|
tooltip?: string | React.ComponentProps<typeof TooltipContent>;
|
|
120
|
-
} & VariantProps<typeof sidebarMenuButtonVariants>):
|
|
120
|
+
} & VariantProps<typeof sidebarMenuButtonVariants>): react_jsx_runtime2.JSX.Element;
|
|
121
121
|
declare function DetailDialogSidebarMenuAction({
|
|
122
122
|
className,
|
|
123
123
|
asChild,
|
|
@@ -126,26 +126,26 @@ declare function DetailDialogSidebarMenuAction({
|
|
|
126
126
|
}: React.ComponentProps<'button'> & {
|
|
127
127
|
asChild?: boolean;
|
|
128
128
|
showOnHover?: boolean;
|
|
129
|
-
}):
|
|
129
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
130
130
|
declare function DetailDialogSidebarMenuBadge({
|
|
131
131
|
className,
|
|
132
132
|
...props
|
|
133
|
-
}: React.ComponentProps<'div'>):
|
|
133
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime2.JSX.Element;
|
|
134
134
|
declare function DetailDialogSidebarMenuSkeleton({
|
|
135
135
|
className,
|
|
136
136
|
showIcon,
|
|
137
137
|
...props
|
|
138
138
|
}: React.ComponentProps<'div'> & {
|
|
139
139
|
showIcon?: boolean;
|
|
140
|
-
}):
|
|
140
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
141
141
|
declare function DetailDialogSidebarMenuSub({
|
|
142
142
|
className,
|
|
143
143
|
...props
|
|
144
|
-
}: React.ComponentProps<'ul'>):
|
|
144
|
+
}: React.ComponentProps<'ul'>): react_jsx_runtime2.JSX.Element;
|
|
145
145
|
declare function DetailDialogSidebarMenuSubItem({
|
|
146
146
|
className,
|
|
147
147
|
...props
|
|
148
|
-
}: React.ComponentProps<'li'>):
|
|
148
|
+
}: React.ComponentProps<'li'>): react_jsx_runtime2.JSX.Element;
|
|
149
149
|
declare function DetailDialogSidebarMenuSubButton({
|
|
150
150
|
asChild,
|
|
151
151
|
size,
|
|
@@ -156,7 +156,7 @@ declare function DetailDialogSidebarMenuSubButton({
|
|
|
156
156
|
asChild?: boolean;
|
|
157
157
|
size?: 'sm' | 'md';
|
|
158
158
|
isActive?: boolean;
|
|
159
|
-
}):
|
|
159
|
+
}): react_jsx_runtime2.JSX.Element;
|
|
160
160
|
//#endregion
|
|
161
161
|
export { DetailDialogSidebarContent, DetailDialogSidebarFooter, DetailDialogSidebarGroup, DetailDialogSidebarGroupAction, DetailDialogSidebarGroupContent, DetailDialogSidebarGroupLabel, DetailDialogSidebarHeader, DetailDialogSidebarMenu, DetailDialogSidebarMenuAction, DetailDialogSidebarMenuBadge, DetailDialogSidebarMenuButton, DetailDialogSidebarMenuItem, DetailDialogSidebarMenuSkeleton, DetailDialogSidebarMenuSub, DetailDialogSidebarMenuSubButton, DetailDialogSidebarMenuSubItem, DetailDialogSidebarRail, DetailDialogSidebarSeparator, DetailDialogSidebarTrigger, Sidebar, SidebarInset, SidebarProvider, useSidebar };
|
|
162
162
|
//# sourceMappingURL=sidebar.d.mts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import"../../../button.variants-CL2rLGYO.mjs";import{t as e}from"../../../button-C_yZHudZ.mjs";import{t}from"../../../skeleton-Ba6koCVf.mjs";import{i as n,n as r,r as i,t as a}from"../../../tooltip-B3dTcgcc.mjs";import{t as o}from"../../../separator-Bf0gymN4.mjs";import{i as s,o as c,r as l,s as u,t as d}from"../../../sheet-oadGRiie.mjs";import{cn as f}from"@customafk/react-toolkit/utils";import{cva as p}from"class-variance-authority";import{createContext as m,use as h,useCallback as g,useEffect as _,useMemo as v,useState as y}from"react";import{jsx as b,jsxs as x}from"react/jsx-runtime";import{MenuIcon as S}from"lucide-react";import{Slot as C}from"radix-ui";import{useIsMobile as w}from"@customafk/react-toolkit/hooks/useMobile";const T=m(null);function E(){let e=h(T);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function D({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:a,children:o,...s}){let c=w(),[l,u]=y(!1),[d,p]=y(e),m=t??d,h=g(e=>{let t=typeof e==`function`?e(m):e;n?n(t):p(t),document.cookie=`detai_dialog_sidebar_state=${t}; path=/; max-age=604800`},[n,m]),x=g(()=>c?u(e=>!e):h(e=>!e),[c,h]);_(()=>{let e=e=>{e.key===`p`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),x())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[x]);let S=m?`expanded`:`collapsed`,C=v(()=>({state:S,isMobile:c,toggleSidebar:x,open:m,setOpen:h,openMobile:l,setOpenMobile:u}),[S,c,m,h,l,x]);return b(T.Provider,{value:C,children:b(i,{delayDuration:0,children:b(`div`,{"data-slot":`sidebar-wrapper`,style:{"--sidebar-width":`20rem`,"--sidebar-width-icon":`3rem`,...a},className:f(`group/sidebar-wrapper flex h-full min-h-[85dvh] w-full items-start has-data-[variant=inset]:bg-sidebar`,r),...s,children:o})})})}function O({side:e=`left`,variant:t=`sidebar`,collapsible:n=`offcanvas`,className:r,children:i,...a}){let{state:o,isMobile:p,openMobile:m,setOpenMobile:h}=E();return n===`none`?b(`div`,{"data-slot":`sidebar`,className:f(`flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground`,r),...a,children:i}):p?b(d,{open:m,onOpenChange:h,...a,children:x(l,{"data-sidebar":`sidebar`,"data-slot":`sidebar`,"data-mobile":`true`,className:`z-20 hidden w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground shadow-nav md:flex [&>button]:hidden`,style:{"--sidebar-width":`18rem`},side:e,children:[x(c,{className:`sr-only`,children:[b(u,{children:`Sidebar`}),b(s,{children:`Displays the mobile sidebar.`})]}),b(`div`,{className:`flex h-full w-full flex-col`,children:i})]})}):x(`div`,{className:`group peer hidden text-sidebar-foreground md:block`,"data-state":o,"data-collapsible":o===`collapsed`?n:``,"data-variant":t,"data-side":e,"data-slot":`sidebar`,children:[b(`div`,{"data-slot":`sidebar-gap`,className:f(`relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear`,`group-data-[collapsible=offcanvas]:w-0`,`group-data-[side=right]:rotate-180`,t===`floating`||t===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`)}),b(`div`,{"data-slot":`sidebar-container`,className:f(`absolute inset-y-0 z-20 hidden w-(--sidebar-width) shadow-nav transition-[left,right,width] duration-200 ease-linear md:flex`,e===`left`?`left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]`:`right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]`,t===`floating`||t===`inset`?`p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`,r),...a,children:b(`div`,{"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,className:f(`flex size-full flex-col shadow-nav`,`group-data-[variant=floating]:border-sidebar-border`,`group-data-[variant=floating]:rounded-lg`,`group-data-[variant=floating]:border`,`group-data-[variant=floating]:shadow-sm`),children:i})})]})}function k({className:t,onClick:n,...r}){let{toggleSidebar:i}=E();return x(e,{"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,variant:`ghost`,color:`secondary`,size:`icon`,className:f(`size-10 rounded-full [&_svg]:size-6!`,t),onClick:e=>{n?.(e),i()},...r,children:[b(S,{}),b(`span`,{className:`sr-only`,children:`Toggle Sidebar`})]})}function A({className:e,...t}){let{toggleSidebar:n}=E();return b(`button`,{"data-sidebar":`rail`,"data-slot":`sidebar-rail`,"aria-label":`Toggle Sidebar`,tabIndex:-1,onClick:n,title:`Toggle Sidebar`,className:f(`absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear sm:flex`,`after:absolute`,`after:inset-y-0`,`after:left-1/2 after:w-0.5`,`hover:after:bg-sidebar-border`,`group-data-[side=left]:-right-4`,`group-data-[side=right]:left-0`,`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`,`hover:group-data-[collapsible=offcanvas]:bg-sidebar`,`group-data-[collapsible=offcanvas]:translate-x-0`,`group-data-[collapsible=offcanvas]:after:left-full`,`[[data-side=left][data-collapsible=offcanvas]_&]:-right-2`,`[[data-side=right][data-collapsible=offcanvas]_&]:-left-2`,e),...t})}function j({className:e,...t}){return b(`main`,{"data-slot":`sidebar-inset`,className:f(`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`,e),...t})}function M({className:e,...t}){return b(`div`,{"data-slot":`sidebar-header`,"data-sidebar":`header`,className:f(`flex flex-col gap-2 p-2`,e),...t})}function N({className:e,children:t,...n}){let{open:r}=E();return b(`div`,{"data-slot":`sidebar-footer`,"data-sidebar":`footer`,className:f(`flex flex-col gap-2 p-2`,e),...n,children:x(B,{children:[r&&b(V,{children:t}),b(V,{children:b(`p`,{className:`pt-2 text-center text-muted-foreground text-xs`,children:`Copyright © 2025, Lunas.`})})]})})}function P({className:e,...t}){return b(o,{"data-slot":`sidebar-separator`,"data-sidebar":`separator`,className:f(`mx-2 w-auto bg-sidebar-border`,e),...t})}function F({className:e,...t}){return b(`div`,{"data-slot":`sidebar-content`,"data-sidebar":`content`,className:f(`flex min-h-0 flex-1 flex-col gap-2 overflow-auto`,`group-data-[collapsible=icon]:overflow-hidden`,e),...t})}function I({className:e,...t}){return b(`div`,{"data-slot":`sidebar-group`,"data-sidebar":`group`,className:f(`relative flex w-full min-w-0 flex-col p-2`,e),...t})}function L({className:e,asChild:t=!1,...n}){return b(t?C.Slot:`div`,{"data-slot":`sidebar-group-label`,"data-sidebar":`group-label`,className:f(`flex h-8 shrink-0 items-center rounded-md px-2 font-medium text-sidebar-foreground/70 text-xs outline-hidden ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`group-data-[collapsible=icon]:-mt-8`,`group-data-[collapsible=icon]:opacity-0`,e),...n})}function R({className:e,asChild:t=!1,...n}){return b(t?C.Slot:`button`,{"data-slot":`sidebar-group-action`,"data-sidebar":`group-action`,className:f(`absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform`,`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`after:absolute`,`after:-inset-2`,`md:after:hidden`,`group-data-[collapsible=icon]:hidden`,e),...n})}function z({className:e,...t}){return b(`div`,{"data-slot":`sidebar-group-content`,"data-sidebar":`group-content`,className:f(`w-full text-sm`,e),...t})}function B({className:e,...t}){return b(`ul`,{"data-slot":`sidebar-menu`,"data-sidebar":`menu`,className:f(`flex w-full min-w-0 flex-col gap-1`,e),...t})}function V({className:e,...t}){return b(`li`,{"data-slot":`sidebar-menu-item`,"data-sidebar":`menu-item`,className:f(`group/menu-item relative`,e),...t})}const H=p([`peer/menu-button`,`cursor-pointer`,`flex w-full items-center gap-2`,`overflow-hidden rounded-md p-2 outline-hidden`,`truncate text-left font-normal`,`transition-[color,width,height,padding]`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`active:bg-sidebar-accent`,`active:text-sidebar-accent-foreground`,`disabled:pointer-events-none`,`disabled:opacity-50`,`group-has-data-[sidebar=menu-action]/menu-item:pr-8`,`aria-disabled:pointer-events-none`,`aria-disabled:opacity-50`,`data-[active=true]:bg-sidebar-primary-muted`,`data-[active=true]:font-normal`,`data-[active=true]:text-sidebar-primary`,`data-[state=open]:hover:bg-sidebar-accent`,`data-[state=open]:hover:text-sidebar-accent-foreground`,`group-data-[collapsible=icon]:size-8!`,`group-data-[collapsible=icon]:p-2!`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`[&>span:last-child]:truncate`],{variants:{variant:{default:`hover:bg-sidebar-accent/60 hover:text-sidebar-accent-foreground/80`,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))]`},size:{default:`h-8 text-sm`,sm:`h-7 text-xs`,lg:`h-12 text-sm group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function U({asChild:e=!1,isActive:t=!1,variant:i=`default`,size:o=`default`,tooltip:s,className:c,...l}){let u=e?C.Slot:`button`,{state:d}=E(),p=b(u,{"data-slot":`sidebar-menu-button`,"data-sidebar":`menu-button`,"data-size":o,"data-active":t,className:f(H({variant:i,size:o}),c),...l});return s?(typeof s==`string`&&(s={children:s}),x(a,{children:[b(n,{asChild:!0,children:p}),b(r,{side:`right`,align:`center`,hidden:d!==`collapsed`,...s})]})):p}function W({className:e,asChild:t=!1,showOnHover:n=!1,...r}){return b(t?C.Slot:`button`,{"data-slot":`sidebar-menu-action`,"data-sidebar":`menu-action`,className:f(`text-sidebar-foreground ring-sidebar-ring`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform peer-hover/menu-button:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`after:absolute after:-inset-2 md:after:hidden`,`peer-data-[size=sm]/menu-button:top-1`,`peer-data-[size=default]/menu-button:top-1.5`,`peer-data-[size=lg]/menu-button:top-2.5`,`group-data-[collapsible=icon]:hidden`,n&&`peer-data-[active=true]/menu-button:text-sidebar-accent-foreground`,n&&`$group-focus-within/menu-item:opacity-100`,n&&`group-hover/menu-item:opacity-100`,n&&`data-[state=open]:opacity-100 md:opacity-0`,e),...r})}function G({className:e,...t}){return b(`div`,{"data-slot":`sidebar-menu-badge`,"data-sidebar":`menu-badge`,className:f(`pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 font-medium text-sidebar-foreground text-xs tabular-nums`,`peer-hover/menu-button:text-sidebar-accent-foreground`,`peer-data-[active=true]/menu-button:text-sidebar-accent-foreground`,`peer-data-[size=sm]/menu-button:top-1`,`peer-data-[size=default]/menu-button:top-1.5`,`peer-data-[size=lg]/menu-button:top-2.5`,`group-data-[collapsible=icon]:hidden`,e),...t})}function K({className:e,showIcon:n=!1,...r}){let i=v(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return x(`div`,{"data-slot":`sidebar-menu-skeleton`,"data-sidebar":`menu-skeleton`,className:f(`flex h-8 items-center gap-2 rounded-md px-2`,e),...r,children:[n&&b(t,{className:`size-4 rounded-md`,"data-sidebar":`menu-skeleton-icon`}),b(t,{className:`h-4 max-w-(--skeleton-width) flex-1`,"data-sidebar":`menu-skeleton-text`,style:{"--skeleton-width":i}})]})}function q({className:e,...t}){return b(`ul`,{"data-slot":`sidebar-menu-sub`,"data-sidebar":`menu-sub`,className:f(`mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-sidebar-border border-l px-2.5 py-0.5`,`group-data-[collapsible=icon]:hidden`,e),...t})}function J({className:e,...t}){return b(`li`,{"data-slot":`sidebar-menu-sub-item`,"data-sidebar":`menu-sub-item`,className:f(`group/menu-sub-item relative`,e),...t})}function Y({asChild:e=!1,size:t=`md`,isActive:n=!1,className:r,...i}){return b(e?C.Slot:`a`,{"data-slot":`sidebar-menu-sub-button`,"data-sidebar":`menu-sub-button`,"data-size":t,"data-active":n,className:f(`text-sidebar-foreground ring-sidebar-ring`,`flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`active:bg-sidebar-accent`,`active:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`disabled:pointer-events-none`,`disabled:opacity-50`,`aria-disabled:pointer-events-none`,`aria-disabled:opacity-50`,`[&>span:last-child]:truncate`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`[&>svg]:text-sidebar-accent-foreground`,`data-[active=true]:bg-sidebar-accent`,`data-[active=true]:text-sidebar-accent-foreground`,`group-data-[collapsible=icon]:hidden`,t===`sm`&&`text-xs`,t===`md`&&`text-sm`,r),...i})}export{F as DetailDialogSidebarContent,N as DetailDialogSidebarFooter,I as DetailDialogSidebarGroup,R as DetailDialogSidebarGroupAction,z as DetailDialogSidebarGroupContent,L as DetailDialogSidebarGroupLabel,M as DetailDialogSidebarHeader,B as DetailDialogSidebarMenu,W as DetailDialogSidebarMenuAction,G as DetailDialogSidebarMenuBadge,U as DetailDialogSidebarMenuButton,V as DetailDialogSidebarMenuItem,K as DetailDialogSidebarMenuSkeleton,q as DetailDialogSidebarMenuSub,Y as DetailDialogSidebarMenuSubButton,J as DetailDialogSidebarMenuSubItem,A as DetailDialogSidebarRail,P as DetailDialogSidebarSeparator,k as DetailDialogSidebarTrigger,O as Sidebar,j as SidebarInset,D as SidebarProvider,E as useSidebar};
|
|
1
|
+
"use client";import"../../../button.variants-DuuH1O0_.mjs";import{t as e}from"../../../button-6-3G2PiR.mjs";import{t}from"../../../skeleton-Ba6koCVf.mjs";import{i as n,n as r,r as i,t as a}from"../../../tooltip-B3dTcgcc.mjs";import{t as o}from"../../../separator-Bf0gymN4.mjs";import{i as s,o as c,r as l,s as u,t as d}from"../../../sheet-oadGRiie.mjs";import{cn as f}from"@customafk/react-toolkit/utils";import{cva as p}from"class-variance-authority";import{createContext as m,use as h,useCallback as g,useEffect as _,useMemo as v,useState as y}from"react";import{jsx as b,jsxs as x}from"react/jsx-runtime";import{MenuIcon as S}from"lucide-react";import{Slot as C}from"radix-ui";import{useIsMobile as w}from"@customafk/react-toolkit/hooks/useMobile";const T=m(null);function E(){let e=h(T);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function D({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:a,children:o,...s}){let c=w(),[l,u]=y(!1),[d,p]=y(e),m=t??d,h=g(e=>{let t=typeof e==`function`?e(m):e;n?n(t):p(t),document.cookie=`detai_dialog_sidebar_state=${t}; path=/; max-age=604800`},[n,m]),x=g(()=>c?u(e=>!e):h(e=>!e),[c,h]);_(()=>{let e=e=>{e.key===`p`&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),x())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[x]);let S=m?`expanded`:`collapsed`,C=v(()=>({state:S,isMobile:c,toggleSidebar:x,open:m,setOpen:h,openMobile:l,setOpenMobile:u}),[S,c,m,h,l,x]);return b(T.Provider,{value:C,children:b(i,{delayDuration:0,children:b(`div`,{"data-slot":`sidebar-wrapper`,style:{"--sidebar-width":`20rem`,"--sidebar-width-icon":`3rem`,...a},className:f(`group/sidebar-wrapper flex h-full min-h-[85dvh] w-full items-start has-data-[variant=inset]:bg-sidebar`,r),...s,children:o})})})}function O({side:e=`left`,variant:t=`sidebar`,collapsible:n=`offcanvas`,className:r,children:i,...a}){let{state:o,isMobile:p,openMobile:m,setOpenMobile:h}=E();return n===`none`?b(`div`,{"data-slot":`sidebar`,className:f(`flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground`,r),...a,children:i}):p?b(d,{open:m,onOpenChange:h,...a,children:x(l,{"data-sidebar":`sidebar`,"data-slot":`sidebar`,"data-mobile":`true`,className:`z-20 hidden w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground shadow-nav md:flex [&>button]:hidden`,style:{"--sidebar-width":`18rem`},side:e,children:[x(c,{className:`sr-only`,children:[b(u,{children:`Sidebar`}),b(s,{children:`Displays the mobile sidebar.`})]}),b(`div`,{className:`flex h-full w-full flex-col`,children:i})]})}):x(`div`,{className:`group peer hidden text-sidebar-foreground md:block`,"data-state":o,"data-collapsible":o===`collapsed`?n:``,"data-variant":t,"data-side":e,"data-slot":`sidebar`,children:[b(`div`,{"data-slot":`sidebar-gap`,className:f(`relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear`,`group-data-[collapsible=offcanvas]:w-0`,`group-data-[side=right]:rotate-180`,t===`floating`||t===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`)}),b(`div`,{"data-slot":`sidebar-container`,className:f(`absolute inset-y-0 z-20 hidden w-(--sidebar-width) shadow-nav transition-[left,right,width] duration-200 ease-linear md:flex`,e===`left`?`left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]`:`right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]`,t===`floating`||t===`inset`?`p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`,r),...a,children:b(`div`,{"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,className:f(`flex size-full flex-col shadow-nav`,`group-data-[variant=floating]:border-sidebar-border`,`group-data-[variant=floating]:rounded-lg`,`group-data-[variant=floating]:border`,`group-data-[variant=floating]:shadow-sm`),children:i})})]})}function k({className:t,onClick:n,...r}){let{toggleSidebar:i}=E();return x(e,{"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,variant:`ghost`,color:`secondary`,size:`icon`,className:f(`size-10 rounded-full [&_svg]:size-6!`,t),onClick:e=>{n?.(e),i()},...r,children:[b(S,{}),b(`span`,{className:`sr-only`,children:`Toggle Sidebar`})]})}function A({className:e,...t}){let{toggleSidebar:n}=E();return b(`button`,{"data-sidebar":`rail`,"data-slot":`sidebar-rail`,"aria-label":`Toggle Sidebar`,tabIndex:-1,onClick:n,title:`Toggle Sidebar`,className:f(`absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear sm:flex`,`after:absolute`,`after:inset-y-0`,`after:left-1/2 after:w-0.5`,`hover:after:bg-sidebar-border`,`group-data-[side=left]:-right-4`,`group-data-[side=right]:left-0`,`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`,`hover:group-data-[collapsible=offcanvas]:bg-sidebar`,`group-data-[collapsible=offcanvas]:translate-x-0`,`group-data-[collapsible=offcanvas]:after:left-full`,`[[data-side=left][data-collapsible=offcanvas]_&]:-right-2`,`[[data-side=right][data-collapsible=offcanvas]_&]:-left-2`,e),...t})}function j({className:e,...t}){return b(`main`,{"data-slot":`sidebar-inset`,className:f(`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`,e),...t})}function M({className:e,...t}){return b(`div`,{"data-slot":`sidebar-header`,"data-sidebar":`header`,className:f(`flex flex-col gap-2 p-2`,e),...t})}function N({className:e,children:t,...n}){let{open:r}=E();return b(`div`,{"data-slot":`sidebar-footer`,"data-sidebar":`footer`,className:f(`flex flex-col gap-2 p-2`,e),...n,children:x(B,{children:[r&&b(V,{children:t}),b(V,{children:b(`p`,{className:`pt-2 text-center text-muted-foreground text-xs`,children:`Copyright © 2025, Lunas.`})})]})})}function P({className:e,...t}){return b(o,{"data-slot":`sidebar-separator`,"data-sidebar":`separator`,className:f(`mx-2 w-auto bg-sidebar-border`,e),...t})}function F({className:e,...t}){return b(`div`,{"data-slot":`sidebar-content`,"data-sidebar":`content`,className:f(`flex min-h-0 flex-1 flex-col gap-2 overflow-auto`,`group-data-[collapsible=icon]:overflow-hidden`,e),...t})}function I({className:e,...t}){return b(`div`,{"data-slot":`sidebar-group`,"data-sidebar":`group`,className:f(`relative flex w-full min-w-0 flex-col p-2`,e),...t})}function L({className:e,asChild:t=!1,...n}){return b(t?C.Slot:`div`,{"data-slot":`sidebar-group-label`,"data-sidebar":`group-label`,className:f(`flex h-8 shrink-0 items-center rounded-md px-2 font-medium text-sidebar-foreground/70 text-xs outline-hidden ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`group-data-[collapsible=icon]:-mt-8`,`group-data-[collapsible=icon]:opacity-0`,e),...n})}function R({className:e,asChild:t=!1,...n}){return b(t?C.Slot:`button`,{"data-slot":`sidebar-group-action`,"data-sidebar":`group-action`,className:f(`absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform`,`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`after:absolute`,`after:-inset-2`,`md:after:hidden`,`group-data-[collapsible=icon]:hidden`,e),...n})}function z({className:e,...t}){return b(`div`,{"data-slot":`sidebar-group-content`,"data-sidebar":`group-content`,className:f(`w-full text-sm`,e),...t})}function B({className:e,...t}){return b(`ul`,{"data-slot":`sidebar-menu`,"data-sidebar":`menu`,className:f(`flex w-full min-w-0 flex-col gap-1`,e),...t})}function V({className:e,...t}){return b(`li`,{"data-slot":`sidebar-menu-item`,"data-sidebar":`menu-item`,className:f(`group/menu-item relative`,e),...t})}const H=p([`peer/menu-button`,`cursor-pointer`,`flex w-full items-center gap-2`,`overflow-hidden rounded-md p-2 outline-hidden`,`truncate text-left font-normal`,`transition-[color,width,height,padding]`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`active:bg-sidebar-accent`,`active:text-sidebar-accent-foreground`,`disabled:pointer-events-none`,`disabled:opacity-50`,`group-has-data-[sidebar=menu-action]/menu-item:pr-8`,`aria-disabled:pointer-events-none`,`aria-disabled:opacity-50`,`data-[active=true]:bg-sidebar-primary-muted`,`data-[active=true]:font-normal`,`data-[active=true]:text-sidebar-primary`,`data-[state=open]:hover:bg-sidebar-accent`,`data-[state=open]:hover:text-sidebar-accent-foreground`,`group-data-[collapsible=icon]:size-8!`,`group-data-[collapsible=icon]:p-2!`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`[&>span:last-child]:truncate`],{variants:{variant:{default:`hover:bg-sidebar-accent/60 hover:text-sidebar-accent-foreground/80`,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))]`},size:{default:`h-8 text-sm`,sm:`h-7 text-xs`,lg:`h-12 text-sm group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function U({asChild:e=!1,isActive:t=!1,variant:i=`default`,size:o=`default`,tooltip:s,className:c,...l}){let u=e?C.Slot:`button`,{state:d}=E(),p=b(u,{"data-slot":`sidebar-menu-button`,"data-sidebar":`menu-button`,"data-size":o,"data-active":t,className:f(H({variant:i,size:o}),c),...l});return s?(typeof s==`string`&&(s={children:s}),x(a,{children:[b(n,{asChild:!0,children:p}),b(r,{side:`right`,align:`center`,hidden:d!==`collapsed`,...s})]})):p}function W({className:e,asChild:t=!1,showOnHover:n=!1,...r}){return b(t?C.Slot:`button`,{"data-slot":`sidebar-menu-action`,"data-sidebar":`menu-action`,className:f(`text-sidebar-foreground ring-sidebar-ring`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform peer-hover/menu-button:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`after:absolute after:-inset-2 md:after:hidden`,`peer-data-[size=sm]/menu-button:top-1`,`peer-data-[size=default]/menu-button:top-1.5`,`peer-data-[size=lg]/menu-button:top-2.5`,`group-data-[collapsible=icon]:hidden`,n&&`peer-data-[active=true]/menu-button:text-sidebar-accent-foreground`,n&&`$group-focus-within/menu-item:opacity-100`,n&&`group-hover/menu-item:opacity-100`,n&&`data-[state=open]:opacity-100 md:opacity-0`,e),...r})}function G({className:e,...t}){return b(`div`,{"data-slot":`sidebar-menu-badge`,"data-sidebar":`menu-badge`,className:f(`pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 font-medium text-sidebar-foreground text-xs tabular-nums`,`peer-hover/menu-button:text-sidebar-accent-foreground`,`peer-data-[active=true]/menu-button:text-sidebar-accent-foreground`,`peer-data-[size=sm]/menu-button:top-1`,`peer-data-[size=default]/menu-button:top-1.5`,`peer-data-[size=lg]/menu-button:top-2.5`,`group-data-[collapsible=icon]:hidden`,e),...t})}function K({className:e,showIcon:n=!1,...r}){let i=v(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return x(`div`,{"data-slot":`sidebar-menu-skeleton`,"data-sidebar":`menu-skeleton`,className:f(`flex h-8 items-center gap-2 rounded-md px-2`,e),...r,children:[n&&b(t,{className:`size-4 rounded-md`,"data-sidebar":`menu-skeleton-icon`}),b(t,{className:`h-4 max-w-(--skeleton-width) flex-1`,"data-sidebar":`menu-skeleton-text`,style:{"--skeleton-width":i}})]})}function q({className:e,...t}){return b(`ul`,{"data-slot":`sidebar-menu-sub`,"data-sidebar":`menu-sub`,className:f(`mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-sidebar-border border-l px-2.5 py-0.5`,`group-data-[collapsible=icon]:hidden`,e),...t})}function J({className:e,...t}){return b(`li`,{"data-slot":`sidebar-menu-sub-item`,"data-sidebar":`menu-sub-item`,className:f(`group/menu-sub-item relative`,e),...t})}function Y({asChild:e=!1,size:t=`md`,isActive:n=!1,className:r,...i}){return b(e?C.Slot:`a`,{"data-slot":`sidebar-menu-sub-button`,"data-sidebar":`menu-sub-button`,"data-size":t,"data-active":n,className:f(`text-sidebar-foreground ring-sidebar-ring`,`flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden`,`hover:bg-sidebar-accent`,`hover:text-sidebar-accent-foreground`,`active:bg-sidebar-accent`,`active:text-sidebar-accent-foreground`,`focus-visible:ring-2`,`disabled:pointer-events-none`,`disabled:opacity-50`,`aria-disabled:pointer-events-none`,`aria-disabled:opacity-50`,`[&>span:last-child]:truncate`,`[&>svg]:size-4`,`[&>svg]:shrink-0`,`[&>svg]:text-sidebar-accent-foreground`,`data-[active=true]:bg-sidebar-accent`,`data-[active=true]:text-sidebar-accent-foreground`,`group-data-[collapsible=icon]:hidden`,t===`sm`&&`text-xs`,t===`md`&&`text-sm`,r),...i})}export{F as DetailDialogSidebarContent,N as DetailDialogSidebarFooter,I as DetailDialogSidebarGroup,R as DetailDialogSidebarGroupAction,z as DetailDialogSidebarGroupContent,L as DetailDialogSidebarGroupLabel,M as DetailDialogSidebarHeader,B as DetailDialogSidebarMenu,W as DetailDialogSidebarMenuAction,G as DetailDialogSidebarMenuBadge,U as DetailDialogSidebarMenuButton,V as DetailDialogSidebarMenuItem,K as DetailDialogSidebarMenuSkeleton,q as DetailDialogSidebarMenuSub,Y as DetailDialogSidebarMenuSubButton,J as DetailDialogSidebarMenuSubItem,A as DetailDialogSidebarRail,P as DetailDialogSidebarSeparator,k as DetailDialogSidebarTrigger,O as Sidebar,j as SidebarInset,D as SidebarProvider,E as useSidebar};
|
|
2
2
|
//# sourceMappingURL=sidebar.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../button.variants-
|
|
1
|
+
const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../button.variants-rdXrPUao.cjs`),require(`../../button-D0WaocKO.cjs`),require(`../../skeleton-CHympz8k.cjs`);const t=require(`../../flex-twCgWyx1.cjs`),n=require(`../../date-em5f7hCx.cjs`);require(`../../tooltip-DC6i1A25.cjs`);const r=require(`../../typography/title.cjs`);require(`../../separator-C3ip6sbh.cjs`),require(`../../sheet-5MJRtrfG.cjs`);const i=require(`./components/sidebar.cjs`);let a=require(`react/jsx-runtime`),o=require(`lucide-react`),s=require(`radix-ui`);const c=({open:e,isLoading:c,title:l,createdAt:u,onOpenChange:d,sidebar:f,children:p})=>{let{content:m,footer:h}=f||{};return(0,a.jsx)(s.Dialog.Root,{"data-slot":`detail-dialog`,open:e,onOpenChange:d,children:(0,a.jsxs)(s.Dialog.Portal,{"data-slot":`detail-dialog-portal`,children:[(0,a.jsx)(s.Dialog.Overlay,{"data-slot":`detail-dialog-overlay`,className:`data-[state=open]:fade-in-0 data-[state=closed]:fade-out-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in`}),(0,a.jsx)(`div`,{className:`fixed inset-0 z-50 flex items-center justify-center`,children:(0,a.jsxs)(s.Dialog.Content,{"data-slot":`dialog-content`,className:`data-[state=open]:fade-in-0 data-[state=open]:zoom-in-80 data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-80 relative z-50 grid h-full max-h-dvh w-full max-w-svw gap-4 overflow-hidden rounded-none border-none bg-background p-0 shadow-dialog outline-none duration-200 data-[state=closed]:animate-out data-[state=open]:animate-in sm:max-w-lg md:max-h-[90dvh] md:max-w-[90svw] md:rounded-lg xl:max-h-[90dvh] xl:max-w-[90svw] 2xl:max-h-[90dvh] 2xl:max-w-[90svw]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:[(0,a.jsxs)(i.SidebarProvider,{children:[(0,a.jsxs)(i.Sidebar,{collapsible:`icon`,children:[(0,a.jsx)(i.DetailDialogSidebarHeader,{children:(0,a.jsx)(i.DetailDialogSidebarMenu,{children:(0,a.jsx)(i.DetailDialogSidebarMenuItem,{children:(0,a.jsxs)(i.DetailDialogSidebarMenuButton,{size:`lg`,tabIndex:-1,children:[(0,a.jsx)(`div`,{className:`flex aspect-square size-8 items-center justify-center rounded-lg bg-sidebar-primary text-sidebar-primary-foreground`,children:(0,a.jsx)(o.CatIcon,{size:16})}),(0,a.jsxs)(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[(0,a.jsx)(`span`,{className:`truncate font-medium`,children:f?.title||`Detail Dialog`}),(0,a.jsx)(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),(0,a.jsx)(i.DetailDialogSidebarContent,{children:m}),(0,a.jsx)(i.DetailDialogSidebarFooter,{children:h})]}),(0,a.jsx)(`main`,{"data-slot":`detail-dialog-main`,className:`relative h-full flex-1`,children:(0,a.jsxs)(t.t,{padding:`none`,gap:`none`,vertical:!0,align:`stretch`,className:`absolute inset-0 size-full`,children:[(0,a.jsxs)(`header`,{className:`flex w-full flex-0 items-start gap-x-2.5 border-border-weak border-b bg-card py-2.5 pr-12 pl-2`,children:[(0,a.jsx)(i.DetailDialogSidebarTrigger,{}),(0,a.jsxs)(t.t,{vertical:!0,align:`start`,padding:`none`,width:`null`,wrap:!1,className:`flex-1 gap-0`,children:[(0,a.jsx)(r.Title,{level:5,className:`line-clamp-1 truncate text-wrap`,children:l||`Detail Dialog`}),!!u&&(0,a.jsxs)(t.t,{padding:`none`,className:`relative items-center text-text-positive-weak`,children:[(0,a.jsx)(o.CalendarIcon,{size:12}),(0,a.jsx)(n.t,{showTime:!0,showHoliday:!0,date:u,format:`full`})]})]})]}),c?(0,a.jsx)(t.t,{justify:`center`,className:`inset-shadow-sm w-full flex-1 bg-muted-muted`,children:(0,a.jsx)(`div`,{className:`loader`})}):(0,a.jsx)(`section`,{"data-slot":`detail-dialog-body-loading`,className:`relative inset-shadow-sm flex flex-1 snap-y flex-col gap-0 overflow-y-auto bg-muted-bg-subtle`,children:p})]})})]}),(0,a.jsx)(s.Dialog.Close,{"data-slot":`dialog-close`,tabIndex:-1,asChild:!0,className:`absolute top-3 right-3`,children:(0,a.jsx)(`button`,{className:`flex cursor-pointer items-center justify-center rounded-[100px] p-2 text-text-positive-weak transition-colors hover:bg-muted-muted hover:text-text-positive active:bg-muted-weak active:text-text-positive-strong disabled:pointer-events-none disabled:opacity-60`,children:(0,a.jsx)(o.XIcon,{size:24})})})]})})]})})};exports.DetailDialog=c;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../button.variants-
|
|
1
|
+
import"../../button.variants-DuuH1O0_.mjs";import"../../button-6-3G2PiR.mjs";import"../../skeleton-Ba6koCVf.mjs";import{t as e}from"../../flex-BP8sTi70.mjs";import{t}from"../../date-By93kONr.mjs";import"../../tooltip-B3dTcgcc.mjs";import{Title as n}from"../../typography/title.mjs";import"../../separator-Bf0gymN4.mjs";import"../../sheet-oadGRiie.mjs";import{DetailDialogSidebarContent as r,DetailDialogSidebarFooter as i,DetailDialogSidebarHeader as a,DetailDialogSidebarMenu as o,DetailDialogSidebarMenuButton as s,DetailDialogSidebarMenuItem as c,DetailDialogSidebarTrigger as l,Sidebar as u,SidebarProvider as d}from"./components/sidebar.mjs";import{jsx as f,jsxs as p}from"react/jsx-runtime";import{CalendarIcon as m,CatIcon as h,XIcon as g}from"lucide-react";import{Dialog as _}from"radix-ui";const v=({open:v,isLoading:y,title:b,createdAt:x,onOpenChange:S,sidebar:C,children:w})=>{let{content:T,footer:E}=C||{};return f(_.Root,{"data-slot":`detail-dialog`,open:v,onOpenChange:S,children:p(_.Portal,{"data-slot":`detail-dialog-portal`,children:[f(_.Overlay,{"data-slot":`detail-dialog-overlay`,className:`data-[state=open]:fade-in-0 data-[state=closed]:fade-out-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in`}),f(`div`,{className:`fixed inset-0 z-50 flex items-center justify-center`,children:p(_.Content,{"data-slot":`dialog-content`,className:`data-[state=open]:fade-in-0 data-[state=open]:zoom-in-80 data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-80 relative z-50 grid h-full max-h-dvh w-full max-w-svw gap-4 overflow-hidden rounded-none border-none bg-background p-0 shadow-dialog outline-none duration-200 data-[state=closed]:animate-out data-[state=open]:animate-in sm:max-w-lg md:max-h-[90dvh] md:max-w-[90svw] md:rounded-lg xl:max-h-[90dvh] xl:max-w-[90svw] 2xl:max-h-[90dvh] 2xl:max-w-[90svw]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:[p(d,{children:[p(u,{collapsible:`icon`,children:[f(a,{children:f(o,{children:f(c,{children:p(s,{size:`lg`,tabIndex:-1,children:[f(`div`,{className:`flex aspect-square size-8 items-center justify-center rounded-lg bg-sidebar-primary text-sidebar-primary-foreground`,children:f(h,{size:16})}),p(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[f(`span`,{className:`truncate font-medium`,children:C?.title||`Detail Dialog`}),f(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),f(r,{children:T}),f(i,{children:E})]}),f(`main`,{"data-slot":`detail-dialog-main`,className:`relative h-full flex-1`,children:p(e,{padding:`none`,gap:`none`,vertical:!0,align:`stretch`,className:`absolute inset-0 size-full`,children:[p(`header`,{className:`flex w-full flex-0 items-start gap-x-2.5 border-border-weak border-b bg-card py-2.5 pr-12 pl-2`,children:[f(l,{}),p(e,{vertical:!0,align:`start`,padding:`none`,width:`null`,wrap:!1,className:`flex-1 gap-0`,children:[f(n,{level:5,className:`line-clamp-1 truncate text-wrap`,children:b||`Detail Dialog`}),!!x&&p(e,{padding:`none`,className:`relative items-center text-text-positive-weak`,children:[f(m,{size:12}),f(t,{showTime:!0,showHoliday:!0,date:x,format:`full`})]})]})]}),y?f(e,{justify:`center`,className:`inset-shadow-sm w-full flex-1 bg-muted-muted`,children:f(`div`,{className:`loader`})}):f(`section`,{"data-slot":`detail-dialog-body-loading`,className:`relative inset-shadow-sm flex flex-1 snap-y flex-col gap-0 overflow-y-auto bg-muted-bg-subtle`,children:w})]})})]}),f(_.Close,{"data-slot":`dialog-close`,tabIndex:-1,asChild:!0,className:`absolute top-3 right-3`,children:f(`button`,{className:`flex cursor-pointer items-center justify-center rounded-[100px] p-2 text-text-positive-weak transition-colors hover:bg-muted-muted hover:text-text-positive active:bg-muted-weak active:text-text-positive-strong disabled:pointer-events-none disabled:opacity-60`,children:f(g,{size:24})})})]})})]})})};export{v as DetailDialog};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../chunk-Bmb41Sf3.cjs`);require(`../heading-BEm5CCSE.cjs`),require(`../paragraph-
|
|
1
|
+
const e=require(`../chunk-Bmb41Sf3.cjs`);require(`../heading-BEm5CCSE.cjs`),require(`../paragraph-B72bHMf7.cjs`),require(`../button.variants-rdXrPUao.cjs`);const t=require(`../ui/alert-dialog.cjs`);let n=require(`react`),r=require(`react/jsx-runtime`),i=require(`lucide-react`);const a=({open:e,title:a,children:o,onOpenChange:s})=>{let c=(0,n.useCallback)(()=>{s?.(!1)},[s]);return(0,r.jsx)(t.AlertDialog,{open:e,onOpenChange:s,children:(0,r.jsxs)(t.AlertDialogContent,{className:`gap-8 p-4 sm:max-w-md`,children:[(0,r.jsx)(t.AlertDialogHeader,{children:(0,r.jsxs)(`div`,{className:`text-destructive flex flex-col items-center`,children:[(0,r.jsx)(i.AlertTriangleIcon,{size:42}),(0,r.jsx)(t.AlertDialogTitle,{className:`text-xl font-medium`,children:a||`An error occurred`})]})}),o,(0,r.jsx)(t.AlertDialogFooter,{children:(0,r.jsx)(t.AlertDialogAction,{className:`w-full sm:w-28`,onClick:c,children:`Close`})})]})})};exports.ErrorDialog=a;
|
|
2
2
|
//# sourceMappingURL=error-dialog.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../heading--VmdIi7C.mjs";import"../paragraph-
|
|
1
|
+
import"../heading--VmdIi7C.mjs";import"../paragraph-moBSTPmT.mjs";import"../button.variants-DuuH1O0_.mjs";import{AlertDialog as e,AlertDialogAction as t,AlertDialogContent as n,AlertDialogFooter as r,AlertDialogHeader as i,AlertDialogTitle as a}from"../ui/alert-dialog.mjs";import{useCallback as o}from"react";import{jsx as s,jsxs as c}from"react/jsx-runtime";import{AlertTriangleIcon as l}from"lucide-react";const u=({open:u,title:d,children:f,onOpenChange:p})=>{let m=o(()=>{p?.(!1)},[p]);return s(e,{open:u,onOpenChange:p,children:c(n,{className:`gap-8 p-4 sm:max-w-md`,children:[s(i,{children:c(`div`,{className:`text-destructive flex flex-col items-center`,children:[s(l,{size:42}),s(a,{className:`text-xl font-medium`,children:d||`An error occurred`})]})}),f,s(r,{children:s(t,{className:`w-full sm:w-28`,onClick:m,children:`Close`})})]})})};export{u as ErrorDialog};
|
|
2
2
|
//# sourceMappingURL=error-dialog.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../chunk-Bmb41Sf3.cjs`);require(`../heading-BEm5CCSE.cjs`),require(`../paragraph-
|
|
1
|
+
const e=require(`../chunk-Bmb41Sf3.cjs`);require(`../heading-BEm5CCSE.cjs`),require(`../paragraph-B72bHMf7.cjs`),require(`../close-D_Ge7gnP.cjs`);const t=require(`../dialog-DjRiV5vR.cjs`);let n=require(`react/jsx-runtime`);const r=({open:e,onOpenChange:r})=>(0,n.jsx)(t.t,{open:e,onOpenChange:r,children:(0,n.jsxs)(t.r,{showCloseButton:!1,className:`pointer-events-none border-none bg-transparent shadow-none outline-0 [&>div]:bg-transparent`,children:[(0,n.jsx)(t.l,{}),(0,n.jsx)(`div`,{className:`flex items-center justify-center`,children:(0,n.jsx)(`div`,{className:`loader opacity-60`})})]})});exports.LoadingDialog=r;
|
|
2
2
|
//# sourceMappingURL=loading-dialog.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../heading--VmdIi7C.mjs";import"../paragraph-
|
|
1
|
+
import"../heading--VmdIi7C.mjs";import"../paragraph-moBSTPmT.mjs";import"../close-DfuHB7kq.mjs";import{l as e,r as t,t as n}from"../dialog-CxELDK98.mjs";import{jsx as r,jsxs as i}from"react/jsx-runtime";const a=({open:a,onOpenChange:o})=>r(n,{open:a,onOpenChange:o,children:i(t,{showCloseButton:!1,className:`pointer-events-none border-none bg-transparent shadow-none outline-0 [&>div]:bg-transparent`,children:[r(e,{}),r(`div`,{className:`flex items-center justify-center`,children:r(`div`,{className:`loader opacity-60`})})]})});export{a as LoadingDialog};
|
|
2
2
|
//# sourceMappingURL=loading-dialog.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../../chunk-Bmb41Sf3.cjs`),t=require(`../../paragraph-
|
|
1
|
+
const e=require(`../../chunk-Bmb41Sf3.cjs`),t=require(`../../paragraph-B72bHMf7.cjs`);require(`../../skeleton-CHympz8k.cjs`);const n=require(`../../image-DuFv8sPr.cjs`),r=require(`../../flex-twCgWyx1.cjs`),i=require(`../../date-em5f7hCx.cjs`),a=require(`../../tooltip-DC6i1A25.cjs`);let o=require(`@customafk/react-toolkit/utils`),s=require(`react`),c=require(`react/jsx-runtime`);const l=()=>(0,c.jsx)(`div`,{className:`flex items-center gap-0 font-medium text-sm text-text-positive-muted italic`,children:(0,c.jsx)(`p`,{children:`Empty Value`})}),u=({label:e})=>e?(0,c.jsx)(`div`,{className:`w-fit rounded-full border border-border-weak px-3 py-1 font-medium text-text-positive-weak text-xs tabular-nums shadow-xs`,children:e}):(0,c.jsx)(l,{}),d=({date:e})=>e==null?(0,c.jsx)(l,{}):(0,c.jsx)(a.r,{children:(0,c.jsxs)(a.t,{children:[(0,c.jsx)(a.i,{children:(0,c.jsx)(i.t,{date:e,format:`medium`})}),(0,c.jsx)(a.n,{children:(0,c.jsx)(i.t,{date:e,format:`full`,showTime:!0,className:`font-medium text-xs`})})]})}),f=({images:e})=>!e||!e.length?(0,c.jsx)(l,{}):e.length===1?(0,c.jsx)(`div`,{className:`flex flex-wrap gap-4`,children:(0,c.jsx)(`div`,{className:`group relative size-42 rounded-sm border border-border shadow-xs`,children:(0,c.jsx)(n.t,{src:e[0].src,alt:e[0].alt,width:`100%`,height:`100%`})},e[0].id)}):(0,c.jsx)(`div`,{className:`flex flex-wrap gap-4`,children:e.map(e=>(0,c.jsx)(`div`,{className:`group relative size-16 rounded-lg border border-border shadow-xs`,children:(0,c.jsx)(n.t,{src:e.src,alt:e.alt,width:`100%`,height:`100%`})},e.id))}),p=({content:e})=>e==null?(0,c.jsx)(l,{}):(0,c.jsxs)(a.t,{children:[(0,c.jsx)(a.i,{children:(0,c.jsx)(t.t,{variant:`sm`,className:`whitespace-pre-line break-all text-start text-sm`,children:e})}),(0,c.jsx)(a.n,{align:`start`,className:`h-fit min-w-48 max-w-80 pt-4`,children:(0,c.jsxs)(`div`,{className:`flex flex-col gap-y-2`,children:[(0,c.jsx)(`p`,{className:`whitespace-pre-line text-wrap break-keep`,children:e}),(0,c.jsxs)(`p`,{className:`w-full text-end`,children:[e.toString().length,` chars`]})]})})]}),m=({name:e})=>e?(0,c.jsxs)(a.t,{children:[(0,c.jsx)(a.i,{children:(0,c.jsx)(t.t,{variant:`sm`,className:`line-clamp-2 w-full truncate`,children:e})}),(0,c.jsx)(a.n,{align:`start`,className:`h-fit min-w-48 max-w-80 pt-4`,children:(0,c.jsxs)(`div`,{className:`flex flex-col gap-y-2`,children:[(0,c.jsx)(`p`,{className:`whitespace-pre-line text-wrap break-keep`,children:e}),(0,c.jsxs)(`p`,{className:`w-full text-end`,children:[e.length,` chars`]})]})})]}):(0,c.jsx)(l,{}),h=({value:e})=>(0,c.jsxs)(a.t,{children:[(0,c.jsx)(a.i,{children:(0,c.jsx)(t.t,{variant:`sm`,children:e.replace(/(\d{3})(\d{3})(\d{4})/,`($1) $2-$3`)})}),(0,c.jsx)(a.n,{align:`start`,children:(0,c.jsx)(`p`,{className:`tabular-nums`,children:e.slice(1).replace(/(\d{2})(\d{3})(\d{4})/,`(00) (+84) ($1) $2-$3`)})})]}),g=(e,t,n)=>{let r=10**t;switch(n){case`floor`:return Math.floor(e*r)/r;case`ceil`:return Math.ceil(e*r)/r;default:return Math.round(e*r)/r}},_=(0,s.memo)(({decimalSeparator:e=`.`,groupSeparator:t=`,`,prefix:n,suffix:i,precision:a,roundingMode:u=`round`,showTrailingZeros:d=!1,size:f=`sm`,value:p=0})=>{let m=(0,s.useMemo)(()=>{let e={};return typeof a==`number`&&a>=0&&d&&(e.minimumFractionDigits=a),e.maximumFractionDigits=a,e},[a,d]),h=(0,s.useCallback)(e=>{let t=e;return typeof a==`number`&&a>=0&&(t=g(e,a,u)),t.toLocaleString(`en-US`,m)},[u,m,a]),_=(0,s.useMemo)(()=>{if(typeof p==`number`)return Number.isNaN(p)||!Number.isFinite(p)?`N/A`:h(p);if(typeof p==`string`){let e=p.trim();if(!e)return`N/A`;let t=Number(e);return Number.isNaN(t)||!Number.isFinite(t)?`N/A`:h(t)}return`N/A`},[p,h]),v=(0,s.useMemo)(()=>e===`.`&&t===`,`?_:_.replace(/,/g,t).replace(/\./g,e),[_,e,t]);return v===`0`||v===`N/A`||!v?(0,c.jsx)(l,{}):(0,c.jsxs)(r.t,{padding:`none`,className:(0,o.cn)(`font-number text-lg text-text-positive tabular-nums`,f===`xs`&&`text-xs`,f===`sm`&&`text-sm`,f===`md`&&`text-base`,f===`lg`&&`text-lg`,f===`xl`&&`text-xl`),children:[n,(0,c.jsx)(`p`,{children:v}),i]})});_.displayName=`DescriptionStatistic`;const v=({label:e,labelColSpan:t=3,children:n})=>(0,c.jsxs)(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(12, minmax(0, 1fr))`},className:`grid border-b border-b-border`,children:[(0,c.jsx)(`div`,{style:{gridColumn:`span ${t} / span ${t}`},className:`flex min-w-full items-center justify-start overflow-x-hidden text-wrap break-all border-r border-r-border bg-secondary-muted py-3 pr-2 pl-4 text-sm text-text-positive-weak tabular-nums`,children:e}),(0,c.jsx)(`div`,{style:{gridColumn:`span ${12-t} / span ${12-t}`},className:`flex flex-wrap gap-2 py-3 pr-2 pl-4 text-sm text-text-positive`,children:n})]}),y=({children:e,className:t})=>(0,c.jsx)(`div`,{"data-slot":`description-wrapper`,className:(0,o.cn)(`relative flex size-full flex-col gap-y-0 space-y-0 overflow-hidden rounded-lg border border-border bg-card shadow-xs ring-3 ring-border-muted`,t),children:e});exports.Description=y,exports.DescriptionBadge=u,exports.DescriptionDate=d,exports.DescriptionEmpty=l,exports.DescriptionImages=f,exports.DescriptionItem=v,exports.DescriptionLongText=p,exports.DescriptionName=m,exports.DescriptionNumberPhone=h,exports.DescriptionStatistic=_;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime345 from "react/jsx-runtime";
|
|
2
|
+
import * as react266 from "react";
|
|
3
3
|
|
|
4
4
|
//#region packages/components/features/descriptions/components/badge.d.ts
|
|
5
5
|
declare const DescriptionBadge: React.FC<{
|
|
@@ -51,7 +51,7 @@ type Props = {
|
|
|
51
51
|
size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
52
52
|
value: number | string | null | undefined;
|
|
53
53
|
};
|
|
54
|
-
declare const DescriptionStatistic:
|
|
54
|
+
declare const DescriptionStatistic: react266.MemoExoticComponent<({
|
|
55
55
|
decimalSeparator,
|
|
56
56
|
groupSeparator,
|
|
57
57
|
prefix: Prefix,
|
|
@@ -61,7 +61,7 @@ declare const DescriptionStatistic: react254.MemoExoticComponent<({
|
|
|
61
61
|
showTrailingZeros,
|
|
62
62
|
size,
|
|
63
63
|
value
|
|
64
|
-
}: Props) =>
|
|
64
|
+
}: Props) => react_jsx_runtime345.JSX.Element>;
|
|
65
65
|
//#endregion
|
|
66
66
|
//#region packages/components/features/descriptions/index.d.ts
|
|
67
67
|
declare const DescriptionItem: React.FC<React.PropsWithChildren<{
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"../../paragraph-
|
|
1
|
+
import{t as e}from"../../paragraph-moBSTPmT.mjs";import"../../skeleton-Ba6koCVf.mjs";import{t}from"../../image-CS_Q0WA7.mjs";import{t as n}from"../../flex-BP8sTi70.mjs";import{t as r}from"../../date-By93kONr.mjs";import{i,n as a,r as o,t as s}from"../../tooltip-B3dTcgcc.mjs";import{cn as c}from"@customafk/react-toolkit/utils";import{memo as l,useCallback as u,useMemo as d}from"react";import{jsx as f,jsxs as p}from"react/jsx-runtime";const m=()=>f(`div`,{className:`flex items-center gap-0 font-medium text-sm text-text-positive-muted italic`,children:f(`p`,{children:`Empty Value`})}),h=({label:e})=>e?f(`div`,{className:`w-fit rounded-full border border-border-weak px-3 py-1 font-medium text-text-positive-weak text-xs tabular-nums shadow-xs`,children:e}):f(m,{}),g=({date:e})=>e==null?f(m,{}):f(o,{children:p(s,{children:[f(i,{children:f(r,{date:e,format:`medium`})}),f(a,{children:f(r,{date:e,format:`full`,showTime:!0,className:`font-medium text-xs`})})]})}),_=({images:e})=>!e||!e.length?f(m,{}):e.length===1?f(`div`,{className:`flex flex-wrap gap-4`,children:f(`div`,{className:`group relative size-42 rounded-sm border border-border shadow-xs`,children:f(t,{src:e[0].src,alt:e[0].alt,width:`100%`,height:`100%`})},e[0].id)}):f(`div`,{className:`flex flex-wrap gap-4`,children:e.map(e=>f(`div`,{className:`group relative size-16 rounded-lg border border-border shadow-xs`,children:f(t,{src:e.src,alt:e.alt,width:`100%`,height:`100%`})},e.id))}),v=({content:t})=>t==null?f(m,{}):p(s,{children:[f(i,{children:f(e,{variant:`sm`,className:`whitespace-pre-line break-all text-start text-sm`,children:t})}),f(a,{align:`start`,className:`h-fit min-w-48 max-w-80 pt-4`,children:p(`div`,{className:`flex flex-col gap-y-2`,children:[f(`p`,{className:`whitespace-pre-line text-wrap break-keep`,children:t}),p(`p`,{className:`w-full text-end`,children:[t.toString().length,` chars`]})]})})]}),y=({name:t})=>t?p(s,{children:[f(i,{children:f(e,{variant:`sm`,className:`line-clamp-2 w-full truncate`,children:t})}),f(a,{align:`start`,className:`h-fit min-w-48 max-w-80 pt-4`,children:p(`div`,{className:`flex flex-col gap-y-2`,children:[f(`p`,{className:`whitespace-pre-line text-wrap break-keep`,children:t}),p(`p`,{className:`w-full text-end`,children:[t.length,` chars`]})]})})]}):f(m,{}),b=({value:t})=>p(s,{children:[f(i,{children:f(e,{variant:`sm`,children:t.replace(/(\d{3})(\d{3})(\d{4})/,`($1) $2-$3`)})}),f(a,{align:`start`,children:f(`p`,{className:`tabular-nums`,children:t.slice(1).replace(/(\d{2})(\d{3})(\d{4})/,`(00) (+84) ($1) $2-$3`)})})]}),x=(e,t,n)=>{let r=10**t;switch(n){case`floor`:return Math.floor(e*r)/r;case`ceil`:return Math.ceil(e*r)/r;default:return Math.round(e*r)/r}},S=l(({decimalSeparator:e=`.`,groupSeparator:t=`,`,prefix:r,suffix:i,precision:a,roundingMode:o=`round`,showTrailingZeros:s=!1,size:l=`sm`,value:h=0})=>{let g=d(()=>{let e={};return typeof a==`number`&&a>=0&&s&&(e.minimumFractionDigits=a),e.maximumFractionDigits=a,e},[a,s]),_=u(e=>{let t=e;return typeof a==`number`&&a>=0&&(t=x(e,a,o)),t.toLocaleString(`en-US`,g)},[o,g,a]),v=d(()=>{if(typeof h==`number`)return Number.isNaN(h)||!Number.isFinite(h)?`N/A`:_(h);if(typeof h==`string`){let e=h.trim();if(!e)return`N/A`;let t=Number(e);return Number.isNaN(t)||!Number.isFinite(t)?`N/A`:_(t)}return`N/A`},[h,_]),y=d(()=>e===`.`&&t===`,`?v:v.replace(/,/g,t).replace(/\./g,e),[v,e,t]);return y===`0`||y===`N/A`||!y?f(m,{}):p(n,{padding:`none`,className:c(`font-number text-lg text-text-positive tabular-nums`,l===`xs`&&`text-xs`,l===`sm`&&`text-sm`,l===`md`&&`text-base`,l===`lg`&&`text-lg`,l===`xl`&&`text-xl`),children:[r,f(`p`,{children:y}),i]})});S.displayName=`DescriptionStatistic`;const C=({label:e,labelColSpan:t=3,children:n})=>p(`div`,{style:{display:`grid`,gridTemplateColumns:`repeat(12, minmax(0, 1fr))`},className:`grid border-b border-b-border`,children:[f(`div`,{style:{gridColumn:`span ${t} / span ${t}`},className:`flex min-w-full items-center justify-start overflow-x-hidden text-wrap break-all border-r border-r-border bg-secondary-muted py-3 pr-2 pl-4 text-sm text-text-positive-weak tabular-nums`,children:e}),f(`div`,{style:{gridColumn:`span ${12-t} / span ${12-t}`},className:`flex flex-wrap gap-2 py-3 pr-2 pl-4 text-sm text-text-positive`,children:n})]}),w=({children:e,className:t})=>f(`div`,{"data-slot":`description-wrapper`,className:c(`relative flex size-full flex-col gap-y-0 space-y-0 overflow-hidden rounded-lg border border-border bg-card shadow-xs ring-3 ring-border-muted`,t),children:e});export{w as Description,h as DescriptionBadge,g as DescriptionDate,m as DescriptionEmpty,_ as DescriptionImages,C as DescriptionItem,v as DescriptionLongText,y as DescriptionName,b as DescriptionNumberPhone,S as DescriptionStatistic};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../heading-BEm5CCSE.cjs`),require(`../../paragraph-
|
|
1
|
+
const e=require(`../../chunk-Bmb41Sf3.cjs`);require(`../../heading-BEm5CCSE.cjs`),require(`../../paragraph-B72bHMf7.cjs`),require(`../../close-D_Ge7gnP.cjs`);const t=require(`../../dialog-DjRiV5vR.cjs`),n=require(`../../command-_zpTaaIk.cjs`);let r=require(`react/jsx-runtime`),i=require(`lucide-react`);const a=({value:e})=>(0,r.jsx)(n.o,{value:e,children:(0,r.jsxs)(`div`,{className:`size-full flex space-x-2 items-center`,children:[(0,r.jsx)(`div`,{className:`size-12 border border-border rounded-lg bg-card`}),(0,r.jsxs)(`div`,{className:`flex flex-col grow text-sm`,children:[(0,r.jsxs)(`p`,{className:`font-semibold`,children:[`Content Item for `,e]}),(0,r.jsx)(`p`,{className:`font-medium text-text-positive-weak`,children:`100.000VND`})]}),(0,r.jsx)(`button`,{className:`size-8 flex items-center justify-center grow-0`,children:(0,r.jsx)(i.ForwardIcon,{size:20,className:`text-text-positive-weak`})})]})}),o=()=>(0,r.jsxs)(n.t,{children:[(0,r.jsx)(n.a,{placeholder:`Type a command or search...`}),(0,r.jsxs)(n.s,{children:[(0,r.jsxs)(n.r,{className:`h-80 flex flex-col items-center justify-center space-y-2`,children:[(0,r.jsx)(i.Package2Icon,{strokeWidth:1,size:64,className:`text-text-positive-weak`}),(0,r.jsx)(`span`,{className:`ml-2`,children:`No results found.`})]}),(0,r.jsxs)(n.i,{heading:`Search Results`,children:[(0,r.jsx)(a,{value:`example-item-1`}),(0,r.jsx)(a,{value:`example-item-2`}),(0,r.jsx)(a,{value:`example-item-3`})]})]})]}),s=()=>(0,r.jsx)(t.t,{open:!0,children:(0,r.jsx)(t.r,{showCloseButton:!1,className:`sm:max-w-3xl`,children:(0,r.jsx)(o,{})})});exports.SearchModal=s;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime7 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region packages/components/features/search-modal/index.d.ts
|
|
4
|
-
declare const SearchModal: () =>
|
|
4
|
+
declare const SearchModal: () => react_jsx_runtime7.JSX.Element;
|
|
5
5
|
//#endregion
|
|
6
6
|
export { SearchModal };
|
|
7
7
|
//# sourceMappingURL=index.d.cts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime25 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region packages/components/features/search-modal/index.d.ts
|
|
4
|
-
declare const SearchModal: () =>
|
|
4
|
+
declare const SearchModal: () => react_jsx_runtime25.JSX.Element;
|
|
5
5
|
//#endregion
|
|
6
6
|
export { SearchModal };
|
|
7
7
|
//# sourceMappingURL=index.d.mts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../heading--VmdIi7C.mjs";import"../../paragraph-
|
|
1
|
+
import"../../heading--VmdIi7C.mjs";import"../../paragraph-moBSTPmT.mjs";import"../../close-DfuHB7kq.mjs";import{r as e,t}from"../../dialog-CxELDK98.mjs";import{a as n,i as r,o as i,r as a,s as o,t as s}from"../../command-DhBTNTqz.mjs";import{jsx as c,jsxs as l}from"react/jsx-runtime";import{ForwardIcon as u,Package2Icon as d}from"lucide-react";const f=({value:e})=>c(i,{value:e,children:l(`div`,{className:`size-full flex space-x-2 items-center`,children:[c(`div`,{className:`size-12 border border-border rounded-lg bg-card`}),l(`div`,{className:`flex flex-col grow text-sm`,children:[l(`p`,{className:`font-semibold`,children:[`Content Item for `,e]}),c(`p`,{className:`font-medium text-text-positive-weak`,children:`100.000VND`})]}),c(`button`,{className:`size-8 flex items-center justify-center grow-0`,children:c(u,{size:20,className:`text-text-positive-weak`})})]})}),p=()=>l(s,{children:[c(n,{placeholder:`Type a command or search...`}),l(o,{children:[l(a,{className:`h-80 flex flex-col items-center justify-center space-y-2`,children:[c(d,{strokeWidth:1,size:64,className:`text-text-positive-weak`}),c(`span`,{className:`ml-2`,children:`No results found.`})]}),l(r,{heading:`Search Results`,children:[c(f,{value:`example-item-1`}),c(f,{value:`example-item-2`}),c(f,{value:`example-item-3`})]})]})]}),m=()=>c(t,{open:!0,children:c(e,{showCloseButton:!1,className:`sm:max-w-3xl`,children:c(p,{})})});export{m as SearchModal};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|