BigW Consortium Gitlab

Commit 4306c0b4 by geoandri Committed by George Andrinopoulos

Refactor shortcuts_wiki.js

parent 3c2596f7
......@@ -35,7 +35,6 @@ import './shortcuts_navigation';
import './shortcuts_find_file';
import './shortcuts_issuable';
import './shortcuts_network';
import './shortcuts_wiki';
// behaviors
import './behaviors/';
......
/* 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');
}
}
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