import { JSX } from "preact"; interface FileInputProps extends Omit, "type" | "value"> { label?: string; } export default function FileInput({ label, className = "", ...props }: FileInputProps) { const inputClasses = `w-full block box-border rounded border border-gray-300 dark:border-gray-600 text-sm outline-none h-[38px] leading-[30px] py-1 px-1.5 dark:bg-gray-800 dark:text-gray-100 file:mr-2 file:py-1 file:px-3 file:rounded file:border-0 file:text-sm file:font-medium file:cursor-pointer file:bg-gray-100 file:text-gray-700 file:hover:bg-gray-200 file:dark:bg-gray-600 file:dark:text-gray-100 file:dark:hover:bg-gray-500 ${className}`; if (label) { return (
); } return ; }