Commit a1408948 authored by Jacob Schatz's avatar Jacob Schatz

Styles for file list change.

New download btn WIP.
parent 9ae820ad
...@@ -191,3 +191,7 @@ ...@@ -191,3 +191,7 @@
@include btn-green @include btn-green
} }
} }
.btn-icon {
}
\ No newline at end of file
...@@ -14,9 +14,15 @@ ...@@ -14,9 +14,15 @@
.tree-table { .tree-table {
margin-bottom: 0; margin-bottom: 0;
tr:nth-child(odd) {
background-color: #F7F9FB;
}
tr { tr {
> td, > th { > td, > th {
line-height: 26px; line-height: 26px;
border-top: 1px solid #EEF0F2;
border-bottom: 1px solid #EEF0F2;
} }
&:hover { &:hover {
......
- ref = ref || nil - ref = ref || nil
- btn_class = btn_class || '' - btn_class = btn_class || ''
- split_button = split_button || false
- if split_button == true .btn-group
%span.btn-group{class: btn_class} %button.btn.dropdown-toggle{ 'data-toggle' => 'dropdown', class: btn_class }
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn col-xs-10', rel: 'nofollow' do =icon('download')
%i.fa.fa-download Download
%span Download zip %span.caret
%a.col-xs-2.btn.dropdown-toggle{ 'data-toggle' => 'dropdown' } %span.sr-only
%span.caret Select Archive Format
%span.sr-only %ul.col-xs-10.dropdown-menu{ role: 'menu' }
Select Archive Format %li
%ul.col-xs-10.dropdown-menu{ role: 'menu' } = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), rel: 'nofollow' do
%li %i.fa.fa-download
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), rel: 'nofollow' do %span Download zip
%i.fa.fa-download %li
%span Download zip = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.gz'), rel: 'nofollow' do
%li %i.fa.fa-download
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.gz'), rel: 'nofollow' do %span Download tar.gz
%i.fa.fa-download %li
%span Download tar.gz = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.bz2'), rel: 'nofollow' do
%li %i.fa.fa-download
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.bz2'), rel: 'nofollow' do %span Download tar.bz2
%i.fa.fa-download %li
%span Download tar.bz2 = link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar'), rel: 'nofollow' do
%li %i.fa.fa-download
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar'), rel: 'nofollow' do %span Download tar
%i.fa.fa-download \ No newline at end of file
%span Download tar
- else
%span.btn-group{class: btn_class}
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'zip'), class: 'btn', rel: 'nofollow' do
%i.fa.fa-download
%span zip
= link_to archive_namespace_project_repository_path(@project.namespace, @project, ref: ref, format: 'tar.gz'), class: 'btn', rel: 'nofollow' do
%i.fa.fa-download
%span tar.gz
...@@ -6,9 +6,8 @@ ...@@ -6,9 +6,8 @@
= render 'projects/last_push' = render 'projects/last_push'
.tree-controls .tree-controls
= render 'projects/find_file_link'
- if can? current_user, :download_code, @project - if can? current_user, :download_code, @project
= render 'projects/repositories/download_archive', ref: @ref, btn_class: 'hidden-xs hidden-sm btn-grouped', split_button: true = render 'projects/repositories/download_archive', ref: @ref, btn_class: 'hidden-xs hidden-sm btn-grouped btn-success'
#tree-holder.tree-holder.clearfix #tree-holder.tree-holder.clearfix
.nav-block .nav-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