From b8126d7f38501a4d762fe79c15b10cf21ebd6b89 Mon Sep 17 00:00:00 2001 From: nachtjasmin Date: Wed, 26 Nov 2025 11:21:20 +0100 Subject: [PATCH] fix(ui): use octicon-repo-forked in repo list (#10227) Closes: #10153 ![Screenshot of the fixed icon](/attachments/38559840-9cd0-4e37-9a25-106d21db8a42) Co-authored-by: 0ko <0ko@noreply.codeberg.org> Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/10227 Reviewed-by: 0ko <0ko@noreply.codeberg.org> Co-authored-by: nachtjasmin Co-committed-by: nachtjasmin --- templates/explore/repo_list.tmpl | 2 +- tests/integration/explore_repos_test.go | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/templates/explore/repo_list.tmpl b/templates/explore/repo_list.tmpl index d7e12930ca..5aca760548 100644 --- a/templates/explore/repo_list.tmpl +++ b/templates/explore/repo_list.tmpl @@ -55,7 +55,7 @@ data-tooltip-content="{{ctx.Locale.TrPluralString .NumForks "fork.n_forks" (ctx.Locale.PrettyNumber .NumForks)}}" {{end}} > - {{svg "octicon-git-branch" 16}} + {{svg "octicon-repo-forked" 16}} {{CountFmt .NumForks}} {{end}} diff --git a/tests/integration/explore_repos_test.go b/tests/integration/explore_repos_test.go index 1ed07248f6..cbf2214183 100644 --- a/tests/integration/explore_repos_test.go +++ b/tests/integration/explore_repos_test.go @@ -24,6 +24,10 @@ func testExploreStarForkCounters(t *testing.T, repoQuery, expectedStars, expecte assert.Equal(t, expectedStars, starsAriaLabel) assert.Equal(t, expectedForks, forksAriaLabel) + + // Verify that correct icons are used + assert.True(t, repoListEntry.Find("a[href$='/stars'] > svg").HasClass("octicon-star")) + assert.True(t, repoListEntry.Find("a[href$='/forks'] > svg").HasClass("octicon-repo-forked")) } func TestExploreRepos(t *testing.T) {