Skip to content

Commit

Permalink
Merge pull request #248 from tarkalabs/raja/unwantedlogsremoved
Browse files Browse the repository at this point in the history
fix: unwanted logs removed in TUChip
  • Loading branch information
rajajawahar authored May 28, 2024
2 parents d2be976 + 0a667a9 commit 629a0ad
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 11 deletions.
2 changes: 1 addition & 1 deletion tarka-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ publishing {
run {
groupId = "com.tarkalabs"
artifactId = getLibraryArtifactId()
version = "1.1.28"
version = "1.1.29"
artifact("$buildDir/outputs/aar/tarka-ui-release.aar")
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.tarkalabs.tarkaui.components

import android.util.Log
import androidx.compose.foundation.background
import androidx.compose.foundation.border
import androidx.compose.foundation.clickable
Expand Down Expand Up @@ -149,8 +148,6 @@ enum class ChipSize(val size: Dp) {
val commonLabel = getCommonLabel(label)
val leadingIcon = leadingIcon()

Log.e("TAG_CHIP", "TUIChipPreview: 888")

when (type) {
is ChipType.Assist -> {
AssistChip(modifier = commonModifier,
Expand Down Expand Up @@ -339,11 +336,9 @@ data class TUIChipTags(
label = "Something",
onClick = {
showSearchbar = true
Log.e("TAG_CHIP", "TUIChipPreview: TAG_CLICKED")
},
onDismissClick = {
showSearchbar = !showSearchbar
Log.e("TAG_CHIP", "TUIChipPreview: 123")
},
)
VerticalSpacer(space = 20)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ fun TUIDateStyle(
.align(Alignment.CenterVertically),
tint = TUITheme.colors.utilityOutline
)
if (style.startDate.isEmpty()) {
if (style.startDate == null) {
Text(
text = stringResource(id = style.primaryNotAvailableText),
style = TUITheme.typography.body7,
Expand All @@ -269,7 +269,7 @@ fun TUIDateStyle(
.align(Alignment.CenterVertically),
tint = TUITheme.colors.utilityOutline
)
if (style.endDate.isEmpty()) {
if (style.endDate == null) {
Text(
text = stringResource(id = style.primaryNotAvailableText),
style = TUITheme.typography.body7,
Expand Down Expand Up @@ -335,8 +335,8 @@ sealed class TextRowStyle {
data class TitleWithDescription(val description: String) : TextRowStyle()

data class DateStyle(
val startDate: String = "",
val endDate: String = "",
val startDate: String? = null,
val endDate: String? = null,
@StringRes val primaryNotAvailableText: Int = R.string.not_availble,
) : TextRowStyle()

Expand All @@ -362,9 +362,10 @@ data class TUITextRowTags(
@Preview(showBackground = true)
@Composable
fun TUITextRowPreview() {

TUITextRow(
title = "Duration", style = DateStyle(
"Jan 20 3000 friday march 32", "Jan 20 3000 friday march 32"
null, "Jan 20 3000 friday march 32"
), onTextRowClick = {
Log.d("TAG", "TUITextRowPreview: ")
}, onInfoIconClick = null
Expand Down

0 comments on commit 629a0ad

Please sign in to comment.