mirror of
1
Fork 0

Merge pull request '[BUG] Fix tooltip for 1000+ stars/forks' (#3147) from gusted/forgejo-tooltip-1000 into forgejo

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/3147
Reviewed-by: Otto <otto@codeberg.org>
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
This commit is contained in:
Gusted 2024-04-10 22:34:03 +00:00
commit 97fe5e6341
1 changed files with 4 additions and 4 deletions

View File

@ -38,15 +38,15 @@
</a>
{{end}}
{{if not $.DisableStars}}
<a class="flex-text-inline" href="{{.Link}}/stars" aria-label="{{ctx.Locale.TrN .NumStars "explore.stars_one" "explore.stars_few" .NumStars}}">
<a class="flex-text-inline" href="{{.Link}}/stars" aria-label="{{ctx.Locale.TrN .NumStars "explore.stars_one" "explore.stars_few" .NumStars}}" {{if ge .NumStars 1000}}data-tooltip-content="{{.NumStars}}"{{end}}>
{{svg "octicon-star" 16}}
{{if ge .NumStars 1000}}data-tooltip-content="{{.NumStars}}"{{end}}{{CountFmt .NumStars}}
{{CountFmt .NumStars}}
</a>
{{end}}
{{if not $.DisableForks}}
<a class="flex-text-inline" href="{{.Link}}/forks" aria-label="{{ctx.Locale.TrN .NumForks "explore.forks_one" "explore.forks_few" .NumForks}}">
<a class="flex-text-inline" href="{{.Link}}/forks" aria-label="{{ctx.Locale.TrN .NumForks "explore.forks_one" "explore.forks_few" .NumForks}}" {{if ge .NumForks 1000}}data-tooltip-content="{{.NumForks}}"{{end}}>
{{svg "octicon-git-branch" 16}}
{{if ge .NumForks 1000}}data-tooltip-content="{{.NumForks}}"{{end}}{{CountFmt .NumForks}}
{{CountFmt .NumForks}}
</a>
{{end}}
</div>