Commit 43a8eaa579

43a8eaa579f8101094c28bc0d097b58dc6f356e2

parent: 2dba2b3994

Verified · cmc ci/build: success ci/test: success ci/vuln: success

cmc <hello@cleberg.net> · 2026-09-04 03:11 UTC

css: dead rules out, off-scale values on the scale, undefined classes resolved

Removed rules no template reaches (.mirrorline, .mirrorerr,
.railsettings, .container, .repogrid), a dark block that restated the
light value, and the second of two form.inline and .repohead .topics
declarations. The landing headline and the 404 code join the type
scale as --fs-6 and --fs-7, the dropdown shadow is a --shadow token in
both schemes, the rail item padding is --sp-1, and the blame border
uses --r-md instead of an undefined --rad-2 with a 6px fallback.
Templates asked for .primary, which a bare button already is, and
.pathbar .actions, which the stylesheet spelled .act; the edit form's
widths move from inline styles to rules.

Closes #131

Layout: unified · split

internal/web/static/style.css +14 −19
@@ -82,6 +82,8 @@
82 --fs-3: 1rem; 82 --fs-3: 1rem;
83 --fs-4: 1.2rem; 83 --fs-4: 1.2rem;
84 --fs-5: 1.6rem; 84 --fs-5: 1.6rem;
85 --fs-6: 1.8rem; /* landing headline */
86 --fs-7: 4rem; /* the 404 code */
85 87
86 /* spacing */ 88 /* spacing */
87 --sp-1: 0.25rem; 89 --sp-1: 0.25rem;
@@ -98,6 +100,7 @@
98 --r-md: 2px; 100 --r-md: 2px;
99 --r-lg: 2px; 101 --r-lg: 2px;
100 --r-pill: 2px; 102 --r-pill: 2px;
103 --shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
101} 104}
102@media (prefers-color-scheme: dark) { 105@media (prefers-color-scheme: dark) {
103 :root { 106 :root {
@@ -120,6 +123,7 @@
120 --accent-fg: #ffffff; 123 --accent-fg: #ffffff;
121 --fill: #0000f0; /* fills stay pure; white on it clears 9:1 */ 124 --fill: #0000f0; /* fills stay pure; white on it clears 9:1 */
122 --fill-edge: #7d8cff; /* a button's boundary: #0000f0 on #0a0a0a is 1.3:1 (#120) */ 125 --fill-edge: #7d8cff; /* a button's boundary: #0000f0 on #0a0a0a is 1.3:1 (#120) */
126 --shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
123 --mark: #ff6b3d; 127 --mark: #ff6b3d;
124 --warn: #ff6b3d; 128 --warn: #ff6b3d;
125 --ok: #3fce7a; 129 --ok: #3fce7a;
@@ -223,7 +227,7 @@ a.brand span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
223ul.raillist { list-style: none; margin: 0; padding: 0; } 227ul.raillist { list-style: none; margin: 0; padding: 0; }
224ul.raillist a { 228ul.raillist a {
225 display: block; 229 display: block;
226 padding: 0.28rem var(--sp-4); 230 padding: var(--sp-1) var(--sp-4);
227 color: var(--shell-fg); 231 color: var(--shell-fg);
228 font-size: var(--fs-2); 232 font-size: var(--fs-2);
229 border-left: 3px solid transparent; 233 border-left: 3px solid transparent;
@@ -289,8 +293,6 @@ a.railuser { display: inline-flex; align-items: center; gap: var(--sp-2); }
289 none and the name draws its own — the avatar square stays undecorated */ 293 none and the name draws its own — the avatar square stays undecorated */
290a.railuser:hover { text-decoration: none; } 294a.railuser:hover { text-decoration: none; }
291a.railuser:hover .uname { text-decoration: underline; } 295a.railuser:hover .uname { text-decoration: underline; }
292.railfoot .railsettings { color: var(--shell-muted); display: inline-flex; }
293.railfoot .railsettings:hover { color: var(--shell-fg); }
294.railfoot form { margin-left: auto; } 296.railfoot form { margin-left: auto; }
295.railfoot .linklike { 297.railfoot .linklike {
296 background: none; border: 0; padding: 0; cursor: pointer; 298 background: none; border: 0; padding: 0; cursor: pointer;
@@ -337,7 +339,6 @@ a.railuser:hover .uname { text-decoration: underline; }
337.repotitle .sep { color: var(--muted); margin: 0 0.12em; font-weight: 400; } 339.repotitle .sep { color: var(--muted); margin: 0 0.12em; font-weight: 400; }
338.repodesc { margin: var(--sp-2) 0 0; color: var(--muted); font-size: var(--fs-2); max-width: 62ch; } 340.repodesc { margin: var(--sp-2) 0 0; color: var(--muted); font-size: var(--fs-2); max-width: 62ch; }
339.repometa { margin: var(--sp-1) 0 0; color: var(--muted); font-size: var(--fs-1); } 341.repometa { margin: var(--sp-1) 0 0; color: var(--muted); font-size: var(--fs-1); }
340.repohead .topics { margin: var(--sp-2) 0 0; }
341 342
342button.btn { 343button.btn {
343 font: inherit; 344 font: inherit;
@@ -470,7 +471,7 @@ details.refmenu .refdrop {
470 background: var(--bg); 471 background: var(--bg);
471 border: 1px solid var(--line); 472 border: 1px solid var(--line);
472 border-radius: var(--r-md); 473 border-radius: var(--r-md);
473 box-shadow: 0 4px 16px rgba(0,0,0,0.12); 474 box-shadow: var(--shadow);
474 padding: var(--sp-1) 0; 475 padding: var(--sp-1) 0;
475} 476}
476details.refmenu .refdrop a { 477details.refmenu .refdrop a {
@@ -728,7 +729,7 @@ a.memberchip .role { color: var(--muted); }
728 729
729/* landing page */ 730/* landing page */
730.landing { max-width: 44rem; padding: var(--sp-6) 0; } 731.landing { max-width: 44rem; padding: var(--sp-6) 0; }
731.landing h1 { font-size: 1.8rem; margin-bottom: var(--sp-3); } 732.landing h1 { font-size: var(--fs-6); margin-bottom: var(--sp-3); }
732.landing .lede { font-size: var(--fs-4); color: var(--muted); line-height: 1.7; margin: 0 0 var(--sp-4); } 733.landing .lede { font-size: var(--fs-4); color: var(--muted); line-height: 1.7; margin: 0 0 var(--sp-4); }
733pre.quickstart { 734pre.quickstart {
734 background: var(--code-bg); 735 background: var(--code-bg);
@@ -742,7 +743,6 @@ pre.quickstart {
742 743
743/* index toolbar */ 744/* index toolbar */
744p.toolbar { color: var(--muted); font-size: var(--fs-2); margin-top: var(--sp-4); } 745p.toolbar { color: var(--muted); font-size: var(--fs-2); margin-top: var(--sp-4); }
745form.inline { display: inline; }
746button.linklike { 746button.linklike {
747 background: none; 747 background: none;
748 border: none; 748 border: none;
@@ -767,10 +767,6 @@ button.linklike:hover { text-decoration: underline; filter: none; }
767 follow the site's own colors. */ 767 follow the site's own colors. */
768.code { background: var(--code-bg); color: var(--fg); padding: var(--sp-3) var(--sp-4); border-color: var(--line); } 768.code { background: var(--code-bg); color: var(--fg); padding: var(--sp-3) var(--sp-4); border-color: var(--line); }
769.code pre { margin: 0; background: transparent !important; } 769.code pre { margin: 0; background: transparent !important; }
770@media (prefers-color-scheme: dark) {
771 .code { border-color: var(--line); }
772}
773
774/* rendered markdown / org / html */ 770/* rendered markdown / org / html */
775.rendered { max-width: 100%; overflow-wrap: anywhere; } 771.rendered { max-width: 100%; overflow-wrap: anywhere; }
776/* A linked line: #f2-n17 on a diff, #L17 on a file (#118). */ 772/* A linked line: #f2-n17 on a diff, #L17 on a file (#118). */
@@ -1024,8 +1020,6 @@ table.difftable td.ln a.cmt:focus { color: var(--accent); text-decoration: under
1024.chip.label { font-weight: 500; } 1020.chip.label { font-weight: 500; }
1025.chip.topic { --chip: var(--accent); } 1021.chip.topic { --chip: var(--accent); }
1026.repohead .topics { margin: 0 0 var(--sp-2); } 1022.repohead .topics { margin: 0 0 var(--sp-2); }
1027.repohead .mirrorline { margin: 0 0 var(--sp-2); }
1028.mirrorerr { color: var(--bad); }
1029.badge-verified { --chip: var(--ok); } 1023.badge-verified { --chip: var(--ok); }
1030.badge-unsigned { --chip: var(--neutral); } 1024.badge-unsigned { --chip: var(--neutral); }
1031.badge-signed_unknown_key { --chip: var(--warn); } 1025.badge-signed_unknown_key { --chip: var(--warn); }
@@ -1317,7 +1311,7 @@ button:hover { filter: brightness(1.15); }
1317.notfound { text-align: center; padding: var(--sp-6) 0; } 1311.notfound { text-align: center; padding: var(--sp-6) 0; }
1318.notfound .bigcode { 1312.notfound .bigcode {
1319 font-family: var(--mono); 1313 font-family: var(--mono);
1320 font-size: 4rem; 1314 font-size: var(--fs-7);
1321 color: var(--faint); 1315 color: var(--faint);
1322 -webkit-text-stroke: 1px var(--line); 1316 -webkit-text-stroke: 1px var(--line);
1323 margin: 0; 1317 margin: 0;
@@ -1386,7 +1380,7 @@ pre.matchline mark {
1386/* blame */ 1380/* blame */
1387.blame { 1381.blame {
1388 border: 1px solid var(--line); 1382 border: 1px solid var(--line);
1389 border-radius: var(--rad-2, 6px); 1383 border-radius: var(--r-md);
1390 overflow: hidden; 1384 overflow: hidden;
1391} 1385}
1392.blamehunk { 1386.blamehunk {
@@ -1429,9 +1423,6 @@ pre.matchline mark {
1429 1423
1430/* mobile */ 1424/* mobile */
1431@media (max-width: 40rem) { 1425@media (max-width: 40rem) {
1432 .container { padding-left: var(--sp-4); padding-right: var(--sp-4); }
1433 main.container { padding-top: var(--sp-2); }
1434 .repogrid { grid-template-columns: 1fr; }
1435 .thread { margin-left: var(--sp-3); } 1426 .thread { margin-left: var(--sp-3); }
1436 /* the commit subject is the widest thing in the listing and the one 1427 /* the commit subject is the widest thing in the listing and the one
1437 column a phone can do without: the tipbar above already names the 1428 column a phone can do without: the tipbar above already names the
@@ -1482,7 +1473,7 @@ table.tree td.name { width: 25%; white-space: nowrap; }
1482table.tree td.name.dir a { color: var(--accent); } 1473table.tree td.name.dir a { color: var(--accent); }
1483p.clone { margin: 0 0 var(--sp-3); } 1474p.clone { margin: 0 0 var(--sp-3); }
1484p.filefacts { color: var(--muted); font-size: var(--fs-1); margin: 0 0 var(--sp-3); } 1475p.filefacts { color: var(--muted); font-size: var(--fs-1); margin: 0 0 var(--sp-3); }
1485.pathbar .act { font-size: var(--fs-1); } 1476.pathbar .actions { font-size: var(--fs-1); color: var(--muted); }
1486 1477
1487/* merge request: a two-column split, so state has somewhere to live that 1478/* merge request: a two-column split, so state has somewhere to live that
1488 is not a run-on sentence under the title */ 1479 is not a run-on sentence under the title */
@@ -1549,3 +1540,7 @@ nav.subtabs a i {
1549p.diffstat { color: var(--muted); font-size: var(--fs-2); margin: 0 0 var(--sp-3); } 1540p.diffstat { color: var(--muted); font-size: var(--fs-2); margin: 0 0 var(--sp-3); }
1550p.diffstat .add { color: var(--ok); } 1541p.diffstat .add { color: var(--ok); }
1551p.diffstat .del { color: var(--bad); } 1542p.diffstat .del { color: var(--bad); }
1543
1544/* file edit form */
1545.editform textarea { width: 100%; }
1546.editform input[name="message"] { width: 60%; }
internal/web/templates/account.html +2 −2
@@ -29,7 +29,7 @@ a CI checkout wants.</p>
29 <option value="full">full — commands and git</option> 29 <option value="full">full — commands and git</option>
30 <option value="git">git — git transport only</option> 30 <option value="git">git — git transport only</option>
31 </select> 31 </select>
32 <button type="submit" class="primary">Add key</button> 32 <button type="submit">Add key</button>
33 </form> 33 </form>
34</details> 34</details>
35 35
@@ -76,7 +76,7 @@ account, and where notifications go.</p>
76 <input type="hidden" name="field" value="pgp-add"> 76 <input type="hidden" name="field" value="pgp-add">
77 <label for="pgpkey">Armored public key</label> 77 <label for="pgpkey">Armored public key</label>
78 <textarea id="pgpkey" name="key" rows="6" required placeholder="-----BEGIN PGP PUBLIC KEY BLOCK-----"></textarea> 78 <textarea id="pgpkey" name="key" rows="6" required placeholder="-----BEGIN PGP PUBLIC KEY BLOCK-----"></textarea>
79 <button type="submit" class="primary">Add key</button> 79 <button type="submit">Add key</button>
80 </form> 80 </form>
81</details> 81</details>
82 82
internal/web/templates/builds.html +1 −1
@@ -8,7 +8,7 @@
8 <select id="job" name="job"> 8 <select id="job" name="job">
9 {{range .Jobs}}<option value="{{.Name}}">{{.Name}}{{if .Schedule}} (schedule {{.Schedule}}){{else if .Tags}} (tags {{.Tags}}){{end}}</option>{{end}} 9 {{range .Jobs}}<option value="{{.Name}}">{{.Name}}{{if .Schedule}} (schedule {{.Schedule}}){{else if .Tags}} (tags {{.Tags}}){{end}}</option>{{end}}
10 </select> 10 </select>
11 <button type="submit" class="primary">Run</button> 11 <button type="submit">Run</button>
12</form> 12</form>
13{{end}} 13{{end}}
14<details class="editbox"><summary>Status badge</summary> 14<details class="editbox"><summary>Status badge</summary>
internal/web/templates/edit.html +3 −3
@@ -2,9 +2,9 @@
2{{define "content"}} 2{{define "content"}}
3<h1>edit {{.Repo.OwnerName}}/{{.Repo.Name}} : {{.Path}} @ {{.Ref}}</h1> 3<h1>edit {{.Repo.OwnerName}}/{{.Repo.Name}} : {{.Path}} @ {{.Ref}}</h1>
4{{if .Error}}<p class="error" role="alert">{{.Error}}</p>{{end}} 4{{if .Error}}<p class="error" role="alert">{{.Error}}</p>{{end}}
5<form method="post" action="/{{.Repo.OwnerName}}/{{.Repo.Name}}/edit/{{.Ref}}/{{.Path}}"> 5<form method="post" action="/{{.Repo.OwnerName}}/{{.Repo.Name}}/edit/{{.Ref}}/{{.Path}}" class="editform">
6<p><textarea name="content" aria-label="File contents" rows="24" style="width:100%" spellcheck="false">{{.Content}}</textarea></p> 6<p><textarea name="content" aria-label="File contents" rows="24" spellcheck="false">{{.Content}}</textarea></p>
7<p><input name="message" aria-label="Commit message" placeholder="commit message" style="width:60%"> 7<p><input name="message" aria-label="Commit message" placeholder="commit message">
8<button type="submit">Commit to {{.Ref}}</button></p> 8<button type="submit">Commit to {{.Ref}}</button></p>
9<p class="crumbs">this commit will be unsigned and authored as {{.Viewer}}</p> 9<p class="crumbs">this commit will be unsigned and authored as {{.Viewer}}</p>
10</form> 10</form>
internal/web/templates/mr.html +1 −1
@@ -102,7 +102,7 @@
102 <option value="squash">Squash</option> 102 <option value="squash">Squash</option>
103 <option value="rebase">Rebase</option> 103 <option value="rebase">Rebase</option>
104 </select> 104 </select>
105 <button type="submit" class="primary">Merge</button> 105 <button type="submit">Merge</button>
106 </form> 106 </form>
107 <form method="post" action="{{$base}}/close" class="actions"> 107 <form method="post" action="{{$base}}/close" class="actions">
108 <button type="submit">Close without merging</button> 108 <button type="submit">Close without merging</button>
internal/web/templates/mrnew.html +1 −1
@@ -16,7 +16,7 @@
16</p> 16</p>
17<p><input type="text" name="title" aria-label="Title" placeholder="title" value="{{.Title}}" required></p> 17<p><input type="text" name="title" aria-label="Title" placeholder="title" value="{{.Title}}" required></p>
18<p><textarea name="body" aria-label="Description" rows="10" placeholder="what changes, and why">{{.Body}}</textarea></p> 18<p><textarea name="body" aria-label="Description" rows="10" placeholder="what changes, and why">{{.Body}}</textarea></p>
19<p><button type="submit" class="primary">Open merge request</button></p> 19<p><button type="submit">Open merge request</button></p>
20</form> 20</form>
21<p class="meta">A branch in a fork opens from the CLI: 21<p class="meta">A branch in a fork opens from the CLI:
22<code>gitbay mr create {{.Repo.OwnerName}}/{{.Repo.Name}} --source owner/fork:branch --target {{.Repo.DefaultBranch}} --title "…"</code></p> 22<code>gitbay mr create {{.Repo.OwnerName}}/{{.Repo.Name}} --source owner/fork:branch --target {{.Repo.DefaultBranch}} --title "…"</code></p>
internal/web/templates/releases.html +1 −1
@@ -13,7 +13,7 @@
13 </p> 13 </p>
14 <p><input type="text" name="title" aria-label="Title" placeholder="title (defaults to the tag)"></p> 14 <p><input type="text" name="title" aria-label="Title" placeholder="title (defaults to the tag)"></p>
15 <p><textarea name="notes" aria-label="Notes" rows="6" placeholder="what changed"></textarea></p> 15 <p><textarea name="notes" aria-label="Notes" rows="6" placeholder="what changed"></textarea></p>
16 <p><button type="submit" class="primary">Create release</button></p> 16 <p><button type="submit">Create release</button></p>
17</form> 17</form>
18</details> 18</details>
19{{else if .CanWrite}}<p class="meta">Push a tag to create a release from it.</p>{{end}} 19{{else if .CanWrite}}<p class="meta">Push a tag to create a release from it.</p>{{end}}