{{template "repo/header" .}}

{{DateTime "long" .DateFrom}} - {{DateTime "long" .DateUntil}}

{{if (or (.Permission.CanRead $.UnitTypeIssues) (.Permission.CanRead $.UnitTypePullRequests))}}

{{.locale.Tr "repo.activity.overview"}}

{{if .Permission.CanRead $.UnitTypePullRequests}}
{{if gt .Activity.ActivePRCount 0}}
{{else}}
{{end}} {{.locale.TrN .Activity.ActivePRCount "repo.activity.active_prs_count_1" "repo.activity.active_prs_count_n" .Activity.ActivePRCount | Safe}}
{{end}} {{if .Permission.CanRead $.UnitTypeIssues}}
{{if gt .Activity.ActiveIssueCount 0}}
{{else}}
{{end}} {{.locale.TrN .Activity.ActiveIssueCount "repo.activity.active_issues_count_1" "repo.activity.active_issues_count_n" .Activity.ActiveIssueCount | Safe}}
{{end}}
{{end}} {{if .Permission.CanRead $.UnitTypeCode}} {{if eq .Activity.Code.CommitCountInAllBranches 0}}

{{.locale.Tr "repo.activity.no_git_activity"}}

{{end}} {{if gt .Activity.Code.CommitCountInAllBranches 0}}
{{.locale.Tr "repo.activity.git_stats_exclude_merges"}} {{.locale.TrN .Activity.Code.AuthorCount "repo.activity.git_stats_author_1" "repo.activity.git_stats_author_n" .Activity.Code.AuthorCount}} {{.locale.TrN .Activity.Code.AuthorCount "repo.activity.git_stats_pushed_1" "repo.activity.git_stats_pushed_n"}} {{.locale.TrN .Activity.Code.CommitCount "repo.activity.git_stats_commit_1" "repo.activity.git_stats_commit_n" .Activity.Code.CommitCount}} {{.locale.Tr "repo.activity.git_stats_push_to_branch" .Repository.DefaultBranch}} {{.locale.TrN .Activity.Code.CommitCountInAllBranches "repo.activity.git_stats_commit_1" "repo.activity.git_stats_commit_n" .Activity.Code.CommitCountInAllBranches}} {{.locale.Tr "repo.activity.git_stats_push_to_all_branches"}} {{.locale.Tr "repo.activity.git_stats_on_default_branch" .Repository.DefaultBranch}} {{.locale.TrN .Activity.Code.ChangedFiles "repo.activity.git_stats_file_1" "repo.activity.git_stats_file_n" .Activity.Code.ChangedFiles}} {{.locale.TrN .Activity.Code.ChangedFiles "repo.activity.git_stats_files_changed_1" "repo.activity.git_stats_files_changed_n"}} {{.locale.Tr "repo.activity.git_stats_additions"}} {{.locale.TrN .Activity.Code.Additions "repo.activity.git_stats_addition_1" "repo.activity.git_stats_addition_n" .Activity.Code.Additions}} {{.locale.Tr "repo.activity.git_stats_and_deletions"}} {{.locale.TrN .Activity.Code.Deletions "repo.activity.git_stats_deletion_1" "repo.activity.git_stats_deletion_n" .Activity.Code.Deletions}}.
{{end}} {{end}} {{if gt .Activity.PublishedReleaseCount 0}}

{{svg "octicon-tag"}} {{.locale.Tr "repo.activity.title.releases_published_by" (.locale.TrN .Activity.PublishedReleaseCount "repo.activity.title.releases_1" "repo.activity.title.releases_n" .Activity.PublishedReleaseCount) (.locale.TrN .Activity.PublishedReleaseAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n" .Activity.PublishedReleaseAuthorCount) }}

{{range .Activity.PublishedReleases}}

{{$.locale.Tr "repo.activity.published_release_label"}} {{.TagName}} {{if not .IsTag}} {{.Title | RenderEmoji $.Context}} {{end}} {{TimeSinceUnix .CreatedUnix $.locale}}

{{end}}
{{end}} {{if gt .Activity.MergedPRCount 0}}

{{svg "octicon-git-pull-request"}} {{.locale.Tr "repo.activity.title.prs_merged_by" (.locale.TrN .Activity.MergedPRCount "repo.activity.title.prs_1" "repo.activity.title.prs_n" .Activity.MergedPRCount) (.locale.TrN .Activity.MergedPRAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n" .Activity.MergedPRAuthorCount) }}

{{range .Activity.MergedPRs}}

{{$.locale.Tr "repo.activity.merged_prs_label"}} #{{.Index}} {{.Issue.Title | RenderEmoji $.Context}} {{TimeSinceUnix .MergedUnix $.locale}}

{{end}}
{{end}} {{if gt .Activity.OpenedPRCount 0}}

{{svg "octicon-git-branch"}} {{.locale.Tr "repo.activity.title.prs_opened_by" (.locale.TrN .Activity.OpenedPRCount "repo.activity.title.prs_1" "repo.activity.title.prs_n" .Activity.OpenedPRCount) (.locale.TrN .Activity.OpenedPRAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n" .Activity.OpenedPRAuthorCount) }}

{{range .Activity.OpenedPRs}}

{{$.locale.Tr "repo.activity.opened_prs_label"}} #{{.Index}} {{.Issue.Title | RenderEmoji $.Context}} {{TimeSinceUnix .Issue.CreatedUnix $.locale}}

{{end}}
{{end}} {{if gt .Activity.ClosedIssueCount 0}}

{{svg "octicon-issue-closed"}} {{.locale.Tr "repo.activity.title.issues_closed_from" (.locale.TrN .Activity.ClosedIssueCount "repo.activity.title.issues_1" "repo.activity.title.issues_n" .Activity.ClosedIssueCount) (.locale.TrN .Activity.ClosedIssueAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n" .Activity.ClosedIssueAuthorCount) }}

{{range .Activity.ClosedIssues}}

{{$.locale.Tr "repo.activity.closed_issue_label"}} #{{.Index}} {{.Title | RenderEmoji $.Context}} {{TimeSinceUnix .ClosedUnix $.locale}}

{{end}}
{{end}} {{if gt .Activity.OpenedIssueCount 0}}

{{svg "octicon-issue-opened"}} {{.locale.Tr "repo.activity.title.issues_created_by" (.locale.TrN .Activity.OpenedIssueCount "repo.activity.title.issues_1" "repo.activity.title.issues_n" .Activity.OpenedIssueCount) (.locale.TrN .Activity.OpenedIssueAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n" .Activity.OpenedIssueAuthorCount) }}

{{range .Activity.OpenedIssues}}

{{$.locale.Tr "repo.activity.new_issue_label"}} #{{.Index}} {{.Title | RenderEmoji $.Context}} {{TimeSinceUnix .CreatedUnix $.locale}}

{{end}}
{{end}} {{if gt .Activity.UnresolvedIssueCount 0}}

{{svg "octicon-comment-discussion"}} {{.locale.TrN .Activity.UnresolvedIssueCount "repo.activity.title.unresolved_conv_1" "repo.activity.title.unresolved_conv_n" .Activity.UnresolvedIssueCount}}

{{.locale.Tr "repo.activity.unresolved_conv_desc"}}
{{range .Activity.UnresolvedIssues}}

{{$.locale.Tr "repo.activity.unresolved_conv_label"}} #{{.Index}} {{if .IsPull}} {{.Title | RenderEmoji $.Context}} {{else}} {{.Title | RenderEmoji $.Context}} {{end}} {{TimeSinceUnix .UpdatedUnix $.locale}}

{{end}}
{{end}}