refactor: Update OutputComponent to use name instead of selected when types.length < 2

This commit is contained in:
anovazzi1 2024-06-12 18:54:56 -03:00
commit ae49081776

View file

@ -27,7 +27,7 @@ export default function OutputComponent({
const updateNodeInternals = useUpdateNodeInternals();
if (types.length < 2) {
return <span className={cn(frozen ? " text-ice" : "")}>{selected}</span>;
return <span className={cn(frozen ? " text-ice" : "")}>{name}</span>;
}
return (
@ -40,7 +40,7 @@ export default function OutputComponent({
size="xs"
className={cn(
frozen ? "text-ice" : "",
"items-center gap-1 pl-2 pr-1.5 align-middle text-xs font-normal"
"items-center gap-1 pl-2 pr-1.5 align-middle text-xs font-normal",
)}
>
<span className="pb-px">{selected}</span>