#3348 always use relative avatar link in the template

This commit is contained in:
Unknwon 2016-08-05 12:12:54 -07:00
parent db3d393576
commit 50422f1fc2
32 changed files with 58 additions and 57 deletions

View file

@ -1,8 +1,9 @@
The issue will be closed without any reasons if it does not satisfy any of following requirements: The issue will be closed without any reasons if it does not satisfy any of following requirements:
1. Please do NOT post questions or config/deploy problems on GitHub, please use our forum: https://discuss.gogs.io 1. Please speak English, we have forum in [Chinese](https://discuss.gogs.io/c/getting-help/getting-help-chinese).
2. Please take a moment to search that an issue doesn't already exist. 2. Please post questions or config/deploy problems on our forum: https://discuss.gogs.io, here are bugs and feature requests only.
3. Please give all relevant information below for bug reports; incomplete details considered invalid report. 3. Please take a moment to search that an issue doesn't already exist.
4. Please give all relevant information below for bug reports; incomplete details considered invalid report.
**You MUST delete above content including this line before posting; too lazy to take this action considered invalid report.** **You MUST delete above content including this line before posting; too lazy to take this action considered invalid report.**

View file

@ -3,7 +3,7 @@ Gogs - Go Git Service [![Build Status](https://travis-ci.org/gogits/gogs.svg?bra
![](https://github.com/gogits/gogs/blob/master/public/img/gogs-large-resize.png?raw=true) ![](https://github.com/gogits/gogs/blob/master/public/img/gogs-large-resize.png?raw=true)
##### Current tip version: 0.9.61 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions) ##### Current tip version: 0.9.62 (see [Releases](https://github.com/gogits/gogs/releases) for binary versions)
| Web | UI | Preview | | Web | UI | Preview |
|:-------------:|:-------:|:-------:| |:-------------:|:-------:|:-------:|

View file

@ -31,6 +31,7 @@ ilko <kontact-mr.k AT outlook DOT com">
Ilya Makarov Ilya Makarov
Jamie Mansfield <dev AT jamierocks DOT uk> Jamie Mansfield <dev AT jamierocks DOT uk>
Jean THOMAS <contact AT tibounise DOT com> Jean THOMAS <contact AT tibounise DOT com>
Joubert RedRat <me+github AT redrat DOT com DOT br>
Juraj Bubniak <contact AT jbub DOT eu> Juraj Bubniak <contact AT jbub DOT eu>
Lafriks <lafriks AT gmail DOT com> Lafriks <lafriks AT gmail DOT com>
Lauri Ojansivu <x AT xet7 DOT org> Lauri Ojansivu <x AT xet7 DOT org>

View file

@ -17,7 +17,7 @@ import (
"github.com/gogits/gogs/modules/setting" "github.com/gogits/gogs/modules/setting"
) )
const APP_VER = "0.9.61.0804" const APP_VER = "0.9.62.0805"
func init() { func init() {
runtime.GOMAXPROCS(runtime.NumCPU()) runtime.GOMAXPROCS(runtime.NumCPU())

View file

@ -288,7 +288,7 @@ func (push *PushCommits) AvatarLink(email string) string {
log.Error(4, "GetUserByEmail: %v", err) log.Error(4, "GetUserByEmail: %v", err)
} }
} else { } else {
push.avatars[email] = u.AvatarLink() push.avatars[email] = u.RelAvatarLink()
} }
} }

View file

@ -254,11 +254,11 @@ func (u *User) RelAvatarLink() string {
return setting.GravatarSource + u.Avatar return setting.GravatarSource + u.Avatar
} }
// AvatarLink returns user avatar link. // AvatarLink returns user avatar absolute link.
func (u *User) AvatarLink() string { func (u *User) AvatarLink() string {
link := u.RelAvatarLink() link := u.RelAvatarLink()
if link[0] == '/' && link[1] != '/' { if link[0] == '/' && link[1] != '/' {
return strings.TrimSuffix(setting.AppUrl, "/") + link return setting.AppUrl + link[1:]
} }
return link return link
} }

View file

@ -77,7 +77,7 @@ func retrieveFeeds(ctx *context.Context, ctxUser *models.User, userID, offset in
ctx.Handle(500, "GetUserByName", err) ctx.Handle(500, "GetUserByName", err)
return return
} }
unameAvatars[act.ActUserName] = u.AvatarLink() unameAvatars[act.ActUserName] = u.RelAvatarLink()
} }
act.ActAvatar = unameAvatars[act.ActUserName] act.ActAvatar = unameAvatars[act.ActUserName]

View file

@ -1 +1 @@
0.9.61.0804 0.9.62.0805

View file

@ -90,7 +90,7 @@
<div class="ui dropdown head link jump item poping up" tabindex="-1" data-content="{{.i18n.Tr "user_profile_and_more"}}" data-variation="tiny inverted"> <div class="ui dropdown head link jump item poping up" tabindex="-1" data-content="{{.i18n.Tr "user_profile_and_more"}}" data-variation="tiny inverted">
<span class="text avatar"> <span class="text avatar">
<img class="ui small rounded image" src="{{.SignedUser.AvatarLink}}"> <img class="ui small rounded image" src="{{.SignedUser.RelAvatarLink}}">
<span class="sr-only">{{.i18n.Tr "user_profile_and_more"}}</span> <span class="sr-only">{{.i18n.Tr "user_profile_and_more"}}</span>
<i class="octicon octicon-triangle-down" tabindex="-1"></i> <i class="octicon octicon-triangle-down" tabindex="-1"></i>
</span> </span>

View file

@ -9,7 +9,7 @@
<div class="ui user list"> <div class="ui user list">
{{range .Users}} {{range .Users}}
<div class="item"> <div class="item">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
<div class="content"> <div class="content">
<span class="header"><a href="{{.HomeLink}}">{{.Name}}</a> {{.FullName}}</span> <span class="header"><a href="{{.HomeLink}}">{{.Name}}</a> {{.FullName}}</span>
<div class="description"> <div class="description">

View file

@ -3,7 +3,7 @@
<div class="ui vertically grid head"> <div class="ui vertically grid head">
<div class="column"> <div class="column">
<div class="ui header"> <div class="ui header">
<img class="ui image" src="{{.AvatarLink}}?s=100"> <img class="ui image" src="{{.RelAvatarLink}}?s=100">
<span class="text thin grey"><a href="{{.HomeLink}}">{{.DisplayName}}</a></span> <span class="text thin grey"><a href="{{.HomeLink}}">{{.DisplayName}}</a></span>
<div class="ui right"> <div class="ui right">

View file

@ -3,7 +3,7 @@
<div class="ui container"> <div class="ui container">
<div class="ui grid"> <div class="ui grid">
<div class="ui sixteen wide column"> <div class="ui sixteen wide column">
<img class="ui left" id="org-avatar" src="{{.Org.AvatarLink}}?s=140"/> <img class="ui left" id="org-avatar" src="{{.Org.RelAvatarLink}}?s=140"/>
<div id="org-info"> <div id="org-info">
<div class="ui header"> <div class="ui header">
{{.Org.DisplayName}} {{.Org.DisplayName}}
@ -48,7 +48,7 @@
{{$isMember := .IsOrganizationMember}} {{$isMember := .IsOrganizationMember}}
{{range .Members}} {{range .Members}}
{{if or $isMember (.IsPublicMember $.Org.ID)}} {{if or $isMember (.IsPublicMember $.Org.ID)}}
<a href="{{.HomeLink}}" title="{{.Name}}{{if .FullName}} ({{.FullName}}){{end}}"><img class="ui avatar" src="{{.AvatarLink}}"></a> <a href="{{.HomeLink}}" title="{{.Name}}{{if .FullName}} ({{.FullName}}){{end}}"><img class="ui avatar" src="{{.RelAvatarLink}}"></a>
{{end}} {{end}}
{{end}} {{end}}
</div> </div>

View file

@ -14,7 +14,7 @@
{{range .Members}} {{range .Members}}
<div class="item ui grid"> <div class="item ui grid">
<div class="ui one wide column"> <div class="ui one wide column">
<img class="ui avatar" src="{{.AvatarLink}}?s=48"> <img class="ui avatar" src="{{.RelAvatarLink}}?s=48">
</div> </div>
<div class="ui three wide column"> <div class="ui three wide column">
<div class="meta"><a href="{{.HomeLink}}">{{.Name}}</a></div> <div class="meta"><a href="{{.HomeLink}}">{{.Name}}</a></div>

View file

@ -16,7 +16,7 @@
<a class="ui red small button right" href="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/remove?uid={{.ID}}">{{$.i18n.Tr "org.members.remove"}}</a> <a class="ui red small button right" href="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/remove?uid={{.ID}}">{{$.i18n.Tr "org.members.remove"}}</a>
{{end}} {{end}}
<a href="{{.HomeLink}}"> <a href="{{.HomeLink}}">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
{{.DisplayName}} {{.DisplayName}}
</a> </a>
</div> </div>

View file

@ -26,7 +26,7 @@
<div class="ui attached segment members"> <div class="ui attached segment members">
{{range .Members}} {{range .Members}}
<a href="{{.HomeLink}}" title="{{.Name}}"> <a href="{{.HomeLink}}" title="{{.Name}}">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
</a> </a>
{{end}} {{end}}
</div> </div>

View file

@ -30,7 +30,7 @@
<tr> <tr>
<td class="author"> <td class="author">
{{if .User}} {{if .User}}
<img class="ui avatar image" src="{{.User.AvatarLink}}" alt=""/>&nbsp;&nbsp;<a href="{{AppSubUrl}}/{{.User.Name}}">{{.Author.Name}}</a> <img class="ui avatar image" src="{{.User.RelAvatarLink}}" alt=""/>&nbsp;&nbsp;<a href="{{AppSubUrl}}/{{.User.Name}}">{{.Author.Name}}</a>
{{else}} {{else}}
<img class="ui avatar image" src="{{AvatarLink .Author.Email}}" alt=""/>&nbsp;&nbsp;{{.Author.Name}} <img class="ui avatar image" src="{{AvatarLink .Author.Email}}" alt=""/>&nbsp;&nbsp;{{.Author.Name}}
{{end}} {{end}}

View file

@ -14,18 +14,18 @@
<div class="ui selection owner dropdown"> <div class="ui selection owner dropdown">
<input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required> <input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required>
<span class="text"> <span class="text">
<img class="ui mini image" src="{{.ContextUser.AvatarLink}}"> <img class="ui mini image" src="{{.ContextUser.RelAvatarLink}}">
{{.ContextUser.ShortName 20}} {{.ContextUser.ShortName 20}}
</span> </span>
<i class="dropdown icon"></i> <i class="dropdown icon"></i>
<div class="menu"> <div class="menu">
<div class="item" data-value="{{.SignedUser.ID}}"> <div class="item" data-value="{{.SignedUser.ID}}">
<img class="ui mini image" src="{{.SignedUser.AvatarLink}}"> <img class="ui mini image" src="{{.SignedUser.RelAvatarLink}}">
{{.SignedUser.ShortName 20}} {{.SignedUser.ShortName 20}}
</div> </div>
{{range .Orgs}} {{range .Orgs}}
<div class="item" data-value="{{.ID}}"> <div class="item" data-value="{{.ID}}">
<img class="ui mini image" src="{{.AvatarLink}}"> <img class="ui mini image" src="{{.RelAvatarLink}}">
{{.ShortName 20}} {{.ShortName 20}}
</div> </div>
{{end}} {{end}}

View file

@ -13,7 +13,7 @@
</div> </div>
<div class="ui attached info segment"> <div class="ui attached info segment">
{{if .Author}} {{if .Author}}
<img class="ui avatar image" src="{{.Author.AvatarLink}}" /> <img class="ui avatar image" src="{{.Author.RelAvatarLink}}" />
<a href="{{.Author.HomeLink}}"><strong>{{.Commit.Author.Name}}</strong></a> {{if .IsSigned}}<{{.Commit.Author.Email}}>{{end}} <a href="{{.Author.HomeLink}}"><strong>{{.Commit.Author.Name}}</strong></a> {{if .IsSigned}}<{{.Commit.Author.Email}}>{{end}}
{{else}} {{else}}
<img class="ui avatar image" src="{{AvatarLink .Commit.Author.Email}}" /> <img class="ui avatar image" src="{{AvatarLink .Commit.Author.Email}}" />

View file

@ -8,7 +8,7 @@
<div class="ui list"> <div class="ui list">
{{range .Forks}} {{range .Forks}}
<div class="item"> <div class="item">
<img class="ui avatar image" src="{{.Owner.AvatarLink}}"> <img class="ui avatar image" src="{{.Owner.RelAvatarLink}}">
<div class="link"> <div class="link">
<a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a> <a href="{{AppSubUrl}}/{{.Owner.Name}}">{{.Owner.Name}}</a>
/ /

View file

@ -61,7 +61,7 @@
<div class="menu"> <div class="menu">
<a class="item" href="{{$.Link}}?type={{$.ViewType}}&sort={{$.SortType}}&state={{$.State}}&labels={{.SelectLabels}}&milestone={{$.MilestoneID}}">{{.i18n.Tr "repo.issues.filter_assginee_no_select"}}</a> <a class="item" href="{{$.Link}}?type={{$.ViewType}}&sort={{$.SortType}}&state={{$.State}}&labels={{.SelectLabels}}&milestone={{$.MilestoneID}}">{{.i18n.Tr "repo.issues.filter_assginee_no_select"}}</a>
{{range .Assignees}} {{range .Assignees}}
<a class="{{if eq $.AssigneeID .ID}}active selected{{end}} item" href="{{$.Link}}?type={{$.ViewType}}&sort={{$.SortType}}&state={{$.State}}&labels={{$.SelectLabels}}&milestone={{$.MilestoneID}}&assignee={{.ID}}"><img src="{{.AvatarLink}}"> {{.Name}}</a> <a class="{{if eq $.AssigneeID .ID}}active selected{{end}} item" href="{{$.Link}}?type={{$.ViewType}}&sort={{$.SortType}}&state={{$.State}}&labels={{$.SelectLabels}}&milestone={{$.MilestoneID}}&assignee={{.ID}}"><img src="{{.RelAvatarLink}}"> {{.Name}}</a>
{{end}} {{end}}
</div> </div>
</div> </div>
@ -121,7 +121,7 @@
{{end}} {{end}}
{{if .Assignee}} {{if .Assignee}}
<a class="ui right assignee poping up" href="{{.Assignee.HomeLink}}" data-content="{{.Assignee.Name}}" data-variation="inverted" data-position="left center"> <a class="ui right assignee poping up" href="{{.Assignee.HomeLink}}" data-content="{{.Assignee.Name}}" data-variation="inverted" data-position="left center">
<img class="ui avatar image" src="{{.Assignee.AvatarLink}}"> <img class="ui avatar image" src="{{.Assignee.RelAvatarLink}}">
</a> </a>
{{end}} {{end}}
</p> </p>

View file

@ -9,7 +9,7 @@
<div class="ui comments"> <div class="ui comments">
<div class="comment"> <div class="comment">
<a class="avatar" href="{{.SignedUser.HomeLink}}"> <a class="avatar" href="{{.SignedUser.HomeLink}}">
<img src="{{.SignedUser.AvatarLink}}"> <img src="{{.SignedUser.RelAvatarLink}}">
</a> </a>
<div class="ui segment content"> <div class="ui segment content">
<div class="field"> <div class="field">
@ -104,7 +104,7 @@
<div class="menu"> <div class="menu">
<div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_assignee"}}</div> <div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_assignee"}}</div>
{{range .Assignees}} {{range .Assignees}}
<div class="item" data-id="{{.ID}}" data-href="{{$.RepoLink}}/issues?assignee={{.ID}}" data-avatar="{{.AvatarLink}}"><img src="{{.AvatarLink}}"> {{.Name}}</div> <div class="item" data-id="{{.ID}}" data-href="{{$.RepoLink}}/issues?assignee={{.ID}}" data-avatar="{{.RelAvatarLink}}"><img src="{{.RelAvatarLink}}"> {{.Name}}</div>
{{end}} {{end}}
</div> </div>
</div> </div>
@ -112,7 +112,7 @@
<span class="no-select item {{if .Assignee}}hide{{end}}">{{.i18n.Tr "repo.issues.new.no_assignee"}}</span> <span class="no-select item {{if .Assignee}}hide{{end}}">{{.i18n.Tr "repo.issues.new.no_assignee"}}</span>
<div class="selected"> <div class="selected">
{{if .Assignee}} {{if .Assignee}}
<a class="item" href="{{.RepoLink}}/issues?assignee={{.Assignee.ID}}"><img class="ui avatar image" src="{{.Assignee.AvatarLink}}"> {{.Assignee.Name}}</a> <a class="item" href="{{.RepoLink}}/issues?assignee={{.Assignee.ID}}"><img class="ui avatar image" src="{{.Assignee.RelAvatarLink}}"> {{.Assignee.Name}}</a>
{{end}} {{end}}
</div> </div>
</div> </div>

View file

@ -13,7 +13,7 @@
<ui class="ui comments"> <ui class="ui comments">
<div class="comment"> <div class="comment">
<a class="avatar" {{if gt .Issue.Poster.ID 0}}href="{{.Issue.Poster.HomeLink}}"{{end}}> <a class="avatar" {{if gt .Issue.Poster.ID 0}}href="{{.Issue.Poster.HomeLink}}"{{end}}>
<img src="{{.Issue.Poster.AvatarLink}}"> <img src="{{.Issue.Poster.RelAvatarLink}}">
</a> </a>
<div class="content"> <div class="content">
<div class="ui top attached header"> <div class="ui top attached header">
@ -56,7 +56,7 @@
{{if eq .Type 0}} {{if eq .Type 0}}
<div class="comment" id="{{.HashTag}}"> <div class="comment" id="{{.HashTag}}">
<a class="avatar" {{if gt .Poster.ID 0}}href="{{.Poster.HomeLink}}"{{end}}> <a class="avatar" {{if gt .Poster.ID 0}}href="{{.Poster.HomeLink}}"{{end}}>
<img src="{{.Poster.AvatarLink}}"> <img src="{{.Poster.RelAvatarLink}}">
</a> </a>
<div class="content"> <div class="content">
<div class="ui top attached header"> <div class="ui top attached header">
@ -107,7 +107,7 @@
<div class="event"> <div class="event">
<span class="octicon octicon-primitive-dot"></span> <span class="octicon octicon-primitive-dot"></span>
<a class="ui avatar image" href="{{.Poster.HomeLink}}"> <a class="ui avatar image" href="{{.Poster.HomeLink}}">
<img src="{{.Poster.AvatarLink}}"> <img src="{{.Poster.RelAvatarLink}}">
</a> </a>
<span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.reopened_at" .EventTag $createdStr | Safe}}</span> <span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.reopened_at" .EventTag $createdStr | Safe}}</span>
</div> </div>
@ -115,7 +115,7 @@
<div class="event"> <div class="event">
<span class="octicon octicon-circle-slash"></span> <span class="octicon octicon-circle-slash"></span>
<a class="ui avatar image" href="{{.Poster.HomeLink}}"> <a class="ui avatar image" href="{{.Poster.HomeLink}}">
<img src="{{.Poster.AvatarLink}}"> <img src="{{.Poster.RelAvatarLink}}">
</a> </a>
<span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.closed_at" .EventTag $createdStr | Safe}}</span> <span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.closed_at" .EventTag $createdStr | Safe}}</span>
</div> </div>
@ -123,7 +123,7 @@
<div class="event"> <div class="event">
<span class="octicon octicon-bookmark"></span> <span class="octicon octicon-bookmark"></span>
<a class="ui avatar image" href="{{.Poster.HomeLink}}"> <a class="ui avatar image" href="{{.Poster.HomeLink}}">
<img src="{{.Poster.AvatarLink}}"> <img src="{{.Poster.RelAvatarLink}}">
</a> </a>
<span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.commit_ref_at" .EventTag $createdStr | Safe}}</span> <span class="text grey"><a href="{{.Poster.HomeLink}}">{{.Poster.Name}}</a> {{$.i18n.Tr "repo.issues.commit_ref_at" .EventTag $createdStr | Safe}}</span>
@ -199,7 +199,7 @@
{{if .IsSigned}} {{if .IsSigned}}
<div class="comment form"> <div class="comment form">
<a class="avatar" href="{{.SignedUser.HomeLink}}"> <a class="avatar" href="{{.SignedUser.HomeLink}}">
<img src="{{.SignedUser.AvatarLink}}"> <img src="{{.SignedUser.RelAvatarLink}}">
</a> </a>
<div class="content"> <div class="content">
<form class="ui segment form" id="comment-form" action="{{$.RepoLink}}/issues/{{.Issue.Index}}/comments" method="post"> <form class="ui segment form" id="comment-form" action="{{$.RepoLink}}/issues/{{.Issue.Index}}/comments" method="post">
@ -309,7 +309,7 @@
<div class="menu" data-action="update" data-update-url="{{$.RepoLink}}/issues/{{$.Issue.Index}}/assignee"> <div class="menu" data-action="update" data-update-url="{{$.RepoLink}}/issues/{{$.Issue.Index}}/assignee">
<div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_assignee"}}</div> <div class="no-select item">{{.i18n.Tr "repo.issues.new.clear_assignee"}}</div>
{{range .Assignees}} {{range .Assignees}}
<div class="item" data-id="{{.ID}}" data-href="{{$.RepoLink}}/issues?assignee={{.ID}}" data-avatar="{{.AvatarLink}}"><img src="{{.AvatarLink}}"> {{.Name}}</div> <div class="item" data-id="{{.ID}}" data-href="{{$.RepoLink}}/issues?assignee={{.ID}}" data-avatar="{{.RelAvatarLink}}"><img src="{{.RelAvatarLink}}"> {{.Name}}</div>
{{end}} {{end}}
</div> </div>
</div> </div>
@ -317,7 +317,7 @@
<span class="no-select item {{if .Issue.Assignee}}hide{{end}}">{{.i18n.Tr "repo.issues.new.no_assignee"}}</span> <span class="no-select item {{if .Issue.Assignee}}hide{{end}}">{{.i18n.Tr "repo.issues.new.no_assignee"}}</span>
<div class="selected"> <div class="selected">
{{if .Issue.Assignee}} {{if .Issue.Assignee}}
<a class="item" href="{{$.RepoLink}}/issues?assignee={{.Issue.Assignee.ID}}"><img class="ui avatar image" src="{{.Issue.Assignee.AvatarLink}}"> {{.Issue.Assignee.Name}}</a> <a class="item" href="{{$.RepoLink}}/issues?assignee={{.Issue.Assignee.ID}}"><img class="ui avatar image" src="{{.Issue.Assignee.RelAvatarLink}}"> {{.Issue.Assignee.Name}}</a>
{{end}} {{end}}
</div> </div>
</div> </div>
@ -329,7 +329,7 @@
<div> <div>
{{range .Participants}} {{range .Participants}}
<a href="{{.HomeLink}}"> <a href="{{.HomeLink}}">
<img class="ui avatar image poping up" src="{{.AvatarLink}}" data-content="{{.DisplayName}}" data-position="top center" data-variation="small inverted"> <img class="ui avatar image poping up" src="{{.RelAvatarLink}}" data-content="{{.DisplayName}}" data-position="top center" data-variation="small inverted">
</a> </a>
{{end}} {{end}}
</div> </div>

View file

@ -39,18 +39,18 @@
<div class="ui selection owner dropdown"> <div class="ui selection owner dropdown">
<input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required> <input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required>
<span class="text"> <span class="text">
<img class="ui mini image" src="{{.ContextUser.AvatarLink}}"> <img class="ui mini image" src="{{.ContextUser.RelAvatarLink}}">
{{.ContextUser.ShortName 20}} {{.ContextUser.ShortName 20}}
</span> </span>
<i class="dropdown icon"></i> <i class="dropdown icon"></i>
<div class="menu"> <div class="menu">
<div class="item" data-value="{{.SignedUser.ID}}"> <div class="item" data-value="{{.SignedUser.ID}}">
<img class="ui mini image" src="{{.SignedUser.AvatarLink}}"> <img class="ui mini image" src="{{.SignedUser.RelAvatarLink}}">
{{.SignedUser.ShortName 20}} {{.SignedUser.ShortName 20}}
</div> </div>
{{range .Orgs}} {{range .Orgs}}
<div class="item" data-value="{{.ID}}"> <div class="item" data-value="{{.ID}}">
<img class="ui mini image" src="{{.AvatarLink}}"> <img class="ui mini image" src="{{.RelAvatarLink}}">
{{.ShortName 20}} {{.ShortName 20}}
</div> </div>
{{end}} {{end}}

View file

@ -14,19 +14,19 @@
<div class="ui selection owner dropdown"> <div class="ui selection owner dropdown">
<input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required> <input type="hidden" id="uid" name="uid" value="{{.ContextUser.ID}}" required>
<span class="text"> <span class="text">
<img class="ui mini image" src="{{.ContextUser.AvatarLink}}"> <img class="ui mini image" src="{{.ContextUser.RelAvatarLink}}">
{{.ContextUser.ShortName 20}} {{.ContextUser.ShortName 20}}
</span> </span>
<i class="dropdown icon"></i> <i class="dropdown icon"></i>
<div class="menu"> <div class="menu">
<div class="item" data-value="{{.SignedUser.ID}}"> <div class="item" data-value="{{.SignedUser.ID}}">
<img class="ui mini image" src="{{.SignedUser.AvatarLink}}"> <img class="ui mini image" src="{{.SignedUser.RelAvatarLink}}">
{{.SignedUser.ShortName 20}} {{.SignedUser.ShortName 20}}
</div> </div>
{{range .Orgs}} {{range .Orgs}}
{{if .IsOwnedBy $.SignedUser.ID}} {{if .IsOwnedBy $.SignedUser.ID}}
<div class="item" data-value="{{.ID}}"> <div class="item" data-value="{{.ID}}">
<img class="ui mini image" src="{{.AvatarLink}}"> <img class="ui mini image" src="{{.RelAvatarLink}}">
{{.ShortName 20}} {{.ShortName 20}}
</div> </div>
{{end}} {{end}}

View file

@ -41,7 +41,7 @@
</h3> </h3>
<p class="text grey"> <p class="text grey">
<span class="author"> <span class="author">
<img class="img-10" src="{{.Publisher.AvatarLink}}"> <img class="img-10" src="{{.Publisher.RelAvatarLink}}">
<a href="{{AppSubUrl}}/{{.Publisher.Name}}">{{.Publisher.Name}}</a> <a href="{{AppSubUrl}}/{{.Publisher.Name}}">{{.Publisher.Name}}</a>
</span> </span>
{{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}} {{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}}

View file

@ -14,7 +14,7 @@
<div class="item ui grid"> <div class="item ui grid">
<div class="ui five wide column"> <div class="ui five wide column">
<a href="{{AppSubUrl}}/{{.Name}}"> <a href="{{AppSubUrl}}/{{.Name}}">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
{{.DisplayName}} {{.DisplayName}}
</a> </a>
</div> </div>

View file

@ -6,7 +6,7 @@
{{range .Cards}} {{range .Cards}}
<li class="item ui segment"> <li class="item ui segment">
<a href="{{.HomeLink}}"> <a href="{{.HomeLink}}">
<img class="avatar" src="{{.AvatarLink}}"/> <img class="avatar" src="{{.RelAvatarLink}}"/>
</a> </a>
<h3 class="name"><a href="{{.HomeLink}}">{{.DisplayName}}</a></h3> <h3 class="name"><a href="{{.HomeLink}}">{{.DisplayName}}</a></h3>

View file

@ -3,7 +3,7 @@
<tr> <tr>
<th class="four wide"> <th class="four wide">
{{if .LastCommitUser}} {{if .LastCommitUser}}
<img class="ui avatar image img-12" src="{{.LastCommitUser.AvatarLink}}" /> <img class="ui avatar image img-12" src="{{.LastCommitUser.RelAvatarLink}}" />
<a href="{{AppSubUrl}}/{{.LastCommitUser.Name}}"><strong>{{.LastCommit.Author.Name}}</strong></a> <a href="{{AppSubUrl}}/{{.LastCommitUser.Name}}"><strong>{{.LastCommit.Author.Name}}</strong></a>
{{else}} {{else}}
<img class="ui avatar image img-12" src="{{AvatarLink .LastCommit.Author.Email}}" /> <img class="ui avatar image img-12" src="{{AvatarLink .LastCommit.Author.Email}}" />

View file

@ -72,7 +72,7 @@
{{$.i18n.Tr "repo.issues.opened_by" $timeStr .Poster.HomeLink .Poster.Name | Safe}} {{$.i18n.Tr "repo.issues.opened_by" $timeStr .Poster.HomeLink .Poster.Name | Safe}}
{{if .Assignee}} {{if .Assignee}}
<a class="ui right assignee poping up" href="{{.Assignee.HomeLink}}" data-content="{{.Assignee.Name}}" data-variation="inverted" data-position="left center"> <a class="ui right assignee poping up" href="{{.Assignee.HomeLink}}" data-content="{{.Assignee.Name}}" data-variation="inverted" data-position="left center">
<img class="ui avatar image" src="{{.Assignee.AvatarLink}}"> <img class="ui avatar image" src="{{.Assignee.RelAvatarLink}}">
</a> </a>
{{end}} {{end}}
</p> </p>

View file

@ -1,7 +1,7 @@
<div class="ui container"> <div class="ui container">
<div class="ui floating dropdown link jump"> <div class="ui floating dropdown link jump">
<span class="text"> <span class="text">
<img class="ui avatar image" src="{{.ContextUser.AvatarLink}}"> <img class="ui avatar image" src="{{.ContextUser.RelAvatarLink}}">
{{.ContextUser.ShortName 20}} {{.ContextUser.ShortName 20}}
<i class="dropdown icon"></i> <i class="dropdown icon"></i>
</span> </span>
@ -11,12 +11,12 @@
</div> </div>
<div class="items"> <div class="items">
<a class="{{if eq .ContextUser.ID .SignedUser.ID}}active selected{{end}} item" href="{{AppSubUrl}}/{{if .PageIsIssues}}issues{{else if .PageIsPulls}}pulls{{end}}"> <a class="{{if eq .ContextUser.ID .SignedUser.ID}}active selected{{end}} item" href="{{AppSubUrl}}/{{if .PageIsIssues}}issues{{else if .PageIsPulls}}pulls{{end}}">
<img class="ui avatar image" src="{{.SignedUser.AvatarLink}}"> <img class="ui avatar image" src="{{.SignedUser.RelAvatarLink}}">
{{.SignedUser.Name}} {{.SignedUser.Name}}
</a> </a>
{{range .Orgs}} {{range .Orgs}}
<a class="{{if eq $.ContextUser.ID .ID}}active selected{{end}} item" href="{{AppSubUrl}}/org/{{.Name}}/{{if $.PageIsIssues}}issues{{else if $.PageIsPulls}}pulls{{else}}dashboard{{end}}"> <a class="{{if eq $.ContextUser.ID .ID}}active selected{{end}} item" href="{{AppSubUrl}}/org/{{.Name}}/{{if $.PageIsIssues}}issues{{else if $.PageIsPulls}}pulls{{else}}dashboard{{end}}">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
{{.ShortName 20}} {{.ShortName 20}}
</a> </a>
{{end}} {{end}}

View file

@ -1,13 +1,12 @@
{{with .Owner}} {{with .Owner}}
<div class="ui container"> <div class="ui container">
<img class="ui avatar image" src="{{.AvatarLink}}"> <img class="ui avatar image" src="{{.RelAvatarLink}}">
<span class="header name"> <span class="header name">
<a href="{{.HomeLink}}">{{.Name}}</a> <a href="{{.HomeLink}}">{{.Name}}</a>
{{with .FullName}}({{.}}){{end}} {{with .FullName}}({{.}}){{end}}
</span> </span>
<div class="ui right"> <div class="ui right">
{{if or $.PageIsFollowers $.PageIsFollowing}} {{if or $.PageIsFollowers $.PageIsFollowing}}
{{if and $.IsSigned (ne $.SignedUserName .Name)}} {{if and $.IsSigned (ne $.SignedUserName .Name)}}
<div class="follow"> <div class="follow">

View file

@ -6,11 +6,11 @@
<div class="ui card"> <div class="ui card">
{{if eq .SignedUserName .Owner.Name}} {{if eq .SignedUserName .Owner.Name}}
<a class="image poping up" href="{{AppSubUrl}}/user/settings" id="profile-avatar" data-content="{{.i18n.Tr "user.change_avatar"}}" data-variation="inverted tiny" data-position="bottom center"> <a class="image poping up" href="{{AppSubUrl}}/user/settings" id="profile-avatar" data-content="{{.i18n.Tr "user.change_avatar"}}" data-variation="inverted tiny" data-position="bottom center">
<img src="{{.Owner.AvatarLink}}?s=290" title="{{.Owner.Name}}"/> <img src="{{.Owner.RelAvatarLink}}?s=290" title="{{.Owner.Name}}"/>
</a> </a>
{{else}} {{else}}
<span class="image"> <span class="image">
<img src="{{.Owner.AvatarLink}}?s=290" title="{{.Owner.Name}}"/> <img src="{{.Owner.RelAvatarLink}}?s=290" title="{{.Owner.Name}}"/>
</span> </span>
{{end}} {{end}}
<div class="content"> <div class="content">
@ -56,7 +56,7 @@
{{if .Orgs}} {{if .Orgs}}
<li> <li>
{{range .Orgs}} {{range .Orgs}}
<a href="{{.HomeLink}}"><img class="ui mini image poping up" src="{{.AvatarLink}}" data-content="{{.Name}}" data-position="top center" data-variation="tiny inverted"></a> <a href="{{.HomeLink}}"><img class="ui mini image poping up" src="{{.RelAvatarLink}}" data-content="{{.Name}}" data-position="top center" data-variation="tiny inverted"></a>
{{end}} {{end}}
</li> </li>
{{end}} {{end}}