@customafk/lunas-ui 0.0.41 → 0.0.42
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-B3IGQSHK.d.cts → button-BRHXAci1.d.cts} +5 -5
- package/dist/{button-DDKLvzA9.d.ts → button-DzJicXG7.d.ts} +3 -3
- package/dist/{command-4kxRwXtl.d.cts → command-BwIrZXxZ.d.cts} +12 -12
- package/dist/{command-Cc0A7QL7.d.ts → command-DklaqE_y.d.ts} +12 -12
- package/dist/data-display/country.cjs +1 -1
- package/dist/data-display/country.js +1 -1
- package/dist/data-display/data-list.cjs +1 -1
- package/dist/data-display/data-list.js +1 -1
- package/dist/data-display/empty.cjs +1 -1
- package/dist/data-display/empty.d.cts +2 -2
- package/dist/data-display/empty.js +1 -1
- package/dist/data-display/statistic.cjs +1 -1
- package/dist/data-display/statistic.d.cts +2 -2
- package/dist/data-display/statistic.js +1 -1
- package/dist/{dialog-CIrv1yaX.d.cts → dialog-CPq4R2AI.d.cts} +12 -12
- package/dist/{dialog-DD4Dinba.d.ts → dialog-sMaQeOv6.d.ts} +12 -12
- package/dist/dialogs/detail-dialog/component/sidebar.cjs +1 -1
- package/dist/dialogs/detail-dialog/component/sidebar.d.cts +4 -4
- package/dist/dialogs/detail-dialog/component/sidebar.d.ts +4 -4
- package/dist/dialogs/detail-dialog/component/sidebar.js +1 -1
- package/dist/dialogs/detail-dialog/index.cjs +1 -1
- package/dist/dialogs/detail-dialog/index.cjs.map +1 -1
- package/dist/dialogs/detail-dialog/index.js +1 -1
- package/dist/dialogs/detail-dialog/index.js.map +1 -1
- package/dist/dialogs/form-dialog.d.cts +2 -2
- package/dist/dialogs/form-dialog.d.ts +2 -2
- package/dist/flex-CbkTJwcD.js +2 -0
- package/dist/flex-CbkTJwcD.js.map +1 -0
- package/dist/flex-DnFMe9kC.cjs +2 -0
- package/dist/flex-DnFMe9kC.cjs.map +1 -0
- package/dist/forms/combobox-field.d.cts +2 -2
- package/dist/forms/combobox-field.d.ts +2 -2
- package/dist/forms/date-field.d.cts +2 -2
- package/dist/forms/date-field.d.ts +2 -2
- package/dist/forms/form-wrapper.d.cts +2 -2
- package/dist/forms/form-wrapper.d.ts +2 -2
- package/dist/forms/multi-select-field.d.ts +2 -2
- package/dist/forms/number-field.d.cts +2 -2
- package/dist/forms/number-field.d.ts +2 -2
- package/dist/forms/password-field.d.cts +2 -2
- package/dist/forms/password-field.d.ts +2 -2
- package/dist/forms/select-field.d.cts +2 -2
- package/dist/forms/select-field.d.ts +2 -2
- package/dist/forms/switch-field.d.cts +2 -2
- package/dist/forms/switch-field.d.ts +2 -2
- package/dist/forms/text-field.cjs +1 -1
- package/dist/forms/text-field.d.cts +2 -2
- package/dist/forms/text-field.d.ts +2 -2
- package/dist/forms/text-field.js +1 -1
- package/dist/forms/textarea-field.d.cts +2 -2
- package/dist/forms/textarea-field.d.ts +2 -2
- package/dist/{input-CBmfFkSA.d.cts → input-6yLVoluZ.d.cts} +3 -3
- package/dist/{input-CVn7IbgO.d.ts → input-I8ngYGaj.d.ts} +3 -3
- package/dist/layouts/app-layout/index.cjs +1 -1
- package/dist/layouts/app-layout/index.cjs.map +1 -1
- package/dist/layouts/app-layout/index.d.cts +3 -3
- package/dist/layouts/app-layout/index.d.ts +3 -3
- package/dist/layouts/app-layout/index.js +1 -1
- package/dist/layouts/app-layout/index.js.map +1 -1
- package/dist/layouts/flex.cjs +1 -1
- package/dist/layouts/flex.d.cts +5 -5
- package/dist/layouts/flex.d.ts +1 -1
- package/dist/layouts/flex.js +1 -1
- package/dist/layouts/main/index.d.cts +4 -4
- package/dist/{separator-DHBhn7Y8.d.cts → separator-DnxxU9GH.d.cts} +3 -3
- package/dist/{separator-CKvy23ea.d.ts → separator-F-PIApnV.d.ts} +3 -3
- package/dist/sidebar-B8vyPsEX.cjs +2 -0
- package/dist/sidebar-B8vyPsEX.cjs.map +1 -0
- package/dist/sidebar-CUDxSzag.js +2 -0
- package/dist/sidebar-CUDxSzag.js.map +1 -0
- package/dist/table/index.cjs +1 -1
- package/dist/table/index.d.cts +2 -2
- package/dist/table/index.d.ts +2 -2
- package/dist/table/index.js +1 -1
- package/dist/{toggle-BLlf4Xgl.d.cts → toggle-DH9IssyE.d.ts} +4 -4
- package/dist/{toggle-Bmcoz8U-.d.ts → toggle-Das7hUtB.d.cts} +4 -4
- package/dist/{tooltip-etVeWcFC.d.cts → tooltip-Dkh_dieJ.d.cts} +6 -6
- package/dist/{tooltip-D0KLOhA8.d.ts → tooltip-GgIQS_wc.d.ts} +6 -6
- package/dist/typography/paragraph.d.cts +2 -2
- package/dist/typography/paragraph.d.ts +2 -2
- package/dist/typography/title.d.cts +2 -2
- package/dist/typography/title.d.ts +2 -2
- package/dist/ui/alert-dialog.d.cts +12 -12
- package/dist/ui/alert-dialog.d.ts +12 -12
- package/dist/ui/alert.d.cts +4 -4
- package/dist/ui/alert.d.ts +6 -6
- package/dist/ui/aspect-ratio.d.cts +2 -2
- package/dist/ui/avatar.d.cts +4 -4
- package/dist/ui/avatar.d.ts +4 -4
- package/dist/ui/badge.d.cts +4 -4
- package/dist/ui/badge.d.ts +4 -4
- package/dist/ui/breadcrumb.d.cts +8 -8
- package/dist/ui/breadcrumb.d.ts +8 -8
- package/dist/ui/button.d.cts +1 -1
- package/dist/ui/button.d.ts +1 -1
- package/dist/ui/calendar.d.cts +4 -4
- package/dist/ui/calendar.d.ts +4 -4
- package/dist/ui/card.d.cts +8 -8
- package/dist/ui/card.d.ts +8 -8
- package/dist/ui/carousel.d.cts +7 -7
- package/dist/ui/carousel.d.ts +7 -7
- package/dist/ui/collapsible.d.cts +4 -4
- package/dist/ui/collapsible.d.ts +4 -4
- package/dist/ui/command.d.cts +2 -2
- package/dist/ui/command.d.ts +2 -2
- package/dist/ui/context-menu.d.cts +16 -16
- package/dist/ui/context-menu.d.ts +16 -16
- package/dist/ui/dialog.d.cts +1 -1
- package/dist/ui/dialog.d.ts +1 -1
- package/dist/ui/dropdown-menu.d.cts +16 -16
- package/dist/ui/dropdown-menu.d.ts +16 -16
- package/dist/ui/file-uploader.d.cts +2 -2
- package/dist/ui/file-uploader.d.ts +2 -2
- package/dist/ui/form.d.cts +7 -7
- package/dist/ui/form.d.ts +7 -7
- package/dist/ui/hover-card.d.cts +4 -4
- package/dist/ui/hover-card.d.ts +4 -4
- package/dist/ui/input-otp.d.cts +5 -5
- package/dist/ui/input-otp.d.ts +5 -5
- package/dist/ui/input.d.cts +1 -1
- package/dist/ui/input.d.ts +1 -1
- package/dist/ui/inputs/search-input.d.cts +1 -1
- package/dist/ui/inputs/search-input.d.ts +1 -1
- package/dist/ui/label.d.cts +2 -2
- package/dist/ui/label.d.ts +2 -2
- package/dist/ui/menubar.d.cts +17 -17
- package/dist/ui/menubar.d.ts +17 -17
- package/dist/ui/multi-select.d.cts +2 -2
- package/dist/ui/multi-select.d.ts +2 -2
- package/dist/ui/navigation-menu.d.cts +9 -9
- package/dist/ui/navigation-menu.d.ts +9 -9
- package/dist/ui/pagination.d.cts +9 -9
- package/dist/ui/pagination.d.ts +9 -9
- package/dist/ui/popover.d.cts +5 -5
- package/dist/ui/popover.d.ts +5 -5
- package/dist/ui/progress.d.cts +2 -2
- package/dist/ui/progress.d.ts +2 -2
- package/dist/ui/radio-group.d.cts +3 -3
- package/dist/ui/radio-group.d.ts +3 -3
- package/dist/ui/resizable.d.cts +4 -4
- package/dist/ui/resizable.d.ts +4 -4
- package/dist/ui/scroll-area.d.cts +3 -3
- package/dist/ui/scroll-area.d.ts +3 -3
- package/dist/ui/select.d.cts +11 -11
- package/dist/ui/select.d.ts +11 -11
- package/dist/ui/separator.d.cts +1 -1
- package/dist/ui/separator.d.ts +1 -1
- package/dist/ui/sheet.d.cts +9 -9
- package/dist/ui/sheet.d.ts +9 -9
- package/dist/ui/sidebar.d.cts +30 -30
- package/dist/ui/sidebar.d.ts +30 -30
- package/dist/ui/skeleton.d.cts +2 -2
- package/dist/ui/skeleton.d.ts +2 -2
- package/dist/ui/slider.d.cts +2 -2
- package/dist/ui/slider.d.ts +2 -2
- package/dist/ui/sonner.d.ts +2 -2
- package/dist/ui/switch.d.cts +2 -2
- package/dist/ui/switch.d.ts +2 -2
- package/dist/ui/table.d.cts +9 -9
- package/dist/ui/table.d.ts +9 -9
- package/dist/ui/tabs.d.cts +5 -5
- package/dist/ui/tabs.d.ts +5 -5
- package/dist/ui/textarea.d.cts +2 -2
- package/dist/ui/textarea.d.ts +2 -2
- package/dist/ui/toggle-group.d.cts +4 -4
- package/dist/ui/toggle-group.d.ts +4 -4
- package/dist/ui/toggle.d.cts +1 -1
- package/dist/ui/toggle.d.ts +1 -1
- package/dist/ui/tooltip.d.cts +1 -1
- package/dist/ui/tooltip.d.ts +1 -1
- package/package.json +1 -1
- package/dist/flex-CNA_SId-.cjs +0 -2
- package/dist/flex-CNA_SId-.cjs.map +0 -1
- package/dist/flex-ILvQrYMJ.js +0 -2
- package/dist/flex-ILvQrYMJ.js.map +0 -1
- package/dist/sidebar-3ZtESIIQ.cjs +0 -2
- package/dist/sidebar-3ZtESIIQ.cjs.map +0 -1
- package/dist/sidebar-3aHCC_OD.js +0 -2
- package/dist/sidebar-3aHCC_OD.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime41 from "react/jsx-runtime";
|
|
2
|
+
import * as class_variance_authority_types1 from "class-variance-authority/types";
|
|
3
3
|
import { VariantProps } from "class-variance-authority";
|
|
4
4
|
|
|
5
5
|
//#region packages/components/ui/button.d.ts
|
|
@@ -7,7 +7,7 @@ declare const buttonVariants: (props?: ({
|
|
|
7
7
|
variant?: "default" | "outline" | "ghost" | "link" | null | undefined;
|
|
8
8
|
color?: "muted" | "primary" | "secondary" | "success" | "important" | "info" | "warning" | "danger" | null | undefined;
|
|
9
9
|
size?: "sm" | "lg" | "default" | "icon" | null | undefined;
|
|
10
|
-
} &
|
|
10
|
+
} & class_variance_authority_types1.ClassProp) | undefined) => string;
|
|
11
11
|
declare function Button({
|
|
12
12
|
className,
|
|
13
13
|
variant,
|
|
@@ -20,7 +20,7 @@ declare function Button({
|
|
|
20
20
|
}: React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
|
|
21
21
|
asChild?: boolean;
|
|
22
22
|
isLoading?: boolean;
|
|
23
|
-
}):
|
|
23
|
+
}): react_jsx_runtime41.JSX.Element;
|
|
24
24
|
//#endregion
|
|
25
25
|
export { Button, buttonVariants };
|
|
26
|
-
//# sourceMappingURL=button-
|
|
26
|
+
//# sourceMappingURL=button-BRHXAci1.d.cts.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime94 from "react/jsx-runtime";
|
|
2
2
|
import { VariantProps } from "class-variance-authority";
|
|
3
3
|
import * as class_variance_authority_types2 from "class-variance-authority/types";
|
|
4
4
|
|
|
@@ -20,7 +20,7 @@ declare function Button({
|
|
|
20
20
|
}: React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
|
|
21
21
|
asChild?: boolean;
|
|
22
22
|
isLoading?: boolean;
|
|
23
|
-
}):
|
|
23
|
+
}): react_jsx_runtime94.JSX.Element;
|
|
24
24
|
//#endregion
|
|
25
25
|
export { Button, buttonVariants };
|
|
26
|
-
//# sourceMappingURL=button-
|
|
26
|
+
//# sourceMappingURL=button-DzJicXG7.d.ts.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { Dialog } from "./dialog-
|
|
2
|
-
import * as
|
|
1
|
+
import { Dialog } from "./dialog-CPq4R2AI.cjs";
|
|
2
|
+
import * as react_jsx_runtime60 from "react/jsx-runtime";
|
|
3
3
|
import { Command } from "cmdk";
|
|
4
4
|
|
|
5
5
|
//#region packages/components/ui/command.d.ts
|
|
6
6
|
declare function Command$1({
|
|
7
7
|
className,
|
|
8
8
|
...props
|
|
9
|
-
}: React.ComponentProps<typeof Command>):
|
|
9
|
+
}: React.ComponentProps<typeof Command>): react_jsx_runtime60.JSX.Element;
|
|
10
10
|
declare function CommandDialog({
|
|
11
11
|
title,
|
|
12
12
|
description,
|
|
@@ -19,34 +19,34 @@ declare function CommandDialog({
|
|
|
19
19
|
description?: string;
|
|
20
20
|
className?: string;
|
|
21
21
|
showCloseButton?: boolean;
|
|
22
|
-
}):
|
|
22
|
+
}): react_jsx_runtime60.JSX.Element;
|
|
23
23
|
declare function CommandInput({
|
|
24
24
|
className,
|
|
25
25
|
...props
|
|
26
|
-
}: React.ComponentProps<typeof Command.Input>):
|
|
26
|
+
}: React.ComponentProps<typeof Command.Input>): react_jsx_runtime60.JSX.Element;
|
|
27
27
|
declare function CommandList({
|
|
28
28
|
className,
|
|
29
29
|
...props
|
|
30
|
-
}: React.ComponentProps<typeof Command.List>):
|
|
30
|
+
}: React.ComponentProps<typeof Command.List>): react_jsx_runtime60.JSX.Element;
|
|
31
31
|
declare function CommandEmpty({
|
|
32
32
|
...props
|
|
33
|
-
}: React.ComponentProps<typeof Command.Empty>):
|
|
33
|
+
}: React.ComponentProps<typeof Command.Empty>): react_jsx_runtime60.JSX.Element;
|
|
34
34
|
declare function CommandGroup({
|
|
35
35
|
className,
|
|
36
36
|
...props
|
|
37
|
-
}: React.ComponentProps<typeof Command.Group>):
|
|
37
|
+
}: React.ComponentProps<typeof Command.Group>): react_jsx_runtime60.JSX.Element;
|
|
38
38
|
declare function CommandSeparator({
|
|
39
39
|
className,
|
|
40
40
|
...props
|
|
41
|
-
}: React.ComponentProps<typeof Command.Separator>):
|
|
41
|
+
}: React.ComponentProps<typeof Command.Separator>): react_jsx_runtime60.JSX.Element;
|
|
42
42
|
declare function CommandItem({
|
|
43
43
|
className,
|
|
44
44
|
...props
|
|
45
|
-
}: React.ComponentProps<typeof Command.Item>):
|
|
45
|
+
}: React.ComponentProps<typeof Command.Item>): react_jsx_runtime60.JSX.Element;
|
|
46
46
|
declare function CommandShortcut({
|
|
47
47
|
className,
|
|
48
48
|
...props
|
|
49
|
-
}: React.ComponentProps<'span'>):
|
|
49
|
+
}: React.ComponentProps<'span'>): react_jsx_runtime60.JSX.Element;
|
|
50
50
|
//#endregion
|
|
51
51
|
export { Command$1 as Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut };
|
|
52
|
-
//# sourceMappingURL=command-
|
|
52
|
+
//# sourceMappingURL=command-BwIrZXxZ.d.cts.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { Dialog } from "./dialog-
|
|
2
|
-
import * as
|
|
1
|
+
import { Dialog } from "./dialog-sMaQeOv6.js";
|
|
2
|
+
import * as react_jsx_runtime57 from "react/jsx-runtime";
|
|
3
3
|
import { Command } from "cmdk";
|
|
4
4
|
|
|
5
5
|
//#region packages/components/ui/command.d.ts
|
|
6
6
|
declare function Command$1({
|
|
7
7
|
className,
|
|
8
8
|
...props
|
|
9
|
-
}: React.ComponentProps<typeof Command>):
|
|
9
|
+
}: React.ComponentProps<typeof Command>): react_jsx_runtime57.JSX.Element;
|
|
10
10
|
declare function CommandDialog({
|
|
11
11
|
title,
|
|
12
12
|
description,
|
|
@@ -19,34 +19,34 @@ declare function CommandDialog({
|
|
|
19
19
|
description?: string;
|
|
20
20
|
className?: string;
|
|
21
21
|
showCloseButton?: boolean;
|
|
22
|
-
}):
|
|
22
|
+
}): react_jsx_runtime57.JSX.Element;
|
|
23
23
|
declare function CommandInput({
|
|
24
24
|
className,
|
|
25
25
|
...props
|
|
26
|
-
}: React.ComponentProps<typeof Command.Input>):
|
|
26
|
+
}: React.ComponentProps<typeof Command.Input>): react_jsx_runtime57.JSX.Element;
|
|
27
27
|
declare function CommandList({
|
|
28
28
|
className,
|
|
29
29
|
...props
|
|
30
|
-
}: React.ComponentProps<typeof Command.List>):
|
|
30
|
+
}: React.ComponentProps<typeof Command.List>): react_jsx_runtime57.JSX.Element;
|
|
31
31
|
declare function CommandEmpty({
|
|
32
32
|
...props
|
|
33
|
-
}: React.ComponentProps<typeof Command.Empty>):
|
|
33
|
+
}: React.ComponentProps<typeof Command.Empty>): react_jsx_runtime57.JSX.Element;
|
|
34
34
|
declare function CommandGroup({
|
|
35
35
|
className,
|
|
36
36
|
...props
|
|
37
|
-
}: React.ComponentProps<typeof Command.Group>):
|
|
37
|
+
}: React.ComponentProps<typeof Command.Group>): react_jsx_runtime57.JSX.Element;
|
|
38
38
|
declare function CommandSeparator({
|
|
39
39
|
className,
|
|
40
40
|
...props
|
|
41
|
-
}: React.ComponentProps<typeof Command.Separator>):
|
|
41
|
+
}: React.ComponentProps<typeof Command.Separator>): react_jsx_runtime57.JSX.Element;
|
|
42
42
|
declare function CommandItem({
|
|
43
43
|
className,
|
|
44
44
|
...props
|
|
45
|
-
}: React.ComponentProps<typeof Command.Item>):
|
|
45
|
+
}: React.ComponentProps<typeof Command.Item>): react_jsx_runtime57.JSX.Element;
|
|
46
46
|
declare function CommandShortcut({
|
|
47
47
|
className,
|
|
48
48
|
...props
|
|
49
|
-
}: React.ComponentProps<'span'>):
|
|
49
|
+
}: React.ComponentProps<'span'>): react_jsx_runtime57.JSX.Element;
|
|
50
50
|
//#endregion
|
|
51
51
|
export { Command$1 as Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut };
|
|
52
|
-
//# sourceMappingURL=command-
|
|
52
|
+
//# sourceMappingURL=command-DklaqE_y.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../types-CrbWxjnp.cjs`),n=require(`../flex-
|
|
1
|
+
const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../types-CrbWxjnp.cjs`),n=require(`../flex-DnFMe9kC.cjs`),r=require(`../paragraph-DcRBcRhQ.cjs`),i=e.__toESM(require(`react`)),a=e.__toESM(require(`react/jsx-runtime`)),o=e.__toESM(require(`react-country-flag`)),s=({country:e})=>{let s=i.default.useMemo(()=>({[t.ECountry.VIETNAM]:`VN`,[t.ECountry.USA]:`US`,[t.ECountry.JAPAN]:`JP`,[t.ECountry.CHINA]:`CN`,[t.ECountry.KOREA]:`KR`,[t.ECountry.SINGAPORE]:`SG`,[t.ECountry.MALAYSIA]:`MY`,[t.ECountry.INDONESIA]:`ID`,[t.ECountry.TAIWAN]:`TW`,[t.ECountry.THAILAND]:`TH`}),[]);return e?(0,a.jsxs)(n.Flex,{padding:`none`,className:`h-4 px-1`,children:[(0,a.jsx)(o.default,{svg:!0,countryCode:e?s[e]:`VN`,className:`emojiFlag border`}),(0,a.jsxs)(r.Paragraph,{variant:`sm`,children:[e===t.ECountry.VIETNAM&&`Vietnam`,e===t.ECountry.USA&&`America`,e===t.ECountry.JAPAN&&`Japan`,e===t.ECountry.CHINA&&`China`,e===t.ECountry.KOREA&&`Korea`,e===t.ECountry.SINGAPORE&&`Singapore`,e===t.ECountry.MALAYSIA&&`Malaysia`,e===t.ECountry.INDONESIA&&`Indonesia`,e===t.ECountry.TAIWAN&&`Taiwan`,e===t.ECountry.THAILAND&&`Thailand`]})]}):(0,a.jsx)(n.Flex,{padding:`none`,className:`h-4 px-1`,children:(0,a.jsx)(r.Paragraph,{variant:`muted`,className:`line-clamp-1 text-xs`,children:`No country`})})};exports.CountryDisplay=s;
|
|
2
2
|
//# sourceMappingURL=country.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../utils-D9AH0PUV.js";import{ECountry as e}from"../types-DaIHddx7.js";import{Flex as t}from"../flex-
|
|
1
|
+
import"../utils-D9AH0PUV.js";import{ECountry as e}from"../types-DaIHddx7.js";import{Flex as t}from"../flex-CbkTJwcD.js";import{Paragraph as n}from"../paragraph-B4cQhLhW.js";import r from"react";import{jsx as i,jsxs as a}from"react/jsx-runtime";import o from"react-country-flag";const s=({country:s})=>{let c=r.useMemo(()=>({[e.VIETNAM]:`VN`,[e.USA]:`US`,[e.JAPAN]:`JP`,[e.CHINA]:`CN`,[e.KOREA]:`KR`,[e.SINGAPORE]:`SG`,[e.MALAYSIA]:`MY`,[e.INDONESIA]:`ID`,[e.TAIWAN]:`TW`,[e.THAILAND]:`TH`}),[]);return s?a(t,{padding:`none`,className:`h-4 px-1`,children:[i(o,{svg:!0,countryCode:s?c[s]:`VN`,className:`emojiFlag border`}),a(n,{variant:`sm`,children:[s===e.VIETNAM&&`Vietnam`,s===e.USA&&`America`,s===e.JAPAN&&`Japan`,s===e.CHINA&&`China`,s===e.KOREA&&`Korea`,s===e.SINGAPORE&&`Singapore`,s===e.MALAYSIA&&`Malaysia`,s===e.INDONESIA&&`Indonesia`,s===e.TAIWAN&&`Taiwan`,s===e.THAILAND&&`Thailand`]})]}):i(t,{padding:`none`,className:`h-4 px-1`,children:i(n,{variant:`muted`,className:`line-clamp-1 text-xs`,children:`No country`})})};export{s as CountryDisplay};
|
|
2
2
|
//# sourceMappingURL=country.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../flex-
|
|
1
|
+
const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../flex-DnFMe9kC.cjs`),n=e.__toESM(require(`react/jsx-runtime`)),r=({children:e})=>(0,n.jsx)(t.Flex,{vertical:!0,padding:`none`,gap:`md`,width:`full`,children:e}),i=({label:e,value:r,minLabelWidth:i=`120px`})=>(0,n.jsxs)(t.Flex,{align:`center`,justify:`start`,width:`full`,padding:`none`,gap:`md`,children:[(0,n.jsx)(`div`,{style:{minWidth:i},className:`text-text-positive-weak text-sm`,children:e}),(0,n.jsx)(`div`,{className:`text-text-positive text-sm`,children:r})]});exports.DataList=r,exports.DataListItem=i;
|
|
2
2
|
//# sourceMappingURL=data-list.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../utils-D9AH0PUV.js";import{Flex as e}from"../flex-
|
|
1
|
+
import"../utils-D9AH0PUV.js";import{Flex as e}from"../flex-CbkTJwcD.js";import{jsx as t,jsxs as n}from"react/jsx-runtime";const r=({children:n})=>t(e,{vertical:!0,padding:`none`,gap:`md`,width:`full`,children:n}),i=({label:r,value:i,minLabelWidth:a=`120px`})=>n(e,{align:`center`,justify:`start`,width:`full`,padding:`none`,gap:`md`,children:[t(`div`,{style:{minWidth:a},className:`text-text-positive-weak text-sm`,children:r}),t(`div`,{className:`text-text-positive text-sm`,children:i})]});export{r as DataList,i as DataListItem};
|
|
2
2
|
//# sourceMappingURL=data-list.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../flex-
|
|
1
|
+
"use client";const e=require(`../chunk-CUT6urMc.cjs`);require(`../utils-BsjVK5EW.cjs`);const t=require(`../flex-DnFMe9kC.cjs`),n=e.__toESM(require(`react/jsx-runtime`)),r=e.__toESM(require(`lucide-react`)),i=()=>(0,n.jsxs)(t.Flex,{vertical:!0,justify:`center`,align:`center`,gap:`sm`,className:`text-text-positive-muted size-full`,children:[(0,n.jsx)(r.PackageOpenIcon,{size:52,strokeWidth:1}),(0,n.jsx)(`p`,{className:`text-sm`,children:`Không có dữ liệu nào để hiển thị.`})]});exports.EmptyDisplay=i;
|
|
2
2
|
//# sourceMappingURL=empty.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime0 from "react/jsx-runtime";
|
|
2
2
|
|
|
3
3
|
//#region packages/components/data-display/empty.d.ts
|
|
4
|
-
declare const EmptyDisplay: () =>
|
|
4
|
+
declare const EmptyDisplay: () => react_jsx_runtime0.JSX.Element;
|
|
5
5
|
//#endregion
|
|
6
6
|
export { EmptyDisplay };
|
|
7
7
|
//# sourceMappingURL=empty.d.cts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";import"../utils-D9AH0PUV.js";import{Flex as e}from"../flex-
|
|
1
|
+
"use client";import"../utils-D9AH0PUV.js";import{Flex as e}from"../flex-CbkTJwcD.js";import{jsx as t,jsxs as n}from"react/jsx-runtime";import{PackageOpenIcon as r}from"lucide-react";const i=()=>n(e,{vertical:!0,justify:`center`,align:`center`,gap:`sm`,className:`text-text-positive-muted size-full`,children:[t(r,{size:52,strokeWidth:1}),t(`p`,{className:`text-sm`,children:`Không có dữ liệu nào để hiển thị.`})]});export{i as EmptyDisplay};
|
|
2
2
|
//# sourceMappingURL=empty.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const e=require(`../chunk-CUT6urMc.cjs`),t=require(`../utils-BsjVK5EW.cjs`),n=require(`../flex-
|
|
1
|
+
const e=require(`../chunk-CUT6urMc.cjs`),t=require(`../utils-BsjVK5EW.cjs`),n=require(`../flex-DnFMe9kC.cjs`),r=e.__toESM(require(`react`)),i=e.__toESM(require(`react/jsx-runtime`)),a=r.default.memo(({decimalSeparator:e=`.`,groupSeparator:a=`,`,prefix:o,suffix:s,precision:c,roundingMode:l=`round`,showTrailingZeros:u=!1,size:d=`lg`,value:f})=>{let p=r.default.useCallback((e,t)=>{let n=Math.pow(10,t);switch(l){case`floor`:return Math.floor(e*n)/n;case`ceil`:return Math.ceil(e*n)/n;case`round`:default:return Math.round(e*n)/n}},[l]),m=r.default.useMemo(()=>{let e={};return typeof c==`number`&&c>=0&&(u&&(e.minimumFractionDigits=c),e.maximumFractionDigits=c),e},[c,u]),h=r.default.useCallback(e=>{let t=e;return typeof c==`number`&&c>=0&&(t=p(e,c)),t.toLocaleString(`en-US`,m)},[p,m,c]),g=r.default.useMemo(()=>{if(typeof f==`number`)return isNaN(f)||!isFinite(f)?`N/A`:h(f);if(typeof f==`string`){let e=f.trim();if(!e)return`N/A`;let t=Number(e);return isNaN(t)||!isFinite(t)?`N/A`:h(t)}return`N/A`},[f,h]),_=r.default.useMemo(()=>e===`.`&&a===`,`?g:g.replace(/,/g,a).replace(/\./g,e),[g,e,a]);return(0,i.jsxs)(n.Flex,{padding:`none`,className:t.cn(`text-secondary-foreground font-number text-lg`,d===`xs`&&`text-xs`,d===`sm`&&`text-sm`,d===`md`&&`text-base`,d===`lg`&&`text-lg`,d===`xl`&&`text-xl`),children:[o,(0,i.jsx)(`p`,{children:_}),s]})});a.displayName=`Statistic`,exports.Statistic=a;
|
|
2
2
|
//# sourceMappingURL=statistic.cjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime199 from "react/jsx-runtime";
|
|
2
2
|
import React from "react";
|
|
3
3
|
|
|
4
4
|
//#region packages/components/data-display/statistic.d.ts
|
|
@@ -23,7 +23,7 @@ declare const Statistic: React.MemoExoticComponent<({
|
|
|
23
23
|
showTrailingZeros,
|
|
24
24
|
size,
|
|
25
25
|
value
|
|
26
|
-
}: Props) =>
|
|
26
|
+
}: Props) => react_jsx_runtime199.JSX.Element>;
|
|
27
27
|
//#endregion
|
|
28
28
|
export { Statistic };
|
|
29
29
|
//# sourceMappingURL=statistic.d.cts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{cn as e}from"../utils-D9AH0PUV.js";import{Flex as t}from"../flex-
|
|
1
|
+
import{cn as e}from"../utils-D9AH0PUV.js";import{Flex as t}from"../flex-CbkTJwcD.js";import n from"react";import{jsx as r,jsxs as i}from"react/jsx-runtime";const a=n.memo(({decimalSeparator:a=`.`,groupSeparator:o=`,`,prefix:s,suffix:c,precision:l,roundingMode:u=`round`,showTrailingZeros:d=!1,size:f=`lg`,value:p})=>{let m=n.useCallback((e,t)=>{let n=Math.pow(10,t);switch(u){case`floor`:return Math.floor(e*n)/n;case`ceil`:return Math.ceil(e*n)/n;case`round`:default:return Math.round(e*n)/n}},[u]),h=n.useMemo(()=>{let e={};return typeof l==`number`&&l>=0&&(d&&(e.minimumFractionDigits=l),e.maximumFractionDigits=l),e},[l,d]),g=n.useCallback(e=>{let t=e;return typeof l==`number`&&l>=0&&(t=m(e,l)),t.toLocaleString(`en-US`,h)},[m,h,l]),_=n.useMemo(()=>{if(typeof p==`number`)return isNaN(p)||!isFinite(p)?`N/A`:g(p);if(typeof p==`string`){let e=p.trim();if(!e)return`N/A`;let t=Number(e);return isNaN(t)||!isFinite(t)?`N/A`:g(t)}return`N/A`},[p,g]),v=n.useMemo(()=>a===`.`&&o===`,`?_:_.replace(/,/g,o).replace(/\./g,a),[_,a,o]);return i(t,{padding:`none`,className:e(`text-secondary-foreground font-number text-lg`,f===`xs`&&`text-xs`,f===`sm`&&`text-sm`,f===`md`&&`text-base`,f===`lg`&&`text-lg`,f===`xl`&&`text-xl`),children:[s,r(`p`,{children:v}),c]})});a.displayName=`Statistic`;export{a as Statistic};
|
|
2
2
|
//# sourceMappingURL=statistic.js.map
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime84 from "react/jsx-runtime";
|
|
2
2
|
import { Dialog } from "radix-ui";
|
|
3
3
|
|
|
4
4
|
//#region packages/components/ui/dialog.d.ts
|
|
5
5
|
declare function Dialog$1({
|
|
6
6
|
...props
|
|
7
|
-
}: React.ComponentProps<typeof Dialog.Root>):
|
|
7
|
+
}: React.ComponentProps<typeof Dialog.Root>): react_jsx_runtime84.JSX.Element;
|
|
8
8
|
declare function DialogTrigger({
|
|
9
9
|
...props
|
|
10
|
-
}: React.ComponentProps<typeof Dialog.Trigger>):
|
|
10
|
+
}: React.ComponentProps<typeof Dialog.Trigger>): react_jsx_runtime84.JSX.Element;
|
|
11
11
|
declare function DialogPortal({
|
|
12
12
|
...props
|
|
13
|
-
}: React.ComponentProps<typeof Dialog.Portal>):
|
|
13
|
+
}: React.ComponentProps<typeof Dialog.Portal>): react_jsx_runtime84.JSX.Element;
|
|
14
14
|
declare function DialogClose({
|
|
15
15
|
...props
|
|
16
|
-
}: React.ComponentProps<typeof Dialog.Close>):
|
|
16
|
+
}: React.ComponentProps<typeof Dialog.Close>): react_jsx_runtime84.JSX.Element;
|
|
17
17
|
declare function DialogOverlay({
|
|
18
18
|
className,
|
|
19
19
|
...props
|
|
20
|
-
}: React.ComponentProps<typeof Dialog.Overlay>):
|
|
20
|
+
}: React.ComponentProps<typeof Dialog.Overlay>): react_jsx_runtime84.JSX.Element;
|
|
21
21
|
declare function DialogContent({
|
|
22
22
|
className,
|
|
23
23
|
children,
|
|
@@ -25,23 +25,23 @@ declare function DialogContent({
|
|
|
25
25
|
...props
|
|
26
26
|
}: React.ComponentProps<typeof Dialog.Content> & {
|
|
27
27
|
showCloseButton?: boolean;
|
|
28
|
-
}):
|
|
28
|
+
}): react_jsx_runtime84.JSX.Element;
|
|
29
29
|
declare function DialogHeader({
|
|
30
30
|
className,
|
|
31
31
|
...props
|
|
32
|
-
}: React.ComponentProps<'div'>):
|
|
32
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime84.JSX.Element;
|
|
33
33
|
declare function DialogFooter({
|
|
34
34
|
className,
|
|
35
35
|
...props
|
|
36
|
-
}: React.ComponentProps<'div'>):
|
|
36
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime84.JSX.Element;
|
|
37
37
|
declare function DialogTitle({
|
|
38
38
|
className,
|
|
39
39
|
...props
|
|
40
|
-
}: React.ComponentProps<typeof Dialog.Title>):
|
|
40
|
+
}: React.ComponentProps<typeof Dialog.Title>): react_jsx_runtime84.JSX.Element;
|
|
41
41
|
declare function DialogDescription({
|
|
42
42
|
className,
|
|
43
43
|
...props
|
|
44
|
-
}: React.ComponentProps<typeof Dialog.Description>):
|
|
44
|
+
}: React.ComponentProps<typeof Dialog.Description>): react_jsx_runtime84.JSX.Element;
|
|
45
45
|
//#endregion
|
|
46
46
|
export { Dialog$1 as Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger };
|
|
47
|
-
//# sourceMappingURL=dialog-
|
|
47
|
+
//# sourceMappingURL=dialog-CPq4R2AI.d.cts.map
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime84 from "react/jsx-runtime";
|
|
2
2
|
import { Dialog } from "radix-ui";
|
|
3
3
|
|
|
4
4
|
//#region packages/components/ui/dialog.d.ts
|
|
5
5
|
declare function Dialog$1({
|
|
6
6
|
...props
|
|
7
|
-
}: React.ComponentProps<typeof Dialog.Root>):
|
|
7
|
+
}: React.ComponentProps<typeof Dialog.Root>): react_jsx_runtime84.JSX.Element;
|
|
8
8
|
declare function DialogTrigger({
|
|
9
9
|
...props
|
|
10
|
-
}: React.ComponentProps<typeof Dialog.Trigger>):
|
|
10
|
+
}: React.ComponentProps<typeof Dialog.Trigger>): react_jsx_runtime84.JSX.Element;
|
|
11
11
|
declare function DialogPortal({
|
|
12
12
|
...props
|
|
13
|
-
}: React.ComponentProps<typeof Dialog.Portal>):
|
|
13
|
+
}: React.ComponentProps<typeof Dialog.Portal>): react_jsx_runtime84.JSX.Element;
|
|
14
14
|
declare function DialogClose({
|
|
15
15
|
...props
|
|
16
|
-
}: React.ComponentProps<typeof Dialog.Close>):
|
|
16
|
+
}: React.ComponentProps<typeof Dialog.Close>): react_jsx_runtime84.JSX.Element;
|
|
17
17
|
declare function DialogOverlay({
|
|
18
18
|
className,
|
|
19
19
|
...props
|
|
20
|
-
}: React.ComponentProps<typeof Dialog.Overlay>):
|
|
20
|
+
}: React.ComponentProps<typeof Dialog.Overlay>): react_jsx_runtime84.JSX.Element;
|
|
21
21
|
declare function DialogContent({
|
|
22
22
|
className,
|
|
23
23
|
children,
|
|
@@ -25,23 +25,23 @@ declare function DialogContent({
|
|
|
25
25
|
...props
|
|
26
26
|
}: React.ComponentProps<typeof Dialog.Content> & {
|
|
27
27
|
showCloseButton?: boolean;
|
|
28
|
-
}):
|
|
28
|
+
}): react_jsx_runtime84.JSX.Element;
|
|
29
29
|
declare function DialogHeader({
|
|
30
30
|
className,
|
|
31
31
|
...props
|
|
32
|
-
}: React.ComponentProps<'div'>):
|
|
32
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime84.JSX.Element;
|
|
33
33
|
declare function DialogFooter({
|
|
34
34
|
className,
|
|
35
35
|
...props
|
|
36
|
-
}: React.ComponentProps<'div'>):
|
|
36
|
+
}: React.ComponentProps<'div'>): react_jsx_runtime84.JSX.Element;
|
|
37
37
|
declare function DialogTitle({
|
|
38
38
|
className,
|
|
39
39
|
...props
|
|
40
|
-
}: React.ComponentProps<typeof Dialog.Title>):
|
|
40
|
+
}: React.ComponentProps<typeof Dialog.Title>): react_jsx_runtime84.JSX.Element;
|
|
41
41
|
declare function DialogDescription({
|
|
42
42
|
className,
|
|
43
43
|
...props
|
|
44
|
-
}: React.ComponentProps<typeof Dialog.Description>):
|
|
44
|
+
}: React.ComponentProps<typeof Dialog.Description>): react_jsx_runtime84.JSX.Element;
|
|
45
45
|
//#endregion
|
|
46
46
|
export { Dialog$1 as Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger };
|
|
47
|
-
//# sourceMappingURL=dialog-
|
|
47
|
+
//# sourceMappingURL=dialog-sMaQeOv6.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";require(`../../../utils-BsjVK5EW.cjs`),require(`../../../tooltip-D7xs4Hao.cjs`),require(`../../../button-Cg9ZsZ68.cjs`),require(`../../../input-C2xQcVZP.cjs`),require(`../../../separator-Cigaqna1.cjs`),require(`../../../sheet-CX3PajAc.cjs`),require(`../../../skeleton-tNlCAW9R.cjs`),require(`../../../use-mobile-DD7ESbjU.cjs`);const e=require(`../../../sidebar-
|
|
1
|
+
"use client";require(`../../../utils-BsjVK5EW.cjs`),require(`../../../tooltip-D7xs4Hao.cjs`),require(`../../../button-Cg9ZsZ68.cjs`),require(`../../../input-C2xQcVZP.cjs`),require(`../../../separator-Cigaqna1.cjs`),require(`../../../sheet-CX3PajAc.cjs`),require(`../../../skeleton-tNlCAW9R.cjs`),require(`../../../use-mobile-DD7ESbjU.cjs`);const e=require(`../../../sidebar-B8vyPsEX.cjs`);exports.DetailDialogSidebarContent=e.DetailDialogSidebarContent,exports.DetailDialogSidebarFooter=e.DetailDialogSidebarFooter,exports.DetailDialogSidebarGroup=e.DetailDialogSidebarGroup,exports.DetailDialogSidebarGroupAction=e.DetailDialogSidebarGroupAction,exports.DetailDialogSidebarGroupContent=e.DetailDialogSidebarGroupContent,exports.DetailDialogSidebarGroupLabel=e.DetailDialogSidebarGroupLabel,exports.DetailDialogSidebarHeader=e.DetailDialogSidebarHeader,exports.DetailDialogSidebarMenu=e.DetailDialogSidebarMenu,exports.DetailDialogSidebarMenuAction=e.DetailDialogSidebarMenuAction,exports.DetailDialogSidebarMenuBadge=e.DetailDialogSidebarMenuBadge,exports.DetailDialogSidebarMenuButton=e.DetailDialogSidebarMenuButton,exports.DetailDialogSidebarMenuItem=e.DetailDialogSidebarMenuItem,exports.DetailDialogSidebarMenuSkeleton=e.DetailDialogSidebarMenuSkeleton,exports.DetailDialogSidebarMenuSub=e.DetailDialogSidebarMenuSub,exports.DetailDialogSidebarMenuSubButton=e.DetailDialogSidebarMenuSubButton,exports.DetailDialogSidebarMenuSubItem=e.DetailDialogSidebarMenuSubItem,exports.DetailDialogSidebarRail=e.DetailDialogSidebarRail,exports.DetailDialogSidebarSeparator=e.DetailDialogSidebarSeparator,exports.DetailDialogSidebarTrigger=e.DetailDialogSidebarTrigger,exports.Sidebar=e.Sidebar,exports.SidebarInput=e.SidebarInput,exports.SidebarInset=e.SidebarInset,exports.SidebarProvider=e.SidebarProvider,exports.useSidebar=e.useSidebar;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Button } from "../../../button-
|
|
2
|
-
import { Input } from "../../../input-
|
|
3
|
-
import { Separator } from "../../../separator-
|
|
4
|
-
import { TooltipContent } from "../../../tooltip-
|
|
1
|
+
import { Button } from "../../../button-BRHXAci1.cjs";
|
|
2
|
+
import { Input } from "../../../input-6yLVoluZ.cjs";
|
|
3
|
+
import { Separator } from "../../../separator-DnxxU9GH.cjs";
|
|
4
|
+
import { TooltipContent } from "../../../tooltip-Dkh_dieJ.cjs";
|
|
5
5
|
import * as react_jsx_runtime236 from "react/jsx-runtime";
|
|
6
6
|
import React from "react";
|
|
7
7
|
import * as class_variance_authority_types6 from "class-variance-authority/types";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Button } from "../../../button-
|
|
2
|
-
import { Input } from "../../../input-
|
|
3
|
-
import { Separator } from "../../../separator-
|
|
4
|
-
import { TooltipContent } from "../../../tooltip-
|
|
1
|
+
import { Button } from "../../../button-DzJicXG7.js";
|
|
2
|
+
import { Input } from "../../../input-I8ngYGaj.js";
|
|
3
|
+
import { Separator } from "../../../separator-F-PIApnV.js";
|
|
4
|
+
import { TooltipContent } from "../../../tooltip-GgIQS_wc.js";
|
|
5
5
|
import React from "react";
|
|
6
6
|
import * as react_jsx_runtime236 from "react/jsx-runtime";
|
|
7
7
|
import { VariantProps } from "class-variance-authority";
|
|
@@ -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"../../../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-
|
|
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-CUDxSzag.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`)
|
|
1
|
+
const e=require(`../../chunk-CUT6urMc.cjs`),t=require(`../../utils-BsjVK5EW.cjs`);require(`../../card-BDtW5n7z.cjs`);const n=require(`../../flex-DnFMe9kC.cjs`),r=require(`../../date-nd8WkPlx.cjs`);require(`../../tooltip-D7xs4Hao.cjs`),require(`../../button-Cg9ZsZ68.cjs`);const i=require(`../../dialog-CguMVyyd.cjs`);require(`../../input-C2xQcVZP.cjs`);const a=require(`../../title-6Uosk2b4.cjs`);require(`../../separator-Cigaqna1.cjs`),require(`../../sheet-CX3PajAc.cjs`),require(`../../skeleton-tNlCAW9R.cjs`),require(`../../use-mobile-DD7ESbjU.cjs`);const o=require(`../../sidebar-B8vyPsEX.cjs`),s=e.__toESM(require(`react/jsx-runtime`)),c=e.__toESM(require(`lucide-react`)),l=()=>(0,s.jsxs)(i.DialogHeader,{className:`sr-only`,children:[(0,s.jsx)(i.DialogTitle,{className:`sr-only`}),(0,s.jsx)(i.DialogDescription,{className:`sr-only`})]}),u=({children:e})=>(0,s.jsx)(`main`,{"data-slot":`detail-dialog-main`,className:`relative h-full flex-1`,children:(0,s.jsx)(n.Flex,{padding:`none`,gap:`none`,vertical:!0,align:`stretch`,className:`absolute inset-0 size-full`,children:e})}),d=({title:e,createdAt:t})=>(0,s.jsxs)(`header`,{className:`bg-card border-border-weak flex w-full flex-0 items-start gap-x-2.5 border-b py-2.5 pr-12 pl-2`,children:[(0,s.jsx)(o.DetailDialogSidebarTrigger,{}),(0,s.jsxs)(n.Flex,{vertical:!0,align:`start`,padding:`none`,width:`null`,wrap:!1,className:`flex-1`,children:[(0,s.jsx)(a.Title,{level:5,className:`line-clamp-1 truncate text-wrap`,children:e||`Detail Dialog`}),(0,s.jsxs)(n.Flex,{padding:`none`,className:`text-text-positive-weak relative`,children:[(0,s.jsx)(c.CalendarIcon,{size:12,className:`absolute top-0.5 md:top-1`}),!!t&&(0,s.jsx)(r.DateDisplay,{showTime:!0,showHoliday:!0,date:t,format:`full`,className:`ml-4 text-xs md:text-sm`})]})]})]}),f=({children:e})=>(0,s.jsx)(i.DialogContent,{className:t.cn(`relative h-full overflow-hidden border-none p-0`,`rounded-none md:rounded-lg`,`max-h-svh max-w-svw`,`md:max-h-[90svh] md:max-w-[90svw]`,`xl:max-h-[90svh] xl:max-w-[90svw]`,`2xl:max-h-[90svh] 2xl:max-w-7xl`),onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:e}),p=({title:e,sidebarFooter:t,children:n})=>(0,s.jsxs)(o.Sidebar,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[(0,s.jsx)(o.DetailDialogSidebarHeader,{children:(0,s.jsx)(o.DetailDialogSidebarMenu,{children:(0,s.jsx)(o.DetailDialogSidebarMenuItem,{children:(0,s.jsxs)(o.DetailDialogSidebarMenuButton,{size:`lg`,tabIndex:-1,children:[(0,s.jsx)(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:(0,s.jsx)(c.CatIcon,{size:16})}),(0,s.jsxs)(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[(0,s.jsx)(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),(0,s.jsx)(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),(0,s.jsx)(o.DetailDialogSidebarContent,{children:(0,s.jsx)(o.DetailDialogSidebarGroup,{children:n})}),t&&(0,s.jsx)(o.DetailDialogSidebarFooter,{children:t})]}),m=({open:e,isLoading:t=!1,sidebarTitle:r,sidebar:a,sidebarFooter:c,title:m,createdAt:h,onOpenChange:g,children:_})=>(0,s.jsx)(i.Dialog,{open:e,onOpenChange:g,children:(0,s.jsxs)(f,{children:[(0,s.jsx)(l,{}),(0,s.jsxs)(o.SidebarProvider,{className:`h-full min-h-[85svh] items-start`,children:[(0,s.jsx)(p,{title:r,sidebarFooter:c,children:a}),(0,s.jsxs)(u,{children:[(0,s.jsx)(d,{title:m,createdAt:h}),t?(0,s.jsx)(n.Flex,{justify:`center`,className:`bg-muted-muted w-full flex-1 inset-shadow-sm`,children:(0,s.jsx)(`div`,{className:`loader`})}):(0,s.jsx)(`section`,{className:`bg-muted-muted relative flex flex-1 snap-y flex-col gap-0 overflow-y-auto inset-shadow-sm`,children:_})]})]})]})});exports.DetailDialog=m;
|
|
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
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["DialogHeader","DialogTitle","DialogDescription","DetailDialogMain: React.FC<React.PropsWithChildren>","Flex","DetailDialogMainHeader: React.FC<React.PropsWithChildren<DetailDialogMainHeaderProps>>","DetailDialogSidebarTrigger","Title","CalendarIcon","DateDisplay","DetailDialogWrapper: React.FC<React.PropsWithChildren>","DialogContent","cn","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'\nimport { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => (\n <main data-slot=\"detail-dialog-main\" className=\"relative h-full flex-1\">\n <Flex padding=\"none\" gap=\"none\" vertical align=\"stretch\" className=\"absolute inset-0 size-full\">\n {children}\n </Flex>\n </main>\n)\n\ntype DetailDialogMainHeaderProps = {\n title: string\n createdAt?: string | Date | number\n}\nexport const DetailDialogMainHeader: React.FC<React.PropsWithChildren<DetailDialogMainHeaderProps>> = ({ title, createdAt }) => (\n <header className=\"bg-card border-border-weak flex w-full flex-0 items-start gap-x-2.5 border-b py-2.5 pr-12 pl-2\">\n <DetailDialogSidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" width=\"null\" wrap={false} className=\"flex-1\">\n <Title level={5} className=\"line-clamp-1 truncate text-wrap\">\n {title || 'Detail Dialog'}\n </Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak relative\">\n <CalendarIcon size={12} className=\"absolute top-0.5 md:top-1\" />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" className=\"ml-4 text-xs md:text-sm\" />}\n </Flex>\n </Flex>\n </header>\n)\n\nexport const DetailDialogMainGroup: React.FC<React.PropsWithChildren> = ({ children }) => (\n <Flex vertical gap=\"md\" padding=\"md\" width=\"full\">\n {children}\n </Flex>\n)\n\ntype DetailDialogMainGroupItemProps = {\n title?: string\n description?: string\n}\nexport const DetailDialogMainGroupItem: React.FC<React.PropsWithChildren<DetailDialogMainGroupItemProps>> = ({ title, description, children }) => (\n <Card className=\"w-full snap-start scroll-mt-4\">\n <CardHeader>\n <CardTitle>{title}</CardTitle>\n <CardDescription>{description}</CardDescription>\n </CardHeader>\n <CardContent>{children}</CardContent>\n </Card>\n)\n","import { DialogContent } from '@/components/ui/dialog'\nimport { cn } from '@/lib/utils'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className={cn(\n 'relative h-full overflow-hidden border-none p-0',\n 'rounded-none md:rounded-lg',\n 'max-h-svh max-w-svw',\n 'md:max-h-[90svh] md:max-w-[90svw]',\n 'xl:max-h-[90svh] xl:max-w-[90svw]',\n '2xl:max-h-[90svh] 2xl:max-w-7xl',\n )}\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 w-full flex-1 inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex flex-1 snap-y flex-col gap-0 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"sqBAEa,OAET,EAAA,EAAA,MAACA,EAAAA,aAAAA,CAAa,UAAU,qBACtB,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,UAAU,aACvB,EAAA,EAAA,KAACC,EAAAA,kBAAAA,CAAkB,UAAU,eCGtBC,GAAuD,CAAE,eACpE,EAAA,EAAA,KAAC,OAAA,CAAK,YAAU,qBAAqB,UAAU,mCAC7C,EAAA,EAAA,KAACuB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,UAAU,UAAU,6BAChE,eASMrB,GAA0F,CAAE,QAAO,gBAC9G,EAAA,EAAA,MAAC,SAAA,CAAO,UAAU,4GAChB,EAAA,EAAA,KAACC,EAAAA,2BAAAA,KACD,EAAA,EAAA,MAACoB,EAAAA,KAAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,MAAM,OAAO,KAAM,GAAO,UAAU,oBAC9E,EAAA,EAAA,KAACnB,EAAAA,MAAAA,CAAM,MAAO,EAAG,UAAU,2CACxB,GAAS,mBAEZ,EAAA,EAAA,MAACmB,EAAAA,KAAAA,CAAK,QAAQ,OAAO,UAAU,8CAC7B,EAAA,EAAA,KAAClB,EAAAA,aAAAA,CAAa,KAAM,GAAI,UAAU,8BACjC,CAAC,CAAC,IAAa,EAAA,EAAA,KAACC,EAAAA,YAAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,OAAO,UAAU,qCC3BtFC,GAA0D,CAAE,eAErE,EAAA,EAAA,KAACC,EAAAA,cAAAA,CACC,UAAWC,EAAAA,GACT,kDACA,6BACA,sBACA,oCACA,oCACA,mCAEF,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCCDC,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,yDAC/B,EAAA,EAAA,KAAC,MAAA,CAAI,UAAU,cAGjB,EAAA,EAAA,KAAC,UAAA,CAAQ,UAAU,4FAA6F"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../utils-D9AH0PUV.js";import{Flex as
|
|
1
|
+
import{cn as e}from"../../utils-D9AH0PUV.js";import"../../card-C17NWErE.js";import{Flex as t}from"../../flex-CbkTJwcD.js";import{DateDisplay as n}from"../../date-BMq_DNsv.js";import"../../tooltip-CaqA5ydI.js";import"../../button-tXV0dTFU.js";import{Dialog as r,DialogContent as i,DialogDescription as a,DialogHeader as o,DialogTitle as s}from"../../dialog-YTzM43YA.js";import"../../input-DgJVc3kt.js";import{Title as c}from"../../title-CxIwADiB.js";import"../../separator-aLdI4FQe.js";import"../../sheet-DqPtcv9H.js";import"../../skeleton-BSi1n1L2.js";import"../../use-mobile-CNVZwItd.js";import{DetailDialogSidebarContent as l,DetailDialogSidebarFooter as u,DetailDialogSidebarGroup as d,DetailDialogSidebarHeader as f,DetailDialogSidebarMenu as p,DetailDialogSidebarMenuButton as m,DetailDialogSidebarMenuItem as h,DetailDialogSidebarTrigger as g,Sidebar as _,SidebarProvider as v}from"../../sidebar-CUDxSzag.js";import{jsx as y,jsxs as b}from"react/jsx-runtime";import{CalendarIcon as x,CatIcon as S}from"lucide-react";const C=()=>b(o,{className:`sr-only`,children:[y(s,{className:`sr-only`}),y(a,{className:`sr-only`})]}),w=({children:e})=>y(`main`,{"data-slot":`detail-dialog-main`,className:`relative h-full flex-1`,children:y(t,{padding:`none`,gap:`none`,vertical:!0,align:`stretch`,className:`absolute inset-0 size-full`,children:e})}),T=({title:e,createdAt:r})=>b(`header`,{className:`bg-card border-border-weak flex w-full flex-0 items-start gap-x-2.5 border-b py-2.5 pr-12 pl-2`,children:[y(g,{}),b(t,{vertical:!0,align:`start`,padding:`none`,width:`null`,wrap:!1,className:`flex-1`,children:[y(c,{level:5,className:`line-clamp-1 truncate text-wrap`,children:e||`Detail Dialog`}),b(t,{padding:`none`,className:`text-text-positive-weak relative`,children:[y(x,{size:12,className:`absolute top-0.5 md:top-1`}),!!r&&y(n,{showTime:!0,showHoliday:!0,date:r,format:`full`,className:`ml-4 text-xs md:text-sm`})]})]})]}),E=({children:t})=>y(i,{className:e(`relative h-full overflow-hidden border-none p-0`,`rounded-none md:rounded-lg`,`max-h-svh max-w-svw`,`md:max-h-[90svh] md:max-w-[90svw]`,`xl:max-h-[90svh] xl:max-w-[90svw]`,`2xl:max-h-[90svh] 2xl:max-w-7xl`),onInteractOutside:e=>{e.preventDefault(),e.stopPropagation()},children:t}),D=({title:e,sidebarFooter:t,children:n})=>b(_,{collapsible:`icon`,className:`shadow-nav z-20 hidden md:flex`,children:[y(f,{children:y(p,{children:y(h,{children:b(m,{size:`lg`,tabIndex:-1,children:[y(`div`,{className:`bg-sidebar-primary text-sidebar-primary-foreground flex aspect-square size-8 items-center justify-center rounded-lg`,children:y(S,{size:16})}),b(`div`,{className:`grid flex-1 text-left text-sm leading-tight`,children:[y(`span`,{className:`truncate font-medium`,children:e||`Detail Dialog`}),y(`span`,{className:`truncate text-xs`,children:`Lunas Enterprise`})]})]})})})}),y(l,{children:y(d,{children:n})}),t&&y(u,{children:t})]}),O=({open:e,isLoading:n=!1,sidebarTitle:i,sidebar:a,sidebarFooter:o,title:s,createdAt:c,onOpenChange:l,children:u})=>y(r,{open:e,onOpenChange:l,children:b(E,{children:[y(C,{}),b(v,{className:`h-full min-h-[85svh] items-start`,children:[y(D,{title:i,sidebarFooter:o,children:a}),b(w,{children:[y(T,{title:s,createdAt:c}),n?y(t,{justify:`center`,className:`bg-muted-muted w-full flex-1 inset-shadow-sm`,children:y(`div`,{className:`loader`})}):y(`section`,{className:`bg-muted-muted relative flex flex-1 snap-y flex-col gap-0 overflow-y-auto inset-shadow-sm`,children:u})]})]})]})});export{O 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
|
|
1
|
+
{"version":3,"file":"index.js","names":["DetailDialogMain: React.FC<React.PropsWithChildren>","DetailDialogMainHeader: React.FC<React.PropsWithChildren<DetailDialogMainHeaderProps>>","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'\nimport { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card'\n\nexport const DetailDialogMain: React.FC<React.PropsWithChildren> = ({ children }) => (\n <main data-slot=\"detail-dialog-main\" className=\"relative h-full flex-1\">\n <Flex padding=\"none\" gap=\"none\" vertical align=\"stretch\" className=\"absolute inset-0 size-full\">\n {children}\n </Flex>\n </main>\n)\n\ntype DetailDialogMainHeaderProps = {\n title: string\n createdAt?: string | Date | number\n}\nexport const DetailDialogMainHeader: React.FC<React.PropsWithChildren<DetailDialogMainHeaderProps>> = ({ title, createdAt }) => (\n <header className=\"bg-card border-border-weak flex w-full flex-0 items-start gap-x-2.5 border-b py-2.5 pr-12 pl-2\">\n <DetailDialogSidebarTrigger />\n <Flex vertical align=\"start\" padding=\"none\" width=\"null\" wrap={false} className=\"flex-1\">\n <Title level={5} className=\"line-clamp-1 truncate text-wrap\">\n {title || 'Detail Dialog'}\n </Title>\n <Flex padding=\"none\" className=\"text-text-positive-weak relative\">\n <CalendarIcon size={12} className=\"absolute top-0.5 md:top-1\" />\n {!!createdAt && <DateDisplay showTime showHoliday date={createdAt} format=\"full\" className=\"ml-4 text-xs md:text-sm\" />}\n </Flex>\n </Flex>\n </header>\n)\n\nexport const DetailDialogMainGroup: React.FC<React.PropsWithChildren> = ({ children }) => (\n <Flex vertical gap=\"md\" padding=\"md\" width=\"full\">\n {children}\n </Flex>\n)\n\ntype DetailDialogMainGroupItemProps = {\n title?: string\n description?: string\n}\nexport const DetailDialogMainGroupItem: React.FC<React.PropsWithChildren<DetailDialogMainGroupItemProps>> = ({ title, description, children }) => (\n <Card className=\"w-full snap-start scroll-mt-4\">\n <CardHeader>\n <CardTitle>{title}</CardTitle>\n <CardDescription>{description}</CardDescription>\n </CardHeader>\n <CardContent>{children}</CardContent>\n </Card>\n)\n","import { DialogContent } from '@/components/ui/dialog'\nimport { cn } from '@/lib/utils'\n\nexport const DetailDialogWrapper: React.FC<React.PropsWithChildren> = ({ children }) => {\n return (\n <DialogContent\n className={cn(\n 'relative h-full overflow-hidden border-none p-0',\n 'rounded-none md:rounded-lg',\n 'max-h-svh max-w-svw',\n 'md:max-h-[90svh] md:max-w-[90svw]',\n 'xl:max-h-[90svh] xl:max-w-[90svw]',\n '2xl:max-h-[90svh] 2xl:max-w-7xl',\n )}\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 w-full flex-1 inset-shadow-sm\">\n <div className=\"loader\" />\n </Flex>\n ) : (\n <section className=\"bg-muted-muted relative flex flex-1 snap-y flex-col gap-0 overflow-y-auto inset-shadow-sm\">{children}</section>\n )}\n </DetailDialogMain>\n </SidebarProvider>\n </DetailDialogWrapper>\n </Dialog>\n )\n}\n"],"mappings":"8/BAEA,MAAa,MAET,EAAC,EAAA,CAAa,UAAU,oBACtB,EAAC,EAAA,CAAY,UAAU,YACvB,EAAC,EAAA,CAAkB,UAAU,eCGtBA,GAAuD,CAAE,cACpE,EAAC,OAAA,CAAK,YAAU,qBAAqB,UAAU,kCAC7C,EAAC,EAAA,CAAK,QAAQ,OAAO,IAAI,OAAO,SAAA,GAAS,MAAM,UAAU,UAAU,6BAChE,eASMC,GAA0F,CAAE,QAAO,eAC9G,EAAC,SAAA,CAAO,UAAU,2GAChB,EAAC,EAAA,IACD,EAAC,EAAA,CAAK,SAAA,GAAS,MAAM,QAAQ,QAAQ,OAAO,MAAM,OAAO,KAAM,GAAO,UAAU,mBAC9E,EAAC,EAAA,CAAM,MAAO,EAAG,UAAU,2CACxB,GAAS,kBAEZ,EAAC,EAAA,CAAK,QAAQ,OAAO,UAAU,6CAC7B,EAAC,EAAA,CAAa,KAAM,GAAI,UAAU,8BACjC,CAAC,CAAC,GAAa,EAAC,EAAA,CAAY,SAAA,GAAS,YAAA,GAAY,KAAM,EAAW,OAAO,OAAO,UAAU,qCC3BtFC,GAA0D,CAAE,cAErE,EAAC,EAAA,CACC,UAAW,EACT,kDACA,6BACA,sBACA,oCACA,oCACA,mCAEF,kBAAoB,GAAM,CACxB,EAAE,iBACF,EAAE,mBAGH,aCCDC,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,wDAC/B,EAAC,MAAA,CAAI,UAAU,aAGjB,EAAC,UAAA,CAAQ,UAAU,4FAA6F"}
|