Closed willnwalker closed 3 months ago
Have u seen the ExpandableCard component?
Yes, this is a response to that component. I had to add an adaptive box for header images to scale properly which I felt some other users might want knowledge of how to implement. Would also love some more examples of how to nest container composables when using animation - was getting warnings in IDE of shadowing due to multiple columns, for instance.
Solution I arrived at was a composable that wrapped Box taking a maxHeight param. That param is used to constrain the nested box's height, and its width is established by aspect ratio by using size callback modifier until that maxHeight is reached, at which point it is allowed to grow horizontally without regard to the aspect ratio.
@willnwalker I need more context to understand your request.
If you have a specific component you would like to see (ie some specific UI patterns you have seen in an app), let me know.
What you are describing sounds like instructions of how to use specific APIs, which you can find in Compose's documentation.
If you don't have a specific component, kindly close this issue.
Would appreciate details on how to make expandable cards with a header element with constraints. Specifically implementing card headers that maintain an aspect ratio up to a certain width, and therefore have a maximum height (for larger displays where list items shouldn't get obscenely big). Also looking for a primer on how to work with animated visibility and growing/shrinking container composables (animating visibility for the expanded view of a card is tricky to understand)