summaryrefslogtreecommitdiff
path: root/app/views/projects/commits/_commits.html.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/projects/commits/_commits.html.haml')
-rw-r--r--app/views/projects/commits/_commits.html.haml11
1 files changed, 7 insertions, 4 deletions
diff --git a/app/views/projects/commits/_commits.html.haml b/app/views/projects/commits/_commits.html.haml
index 88c7d7bc44b..c764e35dd2a 100644
--- a/app/views/projects/commits/_commits.html.haml
+++ b/app/views/projects/commits/_commits.html.haml
@@ -2,11 +2,14 @@
- commits, hidden = limited_commits(@commits)
- commits.chunk { |c| c.committed_date.in_time_zone.to_date }.each do |day, commits|
- %li.commit-header #{day.strftime('%d %b, %Y')} #{pluralize(commits.count, 'commit')}
- %li.commits-row
+ %li.commit-header.js-commit-header{ data: { day: day } }
+ %span.day= l(day, format: '%d %b, %Y')
+ %span.commits-count= n_("%d commit", "%d commits", commits.count) % commits.count
+
+ %li.commits-row{ data: { day: day } }
%ul.content-list.commit-list
- = render commits, project: project, ref: ref
+ = render partial: 'projects/commits/commit', collection: commits, locals: { project: project, ref: ref }
- if hidden > 0
%li.alert.alert-warning
- #{number_with_delimiter(hidden)} additional commits have been omitted to prevent performance issues.
+ = n_('%s additional commit has been omitted to prevent performance issues.', '%s additional commits have been omitted to prevent performance issues.', hidden) % number_with_delimiter(hidden)