@customafk/lunas-ui 0.0.38 → 0.0.40

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.
Files changed (175) hide show
  1. package/dist/{button-CuD6ftFd.d.cts → button-B3IGQSHK.d.cts} +5 -5
  2. package/dist/{button-DG4Wt4hh.d.ts → button-DDKLvzA9.d.ts} +3 -3
  3. package/dist/calendar-4R0xSc0m.js +2 -0
  4. package/dist/calendar-4R0xSc0m.js.map +1 -0
  5. package/dist/calendar-DB7j4ZPb.cjs +2 -0
  6. package/dist/calendar-DB7j4ZPb.cjs.map +1 -0
  7. package/dist/{command-DT-Vyt0F.d.cts → command-4kxRwXtl.d.cts} +12 -12
  8. package/dist/{command-D-A3HhTp.d.ts → command-Cc0A7QL7.d.ts} +12 -12
  9. package/dist/data-display/empty.d.cts +2 -2
  10. package/dist/data-display/empty.d.ts +2 -2
  11. package/dist/data-display/statistic.d.cts +2 -2
  12. package/dist/data-display/statistic.d.ts +2 -2
  13. package/dist/{dialog-bbVmbjTG.d.cts → dialog-CIrv1yaX.d.cts} +12 -12
  14. package/dist/{dialog-q2qolwKy.d.ts → dialog-DD4Dinba.d.ts} +12 -12
  15. package/dist/dialogs/detail-dialog/component/sidebar.cjs +1 -1
  16. package/dist/dialogs/detail-dialog/component/sidebar.d.cts +49 -48
  17. package/dist/dialogs/detail-dialog/component/sidebar.d.ts +49 -48
  18. package/dist/dialogs/detail-dialog/component/sidebar.js +1 -1
  19. package/dist/dialogs/detail-dialog/index.cjs +1 -1
  20. package/dist/dialogs/detail-dialog/index.cjs.map +1 -1
  21. package/dist/dialogs/detail-dialog/index.js +1 -1
  22. package/dist/dialogs/detail-dialog/index.js.map +1 -1
  23. package/dist/dialogs/form-dialog.d.cts +2 -2
  24. package/dist/dialogs/form-dialog.d.ts +2 -2
  25. package/dist/forms/combobox-field.d.cts +2 -2
  26. package/dist/forms/combobox-field.d.ts +2 -2
  27. package/dist/forms/date-field.cjs +1 -1
  28. package/dist/forms/date-field.d.cts +2 -2
  29. package/dist/forms/date-field.d.ts +2 -2
  30. package/dist/forms/date-field.js +1 -1
  31. package/dist/forms/form-wrapper.d.cts +2 -2
  32. package/dist/forms/form-wrapper.d.ts +2 -2
  33. package/dist/forms/multi-select-field.d.cts +2 -2
  34. package/dist/forms/multi-select-field.d.ts +2 -2
  35. package/dist/forms/number-field.d.cts +2 -2
  36. package/dist/forms/number-field.d.ts +2 -2
  37. package/dist/forms/password-field.d.cts +2 -2
  38. package/dist/forms/password-field.d.ts +2 -2
  39. package/dist/forms/select-field.d.cts +2 -2
  40. package/dist/forms/select-field.d.ts +2 -2
  41. package/dist/forms/switch-field.d.cts +2 -2
  42. package/dist/forms/switch-field.d.ts +2 -2
  43. package/dist/forms/text-field.d.cts +2 -2
  44. package/dist/forms/text-field.d.ts +2 -2
  45. package/dist/forms/textarea-field.d.cts +2 -2
  46. package/dist/forms/textarea-field.d.ts +2 -2
  47. package/dist/{input-xXKZJ_56.d.ts → input-CBmfFkSA.d.cts} +3 -3
  48. package/dist/{input-Cl99LGyN.d.cts → input-CVn7IbgO.d.ts} +3 -3
  49. package/dist/layouts/app-layout/index.cjs +1 -1
  50. package/dist/layouts/app-layout/index.cjs.map +1 -1
  51. package/dist/layouts/app-layout/index.d.cts +24 -24
  52. package/dist/layouts/app-layout/index.d.ts +47 -47
  53. package/dist/layouts/app-layout/index.js +1 -1
  54. package/dist/layouts/app-layout/index.js.map +1 -1
  55. package/dist/layouts/flex.d.cts +7 -7
  56. package/dist/layouts/flex.d.ts +5 -5
  57. package/dist/layouts/main/index.d.cts +4 -4
  58. package/dist/layouts/main/index.d.ts +4 -4
  59. package/dist/{separator-DUrj7nek.d.ts → separator-CKvy23ea.d.ts} +3 -3
  60. package/dist/{separator-DnlF2DdF.d.cts → separator-DHBhn7Y8.d.cts} +3 -3
  61. package/dist/sidebar-3ZtESIIQ.cjs +2 -0
  62. package/dist/sidebar-3ZtESIIQ.cjs.map +1 -0
  63. package/dist/sidebar-3aHCC_OD.js +2 -0
  64. package/dist/sidebar-3aHCC_OD.js.map +1 -0
  65. package/dist/table/index.d.cts +2 -2
  66. package/dist/table/index.d.ts +2 -2
  67. package/dist/{toggle-CtovzZAs.d.cts → toggle-BLlf4Xgl.d.cts} +3 -3
  68. package/dist/{toggle-DBzjbA4J.d.ts → toggle-Bmcoz8U-.d.ts} +5 -5
  69. package/dist/{tooltip-0nIbScX6.d.ts → tooltip-D0KLOhA8.d.ts} +6 -6
  70. package/dist/{tooltip-Dmw3-czf.d.cts → tooltip-etVeWcFC.d.cts} +6 -6
  71. package/dist/typography/paragraph.d.cts +2 -2
  72. package/dist/typography/paragraph.d.ts +2 -2
  73. package/dist/typography/title.d.cts +2 -2
  74. package/dist/typography/title.d.ts +2 -2
  75. package/dist/ui/alert-dialog.d.cts +12 -12
  76. package/dist/ui/alert-dialog.d.ts +12 -12
  77. package/dist/ui/alert.d.cts +4 -4
  78. package/dist/ui/alert.d.ts +4 -4
  79. package/dist/ui/aspect-ratio.d.cts +2 -2
  80. package/dist/ui/aspect-ratio.d.ts +2 -2
  81. package/dist/ui/avatar.d.cts +4 -4
  82. package/dist/ui/avatar.d.ts +4 -4
  83. package/dist/ui/badge.d.cts +5 -5
  84. package/dist/ui/badge.d.ts +3 -3
  85. package/dist/ui/breadcrumb.d.cts +8 -8
  86. package/dist/ui/breadcrumb.d.ts +8 -8
  87. package/dist/ui/button.d.cts +1 -1
  88. package/dist/ui/button.d.ts +1 -1
  89. package/dist/ui/calendar.cjs +1 -1
  90. package/dist/ui/calendar.d.cts +4 -4
  91. package/dist/ui/calendar.d.ts +4 -4
  92. package/dist/ui/calendar.js +1 -1
  93. package/dist/ui/card.d.cts +8 -8
  94. package/dist/ui/card.d.ts +8 -8
  95. package/dist/ui/carousel.d.cts +7 -7
  96. package/dist/ui/carousel.d.ts +7 -7
  97. package/dist/ui/collapsible.d.cts +4 -4
  98. package/dist/ui/collapsible.d.ts +4 -4
  99. package/dist/ui/command.d.cts +2 -2
  100. package/dist/ui/command.d.ts +2 -2
  101. package/dist/ui/context-menu.d.cts +16 -16
  102. package/dist/ui/context-menu.d.ts +16 -16
  103. package/dist/ui/dialog.d.cts +1 -1
  104. package/dist/ui/dialog.d.ts +1 -1
  105. package/dist/ui/dropdown-menu.d.cts +16 -16
  106. package/dist/ui/dropdown-menu.d.ts +16 -16
  107. package/dist/ui/file-uploader.d.cts +2 -2
  108. package/dist/ui/file-uploader.d.ts +2 -2
  109. package/dist/ui/form.d.cts +7 -7
  110. package/dist/ui/form.d.ts +7 -7
  111. package/dist/ui/hover-card.d.cts +4 -4
  112. package/dist/ui/hover-card.d.ts +4 -4
  113. package/dist/ui/input-otp.d.cts +5 -5
  114. package/dist/ui/input-otp.d.ts +5 -5
  115. package/dist/ui/input.d.cts +1 -1
  116. package/dist/ui/input.d.ts +1 -1
  117. package/dist/ui/inputs/search-input.d.cts +3 -3
  118. package/dist/ui/inputs/search-input.d.ts +3 -3
  119. package/dist/ui/label.d.cts +2 -2
  120. package/dist/ui/label.d.ts +2 -2
  121. package/dist/ui/menubar.d.cts +17 -17
  122. package/dist/ui/menubar.d.ts +17 -17
  123. package/dist/ui/multi-select.d.cts +2 -2
  124. package/dist/ui/multi-select.d.ts +2 -2
  125. package/dist/ui/navigation-menu.d.cts +9 -9
  126. package/dist/ui/navigation-menu.d.ts +11 -11
  127. package/dist/ui/pagination.d.cts +9 -9
  128. package/dist/ui/pagination.d.ts +9 -9
  129. package/dist/ui/popover.d.cts +5 -5
  130. package/dist/ui/popover.d.ts +5 -5
  131. package/dist/ui/progress.d.cts +2 -2
  132. package/dist/ui/progress.d.ts +2 -2
  133. package/dist/ui/radio-group.d.cts +3 -3
  134. package/dist/ui/radio-group.d.ts +3 -3
  135. package/dist/ui/resizable.d.cts +4 -4
  136. package/dist/ui/resizable.d.ts +4 -4
  137. package/dist/ui/scroll-area.d.cts +3 -3
  138. package/dist/ui/scroll-area.d.ts +3 -3
  139. package/dist/ui/select.d.cts +11 -11
  140. package/dist/ui/select.d.ts +11 -11
  141. package/dist/ui/separator.d.cts +1 -1
  142. package/dist/ui/separator.d.ts +1 -1
  143. package/dist/ui/sheet.d.cts +9 -9
  144. package/dist/ui/sheet.d.ts +9 -9
  145. package/dist/ui/sidebar.d.cts +28 -28
  146. package/dist/ui/sidebar.d.ts +28 -28
  147. package/dist/ui/skeleton.d.cts +2 -2
  148. package/dist/ui/skeleton.d.ts +2 -2
  149. package/dist/ui/slider.d.cts +2 -2
  150. package/dist/ui/slider.d.ts +2 -2
  151. package/dist/ui/sonner.d.cts +2 -2
  152. package/dist/ui/sonner.d.ts +2 -2
  153. package/dist/ui/switch.d.cts +2 -2
  154. package/dist/ui/switch.d.ts +2 -2
  155. package/dist/ui/table.d.cts +9 -9
  156. package/dist/ui/table.d.ts +9 -9
  157. package/dist/ui/tabs.d.cts +5 -5
  158. package/dist/ui/tabs.d.ts +5 -5
  159. package/dist/ui/textarea.d.ts +2 -2
  160. package/dist/ui/toggle-group.d.cts +4 -4
  161. package/dist/ui/toggle-group.d.ts +4 -4
  162. package/dist/ui/toggle.d.cts +1 -1
  163. package/dist/ui/toggle.d.ts +1 -1
  164. package/dist/ui/tooltip.d.cts +1 -1
  165. package/dist/ui/tooltip.d.ts +1 -1
  166. package/package.json +1 -5
  167. package/styles/theme.css +7 -3
  168. package/dist/calendar-CdqoCacy.js +0 -2
  169. package/dist/calendar-CdqoCacy.js.map +0 -1
  170. package/dist/calendar-Di2ItTy8.cjs +0 -2
  171. package/dist/calendar-Di2ItTy8.cjs.map +0 -1
  172. package/dist/sidebar-DQ2i5dVQ.cjs +0 -2
  173. package/dist/sidebar-DQ2i5dVQ.cjs.map +0 -1
  174. package/dist/sidebar-PJA75H5x.js +0 -2
  175. package/dist/sidebar-PJA75H5x.js.map +0 -1
@@ -1,9 +1,9 @@
1
- import { Button } from "../../../button-DG4Wt4hh.js";
2
- import { Input } from "../../../input-xXKZJ_56.js";
3
- import { Separator } from "../../../separator-DUrj7nek.js";
4
- import { TooltipContent } from "../../../tooltip-0nIbScX6.js";
1
+ import { Button } from "../../../button-DDKLvzA9.js";
2
+ import { Input } from "../../../input-CVn7IbgO.js";
3
+ import { Separator } from "../../../separator-CKvy23ea.js";
4
+ import { TooltipContent } from "../../../tooltip-D0KLOhA8.js";
5
5
  import React from "react";
6
- import * as react_jsx_runtime222 from "react/jsx-runtime";
6
+ import * as react_jsx_runtime236 from "react/jsx-runtime";
7
7
  import { VariantProps } from "class-variance-authority";
8
8
  import * as class_variance_authority_types6 from "class-variance-authority/types";
9
9
 
@@ -14,6 +14,7 @@ type SidebarContextProps = {
14
14
  setOpen: (open: boolean) => void;
15
15
  openMobile: boolean;
16
16
  setOpenMobile: (open: boolean) => void;
17
+ isMobile: boolean;
17
18
  toggleSidebar: () => void;
18
19
  };
19
20
  declare function useSidebar(): SidebarContextProps;
@@ -29,7 +30,7 @@ declare function SidebarProvider({
29
30
  defaultOpen?: boolean;
30
31
  open?: boolean;
31
32
  onOpenChange?: (open: boolean) => void;
32
- }): react_jsx_runtime222.JSX.Element;
33
+ }): react_jsx_runtime236.JSX.Element;
33
34
  declare function Sidebar({
34
35
  side,
35
36
  variant,
@@ -41,75 +42,75 @@ declare function Sidebar({
41
42
  side?: 'left' | 'right';
42
43
  variant?: 'sidebar' | 'floating' | 'inset';
43
44
  collapsible?: 'offcanvas' | 'icon' | 'none';
44
- }): react_jsx_runtime222.JSX.Element;
45
- declare function SidebarTrigger({
45
+ }): react_jsx_runtime236.JSX.Element;
46
+ declare function DetailDialogSidebarTrigger({
46
47
  className,
47
48
  onClick,
48
49
  ...props
49
- }: React.ComponentProps<typeof Button>): react_jsx_runtime222.JSX.Element;
50
- declare function SidebarRail({
50
+ }: React.ComponentProps<typeof Button>): react_jsx_runtime236.JSX.Element;
51
+ declare function DetailDialogSidebarRail({
51
52
  className,
52
53
  ...props
53
- }: React.ComponentProps<'button'>): react_jsx_runtime222.JSX.Element;
54
+ }: React.ComponentProps<'button'>): react_jsx_runtime236.JSX.Element;
54
55
  declare function SidebarInset({
55
56
  className,
56
57
  ...props
57
- }: React.ComponentProps<'main'>): react_jsx_runtime222.JSX.Element;
58
+ }: React.ComponentProps<'main'>): react_jsx_runtime236.JSX.Element;
58
59
  declare function SidebarInput({
59
60
  className,
60
61
  ...props
61
- }: React.ComponentProps<typeof Input>): react_jsx_runtime222.JSX.Element;
62
- declare function SidebarHeader({
62
+ }: React.ComponentProps<typeof Input>): react_jsx_runtime236.JSX.Element;
63
+ declare function DetailDialogSidebarHeader({
63
64
  className,
64
65
  ...props
65
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
66
- declare function SidebarFooter({
66
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
67
+ declare function DetailDialogSidebarFooter({
67
68
  className,
68
69
  ...props
69
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
70
- declare function SidebarSeparator({
70
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
71
+ declare function DetailDialogSidebarSeparator({
71
72
  className,
72
73
  ...props
73
- }: React.ComponentProps<typeof Separator>): react_jsx_runtime222.JSX.Element;
74
- declare function SidebarContent({
74
+ }: React.ComponentProps<typeof Separator>): react_jsx_runtime236.JSX.Element;
75
+ declare function DetailDialogSidebarContent({
75
76
  className,
76
77
  ...props
77
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
78
- declare function SidebarGroup({
78
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
79
+ declare function DetailDialogSidebarGroup({
79
80
  className,
80
81
  ...props
81
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
82
- declare function SidebarGroupLabel({
82
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
83
+ declare function DetailDialogSidebarGroupLabel({
83
84
  className,
84
85
  asChild,
85
86
  ...props
86
87
  }: React.ComponentProps<'div'> & {
87
88
  asChild?: boolean;
88
- }): react_jsx_runtime222.JSX.Element;
89
- declare function SidebarGroupAction({
89
+ }): react_jsx_runtime236.JSX.Element;
90
+ declare function DetailDialogSidebarGroupAction({
90
91
  className,
91
92
  asChild,
92
93
  ...props
93
94
  }: React.ComponentProps<'button'> & {
94
95
  asChild?: boolean;
95
- }): react_jsx_runtime222.JSX.Element;
96
- declare function SidebarGroupContent({
96
+ }): react_jsx_runtime236.JSX.Element;
97
+ declare function DetailDialogSidebarGroupContent({
97
98
  className,
98
99
  ...props
99
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
100
- declare function SidebarMenu({
100
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
101
+ declare function DetailDialogSidebarMenu({
101
102
  className,
102
103
  ...props
103
- }: React.ComponentProps<'ul'>): react_jsx_runtime222.JSX.Element;
104
- declare function SidebarMenuItem({
104
+ }: React.ComponentProps<'ul'>): react_jsx_runtime236.JSX.Element;
105
+ declare function DetailDialogSidebarMenuItem({
105
106
  className,
106
107
  ...props
107
- }: React.ComponentProps<'li'>): react_jsx_runtime222.JSX.Element;
108
+ }: React.ComponentProps<'li'>): react_jsx_runtime236.JSX.Element;
108
109
  declare const sidebarMenuButtonVariants: (props?: ({
109
110
  variant?: "default" | "outline" | null | undefined;
110
111
  size?: "sm" | "lg" | "default" | null | undefined;
111
112
  } & class_variance_authority_types6.ClassProp) | undefined) => string;
112
- declare function SidebarMenuButton({
113
+ declare function DetailDialogSidebarMenuButton({
113
114
  asChild,
114
115
  isActive,
115
116
  variant,
@@ -121,8 +122,8 @@ declare function SidebarMenuButton({
121
122
  asChild?: boolean;
122
123
  isActive?: boolean;
123
124
  tooltip?: string | React.ComponentProps<typeof TooltipContent>;
124
- } & VariantProps<typeof sidebarMenuButtonVariants>): react_jsx_runtime222.JSX.Element;
125
- declare function SidebarMenuAction({
125
+ } & VariantProps<typeof sidebarMenuButtonVariants>): react_jsx_runtime236.JSX.Element;
126
+ declare function DetailDialogSidebarMenuAction({
126
127
  className,
127
128
  asChild,
128
129
  showOnHover,
@@ -130,27 +131,27 @@ declare function SidebarMenuAction({
130
131
  }: React.ComponentProps<'button'> & {
131
132
  asChild?: boolean;
132
133
  showOnHover?: boolean;
133
- }): react_jsx_runtime222.JSX.Element;
134
- declare function SidebarMenuBadge({
134
+ }): react_jsx_runtime236.JSX.Element;
135
+ declare function DetailDialogSidebarMenuBadge({
135
136
  className,
136
137
  ...props
137
- }: React.ComponentProps<'div'>): react_jsx_runtime222.JSX.Element;
138
- declare function SidebarMenuSkeleton({
138
+ }: React.ComponentProps<'div'>): react_jsx_runtime236.JSX.Element;
139
+ declare function DetailDialogSidebarMenuSkeleton({
139
140
  className,
140
141
  showIcon,
141
142
  ...props
142
143
  }: React.ComponentProps<'div'> & {
143
144
  showIcon?: boolean;
144
- }): react_jsx_runtime222.JSX.Element;
145
- declare function SidebarMenuSub({
145
+ }): react_jsx_runtime236.JSX.Element;
146
+ declare function DetailDialogSidebarMenuSub({
146
147
  className,
147
148
  ...props
148
- }: React.ComponentProps<'ul'>): react_jsx_runtime222.JSX.Element;
149
- declare function SidebarMenuSubItem({
149
+ }: React.ComponentProps<'ul'>): react_jsx_runtime236.JSX.Element;
150
+ declare function DetailDialogSidebarMenuSubItem({
150
151
  className,
151
152
  ...props
152
- }: React.ComponentProps<'li'>): react_jsx_runtime222.JSX.Element;
153
- declare function SidebarMenuSubButton({
153
+ }: React.ComponentProps<'li'>): react_jsx_runtime236.JSX.Element;
154
+ declare function DetailDialogSidebarMenuSubButton({
154
155
  asChild,
155
156
  size,
156
157
  isActive,
@@ -160,7 +161,7 @@ declare function SidebarMenuSubButton({
160
161
  asChild?: boolean;
161
162
  size?: 'sm' | 'md';
162
163
  isActive?: boolean;
163
- }): react_jsx_runtime222.JSX.Element;
164
+ }): react_jsx_runtime236.JSX.Element;
164
165
  //#endregion
165
- export { Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, useSidebar };
166
+ export { DetailDialogSidebarContent, DetailDialogSidebarFooter, DetailDialogSidebarGroup, DetailDialogSidebarGroupAction, DetailDialogSidebarGroupContent, DetailDialogSidebarGroupLabel, DetailDialogSidebarHeader, DetailDialogSidebarMenu, DetailDialogSidebarMenuAction, DetailDialogSidebarMenuBadge, DetailDialogSidebarMenuButton, DetailDialogSidebarMenuItem, DetailDialogSidebarMenuSkeleton, DetailDialogSidebarMenuSub, DetailDialogSidebarMenuSubButton, DetailDialogSidebarMenuSubItem, DetailDialogSidebarRail, DetailDialogSidebarSeparator, DetailDialogSidebarTrigger, Sidebar, SidebarInput, SidebarInset, SidebarProvider, useSidebar };
166
167
  //# sourceMappingURL=sidebar.d.ts.map
@@ -1 +1 @@
1
- "use client";import"../../../utils-D9AH0PUV.js";import"../../../tooltip-CaqA5ydI.js";import"../../../button-tXV0dTFU.js";import"../../../input-DgJVc3kt.js";import"../../../separator-aLdI4FQe.js";import"../../../skeleton-BSi1n1L2.js";import{Sidebar as e,SidebarContent as t,SidebarFooter as n,SidebarGroup as r,SidebarGroupAction as i,SidebarGroupContent as a,SidebarGroupLabel as o,SidebarHeader as s,SidebarInput as c,SidebarInset as l,SidebarMenu as u,SidebarMenuAction as d,SidebarMenuBadge as f,SidebarMenuButton as p,SidebarMenuItem as m,SidebarMenuSkeleton as h,SidebarMenuSub as g,SidebarMenuSubButton as _,SidebarMenuSubItem as v,SidebarProvider as y,SidebarRail as b,SidebarSeparator as x,SidebarTrigger as S,useSidebar as C}from"../../../sidebar-PJA75H5x.js";export{e as Sidebar,t as SidebarContent,n as SidebarFooter,r as SidebarGroup,i as SidebarGroupAction,a as SidebarGroupContent,o as SidebarGroupLabel,s as SidebarHeader,c as SidebarInput,l as SidebarInset,u as SidebarMenu,d as SidebarMenuAction,f as SidebarMenuBadge,p as SidebarMenuButton,m as SidebarMenuItem,h as SidebarMenuSkeleton,g as SidebarMenuSub,_ as SidebarMenuSubButton,v as SidebarMenuSubItem,y as SidebarProvider,b as SidebarRail,x as SidebarSeparator,S as SidebarTrigger,C as useSidebar};
1
+ "use client";import"../../../utils-D9AH0PUV.js";import"../../../tooltip-CaqA5ydI.js";import"../../../button-tXV0dTFU.js";import"../../../input-DgJVc3kt.js";import"../../../separator-aLdI4FQe.js";import"../../../sheet-DqPtcv9H.js";import"../../../skeleton-BSi1n1L2.js";import"../../../use-mobile-CNVZwItd.js";import{DetailDialogSidebarContent as e,DetailDialogSidebarFooter as t,DetailDialogSidebarGroup as n,DetailDialogSidebarGroupAction as r,DetailDialogSidebarGroupContent as i,DetailDialogSidebarGroupLabel as a,DetailDialogSidebarHeader as o,DetailDialogSidebarMenu as s,DetailDialogSidebarMenuAction as c,DetailDialogSidebarMenuBadge as l,DetailDialogSidebarMenuButton as u,DetailDialogSidebarMenuItem as d,DetailDialogSidebarMenuSkeleton as f,DetailDialogSidebarMenuSub as p,DetailDialogSidebarMenuSubButton as m,DetailDialogSidebarMenuSubItem as h,DetailDialogSidebarRail as g,DetailDialogSidebarSeparator as _,DetailDialogSidebarTrigger as v,Sidebar as y,SidebarInput as b,SidebarInset as x,SidebarProvider as S,useSidebar as C}from"../../../sidebar-3aHCC_OD.js";export{e as DetailDialogSidebarContent,t as DetailDialogSidebarFooter,n as DetailDialogSidebarGroup,r as DetailDialogSidebarGroupAction,i as DetailDialogSidebarGroupContent,a as DetailDialogSidebarGroupLabel,o as DetailDialogSidebarHeader,s as DetailDialogSidebarMenu,c as DetailDialogSidebarMenuAction,l as DetailDialogSidebarMenuBadge,u as DetailDialogSidebarMenuButton,d as DetailDialogSidebarMenuItem,f as DetailDialogSidebarMenuSkeleton,p as DetailDialogSidebarMenuSub,m as DetailDialogSidebarMenuSubButton,h as DetailDialogSidebarMenuSubItem,g as DetailDialogSidebarRail,_ as DetailDialogSidebarSeparator,v as DetailDialogSidebarTrigger,y as Sidebar,b as SidebarInput,x as SidebarInset,S as SidebarProvider,C as useSidebar};
@@ -1,2 +1,2 @@
1
- const e=require(`../../chunk-CUT6urMc.cjs`);require(`../../utils-BsjVK5EW.cjs`);const t=require(`../../flex-CNA_SId-.cjs`),n=require(`../../date-nd8WkPlx.cjs`);require(`../../tooltip-D7xs4Hao.cjs`),require(`../../button-Cg9ZsZ68.cjs`);const r=require(`../../dialog-CguMVyyd.cjs`);require(`../../input-C2xQcVZP.cjs`);const i=require(`../../title-6Uosk2b4.cjs`);require(`../../separator-Cigaqna1.cjs`),require(`../../skeleton-tNlCAW9R.cjs`);const a=require(`../../sidebar-DQ2i5dVQ.cjs`),o=e.__toESM(require(`react/jsx-runtime`)),s=e.__toESM(require(`lucide-react`)),c=()=>(0,o.jsxs)(r.DialogHeader,{className:`sr-only`,children:[(0,o.jsx)(r.DialogTitle,{className:`sr-only`}),(0,o.jsx)(r.DialogDescription,{className:`sr-only`})]}),l=({children:e})=>(0,o.jsx)(`main`,{className:`relative flex h-full flex-1 flex-col`,children:(0,o.jsx)(t.Flex,{padding:`none`,gap:`none`,vertical:!0,width:`full`,align:`stretch`,className:`absolute inset-0 h-full`,children:e})}),u=({title:e,createdAt:r})=>(0,o.jsxs)(`header`,{className:`bg-card relative flex items-start gap-x-2.5 px-2 py-2.5`,children:[(0,o.jsx)(a.SidebarTrigger,{}),(0,o.jsxs)(t.Flex,{vertical:!0,align:`start`,padding:`none`,className:`flex-1`,children:[(0,o.jsx)(i.Title,{level:5,children:e||`Detail Dialog`}),(0,o.jsxs)(t.Flex,{padding:`none`,className:`text-text-positive-weak`,children:[(0,o.jsx)(s.CalendarIcon,{size:12}),!!r&&(0,o.jsx)(n.DateDisplay,{showTime:!0,showHoliday:!0,date:r,format:`full`})]})]})]}),d=({children:e})=>(0,o.jsx)(r.DialogContent,{className:`relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:e}),f=({title:e,sidebarFooter:t,children:n})=>(0,o.jsxs)(a.Sidebar,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[(0,o.jsx)(a.SidebarHeader,{children:(0,o.jsx)(a.SidebarMenu,{children:(0,o.jsx)(a.SidebarMenuItem,{children:(0,o.jsxs)(a.SidebarMenuButton,{size:`lg`,tabIndex:-1,children:[(0,o.jsx)(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:(0,o.jsx)(s.CatIcon,{size:16})}),(0,o.jsxs)(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[(0,o.jsx)(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),(0,o.jsx)(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),(0,o.jsx)(a.SidebarContent,{children:(0,o.jsx)(a.SidebarGroup,{children:n})}),t&&(0,o.jsx)(a.SidebarFooter,{children:t})]}),p=({open:e,isLoading:n=!1,sidebarTitle:i,sidebar:s,sidebarFooter:p,title:m,createdAt:h,onOpenChange:g,children:_})=>(0,o.jsx)(r.Dialog,{open:e,onOpenChange:g,children:(0,o.jsxs)(d,{children:[(0,o.jsx)(c,{}),(0,o.jsxs)(a.SidebarProvider,{className:`h-full min-h-[85svh] items-start`,children:[(0,o.jsx)(f,{title:i,sidebarFooter:p,children:s}),(0,o.jsxs)(l,{children:[(0,o.jsx)(u,{title:m,createdAt:h}),n?(0,o.jsx)(t.Flex,{justify:`center`,className:`bg-muted-muted size-full inset-shadow-sm`,children:(0,o.jsx)(`div`,{className:`loader`})}):(0,o.jsx)(`section`,{className:`bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm`,children:_})]})]})]})});exports.DetailDialog=p;
1
+ const e=require(`../../chunk-CUT6urMc.cjs`);require(`../../utils-BsjVK5EW.cjs`);const t=require(`../../flex-CNA_SId-.cjs`),n=require(`../../date-nd8WkPlx.cjs`);require(`../../tooltip-D7xs4Hao.cjs`),require(`../../button-Cg9ZsZ68.cjs`);const r=require(`../../dialog-CguMVyyd.cjs`);require(`../../input-C2xQcVZP.cjs`);const i=require(`../../title-6Uosk2b4.cjs`);require(`../../separator-Cigaqna1.cjs`),require(`../../sheet-CX3PajAc.cjs`),require(`../../skeleton-tNlCAW9R.cjs`),require(`../../use-mobile-DD7ESbjU.cjs`);const a=require(`../../sidebar-3ZtESIIQ.cjs`),o=e.__toESM(require(`react/jsx-runtime`)),s=e.__toESM(require(`lucide-react`)),c=()=>(0,o.jsxs)(r.DialogHeader,{className:`sr-only`,children:[(0,o.jsx)(r.DialogTitle,{className:`sr-only`}),(0,o.jsx)(r.DialogDescription,{className:`sr-only`})]}),l=({children:e})=>(0,o.jsx)(`main`,{className:`relative flex h-full flex-1 flex-col`,children:(0,o.jsx)(t.Flex,{padding:`none`,gap:`none`,vertical:!0,width:`full`,align:`stretch`,className:`absolute inset-0 h-full`,children:e})}),u=({title:e,createdAt:r})=>(0,o.jsxs)(`header`,{className:`bg-card relative flex items-start gap-x-2.5 px-2 py-2.5`,children:[(0,o.jsx)(a.DetailDialogSidebarTrigger,{}),(0,o.jsxs)(t.Flex,{vertical:!0,align:`start`,padding:`none`,className:`flex-1`,children:[(0,o.jsx)(i.Title,{level:5,children:e||`Detail Dialog`}),(0,o.jsxs)(t.Flex,{padding:`none`,className:`text-text-positive-weak`,children:[(0,o.jsx)(s.CalendarIcon,{size:12}),!!r&&(0,o.jsx)(n.DateDisplay,{showTime:!0,showHoliday:!0,date:r,format:`full`})]})]})]}),d=({children:e})=>(0,o.jsx)(r.DialogContent,{className:`relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:e}),f=({title:e,sidebarFooter:t,children:n})=>(0,o.jsxs)(a.Sidebar,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[(0,o.jsx)(a.DetailDialogSidebarHeader,{children:(0,o.jsx)(a.DetailDialogSidebarMenu,{children:(0,o.jsx)(a.DetailDialogSidebarMenuItem,{children:(0,o.jsxs)(a.DetailDialogSidebarMenuButton,{size:`lg`,tabIndex:-1,children:[(0,o.jsx)(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:(0,o.jsx)(s.CatIcon,{size:16})}),(0,o.jsxs)(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[(0,o.jsx)(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),(0,o.jsx)(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),(0,o.jsx)(a.DetailDialogSidebarContent,{children:(0,o.jsx)(a.DetailDialogSidebarGroup,{children:n})}),t&&(0,o.jsx)(a.DetailDialogSidebarFooter,{children:t})]}),p=({open:e,isLoading:n=!1,sidebarTitle:i,sidebar:s,sidebarFooter:p,title:m,createdAt:h,onOpenChange:g,children:_})=>(0,o.jsx)(r.Dialog,{open:e,onOpenChange:g,children:(0,o.jsxs)(d,{children:[(0,o.jsx)(c,{}),(0,o.jsxs)(a.SidebarProvider,{className:`h-full min-h-[85svh] items-start`,children:[(0,o.jsx)(f,{title:i,sidebarFooter:p,children:s}),(0,o.jsxs)(l,{children:[(0,o.jsx)(u,{title:m,createdAt:h}),n?(0,o.jsx)(t.Flex,{justify:`center`,className:`bg-muted-muted size-full inset-shadow-sm`,children:(0,o.jsx)(`div`,{className:`loader`})}):(0,o.jsx)(`section`,{className:`bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm`,children:_})]})]})]})});exports.DetailDialog=p;
2
2
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","names":["DialogHeader","DialogTitle","DialogDescription","DetailDialogMain: React.FC<React.PropsWithChildren>","Flex","DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n>","SidebarTrigger","Title","CalendarIcon","DateDisplay","DetailDialogWrapper: React.FC<React.PropsWithChildren>","DialogContent","DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>>","Sidebar","SidebarHeader","SidebarMenu","SidebarMenuItem","SidebarMenuButton","CatIcon","SidebarContent","SidebarGroup","SidebarFooter","DetailDialog: React.FC<React.PropsWithChildren<Props>>","Dialog","SidebarProvider","Flex"],"sources":["../../../packages/components/dialogs/detail-dialog/component/header.tsx","../../../packages/components/dialogs/detail-dialog/component/main.tsx","../../../packages/components/dialogs/detail-dialog/component/wrapper.tsx","../../../packages/components/dialogs/detail-dialog/index.tsx"],"sourcesContent":["import { DialogDescription, DialogHeader, DialogTitle } from '@/components/ui/dialog'\n\nexport const DetailDialogHeader = () => {\n return (\n <DialogHeader className=\"sr-only\">\n <DialogTitle className=\"sr-only\"></DialogTitle>\n <DialogDescription className=\"sr-only\"></DialogDescription>\n </DialogHeader>\n )\n}\n","import { CalendarIcon } from 'lucide-react'\n\nimport { DateDisplay } from '@/components/data-display/date'\nimport { Flex } from '@/components/layouts/flex'\nimport { Title } from '@/components/typography/title'\n\nimport { SidebarTrigger } from './sidebar'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <main className=\"relative flex h-full flex-1 flex-col\">\n <Flex padding=\"none\" gap=\"none\" vertical width=\"full\" align=\"stretch\" className=\"absolute inset-0 h-full\">\n {children}\n </Flex>\n </main>\n )\n}\n\nexport const DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n> = ({ title, createdAt }) => {\n return (\n <header className=\"bg-card relative flex items-start gap-x-2.5 px-2 py-2.5\">\n <SidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" className=\"flex-1\">\n <Title level={5}>{title || 'Detail Dialog'}</Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak\">\n <CalendarIcon size={12} />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" />}\n </Flex>\n </Flex>\n </header>\n )\n}\n","import { DialogContent } from '@/components/ui/dialog'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className=\"relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]\"\n onInteractOutside={(e) => {\n e.preventDefault()\n e.stopPropagation()\n }}\n >\n {children}\n </DialogContent>\n )\n}\n","import { CatIcon } from 'lucide-react'\n\nimport { Flex } from '@/components/layouts/flex'\nimport { Dialog } from '@/components/ui/dialog'\n\nimport { DetailDialogHeader } from './component/header'\nimport { DetailDialogMain, DetailDialogMainHeader } from './component/main'\nimport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarHeader,\n SidebarMenu,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarProvider,\n} from './component/sidebar'\nimport { DetailDialogWrapper } from './component/wrapper'\n\nconst DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>> = ({ title, sidebarFooter, children }) => {\n return (\n <Sidebar collapsible=\"icon\" className=\"shadow-nav z-20 hidden md:flex\">\n <SidebarHeader>\n <SidebarMenu>\n <SidebarMenuItem>\n <SidebarMenuButton size=\"lg\" tabIndex={-1}>\n <div className=\"bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg\">\n <CatIcon size={16} />\n </div>\n <div className=\"grid flex-1 text-left text-sm leading-tight\">\n <span className=\"truncate font-medium\">{title || 'Detail Dialog'}</span>\n <span className=\"truncate text-xs\">Lunas Enterprise</span>\n </div>\n </SidebarMenuButton>\n </SidebarMenuItem>\n </SidebarMenu>\n </SidebarHeader>\n <SidebarContent>\n <SidebarGroup>{children}</SidebarGroup>\n </SidebarContent>\n {sidebarFooter && <SidebarFooter>{sidebarFooter}</SidebarFooter>}\n </Sidebar>\n )\n}\n\ntype Props = {\n open?: boolean\n isLoading?: boolean\n sidebarTitle?: string\n sidebar?: React.ReactNode\n sidebarFooter?: React.ReactNode\n title: string\n createdAt: string | Date | number\n onOpenChange?: (open: boolean) => void | Promise<void>\n}\nexport const DetailDialog: React.FC<React.PropsWithChildren<Props>> = ({\n open,\n isLoading = false,\n sidebarTitle,\n sidebar,\n sidebarFooter,\n title,\n createdAt,\n onOpenChange,\n children,\n}) => {\n return (\n <Dialog open={open} onOpenChange={onOpenChange}>\n <DetailDialogWrapper>\n <DetailDialogHeader />\n <SidebarProvider className=\"h-full min-h-[85svh] items-start\">\n <DetailDialogSidebar title={sidebarTitle} sidebarFooter={sidebarFooter} children={sidebar} />\n <DetailDialogMain>\n <DetailDialogMainHeader title={title} createdAt={createdAt} />\n {isLoading ? (\n <Flex justify=\"center\" className=\"bg-muted-muted size-full inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"ojBAEa,OAET,EAAA,EAAA,MAACA,EAAAA,aAAAA,CAAa,UAAU,qBACtB,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,UAAU,aACvB,EAAA,EAAA,KAACC,EAAAA,kBAAAA,CAAkB,UAAU,eCEtBC,GAAuD,CAAE,eAElE,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,iDACd,EAAA,EAAA,KAACsB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,OAAO,MAAM,UAAU,UAAU,0BAC7E,eAMIpB,GAKR,CAAE,QAAO,gBAEV,EAAA,EAAA,MAAC,SAAA,CAAO,UAAU,qEAChB,EAAA,EAAA,KAACC,EAAAA,eAAAA,KACD,EAAA,EAAA,MAACmB,EAAAA,KAAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,UAAU,oBACpD,EAAA,EAAA,KAAClB,EAAAA,MAAAA,CAAM,MAAO,WAAI,GAAS,mBAC3B,EAAA,EAAA,MAACkB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,UAAU,qCAC7B,EAAA,EAAA,KAACjB,EAAAA,aAAAA,CAAa,KAAM,KACnB,CAAC,CAAC,IAAa,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,kBC7BvEC,GAA0D,CAAE,eAErE,EAAA,EAAA,KAACC,EAAAA,cAAAA,CACC,UAAU,wGACV,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCSDC,GAA+G,CAAE,QAAO,gBAAe,eAEzI,EAAA,EAAA,MAACC,EAAAA,QAAAA,CAAQ,YAAY,OAAO,UAAU,4CACpC,EAAA,EAAA,KAACC,EAAAA,cAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,gBAAAA,CAAAA,UACC,EAAA,EAAA,MAACC,EAAAA,kBAAAA,CAAkB,KAAK,KAAK,SAAU,cACrC,EAAA,EAAA,KAAC,MAAA,CAAI,UAAU,gIACb,EAAA,EAAA,KAACC,EAAAA,QAAAA,CAAQ,KAAM,QAEjB,EAAA,EAAA,MAAC,MAAA,CAAI,UAAU,yDACb,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,gCAAwB,GAAS,mBACjD,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,4BAAmB,kCAM7C,EAAA,EAAA,KAACC,EAAAA,eAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,aAAAA,CAAc,eAEhB,IAAiB,EAAA,EAAA,KAACC,EAAAA,cAAAA,CAAAA,SAAe,OAe3BC,GAA0D,CACrE,OACA,YAAY,GACZ,eACA,UACA,gBACA,QACA,YACA,eACA,eAGE,EAAA,EAAA,KAACC,EAAAA,OAAAA,CAAa,OAAoB,yBAChC,EAAA,EAAA,MAAC,EAAA,CAAA,SAAA,EACC,EAAA,EAAA,KAAC,EAAA,KACD,EAAA,EAAA,MAACC,EAAAA,gBAAAA,CAAgB,UAAU,8CACzB,EAAA,EAAA,KAAC,EAAA,CAAoB,MAAO,EAA6B,gBAAe,SAAU,KAClF,EAAA,EAAA,MAAC,EAAA,CAAA,SAAA,EACC,EAAA,EAAA,KAAC,EAAA,CAA8B,QAAkB,cAChD,GACC,EAAA,EAAA,KAACC,EAAAA,KAAAA,CAAK,QAAQ,SAAS,UAAU,qDAC/B,EAAA,EAAA,KAAC,MAAA,CAAI,UAAU,cAGjB,EAAA,EAAA,KAAC,UAAA,CAAQ,UAAU,iEAAkE"}
1
+ {"version":3,"file":"index.cjs","names":["DialogHeader","DialogTitle","DialogDescription","DetailDialogMain: React.FC<React.PropsWithChildren>","Flex","DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n>","DetailDialogSidebarTrigger","Title","CalendarIcon","DateDisplay","DetailDialogWrapper: React.FC<React.PropsWithChildren>","DialogContent","DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>>","Sidebar","DetailDialogSidebarHeader","DetailDialogSidebarMenu","DetailDialogSidebarMenuItem","DetailDialogSidebarMenuButton","CatIcon","DetailDialogSidebarContent","DetailDialogSidebarGroup","DetailDialogSidebarFooter","DetailDialog: React.FC<React.PropsWithChildren<Props>>","Dialog","SidebarProvider","Flex"],"sources":["../../../packages/components/dialogs/detail-dialog/component/header.tsx","../../../packages/components/dialogs/detail-dialog/component/main.tsx","../../../packages/components/dialogs/detail-dialog/component/wrapper.tsx","../../../packages/components/dialogs/detail-dialog/index.tsx"],"sourcesContent":["import { DialogDescription, DialogHeader, DialogTitle } from '@/components/ui/dialog'\n\nexport const DetailDialogHeader = () => {\n return (\n <DialogHeader className=\"sr-only\">\n <DialogTitle className=\"sr-only\"></DialogTitle>\n <DialogDescription className=\"sr-only\"></DialogDescription>\n </DialogHeader>\n )\n}\n","import { CalendarIcon } from 'lucide-react'\n\nimport { DateDisplay } from '@/components/data-display/date'\nimport { Flex } from '@/components/layouts/flex'\nimport { Title } from '@/components/typography/title'\n\nimport { DetailDialogSidebarTrigger } from './sidebar'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <main className=\"relative flex h-full flex-1 flex-col\">\n <Flex padding=\"none\" gap=\"none\" vertical width=\"full\" align=\"stretch\" className=\"absolute inset-0 h-full\">\n {children}\n </Flex>\n </main>\n )\n}\n\nexport const DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n> = ({ title, createdAt }) => {\n return (\n <header className=\"bg-card relative flex items-start gap-x-2.5 px-2 py-2.5\">\n <DetailDialogSidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" className=\"flex-1\">\n <Title level={5}>{title || 'Detail Dialog'}</Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak\">\n <CalendarIcon size={12} />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" />}\n </Flex>\n </Flex>\n </header>\n )\n}\n","import { DialogContent } from '@/components/ui/dialog'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className=\"relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]\"\n onInteractOutside={(e) => {\n e.preventDefault()\n e.stopPropagation()\n }}\n >\n {children}\n </DialogContent>\n )\n}\n","import { CatIcon } from 'lucide-react'\n\nimport { Flex } from '@/components/layouts/flex'\nimport { Dialog } from '@/components/ui/dialog'\n\nimport { DetailDialogHeader } from './component/header'\nimport { DetailDialogMain, DetailDialogMainHeader } from './component/main'\nimport {\n Sidebar,\n SidebarProvider,\n DetailDialogSidebarContent,\n DetailDialogSidebarFooter,\n DetailDialogSidebarGroup,\n DetailDialogSidebarHeader,\n DetailDialogSidebarMenu,\n DetailDialogSidebarMenuButton,\n DetailDialogSidebarMenuItem,\n} from './component/sidebar'\nimport { DetailDialogWrapper } from './component/wrapper'\n\nconst DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>> = ({ title, sidebarFooter, children }) => {\n return (\n <Sidebar collapsible=\"icon\" className=\"shadow-nav z-20 hidden md:flex\">\n <DetailDialogSidebarHeader>\n <DetailDialogSidebarMenu>\n <DetailDialogSidebarMenuItem>\n <DetailDialogSidebarMenuButton size=\"lg\" tabIndex={-1}>\n <div className=\"bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg\">\n <CatIcon size={16} />\n </div>\n <div className=\"grid flex-1 text-left text-sm leading-tight\">\n <span className=\"truncate font-medium\">{title || 'Detail Dialog'}</span>\n <span className=\"truncate text-xs\">Lunas Enterprise</span>\n </div>\n </DetailDialogSidebarMenuButton>\n </DetailDialogSidebarMenuItem>\n </DetailDialogSidebarMenu>\n </DetailDialogSidebarHeader>\n <DetailDialogSidebarContent>\n <DetailDialogSidebarGroup>{children}</DetailDialogSidebarGroup>\n </DetailDialogSidebarContent>\n {sidebarFooter && <DetailDialogSidebarFooter>{sidebarFooter}</DetailDialogSidebarFooter>}\n </Sidebar>\n )\n}\n\ntype Props = {\n open?: boolean\n isLoading?: boolean\n sidebarTitle?: string\n sidebar?: React.ReactNode\n sidebarFooter?: React.ReactNode\n title: string\n createdAt: string | Date | number\n onOpenChange?: (open: boolean) => void | Promise<void>\n}\nexport const DetailDialog: React.FC<React.PropsWithChildren<Props>> = ({\n open,\n isLoading = false,\n sidebarTitle,\n sidebar,\n sidebarFooter,\n title,\n createdAt,\n onOpenChange,\n children,\n}) => {\n return (\n <Dialog open={open} onOpenChange={onOpenChange}>\n <DetailDialogWrapper>\n <DetailDialogHeader />\n <SidebarProvider className=\"h-full min-h-[85svh] items-start\">\n <DetailDialogSidebar title={sidebarTitle} sidebarFooter={sidebarFooter} children={sidebar} />\n <DetailDialogMain>\n <DetailDialogMainHeader title={title} createdAt={createdAt} />\n {isLoading ? (\n <Flex justify=\"center\" className=\"bg-muted-muted size-full inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"ioBAEa,OAET,EAAA,EAAA,MAACA,EAAAA,aAAAA,CAAa,UAAU,qBACtB,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,UAAU,aACvB,EAAA,EAAA,KAACC,EAAAA,kBAAAA,CAAkB,UAAU,eCEtBC,GAAuD,CAAE,eAElE,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,iDACd,EAAA,EAAA,KAACsB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,OAAO,MAAM,UAAU,UAAU,0BAC7E,eAMIpB,GAKR,CAAE,QAAO,gBAEV,EAAA,EAAA,MAAC,SAAA,CAAO,UAAU,qEAChB,EAAA,EAAA,KAACC,EAAAA,2BAAAA,KACD,EAAA,EAAA,MAACmB,EAAAA,KAAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,UAAU,oBACpD,EAAA,EAAA,KAAClB,EAAAA,MAAAA,CAAM,MAAO,WAAI,GAAS,mBAC3B,EAAA,EAAA,MAACkB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,UAAU,qCAC7B,EAAA,EAAA,KAACjB,EAAAA,aAAAA,CAAa,KAAM,KACnB,CAAC,CAAC,IAAa,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,kBC7BvEC,GAA0D,CAAE,eAErE,EAAA,EAAA,KAACC,EAAAA,cAAAA,CACC,UAAU,wGACV,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCSDC,GAA+G,CAAE,QAAO,gBAAe,eAEzI,EAAA,EAAA,MAACC,EAAAA,QAAAA,CAAQ,YAAY,OAAO,UAAU,4CACpC,EAAA,EAAA,KAACC,EAAAA,0BAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,wBAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,4BAAAA,CAAAA,UACC,EAAA,EAAA,MAACC,EAAAA,8BAAAA,CAA8B,KAAK,KAAK,SAAU,cACjD,EAAA,EAAA,KAAC,MAAA,CAAI,UAAU,gIACb,EAAA,EAAA,KAACC,EAAAA,QAAAA,CAAQ,KAAM,QAEjB,EAAA,EAAA,MAAC,MAAA,CAAI,UAAU,yDACb,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,gCAAwB,GAAS,mBACjD,EAAA,EAAA,KAAC,OAAA,CAAK,UAAU,4BAAmB,kCAM7C,EAAA,EAAA,KAACC,EAAAA,2BAAAA,CAAAA,UACC,EAAA,EAAA,KAACC,EAAAA,yBAAAA,CAA0B,eAE5B,IAAiB,EAAA,EAAA,KAACC,EAAAA,0BAAAA,CAAAA,SAA2B,OAevCC,GAA0D,CACrE,OACA,YAAY,GACZ,eACA,UACA,gBACA,QACA,YACA,eACA,eAGE,EAAA,EAAA,KAACC,EAAAA,OAAAA,CAAa,OAAoB,yBAChC,EAAA,EAAA,MAAC,EAAA,CAAA,SAAA,EACC,EAAA,EAAA,KAAC,EAAA,KACD,EAAA,EAAA,MAACC,EAAAA,gBAAAA,CAAgB,UAAU,8CACzB,EAAA,EAAA,KAAC,EAAA,CAAoB,MAAO,EAA6B,gBAAe,SAAU,KAClF,EAAA,EAAA,MAAC,EAAA,CAAA,SAAA,EACC,EAAA,EAAA,KAAC,EAAA,CAA8B,QAAkB,cAChD,GACC,EAAA,EAAA,KAACC,EAAAA,KAAAA,CAAK,QAAQ,SAAS,UAAU,qDAC/B,EAAA,EAAA,KAAC,MAAA,CAAI,UAAU,cAGjB,EAAA,EAAA,KAAC,UAAA,CAAQ,UAAU,iEAAkE"}
@@ -1,2 +1,2 @@
1
- import"../../utils-D9AH0PUV.js";import{Flex as e}from"../../flex-ILvQrYMJ.js";import{DateDisplay as t}from"../../date-BMq_DNsv.js";import"../../tooltip-CaqA5ydI.js";import"../../button-tXV0dTFU.js";import{Dialog as n,DialogContent as r,DialogDescription as i,DialogHeader as a,DialogTitle as o}from"../../dialog-YTzM43YA.js";import"../../input-DgJVc3kt.js";import{Title as s}from"../../title-CxIwADiB.js";import"../../separator-aLdI4FQe.js";import"../../skeleton-BSi1n1L2.js";import{Sidebar as c,SidebarContent as l,SidebarFooter as u,SidebarGroup as d,SidebarHeader as f,SidebarMenu as p,SidebarMenuButton as m,SidebarMenuItem as h,SidebarProvider as g,SidebarTrigger as _}from"../../sidebar-PJA75H5x.js";import{jsx as v,jsxs as y}from"react/jsx-runtime";import{CalendarIcon as b,CatIcon as x}from"lucide-react";const S=()=>y(a,{className:`sr-only`,children:[v(o,{className:`sr-only`}),v(i,{className:`sr-only`})]}),C=({children:t})=>v(`main`,{className:`relative flex h-full flex-1 flex-col`,children:v(e,{padding:`none`,gap:`none`,vertical:!0,width:`full`,align:`stretch`,className:`absolute inset-0 h-full`,children:t})}),w=({title:n,createdAt:r})=>y(`header`,{className:`bg-card relative flex items-start gap-x-2.5 px-2 py-2.5`,children:[v(_,{}),y(e,{vertical:!0,align:`start`,padding:`none`,className:`flex-1`,children:[v(s,{level:5,children:n||`Detail Dialog`}),y(e,{padding:`none`,className:`text-text-positive-weak`,children:[v(b,{size:12}),!!r&&v(t,{showTime:!0,showHoliday:!0,date:r,format:`full`})]})]})]}),T=({children:e})=>v(r,{className:`relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:e}),E=({title:e,sidebarFooter:t,children:n})=>y(c,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[v(f,{children:v(p,{children:v(h,{children:y(m,{size:`lg`,tabIndex:-1,children:[v(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:v(x,{size:16})}),y(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[v(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),v(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),v(l,{children:v(d,{children:n})}),t&&v(u,{children:t})]}),D=({open:t,isLoading:r=!1,sidebarTitle:i,sidebar:a,sidebarFooter:o,title:s,createdAt:c,onOpenChange:l,children:u})=>v(n,{open:t,onOpenChange:l,children:y(T,{children:[v(S,{}),y(g,{className:`h-full min-h-[85svh] items-start`,children:[v(E,{title:i,sidebarFooter:o,children:a}),y(C,{children:[v(w,{title:s,createdAt:c}),r?v(e,{justify:`center`,className:`bg-muted-muted size-full inset-shadow-sm`,children:v(`div`,{className:`loader`})}):v(`section`,{className:`bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm`,children:u})]})]})]})});export{D as DetailDialog};
1
+ import"../../utils-D9AH0PUV.js";import{Flex as e}from"../../flex-ILvQrYMJ.js";import{DateDisplay as t}from"../../date-BMq_DNsv.js";import"../../tooltip-CaqA5ydI.js";import"../../button-tXV0dTFU.js";import{Dialog as n,DialogContent as r,DialogDescription as i,DialogHeader as a,DialogTitle as o}from"../../dialog-YTzM43YA.js";import"../../input-DgJVc3kt.js";import{Title as s}from"../../title-CxIwADiB.js";import"../../separator-aLdI4FQe.js";import"../../sheet-DqPtcv9H.js";import"../../skeleton-BSi1n1L2.js";import"../../use-mobile-CNVZwItd.js";import{DetailDialogSidebarContent as c,DetailDialogSidebarFooter as l,DetailDialogSidebarGroup as u,DetailDialogSidebarHeader as d,DetailDialogSidebarMenu as f,DetailDialogSidebarMenuButton as p,DetailDialogSidebarMenuItem as m,DetailDialogSidebarTrigger as h,Sidebar as g,SidebarProvider as _}from"../../sidebar-3aHCC_OD.js";import{jsx as v,jsxs as y}from"react/jsx-runtime";import{CalendarIcon as b,CatIcon as x}from"lucide-react";const S=()=>y(a,{className:`sr-only`,children:[v(o,{className:`sr-only`}),v(i,{className:`sr-only`})]}),C=({children:t})=>v(`main`,{className:`relative flex h-full flex-1 flex-col`,children:v(e,{padding:`none`,gap:`none`,vertical:!0,width:`full`,align:`stretch`,className:`absolute inset-0 h-full`,children:t})}),w=({title:n,createdAt:r})=>y(`header`,{className:`bg-card relative flex items-start gap-x-2.5 px-2 py-2.5`,children:[v(h,{}),y(e,{vertical:!0,align:`start`,padding:`none`,className:`flex-1`,children:[v(s,{level:5,children:n||`Detail Dialog`}),y(e,{padding:`none`,className:`text-text-positive-weak`,children:[v(b,{size:12}),!!r&&v(t,{showTime:!0,showHoliday:!0,date:r,format:`full`})]})]})]}),T=({children:e})=>v(r,{className:`relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]`,onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:e}),E=({title:e,sidebarFooter:t,children:n})=>y(g,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[v(d,{children:v(f,{children:v(m,{children:y(p,{size:`lg`,tabIndex:-1,children:[v(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:v(x,{size:16})}),y(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[v(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),v(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),v(c,{children:v(u,{children:n})}),t&&v(l,{children:t})]}),D=({open:t,isLoading:r=!1,sidebarTitle:i,sidebar:a,sidebarFooter:o,title:s,createdAt:c,onOpenChange:l,children:u})=>v(n,{open:t,onOpenChange:l,children:y(T,{children:[v(S,{}),y(_,{className:`h-full min-h-[85svh] items-start`,children:[v(E,{title:i,sidebarFooter:o,children:a}),y(C,{children:[v(w,{title:s,createdAt:c}),r?v(e,{justify:`center`,className:`bg-muted-muted size-full inset-shadow-sm`,children:v(`div`,{className:`loader`})}):v(`section`,{className:`bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm`,children:u})]})]})]})});export{D as DetailDialog};
2
2
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["DetailDialogMain: React.FC<React.PropsWithChildren>","DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n>","DetailDialogWrapper: React.FC<React.PropsWithChildren>","DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>>","DetailDialog: React.FC<React.PropsWithChildren<Props>>"],"sources":["../../../packages/components/dialogs/detail-dialog/component/header.tsx","../../../packages/components/dialogs/detail-dialog/component/main.tsx","../../../packages/components/dialogs/detail-dialog/component/wrapper.tsx","../../../packages/components/dialogs/detail-dialog/index.tsx"],"sourcesContent":["import { DialogDescription, DialogHeader, DialogTitle } from '@/components/ui/dialog'\n\nexport const DetailDialogHeader = () => {\n return (\n <DialogHeader className=\"sr-only\">\n <DialogTitle className=\"sr-only\"></DialogTitle>\n <DialogDescription className=\"sr-only\"></DialogDescription>\n </DialogHeader>\n )\n}\n","import { CalendarIcon } from 'lucide-react'\n\nimport { DateDisplay } from '@/components/data-display/date'\nimport { Flex } from '@/components/layouts/flex'\nimport { Title } from '@/components/typography/title'\n\nimport { SidebarTrigger } from './sidebar'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <main className=\"relative flex h-full flex-1 flex-col\">\n <Flex padding=\"none\" gap=\"none\" vertical width=\"full\" align=\"stretch\" className=\"absolute inset-0 h-full\">\n {children}\n </Flex>\n </main>\n )\n}\n\nexport const DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n> = ({ title, createdAt }) => {\n return (\n <header className=\"bg-card relative flex items-start gap-x-2.5 px-2 py-2.5\">\n <SidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" className=\"flex-1\">\n <Title level={5}>{title || 'Detail Dialog'}</Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak\">\n <CalendarIcon size={12} />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" />}\n </Flex>\n </Flex>\n </header>\n )\n}\n","import { DialogContent } from '@/components/ui/dialog'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className=\"relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]\"\n onInteractOutside={(e) => {\n e.preventDefault()\n e.stopPropagation()\n }}\n >\n {children}\n </DialogContent>\n )\n}\n","import { CatIcon } from 'lucide-react'\n\nimport { Flex } from '@/components/layouts/flex'\nimport { Dialog } from '@/components/ui/dialog'\n\nimport { DetailDialogHeader } from './component/header'\nimport { DetailDialogMain, DetailDialogMainHeader } from './component/main'\nimport {\n Sidebar,\n SidebarContent,\n SidebarFooter,\n SidebarGroup,\n SidebarHeader,\n SidebarMenu,\n SidebarMenuButton,\n SidebarMenuItem,\n SidebarProvider,\n} from './component/sidebar'\nimport { DetailDialogWrapper } from './component/wrapper'\n\nconst DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>> = ({ title, sidebarFooter, children }) => {\n return (\n <Sidebar collapsible=\"icon\" className=\"shadow-nav z-20 hidden md:flex\">\n <SidebarHeader>\n <SidebarMenu>\n <SidebarMenuItem>\n <SidebarMenuButton size=\"lg\" tabIndex={-1}>\n <div className=\"bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg\">\n <CatIcon size={16} />\n </div>\n <div className=\"grid flex-1 text-left text-sm leading-tight\">\n <span className=\"truncate font-medium\">{title || 'Detail Dialog'}</span>\n <span className=\"truncate text-xs\">Lunas Enterprise</span>\n </div>\n </SidebarMenuButton>\n </SidebarMenuItem>\n </SidebarMenu>\n </SidebarHeader>\n <SidebarContent>\n <SidebarGroup>{children}</SidebarGroup>\n </SidebarContent>\n {sidebarFooter && <SidebarFooter>{sidebarFooter}</SidebarFooter>}\n </Sidebar>\n )\n}\n\ntype Props = {\n open?: boolean\n isLoading?: boolean\n sidebarTitle?: string\n sidebar?: React.ReactNode\n sidebarFooter?: React.ReactNode\n title: string\n createdAt: string | Date | number\n onOpenChange?: (open: boolean) => void | Promise<void>\n}\nexport const DetailDialog: React.FC<React.PropsWithChildren<Props>> = ({\n open,\n isLoading = false,\n sidebarTitle,\n sidebar,\n sidebarFooter,\n title,\n createdAt,\n onOpenChange,\n children,\n}) => {\n return (\n <Dialog open={open} onOpenChange={onOpenChange}>\n <DetailDialogWrapper>\n <DetailDialogHeader />\n <SidebarProvider className=\"h-full min-h-[85svh] items-start\">\n <DetailDialogSidebar title={sidebarTitle} sidebarFooter={sidebarFooter} children={sidebar} />\n <DetailDialogMain>\n <DetailDialogMainHeader title={title} createdAt={createdAt} />\n {isLoading ? (\n <Flex justify=\"center\" className=\"bg-muted-muted size-full inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"6yBAEA,MAAa,MAET,EAAC,EAAA,CAAa,UAAU,oBACtB,EAAC,EAAA,CAAY,UAAU,YACvB,EAAC,EAAA,CAAkB,UAAU,eCEtBA,GAAuD,CAAE,cAElE,EAAC,OAAA,CAAK,UAAU,gDACd,EAAC,EAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,OAAO,MAAM,UAAU,UAAU,0BAC7E,eAMIC,GAKR,CAAE,QAAO,eAEV,EAAC,SAAA,CAAO,UAAU,oEAChB,EAAC,EAAA,IACD,EAAC,EAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,UAAU,mBACpD,EAAC,EAAA,CAAM,MAAO,WAAI,GAAS,kBAC3B,EAAC,EAAA,CAAK,QAAQ,OAAO,UAAU,oCAC7B,EAAC,EAAA,CAAa,KAAM,KACnB,CAAC,CAAC,GAAa,EAAC,EAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,kBC7BvEC,GAA0D,CAAE,cAErE,EAAC,EAAA,CACC,UAAU,wGACV,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCSDC,GAA+G,CAAE,QAAO,gBAAe,cAEzI,EAAC,EAAA,CAAQ,YAAY,OAAO,UAAU,2CACpC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAkB,KAAK,KAAK,SAAU,aACrC,EAAC,MAAA,CAAI,UAAU,+HACb,EAAC,EAAA,CAAQ,KAAM,OAEjB,EAAC,MAAA,CAAI,UAAU,wDACb,EAAC,OAAA,CAAK,UAAU,gCAAwB,GAAS,kBACjD,EAAC,OAAA,CAAK,UAAU,4BAAmB,iCAM7C,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAc,eAEhB,GAAiB,EAAC,EAAA,CAAA,SAAe,OAe3BC,GAA0D,CACrE,OACA,YAAY,GACZ,eACA,UACA,gBACA,QACA,YACA,eACA,cAGE,EAAC,EAAA,CAAa,OAAoB,wBAChC,EAAC,EAAA,CAAA,SAAA,CACC,EAAC,EAAA,IACD,EAAC,EAAA,CAAgB,UAAU,6CACzB,EAAC,EAAA,CAAoB,MAAO,EAA6B,gBAAe,SAAU,IAClF,EAAC,EAAA,CAAA,SAAA,CACC,EAAC,EAAA,CAA8B,QAAkB,cAChD,EACC,EAAC,EAAA,CAAK,QAAQ,SAAS,UAAU,oDAC/B,EAAC,MAAA,CAAI,UAAU,aAGjB,EAAC,UAAA,CAAQ,UAAU,iEAAkE"}
1
+ {"version":3,"file":"index.js","names":["DetailDialogMain: React.FC<React.PropsWithChildren>","DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n>","DetailDialogWrapper: React.FC<React.PropsWithChildren>","DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>>","DetailDialog: React.FC<React.PropsWithChildren<Props>>"],"sources":["../../../packages/components/dialogs/detail-dialog/component/header.tsx","../../../packages/components/dialogs/detail-dialog/component/main.tsx","../../../packages/components/dialogs/detail-dialog/component/wrapper.tsx","../../../packages/components/dialogs/detail-dialog/index.tsx"],"sourcesContent":["import { DialogDescription, DialogHeader, DialogTitle } from '@/components/ui/dialog'\n\nexport const DetailDialogHeader = () => {\n return (\n <DialogHeader className=\"sr-only\">\n <DialogTitle className=\"sr-only\"></DialogTitle>\n <DialogDescription className=\"sr-only\"></DialogDescription>\n </DialogHeader>\n )\n}\n","import { CalendarIcon } from 'lucide-react'\n\nimport { DateDisplay } from '@/components/data-display/date'\nimport { Flex } from '@/components/layouts/flex'\nimport { Title } from '@/components/typography/title'\n\nimport { DetailDialogSidebarTrigger } from './sidebar'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <main className=\"relative flex h-full flex-1 flex-col\">\n <Flex padding=\"none\" gap=\"none\" vertical width=\"full\" align=\"stretch\" className=\"absolute inset-0 h-full\">\n {children}\n </Flex>\n </main>\n )\n}\n\nexport const DetailDialogMainHeader: React.FC<\n React.PropsWithChildren<{\n title: string\n createdAt?: string | Date | number\n }>\n> = ({ title, createdAt }) => {\n return (\n <header className=\"bg-card relative flex items-start gap-x-2.5 px-2 py-2.5\">\n <DetailDialogSidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" className=\"flex-1\">\n <Title level={5}>{title || 'Detail Dialog'}</Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak\">\n <CalendarIcon size={12} />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" />}\n </Flex>\n </Flex>\n </header>\n )\n}\n","import { DialogContent } from '@/components/ui/dialog'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className=\"relative h-full max-h-[90svh] overflow-hidden rounded-lg border-none p-0 sm:max-w-[calc(100svw-2rem)]\"\n onInteractOutside={(e) => {\n e.preventDefault()\n e.stopPropagation()\n }}\n >\n {children}\n </DialogContent>\n )\n}\n","import { CatIcon } from 'lucide-react'\n\nimport { Flex } from '@/components/layouts/flex'\nimport { Dialog } from '@/components/ui/dialog'\n\nimport { DetailDialogHeader } from './component/header'\nimport { DetailDialogMain, DetailDialogMainHeader } from './component/main'\nimport {\n Sidebar,\n SidebarProvider,\n DetailDialogSidebarContent,\n DetailDialogSidebarFooter,\n DetailDialogSidebarGroup,\n DetailDialogSidebarHeader,\n DetailDialogSidebarMenu,\n DetailDialogSidebarMenuButton,\n DetailDialogSidebarMenuItem,\n} from './component/sidebar'\nimport { DetailDialogWrapper } from './component/wrapper'\n\nconst DetailDialogSidebar: React.FC<React.PropsWithChildren<{ title?: string; sidebarFooter?: React.ReactNode }>> = ({ title, sidebarFooter, children }) => {\n return (\n <Sidebar collapsible=\"icon\" className=\"shadow-nav z-20 hidden md:flex\">\n <DetailDialogSidebarHeader>\n <DetailDialogSidebarMenu>\n <DetailDialogSidebarMenuItem>\n <DetailDialogSidebarMenuButton size=\"lg\" tabIndex={-1}>\n <div className=\"bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg\">\n <CatIcon size={16} />\n </div>\n <div className=\"grid flex-1 text-left text-sm leading-tight\">\n <span className=\"truncate font-medium\">{title || 'Detail Dialog'}</span>\n <span className=\"truncate text-xs\">Lunas Enterprise</span>\n </div>\n </DetailDialogSidebarMenuButton>\n </DetailDialogSidebarMenuItem>\n </DetailDialogSidebarMenu>\n </DetailDialogSidebarHeader>\n <DetailDialogSidebarContent>\n <DetailDialogSidebarGroup>{children}</DetailDialogSidebarGroup>\n </DetailDialogSidebarContent>\n {sidebarFooter && <DetailDialogSidebarFooter>{sidebarFooter}</DetailDialogSidebarFooter>}\n </Sidebar>\n )\n}\n\ntype Props = {\n open?: boolean\n isLoading?: boolean\n sidebarTitle?: string\n sidebar?: React.ReactNode\n sidebarFooter?: React.ReactNode\n title: string\n createdAt: string | Date | number\n onOpenChange?: (open: boolean) => void | Promise<void>\n}\nexport const DetailDialog: React.FC<React.PropsWithChildren<Props>> = ({\n open,\n isLoading = false,\n sidebarTitle,\n sidebar,\n sidebarFooter,\n title,\n createdAt,\n onOpenChange,\n children,\n}) => {\n return (\n <Dialog open={open} onOpenChange={onOpenChange}>\n <DetailDialogWrapper>\n <DetailDialogHeader />\n <SidebarProvider className=\"h-full min-h-[85svh] items-start\">\n <DetailDialogSidebar title={sidebarTitle} sidebarFooter={sidebarFooter} children={sidebar} />\n <DetailDialogMain>\n <DetailDialogMainHeader title={title} createdAt={createdAt} />\n {isLoading ? (\n <Flex justify=\"center\" className=\"bg-muted-muted size-full inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex-1 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"k9BAEA,MAAa,MAET,EAAC,EAAA,CAAa,UAAU,oBACtB,EAAC,EAAA,CAAY,UAAU,YACvB,EAAC,EAAA,CAAkB,UAAU,eCEtBA,GAAuD,CAAE,cAElE,EAAC,OAAA,CAAK,UAAU,gDACd,EAAC,EAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,OAAO,MAAM,UAAU,UAAU,0BAC7E,eAMIC,GAKR,CAAE,QAAO,eAEV,EAAC,SAAA,CAAO,UAAU,oEAChB,EAAC,EAAA,IACD,EAAC,EAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,UAAU,mBACpD,EAAC,EAAA,CAAM,MAAO,WAAI,GAAS,kBAC3B,EAAC,EAAA,CAAK,QAAQ,OAAO,UAAU,oCAC7B,EAAC,EAAA,CAAa,KAAM,KACnB,CAAC,CAAC,GAAa,EAAC,EAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,kBC7BvEC,GAA0D,CAAE,cAErE,EAAC,EAAA,CACC,UAAU,wGACV,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCSDC,GAA+G,CAAE,QAAO,gBAAe,cAEzI,EAAC,EAAA,CAAQ,YAAY,OAAO,UAAU,2CACpC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAA8B,KAAK,KAAK,SAAU,aACjD,EAAC,MAAA,CAAI,UAAU,+HACb,EAAC,EAAA,CAAQ,KAAM,OAEjB,EAAC,MAAA,CAAI,UAAU,wDACb,EAAC,OAAA,CAAK,UAAU,gCAAwB,GAAS,kBACjD,EAAC,OAAA,CAAK,UAAU,4BAAmB,iCAM7C,EAAC,EAAA,CAAA,SACC,EAAC,EAAA,CAA0B,eAE5B,GAAiB,EAAC,EAAA,CAAA,SAA2B,OAevCC,GAA0D,CACrE,OACA,YAAY,GACZ,eACA,UACA,gBACA,QACA,YACA,eACA,cAGE,EAAC,EAAA,CAAa,OAAoB,wBAChC,EAAC,EAAA,CAAA,SAAA,CACC,EAAC,EAAA,IACD,EAAC,EAAA,CAAgB,UAAU,6CACzB,EAAC,EAAA,CAAoB,MAAO,EAA6B,gBAAe,SAAU,IAClF,EAAC,EAAA,CAAA,SAAA,CACC,EAAC,EAAA,CAA8B,QAAkB,cAChD,EACC,EAAC,EAAA,CAAK,QAAQ,SAAS,UAAU,oDAC/B,EAAC,MAAA,CAAI,UAAU,aAGjB,EAAC,UAAA,CAAQ,UAAU,iEAAkE"}
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime13 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime0 from "react/jsx-runtime";
2
2
  import { FieldValues, FormState, SubmitErrorHandler, UseFormProps } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/dialogs/form-dialog.d.ts
@@ -30,7 +30,7 @@ declare const FormDialog: <TFieldValues extends FieldValues = FieldValues>({
30
30
  onError,
31
31
  onReset,
32
32
  children
33
- }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime13.JSX.Element;
33
+ }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime0.JSX.Element;
34
34
  //#endregion
35
35
  export { FormDialog };
36
36
  //# sourceMappingURL=form-dialog.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime36 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime6 from "react/jsx-runtime";
2
2
  import { FieldValues, FormState, SubmitErrorHandler, UseFormProps } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/dialogs/form-dialog.d.ts
@@ -30,7 +30,7 @@ declare const FormDialog: <TFieldValues extends FieldValues = FieldValues>({
30
30
  onError,
31
31
  onReset,
32
32
  children
33
- }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime36.JSX.Element;
33
+ }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime6.JSX.Element;
34
34
  //#endregion
35
35
  export { FormDialog };
36
36
  //# sourceMappingURL=form-dialog.d.ts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime14 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime4 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/combobox-field.d.ts
@@ -22,7 +22,7 @@ declare const ComboboxField: <TFieldValues extends FieldValues = FieldValues>({
22
22
  description,
23
23
  options,
24
24
  onAddNewItem
25
- }: Props<TFieldValues>) => react_jsx_runtime14.JSX.Element;
25
+ }: Props<TFieldValues>) => react_jsx_runtime4.JSX.Element;
26
26
  //#endregion
27
27
  export { ComboboxField };
28
28
  //# sourceMappingURL=combobox-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime51 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime11 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/combobox-field.d.ts
@@ -22,7 +22,7 @@ declare const ComboboxField: <TFieldValues extends FieldValues = FieldValues>({
22
22
  description,
23
23
  options,
24
24
  onAddNewItem
25
- }: Props<TFieldValues>) => react_jsx_runtime51.JSX.Element;
25
+ }: Props<TFieldValues>) => react_jsx_runtime11.JSX.Element;
26
26
  //#endregion
27
27
  export { ComboboxField };
28
28
  //# sourceMappingURL=combobox-field.d.ts.map
@@ -1,2 +1,2 @@
1
- "use client";const e=require(`../chunk-CUT6urMc.cjs`),t=require(`../utils-BsjVK5EW.cjs`),n=require(`../button-Cg9ZsZ68.cjs`);require(`../label-B_2ZQn0X.cjs`);const r=require(`../form-CU-tlomS.cjs`),i=require(`../popover-DCcPvdz2.cjs`),a=require(`../calendar-Di2ItTy8.cjs`),o=e.__toESM(require(`react/jsx-runtime`)),s=e.__toESM(require(`date-fns`)),c=e.__toESM(require(`lucide-react`)),l=({name:e,label:l=`Date Field`,placeholder:u=`Select a date`,description:d=``,isShowErrorMsg:f=!1})=>(0,o.jsx)(r.FormField,{name:e,render:({field:e})=>(0,o.jsxs)(r.FormItem,{className:`w-full`,children:[(0,o.jsx)(r.FormLabel,{children:l}),(0,o.jsxs)(i.Popover,{modal:!0,children:[(0,o.jsx)(i.PopoverTrigger,{asChild:!0,children:(0,o.jsx)(r.FormControl,{children:(0,o.jsxs)(n.Button,{variant:`outline`,className:t.cn(`w-full pl-3 text-left font-normal`,`outline-border-weak font-normal`,`hover:outline-border`,`data-[state=open]:text-text-positive-muted`,`data-[state=open]:outline-1`,`data-[state=open]:outline-primary-strong`,`data-[state=open]:ring-primary-weak`,`data-[state=open]:ring-4`,`focus:border-primary-strong`,`focus:ring-4`,`focus:ring-primary-weak`,`focus:outline-1`,`focus:outline-primary-strong`,!e.value&&`text-muted-foreground`),children:[e.value?(0,s.format)(e.value,`PPP`):(0,o.jsxs)(`span`,{children:[` `,u||`Pick a date`]}),(0,o.jsx)(c.CalendarIcon,{className:`text-text-positive-weak ml-auto size-4`})]})})}),(0,o.jsx)(i.PopoverContent,{className:`w-auto p-0`,align:`start`,children:(0,o.jsx)(a.Calendar,{mode:`single`,selected:e.value,onSelect:t=>{e.onChange(t?.toISOString())},captionLayout:`dropdown`,disabled:e=>e<new Date(`2022-01-01`)})})]}),!!d&&(0,o.jsx)(r.FormDescription,{children:d}),f&&(0,o.jsx)(r.FormMessage,{})]})});exports.DateField=l;
1
+ "use client";const e=require(`../chunk-CUT6urMc.cjs`),t=require(`../utils-BsjVK5EW.cjs`),n=require(`../button-Cg9ZsZ68.cjs`);require(`../label-B_2ZQn0X.cjs`);const r=require(`../form-CU-tlomS.cjs`),i=require(`../popover-DCcPvdz2.cjs`),a=require(`../calendar-DB7j4ZPb.cjs`),o=e.__toESM(require(`react/jsx-runtime`)),s=e.__toESM(require(`date-fns`)),c=e.__toESM(require(`lucide-react`)),l=({name:e,label:l=`Date Field`,placeholder:u=`Select a date`,description:d=``,isShowErrorMsg:f=!1})=>(0,o.jsx)(r.FormField,{name:e,render:({field:e})=>(0,o.jsxs)(r.FormItem,{className:`w-full`,children:[(0,o.jsx)(r.FormLabel,{children:l}),(0,o.jsxs)(i.Popover,{modal:!0,children:[(0,o.jsx)(i.PopoverTrigger,{asChild:!0,children:(0,o.jsx)(r.FormControl,{children:(0,o.jsxs)(n.Button,{variant:`outline`,className:t.cn(`w-full pl-3 text-left font-normal`,`outline-border-weak font-normal`,`hover:outline-border`,`data-[state=open]:text-text-positive-muted`,`data-[state=open]:outline-1`,`data-[state=open]:outline-primary-strong`,`data-[state=open]:ring-primary-weak`,`data-[state=open]:ring-4`,`focus:border-primary-strong`,`focus:ring-4`,`focus:ring-primary-weak`,`focus:outline-1`,`focus:outline-primary-strong`,!e.value&&`text-muted-foreground`),children:[e.value?(0,s.format)(e.value,`PPP`):(0,o.jsxs)(`span`,{children:[` `,u||`Pick a date`]}),(0,o.jsx)(c.CalendarIcon,{className:`text-text-positive-weak ml-auto size-4`})]})})}),(0,o.jsx)(i.PopoverContent,{className:`w-auto p-0`,align:`start`,children:(0,o.jsx)(a.Calendar,{mode:`single`,selected:e.value,onSelect:t=>{e.onChange(t?.toISOString())},captionLayout:`dropdown`,disabled:e=>e<new Date(`2022-01-01`)})})]}),!!d&&(0,o.jsx)(r.FormDescription,{children:d}),f&&(0,o.jsx)(r.FormMessage,{})]})});exports.DateField=l;
2
2
  //# sourceMappingURL=date-field.cjs.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime41 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime2 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/date-field.d.ts
@@ -16,7 +16,7 @@ declare const DateField: <TFieldValues extends FieldValues = FieldValues>({
16
16
  placeholder,
17
17
  description,
18
18
  isShowErrorMsg
19
- }: Props<TFieldValues>) => react_jsx_runtime41.JSX.Element;
19
+ }: Props<TFieldValues>) => react_jsx_runtime2.JSX.Element;
20
20
  //#endregion
21
21
  export { DateField };
22
22
  //# sourceMappingURL=date-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime53 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime2 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/date-field.d.ts
@@ -16,7 +16,7 @@ declare const DateField: <TFieldValues extends FieldValues = FieldValues>({
16
16
  placeholder,
17
17
  description,
18
18
  isShowErrorMsg
19
- }: Props<TFieldValues>) => react_jsx_runtime53.JSX.Element;
19
+ }: Props<TFieldValues>) => react_jsx_runtime2.JSX.Element;
20
20
  //#endregion
21
21
  export { DateField };
22
22
  //# sourceMappingURL=date-field.d.ts.map
@@ -1,2 +1,2 @@
1
- "use client";import{cn as e}from"../utils-D9AH0PUV.js";import{Button as t}from"../button-tXV0dTFU.js";import"../label-D1XmKlc3.js";import{FormControl as n,FormDescription as r,FormField as i,FormItem as a,FormLabel as o,FormMessage as s}from"../form-63w5ez51.js";import{Popover as c,PopoverContent as l,PopoverTrigger as u}from"../popover-CTFp7ZXi.js";import{Calendar as d}from"../calendar-CdqoCacy.js";import{jsx as f,jsxs as p}from"react/jsx-runtime";import{format as m}from"date-fns";import{CalendarIcon as h}from"lucide-react";const g=({name:g,label:_=`Date Field`,placeholder:v=`Select a date`,description:y=``,isShowErrorMsg:b=!1})=>f(i,{name:g,render:({field:i})=>p(a,{className:`w-full`,children:[f(o,{children:_}),p(c,{modal:!0,children:[f(u,{asChild:!0,children:f(n,{children:p(t,{variant:`outline`,className:e(`w-full pl-3 text-left font-normal`,`outline-border-weak font-normal`,`hover:outline-border`,`data-[state=open]:text-text-positive-muted`,`data-[state=open]:outline-1`,`data-[state=open]:outline-primary-strong`,`data-[state=open]:ring-primary-weak`,`data-[state=open]:ring-4`,`focus:border-primary-strong`,`focus:ring-4`,`focus:ring-primary-weak`,`focus:outline-1`,`focus:outline-primary-strong`,!i.value&&`text-muted-foreground`),children:[i.value?m(i.value,`PPP`):p(`span`,{children:[` `,v||`Pick a date`]}),f(h,{className:`text-text-positive-weak ml-auto size-4`})]})})}),f(l,{className:`w-auto p-0`,align:`start`,children:f(d,{mode:`single`,selected:i.value,onSelect:e=>{i.onChange(e?.toISOString())},captionLayout:`dropdown`,disabled:e=>e<new Date(`2022-01-01`)})})]}),!!y&&f(r,{children:y}),b&&f(s,{})]})});export{g as DateField};
1
+ "use client";import{cn as e}from"../utils-D9AH0PUV.js";import{Button as t}from"../button-tXV0dTFU.js";import"../label-D1XmKlc3.js";import{FormControl as n,FormDescription as r,FormField as i,FormItem as a,FormLabel as o,FormMessage as s}from"../form-63w5ez51.js";import{Popover as c,PopoverContent as l,PopoverTrigger as u}from"../popover-CTFp7ZXi.js";import{Calendar as d}from"../calendar-4R0xSc0m.js";import{jsx as f,jsxs as p}from"react/jsx-runtime";import{format as m}from"date-fns";import{CalendarIcon as h}from"lucide-react";const g=({name:g,label:_=`Date Field`,placeholder:v=`Select a date`,description:y=``,isShowErrorMsg:b=!1})=>f(i,{name:g,render:({field:i})=>p(a,{className:`w-full`,children:[f(o,{children:_}),p(c,{modal:!0,children:[f(u,{asChild:!0,children:f(n,{children:p(t,{variant:`outline`,className:e(`w-full pl-3 text-left font-normal`,`outline-border-weak font-normal`,`hover:outline-border`,`data-[state=open]:text-text-positive-muted`,`data-[state=open]:outline-1`,`data-[state=open]:outline-primary-strong`,`data-[state=open]:ring-primary-weak`,`data-[state=open]:ring-4`,`focus:border-primary-strong`,`focus:ring-4`,`focus:ring-primary-weak`,`focus:outline-1`,`focus:outline-primary-strong`,!i.value&&`text-muted-foreground`),children:[i.value?m(i.value,`PPP`):p(`span`,{children:[` `,v||`Pick a date`]}),f(h,{className:`text-text-positive-weak ml-auto size-4`})]})})}),f(l,{className:`w-auto p-0`,align:`start`,children:f(d,{mode:`single`,selected:i.value,onSelect:e=>{i.onChange(e?.toISOString())},captionLayout:`dropdown`,disabled:e=>e<new Date(`2022-01-01`)})})]}),!!y&&f(r,{children:y}),b&&f(s,{})]})});export{g as DateField};
2
2
  //# sourceMappingURL=date-field.js.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime45 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime12 from "react/jsx-runtime";
2
2
  import React from "react";
3
3
  import { FieldValues, FormState, SubmitErrorHandler, UseFormProps } from "react-hook-form";
4
4
 
@@ -19,7 +19,7 @@ declare const FormWrapper: <TFieldValues extends FieldValues = FieldValues>({
19
19
  onError,
20
20
  onSubcribe,
21
21
  children
22
- }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime45.JSX.Element;
22
+ }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime12.JSX.Element;
23
23
  //#endregion
24
24
  export { FormWrapper };
25
25
  //# sourceMappingURL=form-wrapper.d.cts.map
@@ -1,5 +1,5 @@
1
1
  import React from "react";
2
- import * as react_jsx_runtime84 from "react/jsx-runtime";
2
+ import * as react_jsx_runtime7 from "react/jsx-runtime";
3
3
  import { FieldValues, FormState, SubmitErrorHandler, UseFormProps } from "react-hook-form";
4
4
 
5
5
  //#region packages/components/forms/form-wrapper.d.ts
@@ -19,7 +19,7 @@ declare const FormWrapper: <TFieldValues extends FieldValues = FieldValues>({
19
19
  onError,
20
20
  onSubcribe,
21
21
  children
22
- }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime84.JSX.Element;
22
+ }: React.PropsWithChildren<Props<TFieldValues>>) => react_jsx_runtime7.JSX.Element;
23
23
  //#endregion
24
24
  export { FormWrapper };
25
25
  //# sourceMappingURL=form-wrapper.d.ts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime56 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime6 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/multi-select-field.d.ts
@@ -24,7 +24,7 @@ declare const MultiSelectField: <TFieldValues extends FieldValues = FieldValues>
24
24
  description,
25
25
  options,
26
26
  onAdd
27
- }: Props<TFieldValues>) => react_jsx_runtime56.JSX.Element;
27
+ }: Props<TFieldValues>) => react_jsx_runtime6.JSX.Element;
28
28
  //#endregion
29
29
  export { MultiSelectField };
30
30
  //# sourceMappingURL=multi-select-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime102 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime31 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/multi-select-field.d.ts
@@ -24,7 +24,7 @@ declare const MultiSelectField: <TFieldValues extends FieldValues = FieldValues>
24
24
  description,
25
25
  options,
26
26
  onAdd
27
- }: Props<TFieldValues>) => react_jsx_runtime102.JSX.Element;
27
+ }: Props<TFieldValues>) => react_jsx_runtime31.JSX.Element;
28
28
  //#endregion
29
29
  export { MultiSelectField };
30
30
  //# sourceMappingURL=multi-select-field.d.ts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime46 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime10 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/number-field.d.ts
@@ -22,7 +22,7 @@ declare const NumberField: <TFieldValues extends FieldValues = FieldValues>({
22
22
  unitText,
23
23
  description,
24
24
  onValueChange
25
- }: Props<TFieldValues>) => react_jsx_runtime46.JSX.Element;
25
+ }: Props<TFieldValues>) => react_jsx_runtime10.JSX.Element;
26
26
  //#endregion
27
27
  export { NumberField };
28
28
  //# sourceMappingURL=number-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime113 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime3 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/number-field.d.ts
@@ -22,7 +22,7 @@ declare const NumberField: <TFieldValues extends FieldValues = FieldValues>({
22
22
  unitText,
23
23
  description,
24
24
  onValueChange
25
- }: Props<TFieldValues>) => react_jsx_runtime113.JSX.Element;
25
+ }: Props<TFieldValues>) => react_jsx_runtime3.JSX.Element;
26
26
  //#endregion
27
27
  export { NumberField };
28
28
  //# sourceMappingURL=number-field.d.ts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime43 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime11 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/password-field.d.ts
@@ -17,7 +17,7 @@ declare const PasswordField: <TFieldValues extends FieldValues = FieldValues>({
17
17
  isShowErrorMsg,
18
18
  description,
19
19
  onValueChange
20
- }: Props<TFieldValues>) => react_jsx_runtime43.JSX.Element;
20
+ }: Props<TFieldValues>) => react_jsx_runtime11.JSX.Element;
21
21
  //#endregion
22
22
  export { PasswordField };
23
23
  //# sourceMappingURL=password-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime50 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime5 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/password-field.d.ts
@@ -17,7 +17,7 @@ declare const PasswordField: <TFieldValues extends FieldValues = FieldValues>({
17
17
  isShowErrorMsg,
18
18
  description,
19
19
  onValueChange
20
- }: Props<TFieldValues>) => react_jsx_runtime50.JSX.Element;
20
+ }: Props<TFieldValues>) => react_jsx_runtime5.JSX.Element;
21
21
  //#endregion
22
22
  export { PasswordField };
23
23
  //# sourceMappingURL=password-field.d.ts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime44 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime15 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/select-field.d.ts
@@ -27,7 +27,7 @@ declare const SelectField: <TFieldValues extends FieldValues = FieldValues>({
27
27
  isShowErrorMsg,
28
28
  description,
29
29
  className
30
- }: Props<TFieldValues>) => react_jsx_runtime44.JSX.Element;
30
+ }: Props<TFieldValues>) => react_jsx_runtime15.JSX.Element;
31
31
  //#endregion
32
32
  export { SelectField };
33
33
  //# sourceMappingURL=select-field.d.cts.map
@@ -1,4 +1,4 @@
1
- import * as react_jsx_runtime140 from "react/jsx-runtime";
1
+ import * as react_jsx_runtime4 from "react/jsx-runtime";
2
2
  import { FieldPath, FieldValues } from "react-hook-form";
3
3
 
4
4
  //#region packages/components/forms/select-field.d.ts
@@ -27,7 +27,7 @@ declare const SelectField: <TFieldValues extends FieldValues = FieldValues>({
27
27
  isShowErrorMsg,
28
28
  description,
29
29
  className
30
- }: Props<TFieldValues>) => react_jsx_runtime140.JSX.Element;
30
+ }: Props<TFieldValues>) => react_jsx_runtime4.JSX.Element;
31
31
  //#endregion
32
32
  export { SelectField };
33
33
  //# sourceMappingURL=select-field.d.ts.map