🔧 chore: prevent 'gap' due to empty div on Select

This commit is contained in:
Andre H 2024-03-01 11:26:38 +08:00
parent 207b32ce65
commit 4a86952810

View File

@ -284,15 +284,15 @@ export const Select = ({
onClear?.(); onClear?.();
}; };
const renderLabels = useMemo( const renderLabels = useMemo(() => {
() => ( if (!label && !description) return null;
<div className="space-y-1"> return (
<div className="gap-y-1">
<p className={theme.label()}>{label}</p> <p className={theme.label()}>{label}</p>
<p className={theme.description()}>{description}</p> <p className={theme.description()}>{description}</p>
</div> </div>
), );
[theme, label, description], }, [theme, label, description]);
);
const renderLeftIcon = useMemo(() => { const renderLeftIcon = useMemo(() => {
return ( return (