Popupmenu on Kanban card iD

If I put an icon on the Kanban item, I can click on it and the function will get the ID of the Kanban card.
But how to get the same data with a popup menu on an Kanban icon? There I just get the ID of the popup menu.

Hi,

As far as I understand the use-case, the best option is to use standalone popup and manage data in it according to the clicked icon (or item).
Please, check the following demo: Code Snippet