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

Bojie Jiang

01/01/2022, 3:08 AM
What’s custom shape-to-component mapping? (pic1), I’ve tired, but I think I cannot apply to components automatically.
Maybe Using Material components? But I find small and medium for components, that mean I need to define size and component at the same time?
c

Chris Sinco [G]

01/02/2022, 4:19 AM
Some Material Components map to shapes defined in your MaterialTheme, e.g. MaterialTheme.shapes.medium for Button. There's defaults for MaterialTheme that can be overridden (example), or for some components like Surface or Button, you can override the shape through a parameter if you don't want to rely on theming.
👍 1
2 Views