Commit 283f9633 authored by tauriedavis's avatar tauriedavis Committed by Fatih Acet

fix dropdowns for mr-versions

parent a41df736
...@@ -10,23 +10,25 @@ ...@@ -10,23 +10,25 @@
- else - else
version #{version_index(@merge_request_diff)} version #{version_index(@merge_request_diff)}
%span.caret %span.caret
%ul.dropdown-menu.dropdown-menu-selectable .dropdown-menu.dropdown-select.dropdown-menu-selectable
.dropdown-title .dropdown-title
%span Version %span Version:
%button.dropdown-title-button.dropdown-menu-close %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}}
= icon('times', class: 'dropdown-menu-close-icon') = icon('times', class: 'dropdown-menu-close-icon')
- @merge_request_diffs.each do |merge_request_diff| .dropdown-content
%li %ul
= link_to merge_request_version_path(@project, @merge_request, merge_request_diff), class: ('is-active' if merge_request_diff == @merge_request_diff) do - @merge_request_diffs.each do |merge_request_diff|
%strong %li
- if merge_request_diff.latest? = link_to merge_request_version_path(@project, @merge_request, merge_request_diff), class: ('is-active' if merge_request_diff == @merge_request_diff) do
latest version %strong
- else - if merge_request_diff.latest?
version #{version_index(merge_request_diff)} latest version
.monospace #{short_sha(merge_request_diff.head_commit_sha)} - else
%small version #{version_index(merge_request_diff)}
#{number_with_delimiter(merge_request_diff.commits.count)} #{'commit'.pluralize(merge_request_diff.commits.count)}, .monospace #{short_sha(merge_request_diff.head_commit_sha)}
= time_ago_with_tooltip(merge_request_diff.created_at) %small
#{number_with_delimiter(merge_request_diff.commits.count)} #{'commit'.pluralize(merge_request_diff.commits.count)},
= time_ago_with_tooltip(merge_request_diff.created_at)
- if @merge_request_diff.base_commit_sha - if @merge_request_diff.base_commit_sha
and and
...@@ -38,27 +40,29 @@ ...@@ -38,27 +40,29 @@
- else - else
#{@merge_request.target_branch} #{@merge_request.target_branch}
%span.caret %span.caret
%ul.dropdown-menu.dropdown-menu-selectable .dropdown-menu.dropdown-select.dropdown-menu-selectable
.dropdown-title .dropdown-title
%span Compared with %span Compared with:
%button.dropdown-title-button.dropdown-menu-close %button.dropdown-title-button.dropdown-menu-close{aria: {label: "Close"}}
= icon('times', class: 'dropdown-menu-close-icon') = icon('times', class: 'dropdown-menu-close-icon')
- @comparable_diffs.each do |merge_request_diff| .dropdown-content
%li %ul
= link_to merge_request_version_path(@project, @merge_request, @merge_request_diff, merge_request_diff.head_commit_sha), class: ('is-active' if merge_request_diff == @start_version) do - @comparable_diffs.each do |merge_request_diff|
%strong %li
- if merge_request_diff.latest? = link_to merge_request_version_path(@project, @merge_request, @merge_request_diff, merge_request_diff.head_commit_sha), class: ('is-active' if merge_request_diff == @start_version) do
latest version %strong
- else - if merge_request_diff.latest?
version #{version_index(merge_request_diff)} latest version
.monospace #{short_sha(merge_request_diff.head_commit_sha)} - else
%small version #{version_index(merge_request_diff)}
= time_ago_with_tooltip(merge_request_diff.created_at) .monospace #{short_sha(merge_request_diff.head_commit_sha)}
%li %small
= link_to merge_request_version_path(@project, @merge_request, @merge_request_diff), class: ('is-active' unless @start_sha) do = time_ago_with_tooltip(merge_request_diff.created_at)
%strong %li
#{@merge_request.target_branch} (base) = link_to merge_request_version_path(@project, @merge_request, @merge_request_diff), class: ('is-active' unless @start_sha) do
.monospace #{short_sha(@merge_request_diff.base_commit_sha)} %strong
#{@merge_request.target_branch} (base)
.monospace #{short_sha(@merge_request_diff.base_commit_sha)}
- unless @merge_request_diff.latest? && !@start_sha - unless @merge_request_diff.latest? && !@start_sha
.comments-disabled-notif.content-block .comments-disabled-notif.content-block
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment