Skip to content

fix(control-center): show full line breakdown on Projects tab KPI row - #80

Merged
man4ish merged 1 commit into
mainfrom
fix/projects-tab-full-line-breakdown
Sep 11, 2026
Merged

man4ish merged 1 commit into
mainfrom
fix/projects-tab-full-line-breakdown

Conversation

@man4ish

@man4ish man4ish commented Sep 11, 2026

Copy link
Copy Markdown
Collaborator

What

Follow-up to #79. The Projects tab's KPI row now shows the same 6-metric breakdown the internal static ecosystem report (scripts/generate_report.py) already shows at the top level: files, documentation, code lines, comment lines, blank lines, total lines — instead of the previous 4 cards (repositories / code lines / largest repo / categories).

Code lines stays the primary/highlighted metric and keeps driving the ranking (donut chart, project bars, largest-repo ordering, default table sort) — per the earlier discussion in this thread: code-only LOC is the more style-independent metric across repos with different comment/blank conventions, so it shouldn't be replaced as the ranking basis. The other lines are now shown transparently alongside it rather than hidden, and the total column added in #79 stays as a secondary column in the breakdown table.

documentation uses the same narrow definition as the internal report (Markdown-only, not every docs-type language) so the number is identical across both surfaces.

Also fixed

PublicEcosystemPage.test.tsx's mock ReportData.grand was missing files (masked by an as any cast) — harmless until this change made ProjectsTab read grand.files directly, which then crashed under test. Added it to match the real ReportData shape.

Testing

  • npx tsc --noEmit — clean
  • npx vitest run — 678/678 passing
  • npm run build — succeeds

🤖 Generated with Claude Code

https://claude.ai/code/session_014sNhqTgqynXCnKpmt7KbgK

Replace the 4-card KPI row (repositories/code lines/largest repo/
categories) with the same 6-metric breakdown the internal static
ecosystem report already shows: files, documentation, code lines,
comment lines, blank lines, total lines -- code lines stays the
primary/highlighted metric and still drives ranking (donut, bars,
largest-repo ordering, default sort), matching the earlier decision
that code-only LOC is the more style-independent metric; the other
lines are shown transparently alongside it instead of hidden.

"documentation" uses the same narrow definition the internal report
uses (Markdown-only, not every docs-type language) so the number
matches across both surfaces.

Fixes a test fixture gap surfaced by this change: PublicEcosystemPage's
mock ReportData.grand was missing `files`, unnoticed until the tab
started reading it directly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014sNhqTgqynXCnKpmt7KbgK
@man4ish
man4ish merged commit ed43b3b into main Sep 11, 2026
2 checks passed
@man4ish
man4ish deleted the fix/projects-tab-full-line-breakdown branch September 11, 2026 01:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant