mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-01-04 06:02:46 +00:00
initial commit, add hotkey definitions
This commit is contained in:
@@ -47,14 +47,18 @@ const CodeEditor = createClass({
|
|||||||
indentWithTabs : true,
|
indentWithTabs : true,
|
||||||
tabSize : 2,
|
tabSize : 2,
|
||||||
extraKeys : {
|
extraKeys : {
|
||||||
'Ctrl-B' : this.makeBold,
|
'Ctrl-B' : this.makeBold,
|
||||||
'Cmd-B' : this.makeBold,
|
'Cmd-B' : this.makeBold,
|
||||||
'Ctrl-I' : this.makeItalic,
|
'Ctrl-I' : this.makeItalic,
|
||||||
'Cmd-I' : this.makeItalic,
|
'Cmd-I' : this.makeItalic,
|
||||||
'Ctrl-M' : this.makeSpan,
|
'Ctrl-M' : this.makeSpan,
|
||||||
'Cmd-M' : this.makeSpan,
|
'Cmd-M' : this.makeSpan,
|
||||||
'Ctrl-/' : this.makeComment,
|
'Ctrl-/' : this.makeComment,
|
||||||
'Cmd-/' : this.makeComment
|
'Cmd-/' : this.makeComment,
|
||||||
|
'Ctrl-L' : this.makeUnOrderedList,
|
||||||
|
'Cmd-L' : this.makeUnOrderedList,
|
||||||
|
'Shift-Ctrl-L' : this.makeOrderedList,
|
||||||
|
'Shift-Cmd-L' : this.makeOrderedList
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -99,6 +103,10 @@ const CodeEditor = createClass({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
makeUnOrderedList : function() {
|
||||||
|
const selection = this.codeMirror.getSelection()
|
||||||
|
}
|
||||||
|
|
||||||
//=-- Externally used -==//
|
//=-- Externally used -==//
|
||||||
setCursorPosition : function(line, char){
|
setCursorPosition : function(line, char){
|
||||||
setTimeout(()=>{
|
setTimeout(()=>{
|
||||||
|
|||||||
Reference in New Issue
Block a user