summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2016-07-01 17:34:00 +0800
committerLin Jen-Shin <godfat@godfat.org>2016-07-01 17:34:00 +0800
commit08070c76952a27e4710fb9f2c800e71a84fc72c7 (patch)
tree3a89d90ff9a982afb502400561a6450e570fa74d /app/views
parent63477fd27f3eeff5d5f612b27ed71c76926934d2 (diff)
parentab81ea1e8177742a0dfed2c7cf922bb03a8b6c51 (diff)
downloadgitlab-ce-08070c76952a27e4710fb9f2c800e71a84fc72c7.tar.gz
Merge remote-tracking branch 'upstream/master' into enable-shared-runners-with-admins
* upstream/master: (120 commits) Update CHANGELOG for 8.9.4, 8.8.7, and 8.7.9. Remove additional entries from CHANGELOG Catch permission denied errors and ignore the disk Remove coveralls lines Make GH one-off auth the default again for importing GH projects Import from Github using Personal Access Tokens. Remove hardcoded gitlab-shell version in test env now that the required tag is published Updated breakpoint for sidebar pinning Expire branch/tag git data when needed. Remove unnecessary parens Enable Style/UnneededCapitalW Rubocop cop Expiry date on pinned nav cookie Fix broken spec in git_push_service_spec by stubbing an external issue tracker Handle external issues in IssueReferenceFilter Move Changelog entry for build retry fix to 8.9.4 Add Changelog entry for build sidebar retry link fix Improve method that tells if build is retryable Do not show build retry link when build is active Remove coveralls as its unused Move changelot item "Add sub nav to file page view" to 8.9.4 ...
Diffstat (limited to 'app/views')
-rw-r--r--app/views/admin/application_settings/_form.html.haml11
-rw-r--r--app/views/admin/background_jobs/_head.html.haml4
-rw-r--r--app/views/admin/background_jobs/show.html.haml2
-rw-r--r--app/views/admin/builds/index.html.haml2
-rw-r--r--app/views/admin/dashboard/index.html.haml2
-rw-r--r--app/views/admin/groups/index.html.haml5
-rw-r--r--app/views/admin/health_check/show.html.haml2
-rw-r--r--app/views/admin/logs/show.html.haml2
-rw-r--r--app/views/admin/projects/index.html.haml2
-rw-r--r--app/views/admin/runners/index.html.haml2
-rw-r--r--app/views/admin/system_info/show.html.haml25
-rw-r--r--app/views/admin/users/index.html.haml2
-rw-r--r--app/views/events/event/_push.html.haml25
-rw-r--r--app/views/groups/show.html.haml11
-rw-r--r--app/views/help/index.html.haml2
-rw-r--r--app/views/import/github/new.html.haml43
-rw-r--r--app/views/layouts/header/_default.html.haml2
-rw-r--r--app/views/layouts/nav/_admin.html.haml8
-rw-r--r--app/views/layouts/nav/_group.html.haml4
-rw-r--r--app/views/layouts/nav/_profile.html.haml4
-rw-r--r--app/views/layouts/nav/_project.html.haml4
-rw-r--r--app/views/projects/_github_import_modal.html.haml13
-rw-r--r--app/views/projects/_home_panel.html.haml2
-rw-r--r--app/views/projects/_last_push.html.haml2
-rw-r--r--app/views/projects/_md_preview.html.haml4
-rw-r--r--app/views/projects/blob/_text.html.haml2
-rw-r--r--app/views/projects/blob/show.html.haml17
-rw-r--r--app/views/projects/branches/index.html.haml4
-rw-r--r--app/views/projects/builds/index.html.haml2
-rw-r--r--app/views/projects/builds/show.html.haml2
-rw-r--r--app/views/projects/commits/_head.html.haml4
-rw-r--r--app/views/projects/commits/show.html.haml2
-rw-r--r--app/views/projects/compare/index.html.haml2
-rw-r--r--app/views/projects/compare/show.html.haml2
-rw-r--r--app/views/projects/environments/index.html.haml2
-rw-r--r--app/views/projects/environments/show.html.haml2
-rw-r--r--app/views/projects/graphs/ci.html.haml2
-rw-r--r--app/views/projects/graphs/commits.html.haml2
-rw-r--r--app/views/projects/graphs/languages.html.haml2
-rw-r--r--app/views/projects/graphs/show.html.haml2
-rw-r--r--app/views/projects/imports/new.html.haml2
-rw-r--r--app/views/projects/issues/index.html.haml2
-rw-r--r--app/views/projects/labels/index.html.haml2
-rw-r--r--app/views/projects/merge_requests/index.html.haml2
-rw-r--r--app/views/projects/milestones/index.html.haml2
-rw-r--r--app/views/projects/network/_head.html.haml2
-rw-r--r--app/views/projects/network/show.html.haml2
-rw-r--r--app/views/projects/new.html.haml201
-rw-r--r--app/views/projects/notes/_note.html.haml2
-rw-r--r--app/views/projects/pipelines/index.html.haml2
-rw-r--r--app/views/projects/show.html.haml2
-rw-r--r--app/views/projects/tags/index.html.haml4
-rw-r--r--app/views/projects/tree/show.html.haml2
-rw-r--r--app/views/projects/wikis/_new.html.haml2
-rw-r--r--app/views/projects/wikis/edit.html.haml2
-rw-r--r--app/views/projects/wikis/git_access.html.haml2
-rw-r--r--app/views/projects/wikis/history.html.haml2
-rw-r--r--app/views/projects/wikis/pages.html.haml2
-rw-r--r--app/views/projects/wikis/show.html.haml2
-rw-r--r--app/views/shared/_file_highlight.html.haml4
-rw-r--r--app/views/shared/_labels_row.html.haml2
-rw-r--r--app/views/users/calendar_activities.html.haml2
62 files changed, 286 insertions, 195 deletions
diff --git a/app/views/admin/application_settings/_form.html.haml b/app/views/admin/application_settings/_form.html.haml
index c883e8f97da..c1f70bc1866 100644
--- a/app/views/admin/application_settings/_form.html.haml
+++ b/app/views/admin/application_settings/_form.html.haml
@@ -15,7 +15,7 @@
= f.label :default_snippet_visibility, class: 'control-label col-sm-2'
.col-sm-10
= render('shared/visibility_radios', model_method: :default_snippet_visibility, form: f, selected_level: @application_setting.default_snippet_visibility, form_model: ProjectSnippet.new)
- .form-group.group-visibility-level-holder
+ .form-group.project-visibility-level-holder
= f.label :default_group_visibility, class: 'control-label col-sm-2'
.col-sm-10
= render('shared/visibility_radios', model_method: :default_group_visibility, form: f, selected_level: @application_setting.default_group_visibility, form_model: Group.new)
@@ -311,6 +311,15 @@
= f.text_field :sentry_dsn, class: 'form-control'
%fieldset
+ %legend Repository Storage
+ .form-group
+ = f.label :repository_storage, 'Storage path for new projects', class: 'control-label col-sm-2'
+ .col-sm-10
+ = f.select :repository_storage, repository_storage_options_for_select, {}, class: 'form-control'
+ .help-block
+ You can manage the repository storage paths in your gitlab.yml configuration file
+
+ %fieldset
%legend Repository Checks
.form-group
.col-sm-offset-2.col-sm-10
diff --git a/app/views/admin/background_jobs/_head.html.haml b/app/views/admin/background_jobs/_head.html.haml
index d78682532ed..9d722bd7382 100644
--- a/app/views/admin/background_jobs/_head.html.haml
+++ b/app/views/admin/background_jobs/_head.html.haml
@@ -1,5 +1,9 @@
.nav-links.sub-nav
%ul{ class: (container_class) }
+ = nav_link(controller: :system_info) do
+ = link_to admin_system_info_path, title: 'System Info' do
+ %span
+ System Info
= nav_link(controller: :background_jobs) do
= link_to admin_background_jobs_path, title: 'Background Jobs' do
%span
diff --git a/app/views/admin/background_jobs/show.html.haml b/app/views/admin/background_jobs/show.html.haml
index 654d261aa99..4f680b507c4 100644
--- a/app/views/admin/background_jobs/show.html.haml
+++ b/app/views/admin/background_jobs/show.html.haml
@@ -2,7 +2,7 @@
- page_title "Background Jobs"
= render 'admin/background_jobs/head'
-%div{ class: (container_class) }
+%div{ class: container_class }
%h3.page-title Background Jobs
%p.light GitLab uses #{link_to "sidekiq", "http://sidekiq.org/"} library for async job processing
diff --git a/app/views/admin/builds/index.html.haml b/app/views/admin/builds/index.html.haml
index efd5b12cfeb..1e60205f91a 100644
--- a/app/views/admin/builds/index.html.haml
+++ b/app/views/admin/builds/index.html.haml
@@ -1,7 +1,7 @@
- @no_container = true
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
%ul.nav-links
diff --git a/app/views/admin/dashboard/index.html.haml b/app/views/admin/dashboard/index.html.haml
index 4682016a886..a2ac407c159 100644
--- a/app/views/admin/dashboard/index.html.haml
+++ b/app/views/admin/dashboard/index.html.haml
@@ -1,7 +1,7 @@
- @no_container = true
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.admin-dashboard.prepend-top-default
.row
.col-md-4
diff --git a/app/views/admin/groups/index.html.haml b/app/views/admin/groups/index.html.haml
index 4f1996ef7ab..94aa5f5a942 100644
--- a/app/views/admin/groups/index.html.haml
+++ b/app/views/admin/groups/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Groups"
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
%h3.page-title
Groups (#{number_with_delimiter(@groups.total_count)})
@@ -39,7 +39,6 @@
= link_to 'New Group', new_admin_group_path, class: "btn btn-new"
%ul.content-list
- - @groups.each do |group|
- = render 'group', group: group
+ = render @groups
= paginate @groups, theme: "gitlab"
diff --git a/app/views/admin/health_check/show.html.haml b/app/views/admin/health_check/show.html.haml
index 7b8407f9152..e79303240f0 100644
--- a/app/views/admin/health_check/show.html.haml
+++ b/app/views/admin/health_check/show.html.haml
@@ -2,7 +2,7 @@
- page_title "Health Check"
= render 'admin/background_jobs/head'
-%div{ class: (container_class) }
+%div{ class: container_class }
%h3.page-title
Health Check
.bs-callout.clearfix
diff --git a/app/views/admin/logs/show.html.haml b/app/views/admin/logs/show.html.haml
index 5ddc3b9ea85..676812121d7 100644
--- a/app/views/admin/logs/show.html.haml
+++ b/app/views/admin/logs/show.html.haml
@@ -5,7 +5,7 @@
Gitlab::RepositoryCheckLogger]
= render 'admin/background_jobs/head'
-%div{ class: (container_class) }
+%div{ class: container_class }
%ul.nav-links.log-tabs
- loggers.each do |klass|
%li{ class: (klass == Gitlab::GitLogger ? 'active' : '') }
diff --git a/app/views/admin/projects/index.html.haml b/app/views/admin/projects/index.html.haml
index 4822cb693c2..7d2eb423223 100644
--- a/app/views/admin/projects/index.html.haml
+++ b/app/views/admin/projects/index.html.haml
@@ -3,7 +3,7 @@
= render 'shared/show_aside'
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.row.prepend-top-default
%aside.col-md-3
.panel.admin-filter
diff --git a/app/views/admin/runners/index.html.haml b/app/views/admin/runners/index.html.haml
index b5c6b5effe3..a53876d6757 100644
--- a/app/views/admin/runners/index.html.haml
+++ b/app/views/admin/runners/index.html.haml
@@ -1,7 +1,7 @@
- @no_container = true
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
%p.prepend-top-default
%span
diff --git a/app/views/admin/system_info/show.html.haml b/app/views/admin/system_info/show.html.haml
new file mode 100644
index 00000000000..6956e5ab795
--- /dev/null
+++ b/app/views/admin/system_info/show.html.haml
@@ -0,0 +1,25 @@
+- @no_container = true
+- page_title "System Info"
+= render 'admin/background_jobs/head'
+
+%div{ class: container_class }
+ .prepend-top-default
+ .row
+ .col-sm-4
+ .light-well
+ %h4 CPU
+ .data
+ %h1= "#{@cpus} cores"
+ .col-sm-4
+ .light-well
+ %h4 Memory
+ .data
+ %h1= "#{number_to_human_size(@mem_used)} / #{number_to_human_size(@mem_total)}"
+ .col-sm-4
+ .light-well
+ %h4 Disks
+ .data
+ - @disks.each do |disk|
+ %h1= "#{number_to_human_size(disk[:bytes_used])} / #{number_to_human_size(disk[:bytes_total])}"
+ %p= "#{disk[:disk_name]}"
+ %p= "#{disk[:mount_path]}"
diff --git a/app/views/admin/users/index.html.haml b/app/views/admin/users/index.html.haml
index d0a696da64b..21bb99a792c 100644
--- a/app/views/admin/users/index.html.haml
+++ b/app/views/admin/users/index.html.haml
@@ -3,7 +3,7 @@
= render 'shared/show_aside'
= render "admin/dashboard/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.admin-filter
%ul.nav-links
%li{class: "#{'active' unless params[:filter]}"}
diff --git a/app/views/events/event/_push.html.haml b/app/views/events/event/_push.html.haml
index dc4ff17e31a..ea54ef226ec 100644
--- a/app/views/events/event/_push.html.haml
+++ b/app/views/events/event/_push.html.haml
@@ -1,3 +1,5 @@
+- project = event.project
+
.event-title
%span.author_name= link_to_author event
%span.event_label.pushed #{event.action_name} #{event.ref_type}
@@ -5,19 +7,18 @@
%strong= event.ref_name
- else
%strong
- = link_to event.ref_name, namespace_project_commits_path(event.project.namespace, event.project, event.ref_name), title: h(event.target_title)
+ = link_to event.ref_name, namespace_project_commits_path(project.namespace, project, event.ref_name), title: h(event.target_title)
at
- = link_to_project event.project
+ = link_to_project project
- if event.push_with_commits?
- - project = event.project
.event-body
%ul.well-list.event_commits
- few_commits = event.commits[0...2]
- few_commits.each do |commit|
= render "events/commit", commit: commit, project: project, event: event
- - create_mr = event.new_ref? && create_mr_button?(event.project.default_branch, event.ref_name, event.project)
+ - create_mr = event.new_ref? && create_mr_button?(project.default_branch, event.ref_name, project)
- if event.commits_count > 1
%li.commits-stat
- if event.commits_count > 2
@@ -27,18 +28,26 @@
- from = event.commit_from
- from_label = truncate_sha(from)
- else
- - from = event.project.default_branch
+ - from = project.default_branch
- from_label = from
- = link_to namespace_project_compare_path(event.project.namespace, event.project, from: from, to: event.commit_to) do
+ = link_to namespace_project_compare_path(project.namespace, project, from: from, to: event.commit_to) do
Compare #{from_label}...#{truncate_sha(event.commit_to)}
- if create_mr
%span{"data-user-is" => event.author_id, "data-display" => "inline"}
or
- = link_to create_mr_path(event.project.default_branch, event.ref_name, event.project) do
+ = link_to create_mr_path(project.default_branch, event.ref_name, project) do
create a merge request
- elsif create_mr
%li.commits-stat{"data-user-is" => event.author_id}
- = link_to create_mr_path(event.project.default_branch, event.ref_name, event.project) do
+ = link_to create_mr_path(project.default_branch, event.ref_name, project) do
Create Merge Request
+- elsif event.rm_ref?
+ - repository = project.repository
+ - last_commit = repository.commit(event.commit_from)
+ - if last_commit
+ .event-body
+ %ul.well-list.event_commits
+ = render "events/commit", commit: last_commit, project: project, event: event
+
diff --git a/app/views/groups/show.html.haml b/app/views/groups/show.html.haml
index aecefbc6e8f..69f634e75b9 100644
--- a/app/views/groups/show.html.haml
+++ b/app/views/groups/show.html.haml
@@ -5,7 +5,7 @@
= auto_discovery_link_tag(:atom, group_url(@group, format: :atom, private_token: current_user.private_token), title: "#{@group.name} activity")
.cover-block.groups-cover-block
- %div{ class: (container_class) }
+ %div{ class: container_class }
= link_to group_icon(@group), target: '_blank' do
= image_tag group_icon(@group), class: "avatar group-avatar s70"
.group-info
@@ -15,12 +15,17 @@
%span.visibility-icon.has-tooltip{ data: { container: 'body' }, title: visibility_icon_description(@group) }
= visibility_level_icon(@group.visibility_level, fw: false)
+ %span.hidden-xs
+ = render 'shared/notifications/button', notification_setting: @notification_setting
+
+ - if current_user
+ .pull-right
+ = render 'shared/members/access_request_buttons', source: @group
+
- if @group.description.present?
.cover-desc.description
= markdown(@group.description, pipeline: :description)
- - if current_user
- = render 'shared/members/access_request_buttons', source: @group
%div{ class: container_class }
.top-area
diff --git a/app/views/help/index.html.haml b/app/views/help/index.html.haml
index 57bc91ea5a9..57601ae9be0 100644
--- a/app/views/help/index.html.haml
+++ b/app/views/help/index.html.haml
@@ -36,6 +36,6 @@
%ul.well-list
%li= link_to 'See our website for getting help', promo_url + '/getting-help/'
%li= link_to 'Use the search bar on the top of this page', '#', onclick: 'Shortcuts.focusSearch(event)'
- %li= link_to 'Use shortcuts', '#', onclick: 'Shortcuts.showHelp(event)'
+ %li= link_to 'Use shortcuts', '#', onclick: 'Shortcuts.toggleHelp()'
%li= link_to 'Get a support subscription', 'https://about.gitlab.com/pricing/'
%li= link_to 'Compare GitLab editions', 'https://about.gitlab.com/features/#compare'
diff --git a/app/views/import/github/new.html.haml b/app/views/import/github/new.html.haml
new file mode 100644
index 00000000000..435ed7bd4cb
--- /dev/null
+++ b/app/views/import/github/new.html.haml
@@ -0,0 +1,43 @@
+- page_title "GitHub Import"
+- header_title "Projects", root_path
+
+%h3.page-title
+ = icon 'github', text: 'Import Projects from GitHub'
+
+- if github_import_configured?
+ %p
+ To import a GitHub project, you first need to authorize GitLab to access
+ the list of your GitHub repositories:
+
+ = link_to 'List Your GitHub Repositories', status_import_github_path, class: 'btn btn-success'
+
+ %hr
+
+%p
+ - if github_import_configured?
+ Alternatively,
+ - else
+ To import a GitHub project,
+ you can use a
+ = succeed '.' do
+ = link_to 'Personal Access Token', 'https://github.com/settings/tokens'
+ When you create your Personal Access Token,
+ you will need to select the <code>repo</code> scope, so we can display a
+ list of your public and private repositories which are available for import.
+
+= form_tag personal_access_token_import_github_path, method: :post, class: 'form-inline' do
+ .form-group
+ = text_field_tag :personal_access_token, '', class: 'form-control', placeholder: "Personal Access Token", size: 40
+ = submit_tag 'List Your GitHub Repositories', class: 'btn btn-success'
+
+- unless github_import_configured?
+ %hr
+ %p
+ Note:
+ - if current_user.admin?
+ As an administrator you may like to configure
+ - else
+ Consider asking your GitLab administrator to configure
+ = link_to 'GitHub integration', help_page_path("integration", "github")
+ which will allow login via GitHub and allow importing projects without
+ generating a Personal Access Token.
diff --git a/app/views/layouts/header/_default.html.haml b/app/views/layouts/header/_default.html.haml
index 40a2c81eebd..1a39572ac3c 100644
--- a/app/views/layouts/header/_default.html.haml
+++ b/app/views/layouts/header/_default.html.haml
@@ -6,7 +6,7 @@
= icon('bars')
%button.navbar-toggle{type: 'button'}
%span.sr-only Toggle navigation
- = icon('angle-left')
+ = icon('ellipsis-v')
.navbar-collapse.collapse
%ul.nav.navbar-nav
diff --git a/app/views/layouts/nav/_admin.html.haml b/app/views/layouts/nav/_admin.html.haml
index 0f264cd2e06..5ee8772882e 100644
--- a/app/views/layouts/nav/_admin.html.haml
+++ b/app/views/layouts/nav/_admin.html.haml
@@ -1,16 +1,16 @@
.scrolling-tabs-container{ class: nav_control_class }
= render 'layouts/nav/admin_settings'
.fade-left
- = icon('arrow-left')
+ = icon('angle-left')
.fade-right
- = icon('arrow-right')
+ = icon('angle-right')
%ul.nav-links.scrolling-tabs
= nav_link(controller: %w(dashboard admin projects users groups builds runners), html_options: {class: 'home'}) do
= link_to admin_root_path, title: 'Overview', class: 'shortcuts-tree' do
%span
Overview
- = nav_link(controller: %w(background_jobs logs health_check)) do
- = link_to admin_background_jobs_path, title: 'Monitoring' do
+ = nav_link(controller: %w(system_info background_jobs logs health_check)) do
+ = link_to admin_system_info_path, title: 'Monitoring' do
%span
Monitoring
= nav_link(controller: :broadcast_messages) do
diff --git a/app/views/layouts/nav/_group.html.haml b/app/views/layouts/nav/_group.html.haml
index 5d657a9ac84..d7d36c84b6c 100644
--- a/app/views/layouts/nav/_group.html.haml
+++ b/app/views/layouts/nav/_group.html.haml
@@ -1,9 +1,9 @@
.scrolling-tabs-container{ class: nav_control_class }
= render 'layouts/nav/group_settings'
.fade-left
- = icon('arrow-left')
+ = icon('angle-left')
.fade-right
- = icon('arrow-right')
+ = icon('angle-right')
%ul.nav-links.scrolling-tabs
= nav_link(path: 'groups#show', html_options: {class: 'home'}) do
= link_to group_path(@group), title: 'Home' do
diff --git a/app/views/layouts/nav/_profile.html.haml b/app/views/layouts/nav/_profile.html.haml
index f37f9b0f5a3..96fe62c39c3 100644
--- a/app/views/layouts/nav/_profile.html.haml
+++ b/app/views/layouts/nav/_profile.html.haml
@@ -1,8 +1,8 @@
.scrolling-tabs-container
.fade-left
- = icon('arrow-left')
+ = icon('angle-left')
.fade-right
- = icon('arrow-right')
+ = icon('angle-right')
%ul.nav-links.scrolling-tabs
= nav_link(path: 'profiles#show', html_options: {class: 'home'}) do
= link_to profile_path, title: 'Profile Settings' do
diff --git a/app/views/layouts/nav/_project.html.haml b/app/views/layouts/nav/_project.html.haml
index a4bb56aa56f..dcef427cda3 100644
--- a/app/views/layouts/nav/_project.html.haml
+++ b/app/views/layouts/nav/_project.html.haml
@@ -26,9 +26,9 @@
.scrolling-tabs-container{ class: nav_control_class }
.fade-left
- = icon('arrow-left')
+ = icon('angle-left')
.fade-right
- = icon('arrow-right')
+ = icon('angle-right')
%ul.nav-links.scrolling-tabs
= nav_link(path: 'projects#show', html_options: {class: 'home'}) do
= link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do
diff --git a/app/views/projects/_github_import_modal.html.haml b/app/views/projects/_github_import_modal.html.haml
deleted file mode 100644
index 46ad1559356..00000000000
--- a/app/views/projects/_github_import_modal.html.haml
+++ /dev/null
@@ -1,13 +0,0 @@
-%div#github_import_modal.modal
- .modal-dialog
- .modal-content
- .modal-header
- %a.close{href: "#", "data-dismiss" => "modal"} ×
- %h3 Import projects from GitHub
- .modal-body
- To enable importing projects from GitHub,
- - if current_user.admin?
- as administrator you need to configure
- - else
- ask your Gitlab administrator to configure
- == #{link_to 'OAuth integration', help_page_path("integration", "github")}.
diff --git a/app/views/projects/_home_panel.html.haml b/app/views/projects/_home_panel.html.haml
index 86ea08dd229..8ce23379fb4 100644
--- a/app/views/projects/_home_panel.html.haml
+++ b/app/views/projects/_home_panel.html.haml
@@ -1,6 +1,6 @@
- empty_repo = @project.empty_repo?
.project-home-panel.cover-block.clearfix{:class => ("empty-project" if empty_repo)}
- %div{ class: (container_class) }
+ %div{ class: container_class }
.row
.project-image-container
= project_icon(@project, alt: '', class: 'project-avatar avatar s70')
diff --git a/app/views/projects/_last_push.html.haml b/app/views/projects/_last_push.html.haml
index e0ca2a3109c..434d8644b83 100644
--- a/app/views/projects/_last_push.html.haml
+++ b/app/views/projects/_last_push.html.haml
@@ -1,7 +1,7 @@
- if event = last_push_event
- if show_last_push_widget?(event)
.row-content-block.top-block.clear-block.hidden-xs
- %div{ class: (container_class) }
+ %div{ class: container_class }
.event-last-push
.event-last-push-text
%span You pushed to
diff --git a/app/views/projects/_md_preview.html.haml b/app/views/projects/_md_preview.html.haml
index ca6714ef42b..58d961d93ca 100644
--- a/app/views/projects/_md_preview.html.haml
+++ b/app/views/projects/_md_preview.html.haml
@@ -12,13 +12,13 @@
%li.confidential-issue-warning
= icon('warning')
%span This is a confidential issue. Your comment will not be visible to the public.
-
+
%li.pull-right
.toolbar-group
= markdown_toolbar_button({icon: "bold fw", data: { "md-tag" => "**" }, title: "Add bold text" })
= markdown_toolbar_button({icon: "italic fw", data: { "md-tag" => "*" }, title: "Add italic text" })
= markdown_toolbar_button({icon: "quote-right fw", data: { "md-tag" => "> ", "md-prepend" => true }, title: "Insert a quote" })
- = markdown_toolbar_button({icon: "code fw", data: { "md-tag" => "`" }, title: "Insert code" })
+ = markdown_toolbar_button({icon: "code fw", data: { "md-tag" => "`", "md-block" => "```" }, title: "Insert code" })
= markdown_toolbar_button({icon: "list-ul fw", data: { "md-tag" => "* ", "md-prepend" => true }, title: "Add a bullet list" })
= markdown_toolbar_button({icon: "list-ol fw", data: { "md-tag" => "1. ", "md-prepend" => true }, title: "Add a numbered list" })
= markdown_toolbar_button({icon: "check-square-o fw", data: { "md-tag" => "* [ ] ", "md-prepend" => true }, title: "Add a task list" })
diff --git a/app/views/projects/blob/_text.html.haml b/app/views/projects/blob/_text.html.haml
index b1769759dce..58524418a67 100644
--- a/app/views/projects/blob/_text.html.haml
+++ b/app/views/projects/blob/_text.html.haml
@@ -16,4 +16,4 @@
.file-content.code
.nothing-here-block Empty file
- else
- = render 'shared/file_highlight', blob: blob
+ = render 'shared/file_highlight', blob: blob, repository: @repository
diff --git a/app/views/projects/blob/show.html.haml b/app/views/projects/blob/show.html.haml
index ed670dae88d..0ab78a39cf9 100644
--- a/app/views/projects/blob/show.html.haml
+++ b/app/views/projects/blob/show.html.haml
@@ -1,12 +1,15 @@
+- @no_container = true
- page_title @blob.path, @ref
+= render "projects/commits/head"
-= render 'projects/last_push'
+%div{ class: container_class }
+ = render 'projects/last_push'
-%div#tree-holder.tree-holder
- = render 'blob', blob: @blob
+ %div#tree-holder.tree-holder
+ = render 'blob', blob: @blob
-- if can_edit_blob?(@blob)
- = render 'projects/blob/remove'
+ - if can_edit_blob?(@blob)
+ = render 'projects/blob/remove'
- - title = "Replace #{@blob.name}"
- = render 'projects/blob/upload', title: title, placeholder: title, button_title: 'Replace file', form_path: namespace_project_update_blob_path(@project.namespace, @project, @id), method: :put
+ - title = "Replace #{@blob.name}"
+ = render 'projects/blob/upload', title: title, placeholder: title, button_title: 'Replace file', form_path: namespace_project_update_blob_path(@project.namespace, @project, @id), method: :put
diff --git a/app/views/projects/branches/index.html.haml b/app/views/projects/branches/index.html.haml
index e0367c40272..77b405f1f39 100644
--- a/app/views/projects/branches/index.html.haml
+++ b/app/views/projects/branches/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Branches"
= render "projects/commits/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.nav-text
Protected branches can be managed in project settings
@@ -27,7 +27,7 @@
= sort_title_recently_updated
= link_to namespace_project_branches_path(sort: 'last_updated') do
= sort_title_oldest_updated
- - unless @branches.empty?
+ - if @branches.any?
%ul.content-list.all-branches
- @branches.each do |branch|
= render "projects/branches/branch", branch: branch
diff --git a/app/views/projects/builds/index.html.haml b/app/views/projects/builds/index.html.haml
index 181547316aa..a131289ee97 100644
--- a/app/views/projects/builds/index.html.haml
+++ b/app/views/projects/builds/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Builds"
= render "projects/pipelines/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
%ul.nav-links
%li{class: ('active' if @scope.nil?)}
diff --git a/app/views/projects/builds/show.html.haml b/app/views/projects/builds/show.html.haml
index 4e2702c2e44..d1c468c4692 100644
--- a/app/views/projects/builds/show.html.haml
+++ b/app/views/projects/builds/show.html.haml
@@ -67,4 +67,4 @@
= render "sidebar"
:javascript
- new CiBuild("#{namespace_project_build_url(@project.namespace, @project, @build)}", "#{@build.status}", "#{trace_with_state[:state]}")
+ new CiBuild("#{namespace_project_build_url(@project.namespace, @project, @build, :json)}", "#{@build.status}", "#{trace_with_state[:state]}")
diff --git a/app/views/projects/commits/_head.html.haml b/app/views/projects/commits/_head.html.haml
index b11b6c24ccd..61152649907 100644
--- a/app/views/projects/commits/_head.html.haml
+++ b/app/views/projects/commits/_head.html.haml
@@ -1,8 +1,8 @@
.scrolling-tabs-container.sub-nav-scroll
.fade-left
- = icon('arrow-left')
+ = icon('angle-left')
.fade-right
- = icon('arrow-right')
+ = icon('angle-right')
.nav-links.sub-nav.scrolling-tabs
%ul{ class: (container_class) }
= nav_link(controller: %w(tree blob blame edit_tree new_tree find_file)) do
diff --git a/app/views/projects/commits/show.html.haml b/app/views/projects/commits/show.html.haml
index 51ca4eb903e..9a44ba94970 100644
--- a/app/views/projects/commits/show.html.haml
+++ b/app/views/projects/commits/show.html.haml
@@ -7,7 +7,7 @@
= render "head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.row-content-block.second-block.content-component-block
.tree-ref-holder
= render 'shared/ref_switcher', destination: 'commits'
diff --git a/app/views/projects/compare/index.html.haml b/app/views/projects/compare/index.html.haml
index b22285c11e0..e9ff8e90dd5 100644
--- a/app/views/projects/compare/index.html.haml
+++ b/app/views/projects/compare/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Compare"
= render "projects/commits/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
Compare branches, tags or commit ranges.
%br
diff --git a/app/views/projects/compare/show.html.haml b/app/views/projects/compare/show.html.haml
index f4ec7b767f6..28a50e7031a 100644
--- a/app/views/projects/compare/show.html.haml
+++ b/app/views/projects/compare/show.html.haml
@@ -2,7 +2,7 @@
- page_title "#{params[:from]}...#{params[:to]}"
= render "projects/commits/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block.no-bottom-space
= render "form"
diff --git a/app/views/projects/environments/index.html.haml b/app/views/projects/environments/index.html.haml
index a03f117291f..5242021243e 100644
--- a/app/views/projects/environments/index.html.haml
+++ b/app/views/projects/environments/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Environments"
= render "projects/pipelines/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
- if can?(current_user, :create_environment, @project) && !@environments.blank?
.top-area
.nav-controls
diff --git a/app/views/projects/environments/show.html.haml b/app/views/projects/environments/show.html.haml
index 4c15e2759d6..53c62ef234d 100644
--- a/app/views/projects/environments/show.html.haml
+++ b/app/views/projects/environments/show.html.haml
@@ -2,7 +2,7 @@
- page_title "Environments"
= render "projects/pipelines/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.col-md-9
%h3.page-title= @environment.name.titleize
diff --git a/app/views/projects/graphs/ci.html.haml b/app/views/projects/graphs/ci.html.haml
index e695d3ae369..6be4273b6ab 100644
--- a/app/views/projects/graphs/ci.html.haml
+++ b/app/views/projects/graphs/ci.html.haml
@@ -2,7 +2,7 @@
- page_title "Continuous Integration", "Graphs"
= render 'head'
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
.oneline
A collection of graphs for Continuous Integration
diff --git a/app/views/projects/graphs/commits.html.haml b/app/views/projects/graphs/commits.html.haml
index 0daffe68f6f..65db8af494d 100644
--- a/app/views/projects/graphs/commits.html.haml
+++ b/app/views/projects/graphs/commits.html.haml
@@ -2,7 +2,7 @@
- page_title "Commits", "Graphs"
= render 'head'
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
.tree-ref-holder
= render 'shared/ref_switcher', destination: 'graphs_commits'
diff --git a/app/views/projects/graphs/languages.html.haml b/app/views/projects/graphs/languages.html.haml
index 6d97f552a8e..fcfcae0be20 100644
--- a/app/views/projects/graphs/languages.html.haml
+++ b/app/views/projects/graphs/languages.html.haml
@@ -2,7 +2,7 @@
- page_title "Languages", "Graphs"
= render 'head'
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
.oneline
Programming languages used in this repository
diff --git a/app/views/projects/graphs/show.html.haml b/app/views/projects/graphs/show.html.haml
index 9f7e2a361ff..a985b442b2d 100644
--- a/app/views/projects/graphs/show.html.haml
+++ b/app/views/projects/graphs/show.html.haml
@@ -2,7 +2,7 @@
- page_title "Contributors", "Graphs"
= render 'head'
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
.tree-ref-holder
= render 'shared/ref_switcher', destination: 'graphs'
diff --git a/app/views/projects/imports/new.html.haml b/app/views/projects/imports/new.html.haml
index a8a8caf7280..2cd8d03e30e 100644
--- a/app/views/projects/imports/new.html.haml
+++ b/app/views/projects/imports/new.html.haml
@@ -10,7 +10,7 @@
.panel-body
%pre
:preserve
- #{sanitize_repo_path(@project.import_error)}
+ #{sanitize_repo_path(@project, @project.import_error)}
= form_for @project, url: namespace_project_import_path(@project.namespace, @project), method: :post, html: { class: 'form-horizontal' } do |f|
= render "shared/import_form", f: f
diff --git a/app/views/projects/issues/index.html.haml b/app/views/projects/issues/index.html.haml
index cd876b5ea62..7ce4c1e5555 100644
--- a/app/views/projects/issues/index.html.haml
+++ b/app/views/projects/issues/index.html.haml
@@ -6,7 +6,7 @@
- if current_user
= auto_discovery_link_tag(:atom, namespace_project_issues_url(@project.namespace, @project, :atom, private_token: current_user.private_token), title: "#{@project.name} issues")
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
= render 'shared/issuable/nav', type: :issues
.nav-controls
diff --git a/app/views/projects/labels/index.html.haml b/app/views/projects/labels/index.html.haml
index aa4d69550ec..db66a0edbd8 100644
--- a/app/views/projects/labels/index.html.haml
+++ b/app/views/projects/labels/index.html.haml
@@ -3,7 +3,7 @@
- hide_class = ''
= render "projects/issues/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area.adjust
.nav-text
Labels can be applied to issues and merge requests. Star a label to make it a priority label. Order the prioritized labels to change their relative priority, by dragging.
diff --git a/app/views/projects/merge_requests/index.html.haml b/app/views/projects/merge_requests/index.html.haml
index 9f948d41dda..ace275c689b 100644
--- a/app/views/projects/merge_requests/index.html.haml
+++ b/app/views/projects/merge_requests/index.html.haml
@@ -3,7 +3,7 @@
= render "projects/issues/head"
= render 'projects/last_push'
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
= render 'shared/issuable/nav', type: :merge_requests
.nav-controls
diff --git a/app/views/projects/milestones/index.html.haml b/app/views/projects/milestones/index.html.haml
index b0e0bdfff5a..ad2bfbec915 100644
--- a/app/views/projects/milestones/index.html.haml
+++ b/app/views/projects/milestones/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Milestones"
= render "projects/issues/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
= render 'shared/milestones_filter'
diff --git a/app/views/projects/network/_head.html.haml b/app/views/projects/network/_head.html.haml
index 86295a3d011..8f6805268d5 100644
--- a/app/views/projects/network/_head.html.haml
+++ b/app/views/projects/network/_head.html.haml
@@ -1,6 +1,6 @@
- @no_container = true
-%div{ class: (container_class) }
+%div{ class: container_class }
.row-content-block.second-block.content-component-block
.tree-ref-holder
= render partial: 'shared/ref_switcher', locals: {destination: 'graph'}
diff --git a/app/views/projects/network/show.html.haml b/app/views/projects/network/show.html.haml
index 3ca30b4ba6b..091af4df4a1 100644
--- a/app/views/projects/network/show.html.haml
+++ b/app/views/projects/network/show.html.haml
@@ -4,7 +4,7 @@
= page_specific_javascript_tag('network/application.js')
= render "projects/commits/head"
= render "head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.project-network
.controls
= form_tag namespace_project_network_path(@project.namespace, @project, @id), method: :get, class: 'form-inline network-form' do |f|
diff --git a/app/views/projects/new.html.haml b/app/views/projects/new.html.haml
index 3c1c6060504..05f33b78a47 100644
--- a/app/views/projects/new.html.haml
+++ b/app/views/projects/new.html.haml
@@ -1,110 +1,115 @@
- page_title 'New Project'
- header_title "Projects", dashboard_projects_path
-%h3.page-title
- New Project
-%hr
-
.project-edit-container
.project-edit-errors
= render 'projects/errors'
- .project-edit-content
-
- = form_for @project, html: { class: 'new_project form-horizontal js-requires-input' } do |f|
- .form-group
- = f.label :path, class: 'control-label' do
- Project owner
- .col-sm-10
- = f.select :namespace_id, namespaces_options(:current_user), {}, {class: 'select2 js-select-namespace', tabindex: 1}
-
- - if current_user.can_create_group?
- .help-block
- Want to house several dependent projects under the same namespace?
- = link_to "Create a group", new_group_path
-
- .form-group
- = f.label :path, class: 'control-label' do
- Project name
- .col-sm-10
- = f.text_field :path, placeholder: "my-awesome-project", class: "form-control", tabindex: 2, autofocus: true, required: true
-
- - if import_sources_enabled?
- .project-import.js-toggle-container
- .form-group
- %label.control-label Import project from
- .col-sm-10
- - if github_import_enabled?
- - if github_import_configured?
- = link_to status_import_github_path, class: 'btn import_github' do
- %i.fa.fa-github
- GitHub
- - else
- = link_to '#', class: 'how_to_import_link btn import_github' do
- %i.fa.fa-github
- GitHub
- = render 'github_import_modal'
+ .row.prepend-top-default
+ .col-lg-3.profile-settings-sidebar
+ %h4.prepend-top-0
+ New project
+ %p
+ Create or Import your project from popular Git services
+ .col-lg-9
+ = form_for @project, html: { class: 'new_project' } do |f|
+ %fieldset.append-bottom-0
+ .form-group.col-xs-12.col-sm-6
+ = f.label :namespace_id, class: 'label-light' do
+ %span
+ Project path
+ .form-group
+ .input-group
+ - if current_user.can_select_namespace?
+ .input-group-addon
+ = root_url
+ = f.select :namespace_id, namespaces_options(params[:namespace_id] || :current_user, display_path: true), {}, {class: 'select2 js-select-namespace', tabindex: 1}
- - if bitbucket_import_enabled?
- - if bitbucket_import_configured?
- = link_to status_import_bitbucket_path, class: 'btn import_bitbucket', "data-no-turbolink" => "true" do
- %i.fa.fa-bitbucket
- Bitbucket
- else
- = link_to status_import_bitbucket_path, class: 'how_to_import_link btn import_bitbucket', "data-no-turbolink" => "true" do
- %i.fa.fa-bitbucket
- Bitbucket
- = render 'bitbucket_import_modal'
-
- - if gitlab_import_enabled?
- - if gitlab_import_configured?
- = link_to status_import_gitlab_path, class: 'btn import_gitlab' do
- %i.fa.fa-heart
- GitLab.com
- - else
- = link_to status_import_gitlab_path, class: 'how_to_import_link btn import_gitlab' do
- %i.fa.fa-heart
- GitLab.com
- = render 'gitlab_import_modal'
-
- - if gitorious_import_enabled?
- = link_to new_import_gitorious_path, class: 'btn import_gitorious' do
- %i.icon-gitorious.icon-gitorious-small
- Gitorious.org
-
- - if google_code_import_enabled?
- = link_to new_import_google_code_path, class: 'btn import_google_code' do
- %i.fa.fa-google
- Google Code
-
- - if fogbugz_import_enabled?
- = link_to new_import_fogbugz_path, class: 'btn import_fogbugz' do
- %i.fa.fa-bug
- Fogbugz
-
- - if git_import_enabled?
- = link_to "#", class: 'btn js-toggle-button import_git' do
- %i.fa.fa-git
- %span Repo by URL
-
- - if gitlab_project_import_enabled?
- = link_to new_import_gitlab_project_path, class: 'btn import_gitlab_project project-submit' do
- %i.fa.fa-gitlab
- %span GitLab export
-
- .js-toggle-content.hide
- = render "shared/import_form", f: f
-
- .prepend-botton-10
-
- .form-group
- = f.label :description, class: 'control-label' do
- Description
- %span.light (optional)
- .col-sm-10
- = f.text_area :description, class: "form-control", rows: 3, maxlength: 250, tabindex: 3
- = render 'shared/visibility_level', f: f, visibility_level: default_project_visibility, can_change_visibility_level: true, form_model: @project
+ .input-group-addon.static-namespace
+ #{root_url}#{current_user.username}/
+ .form-group.col-xs-12.col-sm-6.project-path
+ = f.label :namespace_id, class: 'label-light' do
+ %span
+ Project name
+ = f.text_field :path, placeholder: "my-awesome-project", class: "form-control", tabindex: 2, autofocus: true, required: true
+ - if current_user.can_create_group?
+ .help-block
+ Want to house several dependent projects under the same namespace?
+ = link_to "Create a group", new_group_path
+
+ - if import_sources_enabled?
+ .project-import.js-toggle-container
+ .form-group.clearfix
+ = f.label :visibility_level, class: 'label-light' do
+ Import project from
+ .col-sm-12.import-buttons
+ %div
+ - if github_import_enabled?
+ = link_to new_import_github_path, class: 'btn import_github' do
+ = icon 'github', text: 'GitHub'
+ %div
+ - if bitbucket_import_enabled?
+ - if bitbucket_import_configured?
+ = link_to status_import_bitbucket_path, class: 'btn import_bitbucket', "data-no-turbolink" => "true" do
+ %i.fa.fa-bitbucket
+ Bitbucket
+ - else
+ = link_to status_import_bitbucket_path, class: 'how_to_import_link btn import_bitbucket', "data-no-turbolink" => "true" do
+ %i.fa.fa-bitbucket
+ Bitbucket
+ = render 'bitbucket_import_modal'
+ %div
+ - if gitlab_import_enabled?
+ - if gitlab_import_configured?
+ = link_to status_import_gitlab_path, class: 'btn import_gitlab' do
+ %i.fa.fa-heart
+ GitLab.com
+ - else
+ = link_to status_import_gitlab_path, class: 'how_to_import_link btn import_gitlab' do
+ %i.fa.fa-heart
+ GitLab.com
+ = render 'gitlab_import_modal'
+ %div
+ - if gitorious_import_enabled?
+ = link_to new_import_gitorious_path, class: 'btn import_gitorious' do
+ %i.icon-gitorious.icon-gitorious-small
+ Gitorious.org
+ %div
+ - if google_code_import_enabled?
+ = link_to new_import_google_code_path, class: 'btn import_google_code' do
+ %i.fa.fa-google
+ Google Code
+ %div
+ - if fogbugz_import_enabled?
+ = link_to new_import_fogbugz_path, class: 'btn import_fogbugz' do
+ %i.fa.fa-bug
+ Fogbugz
+ %div
+ - if git_import_enabled?
+ = link_to "#", class: 'btn js-toggle-button import_git' do
+ %i.fa.fa-git
+ %span Repo by URL
+ %div
+ - if gitlab_project_import_enabled?
+ = link_to new_import_gitlab_project_path, class: 'btn import_gitlab_project project-submit' do
+ %i.fa.fa-gitlab
+ %span GitLab export
+
+ .js-toggle-content.hide
+ = render "shared/import_form", f: f
+
+ .form-group
+ = f.label :description, class: 'label-light' do
+ Project description
+ %span.light (optional)
+ = f.text_area :description, placeholder: 'Description format', class: "form-control", rows: 3, maxlength: 250
+
+ .form-group.project-visibility-level-holder
+ = f.label :visibility_level, class: 'label-light' do
+ Visibility Level
+ = link_to "(?)", help_page_path("public_access", "public_access")
+ = render('shared/visibility_radios', model_method: :visibility_level, form: f, selected_level: @project.visibility_level, form_model: @project)
- .form-actions
= f.submit 'Create project', class: "btn btn-create project-submit", tabindex: 4
= link_to 'Cancel', dashboard_projects_path, class: 'btn btn-cancel'
diff --git a/app/views/projects/notes/_note.html.haml b/app/views/projects/notes/_note.html.haml
index a5e163b91e9..af0046886fb 100644
--- a/app/views/projects/notes/_note.html.haml
+++ b/app/views/projects/notes/_note.html.haml
@@ -17,7 +17,7 @@
%a{ href: "##{dom_id(note)}" }
= time_ago_with_tooltip(note.created_at, placement: 'bottom', html_class: 'note-created-ago')
.note-actions
- - access = note.project.team.human_max_access(note.author.id)
+ - access = note_max_access_for_user(note)
- if access and not note.system
%span.note-role.hidden-xs= access
- if current_user and not note.system
diff --git a/app/views/projects/pipelines/index.html.haml b/app/views/projects/pipelines/index.html.haml
index b70693eeb62..28b475d5c2f 100644
--- a/app/views/projects/pipelines/index.html.haml
+++ b/app/views/projects/pipelines/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Pipelines"
= render "projects/pipelines/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
%ul.nav-links
%li{class: ('active' if @scope.nil?)}
diff --git a/app/views/projects/show.html.haml b/app/views/projects/show.html.haml
index 15f0d85194b..f6e81af2638 100644
--- a/app/views/projects/show.html.haml
+++ b/app/views/projects/show.html.haml
@@ -13,7 +13,7 @@
= render "home_panel"
.project-stats.row-content-block.second-block
- %div{ class: (container_class) }
+ %div{ class: container_class }
%ul.nav
%li
= link_to project_files_path(@project) do
diff --git a/app/views/projects/tags/index.html.haml b/app/views/projects/tags/index.html.haml
index 4ca1f58ac5c..c375bb6dd1b 100644
--- a/app/views/projects/tags/index.html.haml
+++ b/app/views/projects/tags/index.html.haml
@@ -2,7 +2,7 @@
- page_title "Tags"
= render "projects/commits/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.nav-text
Tags give the ability to mark specific points in history as being important
@@ -25,7 +25,7 @@
= sort_title_oldest_updated
.tags
- - unless @tags.empty?
+ - if @tags.any?
%ul.content-list
= render partial: 'tag', collection: @tags
diff --git a/app/views/projects/tree/show.html.haml b/app/views/projects/tree/show.html.haml
index 2abcfcdd7b2..bf5360b4dee 100644
--- a/app/views/projects/tree/show.html.haml
+++ b/app/views/projects/tree/show.html.haml
@@ -7,7 +7,7 @@
= render 'projects/last_push'
= render "projects/commits/head"
-%div{ class: (container_class) }
+%div{ class: container_class }
.tree-controls
= render 'projects/find_file_link'
- if can? current_user, :download_code, @project
diff --git a/app/views/projects/wikis/_new.html.haml b/app/views/projects/wikis/_new.html.haml
index 4f8abcdc8e1..c32cb122c26 100644
--- a/app/views/projects/wikis/_new.html.haml
+++ b/app/views/projects/wikis/_new.html.haml
@@ -1,6 +1,6 @@
- @no_container = true
-%div{ class: (container_class) }
+%div{ class: container_class }
%div#modal-new-wiki.modal
.modal-dialog
.modal-content
diff --git a/app/views/projects/wikis/edit.html.haml b/app/views/projects/wikis/edit.html.haml
index 817bf9b3f69..233538bb488 100644
--- a/app/views/projects/wikis/edit.html.haml
+++ b/app/views/projects/wikis/edit.html.haml
@@ -2,7 +2,7 @@
- page_title "Edit", @page.title.capitalize, "Wiki"
= render 'nav'
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.nav-text
%strong
diff --git a/app/views/projects/wikis/git_access.html.haml b/app/views/projects/wikis/git_access.html.haml
index 6caf7230f35..b8811a28dd6 100644
--- a/app/views/projects/wikis/git_access.html.haml
+++ b/app/views/projects/wikis/git_access.html.haml
@@ -2,7 +2,7 @@
- page_title "Git Access", "Wiki"
= render 'nav'
-%div{ class: (container_class) }
+%div{ class: container_class }
.sub-header-block
%span.oneline
Git access for
diff --git a/app/views/projects/wikis/history.html.haml b/app/views/projects/wikis/history.html.haml
index 630ee35b70b..4c0b14e2c42 100644
--- a/app/views/projects/wikis/history.html.haml
+++ b/app/views/projects/wikis/history.html.haml
@@ -1,6 +1,6 @@
- page_title "History", @page.title.capitalize, "Wiki"
= render 'nav'
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.nav-text
%strong
diff --git a/app/views/projects/wikis/pages.html.haml b/app/views/projects/wikis/pages.html.haml
index 81d9f391c1c..9c10acd4cb6 100644
--- a/app/views/projects/wikis/pages.html.haml
+++ b/app/views/projects/wikis/pages.html.haml
@@ -3,7 +3,7 @@
= render 'nav'
-%div{ class: (container_class) }
+%div{ class: container_class }
%ul.content-list
- @wiki_pages.each do |wiki_page|
%li
diff --git a/app/views/projects/wikis/show.html.haml b/app/views/projects/wikis/show.html.haml
index 76f9b1ecd76..5cebb538cf5 100644
--- a/app/views/projects/wikis/show.html.haml
+++ b/app/views/projects/wikis/show.html.haml
@@ -2,7 +2,7 @@
- page_title @page.title.capitalize, "Wiki"
= render 'nav'
-%div{ class: (container_class) }
+%div{ class: container_class }
.top-area
.nav-text
%strong= @page.title.capitalize
diff --git a/app/views/shared/_file_highlight.html.haml b/app/views/shared/_file_highlight.html.haml
index ad944a19ca1..e26693bf5b9 100644
--- a/app/views/shared/_file_highlight.html.haml
+++ b/app/views/shared/_file_highlight.html.haml
@@ -1,3 +1,5 @@
+- repository = nil unless local_assigns.key?(:repository)
+
.file-content.code.js-syntax-highlight
.line-numbers
- if blob.data.present?
@@ -11,4 +13,4 @@
= link_icon
= i
.blob-content{data: {blob_id: blob.id}}
- = highlight(blob.name, blob.data, plain: blob.no_highlighting?)
+ = highlight(blob.path, blob.data, repository: repository, plain: blob.no_highlighting?)
diff --git a/app/views/shared/_labels_row.html.haml b/app/views/shared/_labels_row.html.haml
index 87028ececd4..5507a05f6c1 100644
--- a/app/views/shared/_labels_row.html.haml
+++ b/app/views/shared/_labels_row.html.haml
@@ -1,6 +1,6 @@
- labels.each do |label|
%span.label-row.btn-group{ role: "group", aria: { label: escape_once(label.name) }, style: "color: #{text_color_for_bg(label.color)}" }
- = link_to namespace_project_label_path(@project.namespace, @project, label),
+ = link_to label_filter_path(@project, label, type: controller.controller_name),
class: "btn btn-transparent has-tooltip",
style: "background-color: #{label.color};",
title: escape_once(label.description),
diff --git a/app/views/users/calendar_activities.html.haml b/app/views/users/calendar_activities.html.haml
index 630d97e339d..f51599212db 100644
--- a/app/views/users/calendar_activities.html.haml
+++ b/app/views/users/calendar_activities.html.haml
@@ -14,7 +14,7 @@
- else
= event_action_name(event)
- if event.target
- %strong= link_to "##{event.target_iid}", [event.project.namespace.becomes(Namespace), event.project, event.target]
+ %strong= link_to "#{event.target.to_reference}", [event.project.namespace.becomes(Namespace), event.project, event.target]
at
%strong