瀏覽代碼

app:change radiobutton

AnnaBezaeva 1 周之前
父節點
當前提交
24d98baaff

+ 0 - 1
.idea/misc.xml

@@ -1,4 +1,3 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="ProjectRootManager">
     <output url="file://$PROJECT_DIR$/out" />

+ 123 - 0
Project_exvesta/.idea/codeStyles/Project.xml

@@ -0,0 +1,123 @@
+<component name="ProjectCodeStyleConfiguration">
+  <code_scheme name="Project" version="173">
+    <JetCodeStyleSettings>
+      <option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
+    </JetCodeStyleSettings>
+    <codeStyleSettings language="XML">
+      <option name="FORCE_REARRANGE_MODE" value="1" />
+      <indentOptions>
+        <option name="CONTINUATION_INDENT_SIZE" value="4" />
+      </indentOptions>
+      <arrangement>
+        <rules>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>xmlns:android</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
+                </AND>
+              </match>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>xmlns:.*</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
+                </AND>
+              </match>
+              <order>BY_NAME</order>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>.*:id</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
+                </AND>
+              </match>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>.*:name</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
+                </AND>
+              </match>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>name</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
+                </AND>
+              </match>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>style</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
+                </AND>
+              </match>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>.*</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>^$</XML_NAMESPACE>
+                </AND>
+              </match>
+              <order>BY_NAME</order>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>.*</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE>
+                </AND>
+              </match>
+              <order>ANDROID_ATTRIBUTE_ORDER</order>
+            </rule>
+          </section>
+          <section>
+            <rule>
+              <match>
+                <AND>
+                  <NAME>.*</NAME>
+                  <XML_ATTRIBUTE />
+                  <XML_NAMESPACE>.*</XML_NAMESPACE>
+                </AND>
+              </match>
+              <order>BY_NAME</order>
+            </rule>
+          </section>
+        </rules>
+      </arrangement>
+    </codeStyleSettings>
+    <codeStyleSettings language="kotlin">
+      <option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
+    </codeStyleSettings>
+  </code_scheme>
+</component>

+ 5 - 0
Project_exvesta/.idea/codeStyles/codeStyleConfig.xml

@@ -0,0 +1,5 @@
+<component name="ProjectCodeStyleConfiguration">
+  <state>
+    <option name="USE_PER_PROJECT_SETTINGS" value="true" />
+  </state>
+</component>

+ 2 - 1
Project_exvesta/.idea/misc.xml

@@ -1,6 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="ExternalStorageConfigurationManager" enabled="true" />
-  <component name="ProjectRootManager" version="2" languageLevel="JDK_17" default="true" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_17" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
     <output url="file://$PROJECT_DIR$/build/classes" />
   </component>
   <component name="ProjectType">

+ 9 - 6
Project_exvesta/app/src/main/java/com/example/exvesta/Screans/Filters.kt

@@ -176,8 +176,9 @@ public  fun Filters(isVisible: Boolean,  onClose: () -> Unit) {
                         Spacer(modifier = Modifier.height(10.dp))
                         Box(
 
-                            modifier = Modifier.align(Alignment.Start)
+                            modifier = Modifier//.align(Alignment.Start)
                                 .fillMaxWidth()
+
                         ) {
                             Text("Стиль")
                         FlowRow(
@@ -200,20 +201,22 @@ public  fun Filters(isVisible: Boolean,  onClose: () -> Unit) {
                                 Box(
                                     modifier = Modifier
 //                                        .size(24.dp) // Размер для выравнивания
-                                        .width(50.dp)
+                                        .width(130.dp)
                                         .align(Alignment.CenterVertically) // Центрируем Box
+                                        .background(Color(0xFFF1F1F3))
                                 ) {
                                     RadioButton(
                                         selected = (styledub == selectedStyledub),
                                         onClick = { selectedStyledub = styledub }
                                     )
-                                }
-                                Text(
+
+                                   Text(
                                     text = styledub.title_style,
                                     fontSize = 16.sp,
-                                    modifier = Modifier.padding(start = 0.dp),
+                                    modifier = Modifier.padding(start = 10.dp),
                                     color = Color(0xFF92A2B0)
-                                )
+                                    )
+                                }
                             }
                          }
                         }

+ 24 - 15
Project_exvesta/app/src/main/java/com/example/exvesta/Screans/Home.kt

@@ -142,7 +142,7 @@ fun Home(navHost: NavHostController) {
                         modifier = Modifier
                             .fillMaxWidth()
                             .padding(vertical = 8.dp),
-                        colors = ButtonDefaults.buttonColors(Color.White)
+                        colors = ButtonDefaults.buttonColors(Color(0xFFF1F1F3))
                     ) {
                         Text(text = "+ добавить фильтр", color = Color(0xFF92A2B0))
                     }
@@ -180,13 +180,22 @@ fun Home(navHost: NavHostController) {
                         onClick = { /*TODO*/ },
                         modifier = Modifier
                             .fillMaxWidth()
+
                             .shadow(
                                 0.dp,
                                 shape = CircleShape,
                                 clip = false
-                            ), // Убираем тень у кнопки
-                        colors = ButtonDefaults.buttonColors(Color.White),
-                        shape = RoundedCornerShape(16.dp) // Скругление кнопки
+                            )// Убираем тень у кнопки
+                            .background(
+                            brush = Brush.horizontalGradient(
+                                colors = listOf(
+                                    Color(0xFFF1F1F3),
+                                    Color(0xFFFFFFFF),
+                                )
+                            ), shape = ButtonDefaults.shape
+                         ), // Убираем тень у кнопки
+                        colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent)
+
                     ) {
                         Text(text = "вещи", color = Color(0xFF92A2B0))
                     }
@@ -204,11 +213,7 @@ fun Home(navHost: NavHostController) {
                     // Тень
                     Box(
                         modifier = Modifier
-                            .align(Alignment.BottomCenter)
-                            .fillMaxWidth()
-                            .height(4.dp) // Высота тени
-                            .background(Color.Black.copy(alpha = 0.2f)) // Цвет и прозрачность тени
-                            .offset(y = 2.dp) // Смещение тени вниз
+                            .shadow(8.dp, RoundedCornerShape(30.dp))
                     )
 
                     // Кнопка
@@ -216,13 +221,17 @@ fun Home(navHost: NavHostController) {
                         onClick = { /*TODO*/ },
                         modifier = Modifier
                             .fillMaxWidth()
-                            .shadow(
-                                0.dp,
-                                shape = CircleShape,
-                                clip = false
+
+                            .background(
+                                brush = Brush.horizontalGradient(
+                                    colors = listOf(
+                                        Color(0xFFF1F1F3),
+                                        Color(0xFFFFFFFF),
+                                    )
+                                ), shape = ButtonDefaults.shape
                             ), // Убираем тень у кнопки
-                        colors = ButtonDefaults.buttonColors(Color.White),
-                        shape = RoundedCornerShape(16.dp) // Скругление кнопки
+                        colors = ButtonDefaults.buttonColors(containerColor = Color.Transparent),
+
                     ) {
                         Text(text = "образы", color = Color(0xFF92A2B0))
                     }

+ 1 - 61
Project_exvesta/app/src/main/java/com/example/exvesta/Screans/Wardrob.kt

@@ -52,7 +52,7 @@ fun Wardrob(navHost: NavHostController) {
     ModalDrawer(
         drawerState = drawerState,
         drawerContent = {
-
+            DrawerContent(navHost)
         },
     ) {
         Column(
@@ -109,63 +109,3 @@ fun Wardrob(navHost: NavHostController) {
 }
 
 
-//@Composable
-//fun DrawerContent() {
-//    Column(
-//        modifier = Modifier
-//            .fillMaxHeight()
-//            .width(250.dp)
-//            .background(Color(0xFFF0F0F0))
-//            .padding(16.dp),
-//        verticalArrangement = Arrangement.Top
-//    ) {
-//        Text(
-//            text = "EXVESTA",
-//            fontSize = 20.sp,
-//            fontWeight = FontWeight.Bold,
-//            color = Color.Black
-//        )
-//        Spacer(modifier = Modifier.height(16.dp))
-//        // Аватар пользователя
-//        Box(
-//            modifier = Modifier
-//                .size(100.dp)
-//                .clip(CircleShape)
-//                .background(Color.LightGray)
-//        )
-//        Spacer(modifier = Modifier.height(16.dp))
-//        Text(
-//            text = "user_name",
-//            fontSize = 16.sp,
-//            fontWeight = FontWeight.Medium,
-//            color = Color.Black
-//        )
-//        Spacer(modifier = Modifier.height(32.dp))
-//        // Кнопки
-//        Button(
-//            onClick = { /* TODO: Открыть "Мои образы" */ },
-//            modifier = Modifier
-//                .fillMaxWidth()
-//                .height(48.dp),
-//            colors = ButtonDefaults.buttonColors(
-//                Color(0xFFF0F0F0),
-//                contentColor = Color.Black
-//            )
-//        ) {
-//            Text("Мои образы")
-//        }
-//        Spacer(modifier = Modifier.height(8.dp))
-//        Button(
-//            onClick = { /* TODO: Открыть "Коллекция" */ },
-//            modifier = Modifier
-//                .fillMaxWidth()
-//                .height(48.dp),
-//            colors = ButtonDefaults.buttonColors(
-//                Color(0xFFF0F0F0),
-//                contentColor = Color.Black
-//            )
-//        ) {
-//            Text("Коллекция")
-//        }
-//    }
-//}

+ 1 - 1
Project_exvesta/app/src/main/java/com/example/exvesta/domain/utils/Constants.kt

@@ -16,4 +16,4 @@ object Constants {
         install(Postgrest)
         install(Storage)
     }
-}
+}