{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "A menu item: an optional icon, the label and an optional trailing mark (a check for selected items). tabindex -1: the menu moves focus with the arrow keys.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "// Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n/**\n * A menu item: an optional icon, the label and an optional trailing mark (a check for selected items). tabindex\n * -1: the menu moves focus with the arrow keys.\n */\nimport { type JSX } from \"solid-js\";\nimport { ButtonPlain, Inline } from \"../compose\";\nimport { cn } from \"../utils\";\n\nexport type DropdownItemProps = {\n  selected?: boolean;\n  class?: string;\n  children?: JSX.Element;\n  icon?: JSX.Element;\n  right?: JSX.Element;\n  onClick?: () => void;\n};\n\nexport function DropdownItem({\n  selected = false,\n  class: className,\n  children,\n  icon,\n  right,\n  onClick,\n}: DropdownItemProps) {\n  return (\n    <ButtonPlain\n      type=\"button\"\n      role=\"menuitem\"\n      class={cn(\"group flex h-9 w-full items-center px-2 text-left text-foreground\", className)}\n      tabindex={-1}\n      data-slot=\"dropdown-item\"\n      data-state={(selected ? \"selected\" : \"default\")}\n      onClick={() => onClick?.()}\n    >\n      <Inline\n        class={\"flex h-7 min-w-0 flex-1 items-center rounded p-1 group-hover:bg-muted group-focus-visible:bg-muted \" +\n          \"group-data-[state=selected]:bg-muted\"}\n        data-slot=\"dropdown-item-content\"\n      >\n        {icon ? (\n          <Inline class=\"flex w-7 shrink-0 items-center pr-2\" data-slot=\"dropdown-item-icon\">\n            {icon}\n          </Inline>\n        ) : null}\n        <Inline class={cn(\"text-xs\", \"min-w-0 flex-1 truncate px-1 font-bold\")} data-slot=\"dropdown-item-label\">\n          {children}\n        </Inline>\n        {right ? (\n          <Inline class=\"flex shrink-0 items-center pr-1\" data-slot=\"dropdown-item-right\">\n            {right}\n          </Inline>\n        ) : null}\n      </Inline>\n    </ButtonPlain>\n  );\n}\n",
      "path": "components/dropdown-item.tsx",
      "target": "components/dropdown-item.tsx"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "solid",
      "component"
    ]
  },
  "name": "dropdown-item",
  "registryDependencies": [
    "compose",
    "utils"
  ],
  "runtime": "solid",
  "title": "Dropdown Item",
  "type": "registry:component"
}
