cerrado @ b71c6c0e5b8dd00d44e40ac0551902a23cbe19d5

 1{% import "github.com/go-git/go-git/v5/plumbing" %}
 2{% import "github.com/go-git/go-git/v5/plumbing/object" %}
 3
 4{% code
 5type GitItemSummaryPage struct {
 6    Tags []*plumbing.Reference
 7    Branches []*plumbing.Reference
 8    Commits []*object.Commit
 9}
10%}
11
12{% func (g *GitItemSummaryPage) Nav(name, ref string) %}{%= GitItemNav(name, ref, Summary) %}{% endfunc %}
13
14{% func (g *GitItemSummaryPage) GitContent(name, ref string) %}
15<div class="row">
16  <div class="col-md-8">
17    {% if len(g.Tags) > 0 %}
18    <div class="event-list">
19      {% for _, t := range g.Tags %}
20      <div class="row event me-md-2">
21          <div class="col-4">
22           {%s t.Name().Short() %}
23          </div>
24          <div class="col-8">
25            <div class="float-end">
26              <a href="/{%s name %}/tree/{%s t.Name().Short() %}">tree</a>
27              <a href="/{%s name %}/log/{%s t.Name().Short() %}">log</a>
28            </div>
29          </div>
30      </div>
31      {% endfor %}
32    </div>
33    {% else %}
34        <p> No tags </p>
35    {% endif %}
36  </div>
37  <div class="col-md-4">
38    <div class="event-list">
39      {% for _, b := range g.Branches %}
40      <div class="row event">
41          <div class="col-4">
42           {%s b.Name().Short() %}
43          </div>
44          <div class="col-8">
45            <div class="float-end">
46              <a href="/{%s name %}/tree/{%s b.Name().Short() %}">tree</a>
47              <a href="/{%s name %}/log/{%s b.Name().Short() %}">log</a>
48            </div>
49          </div>
50      </div>
51      {% endfor %}
52    </div>
53  </div>
54</div>
55<div class="row">
56  <div class="event-list">
57    {% for _, c := range g.Commits %}
58    <div class="row event">
59        <div class="col-xxl-2">
60         {%s TimeFormat(c.Committer.When) %}
61        </div>
62        <div class="col-xxl-7 code-view">
63         <pre>{%s c.Message %}</pre>
64        </div>
65        <div class="col-xxl-3">
66         <small>{%s c.Committer.Name %} &lt;{%s c.Committer.Email %}&gt;</small>
67        </div>
68    </div>
69    {% endfor %}
70  </div>
71</div>
72{% endfunc %}