You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

list.tmpl 2.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. {{template "base/head" .}}
  2. <div role="main" aria-label="{{.Title}}" class="page-content repository issue-list">
  3. {{template "repo/header" .}}
  4. <div class="ui container">
  5. {{if .PinnedIssues}}
  6. <div id="issue-pins" {{if .IsRepoAdmin}}data-is-repo-admin{{end}}>
  7. {{range .PinnedIssues}}
  8. <div class="issue-card gt-word-break {{if $.IsRepoAdmin}}gt-cursor-grab{{end}}" data-move-url="{{$.Link}}/move_pin" data-issue-id="{{.ID}}">
  9. {{template "repo/issue/card" (dict "Issue" . "Page" $ "isPinnedIssueCard" true)}}
  10. </div>
  11. {{end}}
  12. </div>
  13. {{end}}
  14. <div class="list-header">
  15. {{template "repo/issue/navbar" .}}
  16. {{template "repo/issue/search" .}}
  17. {{if not .Repository.IsArchived}}
  18. {{if .PageIsIssueList}}
  19. <a class="ui small primary button issue-list-new" href="{{.RepoLink}}/issues/new{{if .NewIssueChooseTemplate}}/choose{{end}}">{{ctx.Locale.Tr "repo.issues.new"}}</a>
  20. {{else}}
  21. <a class="ui small primary button new-pr-button issue-list-new{{if not .PullRequestCtx.Allowed}} disabled{{end}}" href="{{if .PullRequestCtx.Allowed}}{{.Repository.Link}}/compare/{{.Repository.DefaultBranch | PathEscapeSegments}}...{{if ne .Repository.Owner.Name .PullRequestCtx.BaseRepo.Owner.Name}}{{PathEscape .Repository.Owner.Name}}:{{end}}{{.Repository.DefaultBranch | PathEscapeSegments}}{{end}}">{{ctx.Locale.Tr "repo.pulls.new"}}</a>
  22. {{end}}
  23. {{else}}
  24. {{if not .PageIsIssueList}}
  25. <a class="ui small primary small button issue-list-new{{if not .PullRequestCtx.Allowed}} disabled{{end}}" href="{{if .PullRequestCtx.Allowed}}{{.PullRequestCtx.BaseRepo.Link}}/compare/{{.PullRequestCtx.BaseRepo.DefaultBranch | PathEscapeSegments}}...{{if ne .Repository.Owner.Name .PullRequestCtx.BaseRepo.Owner.Name}}{{PathEscape .Repository.Owner.Name}}:{{end}}{{.Repository.DefaultBranch | PathEscapeSegments}}{{end}}">{{ctx.Locale.Tr "action.compare_commits_general"}}</a>
  26. {{end}}
  27. {{end}}
  28. </div>
  29. {{template "repo/issue/filters" .}}
  30. <div id="issue-actions" class="issue-list-toolbar gt-hidden">
  31. <div class="issue-list-toolbar-left">
  32. {{template "repo/issue/openclose" .}}
  33. </div>
  34. <div class="issue-list-toolbar-right">
  35. {{template "repo/issue/filter_actions" .}}
  36. </div>
  37. </div>
  38. {{template "shared/issuelist" dict "." . "listType" "repo"}}
  39. </div>
  40. </div>
  41. {{template "base/footer" .}}