How does the Elements CMS work together with Modals?

How does the CMS work together with Modals?

Does anyone here have experience with this?

I’d like to display certain data from my CMS Collection inside a Modal.

The data within the Collection itself is displayed correctly. However, when I click the corresponding trigger to open the Modal, the data is not shown as expected.

Do I need to define a specific trigger ID in the Markdown file, or what’s the best way to handle this?

Has anyone here already worked with this setup?