repo_list.tmpl 1.1 KiB

12345678910111213141516171819202122232425262728293031323334
  1. <div class="ui repository list">
  2. {{range .Repos}}
  3. <div class="item">
  4. <div class="ui header">
  5. {{if .RelAvatarLink}}
  6. <img class="ui avatar image" src="{{.RelAvatarLink}}"/>
  7. {{end}}
  8. <a class="name" href="{{.Link}}">
  9. {{if or $.PageIsExplore $.PageIsProfileStarList }}{{if .Owner}}{{.Owner.Name}} / {{end}}{{end}}{{.Name}}
  10. {{if .IsArchived}}<i class="archive icon archived-icon"></i>{{end}}
  11. </a>
  12. {{if .IsPrivate}}
  13. <span class="middle text gold">{{svg "octicon-lock" 16}}</span>
  14. {{else if .IsFork}}
  15. <span class="middle">{{svg "octicon-repo-forked" 16}}</span>
  16. {{else if .IsMirror}}
  17. <span class="middle">{{svg "octicon-repo-clone" 16}}</span>
  18. {{else if .Owner}}
  19. {{if .Owner.Visibility.IsPrivate}}
  20. <span class="text gold">{{svg "octicon-lock" 16}}</span>
  21. {{end}}
  22. {{end}}
  23. </div>
  24. <div class="description">
  25. {{if .DescriptionHTML}}<p class="has-emoji">{{.DescriptionHTML}}</p>{{end}}
  26. <p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSinceUnix .UpdatedUnix $.i18n.Lang}}</p>
  27. </div>
  28. </div>
  29. {{else}}
  30. <div>
  31. {{$.i18n.Tr "explore.repo_no_results"}}
  32. </div>
  33. {{end}}
  34. </div>