{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "poll-result",
  "type": "registry:component",
  "description": "A Card component with optional code display for UI blocks.",
  "registryDependencies": [
    "card",
    "progress"
  ],
  "files": [
    {
      "path": "src/app/components/ui-blocks/cards/code/PollResultCode.tsx",
      "content": "import { Card } from \"@/components/ui/card\"\r\nimport { BadgeProps } from \"@/components/ui/badge\"\r\nimport { Progress, ProgressProps } from \"@/components/ui/progress\"\r\n\r\n\r\nconst PollResultCard = () => {\r\n    const pollResults = [\r\n        { id: \"a\", label: \"A 30 Minutes\", value: 55, color: \"primary\" },\r\n        { id: \"b\", label: \"B More than 30 minutes\", value: 20, color: \"secondary\" },\r\n        { id: \"c\", label: \"C 1 Hour\", value: 15, color: \"success\" },\r\n        { id: \"d\", label: \"D More than 1 hour\", value: 10, color: \"warning\" },\r\n    ]\r\n    return (\r\n        <Card className=\"p-7 flex flex-col gap-6\">\r\n            <div>\r\n                <h3 className=\"font-semibold text-lg\">Result of Poll</h3>\r\n                <p className=\"text-sm text-muted-foreground\">Here is the result for the latest poll</p>\r\n            </div>\r\n            <div>\r\n                <p className=\"text-base\">What is your daily mobile app usage like?</p>\r\n            </div>\r\n            <div className=\"flex flex-col gap-5\">\r\n                {pollResults.map((option) => (\r\n                    <div key={option.id} className=\"flex flex-col gap-1\">\r\n                        <div className=\"flex justify-between text-sm font-medium\">\r\n                            <span>{option.label}</span>\r\n                            <span>{option.value}%</span>\r\n                        </div>\r\n                        <Progress\r\n                            variant={option?.color as ProgressProps['variant']}\r\n                            value={option.value}\r\n                            className=\"h-2 bg-muted\"\r\n                        >\r\n                            <div\r\n                                className={`h-2 rounded-full ${option.color}`}\r\n                                style={{ width: `${option.value}%` }}\r\n                            />\r\n                        </Progress>\r\n                    </div>\r\n                ))}\r\n            </div>\r\n        </Card>\r\n    )\r\n}\r\n\r\nexport default PollResultCard\r\n",
      "type": "registry:component",
      "target": "components/tailwind-admin/cards/poll-result/PollResultCode.tsx"
    }
  ]
}