Add RSS Feed buttons to Repo, User and Org pages (#19370)

This commit is contained in:
ktprograms 2022-04-25 04:03:39 +08:00 committed by GitHub
parent ebb23967dc
commit ef164d33c2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 9 additions and 5 deletions

View File

@ -105,6 +105,8 @@ error404 = The page you are trying to reach either <strong>does not exist</stron
never = Never never = Never
rss_feed = RSS Feed
[error] [error]
occurred = An error occurred occurred = An error occurred
report_message = If you are sure this is a Gitea bug, please search for issues on <a href="https://github.com/go-gitea/gitea/issues" target="_blank">GitHub</a> or open a new issue if necessary. report_message = If you are sure this is a Gitea bug, please search for issues on <a href="https://github.com/go-gitea/gitea/issues" target="_blank">GitHub</a> or open a new issue if necessary.

View File

@ -5,6 +5,7 @@
<div id="org-info"> <div id="org-info">
<div class="ui header"> <div class="ui header">
{{.Org.DisplayName}} {{.Org.DisplayName}}
<a href="{{.Org.HomeLink}}.rss"><i class="ui grey icon tooltip ml-3" data-content="{{.i18n.Tr "rss_feed"}}" data-position="top center">{{svg "octicon-rss" 36}}</i></a>
<span class="org-visibility"> <span class="org-visibility">
{{if .Org.Visibility.IsLimited}}<div class="ui large basic horizontal label">{{.i18n.Tr "org.settings.visibility.limited_shortname"}}</div>{{end}} {{if .Org.Visibility.IsLimited}}<div class="ui large basic horizontal label">{{.i18n.Tr "org.settings.visibility.limited_shortname"}}</div>{{end}}
{{if .Org.Visibility.IsPrivate}}<div class="ui large basic horizontal label">{{.i18n.Tr "org.settings.visibility.private_shortname"}}</div>{{end}} {{if .Org.Visibility.IsPrivate}}<div class="ui large basic horizontal label">{{.i18n.Tr "org.settings.visibility.private_shortname"}}</div>{{end}}

View File

@ -13,6 +13,7 @@
<a href="{{.Owner.HomeLink}}">{{.Owner.Name}}</a> <a href="{{.Owner.HomeLink}}">{{.Owner.Name}}</a>
<div class="mx-2">/</div> <div class="mx-2">/</div>
<a href="{{$.RepoLink}}">{{.Name}}</a> <a href="{{$.RepoLink}}">{{.Name}}</a>
<a href="{{$.RepoLink}}.rss"><i class="ui grey icon tooltip ml-3" data-content="{{$.i18n.Tr "rss_feed"}}" data-position="top center">{{svg "octicon-rss" 18}}</i></a>
<div class="labels df ac fw"> <div class="labels df ac fw">
{{if .IsTemplate}} {{if .IsTemplate}}
{{if .IsPrivate}} {{if .IsPrivate}}

View File

@ -16,6 +16,7 @@
<div class="content word-break profile-avatar-name"> <div class="content word-break profile-avatar-name">
{{if .Owner.FullName}}<span class="header text center">{{.Owner.FullName}}</span>{{end}} {{if .Owner.FullName}}<span class="header text center">{{.Owner.FullName}}</span>{{end}}
<span class="username text center">{{.Owner.Name}}</span> <span class="username text center">{{.Owner.Name}}</span>
<a href="{{.Owner.HomeLink}}.rss"><i class="ui grey icon tooltip ml-3" data-content="{{.i18n.Tr "rss_feed"}}" data-position="bottom center">{{svg "octicon-rss" 18}}</i></a>
</div> </div>
<div class="extra content word-break"> <div class="extra content word-break">
<ul> <ul>

View File

@ -50,6 +50,8 @@
overflow-wrap: anywhere; overflow-wrap: anywhere;
.ui.header { .ui.header {
display: flex;
align-items: center;
font-size: 36px; font-size: 36px;
margin-bottom: 0; margin-bottom: 0;
.org-visibility .label { .org-visibility .label {

View File

@ -3,12 +3,8 @@
.user { .user {
&.profile { &.profile {
.ui.card { .ui.card {
.header,
.username {
display: block;
}
.header { .header {
display: block;
font-weight: 600; font-weight: 600;
font-size: 1.3rem; font-size: 1.3rem;
margin-top: -.2rem; margin-top: -.2rem;
@ -17,6 +13,7 @@
.profile-avatar-name { .profile-avatar-name {
border-top: none; border-top: none;
text-align: center;
} }
.extra.content { .extra.content {