mirror of https://github.com/go-gitea/gitea.git
RSS icon fixes (#24476)
Fix regression from https://github.com/go-gitea/gitea/pull/24471 where CSS rules for `.icon.grey` were removed which were in use by the RSS icons. Gave them their own class instead, removed a wrapper and also fixed vertical alignment on them. Additionally, did a few related fixes on the org header for alignment. Fixes: https://github.com/go-gitea/gitea/issues/24584 <img width="196" alt="Screenshot 2023-05-01 at 22 39 40" src="https://user-images.githubusercontent.com/115237/235528228-959e2385-c1d2-4d5c-baec-e3784d459653.png"> <img width="216" alt="Screenshot 2023-05-01 at 22 44 20" src="https://user-images.githubusercontent.com/115237/235528231-95cbff86-5672-48eb-b214-8bdcefa1612c.png"> <img width="120" alt="Screenshot 2023-05-01 at 22 56 36" src="https://user-images.githubusercontent.com/115237/235529844-b94ab554-3259-4d0c-b040-82aed7d1a111.png"> <img width="372" alt="Screenshot 2023-05-01 at 22 54 25" src="https://user-images.githubusercontent.com/115237/235529744-1a9c201b-5692-4122-9765-2f201a322a9e.png"> <img width="477" alt="Screenshot 2023-05-01 at 22 55 28" src="https://user-images.githubusercontent.com/115237/235529748-62188554-9927-42ef-bc94-7052bce266e2.png"> --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>pull/24641/head^2
parent
f7ede92f82
commit
67db6b6976
@ -0,0 +1,27 @@
|
||||
{{$canReadReleases := $.Permission.CanRead $.UnitTypeReleases}}
|
||||
{{$canReadCode := $.Permission.CanRead $.UnitTypeCode}}
|
||||
|
||||
{{if $canReadReleases}}
|
||||
<div class="gt-df">
|
||||
<div class="gt-f1">
|
||||
<h2 class="ui compact small menu header small-menu-items">
|
||||
<a class="{{if .PageIsReleaseList}}active {{end}}item" href="{{.RepoLink}}/releases">{{.locale.Tr "repo.release.releases"}}</a>
|
||||
{{if $canReadCode}}
|
||||
<a class="{{if .PageIsTagList}}active {{end}}item" href="{{.RepoLink}}/tags">{{.locale.Tr "repo.release.tags"}}</a>
|
||||
{{end}}
|
||||
</h2>
|
||||
{{if .EnableFeed}}
|
||||
<a class="muted gt-mx-3" href="{{.RepoLink}}/{{if .PageIsTagList}}tags{{else}}releases{{end}}.rss" data-tooltip-content="{{.locale.Tr "rss_feed"}}">{{svg "octicon-rss" 18}}</a>
|
||||
{{end}}
|
||||
</div>
|
||||
{{if and (not .PageIsTagList) .CanCreateRelease}}
|
||||
<a class="ui right small green button" href="{{$.RepoLink}}/releases/new">
|
||||
{{.locale.Tr "repo.release.new_release"}}
|
||||
</a>
|
||||
{{end}}
|
||||
</div>
|
||||
<div class="ui divider"></div>
|
||||
{{else if $canReadCode}}
|
||||
{{/* if the "repo.releases" unit is disabled, only show the "commits / branches / tags" sub menu */}}
|
||||
{{template "repo/sub_menu" .}}
|
||||
{{end}}
|
@ -1,17 +0,0 @@
|
||||
{{$canReadReleases := $.Permission.CanRead $.UnitTypeReleases}}
|
||||
{{$canReadCode := $.Permission.CanRead $.UnitTypeCode}}
|
||||
|
||||
{{if $canReadReleases}}
|
||||
<h2 class="ui compact small menu header small-menu-items">
|
||||
<a class="{{if .PageIsReleaseList}}active {{end}}item" href="{{.RepoLink}}/releases">{{.locale.Tr "repo.release.releases"}}</a>
|
||||
{{if $canReadCode}}
|
||||
<a class="{{if .PageIsTagList}}active {{end}}item" href="{{.RepoLink}}/tags">{{.locale.Tr "repo.release.tags"}}</a>
|
||||
{{end}}
|
||||
</h2>
|
||||
|
||||
{{if .EnableFeed}}
|
||||
<a href="{{.RepoLink}}/{{if .PageIsTagList}}tags{{else}}releases{{end}}.rss"><i class="ui grey icon gt-ml-3" data-tooltip-content="{{.locale.Tr "rss_feed"}}">{{svg "octicon-rss" 18}}</i></a>
|
||||
{{end}}
|
||||
{{else if $canReadCode}}
|
||||
{{template "repo/sub_menu" .}}
|
||||
{{end}}
|
Loading…
Reference in New Issue