Commit dab18246 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Align project download button with others in sidebar on project home page

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 0c6217e2
......@@ -220,6 +220,10 @@ ul.nav.nav-projects-tabs {
background-color: #F9F9F9;
border-color: #DDD;
&.dropdown-toggle {
text-align: center;
}
&:hover {
background-color: #eee;
border-color: #DDD;
......
......@@ -3,14 +3,14 @@
- split_button = split_button || false
- if split_button == true
%span.btn-group{class: btn_class}
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn btn-sm', rel: 'nofollow' do
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn col-xs-10', rel: 'nofollow' do
%i.fa.fa-download
%span Download zip
%a.btn-sm.btn.dropdown-toggle{ 'data-toggle' => 'dropdown' }
%a.col-xs-2.btn.dropdown-toggle{ 'data-toggle' => 'dropdown' }
%span.caret
%span.sr-only
Select Archive Format
%ul.dropdown-menu{ role: 'menu' }
%ul.col-xs-10.dropdown-menu{ role: 'menu' }
%li
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), rel: 'nofollow' do
%i.fa.fa-download
......
......@@ -60,11 +60,16 @@
- unless @project.empty_repo?
= link_to namespace_project_compare_index_path(@project.namespace, @project, from: @repository.root_ref, to: @ref || @repository.root_ref), class: 'btn btn-block' do
%i.fa.fa-exchange
Compare code
- if can?(current_user, :download_code, @project)
= render 'projects/repositories/download_archive', split_button: true, btn_class: 'btn-block'
- if version = @repository.version
- detail_url = changelog_url(@project) || version_url(@project)
= link_to detail_url, class: 'btn btn-block' do
%i.fa.fa-file-text-o
Version:
%span.count
= @repository.blob_by_oid(version.id).data
......@@ -80,11 +85,6 @@
- else
#{link_to @project.owner_name, @project.owner}
- unless @project.empty_repo?
- if can? current_user, :download_code, @project
%hr
.prepend-top-10.append-bottom-10
= render 'projects/repositories/download_archive', split_button: true
.prepend-top-10
- @project.ci_services.each do |ci_service|
......
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