Skip to main content
Solved

Component replacement does not adjust the height

  • February 25, 2022
  • 2 replies
  • 2759 views

Bruno_Quaresma

Hey folks, I have a component called Section and this component has an image, which is a component, and a grouped text.

Issue: When I create an instance of the Section component and replace the image component to use another one I would expect the Section component to fit the height of the new image component, but that does not happen.

Link to the Figma file: https://www.figma.com/file/a1BQbulSnwJekRVTwGbPg7/Untitled?node-id=0%3A1

Best answer by tank666

I edited your file and now instance swap works as expected. I added Auto Layout to each of the components, and wrapped the nested content in a frame with a fixed width and height.

Figma – 25 Feb 22
View original
This topic has been closed for comments

2 replies

tank666
  • 4861 replies
  • Answer
  • February 25, 2022

I edited your file and now instance swap works as expected. I added Auto Layout to each of the components, and wrapped the nested content in a frame with a fixed width and height.

Figma – 25 Feb 22

Manuel21
  • 19 replies
  • July 5, 2022

I’m having this problem, it would be good to have a clarification as to exactly how this was resolved. I have components that work exactly as expected except when I use them to replace other components, then hell breaks loose…
I’m finding the behaviour completely inconsistent which makes it very hard to troubleshoot. In some cases, the component is squashed in others, while swapping from exactly the same one it works…


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings