mirror of
https://github.com/go-gitea/gitea
synced 2025-08-14 05:28:27 +00:00
Update Octicons to v10 (#12240)
* Update Octicons to v10 Besides a few renames, these icons are no longer present in v10 that we've used, so had to change: file-symlink-directory -> file-submodule internal-repo -> repo repo-force-push -> repo-push repo-template-private -> repo-template Fixes: https://github.com/go-gitea/gitea/issues/11889 Ref: https://github.com/primer/octicons/releases/tag/v10.0.0 * add custom sliders svg for removed octicon-settings * apply suggestion * fix triangles and use play on admin dashboard * add custom mirror svg * add missing build files * unify custom svgs * move to octicon-repo-clone to gitea-mirror * use octicon-x on conflicts * tweak timeline icons * tweak comment buttons * update settings icon to octicons v1 * switch to octicon-mirror and octicon-tools * replace two wiki buttons with octicons * remove whitespace in svg sources * Fix filepath basename on Windows for SVG bindata (#12241) * move octicons to devDependencies * move back to dependencies * move svgo to devDependencies again Co-authored-by: Cirno the Strongest <1447794+CirnoT@users.noreply.github.com> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
This commit is contained in:
@@ -50,8 +50,7 @@
|
||||
{{$.CsrfTokenHtml}}
|
||||
<div class="ui labeled button" tabindex="0">
|
||||
<button type="submit" class="ui compact basic button">
|
||||
<!-- TODO use star-filled once octicons v2 are in place */ -->
|
||||
{{if $.IsStaringRepo}}{{svg "octicon-star" 16}}{{$.i18n.Tr "repo.unstar"}}{{else}}{{svg "octicon-star" 16}}{{$.i18n.Tr "repo.star"}}{{end}}
|
||||
{{if $.IsStaringRepo}}{{svg "octicon-star-fill" 16}}{{$.i18n.Tr "repo.unstar"}}{{else}}{{svg "octicon-star" 16}}{{$.i18n.Tr "repo.star"}}{{end}}
|
||||
</button>
|
||||
<a class="ui basic label" href="{{.Link}}/stars">
|
||||
{{.NumStars}}
|
||||
|
@@ -1,22 +1,16 @@
|
||||
<div class="repo-header-icon">
|
||||
{{if $.IsTemplate}}
|
||||
{{if $.IsPrivate}}
|
||||
{{svg "octicon-repo-template-private" 32}}
|
||||
{{else}}
|
||||
{{svg "octicon-repo-template" 32}}
|
||||
{{end}}
|
||||
{{svg "octicon-repo-template" 32}}
|
||||
{{else}}
|
||||
{{if $.IsPrivate}}
|
||||
{{svg "octicon-lock" 32}}
|
||||
{{else if and (not $.IsMirror) (not $.IsFork) ($.Owner)}}
|
||||
{{svg "octicon-repo" 32}}
|
||||
{{if $.Owner.Visibility.IsPrivate}}
|
||||
{{svg "octicon-internal-repo" 32}}
|
||||
<img class="ui avatar image" src="{{$.Owner.RelAvatarLink}}">
|
||||
{{else}}
|
||||
{{svg "octicon-repo" 32}}
|
||||
{{end}}
|
||||
{{else if $.IsMirror}}
|
||||
{{svg "octicon-repo-clone" 32}}
|
||||
{{svg "octicon-mirror" 32}}
|
||||
{{else if $.IsFork}}
|
||||
{{svg "octicon-repo-forked" 32}}
|
||||
{{else}}
|
||||
|
@@ -279,7 +279,7 @@
|
||||
{{end}}
|
||||
|
||||
{{if gt $rejectOfficial 0}}
|
||||
<span class="rejects">{{svg "octicon-request-changes" 16}}
|
||||
<span class="rejects">{{svg "octicon-diff" 16}}
|
||||
{{$.i18n.Tr (TrN $.i18n.Lang $rejectOfficial "repo.pulls.reject_count_1" "repo.pulls.reject_count_n") $rejectOfficial}}
|
||||
</span>
|
||||
{{end}}
|
||||
@@ -291,7 +291,7 @@
|
||||
{{end}}
|
||||
|
||||
{{if and (not .PullRequest.HasMerged) (gt (len .PullRequest.ConflictedFiles) 0)}}
|
||||
<span class="conflicting">{{svg "octicon-mirror" 16}} {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
|
||||
<span class="conflicting">{{svg "octicon-x" 16}} {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
|
||||
{{end}}
|
||||
{{end}}
|
||||
</p>
|
||||
|
@@ -251,7 +251,7 @@
|
||||
{{end}}
|
||||
|
||||
{{if gt $rejectOfficial 0}}
|
||||
<span class="rejects">{{svg "octicon-request-changes" 16}}
|
||||
<span class="rejects">{{svg "octicon-diff" 16}}
|
||||
{{$.i18n.Tr (TrN $.i18n.Lang $rejectOfficial "repo.pulls.reject_count_1" "repo.pulls.reject_count_n") $rejectOfficial}}
|
||||
</span>
|
||||
{{end}}
|
||||
@@ -263,7 +263,7 @@
|
||||
{{end}}
|
||||
|
||||
{{if and (not .PullRequest.HasMerged) (gt (len .PullRequest.ConflictedFiles) 0)}}
|
||||
<span class="conflicting">{{svg "octicon-mirror" 16}} {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
|
||||
<span class="conflicting">{{svg "octicon-x" 16}} {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
|
||||
{{end}}
|
||||
{{end}}
|
||||
</p>
|
||||
|
@@ -1,7 +1,6 @@
|
||||
{{if .ctx.IsSigned}}
|
||||
<div class="item action ui pointing top right select-reaction dropdown" data-action-url="{{ .ActionURL }}">
|
||||
<a class="add-reaction">
|
||||
{{svg "octicon-plus-small" 16}}
|
||||
{{svg "octicon-smiley" 16}}
|
||||
</a>
|
||||
<div class="menu">
|
||||
|
@@ -70,7 +70,7 @@
|
||||
</div>
|
||||
{{else if eq .Type 1}}
|
||||
<div class="timeline-item event" id="{{.HashTag}}">
|
||||
<span class="badge">{{svg "octicon-primitive-dot" 16}}</span>
|
||||
<span class="badge">{{svg "octicon-dot-fill" 16}}</span>
|
||||
<a class="ui avatar image" href="{{.Poster.HomeLink}}">
|
||||
<img src="{{.Poster.RelAvatarLink}}">
|
||||
</a>
|
||||
@@ -319,7 +319,7 @@
|
||||
</div>
|
||||
{{else if eq .Type 19}}
|
||||
<div class="timeline-item event" id="{{.HashTag}}">
|
||||
<span class="badge">{{svg "octicon-dependent" 16}}</span>
|
||||
<span class="badge">{{svg "octicon-package-dependents" 16}}</span>
|
||||
<a class="ui avatar image" href="{{.Poster.HomeLink}}">
|
||||
<img src="{{.Poster.RelAvatarLink}}">
|
||||
</a>
|
||||
@@ -344,7 +344,7 @@
|
||||
</div>
|
||||
{{else if eq .Type 20}}
|
||||
<div class="timeline-item event" id="{{.HashTag}}">
|
||||
<span class="badge">{{svg "octicon-dependent" 16}}</span>
|
||||
<span class="badge">{{svg "octicon-package-dependents" 16}}</span>
|
||||
<a class="ui avatar image" href="{{.Poster.HomeLink}}">
|
||||
<img src="{{.Poster.RelAvatarLink}}">
|
||||
</a>
|
||||
@@ -603,7 +603,7 @@
|
||||
</div>
|
||||
{{else if and (eq .Type 29) (or (gt .CommitsNum 0) .IsForcePush)}}
|
||||
<div class="timeline-item event" id="{{.HashTag}}">
|
||||
<span class="badge">{{svg "octicon-repo-force-push" 16}}</span>
|
||||
<span class="badge">{{svg "octicon-repo-push" 16}}</span>
|
||||
<span class="text grey">
|
||||
<a class="author" href="{{.Poster.HomeLink}}">{{.Poster.GetDisplayName}}</a>
|
||||
{{ if .IsForcePush }}
|
||||
|
@@ -1,7 +1,7 @@
|
||||
{{if .ctx.IsSigned}}
|
||||
<div class="item action ui pointing top right custom dropdown context-dropdown">
|
||||
<a class="context-menu">
|
||||
<i class="fa fa-ellipsis-h"></i>
|
||||
{{svg "octicon-kebab-horizontal" 16}}
|
||||
</a>
|
||||
<div class="menu">
|
||||
{{if .diff}}
|
||||
|
@@ -173,7 +173,7 @@
|
||||
{{if and (or $.IsRepoAdmin (not $notAllOverridableChecksOk)) (or (not .RequireSigned) .WillSign)}}
|
||||
{{if $notAllOverridableChecksOk}}
|
||||
<div class="item text yellow">
|
||||
<i class="icon icon-octicon">{{svg "octicon-primitive-dot" 16}}</i>
|
||||
<i class="icon icon-octicon">{{svg "octicon-dot-fill" 16}}</i>
|
||||
{{$.i18n.Tr "repo.pulls.required_status_check_administrator"}}
|
||||
</div>
|
||||
{{else}}
|
||||
|
@@ -14,7 +14,7 @@
|
||||
</div>
|
||||
{{range .Hooks}}
|
||||
<div class="item">
|
||||
<span class="text {{if .IsActive}}green{{else}}grey{{end}}">{{svg "octicon-primitive-dot" 16}}</span>
|
||||
<span class="text {{if .IsActive}}green{{else}}grey{{end}}">{{svg "octicon-dot-fill" 16}}</span>
|
||||
<span>{{.Name}}</span>
|
||||
<a class="text blue ui right" href="{{$.RepoLink}}/settings/hooks/git/{{.Name}}"><i class="fa fa-pencil"></i></a>
|
||||
</div>
|
||||
|
@@ -65,7 +65,7 @@
|
||||
<div class="menu">
|
||||
{{range .Teams}}
|
||||
<div class="item" data-value="{{.ID}}">
|
||||
{{svg "octicon-jersey" 16}}
|
||||
{{svg "octicon-people" 16}}
|
||||
{{.Name}}
|
||||
</div>
|
||||
{{end}}
|
||||
@@ -115,7 +115,7 @@
|
||||
<div class="menu">
|
||||
{{range .Teams}}
|
||||
<div class="item" data-value="{{.ID}}">
|
||||
{{svg "octicon-jersey" 16}}
|
||||
{{svg "octicon-people" 16}}
|
||||
{{.Name}}
|
||||
</div>
|
||||
{{end}}
|
||||
@@ -195,7 +195,7 @@
|
||||
<div class="menu">
|
||||
{{range .Teams}}
|
||||
<div class="item" data-value="{{.ID}}">
|
||||
{{svg "octicon-jersey" 16}}
|
||||
{{svg "octicon-people" 16}}
|
||||
{{.Name}}
|
||||
</div>
|
||||
{{end}}
|
||||
|
@@ -48,7 +48,7 @@
|
||||
{{else if eq .LastStatus 2}}
|
||||
<span class="text red">{{svg "octicon-alert" 16}}</span>
|
||||
{{else}}
|
||||
<span class="text grey">{{svg "octicon-primitive-dot" 16}}</span>
|
||||
<span class="text grey">{{svg "octicon-dot-fill" 16}}</span>
|
||||
{{end}}
|
||||
<a class="dont-break-out" href="{{$.BaseLink}}/{{.ID}}">{{.URL}}</a>
|
||||
<div class="ui right">
|
||||
|
@@ -29,7 +29,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui header eight wide column">
|
||||
<a class="file-revisions-btn ui basic button" title="{{.i18n.Tr "repo.wiki.back_to_wiki"}}" href="{{.RepoLink}}/wiki/{{.PageURL}}" ><span>{{.revision}}</span> <i class="fa fa-fw fa-file-text-o"></i></a>
|
||||
<a class="file-revisions-btn ui basic button" title="{{.i18n.Tr "repo.wiki.back_to_wiki"}}" href="{{.RepoLink}}/wiki/{{.PageURL}}" ><span>{{.revision}}</span> {{svg "octicon-home" 16}}</a>
|
||||
{{$title}}
|
||||
<div class="ui sub header wrap">
|
||||
{{$timeSince := TimeSince .Author.When $.Lang}}
|
||||
|
@@ -56,7 +56,7 @@
|
||||
<div class="ui dividing header">
|
||||
<div class="ui stackable grid">
|
||||
<div class="eight wide column">
|
||||
<a class="file-revisions-btn ui basic button" title="{{.i18n.Tr "repo.wiki.file_revision"}}" href="{{.RepoLink}}/wiki/{{.PageURL}}/_revision" ><span>{{.CommitCount}}</span> <i class="fa fa-fw fa-history"></i></a>
|
||||
<a class="file-revisions-btn ui basic button" title="{{.i18n.Tr "repo.wiki.file_revision"}}" href="{{.RepoLink}}/wiki/{{.PageURL}}/_revision" ><span>{{.CommitCount}}</span> {{svg "octicon-history" 16}}</a>
|
||||
{{$title}}
|
||||
<div class="ui sub header">
|
||||
{{$timeSince := TimeSince .Author.When $.Lang}}
|
||||
|
Reference in New Issue
Block a user