aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/activity.tmpl
diff options
context:
space:
mode:
authorJohn Olheiser <42128690+jolheiser@users.noreply.github.com>2020-02-11 11:02:41 -0600
committerGitHub <noreply@github.com>2020-02-11 12:02:41 -0500
commit86fdba177ad82f3dcdfc237631fef4588042b9d6 (patch)
tree9ee1c1f97a158436e36828d1072fa84fac222317 /templates/repo/activity.tmpl
parente704f7fae7b212902ddd2859d8f88350630b4086 (diff)
downloadgitea-86fdba177ad82f3dcdfc237631fef4588042b9d6.tar.gz
gitea-86fdba177ad82f3dcdfc237631fef4588042b9d6.zip
Add Octicon SVG spritemap (#10107)
* Add octicon SVG sprite Signed-off-by: jolheiser <john.olheiser@gmail.com> * Static prefix Signed-off-by: jolheiser <john.olheiser@gmail.com> * SVG for all repo icons Signed-off-by: jolheiser <john.olheiser@gmail.com> * make vendor Signed-off-by: jolheiser <john.olheiser@gmail.com> * Swap out octicons Signed-off-by: jolheiser <john.olheiser@gmail.com> * Move octicons to top of less imports Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix JS Signed-off-by: jolheiser <john.olheiser@gmail.com> * Definitely not a search/replace Signed-off-by: jolheiser <john.olheiser@gmail.com> * Missed regex Signed-off-by: jolheiser <john.olheiser@gmail.com> * Move to more generic calls and webpack Signed-off-by: jolheiser <john.olheiser@gmail.com> * make svg -> make webpack Signed-off-by: jolheiser <john.olheiser@gmail.com> * Remove svg-sprite Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update tests Signed-off-by: jolheiser <john.olheiser@gmail.com> * Missed a test Signed-off-by: jolheiser <john.olheiser@gmail.com> * Remove svg from makefile Signed-off-by: jolheiser <john.olheiser@gmail.com> * Suggestions Signed-off-by: jolheiser <john.olheiser@gmail.com> * Attempt to fix test Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update tests Signed-off-by: jolheiser <john.olheiser@gmail.com> * Revert timetracking test Signed-off-by: jolheiser <john.olheiser@gmail.com> * Swap .octicon for .svg in less Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add aria-hidden Signed-off-by: jolheiser <john.olheiser@gmail.com> * Replace mega-octicon Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix webpack globbing on Windows Signed-off-by: jolheiser <john.olheiser@gmail.com> * Revert Co-Authored-By: silverwind <me@silverwind.io> * Fix octions from upstream Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix Vue and missed JS function Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add JS helper and PWA Signed-off-by: jolheiser <john.olheiser@gmail.com> * Preload SVG Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: techknowlogick <matti@mdranta.net>
Diffstat (limited to 'templates/repo/activity.tmpl')
-rw-r--r--templates/repo/activity.tmpl20
1 files changed, 10 insertions, 10 deletions
diff --git a/templates/repo/activity.tmpl b/templates/repo/activity.tmpl
index 8c3167bca7..c11a841b2d 100644
--- a/templates/repo/activity.tmpl
+++ b/templates/repo/activity.tmpl
@@ -63,21 +63,21 @@
<div class="ui attached segment horizontal segments">
{{if .Permission.CanRead $.UnitTypePullRequests}}
<a href="#merged-pull-requests" class="ui attached segment text center">
- <i class="text purple octicon octicon-git-pull-request"></i> <strong>{{.Activity.MergedPRCount}}</strong><br>
+ <span class="text purple">{{svg "octicon-git-pull-request" 16}}</span> <strong>{{.Activity.MergedPRCount}}</strong><br>
{{.i18n.Tr (TrN .i18n.Lang .Activity.MergedPRCount "repo.activity.merged_prs_count_1" "repo.activity.merged_prs_count_n") }}
</a>
<a href="#proposed-pull-requests" class="ui attached segment text center">
- <i class="text green octicon octicon-git-branch"></i> <strong>{{.Activity.OpenedPRCount}}</strong><br>
+ <span class="text green">{{svg "octicon-git-branch" 16}}</span> <strong>{{.Activity.OpenedPRCount}}</strong><br>
{{.i18n.Tr (TrN .i18n.Lang .Activity.OpenedPRCount "repo.activity.opened_prs_count_1" "repo.activity.opened_prs_count_n") }}
</a>
{{end}}
{{if .Permission.CanRead $.UnitTypeIssues}}
<a href="#closed-issues" class="ui attached segment text center">
- <i class="text red octicon octicon-issue-closed"></i> <strong>{{.Activity.ClosedIssueCount}}</strong><br>
+ <span class="text red">{{svg "octicon-issue-closed" 16}}</span> <strong>{{.Activity.ClosedIssueCount}}</strong><br>
{{.i18n.Tr (TrN .i18n.Lang .Activity.ClosedIssueCount "repo.activity.closed_issues_count_1" "repo.activity.closed_issues_count_n") }}
</a>
<a href="#new-issues" class="ui attached segment text center">
- <i class="text green octicon octicon-issue-opened"></i> <strong>{{.Activity.OpenedIssueCount}}</strong><br>
+ <span class="text green">{{svg "octicon-issue-opened" 16}}</span> <strong>{{.Activity.OpenedIssueCount}}</strong><br>
{{.i18n.Tr (TrN .i18n.Lang .Activity.OpenedIssueCount "repo.activity.new_issues_count_1" "repo.activity.new_issues_count_n") }}
</a>
{{end}}
@@ -120,7 +120,7 @@
{{if gt .Activity.PublishedReleaseCount 0}}
<h4 class="ui horizontal divider header" id="published-releases">
- <i class="text octicon octicon-tag"></i>
+ <span class="text">{{svg "octicon-tag" 16}}</span>
{{.i18n.Tr "repo.activity.title.releases_published_by" (.i18n.Tr (TrN .i18n.Lang .Activity.PublishedReleaseCount "repo.activity.title.releases_1" "repo.activity.title.releases_n") .Activity.PublishedReleaseCount) (.i18n.Tr (TrN .i18n.Lang .Activity.PublishedReleaseAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n") .Activity.PublishedReleaseAuthorCount) }}
</h4>
<div class="list">
@@ -139,7 +139,7 @@
{{if gt .Activity.MergedPRCount 0}}
<h4 class="ui horizontal divider header" id="merged-pull-requests">
- <i class="text octicon octicon-git-pull-request"></i>
+ <span class="text">{{svg "octicon-git-pull-request" 16}}</span>
{{.i18n.Tr "repo.activity.title.prs_merged_by" (.i18n.Tr (TrN .i18n.Lang .Activity.MergedPRCount "repo.activity.title.prs_1" "repo.activity.title.prs_n") .Activity.MergedPRCount) (.i18n.Tr (TrN .i18n.Lang .Activity.MergedPRAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n") .Activity.MergedPRAuthorCount) }}
</h4>
<div class="list">
@@ -155,7 +155,7 @@
{{if gt .Activity.OpenedPRCount 0}}
<h4 class="ui horizontal divider header" id="proposed-pull-requests">
- <i class="text octicon octicon-git-branch"></i>
+ <span class="text">{{svg "octicon-git-branch" 16}}</span>
{{.i18n.Tr "repo.activity.title.prs_opened_by" (.i18n.Tr (TrN .i18n.Lang .Activity.OpenedPRCount "repo.activity.title.prs_1" "repo.activity.title.prs_n") .Activity.OpenedPRCount) (.i18n.Tr (TrN .i18n.Lang .Activity.OpenedPRAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n") .Activity.OpenedPRAuthorCount) }}
</h4>
<div class="list">
@@ -171,7 +171,7 @@
{{if gt .Activity.ClosedIssueCount 0}}
<h4 class="ui horizontal divider header" id="closed-issues">
- <i class="text octicon octicon-issue-closed"></i>
+ <span class="text">{{svg "octicon-issue-closed" 16}}</span>
{{.i18n.Tr "repo.activity.title.issues_closed_by" (.i18n.Tr (TrN .i18n.Lang .Activity.ClosedIssueCount "repo.activity.title.issues_1" "repo.activity.title.issues_n") .Activity.ClosedIssueCount) (.i18n.Tr (TrN .i18n.Lang .Activity.ClosedIssueAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n") .Activity.ClosedIssueAuthorCount) }}
</h4>
<div class="list">
@@ -187,7 +187,7 @@
{{if gt .Activity.OpenedIssueCount 0}}
<h4 class="ui horizontal divider header" id="new-issues">
- <i class="text octicon octicon-issue-opened"></i>
+ <span class="text">{{svg "octicon-issue-opened" 16}}</span>
{{.i18n.Tr "repo.activity.title.issues_created_by" (.i18n.Tr (TrN .i18n.Lang .Activity.OpenedIssueCount "repo.activity.title.issues_1" "repo.activity.title.issues_n") .Activity.OpenedIssueCount) (.i18n.Tr (TrN .i18n.Lang .Activity.OpenedIssueAuthorCount "repo.activity.title.user_1" "repo.activity.title.user_n") .Activity.OpenedIssueAuthorCount) }}
</h4>
<div class="list">
@@ -203,7 +203,7 @@
{{if gt .Activity.UnresolvedIssueCount 0}}
<h4 class="ui horizontal divider header" id="unresolved-conversations">
- <i class="text octicon octicon-comment-discussion"></i>
+ <span class="text">{{svg "octicon-comment-discussion" 16}}</span>
{{.i18n.Tr (TrN .i18n.Lang .Activity.UnresolvedIssueCount "repo.activity.title.unresolved_conv_1" "repo.activity.title.unresolved_conv_n") .Activity.UnresolvedIssueCount }}
</h4>
<div class="text center desc">