11"use client"
22
33import * as React from "react"
4+
45import * as MenubarPrimitive from "@radix-ui/react-menubar"
56import { Check , ChevronRight , Circle } from "lucide-react"
67
@@ -85,26 +86,21 @@ MenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName
8586const MenubarContent = React . forwardRef <
8687 React . ElementRef < typeof MenubarPrimitive . Content > ,
8788 React . ComponentPropsWithoutRef < typeof MenubarPrimitive . Content >
88- > (
89- (
90- { className, align = "start" , alignOffset = - 4 , sideOffset = 8 , ...props } ,
91- ref
92- ) => (
93- < MenubarPrimitive . Portal >
94- < MenubarPrimitive . Content
95- ref = { ref }
96- align = { align }
97- alignOffset = { alignOffset }
98- sideOffset = { sideOffset }
99- className = { cn (
100- "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in 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" ,
101- className
102- ) }
103- { ...props }
104- />
105- </ MenubarPrimitive . Portal >
106- )
107- )
89+ > ( ( { className, align = "start" , alignOffset = - 4 , sideOffset = 8 , ...props } , ref ) => (
90+ < MenubarPrimitive . Portal >
91+ < MenubarPrimitive . Content
92+ ref = { ref }
93+ align = { align }
94+ alignOffset = { alignOffset }
95+ sideOffset = { sideOffset }
96+ className = { cn (
97+ "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in 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" ,
98+ className
99+ ) }
100+ { ...props }
101+ />
102+ </ MenubarPrimitive . Portal >
103+ ) )
108104MenubarContent . displayName = MenubarPrimitive . Content . displayName
109105
110106const MenubarItem = React . forwardRef <
@@ -178,11 +174,7 @@ const MenubarLabel = React.forwardRef<
178174> ( ( { className, inset, ...props } , ref ) => (
179175 < MenubarPrimitive . Label
180176 ref = { ref }
181- className = { cn (
182- "px-2 py-1.5 text-sm font-semibold" ,
183- inset && "pl-8" ,
184- className
185- ) }
177+ className = { cn ( "px-2 py-1.5 text-sm font-semibold" , inset && "pl-8" , className ) }
186178 { ...props }
187179 />
188180) )
@@ -200,16 +192,10 @@ const MenubarSeparator = React.forwardRef<
200192) )
201193MenubarSeparator . displayName = MenubarPrimitive . Separator . displayName
202194
203- const MenubarShortcut = ( {
204- className,
205- ...props
206- } : React . HTMLAttributes < HTMLSpanElement > ) => {
195+ const MenubarShortcut = ( { className, ...props } : React . HTMLAttributes < HTMLSpanElement > ) => {
207196 return (
208197 < span
209- className = { cn (
210- "ml-auto text-xs tracking-widest text-muted-foreground" ,
211- className
212- ) }
198+ className = { cn ( "ml-auto text-xs tracking-widest text-muted-foreground" , className ) }
213199 { ...props }
214200 />
215201 )
0 commit comments