import type { ButtonHTMLAttributes, InputHTMLAttributes, ReactNode, SelectHTMLAttributes, TextareaHTMLAttributes, } from 'react'; import { cn } from '@/lib/utils/cn'; interface ResourceFieldProps { label: ReactNode; hint?: ReactNode; error?: string; className?: string; tooltip?: string; container?: 'label' | 'div'; children: ReactNode; } function FieldTooltip({ content }: { content: string }) { return ( ? {content} ); } export function ResourceField({ label, hint, error, className, tooltip, container = 'label', children, }: ResourceFieldProps) { const Container = container; return ( {label} {tooltip ? : null} {children} {error ? ( {error} ) : hint ? ( {hint} ) : null} ); } export function ResourceInput(props: InputHTMLAttributes) { return ( ); } export function ResourceTextarea( props: TextareaHTMLAttributes, ) { return (