@* The one row of chrome a git page gets: where you are on the left, where else you can go on the right. Inverted, like a terminal's status line — see git.css. *@ @code { /// One step of the path under the repository. A null href is the step you are on. public sealed record Crumb(string Name, string? Href); /// The repository's directory name. Empty on the index, which has no tabs. [Parameter] public string? Repository { get; set; } /// Which tab to punch out: log, tree or refs. [Parameter] public string? Tab { get; set; } /// The branch the tabs should stay on, when the page is on one. [Parameter] public string? Reference { get; set; } [Parameter] public IReadOnlyList Path { get; set; } = []; private string RepoHref => $"/git/{Uri.EscapeDataString(Repository ?? "")}"; private string Query => string.IsNullOrEmpty(Reference) ? "" : $"?h={Uri.EscapeDataString(Reference)}"; private string? Active(string tab) => tab == Tab ? "on" : null; }