From 409a0d30f61d537421e2e650c97a9db547c042c9 Mon Sep 17 00:00:00 2001 From: Raja Jawahar Date: Mon, 11 Sep 2023 10:19:30 +0530 Subject: [PATCH 1/2] Minor optimisation --- .../uicomponents/components/TUIAttachmentUpload.kt | 3 --- .../components/base/TUIFloatingActionButton.kt | 2 +- .../uicomponents/components/base/TUIIconButton.kt | 2 -- .../uicomponents/components/base/TUIToggleRow.kt | 9 ++++++--- 4 files changed, 7 insertions(+), 9 deletions(-) diff --git a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/TUIAttachmentUpload.kt b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/TUIAttachmentUpload.kt index aae2ed2b..1ae87eb3 100644 --- a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/TUIAttachmentUpload.kt +++ b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/TUIAttachmentUpload.kt @@ -226,9 +226,6 @@ object TUIAttachmentUpload { @Preview @Composable fun PreviewTUIAttachmentUpload() { TUITheme { - var progress by remember { - mutableStateOf(10) - } Box( modifier = Modifier .background(color = TUITheme.colors.surface) diff --git a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIFloatingActionButton.kt b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIFloatingActionButton.kt index 6af68d97..813e0f14 100644 --- a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIFloatingActionButton.kt +++ b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIFloatingActionButton.kt @@ -35,7 +35,7 @@ enum class FloatingActionButtonSize(val size: Dp) { * @param fabSize The size of the FAB. Default is [FloatingActionButtonSize.S]. * @param icon The icon of the button. It should be TarkIcon * @param onClick The callback function to be executed when the button is clicked. - * @param testTag The test tag for the TUIFloatingActionButton. + * @param tags The test tag for the TUIFloatingActionButton. * How to use TUIFloatingActionButton() composable function * diff --git a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIIconButton.kt b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIIconButton.kt index 651123f5..acdab0bb 100644 --- a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIIconButton.kt +++ b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIIconButton.kt @@ -42,8 +42,6 @@ import com.tarkalabs.uicomponents.components.base.IconButtonStyle.PRIMARY import com.tarkalabs.uicomponents.components.base.IconButtonStyle.SECONDARY import com.tarkalabs.uicomponents.theme.TUITheme -// Created by Nilesh Rathod on 12/05/23. - enum class IconButtonSize(val size: Dp) { XS(20.dp), S(24.dp), diff --git a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIToggleRow.kt b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIToggleRow.kt index ac116f3f..c4793d11 100644 --- a/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIToggleRow.kt +++ b/tarkaui/src/main/java/com/tarkalabs/uicomponents/components/base/TUIToggleRow.kt @@ -21,7 +21,7 @@ import com.tarkalabs.uicomponents.theme.TUITheme * @param style The style of the toggle row. Can be [ToggleRowStyle.Title] or [ToggleRowStyle.TitleWithDescription]. * @param modifier A [Modifier] to apply custom styling and layout modifications to the toggle row. * - * @sample TUIToggleRowSample + * @sample TUIToggleRow * * TUIToggleRow(title = "Title", style = Title) * TUIToggleRow(title = "Title", style = TitleWithDescription("Description")) @@ -30,10 +30,13 @@ import com.tarkalabs.uicomponents.theme.TUITheme @Composable fun TUIToggleRow( title: String, style: ToggleRowStyle = Title, - modifier: Modifier = Modifier.fillMaxWidth(), + modifier: Modifier = Modifier, ) { Row( - modifier.defaultMinSize(minHeight = 40.dp), verticalAlignment = Alignment.CenterVertically + modifier + .fillMaxWidth() + .defaultMinSize(minHeight = 40.dp), + verticalAlignment = Alignment.CenterVertically ) { Column(Modifier.weight(1f)) { when (style) { From 3e516277f7bd340e335271e0814e63f55eb74c1e Mon Sep 17 00:00:00 2001 From: Raja Jawahar Date: Mon, 11 Sep 2023 10:46:45 +0530 Subject: [PATCH 2/2] Version bumped to 0.42-alpha --- tarkaui/build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tarkaui/build.gradle.kts b/tarkaui/build.gradle.kts index 1b2761fd..83ae1a21 100644 --- a/tarkaui/build.gradle.kts +++ b/tarkaui/build.gradle.kts @@ -66,7 +66,7 @@ publishing { run { groupId = "com.tarkalabs" artifactId = getLibraryArtifactId() - version = "0.41-alpha" + version = "0.42-alpha" artifact("$buildDir/outputs/aar/${getLibraryArtifactId()}-release.aar") } }