you should be able to write/acquire a hit-test function to see what DOM element(s) are under the mouse cursor when it is double-clicked, and then associate the comments/feedback text with the ID of the selected element
this assumes that all of your DOM elements have unique IDs
(and that your users know that they can do this!)