repodna-engine 1.0.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- repodna/__init__.py +3 -0
- repodna/__main__.py +10 -0
- repodna/advisor/__init__.py +17 -0
- repodna/advisor/engine.py +502 -0
- repodna/advisor/models.py +101 -0
- repodna/agent/__init__.py +87 -0
- repodna/agent/context.py +558 -0
- repodna/agent/deltas.py +198 -0
- repodna/agent/evidence.py +134 -0
- repodna/agent/expansion.py +447 -0
- repodna/agent/localization.py +518 -0
- repodna/agent/models.py +695 -0
- repodna/agent/patch.py +378 -0
- repodna/agent/postflight.py +278 -0
- repodna/agent/preflight.py +336 -0
- repodna/agent/ranking.py +318 -0
- repodna/agent/repo_map.py +392 -0
- repodna/agent/safety.py +111 -0
- repodna/agent/service.py +574 -0
- repodna/agent/sessions.py +264 -0
- repodna/agent/task.py +660 -0
- repodna/agent/telemetry.py +101 -0
- repodna/agent/token_budget.py +231 -0
- repodna/api/__init__.py +1 -0
- repodna/api/agent_routes.py +248 -0
- repodna/api/app.py +2904 -0
- repodna/benchmarks/__init__.py +29 -0
- repodna/benchmarks/baselines.py +126 -0
- repodna/benchmarks/budget_bench.py +162 -0
- repodna/benchmarks/engine.py +418 -0
- repodna/benchmarks/evaluator.py +310 -0
- repodna/benchmarks/metrics.py +206 -0
- repodna/benchmarks/models.py +194 -0
- repodna/benchmarks/scalability.py +166 -0
- repodna/brain/__init__.py +46 -0
- repodna/brain/evidence.py +276 -0
- repodna/brain/extractor.py +1207 -0
- repodna/brain/indexer.py +766 -0
- repodna/brain/models.py +275 -0
- repodna/brain/multilang_extractors.py +889 -0
- repodna/brain/retrieval.py +469 -0
- repodna/brain/tracer.py +203 -0
- repodna/cli/__init__.py +1 -0
- repodna/cli/__main__.py +10 -0
- repodna/cli/agent_cmd.py +228 -0
- repodna/cli/installer.py +590 -0
- repodna/cli/main.py +2173 -0
- repodna/cli/plugin_cmd.py +130 -0
- repodna/cli/workspace_cmd.py +211 -0
- repodna/context/__init__.py +9 -0
- repodna/context/builder.py +379 -0
- repodna/context/models.py +133 -0
- repodna/contract/__init__.py +39 -0
- repodna/contract/evaluator.py +318 -0
- repodna/contract/loader.py +260 -0
- repodna/contract/models.py +185 -0
- repodna/core/__init__.py +1 -0
- repodna/core/analyzer.py +1424 -0
- repodna/diff/__init__.py +35 -0
- repodna/diff/engine.py +332 -0
- repodna/diff/models.py +117 -0
- repodna/diff/snapshot.py +248 -0
- repodna/ecosystem/__init__.py +27 -0
- repodna/ecosystem/contracts.py +129 -0
- repodna/ecosystem/doctor.py +253 -0
- repodna/git_insights/__init__.py +1 -0
- repodna/git_insights/analyzer.py +273 -0
- repodna/graph/__init__.py +1 -0
- repodna/graph/engine.py +562 -0
- repodna/guardian/__init__.py +17 -0
- repodna/guardian/engine.py +369 -0
- repodna/guardian/models.py +104 -0
- repodna/history/__init__.py +40 -0
- repodna/history/cache.py +240 -0
- repodna/history/diff.py +394 -0
- repodna/history/engine.py +557 -0
- repodna/history/evidence.py +160 -0
- repodna/history/models.py +258 -0
- repodna/history/timeline.py +164 -0
- repodna/intelligence/__init__.py +33 -0
- repodna/intelligence/models.py +165 -0
- repodna/intelligence/service.py +570 -0
- repodna/live/__init__.py +94 -0
- repodna/live/alerts.py +443 -0
- repodna/live/coordinator.py +351 -0
- repodna/live/diff.py +444 -0
- repodna/live/events.py +471 -0
- repodna/live/filtering.py +329 -0
- repodna/live/history.py +637 -0
- repodna/live/models.py +505 -0
- repodna/live/observer.py +653 -0
- repodna/live/reconciliation.py +253 -0
- repodna/live/session.py +1547 -0
- repodna/mcp/__init__.py +5 -0
- repodna/mcp/__main__.py +6 -0
- repodna/mcp/agent_tools.py +258 -0
- repodna/mcp/server.py +3283 -0
- repodna/mcp/workspace_tools.py +200 -0
- repodna/parsers/__init__.py +13 -0
- repodna/parsers/base.py +126 -0
- repodna/parsers/capabilities.py +361 -0
- repodna/parsers/project_metadata.py +232 -0
- repodna/parsers/resolver.py +621 -0
- repodna/parsers/treesitter_parser.py +830 -0
- repodna/passport/__init__.py +64 -0
- repodna/passport/generator.py +546 -0
- repodna/passport/migrator.py +139 -0
- repodna/passport/models.py +224 -0
- repodna/passport/validator.py +143 -0
- repodna/performance/__init__.py +89 -0
- repodna/performance/cache.py +1584 -0
- repodna/performance/identity.py +341 -0
- repodna/performance/incremental.py +317 -0
- repodna/performance/models.py +157 -0
- repodna/performance/parallel.py +291 -0
- repodna/plugins/__init__.py +47 -0
- repodna/plugins/evaluator.py +334 -0
- repodna/plugins/models.py +113 -0
- repodna/plugins/validator.py +256 -0
- repodna/quality/__init__.py +91 -0
- repodna/quality/complexity.py +352 -0
- repodna/quality/config.py +159 -0
- repodna/quality/debt.py +73 -0
- repodna/quality/duplicates.py +330 -0
- repodna/quality/engine.py +282 -0
- repodna/quality/impact.py +198 -0
- repodna/quality/models.py +427 -0
- repodna/quality/rules.py +364 -0
- repodna/quality/sarif.py +107 -0
- repodna/quality/security_signals.py +278 -0
- repodna/quality/test_mapping.py +271 -0
- repodna/quality/unused.py +201 -0
- repodna/reports/__init__.py +1 -0
- repodna/reports/exporter.py +374 -0
- repodna/rules/__init__.py +1 -0
- repodna/rules/health.py +436 -0
- repodna/schemas/__init__.py +1 -0
- repodna/schemas/models.py +348 -0
- repodna/security/__init__.py +1 -0
- repodna/security/safe_yaml.py +81 -0
- repodna/security/validators.py +583 -0
- repodna/skills/__init__.py +0 -0
- repodna/skills/repodna/SKILL.md +59 -0
- repodna/skills/repodna/__init__.py +0 -0
- repodna/skills/repodna/examples/workflows.md +85 -0
- repodna/skills/repodna/references/architecture-rules.md +26 -0
- repodna/storage/__init__.py +1 -0
- repodna/storage/workspace.py +199 -0
- repodna/webui/__init__.py +1 -0
- repodna/webui/assets/DependencyGraph-km_Qo-nG.js +43 -0
- repodna/webui/assets/HealthReportView-WVL39aNO.js +1 -0
- repodna/webui/assets/index-ByZ5e5pe.js +506 -0
- repodna/webui/assets/index-CDj3e8hw.css +1 -0
- repodna/webui/index.html +21 -0
- repodna/workspace/__init__.py +131 -0
- repodna/workspace/compatibility.py +317 -0
- repodna/workspace/context.py +175 -0
- repodna/workspace/contracts.py +369 -0
- repodna/workspace/federation.py +411 -0
- repodna/workspace/identity.py +202 -0
- repodna/workspace/impact.py +111 -0
- repodna/workspace/manifest.py +266 -0
- repodna/workspace/models.py +461 -0
- repodna/workspace/packages.py +494 -0
- repodna/workspace/policies.py +142 -0
- repodna/workspace/services.py +238 -0
- repodna/workspace/topology.py +316 -0
- repodna_engine-1.0.1.dist-info/METADATA +129 -0
- repodna_engine-1.0.1.dist-info/RECORD +173 -0
- repodna_engine-1.0.1.dist-info/WHEEL +5 -0
- repodna_engine-1.0.1.dist-info/entry_points.txt +2 -0
- repodna_engine-1.0.1.dist-info/licenses/LICENSE +21 -0
- repodna_engine-1.0.1.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{aj as f,b as v,j as e,ar as N,as as y,at as j,au as c,aq as _,R as w,an as C}from"./index-ByZ5e5pe.js";const $=({result:n,onSelectFileInStudio:o})=>{var m,h,u,g,b;const{t:s}=f(),[i,x]=v.useState("summary"),a=n.health_report,r=n.transparency,p=a.status==="insufficient_dependency_coverage";return e.jsxs("div",{"data-testid":"health-report-view",className:"report-document flex-1 overflow-y-auto p-4 lg:p-6 space-y-6 mx-auto w-full",children:[e.jsxs("section",{"aria-labelledby":"rubric-heading",className:"bg-panel border border-line rounded-lg p-5 flex flex-col lg:flex-row items-start lg:items-center justify-between gap-6",children:[e.jsxs("div",{className:"space-y-2 max-w-3xl",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(N,{className:"w-5 h-5 text-accent","aria-hidden":"true"}),e.jsx("h2",{id:"rubric-heading",className:"text-lg font-bold m-0 text-ink",children:s("report.title")})]}),e.jsx("p",{className:"text-xs text-muted m-0 leading-relaxed",children:a.methodology}),p&&e.jsxs("div",{className:"p-3 rounded-md bg-warning/15 border border-warning/40 text-xs text-warning leading-relaxed space-y-2",children:[e.jsxs("div",{children:[e.jsx("strong",{className:"block text-ink font-semibold mb-0.5",children:s("report.lowCoverageTitle")}),s("report.lowCoverageExplanation")]}),(((m=a.unverified_rules)==null?void 0:m.length)??0)>0&&e.jsxs("div",{"data-testid":"unverified-rules-box",className:"pt-2 border-t border-warning/30",children:[e.jsxs("span",{className:"font-semibold text-warning block mb-1",children:["Unverified / Not Evaluated Rules (",a.unverified_rules.length,"):"]}),e.jsx("ul",{role:"list",className:"m-0 pl-4 space-y-0.5 text-ink font-mono text-[11px]",children:a.unverified_rules.map(t=>e.jsx("li",{children:t},t))})]})]}),a.confidence&&e.jsxs("div",{className:"flex flex-wrap items-center gap-2 text-xs pt-1","data-testid":"health-confidence-banner",children:[e.jsxs("span",{className:`px-2 py-0.5 rounded font-bold uppercase border text-[11px] ${a.confidence==="high"?"bg-success/20 text-success border-success/40":a.confidence==="medium"?"bg-accent/20 text-accent border-accent/40":"bg-warning/20 text-warning border-warning/40"}`,children:[s("report.confidenceLabel")," ",a.confidence]}),e.jsxs("span",{className:"text-muted",children:[s("report.fullAstCoverage")," ",e.jsxs("strong",{children:[(a.ast_loc_coverage_pct??r.ast_loc_coverage_pct??0).toFixed(1),"% ",s("report.ofLoc")]})," ","(",(a.ast_file_coverage_pct??r.ast_file_coverage_pct??0).toFixed(1),"% ",s("report.ofFiles"),")"]}),a.confidence_reason&&e.jsxs("span",{className:"text-muted",children:["• ",a.confidence_reason]})]})]}),e.jsxs("div",{className:"flex items-center gap-4 bg-canvas border border-line rounded-md px-5 py-3 shrink-0",children:[e.jsxs("div",{children:[e.jsx("div",{className:"text-[11px] tracking-wide text-muted font-semibold",children:s("report.overallScore")}),e.jsx("div",{className:"text-3xl font-extrabold text-accent font-mono",children:a.overall_score!==null?e.jsxs(e.Fragment,{children:[a.overall_score.toFixed(1),e.jsx("span",{className:"text-sm text-muted font-normal",children:" / 100"})]}):p?e.jsx("span",{className:"text-base text-warning font-sans font-bold","data-testid":"report-overall-score-status",children:"Not Evaluated — Insufficient Dependency Coverage"}):e.jsx("span",{className:"text-xl text-muted","data-testid":"report-overall-score-status",children:"N/A (Insufficient Data)"})})]}),e.jsx("div",{className:"w-12 h-12 rounded-md bg-accent/15 border border-accent/40 flex items-center justify-center text-2xl font-black text-accent",children:a.grade})]})]}),e.jsx("div",{className:"flex items-center justify-between border-b border-line pb-2",children:e.jsxs("div",{role:"tablist","aria-label":"Report views",className:"flex items-center bg-panel p-1 rounded-lg border border-line gap-1",children:[e.jsx("button",{type:"button",role:"tab","data-testid":"report-tier-summary-btn","aria-selected":i==="summary",onClick:()=>x("summary"),className:`px-3 py-1 rounded-md text-xs font-semibold cursor-pointer transition ${i==="summary"?"bg-accent-solid text-white shadow-sm":"text-muted hover:text-ink"}`,children:s("report.summaryTab")}),e.jsx("button",{type:"button",role:"tab","data-testid":"report-tier-evidence-btn","aria-selected":i==="evidence",onClick:()=>x("evidence"),className:`px-3 py-1 rounded-md text-xs font-semibold cursor-pointer transition ${i==="evidence"?"bg-accent-solid text-white shadow-sm":"text-muted hover:text-ink"}`,children:s("report.evidenceTab")})]})}),e.jsxs("section",{"aria-labelledby":"categories-heading",className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-5 gap-3",children:[e.jsx("h2",{id:"categories-heading",className:"visually-hidden",children:"Architecture Health Categories"}),a.category_scores.map(t=>e.jsxs("div",{className:"bg-panel border border-line rounded-md p-3.5 flex flex-col justify-between gap-2",children:[e.jsxs("div",{children:[e.jsx("div",{className:"text-[11px] font-semibold text-muted",children:t.label}),e.jsxs("div",{className:"text-[11px] text-muted",children:[s("report.weight")," ",t.weight," ",s("report.pts")," •"," ",t.status==="not_evaluated"?s("common.notEvaluated"):`${s("report.deductionLabel")} -${t.deductions.toFixed(1)}`]})]}),e.jsxs("div",{className:"flex items-baseline justify-between mt-1",children:[e.jsx("span",{className:"text-lg font-bold font-mono text-ink",children:t.score!==null?`${t.score.toFixed(0)}%`:t.status==="not_evaluated"?s("common.notEvaluated"):"N/A"}),e.jsx("span",{className:"text-[11px] text-muted",children:t.status==="not_evaluated"?s("report.lowAstCoverage"):t.findings_count===1?s("report.issuesCount_one",{count:1}):s("report.issuesCount_other",{count:t.findings_count})})]}),e.jsx("div",{className:"w-full h-1.5 rounded-full bg-canvas overflow-hidden mt-1",children:t.score!==null?e.jsx("div",{className:`h-full rounded-full ${t.score>=80?"bg-success":t.score>=60?"bg-accent":"bg-danger"}`,style:{width:`${Math.max(0,Math.min(100,t.score))}%`}}):e.jsx("div",{className:"h-full bg-line",style:{width:"100%"}})})]},t.category))]}),i==="summary"&&e.jsxs("section",{"aria-label":"Key architectural findings",className:"space-y-4",children:[e.jsxs("h3",{className:"text-sm font-bold text-ink m-0 flex items-center gap-2",children:[e.jsx(y,{className:"w-4 h-4 text-accent"}),s("report.findingsHeading")]}),a.findings.length===0?e.jsxs("div",{className:"p-5 rounded-lg bg-success/10 border border-success/30 text-success text-xs font-medium flex items-center gap-2",children:[e.jsx(j,{className:"w-4 h-4 text-success"}),s("report.noFindings")]}):e.jsx("div",{className:"grid grid-cols-1 gap-3",children:a.findings.map(t=>e.jsxs("div",{"data-testid":`rule-card-${t.rule_id}`,className:`p-4 rounded-lg border ${t.severity==="critical"?"bg-danger/10 border-danger/40":"bg-warning/10 border-warning/40"}`,children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:"font-mono text-xs font-bold text-ink",children:t.rule_id}),e.jsx("span",{className:"text-xs font-bold text-ink",children:s(`rules.${t.rule_id}.title`,t.title)})]}),e.jsxs("span",{className:`px-2 py-0.5 rounded text-[10px] font-bold uppercase font-mono border ${t.severity==="critical"?"bg-danger/20 text-danger border-danger/40":"bg-warning/20 text-warning border-warning/40"}`,children:[t.severity," (-",t.score_deduction.toFixed(1)," pts)"]})]}),e.jsxs("p",{className:"mt-2 text-xs text-ink leading-relaxed font-normal m-0",children:[e.jsx("strong",{children:s("report.remediation")})," ",s(`rules.${t.rule_id}.remediation`,t.remediation)]}),e.jsxs("div",{className:"mt-2.5 pt-2 border-t border-line/40 flex flex-wrap items-center gap-2 text-[11px] text-muted",children:[e.jsx("span",{children:s("report.affectedModules")}),t.affected_files.slice(0,4).map(l=>e.jsx("button",{type:"button",onClick:()=>o(l),className:"font-mono text-accent hover:underline cursor-pointer",children:l},l)),t.affected_files.length>4&&e.jsx("span",{children:s("report.moreModules",{count:t.affected_files.length-4})})]})]},t.rule_id))})]}),i==="evidence"&&e.jsxs("section",{"aria-labelledby":"rules-report-heading",className:"space-y-4",children:[e.jsx("h3",{id:"rules-report-heading",className:"text-sm font-bold text-ink m-0",children:s("report.evaluationsHeading",{triggered:a.findings.length,passed:a.passed_rules.length})}),e.jsx("div",{tabIndex:0,role:"region","aria-labelledby":"rules-report-heading",className:"table-wrapper",children:e.jsxs("table",{style:{"--label-2":'"Severity"',"--label-3":'"Deduction"',"--label-4":'"Formula & Evidence"',"--label-5":'"Remediation"'},children:[e.jsx("caption",{className:"visually-hidden",children:"Detailed architecture health rule findings, mathematical formulas, and remediation guidance"}),e.jsx("thead",{children:e.jsxs("tr",{className:"text-xs text-muted",children:[e.jsx("th",{scope:"col",className:"p-3 text-left",children:s("report.ruleCol")}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:s("report.severityCol")}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:s("report.deductionCol")}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:s("report.evidenceCol")}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:s("report.remediationCol")})]})}),e.jsx("tbody",{className:"divide-y divide-line text-xs",children:a.findings.length===0?e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"p-6 text-center text-success font-medium",children:a.dependency_graph_evaluated===!1?s("report.noEvaluatedFindings"):s("report.noEvaluatedFindingsGeneral")})}):a.findings.map(t=>e.jsxs("tr",{"data-testid":`rule-card-${t.rule_id}`,className:"hover:bg-panel",children:[e.jsxs("th",{scope:"row",className:"p-3 text-left align-top font-semibold text-ink",children:[e.jsx("div",{className:"font-mono text-accent",children:t.rule_id}),e.jsx("div",{children:s(`rules.${t.rule_id}.title`,t.title)})]}),e.jsx("td",{className:"p-3 align-top",children:e.jsx("span",{className:`px-2 py-0.5 rounded-full text-[11px] font-bold uppercase border ${t.severity==="critical"?"bg-danger/20 text-danger border-danger/40":t.severity==="warning"?"bg-warning/20 text-warning border-warning/40":"bg-accent/20 text-accent border-accent/40"}`,children:t.severity})}),e.jsxs("td",{className:"p-3 align-top font-mono font-bold text-danger",children:["-",t.score_deduction.toFixed(1)," ",e.jsxs("span",{className:"text-muted font-normal",children:["/ -",t.max_deduction]})]}),e.jsxs("td",{className:"p-3 align-top space-y-1.5",children:[e.jsx("div",{className:"text-[11px] font-mono text-muted bg-canvas px-2 py-1 rounded border border-line",children:t.formula_explanation}),e.jsxs("div",{className:"text-[11px] text-muted",children:[e.jsx("strong",{children:s("report.threshold")})," ",t.threshold_description]}),e.jsx("ul",{role:"list",className:"m-0 pl-4 space-y-0.5 text-[11px] font-mono text-muted",children:t.evidence.slice(0,5).map((l,d)=>e.jsx("li",{children:l},d))})]}),e.jsx("td",{className:"p-3 align-top text-muted leading-relaxed max-w-xs",children:s(`rules.${t.rule_id}.remediation`,t.remediation)})]},t.rule_id))})]})}),a.passed_rules.length>0&&e.jsxs("div",{className:"bg-success/10 border border-success/40 rounded-md p-3.5 text-xs",children:[e.jsxs("div",{className:"font-semibold text-success mb-1.5 flex items-center gap-1.5",children:[e.jsx(j,{className:"w-4 h-4 text-success","aria-hidden":"true"}),s("report.passedRulesHeading")," (",a.passed_rules.length,")"]}),e.jsx("ul",{role:"list",className:"m-0 pl-5 space-y-1 text-muted",children:a.passed_rules.map(t=>e.jsx("li",{children:t},t))})]}),(((h=a.unverified_rules)==null?void 0:h.length)??0)>0&&e.jsxs("div",{"data-testid":"unverified-rules-box",className:"bg-warning/10 border border-warning/40 rounded-md p-3.5 text-xs",children:[e.jsxs("div",{className:"font-semibold text-warning mb-1.5 flex items-center gap-1.5",children:[e.jsx(c,{className:"w-4 h-4 text-warning","aria-hidden":"true"}),s("report.unverifiedRulesHeading",{count:a.unverified_rules.length})]}),e.jsx("ul",{role:"list",className:"m-0 pl-5 space-y-1 text-muted",children:a.unverified_rules.map(t=>e.jsx("li",{children:t},t))})]})]}),e.jsxs("section",{"aria-labelledby":"cycles-report-heading",className:"space-y-3",children:[e.jsxs("h3",{id:"cycles-report-heading",className:"text-sm font-bold tracking-wide text-ink m-0 flex items-center gap-1.5",children:[e.jsx(_,{className:"w-4 h-4 text-danger","aria-hidden":"true"}),"Circular Dependency Chains (",n.cycles.length," Cycles in ",n.graph_metrics.scc_count," Cyclic SCCs)"]}),n.graph_metrics.cycles_truncated&&e.jsxs("div",{className:"bg-warning/10 border border-warning/40 rounded-md p-3 text-xs text-warning flex items-center gap-2",children:[e.jsx(c,{className:"w-4 h-4 text-warning shrink-0","aria-hidden":"true"}),e.jsxs("span",{children:[e.jsx("strong",{children:"Cycle Enumeration Truncated:"})," ",n.graph_metrics.cycle_truncation_reason||"Reached cycle reporting cap or Johnson operation budget."]})]}),e.jsx("div",{tabIndex:0,role:"region","aria-labelledby":"cycles-report-heading",className:"table-wrapper",children:e.jsxs("table",{style:{"--label-2":'"Hops"',"--label-3":'"Severity"',"--label-4":'"Cycle Chain"'},children:[e.jsx("caption",{className:"visually-hidden",children:"Detected circular dependency paths"}),e.jsx("thead",{children:e.jsxs("tr",{className:"text-xs text-muted",children:[e.jsx("th",{scope:"col",className:"p-3 text-left",children:"Cycle ID"}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:"Length"}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:"Severity"}),e.jsx("th",{scope:"col",className:"p-3 text-left",children:"Cycle Module Path (Click to Inspect in Studio)"})]})}),e.jsx("tbody",{className:"divide-y divide-line text-xs",children:n.cycles.length===0?e.jsx("tr",{children:e.jsx("td",{colSpan:4,"data-testid":"cycle-analysis-summary-cell",className:`p-5 text-center ${a.dependency_graph_evaluated===!1?"text-warning":"text-success"}`,children:a.cycle_analysis_summary||"No cycles detected in analyzed graph (Acyclic Dependencies Principle satisfied in analyzed modules)"})}):n.cycles.map(t=>e.jsxs("tr",{className:"hover:bg-panel",children:[e.jsx("th",{scope:"row",className:"p-3 text-left font-mono text-danger",children:t.id}),e.jsxs("td",{className:"p-3 font-mono",children:[t.length," hops"]}),e.jsx("td",{className:"p-3 uppercase font-bold text-danger text-[11px]",children:t.severity}),e.jsx("td",{className:"p-3 font-mono",children:e.jsx("div",{className:"flex flex-wrap items-center gap-1.5",children:t.nodes.map((l,d)=>e.jsxs(w.Fragment,{children:[e.jsx("button",{type:"button",onClick:()=>o(l),className:"px-2 py-0.5 rounded bg-panel hover:bg-accent/10 border border-line text-accent cursor-pointer",children:l}),d<t.nodes.length-1&&e.jsx("span",{className:"text-danger",children:"→"})]},`${t.id}-${d}`))})})]},t.id))})]})})]}),e.jsxs("section",{"aria-labelledby":"transparency-report-heading",className:"space-y-3",children:[e.jsxs("h3",{id:"transparency-report-heading",className:"text-sm font-bold tracking-wide text-ink m-0 flex items-center gap-1.5",children:[e.jsx(C,{className:"w-4 h-4 text-accent","aria-hidden":"true"}),"Language Distribution & Parser Transparency"]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-3 text-xs",children:[e.jsxs("div",{className:"bg-panel border border-line rounded-md p-3",children:[e.jsx("div",{className:"text-muted font-semibold uppercase text-[10px]",children:"Supported AST Languages (full_ast)"}),e.jsx("div",{className:"text-ink font-medium mt-1","data-testid":"supported-ast-languages-list",children:r.supported_languages_detected.join(", ")||"None"})]}),e.jsxs("div",{className:"bg-panel border border-line rounded-md p-3",children:[e.jsxs("div",{className:"text-warning font-semibold uppercase text-[10px] flex items-center gap-1",children:[e.jsx(c,{className:"w-3.5 h-3.5 text-warning","aria-hidden":"true"}),"Partial Static Languages (partial_static)"]}),e.jsx("div",{className:"text-ink font-medium mt-1","data-testid":"partial-static-languages-list",children:(((u=r.partial_static_languages_detected)==null?void 0:u.length)??0)>0?`${r.partial_static_languages_detected.join(", ")} (${r.partial_static_files_count??0} files — static using/include scan only; no AST symbol or namespace-to-file graph resolution)`:"None"})]}),e.jsxs("div",{className:"bg-panel border border-line rounded-md p-3",children:[e.jsxs("div",{className:"text-warning font-semibold uppercase text-[10px] flex items-center gap-1",children:[e.jsx(c,{className:"w-3.5 h-3.5 text-warning","aria-hidden":"true"}),"Unsupported Languages (unsupported)"]}),e.jsx("div",{className:"text-ink font-medium mt-1","data-testid":"unsupported-languages-list",children:r.unsupported_languages_detected.length>0?`${r.unsupported_languages_detected.join(", ")} (${r.unsupported_files_count} files)`:(((g=r.partial_static_languages_detected)==null?void 0:g.length)??0)>0?"None (remaining files use partial_static header/using scanning)":"None — 100% of detected languages have AST import support"})]}),e.jsxs("div",{className:"bg-panel border border-line rounded-md p-3",children:[e.jsx("div",{className:"text-muted font-semibold uppercase text-[10px]",children:"Parser Coverage Ratio"}),e.jsxs("div",{className:"text-ink font-medium mt-1",children:[(r.ast_loc_coverage_pct??0).toFixed(1),"% LOC (",((b=r.ast_file_coverage_pct)==null?void 0:b.toFixed(1))??0,"% files)"]})]})]})]})]})};export{$ as HealthReportView};
|