aboutsummaryrefslogtreecommitdiff
path: root/templates/user/meta/header.tmpl
blob: 9d164ae35396a5f2da92a6390559ca0c1e6141d7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
{{with .Owner}}
<div class="ui container">
	<img class="ui avatar image" src="{{.AvatarURLPath}}">
	<span class="header name">
		<a href="{{.HomeURLPath}}">{{.Name}}</a>
		{{with .FullName}}({{.}}){{end}}
	</span>

	<div class="ui right">
		{{if or $.PageIsFollowers $.PageIsFollowing}}
			{{if and $.IsLogged (ne $.LoggedUserName .Name)}}
				<div class="follow">
					{{if $.LoggedUser.IsFollowing .ID}}
					<a class="ui small basic red button" href="{{.HomeURLPath}}/action/unfollow?redirect_to={{$.Link}}"><i class="octicon octicon-person"></i> {{$.i18n.Tr "user.unfollow"}}</a>
					{{else}}
					<a class="ui small basic green button" href="{{.HomeURLPath}}/action/follow?redirect_to={{$.Link}}"><i class="octicon octicon-person"></i> {{$.i18n.Tr "user.follow"}}</a>
					{{end}}
				</div>
			{{end}}
		{{end}}
	</div>
</div>
{{end}}
<div class="ui divider"></div>