aboutsummaryrefslogtreecommitdiff
path: root/templates/gititemtree.qtpl
diff options
context:
space:
mode:
authorGabriel A. Giovanini <mail@gabrielgio.me>2024-06-07 23:02:54 +0200
committerGabriel A. Giovanini <mail@gabrielgio.me>2024-06-07 23:02:54 +0200
commite9098e00fb6339b759df5b0df2e086cef8a7ce83 (patch)
tree97ada52833cf152cf347f418e24ccb5bc05fd5e4 /templates/gititemtree.qtpl
parentc7a8aa113a914e70e027fea93265c7232b865b5e (diff)
downloadcerrado-e9098e00fb6339b759df5b0df2e086cef8a7ce83.tar.gz
cerrado-e9098e00fb6339b759df5b0df2e086cef8a7ce83.tar.bz2
cerrado-e9098e00fb6339b759df5b0df2e086cef8a7ce83.zip
feat: Rework some pages
Diffstat (limited to 'templates/gititemtree.qtpl')
-rw-r--r--templates/gititemtree.qtpl24
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 %}