Changes
2 changed files (+83/-13)
-
static/repo-refs.css (new)
-
@@ -0,0 +1,66 @@/* Copyright 2025 Shota FUJI <pockawoooh@gmail.com> * SPDX-License-Identifier: MIT */ .ref-heading { margin: var(--space-sm) 0; margin-block-start: var(--space-xxl); font-size: var(--font-xl); font-weight: var(--font-chonk); line-height: 1.2; } .ref-heading:first-child{ margin-block-start: 0; } .ref-list { list-style: none; margin: 0; padding: 0; } .ref-item { margin: 0; padding: var(--space-md) 0; display: flex; flex-direction: column; gap: var(--space-sm); } .ref-item + .ref-item { border-block-start: 1px solid var(--color-border-subtle); } .ref-name { font-size: var(--font-md); font-weight: var(--font-thick); line-height: 1.3; } .ref-message { margin: 0; font-size: var(--font-sm); font-weight: var(--font-regular); line-height: 1.3; } .ref-actions { display: flex; align-items: center; gap: var(--space-sm); font-size: var(--font-sm); } .ref-actions > a + a::before { content: "/"; padding-inline-end: var(--space-sm); color: var(--color-fg-subtle); } .ref-empty { font-size: var(--font-md); font-style: italic; line-height: 1.3; color: var(--color-fg-weak); }
-
-
-
@@ -7,6 +7,7 @@ <!DOCTYPE html><html lang="en"> <head> {{ template "head" }} <link rel="stylesheet" href="/static/repo-refs.css" /> <title>Refs - {{ .Meta.DisplayName }}</title> <meta name="description" content="Git refs of {{ .Meta.DisplayName }}" /> </head>
-
@@ -28,35 +29,38 @@ {{ template "repo-nav" . }}</header> <main class="main"> {{- $meta := .Meta -}} <h2>Branches</h2> <ul> <h2 class="ref-heading">Branches</h2> <ul class="ref-list"> {{- range .Branches }} <li> <span>{{ .Name.Short }}</span> <div> <li class="ref-item"> <span class="ref-name">{{ .Name.Short }}</span> <div class="ref-actions"> <a href="/{{ $meta.DisplayName }}/log/{{ .Name.Short }}">Commits</a> <a href="/{{ $meta.DisplayName }}/tree/{{ .Name.Short }}">Files</a> <a href="/{{ $meta.DisplayName }}/archive/{{ .Name.Short }}.tar.gz">Download archive</a> <a href="/{{ $meta.DisplayName }}/archive/{{ .Name.Short }}.tar.gz">Archive</a> </div> </li> {{ end -}} </ul> <h2>Tags</h2> <h2 class="ref-heading">Tags</h2> {{- if .Tags }} <ul> <ul class="ref-list"> {{- range .Tags }} <li> <span>{{ .Name }}</span> <div> <li class="ref-item"> <span class="ref-name">{{ .Name }}</span> {{- if .Message }} <p class="ref-message">{{ .Message }}</p> {{ end -}} <div class="ref-actions"> <a href="/{{ $meta.DisplayName }}/log/{{ .Name }}">Commits</a> <a href="/{{ $meta.DisplayName }}/tree/{{ .Name }}">Files</a> <a href="/{{ $meta.DisplayName }}/archive/{{ .Name }}.tar.gz">Download archive</a> <a href="/{{ $meta.DisplayName }}/archive/{{ .Name }}.tar.gz">Archive</a> </div> </li> {{ end -}} </ul> {{- else -}} <p>This repository has no tags.</p> <p class="ref-empty">This repository has no tags.</p> {{ end -}} </main> </body>
-