generated from AND-SOPT-ANDROID/and-sopt-android-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat/#12: signUp 회원가입 화면 baseviewmodel, uiEvent, uiSideEffect, uiStat…
…e 사용으로 수정
- Loading branch information
1 parent
73964a1
commit 4753dd3
Showing
6 changed files
with
69 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
presentation/src/main/java/org/sopt/and/presentation/sign/signup/contract/SignUpEvent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package org.sopt.and.presentation.sign.signup.contract | ||
|
||
import org.sopt.and.presentation.util.base.UiEvent | ||
|
||
sealed class SignUpEvent: UiEvent { | ||
data class OnIdChanged(val id: String) : SignUpEvent() | ||
data class OnPasswordChanged(val password: String) : SignUpEvent() | ||
data class OnHobbyChanged(val hobby: String) : SignUpEvent() | ||
data object OnSignUpButtonClick : SignUpEvent() | ||
} |
11 changes: 11 additions & 0 deletions
11
...entation/src/main/java/org/sopt/and/presentation/sign/signup/contract/SignUpSideEffect.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package org.sopt.and.presentation.sign.signup.contract | ||
|
||
import androidx.annotation.StringRes | ||
import org.sopt.and.presentation.util.base.UiSideEffect | ||
|
||
sealed class SignUpSideEffect: UiSideEffect { | ||
data class SnackBar(@StringRes val message: Int) : SignUpSideEffect() | ||
data class SnackBarText(val message: String): SignUpSideEffect() | ||
data object NavigateToSignIn: SignUpSideEffect() | ||
} | ||
|
5 changes: 3 additions & 2 deletions
5
...entation/sign/signup/model/SignUpState.kt → ...ation/sign/signup/contract/SignUpState.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
package org.sopt.and.presentation.sign.signup.model | ||
package org.sopt.and.presentation.sign.signup.contract | ||
|
||
import org.sopt.and.presentation.util.KeyUtil.DEFAULT_STRING | ||
import org.sopt.and.presentation.util.base.UiState | ||
|
||
data class SignUpState( | ||
val id: String = DEFAULT_STRING, | ||
val password: String = DEFAULT_STRING, | ||
val hobby: String = DEFAULT_STRING | ||
) | ||
): UiState |
10 changes: 0 additions & 10 deletions
10
presentation/src/main/java/org/sopt/and/presentation/sign/signup/intent/SignUpSideEffect.kt
This file was deleted.
Oops, something went wrong.
63 changes: 33 additions & 30 deletions
63
...entation/src/main/java/org/sopt/and/presentation/sign/signup/viewmodel/SignUpViewModel.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters