22 lines
829 B
TypeScript
22 lines
829 B
TypeScript
import * as React from 'react';
|
|
|
|
import { cn } from '@renderer/lib/utils';
|
|
|
|
const Input = React.forwardRef<HTMLInputElement, React.ComponentProps<'input'>>(
|
|
({ className, type, ...props }, ref) => {
|
|
return (
|
|
<input
|
|
type={type}
|
|
className={cn(
|
|
'flex h-9 w-full rounded-md border border-[var(--color-border)] 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-[var(--color-text)] placeholder:text-[var(--color-text-muted)] focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-[var(--color-border-emphasis)] disabled:cursor-not-allowed disabled:opacity-50',
|
|
className
|
|
)}
|
|
ref={ref}
|
|
{...props}
|
|
/>
|
|
);
|
|
}
|
|
);
|
|
Input.displayName = 'Input';
|
|
|
|
export { Input };
|