diff --git a/docs/decisions.md b/docs/decisions.md
index 5a5ee3e..30bf809 100644
--- a/docs/decisions.md
+++ b/docs/decisions.md
@@ -884,3 +884,31 @@ allowlist of request headers instead of stripping a denylist; git proxying
is capped at 8 concurrent requests (503 beyond); registry blobs are always
downloads; issue, pull and comment bodies are cut at 32 KB and threads show
their newest 100 comments.
+
+## A quieter code bar
+
+On an iPhone the repo tabs overlapped: Safari shrank the scrolling tabs
+below their content, so each icon sat on the previous word. Even where they
+fit, six icons, six labels and four count pills under a wrapping language
+legend made the top of the code box busy. This replaces "Tab bars that fit"
+for the repo tabs; the README box's document tabs are unchanged.
+
+- **Plain words.** The repo tabs drop their icons and read like the site
+ nav above them: secondary text, the open tab in `--accent-bright` with an
+ underline as wide as the word, 1.5rem apart (1.25rem on phones). Counts
+ are small secondary numerals, not pills. `flex: none` on each tab stops
+ Safari's squeeze.
+- **Only tabs with something in them.** Code and Commits always show.
+ Releases, Issues, Pulls and Packages show when they have at least one
+ item, or when they're the open page (an old link to an empty page still
+ says where you are). The pages themselves still exist.
+- **Three languages and "other".** `langBar` keeps the three largest
+ languages instead of six; the rest join "other", in the legend and the
+ strip. On phones the legend is 0.75rem with 0.75rem gaps.
+- **Widths** (Geist Pixel advances, as before): all six tabs with counts
+ take 448px of the 631px column. On a 390px phone (358px of content) the
+ showcase repo's three tabs take 202px; all six take 428px and scroll with
+ the edge fade. The legend for Go, CSS, HTML and other takes 335px on a
+ phone, so it stays on one line down to 375px screens.
+- Not checked in a real browser in this pass: the numbers come from the
+ font's metrics, not a render.
diff --git a/internal/build/repo.go b/internal/build/repo.go
index 0c49791..78b4f5e 100644
--- a/internal/build/repo.go
+++ b/internal/build/repo.go
@@ -511,8 +511,8 @@ func licenseName(src []byte) string {
return "license"
}
-// langBar turns Gitea's bytes-per-language into bar segments: the six
-// largest, plus "other" for the rest.
+// langBar turns Gitea's bytes-per-language into bar segments: the three
+// largest, plus "other" for the rest, so the legend fits one line on phones.
func langBar(bytes map[string]int64) []Lang {
var total int64
names := make([]string, 0, len(bytes))
@@ -527,7 +527,7 @@ func langBar(bytes map[string]int64) []Lang {
x, rest := 0.0, 0.0
for i, n := range names {
pct := 100 * float64(bytes[n]) / float64(total)
- if i >= 6 || pct < 0.5 {
+ if i >= 3 || pct < 0.5 {
rest += pct
continue
}
diff --git a/testdata/golden/index.html b/testdata/golden/index.html
index 22fb10d..a9e721b 100644
--- a/testdata/golden/index.html
+++ b/testdata/golden/index.html
@@ -21,9 +21,9 @@
-
-
-
+
+
+
skip to content
diff --git a/testdata/golden/repo-a/blob/README.md.html b/testdata/golden/repo-a/blob/README.md.html
index 60183a2..b6dd929 100644
--- a/testdata/golden/repo-a/blob/README.md.html
+++ b/testdata/golden/repo-a/blob/README.md.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/blob/big.txt.html b/testdata/golden/repo-a/blob/big.txt.html
index 9e033f1..e8b039f 100644
--- a/testdata/golden/repo-a/blob/big.txt.html
+++ b/testdata/golden/repo-a/blob/big.txt.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/blob/cmd/hello/main.go.html b/testdata/golden/repo-a/blob/cmd/hello/main.go.html
index eb5fd99..5f318c3 100644
--- a/testdata/golden/repo-a/blob/cmd/hello/main.go.html
+++ b/testdata/golden/repo-a/blob/cmd/hello/main.go.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/blob/data.bin.html b/testdata/golden/repo-a/blob/data.bin.html
index 1bbacce..fac77e4 100644
--- a/testdata/golden/repo-a/blob/data.bin.html
+++ b/testdata/golden/repo-a/blob/data.bin.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/blob/docs/logo.png.html b/testdata/golden/repo-a/blob/docs/logo.png.html
index 241100c..3f6aec4 100644
--- a/testdata/golden/repo-a/blob/docs/logo.png.html
+++ b/testdata/golden/repo-a/blob/docs/logo.png.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/branches/index.html b/testdata/golden/repo-a/branches/index.html
index b82b54d..24856bb 100644
--- a/testdata/golden/repo-a/branches/index.html
+++ b/testdata/golden/repo-a/branches/index.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
2 branches
diff --git a/testdata/golden/repo-a/commit-latest.html b/testdata/golden/repo-a/commit-latest.html
index be1242b..84bf8ac 100644
--- a/testdata/golden/repo-a/commit-latest.html
+++ b/testdata/golden/repo-a/commit-latest.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
diff --git a/testdata/golden/repo-a/index.html b/testdata/golden/repo-a/index.html
index feb55bc..1310532 100644
--- a/testdata/golden/repo-a/index.html
+++ b/testdata/golden/repo-a/index.html
@@ -11,13 +11,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
-
Go79.8%
HTML12.3%
CSS6.1%
Shell1.4%
other0.5%
+
Go79.8%
HTML12.3%
CSS6.1%
other1.8%
-
+
main
diff --git a/testdata/golden/repo-a/issues/index.html b/testdata/golden/repo-a/issues/index.html
index 3d9a316..3e111b4 100644
--- a/testdata/golden/repo-a/issues/index.html
+++ b/testdata/golden/repo-a/issues/index.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
1 open · 1 closed
diff --git a/testdata/golden/repo-a/log/index.html b/testdata/golden/repo-a/log/index.html
index 69dc056..108de4b 100644
--- a/testdata/golden/repo-a/log/index.html
+++ b/testdata/golden/repo-a/log/index.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum
Latest 27 of 27 commits on main
diff --git a/testdata/golden/repo-a/packages/index.html b/testdata/golden/repo-a/packages/index.html
index 451a6e2..dfbbcea 100644
--- a/testdata/golden/repo-a/packages/index.html
+++ b/testdata/golden/repo-a/packages/index.html
@@ -10,13 +10,13 @@
-
-
-
+
+
+
skip to content
-
+
Daniel Daum