Function
MenubarSubTrigger
({
className,
inset,
children,
...props
}: React.ComponentProps<typeof MenubarPrimitive.SubTrigger> & {
inset?: boolean;
})
Source from the content-addressed store, hash-verified
| 193 | } |
| 194 | |
| 195 | function MenubarSubTrigger({ |
| 196 | className, |
| 197 | inset, |
| 198 | children, |
| 199 | ...props |
| 200 | }: React.ComponentProps<typeof MenubarPrimitive.SubTrigger> & { |
| 201 | inset?: boolean; |
| 202 | }) { |
| 203 | return ( |
| 204 | <MenubarPrimitive.SubTrigger |
| 205 | data-slot="menubar-sub-trigger" |
| 206 | data-inset={inset} |
| 207 | className={cn( |
| 208 | "flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-none select-none focus:bg-accent focus:text-accent-foreground data-[inset]:pl-8 data-[state=open]:bg-accent data-[state=open]:text-accent-foreground", |
| 209 | className, |
| 210 | )} |
| 211 | {...props} |
| 212 | > |
| 213 | {children} |
| 214 | <ChevronRightIcon className="ml-auto h-4 w-4" /> |
| 215 | </MenubarPrimitive.SubTrigger> |
| 216 | ); |
| 217 | } |
| 218 | |
| 219 | function MenubarSubContent({ |
| 220 | className, |
Callers
nothing calls this directly
Tested by
no test coverage detected