refactor buttons pt2

This commit is contained in:
Dmitriy Zaporozhets 2013-01-29 22:29:21 +02:00
parent 033aa1a885
commit fb617c61b9
49 changed files with 90 additions and 90 deletions

View file

@ -92,7 +92,7 @@
background-color: #ccc; background-color: #ccc;
} }
&.very_small { &.btn-tiny {
font-size: 11px; font-size: 11px;
padding: 2px 6px; padding: 2px 6px;
line-height: 16px; line-height: 16px;

View file

@ -215,10 +215,10 @@ ul.notes {
*/ */
.comment-btn { .comment-btn {
@extend .create-btn; @extend .btn-create;
} }
.reply-btn { .reply-btn {
@extend .primary; @extend .btn-primary;
} }
.file .content tr.line_holder:hover > td { background: $hover !important; } .file .content tr.line_holder:hover > td { background: $hover !important; }
.file .content tr.line_holder:hover > td .line_note_link { .file .content tr.line_holder:hover > td .line_note_link {

View file

@ -6,7 +6,7 @@
= link_to admin_projects_path do = link_to admin_projects_path do
%h1= Project.count %h1= Project.count
%hr %hr
= link_to 'New Project', new_project_path, class: "btn small" = link_to 'New Project', new_project_path, class: "btn btn-small"
.span4 .span4
.ui-box .ui-box
%h5.title Groups %h5.title Groups
@ -14,7 +14,7 @@
= link_to admin_groups_path do = link_to admin_groups_path do
%h1= Group.count %h1= Group.count
%hr %hr
= link_to 'New Group', new_admin_group_path, class: "btn small" = link_to 'New Group', new_admin_group_path, class: "btn btn-small"
.span4 .span4
.ui-box .ui-box
%h5.title Users %h5.title Users
@ -22,7 +22,7 @@
= link_to admin_users_path do = link_to admin_users_path do
%h1= User.count %h1= User.count
%hr %hr
= link_to 'New User', new_admin_user_path, class: "btn small" = link_to 'New User', new_admin_user_path, class: "btn btn-small"
.row .row
.span4 .span4

View file

@ -4,7 +4,7 @@
allows you to keep projects organized. allows you to keep projects organized.
Use groups for uniting related projects. Use groups for uniting related projects.
= link_to 'New Group', new_admin_group_path, class: "btn small right" = link_to 'New Group', new_admin_group_path, class: "btn btn-small right"
%br %br
= form_tag admin_groups_path, method: :get, class: 'form-inline' do = form_tag admin_groups_path, method: :get, class: 'form-inline' do
= text_field_tag :name, params[:name], class: "xlarge" = text_field_tag :name, params[:name], class: "xlarge"
@ -30,6 +30,6 @@
%td %td
= link_to group.owner_name, admin_user_path(group.owner_id) = link_to group.owner_name, admin_user_path(group.owner_id)
%td.bgred %td.bgred
= link_to 'Rename', edit_admin_group_path(group), id: "edit_#{dom_id(group)}", class: "btn small" = link_to 'Rename', edit_admin_group_path(group), id: "edit_#{dom_id(group)}", class: "btn btn-small"
= link_to 'Destroy', [:admin, group], confirm: "REMOVE #{group.name}? Are you sure?", method: :delete, class: "btn small btn-remove" = link_to 'Destroy', [:admin, group], confirm: "REMOVE #{group.name}? Are you sure?", method: :delete, class: "btn btn-small btn-remove"
= paginate @groups, theme: "admin" = paginate @groups, theme: "admin"

View file

@ -33,7 +33,7 @@
%td %td
= link_to admin_hook_path(hook) do = link_to admin_hook_path(hook) do
%strong= hook.url %strong= hook.url
= link_to 'Test Hook', admin_hook_test_path(hook), class: "btn small right" = link_to 'Test Hook', admin_hook_test_path(hook), class: "btn btn-small right"
%td POST %td POST
%td %td
= link_to 'Remove', admin_hook_path(hook), confirm: 'Are you sure?', method: :delete, class: "danger btn small right" = link_to 'Remove', admin_hook_path(hook), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove btn-small right"

View file

@ -1,6 +1,6 @@
%h3.page_title %h3.page_title
Projects Projects
= link_to 'New Project', new_project_path, class: "btn small right" = link_to 'New Project', new_project_path, class: "btn btn-small right"
%hr %hr
@ -52,8 +52,8 @@
%i.icon-lock.cgreen %i.icon-lock.cgreen
= link_to project.name_with_namespace, [:admin, project] = link_to project.name_with_namespace, [:admin, project]
.right .right
= link_to 'Edit', edit_admin_project_path(project), id: "edit_#{dom_id(project)}", class: "btn small" = link_to 'Edit', edit_admin_project_path(project), id: "edit_#{dom_id(project)}", class: "btn btn-small"
= link_to 'Destroy', [:admin, project], confirm: "REMOVE #{project.name}? Are you sure?", method: :delete, class: "btn small btn-remove" = link_to 'Destroy', [:admin, project], confirm: "REMOVE #{project.name}? Are you sure?", method: :delete, class: "btn btn-small btn-remove"
- if @projects.blank? - if @projects.blank?
%p.nothing_here_message 0 projects matches %p.nothing_here_message 0 projects matches
- else - else

View file

@ -129,7 +129,7 @@
%td %td
= link_to tm.name, admin_user_path(tm) = link_to tm.name, admin_user_path(tm)
%td= @project.project_access_human(tm) %td= @project.project_access_human(tm)
%td= link_to 'Edit Access', edit_admin_project_member_path(@project, tm), class: "btn small" %td= link_to 'Edit Access', edit_admin_project_member_path(@project, tm), class: "btn btn-small"
%td= link_to 'Remove from team', admin_project_member_path(@project, tm), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove small" %td= link_to 'Remove from team', admin_project_member_path(@project, tm), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove small"
%br %br

View file

@ -3,7 +3,7 @@
%small %small
simple Teams description simple Teams description
= link_to 'New Team', new_admin_team_path, class: "btn small right" = link_to 'New Team', new_admin_team_path, class: "btn btn-small right"
%br %br
= form_tag admin_teams_path, method: :get, class: 'form-inline' do = form_tag admin_teams_path, method: :get, class: 'form-inline' do
@ -32,7 +32,7 @@
%td %td
= link_to team.owner.name, admin_user_path(team.owner_id) = link_to team.owner.name, admin_user_path(team.owner_id)
%td.bgred %td.bgred
= link_to 'Rename', edit_admin_team_path(team), id: "edit_#{dom_id(team)}", class: "btn small" = link_to 'Rename', edit_admin_team_path(team), id: "edit_#{dom_id(team)}", class: "btn btn-small"
= link_to 'Destroy', admin_team_path(team), confirm: "REMOVE #{team.name}? Are you sure?", method: :delete, class: "btn small btn-remove" = link_to 'Destroy', admin_team_path(team), confirm: "REMOVE #{team.name}? Are you sure?", method: :delete, class: "btn btn-small btn-remove"
= paginate @teams, theme: "admin" = paginate @teams, theme: "admin"

View file

@ -42,7 +42,7 @@
%fieldset %fieldset
%legend %legend
Members (#{@team.members.count}) Members (#{@team.members.count})
%span= link_to 'Add members', new_admin_team_member_path(@team), class: "btn btn-primary small right", id: :add_members_to_team %span= link_to 'Add members', new_admin_team_member_path(@team), class: "btn btn-primary btn-small right", id: :add_members_to_team
- if @team.members.any? - if @team.members.any?
%table#members_list %table#members_list
%thead %thead
@ -60,14 +60,14 @@
%td= @team.human_default_projects_access(member) %td= @team.human_default_projects_access(member)
%td= @team.admin?(member) ? "Admin" : "Member" %td= @team.admin?(member) ? "Admin" : "Member"
%td.bgred %td.bgred
= link_to 'Edit', edit_admin_team_member_path(@team, member), class: "btn small" = link_to 'Edit', edit_admin_team_member_path(@team, member), class: "btn btn-small"
   
= link_to 'Remove', admin_team_member_path(@team, member), confirm: 'Remove member from team. Are you sure?', method: :delete, class: "btn btn-remove small", id: "remove_member_#{member.id}" = link_to 'Remove', admin_team_member_path(@team, member), confirm: 'Remove member from team. Are you sure?', method: :delete, class: "btn btn-remove btn-small", id: "remove_member_#{member.id}"
%fieldset %fieldset
%legend %legend
Projects (#{@team.projects.count}) Projects (#{@team.projects.count})
%span= link_to 'Add projects', new_admin_team_project_path(@team), class: "btn btn-primary small right", id: :assign_projects_to_team %span= link_to 'Add projects', new_admin_team_project_path(@team), class: "btn btn-primary btn-small right", id: :assign_projects_to_team
- if @team.projects.any? - if @team.projects.any?
%table#projects_list %table#projects_list
%thead %thead
@ -82,7 +82,7 @@
%td %td
%span= @team.human_max_project_access(project) %span= @team.human_max_project_access(project)
%td.bgred %td.bgred
= link_to 'Edit', edit_admin_team_project_path(@team, project), class: "btn small" = link_to 'Edit', edit_admin_team_project_path(@team, project), class: "btn btn-small"
   
= link_to 'Relegate', admin_team_project_path(@team, project), confirm: 'Remove project from team. Are you sure?', method: :delete, class: "btn btn-remove small", id: "relegate_project_#{project.id}" = link_to 'Relegate', admin_team_project_path(@team, project), confirm: 'Remove project from team. Are you sure?', method: :delete, class: "btn btn-remove small", id: "relegate_project_#{project.id}"

View file

@ -63,10 +63,10 @@
.alert.alert-error .alert.alert-error
- if @admin_user.blocked - if @admin_user.blocked
%p This user is blocked and is not able to login to GitLab %p This user is blocked and is not able to login to GitLab
= link_to 'Unblock User', unblock_admin_user_path(@admin_user), method: :put, class: "btn small" = link_to 'Unblock User', unblock_admin_user_path(@admin_user), method: :put, class: "btn btn-small"
- else - else
%p Blocked users will be removed from all projects & will not be able to login to GitLab. %p Blocked users will be removed from all projects & will not be able to login to GitLab.
= link_to 'Block User', block_admin_user_path(@admin_user), confirm: 'USER WILL BE BLOCKED! Are you sure?', method: :put, class: "btn small btn-remove" = link_to 'Block User', block_admin_user_path(@admin_user), confirm: 'USER WILL BE BLOCKED! Are you sure?', method: :put, class: "btn btn-small btn-remove"
%fieldset %fieldset
%legend Profile %legend Profile
.clearfix .clearfix

View file

@ -1,6 +1,6 @@
%h3.page_title %h3.page_title
Users Users
= link_to 'New User', new_admin_user_path, class: "btn small right" = link_to 'New User', new_admin_user_path, class: "btn btn-small right"
%br %br
= form_tag admin_users_path, method: :get, class: 'form-inline' do = form_tag admin_users_path, method: :get, class: 'form-inline' do
@ -44,15 +44,15 @@
%td= user.username %td= user.username
%td= user.email %td= user.email
%td= user.users_projects.count %td= user.users_projects.count
%td= link_to 'Edit', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: "btn small" %td= link_to 'Edit', edit_admin_user_path(user), id: "edit_#{dom_id(user)}", class: "btn btn-small"
%td.bgred %td.bgred
- if user == current_user - if user == current_user
%span.cred It's you! %span.cred It's you!
- else - else
- if user.blocked - if user.blocked
= link_to 'Unblock', unblock_admin_user_path(user), method: :put, class: "btn small success" = link_to 'Unblock', unblock_admin_user_path(user), method: :put, class: "btn btn-small success"
- else - else
= link_to 'Block', block_admin_user_path(user), confirm: 'USER WILL BE BLOCKED! Are you sure?', method: :put, class: "btn small btn-remove" = link_to 'Block', block_admin_user_path(user), confirm: 'USER WILL BE BLOCKED! Are you sure?', method: :put, class: "btn btn-small btn-remove"
= link_to 'Destroy', [:admin, user], confirm: "USER #{user.name} WILL BE REMOVED! Are you sure?", method: :delete, class: "btn small btn-remove" = link_to 'Destroy', [:admin, user], confirm: "USER #{user.name} WILL BE REMOVED! Are you sure?", method: :delete, class: "btn btn-small btn-remove"
= paginate @admin_users, theme: "admin" = paginate @admin_users, theme: "admin"

View file

@ -123,5 +123,5 @@
%tr %tr
%td= link_to project.name_with_namespace, admin_project_path(project) %td= link_to project.name_with_namespace, admin_project_path(project)
%td= tm.project_access_human %td= tm.project_access_human
%td= link_to 'Edit Access', edit_admin_project_member_path(project, tm.user), class: "btn small" %td= link_to 'Edit Access', edit_admin_project_member_path(project, tm.user), class: "btn btn-small"
%td= link_to 'Remove from team', admin_project_member_path(project, tm.user), confirm: 'Are you sure?', method: :delete, class: "btn small btn-remove" %td= link_to 'Remove from team', admin_project_member_path(project, tm.user), confirm: 'Are you sure?', method: :delete, class: "btn btn-small btn-remove"

View file

@ -33,7 +33,7 @@
- if diff.a_mode && diff.b_mode && diff.a_mode != diff.b_mode - if diff.a_mode && diff.b_mode && diff.a_mode != diff.b_mode
%span.file-mode= "#{diff.a_mode} → #{diff.b_mode}" %span.file-mode= "#{diff.a_mode} → #{diff.b_mode}"
= link_to project_tree_path(@project, tree_join(@commit.id, diff.new_path)), {:class => 'btn very_small right view-file'} do = link_to project_tree_path(@project, tree_join(@commit.id, diff.new_path)), {:class => 'btn btn-tiny right view-file'} do
View file @ View file @
%span.commit-short-id= @commit.short_id(6) %span.commit-short-id= @commit.short_id(6)

View file

@ -5,7 +5,7 @@
(#{groups.count}) (#{groups.count})
- if current_user.can_create_group? - if current_user.can_create_group?
%span.right %span.right
= link_to new_group_path, class: "btn very_small info" do = link_to new_group_path, class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
New Group New Group
%ul.well-list %ul.well-list

View file

@ -5,7 +5,7 @@
(#{@projects_count}) (#{@projects_count})
- if current_user.can_create_project? - if current_user.can_create_project?
%span.right %span.right
= link_to new_project_path, class: "btn very_small info" do = link_to new_project_path, class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
New Project New Project

View file

@ -4,7 +4,7 @@
%small %small
(#{@teams.count}) (#{@teams.count})
%span.right %span.right
= link_to new_team_path, class: "btn very_small info" do = link_to new_team_path, class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
New Team New Team
%ul.well-list %ul.well-list

View file

@ -4,7 +4,7 @@
(#{@projects.total_count}) (#{@projects.total_count})
- if current_user.can_create_project? - if current_user.can_create_project?
%span.right %span.right
= link_to new_project_path, class: "btn very_small info" do = link_to new_project_path, class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
New Project New Project

View file

@ -8,5 +8,5 @@
= time_ago_in_words(key.created_at) = time_ago_in_words(key.created_at)
ago ago
%td %td
= link_to 'Remove', project_deploy_key_path(key.project, key), confirm: 'Are you sure?', method: :delete, class: "danger btn delete-key small right" = link_to 'Remove', project_deploy_key_path(key.project, key), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove delete-key btn-small right"

View file

@ -4,7 +4,7 @@
Deploy keys allow read-only access to repository. It matches perfectly for CI, staging or production servers. Deploy keys allow read-only access to repository. It matches perfectly for CI, staging or production servers.
- if can? current_user, :admin_project, @project - if can? current_user, :admin_project, @project
= link_to new_project_deploy_key_path(@project), class: "btn small", title: "New Deploy Key" do = link_to new_project_deploy_key_path(@project), class: "btn btn-small", title: "New Deploy Key" do
Add Deploy Key Add Deploy Key
- if @keys.any? - if @keys.any?
%table %table

View file

@ -11,4 +11,4 @@
%hr %hr
%pre= @key.key %pre= @key.key
.right .right
= link_to 'Remove', project_deploy_key_path(@key.project, @key), confirm: 'Are you sure?', method: :delete, class: "danger btn delete-key" = link_to 'Remove', project_deploy_key_path(@key.project, @key), confirm: 'Are you sure?', method: :delete, class: "btn-remove btn delete-key"

View file

@ -5,7 +5,7 @@
(#{projects.count}) (#{projects.count})
- if can? current_user, :manage_group, @group - if can? current_user, :manage_group, @group
%span.right %span.right
= link_to new_project_path(namespace_id: @group.id), class: "btn very_small info" do = link_to new_project_path(namespace_id: @group.id), class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
New Project New Project
%ul.well-list %ul.well-list

View file

@ -1,7 +1,7 @@
.projects .projects
.activities.span8 .activities.span8
= render "events/event_last_push", event: @last_push = render "events/event_last_push", event: @last_push
= link_to dashboard_path, class: 'btn very_small' do = link_to dashboard_path, class: 'btn btn-tiny' do
← To dashboard ← To dashboard
   
%span.cgray You will only see events from projects in this group %span.cgray You will only see events from projects in this group

View file

@ -38,5 +38,5 @@
%span.monospace= hook.url %span.monospace= hook.url
%td %td
.right .right
= link_to 'Test Hook', test_project_hook_path(@project, hook), class: "btn small grouped" = link_to 'Test Hook', test_project_hook_path(@project, hook), class: "btn btn-small grouped"
= link_to 'Remove', project_hook_path(@project, hook), confirm: 'Are you sure?', method: :delete, class: "danger btn small grouped" = link_to 'Remove', project_hook_path(@project, hook), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove btn-small grouped"

View file

@ -4,15 +4,15 @@
= check_box_tag dom_id(issue,"selected"), nil, false, 'data-id' => issue.id, class: "selected_issue", disabled: !can?(current_user, :modify_issue, issue) = check_box_tag dom_id(issue,"selected"), nil, false, 'data-id' => issue.id, class: "selected_issue", disabled: !can?(current_user, :modify_issue, issue)
.right .right
- if issue.notes.any? - if issue.notes.any?
%span.btn.small.disabled.grouped %span.btn.btn-small.disabled.grouped
%i.icon-comment %i.icon-comment
= issue.notes.count = issue.notes.count
- if can? current_user, :modify_issue, issue - if can? current_user, :modify_issue, issue
- if issue.closed - if issue.closed
= link_to 'Reopen', project_issue_path(issue.project, issue, issue: {closed: false }, status_only: true), method: :put, class: "btn small grouped reopen_issue", remote: true = link_to 'Reopen', project_issue_path(issue.project, issue, issue: {closed: false }, status_only: true), method: :put, class: "btn btn-small grouped reopen_issue", remote: true
- else - else
= link_to 'Close', project_issue_path(issue.project, issue, issue: {closed: true }, status_only: true), method: :put, class: "btn small grouped close_issue", remote: true = link_to 'Close', project_issue_path(issue.project, issue, issue: {closed: true }, status_only: true), method: :put, class: "btn btn-small grouped close_issue", remote: true
= link_to edit_project_issue_path(issue.project, issue), class: "btn small edit-issue-link grouped" do = link_to edit_project_issue_path(issue.project, issue), class: "btn btn-small edit-issue-link grouped" do
%i.icon-edit %i.icon-edit
Edit Edit

View file

@ -8,5 +8,5 @@
= time_ago_in_words(key.created_at) = time_ago_in_words(key.created_at)
ago ago
%td %td
= link_to 'Remove', key, confirm: 'Are you sure?', method: :delete, class: "btn small btn-remove delete-key right" = link_to 'Remove', key, confirm: 'Are you sure?', method: :delete, class: "btn btn-small btn-remove delete-key right"

View file

@ -2,19 +2,19 @@
.right .right
.left .left
- if merge_request.merged? - if merge_request.merged?
%span.btn.small.disabled.grouped %span.btn.btn-small.disabled.grouped
%strong %strong
%i.icon-ok %i.icon-ok
= "MERGED" = "MERGED"
- if merge_request.notes.any? - if merge_request.notes.any?
%span.btn.small.disabled.grouped %span.btn.btn-small.disabled.grouped
%i.icon-comment %i.icon-comment
= merge_request.mr_and_commit_notes.count = merge_request.mr_and_commit_notes.count
- if merge_request.milestone_id? - if merge_request.milestone_id?
%span.btn.small.disabled.grouped %span.btn.btn-small.disabled.grouped
%i.icon-time %i.icon-time
= merge_request.milestone.title = merge_request.milestone.title
%span.btn.small.disabled.grouped %span.btn.btn-small.disabled.grouped
= merge_request.source_branch = merge_request.source_branch
→ →
= merge_request.target_branch = merge_request.target_branch

View file

@ -31,7 +31,7 @@
.automerge_widget.cannot_be_merged{style: "display:none"} .automerge_widget.cannot_be_merged{style: "display:none"}
.alert.alert-info .alert.alert-info
%span %span
= link_to "Show how to merge", "#", class: "how_to_merge_link btn small padded", title: "How To Merge" = link_to "Show how to merge", "#", class: "how_to_merge_link btn btn-small padded", title: "How To Merge"
   
%strong This request can't be merged with GitLab. You should do it manually %strong This request can't be merged with GitLab. You should do it manually

View file

@ -1,7 +1,7 @@
%li{class: "milestone milestone-#{milestone.closed ? 'closed' : 'open'}", id: dom_id(milestone) } %li{class: "milestone milestone-#{milestone.closed ? 'closed' : 'open'}", id: dom_id(milestone) }
.right .right
- if can?(current_user, :admin_milestone, milestone.project) and milestone.open? - if can?(current_user, :admin_milestone, milestone.project) and milestone.open?
= link_to edit_project_milestone_path(milestone.project, milestone), class: "btn small edit-milestone-link grouped" do = link_to edit_project_milestone_path(milestone.project, milestone), class: "btn btn-small edit-milestone-link grouped" do
%i.icon-edit %i.icon-edit
Edit Edit
%h4 %h4

View file

@ -3,7 +3,7 @@
%h3.page_title %h3.page_title
Milestones Milestones
- if can? current_user, :admin_milestone, @project - if can? current_user, :admin_milestone, @project
= link_to "New Milestone", new_project_milestone_path(@project), class: "right btn small", title: "New Milestone" = link_to "New Milestone", new_project_milestone_path(@project), class: "right btn btn-small", title: "New Milestone"
%br %br
%div.ui-box %div.ui-box
.title .title

View file

@ -10,12 +10,12 @@
.span6 .span6
.right .right
- unless @milestone.closed - unless @milestone.closed
= link_to new_project_issue_path(@project, issue: { milestone_id: @milestone.id }), class: "btn small grouped", title: "New Issue" do = link_to new_project_issue_path(@project, issue: { milestone_id: @milestone.id }), class: "btn btn-small grouped", title: "New Issue" do
%i.icon-plus %i.icon-plus
New Issue New Issue
= link_to 'Browse Issues', project_issues_path(@milestone.project, milestone_id: @milestone.id), class: "btn edit-milestone-link small grouped" = link_to 'Browse Issues', project_issues_path(@milestone.project, milestone_id: @milestone.id), class: "btn edit-milestone-link small grouped"
- if can?(current_user, :admin_milestone, @project) - if can?(current_user, :admin_milestone, @project)
= link_to edit_project_milestone_path(@project, @milestone), class: "btn small grouped" do = link_to edit_project_milestone_path(@project, @milestone), class: "btn btn-small grouped" do
%i.icon-edit %i.icon-edit
Edit Edit
@ -25,7 +25,7 @@
%hr %hr
%p %p
%span All issues for this milestone are closed. You may close milestone now. %span All issues for this milestone are closed. You may close milestone now.
= link_to 'Close Milestone', project_milestone_path(@project, @milestone, milestone: {closed: true }), method: :put, class: "btn small btn-remove" = link_to 'Close Milestone', project_milestone_path(@project, @milestone, milestone: {closed: true }), method: :put, class: "btn btn-small btn-remove"
.ui-box.ui-box-show .ui-box.ui-box-show
.ui-box-head .ui-box-head

View file

@ -26,7 +26,7 @@
.attachment .attachment
%h6 Attachment: %h6 Attachment:
.file_name.js-attachment-filename File name... .file_name.js-attachment-filename File name...
%a.choose-btn.btn.small.js-choose-note-attachment-button Choose File ... %a.choose-btn.btn.btn-small.js-choose-note-attachment-button Choose File ...
.hint Any file up to 10 MB .hint Any file up to 10 MB
= f.file_field :attachment, class: "js-note-attachment-input" = f.file_field :attachment, class: "js-note-attachment-input"

View file

@ -65,13 +65,13 @@
%li %li
%p %p
Need a group for several dependent projects? Need a group for several dependent projects?
= link_to new_group_path, class: "btn very_small" do = link_to new_group_path, class: "btn btn-tiny" do
Create a group Create a group
- if current_user.can_create_team? - if current_user.can_create_team?
%li %li
%p %p
Want to share a team between projects? Want to share a team between projects?
= link_to new_team_path, class: "btn very_small" do = link_to new_team_path, class: "btn btn-tiny" do
Create a team Create a team
%fieldset %fieldset
%legend %legend
@ -90,7 +90,7 @@
%span.right %span.right
= link_to pluralize(current_user.keys.count, 'key'), keys_path = link_to pluralize(current_user.keys.count, 'key'), keys_path
.padded .padded
= link_to "Add Public Key", new_key_path, class: "btn small" = link_to "Add Public Key", new_key_path, class: "btn btn-small"
.form-actions .form-actions
= f.submit 'Save', class: "btn btn-save" = f.submit 'Save', class: "btn btn-save"

View file

@ -24,11 +24,11 @@
.clearfix .clearfix
.input.light .input.light
Need a group for several dependent projects? Need a group for several dependent projects?
= link_to new_group_path, class: "btn very_small" do = link_to new_group_path, class: "btn btn-tiny" do
Create a group Create a group
- if current_user.can_create_team? - if current_user.can_create_team?
.clearfix .clearfix
.input.light .input.light
Want to share a project between team? Want to share a project between team?
= link_to new_team_path, class: "btn very_small" do = link_to new_team_path, class: "btn btn-tiny" do
Create a team Create a team

View file

@ -51,4 +51,4 @@
(branch was removed from repository) (branch was removed from repository)
%td %td
- if can? current_user, :admin_project, @project - if can? current_user, :admin_project, @project
= link_to 'Unprotect', [@project, branch], confirm: 'Are you sure?', method: :delete, class: "danger btn small" = link_to 'Unprotect', [@project, branch], confirm: 'Are you sure?', method: :delete, class: "btn btn-remove btn-small"

View file

@ -3,7 +3,7 @@
%i.icon-file %i.icon-file
%strong= @snippet.file_name %strong= @snippet.file_name
%span.options %span.options
= link_to "raw", raw_project_snippet_path(@project, @snippet), class: "btn very_small", target: "_blank" = link_to "raw", raw_project_snippet_path(@project, @snippet), class: "btn btn-tiny", target: "_blank"
.file_content.code .file_content.code
- unless @snippet.content.empty? - unless @snippet.content.empty?
%div{class: user_color_scheme_class} %div{class: user_color_scheme_class}

View file

@ -5,7 +5,7 @@
%small share code pastes with others out of git repository %small share code pastes with others out of git repository
- if can? current_user, :write_snippet, @project - if can? current_user, :write_snippet, @project
= link_to new_project_snippet_path(@project), class: "btn small add_new right", title: "New Snippet" do = link_to new_project_snippet_path(@project), class: "btn btn-small add_new right", title: "New Snippet" do
Add new snippet Add new snippet
%br %br
%table %table

View file

@ -4,7 +4,7 @@
= @snippet.title = @snippet.title
%small= @snippet.file_name %small= @snippet.file_name
- if can?(current_user, :admin_snippet, @project) || @snippet.author == current_user - if can?(current_user, :admin_snippet, @project) || @snippet.author == current_user
= link_to "Edit", edit_project_snippet_path(@project, @snippet), class: "btn small right" = link_to "Edit", edit_project_snippet_path(@project, @snippet), class: "btn btn-small right"
%br %br
%div= render 'blob' %div= render 'blob'

View file

@ -19,10 +19,10 @@
- if current_user == user - if current_user == user
%span.btn.disabled This is you! %span.btn.disabled This is you!
- if @project.namespace_owner == user - if @project.namespace_owner == user
%span.btn.disabled.success Owner %span.btn.disabled.btn-success Owner
- elsif user.blocked - elsif user.blocked
%span.btn.disabled.blocked Blocked %span.btn.disabled.blocked Blocked
- elsif allow_admin - elsif allow_admin
= link_to project_team_member_path(@project, user), confirm: remove_from_project_team_message(@project, user), method: :delete, class: "very_small btn btn-remove" do = link_to project_team_member_path(@project, user), confirm: remove_from_project_team_message(@project, user), method: :delete, class: "btn-tiny btn btn-remove" do
%i.icon-minus.icon-white %i.icon-minus.icon-white

View file

@ -8,9 +8,9 @@
- if can? current_user, :admin_team_member, @project - if can? current_user, :admin_team_member, @project
%span.right %span.right
= link_to import_project_team_members_path(@project), class: "btn small grouped", title: "Import team from another project" do = link_to import_project_team_members_path(@project), class: "btn btn-small grouped", title: "Import team from another project" do
Import team from another project Import team from another project
= link_to available_project_teams_path(@project), class: "btn small grouped", title: "Assign project to team of users" do = link_to available_project_teams_path(@project), class: "btn btn-small grouped", title: "Assign project to team of users" do
Assign project to Team of users Assign project to Team of users
= link_to new_project_team_member_path(@project), class: "btn btn-primary small grouped", title: "New Team Member" do = link_to new_project_team_member_path(@project), class: "btn btn-primary small grouped", title: "New Team Member" do
New Team Member New Team Member

View file

@ -5,7 +5,7 @@
(#{projects.count}) (#{projects.count})
- if can? current_user, :manage_user_team, @team - if can? current_user, :manage_user_team, @team
%span.right %span.right
= link_to new_team_project_path(@team), class: "btn very_small info" do = link_to new_team_project_path(@team), class: "btn btn-tiny info" do
%i.icon-plus %i.icon-plus
Assign Project Assign Project
%ul.well-list %ul.well-list

View file

@ -23,9 +23,9 @@
- if current_user == user - if current_user == user
%span.btn.disabled This is you! %span.btn.disabled This is you!
- if @team.owner == user - if @team.owner == user
%span.btn.disabled.success Owner %span.btn.disabled.btn-success Owner
- elsif user.blocked - elsif user.blocked
%span.btn.disabled.blocked Blocked %span.btn.disabled.blocked Blocked
- elsif allow_admin - elsif allow_admin
= link_to team_member_path(@team, user), confirm: remove_from_user_team_message(@team, user), method: :delete, class: "very_small btn btn-remove" do = link_to team_member_path(@team, user), confirm: remove_from_user_team_message(@team, user), method: :delete, class: "btn-tiny btn btn-remove" do
%i.icon-minus.icon-white %i.icon-minus.icon-white

View file

@ -29,7 +29,7 @@
- if current_user.can?(:admin_user_team, @team) - if current_user.can?(:admin_user_team, @team)
%td.bgred %td.bgred
= link_to 'Edit max access', edit_team_project_path(@team, project), class: "btn small" = link_to 'Edit max access', edit_team_project_path(@team, project), class: "btn btn-small"
= link_to 'Relegate', team_project_path(@team, project), confirm: 'Remove project from team and move to global namespace. Are you sure?', method: :delete, class: "btn btn-remove small" = link_to 'Relegate', team_project_path(@team, project), confirm: 'Remove project from team and move to global namespace. Are you sure?', method: :delete, class: "btn btn-remove small"
- else - else

View file

@ -1,6 +1,6 @@
.projects .projects
.activities.span8 .activities.span8
= link_to dashboard_path, class: 'btn very_small' do = link_to dashboard_path, class: 'btn btn-tiny' do
← To dashboard ← To dashboard
   
%span.cgray Events and projects are filtered in scope of team %span.cgray Events and projects are filtered in scope of team

View file

@ -1,12 +1,12 @@
.btn-group.tree-btn-group .btn-group.tree-btn-group
-# only show edit link for text files -# only show edit link for text files
- if @tree.text? - if @tree.text?
= link_to "edit", edit_project_tree_path(@project, @id), class: "btn very_small", disabled: !allowed_tree_edit? = link_to "edit", edit_project_tree_path(@project, @id), class: "btn btn-tiny", disabled: !allowed_tree_edit?
= link_to "raw", project_blob_path(@project, @id), class: "btn very_small", target: "_blank" = link_to "raw", project_blob_path(@project, @id), class: "btn btn-tiny", target: "_blank"
-# only show normal/blame view links for text files -# only show normal/blame view links for text files
- if @tree.text? - if @tree.text?
- if current_page? project_blame_path(@project, @id) - if current_page? project_blame_path(@project, @id)
= link_to "normal view", project_tree_path(@project, @id), class: "btn very_small" = link_to "normal view", project_tree_path(@project, @id), class: "btn btn-tiny"
- else - else
= link_to "blame", project_blame_path(@project, @id), class: "btn very_small" = link_to "blame", project_blame_path(@project, @id), class: "btn btn-tiny"
= link_to "history", project_commits_path(@project, @id), class: "btn very_small" = link_to "history", project_commits_path(@project, @id), class: "btn btn-tiny"

View file

@ -24,7 +24,7 @@
%th Name %th Name
%th Last Update %th Last Update
%th Last Commit %th Last Commit
%th= link_to "history", project_commits_path(@project, @id), class: "btn very_small right" %th= link_to "history", project_commits_path(@project, @id), class: "btn btn-tiny right"
- if tree.up_dir? - if tree.up_dir?
%tr.tree-item %tr.tree-item

View file

@ -10,7 +10,7 @@
%strong= @ref %strong= @ref
%span.options %span.options
.btn-group.tree-btn-group .btn-group.tree-btn-group
= link_to "Cancel", project_tree_path(@project, @id), class: "btn very_small btn-cancel", confirm: "Are you sure?" = link_to "Cancel", project_tree_path(@project, @id), class: "btn btn-tiny btn-cancel", confirm: "Are you sure?"
.file_content.code .file_content.code
%pre#editor= @tree.data %pre#editor= @tree.data

View file

@ -5,7 +5,7 @@
= @user.name = @user.name
- if @user == current_user - if @user == current_user
.right .right
= link_to profile_path, class: 'btn small' do = link_to profile_path, class: 'btn btn-small' do
%i.icon-edit %i.icon-edit
Edit Profile Edit Profile
%br %br

View file

@ -4,5 +4,5 @@
.right .right
- if can? current_user, :admin_wiki, @project - if can? current_user, :admin_wiki, @project
= link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete, class: "btn small btn-remove" do = link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete, class: "btn btn-small btn-remove" do
Delete this page Delete this page

View file

@ -1,12 +1,12 @@
%h3.page_title %h3.page_title
= @wiki.title = @wiki.title
%span.right %span.right
= link_to pages_project_wikis_path(@project), class: "btn small grouped" do = link_to pages_project_wikis_path(@project), class: "btn btn-small grouped" do
Pages Pages
- if can? current_user, :write_wiki, @project - if can? current_user, :write_wiki, @project
= link_to history_project_wiki_path(@project, @wiki), class: "btn small grouped" do = link_to history_project_wiki_path(@project, @wiki), class: "btn btn-small grouped" do
History History
= link_to edit_project_wiki_path(@project, @wiki), class: "btn small grouped" do = link_to edit_project_wiki_path(@project, @wiki), class: "btn btn-small grouped" do
%i.icon-edit %i.icon-edit
Edit Edit
%br %br