{{template "repo/header" .}}
{{template "base/alert" .}} {{template "repo/release_tag_header" .}}

{{.TagCount}} {{ctx.Locale.Tr "repo.release.tags"}}

{{$canReadReleases := $.Permission.CanRead ctx.Consts.RepoUnitTypeReleases}}
{{template "shared/search/combo" dict "Value" .Keyword "Placeholder" (ctx.Locale.Tr "search.tag_kind") "Tooltip" (ctx.Locale.Tr "search.tag_tooltip")}}
{{if .Releases}} {{range $idx, $release := .Releases}} {{end}}

{{if $canReadReleases}} {{.TagName}} {{else}} {{.TagName}} {{end}}

{{if $.Permission.CanRead ctx.Consts.RepoUnitTypeCode}} {{if .CreatedUnix}} {{svg "octicon-clock" 16 "tw-mr-1"}}{{TimeSinceUnix .CreatedUnix ctx.Locale}} {{end}} {{svg "octicon-git-commit" 16 "tw-mr-1"}}{{ShortSha .Sha1}} {{if not $.DisableDownloadSourceArchives}} {{svg "octicon-file-zip" 16 "tw-mr-1"}}ZIP {{svg "octicon-file-zip" 16 "tw-mr-1"}}TAR.GZ {{end}} {{if (and $canReadReleases $.CanCreateRelease $release.IsTag)}} {{svg "octicon-tag" 16 "tw-mr-1"}}{{ctx.Locale.Tr "repo.release.new_release"}} {{end}} {{if (and ($.Permission.CanWrite ctx.Consts.RepoUnitTypeCode) $release.IsTag)}} {{svg "octicon-trash" 16 "tw-mr-1"}}{{ctx.Locale.Tr "repo.release.delete_tag"}} {{end}} {{if and $canReadReleases (not $release.IsTag)}} {{svg "octicon-tag" 16 "tw-mr-1"}}{{ctx.Locale.Tr "repo.release.detail"}} {{end}} {{end}}
{{else}} {{if .NumTags}}

{{ctx.Locale.Tr "no_results_found"}}

{{end}} {{end}}
{{template "base/paginate" .}}