gitea源码

recently_pushed_new_branches.tmpl 705B

12345678910111213141516171819
  1. {{/* Template Attributes:
  2. * RecentBranchesPromptData
  3. */}}
  4. {{$data := .RecentBranchesPromptData}}
  5. {{if $data}}
  6. {{range $recentBranch := $data.RecentlyPushedNewBranches}}
  7. <div class="ui positive message flex-text-block">
  8. <div class="tw-flex-1">
  9. {{$timeSince := DateUtils.TimeSince $recentBranch.CommitTime}}
  10. {{$branchLink := HTMLFormat `<a href="%s">%s</a>` $recentBranch.BranchLink .BranchDisplayName}}
  11. {{ctx.Locale.Tr "repo.pulls.recently_pushed_new_branches" $branchLink $timeSince}}
  12. </div>
  13. <a role="button" class="ui compact green button" href="{{QueryBuild $recentBranch.BranchCompareURL "expand" 1}}">
  14. {{ctx.Locale.Tr "repo.pulls.compare_changes"}}
  15. </a>
  16. </div>
  17. {{end}}
  18. {{end}}