Fix several UI issue (#1680)
- App entry authentication - Update Lottie animation - Fix button text centering - Closes #1667
This commit is contained in:
parent
425052f1db
commit
f59add8e3b
|
@ -23,6 +23,7 @@ import androidx.compose.ui.graphics.Color
|
|||
import androidx.compose.ui.graphics.ColorFilter
|
||||
import androidx.compose.ui.res.painterResource
|
||||
import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.text.style.TextAlign
|
||||
import androidx.compose.ui.unit.dp
|
||||
import co.electriccoin.zcash.ui.design.R
|
||||
import co.electriccoin.zcash.ui.design.newcomponent.PreviewScreens
|
||||
|
@ -82,7 +83,8 @@ fun ZashiButton(
|
|||
Text(
|
||||
text = text,
|
||||
style = ZashiTypography.textMd,
|
||||
fontWeight = FontWeight.SemiBold
|
||||
fontWeight = FontWeight.SemiBold,
|
||||
textAlign = TextAlign.Center
|
||||
)
|
||||
}
|
||||
|
||||
|
|
|
@ -132,10 +132,10 @@ class MainActivity : FragmentActivity() {
|
|||
// }
|
||||
}
|
||||
|
||||
override fun onResume() {
|
||||
Twig.debug { "Activity state: Resume" }
|
||||
override fun onStart() {
|
||||
Twig.debug { "Activity state: Start" }
|
||||
authenticationViewModel.runAuthenticationRequiredCheck()
|
||||
super.onResume()
|
||||
super.onStart()
|
||||
}
|
||||
|
||||
override fun onStop() {
|
||||
|
|
|
@ -264,7 +264,7 @@ private fun SendConfirmationMainContent(
|
|||
}
|
||||
}
|
||||
|
||||
private const val TOP_BLANK_SPACE_RATIO = 0.2f
|
||||
private const val TOP_BLANK_SPACE_RATIO = 0.35f
|
||||
|
||||
@Composable
|
||||
private fun SendingContent(
|
||||
|
@ -298,13 +298,11 @@ private fun SendingContent(
|
|||
height = Dimension.wrapContent
|
||||
}
|
||||
) {
|
||||
// TODO [#1667]: Change lottie animation once we have it
|
||||
// TODO [#1667]: https://github.com/Electric-Coin-Company/zashi-android/issues/1667
|
||||
val lottieRes: Int =
|
||||
if (isSystemInDarkTheme()) {
|
||||
co.electriccoin.zcash.ui.design.R.raw.lottie_loading_white
|
||||
R.raw.send_confirmation_sending_dark_v1
|
||||
} else {
|
||||
co.electriccoin.zcash.ui.design.R.raw.lottie_loading
|
||||
R.raw.send_confirmation_sending_v1
|
||||
}
|
||||
|
||||
val composition by rememberLottieComposition(LottieCompositionSpec.RawRes(lottieRes))
|
||||
|
@ -314,7 +312,7 @@ private fun SendingContent(
|
|||
)
|
||||
|
||||
LottieAnimation(
|
||||
modifier = Modifier.size(200.dp),
|
||||
modifier = Modifier.size(150.dp),
|
||||
composition = composition,
|
||||
progress = { progress },
|
||||
maintainOriginalImageBounds = true
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue