fix: Issues column shows only NW > GW weight errors

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Christian Vidal Wolf
2026-04-22 14:37:01 +02:00
co-authored by Claude Sonnet 4.6
parent 2c08a6593a
commit db25ea793d
+8 -9
View File
@@ -1244,19 +1244,18 @@ export function PricingView({ data, headers, onSaveRow, onCaptureState, onEdit,
</td> </td>
))} ))}
{/* Issues column */} {/* Issues column (weight only) */}
<td className="px-3 py-2 overflow-hidden"> <td className="px-3 py-2 overflow-hidden">
{unitErrors.length > 0 ? ( {(() => {
<div className="flex flex-col gap-1"> const weightError = unitErrors.find(e => e.startsWith('NW'));
{unitErrors.map((err, i) => ( return weightError ? (
<span key={i} className="inline-flex items-center gap-1 px-1.5 py-0.5 rounded text-[10px] font-semibold bg-red-500/15 text-red-400 border border-red-500/30 whitespace-nowrap"> <span className="inline-flex items-center gap-1 px-1.5 py-0.5 rounded text-[10px] font-semibold bg-red-500/15 text-red-400 border border-red-500/30 whitespace-nowrap">
<AlertCircle className="w-3 h-3 shrink-0" />{err} <AlertCircle className="w-3 h-3 shrink-0" />{weightError}
</span> </span>
))}
</div>
) : ( ) : (
<span className="text-slate-600 text-xs"></span> <span className="text-slate-600 text-xs"></span>
)} );
})()}
</td> </td>
{/* Check Column (Validated + Note) */} {/* Check Column (Validated + Note) */}