Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apps/flipcash/core/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@
<string name="title_tapAboveToAddCashToWallet">Tap above to Add Cash to your wallet</string>
<string name="title_tapBelowToAddCashWallet">You don\'t have any cash yet.\nTap below to add cash to your wallet</string>
<string name="title_noBalanceYet">No Balance Yet</string>
<string name="description_noBalanceYet">Get another Flipcash user to give you some cash to get a balance</string>
<string name="description_noBalanceYet">Buy a currency to get started, or get another Flipcash user to give you some cash</string>
<string name="description_noBalanceYetDiscover">Buy your first currency to get started</string>
<string name="action_dismiss">Dismiss</string>
<string name="title_success">Success</string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import androidx.compose.ui.platform.LocalContext
import androidx.compose.ui.platform.LocalFocusManager
import androidx.lifecycle.Lifecycle
import com.flipcash.app.analytics.rememberAnalytics
import com.flipcash.app.core.AppRoute
import com.flipcash.app.router.LocalRouter
import com.flipcash.app.scanner.internal.bills.BillContainer
import com.flipcash.app.session.LocalSessionController
Expand All @@ -34,6 +35,7 @@ import dev.theolm.rinku.DeepLink
import timber.log.Timber
import com.flipcash.app.core.extensions.navigateTo
import com.flipcash.app.core.navigation.DeeplinkType
import com.getcode.manager.BottomBarAction

@Composable
internal fun Scanner() {
Expand Down Expand Up @@ -86,9 +88,17 @@ internal fun Scanner() {
// only allow navigation to give when there is something to give
val hasBalance = state.giveableBalance.orZero().isPositive
if (!hasBalance) {
BottomBarManager.showAlert(
BottomBarManager.showInfo(
title = context.getString(R.string.title_noBalanceYet),
message = context.getString(R.string.description_noBalanceYet),
actions = listOf(
BottomBarAction(
text = context.getString(R.string.action_discoverCurrencies)
) {
navigator.navigateTo(AppRoute.Sheets.TokenDiscovery)
},
),
showCancel = true,
)
return@BillContainer
}
Expand Down
Loading