-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ui: Trade flow UI and improvements in Take Offer (#90)
* - Nav: Back button generalization * - layout improvements: consistent, better padding across screens; tested in small screen devices; BisqTextField improvements * - Takeoffer.TradeAmount 1/2; TakeOffer Scaffold and TopBar updates; BisqSlider; SvgImage; AmountSelector * Take offer screens UI 1/2; i18n keys - modularized * - Offer card UI and some Layout Improvements * Layout / UI Improvements - Take offer screens - Added Interfaces - OfferCard proper UI - Layout spacing improvements - RootNavGraph -> Optimised routes definition and improved popBack nav animation - i18n Improvements * Trade flow screen UI 1/2 * - i18n update and layout/margin improvements in Trade flow * PR Review commits, Trade close dialog - Close trade button logic - Fixed missed i18n keys - Removed number from Trade flow composables - Removed confusing comments
- Loading branch information
1 parent
bb89dfa
commit 849875d
Showing
83 changed files
with
4,508 additions
and
399 deletions.
There are no files selected for viewing
173 changes: 173 additions & 0 deletions
173
...n/kotlin/network/bisq/mobile/presentation/ui/uicases/offers/TakeOfferReviewTradeScreen.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,173 @@ | ||
package network.bisq.mobile.presentation.ui.uicases.offers | ||
|
||
import androidx.compose.foundation.layout.* | ||
import androidx.compose.material3.HorizontalDivider | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Alignment | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.graphics.Color | ||
import androidx.compose.ui.unit.dp | ||
import androidx.navigation.NavHostController | ||
import network.bisq.mobile.presentation.ui.components.atoms.BisqButton | ||
import network.bisq.mobile.presentation.ui.components.atoms.BisqText | ||
import network.bisq.mobile.presentation.ui.navigation.Routes | ||
import network.bisq.mobile.presentation.ui.theme.BisqTheme | ||
import org.koin.compose.koinInject | ||
import org.koin.core.qualifier.named | ||
|
||
@Composable | ||
fun TakeOfferReviewTradeScreen() { | ||
val navController: NavHostController = koinInject(named("RootNavController")) | ||
TakeOfferScaffold { | ||
Column(modifier = Modifier.padding(horizontal = 32.dp, vertical = 24.dp)) { | ||
BisqText.h3Regular( | ||
text = "Review trade", | ||
color = BisqTheme.colors.light1 | ||
) | ||
Spacer(modifier = Modifier.height(32.dp)) | ||
Column( | ||
verticalArrangement = Arrangement.spacedBy(32.dp) | ||
) { | ||
Row( | ||
modifier = Modifier.fillMaxWidth(), | ||
horizontalArrangement = Arrangement.SpaceBetween | ||
) { | ||
Column(verticalArrangement = Arrangement.spacedBy(12.dp)) { | ||
BisqText.largeRegular( | ||
text = "I WANT TO", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "BUY Bitcoin" | ||
) | ||
} | ||
Column( | ||
verticalArrangement = Arrangement.spacedBy(12.dp), | ||
horizontalAlignment = Alignment.End | ||
) { | ||
BisqText.largeRegular( | ||
text = "FIAT PAYMENT METHOD", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "Strike" | ||
) | ||
} | ||
} | ||
|
||
Row( | ||
modifier = Modifier.fillMaxWidth(), | ||
horizontalArrangement = Arrangement.SpaceBetween | ||
) { | ||
Column(verticalArrangement = Arrangement.spacedBy(12.dp)) { | ||
BisqText.largeRegular( | ||
text = "AMOUNT TO PAY", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "900.00" | ||
) | ||
} | ||
Column( | ||
verticalArrangement = Arrangement.spacedBy(12.dp), | ||
horizontalAlignment = Alignment.End | ||
) { | ||
BisqText.largeRegular( | ||
text = "AMOUNT TO RECEIVE", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "0.00918367 btc" | ||
) | ||
} | ||
} | ||
} | ||
HorizontalDivider( | ||
thickness = 1.dp, | ||
modifier = Modifier.padding(vertical = 28.dp), | ||
color = Color(0XFF2B2B2B) | ||
) | ||
Column( | ||
verticalArrangement = Arrangement.spacedBy(32.dp) | ||
) { | ||
Column(verticalArrangement = Arrangement.spacedBy(12.dp)) { | ||
BisqText.largeRegular( | ||
text = "Trade price", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
Column(verticalArrangement = Arrangement.spacedBy(4.dp)) { | ||
Row( | ||
verticalAlignment = Alignment.Bottom, | ||
horizontalArrangement = Arrangement.spacedBy(4.dp) | ||
) { | ||
BisqText.h5Regular( | ||
text = "98,000.68" | ||
) | ||
BisqText.baseRegular( | ||
text = "BTC/USD", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
} | ||
BisqText.smallRegular( | ||
text = "Float price 1.00% above market price of 60,000 BTC/USD", | ||
color = BisqTheme.colors.grey4 | ||
) | ||
} | ||
} | ||
Row( | ||
modifier = Modifier.fillMaxWidth(), | ||
horizontalArrangement = Arrangement.SpaceBetween | ||
) { | ||
Column(verticalArrangement = Arrangement.spacedBy(12.dp)) { | ||
BisqText.largeRegular( | ||
text = "Bitcoin settlement method", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "Lightning" | ||
) | ||
} | ||
Column( | ||
verticalArrangement = Arrangement.spacedBy(12.dp), | ||
horizontalAlignment = Alignment.End | ||
) { | ||
BisqText.largeRegular( | ||
text = "Fiat payment", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "Strike" | ||
) | ||
} | ||
} | ||
Column(verticalArrangement = Arrangement.spacedBy(12.dp)) { | ||
BisqText.largeRegular( | ||
text = "Fees", | ||
color = BisqTheme.colors.grey2 | ||
) | ||
BisqText.h5Regular( | ||
text = "No trade fees in Bisq Easy :-)" | ||
) | ||
} | ||
} | ||
} | ||
Row( | ||
horizontalArrangement = Arrangement.SpaceBetween, | ||
modifier = Modifier.fillMaxWidth().padding(horizontal = 32.dp) | ||
) { | ||
BisqButton( | ||
text = "Back", | ||
backgroundColor = BisqTheme.colors.dark5, | ||
onClick = { }, | ||
padding = PaddingValues(horizontal = 64.dp, vertical = 4.dp) | ||
) | ||
BisqButton( | ||
text = "Next", | ||
onClick = { | ||
navController.navigate(Routes.TradeFlow.name) | ||
}, | ||
padding = PaddingValues(horizontal = 64.dp, vertical = 4.dp) | ||
) | ||
} | ||
} | ||
} |
Binary file added
BIN
+219 Bytes
shared/presentation/src/commonMain/composeResources/drawable/exchange_h_arrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+197 Bytes
shared/presentation/src/commonMain/composeResources/drawable/exchange_v_arrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+3.61 KB
...n/src/commonMain/composeResources/drawable/img_bitcoin_payment_confirmation.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+9.16 KB
...tation/src/commonMain/composeResources/drawable/img_bitcoin_payment_waiting.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+6.85 KB
...sentation/src/commonMain/composeResources/drawable/img_fiat_payment_waiting.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
shared/presentation/src/commonMain/composeResources/drawable/svg_back_button.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
.../presentation/src/commonMain/composeResources/drawable/svg_exchange_h_arrow.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
.../presentation/src/commonMain/composeResources/drawable/svg_exchange_v_arrow.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
shared/presentation/src/commonMain/composeResources/drawable/svg_info.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
shared/presentation/src/commonMain/composeResources/drawable/svg_star.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions
3
shared/presentation/src/commonMain/composeResources/drawable/svg_up_arrow.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+196 Bytes
shared/presentation/src/commonMain/composeResources/drawable/up_arrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.