@@ -16,6 +16,7 @@ import androidx.compose.ui.ExperimentalComposeUiApi
1616import androidx.compose.ui.Modifier
1717import androidx.compose.ui.autofill.AutofillType
1818import androidx.compose.ui.graphics.Color
19+ import androidx.compose.ui.layout.ContentScale
1920import androidx.compose.ui.text.input.KeyboardType
2021import androidx.compose.ui.text.input.PasswordVisualTransformation
2122import androidx.compose.ui.text.input.VisualTransformation
@@ -44,18 +45,27 @@ fun LoginScreen(vm: LoginViewModel) {
4445 }
4546
4647 Column (
47- modifier = Modifier .padding(50 .dp).requiredWidthIn(max = 550 .dp),
48+ modifier = Modifier .padding(10 .dp).requiredWidthIn(max = 550 .dp),
4849 horizontalAlignment = Alignment .CenterHorizontally ,
4950 verticalArrangement = Arrangement .spacedBy(25 .dp, Alignment .CenterVertically )
5051 ) {
51- Image (
52- painter = painterResource(Res .drawable.icon_round),
53- contentDescription = " WaiterRobot icon" ,
52+ Box (
5453 modifier = Modifier
55- .fillMaxWidth(0.4f )
56- .aspectRatio(1f )
57- .padding(bottom = 20 .dp)
58- )
54+ .weight(1f , fill = false )
55+ .heightIn(max = 300 .dp)
56+ .aspectRatio(1f ),
57+ contentAlignment = Alignment .Center
58+ ) {
59+ Image (
60+ painter = painterResource(Res .drawable.icon_round),
61+ contentDescription = " WaiterRobot icon" ,
62+ modifier = Modifier
63+ .fillMaxHeight()
64+ .aspectRatio(1f ),
65+ contentScale = ContentScale .Fit
66+ )
67+ }
68+
5969 Text (text = stringResource(Res .string.login_title), style = MaterialTheme .typography.headlineMedium)
6070 Text (
6171 modifier = Modifier .padding(horizontal = 20 .dp),
0 commit comments