mirror of https://github.com/laurent22/joplin.git
pull/4819/head
parent
9642f5f715
commit
1354c247b4
|
@ -34,11 +34,14 @@ joplin.plugins.register({
|
|||
Name: <input type="text" name="name"/>
|
||||
<br/>
|
||||
Email: <input type="text" name="email"/>
|
||||
<br/>
|
||||
Description: <textarea name="desc"></textarea>
|
||||
</form>
|
||||
`);
|
||||
|
||||
const result3 = await dialogs.open(handle3);
|
||||
console.info('Got result: ' + JSON.stringify(result3));
|
||||
|
||||
},
|
||||
|
||||
});
|
||||
|
|
|
@ -15,7 +15,13 @@ export default function(frameWindow: any, onSubmit: Function, onDismiss: Functio
|
|||
}
|
||||
|
||||
if (event.key === 'Enter') {
|
||||
if (onSubmit) onSubmit();
|
||||
//
|
||||
// Disable enter key from submitting when a text area is in focus!
|
||||
// https://github.com/laurent22/joplin/issues/4766
|
||||
//
|
||||
if (frameWindow.document.activeElement.tagName != 'TEXTAREA') {
|
||||
if (onSubmit) onSubmit();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue