Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with ENTER key and left over marked block... #35

Closed
AzzaAzza69 opened this issue Apr 26, 2023 · 3 comments
Closed

Issue with ENTER key and left over marked block... #35

AzzaAzza69 opened this issue Apr 26, 2023 · 3 comments
Assignees

Comments

@AzzaAzza69
Copy link

When lines are marked up, the ENTER key deletes the text but block marks up any text that follows.

steps to reproduce:
mark up the word block in this sentence and press enter, you will get a new line but " in t" will still be marked up as opposed to expected behaviour of new line and cursor in front of " in this...".

@WebCoder49
Copy link
Owner

Thank you for pointing this out and the many other contributions you have made via issues. I am afraid that I may not be able to address this until late June due to being very busy at the moment, but will try to address it ASAP.

I have one question: are you using the indent plugin? If so, this line could be changed to replace selection_end with selection_start.

input_element.selectionEnd = selection_end + number_indents + 1;

Once you confirm, I will amend this and test it as soon as I have time.

@WebCoder49 WebCoder49 self-assigned this Apr 26, 2023
@AzzaAzza69
Copy link
Author

I haven't downloaded the latest version, I only tried out the online demo @ https://codepen.io/WebCoder49/details/jOypJOx

@WebCoder49
Copy link
Owner

Yes, that does use the indent plugin. Thank you for the quick reply.

WebCoder49 added a commit that referenced this issue Apr 27, 2023
Remove selections after ENTER, so caret doesn't select new text. #35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants