diff options
Diffstat (limited to 'templates/gititemtree.qtpl')
-rw-r--r-- | templates/gititemtree.qtpl | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/templates/gititemtree.qtpl b/templates/gititemtree.qtpl index be7a27d..68b9856 100644 --- a/templates/gititemtree.qtpl +++ b/templates/gititemtree.qtpl @@ -14,15 +14,21 @@ type GitItemTreePage struct { {% func (g *GitItemTreePage) Nav(name, ref string) %}{%= GitItemNav(name, ref, Tree) %}{% endfunc %} {% func (g *GitItemTreePage) GitContent() %} -{% for _, e := range g.Tree.Entries %} <div class="row"> - <div class="col">{%s Ignore(e.Mode.ToOSFileMode()).String() %}</div> - {% if e.Mode.IsFile() %} - <div class="col-md"><a href="/{%s g.Name %}/blob/{%s g.Ref%}/{%s g.CurrentPath %}/{%s e.Name %}">{%s e.Name %}</a></div> - {% else %} - <div class="col-md"><a href="./{%s g.CurrentPath %}/{%s e.Name %}">{%s e.Name %}</a></div> - {% endif %} - <div class="col-md">{%dl Ignore(g.Tree.Size(e.Name))%} KiB</div> + <div class="col-md-12"> + <div class="tree-list"> + {% for _, e := range g.Tree.Entries %} + <div class="mode">{%s Ignore(e.Mode.ToOSFileMode()).String() %}</div> + {% if e.Mode.IsFile() %} + <div class="name blob"><a href="/{%s g.Name %}/blob/{%s g.Ref%}/{%s g.CurrentPath %}/{%s e.Name %}">{%s e.Name %}</a></div> + {% else %} + <div class="name tree"><a href="./{%s g.CurrentPath %}/{%s e.Name %}">{%s e.Name %}</a></div> + {% endif %} + <div class="commit"></div> + <div class="date"></div> + <div class="size">{%dl Ignore(g.Tree.Size(e.Name))%} KiB</div> + {% endfor %} + </div> + </div> </div> -{% endfor %} {% endfunc %} |