Browse Source

Верстка

Anastasia 4 days ago
parent
commit
fe65375ef3

+ 13 - 4
EatWell/app/src/main/java/com/example/eatwell/view/mainActivity/Fridge.kt

@@ -193,7 +193,7 @@ fun fridge(navController: NavController) {
                         .height(270.dp)
                         .clip(RoundedCornerShape(30.dp))
                         .background(fon2)
-                        .padding(50.dp)
+                        .padding(10.dp)
 
 
                 ) {
@@ -212,14 +212,14 @@ fun fridge(navController: NavController) {
                                     painter = rememberImagePainter(item.image),
                                     contentDescription = "Image in Row",
                                     modifier = Modifier
-                                        .size(50.dp)
+                                        .size(70.dp)
                                 )
                                 Text(
                                     text = item.name,
                                     modifier = Modifier,
 
                                     color = Color.Black,
-                                    fontSize = 16.sp,
+                                    fontSize = 19.sp,
                                     fontWeight = FontWeight.Bold,
                                     fontFamily = FontFamily.Monospace
                                 )
@@ -228,7 +228,16 @@ fun fridge(navController: NavController) {
                                         item
                                     )
                                     Resources.viewModel.deleteIngredient(item.id)
-                                }) {
+                                },Modifier
+                                    .background(Color.Transparent),
+                                    colors = ButtonDefaults.buttonColors(containerColor = knopka)
+                                ) {
+                                    Text(
+                                        "-",
+                                        fontSize = 30.sp,
+                                        color = white,
+                                        fontWeight = FontWeight.SemiBold
+                                    )
 
                                 }
                             }

+ 16 - 4
EatWell/app/src/main/java/com/example/eatwell/view/mainActivity/Ingredients.kt

@@ -111,7 +111,7 @@ fun ingredients(navController: NavController) {
                         .height(560.dp)
                         .clip(RoundedCornerShape(30.dp))
                         .background(fon2)
-                        .padding(50.dp)
+                        .padding(10.dp)
                 ) {
 
                     var list = Resources.ingredients
@@ -130,14 +130,14 @@ fun ingredients(navController: NavController) {
                                     painter = rememberImagePainter(item.image),
                                     contentDescription = "Image in Row",
                                     modifier = Modifier
-                                        .size(50.dp)
+                                        .size(70.dp)
                                 )
                                 Text(
                                     text = item.name,
                                     modifier = Modifier,
 
                                     color = Color.Black,
-                                    fontSize = 16.sp,
+                                    fontSize = 19.sp,
                                     fontWeight = FontWeight.Bold,
                                     fontFamily = FontFamily.Monospace
                                 )
@@ -146,9 +146,21 @@ fun ingredients(navController: NavController) {
                                     viewModel.addIngredientToFridge(item.id)
                                     Resources.chosenIngredients.add(
                                         item
-                                    )}) {
+                                    )
+                                 } ,Modifier
+                                    .background(Color.Transparent),
+                                    colors = ButtonDefaults.buttonColors(containerColor = knopka)
+                                ) {
+                                    Text(
+                                        "+",
+                                        fontSize = 30.sp,
+                                        color = white,
+                                        fontWeight = FontWeight.SemiBold
+                                    )
 
                                 }
+
+
                             }
                         }
                     }