Commit 3d1a246f authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge pull request #7697 from Razer6/fix_project_shortcuts

Change keyboard shortcut for activity to project
parents 69c4026e 7f7bf86b
......@@ -3,7 +3,7 @@
class @ShortcutsNavigation extends Shortcuts
constructor: ->
super()
Mousetrap.bind('g a', -> ShortcutsNavigation.findAndollowLink('.shortcuts-activity'))
Mousetrap.bind('g p', -> ShortcutsNavigation.findAndollowLink('.shortcuts-project'))
Mousetrap.bind('g f', -> ShortcutsNavigation.findAndollowLink('.shortcuts-tree'))
Mousetrap.bind('g c', -> ShortcutsNavigation.findAndollowLink('.shortcuts-commits'))
Mousetrap.bind('g n', -> ShortcutsNavigation.findAndollowLink('.shortcuts-network'))
......
......@@ -78,9 +78,9 @@
%tr
%td.shortcut
.key g
.key a
.key p
%td
Go to the activity feed
Go to the project's activity feed
%tr
%td.shortcut
.key g
......
%ul.project-navigation
= nav_link(path: 'projects#show', html_options: {class: "home"}) do
= link_to project_path(@project), title: 'Project', class: 'shortcuts-activity' do
= link_to project_path(@project), title: 'Project', class: 'shortcuts-project' do
Project
- if project_nav_tab? :files
= nav_link(controller: %w(tree blob blame edit_tree new_tree)) do
......
......@@ -44,3 +44,9 @@ Feature: Project shortcuts
Scenario: Navigate to wiki tab
Given I press "g" and "w"
Then the active main tab should be Wiki
@javascript
Scenario: Navigate to project feed
Given I visit my project's files page
Given I press "g" and "p"
Then the active main tab should be Home
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