{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "betting-panel-04", "title": "Betting Panel 04", "description": "A stepper-based betting panel with circular +/− controls for bet amount and rows.", "dependencies": [ "lucide-react" ], "registryDependencies": [ "button", "card", "tabs", "toggle-group" ], "files": [ { "path": "registry/default/blocks/betting-panel-04/components/betting-panel.tsx", "content": "\"use client\";\n\nimport { Minus, Plus } from \"lucide-react\";\nimport { useState } from \"react\";\nimport { Button } from \"@/components/ui/button\";\nimport { Card, CardContent } from \"@/components/ui/card\";\nimport { Tabs, TabsList, TabsTrigger } from \"@/components/ui/tabs\";\nimport { ToggleGroup, ToggleGroupItem } from \"@/components/ui/toggle-group\";\n\nconst BALANCE = 1000;\nconst MIN_BET = 0.01;\nconst MIN_ROWS = 8;\nconst MAX_ROWS = 16;\n\nexport function BettingPanel({\n className,\n ...props\n}: React.ComponentProps<\"div\">) {\n const [betAmount, setBetAmount] = useState(1);\n const [risk, setRisk] = useState([\"medium\"]);\n const [rows, setRows] = useState(12);\n\n const incrementBet = () =>\n setBetAmount((prev) => Math.min(prev + 1, BALANCE));\n const decrementBet = () =>\n setBetAmount((prev) => Math.max(prev - 1, MIN_BET));\n const incrementRows = () => setRows((prev) => Math.min(prev + 1, MAX_ROWS));\n const decrementRows = () => setRows((prev) => Math.max(prev - 1, MIN_ROWS));\n\n return (\n
\n \n \n \n \n \n Manual\n \n \n Auto\n \n \n \n\n
\n
\n \n Balance\n \n ${BALANCE.toFixed(2)}\n
\n\n
\n \n Bet Amount\n \n
\n \n \n \n \n ${betAmount.toFixed(2)}\n \n \n \n \n
\n
\n\n
\n \n Risk\n \n \n \n Low\n \n \n Medium\n \n \n High\n \n \n
\n\n
\n \n Rows\n \n
\n \n \n \n \n {rows}\n \n \n \n \n
\n
\n\n \n
\n
\n
\n
\n );\n}\n\nexport default function BettingPanel04() {\n return (\n
\n
\n \n
\n
\n );\n}\n", "type": "registry:component" } ], "categories": [ "betting" ], "type": "registry:block" }