https://kotlinlang.org logo
#compose
Title
# compose
d

darkmoon_uk

04/09/2022, 5:03 AM
Is there a way to effectively exclude an element from contributing to content wrapping metrics? See this WIP layout where each 'Build' has two rows. I want to horizontally wrap to the top row i.e. the "8663, date, 3" and to disregard/truncate the Git hash below it as far as necessary.
j

Jan Skrasek

04/09/2022, 5:08 AM
Put each row into own Row. The second one make fillMaxWidth and then let the wrapping Column have width(IntrinsicSize.Min)
a

Albert Chang

04/09/2022, 6:22 AM
I don't think that will work as the second row has a bigger intrinsic width. But you can easily achieve what you want using a custom layout.
☝️ 1
z

zalewski.se

04/09/2022, 7:53 AM
Is there a way to effectively exclude an element from contributing to content wrapping metrics?
Have you tried setting
unbounded = true
, like:
Copy code
.wrapContentWidth(unbounded = true)