rebus-ink / reader-frontend

Front end web app for Rebus Ink
https://rebus.ink
GNU Affero General Public License v3.0
3 stars 3 forks source link

Highlighting a whole paragraph also highlights the next paragraph (or part of it) #88

Open Marie000 opened 5 years ago

Marie000 commented 5 years ago

Working on Chrome.

Highlights work ok when I do a part of a paragraph, but when I highlight a whole paragraph, it also highlights from the next paragraph. Sometimes it's part of the next paragraph, sometimes part of it.

Marie000 commented 5 years ago

What I was trying to highlight: Screenshot from 2019-07-23 11-17-14

What the highlights looks like: Screenshot from 2019-07-23 11-17-32

I tried reloading to see the highlight again but it looks like my chapter navigation is all mixed up and I can't find the chapter again. Will update if I find the highlight.

update: highlight is gone :-(

baldurbjarnason commented 5 years ago

Making the highlight match the selection is a question of normalising the ranges in the DOM (i.e. making sure that text nodes are split at the correct locations. Fixing shouldn't be too hard.

Disappearing highlights is a separate bug, though so if it's still happening can you please file it as a separate bug.