Commit 7c5bf937 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge branch 'master' into ui-improvements

parents 88b48017 e46f546b
...@@ -44,6 +44,6 @@ $added: #63c363; ...@@ -44,6 +44,6 @@ $added: #63c363;
$deleted: #f77; $deleted: #f77;
/** /**
* * NProgress customize
*/ */
$nprogress-color: #3498db; $nprogress-color: #3498db;
...@@ -96,7 +96,7 @@ ...@@ -96,7 +96,7 @@
} }
} }
@media(min-width:768px) { @mixin expanded-sidebar {
.page-with-sidebar { .page-with-sidebar {
padding-left: 250px; padding-left: 250px;
} }
...@@ -121,3 +121,44 @@ ...@@ -121,3 +121,44 @@
border-left: 1px solid #EAEAEA; border-left: 1px solid #EAEAEA;
} }
} }
@mixin folded-sidebar {
.page-with-sidebar {
padding-left: 50px;
}
.sidebar-wrapper {
width: 52px;
position: absolute;
left: 50px;
height: 100%;
margin-left: -50px;
.nav-sidebar {
margin-top: 20px;
position: fixed;
top: 45px;
width: 52px;
li a {
padding-left: 18px;
font-size: 14px;
padding: 10px 15px;
text-align: center;
& > span {
display: none;
}
}
}
}
}
@media (max-width: $screen-sm-max) {
@include folded-sidebar;
}
@media(min-width: $screen-sm-max) {
@include expanded-sidebar;
}
%ul.nav-sidebar.navbar-collapse.collapse %ul.nav.nav-sidebar
= nav_link(controller: :dashboard, html_options: {class: 'home'}) do = nav_link(controller: :dashboard, html_options: {class: 'home'}) do
= link_to admin_root_path, title: "Stats" do = link_to admin_root_path, title: "Stats" do
%i.fa.fa-dashboard
%span
Overview Overview
= nav_link(controller: :projects) do = nav_link(controller: :projects) do
= link_to "Projects", admin_projects_path = link_to admin_projects_path do
%i.fa.fa-cube
%span
Projects
= nav_link(controller: :users) do = nav_link(controller: :users) do
= link_to "Users", admin_users_path = link_to admin_users_path do
%i.fa.fa-users
%span
Users
= nav_link(controller: :groups) do = nav_link(controller: :groups) do
= link_to "Groups", admin_groups_path = link_to admin_groups_path do
%i.fa.fa-group
%span
Groups
= nav_link(controller: :logs) do = nav_link(controller: :logs) do
= link_to "Logs", admin_logs_path = link_to admin_logs_path do
%i.fa.fa-file-text
%span
Logs
= nav_link(controller: :broadcast_messages) do = nav_link(controller: :broadcast_messages) do
= link_to "Messages", admin_broadcast_messages_path = link_to admin_broadcast_messages_path do
%i.fa.fa-bullhorn
%span
Messages
= nav_link(controller: :hooks) do = nav_link(controller: :hooks) do
= link_to "Hooks", admin_hooks_path = link_to admin_hooks_path do
%i.fa.fa-external-link
%span
Hooks
= nav_link(controller: :background_jobs) do = nav_link(controller: :background_jobs) do
= link_to "Background Jobs", admin_background_jobs_path = link_to admin_background_jobs_path do
%i.fa.fa-cog
%span
Background Jobs
%ul.nav.nav-sidebar.navbar-collapse.collapse %ul.nav.nav-sidebar
= nav_link(path: 'dashboard#show', html_options: {class: 'home'}) do = nav_link(path: 'dashboard#show', html_options: {class: 'home'}) do
= link_to root_path, title: 'Home', class: 'shortcuts-activity' do = link_to root_path, title: 'Home', class: 'shortcuts-activity' do
%i.fa.fa-dashboard %i.fa.fa-dashboard
%span
Activity Activity
= nav_link(path: 'dashboard#projects') do = nav_link(path: 'dashboard#projects') do
= link_to projects_dashboard_path, class: 'shortcuts-projects' do = link_to projects_dashboard_path, class: 'shortcuts-projects' do
%i.fa.fa-cube %i.fa.fa-cube
%span
Projects Projects
= nav_link(path: 'dashboard#issues') do = nav_link(path: 'dashboard#issues') do
= link_to issues_dashboard_path, class: 'shortcuts-issues' do = link_to issues_dashboard_path, class: 'shortcuts-issues' do
%i.fa.fa-exclamation-circle %i.fa.fa-exclamation-circle
%span
Issues Issues
%span.count= current_user.assigned_issues.opened.count %span.count= current_user.assigned_issues.opened.count
= nav_link(path: 'dashboard#merge_requests') do = nav_link(path: 'dashboard#merge_requests') do
= link_to merge_requests_dashboard_path, class: 'shortcuts-merge_requests' do = link_to merge_requests_dashboard_path, class: 'shortcuts-merge_requests' do
%i.fa.fa-tasks %i.fa.fa-tasks
%span
Merge Requests Merge Requests
%span.count= current_user.assigned_merge_requests.opened.count %span.count= current_user.assigned_merge_requests.opened.count
= nav_link(controller: :help) do = nav_link(controller: :help) do
= link_to help_path do = link_to help_path do
%i.fa.fa-question-circle %i.fa.fa-question-circle
%span
Help Help
%ul.nav.nav-sidebar.navbar-collapse.collapse %ul.nav.nav-sidebar
= nav_link(path: 'groups#show', html_options: {class: 'home'}) do = nav_link(path: 'groups#show', html_options: {class: 'home'}) do
= link_to group_path(@group), title: "Home" do = link_to group_path(@group), title: "Home" do
%i.fa.fa-dashboard %i.fa.fa-dashboard
%span
Activity Activity
- if current_user - if current_user
= nav_link(controller: [:group, :milestones]) do = nav_link(controller: [:group, :milestones]) do
= link_to group_milestones_path(@group) do = link_to group_milestones_path(@group) do
%i.fa.fa-clock-o %i.fa.fa-clock-o
%span
Milestones Milestones
= nav_link(path: 'groups#issues') do = nav_link(path: 'groups#issues') do
= link_to issues_group_path(@group) do = link_to issues_group_path(@group) do
%i.fa.fa-exclamation-circle %i.fa.fa-exclamation-circle
%span
Issues Issues
- if current_user - if current_user
%span.count= Issue.opened.of_group(@group).count %span.count= Issue.opened.of_group(@group).count
= nav_link(path: 'groups#merge_requests') do = nav_link(path: 'groups#merge_requests') do
= link_to merge_requests_group_path(@group) do = link_to merge_requests_group_path(@group) do
%i.fa.fa-tasks %i.fa.fa-tasks
%span
Merge Requests Merge Requests
- if current_user - if current_user
%span.count= MergeRequest.opened.of_group(@group).count %span.count= MergeRequest.opened.of_group(@group).count
= nav_link(path: 'groups#members') do = nav_link(path: 'groups#members') do
= link_to members_group_path(@group) do = link_to members_group_path(@group) do
%i.fa.fa-users %i.fa.fa-users
%span
Members Members
- if can?(current_user, :manage_group, @group) - if can?(current_user, :manage_group, @group)
= nav_link(html_options: { class: "#{"active" if group_settings_page?} separate-item" }) do = nav_link(html_options: { class: "#{"active" if group_settings_page?} separate-item" }) do
= link_to edit_group_path(@group), class: "tab no-highlight" do = link_to edit_group_path(@group), class: "tab no-highlight" do
%i.fa.fa-cogs %i.fa.fa-cogs
%span
Settings Settings
%i.fa.fa-angle-down %i.fa.fa-angle-down
......
%ul.nav-sidebar.navbar-collapse.collapse %ul.nav.nav-sidebar
= nav_link(path: 'profiles#show', html_options: {class: 'home'}) do = nav_link(path: 'profiles#show', html_options: {class: 'home'}) do
= link_to profile_path, title: "Profile" do = link_to profile_path, title: "Profile" do
%i.fa.fa-user %i.fa.fa-user
%span
Profile Profile
= nav_link(controller: :accounts) do = nav_link(controller: :accounts) do
= link_to profile_account_path do = link_to profile_account_path do
...@@ -10,33 +11,40 @@ ...@@ -10,33 +11,40 @@
= nav_link(controller: :emails) do = nav_link(controller: :emails) do
= link_to profile_emails_path do = link_to profile_emails_path do
%i.fa.fa-envelope-o %i.fa.fa-envelope-o
%span
Emails Emails
%span.count= current_user.emails.count + 1 %span.count= current_user.emails.count + 1
- unless current_user.ldap_user? - unless current_user.ldap_user?
= nav_link(controller: :passwords) do = nav_link(controller: :passwords) do
= link_to edit_profile_password_path do = link_to edit_profile_password_path do
%i.fa.fa-lock %i.fa.fa-lock
%span
Password Password
= nav_link(controller: :notifications) do = nav_link(controller: :notifications) do
= link_to profile_notifications_path do = link_to profile_notifications_path do
%i.fa.fa-inbox %i.fa.fa-inbox
%span
Notifications Notifications
= nav_link(controller: :keys) do = nav_link(controller: :keys) do
= link_to profile_keys_path do = link_to profile_keys_path do
%i.fa.fa-key %i.fa.fa-key
%span
SSH Keys SSH Keys
%span.count= current_user.keys.count %span.count= current_user.keys.count
= nav_link(path: 'profiles#design') do = nav_link(path: 'profiles#design') do
= link_to design_profile_path do = link_to design_profile_path do
%i.fa.fa-image %i.fa.fa-image
%span
Design Design
= nav_link(controller: :groups) do = nav_link(controller: :groups) do
= link_to profile_groups_path do = link_to profile_groups_path do
%i.fa.fa-group %i.fa.fa-group
%span
Groups Groups
= nav_link(path: 'profiles#history') do = nav_link(path: 'profiles#history') do
= link_to history_profile_path do = link_to history_profile_path do
%i.fa.fa-history %i.fa.fa-history
%span
History History
%ul.project-navigation.nav.nav-sidebar.navbar-collapse.collapse %ul.project-navigation.nav.nav-sidebar
= nav_link(path: 'projects#show', html_options: {class: "home"}) do = nav_link(path: 'projects#show', html_options: {class: "home"}) do
= link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do = link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do
%i.fa.fa-dashboard %i.fa.fa-dashboard
%span
Project Project
- if project_nav_tab? :files - if project_nav_tab? :files
= nav_link(controller: %w(tree blob blame edit_tree new_tree)) do = nav_link(controller: %w(tree blob blame edit_tree new_tree)) do
= link_to project_tree_path(@project, @ref || @repository.root_ref), class: 'shortcuts-tree' do = link_to project_tree_path(@project, @ref || @repository.root_ref), class: 'shortcuts-tree' do
%i.fa.fa-files-o %i.fa.fa-files-o
%span
Files Files
...@@ -14,24 +16,28 @@ ...@@ -14,24 +16,28 @@
= nav_link(controller: %w(commit commits compare repositories tags branches)) do = nav_link(controller: %w(commit commits compare repositories tags branches)) do
= link_to project_commits_path(@project, @ref || @repository.root_ref), class: 'shortcuts-commits' do = link_to project_commits_path(@project, @ref || @repository.root_ref), class: 'shortcuts-commits' do
%i.fa.fa-history %i.fa.fa-history
%span
Commits Commits
- if project_nav_tab? :network - if project_nav_tab? :network
= nav_link(controller: %w(network)) do = nav_link(controller: %w(network)) do
= link_to project_network_path(@project, @ref || @repository.root_ref), class: 'shortcuts-network' do = link_to project_network_path(@project, @ref || @repository.root_ref), class: 'shortcuts-network' do
%i.fa.fa-code-fork %i.fa.fa-code-fork
%span
Network Network
- if project_nav_tab? :graphs - if project_nav_tab? :graphs
= nav_link(controller: %w(graphs)) do = nav_link(controller: %w(graphs)) do
= link_to project_graph_path(@project, @ref || @repository.root_ref), class: 'shortcuts-graphs' do = link_to project_graph_path(@project, @ref || @repository.root_ref), class: 'shortcuts-graphs' do
%i.fa.fa-area-chart %i.fa.fa-area-chart
%span
Graphs Graphs
- if project_nav_tab? :issues - if project_nav_tab? :issues
= nav_link(controller: %w(issues milestones labels)) do = nav_link(controller: %w(issues milestones labels)) do
= link_to url_for_project_issues, class: 'shortcuts-issues' do = link_to url_for_project_issues, class: 'shortcuts-issues' do
%i.fa.fa-exclamation-circle %i.fa.fa-exclamation-circle
%span
Issues Issues
- if @project.used_default_issues_tracker? - if @project.used_default_issues_tracker?
%span.count.issue_counter= @project.issues.opened.count %span.count.issue_counter= @project.issues.opened.count
...@@ -40,6 +46,7 @@ ...@@ -40,6 +46,7 @@
= nav_link(controller: :merge_requests) do = nav_link(controller: :merge_requests) do
= link_to project_merge_requests_path(@project), class: 'shortcuts-merge_requests' do = link_to project_merge_requests_path(@project), class: 'shortcuts-merge_requests' do
%i.fa.fa-tasks %i.fa.fa-tasks
%span
Merge Requests Merge Requests
%span.count.merge_counter= @project.merge_requests.opened.count %span.count.merge_counter= @project.merge_requests.opened.count
...@@ -47,18 +54,21 @@ ...@@ -47,18 +54,21 @@
= nav_link(controller: :wikis) do = nav_link(controller: :wikis) do
= link_to project_wiki_path(@project, :home), class: 'shortcuts-wiki' do = link_to project_wiki_path(@project, :home), class: 'shortcuts-wiki' do
%i.fa.fa-book %i.fa.fa-book
%span
Wiki Wiki
- if project_nav_tab? :snippets - if project_nav_tab? :snippets
= nav_link(controller: :snippets) do = nav_link(controller: :snippets) do
= link_to project_snippets_path(@project), class: 'shortcuts-snippets' do = link_to project_snippets_path(@project), class: 'shortcuts-snippets' do
%i.fa.fa-file-text-o %i.fa.fa-file-text-o
%span
Snippets Snippets
- if project_nav_tab? :settings - if project_nav_tab? :settings
= nav_link(html_options: {class: "#{project_tab_class} separate-item"}) do = nav_link(html_options: {class: "#{project_tab_class} separate-item"}) do
= link_to edit_project_path(@project), class: "stat-tab tab no-highlight" do = link_to edit_project_path(@project), class: "stat-tab tab no-highlight" do
%i.fa.fa-cogs %i.fa.fa-cogs
%span
Settings Settings
%i.fa.fa-angle-down %i.fa.fa-angle-down
......
...@@ -2,24 +2,30 @@ ...@@ -2,24 +2,30 @@
= nav_link(path: 'projects#edit') do = nav_link(path: 'projects#edit') do
= link_to edit_project_path(@project), class: "stat-tab tab " do = link_to edit_project_path(@project), class: "stat-tab tab " do
%i.fa.fa-pencil-square-o %i.fa.fa-pencil-square-o
%span
Project Project
= nav_link(controller: [:team_members, :teams]) do = nav_link(controller: [:team_members, :teams]) do
= link_to project_team_index_path(@project), class: "team-tab tab" do = link_to project_team_index_path(@project), class: "team-tab tab" do
%i.fa.fa-users %i.fa.fa-users
%span
Members Members
= nav_link(controller: :deploy_keys) do = nav_link(controller: :deploy_keys) do
= link_to project_deploy_keys_path(@project) do = link_to project_deploy_keys_path(@project) do
%i.fa.fa-key %i.fa.fa-key
%span
Deploy Keys Deploy Keys
= nav_link(controller: :hooks) do = nav_link(controller: :hooks) do
= link_to project_hooks_path(@project) do = link_to project_hooks_path(@project) do
%i.fa.fa-link %i.fa.fa-link
%span
Web Hooks Web Hooks
= nav_link(controller: :services) do = nav_link(controller: :services) do
= link_to project_services_path(@project) do = link_to project_services_path(@project) do
%i.fa.fa-cogs %i.fa.fa-cogs
%span
Services Services
= nav_link(controller: :protected_branches) do = nav_link(controller: :protected_branches) do
= link_to project_protected_branches_path(@project) do = link_to project_protected_branches_path(@project) do
%i.fa.fa-lock %i.fa.fa-lock
%span
Protected branches Protected branches
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment