diff --git a/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/Builder.kt b/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/Builder.kt index 26a6554b..2cb1078b 100644 --- a/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/Builder.kt +++ b/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/Builder.kt @@ -15,7 +15,7 @@ open class InfoDialogBuilder internal constructor() : Builder() { var content: CharSequence = SpannableString("") @DrawableRes - var contentImage: Int = 0 + var contentImage: Int? = null var showContentAsHtml: Boolean = false internal fun buildInfoDialog(block: InfoDialogBuilder.() -> Unit): DialogFragment { diff --git a/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/DialogViewState.kt b/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/DialogViewState.kt index 9a0a6833..de62e9eb 100644 --- a/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/DialogViewState.kt +++ b/libraries/dialogs/src/main/java/com/trendyol/uicomponents/dialogs/DialogViewState.kt @@ -29,5 +29,5 @@ data class DialogViewState( fun isContentVisible(): Boolean = content.isNotEmpty() - fun isContentImageVisible(): Boolean = contentImage != null + fun isContentImageVisible(): Boolean = contentImage?.takeIf { it != 0 } != null }