diff --git a/release-notes/8.0.0/4139.md b/release-notes/8.0.0/4139.md new file mode 100644 index 0000000000..116a36d881 --- /dev/null +++ b/release-notes/8.0.0/4139.md @@ -0,0 +1,5 @@ +Reorder repo tabs for better UX: +- Actions is now the last tab +- Packages are located after Releases +- This puts Projects after Pull requests +(tab positions may depend on which units are enabled in the repo) diff --git a/templates/repo/header.tmpl b/templates/repo/header.tmpl index 82e7679cd2..d8c53d08be 100644 --- a/templates/repo/header.tmpl +++ b/templates/repo/header.tmpl @@ -85,9 +85,9 @@ {{if not (or .Repository.IsBeingCreated .Repository.IsBroken)}}
{{if .Permission.CanRead $.UnitTypeCode}} - - {{svg "octicon-code"}} {{ctx.Locale.Tr "repo.code"}} - + + {{svg "octicon-code"}} {{ctx.Locale.Tr "repo.code"}} + {{end}} {{if .Permission.CanRead $.UnitTypeIssues}} @@ -114,21 +114,6 @@ {{end}} - {{if and .EnableActions (not .UnitActionsGlobalDisabled) (.Permission.CanRead $.UnitTypeActions)}} - - {{svg "octicon-play"}} {{ctx.Locale.Tr "actions.actions"}} - {{if .Repository.NumOpenActionRuns}} - {{CountFmt .Repository.NumOpenActionRuns}} - {{end}} - - {{end}} - - {{if .Permission.CanRead $.UnitTypePackages}} - - {{svg "octicon-package"}} {{ctx.Locale.Tr "packages.title"}} - - {{end}} - {{if and (not .UnitProjectsGlobalDisabled) (.Permission.CanRead $.UnitTypeProjects)}} {{svg "octicon-project"}} {{ctx.Locale.Tr "repo.project"}} @@ -139,12 +124,18 @@ {{end}} {{if and (.Permission.CanRead $.UnitTypeReleases) (not .IsEmptyRepo)}} - - {{svg "octicon-tag"}} {{ctx.Locale.Tr "repo.releases"}} - {{if .NumReleases}} - {{CountFmt .NumReleases}} - {{end}} - + + {{svg "octicon-tag"}} {{ctx.Locale.Tr "repo.releases"}} + {{if .NumReleases}} + {{CountFmt .NumReleases}} + {{end}} + + {{end}} + + {{if .Permission.CanRead $.UnitTypePackages}} + + {{svg "octicon-package"}} {{ctx.Locale.Tr "packages.title"}} + {{end}} {{if .Permission.CanRead $.UnitTypeWiki}} @@ -165,6 +156,15 @@ {{end}} + {{if and .EnableActions (not .UnitActionsGlobalDisabled) (.Permission.CanRead $.UnitTypeActions)}} + + {{svg "octicon-play"}} {{ctx.Locale.Tr "actions.actions"}} + {{if .Repository.NumOpenActionRuns}} + {{CountFmt .Repository.NumOpenActionRuns}} + {{end}} + + {{end}} + {{template "custom/extra_tabs" .}} {{if and RepoFlagsEnabled .SignedUser.IsAdmin}}