Commit 8ca0b75d05b457e4335a6734582ba703404cc9c6

Authored by randx
1 parent c7cfe3d8

Tables refactored

app/assets/stylesheets/gitlab_bootstrap/tables.scss
1 table { 1 table {
  2 + @extend .table;
  3 + @extend .table-striped;
  4 + @include solid_shade;
  5 + border:1px solid #bbb;
2 width:100%; 6 width:100%;
  7 +
3 th { 8 th {
4 - padding-top: 9px;  
5 font-weight: bold; 9 font-weight: bold;
6 vertical-align: middle; 10 vertical-align: middle;
  11 + border-bottom: 1px solid #bbb;
  12 + text-shadow: 0 1px 1px #fff;
  13 + @include bg-dark-gray-gradient;
7 } 14 }
  15 +
8 th, td { 16 th, td {
9 - padding: 10px 10px 9px; 17 + padding: 8px;
10 line-height: 18px; 18 line-height: 18px;
11 text-align: left; 19 text-align: left;
12 } 20 }
13 21
14 - &.bordered-table {  
15 - border: 1px solid #DDD;  
16 - border-collapse: separate;  
17 - -webkit-border-radius: 4px;  
18 - -moz-border-radius: 4px;  
19 - border-radius: 4px;  
20 - } 22 + td {
  23 + border-color:#f1f1f1;
  24 + &:first-child {
  25 + border-left:1px solid #bbb;
  26 + }
21 27
22 - &.zebra-striped {  
23 - @extend .table-striped; 28 + &:last-child {
  29 + border-right:1px solid #bbb;
  30 + }
24 } 31 }
25 -}  
26 32
27 -table.admin-table {  
28 - @extend .table-bordered;  
29 - @extend .zebra-striped;  
30 - @include solid_shade;  
31 - th {  
32 - border-color: #CCC;  
33 - border-bottom: 1px solid #bbb;  
34 - @include bg-gray-gradient; 33 + &.bordered {
  34 + @extend .table-bordered;
35 } 35 }
36 -}  
37 36
38 -table.no-borders {  
39 - border:none;  
40 - tr, td { border:none } 37 + &.lite {
  38 + border:none;
  39 + box-shadow:none;
  40 + tr, td {
  41 + border:none;
  42 + background:none !important;
  43 + }
  44 + }
41 } 45 }
app/assets/stylesheets/sections/tree.scss
1 -#tree-holder { 1 +#tree-holder {
2 #tree-content-holder { 2 #tree-content-holder {
3 float:left; 3 float:left;
4 width:100%; 4 width:100%;
@@ -11,40 +11,44 @@ @@ -11,40 +11,44 @@
11 padding:12px; 11 padding:12px;
12 background: #F7F7F7; 12 background: #F7F7F7;
13 13
14 - pre { 14 + pre {
15 overflow: auto; 15 overflow: auto;
16 } 16 }
17 } 17 }
18 } 18 }
19 19
20 - .tree_progress { 20 + .tree_progress {
21 display:none; 21 display:none;
22 margin:20px; 22 margin:20px;
23 - &.loading { 23 + &.loading {
24 display:block; 24 display:block;
25 } 25 }
26 } 26 }
27 27
28 #tree-slider { 28 #tree-slider {
29 @include border-radius(0); 29 @include border-radius(0);
30 - .tree-item {  
31 - &:hover {  
32 - td { background: $hover; } 30 + .tree-item {
  31 + &:hover {
  32 + td {
  33 + background: $hover;
  34 + border-top:1px solid #FEA;
  35 + border-bottom:1px solid #FEA;
  36 + }
33 cursor:pointer; 37 cursor:pointer;
34 } 38 }
35 } 39 }
36 } 40 }
37 41
38 - .tree-item {  
39 - .tree-item-file-name { 42 + .tree-item {
  43 + .tree-item-file-name {
40 vertical-align:middle; 44 vertical-align:middle;
41 - a {  
42 - &:hover { 45 + a {
  46 + &:hover {
43 color:$blue_link; 47 color:$blue_link;
44 } 48 }
45 } 49 }
46 50
47 - img { 51 + img {
48 position: relative; 52 position: relative;
49 top:-1px; 53 top:-1px;
50 } 54 }
@@ -52,37 +56,19 @@ @@ -52,37 +56,19 @@
52 } 56 }
53 57
54 58
55 - #tree-slider {  
56 - @include solid_shade;  
57 - width:100%;  
58 -  
59 - border-color:#ccc;  
60 -  
61 - td {  
62 - padding:8px;  
63 - border-color:#f1f1f1; 59 + #tree-slider {
  60 + td {
64 background:#fafafa; 61 background:#fafafa;
65 } 62 }
66 -  
67 - tr:first-child td:first-child,  
68 - tr:first-child td:last-child {  
69 - border-radius:0;  
70 - }  
71 -  
72 - th {  
73 - border-color: #CCC;  
74 - border-bottom: 1px solid #bbb;  
75 - @include bg-gray-gradient;  
76 - }  
77 } 63 }
78 64
79 - .tree-commit-link { 65 + .tree-commit-link {
80 color:#333; 66 color:#333;
81 } 67 }
82 68
83 - a.tree-commit-link { 69 + a.tree-commit-link {
84 color: #666; 70 color: #666;
85 - &:hover { 71 + &:hover {
86 text-decoration: underline; 72 text-decoration: underline;
87 } 73 }
88 } 74 }
app/views/admin/hooks/index.html.haml
@@ -23,7 +23,7 @@ @@ -23,7 +23,7 @@
23 Hooks 23 Hooks
24 %small (#{@hooks.count}) 24 %small (#{@hooks.count})
25 %br 25 %br
26 - %table.admin-table 26 + %table
27 %tr 27 %tr
28 %th URL 28 %th URL
29 %th Method 29 %th Method
app/views/admin/projects/index.html.haml
@@ -6,7 +6,7 @@ @@ -6,7 +6,7 @@
6 = text_field_tag :name, params[:name], class: "xlarge" 6 = text_field_tag :name, params[:name], class: "xlarge"
7 = submit_tag "Search", class: "btn submit primary" 7 = submit_tag "Search", class: "btn submit primary"
8 8
9 -%table.admin-table 9 +%table
10 %thead 10 %thead
11 %th Name 11 %th Name
12 %th Path 12 %th Path
app/views/admin/projects/show.html.haml
@@ -3,7 +3,11 @@ @@ -3,7 +3,11 @@
3 = link_to 'Edit', edit_admin_project_path(@admin_project), class: "btn right small" 3 = link_to 'Edit', edit_admin_project_path(@admin_project), class: "btn right small"
4 4
5 %br 5 %br
6 -%table.zebra-striped.table-bordered 6 +%table.zebra-striped
  7 + %thead
  8 + %tr
  9 + %th Project
  10 + %th
7 %tr 11 %tr
8 %td 12 %td
9 %b 13 %b
@@ -40,7 +44,7 @@ @@ -40,7 +44,7 @@
40 %small 44 %small
41 (#{@admin_project.users_projects.count}) 45 (#{@admin_project.users_projects.count})
42 %br 46 %br
43 -%table.zebra-striped.table-bordered 47 +%table.zebra-striped
44 %thead 48 %thead
45 %tr 49 %tr
46 %th Name 50 %th Name
@@ -60,7 +64,7 @@ @@ -60,7 +64,7 @@
60 %h3 Add new team member 64 %h3 Add new team member
61 %br 65 %br
62 = form_tag team_update_admin_project_path(@admin_project), class: "bulk_import", method: :put do 66 = form_tag team_update_admin_project_path(@admin_project), class: "bulk_import", method: :put do
63 - %table.zebra-striped.table-bordered 67 + %table.zebra-striped
64 %thead 68 %thead
65 %tr 69 %tr
66 %th Users 70 %th Users
app/views/admin/users/index.html.haml
@@ -19,7 +19,7 @@ @@ -19,7 +19,7 @@
19 = link_to admin_users_path(filter: "wop") do 19 = link_to admin_users_path(filter: "wop") do
20 Without projects 20 Without projects
21 21
22 -%table.admin-table 22 +%table
23 %thead 23 %thead
24 %th Admin 24 %th Admin
25 %th Name 25 %th Name
app/views/admin/users/show.html.haml
@@ -8,7 +8,11 @@ @@ -8,7 +8,11 @@
8 8
9 %br 9 %br
10 10
11 -%table.zebra-striped.table-bordered 11 +%table.zebra-striped
  12 + %thead
  13 + %tr
  14 + %th Profile
  15 + %th
12 %tr 16 %tr
13 %td 17 %td
14 %b 18 %b
@@ -57,7 +61,7 @@ @@ -57,7 +61,7 @@
57 %h3 Add User to Projects 61 %h3 Add User to Projects
58 %br 62 %br
59 = form_tag team_update_admin_user_path(@admin_user), class: "bulk_import", method: :put do 63 = form_tag team_update_admin_user_path(@admin_user), class: "bulk_import", method: :put do
60 - %table.table-bordered 64 + %table
61 %thead 65 %thead
62 %tr 66 %tr
63 %th Projects 67 %th Projects
@@ -78,9 +82,9 @@ @@ -78,9 +82,9 @@
78 %h3 Projects 82 %h3 Projects
79 %br 83 %br
80 84
81 - %table.zebra-striped.table-bordered  
82 - %tr  
83 - %thead 85 + %table.zebra-striped
  86 + %thead
  87 + %tr
84 %th Name 88 %th Name
85 %th Project Access 89 %th Project Access
86 %th 90 %th
app/views/hooks/index.html.haml
@@ -26,11 +26,12 @@ @@ -26,11 +26,12 @@
26 Hooks 26 Hooks
27 %small (#{@hooks.count}) 27 %small (#{@hooks.count})
28 %br 28 %br
29 - %table.admin-table  
30 - %tr  
31 - %th URL  
32 - %th Method  
33 - %th 29 + %table
  30 + %thead
  31 + %tr
  32 + %th URL
  33 + %th Method
  34 + %th
34 - @hooks.each do |hook| 35 - @hooks.each do |hook|
35 %tr 36 %tr
36 %td 37 %td
app/views/keys/index.html.haml
@@ -7,7 +7,7 @@ @@ -7,7 +7,7 @@
7 SSH key allows you to establish a secure connection between your computer and Gitlab 7 SSH key allows you to establish a secure connection between your computer and Gitlab
8 8
9 9
10 -%table#keys-table.admin-table 10 +%table#keys-table
11 %thead 11 %thead
12 %tr 12 %tr
13 %th Name 13 %th Name
app/views/milestones/show.html.haml
@@ -42,7 +42,7 @@ @@ -42,7 +42,7 @@
42 42
43 .row 43 .row
44 .span6 44 .span6
45 - %table.admin-table 45 + %table
46 %thead 46 %thead
47 %th Open Issues 47 %th Open Issues
48 - @issues.each do |issue| 48 - @issues.each do |issue|
@@ -56,7 +56,7 @@ @@ -56,7 +56,7 @@
56 = paginate @issues, theme: "gitlab" 56 = paginate @issues, theme: "gitlab"
57 57
58 .span6 58 .span6
59 - %table.admin-table 59 + %table
60 %thead 60 %thead
61 %th Participants 61 %th Participants
62 - @users.each do |user| 62 - @users.each do |user|
app/views/projects/_team.html.haml
1 -%table.admin-table 1 +%table
2 %thead 2 %thead
3 %tr 3 %tr
4 %th User 4 %th User
app/views/projects/files.html.haml
1 = render "project_head" 1 = render "project_head"
2 - unless @notes.empty? 2 - unless @notes.empty?
3 - %table.zebra-striped.borders 3 + %table
  4 + %thead
  5 + %tr
  6 + %th File name
  7 + %th
  8 +
4 - @notes.each do |note| 9 - @notes.each do |note|
5 %tr 10 %tr
6 %td 11 %td
app/views/protected_branches/index.html.haml
@@ -24,7 +24,7 @@ @@ -24,7 +24,7 @@
24 = f.submit 'Protect', class: "primary btn" 24 = f.submit 'Protect', class: "primary btn"
25 25
26 - unless @branches.empty? 26 - unless @branches.empty?
27 - %table.admin-table 27 + %table
28 %thead 28 %thead
29 %tr 29 %tr
30 %th Name 30 %th Name
app/views/refs/_tree.html.haml
@@ -13,7 +13,7 @@ @@ -13,7 +13,7 @@
13 = render partial: "refs/tree_file", locals: { name: tree.name, content: tree.data, file: tree } 13 = render partial: "refs/tree_file", locals: { name: tree.name, content: tree.data, file: tree }
14 - else 14 - else
15 - contents = tree.contents 15 - contents = tree.contents
16 - %table#tree-slider.bordered-table.table{class: "table_#{@hex_path}" } 16 + %table#tree-slider{class: "table_#{@hex_path}" }
17 %thead 17 %thead
18 %th Name 18 %th Name
19 %th Last Update 19 %th Last Update
app/views/repositories/branches.html.haml
1 = render "repositories/branches_head" 1 = render "repositories/branches_head"
2 - unless @branches.empty? 2 - unless @branches.empty?
3 - %table.admin-table 3 + %table
4 %thead 4 %thead
5 %tr 5 %tr
6 %th Name 6 %th Name
app/views/repositories/show.html.haml
1 = render "branches_head" 1 = render "branches_head"
2 2
3 -%table.admin-table 3 +%table
4 %thead 4 %thead
5 %tr 5 %tr
6 %th Name 6 %th Name
app/views/repositories/tags.html.haml
1 = render "commits/head" 1 = render "commits/head"
2 - unless @tags.empty? 2 - unless @tags.empty?
3 - %table.admin-table 3 + %table
4 %thead 4 %thead
5 %tr 5 %tr
6 %th Name 6 %th Name
app/views/search/show.html.haml
@@ -14,7 +14,7 @@ @@ -14,7 +14,7 @@
14 .search_results 14 .search_results
15 .row 15 .row
16 .span6 16 .span6
17 - %table.admin-table 17 + %table
18 %tr 18 %tr
19 %th Projects 19 %th Projects
20 %tbody 20 %tbody
@@ -31,7 +31,7 @@ @@ -31,7 +31,7 @@
31 %td 31 %td
32 %h4.nothing_here_message No Projects 32 %h4.nothing_here_message No Projects
33 %br 33 %br
34 - %table.admin-table 34 + %table
35 %tr 35 %tr
36 %th Merge Requests 36 %th Merge Requests
37 %tbody 37 %tbody
@@ -49,7 +49,7 @@ @@ -49,7 +49,7 @@
49 %td 49 %td
50 %h4.nothing_here_message No Merge Requests 50 %h4.nothing_here_message No Merge Requests
51 .span6 51 .span6
52 - %table.admin-table 52 + %table
53 %tr 53 %tr
54 %th Issues 54 %th Issues
55 %tbody 55 %tbody
app/views/snippets/index.html.haml
@@ -8,7 +8,7 @@ @@ -8,7 +8,7 @@
8 %br 8 %br
9 To add new snippet - click on button. 9 To add new snippet - click on button.
10 10
11 -%table.admin-table 11 +%table
12 %thead 12 %thead
13 %tr 13 %tr
14 %th Title 14 %th Title
app/views/team_members/show.html.haml
@@ -19,7 +19,7 @@ @@ -19,7 +19,7 @@
19 %br 19 %br
20 .row 20 .row
21 .span6 21 .span6
22 - %table.no-borders 22 + %table.lite
23 %tr 23 %tr
24 %td Email 24 %td Email
25 %td= mail_to user.email 25 %td= mail_to user.email
@@ -39,7 +39,7 @@ @@ -39,7 +39,7 @@
39 %td Bio 39 %td Bio
40 %td= user.bio 40 %td= user.bio
41 .span6 41 .span6
42 - %table.no-borders 42 + %table.lite
43 %tr 43 %tr
44 %td Member since 44 %td Member since
45 %td= @team_member.created_at.stamp("Aug 21, 2011") 45 %td= @team_member.created_at.stamp("Aug 21, 2011")
app/views/wikis/history.html.haml
@@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
2 %span.cgray History for 2 %span.cgray History for
3 = @wikis.last.title 3 = @wikis.last.title
4 %br 4 %br
5 -%table.admin-table 5 +%table
6 %thead 6 %thead
7 %tr 7 %tr
8 %th # 8 %th #
app/views/wikis/pages.html.haml
1 %h3.page_title All Pages 1 %h3.page_title All Pages
2 %br 2 %br
3 -%table.admin-table 3 +%table
4 %thead 4 %thead
5 %tr 5 %tr
6 %th Title 6 %th Title