Component should follow mouse cursor

I want to achieve the following: If I hover the cursor over a certain element (like an absolute layout) a Vaadin component should appear and follow the cursor. Using a custom

instead of a Vaadin component would also be acceptable.
It is important though that I can a) define the component’s position, relative to the mouse cursor and b) that I can show different components/
s, depending on the Element the curser is currently hovering over.

The idea is that the attached component will be placed in the absolute layout once the mouse is clicked.

Does anybody know how this could be achieved using Vaadin/CSS/whatever?

PS: Just to clarify the problem, I made a small image.

You might be able to do this using a Javascript extension with JQuery (
The JS could look like: