Forge
csharp3407750f
1using AgentForge.Abstractions;
2using AgentForge.Contracts;
3using AgentForge.Plugin.View;
4
5namespace AgentForge.Plugin.Org.Web.Components;
6
7internal static class ForgeViewOrgRepoNode
8{
9 internal static string Render(RepoResponse repo) =>
10 ForgeHtml.Li(null,
11 ForgeHtml.Text("📦 "),
12 ForgeHtml.A($"/view/repos/{ForgeRepoNames.ToUrlPath(repo.Name)}", ShortRepoName(repo.Name)),
13 ForgeHtml.Text(" "),
14 ForgeHtml.Badge(repo.DriveMode),
15 ForgeHtml.Text(" "),
16 ForgeHtml.Badge(repo.Visibility));
17
18 private static string ShortRepoName(string fullName)
19 {
20 var slash = fullName.IndexOf('/', StringComparison.Ordinal);
21 return slash >= 0 ? fullName[(slash + 1)..] : fullName;
22 }
23}
24
View only · write via MCP/CIDE