@appcorp/shadcn 1.2.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/app-sidebar.js +16 -23
- package/components/audio.js +11 -19
- package/components/dashboard.js +27 -65
- package/components/drawer-generic.js +20 -28
- package/components/enhanced-checkbox.js +10 -57
- package/components/enhanced-combobox.js +99 -143
- package/components/enhanced-drawer-footer.js +22 -31
- package/components/enhanced-drawer-header.js +6 -14
- package/components/enhanced-dropzone-impl.d.ts +32 -0
- package/components/enhanced-dropzone-impl.js +218 -0
- package/components/enhanced-dropzone.d.ts +2 -63
- package/components/enhanced-dropzone.js +6 -294
- package/components/enhanced-input.js +10 -57
- package/components/enhanced-label.js +6 -52
- package/components/enhanced-radio.js +12 -20
- package/components/enhanced-select.js +13 -61
- package/components/enhanced-slider.js +11 -58
- package/components/enhanced-switch.js +11 -58
- package/components/enhanced-table-footer-action.js +11 -19
- package/components/enhanced-table-footer-page.js +16 -24
- package/components/enhanced-table-footer-pagination.js +11 -21
- package/components/enhanced-table-header-action.js +22 -30
- package/components/enhanced-table-header-search.js +9 -17
- package/components/enhanced-table.js +125 -153
- package/components/enhanced-textarea.js +10 -57
- package/components/field.d.ts +1 -1
- package/components/field.js +31 -88
- package/components/image-resize-dialog.js +61 -159
- package/components/nav-main.js +32 -78
- package/components/nav-projects.js +37 -48
- package/components/nav-user.js +41 -51
- package/components/show-toast.js +5 -9
- package/components/sidebar.d.ts +1 -1
- package/components/sidebar.js +115 -184
- package/components/team-switcher.js +36 -47
- package/components/theme-provider.js +36 -84
- package/components/timeline.js +12 -20
- package/components/tooltip.js +10 -59
- package/components/ui/accordion.js +17 -67
- package/components/ui/alert-dialog.js +32 -89
- package/components/ui/alert.d.ts +1 -1
- package/components/ui/alert.js +14 -63
- package/components/ui/area-chart-v1-impl.d.ts +19 -0
- package/components/ui/area-chart-v1-impl.js +75 -0
- package/components/ui/area-chart-v1.d.ts +2 -19
- package/components/ui/area-chart-v1.js +4 -113
- package/components/ui/aspect-ratio.js +3 -39
- package/components/ui/avatar.js +13 -62
- package/components/ui/badge.d.ts +2 -2
- package/components/ui/badge.js +7 -55
- package/components/ui/breadcrumb.js +27 -80
- package/components/ui/button.d.ts +2 -2
- package/components/ui/button.js +10 -58
- package/components/ui/calendar-impl.d.ts +8 -0
- package/components/ui/calendar-impl.js +55 -0
- package/components/ui/calendar.d.ts +2 -8
- package/components/ui/calendar.js +5 -108
- package/components/ui/card.js +21 -73
- package/components/ui/carousel-impl.d.ts +18 -0
- package/components/ui/carousel-impl.js +117 -0
- package/components/ui/carousel.d.ts +6 -18
- package/components/ui/carousel.js +8 -170
- package/components/ui/chart-impl.d.ts +62 -0
- package/components/ui/chart-impl.js +162 -0
- package/components/ui/chart.d.ts +7 -62
- package/components/ui/chart.js +9 -219
- package/components/ui/checkbox.js +10 -57
- package/components/ui/collapsible.js +5 -43
- package/components/ui/combobox.js +22 -58
- package/components/ui/command-impl.d.ts +80 -0
- package/components/ui/command-impl.js +63 -0
- package/components/ui/command.d.ts +9 -80
- package/components/ui/command.js +12 -117
- package/components/ui/context-menu.js +41 -102
- package/components/ui/dialog.js +28 -84
- package/components/ui/drawer-impl.d.ts +22 -0
- package/components/ui/drawer-impl.js +56 -0
- package/components/ui/drawer.d.ts +10 -22
- package/components/ui/drawer.js +13 -111
- package/components/ui/dropdown-menu.js +41 -102
- package/components/ui/form.d.ts +4 -2
- package/components/ui/form.js +41 -95
- package/components/ui/hover-card.js +9 -58
- package/components/ui/input-otp-impl.d.ts +34 -0
- package/components/ui/input-otp-impl.js +43 -0
- package/components/ui/input-otp.d.ts +4 -34
- package/components/ui/input-otp.js +7 -92
- package/components/ui/input.js +6 -53
- package/components/ui/label.d.ts +1 -1
- package/components/ui/label.js +9 -56
- package/components/ui/language-selector.js +17 -55
- package/components/ui/menubar.js +46 -108
- package/components/ui/navigation-menu.d.ts +1 -1
- package/components/ui/navigation-menu.js +29 -84
- package/components/ui/pagination.js +30 -83
- package/components/ui/popover.js +10 -60
- package/components/ui/progress.js +8 -55
- package/components/ui/radio-group.js +12 -60
- package/components/ui/resizable-impl.d.ts +24 -0
- package/components/ui/resizable-impl.js +27 -0
- package/components/ui/resizable.d.ts +3 -24
- package/components/ui/resizable.js +6 -78
- package/components/ui/scroll-area.js +10 -58
- package/components/ui/select.js +34 -90
- package/components/ui/separator.js +7 -54
- package/components/ui/sheet.d.ts +1 -1
- package/components/ui/sheet.js +30 -86
- package/components/ui/skeleton.js +5 -21
- package/components/ui/slider.js +10 -57
- package/components/ui/sonner.js +7 -24
- package/components/ui/switch.js +8 -55
- package/components/ui/table.js +27 -81
- package/components/ui/tabs.js +14 -64
- package/components/ui/textarea.js +6 -53
- package/components/ui/theme-switcher.js +41 -91
- package/components/ui/toggle.d.ts +2 -2
- package/components/ui/toggle.js +9 -57
- package/data/admin-dashboard.js +16 -19
- package/hooks/use-enhanced-combobox.js +47 -124
- package/hooks/use-mobile.js +8 -44
- package/hooks/use-outside-click.js +6 -10
- package/lib/themes.js +1 -4
- package/lib/toast-utils.js +78 -120
- package/lib/utils.js +4 -11
- package/package.json +9 -90
- package/utils/transform-breadcrumbs.js +4 -8
- package/utils/transform-navitems.js +7 -22
- package/components/aceternity-ui/apple-cards-carousel.d.ts +0 -35
- package/components/aceternity-ui/apple-cards-carousel.js +0 -263
- package/components/shadcn-example/ai-chat/chat-interface.d.ts +0 -11
- package/components/shadcn-example/ai-chat/chat-interface.js +0 -70
- package/components/shadcn-example/ai-chat/index.d.ts +0 -38
- package/components/shadcn-example/ai-chat/index.js +0 -66
- package/components/shadcn-example/ai-chat/sidebar.d.ts +0 -15
- package/components/shadcn-example/ai-chat/sidebar.js +0 -68
- package/components/shadcn-example/ai-chat/welcome-section.d.ts +0 -12
- package/components/shadcn-example/ai-chat/welcome-section.js +0 -26
- package/components/shadcn-example/authentication/index.d.ts +0 -24
- package/components/shadcn-example/authentication/index.js +0 -59
- package/components/shadcn-example/authentication/user-auth-form.d.ts +0 -11
- package/components/shadcn-example/authentication/user-auth-form.js +0 -54
- package/components/shadcn-example/blog-detail-page/comment-section.d.ts +0 -15
- package/components/shadcn-example/blog-detail-page/comment-section.js +0 -83
- package/components/shadcn-example/blog-detail-page/content.d.ts +0 -7
- package/components/shadcn-example/blog-detail-page/content.js +0 -15
- package/components/shadcn-example/blog-detail-page/header.d.ts +0 -11
- package/components/shadcn-example/blog-detail-page/header.js +0 -36
- package/components/shadcn-example/blog-detail-page/index.d.ts +0 -25
- package/components/shadcn-example/blog-detail-page/index.js +0 -74
- package/components/shadcn-example/blog-page/blog-post-card.d.ts +0 -13
- package/components/shadcn-example/blog-page/blog-post-card.js +0 -30
- package/components/shadcn-example/blog-page/featured-post-sidebar-item.d.ts +0 -10
- package/components/shadcn-example/blog-page/featured-post-sidebar-item.js +0 -19
- package/components/shadcn-example/blog-page/index.d.ts +0 -20
- package/components/shadcn-example/blog-page/index.js +0 -36
- package/components/shadcn-example/coming-soon/countdown.d.ts +0 -2
- package/components/shadcn-example/coming-soon/countdown.js +0 -82
- package/components/shadcn-example/coming-soon/index.d.ts +0 -10
- package/components/shadcn-example/coming-soon/index.js +0 -41
- package/components/shadcn-io/color-picker/index.d.ts +0 -43
- package/components/shadcn-io/color-picker/index.js +0 -304
- package/components/shadcn-io/copy-button/index.d.ts +0 -16
- package/components/shadcn-io/copy-button/index.js +0 -121
- package/components/shadcn-io/dropzone/index.d.ts +0 -19
- package/components/shadcn-io/dropzone/index.js +0 -131
- package/components/shadcn-io/gantt/index.d.ts +0 -145
- package/components/shadcn-io/gantt/index.js +0 -766
- package/components/shadcn-io/table/index.d.ts +0 -60
- package/components/shadcn-io/table/index.js +0 -138
- package/templates/appcorp-v1/footer/bottom-bar.d.ts +0 -6
- package/templates/appcorp-v1/footer/bottom-bar.js +0 -25
- package/templates/appcorp-v1/footer/cta.d.ts +0 -6
- package/templates/appcorp-v1/footer/cta.js +0 -21
- package/templates/appcorp-v1/footer/footer-grid.d.ts +0 -14
- package/templates/appcorp-v1/footer/footer-grid.js +0 -52
- package/templates/appcorp-v1/footer/index.d.ts +0 -3
- package/templates/appcorp-v1/footer/index.js +0 -28
- package/templates/appcorp-v1/footer/newsletter.d.ts +0 -11
- package/templates/appcorp-v1/footer/newsletter.js +0 -28
- package/templates/appcorp-v1/footer/stats.d.ts +0 -6
- package/templates/appcorp-v1/footer/stats.js +0 -15
- package/templates/appcorp-v1/header/announcement-bar.d.ts +0 -3
- package/templates/appcorp-v1/header/announcement-bar.js +0 -15
- package/templates/appcorp-v1/header/dropdown-panel.d.ts +0 -8
- package/templates/appcorp-v1/header/dropdown-panel.js +0 -72
- package/templates/appcorp-v1/header/index.d.ts +0 -12
- package/templates/appcorp-v1/header/index.js +0 -16
- package/templates/appcorp-v1/header/mobile-menu.d.ts +0 -14
- package/templates/appcorp-v1/header/mobile-menu.js +0 -101
- package/templates/appcorp-v1/header/navigation-bar.d.ts +0 -3
- package/templates/appcorp-v1/header/navigation-bar.js +0 -117
- package/templates/appcorp-v1/header/social-button.d.ts +0 -7
- package/templates/appcorp-v1/header/social-button.js +0 -48
- package/templates/appcorp-v1/home.d.ts +0 -3
- package/templates/appcorp-v1/home.js +0 -27
- package/templates/data/appcorp-v1.d.ts +0 -93
- package/templates/data/appcorp-v1.js +0 -348
- package/templates/data/edupilotpro-v1.d.ts +0 -33
- package/templates/data/edupilotpro-v1.js +0 -116
- package/templates/data/school-v1.d.ts +0 -328
- package/templates/data/school-v1.js +0 -1563
- package/templates/edupilotpro-v1/feature-card.d.ts +0 -13
- package/templates/edupilotpro-v1/feature-card.js +0 -28
- package/templates/edupilotpro-v1/mockups/dashboard-mockup.d.ts +0 -3
- package/templates/edupilotpro-v1/mockups/dashboard-mockup.js +0 -55
- package/templates/school-v1/footer.d.ts +0 -3
- package/templates/school-v1/footer.js +0 -75
- package/templates/school-v1/index.d.ts +0 -18
- package/templates/school-v1/index.js +0 -60
- package/templates/school-v1/navigation.d.ts +0 -3
- package/templates/school-v1/navigation.js +0 -123
- package/templates/school-v1/sections/about.d.ts +0 -3
- package/templates/school-v1/sections/about.js +0 -49
- package/templates/school-v1/sections/admissions.d.ts +0 -3
- package/templates/school-v1/sections/admissions.js +0 -77
- package/templates/school-v1/sections/contact.d.ts +0 -3
- package/templates/school-v1/sections/contact.js +0 -67
- package/templates/school-v1/sections/faqs.d.ts +0 -3
- package/templates/school-v1/sections/faqs.js +0 -50
- package/templates/school-v1/sections/hero.d.ts +0 -3
- package/templates/school-v1/sections/hero.js +0 -132
- package/templates/school-v1/sections/management.d.ts +0 -3
- package/templates/school-v1/sections/management.js +0 -34
- package/templates/school-v1/sections/policies.d.ts +0 -3
- package/templates/school-v1/sections/policies.js +0 -127
- package/templates/school-v1/sections/programs.d.ts +0 -3
- package/templates/school-v1/sections/programs.js +0 -107
- package/templates/school-v1/sections/testimonials.d.ts +0 -3
- package/templates/school-v1/sections/testimonials.js +0 -46
- package/templates/school-v1/sections/why-choose-us.d.ts +0 -3
- package/templates/school-v1/sections/why-choose-us.js +0 -57
|
@@ -1,80 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
declare const
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
label?: string;
|
|
11
|
-
shouldFilter?: boolean;
|
|
12
|
-
filter?: (value: string, search: string, keywords?: string[]) => number;
|
|
13
|
-
defaultValue?: string;
|
|
14
|
-
value?: string;
|
|
15
|
-
onValueChange?: (value: string) => void;
|
|
16
|
-
loop?: boolean;
|
|
17
|
-
disablePointerSelection?: boolean;
|
|
18
|
-
vimBindings?: boolean;
|
|
19
|
-
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
-
declare const CommandDialog: ({ children, ...props }: DialogProps) => React.JSX.Element;
|
|
21
|
-
declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React.InputHTMLAttributes<HTMLInputElement>> & {
|
|
22
|
-
ref?: React.Ref<HTMLInputElement>;
|
|
23
|
-
} & {
|
|
24
|
-
asChild?: boolean;
|
|
25
|
-
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "type" | "onChange" | "value"> & {
|
|
26
|
-
value?: string;
|
|
27
|
-
onValueChange?: (search: string) => void;
|
|
28
|
-
} & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
29
|
-
declare const CommandList: React.ForwardRefExoticComponent<Omit<{
|
|
30
|
-
children?: React.ReactNode;
|
|
31
|
-
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
32
|
-
ref?: React.Ref<HTMLDivElement>;
|
|
33
|
-
} & {
|
|
34
|
-
asChild?: boolean;
|
|
35
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
36
|
-
label?: string;
|
|
37
|
-
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
38
|
-
declare const CommandEmpty: React.ForwardRefExoticComponent<Omit<{
|
|
39
|
-
children?: React.ReactNode;
|
|
40
|
-
} & Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
41
|
-
ref?: React.Ref<HTMLDivElement>;
|
|
42
|
-
} & {
|
|
43
|
-
asChild?: boolean;
|
|
44
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
45
|
-
declare const CommandGroup: React.ForwardRefExoticComponent<Omit<{
|
|
46
|
-
children?: React.ReactNode;
|
|
47
|
-
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
48
|
-
ref?: React.Ref<HTMLDivElement>;
|
|
49
|
-
} & {
|
|
50
|
-
asChild?: boolean;
|
|
51
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "value" | "heading"> & {
|
|
52
|
-
heading?: React.ReactNode;
|
|
53
|
-
value?: string;
|
|
54
|
-
forceMount?: boolean;
|
|
55
|
-
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
56
|
-
declare const CommandSeparator: React.ForwardRefExoticComponent<Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
57
|
-
ref?: React.Ref<HTMLDivElement>;
|
|
58
|
-
} & {
|
|
59
|
-
asChild?: boolean;
|
|
60
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
61
|
-
alwaysRender?: boolean;
|
|
62
|
-
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
63
|
-
declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
|
|
64
|
-
children?: React.ReactNode;
|
|
65
|
-
} & Omit<Pick<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
66
|
-
ref?: React.Ref<HTMLDivElement>;
|
|
67
|
-
} & {
|
|
68
|
-
asChild?: boolean;
|
|
69
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
|
|
70
|
-
disabled?: boolean;
|
|
71
|
-
onSelect?: (value: string) => void;
|
|
72
|
-
value?: string;
|
|
73
|
-
keywords?: string[];
|
|
74
|
-
forceMount?: boolean;
|
|
75
|
-
} & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
76
|
-
declare const CommandShortcut: {
|
|
77
|
-
({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): React.JSX.Element;
|
|
78
|
-
displayName: string;
|
|
79
|
-
};
|
|
80
|
-
export { Command, CommandDialog, CommandInput, CommandList, CommandEmpty, CommandGroup, CommandItem, CommandShortcut, CommandSeparator, };
|
|
1
|
+
export declare const Command: typeof import("./command-impl")["Command"];
|
|
2
|
+
export declare const CommandDialog: typeof import("./command-impl")["CommandDialog"];
|
|
3
|
+
export declare const CommandInput: typeof import("./command-impl")["CommandInput"];
|
|
4
|
+
export declare const CommandList: typeof import("./command-impl")["CommandList"];
|
|
5
|
+
export declare const CommandEmpty: typeof import("./command-impl")["CommandEmpty"];
|
|
6
|
+
export declare const CommandGroup: typeof import("./command-impl")["CommandGroup"];
|
|
7
|
+
export declare const CommandItem: typeof import("./command-impl")["CommandItem"];
|
|
8
|
+
export declare const CommandShortcut: typeof import("./command-impl")["CommandShortcut"];
|
|
9
|
+
export declare const CommandSeparator: typeof import("./command-impl")["CommandSeparator"];
|
package/components/ui/command.js
CHANGED
|
@@ -1,118 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
15
|
-
if (k2 === undefined) k2 = k;
|
|
16
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
17
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
18
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
19
|
-
}
|
|
20
|
-
Object.defineProperty(o, k2, desc);
|
|
21
|
-
}) : (function(o, m, k, k2) {
|
|
22
|
-
if (k2 === undefined) k2 = k;
|
|
23
|
-
o[k2] = m[k];
|
|
24
|
-
}));
|
|
25
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
26
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
27
|
-
}) : function(o, v) {
|
|
28
|
-
o["default"] = v;
|
|
29
|
-
});
|
|
30
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
31
|
-
var ownKeys = function(o) {
|
|
32
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
33
|
-
var ar = [];
|
|
34
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
35
|
-
return ar;
|
|
36
|
-
};
|
|
37
|
-
return ownKeys(o);
|
|
38
|
-
};
|
|
39
|
-
return function (mod) {
|
|
40
|
-
if (mod && mod.__esModule) return mod;
|
|
41
|
-
var result = {};
|
|
42
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
43
|
-
__setModuleDefault(result, mod);
|
|
44
|
-
return result;
|
|
45
|
-
};
|
|
46
|
-
})();
|
|
47
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
48
|
-
var t = {};
|
|
49
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
50
|
-
t[p] = s[p];
|
|
51
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
52
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
53
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
54
|
-
t[p[i]] = s[p[i]];
|
|
55
|
-
}
|
|
56
|
-
return t;
|
|
57
|
-
};
|
|
58
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
59
|
-
exports.CommandSeparator = exports.CommandShortcut = exports.CommandItem = exports.CommandGroup = exports.CommandEmpty = exports.CommandList = exports.CommandInput = exports.CommandDialog = exports.Command = void 0;
|
|
60
|
-
var React = __importStar(require("react"));
|
|
61
|
-
var cmdk_1 = require("cmdk");
|
|
62
|
-
var utils_1 = require("../../lib/utils");
|
|
63
|
-
var dialog_1 = require("../ui/dialog");
|
|
64
|
-
var react_icons_1 = require("@radix-ui/react-icons");
|
|
65
|
-
var Command = React.forwardRef(function (_a, ref) {
|
|
66
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
67
|
-
return (React.createElement(cmdk_1.Command, __assign({ ref: ref, className: (0, utils_1.cn)("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground", className) }, props)));
|
|
68
|
-
});
|
|
69
|
-
exports.Command = Command;
|
|
70
|
-
Command.displayName = cmdk_1.Command.displayName;
|
|
71
|
-
var CommandDialog = function (_a) {
|
|
72
|
-
var children = _a.children, props = __rest(_a, ["children"]);
|
|
73
|
-
return (React.createElement(dialog_1.Dialog, __assign({}, props),
|
|
74
|
-
React.createElement(dialog_1.DialogContent, { className: "overflow-hidden p-0" },
|
|
75
|
-
React.createElement(Command, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5" }, children))));
|
|
76
|
-
};
|
|
77
|
-
exports.CommandDialog = CommandDialog;
|
|
78
|
-
var CommandInput = React.forwardRef(function (_a, ref) {
|
|
79
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
80
|
-
return (React.createElement("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "" },
|
|
81
|
-
React.createElement(react_icons_1.MagnifyingGlassIcon, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
|
|
82
|
-
React.createElement(cmdk_1.Command.Input, __assign({ ref: ref, className: (0, utils_1.cn)("flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50", className) }, props))));
|
|
83
|
-
});
|
|
84
|
-
exports.CommandInput = CommandInput;
|
|
85
|
-
CommandInput.displayName = cmdk_1.Command.Input.displayName;
|
|
86
|
-
var CommandList = React.forwardRef(function (_a, ref) {
|
|
87
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
88
|
-
return (React.createElement(cmdk_1.Command.List, __assign({ ref: ref, className: (0, utils_1.cn)("max-h-[300px] overflow-y-auto overflow-x-hidden", className) }, props)));
|
|
89
|
-
});
|
|
90
|
-
exports.CommandList = CommandList;
|
|
91
|
-
CommandList.displayName = cmdk_1.Command.List.displayName;
|
|
92
|
-
var CommandEmpty = React.forwardRef(function (props, ref) { return (React.createElement(cmdk_1.Command.Empty, __assign({ ref: ref, className: "py-6 text-center text-sm" }, props))); });
|
|
93
|
-
exports.CommandEmpty = CommandEmpty;
|
|
94
|
-
CommandEmpty.displayName = cmdk_1.Command.Empty.displayName;
|
|
95
|
-
var CommandGroup = React.forwardRef(function (_a, ref) {
|
|
96
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
97
|
-
return (React.createElement(cmdk_1.Command.Group, __assign({ ref: ref, className: (0, utils_1.cn)("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground", className) }, props)));
|
|
98
|
-
});
|
|
99
|
-
exports.CommandGroup = CommandGroup;
|
|
100
|
-
CommandGroup.displayName = cmdk_1.Command.Group.displayName;
|
|
101
|
-
var CommandSeparator = React.forwardRef(function (_a, ref) {
|
|
102
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
103
|
-
return (React.createElement(cmdk_1.Command.Separator, __assign({ ref: ref, className: (0, utils_1.cn)("-mx-1 h-px bg-border", className) }, props)));
|
|
104
|
-
});
|
|
105
|
-
exports.CommandSeparator = CommandSeparator;
|
|
106
|
-
CommandSeparator.displayName = cmdk_1.Command.Separator.displayName;
|
|
107
|
-
var CommandItem = React.forwardRef(function (_a, ref) {
|
|
108
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
109
|
-
return (React.createElement(cmdk_1.Command.Item, __assign({ ref: ref, className: (0, utils_1.cn)("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0", className) }, props)));
|
|
110
|
-
});
|
|
111
|
-
exports.CommandItem = CommandItem;
|
|
112
|
-
CommandItem.displayName = cmdk_1.Command.Item.displayName;
|
|
113
|
-
var CommandShortcut = function (_a) {
|
|
114
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
115
|
-
return (React.createElement("span", __assign({ className: (0, utils_1.cn)("ml-auto text-xs tracking-widest text-muted-foreground", className) }, props)));
|
|
116
|
-
};
|
|
117
|
-
exports.CommandShortcut = CommandShortcut;
|
|
118
|
-
CommandShortcut.displayName = "CommandShortcut";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
const module = import("./command-impl");
|
|
4
|
+
const lazy = (name) => React.lazy(() => module.then((m) => ({ default: m[name] })));
|
|
5
|
+
export const Command = lazy("Command");
|
|
6
|
+
export const CommandDialog = lazy("CommandDialog");
|
|
7
|
+
export const CommandInput = lazy("CommandInput");
|
|
8
|
+
export const CommandList = lazy("CommandList");
|
|
9
|
+
export const CommandEmpty = lazy("CommandEmpty");
|
|
10
|
+
export const CommandGroup = lazy("CommandGroup");
|
|
11
|
+
export const CommandItem = lazy("CommandItem");
|
|
12
|
+
export const CommandShortcut = lazy("CommandShortcut");
|
|
13
|
+
export const CommandSeparator = lazy("CommandSeparator");
|
|
@@ -1,49 +1,4 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
var __assign = (this && this.__assign) || function () {
|
|
4
|
-
__assign = Object.assign || function(t) {
|
|
5
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
6
|
-
s = arguments[i];
|
|
7
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
8
|
-
t[p] = s[p];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
return __assign.apply(this, arguments);
|
|
13
|
-
};
|
|
14
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
15
|
-
if (k2 === undefined) k2 = k;
|
|
16
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
17
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
18
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
19
|
-
}
|
|
20
|
-
Object.defineProperty(o, k2, desc);
|
|
21
|
-
}) : (function(o, m, k, k2) {
|
|
22
|
-
if (k2 === undefined) k2 = k;
|
|
23
|
-
o[k2] = m[k];
|
|
24
|
-
}));
|
|
25
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
26
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
27
|
-
}) : function(o, v) {
|
|
28
|
-
o["default"] = v;
|
|
29
|
-
});
|
|
30
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
31
|
-
var ownKeys = function(o) {
|
|
32
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
33
|
-
var ar = [];
|
|
34
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
35
|
-
return ar;
|
|
36
|
-
};
|
|
37
|
-
return ownKeys(o);
|
|
38
|
-
};
|
|
39
|
-
return function (mod) {
|
|
40
|
-
if (mod && mod.__esModule) return mod;
|
|
41
|
-
var result = {};
|
|
42
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
43
|
-
__setModuleDefault(result, mod);
|
|
44
|
-
return result;
|
|
45
|
-
};
|
|
46
|
-
})();
|
|
47
2
|
var __rest = (this && this.__rest) || function (s, e) {
|
|
48
3
|
var t = {};
|
|
49
4
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
@@ -55,87 +10,71 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
55
10
|
}
|
|
56
11
|
return t;
|
|
57
12
|
};
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
exports.ContextMenuPortal = ContextMenuPortal;
|
|
72
|
-
var ContextMenuSub = ContextMenuPrimitive.Sub;
|
|
73
|
-
exports.ContextMenuSub = ContextMenuSub;
|
|
74
|
-
var ContextMenuRadioGroup = ContextMenuPrimitive.RadioGroup;
|
|
75
|
-
exports.ContextMenuRadioGroup = ContextMenuRadioGroup;
|
|
76
|
-
var ContextMenuSubTrigger = React.forwardRef(function (_a, ref) {
|
|
77
|
-
var className = _a.className, inset = _a.inset, children = _a.children, props = __rest(_a, ["className", "inset", "children"]);
|
|
78
|
-
return (React.createElement(ContextMenuPrimitive.SubTrigger, __assign({ ref: ref, className: (0, utils_1.cn)("flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground", inset && "pl-8", className) }, props),
|
|
13
|
+
import * as React from "react";
|
|
14
|
+
import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
|
|
15
|
+
import { cn } from "../../lib/utils";
|
|
16
|
+
import { CheckIcon, ChevronRightIcon, DotFilledIcon, } from "@radix-ui/react-icons";
|
|
17
|
+
const ContextMenu = ContextMenuPrimitive.Root;
|
|
18
|
+
const ContextMenuTrigger = ContextMenuPrimitive.Trigger;
|
|
19
|
+
const ContextMenuGroup = ContextMenuPrimitive.Group;
|
|
20
|
+
const ContextMenuPortal = ContextMenuPrimitive.Portal;
|
|
21
|
+
const ContextMenuSub = ContextMenuPrimitive.Sub;
|
|
22
|
+
const ContextMenuRadioGroup = ContextMenuPrimitive.RadioGroup;
|
|
23
|
+
const ContextMenuSubTrigger = React.forwardRef((_a, ref) => {
|
|
24
|
+
var { className, inset, children } = _a, props = __rest(_a, ["className", "inset", "children"]);
|
|
25
|
+
return (React.createElement(ContextMenuPrimitive.SubTrigger, Object.assign({ ref: ref, className: cn("flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground", inset && "pl-8", className) }, props),
|
|
79
26
|
children,
|
|
80
|
-
React.createElement(
|
|
27
|
+
React.createElement(ChevronRightIcon, { className: "ml-auto h-4 w-4" })));
|
|
81
28
|
});
|
|
82
|
-
exports.ContextMenuSubTrigger = ContextMenuSubTrigger;
|
|
83
29
|
ContextMenuSubTrigger.displayName = ContextMenuPrimitive.SubTrigger.displayName;
|
|
84
|
-
|
|
85
|
-
var className = _a
|
|
86
|
-
return (React.createElement(ContextMenuPrimitive.SubContent,
|
|
30
|
+
const ContextMenuSubContent = React.forwardRef((_a, ref) => {
|
|
31
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
32
|
+
return (React.createElement(ContextMenuPrimitive.SubContent, Object.assign({ ref: ref, className: cn("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]", className) }, props)));
|
|
87
33
|
});
|
|
88
|
-
exports.ContextMenuSubContent = ContextMenuSubContent;
|
|
89
34
|
ContextMenuSubContent.displayName = ContextMenuPrimitive.SubContent.displayName;
|
|
90
|
-
|
|
91
|
-
var className = _a
|
|
35
|
+
const ContextMenuContent = React.forwardRef((_a, ref) => {
|
|
36
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
92
37
|
return (React.createElement(ContextMenuPrimitive.Portal, null,
|
|
93
|
-
React.createElement(ContextMenuPrimitive.Content,
|
|
38
|
+
React.createElement(ContextMenuPrimitive.Content, Object.assign({ ref: ref, className: cn("z-50 max-h-[--radix-context-menu-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]", className) }, props))));
|
|
94
39
|
});
|
|
95
|
-
exports.ContextMenuContent = ContextMenuContent;
|
|
96
40
|
ContextMenuContent.displayName = ContextMenuPrimitive.Content.displayName;
|
|
97
|
-
|
|
98
|
-
var
|
|
99
|
-
return (React.createElement(ContextMenuPrimitive.Item,
|
|
41
|
+
const ContextMenuItem = React.forwardRef((_a, ref) => {
|
|
42
|
+
var { className, inset } = _a, props = __rest(_a, ["className", "inset"]);
|
|
43
|
+
return (React.createElement(ContextMenuPrimitive.Item, Object.assign({ ref: ref, className: cn("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50", inset && "pl-8", className) }, props)));
|
|
100
44
|
});
|
|
101
|
-
exports.ContextMenuItem = ContextMenuItem;
|
|
102
45
|
ContextMenuItem.displayName = ContextMenuPrimitive.Item.displayName;
|
|
103
|
-
|
|
104
|
-
var
|
|
105
|
-
return (React.createElement(ContextMenuPrimitive.CheckboxItem,
|
|
46
|
+
const ContextMenuCheckboxItem = React.forwardRef((_a, ref) => {
|
|
47
|
+
var { className, children, checked } = _a, props = __rest(_a, ["className", "children", "checked"]);
|
|
48
|
+
return (React.createElement(ContextMenuPrimitive.CheckboxItem, Object.assign({ ref: ref, className: cn("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50", className), checked: checked }, props),
|
|
106
49
|
React.createElement("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center" },
|
|
107
50
|
React.createElement(ContextMenuPrimitive.ItemIndicator, null,
|
|
108
|
-
React.createElement(
|
|
51
|
+
React.createElement(CheckIcon, { className: "h-4 w-4" }))),
|
|
109
52
|
children));
|
|
110
53
|
});
|
|
111
|
-
exports.ContextMenuCheckboxItem = ContextMenuCheckboxItem;
|
|
112
54
|
ContextMenuCheckboxItem.displayName =
|
|
113
55
|
ContextMenuPrimitive.CheckboxItem.displayName;
|
|
114
|
-
|
|
115
|
-
var
|
|
116
|
-
return (React.createElement(ContextMenuPrimitive.RadioItem,
|
|
56
|
+
const ContextMenuRadioItem = React.forwardRef((_a, ref) => {
|
|
57
|
+
var { className, children } = _a, props = __rest(_a, ["className", "children"]);
|
|
58
|
+
return (React.createElement(ContextMenuPrimitive.RadioItem, Object.assign({ ref: ref, className: cn("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50", className) }, props),
|
|
117
59
|
React.createElement("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center" },
|
|
118
60
|
React.createElement(ContextMenuPrimitive.ItemIndicator, null,
|
|
119
|
-
React.createElement(
|
|
61
|
+
React.createElement(DotFilledIcon, { className: "h-4 w-4 fill-current" }))),
|
|
120
62
|
children));
|
|
121
63
|
});
|
|
122
|
-
exports.ContextMenuRadioItem = ContextMenuRadioItem;
|
|
123
64
|
ContextMenuRadioItem.displayName = ContextMenuPrimitive.RadioItem.displayName;
|
|
124
|
-
|
|
125
|
-
var
|
|
126
|
-
return (React.createElement(ContextMenuPrimitive.Label,
|
|
65
|
+
const ContextMenuLabel = React.forwardRef((_a, ref) => {
|
|
66
|
+
var { className, inset } = _a, props = __rest(_a, ["className", "inset"]);
|
|
67
|
+
return (React.createElement(ContextMenuPrimitive.Label, Object.assign({ ref: ref, className: cn("px-2 py-1.5 text-sm font-semibold text-foreground", inset && "pl-8", className) }, props)));
|
|
127
68
|
});
|
|
128
|
-
exports.ContextMenuLabel = ContextMenuLabel;
|
|
129
69
|
ContextMenuLabel.displayName = ContextMenuPrimitive.Label.displayName;
|
|
130
|
-
|
|
131
|
-
var className = _a
|
|
132
|
-
return (React.createElement(ContextMenuPrimitive.Separator,
|
|
70
|
+
const ContextMenuSeparator = React.forwardRef((_a, ref) => {
|
|
71
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
72
|
+
return (React.createElement(ContextMenuPrimitive.Separator, Object.assign({ ref: ref, className: cn("-mx-1 my-1 h-px bg-border", className) }, props)));
|
|
133
73
|
});
|
|
134
|
-
exports.ContextMenuSeparator = ContextMenuSeparator;
|
|
135
74
|
ContextMenuSeparator.displayName = ContextMenuPrimitive.Separator.displayName;
|
|
136
|
-
|
|
137
|
-
var className = _a
|
|
138
|
-
return (React.createElement("span",
|
|
75
|
+
const ContextMenuShortcut = (_a) => {
|
|
76
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
77
|
+
return (React.createElement("span", Object.assign({ className: cn("ml-auto text-xs tracking-widest text-muted-foreground", className) }, props)));
|
|
139
78
|
};
|
|
140
|
-
exports.ContextMenuShortcut = ContextMenuShortcut;
|
|
141
79
|
ContextMenuShortcut.displayName = "ContextMenuShortcut";
|
|
80
|
+
export { ContextMenu, ContextMenuTrigger, ContextMenuContent, ContextMenuItem, ContextMenuCheckboxItem, ContextMenuRadioItem, ContextMenuLabel, ContextMenuSeparator, ContextMenuShortcut, ContextMenuGroup, ContextMenuPortal, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuRadioGroup, };
|
package/components/ui/dialog.js
CHANGED
|
@@ -1,49 +1,4 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";
|
|
3
|
-
var __assign = (this && this.__assign) || function () {
|
|
4
|
-
__assign = Object.assign || function(t) {
|
|
5
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
6
|
-
s = arguments[i];
|
|
7
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
8
|
-
t[p] = s[p];
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
};
|
|
12
|
-
return __assign.apply(this, arguments);
|
|
13
|
-
};
|
|
14
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
15
|
-
if (k2 === undefined) k2 = k;
|
|
16
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
17
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
18
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
19
|
-
}
|
|
20
|
-
Object.defineProperty(o, k2, desc);
|
|
21
|
-
}) : (function(o, m, k, k2) {
|
|
22
|
-
if (k2 === undefined) k2 = k;
|
|
23
|
-
o[k2] = m[k];
|
|
24
|
-
}));
|
|
25
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
26
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
27
|
-
}) : function(o, v) {
|
|
28
|
-
o["default"] = v;
|
|
29
|
-
});
|
|
30
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
31
|
-
var ownKeys = function(o) {
|
|
32
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
33
|
-
var ar = [];
|
|
34
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
35
|
-
return ar;
|
|
36
|
-
};
|
|
37
|
-
return ownKeys(o);
|
|
38
|
-
};
|
|
39
|
-
return function (mod) {
|
|
40
|
-
if (mod && mod.__esModule) return mod;
|
|
41
|
-
var result = {};
|
|
42
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
43
|
-
__setModuleDefault(result, mod);
|
|
44
|
-
return result;
|
|
45
|
-
};
|
|
46
|
-
})();
|
|
47
2
|
var __rest = (this && this.__rest) || function (s, e) {
|
|
48
3
|
var t = {};
|
|
49
4
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
@@ -55,59 +10,48 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
55
10
|
}
|
|
56
11
|
return t;
|
|
57
12
|
};
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
exports.DialogPortal = DialogPortal;
|
|
70
|
-
var DialogClose = DialogPrimitive.Close;
|
|
71
|
-
exports.DialogClose = DialogClose;
|
|
72
|
-
var DialogOverlay = React.forwardRef(function (_a, ref) {
|
|
73
|
-
var className = _a.className, props = __rest(_a, ["className"]);
|
|
74
|
-
return (React.createElement(DialogPrimitive.Overlay, __assign({ ref: ref, className: (0, utils_1.cn)("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", className) }, props)));
|
|
13
|
+
import * as React from "react";
|
|
14
|
+
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
15
|
+
import { cn } from "../../lib/utils";
|
|
16
|
+
import { Cross2Icon } from "@radix-ui/react-icons";
|
|
17
|
+
const Dialog = DialogPrimitive.Root;
|
|
18
|
+
const DialogTrigger = DialogPrimitive.Trigger;
|
|
19
|
+
const DialogPortal = DialogPrimitive.Portal;
|
|
20
|
+
const DialogClose = DialogPrimitive.Close;
|
|
21
|
+
const DialogOverlay = React.forwardRef((_a, ref) => {
|
|
22
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
23
|
+
return (React.createElement(DialogPrimitive.Overlay, Object.assign({ ref: ref, className: cn("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0", className) }, props)));
|
|
75
24
|
});
|
|
76
|
-
exports.DialogOverlay = DialogOverlay;
|
|
77
25
|
DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
|
|
78
|
-
|
|
79
|
-
var
|
|
26
|
+
const DialogContent = React.forwardRef((_a, ref) => {
|
|
27
|
+
var { className, children } = _a, props = __rest(_a, ["className", "children"]);
|
|
80
28
|
return (React.createElement(DialogPortal, null,
|
|
81
29
|
React.createElement(DialogOverlay, null),
|
|
82
|
-
React.createElement(DialogPrimitive.Content,
|
|
30
|
+
React.createElement(DialogPrimitive.Content, Object.assign({ ref: ref, className: cn("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg", className) }, props),
|
|
83
31
|
children,
|
|
84
32
|
React.createElement(DialogPrimitive.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground" },
|
|
85
|
-
React.createElement(
|
|
33
|
+
React.createElement(Cross2Icon, { className: "h-4 w-4" }),
|
|
86
34
|
React.createElement("span", { className: "sr-only" }, "Close")))));
|
|
87
35
|
});
|
|
88
|
-
exports.DialogContent = DialogContent;
|
|
89
36
|
DialogContent.displayName = DialogPrimitive.Content.displayName;
|
|
90
|
-
|
|
91
|
-
var className = _a
|
|
92
|
-
return (React.createElement("div",
|
|
37
|
+
const DialogHeader = (_a) => {
|
|
38
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
39
|
+
return (React.createElement("div", Object.assign({ className: cn("flex flex-col space-y-1.5 text-center sm:text-left", className) }, props)));
|
|
93
40
|
};
|
|
94
|
-
exports.DialogHeader = DialogHeader;
|
|
95
41
|
DialogHeader.displayName = "DialogHeader";
|
|
96
|
-
|
|
97
|
-
var className = _a
|
|
98
|
-
return (React.createElement("div",
|
|
42
|
+
const DialogFooter = (_a) => {
|
|
43
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
44
|
+
return (React.createElement("div", Object.assign({ className: cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", className) }, props)));
|
|
99
45
|
};
|
|
100
|
-
exports.DialogFooter = DialogFooter;
|
|
101
46
|
DialogFooter.displayName = "DialogFooter";
|
|
102
|
-
|
|
103
|
-
var className = _a
|
|
104
|
-
return (React.createElement(DialogPrimitive.Title,
|
|
47
|
+
const DialogTitle = React.forwardRef((_a, ref) => {
|
|
48
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
49
|
+
return (React.createElement(DialogPrimitive.Title, Object.assign({ ref: ref, className: cn("text-lg font-semibold leading-none tracking-tight", className) }, props)));
|
|
105
50
|
});
|
|
106
|
-
exports.DialogTitle = DialogTitle;
|
|
107
51
|
DialogTitle.displayName = DialogPrimitive.Title.displayName;
|
|
108
|
-
|
|
109
|
-
var className = _a
|
|
110
|
-
return (React.createElement(DialogPrimitive.Description,
|
|
52
|
+
const DialogDescription = React.forwardRef((_a, ref) => {
|
|
53
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
|
54
|
+
return (React.createElement(DialogPrimitive.Description, Object.assign({ ref: ref, className: cn("text-sm text-muted-foreground", className) }, props)));
|
|
111
55
|
});
|
|
112
|
-
exports.DialogDescription = DialogDescription;
|
|
113
56
|
DialogDescription.displayName = DialogPrimitive.Description.displayName;
|
|
57
|
+
export { Dialog, DialogPortal, DialogOverlay, DialogTrigger, DialogClose, DialogContent, DialogHeader, DialogFooter, DialogTitle, DialogDescription, };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Drawer as DrawerPrimitive } from "vaul";
|
|
3
|
+
declare const Drawer: {
|
|
4
|
+
({ shouldScaleBackground, ...props }: React.ComponentProps<typeof DrawerPrimitive.Root>): React.JSX.Element;
|
|
5
|
+
displayName: string;
|
|
6
|
+
};
|
|
7
|
+
declare const DrawerTrigger: React.ForwardRefExoticComponent<import("@radix-ui/react-dialog").DialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
8
|
+
declare const DrawerPortal: typeof import("vaul").Portal;
|
|
9
|
+
declare const DrawerClose: React.ForwardRefExoticComponent<import("@radix-ui/react-dialog").DialogCloseProps & React.RefAttributes<HTMLButtonElement>>;
|
|
10
|
+
declare const DrawerOverlay: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
11
|
+
declare const DrawerContent: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
+
declare const DrawerHeader: {
|
|
13
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
|
|
14
|
+
displayName: string;
|
|
15
|
+
};
|
|
16
|
+
declare const DrawerFooter: {
|
|
17
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
|
|
18
|
+
displayName: string;
|
|
19
|
+
};
|
|
20
|
+
declare const DrawerTitle: React.ForwardRefExoticComponent<Omit<import("@radix-ui/react-dialog").DialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
21
|
+
declare const DrawerDescription: React.ForwardRefExoticComponent<Omit<import("@radix-ui/react-dialog").DialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
22
|
+
export { Drawer, DrawerPortal, DrawerOverlay, DrawerTrigger, DrawerClose, DrawerContent, DrawerHeader, DrawerFooter, DrawerTitle, DrawerDescription, };
|