lecom-ui 2.1.6 → 2.1.7

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.
@@ -0,0 +1,86 @@
1
+ import * as React from 'react';
2
+ import { cn } from '../../lib/utils.js';
3
+ import * as SheetPrimitive from '@radix-ui/react-dialog';
4
+ import { X } from 'lucide-react';
5
+
6
+ const Dialog = SheetPrimitive.Root;
7
+ const DialogTrigger = SheetPrimitive.Trigger;
8
+ const DialogPortal = SheetPrimitive.Portal;
9
+ const DialogClose = SheetPrimitive.Close;
10
+ const DialogOverlay = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React.createElement(
11
+ SheetPrimitive.Overlay,
12
+ {
13
+ ref,
14
+ className: cn(
15
+ "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",
16
+ className
17
+ ),
18
+ ...props
19
+ }
20
+ ));
21
+ DialogOverlay.displayName = SheetPrimitive.Overlay.displayName;
22
+ const DialogContent = React.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ React.createElement(DialogPortal, null, /* @__PURE__ */ React.createElement(DialogOverlay, null), /* @__PURE__ */ React.createElement(
23
+ SheetPrimitive.Content,
24
+ {
25
+ ref,
26
+ className: cn(
27
+ "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",
28
+ className
29
+ ),
30
+ ...props
31
+ },
32
+ children,
33
+ /* @__PURE__ */ React.createElement(SheetPrimitive.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" }, /* @__PURE__ */ React.createElement(X, { className: "h-4 w-4" }), /* @__PURE__ */ React.createElement("span", { className: "sr-only" }, "Close"))
34
+ )));
35
+ DialogContent.displayName = SheetPrimitive.Content.displayName;
36
+ const DialogHeader = ({
37
+ className,
38
+ ...props
39
+ }) => /* @__PURE__ */ React.createElement(
40
+ "div",
41
+ {
42
+ className: cn(
43
+ "flex flex-col space-y-1.5 text-center sm:text-left",
44
+ className
45
+ ),
46
+ ...props
47
+ }
48
+ );
49
+ DialogHeader.displayName = "DialogHeader";
50
+ const DialogFooter = ({
51
+ className,
52
+ ...props
53
+ }) => /* @__PURE__ */ React.createElement(
54
+ "div",
55
+ {
56
+ className: cn(
57
+ "flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
58
+ className
59
+ ),
60
+ ...props
61
+ }
62
+ );
63
+ DialogFooter.displayName = "DialogFooter";
64
+ const DialogTitle = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React.createElement(
65
+ SheetPrimitive.Title,
66
+ {
67
+ ref,
68
+ className: cn(
69
+ "text-lg font-semibold leading-none tracking-tight",
70
+ className
71
+ ),
72
+ ...props
73
+ }
74
+ ));
75
+ DialogTitle.displayName = SheetPrimitive.Title.displayName;
76
+ const DialogDescription = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React.createElement(
77
+ SheetPrimitive.Description,
78
+ {
79
+ ref,
80
+ className: cn("text-sm text-muted-foreground", className),
81
+ ...props
82
+ }
83
+ ));
84
+ DialogDescription.displayName = SheetPrimitive.Description.displayName;
85
+
86
+ export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger };
package/dist/index.d.ts CHANGED
@@ -3,6 +3,7 @@ import * as React$1 from 'react';
3
3
  import { VariantProps } from 'class-variance-authority';
4
4
  import { CustomStyles as CustomStyles$2 } from '@/components/Button';
5
5
  import * as PopoverPrimitive from '@radix-ui/react-popover';
6
+ import * as DialogPrimitive from '@radix-ui/react-dialog';
6
7
 
7
8
  type Transparent = 'transparent';
8
9
  type Black = 'black';
@@ -335,4 +336,21 @@ declare const Popover: React$1.FC<PopoverPrimitive.PopoverProps>;
335
336
  declare const PopoverTrigger: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
336
337
  declare const PopoverContent: React$1.ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
337
338
 
338
- export { type BgColor, Button, type ButtonProps, CadastroFacil, type CadastroFacilProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type Color, type ColorToken, type CustomStyles$1 as CustomStyles, type FillColor, type Fonts, Header, type HeaderProps, Layout, type LayoutProps, LogoLecom, type LogoLecomProps, ModoTeste, type ModoTesteProps, Popover, PopoverContent, PopoverTrigger, Rpa, type RpaProps, type SideBarProps, Skeleton, type TextColor, Typography, type TypographyProps, buttonVariants, colors, fonts, headerVariants, typographyVariants };
339
+ declare const Dialog: React$1.FC<DialogPrimitive.DialogProps>;
340
+ declare const DialogTrigger: React$1.ForwardRefExoticComponent<DialogPrimitive.DialogTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
341
+ declare const DialogPortal: React$1.FC<DialogPrimitive.DialogPortalProps>;
342
+ declare const DialogClose: React$1.ForwardRefExoticComponent<DialogPrimitive.DialogCloseProps & React$1.RefAttributes<HTMLButtonElement>>;
343
+ declare const DialogOverlay: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
344
+ declare const DialogContent: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
345
+ declare const DialogHeader: {
346
+ ({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
347
+ displayName: string;
348
+ };
349
+ declare const DialogFooter: {
350
+ ({ className, ...props }: React$1.HTMLAttributes<HTMLDivElement>): React$1.JSX.Element;
351
+ displayName: string;
352
+ };
353
+ declare const DialogTitle: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogTitleProps & React$1.RefAttributes<HTMLHeadingElement>, "ref"> & React$1.RefAttributes<HTMLHeadingElement>>;
354
+ declare const DialogDescription: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogDescriptionProps & React$1.RefAttributes<HTMLParagraphElement>, "ref"> & React$1.RefAttributes<HTMLParagraphElement>>;
355
+
356
+ export { type BgColor, Button, type ButtonProps, CadastroFacil, type CadastroFacilProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type Color, type ColorToken, type CustomStyles$1 as CustomStyles, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type FillColor, type Fonts, Header, type HeaderProps, Layout, type LayoutProps, LogoLecom, type LogoLecomProps, ModoTeste, type ModoTesteProps, Popover, PopoverContent, PopoverTrigger, Rpa, type RpaProps, type SideBarProps, Skeleton, type TextColor, Typography, type TypographyProps, buttonVariants, colors, fonts, headerVariants, typographyVariants };
package/dist/index.js CHANGED
@@ -11,3 +11,4 @@ export { ModoTeste } from './components/CustomIcon/Icons/ModoTeste.js';
11
11
  export { Rpa } from './components/CustomIcon/Icons/Rpa.js';
12
12
  export { Header, headerVariants } from './components/Header/Header.js';
13
13
  export { Popover, PopoverContent, PopoverTrigger } from './components/Popover/Popover.js';
14
+ export { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger } from './components/Dialog/Dialog.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lecom-ui",
3
- "version": "2.1.6",
3
+ "version": "2.1.7",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "module": "dist/index.js",