mirror of
https://github.com/fastmail/Squire.git
synced 2024-12-22 15:23:29 -05:00
Markup links on 'enter' too.
* Check for links in the current text node, and add <a> tags if found, when the enter key is pressed, not just when the spacebar is pressed.
This commit is contained in:
parent
f49d1c190e
commit
45711a38a4
1 changed files with 2 additions and 1 deletions
|
@ -1383,8 +1383,9 @@
|
|||
var range = getSelection();
|
||||
if ( !range ) { return; }
|
||||
|
||||
// Save undo checkpoint
|
||||
// Save undo checkpoint and add any links in the preceding section.
|
||||
recordUndoState( range );
|
||||
addLinks( range.startContainer );
|
||||
getRangeAndRemoveBookmark( range );
|
||||
|
||||
// Selected text is overwritten, therefore delete the contents
|
||||
|
|
Loading…
Reference in a new issue