1
0
Fork 0

Minor UI fixes (#14926)

* disable fork button when not signed in

* fix commit body styling on PR page

* fixup! fix commit body styling on PR page
This commit is contained in:
Norwin 2021-03-08 17:55:37 +00:00 committed by GitHub
parent f061277c86
commit f4ce10c6a3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 2 deletions

View file

@ -83,7 +83,7 @@
</div> </div>
</form> </form>
{{if and (not .IsEmpty) ($.Permission.CanRead $.UnitTypeCode)}} {{if and (not .IsEmpty) ($.Permission.CanRead $.UnitTypeCode)}}
<div class="ui labeled button" tabindex="0"> <div class="ui labeled button {{if not $.IsSigned}} disabled{{end}}" tabindex="0">
<a class="ui compact small basic button {{if or (not $.IsSigned) (not $.CanSignedUserFork)}}poping up{{end}}" {{if $.CanSignedUserFork}}href="{{AppSubUrl}}/repo/fork/{{.ID}}"{{else if $.IsSigned}} data-content="{{$.i18n.Tr "repo.fork_from_self"}}" {{ else }} data-content="{{$.i18n.Tr "repo.fork_guest_user" }}" rel="nofollow" href="{{AppSubUrl}}/user/login?redirect_to={{AppSubUrl}}/repo/fork/{{.ID}}" {{end}} data-position="top center" data-variation="tiny"> <a class="ui compact small basic button {{if or (not $.IsSigned) (not $.CanSignedUserFork)}}poping up{{end}}" {{if $.CanSignedUserFork}}href="{{AppSubUrl}}/repo/fork/{{.ID}}"{{else if $.IsSigned}} data-content="{{$.i18n.Tr "repo.fork_from_self"}}" {{ else }} data-content="{{$.i18n.Tr "repo.fork_guest_user" }}" rel="nofollow" href="{{AppSubUrl}}/user/login?redirect_to={{AppSubUrl}}/repo/fork/{{.ID}}" {{end}} data-position="top center" data-variation="tiny">
{{svg "octicon-repo-forked"}}{{$.i18n.Tr "repo.fork"}} {{svg "octicon-repo-forked"}}{{$.i18n.Tr "repo.fork"}}
</a> </a>

View file

@ -2768,12 +2768,17 @@ tbody.commit-list {
.commit-body { .commit-body {
white-space: pre-wrap; white-space: pre-wrap;
line-height: initial;
} }
.repository:not(.diff) { .repository:not(.diff) {
.commit-body { .commit-body { // commit history list
margin: 0; margin: 0;
} }
.timeline-item .commit-body { // PR-comment
margin-left: 40px;
}
} }
.git-notes.top { .git-notes.top {