Closed raphael10-collab closed 1 year ago
A quick response, as I (nor others, it seems) get around to look further at your issue. From your description it’s not clear to me what you mean. If you mean to create a TextPositionSelector, see the describeTextPosition. Best to get the position of the selection before highlighting it (if you do both), because the highlighter will modify the dom and thereby the selection.
If you mean position as in coordinates on the page, you can get those from the browser’s APIs, e.g. Range.getBoundingClientRect
. I hope that helps.
The text is highlighted but I do not get the text position, needed for further annotating
This is the code I'm using: