mirror of
https://github.com/bitwarden/android.git
synced 2025-03-15 18:58:59 +03:00
Replace vertical padding with Spacers on Login & Landing screens (#439)
This commit is contained in:
parent
800e0e018c
commit
2a9cec5f8e
2 changed files with 15 additions and 13 deletions
|
@ -239,7 +239,7 @@ private fun LandingScreenContent(
|
|||
.fillMaxWidth(),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
Spacer(modifier = Modifier.height(16.dp))
|
||||
|
||||
Spacer(modifier = Modifier.weight(1f))
|
||||
|
||||
|
@ -249,16 +249,13 @@ private fun LandingScreenContent(
|
|||
style = MaterialTheme.typography.headlineSmall,
|
||||
color = MaterialTheme.colorScheme.onSurface,
|
||||
modifier = Modifier
|
||||
.padding(
|
||||
horizontal = 24.dp,
|
||||
vertical = 8.dp,
|
||||
)
|
||||
.padding(horizontal = 24.dp)
|
||||
.wrapContentHeight(),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.weight(1f))
|
||||
|
||||
Spacer(modifier = Modifier.height(32.dp))
|
||||
Spacer(modifier = Modifier.height(40.dp))
|
||||
|
||||
BitwardenTextField(
|
||||
modifier = Modifier
|
||||
|
|
|
@ -6,6 +6,7 @@ import androidx.compose.foundation.layout.Column
|
|||
import androidx.compose.foundation.layout.Spacer
|
||||
import androidx.compose.foundation.layout.fillMaxSize
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.foundation.layout.height
|
||||
import androidx.compose.foundation.layout.imePadding
|
||||
import androidx.compose.foundation.layout.navigationBarsPadding
|
||||
import androidx.compose.foundation.layout.padding
|
||||
|
@ -215,7 +216,6 @@ private fun LoginScreenContent(
|
|||
modifier = Modifier
|
||||
.semantics { testTag = "GetMasterPasswordHintLabel" }
|
||||
.fillMaxWidth()
|
||||
.padding(bottom = 8.dp)
|
||||
.clickable { onMasterPasswordClick() }
|
||||
.padding(
|
||||
vertical = 4.dp,
|
||||
|
@ -223,26 +223,30 @@ private fun LoginScreenContent(
|
|||
),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(20.dp))
|
||||
|
||||
BitwardenFilledButton(
|
||||
label = stringResource(id = R.string.log_in_with_master_password),
|
||||
onClick = onLoginButtonClick,
|
||||
isEnabled = state.isLoginButtonEnabled,
|
||||
modifier = Modifier
|
||||
.semantics { testTag = "LogInWithMasterPasswordButton" }
|
||||
.fillMaxWidth()
|
||||
.padding(vertical = 12.dp),
|
||||
.fillMaxWidth(),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(12.dp))
|
||||
|
||||
BitwardenOutlinedButtonWithIcon(
|
||||
label = stringResource(id = R.string.log_in_sso),
|
||||
icon = painterResource(id = R.drawable.ic_briefcase),
|
||||
onClick = onSingleSignOnClick,
|
||||
modifier = Modifier
|
||||
.semantics { testTag = "LogInWithSsoButton" }
|
||||
.fillMaxWidth()
|
||||
.padding(bottom = 24.dp),
|
||||
.fillMaxWidth(),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(24.dp))
|
||||
|
||||
Text(
|
||||
text = stringResource(
|
||||
id = R.string.logging_in_as_x_on_y,
|
||||
|
@ -254,10 +258,11 @@ private fun LoginScreenContent(
|
|||
color = MaterialTheme.colorScheme.onSurfaceVariant,
|
||||
modifier = Modifier
|
||||
.semantics { testTag = "LoggingInAsLabel" }
|
||||
.fillMaxWidth()
|
||||
.padding(bottom = 8.dp),
|
||||
.fillMaxWidth(),
|
||||
)
|
||||
|
||||
Spacer(modifier = Modifier.height(8.dp))
|
||||
|
||||
// TODO: Need to figure out better handling for very small clickable text (BIT-724)
|
||||
Text(
|
||||
modifier = Modifier
|
||||
|
|
Loading…
Add table
Reference in a new issue