Skip to content

Commit

Permalink
头像设成圆角
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmykuu committed Apr 11, 2013
1 parent a6790eb commit c2c17d1
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/gopher/views.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ func (u *Utils) UserInfo(username string) template.HTML {
c.Find(bson.M{"username": username}).One(&user)

format := `<div>
<a href="/member/%s"><img class="gravatar" src="%s-middle" style="float:left;"></a>
<a href="/member/%s"><img class="gravatar img-rounded" src="%s-middle" style="float:left;"></a>
<h3><a href="/member/%s">%s</a></h3>
<div class="clearfix"></div>
</div>`
Expand Down
4 changes: 2 additions & 2 deletions templates/account/info.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
{{$utils := .utils}}
{{$user := $utils.AssertUser .user}}
<div class="content">
<img src="{{$user.AvatarImgSrc}}-large" class="pull-left" style="margin-right: 20px;">
<img src="{{$user.AvatarImgSrc}}-large" class="pull-left img-rounded" style="margin-right: 20px;">
<h3>{{$user.Username}}</h3>
{{if $user.Tagline}}
<h3><small>{{$user.Tagline}}</small></h3>
Expand Down Expand Up @@ -67,7 +67,7 @@ <h4>{{$user.Username}}最近创建的主题</h4>
<dl class="topics">
{{range $user.LatestTopics}}
<dd>
<a href="/member/{{.Creater.Username}}" class="pull-left" style="margin-right: 10px;"><img src="{{.Creater.AvatarImgSrc}}-middle"></a>
<a href="/member/{{.Creater.Username}}" class="pull-left" style="margin-right: 10px;"><img class="img-rounded" src="{{.Creater.AvatarImgSrc}}-middle"></a>
{{if .CommentCount}}
<a class="badge pull-right" href="/t/{{.Id_.Hex}}#.LatestReplyId.Hex">{{.CommentCount}}</a>
{{end}}
Expand Down
8 changes: 4 additions & 4 deletions templates/account/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ <h4 id="avatar"><small>头像</small></h4>
<p>golang.tc使用<a href="http://www.qiniutek.com/" target="_blank">七牛云存储</a>来提供头像服务.</p>
<p>
当前头像
<img src="{{.user.AvatarImgSrc}}-large">
<img src="{{.user.AvatarImgSrc}}-middle">
<img src="{{.user.AvatarImgSrc}}-small">
<img class="img-rounded" src="{{.user.AvatarImgSrc}}-large">
<img class="img-rounded" src="{{.user.AvatarImgSrc}}-middle">
<img class="img-rounded" src="{{.user.AvatarImgSrc}}-small">
</p>
<p><br><br></p>
<ul class="nav nav-tabs" id="avatar-tab">
Expand All @@ -58,7 +58,7 @@ <h4 id="avatar"><small>头像</small></h4>
<li>
<label>
<input type="radio" name="defaultAvatars" value="{{.}}"{{if $user.IsDefaultAvatar .}} checked{{end}}>
<img src="http://gopher.qiniudn.com/avatar/{{.}}-middle">
<img class="img-rounded" src="http://gopher.qiniudn.com/avatar/{{.}}-middle">
</label>
</li>
{{end}}
Expand Down
2 changes: 1 addition & 1 deletion templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ <h3>欢迎来到Golang中国社区</h3>
<dl class="topics">
{{range .topics}}
<dd>
<a href="/member/{{.Creater.Username}}" class="pull-left" style="margin-right: 10px;"><img src="{{.Creater.AvatarImgSrc}}-middle"></a>
<a href="/member/{{.Creater.Username}}" class="pull-left" style="margin-right: 10px;"><img class="img-rounded" src="{{.Creater.AvatarImgSrc}}-middle"></a>
{{if .CommentCount}}
<a class="badge pull-right" href="/t/{{.Id_.Hex}}#.LatestReplyId.Hex">{{.CommentCount}}</a>
{{end}}
Expand Down
2 changes: 1 addition & 1 deletion templates/topic/show.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ <h1>{{$topic.Title}}</h1>
<a href="/comment/{{.Id_.Hex}}/delete" class="remove label pull-right" title="删除"><i class="icon-white icon-remove"></i></a>
{{end}}
{{end}}
<a href="/" class="pull-left" style="margin-right: 10px;"><img src="{{.Creater.AvatarImgSrc}}-middle"></a>
<a href="/" class="pull-left" style="margin-right: 10px;"><img class="img-rounded" src="{{.Creater.AvatarImgSrc}}-middle"></a>
<div class="info">
<a href="/member/{{.Creater.Username}}"><strong>{{.Creater.Username}}</strong></a>
{{$utils.FormatTime .CreatedAt}}
Expand Down

0 comments on commit c2c17d1

Please sign in to comment.