diff --git a/packages/shadcn-ui/src/components/button-group.tsx b/packages/shadcn-ui/src/components/button-group.tsx index 94bd11b9..61e8cb9e 100644 --- a/packages/shadcn-ui/src/components/button-group.tsx +++ b/packages/shadcn-ui/src/components/button-group.tsx @@ -1,8 +1,7 @@ -import { Slot } from "@radix-ui/react-slot" -import { cva, type VariantProps } from "class-variance-authority" - -import { cn } from "@repo/shadcn-ui/lib/utils" -import { Separator } from "@repo/shadcn-ui/components/separator" +import { Slot } from "@radix-ui/react-slot"; +import { Separator } from "@repo/shadcn-ui/components/separator"; +import { cn } from "@repo/shadcn-ui/lib/utils"; +import { type VariantProps, cva } from "class-variance-authority"; const buttonGroupVariants = cva( "flex w-fit items-stretch [&>*]:focus-visible:z-10 [&>*]:focus-visible:relative [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-md has-[>[data-slot=button-group]]:gap-2", @@ -19,7 +18,7 @@ const buttonGroupVariants = cva( orientation: "horizontal", }, } -) +); function ButtonGroup({ className, @@ -28,13 +27,13 @@ function ButtonGroup({ }: React.ComponentProps<"div"> & VariantProps) { return (
- ) + ); } function ButtonGroupText({ @@ -42,9 +41,9 @@ function ButtonGroupText({ asChild = false, ...props }: React.ComponentProps<"div"> & { - asChild?: boolean + asChild?: boolean; }) { - const Comp = asChild ? Slot : "div" + const Comp = asChild ? Slot : "div"; return ( - ) + ); } function ButtonGroupSeparator({ @@ -64,20 +63,15 @@ function ButtonGroupSeparator({ }: React.ComponentProps) { return ( - ) + ); } -export { - ButtonGroup, - ButtonGroupSeparator, - ButtonGroupText, - buttonGroupVariants, -} +export { ButtonGroup, ButtonGroupSeparator, ButtonGroupText, buttonGroupVariants };