@@ -284,29 +284,30 @@ private fun BottomBarButtons(
284284 ) {
285285 if (state.isCashReserve) return @Row
286286 val canGive = state.balance.nativeAmount.isPositive
287- if (canGive) {
288- CodeButton (
289- modifier = Modifier .weight(1f ),
290- buttonState = ButtonState .Filled ,
291- text = stringResource(R .string.action_give),
292- ) {
293- dispatch(
294- TokenInfoViewModel .Event .OpenScreen (
295- AppRoute .Main .Give (mint = loadable.data.address, fromTokenInfo = true )
296- )
297- )
298- }
299- }
300287
301288 if (state.cashReservesEnabled) {
302289 CodeButton (
303290 modifier = Modifier .weight(1f ),
304- buttonState = if (canGive) ButtonState . Filled20 else ButtonState .Filled ,
291+ buttonState = ButtonState .Filled ,
305292 text = stringResource(R .string.action_buy),
306293 ) {
307294 dispatch(TokenInfoViewModel .Event .OpenPurchaseMethods (forNeededFunds = isForNeededFunds))
308295 }
309296
297+ if (canGive) {
298+ CodeButton (
299+ modifier = Modifier .weight(1f ),
300+ buttonState = ButtonState .Filled20 ,
301+ text = stringResource(R .string.action_give),
302+ ) {
303+ dispatch(
304+ TokenInfoViewModel .Event .OpenScreen (
305+ AppRoute .Main .Give (mint = loadable.data.address, fromTokenInfo = true )
306+ )
307+ )
308+ }
309+ }
310+
310311 if (state.canSell) {
311312 CodeButton (
312313 modifier = Modifier
@@ -324,6 +325,18 @@ private fun BottomBarButtons(
324325 )
325326 }
326327 }
328+ } else {
329+ CodeButton (
330+ modifier = Modifier .weight(1f ),
331+ buttonState = ButtonState .Filled ,
332+ text = stringResource(R .string.action_give),
333+ ) {
334+ dispatch(
335+ TokenInfoViewModel .Event .OpenScreen (
336+ AppRoute .Main .Give (mint = loadable.data.address, fromTokenInfo = true )
337+ )
338+ )
339+ }
327340 }
328341 }
329342 }
0 commit comments