8000 Can't set caret position in contenteditable div · Issue #8 · acdvorak/jquery.caret · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Can't set caret position in contenteditable div #8

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

Open
halid96 opened this issue Oct 31, 2022 · 0 comments
Open

Can't set caret position in contenteditable div #8

halid96 opened this issue Oct 31, 2022 · 0 comments

Comments

@halid96
Copy link
halid96 commented Oct 31, 2022

Everything is working normally and perfectly when the contenteditable div contains only text.

When I have tags inside, it fails... It only takes the first text node inside the contenteditable div... It supposes to calculate all the nodes (img, span, etc) inside the contenteditable text.

The image below shows contenteditable div containing images (emojis)...

When I am checking the caret position when the div contains the image element, it calculates it perfectly, with no errors, the problem is when setting the caret position.

Checking the caret position: console.log( $('#cmb-text').caret()

wqedad

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

1 participant
0