fix enter on title to the code editor

This commit is contained in:
zadam 2019-07-03 20:29:55 +02:00
parent 6d2394a9da
commit e5036318af
2 changed files with 6 additions and 2 deletions

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "trilium",
"version": "0.33.5",
"version": "0.33.6",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@ -83,7 +83,11 @@ class TabContext {
if (utils.isDesktop()) {
// keyboard plugin is not loaded in mobile
this.$noteTitle.bind('keydown', 'return', () => this.getComponent().focus());
this.$noteTitle.bind('keydown', 'return', () => {
this.getComponent().focus();
return false; // to not propagate the enter into the editor (causes issues with codemirror)
});
}
this.$protectButton = this.$tabContent.find(".protect-button");