{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "baseui-input", "description": "A Base UI input component", "dependencies": ["@base-ui/react"], "registryDependencies": ["@craftdotui/utils"], "files": [ { "path": "packages/baseui/components/input/index.tsx", "content": "\"use client\";\n\nimport { Input as InputPrimitive } from \"@base-ui/react/input\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { cn } from \"@/lib/utils\";\n\n/* -------------------------------------------------------------------------- */\n/* Input Variants */\n/* -------------------------------------------------------------------------- */\n\nconst inputVariants = cva(\n\t[\n\t\t\"w-full min-w-0 p-2 bg-background border border-border rounded-md outline-none inline-flex\",\n\t\t\"transition-all duration-200 ease-in-out\",\n\t\t\"placeholder:text-muted-foreground/80 disabled:cursor-not-allowed\",\n\t],\n\t{\n\t\tvariants: {\n\t\t\tvariant: {\n\t\t\t\tdefault: [\n\t\t\t\t\t\"focus-visible:ring-2 focus-visible:ring-ring/20 focus-visible:ring-offset-1\",\n\t\t\t\t\t\"focus-within:ring-2 focus-within:ring-ring/20 focus-within:ring-offset-1\",\n\t\t\t\t],\n\t\t\t\tghost: \"border-0 bg-transparent rounded-none focus:ring-0\",\n\t\t\t},\n\t\t\tsize: {\n\t\t\t\txs: \"h-7 text-xs\",\n\t\t\t\tsm: \"h-8 text-xs\",\n\t\t\t\tmd: \"h-8.5 text-sm\",\n\t\t\t\tlg: \"h-9 text-sm\",\n\t\t\t\txl: \"h-9.5 text-base\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tsize: \"md\",\n\t\t\tvariant: \"default\",\n\t\t},\n\t},\n);\n\n/* -------------------------------------------------------------------------- */\n/* Types */\n/* -------------------------------------------------------------------------- */\n\ntype InputVariants = VariantProps;\n\ninterface InputProps extends Omit, InputVariants {\n\tclassName?: string;\n}\n\n/* -------------------------------------------------------------------------- */\n/* Input Component */\n/* -------------------------------------------------------------------------- */\n\nfunction Input({ className, size, variant, type, ...props }: InputProps) {\n\tconst isFile = type === \"file\";\n\tconst isSearch = type === \"search\";\n\n\treturn (\n\t\t\n\t);\n}\n\n/* -------------------------------------------------------------------------- */\n/* Exports */\n/* -------------------------------------------------------------------------- */\n\nexport { Input, inputVariants };\nexport type { InputProps, InputVariants };\n", "type": "registry:component", "target": "components/baseui/components/input.tsx" } ], "type": "registry:component" }