| gio | d002661 | 2025-05-08 13:00:36 +0000 | [diff] [blame] | 1 | import * as React from "react"; |
| gio | 5f2f100 | 2025-03-20 18:38:48 +0400 | [diff] [blame] | 2 | |
| gio | d002661 | 2025-05-08 13:00:36 +0000 | [diff] [blame] | 3 | import { cn } from "@/lib/utils"; |
| gio | 5f2f100 | 2025-03-20 18:38:48 +0400 | [diff] [blame] | 4 | |
| gio | d002661 | 2025-05-08 13:00:36 +0000 | [diff] [blame] | 5 | export interface InputProps extends React.InputHTMLAttributes<HTMLInputElement> {} |
| gio | 5f2f100 | 2025-03-20 18:38:48 +0400 | [diff] [blame] | 6 | |
| gio | d002661 | 2025-05-08 13:00:36 +0000 | [diff] [blame] | 7 | const Input = React.forwardRef<HTMLInputElement, InputProps>(({ className, type, ...props }, ref) => { |
| 8 | return ( |
| 9 | <input |
| 10 | type={type} |
| 11 | className={cn( |
| 12 | "flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50", |
| 13 | className, |
| 14 | )} |
| 15 | ref={ref} |
| 16 | {...props} |
| 17 | /> |
| 18 | ); |
| 19 | }); |
| 20 | Input.displayName = "Input"; |
| gio | 5f2f100 | 2025-03-20 18:38:48 +0400 | [diff] [blame] | 21 | |
| gio | d002661 | 2025-05-08 13:00:36 +0000 | [diff] [blame] | 22 | export { Input }; |