Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
4306c0b4
Commit
4306c0b4
authored
Apr 10, 2017
by
geoandri
Committed by
George Andrinopoulos
Apr 11, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor shortcuts_wiki.js
parent
3c2596f7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
app/assets/javascripts/main.js
app/assets/javascripts/main.js
+0
-1
app/assets/javascripts/shortcuts_wiki.js
app/assets/javascripts/shortcuts_wiki.js
+5
-3
No files found.
app/assets/javascripts/main.js
View file @
4306c0b4
...
...
@@ -35,7 +35,6 @@ import './shortcuts_navigation';
import
'
./shortcuts_find_file
'
;
import
'
./shortcuts_issuable
'
;
import
'
./shortcuts_network
'
;
import
'
./shortcuts_wiki
'
;
// behaviors
import
'
./behaviors/
'
;
...
...
app/assets/javascripts/shortcuts_wiki.js
View file @
4306c0b4
/* eslint-disable class-methods-use-this */
/* global Mousetrap */
/* global ShortcutsNavigation */
import
findAndFollowLink
from
'
./shortcuts_dashboard_navigation
'
;
export
default
class
ShortcutsWiki
extends
ShortcutsNavigation
{
constructor
()
{
super
();
this
.
$wikiEdit
=
$
(
'
.wiki-edit
'
);
Mousetrap
.
bind
(
'
e
'
,
this
.
editWiki
.
bind
(
this
));
Mousetrap
.
bind
(
'
e
'
,
this
.
editWiki
);
}
editWiki
()
{
gl
.
utils
.
visitUrl
(
this
.
$wikiEdit
.
attr
(
'
href
'
)
);
findAndFollowLink
(
'
.wiki-edit
'
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment