user_cards.tmpl 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <div class="ui container user-cards">
  2. <h2 class="ui dividing header">
  3. {{.CardsTitle}}
  4. </h2>
  5. <ul class="list">
  6. {{range .Cards}}
  7. <li class="item ui segment">
  8. <a href="{{.HomeLink}}">
  9. <img class="avatar" src="{{.RelAvatarLink}}"/>
  10. </a>
  11. <h3 class="name"><a href="{{.HomeLink}}">{{.DisplayName}}</a></h3>
  12. <div class="meta">
  13. {{if .Website}}
  14. <span class="octicon octicon-link"></span> <a href="{{.Website}}" target="_blank">{{.Website}}</a>
  15. {{else if .Location}}
  16. <span class="octicon octicon-location"></span> {{.Location}}
  17. {{else}}
  18. <span class="octicon octicon-clock"></span> {{$.i18n.Tr "user.join_on"}} {{DateFmtShort .Created}}
  19. {{end}}
  20. </div>
  21. </li>
  22. {{end}}
  23. </ul>
  24. {{with .Page}}
  25. {{if gt .TotalPages 1}}
  26. <div class="center page buttons">
  27. <div class="ui borderless pagination menu">
  28. <a class="{{if not .HasPrevious}}disabled{{end}} item" {{if .HasPrevious}}href="{{$.Link}}?page={{.Previous}}"{{end}}>
  29. <i class="left arrow icon"></i> {{$.i18n.Tr "repo.issues.previous"}}
  30. </a>
  31. {{range .Pages}}
  32. {{if eq .Num -1}}
  33. <a class="disabled item">...</a>
  34. {{else}}
  35. <a class="{{if .IsCurrent}}active{{end}} item" {{if not .IsCurrent}}href="{{$.Link}}?page={{.Num}}"{{end}}>{{.Num}}</a>
  36. {{end}}
  37. {{end}}
  38. <a class="{{if not .HasNext}}disabled{{end}} item" {{if .HasNext}}href="{{$.Link}}?page={{.Next}}"{{end}}>
  39. {{$.i18n.Tr "repo.issues.next"}}&nbsp;<i class="icon right arrow"></i>
  40. </a>
  41. </div>
  42. </div>
  43. {{end}}
  44. {{end}}
  45. </div>