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.

graph.tmpl 2.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. {{template "base/head" .}}
  2. <div role="main" aria-label="{{.Title}}" class="page-content repository commits">
  3. {{template "repo/header" .}}
  4. <div class="ui container">
  5. <div id="git-graph-container" class="ui segment{{if eq .Mode "monochrome"}} monochrome{{end}}">
  6. <h2 class="ui header dividing">
  7. {{.locale.Tr "repo.commit_graph"}}
  8. <div class="ui icon buttons tiny color-buttons">
  9. <div class="ui multiple selection search dropdown" id="flow-select-refs-dropdown">
  10. <input type="hidden" name="flow">
  11. <i class="dropdown icon"></i>
  12. <div class="default text">{{.locale.Tr "repo.commit_graph.select"}}</div>
  13. <div class="menu">
  14. <div class="item" data-value="...flow-hide-pr-refs">
  15. <span class="truncate">
  16. {{svg "octicon-eye-closed" 16 "mr-2"}}<span title="{{.locale.Tr "repo.commit_graph.hide_pr_refs"}}">{{.locale.Tr "repo.commit_graph.hide_pr_refs"}}</span>
  17. </span>
  18. </div>
  19. {{range .AllRefs}}
  20. {{$refGroup := .RefGroup}}
  21. {{if eq $refGroup "pull"}}
  22. <div class="item" data-value="{{.Name}}">
  23. <span class="truncate">
  24. {{svg "octicon-git-pull-request" 16 "mr-2"}}<span title="{{.ShortName}}">#{{.ShortName}}</span>
  25. </span>
  26. </div>
  27. {{else if eq $refGroup "tags"}}
  28. <div class="item" data-value="{{.Name}}">
  29. <span class="truncate">
  30. {{svg "octicon-tag" 16 "mr-2"}}<span title="{{.ShortName}}">{{.ShortName}}</span>
  31. </span>
  32. </div>
  33. {{else if eq $refGroup "remotes"}}
  34. <div class="item" data-value="{{.Name}}">
  35. <span class="truncate">
  36. {{svg "octicon-cross-reference" 16 "mr-2"}}<span title="{{.ShortName}}">{{.ShortName}}</span>
  37. </span>
  38. </div>
  39. {{else if eq $refGroup "heads"}}
  40. <div class="item" data-value="{{.Name}}">
  41. <span class="truncate">
  42. {{svg "octicon-git-branch" 16 "mr-2"}}<span title="{{.ShortName}}">{{.ShortName}}</span>
  43. </span>
  44. </div>
  45. {{end}}
  46. {{end}}
  47. </div>
  48. </div>
  49. <button id="flow-color-monochrome" class="ui labelled icon button{{if eq .Mode "monochrome"}} active{{end}}" title="{{.locale.Tr "repo.commit_graph.monochrome"}}">{{svg "material-invert-colors" 16 "mr-2"}}{{.locale.Tr "repo.commit_graph.monochrome"}}</button>
  50. <button id="flow-color-colored" class="ui labelled icon button{{if ne .Mode "monochrome"}} active{{end}}" title="{{.locale.Tr "repo.commit_graph.color"}}">{{svg "material-palette" 16 "mr-2"}}{{.locale.Tr "repo.commit_graph.color"}}</button>
  51. </div>
  52. </h2>
  53. <div class="ui dividing"></div>
  54. <div class="ui segment loading hide" id="loading-indicator"></div>
  55. {{template "repo/graph/svgcontainer" .}}
  56. {{template "repo/graph/commits" .}}
  57. </div>
  58. </div>
  59. </div>
  60. <div id="pagination">
  61. {{template "base/paginate" .}}
  62. </div>
  63. {{template "base/footer" .}}