{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "menubar",
  "type": "registry:ui",
  "dependencies": [
    "@kobalte/core",
    "lucide-solid"
  ],
  "files": [
    {
      "path": "ui/menubar.tsx",
      "content": "import type { Component, ComponentProps, JSX, ValidComponent } from \"solid-js\"\nimport { mergeProps, splitProps } from \"solid-js\"\n\nimport * as MenubarPrimitive from \"@kobalte/core/menubar\"\nimport type { PolymorphicProps } from \"@kobalte/core/polymorphic\"\nimport { Check, ChevronRight, Dot } from \"lucide-solid\"\n\nimport { cn } from \"@/lib/utils\"\n\ntype MenubarRootProps<T extends ValidComponent = \"div\"> = MenubarPrimitive.MenubarRootProps<T> & {\n  class?: string | undefined\n}\n\nconst Menubar = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarRootProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarRootProps, [\"class\"])\n  return (\n    <MenubarPrimitive.Root class={cn(\"cn-menubar\", local.class)} data-slot=\"menubar\" {...others} />\n  )\n}\n\nconst MenubarMenu: Component<MenubarPrimitive.MenubarMenuProps> = (props) => {\n  return <MenubarPrimitive.Menu data-slot=\"menubar-menu\" {...props} />\n}\n\nconst MenubarGroup: Component<MenubarPrimitive.MenubarGroupProps> = (props) => {\n  return <MenubarPrimitive.Group data-slot=\"menubar-group\" {...props} />\n}\n\nconst MenubarPortal: Component<MenubarPrimitive.MenubarPortalProps> = (props) => {\n  return <MenubarPrimitive.Portal data-slot=\"menubar-portal\" {...props} />\n}\n\ntype MenubarRadioGroupProps<\n  T extends ValidComponent = \"div\",\n  TValue = string\n> = MenubarPrimitive.MenubarRadioGroupProps<T, TValue>\n\nconst MenubarRadioGroup = <T extends ValidComponent = \"div\", TValue = string>(\n  props: PolymorphicProps<T, MenubarRadioGroupProps<T, TValue>>\n) => <MenubarPrimitive.RadioGroup data-slot=\"menubar-radio-group\" {...props} />\n\ntype MenubarTriggerProps<T extends ValidComponent = \"button\"> =\n  MenubarPrimitive.MenubarTriggerProps<T> & {\n    class?: string | undefined\n  }\n\nconst MenubarTrigger = <T extends ValidComponent = \"button\">(\n  props: PolymorphicProps<T, MenubarTriggerProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarTriggerProps, [\"class\"])\n  return (\n    <MenubarPrimitive.Trigger\n      class={cn(\"cn-menubar-trigger\", local.class)}\n      data-slot=\"menubar-trigger\"\n      {...others}\n    />\n  )\n}\n\ntype MenubarContentProps<T extends ValidComponent = \"div\"> =\n  MenubarPrimitive.MenubarContentProps<T> & {\n    class?: string | undefined\n  }\n\nconst MenubarContent = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarContentProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarContentProps, [\"class\"])\n  return (\n    <MenubarPrimitive.Portal>\n      <MenubarPrimitive.Content\n        class={cn(\"cn-menubar-content\", local.class)}\n        data-slot=\"menubar-content\"\n        {...others}\n      />\n    </MenubarPrimitive.Portal>\n  )\n}\n\ntype MenubarItemProps<T extends ValidComponent = \"div\"> = MenubarPrimitive.MenubarItemProps<T> & {\n  class?: string | undefined\n  inset?: boolean\n  variant?: \"default\" | \"destructive\"\n}\n\nconst MenubarItem = <T extends ValidComponent = \"div\">(\n  rawProps: PolymorphicProps<T, MenubarItemProps<T>>\n) => {\n  const props = mergeProps({ variant: \"default\" }, rawProps)\n  const [local, others] = splitProps(props as MenubarItemProps, [\"class\", \"inset\", \"variant\"])\n  return (\n    <MenubarPrimitive.Item\n      class={cn(\n        \"cn-menubar-item group/menubar-item relative flex cursor-default select-none items-center outline-hidden data-[disabled]:pointer-events-none data-[inset]:pl-8 data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n        local.class\n      )}\n      data-inset={local.inset}\n      data-slot=\"menubar-item\"\n      data-variant={local.variant}\n      {...others}\n    />\n  )\n}\n\ntype MenubarCheckboxItemProps<T extends ValidComponent = \"div\"> =\n  MenubarPrimitive.MenubarCheckboxItemProps<T> & {\n    class?: string | undefined\n    children?: JSX.Element\n  }\n\nconst MenubarCheckboxItem = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarCheckboxItemProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarCheckboxItemProps, [\"class\", \"children\"])\n  return (\n    <MenubarPrimitive.CheckboxItem\n      class={cn(\n        \"cn-menubar-checkbox-item relative flex cursor-default select-none items-center outline-hidden data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n        local.class\n      )}\n      data-slot=\"menubar-checkbox-item\"\n      {...others}\n    >\n      <span\n        class=\"cn-menubar-item-indicator pointer-events-none\"\n        data-slot=\"menubar-checkbox-item-indicator\"\n      >\n        <MenubarPrimitive.ItemIndicator>\n          <Check />\n        </MenubarPrimitive.ItemIndicator>\n      </span>\n      {local.children}\n    </MenubarPrimitive.CheckboxItem>\n  )\n}\n\ntype MenubarRadioItemProps<T extends ValidComponent = \"div\"> =\n  MenubarPrimitive.MenubarRadioItemProps<T> & {\n    class?: string | undefined\n    children?: JSX.Element\n  }\n\nconst MenubarRadioItem = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarRadioItemProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarRadioItemProps, [\"class\", \"children\"])\n  return (\n    <MenubarPrimitive.RadioItem\n      class={cn(\n        \"cn-menubar-radio-item relative flex cursor-default select-none items-center outline-hidden data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n        local.class\n      )}\n      data-slot=\"menubar-radio-item\"\n      {...others}\n    >\n      <MenubarPrimitive.ItemIndicator\n        class=\"cn-menubar-item-indicator pointer-events-none\"\n        data-slot=\"menubar-radio-item-indicator\"\n      >\n        <Dot />\n      </MenubarPrimitive.ItemIndicator>\n      {local.children}\n    </MenubarPrimitive.RadioItem>\n  )\n}\n\ntype MenubarLabelProps<T extends ValidComponent = \"span\"> =\n  MenubarPrimitive.MenubarGroupLabelProps<T> & {\n    class?: string | undefined\n    inset?: boolean\n  }\n\nconst MenubarLabel = <T extends ValidComponent = \"span\">(\n  props: PolymorphicProps<T, MenubarLabelProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarLabelProps, [\"class\", \"inset\"])\n  return (\n    <MenubarPrimitive.GroupLabel\n      class={cn(\"cn-menubar-label data-[inset]:pl-8\", local.class)}\n      data-inset={local.inset}\n      data-slot=\"menubar-label\"\n      {...others}\n    />\n  )\n}\n\ntype MenubarSeparatorProps<T extends ValidComponent = \"hr\"> =\n  MenubarPrimitive.MenubarSeparatorProps<T> & {\n    class?: string | undefined\n  }\n\nconst MenubarSeparator = <T extends ValidComponent = \"hr\">(\n  props: PolymorphicProps<T, MenubarSeparatorProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarSeparatorProps, [\"class\"])\n  return (\n    <MenubarPrimitive.Separator\n      class={cn(\"cn-menubar-separator\", local.class)}\n      data-slot=\"menubar-separator\"\n      {...others}\n    />\n  )\n}\n\nconst MenubarShortcut: Component<ComponentProps<\"span\">> = (props) => {\n  const [local, others] = splitProps(props, [\"class\"])\n  return (\n    <span class={cn(\"cn-menubar-shortcut\", local.class)} data-slot=\"menubar-shortcut\" {...others} />\n  )\n}\n\nconst MenubarSub: Component<MenubarPrimitive.MenubarSubProps> = (props) => {\n  return <MenubarPrimitive.Sub data-slot=\"menubar-sub\" {...props} />\n}\n\ntype MenubarSubTriggerProps<T extends ValidComponent = \"div\"> =\n  MenubarPrimitive.MenubarSubTriggerProps<T> & {\n    class?: string | undefined\n    inset?: boolean\n    children?: JSX.Element\n  }\n\nconst MenubarSubTrigger = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarSubTriggerProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarSubTriggerProps, [\n    \"class\",\n    \"inset\",\n    \"children\"\n  ])\n  return (\n    <MenubarPrimitive.SubTrigger\n      class={cn(\n        \"cn-menubar-sub-trigger flex cursor-default select-none items-center outline-hidden data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0\",\n        local.class\n      )}\n      data-inset={local.inset}\n      data-slot=\"menubar-sub-trigger\"\n      {...others}\n    >\n      {local.children}\n      <ChevronRight />\n    </MenubarPrimitive.SubTrigger>\n  )\n}\n\ntype MenubarSubContentProps<T extends ValidComponent = \"div\"> =\n  MenubarPrimitive.MenubarSubContentProps<T> & {\n    class?: string | undefined\n  }\n\nconst MenubarSubContent = <T extends ValidComponent = \"div\">(\n  props: PolymorphicProps<T, MenubarSubContentProps<T>>\n) => {\n  const [local, others] = splitProps(props as MenubarSubContentProps, [\"class\"])\n  return (\n    <MenubarPrimitive.SubContent\n      class={cn(\"cn-menubar-sub-content\", local.class)}\n      data-slot=\"menubar-sub-content\"\n      {...others}\n    />\n  )\n}\n\nexport {\n  Menubar,\n  MenubarMenu,\n  MenubarTrigger,\n  MenubarContent,\n  MenubarItem,\n  MenubarCheckboxItem,\n  MenubarRadioGroup,\n  MenubarRadioItem,\n  MenubarLabel,\n  MenubarSeparator,\n  MenubarShortcut,\n  MenubarSub,\n  MenubarSubTrigger,\n  MenubarSubContent,\n  MenubarGroup,\n  MenubarPortal\n}\n",
      "type": "registry:ui"
    }
  ]
}