Instance swap issue. Height set to fixed

I’m experiencing an issue with an instance swap property in Figma. I have a Card component with Auto-layout (width: fixed, and height: hug). It wraps an instance of a component associated with an instance swap property (width: fill and height: hug).
When I create an instance of Card and change the inner instance through the instance property it works fine the first time. From there, if I change it again, Figma sets the height of the inner instance to fixed. This crops the content.

Does anyone knows why this happens and how to fix it? Is it a bug in Figma?

File here:

Hey Pablo, thank you for reaching out with a screen recoding and a link to your file. This looks like a bug to me. I’ve created a support ticket on your behalf, so that our technical quality team can take a look at this. Your ticket number is #849291, for reference.