|
10 | 10 | <div class="ui small label">{{.RepoCount}}</div>
|
11 | 11 | {{end}}
|
12 | 12 | </a>
|
13 |
| - {{if or .ContextUser.IsIndividual (and .ContextUser.IsOrganization .CanReadProjects)}} |
| 13 | + {{if or .ContextUser.IsIndividual .CanReadProjects}} |
14 | 14 | <a href="{{.ContextUser.HomeLink}}/-/projects" class="{{if .PageIsViewProjects}}active {{end}}item">
|
15 | 15 | {{svg "octicon-project-symlink"}} {{ctx.Locale.Tr "user.projects"}}
|
16 | 16 | {{if .ProjectCount}}
|
17 | 17 | <div class="ui small label">{{.ProjectCount}}</div>
|
18 | 18 | {{end}}
|
19 | 19 | </a>
|
20 | 20 | {{end}}
|
21 |
| - {{if and .IsPackageEnabled (or .ContextUser.IsIndividual (and .ContextUser.IsOrganization .CanReadPackages))}} |
| 21 | + {{if and .IsPackageEnabled (or .ContextUser.IsIndividual .CanReadPackages)}} |
22 | 22 | <a href="{{.ContextUser.HomeLink}}/-/packages" class="{{if .IsPackagesPage}}active {{end}}item">
|
23 | 23 | {{svg "octicon-package"}} {{ctx.Locale.Tr "packages.title"}}
|
24 | 24 | </a>
|
25 | 25 | {{end}}
|
26 |
| - {{if and .IsRepoIndexerEnabled (or .ContextUser.IsIndividual (and .ContextUser.IsOrganization .CanReadCode))}} |
| 26 | + {{if and .IsRepoIndexerEnabled (or .ContextUser.IsIndividual .CanReadCode)}} |
27 | 27 | <a href="{{.ContextUser.HomeLink}}/-/code" class="{{if .IsCodePage}}active {{end}}item">
|
28 | 28 | {{svg "octicon-code"}} {{ctx.Locale.Tr "user.code"}}
|
29 | 29 | </a>
|
30 | 30 | {{end}}
|
31 | 31 |
|
32 |
| - {{if .ContextUser.IsOrganization}} |
33 |
| - {{if .NumMembers}} |
34 |
| - <a class="{{if $.PageIsOrgMembers}}active {{end}}item" href="{{$.OrgLink}}/members"> |
35 |
| - {{svg "octicon-person"}} {{ctx.Locale.Tr "org.members"}} |
36 |
| - <div class="ui small label">{{.NumMembers}}</div> |
37 |
| - </a> |
38 |
| - {{end}} |
39 |
| - {{if .IsOrganizationMember}} |
40 |
| - <a class="{{if $.PageIsOrgTeams}}active {{end}}item" href="{{$.OrgLink}}/teams"> |
41 |
| - {{svg "octicon-people"}} {{ctx.Locale.Tr "org.teams"}} |
42 |
| - {{if .NumTeams}} |
43 |
| - <div class="ui small label">{{.NumTeams}}</div> |
44 |
| - {{end}} |
45 |
| - </a> |
46 |
| - {{end}} |
47 |
| - |
48 |
| - {{if .IsOrganizationOwner}} |
49 |
| - <div class="right menu"> |
50 |
| - <a class="item" href="{{.OrgLink}}/settings"> |
51 |
| - {{svg "octicon-tools"}} {{ctx.Locale.Tr "repo.settings"}} |
52 |
| - </a> |
53 |
| - </div> |
54 |
| - {{end}} |
| 32 | + <a class="{{if eq .TabName "activity"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=activity"> |
| 33 | + {{svg "octicon-rss"}} {{ctx.Locale.Tr "user.activity"}} |
| 34 | + </a> |
| 35 | + {{if not .DisableStars}} |
| 36 | + <a class="{{if eq .TabName "stars"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=stars"> |
| 37 | + {{svg "octicon-star"}} {{ctx.Locale.Tr "user.starred"}} |
| 38 | + {{if .ContextUser.NumStars}} |
| 39 | + <div class="ui small label">{{.ContextUser.NumStars}}</div> |
| 40 | + {{end}} |
| 41 | + </a> |
55 | 42 | {{else}}
|
56 |
| - <a class="{{if eq .TabName "activity"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=activity"> |
57 |
| - {{svg "octicon-rss"}} {{ctx.Locale.Tr "user.activity"}} |
| 43 | + <a class="{{if eq .TabName "watching"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=watching"> |
| 44 | + {{svg "octicon-eye"}} {{ctx.Locale.Tr "user.watched"}} |
58 | 45 | </a>
|
59 |
| - {{if not .DisableStars}} |
60 |
| - <a class="{{if eq .TabName "stars"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=stars"> |
61 |
| - {{svg "octicon-star"}} {{ctx.Locale.Tr "user.starred"}} |
62 |
| - {{if .ContextUser.NumStars}} |
63 |
| - <div class="ui small label">{{.ContextUser.NumStars}}</div> |
64 |
| - {{end}} |
65 |
| - </a> |
66 |
| - {{else}} |
67 |
| - <a class="{{if eq .TabName "watching"}}active {{end}}item" href="{{.ContextUser.HomeLink}}?tab=watching"> |
68 |
| - {{svg "octicon-eye"}} {{ctx.Locale.Tr "user.watched"}} |
69 |
| - </a> |
70 |
| - {{end}} |
71 | 46 | {{end}}
|
72 | 47 | </div>
|
0 commit comments