mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-09-11 14:00:29 +00:00
refactor(recovery): trim low-value summary rows
This commit is contained in:
@@ -726,6 +726,8 @@ instead of behaving like a recovery-only executive summary.
|
||||
That support band should stay genuinely short, usually one or two compact
|
||||
rows rather than four-item micro reports, so the operator can scan the summary
|
||||
as orientation instead of reading each card like a dense checklist.
|
||||
When a second support row does not materially change triage, recovery should
|
||||
prefer a single support row over filling the card just because there is room.
|
||||
Those support rows should also stay signal-driven. Recovery summary cards
|
||||
should omit zero-value or low-value support rows like `Primary Item` or `Peak
|
||||
Day` when they do not materially improve operator triage, so the top strip
|
||||
|
||||
@@ -75,6 +75,7 @@ describe('RecoverySummary', () => {
|
||||
expect(screen.queryByText('<7d')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('<1h')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('<24h')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('Days Active')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('Multi-platform')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('Primary Platform')).not.toBeInTheDocument();
|
||||
expect(screen.queryByText('Primary Item')).not.toBeInTheDocument();
|
||||
|
||||
@@ -133,25 +133,16 @@ export const RecoverySummary: Component<RecoverySummaryProps> = (props) => {
|
||||
);
|
||||
|
||||
const footprintRows = createMemo(() => {
|
||||
const rows: Array<{ label: string; value: string | number; valueClass?: string }> = [
|
||||
return [
|
||||
{ label: 'Platforms', value: platformCoverage().platformCount },
|
||||
];
|
||||
if (platformCoverage().multiPlatformCount > 0) {
|
||||
rows.push({
|
||||
label: 'Multi-platform',
|
||||
value: platformCoverage().multiPlatformCount,
|
||||
});
|
||||
}
|
||||
return rows.slice(0, 2);
|
||||
});
|
||||
|
||||
const historyRows = createMemo(() => {
|
||||
const rows: Array<{ label: string; value: string | number; valueClass?: string }> = [];
|
||||
if (activity().latestLabel) {
|
||||
rows.push({ label: 'Latest Activity', value: activity().latestLabel });
|
||||
return [{ label: 'Latest Activity', value: activity().latestLabel }];
|
||||
}
|
||||
rows.push({ label: 'Days Active', value: activity().activeDays });
|
||||
return rows.slice(0, 2);
|
||||
return [{ label: 'Days Active', value: activity().activeDays }];
|
||||
});
|
||||
|
||||
const MetricRows = (rowProps: {
|
||||
|
||||
Reference in New Issue
Block a user