Show hint to link package to repo when viewing empty repo package list (#20504)

* show hint to link package to repo

on empty repo package listing

* reword
This commit is contained in:
Norwin 2022-07-27 13:58:21 +02:00 committed by GitHub
parent 158f2746b8
commit 2ae1675092
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 0 deletions

View file

@ -47,6 +47,10 @@
<div class="empty center">
{{svg "octicon-package" 32}}
<h2>{{.locale.Tr "packages.empty"}}</h2>
{{if and .Repository .CanWritePackages}}
{{$packagesUrl := URLJoin .Owner.HTMLURL "-" "packages" }}
<p>{{.locale.Tr "packages.empty.repo" $packagesUrl | Safe}}</p>
{{end}}
<p>{{.locale.Tr "packages.empty.documentation" | Safe}}</p>
</div>
{{else}}