Codebase intelligence for AI and humans: code health scores, auto-generated docs, git analytics, dead code detection, and architectural decisions via MCP.
Python aicode-complexitycode-healthcode-intelligencecode-qualitydead-codedeveloper-toolsdocumentationgit-analyticsmcpopen-sourcepythonrefactoringstatic-analysistechnical-debt
import * as React from "react";
import { ProportionBar } from "../shared/proportion-bar";
/**
* Language mix as a share bar plus a key.
*
* Languages are named in the key, so they take the share steps (the series
* colours by rank) like every other proportion.
*/
export function LanguageBar({
distribution,
maxShown = 5,
}: {
/** language → file count. */
distribution: Record<string, number>;
maxShown?: number;
}) {
return (
<ProportionBar
label="Files by language"
maxSegments={maxShown}
othersLabel={() => "Other"}
segments={Object.entries(distribution).map(([name, count]) => ({
key: name,
label: name,
value: count,
}))}
/>
);
}