mirror of
https://github.com/Hestia-Homes/assessment-model.git
synced 2026-07-19 17:02:59 +00:00
fix(portfolio): truncate long match addresses; hide Needs attention tab when empty
- MatchAddress: long OS addresses overflowed the candidate row (text column wasn't width-constrained). Give it min-w-0 flex-1 and truncate both lines (full address on hover) so the dialog layout holds. - PortfolioTabs: when nothing is unmatched, render just the properties table with no tab strip (the "Needs attention" tab only appears when count > 0). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
3f8920acd0
commit
fe55a28622
2 changed files with 9 additions and 3 deletions
|
|
@ -188,11 +188,14 @@ export default function MatchAddress({
|
|||
isSelected ? "text-amber-600" : "text-gray-200"
|
||||
}`}
|
||||
/>
|
||||
<span className="min-w-0">
|
||||
<span className="block truncate text-gray-800">
|
||||
<span className="min-w-0 flex-1">
|
||||
<span
|
||||
className="block truncate text-gray-800"
|
||||
title={c.address}
|
||||
>
|
||||
{c.address}
|
||||
</span>
|
||||
<span className="text-[11px] text-gray-500">
|
||||
<span className="block truncate text-[11px] text-gray-500">
|
||||
UPRN {c.uprn} · {label}
|
||||
{c.alreadyInPortfolio
|
||||
? " · already in portfolio"
|
||||
|
|
|
|||
|
|
@ -18,6 +18,9 @@ export default function PortfolioTabs({
|
|||
}) {
|
||||
const [tab, setTab] = useState<"properties" | "needs-attention">("properties");
|
||||
|
||||
// Nothing unmatched → no tab strip at all, just the properties table.
|
||||
if (needsAttentionCount === 0) return <>{properties}</>;
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div className="mb-4 flex items-center gap-1 border-b border-gray-200">
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue