added keybindings for focus on codemirror through Mousetrap
This commit is contained in:
@ -2,7 +2,8 @@ window.common = (function(global) {
|
|||||||
const {
|
const {
|
||||||
$,
|
$,
|
||||||
Rx: { Observable },
|
Rx: { Observable },
|
||||||
common = { init: [] }
|
common = { init: [] },
|
||||||
|
Mousetrap
|
||||||
} = global;
|
} = global;
|
||||||
|
|
||||||
common.ctrlEnterClickHandler = function ctrlEnterClickHandler(e) {
|
common.ctrlEnterClickHandler = function ctrlEnterClickHandler(e) {
|
||||||
@ -42,6 +43,11 @@ window.common = (function(global) {
|
|||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// set focus keybind
|
||||||
|
Mousetrap.bind(['command+shift+e', 'ctrl+shift+e'], () => {
|
||||||
|
common.editor.focus();
|
||||||
|
});
|
||||||
|
|
||||||
// video checklist binding
|
// video checklist binding
|
||||||
$('.challenge-list-checkbox').on('change', function() {
|
$('.challenge-list-checkbox').on('change', function() {
|
||||||
var checkboxId = $(this).parent().parent().attr('id');
|
var checkboxId = $(this).parent().parent().attr('id');
|
||||||
|
Reference in New Issue
Block a user