// SPDX-License-Identifier: AGPL-3.0-or-later package web // Facts is a key/value block on an 11ch key column. templ Facts(facts []Fact) {
for _, f := range facts {
{ f.Key }
@FactValue(f) }
} // CloneBlock is a block of copyable shell lines; each has its own [copy] // button, whose label says "copied" for 1.5 s. templ CloneBlock(c Clone) {
for _, line := range c.Lines {
{ line }
}
} // HomeRow is one row of the home list. Its id is the target of SSE swaps. templ HomeRowView(r HomeRow) { { r.Name } if r.Fresh { new push } { r.Desc } { r.Branch } } // Outline is the README outline; levels indent by 2ch, the h1 is bold. templ Outline(headings []Heading) { } // ReadmeCard is a README in a card whose header names the file. templ ReadmeCard(r Readme) {

{ r.Name }

@ReadmeView(r)
} // ReadmeView is a rendered README. Its HTML comes from the Markdown // renderer, which drops raw HTML and filters URLs. templ ReadmeView(r Readme) {
if r.Note != "" {

{ r.Note }

} else { @templ.Raw(r.HTML) }
} // CommitRows is a cursor table of commits: sha, subject with inline refs, // author, relative date (absolute in the title). templ CommitRows(rows []CommitRow) { for _, c := range rows { }
{ c.Short } { c.Subject } if c.Merge { merge } for _, b := range c.Branches { { b } } for _, t := range c.Tags { tag { t } } { c.Author }
}