{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "vercel", "title": "Vercel", "registryDependencies": [ "alert", "badge", "button", "calendar", "card", "chart", "dialog", "dropdown-menu", "empty", "field", "input-group", "item", "native-select", "popover", "textarea", "example" ], "files": [ { "path": "registry/radix-nova/blocks/vercel.tsx", "content": "\"use client\"\n\nimport * as React from \"react\"\nimport { format } from \"date-fns\"\nimport { type DateRange } from \"react-day-picker\"\nimport { Area, AreaChart } from \"recharts\"\n\nimport {\n Example,\n ExampleWrapper,\n} from \"@/registry/bases/radix/components/example\"\nimport { Alert, AlertDescription } from \"@/registry/bases/radix/ui/alert\"\nimport { Badge } from \"@/registry/bases/radix/ui/badge\"\nimport { Button } from \"@/registry/bases/radix/ui/button\"\nimport { Calendar } from \"@/registry/bases/radix/ui/calendar\"\nimport {\n Card,\n CardAction,\n CardContent,\n CardDescription,\n CardFooter,\n CardHeader,\n CardTitle,\n} from \"@/registry/bases/radix/ui/card\"\nimport {\n ChartContainer,\n ChartTooltip,\n ChartTooltipContent,\n type ChartConfig,\n} from \"@/registry/bases/radix/ui/chart\"\nimport {\n Dialog,\n DialogClose,\n DialogContent,\n DialogDescription,\n DialogFooter,\n DialogHeader,\n DialogTitle,\n DialogTrigger,\n} from \"@/registry/bases/radix/ui/dialog\"\nimport {\n DropdownMenu,\n DropdownMenuContent,\n DropdownMenuItem,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from \"@/registry/bases/radix/ui/dropdown-menu\"\nimport {\n Empty,\n EmptyContent,\n EmptyDescription,\n EmptyHeader,\n EmptyTitle,\n} from \"@/registry/bases/radix/ui/empty\"\nimport { Field, FieldGroup, FieldLabel } from \"@/registry/bases/radix/ui/field\"\nimport {\n InputGroup,\n InputGroupAddon,\n InputGroupInput,\n} from \"@/registry/bases/radix/ui/input-group\"\nimport {\n Item,\n ItemActions,\n ItemContent,\n ItemDescription,\n ItemFooter,\n ItemGroup,\n ItemMedia,\n ItemSeparator,\n ItemTitle,\n} from \"@/registry/bases/radix/ui/item\"\nimport {\n NativeSelect,\n NativeSelectOption,\n} from \"@/registry/bases/radix/ui/native-select\"\nimport {\n Popover,\n PopoverContent,\n PopoverTrigger,\n} from \"@/registry/bases/radix/ui/popover\"\nimport { Textarea } from \"@/registry/bases/radix/ui/textarea\"\nimport { IconPlaceholder } from \"@/app/(create)/components/icon-placeholder\"\n\nexport default function VercelBlock() {\n return (\n \n \n \n \n \n \n \n \n \n \n )\n}\n\nconst items = [\n {\n name: \"Edge Requests\",\n value: \"$1.83K\",\n percentage: 67.34,\n },\n {\n name: \"Fast Data Transfer\",\n percentage: 52.18,\n value: \"$952.51\",\n },\n {\n name: \"Monitoring data points\",\n percentage: 89.42,\n value: \"$901.20\",\n },\n {\n name: \"Web Analytics Events\",\n percentage: 45.67,\n value: \"$603.71\",\n },\n {\n name: \"Edge Request CPU Duration\",\n percentage: 23.91,\n value: \"$4.65\",\n },\n {\n name: \"Fast Origin Transfer\",\n percentage: 38.75,\n value: \"$3.85\",\n },\n {\n name: \"ISR Reads\",\n percentage: 71.24,\n value: \"$2.86\",\n },\n {\n name: \"Function Invocations\",\n percentage: 15.83,\n value: \"$0.60\",\n },\n {\n name: \"ISR Writes\",\n percentage: 26.23,\n value: \"524.52K / 2M\",\n },\n {\n name: \"Function Duration\",\n percentage: 5.11,\n value: \"5.11 GB Hrs / 1K GB Hrs\",\n },\n]\n\nfunction UsageCard() {\n return (\n \n \n \n \n 5 days remaining in cycle\n \n \n \n \n {items.map((item) => (\n \n \n \n \n \n \n {item.name}\n \n \n \n {item.value}\n \n \n \n \n ))}\n \n \n \n \n )\n}\n\nfunction AnomalyAlert() {\n return (\n \n \n \n \n \n Get alerted for anomalies\n \n Automatically monitor your projects for anomalies and get\n notified.\n \n \n \n Upgrade to Observability Plus\n \n \n \n \n \n )\n}\n\nconst environments = [\n \"All Environments\",\n \"Production\",\n \"Preview\",\n \"Development\",\n \"Staging\",\n \"Test\",\n \"Other\",\n]\n\nconst statuses = [\n { name: \"Ready\", color: \"oklch(0.72 0.19 150)\" },\n { name: \"Error\", color: \"oklch(0.64 0.21 25)\" },\n { name: \"Building\", color: \"oklch(0.77 0.16 70)\" },\n { name: \"Queued\", color: \"oklch(0.72 0.00 0)\" },\n { name: \"Provisioning\", color: \"oklch(0.72 0.00 0)\" },\n { name: \"Canceled\", color: \"oklch(0.72 0.00 0)\" },\n]\n\nfunction DeploymentFilter() {\n const [selectedEnvironment, setSelectedEnvironment] = React.useState(\n environments[0]\n )\n const [selectedStatuses, setSelectedStatuses] = React.useState>(\n new Set(statuses.slice(0, 5).map((s) => s.name))\n )\n const [dateRange, setDateRange] = React.useState()\n\n const toggleStatus = (statusName: string) => {\n setSelectedStatuses((prev) => {\n const next = new Set(prev)\n if (next.has(statusName)) {\n next.delete(statusName)\n } else {\n next.add(statusName)\n }\n return next\n })\n }\n\n return (\n \n \n \n \n \n \n {dateRange?.from ? (\n dateRange.to ? (\n <>\n {format(dateRange.from, \"LLL dd, y\")} -{\" \"}\n {format(dateRange.to, \"LLL dd, y\")}\n >\n ) : (\n format(dateRange.from, \"LLL dd, y\")\n )\n ) : (\n \"Select Date Range\"\n )}\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n {selectedEnvironment}\n \n \n \n \n {environments.map((environment) => (\n setSelectedEnvironment(environment)}\n data-active={selectedEnvironment === environment}\n >\n {environment}\n \n \n ))}\n \n \n \n \n \n \n {statuses.map((status) => (\n \n ))}\n \n Status {selectedStatuses.size}/{statuses.length}\n \n \n \n \n {statuses.map((status) => {\n const isSelected = selectedStatuses.has(status.name)\n return (\n toggleStatus(status.name)}\n data-active={isSelected}\n style={\n {\n \"--color\": status.color,\n } as React.CSSProperties\n }\n >\n \n \n {status.name}\n \n \n \n )\n })}\n \n \n \n \n )\n}\n\nconst billingItems = [\n {\n month: \"November 2025\",\n invoiceDate: new Date(2025, 10, 5),\n amount: \"$10.00\",\n status: \"Paid\" as const,\n },\n {\n month: \"October 2025\",\n invoiceDate: new Date(2025, 9, 4),\n amount: \"$10.00\",\n status: \"Paid\" as const,\n },\n {\n month: \"September 2025\",\n invoiceDate: new Date(2025, 8, 4),\n amount: \"$10.00\",\n status: \"Paid\" as const,\n },\n]\n\nfunction BillingList() {\n return (\n \n \n {billingItems.map((item, index) => (\n \n \n \n \n {item.month}\n \n {item.status}\n \n \n \n Infrastructure usage & Vercel platform\n \n \n \n Total Due\n {item.amount}\n \n \n \n Invoiced {format(item.invoiceDate, \"d MMM yyyy\")}\n \n \n \n \n \n \n \n More options\n \n \n \n View invoice\n Download PDF\n \n Contact support\n \n \n \n \n \n Total Due\n {item.amount}\n \n \n \n Invoiced {format(item.invoiceDate, \"d MMM yyyy\")}\n \n \n \n \n {index !== billingItems.length - 1 && (\n \n )}\n \n ))}\n \n \n )\n}\n\nfunction CircularGauge({ percentage }: { percentage: number }) {\n const normalizedPercentage = Math.min(Math.max(percentage, 0), 100)\n const circumference = 2 * Math.PI * 42.5\n const strokePercent = (normalizedPercentage / 100) * circumference\n\n return (\n \n \n \n \n )\n}\n\nconst agentFeatures = [\n {\n id: \"code-reviews\",\n content: (\n <>\n Code reviews with full codebase context to catch{\" \"}\n hard-to-find bugs. bugs.\n >\n ),\n },\n {\n id: \"code-suggestions\",\n content: (\n <>\n Code suggestions validated in sandboxes before you\n merge.\n >\n ),\n },\n {\n id: \"root-cause\",\n content: (\n <>\n Root-cause analysis for production issues with\n deployment context.{\" \"}\n \n Requires Observability Plus\n \n >\n ),\n },\n]\n\nfunction ActivateAgentDialog() {\n return (\n \n \n \n Activate Agent\n \n \n \n Ship faster & safer with Vercel Agent\n \n Your use is subject to Vercel's{\" \"}\n Public Beta Agreement and{\" \"}\n AI Product Terms.\n \n \n \n \n {agentFeatures.map((feature) => (\n \n \n \n \n \n \n {feature.content}\n \n \n \n ))}\n \n \n \n \n Pro teams get $100 in Vercel Agent trial credit for 2 weeks.\n \n \n \n \n \n Cancel\n \n Enable with $100 credits\n \n \n \n \n )\n}\n\nfunction ObservabilityCard() {\n return (\n \n \n \n \n \n Observability Plus is replacing Monitoring\n \n Switch to the improved way to explore your data, with natural\n language. Monitoring will no longer be available on the Pro plan in\n November, 2025\n \n \n \n \n Create Query{\" \"}\n \n \n \n Warning\n \n \n \n \n )\n}\n\nfunction FeedbackForm() {\n return (\n \n \n \n \n \n \n Topic\n \n \n Select a topic\n \n AI\n \n Accounts and Access Controls\n \n \n Billing\n \n \n CDN (Firewall, Caching)\n \n \n CI/CD (Builds, Deployments, Environment Variables)\n \n \n Dashboard Interface (Navigation, UI Issues)\n \n \n Domains\n \n \n Frameworks\n \n \n Marketplace and Integrations\n \n \n Observability (Observability, Logs, Monitoring)\n \n \n Storage\n \n \n \n \n Feedback\n \n \n \n \n \n \n \n Submit\n \n \n \n \n )\n}\n\nconst chartData = [\n { month: \"January\", visitors: 186 },\n { month: \"February\", visitors: 305 },\n { month: \"March\", visitors: 237 },\n { month: \"April\", visitors: 73 },\n { month: \"May\", visitors: 209 },\n { month: \"June\", visitors: 214 },\n]\n\nconst chartConfig = {\n visitors: {\n label: \"Visitors\",\n color: \"var(--chart-1)\",\n },\n} satisfies ChartConfig\n\nfunction AnalyticsCard() {\n return (\n \n \n \n Analytics\n \n 418.2K Visitors +10%\n \n \n \n View Analytics\n \n \n \n \n \n }\n defaultIndex={2}\n />\n \n \n \n \n \n )\n}\n", "type": "registry:block" } ], "type": "registry:block" }