From 21de4f19ff75971ef1cbe227fec5c42c9d9a1ac7 Mon Sep 17 00:00:00 2001 From: fankesyooni Date: Sat, 6 Jan 2024 03:59:54 +0800 Subject: [PATCH] refactor: override FlexiTheme for Sizes --- .../kotlin/com/highcapable/flexiui/FlexiTheme.kt | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/flexiui-core/src/commonMain/kotlin/com/highcapable/flexiui/FlexiTheme.kt b/flexiui-core/src/commonMain/kotlin/com/highcapable/flexiui/FlexiTheme.kt index 1a58535..d9d9223 100644 --- a/flexiui-core/src/commonMain/kotlin/com/highcapable/flexiui/FlexiTheme.kt +++ b/flexiui-core/src/commonMain/kotlin/com/highcapable/flexiui/FlexiTheme.kt @@ -32,7 +32,17 @@ fun FlexiTheme( colors: Colors = FlexiTheme.colors, shapes: Shapes = FlexiTheme.shapes, typography: Typography = FlexiTheme.typography, - sizes: Sizes = FlexiTheme.sizes, + content: @Composable () -> Unit +) { + FlexiTheme(colors, shapes, typography, FlexiTheme.sizes, content) +} + +@Composable +fun FlexiTheme( + colors: Colors = FlexiTheme.colors, + shapes: Shapes = FlexiTheme.shapes, + typography: Typography = FlexiTheme.typography, + sizes: Sizes, content: @Composable () -> Unit ) { CompositionLocalProvider(