Skip to main content
April 19, 2024
Question

Why is row height not "hugging" the button correctly?

I have this table cell that has a swappable component inside of it. If i swap the default content of the cell with a button, the cell i expect the cell to “hug” the button / expand in height. Instead the button height does not change regardless of set size - sm, md, lg. What am i missing?

This topic has been closed for replies.

8 replies

Pavel_Kiselev
Power Member
April 19, 2024

Try figure out with details you provided

unfold_UXAuthor
April 19, 2024

This makes it clearer, i hope:

Pavel_Kiselev
Power Member
April 19, 2024

Wondering what do you see when you select a button inside that cell? Does it show it hugs or fixed?

unfold_UXAuthor
April 19, 2024

The button inside has a fixed height

Nate_G
Power Member
April 19, 2024

@unfold_UX

Double check that:

  • The button components are using auto-layout → hug/hug
  • The button instance inside your cell component → hug/hug
  • The main cell component is also auto-layout and has “hug” set on the height.

→ Get Example File

Nate G
Pavel_Kiselev
Power Member
April 19, 2024

That’s the root cause, once you fix that to hug contents you’ll be fine

unfold_UXAuthor
April 26, 2024

That fixed it. Thank you!

unfold_UXAuthor
April 26, 2024

Absolutely! Thank you!