alorma
10/27/2020, 5:11 PMJavier
10/27/2020, 5:14 PMalorma
10/27/2020, 5:16 PMJavier
10/27/2020, 5:18 PMalorma
10/27/2020, 5:18 PMdata class MaterialThemeHolder(
val name: String,
val lightColors: Colors,
val darkColors: Colors,
val shapes: Shapes,
val typography: Typography
) {
@Composable
fun compile(
isDark: Boolean = isSystemInDarkTheme(),
content: @Composable () -> Unit,
) {
MaterialTheme(
colors = if (isDark) darkColors else lightColors,
shapes = shapes,
typography = typography,
content = content,
)
}
}
Afzal Najam
10/27/2020, 6:47 PM