all repos

mugit @ afcfaf3e038adfaa00c7299ea3c0197e9d861a57

馃惍 git server that your cow will love
8 files changed, 52 insertions(+), 107 deletions(-)
ui: redo css, again
Author: Oleksandr Smirnov olexsmir@gmail.com
Committed at: 2026-03-12 13:50:45 +0200
Authored at: 2026-03-11 22:11:59 +0200
Change ID: skqkklykzyqrrzymzzwsozunztpqoptp
Parent: d4f69f4
M web/static/style.css
路路路
        9
        9
           --darker: #222;

      
        10
        10
           --diff-add: green;

      
        11
        11
           --diff-del: red;

      
        
        12
        +  --sel-bg: rgba(0, 0, 0, 0.08);

      
        12
        13
         

      
        13
        14
           --sans-font: -apple-system, BlinkMacSystemFont, "Inter", "Roboto", "Segoe UI", sans-serif;

      
        14
        
        -  --mono-font: 'SF Mono', SFMono-Regular, ui-monospace, 'DejaVu Sans Mono', 'Roboto Mono', Menlo, Consolas, monospace;

      
        
        15
        +  --mono-font: "SF Mono", SFMono-Regular, ui-monospace, "DejaVu Sans Mono", "Roboto Mono", Menlo, Consolas, monospace;

      
        15
        16
         }

      
        16
        17
         

      
        17
        18
         @media (prefers-color-scheme: dark) {

      路路路
        25
        26
             --dark: #ddd;

      
        26
        27
             --darker: #f4f4f4;

      
        27
        28
             --white: #000;

      
        
        29
        +    --sel-bg: rgba(255, 255, 255, 0.08);

      
        28
        30
           }

      
        29
        31
         }

      
        30
        32
         

      路路路
        34
        36
           margin: 0;

      
        35
        37
         }

      
        36
        38
         

      
        
        39
        +::selection { background: var(--medium-gray); }

      
        
        40
        +

      
        37
        41
         html {

      
        38
        42
           background: var(--white);

      
        39
        43
           -webkit-text-size-adjust: none;

      路路路
        49
        53
           margin: 40px auto;

      
        50
        54
         }

      
        51
        55
         

      
        52
        
        -::selection {

      
        53
        
        -  background: var(--medium-gray);

      
        54
        
        -}

      
        55
        
        -

      
        56
        56
         a {

      
        57
        57
           text-decoration: none;

      
        58
        58
           word-wrap: break-word;

      路路路
        78
        78
         nav { padding: 0.4rem 0 1.5rem 0; }

      
        79
        79
         nav ul {

      
        80
        80
           list-style: none;

      
        81
        
        -  padding-bottom: 20px;

      
        
        81
        +  padding-bottom: 1.25rem;

      
        82
        82
         }

      
        83
        83
         

      
        84
        84
         nav ul li {

      路路路
        87
        87
         }

      
        88
        88
         

      
        89
        89
         /* utilities */

      
        
        90
        +.mono { font-family: var(--mono-font); }

      
        90
        91
         .nowrap { white-space: nowrap; }

      
        91
        92
         .fill { width: 100%; }

      
        92
        93
         .muted { color: var(--gray); }

      
        93
        
        -.padtop { padding-top: 20px; }

      
        94
        
        -

      
        
        94
        +.pt { padding-top: 1rem; }

      
        
        95
        +.mb { margin-bottom: 1rem; }

      
        95
        96
         .center {

      
        96
        97
           display: flex;

      
        97
        98
           justify-content: center;

      
        98
        99
         }

      
        99
        100
         

      
        100
        
        -.size { text-align: right; }

      
        101
        
        -

      
        102
        
        -.mode, .size,

      
        103
        
        -.commit-hash, .commit-email,

      
        104
        
        -.diff-type { font-family: var(--mono-font); }

      
        105
        
        -

      
        106
        
        -.mb { margin-bottom: 1rem; }

      
        107
        
        -

      
        108
        101
         /* tables */

      
        109
        102
         .table {

      
        110
        103
           width: 100%;

      路路路
        138
        131
           padding: 0.5rem 0.7rem;

      
        139
        132
           background: var(--white);

      
        140
        133
           border: 1px solid var(--medium-gray);

      
        141
        
        -  border-radius: 4px;

      
        142
        
        -  box-shadow: 0 2px 8px rgba(0,0,0,0.1);

      
        143
        134
           z-index: 10;

      
        144
        135
           font-size: 0.85em;

      
        145
        136
           line-height: 1.3;

      路路路
        147
        138
           white-space: nowrap;

      
        148
        139
         }

      
        149
        140
         

      
        150
        
        -.author, .age { position: relative; }

      
        151
        
        -

      
        152
        
        -.author:hover .tooltip,

      
        153
        
        -.author:focus-within .tooltip,

      
        154
        
        -.age:hover .tooltip,

      
        155
        
        -.age:focus-within .tooltip {

      
        156
        
        -  display: block;

      
        157
        
        -}

      
        
        141
        +.has-tip { position: relative; }

      
        
        142
        +.has-tip:hover .tooltip,

      
        
        143
        +.has-tip:focus-within .tooltip { display: block; }

      
        158
        144
         

      
        159
        145
         /* box */

      
        
        146
        +.box + .box { margin-top: 0.8rem; }

      
        160
        147
         .box {

      
        161
        148
           background: var(--light-gray);

      
        162
        149
           padding: 0.6rem;

      
        163
        150
         }

      
        164
        151
         

      
        165
        
        -.box + .box {

      
        166
        
        -  margin-top: 0.8rem;

      
        167
        
        -}

      
        168
        
        -

      
        169
        152
         /* repo header */

      
        170
        153
         .repo-header { margin-bottom: 1.25rem; }

      
        
        154
        +.repo-header .desc { margin-top: 0.35rem; }

      
        
        155
        +.repo-header .repo-nav { padding: 0.5rem 0 0 0; }

      
        
        156
        +.repo-header .repo-nav ul { padding-bottom: 0; }

      
        171
        157
         

      
        172
        
        -.repo-breadcrumb,

      
        173
        
        -.repo-breadcrumb a {

      
        174
        
        -  color: var(--gray);

      
        175
        
        -}

      
        176
        158
         

      
        
        159
        +.repo-breadcrumb,

      
        
        160
        +.repo-breadcrumb a { color: var(--gray); }

      
        177
        161
         .repo-breadcrumb:before { content: "<"; }

      
        178
        162
         

      
        179
        163
         .repo-name {

      路路路
        182
        166
           margin-top: 0.25rem;

      
        183
        167
         }

      
        184
        168
         

      
        185
        
        -.repo-header .desc { margin-top: 0.35rem; }

      
        186
        
        -.repo-header .repo-nav { padding: 0.5rem 0 0 0; }

      
        187
        
        -.repo-header .repo-nav ul { padding-bottom: 0; }

      
        188
        
        -

      
        189
        169
         /* index page */

      
        190
        170
         .index { margin-top: 2em; }

      
        191
        171
         

      路路路
        209
        189
         }

      
        210
        190
         

      
        211
        191
         /* log page */

      
        212
        
        -.log td.author .author-short {

      
        
        192
        +.log td.has-tip .author-short {

      
        213
        193
           display: inline-block;

      
        214
        194
           max-width: 25ch;

      
        215
        195
           overflow: hidden;

      路路路
        237
        217
         

      
        238
        218
         .line-number {

      
        239
        219
           width: 1%;

      
        240
        
        -  -moz-user-select: -moz-none;

      
        
        220
        +  user-select: none;

      
        
        221
        +  -webkit-user-select: none;

      
        
        222
        +  -moz-user-select: none;

      
        241
        223
           -khtml-user-select: none;

      
        242
        
        -  -webkit-user-select: none;

      
        243
        224
           -o-user-select: none;

      
        
        225
        +  text-align: right;

      
        
        226
        +  color: var(--gray);

      
        244
        227
         }

      
        245
        228
         

      
        246
        229
         .line-number a:hover { border-bottom: none; }

      
        247
        230
         .line-number a {

      
        248
        
        -    display: block;

      
        249
        
        -    padding: 0 1rem;

      
        250
        
        -    text-decoration: none;

      
        
        231
        +  display: block;

      
        
        232
        +  padding: 0 1rem;

      
        
        233
        +  text-decoration: none;

      
        251
        234
         }

      
        252
        235
         

      
        253
        
        -.line:has(a:target) { background-color: rgba(0,0,0,0.4); }

      
        
        236
        +.line:has(a:target) { background-color: var(--sel-bg); }

      
        254
        237
         

      
        255
        238
         .image-viewer, .binary-viewer { padding: 1rem 0; }

      
        256
        239
         .image-viewer img {

      路路路
        260
        243
         

      
        261
        244
         /* commit */

      
        262
        245
         .commit { margin-bottom: 1rem; }

      
        263
        
        -

      
        
        246
        +.commit .box { margin-bottom: 0.25rem; }

      
        
        247
        +.commit .commit-info { padding-bottom: 0.25rem; }

      
        264
        248
         .commit pre {

      
        265
        249
           padding-bottom: 0;

      
        266
        250
           white-space: pre-wrap;

      
        267
        251
         }

      
        268
        252
         

      
        269
        
        -.commit .box { margin-bottom: 0.25rem; }

      
        270
        
        -.commit .commit-info {

      
        271
        
        -  padding-bottom: 0.25rem;

      
        272
        
        -}

      
        273
        
        -

      
        274
        253
         .commit-message {

      
        275
        254
           margin-top: 0.25rem;

      
        276
        255
           font-size: 1rem;

      路路路
        285
        264
         

      
        286
        265
         .commit-date { float: right; }

      
        287
        266
         

      
        
        267
        +.commit-email { font-family: var(--mono-font); }

      
        288
        268
         .commit-email:before { content: '<'; }

      
        289
        269
         .commit-email:after { content: '>'; }

      
        290
        270
         

      
        291
        
        -.commit-refs {

      
        292
        
        -  margin: 0.5rem 0 1rem 0;

      
        293
        
        -}

      
        294
        
        -

      
        
        271
        +.commit-refs { margin: 0.5rem 0 1rem 0; }

      
        
        272
        +.commit-refs td.label { padding-right: 1rem; }

      
        295
        273
         .commit-refs td {

      
        296
        274
           padding: 0.15rem 0.5rem 0.15rem 0;

      
        297
        275
           border: none;

      
        298
        
        -}

      
        299
        
        -

      
        300
        
        -.commit-refs td.label {

      
        301
        
        -  padding-right: 1rem;

      
        302
        276
         }

      
        303
        277
         

      
        304
        278
         /* diff */

      路路路
        314
        288
           margin: 0;

      
        315
        289
         }

      
        316
        290
         

      
        317
        
        -.diff-line {

      
        318
        
        -  display: flex;

      
        319
        
        -}

      
        320
        
        -

      
        
        291
        +.diff-line { display: flex; }

      
        
        292
        +.diff-line:target { background: var(--sel-bg); }

      
        321
        293
         .diff-line .line-number {

      
        322
        294
           flex-shrink: 0;

      
        323
        
        -  user-select: none;

      
        324
        
        -  -webkit-user-select: none;

      
        325
        
        -  text-align: right;

      
        326
        
        -  color: var(--gray);

      
        327
        295
           border-right: 1px solid var(--light-gray);

      
        328
        296
           padding: 0 0.5rem;

      
        329
        297
           min-width: 3rem;

      路路路
        339
        307
           padding: 0 0.5rem;

      
        340
        308
         }

      
        341
        309
         

      
        342
        
        -.diff-line:target {

      
        343
        
        -  background: rgba(0, 0, 0, 0.05);

      
        344
        
        -}

      
        345
        
        -

      
        346
        
        -@media (prefers-color-scheme: dark) {

      
        347
        
        -  .diff-line:target {

      
        348
        
        -    background: rgba(255, 255, 255, 0.05);

      
        349
        
        -  }

      
        350
        
        -}

      
        351
        
        -

      
        352
        310
         .diff-stat { padding: 1rem 0 1rem 0; }

      
        353
        311
         .diff-add { color: var(--diff-add); }

      
        354
        312
         .diff-del { color: var(--diff-del); }

      路路路
        361
        319
         

      
        362
        320
         .jump { margin-top: 0.5rem; }

      
        363
        321
         .jump-table { margin-top: 0.25rem; }

      
        364
        
        -

      
        
        322
        +.jump-table .diff-type { width: 2ch; }

      
        365
        323
         .jump-table td {

      
        366
        324
           padding: 0.15rem 0.5rem;

      
        367
        325
           border-color: var(--medium-gray);

      
        368
        
        -}

      
        369
        
        -

      
        370
        
        -.jump-table .diff-type {

      
        371
        
        -  width: 2ch;

      
        372
        326
         }

      
        373
        327
         

      
        374
        328
         /* refs */

      路路路
        398
        352
         }

      
        399
        353
         .readme > *:first-child { margin-top: 0; }

      
        400
        354
         

      
        401
        
        -.readme h1, .readme h2, .readme h3,

      
        402
        
        -.readme h4, .readme h5, .readme h6 {

      
        
        355
        +.readme h1, .readme h2, .readme h3, .readme h4, .readme h5, .readme h6 {

      
        403
        356
           margin-top: 1.5em;

      
        404
        357
           margin-bottom: 0.5em;

      
        405
        358
           line-height: 1.25;

      路路路
        447
        400
         }

      
        448
        401
         

      
        449
        402
         @media (max-width: 600px) {

      
        450
        
        -  .repo-index {

      
        451
        
        -    flex-direction: column;

      
        452
        
        -  }

      
        
        403
        +  pre { font-size: 0.8rem; }

      
        453
        404
         

      
        454
        
        -  .repo-index-main,

      
        455
        
        -  .repo-index-side {

      
        
        405
        +  .repo-index { flex-direction: column; }

      
        
        406
        +  .repo-index-main, .repo-index-side {

      
        456
        407
             flex: none;

      
        457
        408
             width: 100%;

      
        458
        409
           }

      
        459
        410
         

      
        460
        
        -  .commit-info:not(:last-child) {

      
        461
        
        -    padding-bottom: 1.5rem;

      
        462
        
        -  }

      
        463
        
        -

      
        464
        
        -  pre {

      
        465
        
        -    font-size: 0.8rem;

      
        466
        
        -  }

      
        
        411
        +  .commit-info:not(:last-child) { padding-bottom: 1.5rem; }

      
        467
        412
         }

      
M web/templates/index.html
路路路
        30
        30
                       </a>

      
        31
        31
                     <td class="nowrap">

      
        32
        32
                       {{ if not .LastCommit.IsZero }}

      
        33
        
        -              <span class="age">

      
        
        33
        +              <span class="has-tip">

      
        34
        34
                         {{- humanizeRelTime .LastCommit -}}

      
        35
        35
                         <span class="tooltip" role="tooltip">{{- humanizeTime .LastCommit -}}</span>

      
        36
        36
                       </span>

      
M web/templates/repo_commit.html
路路路
        71
        71
                       {{ $path := .Name.New }}

      
        72
        72
                       {{ if not $path }}{{ $path = .Name.Old }}{{ end }}

      
        73
        73
                       <tr>

      
        74
        
        -                <td class="diff-type">{{ template "_diff_type" . }}</td>

      
        
        74
        +                <td class="mono">{{ template "_diff_type" . }}</td>

      
        75
        75
                         <td class="fill">

      
        76
        76
                           <a href="#{{ $path }}">

      
        77
        77
                             {{ if .IsRename }}{{ .Name.Old }} &#8594; {{ .Name.New }}

      
M web/templates/repo_file.html
路路路
        10
        10
               <p>

      
        11
        11
                 <a class="link" href="/{{ .RepoName }}/tree/{{ .P.Ref }}">{{ .RepoName }}</a>

      
        12
        12
                 {{- range .P.Breadcrumbs  -}}

      
        13
        
        -        <span class="mode">/</span>

      
        
        13
        +        <span class="mono">/</span>

      
        14
        14
                 {{- if .IsLast -}}{{- .Name -}}

      
        15
        15
                 {{- else -}}<a class="link" href="/{{ $.RepoName }}/tree/{{ $.P.Ref }}/{{ .Path }}">{{ .Name }}</a>{{- end -}}

      
        16
        16
                 {{- end -}}

      
M web/templates/repo_index.html
路路路
        19
        19
                     <div>

      
        20
        20
                       <a href="/{{ $repo }}/commit/{{ .Hash }}" class="commit-hash link">{{ .HashShort }}</a>

      
        21
        21
                       &mdash; {{ .AuthorName }}

      
        22
        
        -              <span class="commit-date commit-info age">

      
        
        22
        +              <span class="commit-date commit-info has-tip">

      
        23
        23
                         {{ .Committed.Format "Mon, 02 Jan 2006" }}

      
        24
        24
                         <span class="tooltip" role="tooltip">{{ humanizeTime .Committed }}</span>

      
        25
        25
                       </span>

      
M web/templates/repo_log.html
路路路
        26
        26
                         {{- else -}}<span class="muted">Empty message</span>{{- end -}}

      
        27
        27
                       </a>

      
        28
        28
                     </td>

      
        29
        
        -            <td class="author nowrap">

      
        
        29
        +            <td class="has-tip nowrap">

      
        30
        30
                       <span class="author-short">

      
        31
        31
                         {{ .AuthorName }} <a href="mailto:{{ .AuthorEmail }}" class="commit-email">{{ .AuthorEmail }}</a>

      
        32
        32
                       </span>

      路路路
        35
        35
                         <a href="mailto:{{ .AuthorEmail }}" class="commit-email">{{ .AuthorEmail }}</a>

      
        36
        36
                       </span>

      
        37
        37
                     </td>

      
        38
        
        -            <td class="commit-hash">

      
        
        38
        +            <td class="mono">

      
        39
        39
                       <a href="/{{ $repo }}/commit/{{ .Hash }}">{{ .HashShort }}</a>

      
        40
        40
                     </td>

      
        41
        
        -            <td class="age nowrap">

      
        
        41
        +            <td class="has-tip nowrap">

      
        42
        42
                       {{ humanizeRelTime .Committed }}

      
        43
        43
                       <span class="tooltip" role="tooltip">{{ humanizeTime .Committed }}</span>

      
        44
        44
                     </td>

      
M web/templates/repo_refs.html
路路路
        20
        20
                 {{ end }}

      
        21
        21
               </div>

      
        22
        22
               {{ if .P.Tags }}

      
        23
        
        -      <h3 class="padtop">tags</h3>

      
        
        23
        +      <h3 class="pt">tags</h3>

      
        24
        24
               <div class="refs">

      
        25
        25
                 {{ range .P.Tags }}

      
        26
        26
                 <div>

      
M web/templates/repo_tree.html
路路路
        14
        14
               <p class="mb">

      
        15
        15
                 <a class="link" href="/{{ $name }}/tree/{{ .P.Ref }}">{{ .RepoName }}</a>

      
        16
        16
                 {{- range .P.Breadcrumbs  -}}

      
        17
        
        -        <span class="mode">/</span>

      
        
        17
        +        <span class="mono">/</span>

      
        18
        18
                 {{- if .IsLast -}}{{- .Name -}}

      
        19
        19
                 {{- else -}}<a class="link" href="/{{ $name }}/tree/{{ $.P.Ref }}/{{ .Path }}">{{ .Name }}</a>{{- end -}}

      
        20
        20
                 {{- end -}}

      路路路
        47
        47
                     <td class="fill">

      
        48
        48
                       <a href="/{{ $name }}/commit/{{ .Commit.Hash }}">{{ commitSummary .Commit.Message }}</a>

      
        49
        49
                     </td>

      
        50
        
        -            <td class="age nowrap">

      
        
        50
        +            <td class="has-tip nowrap">

      
        51
        51
                       <a href="/{{ $.RepoName }}/commit/{{ .Commit.Hash }}">{{ humanizeRelTime .Commit.Committed }}</a>

      
        52
        52
                       <span class="tooltip" role="tooltip">{{ humanizeTime .Commit.Committed }}</span>

      
        53
        53
                     </td>

      路路路
        65
        65
                     <td class="fill">

      
        66
        66
                       <a href="/{{ $.RepoName }}/commit/{{ .Commit.Hash }}">{{ commitSummary .Commit.Message }}</a>

      
        67
        67
                     </td>

      
        68
        
        -            <td class="age nowrap">

      
        
        68
        +            <td class="has-tip nowrap">

      
        69
        69
                       <a href="/{{ $.RepoName }}/commit/{{ .Commit.Hash }}">{{ humanizeRelTime .Commit.Committed }}</a>

      
        70
        70
                       <span class="tooltip" role="tooltip">{{ humanizeTime .Commit.Committed }}</span>

      
        71
        71
                     </td>