I created a function which tracks who wrote what on the canvas. I add the userId to the Step before dispatching it or when receiving it from the server and later on the function uses that information to do the tracking: https://github.com/FelipeTaiarol/ProseMirror-Author-Tracking/blob/master/index.ts The code was based on the tracking example: https://github.com/ProseMirror/website/blob/master/pages/examples/track/example.js
Everything works fine but now I would like to track the position relative to a given node instead of using the absolute position. The reason for that is that I want to be able to move that node around without overriding the tracking information.
If I use the absolute position when I move the node around the absolute position changes so the tracking information is lost, if the tracking information was relative to the node I am moving I think everything would work.
Does anybody know how I could make it work ?