Browse Source

update && add: update navigation, update onboard, add singIn screen and start creating signUp

Bax 1 week ago
parent
commit
64f6a6ad5e
17 changed files with 247 additions and 71 deletions
  1. 2 2
      mobile_app/wabi/.idea/deploymentTargetSelector.xml
  2. 8 1
      mobile_app/wabi/app/src/main/java/com/example/wabi/domain/navigation/Navigation.kt
  3. 1 0
      mobile_app/wabi/app/src/main/java/com/example/wabi/domain/network/SupabaseService.kt
  4. 8 6
      mobile_app/wabi/app/src/main/java/com/example/wabi/domain/network/SupabaseServiceImpl.kt
  5. 0 4
      mobile_app/wabi/app/src/main/java/com/example/wabi/domain/repository/PrefManager.kt
  6. 12 0
      mobile_app/wabi/app/src/main/java/com/example/wabi/domain/repository/UserData.kt
  7. 20 9
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/MainActivity.kt
  8. 27 0
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/MainViewModel.kt
  9. 8 4
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/common_elements/bars/bottom/BottomBar.kt
  10. 1 1
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/basket/Basket.kt
  11. 3 6
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/onboard/items/OnBoardState.kt
  12. 2 1
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/onboard/screeen/Onboard.kt
  13. 93 22
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signIn/SignIn.kt
  14. 29 6
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signIn/SignInViewModel.kt
  15. 14 6
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signUp/SignUp.kt
  16. 12 0
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signUp/SignUpViewModel.kt
  17. 7 3
      mobile_app/wabi/app/src/main/java/com/example/wabi/view/ui/theme/Type.kt

+ 2 - 2
mobile_app/wabi/.idea/deploymentTargetSelector.xml

@@ -4,10 +4,10 @@
     <selectionStates>
       <SelectionState runConfigName="app">
         <option name="selectionMode" value="DROPDOWN" />
-        <DropdownSelection timestamp="2024-11-21T07:40:04.317590300Z">
+        <DropdownSelection timestamp="2024-11-21T15:48:06.690092200Z">
           <Target type="DEFAULT_BOOT">
             <handle>
-              <DeviceId pluginId="LocalEmulator" identifier="path=C:\Users\bax\.android\avd\Medium_Phone_API_30.avd" />
+              <DeviceId pluginId="PhysicalDevice" identifier="serial=RF8R80XPK2W" />
             </handle>
           </Target>
         </DropdownSelection>

+ 8 - 1
mobile_app/wabi/app/src/main/java/com/example/wabi/domain/navigation/Navigation.kt

@@ -1,5 +1,6 @@
 package com.example.wabi.domain.navigation
 
+import android.util.Log
 import androidx.compose.runtime.Composable
 import androidx.compose.runtime.MutableState
 import androidx.navigation.NavHostController
@@ -17,7 +18,7 @@ import com.example.wabi.view.screens.signUp.SignUp
 fun Navigation(
     controller: NavHostController,
     visibleBB: MutableState<Boolean>,
-    visibleTB: MutableState<Boolean>
+    visibleTB: MutableState<Boolean>,
 ) {
     NavHost(
         navController = controller, startDestination = Routes.BASKET
@@ -25,25 +26,31 @@ fun Navigation(
 
         composable(Routes.BASKET) {
             visibleBB.value = true
+            Log.d("Navigation ->", "nav to ${Routes.BASKET}")
             Basket(navController = controller)
         }
         composable(Routes.ONBOARD) {
+            Log.d("Navigation ->", "nav to ${Routes.ONBOARD}")
             visibleBB.value = false
             Onboard(navController = controller)
         }
         composable(Routes.SIGNIN) {
+            Log.d("Navigation ->", "nav to  ${Routes.SIGNIN}")
             visibleBB.value = true
             SignIn(navController = controller)
         }
         composable(Routes.SIGNUP) {
+            Log.d("Navigation ->", "nav to  ${Routes.SIGNUP}")
             visibleBB.value = false
             SignUp(navController = controller)
         }
         composable(Routes.PROFILE) {
+            Log.d("Navigation ->", "nav to ${Routes.PROFILE}")
             visibleBB.value = true
             Profile(navController = controller)
         }
         composable(Routes.CATALOG) {
+            Log.d("Navigation ->", "nav to  ${Routes.CATALOG}")
             visibleBB.value = true
             Catalog(navController = controller)
         }

+ 1 - 0
mobile_app/wabi/app/src/main/java/com/example/wabi/domain/network/SupabaseService.kt

@@ -9,5 +9,6 @@ interface SupabaseService {
     suspend fun signUp(email: String)
     suspend fun verifyEmail(email: String)
     suspend fun updateUserData(email: String, password: String, nickname: String, theme: Int = 0, imgeLink: String?)
+    suspend fun isSession(): Boolean
 }
 

+ 8 - 6
mobile_app/wabi/app/src/main/java/com/example/wabi/domain/network/SupabaseServiceImpl.kt

@@ -7,7 +7,8 @@ import io.github.jan.supabase.auth.auth
 import io.github.jan.supabase.auth.providers.builtin.Email
 import jakarta.inject.Inject
 
-class SupabaseServiceImpl @Inject constructor(private val supabase: SupabaseClient) : SupabaseService {
+class SupabaseServiceImpl @Inject constructor(private val supabase: SupabaseClient) :
+    SupabaseService {
     override suspend fun signIn(email: String, password: String): Response {
         return try {
             var response = supabase.auth.signInWith(Email) {
@@ -40,13 +41,14 @@ class SupabaseServiceImpl @Inject constructor(private val supabase: SupabaseClie
     }
 
     override suspend fun updateUserData(
-        email: String,
-        password: String,
-        nickname: String,
-        theme: Int,
-        imgeLink: String?
+        email: String, password: String, nickname: String, theme: Int, imgeLink: String?
     ) {
         TODO("Not yet implemented")
     }
 
+    //проверка того, вошёл ли пользователь в систему
+    override suspend fun isSession(): Boolean {
+        return supabase.auth.currentUserOrNull() != null
+    }
+
 }

+ 0 - 4
mobile_app/wabi/app/src/main/java/com/example/wabi/domain/repository/PrefManager.kt

@@ -18,8 +18,4 @@ object PrefManager {
     var userTheme: Int
         get() = localDataSP.getInt("userTheme", 0)
         set(value) = localDataSP.edit().putInt("userTheme", value).apply()
-
-    var currentUser: String?
-        get() = localDataSP.getString("currentUser", null)
-        set(value) = localDataSP.edit().putString("currentUser", value).apply()
 }

+ 12 - 0
mobile_app/wabi/app/src/main/java/com/example/wabi/domain/repository/UserData.kt

@@ -0,0 +1,12 @@
+package com.example.wabi.domain.repository
+
+import android.annotation.SuppressLint
+import android.content.Context
+import androidx.compose.runtime.MutableState
+import androidx.compose.runtime.mutableStateOf
+
+@SuppressLint("StaticFieldLeak")
+object UserData {
+    var context: Context? = null
+    val isSession: MutableState<Boolean> = mutableStateOf(false)
+}

+ 20 - 9
mobile_app/wabi/app/src/main/java/com/example/wabi/view/MainActivity.kt

@@ -1,21 +1,25 @@
 package com.example.wabi.view
 
 import android.os.Bundle
+import android.util.Log
 import androidx.activity.ComponentActivity
 import androidx.activity.compose.setContent
 import androidx.compose.foundation.layout.Box
 import androidx.compose.foundation.layout.fillMaxSize
 import androidx.compose.foundation.layout.padding
 import androidx.compose.material3.Scaffold
+import androidx.compose.runtime.Composable
 import androidx.compose.runtime.mutableStateOf
 import androidx.compose.runtime.remember
 import androidx.compose.ui.Modifier
 import androidx.compose.ui.platform.LocalContext
 import androidx.core.splashscreen.SplashScreen.Companion.installSplashScreen
+import androidx.hilt.navigation.compose.hiltViewModel
 import androidx.navigation.compose.rememberNavController
 import com.example.wabi.domain.navigation.Navigation
 import com.example.wabi.domain.navigation.Routes
 import com.example.wabi.domain.repository.PrefManager
+import com.example.wabi.domain.repository.UserData
 import com.example.wabi.ui.theme.WabiTheme
 import com.example.wabi.view.common_elements.bars.bottom.BottomBar
 import dagger.hilt.android.AndroidEntryPoint
@@ -29,35 +33,37 @@ class MainActivity : ComponentActivity() {
         installSplashScreen()
 
         setContent {
-            val context = LocalContext.current
-            PrefManager.initPrefManager(context)
-
+            UserData.context = LocalContext.current
+            PrefManager.initPrefManager(UserData.context!!)
             val navHostController = rememberNavController()
             val visibleBB = remember { mutableStateOf(false) }
             val visibleTB = remember { mutableStateOf(false) }
-
-            PrefManager.currentUser = "на логин"
-            PrefManager.userTheme = 0
+            UserData.isSession.value = CheckSession()
 
             WabiTheme(themeState = PrefManager.userTheme) {
                 Scaffold(modifier = Modifier.fillMaxSize(),
                     containerColor = WabiTheme.colors.backgroundColor,
                     bottomBar = {
                         if (visibleBB.value) {
-                            BottomBar(navController = navHostController, context = context)
+                            BottomBar(
+                                navController = navHostController,
+                                context = UserData.context!!,
+                                isSession = UserData.isSession
+                            )
                         }
                     }) { paddingValues ->
+                    Log.d("Start", "Session: ${UserData.isSession.value}")
                     Box(
                         modifier = Modifier.padding(paddingValues)
                     ) {
                         Navigation(
                             controller = navHostController,
                             visibleBB = visibleBB,
-                            visibleTB = visibleTB
+                            visibleTB = visibleTB,
                         )
 
                         if (PrefManager.onboard) {
-                            PrefManager.onboard = false
+                            PrefManager.onboard = true
                             visibleBB.value = false
                             navHostController.navigate(Routes.ONBOARD)
                         } else {
@@ -70,3 +76,8 @@ class MainActivity : ComponentActivity() {
         }
     }
 }
+
+@Composable
+fun CheckSession(vm: MainViewModel = hiltViewModel()): Boolean {
+    return vm.isSession()
+}

+ 27 - 0
mobile_app/wabi/app/src/main/java/com/example/wabi/view/MainViewModel.kt

@@ -0,0 +1,27 @@
+package com.example.wabi.view
+
+import androidx.lifecycle.ViewModel
+import androidx.lifecycle.viewModelScope
+import com.example.wabi.domain.network.SupabaseServiceImpl
+import dagger.hilt.android.lifecycle.HiltViewModel
+
+import kotlinx.coroutines.launch
+import javax.inject.Inject
+
+@HiltViewModel
+class MainViewModel @Inject constructor(private val sup: SupabaseServiceImpl) : ViewModel() {
+
+    fun isSession(): Boolean {
+        var result = false
+        viewModelScope.launch {
+            result = sup.isSession()
+        }
+        return result
+    }
+
+    fun GetThemeState() {
+        viewModelScope.launch {
+
+        }
+    }
+}

+ 8 - 4
mobile_app/wabi/app/src/main/java/com/example/wabi/view/common_elements/bars/bottom/BottomBar.kt

@@ -15,6 +15,7 @@ import androidx.compose.material3.ButtonDefaults
 import androidx.compose.material3.Icon
 import androidx.compose.material3.NavigationBar
 import androidx.compose.runtime.Composable
+import androidx.compose.runtime.MutableState
 import androidx.compose.runtime.getValue
 import androidx.compose.ui.Modifier
 import androidx.compose.ui.draw.clip
@@ -29,7 +30,10 @@ import com.example.wabi.ui.theme.WabiTheme
 
 @Composable
 fun BottomBar(
-    navController: NavHostController, modifier: Modifier = Modifier, context: Context
+    navController: NavHostController,
+    modifier: Modifier = Modifier,
+    context: Context,
+    isSession: MutableState<Boolean>
 ) {
     val screens = listOf(
         DestinationsBB.Catalog, DestinationsBB.Basket, DestinationsBB.Profile
@@ -56,13 +60,13 @@ fun BottomBar(
                             nav.NextScreen(
                                 navController = navController,
                                 whereFrom = currentRoute,
-                                where = screen.route
+                                where = if (isSession.value) screen.route else screen.anotherRoute
                             )
                         },
                         contentPadding = PaddingValues(10.dp),
                         modifier = Modifier
                             .size(60.dp)
-                            .offset(y = -8.dp),
+                            .offset(y = (-8).dp),
                         colors = ButtonDefaults.buttonColors(
                             contentColor = WabiTheme.colors.backgroundColor,
                             containerColor = WabiTheme.colors.mainColor
@@ -83,7 +87,7 @@ fun BottomBar(
                             nav.NextScreen(
                                 navController = navController,
                                 whereFrom = currentRoute!!,
-                                where = if (PrefManager.currentUser == null) screen.anotherRoute else screen.route
+                                where = if (isSession.value) screen.route else screen.anotherRoute
                             )
                         },
                         contentPadding = PaddingValues(10.dp),

+ 1 - 1
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/basket/Basket.kt

@@ -6,6 +6,7 @@ import androidx.compose.runtime.Composable
 import androidx.hilt.navigation.compose.hiltViewModel
 import androidx.navigation.NavHostController
 
+
 @Composable
 fun Basket(navController: NavHostController, vm: BasketVM = hiltViewModel()) {
 //        CostRow(
@@ -55,5 +56,4 @@ fun Basket(navController: NavHostController, vm: BasketVM = hiltViewModel()) {
     Row {
         Text("Это корзина")
     }
-
 }

+ 3 - 6
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/onboard/items/OnBoardState.kt

@@ -5,7 +5,6 @@ import androidx.compose.foundation.background
 import androidx.compose.foundation.layout.Arrangement
 import androidx.compose.foundation.layout.Column
 import androidx.compose.foundation.layout.Spacer
-import androidx.compose.foundation.layout.fillMaxHeight
 import androidx.compose.foundation.layout.fillMaxWidth
 import androidx.compose.foundation.layout.height
 import androidx.compose.foundation.layout.padding
@@ -21,24 +20,22 @@ import com.example.wabi.ui.theme.WabiTheme
 
 //модель отображения onboard
 @Composable
-fun OnBoardState(onboardItem: OnBoardItem) {
+fun OnBoardState(onboardItem: OnBoardItem, modifier: Modifier = Modifier) {
     Column(
         horizontalAlignment = Alignment.CenterHorizontally,
     ) {
         Column(
-            modifier = Modifier
+            modifier = modifier
                 .background(color = WabiTheme.colors.onBoardLight)
                 .fillMaxWidth()
-                .height(400.dp),
+                .padding(20.dp),
             verticalArrangement = Arrangement.Center,
             horizontalAlignment = Alignment.CenterHorizontally
         ) {
             Image(
                 imageVector = ImageVector.vectorResource(onboardItem.image),
                 contentDescription = "onboardItem",
-                modifier = Modifier.fillMaxHeight()
             )
-            Spacer(modifier = Modifier.height(50.dp))
         }
         Spacer(modifier = Modifier.height(30.dp))
         Text(

+ 2 - 1
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/onboard/screeen/Onboard.kt

@@ -63,8 +63,9 @@ fun Onboard(
         horizontalAlignment = Alignment.CenterHorizontally
     ) {
         HorizontalPager(state = pagerState) { index ->
-            OnBoardState(onboardItem = pages[index])
+            OnBoardState(onboardItem = pages[index], modifier = Modifier.height(370.dp))
         }
+
         Spacer(modifier = Modifier.height(40.dp))
         OnBoardIndicator(
             pageSize = 3, currentPage = pagerState.currentPage

+ 93 - 22
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signIn/SignIn.kt

@@ -1,37 +1,108 @@
 package com.example.wabi.view.screens.signIn
 
-import androidx.compose.foundation.layout.Row
+import androidx.compose.foundation.layout.Arrangement
+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.offset
+import androidx.compose.foundation.layout.padding
+import androidx.compose.foundation.rememberScrollState
+import androidx.compose.foundation.verticalScroll
 import androidx.compose.material3.Text
 import androidx.compose.runtime.Composable
+import androidx.compose.runtime.mutableStateOf
+import androidx.compose.runtime.remember
+import androidx.compose.ui.Alignment
+import androidx.compose.ui.Modifier
+import androidx.compose.ui.unit.dp
 import androidx.hilt.navigation.compose.hiltViewModel
 import androidx.navigation.NavHostController
-import com.example.wabi.view.common_elements.textfields.CodeTextField
+import com.example.wabi.ui.theme.WabiTheme
+import com.example.wabi.view.common_elements.button.ButtonLink
+import com.example.wabi.view.common_elements.button.MainButton
+import com.example.wabi.view.common_elements.text.error.ErrorList
+import com.example.wabi.view.common_elements.text.error.ErrorPrint
 import com.example.wabi.view.common_elements.textfields.MainTextField
 import com.example.wabi.view.common_elements.textfields.PasswordTextField
 
 @Composable
 fun SignIn(navController: NavHostController, vm: SignInViewModel = hiltViewModel()) {
     val data = vm.data
+    val printError = remember { mutableStateOf(false) }
 
-    Row {
-        Text("Это вход")
-    }
+    Column(
+        modifier = Modifier
+            .fillMaxSize()
+            .verticalScroll(rememberScrollState()),
+        verticalArrangement = Arrangement.SpaceAround,
+        horizontalAlignment = Alignment.CenterHorizontally
+    ) {
 
-    CodeTextField(
-        value = data.email,
-        input = { vm.UpdateData(data.copy(email = it)) },
-    )
-    MainTextField(
-        value = data.email,
-        input = { vm.UpdateData(data.copy(email = it)) },
-        placeholder = "Почта",
-        lable = "Введите почту:",
-        trailingText = ""
-    )
-    PasswordTextField(
-        value = data.password,
-        input = { vm.UpdateData(data.copy(password = it)) },
-        placeholder = "Пароль",
-        lable = "Введите пароль:"
-    )
+        Text(
+            text = "Добро\nпожаловать!",
+            style = WabiTheme.fonts.headerFont,
+            maxLines = 2,
+            minLines = 2,
+            color = WabiTheme.colors.mainColor
+        )
+        Text(
+            text = "Войдите, чтобы\nпользоваться функциями приложения",
+            style = WabiTheme.fonts.mainFont,
+            color = WabiTheme.colors.mainColor
+        )
+        ErrorPrint(text = if (printError.value) ErrorList.errorPassOrEmail else "")
+        Column(
+            modifier = Modifier.fillMaxWidth()
+        ) {
+            MainTextField(
+                value = data.email,
+                input = { vm.updateData(data.copy(email = it)) },
+                placeholder = "Почта",
+                lable = "Введите почту:",
+                trailingText = ""
+            )
+            Spacer(modifier = Modifier.height(10.dp))
+            PasswordTextField(
+                value = data.password,
+                input = { vm.updateData(data.copy(password = it)) },
+                placeholder = "Пароль",
+                lable = "Введите пароль:"
+            )
+        }
+        Column(
+            horizontalAlignment = Alignment.CenterHorizontally
+        ) {
+            Text(
+                text = "Нет аккаунта?",
+                style = WabiTheme.fonts.acentFont,
+                color = WabiTheme.colors.mainColor
+            )
+            ButtonLink(
+                onClick = {
+                    vm.goToRegistration(navController = navController)
+                },
+                textContent = "Зарегистирируйтесь!",
+                modifierButton = Modifier.offset(y = -15.dp),
+                colorContent = WabiTheme.colors.mainColor
+            )
+            MainButton(
+                onClick = {
+                    vm.signIn(navController = navController, printError = printError)
+                },
+                enabled = data.email != "" && data.password != "",
+                textContent = "Войти",
+                modifierButton = Modifier
+                    .padding(30.dp, 0.dp)
+                    .fillMaxWidth()
+            )
+            Spacer(Modifier.height(5.dp))
+            ButtonLink(
+                onClick = {
+                    //привязать переход на страницу регистрации
+                }, textContent = "Забыли пароль?", colorContent = WabiTheme.colors.mainColor
+            )
+        }
+    }
 }

+ 29 - 6
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signIn/SignInViewModel.kt

@@ -1,27 +1,50 @@
 package com.example.wabi.view.screens.signIn
 
+import android.util.Log
+import androidx.compose.runtime.MutableState
 import androidx.compose.runtime.mutableStateOf
 import androidx.lifecycle.ViewModel
 import androidx.lifecycle.viewModelScope
 import androidx.navigation.NavHostController
+import com.example.wabi.domain.navigation.NavigationFun
+import com.example.wabi.domain.navigation.Routes
 import com.example.wabi.domain.network.SupabaseServiceImpl
+import com.example.wabi.domain.repository.UserData
 import com.example.wabi.model.screens.SignInState
 import dagger.hilt.android.lifecycle.HiltViewModel
-import javax.inject.Inject
 import kotlinx.coroutines.launch
+import javax.inject.Inject
 
 @HiltViewModel
-class SignInViewModel @Inject constructor(private val sup: SupabaseServiceImpl) : ViewModel() {
+class SignInViewModel @Inject constructor(
+    private val sup: SupabaseServiceImpl, private val nav: NavigationFun
+) : ViewModel() {
     private val _data = mutableStateOf(SignInState())
     val data: SignInState get() = _data.value
 
-    fun UpdateData(newData: SignInState) {
+    fun updateData(newData: SignInState) {
         _data.value = newData
     }
 
-    fun signIn(navController: NavHostController) {
-        viewModelScope.launch {
-            sup.signIn(_data.value.email, _data.value.password)
+    fun signIn(navController: NavHostController, printError: MutableState<Boolean>) {
+        if (data.email != "" && data.password != "") {
+            viewModelScope.launch {
+                val response = sup.signIn(_data.value.email, _data.value.password)
+                if (response.error == "") {
+                    UserData.isSession.value = true
+                    printError.value = false
+                    nav.NextScreen(navController = navController, Routes.SIGNIN, Routes.PROFILE)
+                } else {
+                    Log.d("signIn", "Ошибка входа!")
+                    printError.value = true
+                }
+            }
         }
     }
+
+    fun goToRegistration(navController: NavHostController) {
+        nav.NextScreen(
+            navController = navController, whereFrom = Routes.SIGNIN, where = Routes.SIGNUP
+        )
+    }
 }

+ 14 - 6
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signUp/SignUp.kt

@@ -1,14 +1,22 @@
 package com.example.wabi.view.screens.signUp
 
-import androidx.compose.foundation.layout.Row
-import androidx.compose.material3.Text
+import androidx.compose.foundation.layout.Column
+import androidx.compose.foundation.layout.fillMaxWidth
 import androidx.compose.runtime.Composable
+import androidx.compose.ui.Modifier
+import androidx.hilt.navigation.compose.hiltViewModel
 import androidx.navigation.NavHostController
 
 
 @Composable
-fun SignUp(navController: NavHostController) {
-    Row {
-        Text("Это регистрация")
+fun SignUp(navController: NavHostController, vm: SignUpViewModel = hiltViewModel()) {
+
+    // val states = listOf()
+
+    Column(
+        modifier = Modifier.fillMaxWidth()
+    ) {
+
     }
-}
+}
+

+ 12 - 0
mobile_app/wabi/app/src/main/java/com/example/wabi/view/screens/signUp/SignUpViewModel.kt

@@ -0,0 +1,12 @@
+package com.example.wabi.view.screens.signUp
+
+import androidx.lifecycle.ViewModel
+import com.example.wabi.domain.network.SupabaseServiceImpl
+import dagger.hilt.android.lifecycle.HiltViewModel
+import javax.inject.Inject
+
+@HiltViewModel
+class SignUpViewModel @Inject constructor(private val sup: SupabaseServiceImpl) : ViewModel()
+{
+
+}

+ 7 - 3
mobile_app/wabi/app/src/main/java/com/example/wabi/view/ui/theme/Type.kt

@@ -39,18 +39,21 @@ val type = Type(
         fontFamily = BalooDa2,
         fontWeight = FontWeight.Bold,
         fontSize = 35.sp,
-        textAlign = TextAlign.Center
+        textAlign = TextAlign.Center,
+        lineHeight = 35.sp,
     ),
     mainFont = TextStyle(
         fontFamily = Confortaa,
         fontWeight = FontWeight.Normal,
         fontSize = 20.sp,
-        textAlign = TextAlign.Center
+        textAlign = TextAlign.Center,
+        lineHeight = 20.sp
     ),
     acentFont = TextStyle(
         fontFamily = EduQLDBeginner,
         fontWeight = FontWeight.Normal,
-        fontSize = 20.sp
+        fontSize = 20.sp,
+        lineHeight = 20.sp
     ),
     buttonFont = TextStyle(
         fontFamily = BalooDa2,
@@ -69,6 +72,7 @@ val type = Type(
         fontWeight = FontWeight.Normal,
         fontSize = 20.sp,
         textDecoration = TextDecoration.Underline,
+        lineHeight = 20.sp
     ),
     forTextField = TextStyle(
         fontFamily = BalooDa2,