mirror of
https://github.com/lukevella/rallly.git
synced 2025-06-19 11:01:59 +02:00
💄 Upate dialog styles
This commit is contained in:
parent
8001256dc1
commit
e3eaee864f
1 changed files with 9 additions and 5 deletions
|
@ -5,6 +5,8 @@ import { XIcon } from "lucide-react";
|
||||||
import * as React from "react";
|
import * as React from "react";
|
||||||
|
|
||||||
import { cn } from "./lib/utils";
|
import { cn } from "./lib/utils";
|
||||||
|
import { Button } from "./button";
|
||||||
|
import { Icon } from "./icon";
|
||||||
|
|
||||||
export type { DialogProps } from "@radix-ui/react-dialog";
|
export type { DialogProps } from "@radix-ui/react-dialog";
|
||||||
|
|
||||||
|
@ -59,12 +61,14 @@ const DialogContent = React.forwardRef<
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
{!hideCloseButton ? (
|
{!hideCloseButton ? (
|
||||||
<DialogPrimitive.Close className="ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none">
|
<DialogClose asChild className="absolute right-4 top-4">
|
||||||
<>
|
<Button size="icon" variant="ghost">
|
||||||
<XIcon className="size-4" />
|
<Icon>
|
||||||
|
<XIcon />
|
||||||
|
</Icon>
|
||||||
<span className="sr-only">Close</span>
|
<span className="sr-only">Close</span>
|
||||||
</>
|
</Button>
|
||||||
</DialogPrimitive.Close>
|
</DialogClose>
|
||||||
) : null}
|
) : null}
|
||||||
</DialogPrimitive.Content>
|
</DialogPrimitive.Content>
|
||||||
</DialogPortal>
|
</DialogPortal>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue